Class OpenSkyhawk::NeedleGauge
ClassList > OpenSkyhawk > NeedleGauge
DCS-driven pointer gauge over any MotorDriver backend.
#include <NeedleGauge.h>
Inherits the following classes: OpenSkyhawk::OutputBase
Public Functions
| Type | Name |
|---|---|
| NeedleGauge (uint16_t controlId, uint16_t mask, MotorDriver & motor, const GaugeCal & cal) Construct and register a pointer gauge. |
|
| virtual void | configure () override Configure and home the motor ( PanelGroup::setup() ). |
| virtual void | onControlPacket (uint16_t controlId, uint16_t value) override Retarget the motor from a CTRL_BCAST packet. Stores only — never steps here. |
| virtual void | update () override Advance the motor toward its target (non-blocking). |
Public Functions inherited from OpenSkyhawk::OutputBase
| Type | Name |
|---|---|
| virtual void | configure () Configure hardware pins for this output. |
| OutputBase * | next () const Next output in the list; nullptr at end. |
| virtual void | onControlPacket (uint16_t controlId, uint16_t value) = 0 Called for every non-null ControlPacket in a CTRL_BCAST frame. |
| virtual void | update () Called every PanelGroup::loop() iteration. |
Public Static Functions inherited from OpenSkyhawk::OutputBase
| Type | Name |
|---|---|
| OutputBase * | head () Head of the self-registered linked list. |
Protected Functions inherited from OpenSkyhawk::OutputBase
| Type | Name |
|---|---|
| OutputBase () Registers this instance into the linked list. |
Public Functions Documentation
function NeedleGauge
Construct and register a pointer gauge.
OpenSkyhawk::NeedleGauge::NeedleGauge (
uint16_t controlId,
uint16_t mask,
MotorDriver & motor,
const GaugeCal & cal
)
Parameters:
controlIdDCS-BIOS output address (A_4E_C_* from A4EC_OutputIds.h).maskField mask (A_4E_C_*_AM, or 0xFFFF for a whole-word gauge).motorCaller-owned MotorDriver (e.g. a StepperMotor). Must outlive this.calValue→position calibration. Must outlive this.
function configure
Configure and home the motor ( PanelGroup::setup() ).
virtual void OpenSkyhawk::NeedleGauge::configure () override
Implements OpenSkyhawk::OutputBase::configure
function onControlPacket
Retarget the motor from a CTRL_BCAST packet. Stores only — never steps here.
virtual void OpenSkyhawk::NeedleGauge::onControlPacket (
uint16_t controlId,
uint16_t value
) override
Parameters:
controlIdIncoming packet controlId. Ignored if != _controlId.valueRaw 16-bit DCS-BIOS value.
Implements OpenSkyhawk::OutputBase::onControlPacket
function update
Advance the motor toward its target (non-blocking).
virtual void OpenSkyhawk::NeedleGauge::update () override
Implements OpenSkyhawk::OutputBase::update
The documentation for this class was generated from the following file Firmware/Libraries/PanelGroup/Outputs/NeedleGauge/NeedleGauge.h