MAX22200 Driver 0.1.0
API reference
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Friends | List of all members
max22200::LatchedFaults Struct Reference

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. More...

#include <max22200_types.hpp>

Public Member Functions

constexpr bool Any () const noexcept
 

Public Attributes

bool overtemperature {false}
 OVT seen by a STATUS read or in a fault byte.
 
bool undervoltage {false}
 
bool overcurrent {false}
 OCP in a fault byte: some channel had an OCP flag.
 
bool open_load {false}
 OLF in a fault byte: some channel had an OLF flag.
 
bool hit_not_reached {false}
 HHF in a fault byte: some channel had an HHF flag.
 
bool plunger {false}
 DPM in a fault byte: some channel had a DPM flag.
 
bool lost {false}
 
Faults faults {}
 

Friends

constexpr bool operator== (const LatchedFaults &lhs, const LatchedFaults &rhs) noexcept=default
 

Detailed Description

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.

Member Function Documentation

◆ Any()

constexpr bool max22200::LatchedFaults::Any ( ) const
inlineconstexprnoexcept
Returns
true when any flag is latched.

Friends And Related Symbol Documentation

◆ operator==

constexpr bool operator== ( const LatchedFaults &  lhs,
const LatchedFaults &  rhs 
)
friend
Parameters
lhsThe first value.
rhsThe value to compare it with.
Returns
true when every field of lhs equals rhs's.

Member Data Documentation

◆ faults

Faults max22200::LatchedFaults::faults {}

FAULT flags a FAULT read cleared, per channel. A summary flag above without its channel here: the chip cleared it first.

◆ lost

bool max22200::LatchedFaults::lost {false}

A read of a running driver that clears flags (STATUS, or FAULT where the read clears) did not deliver them: the transfer failed or SDO floated. Flags may be gone unseen.

◆ undervoltage

bool max22200::LatchedFaults::undervoltage {false}

UVM seen by a STATUS read or in a fault byte (the start-up's own power-on UVM is not kept).


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