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.cpp
- Revision:
- 19:c6ad6b453b39
- Parent:
- 17:887cfe1d309f
- Child:
- 25:589742cd3137
diff -r d8a9c25d6137 -r c6ad6b453b39 Global.cpp --- a/Global.cpp Tue May 10 07:50:40 2016 +0000 +++ b/Global.cpp Wed May 11 03:02:10 2016 +0000 @@ -40,6 +40,8 @@ double Global::ultsonic; double Global::atmpress; int Global::selector; +double Global::servovolt; +double Global::miconvolt; int Global::pitchtime; int Global::pitchdegreetime; @@ -52,6 +54,8 @@ int Global::ultsonictime; int Global::atmpresstime; int Global::selectortime; +int Global::servovolttime; +int Global::miconvolttime; //----------------どこからでも使えるled,スイッチ,タイマーの一括管理----------------------------- Timer Global::timer; @@ -185,6 +189,8 @@ double Global::getultsonic(){return ultsonic;} double Global::getatmpress(){return atmpress;} int Global::getselector(){return selector;} +double Global::getservovolt(){return servovolt;} +double Global::getmiconvolt(){return miconvolt;} int Global::getpitchtime(){return pitchtime;} int Global::getpitchdegreetime(){return pitchdegreetime;} @@ -197,6 +203,8 @@ int Global::getultsonictime(){return ultsonictime;} int Global::getatmpresstime(){return atmpresstime;} int Global::getselectortime(){return selectortime;} +int Global::getservovolttime(){return servovolttime;} +int Global::getmiconvolttime(){return miconvolttime;} @@ -244,3 +252,11 @@ selector = _selector; selectortime = timer.read_ms(); } +void Global::setservovolt(double _servovolt){ + servovolt = _servovolt; + servovolttime = timer.read_ms(); +} +void Global::setmiconvolt(double _miconvolt){ + miconvolt = _miconvolt; + miconvolttime = timer.read_ms(); +}