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

    ATOMS3 Screen Backlight → Want to Switch OFF

    Atom
    3
    3
    2.3k
    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.
    • H
      hugo.reed
      last edited by

      Hello Here,
      In order to only use my AtomS3 for a BLE application and connect it via USB-C to a small battery, I'd like to cut the backlight completely in order to save energy and tiny heat when long time ON, ∆ and also use an OTII-ARC tool to measure the consumption of my program and the AtomS3 in this BLE advertising mode,

      • without over-consumption due to the fact that the backlight is always ON - even if the pixels are black.
        I understand that the lcd is a N085-1212TBWIG06-C08 ; on the M5STICK and M5STICKplus I was able to cut the screen with the following code: (thanks community)

      *void turnOffScreen() {
      // try to turn off screen - https://community.m5stack.com/topic/1025/m5stickc-turn-off-screen-completely/11
      // OK
      Wire1.beginTransmission(0x34);
      Wire1.write(0x12);
      Wire1.write(0b01001011); // LDO2, aka OLED_VDD, off
      Wire1.endTransmission();

      // not tested
      /M5.begin(0,1,1);
      M5.Axp.SetLDO2(false);
      M5.Axp.SetLDO3(false);
      /

      //M5.Lcd.setBrightness(0);
      //M5.Axp.ScreenSwitch(false);
      }*

      The reason I'm here is that this code doesn't work on the ATOMS3 and I haven't figured out how to do it yet.
      Can you help me?
      Thank you in advance

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

        Hello @hugo-reed

        according to the M5AtomS3 documentation the backlight is connected to GPIO16. So setting that to LOW should turn it off. (Note: not tested)

        digitalWrite(16, LOW);
        

        Note: GPIO16 gets initialized and set to HIGH in function M5Display::begin().

        Thanks
        Felix

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

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

          Alternatively - using M5Unified you can also call:

          M5.Display.sleep();

          To wake it up again use:

          M5.Display.wakeup();

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