Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed mbed-STM32F103C8T6 OneWireCRC_LoRa_Node SX1276Lib_LoRa_Node
Thermometer.h
- Committer:
- lukas_formanek
- Date:
- 2018-04-19
- Revision:
- 0:cc04364f049a
- Child:
- 1:a54ff5e2c2f3
File content as of revision 0:cc04364f049a:
#ifndef THERMOMETER_H #define THERMOMETER_H #include "mbed.h" #include "Board.h" #include "DS18B20.h" #include "DS18S20.h" #include "OneWireDefs.h" #define THERMOMETER DS18B20 #define THERMOMETER_CRC_ON true #define THERMOMETER_USE_ADDR true #define THERMOMETER_PARASITIC false #define THERMOMETER_RESOLUTION twelveBit //#define MAX_MESSAGE_LENGTH class Thermometer { private: THERMOMETER thermometer; /**< Teplomer na pine D6 */ Ticker thermometerTicker; volatile float meassuredValue; // char messageToSend[] void OnSampleTick(); public: Thermometer(bool crcOn, bool useAddr, bool parasitic, PinName pin); void Init(); void StartPeriodicMeassure(float timeSec); }; #endif