My modifications/additions to the code
Dependencies: ADXL345 ADXL345_I2C IMUfilter ITG3200 Servo fishgait mbed-rtos mbed pixy_cam
Fork of robotic_fish_ver_4_8 by
Revision 18:9ba4566f2361, committed 2014-05-22
- Comitter:
- rkk
- Date:
- Thu May 22 13:35:01 2014 +0000
- Parent:
- 17:6970aef8154b
- Child:
- 19:655db88b045c
- Commit message:
- bang bang yaw control
Changed in this revision
| MainController.cpp | Show annotated file Show diff for this revision Revisions of this file |
| MainController.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/MainController.cpp Thu May 22 04:32:19 2014 +0000
+++ b/MainController.cpp Thu May 22 13:35:01 2014 +0000
@@ -7,9 +7,9 @@
ch4(p17,0.055,0.092), //rudder
ch6(p15,0.055,0.092), //volume
mcon(p22, p6, p7), // change pin p5 to p7, because p5 is burned through
- ap(p25, p26),
- leftservo(p21),
- rightservo(p22)
+ ap(p25, p26)//,
+ //leftservo(p21),
+ //rightservo(p22)
{
wait_ms(50);
@@ -70,9 +70,9 @@
}
//Set Servo Values
- pitch = this->calculatePitch();
- leftservo = pitch;
- rightservo = 1.0 - pitch;
+ //pitch = this->calculatePitch();
+ //leftservo = pitch;
+ //rightservo = 1.0 - pitch;
// if (curTime > 1/(2*frq) && (switched == false))
// {
--- a/MainController.h Thu May 22 04:32:19 2014 +0000
+++ b/MainController.h Thu May 22 13:35:01 2014 +0000
@@ -61,8 +61,8 @@
PwmIn ch6;
PololuMController mcon;
Guardian ap;
- Servo leftservo;
- Servo rightservo;
+ //Servo leftservo;
+ //Servo rightservo;
Timer timer1;
Ticker ticker1;
