🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    M5Stack CoreS3 SE + COMMU display problem when replugging USB

    Arduino
    2
    3
    56
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F
      frank_b
      last edited by

      hi

      i have a weird problem with the CoreS3 SE + COMMU. i have some RS485 device and data coming on a UART configured to the CoreS3 port (next to the USB-C connector). data is displayed/updated on the screen. during (arduino) development all worked fine. flashing code over USB automatically restarts the code and i have a nice display updating every second.

      but i found out that not flashing the CoreS3 and just connecting USB-C for power (and logging) i get a somewhat scrambled display.

      i have chatted quite a bit with the M5Stack AI chat but it is still not fixed. everytime i just connect USB-C it is a bit scrambled. re-flashing the same code give a nice and clean display. what is going on??

      my initialization code is (most of it suggested by M5Stack AI):

          auto cfg = M5.config();
          cfg.internal_imu = false;
          cfg.internal_mic = false;
          cfg.clear_display = true; // Ensure display is cleared during init
      
          // Initialize M5 with proper power sequencing
          M5.begin(cfg);
      
          // Explicitly reset the AW9523 IO expander that controls display power
          Wire.begin(11, 12); // CoreS3 internal I2C bus pins
          Wire.beginTransmission(0x58); // AW9523 address
          Wire.write(0x00); // Reset register
          Wire.write(0x00); // Perform hardware reset
          Wire.endTransmission();
          delay(100);
      
          // Re-initialize display with full reset
          M5.Display.init();
          M5.Display.setBrightness(128);
          M5.Display.fillScreen(TFT_BLACK);
          M5.Display.display();
      

      the wire command actually give errors so i do not think it is doing anything:

      E (3570) i2c.master: I2C transaction unexpected nack detected
      E (3571) i2c.master: s_i2c_synchronous_transaction(945): I2C transaction failed
      E (3572) i2c.master: i2c_master_multi_buffer_transmit(1207): I2C transaction failed
      

      here is a "scrambled" picture:
      replug-usb-small.jpg

      and this after reflash:
      reflash-small.jpg

      help?!

      felmueF 1 Reply Last reply Reply Quote 0
      • felmueF
        felmue @frank_b
        last edited by

        Hello @frank_b

        have you tired without COMMU module stacked?

        Thanks
        Felix

        GPIO translation table M5Stack / M5Core2
        Information about various M5Stack products.
        Code examples

        F 1 Reply Last reply Reply Quote 0
        • F
          frank_b @felmue
          last edited by

          @felmue thanks for your message: i also had the "din base" and the "lan module" connected (but not used). disconnecting the lan module fixes the problem!!

          1 Reply Last reply Reply Quote 0
          • First post
            Last post