This is a hello world starting point for arduino controlled WS2812B RGB leds.
Anyone who has already used an arduino has probably used the Arduino IDE. You
don't need it! This project will introduce the amazing platformio
command
line tool. This project can be edited using any text editor you wish.
Pull requests are welcome!
- Connect a strip of 40 WS2812B leds to an arduino
- Serial data on PIN 5
- Plug arduino into computer
- Find its port
- Clone repo
- using ssh
git clone [email protected]:DanHartman/ws2812b.git
- using https
git clone https://github.com/DanHartman/ws2812b.git
- using ssh
cd ws2812b/platformio/
platformio run -e uno --target upload --upload-port "/WHATEVER/PORT/YOU/SEE/IT/CONNECTED/TO"
- Power up and enjoy!
platformio
PlatformIO Core (CLI) install
This project is agnostic in this regard. You will simply select which kind of
Arduino you're using when you run the platformio commands. All examples in this
README are given using an uno
board. However, the user may specify nano
as
well. Extending this to other boards is as simple as adding environments to the
platformio/platformio.ini
file.
This project will use D5
as the data pin per this diagram
- connect arduino to host machine
- determine its serial port
- *Nix
ls /dev/
- Windows: check the
device manager
- *Nix
cd platformio
- compile:
platformio run -e uno
- burn to uno:
platformio run -e uno --target upload --upload-port "/dev/ttyUSB0"