![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Still Test
Dependencies: DXL_SDK_For_F446RE RobotControl_7Axis Matrix mbed
Diff: main.cpp
- Revision:
- 7:15f0494813f7
- Parent:
- 4:53ef39fbf9d9
- Child:
- 8:37f5a7219fe6
--- a/main.cpp Wed Feb 08 11:21:26 2017 +0800 +++ b/main.cpp Wed Feb 08 12:27:32 2017 +0800 @@ -54,10 +54,9 @@ //dxl_write_byte(3,ADDRESS_LED,0); //dxl_ping(3); - short int pos=0; //16bit + short int pos=0; //16bit while(1) { - //pc.printf("before=%d\n",rt); @@ -89,6 +88,38 @@ pc.printf("X%d=%d,",i,pos); } pc.printf("\n"); - wait_ms(500); - } + + + + //====Test syncWrite_u16base=== + static short int pos3=-100; + pos3=(pos3==-100)? 100 :-100; + + short int SyncPage1[21]= + { + ID_AXIS1,100,5, + ID_AXIS2,100,5, + ID_AXIS3,100,5, + ID_AXIS4,100,5, + ID_AXIS5,100,5, + ID_AXIS6,100,5, + ID_AXIS7,100,5, + }; + + wait(2); + //short int SyncPage1[21]=//Test use + //{ + // 0x00,0x010,0x150, // 3 Dynamixels are move to position 512 + // 0x01,0x020,0x360, + // 0x02,0x030,0x170, + // 0x03,0x220,0x380, + // 0x05,0x123,0x121, + // 0x06,0x234,0x143, + // 0x07,0x145,0x167 + //}; + + + syncWrite_u16base(GOAL_POSITION, 2,SyncPage1,21);//start_addr, data_length, *param, param_length; + + } }