Nix (Dev) 3.5.10
dev - 3.5.10 - 1af9301
Loading...
Searching...
No Matches
iv::comms::can::LomCommunicationController Class Referencefinal

#include <LomCommunicationController.hpp>

Inheritance diagram for iv::comms::can::LomCommunicationController:
[legend]
Collaboration diagram for iv::comms::can::LomCommunicationController:
[legend]

Public Member Functions

 LomCommunicationController ()=delete
 
 LomCommunicationController (const std::shared_ptr< ICommunicationDriver > &driver, const std::shared_ptr< iv::model::comms::NetworkData > &networkData)
 
 LomCommunicationController (const LomCommunicationController &other)=delete
 
 LomCommunicationController (const LomCommunicationController &&other)=delete
 
 ~LomCommunicationController () override
 
LomCommunicationControlleroperator= (const LomCommunicationController &other)=delete
 
LomCommunicationControlleroperator= (LomCommunicationController &&other)=delete
 
void initialize () override
 
void addChannel (const std::shared_ptr< iv::channels::AbstractChannel > &channel) override
 
bool sendMessage (const std::shared_ptr< CMessageCan > &message) const
 
std::optional< std::shared_ptr< CMessageCan > > receiveMessage (iv::comms::can::eMessageType type, std::optional< uint32_t > msgId=std::nullopt)
 
void emptySdoQueue (iv::types::unitId unitId) const
 
void pause () const
 
void resume () const
 
iv::types::networkId getNetworkId () const
 
std::shared_ptr< iv::model::comms::NetworkDatagetCommConfig () const
 
std::shared_ptr< iv::comms::ICommunicationDrivergetDriver () const
 
bool hasChannel (const iv::types::channelId &channelId) const
 
bool isEnabled ()
 

Public Attributes

std::mutex m_sendMutex
 
std::mutex m_receiveMutex
 
std::mutex m_processMutex
 

Protected Attributes

iv::types::networkId m_networkId
 
std::shared_ptr< bool > m_isEnabled
 
std::shared_ptr< iv::model::comms::NetworkDatam_commConfig
 
std::shared_ptr< iv::comms::ICommunicationProtocolm_protocol
 
std::shared_ptr< iv::comms::ICommunicationDriverm_driver
 
std::map< iv::types::channelId, std::shared_ptr< iv::channels::AbstractChannel > > m_channels
 
std::weak_ptr< iv::channels::AbstractChannelm_errorChannel
 
std::weak_ptr< iv::channels::AbstractChannelm_heartbeatChannel
 
std::weak_ptr< iv::comms::ICommunicationControllerm_fallbackComm
 
std::weak_ptr< iv::diamar::AppFailuresLoggerManagerm_appFailuresLoggerManager
 

Private Member Functions

bool frame () override
 
bool sendFrame ()
 
bool receiveFrame ()
 

Private Attributes

std::shared_ptr< iv::comms::can::ICanCommunicationProtocolm_canProtocol
 
std::map< std::pair< iv::types::unitId, iv::types::indexChannel >, std::weak_ptr< iv::channels::AbstractChannel > > m_lomChannels
 
std::unique_ptr< containers::CircularQueue< std::shared_ptr< CMessageCan >, 100 > > m_sendQueue
 
std::map< iv::comms::can::eMessageType, std::unique_ptr< iv::containers::CircularQueue< std::shared_ptr< CMessageCan >, 500 > > > m_receiveQueues
 
std::map< uint16_t, std::unique_ptr< iv::containers::CircularQueue< std::shared_ptr< CMessageCan >, 500 > > > m_receivedSDOMessages
 
std::mutex m_receiveSdoMessagesMutex
 
std::shared_ptr< iv::comms::can::AbstractMessageProcessorm_processor
 
iv::types::timestamp lastTimestampSync
 
iv::types::timestamp lastTimestampReceived
 
iv::comms::eLomLine m_line
 

Friends

class LomCommunicationControllerFrame
 
class LomMessageProcessor
 

Constructor & Destructor Documentation

◆ LomCommunicationController() [1/4]

iv::comms::can::LomCommunicationController::LomCommunicationController ( )
delete

◆ LomCommunicationController() [2/4]

iv::comms::can::LomCommunicationController::LomCommunicationController ( const std::shared_ptr< ICommunicationDriver > & driver,
const std::shared_ptr< iv::model::comms::NetworkData > & networkData )

◆ LomCommunicationController() [3/4]

iv::comms::can::LomCommunicationController::LomCommunicationController ( const LomCommunicationController & other)
delete

◆ LomCommunicationController() [4/4]

iv::comms::can::LomCommunicationController::LomCommunicationController ( const LomCommunicationController && other)
delete

◆ ~LomCommunicationController()

iv::comms::can::LomCommunicationController::~LomCommunicationController ( )
overridedefault

Member Function Documentation

◆ addChannel()

void iv::comms::can::LomCommunicationController::addChannel ( const std::shared_ptr< iv::channels::AbstractChannel > & channel)
overridevirtual

◆ emptySdoQueue()

void iv::comms::can::LomCommunicationController::emptySdoQueue ( iv::types::unitId unitId) const

◆ frame()

bool iv::comms::can::LomCommunicationController::frame ( )
overrideprivatevirtual

◆ getCommConfig()

std::shared_ptr< iv::model::comms::NetworkData > iv::comms::ICommunicationController::getCommConfig ( ) const
inlinenodiscardinherited

◆ getDriver()

std::shared_ptr< iv::comms::ICommunicationDriver > iv::comms::ICommunicationController::getDriver ( ) const
inlinenodiscardinherited

◆ getNetworkId()

iv::types::networkId iv::comms::ICommunicationController::getNetworkId ( ) const
inlinenodiscardinherited

◆ hasChannel()

bool iv::comms::ICommunicationController::hasChannel ( const iv::types::channelId & channelId) const
inlinenodiscardinherited

◆ initialize()

void iv::comms::can::LomCommunicationController::initialize ( )
overridevirtual

◆ isEnabled()

bool iv::comms::ICommunicationController::isEnabled ( )
inlinenodiscardinherited

◆ operator=() [1/2]

LomCommunicationController & iv::comms::can::LomCommunicationController::operator= ( const LomCommunicationController & other)
delete

◆ operator=() [2/2]

LomCommunicationController & iv::comms::can::LomCommunicationController::operator= ( LomCommunicationController && other)
delete

◆ pause()

void iv::comms::ICommunicationController::pause ( ) const
inlineinherited

◆ receiveFrame()

bool iv::comms::can::LomCommunicationController::receiveFrame ( )
private

◆ receiveMessage()

std::optional< std::shared_ptr< CMessageCan > > iv::comms::can::LomCommunicationController::receiveMessage ( iv::comms::can::eMessageType type,
std::optional< uint32_t > msgId = std::nullopt )

◆ resume()

void iv::comms::ICommunicationController::resume ( ) const
inlineinherited

◆ sendFrame()

bool iv::comms::can::LomCommunicationController::sendFrame ( )
private

◆ sendMessage()

bool iv::comms::can::LomCommunicationController::sendMessage ( const std::shared_ptr< CMessageCan > & message) const

Friends And Related Symbol Documentation

◆ LomCommunicationControllerFrame

friend class LomCommunicationControllerFrame
friend

◆ LomMessageProcessor

friend class LomMessageProcessor
friend

Member Data Documentation

◆ lastTimestampReceived

iv::types::timestamp iv::comms::can::LomCommunicationController::lastTimestampReceived
private

◆ lastTimestampSync

iv::types::timestamp iv::comms::can::LomCommunicationController::lastTimestampSync
private

◆ m_appFailuresLoggerManager

std::weak_ptr<iv::diamar::AppFailuresLoggerManager> iv::comms::ICommunicationController::m_appFailuresLoggerManager
protectedinherited

◆ m_canProtocol

std::shared_ptr<iv::comms::can::ICanCommunicationProtocol> iv::comms::can::LomCommunicationController::m_canProtocol
private

◆ m_channels

std::map<iv::types::channelId, std::shared_ptr<iv::channels::AbstractChannel> > iv::comms::ICommunicationController::m_channels
protectedinherited

◆ m_commConfig

std::shared_ptr<iv::model::comms::NetworkData> iv::comms::ICommunicationController::m_commConfig
protectedinherited

◆ m_driver

std::shared_ptr<iv::comms::ICommunicationDriver> iv::comms::ICommunicationController::m_driver
protectedinherited

◆ m_errorChannel

std::weak_ptr<iv::channels::AbstractChannel> iv::comms::ICommunicationController::m_errorChannel
protectedinherited

◆ m_fallbackComm

std::weak_ptr<iv::comms::ICommunicationController> iv::comms::ICommunicationController::m_fallbackComm
protectedinherited

◆ m_heartbeatChannel

std::weak_ptr<iv::channels::AbstractChannel> iv::comms::ICommunicationController::m_heartbeatChannel
protectedinherited

◆ m_isEnabled

std::shared_ptr<bool> iv::comms::ICommunicationController::m_isEnabled
protectedinherited

◆ m_line

iv::comms::eLomLine iv::comms::can::LomCommunicationController::m_line
private

◆ m_lomChannels

std::map<std::pair<iv::types::unitId, iv::types::indexChannel>, std::weak_ptr<iv::channels::AbstractChannel> > iv::comms::can::LomCommunicationController::m_lomChannels
private

◆ m_networkId

iv::types::networkId iv::comms::ICommunicationController::m_networkId
protectedinherited

◆ m_processMutex

std::mutex iv::comms::can::LomCommunicationController::m_processMutex

◆ m_processor

std::shared_ptr<iv::comms::can::AbstractMessageProcessor> iv::comms::can::LomCommunicationController::m_processor
private

◆ m_protocol

std::shared_ptr<iv::comms::ICommunicationProtocol> iv::comms::ICommunicationController::m_protocol
protectedinherited

◆ m_receivedSDOMessages

std::map<uint16_t, std::unique_ptr<iv::containers::CircularQueue<std::shared_ptr<CMessageCan>, 500> > > iv::comms::can::LomCommunicationController::m_receivedSDOMessages
private

◆ m_receiveMutex

std::mutex iv::comms::can::LomCommunicationController::m_receiveMutex

◆ m_receiveQueues

std::map<iv::comms::can::eMessageType, std::unique_ptr<iv::containers::CircularQueue<std::shared_ptr<CMessageCan>, 500> > > iv::comms::can::LomCommunicationController::m_receiveQueues
private

◆ m_receiveSdoMessagesMutex

std::mutex iv::comms::can::LomCommunicationController::m_receiveSdoMessagesMutex
private

◆ m_sendMutex

std::mutex iv::comms::can::LomCommunicationController::m_sendMutex

◆ m_sendQueue

std::unique_ptr<containers::CircularQueue<std::shared_ptr<CMessageCan>, 100> > iv::comms::can::LomCommunicationController::m_sendQueue
private

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