Quick Start for Dynamixel Pro v1.00b
Page
96
/
139
Result = dxl_write_byte(Port, ID, P_TORQUE_ENABLE, 1, &ErrorStatus);
if
( Result != COMM_RXSUCCESS )
{
printf(
"Failed to write!\n"
);
printf(
"Press any key to terminate...\n"
);
_getch();
return
0;
}
//Rotating Start
printf(
"Rotating Start\n"
);
Result = dxl_write_dword(Port, ID, 600, 5000, &ErrorStatus);
if
( Result != COMM_RXSUCCESS )
{
printf(
"Failed to write!\n"
);
printf(
"Press any key to terminate...\n"
);
_getch();
return
0;
}
printf(
"Press any key to terminate...\n"
);
printf(
"\n"
);
while
(
true
)
{
if
(_kbhit())
break
;
unsigned
char
data[5];
dxl_read(Port, ID, P_INDIRECT_DATA_0, 5, data, &ErrorStatus);
int
temp, present_position;
temp = data[0];
present_position = DXL_MAKEDWORD( DXL_MAKEWORD(data[1], data[2]),
DXL_MAKEWORD(data[3], data[4]) );
printf(
"\r"
);
printf(
"present temperature : %d, presen position : %d"
, temp, present_position);
}
printf(
"\n"
);
//Close the port of USB2DXL
dxl_terminate(Port);
return
0;
}
Summary of Contents for Dynamixel Pro
Page 1: ...Quick Start for Dynamixel Pro ...
Page 8: ...Quick Start for Dynamixel Pro v1 00b Page 8 139 ...
Page 33: ...Quick Start for Dynamixel Pro v1 00b Page 33 139 Check Dynamixel PRO firmware update results ...
Page 37: ...Quick Start for Dynamixel Pro v1 00b Page 37 139 Dynamixel PRO firmware recovery is complete ...
Page 66: ...Quick Start for Dynamixel Pro v1 00b Page 66 139 The present temperature is constantly read ...
Page 133: ...Quick Start for Dynamixel Pro v1 00b Page 133 139 2 3 2 42 series H42 L42 ...
Page 136: ...Quick Start for Dynamixel Pro v1 00b Page 136 139 ...
Page 138: ...Quick Start for Dynamixel Pro v1 00b Page 138 139 iii L42 10 S300 R ...
Page 139: ...Quick Start for Dynamixel Pro v1 00b Page 139 139 2 5 Model notation ...