mysensors.h 686 Bytes
Newer Older
Nelso Jost's avatar
Nelso Jost committed
1
2
3
4
5
6
#ifndef MYSENSORS_H
#define MYSENSORS_H

#include "Arduino.h"

String read_LDR();
Nelso Jost's avatar
Nelso Jost committed
7
8

#include "DHT.h"
Nelso Jost's avatar
Nelso Jost committed
9
10
11
String read_DHT22_TEMP();
String read_DHT22_AH();

Nelso Jost's avatar
Nelso Jost committed
12
13
14
15
16
17
18
19
#include "Adafruit_BMP085.h"
String read_BMP085_PRESSURE();

#include "RTClib.h"
String read_RTC_DS1307();
String get_datetime_str(DateTime dt);
String set_time_from_csv(String s);

Nelso Jost's avatar
Nelso Jost committed
20
21
void mysensors_setup();

Nelso Jost's avatar
Nelso Jost committed
22
23
24
25
#define __SENSOR_COUNT            5
#define __LIST_SENSOR_NICKNAMES   {"LDR", "BMP085_PRESSURE", "DHT22_TEMP", "DHT22_AH", "RTC_DS1307"}
#define __LIST_SENSOR_SHORT_NICKS {"l", "p", "t", "ah", "dt"}
#define __FP_ARRAY_SENSOR_READ    {&read_LDR, &read_BMP085_PRESSURE, &read_DHT22_TEMP, &read_DHT22_AH, &read_RTC_DS1307}
Nelso Jost's avatar
Nelso Jost committed
26
27

#endif