banban525/echonetlite2mqtt

By banban525

Updated 7 days ago

ECHONET Lite to MQTT bridge.

Image
API Management
Web Servers

8.6K

GitHub Release Date

ECHONET Lite to MQTT bridge.

GitHub: https://github.com/banban525/echonetlite2mqtt

Description

This application publishes ECHONET Lite devices to MQTT. And uses MQTT to work with ECHONET Lite devices. This will allow you to operate your ECHONET Lite device from a smart home application that supports MQTT.

topimage

The supported devices are as follows.

  • Emergency button (0x0003)
  • Human detection sensor (0x0007)
  • Temperature sensor (0x0011)
  • Humidity sensor (0x0012)
  • Bath heating status sensor (0x0016)
  • CO2 sensor (0x001B)
  • VOC sensor (0x001D)
  • Electric energy sensor (0x0022)
  • Current sensor (0x0023)
  • Illuminance sensor (0x00D0)
  • Home air conditioner (0x0130)
  • Ventilation fan (0x0133)
  • Air conditioner ventilation fan (0x0134)
  • Air cleaner (0x0135)
  • Package-type commercial air conditioner (indoor unit) (except those for facilities) (0x0156)
  • Package-type commercial air conditioner (outdoor unit) (0x0157)
  • Electrically operated rain sliding door/shutter (0x0263)
  • Electrically operated window (0x0265)
  • Electric water heater (0x026B)
  • Electric lock (0x026F)
  • Instantaneous water heater (0x0272)
  • Bathroom heater dryer (0x0273)
  • Household solar power generation (0x0279)
  • Cold or hot water heat source equipment (0x027A)
  • Floor heater (0x027B)
  • Fuel cell (0x027C)
  • Storage battery (0x027D)
  • EV charger and discharger (0x027E)
  • Watt-hour meter (0x0280)
  • Water flowmeter (0x0281)
  • Gas meter (0x0282)
  • Power distribution board metering (0x0287)
  • Low-voltage smart electric energy meter (0x0288)
  • High-voltage smart electric energy meter (0x028A)
  • Smart electric energy meter for sub-metering (0x028D)
  • General lighting (0x0290)
  • Mono functional lighting (0x0291)
  • EV Charger (0x02A1)
  • Lighting system (0x02A3)
  • Extended lighting system (0x02A4)
  • Hybrid water heater (0x02A6)
  • Refrigerator (0x03B7)
  • Cooking heater (0x03B9)
  • Rice cooker (0x03BB)
  • Commercial showcase (0x03CE)
  • Washer and dryer (0x03D3)
  • Commercial show case outdoor unit (0x03D4)
  • Switch (supporting JEM-A/HA terminals) (0x05FD)
  • Controller (0x05FF)
  • Television (0x0602)

DEMO

demo-webui

demo-aircon

more demo movies and settings examples

How to use

Use docker
  1. Run the following command
docker run -d --net=host -e MQTT_BROKER="mqtt://your.mqtt.brocker" banban525/echonetlite2mqtt 
  1. Open "http://(docker host):3000" in your browser. You can view the detected devices and logs.

Environment Variables

MQTT Options

  • MQTT_BROKER ... MQTT Brocker's URL. starts with "mqtt://" or "mqtts://".
  • MQTT_OPTION_FILE ... the MQTT option file path. The schema is MQTT.js ClientOptions. (Default: empty)
  • MQTT_CA_FILE ... The MQTT CA file path. If this file exists, it will be loaded and set as an "ca" option. (Default: not load)
  • MQTT_CERT_FILE ... The MQTT cert file path. If this file exists, it will be loaded and set as an "cert" option. (Default: not load)
  • MQTT_KEY_FILE ... The MQTT key file path. If this file exists, it will be loaded and set as an "key" option. (Default: not load)
  • MQTT_BASE_TOPIC ... MQTT topic prefix. (Default:"echonetlite2mqtt/elapi/v2/devices")

REST API Options

  • REST_API_HOST ... Host IP of the administrator page. If there are multiple IPs, specify them. (Default: 0.0.0.0)
  • REST_API_PORT ... Admin page port number. (Default: 3000)

ECHONET Lite Options

  • ECHONET_TARGET_NETWORK ... Specify the network for ECHONET Lite in the format "xxx.xxx.xxx.xxx/yy". (Default: Auto)
  • ECHONET_ALIAS_FILE ... The file path for alias option file. (Defalt: (empty))
  • ECHONET_INTERVAL_TO_GET_PROPERTIES ... Specifies the time interval for acquiring ECHONET Lite properties. (Unit: ms) (Default: 100)
Alias Option File Format

You can alias device Ids using ECHONET_ALIAS_FILE ( or --echonetAliasFile ) option. This option specifies the path of the Alias Option File.

The Alias ​​Option File is a Json file with the following format:

{
  "aliases":[
    {
      "id":"fe00-your-device-id-00000000000000",
      "name":"alias name"
    },

...

    {
      "id":"fe0000251c4190000081e5bb0000000000",
      "name":"shutter"
    },
    {
      "id":"fe000008dcfe23ba1ff000000000000000",
      "name":"airconditioner-living"
    }
  ]
}

Third party use

LISENCE

MIT

Author

banban525

Docker Pull Command

docker pull banban525/echonetlite2mqtt