Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Global.h
- Revision:
- 1:3f857674a290
- Parent:
- 0:2a15bd367891
- Child:
- 4:650af94bf062
--- a/Global.h Mon Sep 07 01:19:55 2015 +0000 +++ b/Global.h Mon Sep 07 21:56:25 2015 +0000 @@ -25,19 +25,25 @@ static double trimyaw; static double inttrimpitch; static double inttrimyaw; - static std::vector<double> _pitch; - static std::vector<double> _yaw; -// static double _pitch; -// static double _yaw; - static std::vector<double> _airspeed; - static std::vector<double> _cadence; - static std::vector<double> _altitude; + static double pitch; + static double yaw; + static double airspeed; + static double cadence; + static double altitude; + public : static const int rotateperrevolutions=12; static const int rotateperrevolutions_onepulse=1; - static void initialize(); - static void update(); + + static class Ticker ticker; + static class Timer timer; + static class DigitalIn initializeswitch; + static class DigitalOut led1; + static class DigitalOut led2; + static class DigitalOut led3; + static class DigitalOut led4; + static int getmaxpitch(); static int getminpitch(); static int getmaxyaw(); @@ -46,6 +52,7 @@ static float getminrudderangle(); static float getmaxelevatorangle(); static float getminelevatorangle(); + static void setmaxpitchdegree(double maxpitchdegree); static void setneutralpitchdegree(double neutralpitchdegree); static void setminpitchdegree(double minpitchdegree); @@ -54,36 +61,27 @@ static void setminyawdegree(double minyawdegree); static void setneutralrudderangle(double neutralrudderangle); static void setneutralelevatorangle(double neutralelevatorangle); - static void setpitch(double pitch); - static void setyaw(double yaw); + + static double getpitch(); static double getyaw(); - static void settrimpitch(double _trimpitch); - static void settrimyaw(double _trimyaw); static double gettrimpitch(); static double gettrimyaw(); - static void setinttrimpitch(double _inttrimpitch); - static void setinttrimyaw(double _inttrimyaw); static double getinttrimpitch(); static double getinttrimyaw(); - - static void setairspeed(double airspeed); - static void setcadence(double cadence); - static void setaltitude(double altitude); static double getairspeed(); static double getcadence(); static double getaltitude(); - static void store(std::vector<double> &pitch, std::vector<double> &yaw, - std::vector<double> &airspeed, std::vector<double> &cadence, std::vector<double> &altitude); - - static class Ticker ticker; - static class Timer timer; - static class DigitalIn initializeswitch; - static class DigitalOut led1; - static class DigitalOut led2; - static class DigitalOut led3; - static class DigitalOut led4; - + + static void setpitch(double _pitch); + static void settrimpitch(double _trimpitch); + static void setinttrimpitch(double _inttrimpitch); + static void setyaw(double _yaw); + static void settrimyaw(double _trimyaw); + static void setinttrimyaw(double _inttrimyaw); + static void setairspeed(double _airspeed); + static void setcadence(double _cadence); + static void setaltitude(double _altitude); }; #endif \ No newline at end of file