ClearCore Status Register Manager class.
This class manages access to ClearCore status information.
ClearCore Status Register Manager class.
More...
#include <StatusManager.h>
bool ClearCore::StatusManager::AdcIsInTimeout |
( |
| ) |
|
Read accessor for whether the ADC has timed out while attempting a conversion.
- Returns
- True if the ADC is currently timed out, false otherwise.
void ClearCore::StatusManager::BlinkCodeClear |
( |
uint8_t |
group, |
|
|
uint8_t |
code |
|
) |
| |
|
inline |
Deactivate a blink code.
Clear out a currently active blink code. This is useful for when an error can be fixed on the fly, while the board is still operating, to avoid being continually alerted to the error even after it was resolved.
- Parameters
-
[in] | group | The group number the blink code belongs to. |
[in] | code | The blink code number to clear. |
See ClearCore Status Blink Codes for group and code numbers.
void ClearCore::StatusManager::HBridgeReset |
( |
| ) |
|
Clear on read accessor for connector overload status since the last invocation of this function.
- Parameters
-
[in] | mask | (optional) A SysConnectorState whose asserted bits indicate which of the ClearCore connector overload status bits to check for an asserted state. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for connector overloads. If no mask is provided, it's equivalent to passing a SysConnectorState with all bits asserted, in which case this function would report any connectors in an overload state since the last invocation of this function. |
- Returns
- SysConnectorState register whose asserted bits indicate which connectors have been overloaded since the last poll.
Accessor for the real time overload status of the I/O connectors.
- Parameters
-
[in] | mask | (optional) A SysConnectorState whose asserted bits indicate which of the ClearCore connector overload status bits to check for an asserted state. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for connector overloads. If no mask is provided, it's equivalent to passing a SysConnectorState with all bits asserted, in which case this function would report any connectors currently in an overloaded state. |
- Returns
- SysConnectorState register whose asserted bits indicate which connectors are currently overloaded.
Accessor for connector overload status since startup (or board reset).
- Parameters
-
[in] | mask | (optional) A SysConnectorState whose asserted bits indicate which of the ClearCore connector overload status bits to check for an asserted state. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for connector overloads. If no mask is provided, it's equivalent to passing a SysConnectorState with all bits asserted, in which case this function would report any connectors that have been in an overload state since board startup. |
- Returns
- SysConnectorState register whose asserted bits indicate which connectors have been overloaded since startup.
Access to all accumulated status bits that have asserted since board startup (or since the last board reset).
- Note
- This is not a clear on read operation, so reading this register does not automatically clear out the bits that have been raised, unlike StatusRisen() and StatusFallen().
bool ccioConnectionProb =
if (ccioConnectionProb) {
}
- Parameters
-
[in] | mask | (optional) A StatusRegister whose asserted bits indicate which of the ClearCore status bits to check for an asserted state. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for asserted status bits. If no mask is provided, it's equivalent to passing a StatusRegister with all bits asserted, in which case this function would report any accumulated asserted status bits. |
- Returns
- StatusRegister whose asserted bits indicate which ClearCore status bits have risen since startup.
Accumulating Clear on read accessor for any status bits that were asserted sometime since the previous invocation of this function.
- Note
- This is similar to StatusRisen() except that it tracks asserted status bits rather than status bits that have transitioned from deasserted to asserted. Therefore in the case that the supply voltage has been low since startup, i.e. its status bit has been set since startup, calling this function repeatedly will show that bit asserted each time, while calling StatusRisen() repeatedly will only show the bit asserted on the first call, since it transitioned from deasserted to asserted only once at startup.
if (ccioConnectionProb) {
}
- Parameters
-
[in] | mask | (optional) A StatusRegister whose asserted bits indicate which of the ClearCore status bits to check for an asserted state. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for asserted status bits. If no mask is provided, it's equivalent to passing a StatusRegister with all bits asserted, in which case this function would report any accumulated asserted status bits. |
- Returns
- StatusRegister whose asserted bits indicate which ClearCore status bits have been asserted since the last poll.
Clear on read accessor for status bits that have fallen (transitioned from asserted to deasserted) sometime since the previous invocation of this function.
StatusManager::StatusRegister mask;
mask.bit.VSupplyOverVoltage = 1;
mask.bit.VSupplyUnderVoltage = 1;
if (fallen.reg) {
}
- Parameters
-
[in] | mask | (optional) A StatusRegister whose asserted bits indicate which of the ClearCore status bits to check for falling edges. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for falling edges. If no mask is provided, it's equivalent to passing a StatusRegister with all bits asserted, in which case this function would report falling edges on any of the status bits. |
- Returns
- StatusRegister whose asserted bits indicate which ClearCore status bits have fallen since the last poll.
Clear on read accessor for status bits that have risen (transitioned from deasserted to asserted) sometime since the previous invocation of this function.
StatusManager::StatusRegister mask;
mask.bit.VSupplyOverVoltage = 1;
mask.bit.VSupplyUnderVoltage = 1;
if (risen.reg) {
}
- Parameters
-
[in] | mask | (optional) A StatusRegister whose asserted bits indicate which of the ClearCore status bits to check for rising edges. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for rising edges. If no mask is provided, it's equivalent to passing a StatusRegister with all bits asserted, in which case this function would report rising edges on any of the status bits. |
- Returns
- StatusRegister whose asserted bits indicate which ClearCore status bits have risen since the last poll.
The real time status register.
The bits that are asserted in the status register that's returned indicate events that are occurring now.
- Note
- This register shows a real-time view of the ClearCore's status. Some of the status bits contained within are of a transient nature and will not persist for multiple samples. This means that your polling of this register may miss certain status events. To catch these events poll the StatusRisen and StatusFallen registers.
- Parameters
-
[in] | mask | (optional) A StatusRegister whose asserted bits indicate which of the ClearCore status bits to check for an asserted state. If one of the bit members of this mask are deasserted, that bit will be ignored when checking for asserted status bits. If no mask is provided, it's equivalent to passing a StatusRegister with all bits asserted, in which case this function would report any status bits that are currently asserted. |
- Returns
- StatusRegister whose asserted bits indicate currently active ClearCore status events.
- Examples:
- ClearCoreBoardStatus/ClearCoreStatusRegister/ClearCoreStatusRegister.cpp, and DigitalIOExamples/WriteHBridgeOutput/WriteHBridgeOutput.cpp.
void ClearCore::StatusManager::UserBlinkCode |
( |
uint8_t |
mask | ) |
|
|
inline |
Activate an application driven blink code.
This function allows the application code to display a blink code in the #BLINK_GROUP_APPLICATION code group.
uint8_t errorCode = 3;
if (errorCode) {
}
- Parameters
-
[in] | mask | A mask representing an aggregate of blink codes to display. |
The documentation for this class was generated from the following file: