temp

Committer:
BenRJG
Date:
Thu Dec 06 15:38:09 2018 +0000
Revision:
0:2a4af0cb6e8d
Imported Code from Kiel; Added button functionality; Added set DateTime Functionality

Who changed what in which revision?

UserRevisionLine numberNew contents of line
BenRJG 0:2a4af0cb6e8d 1 #include "mbed.h"
BenRJG 0:2a4af0cb6e8d 2 #include "SDBlockDevice.h"
BenRJG 0:2a4af0cb6e8d 3 #include "FATFileSystem.h"
BenRJG 0:2a4af0cb6e8d 4 #include "General.hpp"
BenRJG 0:2a4af0cb6e8d 5 #include "rtos.h"
BenRJG 0:2a4af0cb6e8d 6
BenRJG 0:2a4af0cb6e8d 7 // Class SDReader expects mosi miso sclk and cs pins and is used for controlling a spi connected sd reader
BenRJG 0:2a4af0cb6e8d 8 class SDReader {
BenRJG 0:2a4af0cb6e8d 9 public:
BenRJG 0:2a4af0cb6e8d 10 SDReader(PinName mosi, PinName miso, PinName sclk, PinName cs) : sd(mosi, miso, sclk, cs), fs("sd", &sd){}
BenRJG 0:2a4af0cb6e8d 11 BYTE INIT(void);
BenRJG 0:2a4af0cb6e8d 12 void UPLOAD(FLOAT_32 LIGHT, FLOAT_32 TEMP, FLOAT_32 PRESS);
BenRJG 0:2a4af0cb6e8d 13 BYTE* DOWNLOAD(void);
BenRJG 0:2a4af0cb6e8d 14 void unmount(void);
BenRJG 0:2a4af0cb6e8d 15 private:
BenRJG 0:2a4af0cb6e8d 16 SDBlockDevice sd;
BenRJG 0:2a4af0cb6e8d 17 FATFileSystem fs;
BenRJG 0:2a4af0cb6e8d 18 };
BenRJG 0:2a4af0cb6e8d 19
BenRJG 0:2a4af0cb6e8d 20 void SDThread(void); // Thread for terminal to run in
BenRJG 0:2a4af0cb6e8d 21