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
Diff: main.cpp
- Branch:
- DistanceRegulation
- Revision:
- 25:69190c222dbf
- Parent:
- 11:002927b2675d
- Child:
- 26:11539036f0fb
--- a/main.cpp Sun Nov 05 09:41:25 2017 +0000 +++ b/main.cpp Sun Nov 26 17:27:39 2017 +0000 @@ -20,10 +20,12 @@ int main(){ + pc.baud(115200); + // INITIALIZE CLASSES _ppmRegen = new PpmRegen(_interruptPort); _sonic = new HCSR04(p29, p30); - _groundDistance = new PID(10, 0, 0, 2); + _groundDistance = new PID(0, 0, 0, 10); // STARTING THREADS serverThread.start(serverRun);