Zephyr API Documentation  3.6.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
modbus_user_callbacks Struct Reference

Modbus Server User Callback structure. More...

#include <modbus.h>

Data Fields

int(* coil_rd )(uint16_t addr, bool *state)
 Coil read callback.
 
int(* coil_wr )(uint16_t addr, bool state)
 Coil write callback.
 
int(* discrete_input_rd )(uint16_t addr, bool *state)
 Discrete Input read callback.
 
int(* input_reg_rd )(uint16_t addr, uint16_t *reg)
 Input Register read callback.
 
int(* input_reg_rd_fp )(uint16_t addr, float *reg)
 Floating Point Input Register read callback.
 
int(* holding_reg_rd )(uint16_t addr, uint16_t *reg)
 Holding Register read callback.
 
int(* holding_reg_wr )(uint16_t addr, uint16_t reg)
 Holding Register write callback.
 
int(* holding_reg_rd_fp )(uint16_t addr, float *reg)
 Floating Point Holding Register read callback.
 
int(* holding_reg_wr_fp )(uint16_t addr, float reg)
 Floating Point Holding Register write callback.
 

Detailed Description

Modbus Server User Callback structure.

Field Documentation

◆ coil_rd

int(* modbus_user_callbacks::coil_rd) (uint16_t addr, bool *state)

Coil read callback.

◆ coil_wr

int(* modbus_user_callbacks::coil_wr) (uint16_t addr, bool state)

Coil write callback.

◆ discrete_input_rd

int(* modbus_user_callbacks::discrete_input_rd) (uint16_t addr, bool *state)

Discrete Input read callback.

◆ holding_reg_rd

int(* modbus_user_callbacks::holding_reg_rd) (uint16_t addr, uint16_t *reg)

Holding Register read callback.

◆ holding_reg_rd_fp

int(* modbus_user_callbacks::holding_reg_rd_fp) (uint16_t addr, float *reg)

Floating Point Holding Register read callback.

◆ holding_reg_wr

int(* modbus_user_callbacks::holding_reg_wr) (uint16_t addr, uint16_t reg)

Holding Register write callback.

◆ holding_reg_wr_fp

int(* modbus_user_callbacks::holding_reg_wr_fp) (uint16_t addr, float reg)

Floating Point Holding Register write callback.

◆ input_reg_rd

int(* modbus_user_callbacks::input_reg_rd) (uint16_t addr, uint16_t *reg)

Input Register read callback.

◆ input_reg_rd_fp

int(* modbus_user_callbacks::input_reg_rd_fp) (uint16_t addr, float *reg)

Floating Point Input Register read callback.


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