|
|
@ -37,7 +37,6 @@ void motor_init(motor_t *motor) { |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
static double motor_drive_read_encoder(); |
|
|
|
static uint8_t motor_drive_set_packages_ctr(double position, int direction); |
|
|
|
|
|
|
@ -82,7 +81,7 @@ void motor_run_to_postion(int rotation_direction, double position, int speed_lev |
|
|
|
uint8_t checksum = 0; |
|
|
|
uint32_t limit_speed = 0; |
|
|
|
uint8_t buffer[14] = {0x3E, 0XA6, MOTOR_ID, 0X08, 0XED, 0X00, 0X00, 0X00, 0X00, 0X00, 0X00, 0X00, 0X00, 0X00}; |
|
|
|
// char *notify_err = "set size error"; |
|
|
|
// char *notify_err = "set size error"; |
|
|
|
|
|
|
|
// forward |
|
|
|
if ((rotation_direction == 1)) { |
|
|
@ -146,7 +145,7 @@ void motor_run_to_postion(int rotation_direction, double position, int speed_lev |
|
|
|
} |
|
|
|
|
|
|
|
// Parse receive |
|
|
|
// motor_drive_buffer_cmd_parse(buffer); |
|
|
|
// motor_drive_buffer_cmd_parse(buffer); |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|