Regenerating PPM signal based on distances from ultrasonic sensors, ESP8266 for connectin via wifi. Autonomous quadcopter behaviour, autonomou height holding. Flying direction based on front and back ultrasonic sensors.

Dependencies:   ConfigFile HCSR04 PID PPM2 mbed-rtos mbed

Revision:
2:d172c9963f87
Child:
8:b5128641d4cf
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/hardware.h	Thu Oct 26 15:54:47 2017 +0000
@@ -0,0 +1,28 @@
+#ifndef HARDWARE
+#define HARDWARE
+
+#include "mbed.h"
+#include "PpmRegen.h"
+#include "PID.h"
+#include "hcsr04.h"
+
+Serial pc(USBTX, USBRX); // tx, rx
+
+Thread serverThread;
+Thread distanceThread;
+
+InterruptIn*    _interruptPort =    new InterruptIn(p28);
+PwmOut*         _roll =             new PwmOut(p21);
+PwmOut*         _pitch =            new PwmOut(p22);
+PwmOut*         _throttle =         new PwmOut(p23);
+PwmOut*         _yaw =              new PwmOut(p24);
+PwmOut*         _aux1 =             new PwmOut(p25);
+PwmOut*         _aux2 =             new PwmOut(p26);
+PpmRegen* _ppmRegen;
+
+PID* _groundDistance;
+
+HCSR04* _sonic;
+
+
+#endif
\ No newline at end of file