![]() |
OpenSourceSimWheelESP32
Open-source wireless steering wheel/button box for ESP32 boards
|
Configure input hardware and specify input numbers. More...
#include "SimWheelTypes.hpp"#include <cstdint>#include <stdexcept>#include <vector>#include <map>#include <cstring>#include <array>Go to the source code of this file.
Classes | |
| struct | AnalogMultiplexerChip< PinTags > |
| Generic analog multiplexer chip. More... | |
Typedefs | |
| typedef std::map< OutputGPIO, std::map< InputGPIO, InputNumber > > | ButtonMatrix |
| Button matrix specification. | |
| typedef AnalogMultiplexerChip< Mux8Pin > | AnalogMultiplexerChip8 |
| 8-channel analog multiplexer chip | |
| typedef AnalogMultiplexerChip< Mux16Pin > | AnalogMultiplexerChip16 |
| 16-channel analog multiplexer chip | |
| typedef AnalogMultiplexerChip< Mux32Pin > | AnalogMultiplexerChip32 |
| 32-channel analog multiplexer chip | |
| template<typename PinTags > | |
| using | AnalogMultiplexerGroup = std::vector<AnalogMultiplexerChip<PinTags>> |
| Group of analog multiplexer chips sharing the same selector pins. | |
| template<typename PinTags > | |
| using | GPIOExpanderChip = std::map<PinTags, InputNumber> |
| Generic GPIO expander chip. | |
| typedef GPIOExpanderChip< MCP23017Pin > | MCP23017Expander |
| MCP23017 GPIO Expander for switches. | |
| typedef GPIOExpanderChip< PCF8574Pin > | PCF8574Expander |
| PCF8574 GPIO Expander for switches. | |
| typedef std::map< SR8Pin, InputNumber > | ShiftRegisterChip |
| PISO shift register chip. | |
| typedef std::vector< ShiftRegisterChip > | ShiftRegisterChain |
| Chain of PISO shift registers for switches. | |
| typedef std::map< uint8_t, InputNumber > | RotaryCodedSwitch |
| Rotary coded switch. | |
| typedef std::array< InputNumber, 8 > | CodedSwitch8 |
| Rotary coded switch up to 8 positions. | |
| typedef std::array< InputNumber, 16 > | CodedSwitch16 |
| Rotary coded switch up to 16 positions. | |
| typedef std::array< InputNumber, 32 > | CodedSwitch32 |
| Rotary coded switch up to 32 positions. | |
Enumerations | |
| enum class | Mux8Pin { A0 = 0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 } |
| 74HC4051N pin tags for switches or any other 8-channel multiplexer More... | |
| enum class | Mux16Pin { I0 = 0 , I1 , I2 , I3 , I4 , I5 , I6 , I7 , I8 , I9 , I10 , I11 , I12 , I13 , I14 , I15 } |
| CD74HCx4067 pin tags for switches or any other 16-channel multiplexer. More... | |
| enum class | Mux32Pin { S1 = 0 , S2 , S3 , S4 , S5 , S6 , S7 , S8 , S9 , S10 , S11 , S12 , S13 , S14 , S15 , S16 , S17 , S18 , S19 , S20 , S21 , S22 , S23 , S24 , S25 , S26 , S27 , S28 , S29 , S30 , S31 , S32 } |
| ADG732 pin tags for switches or any other 32-channel multiplexer. More... | |
| enum class | MCP23017Pin { GPA0 = 0 , GPA1 , GPA2 , GPA3 , GPA4 , GPA5 , GPA6 , GPA7 , GPB0 , GPB1 , GPB2 , GPB3 , GPB4 , GPB5 , GPB6 , GPB7 } |
| MCP23017 pin tags for switches. More... | |
| enum class | PCF8574Pin { P0 = 0 , P1 , P2 , P3 , P4 , P5 , P6 , P7 } |
| MCP23017 pin tags for switches. More... | |
| enum class | SR8Pin { H = 0 , G , F , E , D , C , B , A } |
| 74HC165N pin tags for switches More... | |
Functions | |
| void | populateButtonMatrix (ButtonMatrix &matrix, const OutputGPIOCollection selectors, const InputGPIOCollection inputs, const InputNumber first) |
| Populate a button matrix with sequential input numbers. | |
Configure input hardware and specify input numbers.
Definition in file InputSpecification.hpp.
16-channel analog multiplexer chip
Definition at line 195 of file InputSpecification.hpp.
32-channel analog multiplexer chip
Definition at line 201 of file InputSpecification.hpp.
8-channel analog multiplexer chip
Definition at line 189 of file InputSpecification.hpp.
| using AnalogMultiplexerGroup = std::vector<AnalogMultiplexerChip<PinTags>> |
Group of analog multiplexer chips sharing the same selector pins.
| PinTags | Pin tags |
Definition at line 209 of file InputSpecification.hpp.
| typedef std::map<OutputGPIO, std::map<InputGPIO, InputNumber> > ButtonMatrix |
Button matrix specification.
Definition at line 36 of file InputSpecification.hpp.
| typedef std::array<InputNumber, 16> CodedSwitch16 |
Rotary coded switch up to 16 positions.
Definition at line 333 of file InputSpecification.hpp.
| typedef std::array<InputNumber, 32> CodedSwitch32 |
Rotary coded switch up to 32 positions.
Definition at line 339 of file InputSpecification.hpp.
| typedef std::array<InputNumber, 8> CodedSwitch8 |
Rotary coded switch up to 8 positions.
Definition at line 327 of file InputSpecification.hpp.
| using GPIOExpanderChip = std::map<PinTags, InputNumber> |
Generic GPIO expander chip.
| PinTags |
Definition at line 261 of file InputSpecification.hpp.
| typedef GPIOExpanderChip<MCP23017Pin> MCP23017Expander |
MCP23017 GPIO Expander for switches.
Definition at line 267 of file InputSpecification.hpp.
| typedef GPIOExpanderChip<PCF8574Pin> PCF8574Expander |
PCF8574 GPIO Expander for switches.
Definition at line 273 of file InputSpecification.hpp.
| typedef std::map<uint8_t, InputNumber> RotaryCodedSwitch |
Rotary coded switch.
Definition at line 321 of file InputSpecification.hpp.
| typedef std::vector<ShiftRegisterChip> ShiftRegisterChain |
Chain of PISO shift registers for switches.
Definition at line 310 of file InputSpecification.hpp.
| typedef std::map<SR8Pin, InputNumber> ShiftRegisterChip |
PISO shift register chip.
Definition at line 299 of file InputSpecification.hpp.
|
strong |
MCP23017 pin tags for switches.
Definition at line 219 of file InputSpecification.hpp.
|
strong |
CD74HCx4067 pin tags for switches or any other 16-channel multiplexer.
Definition at line 84 of file InputSpecification.hpp.
|
strong |
ADG732 pin tags for switches or any other 32-channel multiplexer.
Definition at line 109 of file InputSpecification.hpp.
|
strong |
74HC4051N pin tags for switches or any other 8-channel multiplexer
Definition at line 67 of file InputSpecification.hpp.
|
strong |
MCP23017 pin tags for switches.
Definition at line 243 of file InputSpecification.hpp.
|
strong |
74HC165N pin tags for switches
Definition at line 283 of file InputSpecification.hpp.
|
inline |
Populate a button matrix with sequential input numbers.
| matrix | Button matrix |
| selectors | Collection of selector pins |
| inputs | Collection of input pins |
| first | First input number to be assigned |
Definition at line 46 of file InputSpecification.hpp.