|
My Project
|
Request message for register functions. More...
#include <uuid/modbus.h>


Public Member Functions | |
| RegisterRequest (uint16_t device, uint8_t function_code, uint16_t timeout_ms, uint16_t address, uint16_t data, const std::shared_ptr< Response > &response) | |
| Create a new register request message (not directly useful). More... | |
| uint16_t | encode (frame_buffer_t &frame) override |
| Encode this request and store it in a message frame buffer. More... | |
| uint16_t | address () const |
| Get the register address. More... | |
| uint16_t | data () const |
| Get the register size or value. More... | |
Public Member Functions inherited from uuid::modbus::Request | |
| Request (uint16_t device, uint8_t function_code, uint16_t timeout_ms, const std::shared_ptr< Response > &response) | |
| Create a new request message (not directly useful). More... | |
| uint16_t | device () const |
| Get the destination device address. More... | |
| uint8_t | function_code () const |
| Get the function code of the request. More... | |
| uint16_t | timeout_ms () const |
| Get the timeout to wait for a response in milliseconds. More... | |
| Response & | response () const |
| Get the response object. More... | |
Private Attributes | |
| const uint16_t | address_ |
| const uint16_t | data_ |
Request message for register functions.
This will be created when a request is submitted and then discarded when the response is updated with the outcome.
| uuid::modbus::RegisterRequest::RegisterRequest | ( | uint16_t | device, |
| uint8_t | function_code, | ||
| uint16_t | timeout_ms, | ||
| uint16_t | address, | ||
| uint16_t | data, | ||
| const std::shared_ptr< Response > & | response | ||
| ) |
Create a new register request message (not directly useful).
| [in] | device | Destination device address. |
| [in] | function_code | Function code of the request. |
| [in] | timeout_ms | Timeout to wait for a response in milliseconds. |
| [in] | address | Register address. |
| [in] | data | Number of registers to read or register value to write. |
| [in] | response | Response object. |
Definition at line 99 of file register_functions.cpp.
|
inline |
|
inline |
|
overridevirtual |
Encode this request and store it in a message frame buffer.
| [out] | frame | Message frame data. |
Reimplemented from uuid::modbus::Request.
Definition at line 106 of file register_functions.cpp.
|
private |
|
private |