2018-11-26 11:58:15 +00:00
|
|
|
/*
|
|
|
|
* This file is part of the "bluetoothheater" distribution
|
|
|
|
* (https://gitlab.com/mrjones.id.au/bluetoothheater)
|
|
|
|
*
|
|
|
|
* Copyright (C) 2018 Ray Jones <ray@mrjones.id.au>
|
|
|
|
* Copyright (C) 2018 James Clark
|
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
2018-10-30 07:56:51 +00:00
|
|
|
// Place Holder Config File - User config vars and defines to be moved here
|
2018-10-30 11:05:29 +00:00
|
|
|
|
2018-10-31 18:57:21 +00:00
|
|
|
//////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Configure bluetooth options
|
|
|
|
// ** Recommended to use HC-05 for now **
|
2018-10-31 20:55:25 +00:00
|
|
|
// If none are enabled, we'll use an abstract class that only reports
|
|
|
|
// to the debug port what would have been sent
|
2018-10-31 18:57:21 +00:00
|
|
|
//
|
2018-10-31 20:55:25 +00:00
|
|
|
#define USE_HC05_BLUETOOTH 1
|
|
|
|
#define USE_BLE_BLUETOOTH 0
|
|
|
|
#define USE_CLASSIC_BLUETOOTH 0
|
|
|
|
|
2018-11-07 18:23:40 +00:00
|
|
|
//////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Configure WiFi options
|
|
|
|
//
|
|
|
|
// *** Presently ESP32 Bluetooth and WiFi do not co-exist well (ala don't work!) ***
|
|
|
|
// HC-05 works OK with WiFi
|
|
|
|
//
|
2019-02-26 08:38:30 +00:00
|
|
|
#define USE_WIFI 1
|
2019-01-14 04:22:57 +00:00
|
|
|
#define USE_OTA 1
|
2018-11-07 18:23:40 +00:00
|
|
|
#define USE_WEBSERVER 1
|
2019-01-20 10:14:45 +00:00
|
|
|
#define USE_SPIFFS 1
|
|
|
|
|
2019-05-20 12:09:59 +00:00
|
|
|
#define USE_PORTAL_TRIGGER_PIN 0
|
2018-11-07 10:31:00 +00:00
|
|
|
|
2018-10-31 20:55:25 +00:00
|
|
|
|
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// debug reporting options
|
|
|
|
//
|
|
|
|
// true: each frame of data is reported on a new lines
|
|
|
|
// false: controller, then heater response frmaes are reported on a single line (excel CSV worthy!)
|
|
|
|
//
|
2019-01-13 19:59:32 +00:00
|
|
|
#define REPORT_RAW_DATA 0 /* can toggle using <B> from debug console */
|
2018-12-20 04:19:59 +00:00
|
|
|
#define TERMINATE_OEM_LINE 0 /* when an OEM controller exists */
|
|
|
|
#define TERMINATE_BTC_LINE 0 /* when an OEM controller does not exist */
|
2019-01-13 19:59:32 +00:00
|
|
|
#define REPORT_OEM_RESYNC 0 /* report idle time if OEM controller detected */
|
2018-12-21 21:48:39 +00:00
|
|
|
#define REPORT_STATE_MACHINE_TRANSITIONS 0 /* state machine changes reported to DebugPort */
|
2018-12-20 07:33:44 +00:00
|
|
|
#define REPORT_BLUEWIRE_RECYCLES 1 /* best default on as this is abnormal behaviour can toggle using <W> on debug console */
|
2018-10-31 20:55:25 +00:00
|
|
|
|
2018-11-06 09:43:54 +00:00
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// LED monitoring
|
|
|
|
//
|
|
|
|
// 1: enable specific LED function
|
|
|
|
// 0: disable specific LED function
|
|
|
|
//
|
|
|
|
#define RX_LED 1 /* flash when receiving blue wire data */
|
|
|
|
#define BT_LED 0 /* flash when sending bluetooth data */
|
2018-11-13 11:02:14 +00:00
|
|
|
|
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// DS18B20 temperature sensing
|
|
|
|
//
|
|
|
|
#define TEMPERATURE_INTERVAL 1000
|
2018-12-09 01:10:56 +00:00
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Real Time Clock support
|
|
|
|
//
|
|
|
|
// only select one option to use the indicated hardware
|
|
|
|
// if none are selected, RTC_Millis will be used, which is volatile (based upon millis())
|
|
|
|
//
|
|
|
|
#define RTC_USE_DS3231 1
|
|
|
|
#define RTC_USE_DS1307 0
|
|
|
|
#define RTC_USE_PCF8523 0
|
2018-11-19 19:31:20 +00:00
|
|
|
|
|
|
|
|
2018-12-09 01:10:56 +00:00
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Blue wire handling
|
|
|
|
//
|
2018-12-19 19:13:28 +00:00
|
|
|
#define SUPPORT_OEM_CONTROLLER 1 /* 0=we send without regard to an OEM's data, 1=co-exist with OEM controller */
|
2018-12-20 04:19:59 +00:00
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Communications reporting
|
|
|
|
//
|
|
|
|
#define REPORT_JSON_TRANSMIT 1
|
|
|
|
|
2019-01-10 05:01:52 +00:00
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Adafruit OLED selection
|
|
|
|
//
|
|
|
|
#define USE_ADAFRUIT_SH1106 1
|
2019-04-04 10:48:05 +00:00
|
|
|
#define USE_ADAFRUIT_SSD1306 0
|
|
|
|
|
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Protocol exploration
|
|
|
|
//
|
|
|
|
//#define PROTOCOL_INVESTIGATION
|
2019-05-17 06:08:35 +00:00
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
2019-05-20 12:09:59 +00:00
|
|
|
// Software based watchdog
|
2019-05-17 06:08:35 +00:00
|
|
|
//
|
|
|
|
#define USE_SW_WATCHDOG 1
|
|
|
|
|