The badge can be easily reprogrammed using the Arduino IDE as an "Arduino Leonardo" target. In my case, I accidentally erased the flash of the atmega32u4 while trying to dump the stock firmware, so I used a buspirate as an ISP to burn the arduino bootloader back on to the badge via the broken out ICSP header. After a few rounds of guessing at pin numbers, I mapped all the pot and LED pins out as follows:
Arduino Pin | Connected to |
A2 | Left potentiometer |
A1 | Cener potentiometer |
A0 | Right potentiometer |
11 | Neopixels |
- The first neopixel (index 0) is the bottom most LED.
- Each pot turned fully counterclockwise provides a value of 1023, and 0 when fully clockwise
I wrote a quick demo sketch where each potentiometer controls the brightness of Red, Green, and Blue respectively. The first 3 LEDs show each individual color brightness and the 4th LED displays all 3 color channels at once, mixing to different colors depending on the brightness of each color channel. The result is showed in the first image in my project gallery. I have shared the code to this sketch on github, also linked from the main project page.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.