EasyManua.ls Logo

Alpha 6000S series - Page 204

Alpha 6000S series
221 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Appendix 4 Use of MODBUS Communication
203
}
else
{
crc=crc>>1 ;
crc^=0xa001 ;
}
}
ulenth-=1 ;
uptr++;
}
return(((crc&0x00FF)<<8)|((crc&0xFF00)>>8));
}
Example of Command Application
[03H]
Reading of Single-character Command: read the single-character record content from the specified code. The record
content is divided into high 8 bits and low 8 bits and becomes part of the response content in order.
Example: read the state of frequency inverter 1
Command Content
Frequency Inverter
Address
01
Command Code 03
Start
Address
High Bit 00
Low Bit 20
Number of
Addresses
High Bit 00
Low Bit 01
CRC
High Bit 85
Low Bit C0
Normal Response Content
Frequency Inverter
Address
01
Command Code 03
Number of Data 02
Content
of Data
High Bit 00
Low Bit C1
CRC
High Bit 79
Low Bit D4
Abnormal Response Content
Frequency Inverter
Address
01
Command Code 83
Abnormality Code 03
CRC
High Bit 01
Low Bit 31
Notes: The number of data doubles that of address.
[06H]
Single-character Writing Command: write a single character into the specified register, and save the specified data in
the specified register. The data saved should be among the order of record codes. The command content should be
arrayed in the sequence of high 8 bits and low 8 bits.
Example: start the operation of frequency inverter 1
Command Content
Frequency Inverter
Address
01
Command Code 06
Start
Address
High Bit 00
Low Bit 01
Content of
Data
High Bit 00
Low Bit 01
CRC
High Bit 19
Low Bit CA
Normal Response Content
Frequency Inverter
Address
01
Command Code 06
Start
Address
High Bit 00
Low Bit 01
Content
of Data
High Bit 00
Low Bit 01
CRC
High Bit 19
Low Bit CA
Abnormal Response Content
Frequency Inverter
Address
01
Command Code 86
Abnormality Code 00
CRC
High Bit 42
Low Bit 60

Table of Contents