Neptune_170620

Dependencies:   mbed

Committer:
Picmon
Date:
Wed Jun 17 10:11:19 2020 +0000
Revision:
0:20b4b057fa7f
Neptune;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Picmon 0:20b4b057fa7f 1
Picmon 0:20b4b057fa7f 2 #ifndef FUNCTIONS_H
Picmon 0:20b4b057fa7f 3 #define FUNCTIONS_H
Picmon 0:20b4b057fa7f 4
Picmon 0:20b4b057fa7f 5 #include "mbed.h"
Picmon 0:20b4b057fa7f 6 #include "Definitions.h"
Picmon 0:20b4b057fa7f 7
Picmon 0:20b4b057fa7f 8 extern Thread thread;
Picmon 0:20b4b057fa7f 9 extern volatile uint16_t loopTime;
Picmon 0:20b4b057fa7f 10 extern volatile bool loopTimeFlag;
Picmon 0:20b4b057fa7f 11 extern volatile bool readFlag;
Picmon 0:20b4b057fa7f 12
Picmon 0:20b4b057fa7f 13 extern uint8_t pumpType;
Picmon 0:20b4b057fa7f 14 extern const uint8_t uOutPut1_ID[7];
Picmon 0:20b4b057fa7f 15 extern const uint8_t uOutPut2_ID[7];
Picmon 0:20b4b057fa7f 16 extern const uint8_t uFlowUnitID[10];
Picmon 0:20b4b057fa7f 17 extern const string sFlowUnits[];
Picmon 0:20b4b057fa7f 18 extern const float fMaxFlowUnits[][10];
Picmon 0:20b4b057fa7f 19 extern const float fMinFlowUnits[][10];
Picmon 0:20b4b057fa7f 20
Picmon 0:20b4b057fa7f 21 extern const string menuStringArray[][10];
Picmon 0:20b4b057fa7f 22
Picmon 0:20b4b057fa7f 23 extern bool incFlag;
Picmon 0:20b4b057fa7f 24 extern bool decFlag;
Picmon 0:20b4b057fa7f 25 extern bool okFlag;
Picmon 0:20b4b057fa7f 26 extern bool manFlag;
Picmon 0:20b4b057fa7f 27
Picmon 0:20b4b057fa7f 28 extern uint8_t calState;
Picmon 0:20b4b057fa7f 29
Picmon 0:20b4b057fa7f 30 uint8_t decodeByteNVM(uint8_t nvmByte, uint8_t *prec);
Picmon 0:20b4b057fa7f 31
Picmon 0:20b4b057fa7f 32 char* itoa(int num, char* str, int base);
Picmon 0:20b4b057fa7f 33 long mapI(long x, long in_min, long in_max, long out_min, long out_max);
Picmon 0:20b4b057fa7f 34 float mapF(float in, float inMin, float inMax, float outMin, float outMax);
Picmon 0:20b4b057fa7f 35 void nexScrnUpdate(void);
Picmon 0:20b4b057fa7f 36 void dbgNextion(void);
Picmon 0:20b4b057fa7f 37 void eepromTesting(void);
Picmon 0:20b4b057fa7f 38 void infoScrn(void);
Picmon 0:20b4b057fa7f 39 void NVM_update_Thread(void);
Picmon 0:20b4b057fa7f 40
Picmon 0:20b4b057fa7f 41 void nexInit(uint32_t baud);
Picmon 0:20b4b057fa7f 42 float low_pass_filterF(float x);
Picmon 0:20b4b057fa7f 43 void keyScan(void);
Picmon 0:20b4b057fa7f 44 float flowUnitPrec(int8_t precision);
Picmon 0:20b4b057fa7f 45 uint8_t runModeNVM(uint8_t settingIndex);
Picmon 0:20b4b057fa7f 46 void dbgStates(uint8_t state);
Picmon 0:20b4b057fa7f 47 uint8_t touchBtn(uint8_t nexPage, uint8_t nexBtn, uint8_t nexPushPop);
Picmon 0:20b4b057fa7f 48 uint8_t anaCal(void);
Picmon 0:20b4b057fa7f 49 float incDecControl(float *val, float precision, float min, float max, float speedLimit);
Picmon 0:20b4b057fa7f 50 bool drawCalGraph(float x1, float y1, float x2, float y2,bool draw);
Picmon 0:20b4b057fa7f 51 uint8_t retLastStoredTask(uint8_t storedTask);
Picmon 0:20b4b057fa7f 52 void flowUnitInc(uint8_t *flowUx, uint8_t *flowUy, uint8_t *flowUz);
Picmon 0:20b4b057fa7f 53 void flowUnitDec(uint8_t *flowUx, uint8_t *flowUy, uint8_t *flowUz);
Picmon 0:20b4b057fa7f 54 void dispList(uint8_t i[3], uint8_t incDec, uint8_t stringList, const string sArray[2][10], uint8_t maxListStrings);
Picmon 0:20b4b057fa7f 55 uint8_t ReadListIndexNVM(uint8_t nvm);
Picmon 0:20b4b057fa7f 56 void loopTimeMeasure(void);
Picmon 0:20b4b057fa7f 57 float motorRPM(void);
Picmon 0:20b4b057fa7f 58
Picmon 0:20b4b057fa7f 59 #endif