Output - vingerha/gazpar_2_mqtt GitHub Wiki
1. MQTT
Measures
Last measures :
Topic | Description |
---|---|
gazpar/PCE/last/index | Gas index in m3 of the last measure |
gazpar/PCE/last/date | Date of the last measure |
gazpar/PCE/last/energy | Gas consumption in kWh of the last measure |
gazpar/PCE/last/gas | Gas consumption in m3 of the last measure |
gazpar/PCE/last/conversion_factor | Conversion factor in kWh/m3 of the last measure |
Published measures :
Topic | Description |
---|---|
gazpar/PCE/published/index | Gas index in m3 of the last published measure |
gazpar/PCE/published/start_date | Start date of the period of the last published measure |
gazpar/PCE/published/end_date | End date of the period of the last published measure |
gazpar/PCE/published/energy | Gas consumption in kWh of the last published measure |
gazpar/PCE/published/gas | Gas consumption in m3 of the last published measure |
gazpar/PCE/published/conversion_factor | Conversion factor in kWh/m3 of the last published measure |
Calculated calendar measures :
Topic | Description |
---|---|
gazpar/PCE/histo/current_year_gas | Gas consumption in m3 of current year |
gazpar/PCE/histo/previous_year_gas | Gas consumption in m3 of previous year |
gazpar/PCE/histo/current_month_gas | Gas consumption in m3 of current month |
gazpar/PCE/histo/previous_month_gas | Gas consumption in m3 of previous month |
gazpar/PCE/histo/current_month_previous_year_gas | Gas consumption in m3 of current month, 1 year ago |
gazpar/PCE/histo/current_week_gas | Gas consumption in m3 of current week |
gazpar/PCE/histo/previous_week_gas | Gas consumption in m3 of previous week |
gazpar/PCE/histo/current_week_previous_year | Gas consumption in m3 of current week, 1 year ago |
gazpar/PCE/histo/day-1_gas | Gas consumption in m3, 1 day ago |
gazpar/PCE/histo/day-2_gas | Gas consumption in m3, 2 day ago |
gazpar/PCE/histo/day-3_gas | Gas consumption in m3, 3 day ago |
gazpar/PCE/histo/day-4_gas | Gas consumption in m3, 4 day ago |
gazpar/PCE/histo/day-5_gas | Gas consumption in m3, 5 day ago |
gazpar/PCE/histo/day-6_gas | Gas consumption in m3, 6 day ago |
gazpar/PCE/histo/day-7_gas | Gas consumption in m3, 7 day ago |
Calculated rolling measures :
Topic | Description |
---|---|
gazpar/PCE/histo/rolling_year_gas | Gas consumption in m3 for 1 rolling year |
gazpar/PCE/histo/rolling_year_last_year_gas | Gas consumption in m3 for 1 rolling year, 1 year ago |
gazpar/PCE/histo/rolling_month_gas | Gas consumption in m3 for 1 rolling month |
gazpar/PCE/histo/rolling_month_last_month_gas | Gas consumption in m3 for 1 rolling month, 1 month ago |
gazpar/PCE/histo/rolling_month_last_year_gas | Gas consumption in m3 for 1 rolling month, 1 year ago |
gazpar/PCE/histo/rolling_month_last_2_year_gas | Gas consumption in m3 for 1 rolling month, 2 years ago |
gazpar/PCE/histo/rolling_week_gas | Gas consumption in m3 for 1 rolling week |
gazpar/PCE/histo/rolling_week_last_week_gas | Gas consumption in m3 for 1 rolling week, 1 week ago |
gazpar/PCE/histo/rolling_week_last_year_gas | Gas consumption in m3 for 1 rolling week, 1 year ago |
gazpar/PCE/histo/rolling_week_last_2_year_gas | Gas consumption in m3 for 1 rolling week, 2 years ago |
Calculated thresold measures :
Topic | Description |
---|---|
gazpar/PCE/thresold/current_month_thresold | Thresold in kWh of current month |
gazpar/PCE/thresold/current_month_thresold_percentage | Percentage of energy consumption and thresold of current month |
gazpar/PCE/thresold/current_month_thresold_problem | Warning when energy consumption is higher than 80% of the thresold of current month |
gazpar/PCE/thresold/previous_month_thresold | Thresold in kWh of previous month |
gazpar/PCE/thresold/previous_month_thresold_percentage | Percentage of energy consumption and thresold of previous month |
gazpar/PCE/thresold/previous_month_thresold_problem | Warning when energy consumption is higher than 80% of the thresold of previous month |
Note : thresold percentage can be editable in environment variable
Status
Topic | Description |
---|---|
gazpar/PCE/status/date | Last execution date time of gazpar2mqtt |
gazpar/PCE/status/value | Last execution status of gazpar2mqtt (ON or OFF) |
2. Home Assistant (discovery mode)
Gazpar2mqtt provides Home Assistant compatible Mqtt devices. The discovery function enable to use MQTT devices with a minimal configuration effort.
Have a look to Home Assistant Mqtt discovery documentation.
Device
Device name | Device ID | Model | Manufacturer |
---|---|---|---|
gazpar | gazpar_PCE | PCE | GRDF |
Note : you can replace the default device name gazpar by editing the related parameter.
List of entities
Last informative measure entities :
Entity name | Component | Device class | Description |
---|---|---|---|
gazpar_PCE_index | Sensor | Gas | Gas index in m3 of the last measure |
gazpar_PCE_gas | Sensor | Gas | Gas consumption in m3 of the last measure |
gazpar_PCE_energy | Sensor | Energy | Gas consumption in kWh of the last measure |
gazpar_PCE_consumption_date | Sensor | Date | Date of the last measure |
gazpar_PCE_connectivity | Binary sensor | Connectivity | Binary sensor which indicates if the last gazpar statement succeeded (ON) or failed (OFF) |
Last published measure entities :
Entity name | Component | Device class | Description |
---|---|---|---|
gazpar_PCE_published_index | Sensor | Gas | Gas index in m3 of the last published measure |
gazpar_PCE_published_gas | Sensor | Gas | Gas consumption in m3 of the last published measure |
gazpar_PCE_published_energy | Sensor | Energy | Gas consumption in kWh of the last published measure |
gazpar_PCE_published_consumption_start_date | Sensor | Date | Start date of the last published measure |
gazpar_PCE_published_consumption_end_date | Sensor | Date | End date of the last published measure |
Calendar measure entities :
Entity name | Component | Device class | Description |
---|---|---|---|
gazpar_PCE_current_year_gas | Sensor | Gas | Gas consumption in m3 of current year |
gazpar_PCE_previous_year_gas | Sensor | Gas | Gas consumption in m3 of previous year |
gazpar_PCE_previous_2_year_gas | Sensor | Gas | Gas consumption in m3 of previous 2 years |
gazpar_PCE_current_month_gas | Sensor | Gas | Gas consumption in m3 of current month |
gazpar_PCE_previous_month_gas | Sensor | Gas | Gas consumption in m3 of previous month |
gazpar_PCE_current_month_last_year_gas | Sensor | Gas | Gas consumption in m3 of current month, 1 year ago |
gazpar_PCE_current_week_gas | Sensor | Gas | Gas consumption in m3 of current week |
gazpar_PCE_previous_week_gas | Sensor | Gas | Gas consumption in m3 of current week |
gazpar_PCE_current_week_last_year_gas | Sensor | Gas | Gas consumption in m3 of current week, 1 year ago |
gazpar_PCE_day_1_gas | Sensor | Gas | Gas consumption based on index in m3 of day -1 |
gazpar_PCE_day_x_gas | Sensor | Gas | Gas consumption based on index in m3 of day -x (max 7d back) |
gazpar_PCE_day_1_gas_gross | Sensor | Gas | Gas gross consumption in m3 of day -1 |
gazpar_PCE_day_x_gas_gross | Sensor | Gas | Gas gross consumption in m3 of day -x (max 7d back) |
Rolling measure entities :
Entity name | Component | Device class | Description |
---|---|---|---|
gazpar_PCE_rolling_year_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling year |
gazpar_PCE_rolling_year_last_year_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling year, 1 year ago |
gazpar_PCE_rolling_rolling_month_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling month |
gazpar_PCE_rolling_month_last_month_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling month, 1 month ago |
gazpar_PCE_rolling_month_last_year_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling month, 1 year ago |
gazpar_PCE_rolling_month_last_2_year_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling month, 2 years ago |
gazpar_PCE_rolling_rolling_week_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling week |
gazpar_PCE_rolling_week_last_week_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling week, 1 week ago |
gazpar_PCE_rolling_week_last_year_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling week, 1 year ago |
gazpar_PCE_rolling_week_last_2_year_gas | Sensor | Gas | Gas consumption in m3 for 1 rolling week, 2 years ago |
Calculated thresold measures :
Entity name | Component | Device class | Description |
---|---|---|---|
gazpar_PCE_current_month_thresold | Sensor | Energy | Thresold in kWh of current month |
gazpar_PCE_current_month_thresold | Sensor | None | Percentage of energy consumption and thresold of current month |
gazpar_PCE_current_month_thresold | Binary sensor | Problem | Warning when energy consumption is higher than 80% of the thresold of current month |
gazpar_PCE_previous_month_thresold | Sensor | Energy | Thresold in kWh of previous month |
gazpar_PCE_previous_month_thresold | Sensor | None | Percentage of energy consumption and thresold of previous month |
gazpar_PCE_previous_month_thresold | Binary sensor | Problem | Warning when energy consumption is higher than 80% of the thresold of previous month |
Note : thresold percentage can be editable in environment variable.
3. InfluxDb
You can activate export of data to your InfluxDb v2 database. InfluxDb v1 is currently not supported. If you have connection issues try adding this to the service section in docker-compose.yml
network_mode = "host"
3b. Grafana (not yet tested)
Example of a Grafana dashboard using InfluxDb v2 and gazpar2mqtt measures :
To integrate this dashboard into Grafana, copy/paste content of file grafana_sample.json.
4. Long Term Statistics
In order to use long term statistics, you need to use the appropriate parameters in docker-compose.yml (or param.py) Create a Long Term Access token in HA and use that.
Required params (webservice)
HASS_LTS: True
HASS_LTS_HOST: "http://192.168.x.y:8123"
HASS_LTS_TOKEN: 98724kjhawelkj....etc. (use the Long Term Access token, generated for the LTS_HOST below)
Note: for the HAOS-addon:
HASS_LTS=True
HASS_LTS_HOST="http://homeassistant.local:8123"
HASS_LTS_TOKEN=98724kjhawelkj....etc. (use the Long Term Access token, generated for the LTS_HOST below)
Generated statistics: Please note that these statistics are imported, they donot exist as entities with the same name
Nom | Contains |
---|---|
gazpar:[device]_[pce-alias]_consumption_stat | for daily figures in m3 |
gazpar:[device]_[pce-alias]_consumption_kwh_stat | for daily figures in kWh |
gazpar:[device]_[pce-alias]_consumption_cost_stat | daily cost |
and for the periodic "published" figures
Nom | Contains |
---|---|
gazpar:[device]_[pce-alias]_consumption_pub_stat | for periodic figures in m3 |
gazpar:[device]_[pce-alias]_consumption_kwh_pub_stat | for periodic figures in kWh |
gazpar:[device]_[pce-alias]_consumption_cost_pub_stat | periodic cost |
You can add these sensor to your Energy dashboard, noting that this sensor only (!) exists as a long term statistic