We are going to win! wohoo

Dependencies:   mbed mbed-rtos

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers ui.h Source File

ui.h

00001 
00002 #ifndef UI_H
00003 #define UI_H
00004 
00005 #include "rtos.h"
00006 
00007 #define NUMIDS 32
00008 
00009 class UI {
00010 public:
00011     Thread tUI;
00012     
00013     UI();
00014     
00015     bool regid(char id, unsigned int length);
00016     bool updateval(char id, float* buffer, unsigned int length);
00017     bool updateval(char id, float value);
00018     bool unregid(char id);
00019     
00020 private:
00021     Mutex printlock;
00022     char idlist[NUMIDS];
00023     float* buffarr[NUMIDS];
00024     volatile int newdataflags; //Only works for NUMID = 32
00025     
00026     void printloop();
00027     static void printtw(void const *arg){ ((UI*)arg)->printloop(); }
00028 };
00029 
00030 #endif //UI_H