Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
LEDs and NeoPixelIntroduction | ||||||||
Line: 10 to 10 | ||||||||
You can see the LEDs in the far left, bottom corner. The power LED is marked "ON" while the user programmable one is marked "L". The NeoPixel is based on the WS2812 addressable RGB LED which is often used in LED chains. In our case we have 6 LEDs arranged in a ring with a 7th one placed in the center of the ring. | ||||||||
Changed: | ||||||||
< < | Again the LEDs are accessible, this time through a dedicate serial protocol, on a GPIO line. For the board we are using the GPIO line can be selected with solder jumpers. The jumpers were set to D0 or GPIO 26. | |||||||
> > |
| |||||||
Further introductory remarks: | ||||||||
Changed: | ||||||||
< < | In comparison with the first exercise session these exercises are rather simple. This is mainly due to the fact that all difficulties in accessing the devices is hidden from you in the drivers which are part of MicroPython. If you want to know what is going on behind the scene please have a look at https://www.parallax.com/sites/default/files/downloads/28085-WS2812B-RGB-LED-Datasheet.pdf | |||||||
> > | In comparison with the first exercise session these exercises are rather simple. This is mainly due to the fact that all difficulties in accessing the devices are hidden from you in the drivers which are part of MicroPython. If you want to know what is going on behind the scene please have a look at https://www.parallax.com/sites/default/files/downloads/28085-WS2812B-RGB-LED-Datasheet.pdf | |||||||
Exercise 1: Switching the user LED with REPLIt is actually very easy to access the LED because all you need is already available in MicroPython. Just look it up athttps://docs.micropython.org/en/latest/esp32/quickref.html#pins-and-gpio and try the example using GPIO pin 2. Don't write a script just yet but switch the LED on and off with REPL. | ||||||||
Line: 36 to 35 | ||||||||
-- Uli Raich - 2020-05-05
Exercise 5: The WS2812 addressable LED | ||||||||
Changed: | ||||||||
< < | The WS2812 LED is often used in LED chains. It is an RGB LED using a single data line which can be cascaded. It has a data in pin and a data out pin where the data out pin is connected to the data in pin of the following LED. It uses a serial protocol that must be precisely timed. For more information please consult the data sheet. Fortunatelly a driver for the WS2812 running on the ESP32 is already integrate into the MicroPython binary. | |||||||
> > | The WS2812 LED is often used in LED chains. It is an RGB LED using a single data line which can be cascaded. It has a data in pin and a data out pin where the data out pin is connected to the data in pin of the following LED. It uses a serial protocol that must be precisely timed. For more information please consult the data sheet. Fortunately a driver for the WS2812 running on the ESP32 is already integrated into the MicroPython binary. | |||||||
Warning: The WS2812 produces very bright light! Do not look into it directly or reduce the light intensity by software. | ||||||||
Line: 53 to 52 | ||||||||
| ||||||||
Added: | ||||||||
> > |
|