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.
Revision 54:9dc1bfb53391, committed 2019-11-17
- Comitter:
- yabahiro
- Date:
- Sun Nov 17 02:51:05 2019 +0000
- Parent:
- 53:694dbd7dfa0e
- Commit message:
- aa;
Changed in this revision
System/Process/Process.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/System/Process/Process.cpp Fri Nov 15 11:49:03 2019 +0000 +++ b/System/Process/Process.cpp Sun Nov 17 02:51:05 2019 +0000 @@ -824,6 +824,7 @@ if(g[3]==98&&countss>=10000) { mode=22; countss=0; + cross=0; fast=60; normal=40; slow=20; @@ -839,9 +840,10 @@ motor[TIRE_BL].dir = BRAKE; if(g[0]==0) { mode=22; - fast=60; - normal=40; - slow=25; + cross=0; + fast=80; + normal=60; + slow=40; } } break; @@ -959,23 +961,20 @@ countss=0; } } else { - if(g[0]==98) { + if(cross==2) { slow=25; normal=30; fast=30; - } - if(g[3]==0) { - slow=25; - normal=40; - fast=60; - mode=23; + if(g[3]==0) { + solenoid.solenoid2 = SOLENOID_OFF; + slow=40; + normal=60; + fast=80; + mode=23; + } } switch(g[0]) { case 98: - solenoid.solenoid2 = SOLENOID_OFF; - fast=40; - normal=30; - slow=25; motor[TIRE_FR].pwm = normal; motor[TIRE_FR].dir = BACK; motor[TIRE_FL].pwm = normal+5; @@ -984,6 +983,10 @@ motor[TIRE_BR].dir = BACK; motor[TIRE_BL].pwm = normal; motor[TIRE_BL].dir = FOR; + if(countss>30000) { + cross++; + countss=0; + } break; case 0: motor[TIRE_FR].pwm = fast; @@ -1756,11 +1759,9 @@ } break; case 41: - /* - if(LIF||LIB) { - mode=42; - } - */ + if(LIF||LIB) { + mode=42; + } motor[TIRE_FR].pwm = 30; motor[TIRE_FR].dir = BACK; motor[TIRE_FL].pwm = 0;