Scientific task box V1
Dependents: Scientific_RTOS Scientific_RTOS
BOX.h
- Committer:
- Alessio_Zaino
- Date:
- 2019-05-13
- Revision:
- 0:01deb85101c9
- Child:
- 2:f8120bb54b69
File content as of revision 0:01deb85101c9:
#ifndef BOX_H #define BOX_H #include "mbed.h" #include "HX711.h" #include "DS18B20.h" class BOX { public: BOX (PinName pinCLK_HX711, PinName pinDAT_HX711,PinName pin_temp, PinName pin_cond,int HX711_coefficent); float get_temp(); //return temperature from DS18B20 int get_weight(); //return weight in g from hx711 int get_resistance();//return soil resistance void tare(unsigned char times=20); //sets tare on HX711 library //virtual ~BOX(); private: PinName _pinCLK; PinName _pinDAT; PinName _pintemp; PinName _pincond; int _coefficent; float _tmp; DS18B20 therm; // Dallas 1-wire HX711 balance; }; #endif