cyg_modbus_response_nocopy — Provide MODBUS response (no copy)


#include <cyg/modbus.h>

cyg_bool cyg_modbus_response_nocopy(cyg_handle_t ctx, cyg_uint8 len);


Like the cyg_modbus_response() call this function is used to provide the MODBUS server with a valid response to a request handed to the backend for processing. This call assumes that the original PDU buffer (as referenced through the opaque ctx handle) contains the response data.

This “PDU buffer” re-use can simplify the backend processing, since it no longer needs to dynamically manage buffers that are handed-off to the main MODBUS server control.

Return value

Currently only ENOERR is returned.