Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: main_ps3.cpp
- Revision:
- 43:a7423cfee3c8
- Parent:
- 42:c420857a3a6f
diff -r c420857a3a6f -r a7423cfee3c8 main_ps3.cpp --- a/main_ps3.cpp Wed Nov 18 04:24:35 2015 +0000 +++ b/main_ps3.cpp Thu Nov 19 07:25:27 2015 +0000 @@ -64,7 +64,7 @@ // targ_sita=0.0; targ_sita=-0.03; } - if((step==3)&&(x<1700.0)) { + if((step==3)&&(x<1800.0)) { targ_sita=PI/4; step=4; } @@ -105,15 +105,15 @@ CStep=7; }*/ ///////////////////////////////////////// - if((x<7800.0)&&(CStep==5)) { + if((x<7830.0)&&(CStep==5)) { if(!skip) sendData(1,6); //front CStep=6; } - if((x<6670.0)&&(CStep==6)) { + if((x<6710.0)&&(CStep==6)) { if(!skip) sendData(1,5); //middle CStep=7; } - if((x<5470.0)&&(CStep==7)) { + if((x<5500.0)&&(CStep==7)) { if(!skip) sendData(1,4); //over CStep=8; } @@ -143,7 +143,7 @@ // targ_sita=0.0; targ_sita=-0.03; } - if((step==13)&&(x<1450.0)) { + if((step==13)&&(x<1400.0)) { targ_sita=PI/4; step=14; } @@ -153,15 +153,15 @@ } //Cylinderd - if((x>3200.0)&&(CStep==10)) { + if((x>3230.0)&&(CStep==10)) { if(!skip) sendData(1,1); CStep=11; } - if((x>6050.0)&&(CStep==11)) { + if((x>6100.0)&&(CStep==11)) { if(!skip) sendData(1,2); CStep=12; } - if((x>7700.0)&&(CStep==12)) { + if((x>7750.0)&&(CStep==12)) { if(!skip) sendData(1,3); CStep=13; } @@ -170,16 +170,16 @@ CStep=14; } if((x>9900.0)&&(CStep==14)) CStep=15; - if((x<9500.0)&&(CStep==15)) { //7.8 +// if((x<9500.0)&&(CStep==15)) { //7.8 + if((x<9600.0)&&(CStep==15)) { //7.8 if(!skip) sendData(1,4); CStep=16; } - if((x<7800.0)&&(CStep==16)) { //7.8 -// if((x<7950.0)&&(CStep==16)) { //7.8 + if((x<7750.0)&&(CStep==16)) { //7.8 if(!skip) sendData(1,5); CStep=17; } - if((x<5400.0)&&(CStep==17)) { //7.8 + if((x<5500.0)&&(CStep==17)) { //7.8 // if((x<5750.0)&&(CStep==17)) { //7.8 if(!skip) sendData(1,6); CStep=18; @@ -256,7 +256,7 @@ if(!skip) sendData(1,4); //front CStep=6; } - if((x<6830.0)&&(CStep==6)) { + if((x<6800.0)&&(CStep==6)) { if(!skip) sendData(1,5); //middle CStep=7; } @@ -342,12 +342,12 @@ manualIM920(); /*IM920 button*/ #ifdef BLUE /********************************Swing Mode(middle)*********************************/ - if((mstep==0)&&((10000.0>x)&&(x>1350.0))) { + if((mstep==0)&&((10000.0>x)&&(x>1400.0))) { dpcount=speed; mstep=1; } if((mstep==1)&&((velocity<5.0)&&(velocity>-5.0))){ - targ_sita=PI/4.0+PI/30.0; + targ_sita=PI/4.0+PI/30.0+PI/180.0; swingmoved=2; mstep=251; } @@ -488,7 +488,7 @@ mstep=11; } if((mstep==11)&&((velocity<5.0)&&(velocity>-5.0))){ - targ_sita=-PI/3.0-PI/10.0+PI/4.0-PI/50.0; + targ_sita=-PI/3.0-PI/10.0+PI/4.0-PI/38.0; swingmoved=2; mstep=252; }