most functionality to splashdwon, find neutral and start mission. short timeouts still in code for testing, will adjust to go directly to sit_idle after splashdown

Dependencies:   mbed MODSERIAL FATFileSystem

Committer:
tnhnrl
Date:
Mon Jun 25 15:44:00 2018 +0000
Revision:
67:c86a4b464682
Parent:
54:d4990fb68404
Child:
73:f6f378311c8d
fix timing

Who changed what in which revision?

UserRevisionLine numberNew contents of line
tnhnrl 45:16b8162188ca 1 #ifndef AUTOPILOTSTATICDEFS_H_
tnhnrl 45:16b8162188ca 2 #define AUTOPILOTSTATICDEFS_H_
tnhnrl 45:16b8162188ca 3
tnhnrl 45:16b8162188ca 4 #include "mbed.h"
tnhnrl 45:16b8162188ca 5 #include "MODSERIAL.h"
tnhnrl 45:16b8162188ca 6 #include "ltc1298.hpp"
tnhnrl 45:16b8162188ca 7 #include "LinearActuator.hpp"
tnhnrl 45:16b8162188ca 8 #include "IMU.h"
tnhnrl 45:16b8162188ca 9 #include "omegaPX209.hpp"
tnhnrl 45:16b8162188ca 10 #include "PosVelFilter.hpp"
tnhnrl 45:16b8162188ca 11 #include "OuterLoop.hpp"
tnhnrl 45:16b8162188ca 12 #include "StateMachine.hpp"
tnhnrl 45:16b8162188ca 13
tnhnrl 45:16b8162188ca 14 #include "ConfigFileIO.hpp"
tnhnrl 45:16b8162188ca 15 #include "SequenceController.hpp"
tnhnrl 45:16b8162188ca 16 #include "MbedLogger.hpp"
mkelly10 51:c5c40272ecc3 17 // #include "SDFileSystem.h"
tnhnrl 45:16b8162188ca 18 #include "ServoDriver.hpp"
tnhnrl 45:16b8162188ca 19
tnhnrl 45:16b8162188ca 20 //Declare static global variables using 'construct on use' idiom to ensure they are always constructed correctly
tnhnrl 45:16b8162188ca 21 // and avoid "static initialization order fiasco".
tnhnrl 45:16b8162188ca 22
tnhnrl 45:16b8162188ca 23 Timer & systemTime();
tnhnrl 45:16b8162188ca 24 Ticker & pulse();
tnhnrl 45:16b8162188ca 25
tnhnrl 45:16b8162188ca 26 MODSERIAL & pc();
tnhnrl 45:16b8162188ca 27 //MODSERIAL & xb();
tnhnrl 45:16b8162188ca 28
tnhnrl 45:16b8162188ca 29 LocalFileSystem & local();
tnhnrl 45:16b8162188ca 30
tnhnrl 45:16b8162188ca 31 SpiADC & adc();
tnhnrl 45:16b8162188ca 32 LinearActuator & bce();
tnhnrl 45:16b8162188ca 33 LinearActuator & batt();
tnhnrl 45:16b8162188ca 34
tnhnrl 45:16b8162188ca 35 omegaPX209 & depth();
tnhnrl 45:16b8162188ca 36 OuterLoop & depthLoop();
tnhnrl 45:16b8162188ca 37
tnhnrl 45:16b8162188ca 38 IMU & imu();
tnhnrl 45:16b8162188ca 39 OuterLoop & pitchLoop();
tnhnrl 45:16b8162188ca 40
tnhnrl 45:16b8162188ca 41 StateMachine & stateMachine();
tnhnrl 45:16b8162188ca 42
tnhnrl 45:16b8162188ca 43 MbedLogger & mbedLogger(); //internal memory log files
tnhnrl 45:16b8162188ca 44
mkelly10 51:c5c40272ecc3 45 // SDFileSystem & sd_card(); //SD card file system
tnhnrl 45:16b8162188ca 46 MbedLogger & sdLogger(); //sd log files
tnhnrl 45:16b8162188ca 47
tnhnrl 45:16b8162188ca 48 ConfigFileIO & configFileIO();
tnhnrl 45:16b8162188ca 49
tnhnrl 45:16b8162188ca 50 SequenceController & sequenceController();
tnhnrl 45:16b8162188ca 51
tnhnrl 45:16b8162188ca 52 //servo driver
tnhnrl 52:f207567d3ea4 53 ServoDriver & rudder(); //new 06/06/2018
tnhnrl 54:d4990fb68404 54 OuterLoop & headingLoop(); //change 06/08/2018
tnhnrl 45:16b8162188ca 55
tnhnrl 45:16b8162188ca 56 // leds for debugging, global for use in any function
tnhnrl 45:16b8162188ca 57 DigitalOut & led1();
tnhnrl 45:16b8162188ca 58 DigitalOut & led2();
tnhnrl 45:16b8162188ca 59 DigitalOut & led3();
tnhnrl 45:16b8162188ca 60 DigitalOut & led4();
tnhnrl 45:16b8162188ca 61
tnhnrl 45:16b8162188ca 62 #endif