Add PixelStomp MUX driver (DAT=9, LD=10, CLK=11, DI=12)
- New PixelStompMux class with shift register read/write - Read 10 buttons via DI (active LOW) - Drive 10 LEDs via DAT (shift out + latch) - LED startup animation uses MUX - Switch polling reads from MUX shift register - MUX instance shared between switch and LED drivers
This commit is contained in:
@@ -21,6 +21,8 @@ struct SwitchState {
|
||||
uint32_t debounce_time;
|
||||
};
|
||||
|
||||
class PixelStompMux;
|
||||
|
||||
class DefaultSwitchStub : public SwitchStub {
|
||||
private:
|
||||
static const uint8_t NUM_SWITCHES = 10;
|
||||
@@ -33,4 +35,6 @@ public:
|
||||
bool is_pressed(uint8_t switch_id) override;
|
||||
void configure_switch(uint8_t switch_id, uint8_t gpio_pin) override;
|
||||
void set_debounce_time(uint32_t time_ms) override;
|
||||
|
||||
void set_mux(PixelStompMux* mux);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user