Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This function allows you to change the Modbus mode of a channel. You would typically not need to use this function because the channel’s mode would have been set in MB_CfgCh().

Prototype

void  MB_ModeSet (MODBUS_CH  *pch, 
                   CPU_INT08U  mode)

Arguments

pch

is a pointer to the channel (returned by MB_CfgCh()). This pointer specifies onto which channel the Modbus master will be communicating on.

mode

specifies whether you want the channel to support ASII or RTU mode and thus, you must pass either MODBUS_MODE_ASCII or MODBUS_MODE_RTU, respectively.

Returned Value

None

Notes / Warnings

None

Called By

Your Modbus master or slave application.