User Tools

Site Tools


feathers2_apa102

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
feathers2_apa102 [2024/03/26 10:10]
sausage
feathers2_apa102 [2024/04/04 01:09]
sausage [FeatherS2 ESP32-S2 APA102]
Line 1: Line 1:
-====== ​FeatherS2 ​ESP32-S2 APA102 ======+====== ESP32-S2 ​and the APA102 ​RGB LED ======
  
 {{ ::​esp32s2:​feathers2.jpg?​direct&​400|}} {{ ::​esp32s2:​feathers2.jpg?​direct&​400|}}
Line 24: Line 24:
  
  
-===== Setting up an ESP32 or ESP32-S2 project =====+===== Setting up an ESP32-S2 project =====
  
 In order that we can get the RGB LED working together, let's make a new project. In order that we can get the RGB LED working together, let's make a new project.
Line 132: Line 132:
 </​code>​ </​code>​
  
-To explain the initApa102 function, we have a minimal SPI config ​and a minimal SPI bus configThe SPI bus is initialised with the SPI config along with which SPI host it is for. The SPI bus config and the SPI host is passed a new device. ******+To explain the initApa102 function, we have a minimal SPI Interface Config ​and a minimal SPI Bus ConfigThese configs are set to a SPI host device ​it is for. 
  
-Note the host is FSPI_HOST. This is the host that is controlling the LED. On ESP32 boards (non S2), this SPI is named HSPI_HOST.+Our host is ''​FSPI_HOST''​. This is one that is controlling the LED. On ESP32 boards (non S2), this SPI is named ''​HSPI_HOST''​.
  
 See: https://​github.com/​espressif/​esp-idf/​blob/​357a2776032299b8bc4044900a8f1d6950d7ce89/​components/​hal/​include/​hal/​spi_types.h#​L47-L57 See: https://​github.com/​espressif/​esp-idf/​blob/​357a2776032299b8bc4044900a8f1d6950d7ce89/​components/​hal/​include/​hal/​spi_types.h#​L47-L57
Line 208: Line 208:
 The LED won't come on? There are a number of things to re-check: The LED won't come on? There are a number of things to re-check:
  
-  - Ensure USB CDC is set in the menuconfig ​or the board firmware will fail.+  - Firmware may have crashed. ​Ensure USB CDC is set in the menuconfig.
   - Ensure RGB_DATA_PIN is set to mosi_io_num and RGB_CLK_PIN to sclk_io_num. Check it's not the wrong way around.   - Ensure RGB_DATA_PIN is set to mosi_io_num and RGB_CLK_PIN to sclk_io_num. Check it's not the wrong way around.
   - Ensure pin 21 is on to supply power.   - Ensure pin 21 is on to supply power.
feathers2_apa102.txt ยท Last modified: 2024/04/04 21:34 by sausage