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.
Dependencies: BNO055_fusion PowerControl mbed BMP280
Fork of DEMO3 by
Diff: LOCOMOTION.cpp
- Revision:
- 30:116cd143fdf7
- Parent:
- 29:e8ef4a2e628d
--- a/LOCOMOTION.cpp Wed Apr 13 07:48:49 2016 +0000
+++ b/LOCOMOTION.cpp Tue Apr 19 02:04:10 2016 +0000
@@ -130,10 +130,12 @@
_m1dir=0;
_m2dir=1;
setMotors12(compG(s,_m1dir,current),compG(s,_m2dir,current));
+ //_m2dir=0;
} else if(wrap(current+diff)<180-error) {
_m1dir=1;
_m2dir=0;
setMotors12(compG(s,_m1dir,current),compG(s,_m2dir,current));
+ //_m2dir=1;
} else {
setMotors(0);
return true;
@@ -243,7 +245,7 @@
{
_m1dir=1;
_m2dir=1;
- setMotors12(compG(0.5,_m1dir,angle),compG(0.5,_m2dir,angle));
+ setMotors12(compG(0.2,_m1dir,angle),compG(0.2,_m2dir,angle));
}
void LOCOMOTION::moveB(void)
