|
MAX22200 Driver 0.1.0
API reference
|
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.
More...
#include <max22200_types.hpp>
Public Attributes | |
| Variant | variant {Variant::Max22200} |
| uint32_t | rref_ohm {kNoRref} |
| uint32_t | wake_timeout_us {kDefaultWakeTimeoutUs} |
| uint8_t | loaded_channels {0} |
| MasterClock | clock {MasterClock::Khz100} |
| FREQM. | |
| FaultMask | fault_mask {} |
| M_OVT to M_UVM. | |
| std::array< PairMode, kPairs > | pairs {} |
| CM10, CM32, CM54, CM76; index = pair. | |
| std::array< ChannelConfig, kChannels > | channels {} |
| CFG_CH0 to CFG_CH7; index = channel. | |
| DpmConfig | dpm {} |
| CFG_DPM. | |
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.
EnsureInitialized() writes all of it, in the order of Figure 6; ApplyConfig() writes what changes. Verification is not configured here: each call that can read back takes a Verify.
| uint8_t max22200::Config::loaded_channels {0} |
The channels with a load fitted, bit n for channel n, a board fact; never sent. Only these may enable a load-dependent diagnostic (open load, plunger movement, HIT current check): on an unloaded channel it would report a fault that is only the missing load, and pull the shared FAULT pin (handbook KB-CPP-131). 0 (the default): no channel declared, every diagnostic off.
| uint32_t max22200::Config::rref_ohm {kNoRref} |
The resistor from IREF to ground, in ohms, a board fact: kMinRrefOhm to kMaxRrefOhm, or kNoRref (the default: not given). Sets IFS for the current conversions (CurrentCode()); never sent. Codes work without it; the conversions refuse kNoRref (InvalidArgument).
| Variant max22200::Config::variant {Variant::Max22200} |
The fitted part; never sent. Check the BOM first.
| uint32_t max22200::Config::wake_timeout_us {kDefaultWakeTimeoutUs} |
How long EnsureInitialized() waits for ACTIVE to read 1 with UVM clear, in microseconds: kMinWakeTimeoutUs to kMaxWakeTimeoutUs. Long or soft supply rails need more.