Eurobot2012_Primary

Dependencies:   mbed Eurobot_2012_Primary

Committer:
narshu
Date:
Thu Apr 26 21:02:12 2012 +0000
Revision:
2:cffa347bb943
Child:
8:ffc7d8af2d5a
not working

Who changed what in which revision?

UserRevisionLine numberNew contents of line
narshu 2:cffa347bb943 1
narshu 2:cffa347bb943 2 #ifndef UI_H
narshu 2:cffa347bb943 3 #define UI_H
narshu 2:cffa347bb943 4
narshu 2:cffa347bb943 5 #include "rtos.h"
narshu 2:cffa347bb943 6
narshu 2:cffa347bb943 7 #define NUMIDS 32
narshu 2:cffa347bb943 8
narshu 2:cffa347bb943 9 class UI {
narshu 2:cffa347bb943 10 public:
narshu 2:cffa347bb943 11 Thread tUI;
narshu 2:cffa347bb943 12
narshu 2:cffa347bb943 13 UI();
narshu 2:cffa347bb943 14
narshu 2:cffa347bb943 15 bool regid(char id, unsigned int length);
narshu 2:cffa347bb943 16 bool updateval(char id, float* buffer, unsigned int length);
narshu 2:cffa347bb943 17 bool updateval(char id, float value);
narshu 2:cffa347bb943 18 bool unregid(char id);
narshu 2:cffa347bb943 19
narshu 2:cffa347bb943 20 private:
narshu 2:cffa347bb943 21 char idlist[NUMIDS];
narshu 2:cffa347bb943 22 float* buffarr[NUMIDS];
narshu 2:cffa347bb943 23 int newdataflags; //Only works for NUMID = 32
narshu 2:cffa347bb943 24
narshu 2:cffa347bb943 25 void printloop();
narshu 2:cffa347bb943 26 static void printtw(void const *arg){ ((UI*)arg)->printloop(); }
narshu 2:cffa347bb943 27 };
narshu 2:cffa347bb943 28
narshu 2:cffa347bb943 29 #endif //UI_H