2022-07-15 19:19:28 +02:00

41 lines
929 B
C

#ifndef _COMMON_H_
#define _COMMON_H_
#define Q(x) #x
#define QUOTE(x) Q(x)
// Module connection pins (ESP GPIO-Nums)
#define CLK 12
#define DIO_FAC_1_7SEG 13
#define DIO_FAC_2_7SEG 17
#define DIO_FAC_3_7SEG 21
#define DIO_FAC_1_TRG 36
#define FAC_1_TRG_PRESSED LOW
#define DIO_FAC_2_TRG 37
#define FAC_2_TRG_PRESSED LOW
#define DIO_FAC_3_TRG 38
#define FAC_3_TRG_PRESSED LOW
#ifndef HOST_NAME
#define HOST_NAME "DE_Timer_%06X" // Use printf-Formatting - Chip-ID (uin32_t) will be added
#endif
#ifndef OTA_DELAY
#define OTA_DELAY 50 // ticks -> 10ms / tick
#endif
#ifndef ADMIN_PASSWORD
#error "You need to define ADMIN_PASSWORD for OTA-Update"
#endif
#ifndef WIFI_PASSWORD
#error "You must define an WIFI_PASSWORD for OTA-Update"
#endif
#ifndef WIFI_SSID
#error "You must define an WIFI_SSID for OTA-Update"
#endif
#ifndef WIFI_AP_PASSWORD
#error "You must define an WIFI_AP_PASSWORD for Standalone AP-Mode"
#endif
#endif