29#ifndef __DIGITALINOUT_H__
30#define __DIGITALINOUT_H__
64#ifndef HIDE_FROM_DOXYGEN
182 bool State(int16_t newState)
override;
188 return (
volatile bool &)m_isInFault;
216 uint16_t pulseCount = 0,
217 bool blockUntilDone =
false);
251 return m_pulseActive;
276 uint32_t m_outputPort;
277 uint32_t m_outputDataBit;
278 uint32_t m_outputDataMask;
279 bool m_logicInversion;
286#ifndef HIDE_FROM_DOXYGEN
291 const PeripheralRoute *inputInfo,
292 const PeripheralRoute *outputInfo,
293 bool logicInversion);
303 void Refresh()
override;
313 uint32_t m_pulseOnTicks;
314 uint32_t m_pulseOffTicks;
315 uint32_t m_pulseStart;
316 uint16_t m_pulseStopCount;
317 uint16_t m_pulseCounter;
318 uint8_t m_overloadTripCnt;
321 bool m_pulseStopPending;
322 uint16_t m_overloadFoldbackCnt;
324 void OutputPin(
bool val) {
326 val != m_logicInversion);
Base class for all connector classes.
ClearCore Digital Input Connector class.
LED shift register access class.
ClearCorePins
ClearCore PIN definitions.
Definition SysConnectors.h:54
ClearCore common utility functions.
#define DATA_OUTPUT_STATE(GPIO_PORT, DATA_MASK, STATE)
Definition SysUtils.h:86
virtual ConnectorModes Mode()
Get the connector's operational mode.
Definition Connector.h:309
ConnectorModes
All possible operational modes for a connector.
Definition Connector.h:74
@ OUTPUT_PWM
Definition Connector.h:106
@ OUTPUT_DIGITAL
Definition Connector.h:98
ConnectorTypes
The different types of ClearCore connectors.
Definition Connector.h:172
@ DIGITAL_IN_OUT_TYPE
Definition Connector.h:199
ClearCore digital input connector class.
Definition DigitalIn.h:70
ClearCore digital output connector class.
Definition DigitalInOut.h:60
bool State(int16_t newState) override
Set the output state of the connector.
virtual ConnectorModes Mode() override
Get the connector's operational mode.
Definition DigitalInOut.h:85
void OutputPulsesStart(uint32_t onTime, uint32_t offTime, uint16_t pulseCount=0, bool blockUntilDone=false)
Start an output pulse.
bool IsInHwFault() override
Get whether the connector is in a hardware fault state.
Definition DigitalInOut.h:187
int16_t State() override
Get the connector's last majority-filtered sampled value.
Connector::ConnectorTypes Type() override
Get connector type.
Definition DigitalInOut.h:117
volatile const bool & OutputPulsesActive()
Check the output pulse state.
Definition DigitalInOut.h:250
virtual bool Mode(ConnectorModes newMode) override
Set the connector's operational mode.
bool IsWritable() override
Get R/W status of the connector.
Definition DigitalInOut.h:132
void OutputPulsesStop(bool stopImmediately=true)
Stop an output pulse.
bool PwmDuty(uint8_t newDuty)
Set the PWM duty on the I/O pin.
ClearCore Board Supervisory System Manager.
Definition SysManager.h:58
Namespace to encompass the ClearCore board API.
Definition AdcManager.h:36