ESP8266/ESP32 based mesh to drive and synchronize a swarm of mobile LEDs
VIDEO: https://www.youtube.com/watch?v=Uttsf_RPKiI
In the video the nodes are using the awesome M5Stack Atom Matrix ESP32 dev kit: https://m5stack.com/collections/m5-atom/products/atom-matrix-esp32-development-kit
Using these awesome libraries:
- painlessMesh: https://gitlab.com/painlessMesh
- FastLED: https://github.com/FastLED/FastLED
- TaskScheduler: https://github.com/arkhipenko/TaskScheduler
- ArduinoTapTempo: https://github.com/dxinteractive/ArduinoTapTempo
Please note the official ArduinoTapTempo has a bug that crashes ESP32 I've updated platformio.ini with a fork that has a fix
- No central node needed
- Automatic joining of wifi mesh
- Mesh leader election
- Automatic synchronisation of pattern, pattern timing and BPM (for bpm based patterns).
- Each node will work standalone when out of range of the rest (it will become it's own leader)
- On the Atom Matrix 5x5 rgb display the heart animation will pulse slowly (with a blue center) when alone (out of range) and will pulse quickly when together in a mesh!
Exact synchronisation of patterns and timing is done by FastLED using the clock from the mesh instead of an internal timer:
uint32_t get_millisecond_timer() {
return mesh.getNodeTime()/1000 ;
}
- Make a new src/headers/.h file with your preferences (see other files for examples)
- Edit platformio.ini with your board details and point to the header file (see other examples)
- Compile & upload
- Multi-node sequential patterns: nodes handoff patterns to each other in sequence
- Control via an app or other interface
- UI/UX: button to control BPM/brightness - or long/short press controls