esp8266-geigercounter/settings.h.example
hem@hdk 0c10ef4ba9
Fix custom hostname (#2)
- Changed HOSTNAME to constant macro definition so it is properly evaluated via #ifdef directive.

- Increased max. hostname length to 24 characters.
2020-09-23 13:10:11 +02:00

47 lines
No EOL
1.2 KiB
Text

#define IDX_CPS_KEY 0
#define IDX_CPM_KEY 2
#define IDX_uSv_KEY 4
#define IDX_CPM 3
#define IDX_uSv 5
#define IDX_MODE 6
#define RECV_LINE_SIZE 37
#define PIN_UART_RX 0 // 4
#define PIN_UART_TX 13 // UNUSED
#define UPDATE_INTERVAL_SECONDS 60L
#define BAUD_GEIGERCOUNTER 9600
//#define HOSTNAME "ESP-GeigerCounter" //Optional
const char* OTA_PASSWORD = "foobar";
#define MQTT_HOST "mqtt.core.bckspc.de"
//If you don't want to use home-assistant autodiscovery comment this out
#define USE_HA_AUTODISCOVERY
#ifdef USE_HA_AUTODISCOVERY
#define HA_DISCOVERY_PREFIX "homeassistant"
const char* MQTT_LAST_WILL_PAYLOAD_CONNECTED = "online";
const char* MQTT_LAST_WILL_PAYLOAD_DISCONNECTED = "offline";
#else
//If you're not using HA Autodiscovery, you can specify your topics here
const char* MQTT_TOPIC_CPM_MEASUREMENT = "sensor/radiation/cpm";
const char* MQTT_TOPIC_USV_MEASUREMENT = "sensor/radiation/uSv";
const char* MQTT_TOPIC_LAST_WILL = "sensor/radiation/will";
const char* MQTT_LAST_WILL_PAYLOAD_CONNECTED = "connected";
const char* MQTT_LAST_WILL_PAYLOAD_DISCONNECTED = "disconnected";
#endif
const char* MQTT_USERNAME = NULL;
const char* MQTT_PASSWORD = NULL;
const uint8_t MQTT_MAX_CONNECT_RETRY = 42;
const char* delimiter = ", ";