@cliffwade I am running FreeRTOS on the #ravelights I make.

Well, today in Ravelights progress, we've got the things using their new NimBLE-backed updater. Turns out a writable attribute had gone missing in the upgrade.

It's being weird, though - our "you can run the updater webapp" support matrix has gone from Windows/Android to Android/iOS (mobile and desktop).

When I try to run the updater from Windows, my ESP32 says things like "Updater disconnected for reason β„– 520." Or β„– 12, a classic. And then a bunch of E NimBLEAdvertising: ble_gap_adv_stop rc=22 Host not synced with controller.

I have, needless to say, no idea what this means. Maybe it's timing related? I tried loosening up the time on both ends but that didn't help. 

At least pairing is working well again. Turns out an advertised capability had gone for a walk as well during the upgrade. This whole thing has turned out to be surprisingly hard, I will say.

#Ravelights #Bluetooth #JustWindowsThings

Usually, if I have a member constant I want to have configurable in my constructor, I have it by the same name in the constructor parameters. In this case, ModePattern* backingMode was passed in, and then saved for later use in the constructor list via backingMode(backingMode). This pattern has worked fine for about two years () at this point.

Today, it stopped working because I had a lambda function which captured by reference, [&](){...}-like. I had copied out the pattern sampling function, backingMode->sample(samplePoint, Layer::Primary) from another function in my class. Copy-paste-done, works perfectly, moving on. Except.

I'd copied it into my constructor. The way precedence works, backingMode is looked up first in function args, then in class members. So when I moved the line of code up to the constructor, inside the lambda function, it neatly captured a reference to the constructor parameter instead of the class member function which was being used previously. And this worked fine, until I actually went and looked up a member variable in the lambda which was run after the function returned. A few seconds later, the memory was overwritten with some value that pointed into the zero-page, and I get the error.

It could have been hours. We got lucky this time. 

Anyway, I just learned how addr2line works in Linux, so that's useful going forward. I'm... new to this yet. Another entry in the #ravelights development ongoing saga 

Hmh. The particle effect is kinda working ok for the probably-upcoming #ravelights chill mode. Still not really happy with it though. πŸ€”

Did a bit of work on my Ravelight project tonight. Seems if I send state sync message over Bluetooth, the light never shows up in the scan for Bluetooth updating. It's still there, it just doesn't show up.

I don't know why because my graphics card hung during the debugging session for that.

Something around here is cursed, I swear.

#ravelights

Dry run on the light show. My niece and nephew’s Halloween party is gonna be epic. #halloween #halloweenparty #lightshow #partylights #ravelights #rave #bestuncleever #favoriteuncle