acid-drop

- Hacking the planet from a LilyGo T-Deck using custom firmware
git clone git://git.acid.vegas/acid-drop.git
Log | Files | Refs | Archive | README | LICENSE

lv_example_led_1.py (464B)

      1 #
      2 # Create LED's with different brightness and color
      3 #
      4 
      5 # Create a LED and switch it OFF
      6 led1  = lv.led(lv.scr_act())
      7 led1.align(lv.ALIGN.CENTER, -80, 0)
      8 led1.off()
      9 
     10 # Copy the previous LED and set a brightness
     11 led2  = lv.led(lv.scr_act())
     12 led2.align(lv.ALIGN.CENTER, 0, 0)
     13 led2.set_brightness(150)
     14 led2.set_color(lv.palette_main(lv.PALETTE.RED))
     15 
     16 # Copy the previous LED and switch it ON
     17 led3  = lv.led(lv.scr_act())
     18 led3.align(lv.ALIGN.CENTER, 80, 0)
     19 led3.on()
     20