mirror of https://github.com/arendst/Tasmota.git
Support for Matter 1.3 Water leak detectors (#21456)
* Create Matter_Plugin_2_Sensor_Waterleak.be * Update Matter_Plugin_2_Sensor_Waterleak.be * Create Matter_Plugin_3_Bridge_Sensor_Waterleak.be * Create Matter_Plugin_9_Virt_Sensor_Waterleak.be * Update Matter_UI.be * Update be_matter_module.c * Update Matter_UI.be * Solidify Matter * Solidified new Matter files * Solidified new Matter files
This commit is contained in:
parent
2eccc96c62
commit
dc107a1a6e
|
@ -253,8 +253,10 @@ extern const bclass be_class_Matter_TLV; // need to declare it upfront because
|
||||||
#include "solidify/solidified_Matter_Plugin_2_Sensor_Occupancy.h"
|
#include "solidify/solidified_Matter_Plugin_2_Sensor_Occupancy.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_2_Sensor_OnOff.h"
|
#include "solidify/solidified_Matter_Plugin_2_Sensor_OnOff.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_2_Sensor_Contact.h"
|
#include "solidify/solidified_Matter_Plugin_2_Sensor_Contact.h"
|
||||||
|
#include "solidify/solidified_Matter_Plugin_2_Sensor_Waterleak.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_9_Virt_Sensor_Contact.h"
|
#include "solidify/solidified_Matter_Plugin_9_Virt_Sensor_Contact.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_9_Virt_Sensor_Occupancy.h"
|
#include "solidify/solidified_Matter_Plugin_9_Virt_Sensor_Occupancy.h"
|
||||||
|
#include "solidify/solidified_Matter_Plugin_9_Virt_Sensor_Waterleak.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_2_Bridge_HTTP.h"
|
#include "solidify/solidified_Matter_Plugin_2_Bridge_HTTP.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_4_Bridge_OnOff.h"
|
#include "solidify/solidified_Matter_Plugin_4_Bridge_OnOff.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_3_Bridge_Light0.h"
|
#include "solidify/solidified_Matter_Plugin_3_Bridge_Light0.h"
|
||||||
|
@ -269,6 +271,7 @@ extern const bclass be_class_Matter_TLV; // need to declare it upfront because
|
||||||
#include "solidify/solidified_Matter_Plugin_3_Bridge_Sensor_Occupancy.h"
|
#include "solidify/solidified_Matter_Plugin_3_Bridge_Sensor_Occupancy.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_3_Bridge_Sensor_Contact.h"
|
#include "solidify/solidified_Matter_Plugin_3_Bridge_Sensor_Contact.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_4_Bridge_Sensor_Flow.h"
|
#include "solidify/solidified_Matter_Plugin_4_Bridge_Sensor_Flow.h"
|
||||||
|
#include "solidify/solidified_Matter_Plugin_3_Bridge_Sensor_Waterleak.h"
|
||||||
#include "solidify/solidified_Matter_Plugin_z_All.h"
|
#include "solidify/solidified_Matter_Plugin_z_All.h"
|
||||||
#include "solidify/solidified_Matter_zz_Device.h"
|
#include "solidify/solidified_Matter_zz_Device.h"
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,119 @@
|
||||||
|
#
|
||||||
|
# Matter_Plugin_2_Sensor_Waterleak.be - implements the behavior for a Water leak Sensor
|
||||||
|
#
|
||||||
|
# Copyright (C) 2024 Stephan Hadinger & Theo Arends
|
||||||
|
#
|
||||||
|
# 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 <http://www.gnu.org/licenses/>.
|
||||||
|
#
|
||||||
|
|
||||||
|
import matter
|
||||||
|
|
||||||
|
# Matter plug-in for core behavior
|
||||||
|
|
||||||
|
#@ solidify:Matter_Plugin_Sensor_Waterleak,weak
|
||||||
|
|
||||||
|
class Matter_Plugin_Sensor_Waterleak : Matter_Plugin_Device
|
||||||
|
static var TYPE = "waterleak" # name of the plug-in in json
|
||||||
|
static var DISPLAY_NAME = "Waterleak" # display name of the plug-in
|
||||||
|
static var ARG = "switch" # additional argument name (or empty if none)
|
||||||
|
static var ARG_HINT = "Switch<x> number"
|
||||||
|
static var ARG_TYPE = / x -> int(x) # function to convert argument to the right type
|
||||||
|
static var UPDATE_TIME = 750 # update every 750ms
|
||||||
|
static var UPDATE_COMMANDS = matter.UC_LIST(_class, "Waterleak")
|
||||||
|
static var CLUSTERS = matter.consolidate_clusters(_class, {
|
||||||
|
0x0045: [0], # Boolean State p.70 - no writable
|
||||||
|
})
|
||||||
|
# MATTER_WATER_LEAK_DETECTOR_DEVICE_TYPE_ID 0x0043
|
||||||
|
static var TYPES = { 0x0043: 1 } # Waterleak Sensor, rev 1
|
||||||
|
|
||||||
|
var tasmota_switch_index # Switch number in Tasmota (one based)
|
||||||
|
var shadow_leak
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# Constructor
|
||||||
|
def init(device, endpoint, config)
|
||||||
|
super(self).init(device, endpoint, config)
|
||||||
|
self.shadow_leak = false
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# parse_configuration
|
||||||
|
#
|
||||||
|
# Parse configuration map
|
||||||
|
def parse_configuration(config)
|
||||||
|
self.tasmota_switch_index = int(config.find(self.ARG #-'switch'-#, 1))
|
||||||
|
if self.tasmota_switch_index <= 0 self.tasmota_switch_index = 1 end
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# Update shadow
|
||||||
|
#
|
||||||
|
def update_shadow()
|
||||||
|
super(self).update_shadow()
|
||||||
|
if !self.VIRTUAL
|
||||||
|
var switch_str = "Switch" + str(self.tasmota_switch_index)
|
||||||
|
|
||||||
|
var j = tasmota.cmd("Status 8", true)
|
||||||
|
if j != nil j = j.find("StatusSNS") end
|
||||||
|
if j != nil && j.contains(switch_str)
|
||||||
|
var state = (j.find(switch_str) == "ON")
|
||||||
|
|
||||||
|
if (self.shadow_leak != state)
|
||||||
|
self.attribute_updated(0x0045, 0x0000)
|
||||||
|
end
|
||||||
|
self.shadow_leak = state
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# read an attribute
|
||||||
|
#
|
||||||
|
def read_attribute(session, ctx, tlv_solo)
|
||||||
|
var TLV = matter.TLV
|
||||||
|
var cluster = ctx.cluster
|
||||||
|
var attribute = ctx.attribute
|
||||||
|
|
||||||
|
# ====================================================================================================
|
||||||
|
if cluster == 0x0045 # ========== Boolean State ==========
|
||||||
|
if attribute == 0x0000 # ---------- StateValue / bool ----------
|
||||||
|
if self.shadow_leak != nil
|
||||||
|
return tlv_solo.set(TLV.BOOL, self.shadow_leak)
|
||||||
|
else
|
||||||
|
return tlv_solo.set(TLV.NULL, nil)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
return super(self).read_attribute(session, ctx, tlv_solo)
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# update_virtual
|
||||||
|
#
|
||||||
|
# Update internal state for virtual devices
|
||||||
|
def update_virtual(payload_json)
|
||||||
|
var val_onoff = payload_json.find("Waterleak")
|
||||||
|
if val_onoff != nil
|
||||||
|
val_onoff = bool(val_onoff)
|
||||||
|
if self.shadow_leak != val_onoff
|
||||||
|
self.attribute_updated(0x0045, 0x0000)
|
||||||
|
self.shadow_leak = val_onoff
|
||||||
|
end
|
||||||
|
end
|
||||||
|
super(self).update_virtual(payload_json)
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
matter.Plugin_Sensor_Waterleak = Matter_Plugin_Sensor_Waterleak
|
|
@ -0,0 +1,110 @@
|
||||||
|
#
|
||||||
|
# Matter_Plugin_Bridge_Sensor_Waterleak.be - implements Waterleak Sensor via HTTP to Tasmota
|
||||||
|
#
|
||||||
|
# Copyright (C) 2024 Stephan Hadinger & Theo Arends
|
||||||
|
#
|
||||||
|
# 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 <http://www.gnu.org/licenses/>.
|
||||||
|
#
|
||||||
|
|
||||||
|
import matter
|
||||||
|
|
||||||
|
# Matter plug-in for core behavior
|
||||||
|
|
||||||
|
#@ solidify:Matter_Plugin_Bridge_Sensor_Waterleak,weak
|
||||||
|
|
||||||
|
class Matter_Plugin_Bridge_Sensor_Waterleak : Matter_Plugin_Bridge_HTTP
|
||||||
|
static var TYPE = "http_waterleak" # name of the plug-in in json
|
||||||
|
static var DISPLAY_NAME = "Waterleak" # display name of the plug-in
|
||||||
|
static var ARG = "switch" # additional argument name (or empty if none)
|
||||||
|
static var ARG_HINT = "Switch<x> number"
|
||||||
|
static var ARG_TYPE = / x -> int(x) # function to convert argument to the right type
|
||||||
|
static var UPDATE_TIME = 5000 # update every 5s
|
||||||
|
static var UPDATE_CMD = "Status 8" # command to send for updates
|
||||||
|
|
||||||
|
static var CLUSTERS = matter.consolidate_clusters(_class, {
|
||||||
|
0x0045: [0], # Boolean State p.70 - no writable
|
||||||
|
})
|
||||||
|
static var TYPES = { 0x0043: 1 } # Waterleak Sensor, rev 1
|
||||||
|
|
||||||
|
var tasmota_switch_index # Switch number in Tasmota (one based)
|
||||||
|
var shadow_Waterleak
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# Constructor
|
||||||
|
def init(device, endpoint, arguments)
|
||||||
|
super(self).init(device, endpoint, arguments)
|
||||||
|
self.tasmota_switch_index = int(arguments.find(self.ARG #-'switch'-#, 1))
|
||||||
|
if self.tasmota_switch_index <= 0 self.tasmota_switch_index = 1 end
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# Stub for updating shadow values (local copies of what we published to the Matter gateway)
|
||||||
|
#
|
||||||
|
# This call is synnchronous and blocking.
|
||||||
|
def parse_update(data, index)
|
||||||
|
if index == 8 # Status 8
|
||||||
|
var state = false
|
||||||
|
|
||||||
|
state = (data.find("Switch" + str(self.tasmota_switch_index)) == "ON")
|
||||||
|
|
||||||
|
if self.shadow_Waterleak != nil && self.shadow_Waterleak != bool(state)
|
||||||
|
self.attribute_updated(0x0045, 0x0000)
|
||||||
|
end
|
||||||
|
self.shadow_Waterleak = state
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# read an attribute
|
||||||
|
#
|
||||||
|
def read_attribute(session, ctx, tlv_solo)
|
||||||
|
var TLV = matter.TLV
|
||||||
|
var cluster = ctx.cluster
|
||||||
|
var attribute = ctx.attribute
|
||||||
|
|
||||||
|
# ====================================================================================================
|
||||||
|
if cluster == 0x0045 # ========== Boolean State ==========
|
||||||
|
if attribute == 0x0000 # ---------- StateValue / bool ----------
|
||||||
|
if self.shadow_Waterleak != nil
|
||||||
|
return tlv_solo.set(TLV.BOOL, self.shadow_Waterleak)
|
||||||
|
else
|
||||||
|
return tlv_solo.set(TLV.NULL, nil)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
return super(self).read_attribute(session, ctx, tlv_solo)
|
||||||
|
end
|
||||||
|
|
||||||
|
#############################################################
|
||||||
|
# web_values
|
||||||
|
#
|
||||||
|
# Show values of the remote device as HTML
|
||||||
|
def web_values()
|
||||||
|
import webserver
|
||||||
|
self.web_values_prefix() # display '| ' and name if present
|
||||||
|
webserver.content_send(format("Waterleak%i %s", self.tasmota_switch_index, self.web_value_onoff(self.shadow_Waterleak)))
|
||||||
|
end
|
||||||
|
|
||||||
|
# Show prefix before web value
|
||||||
|
def web_values_prefix()
|
||||||
|
import webserver
|
||||||
|
var name = self.get_name()
|
||||||
|
if !name
|
||||||
|
name = "Switch" + str(self.tasmota_switch_index)
|
||||||
|
end
|
||||||
|
webserver.content_send(format(self.PREFIX, name ? webserver.html_escape(name) : ""))
|
||||||
|
end
|
||||||
|
end
|
||||||
|
matter.Plugin_Bridge_Sensor_Waterleak = Matter_Plugin_Bridge_Sensor_Waterleak
|
|
@ -0,0 +1,35 @@
|
||||||
|
|
||||||
|
#
|
||||||
|
# Matter_Plugin_9_Virt_Sensor_Waterleak.be - implements the behavior for a Virtual Waterleak Sensor
|
||||||
|
#
|
||||||
|
# Copyright (C) 2024 Stephan Hadinger & Theo Arends
|
||||||
|
#
|
||||||
|
# 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 <http://www.gnu.org/licenses/>.
|
||||||
|
#
|
||||||
|
|
||||||
|
import matter
|
||||||
|
|
||||||
|
# Matter plug-in for core behavior
|
||||||
|
|
||||||
|
#@ solidify:Matter_Plugin_Virt_Sensor_Waterleak ,weak
|
||||||
|
|
||||||
|
class Matter_Plugin_Virt_Sensor_Waterleak : Matter_Plugin_Virt_Sensor_Waterleak
|
||||||
|
static var TYPE = "v_waterleak" # name of the plug-in in json
|
||||||
|
static var DISPLAY_NAME = "v.Waterleak" # display name of the plug-in
|
||||||
|
static var ARG = "" # no arg for virtual device
|
||||||
|
static var ARG_HINT = "_Not used_" # Hint for entering the Argument (inside 'placeholder')
|
||||||
|
static var VIRTUAL = true # virtual device
|
||||||
|
|
||||||
|
end
|
||||||
|
matter.Plugin_Virt_Sensor_Waterleak = Matter_Plugin_Virt_Sensor_Waterleak
|
|
@ -33,12 +33,12 @@ import matter
|
||||||
#################################################################################
|
#################################################################################
|
||||||
class Matter_UI
|
class Matter_UI
|
||||||
static var _CLASSES_TYPES = "|relay|light0|light1|light2|light3|shutter|shutter+tilt"
|
static var _CLASSES_TYPES = "|relay|light0|light1|light2|light3|shutter|shutter+tilt"
|
||||||
"|temperature|pressure|illuminance|humidity|occupancy|onoff|contact|flow"
|
"|temperature|pressure|illuminance|humidity|occupancy|onoff|contact|flow|waterleak"
|
||||||
"|-virtual|v_relay|v_light0|v_light1|v_light2|v_light3"
|
"|-virtual|v_relay|v_light0|v_light1|v_light2|v_light3"
|
||||||
"|v_temp|v_pressure|v_illuminance|v_humidity|v_occupancy|v_contact|v_flow"
|
"|v_temp|v_pressure|v_illuminance|v_humidity|v_occupancy|v_contact|v_flow|v_waterleak"
|
||||||
static var _CLASSES_TYPES2= "|http_relay|http_light0|http_light1|http_light2|http_light3"
|
static var _CLASSES_TYPES2= "|http_relay|http_light0|http_light1|http_light2|http_light3"
|
||||||
"|http_temperature|http_pressure|http_illuminance|http_humidity"
|
"|http_temperature|http_pressure|http_illuminance|http_humidity"
|
||||||
"|http_occupancy|http_contact|http_flow"
|
"|http_occupancy|http_contact|http_flow|http_waterleak"
|
||||||
var device
|
var device
|
||||||
|
|
||||||
# ####################################################################################################
|
# ####################################################################################################
|
||||||
|
|
|
@ -0,0 +1,444 @@
|
||||||
|
/* Solidification of Matter_Plugin_2_Sensor_Waterleak.h */
|
||||||
|
/********************************************************************\
|
||||||
|
* Generated code, don't edit *
|
||||||
|
\********************************************************************/
|
||||||
|
#include "be_constobj.h"
|
||||||
|
|
||||||
|
extern const bclass be_class_Matter_Plugin_Sensor_Waterleak;
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: <lambda>
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Sensor_Waterleak__X3Clambda_X3E, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
3, /* nstack */
|
||||||
|
1, /* argc */
|
||||||
|
0, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
0, /* has constants */
|
||||||
|
NULL, /* no const */
|
||||||
|
be_str_weak(_X3Clambda_X3E),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[ 4]) { /* code */
|
||||||
|
0x60040009, // 0000 GETGBL R1 G9
|
||||||
|
0x5C080000, // 0001 MOVE R2 R0
|
||||||
|
0x7C040200, // 0002 CALL R1 1
|
||||||
|
0x80040200, // 0003 RET 1 R1
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: init
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Sensor_Waterleak_init, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
9, /* nstack */
|
||||||
|
4, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 2]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(init),
|
||||||
|
/* K1 */ be_nested_str_weak(shadow_leak),
|
||||||
|
}),
|
||||||
|
be_str_weak(init),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[11]) { /* code */
|
||||||
|
0x60100003, // 0000 GETGBL R4 G3
|
||||||
|
0x5C140000, // 0001 MOVE R5 R0
|
||||||
|
0x7C100200, // 0002 CALL R4 1
|
||||||
|
0x8C100900, // 0003 GETMET R4 R4 K0
|
||||||
|
0x5C180200, // 0004 MOVE R6 R1
|
||||||
|
0x5C1C0400, // 0005 MOVE R7 R2
|
||||||
|
0x5C200600, // 0006 MOVE R8 R3
|
||||||
|
0x7C100800, // 0007 CALL R4 4
|
||||||
|
0x50100000, // 0008 LDBOOL R4 0 0
|
||||||
|
0x90020204, // 0009 SETMBR R0 K1 R4
|
||||||
|
0x80000000, // 000A RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: update_shadow
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Sensor_Waterleak_update_shadow, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
8, /* nstack */
|
||||||
|
1, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[14]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(update_shadow),
|
||||||
|
/* K1 */ be_nested_str_weak(VIRTUAL),
|
||||||
|
/* K2 */ be_nested_str_weak(Switch),
|
||||||
|
/* K3 */ be_nested_str_weak(tasmota_switch_index),
|
||||||
|
/* K4 */ be_nested_str_weak(tasmota),
|
||||||
|
/* K5 */ be_nested_str_weak(cmd),
|
||||||
|
/* K6 */ be_nested_str_weak(Status_X208),
|
||||||
|
/* K7 */ be_nested_str_weak(find),
|
||||||
|
/* K8 */ be_nested_str_weak(StatusSNS),
|
||||||
|
/* K9 */ be_nested_str_weak(contains),
|
||||||
|
/* K10 */ be_nested_str_weak(ON),
|
||||||
|
/* K11 */ be_nested_str_weak(shadow_leak),
|
||||||
|
/* K12 */ be_nested_str_weak(attribute_updated),
|
||||||
|
/* K13 */ be_const_int(0),
|
||||||
|
}),
|
||||||
|
be_str_weak(update_shadow),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[43]) { /* code */
|
||||||
|
0x60040003, // 0000 GETGBL R1 G3
|
||||||
|
0x5C080000, // 0001 MOVE R2 R0
|
||||||
|
0x7C040200, // 0002 CALL R1 1
|
||||||
|
0x8C040300, // 0003 GETMET R1 R1 K0
|
||||||
|
0x7C040200, // 0004 CALL R1 1
|
||||||
|
0x88040101, // 0005 GETMBR R1 R0 K1
|
||||||
|
0x74060022, // 0006 JMPT R1 #002A
|
||||||
|
0x60040008, // 0007 GETGBL R1 G8
|
||||||
|
0x88080103, // 0008 GETMBR R2 R0 K3
|
||||||
|
0x7C040200, // 0009 CALL R1 1
|
||||||
|
0x00060401, // 000A ADD R1 K2 R1
|
||||||
|
0xB80A0800, // 000B GETNGBL R2 K4
|
||||||
|
0x8C080505, // 000C GETMET R2 R2 K5
|
||||||
|
0x58100006, // 000D LDCONST R4 K6
|
||||||
|
0x50140200, // 000E LDBOOL R5 1 0
|
||||||
|
0x7C080600, // 000F CALL R2 3
|
||||||
|
0x4C0C0000, // 0010 LDNIL R3
|
||||||
|
0x200C0403, // 0011 NE R3 R2 R3
|
||||||
|
0x780E0003, // 0012 JMPF R3 #0017
|
||||||
|
0x8C0C0507, // 0013 GETMET R3 R2 K7
|
||||||
|
0x58140008, // 0014 LDCONST R5 K8
|
||||||
|
0x7C0C0400, // 0015 CALL R3 2
|
||||||
|
0x5C080600, // 0016 MOVE R2 R3
|
||||||
|
0x4C0C0000, // 0017 LDNIL R3
|
||||||
|
0x200C0403, // 0018 NE R3 R2 R3
|
||||||
|
0x780E000F, // 0019 JMPF R3 #002A
|
||||||
|
0x8C0C0509, // 001A GETMET R3 R2 K9
|
||||||
|
0x5C140200, // 001B MOVE R5 R1
|
||||||
|
0x7C0C0400, // 001C CALL R3 2
|
||||||
|
0x780E000B, // 001D JMPF R3 #002A
|
||||||
|
0x8C0C0507, // 001E GETMET R3 R2 K7
|
||||||
|
0x5C140200, // 001F MOVE R5 R1
|
||||||
|
0x7C0C0400, // 0020 CALL R3 2
|
||||||
|
0x1C0C070A, // 0021 EQ R3 R3 K10
|
||||||
|
0x8810010B, // 0022 GETMBR R4 R0 K11
|
||||||
|
0x20100803, // 0023 NE R4 R4 R3
|
||||||
|
0x78120003, // 0024 JMPF R4 #0029
|
||||||
|
0x8C10010C, // 0025 GETMET R4 R0 K12
|
||||||
|
0x541A0044, // 0026 LDINT R6 69
|
||||||
|
0x581C000D, // 0027 LDCONST R7 K13
|
||||||
|
0x7C100600, // 0028 CALL R4 3
|
||||||
|
0x90021603, // 0029 SETMBR R0 K11 R3
|
||||||
|
0x80000000, // 002A RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: parse_configuration
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Sensor_Waterleak_parse_configuration, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
7, /* nstack */
|
||||||
|
2, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 5]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(tasmota_switch_index),
|
||||||
|
/* K1 */ be_nested_str_weak(find),
|
||||||
|
/* K2 */ be_nested_str_weak(ARG),
|
||||||
|
/* K3 */ be_const_int(1),
|
||||||
|
/* K4 */ be_const_int(0),
|
||||||
|
}),
|
||||||
|
be_str_weak(parse_configuration),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[12]) { /* code */
|
||||||
|
0x60080009, // 0000 GETGBL R2 G9
|
||||||
|
0x8C0C0301, // 0001 GETMET R3 R1 K1
|
||||||
|
0x88140102, // 0002 GETMBR R5 R0 K2
|
||||||
|
0x58180003, // 0003 LDCONST R6 K3
|
||||||
|
0x7C0C0600, // 0004 CALL R3 3
|
||||||
|
0x7C080200, // 0005 CALL R2 1
|
||||||
|
0x90020002, // 0006 SETMBR R0 K0 R2
|
||||||
|
0x88080100, // 0007 GETMBR R2 R0 K0
|
||||||
|
0x18080504, // 0008 LE R2 R2 K4
|
||||||
|
0x780A0000, // 0009 JMPF R2 #000B
|
||||||
|
0x90020103, // 000A SETMBR R0 K0 K3
|
||||||
|
0x80000000, // 000B RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: read_attribute
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Sensor_Waterleak_read_attribute, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
12, /* nstack */
|
||||||
|
4, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[10]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(matter),
|
||||||
|
/* K1 */ be_nested_str_weak(TLV),
|
||||||
|
/* K2 */ be_nested_str_weak(cluster),
|
||||||
|
/* K3 */ be_nested_str_weak(attribute),
|
||||||
|
/* K4 */ be_const_int(0),
|
||||||
|
/* K5 */ be_nested_str_weak(shadow_leak),
|
||||||
|
/* K6 */ be_nested_str_weak(set),
|
||||||
|
/* K7 */ be_nested_str_weak(BOOL),
|
||||||
|
/* K8 */ be_nested_str_weak(NULL),
|
||||||
|
/* K9 */ be_nested_str_weak(read_attribute),
|
||||||
|
}),
|
||||||
|
be_str_weak(read_attribute),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[33]) { /* code */
|
||||||
|
0xB8120000, // 0000 GETNGBL R4 K0
|
||||||
|
0x88100901, // 0001 GETMBR R4 R4 K1
|
||||||
|
0x88140502, // 0002 GETMBR R5 R2 K2
|
||||||
|
0x88180503, // 0003 GETMBR R6 R2 K3
|
||||||
|
0x541E0044, // 0004 LDINT R7 69
|
||||||
|
0x1C1C0A07, // 0005 EQ R7 R5 R7
|
||||||
|
0x781E0010, // 0006 JMPF R7 #0018
|
||||||
|
0x1C1C0D04, // 0007 EQ R7 R6 K4
|
||||||
|
0x781E000E, // 0008 JMPF R7 #0018
|
||||||
|
0x881C0105, // 0009 GETMBR R7 R0 K5
|
||||||
|
0x4C200000, // 000A LDNIL R8
|
||||||
|
0x201C0E08, // 000B NE R7 R7 R8
|
||||||
|
0x781E0005, // 000C JMPF R7 #0013
|
||||||
|
0x8C1C0706, // 000D GETMET R7 R3 K6
|
||||||
|
0x88240907, // 000E GETMBR R9 R4 K7
|
||||||
|
0x88280105, // 000F GETMBR R10 R0 K5
|
||||||
|
0x7C1C0600, // 0010 CALL R7 3
|
||||||
|
0x80040E00, // 0011 RET 1 R7
|
||||||
|
0x70020004, // 0012 JMP #0018
|
||||||
|
0x8C1C0706, // 0013 GETMET R7 R3 K6
|
||||||
|
0x88240908, // 0014 GETMBR R9 R4 K8
|
||||||
|
0x4C280000, // 0015 LDNIL R10
|
||||||
|
0x7C1C0600, // 0016 CALL R7 3
|
||||||
|
0x80040E00, // 0017 RET 1 R7
|
||||||
|
0x601C0003, // 0018 GETGBL R7 G3
|
||||||
|
0x5C200000, // 0019 MOVE R8 R0
|
||||||
|
0x7C1C0200, // 001A CALL R7 1
|
||||||
|
0x8C1C0F09, // 001B GETMET R7 R7 K9
|
||||||
|
0x5C240200, // 001C MOVE R9 R1
|
||||||
|
0x5C280400, // 001D MOVE R10 R2
|
||||||
|
0x5C2C0600, // 001E MOVE R11 R3
|
||||||
|
0x7C1C0800, // 001F CALL R7 4
|
||||||
|
0x80040E00, // 0020 RET 1 R7
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: update_virtual
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Sensor_Waterleak_update_virtual, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
7, /* nstack */
|
||||||
|
2, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 6]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(find),
|
||||||
|
/* K1 */ be_nested_str_weak(Waterleak),
|
||||||
|
/* K2 */ be_nested_str_weak(shadow_leak),
|
||||||
|
/* K3 */ be_nested_str_weak(attribute_updated),
|
||||||
|
/* K4 */ be_const_int(0),
|
||||||
|
/* K5 */ be_nested_str_weak(update_virtual),
|
||||||
|
}),
|
||||||
|
be_str_weak(update_virtual),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[25]) { /* code */
|
||||||
|
0x8C080300, // 0000 GETMET R2 R1 K0
|
||||||
|
0x58100001, // 0001 LDCONST R4 K1
|
||||||
|
0x7C080400, // 0002 CALL R2 2
|
||||||
|
0x4C0C0000, // 0003 LDNIL R3
|
||||||
|
0x200C0403, // 0004 NE R3 R2 R3
|
||||||
|
0x780E000B, // 0005 JMPF R3 #0012
|
||||||
|
0x600C0017, // 0006 GETGBL R3 G23
|
||||||
|
0x5C100400, // 0007 MOVE R4 R2
|
||||||
|
0x7C0C0200, // 0008 CALL R3 1
|
||||||
|
0x5C080600, // 0009 MOVE R2 R3
|
||||||
|
0x880C0102, // 000A GETMBR R3 R0 K2
|
||||||
|
0x200C0602, // 000B NE R3 R3 R2
|
||||||
|
0x780E0004, // 000C JMPF R3 #0012
|
||||||
|
0x8C0C0103, // 000D GETMET R3 R0 K3
|
||||||
|
0x54160044, // 000E LDINT R5 69
|
||||||
|
0x58180004, // 000F LDCONST R6 K4
|
||||||
|
0x7C0C0600, // 0010 CALL R3 3
|
||||||
|
0x90020402, // 0011 SETMBR R0 K2 R2
|
||||||
|
0x600C0003, // 0012 GETGBL R3 G3
|
||||||
|
0x5C100000, // 0013 MOVE R4 R0
|
||||||
|
0x7C0C0200, // 0014 CALL R3 1
|
||||||
|
0x8C0C0705, // 0015 GETMET R3 R3 K5
|
||||||
|
0x5C140200, // 0016 MOVE R5 R1
|
||||||
|
0x7C0C0400, // 0017 CALL R3 2
|
||||||
|
0x80000000, // 0018 RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified class: Matter_Plugin_Sensor_Waterleak
|
||||||
|
********************************************************************/
|
||||||
|
extern const bclass be_class_Matter_Plugin_Device;
|
||||||
|
be_local_class(Matter_Plugin_Sensor_Waterleak,
|
||||||
|
2,
|
||||||
|
&be_class_Matter_Plugin_Device,
|
||||||
|
be_nested_map(16,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key_weak(ARG_TYPE, 2), be_const_static_closure(Matter_Plugin_Sensor_Waterleak__X3Clambda_X3E_closure) },
|
||||||
|
{ be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Switch_X3Cx_X3E_X20number) },
|
||||||
|
{ be_const_key_weak(update_virtual, -1), be_const_closure(Matter_Plugin_Sensor_Waterleak_update_virtual_closure) },
|
||||||
|
{ be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_Sensor_Waterleak_init_closure) },
|
||||||
|
{ be_const_key_weak(shadow_leak, 15), be_const_var(1) },
|
||||||
|
{ be_const_key_weak(update_shadow, 4), be_const_closure(Matter_Plugin_Sensor_Waterleak_update_shadow_closure) },
|
||||||
|
{ be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Waterleak) },
|
||||||
|
{ be_const_key_weak(ARG, 11), be_nested_str_weak(switch) },
|
||||||
|
{ be_const_key_weak(UPDATE_TIME, -1), be_const_int(750) },
|
||||||
|
{ be_const_key_weak(CLUSTERS, 12), be_const_simple_instance(be_nested_simple_instance(&be_class_map, {
|
||||||
|
be_const_map( * be_nested_map(6,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key_int(5, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(12,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(1),
|
||||||
|
be_const_int(2),
|
||||||
|
be_const_int(3),
|
||||||
|
be_const_int(4),
|
||||||
|
be_const_int(5),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(3, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(8,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(1),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(57, 1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(12,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(3),
|
||||||
|
be_const_int(5),
|
||||||
|
be_const_int(10),
|
||||||
|
be_const_int(15),
|
||||||
|
be_const_int(17),
|
||||||
|
be_const_int(18),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(69, 2), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(7,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(4, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(7,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(29, 0), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(10,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(1),
|
||||||
|
be_const_int(2),
|
||||||
|
be_const_int(3),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_weak(tasmota_switch_index, 9), be_const_var(0) },
|
||||||
|
{ be_const_key_weak(UPDATE_COMMANDS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(1,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_nested_str_weak(Waterleak),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_weak(read_attribute, 14), be_const_closure(Matter_Plugin_Sensor_Waterleak_read_attribute_closure) },
|
||||||
|
{ be_const_key_weak(TYPE, 6), be_nested_str_weak(waterleak) },
|
||||||
|
{ be_const_key_weak(TYPES, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_map, {
|
||||||
|
be_const_map( * be_nested_map(1,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key_int(67, -1), be_const_int(1) },
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_weak(parse_configuration, -1), be_const_closure(Matter_Plugin_Sensor_Waterleak_parse_configuration_closure) },
|
||||||
|
})),
|
||||||
|
be_str_weak(Matter_Plugin_Sensor_Waterleak)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
void be_load_Matter_Plugin_Sensor_Waterleak_class(bvm *vm) {
|
||||||
|
be_pushntvclass(vm, &be_class_Matter_Plugin_Sensor_Waterleak);
|
||||||
|
be_setglobal(vm, "Matter_Plugin_Sensor_Waterleak");
|
||||||
|
be_pop(vm, 1);
|
||||||
|
}
|
||||||
|
/********************************************************************/
|
||||||
|
/* End of solidification */
|
|
@ -0,0 +1,433 @@
|
||||||
|
/* Solidification of Matter_Plugin_3_Bridge_Sensor_Waterleak.h */
|
||||||
|
/********************************************************************\
|
||||||
|
* Generated code, don't edit *
|
||||||
|
\********************************************************************/
|
||||||
|
#include "be_constobj.h"
|
||||||
|
|
||||||
|
extern const bclass be_class_Matter_Plugin_Bridge_Sensor_Waterleak;
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: <lambda>
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Bridge_Sensor_Waterleak__X3Clambda_X3E, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
3, /* nstack */
|
||||||
|
1, /* argc */
|
||||||
|
0, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
0, /* has constants */
|
||||||
|
NULL, /* no const */
|
||||||
|
be_str_weak(_X3Clambda_X3E),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[ 4]) { /* code */
|
||||||
|
0x60040009, // 0000 GETGBL R1 G9
|
||||||
|
0x5C080000, // 0001 MOVE R2 R0
|
||||||
|
0x7C040200, // 0002 CALL R1 1
|
||||||
|
0x80040200, // 0003 RET 1 R1
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: web_values_prefix
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Bridge_Sensor_Waterleak_web_values_prefix, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
10, /* nstack */
|
||||||
|
1, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 8]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(webserver),
|
||||||
|
/* K1 */ be_nested_str_weak(get_name),
|
||||||
|
/* K2 */ be_nested_str_weak(Switch),
|
||||||
|
/* K3 */ be_nested_str_weak(tasmota_switch_index),
|
||||||
|
/* K4 */ be_nested_str_weak(content_send),
|
||||||
|
/* K5 */ be_nested_str_weak(PREFIX),
|
||||||
|
/* K6 */ be_nested_str_weak(html_escape),
|
||||||
|
/* K7 */ be_nested_str_weak(),
|
||||||
|
}),
|
||||||
|
be_str_weak(web_values_prefix),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[22]) { /* code */
|
||||||
|
0xA4060000, // 0000 IMPORT R1 K0
|
||||||
|
0x8C080101, // 0001 GETMET R2 R0 K1
|
||||||
|
0x7C080200, // 0002 CALL R2 1
|
||||||
|
0x5C0C0400, // 0003 MOVE R3 R2
|
||||||
|
0x740E0004, // 0004 JMPT R3 #000A
|
||||||
|
0x600C0008, // 0005 GETGBL R3 G8
|
||||||
|
0x88100103, // 0006 GETMBR R4 R0 K3
|
||||||
|
0x7C0C0200, // 0007 CALL R3 1
|
||||||
|
0x000E0403, // 0008 ADD R3 K2 R3
|
||||||
|
0x5C080600, // 0009 MOVE R2 R3
|
||||||
|
0x8C0C0304, // 000A GETMET R3 R1 K4
|
||||||
|
0x60140018, // 000B GETGBL R5 G24
|
||||||
|
0x88180105, // 000C GETMBR R6 R0 K5
|
||||||
|
0x780A0003, // 000D JMPF R2 #0012
|
||||||
|
0x8C1C0306, // 000E GETMET R7 R1 K6
|
||||||
|
0x5C240400, // 000F MOVE R9 R2
|
||||||
|
0x7C1C0400, // 0010 CALL R7 2
|
||||||
|
0x70020000, // 0011 JMP #0013
|
||||||
|
0x581C0007, // 0012 LDCONST R7 K7
|
||||||
|
0x7C140400, // 0013 CALL R5 2
|
||||||
|
0x7C0C0400, // 0014 CALL R3 2
|
||||||
|
0x80000000, // 0015 RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: init
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Bridge_Sensor_Waterleak_init, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
9, /* nstack */
|
||||||
|
4, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 6]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(init),
|
||||||
|
/* K1 */ be_nested_str_weak(tasmota_switch_index),
|
||||||
|
/* K2 */ be_nested_str_weak(find),
|
||||||
|
/* K3 */ be_nested_str_weak(ARG),
|
||||||
|
/* K4 */ be_const_int(1),
|
||||||
|
/* K5 */ be_const_int(0),
|
||||||
|
}),
|
||||||
|
be_str_weak(init),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[20]) { /* code */
|
||||||
|
0x60100003, // 0000 GETGBL R4 G3
|
||||||
|
0x5C140000, // 0001 MOVE R5 R0
|
||||||
|
0x7C100200, // 0002 CALL R4 1
|
||||||
|
0x8C100900, // 0003 GETMET R4 R4 K0
|
||||||
|
0x5C180200, // 0004 MOVE R6 R1
|
||||||
|
0x5C1C0400, // 0005 MOVE R7 R2
|
||||||
|
0x5C200600, // 0006 MOVE R8 R3
|
||||||
|
0x7C100800, // 0007 CALL R4 4
|
||||||
|
0x60100009, // 0008 GETGBL R4 G9
|
||||||
|
0x8C140702, // 0009 GETMET R5 R3 K2
|
||||||
|
0x881C0103, // 000A GETMBR R7 R0 K3
|
||||||
|
0x58200004, // 000B LDCONST R8 K4
|
||||||
|
0x7C140600, // 000C CALL R5 3
|
||||||
|
0x7C100200, // 000D CALL R4 1
|
||||||
|
0x90020204, // 000E SETMBR R0 K1 R4
|
||||||
|
0x88100101, // 000F GETMBR R4 R0 K1
|
||||||
|
0x18100905, // 0010 LE R4 R4 K5
|
||||||
|
0x78120000, // 0011 JMPF R4 #0013
|
||||||
|
0x90020304, // 0012 SETMBR R0 K1 K4
|
||||||
|
0x80000000, // 0013 RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: web_values
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Bridge_Sensor_Waterleak_web_values, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
10, /* nstack */
|
||||||
|
1, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 7]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(webserver),
|
||||||
|
/* K1 */ be_nested_str_weak(web_values_prefix),
|
||||||
|
/* K2 */ be_nested_str_weak(content_send),
|
||||||
|
/* K3 */ be_nested_str_weak(Waterleak_X25i_X20_X25s),
|
||||||
|
/* K4 */ be_nested_str_weak(tasmota_switch_index),
|
||||||
|
/* K5 */ be_nested_str_weak(web_value_onoff),
|
||||||
|
/* K6 */ be_nested_str_weak(shadow_Waterleak),
|
||||||
|
}),
|
||||||
|
be_str_weak(web_values),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[13]) { /* code */
|
||||||
|
0xA4060000, // 0000 IMPORT R1 K0
|
||||||
|
0x8C080101, // 0001 GETMET R2 R0 K1
|
||||||
|
0x7C080200, // 0002 CALL R2 1
|
||||||
|
0x8C080302, // 0003 GETMET R2 R1 K2
|
||||||
|
0x60100018, // 0004 GETGBL R4 G24
|
||||||
|
0x58140003, // 0005 LDCONST R5 K3
|
||||||
|
0x88180104, // 0006 GETMBR R6 R0 K4
|
||||||
|
0x8C1C0105, // 0007 GETMET R7 R0 K5
|
||||||
|
0x88240106, // 0008 GETMBR R9 R0 K6
|
||||||
|
0x7C1C0400, // 0009 CALL R7 2
|
||||||
|
0x7C100600, // 000A CALL R4 3
|
||||||
|
0x7C080400, // 000B CALL R2 2
|
||||||
|
0x80000000, // 000C RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: parse_update
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Bridge_Sensor_Waterleak_parse_update, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
8, /* nstack */
|
||||||
|
3, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[ 7]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(find),
|
||||||
|
/* K1 */ be_nested_str_weak(Switch),
|
||||||
|
/* K2 */ be_nested_str_weak(tasmota_switch_index),
|
||||||
|
/* K3 */ be_nested_str_weak(ON),
|
||||||
|
/* K4 */ be_nested_str_weak(shadow_Waterleak),
|
||||||
|
/* K5 */ be_nested_str_weak(attribute_updated),
|
||||||
|
/* K6 */ be_const_int(0),
|
||||||
|
}),
|
||||||
|
be_str_weak(parse_update),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[28]) { /* code */
|
||||||
|
0x540E0007, // 0000 LDINT R3 8
|
||||||
|
0x1C0C0403, // 0001 EQ R3 R2 R3
|
||||||
|
0x780E0017, // 0002 JMPF R3 #001B
|
||||||
|
0x500C0000, // 0003 LDBOOL R3 0 0
|
||||||
|
0x8C100300, // 0004 GETMET R4 R1 K0
|
||||||
|
0x60180008, // 0005 GETGBL R6 G8
|
||||||
|
0x881C0102, // 0006 GETMBR R7 R0 K2
|
||||||
|
0x7C180200, // 0007 CALL R6 1
|
||||||
|
0x001A0206, // 0008 ADD R6 K1 R6
|
||||||
|
0x7C100400, // 0009 CALL R4 2
|
||||||
|
0x1C100903, // 000A EQ R4 R4 K3
|
||||||
|
0x5C0C0800, // 000B MOVE R3 R4
|
||||||
|
0x88100104, // 000C GETMBR R4 R0 K4
|
||||||
|
0x4C140000, // 000D LDNIL R5
|
||||||
|
0x20100805, // 000E NE R4 R4 R5
|
||||||
|
0x78120009, // 000F JMPF R4 #001A
|
||||||
|
0x88100104, // 0010 GETMBR R4 R0 K4
|
||||||
|
0x60140017, // 0011 GETGBL R5 G23
|
||||||
|
0x5C180600, // 0012 MOVE R6 R3
|
||||||
|
0x7C140200, // 0013 CALL R5 1
|
||||||
|
0x20100805, // 0014 NE R4 R4 R5
|
||||||
|
0x78120003, // 0015 JMPF R4 #001A
|
||||||
|
0x8C100105, // 0016 GETMET R4 R0 K5
|
||||||
|
0x541A0044, // 0017 LDINT R6 69
|
||||||
|
0x581C0006, // 0018 LDCONST R7 K6
|
||||||
|
0x7C100600, // 0019 CALL R4 3
|
||||||
|
0x90020803, // 001A SETMBR R0 K4 R3
|
||||||
|
0x80000000, // 001B RET 0
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified function: read_attribute
|
||||||
|
********************************************************************/
|
||||||
|
be_local_closure(Matter_Plugin_Bridge_Sensor_Waterleak_read_attribute, /* name */
|
||||||
|
be_nested_proto(
|
||||||
|
12, /* nstack */
|
||||||
|
4, /* argc */
|
||||||
|
2, /* varg */
|
||||||
|
0, /* has upvals */
|
||||||
|
NULL, /* no upvals */
|
||||||
|
0, /* has sup protos */
|
||||||
|
NULL, /* no sub protos */
|
||||||
|
1, /* has constants */
|
||||||
|
( &(const bvalue[10]) { /* constants */
|
||||||
|
/* K0 */ be_nested_str_weak(matter),
|
||||||
|
/* K1 */ be_nested_str_weak(TLV),
|
||||||
|
/* K2 */ be_nested_str_weak(cluster),
|
||||||
|
/* K3 */ be_nested_str_weak(attribute),
|
||||||
|
/* K4 */ be_const_int(0),
|
||||||
|
/* K5 */ be_nested_str_weak(shadow_Waterleak),
|
||||||
|
/* K6 */ be_nested_str_weak(set),
|
||||||
|
/* K7 */ be_nested_str_weak(BOOL),
|
||||||
|
/* K8 */ be_nested_str_weak(NULL),
|
||||||
|
/* K9 */ be_nested_str_weak(read_attribute),
|
||||||
|
}),
|
||||||
|
be_str_weak(read_attribute),
|
||||||
|
&be_const_str_solidified,
|
||||||
|
( &(const binstruction[33]) { /* code */
|
||||||
|
0xB8120000, // 0000 GETNGBL R4 K0
|
||||||
|
0x88100901, // 0001 GETMBR R4 R4 K1
|
||||||
|
0x88140502, // 0002 GETMBR R5 R2 K2
|
||||||
|
0x88180503, // 0003 GETMBR R6 R2 K3
|
||||||
|
0x541E0044, // 0004 LDINT R7 69
|
||||||
|
0x1C1C0A07, // 0005 EQ R7 R5 R7
|
||||||
|
0x781E0010, // 0006 JMPF R7 #0018
|
||||||
|
0x1C1C0D04, // 0007 EQ R7 R6 K4
|
||||||
|
0x781E000E, // 0008 JMPF R7 #0018
|
||||||
|
0x881C0105, // 0009 GETMBR R7 R0 K5
|
||||||
|
0x4C200000, // 000A LDNIL R8
|
||||||
|
0x201C0E08, // 000B NE R7 R7 R8
|
||||||
|
0x781E0005, // 000C JMPF R7 #0013
|
||||||
|
0x8C1C0706, // 000D GETMET R7 R3 K6
|
||||||
|
0x88240907, // 000E GETMBR R9 R4 K7
|
||||||
|
0x88280105, // 000F GETMBR R10 R0 K5
|
||||||
|
0x7C1C0600, // 0010 CALL R7 3
|
||||||
|
0x80040E00, // 0011 RET 1 R7
|
||||||
|
0x70020004, // 0012 JMP #0018
|
||||||
|
0x8C1C0706, // 0013 GETMET R7 R3 K6
|
||||||
|
0x88240908, // 0014 GETMBR R9 R4 K8
|
||||||
|
0x4C280000, // 0015 LDNIL R10
|
||||||
|
0x7C1C0600, // 0016 CALL R7 3
|
||||||
|
0x80040E00, // 0017 RET 1 R7
|
||||||
|
0x601C0003, // 0018 GETGBL R7 G3
|
||||||
|
0x5C200000, // 0019 MOVE R8 R0
|
||||||
|
0x7C1C0200, // 001A CALL R7 1
|
||||||
|
0x8C1C0F09, // 001B GETMET R7 R7 K9
|
||||||
|
0x5C240200, // 001C MOVE R9 R1
|
||||||
|
0x5C280400, // 001D MOVE R10 R2
|
||||||
|
0x5C2C0600, // 001E MOVE R11 R3
|
||||||
|
0x7C1C0800, // 001F CALL R7 4
|
||||||
|
0x80040E00, // 0020 RET 1 R7
|
||||||
|
})
|
||||||
|
)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified class: Matter_Plugin_Bridge_Sensor_Waterleak
|
||||||
|
********************************************************************/
|
||||||
|
extern const bclass be_class_Matter_Plugin_Bridge_HTTP;
|
||||||
|
be_local_class(Matter_Plugin_Bridge_Sensor_Waterleak,
|
||||||
|
2,
|
||||||
|
&be_class_Matter_Plugin_Bridge_HTTP,
|
||||||
|
be_nested_map(16,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key_weak(ARG_TYPE, 4), be_const_static_closure(Matter_Plugin_Bridge_Sensor_Waterleak__X3Clambda_X3E_closure) },
|
||||||
|
{ be_const_key_weak(ARG_HINT, 2), be_nested_str_weak(Switch_X3Cx_X3E_X20number) },
|
||||||
|
{ be_const_key_weak(web_values_prefix, -1), be_const_closure(Matter_Plugin_Bridge_Sensor_Waterleak_web_values_prefix_closure) },
|
||||||
|
{ be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_Bridge_Sensor_Waterleak_init_closure) },
|
||||||
|
{ be_const_key_weak(web_values, -1), be_const_closure(Matter_Plugin_Bridge_Sensor_Waterleak_web_values_closure) },
|
||||||
|
{ be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Waterleak) },
|
||||||
|
{ be_const_key_weak(TYPES, 9), be_const_simple_instance(be_nested_simple_instance(&be_class_map, {
|
||||||
|
be_const_map( * be_nested_map(1,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key_int(67, -1), be_const_int(1) },
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_weak(ARG, -1), be_nested_str_weak(switch) },
|
||||||
|
{ be_const_key_weak(parse_update, 12), be_const_closure(Matter_Plugin_Bridge_Sensor_Waterleak_parse_update_closure) },
|
||||||
|
{ be_const_key_weak(CLUSTERS, 11), be_const_simple_instance(be_nested_simple_instance(&be_class_map, {
|
||||||
|
be_const_map( * be_nested_map(6,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key_int(5, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(12,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(1),
|
||||||
|
be_const_int(2),
|
||||||
|
be_const_int(3),
|
||||||
|
be_const_int(4),
|
||||||
|
be_const_int(5),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(3, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(8,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(1),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(57, 1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(12,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(3),
|
||||||
|
be_const_int(5),
|
||||||
|
be_const_int(10),
|
||||||
|
be_const_int(15),
|
||||||
|
be_const_int(17),
|
||||||
|
be_const_int(18),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(69, 2), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(7,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(4, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(7,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_int(29, 0), be_const_simple_instance(be_nested_simple_instance(&be_class_list, {
|
||||||
|
be_const_list( * be_nested_list(10,
|
||||||
|
( (struct bvalue*) &(const bvalue[]) {
|
||||||
|
be_const_int(0),
|
||||||
|
be_const_int(1),
|
||||||
|
be_const_int(2),
|
||||||
|
be_const_int(3),
|
||||||
|
be_const_int(65528),
|
||||||
|
be_const_int(65529),
|
||||||
|
be_const_int(65530),
|
||||||
|
be_const_int(65531),
|
||||||
|
be_const_int(65532),
|
||||||
|
be_const_int(65533),
|
||||||
|
})) ) } )) },
|
||||||
|
})) ) } )) },
|
||||||
|
{ be_const_key_weak(tasmota_switch_index, 6), be_const_var(0) },
|
||||||
|
{ be_const_key_weak(read_attribute, -1), be_const_closure(Matter_Plugin_Bridge_Sensor_Waterleak_read_attribute_closure) },
|
||||||
|
{ be_const_key_weak(UPDATE_TIME, -1), be_const_int(5000) },
|
||||||
|
{ be_const_key_weak(TYPE, 5), be_nested_str_weak(http_waterleak) },
|
||||||
|
{ be_const_key_weak(shadow_Waterleak, -1), be_const_var(1) },
|
||||||
|
{ be_const_key_weak(UPDATE_CMD, -1), be_nested_str_weak(Status_X208) },
|
||||||
|
})),
|
||||||
|
be_str_weak(Matter_Plugin_Bridge_Sensor_Waterleak)
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
void be_load_Matter_Plugin_Bridge_Sensor_Waterleak_class(bvm *vm) {
|
||||||
|
be_pushntvclass(vm, &be_class_Matter_Plugin_Bridge_Sensor_Waterleak);
|
||||||
|
be_setglobal(vm, "Matter_Plugin_Bridge_Sensor_Waterleak");
|
||||||
|
be_pop(vm, 1);
|
||||||
|
}
|
||||||
|
/********************************************************************/
|
||||||
|
/* End of solidification */
|
|
@ -0,0 +1,34 @@
|
||||||
|
/* Solidification of Matter_Plugin_9_Virt_Sensor_Waterleak.h */
|
||||||
|
/********************************************************************\
|
||||||
|
* Generated code, don't edit *
|
||||||
|
\********************************************************************/
|
||||||
|
#include "be_constobj.h"
|
||||||
|
|
||||||
|
extern const bclass be_class_Matter_Plugin_Virt_Sensor_Waterleak;
|
||||||
|
|
||||||
|
/********************************************************************
|
||||||
|
** Solidified class: Matter_Plugin_Virt_Sensor_Waterleak
|
||||||
|
********************************************************************/
|
||||||
|
extern const bclass be_class_Matter_Plugin_Virt_Sensor_Waterleak;
|
||||||
|
be_local_class(Matter_Plugin_Virt_Sensor_Waterleak,
|
||||||
|
0,
|
||||||
|
&be_class_Matter_Plugin_Virt_Sensor_Waterleak,
|
||||||
|
be_nested_map(5,
|
||||||
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
|
{ be_const_key(VIRTUAL, 3), be_const_bool(1) },
|
||||||
|
{ be_const_key(DISPLAY_NAME, -1), be_nested_str(v_X2EWaterleak) },
|
||||||
|
{ be_const_key(TYPE, -1), be_nested_str(v_waterleak) },
|
||||||
|
{ be_const_key(ARG_HINT, -1), be_nested_str(_Not_X20used_) },
|
||||||
|
{ be_const_key(ARG, 2), be_nested_str() },
|
||||||
|
})),
|
||||||
|
(bstring*) &be_const_str_Matter_Plugin_Virt_Sensor_Waterleak
|
||||||
|
);
|
||||||
|
/*******************************************************************/
|
||||||
|
|
||||||
|
void be_load_Matter_Plugin_Virt_Sensor_Waterleak_class(bvm *vm) {
|
||||||
|
be_pushntvclass(vm, &be_class_Matter_Plugin_Virt_Sensor_Waterleak);
|
||||||
|
be_setglobal(vm, "Matter_Plugin_Virt_Sensor_Waterleak");
|
||||||
|
be_pop(vm, 1);
|
||||||
|
}
|
||||||
|
/********************************************************************/
|
||||||
|
/* End of solidification */
|
|
@ -3383,7 +3383,7 @@ be_local_class(Matter_UI,
|
||||||
( (struct bmapnode*) &(const bmapnode[]) {
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
{ be_const_key_weak(equal_map, -1), be_const_static_closure(Matter_UI_equal_map_closure) },
|
{ be_const_key_weak(equal_map, -1), be_const_static_closure(Matter_UI_equal_map_closure) },
|
||||||
{ be_const_key_weak(page_part_mgr_adv, -1), be_const_closure(Matter_UI_page_part_mgr_adv_closure) },
|
{ be_const_key_weak(page_part_mgr_adv, -1), be_const_closure(Matter_UI_page_part_mgr_adv_closure) },
|
||||||
{ be_const_key_weak(_CLASSES_TYPES2, -1), be_nested_str_weak(_X7Chttp_relay_X7Chttp_light0_X7Chttp_light1_X7Chttp_light2_X7Chttp_light3_X7Chttp_temperature_X7Chttp_pressure_X7Chttp_illuminance_X7Chttp_humidity_X7Chttp_occupancy_X7Chttp_contact_X7Chttp_flow) },
|
{ be_const_key_weak(_CLASSES_TYPES2, -1), be_nested_str_weak(_X7Chttp_relay_X7Chttp_light0_X7Chttp_light1_X7Chttp_light2_X7Chttp_light3_X7Chttp_temperature_X7Chttp_pressure_X7Chttp_illuminance_X7Chttp_humidity_X7Chttp_occupancy_X7Chttp_contact_X7Chttp_flow_X7Chttp_waterleak) },
|
||||||
{ be_const_key_weak(page_part_mgr, 25), be_const_closure(Matter_UI_page_part_mgr_closure) },
|
{ be_const_key_weak(page_part_mgr, 25), be_const_closure(Matter_UI_page_part_mgr_closure) },
|
||||||
{ be_const_key_weak(show_plugins_hints_js, -1), be_const_closure(Matter_UI_show_plugins_hints_js_closure) },
|
{ be_const_key_weak(show_plugins_hints_js, -1), be_const_closure(Matter_UI_show_plugins_hints_js_closure) },
|
||||||
{ be_const_key_weak(show_enable, -1), be_const_closure(Matter_UI_show_enable_closure) },
|
{ be_const_key_weak(show_enable, -1), be_const_closure(Matter_UI_show_enable_closure) },
|
||||||
|
@ -3395,7 +3395,7 @@ be_local_class(Matter_UI,
|
||||||
{ be_const_key_weak(show_commissioning_info, -1), be_const_closure(Matter_UI_show_commissioning_info_closure) },
|
{ be_const_key_weak(show_commissioning_info, -1), be_const_closure(Matter_UI_show_commissioning_info_closure) },
|
||||||
{ be_const_key_weak(page_part_ctl, 18), be_const_closure(Matter_UI_page_part_ctl_closure) },
|
{ be_const_key_weak(page_part_ctl, 18), be_const_closure(Matter_UI_page_part_ctl_closure) },
|
||||||
{ be_const_key_weak(show_fabric_info, -1), be_const_closure(Matter_UI_show_fabric_info_closure) },
|
{ be_const_key_weak(show_fabric_info, -1), be_const_closure(Matter_UI_show_fabric_info_closure) },
|
||||||
{ be_const_key_weak(_CLASSES_TYPES, 4), be_nested_str_weak(_X7Crelay_X7Clight0_X7Clight1_X7Clight2_X7Clight3_X7Cshutter_X7Cshutter_X2Btilt_X7Ctemperature_X7Cpressure_X7Cilluminance_X7Chumidity_X7Coccupancy_X7Conoff_X7Ccontact_X7Cflow_X7C_X2Dvirtual_X7Cv_relay_X7Cv_light0_X7Cv_light1_X7Cv_light2_X7Cv_light3_X7Cv_temp_X7Cv_pressure_X7Cv_illuminance_X7Cv_humidity_X7Cv_occupancy_X7Cv_contact_X7Cv_flow) },
|
{ be_const_key_weak(_CLASSES_TYPES, 4), be_nested_str_long(_X7Crelay_X7Clight0_X7Clight1_X7Clight2_X7Clight3_X7Cshutter_X7Cshutter_X2Btilt_X7Ctemperature_X7Cpressure_X7Cilluminance_X7Chumidity_X7Coccupancy_X7Conoff_X7Ccontact_X7Cflow_X7Cwaterleak_X7C_X2Dvirtual_X7Cv_relay_X7Cv_light0_X7Cv_light1_X7Cv_light2_X7Cv_light3_X7Cv_temp_X7Cv_pressure_X7Cv_illuminance_X7Cv_humidity_X7Cv_occupancy_X7Cv_contact_X7Cv_flow_X7Cwaterleak) },
|
||||||
{ be_const_key_weak(web_get_arg, -1), be_const_closure(Matter_UI_web_get_arg_closure) },
|
{ be_const_key_weak(web_get_arg, -1), be_const_closure(Matter_UI_web_get_arg_closure) },
|
||||||
{ be_const_key_weak(plugin_option, 5), be_const_closure(Matter_UI_plugin_option_closure) },
|
{ be_const_key_weak(plugin_option, 5), be_const_closure(Matter_UI_plugin_option_closure) },
|
||||||
{ be_const_key_weak(web_add_config_button, -1), be_const_closure(Matter_UI_web_add_config_button_closure) },
|
{ be_const_key_weak(web_add_config_button, -1), be_const_closure(Matter_UI_web_add_config_button_closure) },
|
||||||
|
|
|
@ -6206,49 +6206,52 @@ be_local_class(Matter_Device,
|
||||||
{ be_const_key_weak(stop, 14), be_const_closure(Matter_Device_stop_closure) },
|
{ be_const_key_weak(stop, 14), be_const_closure(Matter_Device_stop_closure) },
|
||||||
{ be_const_key_weak(stop_basic_commissioning, 13), be_const_closure(Matter_Device_stop_basic_commissioning_closure) },
|
{ be_const_key_weak(stop_basic_commissioning, 13), be_const_closure(Matter_Device_stop_basic_commissioning_closure) },
|
||||||
{ be_const_key_weak(plugins_classes, 10), be_const_simple_instance(be_nested_simple_instance(&be_class_map, {
|
{ be_const_key_weak(plugins_classes, 10), be_const_simple_instance(be_nested_simple_instance(&be_class_map, {
|
||||||
be_const_map( * be_nested_map(41,
|
be_const_map( * be_nested_map(44,
|
||||||
( (struct bmapnode*) &(const bmapnode[]) {
|
( (struct bmapnode*) &(const bmapnode[]) {
|
||||||
{ be_const_key_weak(aggregator, -1), be_const_class(be_class_Matter_Plugin_Aggregator) },
|
{ be_const_key_weak(humidity, 37), be_const_class(be_class_Matter_Plugin_Sensor_Humidity) },
|
||||||
{ be_const_key_weak(light2, -1), be_const_class(be_class_Matter_Plugin_Light2) },
|
{ be_const_key_weak(flow, -1), be_const_class(be_class_Matter_Plugin_Sensor_Flow) },
|
||||||
{ be_const_key_weak(v_light1, 17), be_const_class(be_class_Matter_Plugin_Virt_Light1) },
|
|
||||||
{ be_const_key_weak(v_light3, -1), be_const_class(be_class_Matter_Plugin_Virt_Light3) },
|
|
||||||
{ be_const_key_weak(v_flow, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Flow) },
|
{ be_const_key_weak(v_flow, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Flow) },
|
||||||
{ be_const_key_weak(shutter, 14), be_const_class(be_class_Matter_Plugin_Shutter) },
|
{ be_const_key_weak(waterleak, -1), be_const_class(be_class_Matter_Plugin_Sensor_Waterleak) },
|
||||||
|
{ be_const_key_weak(http_flow, 25), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Flow) },
|
||||||
{ be_const_key_weak(v_pressure, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Pressure) },
|
{ be_const_key_weak(v_pressure, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Pressure) },
|
||||||
{ be_const_key_weak(v_temp, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Temp) },
|
{ be_const_key_weak(v_waterleak, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Waterleak) },
|
||||||
{ be_const_key_weak(http_contact, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Contact) },
|
|
||||||
{ be_const_key_weak(http_humidity, 22), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Humidity) },
|
|
||||||
{ be_const_key_weak(pressure, 13), be_const_class(be_class_Matter_Plugin_Sensor_Pressure) },
|
|
||||||
{ be_const_key_weak(http_pressure, 8), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Pressure) },
|
|
||||||
{ be_const_key_weak(illuminance, -1), be_const_class(be_class_Matter_Plugin_Sensor_Illuminance) },
|
|
||||||
{ be_const_key_weak(light1, -1), be_const_class(be_class_Matter_Plugin_Light1) },
|
|
||||||
{ be_const_key_weak(http_light1, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light1) },
|
|
||||||
{ be_const_key_weak(light3, 36), be_const_class(be_class_Matter_Plugin_Light3) },
|
|
||||||
{ be_const_key_weak(http_occupancy, 31), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Occupancy) },
|
|
||||||
{ be_const_key_weak(v_relay, -1), be_const_class(be_class_Matter_Plugin_Virt_OnOff) },
|
|
||||||
{ be_const_key_weak(contact, -1), be_const_class(be_class_Matter_Plugin_Sensor_Contact) },
|
|
||||||
{ be_const_key_weak(http_temperature, 26), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Temp) },
|
|
||||||
{ be_const_key_weak(v_occupancy, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Occupancy) },
|
|
||||||
{ be_const_key_weak(occupancy, -1), be_const_class(be_class_Matter_Plugin_Sensor_Occupancy) },
|
|
||||||
{ be_const_key_weak(temperature, 32), be_const_class(be_class_Matter_Plugin_Sensor_Temp) },
|
|
||||||
{ be_const_key_weak(flow, 4), be_const_class(be_class_Matter_Plugin_Sensor_Flow) },
|
|
||||||
{ be_const_key_weak(v_contact, 6), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Contact) },
|
|
||||||
{ be_const_key_weak(http_relay, 3), be_const_class(be_class_Matter_Plugin_Bridge_OnOff) },
|
|
||||||
{ be_const_key_weak(http_light2, 29), be_const_class(be_class_Matter_Plugin_Bridge_Light2) },
|
|
||||||
{ be_const_key_weak(root, -1), be_const_class(be_class_Matter_Plugin_Root) },
|
|
||||||
{ be_const_key_weak(http_light3, 9), be_const_class(be_class_Matter_Plugin_Bridge_Light3) },
|
|
||||||
{ be_const_key_weak(light0, -1), be_const_class(be_class_Matter_Plugin_Light0) },
|
|
||||||
{ be_const_key_weak(http_illuminance, 35), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Illuminance) },
|
|
||||||
{ be_const_key_weak(v_light2, -1), be_const_class(be_class_Matter_Plugin_Virt_Light2) },
|
|
||||||
{ be_const_key_weak(v_illuminance, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Illuminance) },
|
|
||||||
{ be_const_key_weak(v_humidity, 15), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Humidity) },
|
|
||||||
{ be_const_key_weak(v_light0, -1), be_const_class(be_class_Matter_Plugin_Virt_Light0) },
|
|
||||||
{ be_const_key_weak(onoff, -1), be_const_class(be_class_Matter_Plugin_Sensor_OnOff) },
|
{ be_const_key_weak(onoff, -1), be_const_class(be_class_Matter_Plugin_Sensor_OnOff) },
|
||||||
|
{ be_const_key_weak(v_occupancy, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Occupancy) },
|
||||||
|
{ be_const_key_weak(temperature, -1), be_const_class(be_class_Matter_Plugin_Sensor_Temp) },
|
||||||
|
{ be_const_key_weak(illuminance, 22), be_const_class(be_class_Matter_Plugin_Sensor_Illuminance) },
|
||||||
|
{ be_const_key_weak(v_light3, 33), be_const_class(be_class_Matter_Plugin_Virt_Light3) },
|
||||||
|
{ be_const_key_weak(contact, -1), be_const_class(be_class_Matter_Plugin_Sensor_Contact) },
|
||||||
|
{ be_const_key_weak(v_light1, 14), be_const_class(be_class_Matter_Plugin_Virt_Light1) },
|
||||||
|
{ be_const_key_weak(http_light1, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light1) },
|
||||||
|
{ be_const_key_weak(http_occupancy, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Occupancy) },
|
||||||
|
{ be_const_key_weak(http_illuminance, 12), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Illuminance) },
|
||||||
|
{ be_const_key_weak(http_pressure, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Pressure) },
|
||||||
|
{ be_const_key_weak(http_contact, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Contact) },
|
||||||
|
{ be_const_key_weak(light2, -1), be_const_class(be_class_Matter_Plugin_Light2) },
|
||||||
|
{ be_const_key_weak(aggregator, -1), be_const_class(be_class_Matter_Plugin_Aggregator) },
|
||||||
|
{ be_const_key_weak(light0, -1), be_const_class(be_class_Matter_Plugin_Light0) },
|
||||||
|
{ be_const_key_weak(occupancy, -1), be_const_class(be_class_Matter_Plugin_Sensor_Occupancy) },
|
||||||
|
{ be_const_key_weak(http_humidity, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Humidity) },
|
||||||
|
{ be_const_key_weak(shutter, 28), be_const_class(be_class_Matter_Plugin_Shutter) },
|
||||||
|
{ be_const_key_weak(http_light0, 24), be_const_class(be_class_Matter_Plugin_Bridge_Light0) },
|
||||||
|
{ be_const_key_weak(http_light2, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light2) },
|
||||||
|
{ be_const_key_weak(v_relay, -1), be_const_class(be_class_Matter_Plugin_Virt_OnOff) },
|
||||||
|
{ be_const_key_weak(v_contact, 41), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Contact) },
|
||||||
|
{ be_const_key_weak(root, 7), be_const_class(be_class_Matter_Plugin_Root) },
|
||||||
|
{ be_const_key_weak(pressure, -1), be_const_class(be_class_Matter_Plugin_Sensor_Pressure) },
|
||||||
|
{ be_const_key_weak(v_illuminance, 8), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Illuminance) },
|
||||||
|
{ be_const_key_weak(v_light2, 26), be_const_class(be_class_Matter_Plugin_Virt_Light2) },
|
||||||
|
{ be_const_key_weak(http_light3, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light3) },
|
||||||
|
{ be_const_key_weak(v_light0, 4), be_const_class(be_class_Matter_Plugin_Virt_Light0) },
|
||||||
|
{ be_const_key_weak(v_humidity, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Humidity) },
|
||||||
|
{ be_const_key_weak(v_temp, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Temp) },
|
||||||
|
{ be_const_key_weak(shutter_X2Btilt, 43), be_const_class(be_class_Matter_Plugin_ShutterTilt) },
|
||||||
|
{ be_const_key_weak(http_waterleak, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Waterleak) },
|
||||||
|
{ be_const_key_weak(http_relay, 16), be_const_class(be_class_Matter_Plugin_Bridge_OnOff) },
|
||||||
|
{ be_const_key_weak(light3, -1), be_const_class(be_class_Matter_Plugin_Light3) },
|
||||||
{ be_const_key_weak(relay, -1), be_const_class(be_class_Matter_Plugin_OnOff) },
|
{ be_const_key_weak(relay, -1), be_const_class(be_class_Matter_Plugin_OnOff) },
|
||||||
{ be_const_key_weak(http_light0, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light0) },
|
{ be_const_key_weak(light1, -1), be_const_class(be_class_Matter_Plugin_Light1) },
|
||||||
{ be_const_key_weak(shutter_X2Btilt, -1), be_const_class(be_class_Matter_Plugin_ShutterTilt) },
|
{ be_const_key_weak(http_temperature, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Temp) },
|
||||||
{ be_const_key_weak(humidity, -1), be_const_class(be_class_Matter_Plugin_Sensor_Humidity) },
|
|
||||||
{ be_const_key_weak(http_flow, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Flow) },
|
|
||||||
})) ) } )) },
|
})) ) } )) },
|
||||||
{ be_const_key_weak(tick, 9), be_const_var(10) },
|
{ be_const_key_weak(tick, 9), be_const_var(10) },
|
||||||
{ be_const_key_weak(commissioning_admin_fabric, -1), be_const_var(17) },
|
{ be_const_key_weak(commissioning_admin_fabric, -1), be_const_var(17) },
|
||||||
|
|
Loading…
Reference in New Issue