![Savch S200 Series Скачать руководство пользователя страница 58](http://html.mh-extra.com/html/savch/s200-series/s200-series_user-manual_1203756058.webp)
54
Procedure 4:Check moves to the right value, if it is 0, the new value of the Procedure3 will be saved in the CRC ,
otherwise ,the XOR A001H(CRC) ,Its result will be saved in the CRC.
Procedure 5:Repeat the Procedure 3,4, fully finish 8-bit operation .
Procedure 6:Repeat the Procedure2,5, take the next command for 8-bit, until finished all the commands operation.
Finally, it get the value of CRC, which is the CRC checking code. It is worth noting that the CRC checking code
must be placed in the message command code.
The following examples are for CRC checking code computing , they are written in C language.
Unsigned char* data ← // Signal reference index
Unsigned char length ← // Length of reference index
Unsigned int crc_chk ( unsigned char* data, unsigned char length)
{
int j;
unsigned int reg_crc=0Xffff;
while ( length--){
reg_crc ^=*data++;
for(j=0; j<8; j++){
if (reg_crc & 0x01) {/*LSB(b0)=1*/
reg_crc=(reg_crc>>1) ^0Xa001;
} else {
Reg_crc=reg_crc>>1;
}
}
}
return reg_crc; //Final value fit with CRC Cache memory
}
4
、
Definition of address in communication agreement:
Definition
Address
Function
Parameters setting
of drive
GGnnH
GG:indicates parameter group, nn:indicates parameter.For example:0401H
indicates parameter (4-01).
Command
2000H
Bit0
~
3
0:No function 1:Stop 2:Start 3:JOG Start
Bit4
~
5
00B:No function 01B:Fwd reference
10B:REV reference 11B:Changing direction
Bit8
~
9
Reserved
Bit6
~
7
Reserved
Bit12
~
15
Reserved
2001 H
Frequency / torque command
Monitor status
2100H
Error code ( Error code):referenc 07-09~07-11
Parameters
Reading
2102H
Frequency / torque reference ( F)
2103H
Output frequency / torque ( H)
2104H
Output Current ( XX.XX)
2105H
DC-BUS Voltage ( XXX.X)
2106H
Output Voltage (XXX.XX)