
25
interface specification
AI series instruments adopt Asynchronous Serial Port, interface level is in accordance with RS232C
and standard RS485. Data format is 1 start bit, 8 bit data, no check-bit, 1-2 stop-bit. Wave
frequency rangs from 4800~19200 bit/S, usually 9600 bit/S. 19200 bit/S is suggested when over 40
pc instruments or require higher refresh rate. 4800 bit/S is suggested when with longer
communication length and interruption. AI controllers adopt RS 485 and can connect 1~80 pc to
one communication interface.
2.It only needs 2 wires to communicate AI controllers and PC when the length is over 1 KM( some
are 3-4KM), which is advantageous compared with RS 232. To make sure PC can be connected,
RS232/RS485 or USB/RS485 converters can be used, changing RS232 or USB interfaces into RS
484 interface. Yudian has developed new RS232/RS485 and USB/RS485 converters with litter
volume and certain thunder-proof ability. No initialization is needed nor outer power supply. All
software can be adjusted to use.
As RS485 interface required, it can connect up to 32 controllers and computers with one
communication line. Repeaters is needed when over 32 pc. Or use 1/2 and 1/4 off-chip interface. At
present, AI interface can connect 60 pc without repeater and is thunder-proof and
electrostatic-proof to some degree.
AI's RS 232 and RS485 interfaces adopt advanced optical isolated technology, when there is
damage or fault in one pc, operation of others is not influenced. When parts of communication
interface or model is failed, controllers keep working with high reliability. 16 bit correct code has a
high accuracy as high as 30000 times than parity check, can promise the reliable data. Under most
conditions AI controllers are not influenced by other brand's product communication. No disordered
data collecting. But AI controller protocol doesn't promise other brand's product can work normally
so Rievtech doesn't suggest to use Rievtech's controllers with other brand's controllers on one
RS485 communication line. Separated connection is better.
3.Communication Instruction
AI controllers adopt 16 bit data format to symbol all instruction codes and datas. After optimization
of software communication instruction, there are only two: reading instruction and writing
instruction.
These two instructions make it easier to compile software with 100 % fulless. The standard reading
and writing instructions formation are as follows:
Reading: address code+52H(82)+ parameter code+0+0+check code
Writing: address code+43H(67)+ parameter code+low byte+high byte+check code
Address code: in order to connect more AI controllers to one communication interface, each
controller has its own communication address. Some valid addresses are 0~80 (some are 0~100),
so up to 80 pc are connectable. Address code depends on Addr Parameter. Two repeated 128~208
( 80H~D0H)
is used to symbol address code. Since code over 128 is seldom used, thus it can reduce the data
and address clashes. AI protocol requires, address code is formed by two same bytes, value is :
80H as follows:
E.g.: If the parameter Addr=10( 16 bit is 0AH,0A=80H= 8AH), then its address code is 8AH 8AH.
Parameter code: controllers' parameter is formed by 1 8-bit binary number (1 byte, write as 16
number). It indicates the reading and writing parameter.
Check code: it is formed by 16bit SUM correct coding. Its computational method is: