AK80-64 AK Series Actuator Driver Manual V1.0.8
Table Of Contents
- Notice
- 1.Ensure that the circuit is normal and the interfac
- 2. The driver board will be hot when output, pleas
- 3. Please Check whether the parts are in good cond
- 4. Several optional control modes can’t be switche
- 5. Please use it strictly in accordance with the w
- Feature
- Disclaimer
- Version Change Record
- 1.Drive Product Information
- ①Three-phase wires connection port
- 2.R-link produce information
- 2.1 Introduction of R-link' appearance&Specificat
- 3. Actuator and R-link Connection and Notices
- Connection instructions: Connect the USB cable to
- 4. Instructions for use of the upper computer
- 1.Click Open File and select the firmware. The firmw
- 2.Click Bootloader.
- 3.Click download and wait for the progress bar to re
- 5. Driver board communication protocol and descrip
https://www.cubemars.com/
47 / 52
//int64 数据位整理
void buffer_append_int64(uint8_t* buffer, int64_t number, int32_t *index) {
buffer[(*index)++] = number >> 56;
buffer[(*index)++] = number >> 48;
buffer[(*index)++] = number >> 40;
buffer[(*index)++] = number >> 32;
buffer[(*index)++] = number >> 24;
buffer[(*index)++] = number >> 16;
buffer[(*index)++] = number >> 8;
buffer[(*index)++] = number;
}
//uint64 数据位整理
void buffer_append_uint64(uint8_t* buffer, uint64_t number, int32_t *index) {
buffer[(*index)++] = number >> 56;
buffer[(*index)++] = number >> 48;
buffer[(*index)++] = number >> 40;
buffer[(*index)++] = number >> 32;
buffer[(*index)++] = number >> 24;
buffer[(*index)++] = number >> 16;
buffer[(*index)++] = number >> 8;
buffer[(*index)++] = number;
}
//CRC 校验
unsigned short crc16(unsigned char *buf, unsigned int len) {
unsigned int i;
unsigned short cksum = 0;
for (i = 0; i < len; i++) {
cksum = crc16_tab[(((cksum >> 8) ^ *buf++) & 0xFF)] ^ (cksum << 8);
}
return cksum;
}
//数据包的整理发送
void packet_send_packet(unsigned char *data, unsigned int len, int handler_num) {
int b_ind = 0;
unsigned short crc;
if (len > PACKET_MAX_PL_LEN) {
return;
}
if (len <= 256) {