diff --git a/src/mappings.rs b/src/mappings.rs index 1f4ac61..bb87868 100644 --- a/src/mappings.rs +++ b/src/mappings.rs @@ -101,6 +101,12 @@ impl StrideMapping { ]) } + pub fn new_fairylights() -> Self { + Self::from_json(&[ + (0, 0, 50, false) + ]) + } + pub fn new_jar() -> Self { Self::from_json(&[ (0, 0, 17, false), diff --git a/src/platform/esp32.rs b/src/platform/esp32.rs index 2f7b3eb..7b9b028 100644 --- a/src/platform/esp32.rs +++ b/src/platform/esp32.rs @@ -139,6 +139,30 @@ impl Board for Esp32Board { MAX_POWER_MW ) }, + [0x4a, 0xca, 0x43, 0x59, 0x85, 0x58, 0x0, 0x0] => { // Albus the tree + StrideOutput::new( + Pixbuf::new(), + StrideMapping::new_jar(), + std::thread::spawn(move || { FastWs2812Esp32Rmt::new(peripherals.rmt.channel0, pins.gpio5).unwrap() }).join().unwrap(), + MAX_POWER_MW + ) + }, + [0x48, 0xca, 0x43, 0x59, 0x9d, 0x48, 0x0, 0x0] => { // kitchen cabinets + StrideOutput::new( + Pixbuf::new(), + StrideMapping::new_fairylights(), + std::thread::spawn(move || { FastWs2812Esp32Rmt::new(peripherals.rmt.channel0, pins.gpio5).unwrap() }).join().unwrap(), + MAX_POWER_MW + ) + }, + [0x48, 0xca, 0x43, 0x59, 0x9e, 0xdc, 0x0, 0x0] => { // front window + StrideOutput::new( + Pixbuf::new(), + StrideMapping::new_fairylights(), + std::thread::spawn(move || { FastWs2812Esp32Rmt::new(peripherals.rmt.channel0, pins.gpio5).unwrap() }).join().unwrap(), + MAX_POWER_MW + ) + } _ => { StrideOutput::new( Pixbuf::new(),