F´ Flight Software - C/C++ Documentation  devel
A framework for building embedded system applications to NASA flight quality standards.
Drv::LinuxSpiDriverComponentBase Class Referenceabstract

Auto-generated base for LinuxSpiDriver component. More...

#include <Drv/LinuxSpiDriver/LinuxSpiDriverComponentAc.hpp>

Inheritance diagram for Drv::LinuxSpiDriverComponentBase:
Fw::PassiveComponentBase Fw::ObjBase Drv::LinuxSpiDriverComponentImpl

Public Member Functions

void init (FwEnumStoreType instance=0)
 Initialize LinuxSpiDriverComponentBase object. More...
 
Drv::InputSpiReadWritePortget_SpiReadWrite_InputPort (FwIndexType portNum)
 
void set_Log_OutputPort (FwIndexType portNum, Fw::InputLogPort *port)
 Connect port to Log[portNum]. More...
 
void set_Time_OutputPort (FwIndexType portNum, Fw::InputTimePort *port)
 Connect port to Time[portNum]. More...
 
void set_Tlm_OutputPort (FwIndexType portNum, Fw::InputTlmPort *port)
 Connect port to Tlm[portNum]. More...
 
- Public Member Functions inherited from Fw::PassiveComponentBase
void setIdBase (const U32)
 Set the ID base. More...
 
U32 getIdBase () const
 

Protected Types

enum  { NUM_SPIREADWRITE_INPUT_PORTS = 1 }
 Enumerations for numbers of typed input ports. More...
 
enum  { NUM_LOG_OUTPUT_PORTS = 1 , NUM_LOGTEXT_OUTPUT_PORTS = 1 , NUM_TIME_OUTPUT_PORTS = 1 , NUM_TLM_OUTPUT_PORTS = 1 }
 Enumerations for numbers of special output ports. More...
 
enum  { EVENTID_SPI_OPENERROR = 0x0 , EVENTID_SPI_CONFIGERROR = 0x1 , EVENTID_SPI_WRITEERROR = 0x2 , EVENTID_SPI_PORTOPENED = 0x4 }
 Event IDs. More...
 
enum  { EVENTID_SPI_WRITEERROR_THROTTLE = 5 }
 Event throttle values: sets initial value of countdown variables. More...
 
enum  { CHANNELID_SPI_BYTES = 0x0 }
 Channel IDs. More...
 

Protected Member Functions

 LinuxSpiDriverComponentBase (const char *compName="")
 Construct LinuxSpiDriverComponentBase object. More...
 
virtual ~LinuxSpiDriverComponentBase ()
 Destroy LinuxSpiDriverComponentBase object. More...
 
FwIndexType getNum_SpiReadWrite_InputPorts () const
 
FwIndexType getNum_Log_OutputPorts () const
 
FwIndexType getNum_Time_OutputPorts () const
 
FwIndexType getNum_Tlm_OutputPorts () const
 
bool isConnected_Log_OutputPort (FwIndexType portNum)
 
bool isConnected_Time_OutputPort (FwIndexType portNum)
 
bool isConnected_Tlm_OutputPort (FwIndexType portNum)
 
virtual void SpiReadWrite_handler (FwIndexType portNum, Fw::Buffer &writeBuffer, Fw::Buffer &readBuffer)=0
 Handler for input port SpiReadWrite. More...
 
void SpiReadWrite_handlerBase (FwIndexType portNum, Fw::Buffer &writeBuffer, Fw::Buffer &readBuffer)
 Handler base-class function for input port SpiReadWrite. More...
 
void log_WARNING_HI_SPI_OpenError (I32 device, I32 select, I32 error)
 
void log_WARNING_HI_SPI_ConfigError (I32 device, I32 select, I32 error)
 
void log_WARNING_HI_SPI_WriteError (I32 device, I32 select, I32 error)
 
void log_ACTIVITY_HI_SPI_PortOpened (I32 device, I32 select)
 
void log_WARNING_HI_SPI_WriteError_ThrottleClear ()
 Reset throttle value for SPI_WriteError. More...
 
void tlmWrite_SPI_Bytes (U32 arg, Fw::Time _tlmTime=Fw::Time())
 
Fw::Time getTime ()
 
- Protected Member Functions inherited from Fw::PassiveComponentBase
 PassiveComponentBase (const char *name)
 Named constructor. More...
 
virtual ~PassiveComponentBase ()
 Destructor. More...
 
void init (NATIVE_INT_TYPE instance)
 Initialization function. More...
 
NATIVE_INT_TYPE getInstance () const
 
- Protected Member Functions inherited from Fw::ObjBase
 ObjBase (const char *name)
 ObjBase constructor. More...
 
virtual ~ObjBase ()
 Destructor. More...
 
void init ()
 Object initializer. More...
 

Friends

class LinuxSpiDriverComponentBaseFriend
 Friend class for white-box testing. More...
 

Detailed Description

Auto-generated base for LinuxSpiDriver component.

Definition at line 28 of file LinuxSpiDriverComponentAc.hpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
protected

Enumerations for numbers of typed input ports.

Enumerator
NUM_SPIREADWRITE_INPUT_PORTS 

Definition at line 46 of file LinuxSpiDriverComponentAc.hpp.

◆ anonymous enum

anonymous enum
protected

Enumerations for numbers of special output ports.

Enumerator
NUM_LOG_OUTPUT_PORTS 
NUM_LOGTEXT_OUTPUT_PORTS 
NUM_TIME_OUTPUT_PORTS 
NUM_TLM_OUTPUT_PORTS 

Definition at line 51 of file LinuxSpiDriverComponentAc.hpp.

◆ anonymous enum

anonymous enum
protected

Event IDs.

Enumerator
EVENTID_SPI_OPENERROR 

SPI open error.

EVENTID_SPI_CONFIGERROR 

SPI config error.

EVENTID_SPI_WRITEERROR 

SPI write error.

EVENTID_SPI_PORTOPENED 

SPI open notification.

Definition at line 59 of file LinuxSpiDriverComponentAc.hpp.

◆ anonymous enum

anonymous enum
protected

Event throttle values: sets initial value of countdown variables.

Enumerator
EVENTID_SPI_WRITEERROR_THROTTLE 

Throttle reset count for SPI_WriteError.

Definition at line 67 of file LinuxSpiDriverComponentAc.hpp.

◆ anonymous enum

anonymous enum
protected

Channel IDs.

Enumerator
CHANNELID_SPI_BYTES 

Channel ID for SPI_Bytes.

Definition at line 72 of file LinuxSpiDriverComponentAc.hpp.

Constructor & Destructor Documentation

◆ LinuxSpiDriverComponentBase()

Drv::LinuxSpiDriverComponentBase::LinuxSpiDriverComponentBase ( const char *  compName = "")
protected

Construct LinuxSpiDriverComponentBase object.

Parameters
compNameThe component name

Definition at line 280 of file LinuxSpiDriverComponentAc.cpp.

◆ ~LinuxSpiDriverComponentBase()

Drv::LinuxSpiDriverComponentBase::~LinuxSpiDriverComponentBase ( )
protectedvirtual

Destroy LinuxSpiDriverComponentBase object.

Definition at line 287 of file LinuxSpiDriverComponentAc.cpp.

Member Function Documentation

◆ get_SpiReadWrite_InputPort()

Drv::InputSpiReadWritePort * Drv::LinuxSpiDriverComponentBase::get_SpiReadWrite_InputPort ( FwIndexType  portNum)

Get typed input port at index

Returns
SpiReadWrite[portNum]
Parameters
portNumThe port number

Definition at line 133 of file LinuxSpiDriverComponentAc.cpp.

◆ getNum_Log_OutputPorts()

FwIndexType Drv::LinuxSpiDriverComponentBase::getNum_Log_OutputPorts ( ) const
protected

Get the number of Log output ports

Returns
The number of Log output ports

Definition at line 307 of file LinuxSpiDriverComponentAc.cpp.

◆ getNum_SpiReadWrite_InputPorts()

FwIndexType Drv::LinuxSpiDriverComponentBase::getNum_SpiReadWrite_InputPorts ( ) const
protected

Get the number of SpiReadWrite input ports

Returns
The number of SpiReadWrite input ports

Definition at line 297 of file LinuxSpiDriverComponentAc.cpp.

◆ getNum_Time_OutputPorts()

FwIndexType Drv::LinuxSpiDriverComponentBase::getNum_Time_OutputPorts ( ) const
protected

Get the number of Time output ports

Returns
The number of Time output ports

Definition at line 323 of file LinuxSpiDriverComponentAc.cpp.

◆ getNum_Tlm_OutputPorts()

FwIndexType Drv::LinuxSpiDriverComponentBase::getNum_Tlm_OutputPorts ( ) const
protected

Get the number of Tlm output ports

Returns
The number of Tlm output ports

Definition at line 329 of file LinuxSpiDriverComponentAc.cpp.

◆ getTime()

Fw::Time Drv::LinuxSpiDriverComponentBase::getTime ( )
protected

Get the time

\return The current time

Definition at line 940 of file LinuxSpiDriverComponentAc.cpp.

◆ init()

void Drv::LinuxSpiDriverComponentBase::init ( FwEnumStoreType  instance = 0)

Initialize LinuxSpiDriverComponentBase object.

Parameters
instanceThe instance number

Definition at line 20 of file LinuxSpiDriverComponentAc.cpp.

◆ isConnected_Log_OutputPort()

bool Drv::LinuxSpiDriverComponentBase::isConnected_Log_OutputPort ( FwIndexType  portNum)
protected

Check whether port Log is connected

Returns
Whether port Log is connected
Parameters
portNumThe port number

Definition at line 339 of file LinuxSpiDriverComponentAc.cpp.

◆ isConnected_Time_OutputPort()

bool Drv::LinuxSpiDriverComponentBase::isConnected_Time_OutputPort ( FwIndexType  portNum)
protected

Check whether port Time is connected

Returns
Whether port Time is connected
Parameters
portNumThe port number

Definition at line 365 of file LinuxSpiDriverComponentAc.cpp.

◆ isConnected_Tlm_OutputPort()

bool Drv::LinuxSpiDriverComponentBase::isConnected_Tlm_OutputPort ( FwIndexType  portNum)
protected

Check whether port Tlm is connected

Returns
Whether port Tlm is connected
Parameters
portNumThe port number

Definition at line 376 of file LinuxSpiDriverComponentAc.cpp.

◆ log_ACTIVITY_HI_SPI_PortOpened()

void Drv::LinuxSpiDriverComponentBase::log_ACTIVITY_HI_SPI_PortOpened ( I32  device,
I32  select 
)
protected

Log event SPI_PortOpened

SPI open notification

Parameters
deviceThe device
selectThe chip select

Definition at line 786 of file LinuxSpiDriverComponentAc.cpp.

◆ log_WARNING_HI_SPI_ConfigError()

void Drv::LinuxSpiDriverComponentBase::log_WARNING_HI_SPI_ConfigError ( I32  device,
I32  select,
I32  error 
)
protected

Log event SPI_ConfigError

SPI config error

Parameters
deviceThe device
selectThe chip select
errorThe error code

Definition at line 538 of file LinuxSpiDriverComponentAc.cpp.

◆ log_WARNING_HI_SPI_OpenError()

void Drv::LinuxSpiDriverComponentBase::log_WARNING_HI_SPI_OpenError ( I32  device,
I32  select,
I32  error 
)
protected

Log event SPI_OpenError

SPI open error

Parameters
deviceThe device
selectThe chip select
errorThe error code

Definition at line 418 of file LinuxSpiDriverComponentAc.cpp.

◆ log_WARNING_HI_SPI_WriteError()

void Drv::LinuxSpiDriverComponentBase::log_WARNING_HI_SPI_WriteError ( I32  device,
I32  select,
I32  error 
)
protected

Log event SPI_WriteError

SPI write error

Parameters
deviceThe device
selectThe chip select
errorThe error code

Definition at line 658 of file LinuxSpiDriverComponentAc.cpp.

◆ log_WARNING_HI_SPI_WriteError_ThrottleClear()

void Drv::LinuxSpiDriverComponentBase::log_WARNING_HI_SPI_WriteError_ThrottleClear ( )
protected

Reset throttle value for SPI_WriteError.

Definition at line 892 of file LinuxSpiDriverComponentAc.cpp.

◆ set_Log_OutputPort()

void Drv::LinuxSpiDriverComponentBase::set_Log_OutputPort ( FwIndexType  portNum,
Fw::InputLogPort port 
)

Connect port to Log[portNum].

Parameters
portNumThe port number
portThe input port

Definition at line 148 of file LinuxSpiDriverComponentAc.cpp.

◆ set_Time_OutputPort()

void Drv::LinuxSpiDriverComponentBase::set_Time_OutputPort ( FwIndexType  portNum,
Fw::InputTimePort port 
)

Connect port to Time[portNum].

Parameters
portNumThe port number
portThe input port

Definition at line 180 of file LinuxSpiDriverComponentAc.cpp.

◆ set_Tlm_OutputPort()

void Drv::LinuxSpiDriverComponentBase::set_Tlm_OutputPort ( FwIndexType  portNum,
Fw::InputTlmPort port 
)

Connect port to Tlm[portNum].

Parameters
portNumThe port number
portThe input port

Definition at line 194 of file LinuxSpiDriverComponentAc.cpp.

◆ SpiReadWrite_handler()

virtual void Drv::LinuxSpiDriverComponentBase::SpiReadWrite_handler ( FwIndexType  portNum,
Fw::Buffer writeBuffer,
Fw::Buffer readBuffer 
)
protectedpure virtual

Handler for input port SpiReadWrite.

Parameters
portNumThe port number

◆ SpiReadWrite_handlerBase()

void Drv::LinuxSpiDriverComponentBase::SpiReadWrite_handlerBase ( FwIndexType  portNum,
Fw::Buffer writeBuffer,
Fw::Buffer readBuffer 
)
protected

Handler base-class function for input port SpiReadWrite.

Parameters
portNumThe port number

Definition at line 393 of file LinuxSpiDriverComponentAc.cpp.

◆ tlmWrite_SPI_Bytes()

void Drv::LinuxSpiDriverComponentBase::tlmWrite_SPI_Bytes ( U32  arg,
Fw::Time  _tlmTime = Fw::Time() 
)
protected

Write telemetry channel SPI_Bytes

Bytes Sent/Received

Parameters
argThe telemetry value
_tlmTimeTimestamp. Default: unspecified, request from getTime port

Definition at line 903 of file LinuxSpiDriverComponentAc.cpp.

Friends And Related Function Documentation

◆ LinuxSpiDriverComponentBaseFriend

friend class LinuxSpiDriverComponentBaseFriend
friend

Friend class for white-box testing.

Definition at line 37 of file LinuxSpiDriverComponentAc.hpp.


The documentation for this class was generated from the following files: