Mqtt discovery (#320)
* add mqtt discovery (compatibile with home assistant) with omg status binary sensor & bme280 sensor * added mqtt discovery to Test_config.h for ESP32 (ESP8266 & other boards was not tested) * include support for ESP8266 & arduino mega * fix getting MAC for esp8266 * esp8266 fix * make mqtt discovery functions functions more generic, readable and easy to use & extend * make mqtt discovery functions functions more generic, readable and easy to use & extend PART 2 * remove the macro for each attribute and supposing that if there is a bme280 we expose all
This commit is contained in:
1 parent
67dd7ac078
commit
81c02c850e
5 files changed
+218
-5
No files matched your search
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
OpenMQTTGateway - ESP8266 or Arduino program for home automation
|
||||
|
||||
Act as a wifi or ethernet gateway between your 433mhz/infrared IR signal and a MQTT broker
|
||||
Send and receiving command by MQTT
|
||||
|
||||
This files enables to set your parameter for the Home assistant mqtt Discovery
|
||||
|
||||
Copyright: (c) Rafal Herok
|
||||
|
||||
This file is part of OpenMQTTGateway.
|
||||
|
||||
OpenMQTTGateway 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.
|
||||
|
||||
OpenMQTTGateway 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 <http://www.gnu.org/licenses/>.
|
||||
|
||||
*/
|
||||
#define discovery_Topic "homeassistant"
|
||||
#define omgStatus //uncomment to create OMG status sensor
|
||||
#define discBme280 //uncomment to enable bme280 sensors
|
||||
|
||||
#define DEVICENAME "OpenMQTTGateway " Gateway_Name
|
||||
#define DEVICEMANUFACTURER "AnimaVitis"
|
||||
Reference in new issue
Block a user