MAX22200 Driver 0.1.0
API reference
Loading...
Searching...
No Matches
Public Attributes | List of all members
max22200::Config Struct 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.
 

Detailed Description

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.

Member Data Documentation

◆ loaded_channels

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.

◆ rref_ohm

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

Variant max22200::Config::variant {Variant::Max22200}

The fitted part; never sent. Check the BOM first.

◆ wake_timeout_us

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.


The documentation for this struct was generated from the following file: