air_conditioner_apiの横で動作するMQTTのagent。 MQTT経由でsubscribeしていたコマンドイベントから、air confitioner apiを叩くことができる。
detail
prefix: {PROJECT_ID}/air_conditioner_api_mqtt_agent
{prefix}/on/cool
{prefix}/on/hot
- temperature: number = 16~31
- airflowLevel: string = "a" | "1" | "2" | "3"
{
"temperature": 26,
"airflowLevel": "2"
}
{prefix}/on/dehumidify
- dehumidificationLevel: number = 1~3
- airflowLevel: string = "a" | "1" | "2" | "3"
{
"dehumidificationLevel": 2,
"airflowLevel": "2"
}
{prefix}/off
None
{prefix}/ping
None
rebbot this mqtt agent
{prefix}/reboot
None
detail
prefix: {PROJECT_ID}/air_conditioner_api_mqtt_agent
ping ack
{prefix}/ack
- mqtt_agent: boolean
- air_conditioner_api: boolean
true: OK, false: not running
{
"mqttAgent": true,
"airConditionerApi": true
}
latest air conditioner state
{prefix}/state
- isRunning: boolean
- type: string = "cool" | "hot" | "dehumidify"
- temperature: number | null = 16 ~ 31 | null(only type="dehumidify")
- dehumidificationLevel: number | null = 1 ~ 3 | null(only type ="hot" or "cool")
- airflowLevel: string = "a" | "1" | "2" | "3"
type = "cool" or "hot"
{
"isRunning": true,
"type": "cool",
"temperature": 26,
"dehumidificationLevel": null,
"airflowLevel": "3"
}
type = "off"
{
"isRunning": true,
"type": "hot",
"temperature": 27,
"dehumidificationLevel": null,
"airflowLevel": "a"
}
type = "dehumidify"
{
"isRunning": false,
"type": "dehumidify",
"temperature": null,
"dehumidificationLevel": 2,
"airflowLevel": "2"
}