Public Member Functions | Private Attributes | List of all members
prbt_hardware_support::ModbusAdapterRunPermitted Class Reference

Listens to the modbus_read topic and reacts to updated RUN_PERMITTED states. More...

#include <modbus_adapter_run_permitted.h>

Public Member Functions

 ModbusAdapterRunPermitted (UpdateRunPermittedFunc &&update_run_permitted_func, const ModbusApiSpec &api_spec)
 
void modbusMsgCallback (const ModbusMsgInStampedConstPtr &msg_raw)
 Called whenever a new modbus messages arrives. More...
 

Private Attributes

const ModbusApiSpec api_spec_
 
UpdateRunPermittedFunc update_run_permitted_
 

Detailed Description

Listens to the modbus_read topic and reacts to updated RUN_PERMITTED states.

Definition at line 36 of file modbus_adapter_run_permitted.h.

Constructor & Destructor Documentation

◆ ModbusAdapterRunPermitted()

prbt_hardware_support::ModbusAdapterRunPermitted::ModbusAdapterRunPermitted ( UpdateRunPermittedFunc &&  update_run_permitted_func,
const ModbusApiSpec api_spec 
)

Definition at line 28 of file modbus_adapter_run_permitted.cpp.

Member Function Documentation

◆ modbusMsgCallback()

void prbt_hardware_support::ModbusAdapterRunPermitted::modbusMsgCallback ( const ModbusMsgInStampedConstPtr &  msg_raw)

Called whenever a new modbus messages arrives.

Note
Filters like for example the UpdateFilter can restrict the number of incoming messages.
A STOP1 is triggered in case:
  • of a disconnect from the modbus server,
  • the modbus message does not contain the expected registers,
  • the modbus API version is incorrect,
  • the RUN_PERMITTED state changes to false.

Definition at line 34 of file modbus_adapter_run_permitted.cpp.

Member Data Documentation

◆ api_spec_

const ModbusApiSpec prbt_hardware_support::ModbusAdapterRunPermitted::api_spec_
private

Definition at line 57 of file modbus_adapter_run_permitted.h.

◆ update_run_permitted_

UpdateRunPermittedFunc prbt_hardware_support::ModbusAdapterRunPermitted::update_run_permitted_
private

Definition at line 58 of file modbus_adapter_run_permitted.h.


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


prbt_hardware_support
Author(s):
autogenerated on Sun Oct 25 2020 03:13:00