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
main.cpp
- Committer:
- sandwich
- Date:
- 2014-07-11
- Revision:
- 25:4f2f441eceec
- Parent:
- 24:9d75ed1462d6
File content as of revision 25:4f2f441eceec:
#include "mbed.h" //#include "rtos.h" #include "Servo.h" //#include "rtos.h" //#include "PwmReader.h" //#include "PwmIn.h" #include "MainController.h" Serial pc(USBTX, USBRX); //Serial syren(p9,p10); //syren replaced the pololu controller Timer t; int main() { //syren.baud(38400); t.start(); MainController mainCtrl; mainCtrl.start(); printf("started\n"); while(true) { //pc.printf("control: %d, frq: %.3f, vol: %.2f, amp: %.3f, yaw: %.2f, dut: %.2f, pit: %.2f, adj: %.2f, t: %.2f\n", // mainCtrl.getOpMode(), mainCtrl.getFrequency(), mainCtrl.getVolume(), mainCtrl.getAmplitude(), mainCtrl.getYaw(), mainCtrl.getDutyCycle(), mainCtrl.getPitch(), mainCtrl.getAdj(), t.read()); //syren.putc(int(mainCtrl.getDutyCycle())); //wait_ms(100); } //t.stop(); //mainCtrl.stop(); }