Functions to Operate with Reserved Channels

<< Click to Display Table of Contents >>

Navigation:  Modbus Universal MasterOPC Server > Lua 5.1 Reference Manual > Function library > The SERVER Library >

Functions to Operate with Reserved Channels

Functions to Operate with Reserved Channels

mbul_mail server.GetReservedChannel

mbul_mail server.SetReservedChannel

server.GetReservedChannel

Returns number of a current interrogation channel: 0 – main channel, 1..3 – reserved channel 1..3 (see The 'Reserved Channels' Section ).

Example

local NumChannel=server.GetReservedChannel( );

-- NumChannel will contain number of a current interrogation channel

server.SetReservedChannel

Sets an interrogation channel: 0 – main channel, 1..3 – reserved channel 1..3 (see The 'Reserved Channels' Section ).

If an unused channel is specified, the function is ignored (that is, the same interrogation channel is used).

Example

local SetChannel=1;

server.SetReservedChannel(SetChannel);

--interrogation will be peformed via the reserved channel number 1