35typedef std::map<OutputGPIO, std::map<InputGPIO, InputNumber>>
ButtonMatrix;
51 uint8_t in = (uint8_t)first;
52 for (
auto row : selectors)
54 matrix[row][col] = in++;
149template <
typename PinTags>
159 : std::map<PinTags,
InputNumber>(), inputGPIO{inputPin} {}
181 for (
auto i = this->begin(); i != this->end(); i++)
219template <
typename PinTags>
271template <
typename PinTags>
Types and constants required for custom firmware setup.
std::set< InputGPIO > InputGPIOCollection
Collection of input GPIOs.
std::set< OutputGPIO > OutputGPIOCollection
Collection of output GPIOs.
Generic analog multiplexer chip.
AnalogMultiplexerChip & operator=(AnalogMultiplexerChip &&)=default
Move-assignment (default)
AnalogMultiplexerChip(InputGPIO inputPin)
Construct a new Analog Multiplexer Chip object.
void reserve_and_book()
Reserve the input pin and book all input numbers.
AnalogMultiplexerChip(const AnalogMultiplexerChip &)=default
Copy constructor (default)
AnalogMultiplexerChip & operator=(const AnalogMultiplexerChip &)=default
Copy-assignment (default)
InputGPIO getInputGPIO()
Get the input GPIO pin.
AnalogMultiplexerChip(AnalogMultiplexerChip &&)=default
Move constructor (default)
void reserve() const
Reserve this GPIO for exclusive use.