User guide

EĆ2
16 Bit Register Reference
Use the following method to reference a 16 bit register. 16 bit register reference is
commonly used to reference message number and status. The symbolic name of
each register should be as meaningful as possible.
nnnnnăIODEFăSYMBOLIC_NAME%[ SLOT=s, REGISTER=r]
Bit Reference
Use the following method to reference individual inputs on the module. Single bit
reference is used to reference link status. The symbolic name of each bit should
be as meaningful as possible.
nnnnnăIODEFăSYMBOLIC_NAME@[ SLOT=s, REGISTER=r, ăBIT=b]
where:
nnnnn - BASIC statement number. This number may range from 1-32767.
SYMBOLIC_NAME! - A symbolic name chosen by the user and ending with (!).
This indicates a long integer data type and all references will access registers r
and r+1.
SYMBOLIC_NAME% - A symbolic name chosen by the user and ending with
(%). This indicates an integer data type and all references will access register r".
SYMBOLIC_NAME@ - A symbolic name chosen by the user and ending with
(@). This indicates a boolean data type and all references will access bit number
b" in the register r".
SLOT - Slot number that the module is plugged into. This number may range
from 0-15.
REGISTER - Specifies the register that is being referenced. This number may
range from 0-72.
BIT - Used with boolean data types only. Specifies the bit in the register that is
being referenced. This number may range from 0-15.
Examples of I/O Definitions
The following statement assigns the symbolic name TARE_WEIGHT! to register
71 on the module located in slot 4:
1020ăăIODEFăTARE_WEIGHT![ SLOT=4, REGISTER=71]
The following statement assigns the symbolic name LINK_STATUS@ to register
4, bit 0, on the module located in slot 7:
2050ăăIODEFăLINK_STATUS@[ SLOT=7, REGISTER=4, BIT=0]
Sample Configuration Task
The following is an example of a configuration task for the interface module:
1000 IODEF LINK_STATUS@[ SLOT = 5, REGISTER = 4, BIT=0 ]
1010 IODEF LINK_CONF%[ SLOT = 5, REGISTER = 20 ]
1020 IODEF BAUD_RATE%[ SLOT = 5, REGISTER = 21 ]
1030 IODEF RQST_STATUS%[ SLOT = 5, REGISTER = 64 ]
1040 IODEF MSG_NO%[ SLOT = 5, REGISTER = 65 ]
1050 IODEF STATUS_A%[ SLOT = 5, REGISTER = 66 ]
1060 IODEF STATUS_B%[ SLOT = 5, REGISTER = 67 ]
1070 IODEF STATUS_C%[ SLOT = 5, REGISTER = 68 ]
1080 IODEF INDICATED_WT![ SLOT = 5, REGISTER = 69 ]
1090 IODEF TARE_WEIGHT![ SLOT = 5, REGISTER = 71 ]
Each application task that references the symbolic names assigned to the
interface module must declare those names COMMON.