Open Model Railroad Network (OpenMRN)
Loading...
Searching...
No Matches
DccOutputHwDummy< N > Struct Template Reference

Interface that the actual outputs have to implement in their hardware-specific classes. More...

#include <DccOutput.hxx>

Inheritance diagram for DccOutputHwDummy< N >:
DccOutputHw< N >

Static Public Member Functions

static void hw_preinit (void)
 Called once during hw_preinit boot state.
 
static unsigned start_railcom_cutout_phase1 (void)
 Invoked at the beginning of a railcom cutout.
 
static unsigned start_railcom_cutout_phase2 (void)
 Invoked at the beginning of a railcom cutout after the delay.
 
static unsigned stop_railcom_cutout_phase1 (void)
 Invoked at the end of a railcom cutout.
 
static void stop_railcom_cutout_phase2 (void)
 Invoked at the end of a railcom cutout.
 
static void enable_output (void)
 Called once every packet by the driver, typically before the preamble, if the output is supposed to be on.
 
static bool need_railcom_cutout ()
 A dummy output never needs a railcom cutout.
 
static void set_disable_reason (DccOutput::DisableReason bit)
 
- Static Public Member Functions inherited from DccOutputHw< N >
static bool need_railcom_cutout ()
 Called by the driver to decide whether to make this channel participate in the railcom cutout.
 
static bool should_be_enabled ()
 Called once after the railcom cutout is done to decide whether this output should be reenabled.
 
static void clear_disable_reason (DccOutput::DisableReason bit)
 Clears a disable reason.
 

Additional Inherited Members

- Static Public Attributes inherited from DccOutputHw< N >
static std::atomic_uint_least8_t outputDisableReasons_
 Bitmask of why this output should be disabled.
 
static std::atomic_uint_least8_t isRailcomCutoutEnabled_
 0 if we should not produce a railcom cutout; 1 for short cutout; 2 for regular cutout.
 
static uint8_t isRailcomCutoutActive_
 1 if we are in a railcom cutout currently.
 
- Static Protected Member Functions inherited from DccOutputHw< N >
static void set_disable_reason_impl (DccOutput::DisableReason bit)
 Set one bit in the disable reasons bit field.
 

Detailed Description

template<int N>
struct DccOutputHwDummy< N >

Interface that the actual outputs have to implement in their hardware-specific classes.

Definition at line 252 of file DccOutput.hxx.

Member Function Documentation

◆ enable_output()

template<int N>
static void DccOutputHwDummy< N >::enable_output ( void  )
inlinestatic

Called once every packet by the driver, typically before the preamble, if the output is supposed to be on.

Definition at line 288 of file DccOutput.hxx.

◆ hw_preinit()

template<int N>
static void DccOutputHwDummy< N >::hw_preinit ( void  )
inlinestatic

Called once during hw_preinit boot state.

Definition at line 256 of file DccOutput.hxx.

◆ need_railcom_cutout()

template<int N>
static bool DccOutputHwDummy< N >::need_railcom_cutout ( )
inlinestatic

A dummy output never needs a railcom cutout.

Definition at line 293 of file DccOutput.hxx.

◆ set_disable_reason()

template<int N>
static void DccOutputHwDummy< N >::set_disable_reason ( DccOutput::DisableReason  bit)
inlinestatic

Definition at line 298 of file DccOutput.hxx.

◆ start_railcom_cutout_phase1()

template<int N>
static unsigned DccOutputHwDummy< N >::start_railcom_cutout_phase1 ( void  )
inlinestatic

Invoked at the beginning of a railcom cutout.

Returns
the number of usec to wait before invoking phase2.

Definition at line 262 of file DccOutput.hxx.

◆ start_railcom_cutout_phase2()

template<int N>
static unsigned DccOutputHwDummy< N >::start_railcom_cutout_phase2 ( void  )
inlinestatic

Invoked at the beginning of a railcom cutout after the delay.

Returns
number of usec to delay before enabling railcom UART receive.

Definition at line 269 of file DccOutput.hxx.

◆ stop_railcom_cutout_phase1()

template<int N>
static unsigned DccOutputHwDummy< N >::stop_railcom_cutout_phase1 ( void  )
inlinestatic

Invoked at the end of a railcom cutout.

Returns
the number of usec to wait before invoking phase2.

Definition at line 276 of file DccOutput.hxx.

◆ stop_railcom_cutout_phase2()

template<int N>
static void DccOutputHwDummy< N >::stop_railcom_cutout_phase2 ( void  )
inlinestatic

Invoked at the end of a railcom cutout.

Definition at line 282 of file DccOutput.hxx.


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