|
MAX22200 Driver 0.1.0
API reference
|
| ▼Nmax22200 | The MAX22200 driver: everything it declares lives here; internals in detail |
| Nreg | The MAX22200 register map |
| CChannelConfig | One channel's CFG_CHn register, as codes (Table 11). ChannelConfig{} is the reset value: CDR, low side, every code 0 (no current), 25 kHz, every diagnostic off |
| CConfig | What the driver is told about the chip and the board. Config{} holds the reset values of STATUS and every CFG_CHn (Register Details, p36, p38-39), for a part declared as Max22200 (correct on both parts) and an RREF not given. CFG_DPM has no reset values in the datasheet (p40-41): dpm is 0, the value the driver writes at start-up, not a known reset state |
| CDpmConfig | The plunger-movement detection settings, CFG_DPM (global, for every channel with ChannelConfig::plunger_detect). DpmConfig{} is all zero |
| CDutyLimits | The duty-cycle limits the chip applies (Table 2), in percent |
| CFaultMask | The fault masks, STATUS[23:17]: a masked fault does not pull FAULT low (its flag is still set). FaultMask{} is the reset value: only COMER masked |
| CFaults | The FAULT register: one byte per fault type, bit n for channel n (Table 12). Also used to say which flags ClearFaults() clears |
| CLatchedFaults | The flags the driver has seen since the last ClearLatchedFaults() (handbook KB-CPP-119): OVT and UVM from every 32-bit STATUS read ("Read Clears All", Register Details), the FAULT flags every FAULT read clears ("Clearing the FAULT Register"), and the summary flags of every fault byte (STATUS[7:0]) any access clocks out, at no extra I/O: the chip clears OLF when a channel switches on (p21) and HHF when it starts a new cycle (p23), so a flag can come and go between two FAULT reads. GetLatchedFaults() returns it with no I/O |
| CMAX22200 | Driver for one MAX22200 or MAX22200A on a platform port |
| CResult | The value of a call, or why there is none |
| CResult< void > | The result of a call that returns no value |
| CSpiInterface | CRTP base of the platform SPI port |
| CStatus | STATUS as read (ReadStatus()): the channels that are on and the seven flags |
| RSpiPort | Satisfied by a class that derives from SpiInterface<Port> and implements the required hooks with exactly the types above, noexcept and returning bool: EnsureInitialized(), Transfer() and GpioSet() (CMD and ENABLE) |