Whilst I await delivery of more WS2812 LEDs, I wanted to start investigating how I can leverage the Alexa Gadget Toolkit integration, so that when I set a timer using Alexa, my LED clock can show the countdown.
Amazon make an Echo Wall Clock which does just that.
I found an open source project called nixie-timer, which had an Alexa Integration and was written for the ESP32
After a few hours of digging around, I had a very basic idea of what the code was doing. I started by trying to replicate the flow using the OOB ESP-IDF.
After many, many, many hours, I realised that I really didn’t know what I was doing, so I went back to the nixie-timer code and added the btstack ESP32 port into my code. This meant I could at least follow the samples provided.
I began trying to run some code myself, but the Bluetooth radio wouldn’t even start. I then took one of the BTStack examples and used that as a starting point. At least they worked.
After more hours, I got the code running, with the occasional kernel panic as I figured stuff out..
Eventually, I got it responding to the Alexa queries and receiving the messages for wakeword, timeinfo and timer.
Exactly what I wanted to achieve. I’m not 100% sure I know what’s going on, but I’ll get more understanding over time.
For starters, I want to use timeinfo to set the internal clock and then I want to use the timer command to display the countdown of an alexa timer.
Now that I’ve moved back to ESP-IDF, I’m going to have to bin my existing Arduino code which powers the LED strip and look at how to make that work.
Happy with progress.
My other WS2812 strip arrived the other day, so I’ve got to look at cutting and connecting the two strips to form one long 180 LED strip. Then I get get a feel of the overall diameter and cut some MDF to house the damn thing.