Bmag incl gps rettelse
Dependencies: mbed WDT MODSERIAL BME280
ErrorHandler/ErrorHandler.h
- Committer:
- MAA
- Date:
- 2017-03-31
- Revision:
- 11:d3d26d0e71ea
- Child:
- 12:2b46960a5d41
File content as of revision 11:d3d26d0e71ea:
#pragma once #include <string> #include "mbed.h" #include "BMAG/BMAG.h" using std::string; enum ErrorState{NONE, NO_GPS, NO_FIX, NO_MAG_DATA,DISPLAY_VBAT_FIX, DISPLAY_MAG_MEASUREMENT}; class ErrorHandler{ public: //constructor ErrorHandler(); //constructor with display ptr ErrorHandler(string * batteryvoltage, bool * fix, BMAG * bmag); //get display lines string getLine1(void); string getLine2(void); //sets errorstate and assigns the correct line values for display void setErrorState(ErrorState es); private: string errorStr1; string errorStr2; char tmparr[10]; bool * fixptr; string * batteryvoltageptr; BMAG * bmagptr; ErrorState currentState; };