From 9ac2a6960367be1de2b43443e8c3d235e3272bbb Mon Sep 17 00:00:00 2001 From: s-hadinger <49731213+s-hadinger@users.noreply.github.com> Date: Sun, 8 Sep 2024 23:16:19 +0200 Subject: [PATCH] Matter support for Zigbee Occupancy and Light 0/1/2 (OnOff / Dimmer / White Color Temperature) (#22110) --- CHANGELOG.md | 1 + .../berry_matter/src/be_matter_module.c | 4 + .../berry_matter/src/embedded/Matter_IM.be | 2 +- .../src/embedded/Matter_Plugin_0.be | 11 +- .../src/embedded/Matter_Plugin_1_Device.be | 44 + .../src/embedded/Matter_Plugin_2_Light0.be | 37 +- .../src/embedded/Matter_Plugin_2_Sensor.be | 44 - .../Matter_Plugin_2_Sensor_Air_Quality.be | 1 + .../Matter_Plugin_2_Sensor_Boolean.be | 11 + ...atter_Plugin_2_Sensor_GenericSwitch_Btn.be | 1 + .../src/embedded/Matter_Plugin_2_Shutter.be | 1 + .../src/embedded/Matter_Plugin_3_Light1.be | 3 +- .../Matter_Plugin_3_Sensor_Contact.be | 10 +- .../Matter_Plugin_3_Sensor_Occupancy.be | 10 +- .../embedded/Matter_Plugin_3_Sensor_OnOff.be | 2 + .../embedded/Matter_Plugin_3_Sensor_Rain.be | 10 +- .../Matter_Plugin_3_Sensor_Waterleak.be | 10 +- .../embedded/Matter_Plugin_8_Bridge_Light0.be | 2 +- .../embedded/Matter_Plugin_9_Virt_Light0.be | 2 +- .../embedded/Matter_Plugin_9_Zigbee_Light0.be | 38 + .../embedded/Matter_Plugin_9_Zigbee_Light1.be | 37 + .../embedded/Matter_Plugin_9_Zigbee_Light2.be | 37 + .../Matter_Plugin_9_Zigbee_Occupancy.be | 38 + .../src/embedded/Matter_z_Zigbee.be | 26 +- .../src/solidify/solidified_Matter_IM.h | 2 +- .../src/solidify/solidified_Matter_Plugin_0.h | 269 +-- .../solidified_Matter_Plugin_1_Device.h | 1750 +++++++++-------- .../solidified_Matter_Plugin_2_Light0.h | 1057 +++++----- .../solidified_Matter_Plugin_2_Sensor.h | 610 +++--- ...ified_Matter_Plugin_2_Sensor_Air_Quality.h | 55 +- ...olidified_Matter_Plugin_2_Sensor_Boolean.h | 292 +-- ...Matter_Plugin_2_Sensor_GenericSwitch_Btn.h | 93 +- .../solidified_Matter_Plugin_2_Shutter.h | 395 ++-- .../solidified_Matter_Plugin_3_Light1.h | 209 +- ...olidified_Matter_Plugin_3_Sensor_Contact.h | 154 +- ...idified_Matter_Plugin_3_Sensor_Occupancy.h | 178 +- .../solidified_Matter_Plugin_3_Sensor_OnOff.h | 150 +- .../solidified_Matter_Plugin_3_Sensor_Rain.h | 154 +- ...idified_Matter_Plugin_3_Sensor_Waterleak.h | 154 +- .../solidified_Matter_Plugin_9_Virt_Light0.h | 2 +- ...solidified_Matter_Plugin_9_Zigbee_Light0.h | 58 + ...solidified_Matter_Plugin_9_Zigbee_Light1.h | 57 + ...solidified_Matter_Plugin_9_Zigbee_Light2.h | 57 + ...idified_Matter_Plugin_9_Zigbee_Occupancy.h | 58 + .../src/solidify/solidified_Matter_z_Zigbee.h | 415 ++-- .../solidify/solidified_Matter_zz_Device.h | 108 +- .../xdrv_52_3_berry_zigbee.ino | 14 +- 47 files changed, 3629 insertions(+), 3044 deletions(-) create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light0.be create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light1.be create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light2.be create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Occupancy.be create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light0.h create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light1.h create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light2.h create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Occupancy.h diff --git a/CHANGELOG.md b/CHANGELOG.md index e8d4a65a6..78b60d39f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ All notable changes to this project will be documented in this file. ## [14.2.0.4] ### Added - HX711 optional calibration precision option on command ``Sensor34 2 `` where `` is 1 to 10 (#13983) +- Matter support for Zigbee Occupancy and Light 0/1/2 (OnOff / Dimmer / White Color Temperature) ### Breaking Changed diff --git a/lib/libesp32/berry_matter/src/be_matter_module.c b/lib/libesp32/berry_matter/src/be_matter_module.c index d75ed4ff7..02db643b3 100644 --- a/lib/libesp32/berry_matter/src/be_matter_module.c +++ b/lib/libesp32/berry_matter/src/be_matter_module.c @@ -296,9 +296,13 @@ extern const bclass be_class_Matter_TLV; // need to declare it upfront because #include "solidify/solidified_Matter_Plugin_8_Bridge_Sensor_Air_Quality.h" #include "solidify/solidified_Matter_Plugin_8_Bridge_Sensor_Rain.h" #include "solidify/solidified_Matter_Plugin_8_Bridge_Sensor_Waterleak.h" +#include "solidify/solidified_Matter_Plugin_9_Zigbee_Light0.h" +#include "solidify/solidified_Matter_Plugin_9_Zigbee_Light1.h" +#include "solidify/solidified_Matter_Plugin_9_Zigbee_Light2.h" #include "solidify/solidified_Matter_Plugin_9_Zigbee_Temperature.h" #include "solidify/solidified_Matter_Plugin_9_Zigbee_Pressure.h" #include "solidify/solidified_Matter_Plugin_9_Zigbee_Humidity.h" +#include "solidify/solidified_Matter_Plugin_9_Zigbee_Occupancy.h" #include "solidify/solidified_Matter_Plugin_z_All.h" #include "solidify/solidified_Matter_zz_Device.h" diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_IM.be b/lib/libesp32/berry_matter/src/embedded/Matter_IM.be index 52949177b..c4810ff99 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_IM.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_IM.be @@ -735,7 +735,7 @@ class Matter_IM var ep_str = (q.endpoint != nil) ? f"{q.endpoint:02X}" : "**" var cl_str = (q.cluster != nil) ? f"{q.cluster:04X}" : "****" var ev_str = (q.event != nil) ? f"{q.event:02X}" : "**" - var event_no_min_str = (event_no_min != nil) ? f" (>{event_no_min})" : "" + var event_no_min_str = (event_no_min != nil) ? f" (event>{event_no_min})" : "" log(f"MTR: >Read_Event({msg.session.local_session_id:6i}) [{ep_str}]{cl_str}/{ev_str} {event_name}{event_no_min_str}", 3) end end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_0.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_0.be index 0e703a44a..2183fc09f 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_0.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_0.be @@ -259,6 +259,13 @@ matter_device.events.dump() # # we limit to 3 commands (to we need more?) def publish_command(key1, value1, key2, value2, key3, value3) + # if zigbee, decompose simple commands + if self.ZIGBEE && self.zigbee_mapper && self.zigbee_mapper.resolve_zb_device() + self.zigbee_mapper.zb_single_command(key1, value1) + self.zigbee_mapper.zb_single_command(key2, value2) + self.zigbee_mapper.zb_single_command(key3, value3) + end + import json var payload = f"{json.dump(key1)}:{json.dump(value1)}" if key2 != nil @@ -537,7 +544,7 @@ matter_device.events.dump() # key: key name in the JSON payload to read from, do nothing if key does not exist or content is `null` # old_val: previous value, used to detect a change or return the value unchanged # type_func: type enforcer for value, typically `int`, `bool`, `str`, `number`, `real` - # cluster/attribute: in case the value has change, publish a change to cluster/attribute + # cluster/attribute: in case the value has change, publish a change to cluster/attribute. Don't publish if they are `nil` # # Returns: # `old_val` if key does not exist, JSON value is `null`, or value is unchanged @@ -547,7 +554,7 @@ matter_device.events.dump() var val = payload.find(key) if (val != nil) val = type_func(val) - if (val != old_val) + if (val != old_val) && (cluster != nil) && (attribute != nil) self.attribute_updated(cluster, attribute) end return val diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_1_Device.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_1_Device.be index c976ed1ee..6a7a6668e 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_1_Device.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_1_Device.be @@ -81,6 +81,24 @@ class Matter_Plugin_Device : Matter_Plugin end end + ############################################################# + # Called when the value changed compared to shadow value + # + # This must be overriden. + # This is where you call `self.attribute_updated(, )` + def value_changed() + # self.attribute_updated(0x0402, 0x0000) + end + + ############################################################# + # Pre-process value + # + # This must be overriden. + # This allows to convert the raw sensor value to the target one, typically int + def pre_value(val) + return val + end + ############################################################# # read an attribute # @@ -455,5 +473,31 @@ class Matter_Plugin_Device : Matter_Plugin return old_val end + ############################################################# + # For Zigbee devices + ############################################################# + ############################################################# + # attributes_refined + # + # Filtered to only events for this endpoint + # + # Can be called only if `self.ZIGBEE` is true + def zigbee_received(frame, attr_list) + import math + log(f"MTR: zigbee_received Ox{self.zigbee_mapper.shortaddr:04X} {attr_list=} {type(attr_list)=}", 3) + var idx = 0 + while (idx < size(attr_list)) + var entry = attr_list[idx] + if (entry.key == self.ZIGBEE_NAME) + var val = self.pre_value(entry.val) + var update_list = { self.JSON_NAME : val } # Matter temperature is 1/100th of degrees + self.update_virtual(update_list) + log(f"MTR: [{self.endpoint:02X}] {self.JSON_NAME} updated {update_list}", 3) + return nil + end + idx += 1 + end + end + end matter.Plugin_Device = Matter_Plugin_Device diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Light0.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Light0.be index 48747460f..76b206c72 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Light0.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Light0.be @@ -25,7 +25,7 @@ import matter class Matter_Plugin_Light0 : Matter_Plugin_Device static var TYPE = "light0" # name of the plug-in in json - static var DISPLAY_NAME = "Light 0 On" # display name of the plug-in + static var DISPLAY_NAME = "Light 0 OnOff" # display name of the plug-in static var ARG = "relay" # additional argument name (or empty if none) static var ARG_TYPE = / x -> int(x) # function to convert argument to the right type static var ARG_HINT = "Relay number" @@ -63,6 +63,7 @@ class Matter_Plugin_Light0 : Matter_Plugin_Device # # Parse configuration map def parse_configuration(config) + super(self).parse_configuration(config) # with Light0 we always need relay number but we don't for Light1/2/3 so self.tasmota_relay_index may be `nil` self.tasmota_relay_index = int(config.find(self.ARG #-'relay'-#, nil)) if (self.tasmota_relay_index != nil && self.tasmota_relay_index <= 0) self.tasmota_relay_index = 1 end @@ -174,6 +175,40 @@ class Matter_Plugin_Light0 : Matter_Plugin_Device super(self).update_virtual(payload) end + ############################################################# + # For Zigbee devices + ############################################################# + ############################################################# + # attributes_refined + # + # Filtered to only events for this endpoint + # Contains common code for Light 0/1/2/3 to avoid code duplication + # + # Can be called only if `self.ZIGBEE` is true + def zigbee_received(frame, attr_list) + import math + log(f"MTR: zigbee_received Ox{self.zigbee_mapper.shortaddr:04X} {attr_list=} {type(attr_list)=}", 3) + var idx = 0 + var update_list = {} + while (idx < size(attr_list)) + var entry = attr_list[idx] + if (entry.key == "Power") + update_list['Power'] = int(entry.val) + end + if (entry.key == "Dimmer") + update_list['Dimmer'] = int(entry.val) + end + if (entry.key == "CT") + update_list['CT'] = int(entry.val) + end + idx += 1 + end + if (size(update_list) > 0) + self.update_virtual(update_list) + log(f"MTR: [{self.endpoint:02X}] Light2 updated {update_list}", 3) + end + end + ############################################################# # For Bridge devices ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor.be index 6384a78ee..d25a0c8bd 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor.be @@ -85,24 +85,6 @@ class Matter_Plugin_Sensor : Matter_Plugin_Device end end - ############################################################# - # Called when the value changed compared to shadow value - # - # This must be overriden. - # This is where you call `self.attribute_updated(, )` - def value_changed() - # self.attribute_updated(0x0402, 0x0000) - end - - ############################################################# - # Pre-process value - # - # This must be overriden. - # This allows to convert the raw sensor value to the target one, typically int - def pre_value(val) - return val - end - ############################################################# # update_virtual # @@ -168,31 +150,5 @@ class Matter_Plugin_Sensor : Matter_Plugin_Device ############################################################# ############################################################# - ############################################################# - # For Zigbee devices - ############################################################# - ############################################################# - # attributes_refined - # - # Filtered to only events for this endpoint - # - # Can be called only if `self.ZIGBEE` is true - def zigbee_received(frame, attr_list) - import math - log(f"MTR: zigbee_received Ox{self.zigbee_mapper.shortaddr:04X} {attr_list=} {type(attr_list)=}", 3) - var idx = 0 - while (idx < size(attr_list)) - var entry = attr_list[idx] - if (entry.key == self.ZIGBEE_NAME) - var val = self.pre_value(entry.val) - var update_list = { self.JSON_NAME : val } # Matter temperature is 1/100th of degrees - self.update_virtual(update_list) - log(f"MTR: [{self.endpoint:02X}] {self.JSON_NAME} updated {update_list}", 3) - return nil - end - idx += 1 - end - end - end matter.Plugin_Sensor = Matter_Plugin_Sensor diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Air_Quality.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Air_Quality.be index 35ad21d85..b110c61a3 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Air_Quality.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Air_Quality.be @@ -77,6 +77,7 @@ class Matter_Plugin_Sensor_Air_Quality : Matter_Plugin_Device # # Parse configuration map def parse_configuration(config) + super(self).parse_configuration(config) self.prefix = str(config.find(self.ARG)) end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Boolean.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Boolean.be index 06d65baa8..632b839e4 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Boolean.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_Boolean.be @@ -46,6 +46,7 @@ class Matter_Plugin_Sensor_Boolean : Matter_Plugin_Device # # Parse configuration map def parse_configuration(config) + super(self).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 @@ -79,6 +80,16 @@ class Matter_Plugin_Sensor_Boolean : Matter_Plugin_Device def value_updated() end + ############################################################# + # update_virtual + # + # Update internal state for virtual devices + def update_virtual(payload) + self.shadow_bool_value = self._parse_update_virtual(payload, self.JSON_NAME, self.shadow_bool_value, bool, nil, nil) # publishing cluster/attr is delegated to `value_updated()` + self.value_updated() + super(self).update_virtual(payload) + end + ############################################################# # For Bridge devices ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_GenericSwitch_Btn.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_GenericSwitch_Btn.be index 377259cca..6a1058612 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_GenericSwitch_Btn.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Sensor_GenericSwitch_Btn.be @@ -46,6 +46,7 @@ class Matter_Plugin_Sensor_GenericSwitch_Btn : Matter_Plugin_Device # # Parse configuration map def parse_configuration(config) + super(self).parse_configuration(config) self.tasmota_switch_index = int(config.find(self.ARG #-'relay'-#, 1)) if self.tasmota_switch_index <= 0 self.tasmota_switch_index = 1 end end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Shutter.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Shutter.be index c7c561f27..d17717fe5 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Shutter.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_2_Shutter.be @@ -49,6 +49,7 @@ class Matter_Plugin_Shutter : Matter_Plugin_Device # # Parse configuration map def parse_configuration(config) + super(self).parse_configuration(config) self.tasmota_shutter_index = config.find(self.ARG #-'relay'-#) if self.tasmota_shutter_index == nil self.tasmota_shutter_index = 0 end self.shadow_shutter_inverted = -1 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Light1.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Light1.be index 501c11c60..fcc77db3b 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Light1.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Light1.be @@ -63,6 +63,7 @@ class Matter_Plugin_Light1 : Matter_Plugin_Light0 # # Parse configuration map def parse_configuration(config) + super(self).parse_configuration(config) # with Light0 we always need relay number but we don't for Light1/2/3 so self.tasmota_relay_index may be `nil` if self.BRIDGE self.tasmota_relay_index = int(config.find(self.ARG #-'relay'-#, nil)) @@ -207,7 +208,7 @@ class Matter_Plugin_Light1 : Matter_Plugin_Light0 var onoff = bri_254 > 0 self.set_bri(bri_254, onoff) ctx.log = "bri:"+str(bri_254) - self.publish_command('Bri', bri_254, 'Dimmer', tasmota.scale_uint(bri_254, 0, 254, 0, 100), 'Power', onoff ? 1 : 0) + self.publish_command('Power', onoff ? 1 : 0, 'Bri', bri_254, 'Dimmer', tasmota.scale_uint(bri_254, 0, 254, 0, 100)) return true elif command == 0x0005 # ---------- MoveWithOnOff ---------- # TODO, we don't really support it diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Contact.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Contact.be index abb2fa7f7..c62822b45 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Contact.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Contact.be @@ -30,6 +30,7 @@ class Matter_Plugin_Sensor_Contact : Matter_Plugin_Sensor_Boolean # static var ARG_HINT = "Switch 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 JSON_NAME = "Contact" # Name of the sensor attribute in JSON payloads static var UPDATE_COMMANDS = matter.UC_LIST(_class, "Contact") static var CLUSTERS = matter.consolidate_clusters(_class, { 0x0045: [0], # Boolean State p.70 - no writable @@ -66,15 +67,6 @@ class Matter_Plugin_Sensor_Contact : Matter_Plugin_Sensor_Boolean return super(self).read_attribute(session, ctx, tlv_solo) end - ############################################################# - # update_virtual - # - # Update internal state for virtual devices - def update_virtual(payload) - self.shadow_bool_value = self._parse_update_virtual(payload, "Contact", self.shadow_bool_value, bool, 0x0045, 0x0000) - super(self).update_virtual(payload) - end - ############################################################# # For Bridge devices ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Occupancy.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Occupancy.be index c30193c9e..7720dbcaa 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Occupancy.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Occupancy.be @@ -30,6 +30,7 @@ class Matter_Plugin_Sensor_Occupancy : Matter_Plugin_Sensor_Boolean # static var ARG_HINT = "Switch 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 JSON_NAME = "Occupancy" # Name of the sensor attribute in JSON payloads static var UPDATE_COMMANDS = matter.UC_LIST(_class, "Occupancy") static var CLUSTERS = matter.consolidate_clusters(_class, { 0x0406: [0,1,2], # Occupancy Sensing p.105 - no writable @@ -70,15 +71,6 @@ class Matter_Plugin_Sensor_Occupancy : Matter_Plugin_Sensor_Boolean return super(self).read_attribute(session, ctx, tlv_solo) end - ############################################################# - # update_virtual - # - # Update internal state for virtual devices - def update_virtual(payload) - self.shadow_bool_value = self._parse_update_virtual(payload, "Occupancy", self.shadow_bool_value, bool, 0x0406, 0x0000) - super(self).update_virtual(payload) - end - ############################################################# # For Bridge devices ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_OnOff.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_OnOff.be index ae736e5bd..4dd87ef7d 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_OnOff.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_OnOff.be @@ -28,6 +28,8 @@ class Matter_Plugin_Sensor_OnOff : Matter_Plugin_Sensor_Boolean # static var ARG_HINT = "Switch 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 JSON_NAME = "OnOff" # Name of the sensor attribute in JSON payloads + static var UPDATE_COMMANDS = matter.UC_LIST(_class, "OnOff") static var CLUSTERS = matter.consolidate_clusters(_class, { 0x0006: [0], # On/Off 1.5 p.48 }) diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Rain.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Rain.be index 970be52b8..92730e54a 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Rain.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Rain.be @@ -30,6 +30,7 @@ class Matter_Plugin_Sensor_Rain : Matter_Plugin_Sensor_Boolean # static var ARG_HINT = "Switch 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 JSON_NAME = "Rain" # Name of the sensor attribute in JSON payloads static var UPDATE_COMMANDS = matter.UC_LIST(_class, "Rain") static var CLUSTERS = matter.consolidate_clusters(_class, { 0x0045: [0], # Boolean State p.70 - no writable @@ -67,15 +68,6 @@ class Matter_Plugin_Sensor_Rain : Matter_Plugin_Sensor_Boolean return super(self).read_attribute(session, ctx, tlv_solo) end - ############################################################# - # update_virtual - # - # Update internal state for virtual devices - def update_virtual(payload) - self.shadow_bool_value = self._parse_update_virtual(payload, "Rain", self.shadow_bool_value, bool, 0x0045, 0x0000) - super(self).update_virtual(payload) - end - ############################################################# # For Bridge devices ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Waterleak.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Waterleak.be index 48102ddd6..14e55ec8f 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Waterleak.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_3_Sensor_Waterleak.be @@ -30,6 +30,7 @@ class Matter_Plugin_Sensor_Waterleak : Matter_Plugin_Sensor_Boolean # static var ARG_HINT = "Switch 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 JSON_NAME = "Waterleak" # Name of the sensor attribute in JSON payloads static var UPDATE_COMMANDS = matter.UC_LIST(_class, "Waterleak") static var CLUSTERS = matter.consolidate_clusters(_class, { 0x0045: [0], # Boolean State p.70 - no writable @@ -67,15 +68,6 @@ class Matter_Plugin_Sensor_Waterleak : Matter_Plugin_Sensor_Boolean return super(self).read_attribute(session, ctx, tlv_solo) end - ############################################################# - # update_virtual - # - # Update internal state for virtual devices - def update_virtual(payload) - self.shadow_bool_value = self._parse_update_virtual(payload, "Waterleak", self.shadow_bool_value, bool, 0x0045, 0x0000) - super(self).update_virtual(payload) - end - ############################################################# # For Bridge devices ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_8_Bridge_Light0.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_8_Bridge_Light0.be index e8c444908..0439803ba 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_8_Bridge_Light0.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_8_Bridge_Light0.be @@ -26,7 +26,7 @@ import matter class Matter_Plugin_Bridge_Light0 : Matter_Plugin_Light0 static var BRIDGE = true # flag as bridged device static var TYPE = "http_light0" # name of the plug-in in json - # static var DISPLAY_NAME = "Light 0 On" # display name of the plug-in + # static var DISPLAY_NAME = "Light 0 OnOff" # display name of the plug-in static var UPDATE_TIME = 3000 # update every 3s end matter.Plugin_Bridge_Light0 = Matter_Plugin_Bridge_Light0 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Virt_Light0.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Virt_Light0.be index 65eb8988b..683da0af7 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Virt_Light0.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Virt_Light0.be @@ -25,7 +25,7 @@ import matter class Matter_Plugin_Virt_Light0 : Matter_Plugin_Light0 static var TYPE = "v_light0" # name of the plug-in in json - static var DISPLAY_NAME = "v.Light 0 On" # display name of the plug-in + static var DISPLAY_NAME = "v.Light 0 OnOff" # 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 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light0.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light0.be new file mode 100644 index 000000000..a00accf19 --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light0.be @@ -0,0 +1,38 @@ +# +# Matter_Plugin_9_Zigbee_Temperature.be - implements the behavior for a Zigbee Light0 +# +# Copyright (C) 2023 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 . +# + +import matter + +# Matter plug-in for core behavior + +#@ solidify:Matter_Plugin_Zigbee_Light0,weak + +class Matter_Plugin_Zigbee_Light0 : Matter_Plugin_Light0 + static var ZIGBEE = true + static var TYPE = "z_light0" # name of the plug-in in json + static var DISPLAY_NAME = "Zig Light 0 OnOff" # display name of the plug-in + static var ZIGBEE_NAME = "Power" # name of zigbee attribute with sensor reported + static var ARG = "zigbee_device" # zigbee device + static var ARG_TYPE = / x -> str(x) # function to convert argument to the right type + static var ARG_HINT = "Device" # Hint for entering the Argument (inside 'placeholder') + static var VIRTUAL = true # virtual device, necessary for Zigbee mapping + var zigbee_mapper # required for zigbee device + +end +matter.Plugin_Zigbee_Light0 = Matter_Plugin_Zigbee_Light0 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light1.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light1.be new file mode 100644 index 000000000..4f9d1f34a --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light1.be @@ -0,0 +1,37 @@ +# +# Matter_Plugin_9_Zigbee_Temperature.be - implements the behavior for a Zigbee Light1 +# +# Copyright (C) 2023 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 . +# + +import matter + +# Matter plug-in for core behavior + +#@ solidify:Matter_Plugin_Zigbee_Light1,weak + +class Matter_Plugin_Zigbee_Light1 : Matter_Plugin_Light1 + static var ZIGBEE = true + static var TYPE = "z_light1" # name of the plug-in in json + static var DISPLAY_NAME = "Zig Light 1 Dimmer" # display name of the plug-in + static var ARG = "zigbee_device" # zigbee device + static var ARG_TYPE = / x -> str(x) # function to convert argument to the right type + static var ARG_HINT = "Device" # Hint for entering the Argument (inside 'placeholder') + static var VIRTUAL = true # virtual device, necessary for Zigbee mapping + var zigbee_mapper # required for zigbee device + +end +matter.Plugin_Zigbee_Light1 = Matter_Plugin_Zigbee_Light1 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light2.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light2.be new file mode 100644 index 000000000..8b30b96a5 --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Light2.be @@ -0,0 +1,37 @@ +# +# Matter_Plugin_9_Zigbee_Temperature.be - implements the behavior for a Zigbee Light2 +# +# Copyright (C) 2023 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 . +# + +import matter + +# Matter plug-in for core behavior + +#@ solidify:Matter_Plugin_Zigbee_Light2,weak + +class Matter_Plugin_Zigbee_Light2 : Matter_Plugin_Light2 + static var ZIGBEE = true + static var TYPE = "z_light2" # name of the plug-in in json + static var DISPLAY_NAME = "Zig Light 2 CT" # display name of the plug-in + static var ARG = "zigbee_device" # zigbee device + static var ARG_TYPE = / x -> str(x) # function to convert argument to the right type + static var ARG_HINT = "Device" # Hint for entering the Argument (inside 'placeholder') + static var VIRTUAL = true # virtual device, necessary for Zigbee mapping + var zigbee_mapper # required for zigbee device + +end +matter.Plugin_Zigbee_Light2 = Matter_Plugin_Zigbee_Light2 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Occupancy.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Occupancy.be new file mode 100644 index 000000000..7ad70e281 --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_9_Zigbee_Occupancy.be @@ -0,0 +1,38 @@ +# +# Matter_Plugin_9_Zigbee_Occupancy.be - implements the behavior for a Zigbee Occupancy sensor +# +# Copyright (C) 2023 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 . +# + +import matter + +# Matter plug-in for core behavior + +#@ solidify:Matter_Plugin_Zigbee_Occupancy,weak + +class Matter_Plugin_Zigbee_Occupancy : Matter_Plugin_Sensor_Occupancy + static var ZIGBEE = true + static var TYPE = "z_occupancy" # name of the plug-in in json + static var DISPLAY_NAME = "Zig Occupancy" # display name of the plug-in + static var ZIGBEE_NAME = "Occupancy" # name of zigbee attribute with sensor reported + static var ARG = "zigbee_device" # zigbee device + static var ARG_TYPE = / x -> str(x) # function to convert argument to the right type + static var ARG_HINT = "Device" # Hint for entering the Argument (inside 'placeholder') + static var VIRTUAL = true # virtual device, necessary for Zigbee mapping + var zigbee_mapper # required for zigbee device + +end +matter.Plugin_Zigbee_Occupancy = Matter_Plugin_Zigbee_Occupancy diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_z_Zigbee.be b/lib/libesp32/berry_matter/src/embedded/Matter_z_Zigbee.be index f8acdaf6d..466a81351 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_z_Zigbee.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_z_Zigbee.be @@ -118,6 +118,29 @@ class Matter_Zigbee_Mapper end end + ############################################################# + # zb_single_command + # + # Convert a `MtrReceived` unitary payload to a Zigbee command + def zb_single_command(key, value) + # to ease caller, we accept nil arguments and do nothing + var cmd + if (key == 'Power') + cmd = f'ZbSend {{"Device":"0x{self.shortaddr:04X}","Send":{{"Power":{value:i}}}}}' + elif (key == 'Bri') + cmd = f'ZbSend {{"Device":"0x{self.shortaddr:04X}","Send":{{"Dimmer":{value:i}}}}}' + elif (key == 'CT') + cmd = f'ZbSend {{"Device":"0x{self.shortaddr:04X}","Send":{{"CT":{value:i}}}}}' + end + # send command + if (cmd != nil) + if tasmota.loglevel(3) + log(f"MTR: '{cmd}'", 3) + end + tasmota.cmd(cmd, true) + end + end + end ########################################################################################## @@ -130,7 +153,7 @@ class Matter_Zigbee var device # reference to the main Device instance # UI static var _CLASSES_TYPES = # Zigbee - "-zigbee|z_temp|z_pressure|z_humidity" + "-zigbee|z_light0|z_light1|z_light2|z_temp|z_pressure|z_humidity|z_occupancy" ############################################################# def init(device) @@ -139,6 +162,7 @@ class Matter_Zigbee zigbee.add_handler(self) # listen to all events received end + ############################################################# # attributes_refined # diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h index 8fb88782b..2f3817b58 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h @@ -109,7 +109,7 @@ static const bvalue be_ktab_class_Matter_IM[203] = { /* K100 */ be_nested_str_weak(_X2A_X2A), /* K101 */ be_nested_str_weak(_X2504X), /* K102 */ be_nested_str_weak(_X2A_X2A_X2A_X2A), - /* K103 */ be_nested_str_weak(_X20_X28_X3E_X25s_X29), + /* K103 */ be_nested_str_weak(_X20_X28event_X3E_X25s_X29), /* K104 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Event_X28_X256i_X29_X20_X5B_X25s_X5D_X25s_X2F_X25s_X20_X25s_X25s), /* K105 */ be_nested_str_weak(finished), /* K106 */ be_nested_str_weak(ready), diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_0.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_0.h index f61ab1813..013f4df7c 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_0.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_0.h @@ -4,8 +4,8 @@ \********************************************************************/ #include "be_constobj.h" extern const bclass be_class_Matter_Plugin; -// compact class 'Matter_Plugin' ktab size: 61, total: 104 (saved 344 bytes) -static const bvalue be_ktab_class_Matter_Plugin[61] = { +// compact class 'Matter_Plugin' ktab size: 65, total: 108 (saved 344 bytes) +static const bvalue be_ktab_class_Matter_Plugin[65] = { /* K0 */ be_nested_str_weak(json), /* K1 */ be_nested_str_weak(node_label), /* K2 */ be_nested_str_weak(_X2C_X22Name_X22_X3A_X25s), @@ -45,28 +45,32 @@ static const bvalue be_ktab_class_Matter_Plugin[61] = { /* K36 */ be_const_int(2), /* K37 */ be_nested_str_weak(get), /* K38 */ be_const_int(1), - /* K39 */ be_nested_str_weak(_X25s_X3A_X25s), - /* K40 */ be_nested_str_weak(_X25s_X2C_X25s_X3A_X25s), - /* K41 */ be_nested_str_weak(publish_command), - /* K42 */ be_nested_str_weak(MtrReceived), - /* K43 */ be_nested_str_weak(contains), - /* K44 */ be_nested_str_weak(TLV), - /* K45 */ be_nested_str_weak(cluster), - /* K46 */ be_nested_str_weak(attribute), - /* K47 */ be_nested_str_weak(Matter_TLV_array), - /* K48 */ be_nested_str_weak(TYPES), - /* K49 */ be_nested_str_weak(keys), - /* K50 */ be_nested_str_weak(add_struct), - /* K51 */ be_nested_str_weak(add_TLV), - /* K52 */ be_nested_str_weak(U2), - /* K53 */ be_nested_str_weak(stop_iteration), - /* K54 */ be_nested_str_weak(get_cluster_list_sorted), - /* K55 */ be_nested_str_weak(U4), - /* K56 */ be_const_int(3), - /* K57 */ be_nested_str_weak(set), - /* K58 */ be_nested_str_weak(get_attribute_list_bytes), - /* K59 */ be_nested_str_weak(FEATURE_MAPS), - /* K60 */ be_nested_str_weak(CLUSTER_REVISIONS), + /* K39 */ be_nested_str_weak(ZIGBEE), + /* K40 */ be_nested_str_weak(zigbee_mapper), + /* K41 */ be_nested_str_weak(resolve_zb_device), + /* K42 */ be_nested_str_weak(zb_single_command), + /* K43 */ be_nested_str_weak(_X25s_X3A_X25s), + /* K44 */ be_nested_str_weak(_X25s_X2C_X25s_X3A_X25s), + /* K45 */ be_nested_str_weak(publish_command), + /* K46 */ be_nested_str_weak(MtrReceived), + /* K47 */ be_nested_str_weak(contains), + /* K48 */ be_nested_str_weak(TLV), + /* K49 */ be_nested_str_weak(cluster), + /* K50 */ be_nested_str_weak(attribute), + /* K51 */ be_nested_str_weak(Matter_TLV_array), + /* K52 */ be_nested_str_weak(TYPES), + /* K53 */ be_nested_str_weak(keys), + /* K54 */ be_nested_str_weak(add_struct), + /* K55 */ be_nested_str_weak(add_TLV), + /* K56 */ be_nested_str_weak(U2), + /* K57 */ be_nested_str_weak(stop_iteration), + /* K58 */ be_nested_str_weak(get_cluster_list_sorted), + /* K59 */ be_nested_str_weak(U4), + /* K60 */ be_const_int(3), + /* K61 */ be_nested_str_weak(set), + /* K62 */ be_nested_str_weak(get_attribute_list_bytes), + /* K63 */ be_nested_str_weak(FEATURE_MAPS), + /* K64 */ be_nested_str_weak(CLUSTER_REVISIONS), }; @@ -742,25 +746,31 @@ be_local_closure(class_Matter_Plugin__parse_update_virtual, /* name */ &be_ktab_class_Matter_Plugin, /* shared constants */ be_str_weak(_parse_update_virtual), &be_const_str_solidified, - ( &(const binstruction[18]) { /* code */ + ( &(const binstruction[24]) { /* code */ 0x8C1C0310, // 0000 GETMET R7 R1 K16 0x5C240400, // 0001 MOVE R9 R2 0x7C1C0400, // 0002 CALL R7 2 0x4C200000, // 0003 LDNIL R8 0x20200E08, // 0004 NE R8 R7 R8 - 0x7822000A, // 0005 JMPF R8 #0011 + 0x78220010, // 0005 JMPF R8 #0017 0x5C200800, // 0006 MOVE R8 R4 0x5C240E00, // 0007 MOVE R9 R7 0x7C200200, // 0008 CALL R8 1 0x5C1C1000, // 0009 MOVE R7 R8 0x20200E03, // 000A NE R8 R7 R3 - 0x78220003, // 000B JMPF R8 #0010 - 0x8C200111, // 000C GETMET R8 R0 K17 - 0x5C280A00, // 000D MOVE R10 R5 - 0x5C2C0C00, // 000E MOVE R11 R6 - 0x7C200600, // 000F CALL R8 3 - 0x80040E00, // 0010 RET 1 R7 - 0x80040600, // 0011 RET 1 R3 + 0x78220009, // 000B JMPF R8 #0016 + 0x4C200000, // 000C LDNIL R8 + 0x20200A08, // 000D NE R8 R5 R8 + 0x78220006, // 000E JMPF R8 #0016 + 0x4C200000, // 000F LDNIL R8 + 0x20200C08, // 0010 NE R8 R6 R8 + 0x78220003, // 0011 JMPF R8 #0016 + 0x8C200111, // 0012 GETMET R8 R0 K17 + 0x5C280A00, // 0013 MOVE R10 R5 + 0x5C2C0C00, // 0014 MOVE R11 R6 + 0x7C200600, // 0015 CALL R8 3 + 0x80040E00, // 0016 RET 1 R7 + 0x80040600, // 0017 RET 1 R3 }) ) ); @@ -983,53 +993,76 @@ be_local_closure(class_Matter_Plugin_publish_command, /* name */ &be_ktab_class_Matter_Plugin, /* shared constants */ be_str_weak(publish_command), &be_const_str_solidified, - ( &(const binstruction[46]) { /* code */ - 0xA41E0000, // 0000 IMPORT R7 K0 - 0x60200018, // 0001 GETGBL R8 G24 - 0x58240027, // 0002 LDCONST R9 K39 - 0x8C280F03, // 0003 GETMET R10 R7 K3 - 0x5C300200, // 0004 MOVE R12 R1 - 0x7C280400, // 0005 CALL R10 2 - 0x8C2C0F03, // 0006 GETMET R11 R7 K3 - 0x5C340400, // 0007 MOVE R13 R2 - 0x7C2C0400, // 0008 CALL R11 2 - 0x7C200600, // 0009 CALL R8 3 - 0x4C240000, // 000A LDNIL R9 - 0x20240609, // 000B NE R9 R3 R9 - 0x7826000A, // 000C JMPF R9 #0018 - 0x60240018, // 000D GETGBL R9 G24 - 0x58280028, // 000E LDCONST R10 K40 - 0x5C2C1000, // 000F MOVE R11 R8 - 0x8C300F03, // 0010 GETMET R12 R7 K3 - 0x5C380600, // 0011 MOVE R14 R3 - 0x7C300400, // 0012 CALL R12 2 - 0x8C340F03, // 0013 GETMET R13 R7 K3 - 0x5C3C0800, // 0014 MOVE R15 R4 - 0x7C340400, // 0015 CALL R13 2 - 0x7C240800, // 0016 CALL R9 4 - 0x5C201200, // 0017 MOVE R8 R9 - 0x4C240000, // 0018 LDNIL R9 - 0x20240A09, // 0019 NE R9 R5 R9 - 0x7826000A, // 001A JMPF R9 #0026 - 0x60240018, // 001B GETGBL R9 G24 - 0x58280028, // 001C LDCONST R10 K40 - 0x5C2C1000, // 001D MOVE R11 R8 - 0x8C300F03, // 001E GETMET R12 R7 K3 - 0x5C380A00, // 001F MOVE R14 R5 - 0x7C300400, // 0020 CALL R12 2 - 0x8C340F03, // 0021 GETMET R13 R7 K3 - 0x5C3C0C00, // 0022 MOVE R15 R6 - 0x7C340400, // 0023 CALL R13 2 - 0x7C240800, // 0024 CALL R9 4 - 0x5C201200, // 0025 MOVE R8 R9 - 0xB8262600, // 0026 GETNGBL R9 K19 - 0x8C241329, // 0027 GETMET R9 R9 K41 - 0x582C002A, // 0028 LDCONST R11 K42 - 0x88300107, // 0029 GETMBR R12 R0 K7 - 0x88340101, // 002A GETMBR R13 R0 K1 - 0x5C381000, // 002B MOVE R14 R8 - 0x7C240A00, // 002C CALL R9 5 - 0x80000000, // 002D RET 0 + ( &(const binstruction[69]) { /* code */ + 0x881C0127, // 0000 GETMBR R7 R0 K39 + 0x781E0014, // 0001 JMPF R7 #0017 + 0x881C0128, // 0002 GETMBR R7 R0 K40 + 0x781E0012, // 0003 JMPF R7 #0017 + 0x881C0128, // 0004 GETMBR R7 R0 K40 + 0x8C1C0F29, // 0005 GETMET R7 R7 K41 + 0x7C1C0200, // 0006 CALL R7 1 + 0x781E000E, // 0007 JMPF R7 #0017 + 0x881C0128, // 0008 GETMBR R7 R0 K40 + 0x8C1C0F2A, // 0009 GETMET R7 R7 K42 + 0x5C240200, // 000A MOVE R9 R1 + 0x5C280400, // 000B MOVE R10 R2 + 0x7C1C0600, // 000C CALL R7 3 + 0x881C0128, // 000D GETMBR R7 R0 K40 + 0x8C1C0F2A, // 000E GETMET R7 R7 K42 + 0x5C240600, // 000F MOVE R9 R3 + 0x5C280800, // 0010 MOVE R10 R4 + 0x7C1C0600, // 0011 CALL R7 3 + 0x881C0128, // 0012 GETMBR R7 R0 K40 + 0x8C1C0F2A, // 0013 GETMET R7 R7 K42 + 0x5C240A00, // 0014 MOVE R9 R5 + 0x5C280C00, // 0015 MOVE R10 R6 + 0x7C1C0600, // 0016 CALL R7 3 + 0xA41E0000, // 0017 IMPORT R7 K0 + 0x60200018, // 0018 GETGBL R8 G24 + 0x5824002B, // 0019 LDCONST R9 K43 + 0x8C280F03, // 001A GETMET R10 R7 K3 + 0x5C300200, // 001B MOVE R12 R1 + 0x7C280400, // 001C CALL R10 2 + 0x8C2C0F03, // 001D GETMET R11 R7 K3 + 0x5C340400, // 001E MOVE R13 R2 + 0x7C2C0400, // 001F CALL R11 2 + 0x7C200600, // 0020 CALL R8 3 + 0x4C240000, // 0021 LDNIL R9 + 0x20240609, // 0022 NE R9 R3 R9 + 0x7826000A, // 0023 JMPF R9 #002F + 0x60240018, // 0024 GETGBL R9 G24 + 0x5828002C, // 0025 LDCONST R10 K44 + 0x5C2C1000, // 0026 MOVE R11 R8 + 0x8C300F03, // 0027 GETMET R12 R7 K3 + 0x5C380600, // 0028 MOVE R14 R3 + 0x7C300400, // 0029 CALL R12 2 + 0x8C340F03, // 002A GETMET R13 R7 K3 + 0x5C3C0800, // 002B MOVE R15 R4 + 0x7C340400, // 002C CALL R13 2 + 0x7C240800, // 002D CALL R9 4 + 0x5C201200, // 002E MOVE R8 R9 + 0x4C240000, // 002F LDNIL R9 + 0x20240A09, // 0030 NE R9 R5 R9 + 0x7826000A, // 0031 JMPF R9 #003D + 0x60240018, // 0032 GETGBL R9 G24 + 0x5828002C, // 0033 LDCONST R10 K44 + 0x5C2C1000, // 0034 MOVE R11 R8 + 0x8C300F03, // 0035 GETMET R12 R7 K3 + 0x5C380A00, // 0036 MOVE R14 R5 + 0x7C300400, // 0037 CALL R12 2 + 0x8C340F03, // 0038 GETMET R13 R7 K3 + 0x5C3C0C00, // 0039 MOVE R15 R6 + 0x7C340400, // 003A CALL R13 2 + 0x7C240800, // 003B CALL R9 4 + 0x5C201200, // 003C MOVE R8 R9 + 0xB8262600, // 003D GETNGBL R9 K19 + 0x8C24132D, // 003E GETMET R9 R9 K45 + 0x582C002E, // 003F LDCONST R11 K46 + 0x88300107, // 0040 GETMBR R12 R0 K7 + 0x88340101, // 0041 GETMBR R13 R0 K1 + 0x5C381000, // 0042 MOVE R14 R8 + 0x7C240A00, // 0043 CALL R9 5 + 0x80000000, // 0044 RET 0 }) ) ); @@ -1079,7 +1112,7 @@ be_local_closure(class_Matter_Plugin_contains_cluster, /* name */ &be_const_str_solidified, ( &(const binstruction[ 5]) { /* code */ 0x8808010F, // 0000 GETMBR R2 R0 K15 - 0x8C08052B, // 0001 GETMET R2 R2 K43 + 0x8C08052F, // 0001 GETMET R2 R2 K47 0x5C100200, // 0002 MOVE R4 R1 0x7C080400, // 0003 CALL R2 2 0x80040400, // 0004 RET 1 R2 @@ -1107,81 +1140,81 @@ be_local_closure(class_Matter_Plugin_read_attribute, /* name */ &be_const_str_solidified, ( &(const binstruction[169]) { /* code */ 0xB8122600, // 0000 GETNGBL R4 K19 - 0x8810092C, // 0001 GETMBR R4 R4 K44 - 0x8814052D, // 0002 GETMBR R5 R2 K45 - 0x8818052E, // 0003 GETMBR R6 R2 K46 + 0x88100930, // 0001 GETMBR R4 R4 K48 + 0x88140531, // 0002 GETMBR R5 R2 K49 + 0x88180532, // 0003 GETMBR R6 R2 K50 0x541E001C, // 0004 LDINT R7 29 0x1C1C0A07, // 0005 EQ R7 R5 R7 0x781E0050, // 0006 JMPF R7 #0058 0x1C1C0D23, // 0007 EQ R7 R6 K35 0x781E001B, // 0008 JMPF R7 #0025 - 0x8C1C092F, // 0009 GETMET R7 R4 K47 + 0x8C1C0933, // 0009 GETMET R7 R4 K51 0x7C1C0200, // 000A CALL R7 1 - 0x88200130, // 000B GETMBR R8 R0 K48 + 0x88200134, // 000B GETMBR R8 R0 K52 0x60240010, // 000C GETGBL R9 G16 - 0x8C281131, // 000D GETMET R10 R8 K49 + 0x8C281135, // 000D GETMET R10 R8 K53 0x7C280200, // 000E CALL R10 1 0x7C240200, // 000F CALL R9 1 0xA802000E, // 0010 EXBLK 0 #0020 0x5C281200, // 0011 MOVE R10 R9 0x7C280000, // 0012 CALL R10 0 - 0x8C2C0F32, // 0013 GETMET R11 R7 K50 + 0x8C2C0F36, // 0013 GETMET R11 R7 K54 0x7C2C0200, // 0014 CALL R11 1 - 0x8C301733, // 0015 GETMET R12 R11 K51 + 0x8C301737, // 0015 GETMET R12 R11 K55 0x58380023, // 0016 LDCONST R14 K35 - 0x883C0934, // 0017 GETMBR R15 R4 K52 + 0x883C0938, // 0017 GETMBR R15 R4 K56 0x5C401400, // 0018 MOVE R16 R10 0x7C300800, // 0019 CALL R12 4 - 0x8C301733, // 001A GETMET R12 R11 K51 + 0x8C301737, // 001A GETMET R12 R11 K55 0x58380026, // 001B LDCONST R14 K38 - 0x883C0934, // 001C GETMBR R15 R4 K52 + 0x883C0938, // 001C GETMBR R15 R4 K56 0x9440100A, // 001D GETIDX R16 R8 R10 0x7C300800, // 001E CALL R12 4 0x7001FFF0, // 001F JMP #0011 - 0x58240035, // 0020 LDCONST R9 K53 + 0x58240039, // 0020 LDCONST R9 K57 0xAC240200, // 0021 CATCH R9 1 0 0xB0080000, // 0022 RAISE 2 R0 R0 0x80040E00, // 0023 RET 1 R7 0x70020032, // 0024 JMP #0058 0x1C1C0D26, // 0025 EQ R7 R6 K38 0x781E0013, // 0026 JMPF R7 #003B - 0x8C1C092F, // 0027 GETMET R7 R4 K47 + 0x8C1C0933, // 0027 GETMET R7 R4 K51 0x7C1C0200, // 0028 CALL R7 1 0x60200010, // 0029 GETGBL R8 G16 - 0x8C240136, // 002A GETMET R9 R0 K54 + 0x8C24013A, // 002A GETMET R9 R0 K58 0x7C240200, // 002B CALL R9 1 0x7C200200, // 002C CALL R8 1 0xA8020007, // 002D EXBLK 0 #0036 0x5C241000, // 002E MOVE R9 R8 0x7C240000, // 002F CALL R9 0 - 0x8C280F33, // 0030 GETMET R10 R7 K51 + 0x8C280F37, // 0030 GETMET R10 R7 K55 0x4C300000, // 0031 LDNIL R12 - 0x88340937, // 0032 GETMBR R13 R4 K55 + 0x8834093B, // 0032 GETMBR R13 R4 K59 0x5C381200, // 0033 MOVE R14 R9 0x7C280800, // 0034 CALL R10 4 0x7001FFF7, // 0035 JMP #002E - 0x58200035, // 0036 LDCONST R8 K53 + 0x58200039, // 0036 LDCONST R8 K57 0xAC200200, // 0037 CATCH R8 1 0 0xB0080000, // 0038 RAISE 2 R0 R0 0x80040E00, // 0039 RET 1 R7 0x7002001C, // 003A JMP #0058 0x1C1C0D24, // 003B EQ R7 R6 K36 0x781E0003, // 003C JMPF R7 #0041 - 0x8C1C092F, // 003D GETMET R7 R4 K47 + 0x8C1C0933, // 003D GETMET R7 R4 K51 0x7C1C0200, // 003E CALL R7 1 0x80040E00, // 003F RET 1 R7 0x70020016, // 0040 JMP #0058 - 0x1C1C0D38, // 0041 EQ R7 R6 K56 + 0x1C1C0D3C, // 0041 EQ R7 R6 K60 0x781E0003, // 0042 JMPF R7 #0047 - 0x8C1C092F, // 0043 GETMET R7 R4 K47 + 0x8C1C0933, // 0043 GETMET R7 R4 K51 0x7C1C0200, // 0044 CALL R7 1 0x80040E00, // 0045 RET 1 R7 0x70020010, // 0046 JMP #0058 0x541EFFFB, // 0047 LDINT R7 65532 0x1C1C0C07, // 0048 EQ R7 R6 R7 0x781E0005, // 0049 JMPF R7 #0050 - 0x8C1C0739, // 004A GETMET R7 R3 K57 - 0x88240937, // 004B GETMBR R9 R4 K55 + 0x8C1C073D, // 004A GETMET R7 R3 K61 + 0x8824093B, // 004B GETMBR R9 R4 K59 0x58280023, // 004C LDCONST R10 K35 0x7C1C0600, // 004D CALL R7 3 0x80040E00, // 004E RET 1 R7 @@ -1189,24 +1222,24 @@ be_local_closure(class_Matter_Plugin_read_attribute, /* name */ 0x541EFFFC, // 0050 LDINT R7 65533 0x1C1C0C07, // 0051 EQ R7 R6 R7 0x781E0004, // 0052 JMPF R7 #0058 - 0x8C1C0739, // 0053 GETMET R7 R3 K57 - 0x88240937, // 0054 GETMBR R9 R4 K55 + 0x8C1C073D, // 0053 GETMET R7 R3 K61 + 0x8824093B, // 0054 GETMBR R9 R4 K59 0x58280026, // 0055 LDCONST R10 K38 0x7C1C0600, // 0056 CALL R7 3 0x80040E00, // 0057 RET 1 R7 0x541EFFF7, // 0058 LDINT R7 65528 0x1C1C0C07, // 0059 EQ R7 R6 R7 0x781E0003, // 005A JMPF R7 #005F - 0x8C1C092F, // 005B GETMET R7 R4 K47 + 0x8C1C0933, // 005B GETMET R7 R4 K51 0x7C1C0200, // 005C CALL R7 1 0x80040E00, // 005D RET 1 R7 0x70020047, // 005E JMP #00A7 0x541EFFFA, // 005F LDINT R7 65531 0x1C1C0C07, // 0060 EQ R7 R6 R7 0x781E001B, // 0061 JMPF R7 #007E - 0x8C1C092F, // 0062 GETMET R7 R4 K47 + 0x8C1C0933, // 0062 GETMET R7 R4 K51 0x7C1C0200, // 0063 CALL R7 1 - 0x8C20013A, // 0064 GETMET R8 R0 K58 + 0x8C20013E, // 0064 GETMET R8 R0 K62 0x5C280A00, // 0065 MOVE R10 R5 0x7C200400, // 0066 CALL R8 2 0x4C240000, // 0067 LDNIL R9 @@ -1220,9 +1253,9 @@ be_local_closure(class_Matter_Plugin_read_attribute, /* name */ 0x58280023, // 006F LDCONST R10 K35 0x142C1409, // 0070 LT R11 R10 R9 0x782E0009, // 0071 JMPF R11 #007C - 0x8C2C0F33, // 0072 GETMET R11 R7 K51 + 0x8C2C0F37, // 0072 GETMET R11 R7 K55 0x4C340000, // 0073 LDNIL R13 - 0x88380934, // 0074 GETMBR R14 R4 K52 + 0x88380938, // 0074 GETMBR R14 R4 K56 0x8C3C1125, // 0075 GETMET R15 R8 K37 0x08441524, // 0076 MUL R17 R10 K36 0x5449FFFD, // 0077 LDINT R18 -2 @@ -1235,27 +1268,27 @@ be_local_closure(class_Matter_Plugin_read_attribute, /* name */ 0x541EFFF9, // 007E LDINT R7 65530 0x1C1C0C07, // 007F EQ R7 R6 R7 0x781E0003, // 0080 JMPF R7 #0085 - 0x8C1C092F, // 0081 GETMET R7 R4 K47 + 0x8C1C0933, // 0081 GETMET R7 R4 K51 0x7C1C0200, // 0082 CALL R7 1 0x80040E00, // 0083 RET 1 R7 0x70020021, // 0084 JMP #00A7 0x541EFFF8, // 0085 LDINT R7 65529 0x1C1C0C07, // 0086 EQ R7 R6 R7 0x781E0003, // 0087 JMPF R7 #008C - 0x8C1C092F, // 0088 GETMET R7 R4 K47 + 0x8C1C0933, // 0088 GETMET R7 R4 K51 0x7C1C0200, // 0089 CALL R7 1 0x80040E00, // 008A RET 1 R7 0x7002001A, // 008B JMP #00A7 0x541EFFFB, // 008C LDINT R7 65532 0x1C1C0C07, // 008D EQ R7 R6 R7 0x781E000A, // 008E JMPF R7 #009A - 0x881C013B, // 008F GETMBR R7 R0 K59 + 0x881C013F, // 008F GETMBR R7 R0 K63 0x8C1C0F10, // 0090 GETMET R7 R7 K16 0x5C240A00, // 0091 MOVE R9 R5 0x58280023, // 0092 LDCONST R10 K35 0x7C1C0600, // 0093 CALL R7 3 - 0x8C200739, // 0094 GETMET R8 R3 K57 - 0x88280937, // 0095 GETMBR R10 R4 K55 + 0x8C20073D, // 0094 GETMET R8 R3 K61 + 0x8828093B, // 0095 GETMBR R10 R4 K59 0x5C2C0E00, // 0096 MOVE R11 R7 0x7C200600, // 0097 CALL R8 3 0x80041000, // 0098 RET 1 R8 @@ -1263,13 +1296,13 @@ be_local_closure(class_Matter_Plugin_read_attribute, /* name */ 0x541EFFFC, // 009A LDINT R7 65533 0x1C1C0C07, // 009B EQ R7 R6 R7 0x781E0009, // 009C JMPF R7 #00A7 - 0x881C013C, // 009D GETMBR R7 R0 K60 + 0x881C0140, // 009D GETMBR R7 R0 K64 0x8C1C0F10, // 009E GETMET R7 R7 K16 0x5C240A00, // 009F MOVE R9 R5 0x58280026, // 00A0 LDCONST R10 K38 0x7C1C0600, // 00A1 CALL R7 3 - 0x8C200739, // 00A2 GETMET R8 R3 K57 - 0x88280937, // 00A3 GETMBR R10 R4 K55 + 0x8C20073D, // 00A2 GETMET R8 R3 K61 + 0x8828093B, // 00A3 GETMBR R10 R4 K59 0x5C2C0E00, // 00A4 MOVE R11 R7 0x7C200600, // 00A5 CALL R8 3 0x80041000, // 00A6 RET 1 R8 diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_1_Device.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_1_Device.h index c8acbb92f..829d07578 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_1_Device.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_1_Device.h @@ -211,146 +211,156 @@ be_local_class(GetOptionReader, })), be_str_weak(GetOptionReader) ); -// compact class 'Matter_Plugin_Device' ktab size: 126, total: 164 (saved 304 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Device[126] = { +// compact class 'Matter_Plugin_Device' ktab size: 136, total: 180 (saved 352 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Device[136] = { /* K0 */ be_nested_str_weak(BRIDGE), - /* K1 */ be_nested_str_weak(http_remote), - /* K2 */ be_nested_str_weak(scheduler), - /* K3 */ be_nested_str_weak(every_250ms), - /* K4 */ be_nested_str_weak(webserver), - /* K5 */ be_nested_str_weak(web_values_prefix), - /* K6 */ be_nested_str_weak(content_send), - /* K7 */ be_nested_str_weak(_X26lt_X3B_X2D_X2D_X20_X28), - /* K8 */ be_nested_str_weak(DISPLAY_NAME), - /* K9 */ be_nested_str_weak(_X29_X20_X2D_X2D_X26gt_X3B), - /* K10 */ be_nested_str_weak(json), - /* K11 */ be_const_int(2), - /* K12 */ be_nested_str_weak(_X20), - /* K13 */ be_const_int(0), - /* K14 */ be_nested_str_weak(call_sync), - /* K15 */ be_nested_str_weak(SYNC_TIMEOUT), - /* K16 */ be_nested_str_weak(device_is_alive), - /* K17 */ be_nested_str_weak(load), - /* K18 */ be_const_int(1), - /* K19 */ be_nested_str_weak(log), - /* K20 */ be_nested_str_weak(MTR_X3A_X20HTTP_X20GET_X20retrying), - /* K21 */ be_const_int(3), - /* K22 */ be_nested_str_weak(ZIGBEE), - /* K23 */ be_nested_str_weak(zigbee_mapper), - /* K24 */ be_nested_str_weak(create_zb_mapper), - /* K25 */ be_nested_str_weak(init), - /* K26 */ be_nested_str_weak(find), - /* K27 */ be_nested_str_weak(ARG_HTTP), - /* K28 */ be_nested_str_weak(device), - /* K29 */ be_nested_str_weak(register_http_remote), - /* K30 */ be_nested_str_weak(PROBE_TIMEOUT), - /* K31 */ be_nested_str_weak(register_cmd_cb), - /* K32 */ be_nested_str_weak(matter), - /* K33 */ be_nested_str_weak(TLV), - /* K34 */ be_nested_str_weak(cluster), - /* K35 */ be_nested_str_weak(attribute), - /* K36 */ be_nested_str_weak(set), - /* K37 */ be_nested_str_weak(U2), - /* K38 */ be_nested_str_weak(U1), - /* K39 */ be_nested_str_weak(Matter_TLV_array), - /* K40 */ be_nested_str_weak(TYPES), - /* K41 */ be_nested_str_weak(keys), - /* K42 */ be_nested_str_weak(add_struct), - /* K43 */ be_nested_str_weak(add_TLV), - /* K44 */ be_nested_str_weak(stop_iteration), - /* K45 */ be_nested_str_weak(NON_BRIDGE_VENDOR), - /* K46 */ be_nested_str_weak(get_admin_vendor), - /* K47 */ be_nested_str_weak(disable_bridge_mode), - /* K48 */ be_nested_str_weak(string), - /* K49 */ be_nested_str_weak(get_info), - /* K50 */ be_nested_str_weak(name), - /* K51 */ be_nested_str_weak(set_or_nil), - /* K52 */ be_nested_str_weak(UTF1), - /* K53 */ be_nested_str_weak(tasmota), - /* K54 */ be_nested_str_weak(cmd), - /* K55 */ be_nested_str_weak(DeviceName), - /* K56 */ be_nested_str_weak(get_name), - /* K57 */ be_nested_str_weak(version), - /* K58 */ be_nested_str_weak(_X28), - /* K59 */ be_nested_str_weak(NULL), - /* K60 */ be_nested_str_weak(Status_X202), - /* K61 */ be_nested_str_weak(StatusFWR), - /* K62 */ be_nested_str_weak(Version), - /* K63 */ be_nested_str_weak(mac), - /* K64 */ be_nested_str_weak(wifi), - /* K65 */ be_nested_str_weak(), - /* K66 */ be_nested_str_weak(BOOL), - /* K67 */ be_nested_str_weak(reachable), - /* K68 */ be_nested_str_weak(read_attribute), - /* K69 */ be_nested_str_weak(parse_configuration), - /* K70 */ be_nested_str_weak(_X3Cb_X3EOn_X3C_X2Fb_X3E), - /* K71 */ be_nested_str_weak(Off), - /* K72 */ be_nested_str_weak(command), - /* K73 */ be_nested_str_weak(Matter_TLV_struct), - /* K74 */ be_nested_str_weak(invoke_request), - /* K75 */ be_nested_str_weak(tick), - /* K76 */ be_nested_str_weak(call_remote_sync), - /* K77 */ be_nested_str_weak(UPDATE_CMD), - /* K78 */ be_nested_str_weak(parse_http_response), - /* K79 */ be_nested_str_weak(PREFIX), - /* K80 */ be_nested_str_weak(html_escape), - /* K81 */ be_nested_str_weak(add_schedule), - /* K82 */ be_nested_str_weak(UPDATE_TIME), - /* K83 */ be_nested_str_weak(introspect), - /* K84 */ be_nested_str_weak(get), - /* K85 */ be_nested_str_weak(JSON_NAME), - /* K86 */ be_nested_str_weak(contains), - /* K87 */ be_nested_str_weak(shadow_value), - /* K88 */ be_nested_str_weak(dump), - /* K89 */ be_nested_str_weak(null), - /* K90 */ be_nested_str_weak(_X2C_X22_X25s_X22_X3A_X25s), - /* K91 */ be_nested_str_weak(shadow_onoff), - /* K92 */ be_nested_str_weak(Power), - /* K93 */ be_nested_str_weak(shadow_bri), - /* K94 */ be_nested_str_weak(Bri), - /* K95 */ be_nested_str_weak(shadow_ct), - /* K96 */ be_nested_str_weak(CT), - /* K97 */ be_nested_str_weak(shadow_hue), - /* K98 */ be_nested_str_weak(Hue), - /* K99 */ be_nested_str_weak(shadow_sat), - /* K100 */ be_nested_str_weak(Sat), - /* K101 */ be_nested_str_weak(shadow_shutter_pos), - /* K102 */ be_nested_str_weak(ShutterPos), - /* K103 */ be_nested_str_weak(shadow_shutter_target), - /* K104 */ be_nested_str_weak(ShutterTarget), - /* K105 */ be_nested_str_weak(shadow_shutter_tilt), - /* K106 */ be_nested_str_weak(ShutterTilt), - /* K107 */ be_nested_str_weak(shadow_contact), - /* K108 */ be_nested_str_weak(Contact), - /* K109 */ be_nested_str_weak(shadow_occupancy), - /* K110 */ be_nested_str_weak(Occupancy), - /* K111 */ be_nested_str_weak(shadow_air_quality), - /* K112 */ be_nested_str_weak(AirQuality), - /* K113 */ be_nested_str_weak(shadow_co2), - /* K114 */ be_nested_str_weak(CO2), - /* K115 */ be_nested_str_weak(shadow_pm1), - /* K116 */ be_nested_str_weak(PM1), - /* K117 */ be_nested_str_weak(shadow_pm2_5), - /* K118 */ be_nested_str_weak(PM2_X2E5), - /* K119 */ be_nested_str_weak(shadow_pm10), - /* K120 */ be_nested_str_weak(PM10), - /* K121 */ be_nested_str_weak(shadow_tvoc), - /* K122 */ be_nested_str_weak(TVOC), - /* K123 */ be_nested_str_weak(parse_status_response_and_call_method), - /* K124 */ be_nested_str_weak(parse_status), - /* K125 */ be_nested_str_weak(attribute_updated), + /* K1 */ be_nested_str_weak(json), + /* K2 */ be_const_int(2), + /* K3 */ be_nested_str_weak(_X20), + /* K4 */ be_const_int(0), + /* K5 */ be_nested_str_weak(http_remote), + /* K6 */ be_nested_str_weak(call_sync), + /* K7 */ be_nested_str_weak(SYNC_TIMEOUT), + /* K8 */ be_nested_str_weak(device_is_alive), + /* K9 */ be_nested_str_weak(load), + /* K10 */ be_const_int(1), + /* K11 */ be_nested_str_weak(log), + /* K12 */ be_nested_str_weak(MTR_X3A_X20HTTP_X20GET_X20retrying), + /* K13 */ be_const_int(3), + /* K14 */ be_nested_str_weak(webserver), + /* K15 */ be_nested_str_weak(web_values_prefix), + /* K16 */ be_nested_str_weak(content_send), + /* K17 */ be_nested_str_weak(_X26lt_X3B_X2D_X2D_X20_X28), + /* K18 */ be_nested_str_weak(DISPLAY_NAME), + /* K19 */ be_nested_str_weak(_X29_X20_X2D_X2D_X26gt_X3B), + /* K20 */ be_nested_str_weak(tick), + /* K21 */ be_nested_str_weak(device), + /* K22 */ be_nested_str_weak(parse_status_response_and_call_method), + /* K23 */ be_nested_str_weak(parse_status), + /* K24 */ be_nested_str_weak(add_schedule), + /* K25 */ be_nested_str_weak(UPDATE_CMD), + /* K26 */ be_nested_str_weak(UPDATE_TIME), + /* K27 */ be_nested_str_weak(matter), + /* K28 */ be_nested_str_weak(TLV), + /* K29 */ be_nested_str_weak(cluster), + /* K30 */ be_nested_str_weak(command), + /* K31 */ be_nested_str_weak(Matter_TLV_struct), + /* K32 */ be_nested_str_weak(add_TLV), + /* K33 */ be_nested_str_weak(U2), + /* K34 */ be_nested_str_weak(invoke_request), + /* K35 */ be_nested_str_weak(scheduler), + /* K36 */ be_nested_str_weak(every_250ms), + /* K37 */ be_nested_str_weak(math), + /* K38 */ be_nested_str_weak(MTR_X3A_X20zigbee_received_X20Ox_X2504X_X20attr_list_X3D_X25s_X20type_X28attr_list_X29_X3D_X25s), + /* K39 */ be_nested_str_weak(zigbee_mapper), + /* K40 */ be_nested_str_weak(shortaddr), + /* K41 */ be_nested_str_weak(key), + /* K42 */ be_nested_str_weak(ZIGBEE_NAME), + /* K43 */ be_nested_str_weak(pre_value), + /* K44 */ be_nested_str_weak(val), + /* K45 */ be_nested_str_weak(JSON_NAME), + /* K46 */ be_nested_str_weak(update_virtual), + /* K47 */ be_nested_str_weak(MTR_X3A_X20_X5B_X2502X_X5D_X20_X25s_X20updated_X20_X25s), + /* K48 */ be_nested_str_weak(endpoint), + /* K49 */ be_nested_str_weak(get_name), + /* K50 */ be_nested_str_weak(PREFIX), + /* K51 */ be_nested_str_weak(html_escape), + /* K52 */ be_nested_str_weak(), + /* K53 */ be_nested_str_weak(ZIGBEE), + /* K54 */ be_nested_str_weak(create_zb_mapper), + /* K55 */ be_nested_str_weak(init), + /* K56 */ be_nested_str_weak(find), + /* K57 */ be_nested_str_weak(ARG_HTTP), + /* K58 */ be_nested_str_weak(register_http_remote), + /* K59 */ be_nested_str_weak(PROBE_TIMEOUT), + /* K60 */ be_nested_str_weak(register_cmd_cb), + /* K61 */ be_nested_str_weak(attribute), + /* K62 */ be_nested_str_weak(set), + /* K63 */ be_nested_str_weak(U1), + /* K64 */ be_nested_str_weak(Matter_TLV_array), + /* K65 */ be_nested_str_weak(TYPES), + /* K66 */ be_nested_str_weak(keys), + /* K67 */ be_nested_str_weak(add_struct), + /* K68 */ be_nested_str_weak(stop_iteration), + /* K69 */ be_nested_str_weak(NON_BRIDGE_VENDOR), + /* K70 */ be_nested_str_weak(get_admin_vendor), + /* K71 */ be_nested_str_weak(disable_bridge_mode), + /* K72 */ be_nested_str_weak(string), + /* K73 */ be_nested_str_weak(get_info), + /* K74 */ be_nested_str_weak(name), + /* K75 */ be_nested_str_weak(set_or_nil), + /* K76 */ be_nested_str_weak(UTF1), + /* K77 */ be_nested_str_weak(tasmota), + /* K78 */ be_nested_str_weak(cmd), + /* K79 */ be_nested_str_weak(DeviceName), + /* K80 */ be_nested_str_weak(version), + /* K81 */ be_nested_str_weak(_X28), + /* K82 */ be_nested_str_weak(NULL), + /* K83 */ be_nested_str_weak(Status_X202), + /* K84 */ be_nested_str_weak(StatusFWR), + /* K85 */ be_nested_str_weak(Version), + /* K86 */ be_nested_str_weak(mac), + /* K87 */ be_nested_str_weak(wifi), + /* K88 */ be_nested_str_weak(BOOL), + /* K89 */ be_nested_str_weak(reachable), + /* K90 */ be_nested_str_weak(read_attribute), + /* K91 */ be_nested_str_weak(call_remote_sync), + /* K92 */ be_nested_str_weak(parse_http_response), + /* K93 */ be_nested_str_weak(_X3Cb_X3EOn_X3C_X2Fb_X3E), + /* K94 */ be_nested_str_weak(Off), + /* K95 */ be_nested_str_weak(introspect), + /* K96 */ be_nested_str_weak(get), + /* K97 */ be_nested_str_weak(contains), + /* K98 */ be_nested_str_weak(shadow_value), + /* K99 */ be_nested_str_weak(dump), + /* K100 */ be_nested_str_weak(null), + /* K101 */ be_nested_str_weak(_X2C_X22_X25s_X22_X3A_X25s), + /* K102 */ be_nested_str_weak(shadow_onoff), + /* K103 */ be_nested_str_weak(Power), + /* K104 */ be_nested_str_weak(shadow_bri), + /* K105 */ be_nested_str_weak(Bri), + /* K106 */ be_nested_str_weak(shadow_ct), + /* K107 */ be_nested_str_weak(CT), + /* K108 */ be_nested_str_weak(shadow_hue), + /* K109 */ be_nested_str_weak(Hue), + /* K110 */ be_nested_str_weak(shadow_sat), + /* K111 */ be_nested_str_weak(Sat), + /* K112 */ be_nested_str_weak(shadow_shutter_pos), + /* K113 */ be_nested_str_weak(ShutterPos), + /* K114 */ be_nested_str_weak(shadow_shutter_target), + /* K115 */ be_nested_str_weak(ShutterTarget), + /* K116 */ be_nested_str_weak(shadow_shutter_tilt), + /* K117 */ be_nested_str_weak(ShutterTilt), + /* K118 */ be_nested_str_weak(shadow_contact), + /* K119 */ be_nested_str_weak(Contact), + /* K120 */ be_nested_str_weak(shadow_occupancy), + /* K121 */ be_nested_str_weak(Occupancy), + /* K122 */ be_nested_str_weak(shadow_air_quality), + /* K123 */ be_nested_str_weak(AirQuality), + /* K124 */ be_nested_str_weak(shadow_co2), + /* K125 */ be_nested_str_weak(CO2), + /* K126 */ be_nested_str_weak(shadow_pm1), + /* K127 */ be_nested_str_weak(PM1), + /* K128 */ be_nested_str_weak(shadow_pm2_5), + /* K129 */ be_nested_str_weak(PM2_X2E5), + /* K130 */ be_nested_str_weak(shadow_pm10), + /* K131 */ be_nested_str_weak(PM10), + /* K132 */ be_nested_str_weak(shadow_tvoc), + /* K133 */ be_nested_str_weak(TVOC), + /* K134 */ be_nested_str_weak(parse_configuration), + /* K135 */ be_nested_str_weak(attribute_updated), }; extern const bclass be_class_Matter_Plugin_Device; /******************************************************************** -** Solidified function: every_250ms +** Solidified function: pre_value ********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_every_250ms, /* name */ +be_local_closure(class_Matter_Plugin_Device_pre_value, /* name */ be_nested_proto( - 3, /* nstack */ - 1, /* argc */ + 2, /* nstack */ + 2, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -358,77 +368,10 @@ be_local_closure(class_Matter_Plugin_Device_every_250ms, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(every_250ms), - &be_const_str_solidified, - ( &(const binstruction[12]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x78060003, // 0001 JMPF R1 #0006 - 0x88040101, // 0002 GETMBR R1 R0 K1 - 0x8C040302, // 0003 GETMET R1 R1 K2 - 0x7C040200, // 0004 CALL R1 1 - 0x70020004, // 0005 JMP #000B - 0x60040003, // 0006 GETGBL R1 G3 - 0x5C080000, // 0007 MOVE R2 R0 - 0x7C040200, // 0008 CALL R1 1 - 0x8C040303, // 0009 GETMET R1 R1 K3 - 0x7C040200, // 000A CALL R1 1 - 0x80000000, // 000B RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: web_values -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_web_values, /* name */ - be_nested_proto( - 5, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(web_values), - &be_const_str_solidified, - ( &(const binstruction[ 9]) { /* code */ - 0xA4060800, // 0000 IMPORT R1 K4 - 0x8C080105, // 0001 GETMET R2 R0 K5 - 0x7C080200, // 0002 CALL R2 1 - 0x8C080306, // 0003 GETMET R2 R1 K6 - 0x88100108, // 0004 GETMBR R4 R0 K8 - 0x00120E04, // 0005 ADD R4 K7 R4 - 0x00100909, // 0006 ADD R4 R4 K9 - 0x7C080400, // 0007 CALL R2 2 - 0x80000000, // 0008 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: parse_status -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_parse_status, /* name */ - be_nested_proto( - 3, /* nstack */ - 3, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(parse_status), + be_str_weak(pre_value), &be_const_str_solidified, ( &(const binstruction[ 1]) { /* code */ - 0x80000000, // 0000 RET 0 + 0x80040200, // 0000 RET 1 R1 }) ) ); @@ -454,43 +397,43 @@ be_local_closure(class_Matter_Plugin_Device_call_remote_sync, /* name */ ( &(const binstruction[44]) { /* code */ 0x880C0100, // 0000 GETMBR R3 R0 K0 0x780E0028, // 0001 JMPF R3 #002B - 0xA40E1400, // 0002 IMPORT R3 K10 - 0x5810000B, // 0003 LDCONST R4 K11 + 0xA40E0200, // 0002 IMPORT R3 K1 + 0x58100002, // 0003 LDCONST R4 K2 0x4C140000, // 0004 LDNIL R5 0x20140405, // 0005 NE R5 R2 R5 0x78160005, // 0006 JMPF R5 #000D - 0x0014030C, // 0007 ADD R5 R1 K12 + 0x00140303, // 0007 ADD R5 R1 K3 0x60180008, // 0008 GETGBL R6 G8 0x5C1C0400, // 0009 MOVE R7 R2 0x7C180200, // 000A CALL R6 1 0x00140A06, // 000B ADD R5 R5 R6 0x5C040A00, // 000C MOVE R1 R5 - 0x2414090D, // 000D GT R5 R4 K13 + 0x24140904, // 000D GT R5 R4 K4 0x78160015, // 000E JMPF R5 #0025 - 0x88140101, // 000F GETMBR R5 R0 K1 - 0x8C140B0E, // 0010 GETMET R5 R5 K14 + 0x88140105, // 000F GETMBR R5 R0 K5 + 0x8C140B06, // 0010 GETMET R5 R5 K6 0x5C1C0200, // 0011 MOVE R7 R1 - 0x8820010F, // 0012 GETMBR R8 R0 K15 + 0x88200107, // 0012 GETMBR R8 R0 K7 0x7C140600, // 0013 CALL R5 3 0x4C180000, // 0014 LDNIL R6 0x20180A06, // 0015 NE R6 R5 R6 0x781A0007, // 0016 JMPF R6 #001F - 0x88180101, // 0017 GETMBR R6 R0 K1 - 0x8C180D10, // 0018 GETMET R6 R6 K16 + 0x88180105, // 0017 GETMBR R6 R0 K5 + 0x8C180D08, // 0018 GETMET R6 R6 K8 0x50200200, // 0019 LDBOOL R8 1 0 0x7C180400, // 001A CALL R6 2 - 0x8C180711, // 001B GETMET R6 R3 K17 + 0x8C180709, // 001B GETMET R6 R3 K9 0x5C200A00, // 001C MOVE R8 R5 0x7C180400, // 001D CALL R6 2 0x80040C00, // 001E RET 1 R6 - 0x04100912, // 001F SUB R4 R4 K18 - 0xB81A2600, // 0020 GETNGBL R6 K19 - 0x581C0014, // 0021 LDCONST R7 K20 - 0x58200015, // 0022 LDCONST R8 K21 + 0x0410090A, // 001F SUB R4 R4 K10 + 0xB81A1600, // 0020 GETNGBL R6 K11 + 0x581C000C, // 0021 LDCONST R7 K12 + 0x5820000D, // 0022 LDCONST R8 K13 0x7C180400, // 0023 CALL R6 2 0x7001FFE7, // 0024 JMP #000D - 0x88140101, // 0025 GETMBR R5 R0 K1 - 0x8C140B10, // 0026 GETMET R5 R5 K16 + 0x88140105, // 0025 GETMBR R5 R0 K5 + 0x8C140B08, // 0026 GETMET R5 R5 K8 0x501C0000, // 0027 LDBOOL R7 0 0 0x7C140400, // 0028 CALL R5 2 0x4C140000, // 0029 LDNIL R5 @@ -503,330 +446,12 @@ be_local_closure(class_Matter_Plugin_Device_call_remote_sync, /* name */ /******************************************************************** -** Solidified function: init +** Solidified function: web_values ********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_init, /* name */ - be_nested_proto( - 9, /* nstack */ - 4, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[28]) { /* code */ - 0x88100116, // 0000 GETMBR R4 R0 K22 - 0x78120003, // 0001 JMPF R4 #0006 - 0x8C100318, // 0002 GETMET R4 R1 K24 - 0x5C180000, // 0003 MOVE R6 R0 - 0x7C100400, // 0004 CALL R4 2 - 0x90022E04, // 0005 SETMBR R0 K23 R4 - 0x60100003, // 0006 GETGBL R4 G3 - 0x5C140000, // 0007 MOVE R5 R0 - 0x7C100200, // 0008 CALL R4 1 - 0x8C100919, // 0009 GETMET R4 R4 K25 - 0x5C180200, // 000A MOVE R6 R1 - 0x5C1C0400, // 000B MOVE R7 R2 - 0x5C200600, // 000C MOVE R8 R3 - 0x7C100800, // 000D CALL R4 4 - 0x88100100, // 000E GETMBR R4 R0 K0 - 0x7812000A, // 000F JMPF R4 #001B - 0x8C10071A, // 0010 GETMET R4 R3 K26 - 0x8818011B, // 0011 GETMBR R6 R0 K27 - 0x7C100400, // 0012 CALL R4 2 - 0x8814011C, // 0013 GETMBR R5 R0 K28 - 0x8C140B1D, // 0014 GETMET R5 R5 K29 - 0x5C1C0800, // 0015 MOVE R7 R4 - 0x8820011E, // 0016 GETMBR R8 R0 K30 - 0x7C140600, // 0017 CALL R5 3 - 0x90020205, // 0018 SETMBR R0 K1 R5 - 0x8C14011F, // 0019 GETMET R5 R0 K31 - 0x7C140200, // 001A CALL R5 1 - 0x80000000, // 001B RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: read_attribute -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_read_attribute, /* name */ - be_nested_proto( - 17, /* nstack */ - 4, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(read_attribute), - &be_const_str_solidified, - ( &(const binstruction[244]) { /* code */ - 0xB8124000, // 0000 GETNGBL R4 K32 - 0x88100921, // 0001 GETMBR R4 R4 K33 - 0x88140522, // 0002 GETMBR R5 R2 K34 - 0x88180523, // 0003 GETMBR R6 R2 K35 - 0x1C1C0B15, // 0004 EQ R7 R5 K21 - 0x781E000F, // 0005 JMPF R7 #0016 - 0x1C1C0D0D, // 0006 EQ R7 R6 K13 - 0x781E0005, // 0007 JMPF R7 #000E - 0x8C1C0724, // 0008 GETMET R7 R3 K36 - 0x88240925, // 0009 GETMBR R9 R4 K37 - 0x5828000D, // 000A LDCONST R10 K13 - 0x7C1C0600, // 000B CALL R7 3 - 0x80040E00, // 000C RET 1 R7 - 0x70020006, // 000D JMP #0015 - 0x1C1C0D12, // 000E EQ R7 R6 K18 - 0x781E0004, // 000F JMPF R7 #0015 - 0x8C1C0724, // 0010 GETMET R7 R3 K36 - 0x88240926, // 0011 GETMBR R9 R4 K38 - 0x5828000D, // 0012 LDCONST R10 K13 - 0x7C1C0600, // 0013 CALL R7 3 - 0x80040E00, // 0014 RET 1 R7 - 0x700200D4, // 0015 JMP #00EB - 0x541E0003, // 0016 LDINT R7 4 - 0x1C1C0A07, // 0017 EQ R7 R5 R7 - 0x781E0004, // 0018 JMPF R7 #001E - 0x1C1C0D0D, // 0019 EQ R7 R6 K13 - 0x781E0001, // 001A JMPF R7 #001D - 0x4C1C0000, // 001B LDNIL R7 - 0x80040E00, // 001C RET 1 R7 - 0x700200CC, // 001D JMP #00EB - 0x541E0004, // 001E LDINT R7 5 - 0x1C1C0A07, // 001F EQ R7 R5 R7 - 0x781E0000, // 0020 JMPF R7 #0022 - 0x700200C8, // 0021 JMP #00EB - 0x541E001C, // 0022 LDINT R7 29 - 0x1C1C0A07, // 0023 EQ R7 R5 R7 - 0x781E0034, // 0024 JMPF R7 #005A - 0x1C1C0D0D, // 0025 EQ R7 R6 K13 - 0x781E0031, // 0026 JMPF R7 #0059 - 0x8C1C0927, // 0027 GETMET R7 R4 K39 - 0x7C1C0200, // 0028 CALL R7 1 - 0x88200128, // 0029 GETMBR R8 R0 K40 - 0x60240010, // 002A GETGBL R9 G16 - 0x8C281129, // 002B GETMET R10 R8 K41 - 0x7C280200, // 002C CALL R10 1 - 0x7C240200, // 002D CALL R9 1 - 0xA802000E, // 002E EXBLK 0 #003E - 0x5C281200, // 002F MOVE R10 R9 - 0x7C280000, // 0030 CALL R10 0 - 0x8C2C0F2A, // 0031 GETMET R11 R7 K42 - 0x7C2C0200, // 0032 CALL R11 1 - 0x8C30172B, // 0033 GETMET R12 R11 K43 - 0x5838000D, // 0034 LDCONST R14 K13 - 0x883C0925, // 0035 GETMBR R15 R4 K37 - 0x5C401400, // 0036 MOVE R16 R10 - 0x7C300800, // 0037 CALL R12 4 - 0x8C30172B, // 0038 GETMET R12 R11 K43 - 0x58380012, // 0039 LDCONST R14 K18 - 0x883C0925, // 003A GETMBR R15 R4 K37 - 0x9440100A, // 003B GETIDX R16 R8 R10 - 0x7C300800, // 003C CALL R12 4 - 0x7001FFF0, // 003D JMP #002F - 0x5824002C, // 003E LDCONST R9 K44 - 0xAC240200, // 003F CATCH R9 1 0 - 0xB0080000, // 0040 RAISE 2 R0 R0 - 0x8824012D, // 0041 GETMBR R9 R0 K45 - 0x8C24131A, // 0042 GETMET R9 R9 K26 - 0x8C2C032E, // 0043 GETMET R11 R1 K46 - 0x7C2C0200, // 0044 CALL R11 1 - 0x7C240400, // 0045 CALL R9 2 - 0x4C280000, // 0046 LDNIL R10 - 0x1C24120A, // 0047 EQ R9 R9 R10 - 0x7826000E, // 0048 JMPF R9 #0058 - 0x8824011C, // 0049 GETMBR R9 R0 K28 - 0x8824132F, // 004A GETMBR R9 R9 K47 - 0x7426000B, // 004B JMPT R9 #0058 - 0x8C240F2A, // 004C GETMET R9 R7 K42 - 0x7C240200, // 004D CALL R9 1 - 0x8C28132B, // 004E GETMET R10 R9 K43 - 0x5830000D, // 004F LDCONST R12 K13 - 0x88340925, // 0050 GETMBR R13 R4 K37 - 0x543A0012, // 0051 LDINT R14 19 - 0x7C280800, // 0052 CALL R10 4 - 0x8C28132B, // 0053 GETMET R10 R9 K43 - 0x58300012, // 0054 LDCONST R12 K18 - 0x88340925, // 0055 GETMBR R13 R4 K37 - 0x58380012, // 0056 LDCONST R14 K18 - 0x7C280800, // 0057 CALL R10 4 - 0x80040E00, // 0058 RET 1 R7 - 0x70020090, // 0059 JMP #00EB - 0x541E0038, // 005A LDINT R7 57 - 0x1C1C0A07, // 005B EQ R7 R5 R7 - 0x781E008D, // 005C JMPF R7 #00EB - 0xA41E6000, // 005D IMPORT R7 K48 - 0x1C200D15, // 005E EQ R8 R6 K21 - 0x78220018, // 005F JMPF R8 #0079 - 0x88200100, // 0060 GETMBR R8 R0 K0 - 0x7822000B, // 0061 JMPF R8 #006E - 0x88200101, // 0062 GETMBR R8 R0 K1 - 0x8C201131, // 0063 GETMET R8 R8 K49 - 0x7C200200, // 0064 CALL R8 1 - 0x8C20111A, // 0065 GETMET R8 R8 K26 - 0x58280032, // 0066 LDCONST R10 K50 - 0x7C200400, // 0067 CALL R8 2 - 0x8C240733, // 0068 GETMET R9 R3 K51 - 0x882C0934, // 0069 GETMBR R11 R4 K52 - 0x5C301000, // 006A MOVE R12 R8 - 0x7C240600, // 006B CALL R9 3 - 0x80041200, // 006C RET 1 R9 - 0x70020009, // 006D JMP #0078 - 0x8C200724, // 006E GETMET R8 R3 K36 - 0x88280934, // 006F GETMBR R10 R4 K52 - 0xB82E6A00, // 0070 GETNGBL R11 K53 - 0x8C2C1736, // 0071 GETMET R11 R11 K54 - 0x58340037, // 0072 LDCONST R13 K55 - 0x50380200, // 0073 LDBOOL R14 1 0 - 0x7C2C0600, // 0074 CALL R11 3 - 0x942C1737, // 0075 GETIDX R11 R11 K55 - 0x7C200600, // 0076 CALL R8 3 - 0x80041000, // 0077 RET 1 R8 - 0x70020071, // 0078 JMP #00EB - 0x54220004, // 0079 LDINT R8 5 - 0x1C200C08, // 007A EQ R8 R6 R8 - 0x78220006, // 007B JMPF R8 #0083 - 0x8C200724, // 007C GETMET R8 R3 K36 - 0x88280934, // 007D GETMBR R10 R4 K52 - 0x8C2C0138, // 007E GETMET R11 R0 K56 - 0x7C2C0200, // 007F CALL R11 1 - 0x7C200600, // 0080 CALL R8 3 - 0x80041000, // 0081 RET 1 R8 - 0x70020067, // 0082 JMP #00EB - 0x54220009, // 0083 LDINT R8 10 - 0x1C200C08, // 0084 EQ R8 R6 R8 - 0x78220033, // 0085 JMPF R8 #00BA - 0x88200100, // 0086 GETMBR R8 R0 K0 - 0x7822001B, // 0087 JMPF R8 #00A4 - 0x88200101, // 0088 GETMBR R8 R0 K1 - 0x8C201131, // 0089 GETMET R8 R8 K49 - 0x7C200200, // 008A CALL R8 1 - 0x8C20111A, // 008B GETMET R8 R8 K26 - 0x58280039, // 008C LDCONST R10 K57 - 0x7C200400, // 008D CALL R8 2 - 0x7822000E, // 008E JMPF R8 #009E - 0x8C240F1A, // 008F GETMET R9 R7 K26 - 0x5C2C1000, // 0090 MOVE R11 R8 - 0x5830003A, // 0091 LDCONST R12 K58 - 0x7C240600, // 0092 CALL R9 3 - 0x2428130D, // 0093 GT R10 R9 K13 - 0x782A0002, // 0094 JMPF R10 #0098 - 0x04281312, // 0095 SUB R10 R9 K18 - 0x402A1A0A, // 0096 CONNECT R10 K13 R10 - 0x9420100A, // 0097 GETIDX R8 R8 R10 - 0x8C280724, // 0098 GETMET R10 R3 K36 - 0x88300934, // 0099 GETMBR R12 R4 K52 - 0x5C341000, // 009A MOVE R13 R8 - 0x7C280600, // 009B CALL R10 3 - 0x80041400, // 009C RET 1 R10 - 0x70020004, // 009D JMP #00A3 - 0x8C240724, // 009E GETMET R9 R3 K36 - 0x882C093B, // 009F GETMBR R11 R4 K59 - 0x4C300000, // 00A0 LDNIL R12 - 0x7C240600, // 00A1 CALL R9 3 - 0x80041200, // 00A2 RET 1 R9 - 0x70020014, // 00A3 JMP #00B9 - 0xB8226A00, // 00A4 GETNGBL R8 K53 - 0x8C201136, // 00A5 GETMET R8 R8 K54 - 0x5828003C, // 00A6 LDCONST R10 K60 - 0x502C0200, // 00A7 LDBOOL R11 1 0 - 0x7C200600, // 00A8 CALL R8 3 - 0x9420113D, // 00A9 GETIDX R8 R8 K61 - 0x9420113E, // 00AA GETIDX R8 R8 K62 - 0x8C240F1A, // 00AB GETMET R9 R7 K26 - 0x5C2C1000, // 00AC MOVE R11 R8 - 0x5830003A, // 00AD LDCONST R12 K58 - 0x7C240600, // 00AE CALL R9 3 - 0x2428130D, // 00AF GT R10 R9 K13 - 0x782A0002, // 00B0 JMPF R10 #00B4 - 0x04281312, // 00B1 SUB R10 R9 K18 - 0x402A1A0A, // 00B2 CONNECT R10 K13 R10 - 0x9420100A, // 00B3 GETIDX R8 R8 R10 - 0x8C280724, // 00B4 GETMET R10 R3 K36 - 0x88300934, // 00B5 GETMBR R12 R4 K52 - 0x5C341000, // 00B6 MOVE R13 R8 - 0x7C280600, // 00B7 CALL R10 3 - 0x80041400, // 00B8 RET 1 R10 - 0x70020030, // 00B9 JMP #00EB - 0x5422000E, // 00BA LDINT R8 15 - 0x1C200C08, // 00BB EQ R8 R6 R8 - 0x74220002, // 00BC JMPT R8 #00C0 - 0x54220011, // 00BD LDINT R8 18 - 0x1C200C08, // 00BE EQ R8 R6 R8 - 0x78220019, // 00BF JMPF R8 #00DA - 0x88200100, // 00C0 GETMBR R8 R0 K0 - 0x7822000B, // 00C1 JMPF R8 #00CE - 0x88200101, // 00C2 GETMBR R8 R0 K1 - 0x8C201131, // 00C3 GETMET R8 R8 K49 - 0x7C200200, // 00C4 CALL R8 1 - 0x8C20111A, // 00C5 GETMET R8 R8 K26 - 0x5828003F, // 00C6 LDCONST R10 K63 - 0x7C200400, // 00C7 CALL R8 2 - 0x8C240733, // 00C8 GETMET R9 R3 K51 - 0x882C0934, // 00C9 GETMBR R11 R4 K52 - 0x5C301000, // 00CA MOVE R12 R8 - 0x7C240600, // 00CB CALL R9 3 - 0x80041200, // 00CC RET 1 R9 - 0x7002000A, // 00CD JMP #00D9 - 0x8C200724, // 00CE GETMET R8 R3 K36 - 0x88280934, // 00CF GETMBR R10 R4 K52 - 0xB82E6A00, // 00D0 GETNGBL R11 K53 - 0x8C2C1740, // 00D1 GETMET R11 R11 K64 - 0x7C2C0200, // 00D2 CALL R11 1 - 0x8C2C171A, // 00D3 GETMET R11 R11 K26 - 0x5834003F, // 00D4 LDCONST R13 K63 - 0x58380041, // 00D5 LDCONST R14 K65 - 0x7C2C0600, // 00D6 CALL R11 3 - 0x7C200600, // 00D7 CALL R8 3 - 0x80041000, // 00D8 RET 1 R8 - 0x70020010, // 00D9 JMP #00EB - 0x54220010, // 00DA LDINT R8 17 - 0x1C200C08, // 00DB EQ R8 R6 R8 - 0x7822000D, // 00DC JMPF R8 #00EB - 0x88200100, // 00DD GETMBR R8 R0 K0 - 0x78220006, // 00DE JMPF R8 #00E6 - 0x8C200724, // 00DF GETMET R8 R3 K36 - 0x88280942, // 00E0 GETMBR R10 R4 K66 - 0x882C0101, // 00E1 GETMBR R11 R0 K1 - 0x882C1743, // 00E2 GETMBR R11 R11 K67 - 0x7C200600, // 00E3 CALL R8 3 - 0x80041000, // 00E4 RET 1 R8 - 0x70020004, // 00E5 JMP #00EB - 0x8C200724, // 00E6 GETMET R8 R3 K36 - 0x88280942, // 00E7 GETMBR R10 R4 K66 - 0x582C0012, // 00E8 LDCONST R11 K18 - 0x7C200600, // 00E9 CALL R8 3 - 0x80041000, // 00EA RET 1 R8 - 0x601C0003, // 00EB GETGBL R7 G3 - 0x5C200000, // 00EC MOVE R8 R0 - 0x7C1C0200, // 00ED CALL R7 1 - 0x8C1C0F44, // 00EE GETMET R7 R7 K68 - 0x5C240200, // 00EF MOVE R9 R1 - 0x5C280400, // 00F0 MOVE R10 R2 - 0x5C2C0600, // 00F1 MOVE R11 R3 - 0x7C1C0800, // 00F2 CALL R7 4 - 0x80040E00, // 00F3 RET 1 R7 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: parse_configuration -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_parse_configuration, /* name */ +be_local_closure(class_Matter_Plugin_Device_web_values, /* name */ be_nested_proto( 5, /* nstack */ - 2, /* argc */ + 1, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -834,16 +459,16 @@ be_local_closure(class_Matter_Plugin_Device_parse_configuration, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(parse_configuration), + be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[ 9]) { /* code */ - 0x88080116, // 0000 GETMBR R2 R0 K22 - 0x780A0005, // 0001 JMPF R2 #0008 - 0x88080117, // 0002 GETMBR R2 R0 K23 - 0x780A0003, // 0003 JMPF R2 #0008 - 0x88080117, // 0004 GETMBR R2 R0 K23 - 0x8C080545, // 0005 GETMET R2 R2 K69 - 0x5C100200, // 0006 MOVE R4 R1 + 0xA4061C00, // 0000 IMPORT R1 K14 + 0x8C08010F, // 0001 GETMET R2 R0 K15 + 0x7C080200, // 0002 CALL R2 1 + 0x8C080310, // 0003 GETMET R2 R1 K16 + 0x88100112, // 0004 GETMBR R4 R0 K18 + 0x00122204, // 0005 ADD R4 K17 R4 + 0x00100913, // 0006 ADD R4 R4 K19 0x7C080400, // 0007 CALL R2 2 0x80000000, // 0008 RET 0 }) @@ -853,44 +478,11 @@ be_local_closure(class_Matter_Plugin_Device_parse_configuration, /* name */ /******************************************************************** -** Solidified function: web_value_onoff +** Solidified function: parse_http_response ********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_web_value_onoff, /* name */ +be_local_closure(class_Matter_Plugin_Device_parse_http_response, /* name */ be_nested_proto( - 3, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(web_value_onoff), - &be_const_str_solidified, - ( &(const binstruction[10]) { /* code */ - 0x4C080000, // 0000 LDNIL R2 - 0x20080202, // 0001 NE R2 R1 R2 - 0x780A0004, // 0002 JMPF R2 #0008 - 0x78060001, // 0003 JMPF R1 #0006 - 0x58080046, // 0004 LDCONST R2 K70 - 0x70020000, // 0005 JMP #0007 - 0x58080047, // 0006 LDCONST R2 K71 - 0x70020000, // 0007 JMP #0009 - 0x58080041, // 0008 LDCONST R2 K65 - 0x80040400, // 0009 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: invoke_request -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_invoke_request, /* name */ - be_nested_proto( - 13, /* nstack */ + 11, /* nstack */ 4, /* argc */ 10, /* varg */ 0, /* has upvals */ @@ -899,141 +491,23 @@ be_local_closure(class_Matter_Plugin_Device_invoke_request, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(invoke_request), + be_str_weak(parse_http_response), &be_const_str_solidified, - ( &(const binstruction[51]) { /* code */ - 0xB8124000, // 0000 GETNGBL R4 K32 - 0x88100921, // 0001 GETMBR R4 R4 K33 - 0x88140722, // 0002 GETMBR R5 R3 K34 - 0x88180748, // 0003 GETMBR R6 R3 K72 - 0x1C1C0B15, // 0004 EQ R7 R5 K21 - 0x781E0016, // 0005 JMPF R7 #001D - 0x1C1C0D0D, // 0006 EQ R7 R6 K13 - 0x781E0002, // 0007 JMPF R7 #000B - 0x501C0200, // 0008 LDBOOL R7 1 0 - 0x80040E00, // 0009 RET 1 R7 - 0x70020010, // 000A JMP #001C - 0x1C1C0D12, // 000B EQ R7 R6 K18 - 0x781E0009, // 000C JMPF R7 #0017 - 0x8C1C0949, // 000D GETMET R7 R4 K73 - 0x7C1C0200, // 000E CALL R7 1 - 0x8C200F2B, // 000F GETMET R8 R7 K43 - 0x5828000D, // 0010 LDCONST R10 K13 - 0x882C0925, // 0011 GETMBR R11 R4 K37 - 0x5830000D, // 0012 LDCONST R12 K13 - 0x7C200800, // 0013 CALL R8 4 - 0x900E910D, // 0014 SETMBR R3 K72 K13 - 0x80040E00, // 0015 RET 1 R7 - 0x70020004, // 0016 JMP #001C - 0x541E003F, // 0017 LDINT R7 64 - 0x1C1C0C07, // 0018 EQ R7 R6 R7 - 0x781E0001, // 0019 JMPF R7 #001C - 0x501C0200, // 001A LDBOOL R7 1 0 - 0x80040E00, // 001B RET 1 R7 - 0x70020014, // 001C JMP #0032 - 0x541E0003, // 001D LDINT R7 4 - 0x1C1C0A07, // 001E EQ R7 R5 R7 - 0x781E0002, // 001F JMPF R7 #0023 - 0x501C0200, // 0020 LDBOOL R7 1 0 - 0x80040E00, // 0021 RET 1 R7 - 0x7002000E, // 0022 JMP #0032 - 0x541E0004, // 0023 LDINT R7 5 - 0x1C1C0A07, // 0024 EQ R7 R5 R7 - 0x781E0002, // 0025 JMPF R7 #0029 - 0x501C0200, // 0026 LDBOOL R7 1 0 - 0x80040E00, // 0027 RET 1 R7 - 0x70020008, // 0028 JMP #0032 - 0x601C0003, // 0029 GETGBL R7 G3 - 0x5C200000, // 002A MOVE R8 R0 - 0x7C1C0200, // 002B CALL R7 1 - 0x8C1C0F4A, // 002C GETMET R7 R7 K74 - 0x5C240200, // 002D MOVE R9 R1 - 0x5C280400, // 002E MOVE R10 R2 - 0x5C2C0600, // 002F MOVE R11 R3 - 0x7C1C0800, // 0030 CALL R7 4 - 0x80040E00, // 0031 RET 1 R7 - 0x80000000, // 0032 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: update_shadow -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_update_shadow, /* name */ - be_nested_proto( - 7, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(update_shadow), - &be_const_str_solidified, - ( &(const binstruction[20]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x7806000D, // 0001 JMPF R1 #0010 - 0x8804014B, // 0002 GETMBR R1 R0 K75 - 0x8808011C, // 0003 GETMBR R2 R0 K28 - 0x8808054B, // 0004 GETMBR R2 R2 K75 - 0x20040202, // 0005 NE R1 R1 R2 - 0x78060008, // 0006 JMPF R1 #0010 - 0x8C04014C, // 0007 GETMET R1 R0 K76 - 0x880C014D, // 0008 GETMBR R3 R0 K77 - 0x7C040400, // 0009 CALL R1 2 - 0x78060004, // 000A JMPF R1 #0010 - 0x8C08014E, // 000B GETMET R2 R0 K78 - 0x58100012, // 000C LDCONST R4 K18 - 0x5C140200, // 000D MOVE R5 R1 - 0x8818014D, // 000E GETMBR R6 R0 K77 - 0x7C080800, // 000F CALL R2 4 - 0x8804011C, // 0010 GETMBR R1 R0 K28 - 0x8804034B, // 0011 GETMBR R1 R1 K75 - 0x90029601, // 0012 SETMBR R0 K75 R1 - 0x80000000, // 0013 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: web_values_prefix -********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_web_values_prefix, /* name */ - be_nested_proto( - 10, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(web_values_prefix), - &be_const_str_solidified, - ( &(const binstruction[15]) { /* code */ - 0xA4060800, // 0000 IMPORT R1 K4 - 0x8C080138, // 0001 GETMET R2 R0 K56 - 0x7C080200, // 0002 CALL R2 1 - 0x8C0C0306, // 0003 GETMET R3 R1 K6 - 0x60140018, // 0004 GETGBL R5 G24 - 0x8818014F, // 0005 GETMBR R6 R0 K79 - 0x780A0003, // 0006 JMPF R2 #000B - 0x8C1C0350, // 0007 GETMET R7 R1 K80 - 0x5C240400, // 0008 MOVE R9 R2 - 0x7C1C0400, // 0009 CALL R7 2 - 0x70020000, // 000A JMP #000C - 0x581C0041, // 000B LDCONST R7 K65 - 0x7C140400, // 000C CALL R5 2 - 0x7C0C0400, // 000D CALL R3 2 - 0x80000000, // 000E RET 0 + ( &(const binstruction[14]) { /* code */ + 0x88100100, // 0000 GETMBR R4 R0 K0 + 0x7812000A, // 0001 JMPF R4 #000D + 0x88100115, // 0002 GETMBR R4 R0 K21 + 0x88100914, // 0003 GETMBR R4 R4 K20 + 0x90022804, // 0004 SETMBR R0 K20 R4 + 0x88100105, // 0005 GETMBR R4 R0 K5 + 0x8C100916, // 0006 GETMET R4 R4 K22 + 0x5C180200, // 0007 MOVE R6 R1 + 0x5C1C0400, // 0008 MOVE R7 R2 + 0x5C200600, // 0009 MOVE R8 R3 + 0x5C240000, // 000A MOVE R9 R0 + 0x88280117, // 000B GETMBR R10 R0 K23 + 0x7C100C00, // 000C CALL R4 6 + 0x80000000, // 000D RET 0 }) ) ); @@ -1084,10 +558,10 @@ be_local_closure(class_Matter_Plugin_Device_register_cmd_cb, /* name */ be_str_weak(register_cmd_cb), &be_const_str_solidified, ( &(const binstruction[ 8]) { /* code */ - 0x88040101, // 0000 GETMBR R1 R0 K1 - 0x8C040351, // 0001 GETMET R1 R1 K81 - 0x880C014D, // 0002 GETMBR R3 R0 K77 - 0x88100152, // 0003 GETMBR R4 R0 K82 + 0x88040105, // 0000 GETMBR R1 R0 K5 + 0x8C040318, // 0001 GETMET R1 R1 K24 + 0x880C0119, // 0002 GETMBR R3 R0 K25 + 0x8810011A, // 0003 GETMBR R4 R0 K26 0x84140000, // 0004 CLOSURE R5 P0 0x7C040800, // 0005 CALL R1 4 0xA0000000, // 0006 CLOSE R0 @@ -1098,6 +572,618 @@ be_local_closure(class_Matter_Plugin_Device_register_cmd_cb, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: invoke_request +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_invoke_request, /* name */ + be_nested_proto( + 13, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(invoke_request), + &be_const_str_solidified, + ( &(const binstruction[51]) { /* code */ + 0xB8123600, // 0000 GETNGBL R4 K27 + 0x8810091C, // 0001 GETMBR R4 R4 K28 + 0x8814071D, // 0002 GETMBR R5 R3 K29 + 0x8818071E, // 0003 GETMBR R6 R3 K30 + 0x1C1C0B0D, // 0004 EQ R7 R5 K13 + 0x781E0016, // 0005 JMPF R7 #001D + 0x1C1C0D04, // 0006 EQ R7 R6 K4 + 0x781E0002, // 0007 JMPF R7 #000B + 0x501C0200, // 0008 LDBOOL R7 1 0 + 0x80040E00, // 0009 RET 1 R7 + 0x70020010, // 000A JMP #001C + 0x1C1C0D0A, // 000B EQ R7 R6 K10 + 0x781E0009, // 000C JMPF R7 #0017 + 0x8C1C091F, // 000D GETMET R7 R4 K31 + 0x7C1C0200, // 000E CALL R7 1 + 0x8C200F20, // 000F GETMET R8 R7 K32 + 0x58280004, // 0010 LDCONST R10 K4 + 0x882C0921, // 0011 GETMBR R11 R4 K33 + 0x58300004, // 0012 LDCONST R12 K4 + 0x7C200800, // 0013 CALL R8 4 + 0x900E3D04, // 0014 SETMBR R3 K30 K4 + 0x80040E00, // 0015 RET 1 R7 + 0x70020004, // 0016 JMP #001C + 0x541E003F, // 0017 LDINT R7 64 + 0x1C1C0C07, // 0018 EQ R7 R6 R7 + 0x781E0001, // 0019 JMPF R7 #001C + 0x501C0200, // 001A LDBOOL R7 1 0 + 0x80040E00, // 001B RET 1 R7 + 0x70020014, // 001C JMP #0032 + 0x541E0003, // 001D LDINT R7 4 + 0x1C1C0A07, // 001E EQ R7 R5 R7 + 0x781E0002, // 001F JMPF R7 #0023 + 0x501C0200, // 0020 LDBOOL R7 1 0 + 0x80040E00, // 0021 RET 1 R7 + 0x7002000E, // 0022 JMP #0032 + 0x541E0004, // 0023 LDINT R7 5 + 0x1C1C0A07, // 0024 EQ R7 R5 R7 + 0x781E0002, // 0025 JMPF R7 #0029 + 0x501C0200, // 0026 LDBOOL R7 1 0 + 0x80040E00, // 0027 RET 1 R7 + 0x70020008, // 0028 JMP #0032 + 0x601C0003, // 0029 GETGBL R7 G3 + 0x5C200000, // 002A MOVE R8 R0 + 0x7C1C0200, // 002B CALL R7 1 + 0x8C1C0F22, // 002C GETMET R7 R7 K34 + 0x5C240200, // 002D MOVE R9 R1 + 0x5C280400, // 002E MOVE R10 R2 + 0x5C2C0600, // 002F MOVE R11 R3 + 0x7C1C0800, // 0030 CALL R7 4 + 0x80040E00, // 0031 RET 1 R7 + 0x80000000, // 0032 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: every_250ms +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_every_250ms, /* name */ + be_nested_proto( + 3, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(every_250ms), + &be_const_str_solidified, + ( &(const binstruction[12]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x78060003, // 0001 JMPF R1 #0006 + 0x88040105, // 0002 GETMBR R1 R0 K5 + 0x8C040323, // 0003 GETMET R1 R1 K35 + 0x7C040200, // 0004 CALL R1 1 + 0x70020004, // 0005 JMP #000B + 0x60040003, // 0006 GETGBL R1 G3 + 0x5C080000, // 0007 MOVE R2 R0 + 0x7C040200, // 0008 CALL R1 1 + 0x8C040324, // 0009 GETMET R1 R1 K36 + 0x7C040200, // 000A CALL R1 1 + 0x80000000, // 000B RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: zigbee_received +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_zigbee_received, /* name */ + be_nested_proto( + 14, /* nstack */ + 3, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(zigbee_received), + &be_const_str_solidified, + ( &(const binstruction[48]) { /* code */ + 0xA40E4A00, // 0000 IMPORT R3 K37 + 0xB8121600, // 0001 GETNGBL R4 K11 + 0x60140018, // 0002 GETGBL R5 G24 + 0x58180026, // 0003 LDCONST R6 K38 + 0x881C0127, // 0004 GETMBR R7 R0 K39 + 0x881C0F28, // 0005 GETMBR R7 R7 K40 + 0x5C200400, // 0006 MOVE R8 R2 + 0x60240004, // 0007 GETGBL R9 G4 + 0x5C280400, // 0008 MOVE R10 R2 + 0x7C240200, // 0009 CALL R9 1 + 0x7C140800, // 000A CALL R5 4 + 0x5818000D, // 000B LDCONST R6 K13 + 0x7C100400, // 000C CALL R4 2 + 0x58100004, // 000D LDCONST R4 K4 + 0x6014000C, // 000E GETGBL R5 G12 + 0x5C180400, // 000F MOVE R6 R2 + 0x7C140200, // 0010 CALL R5 1 + 0x14140805, // 0011 LT R5 R4 R5 + 0x7816001B, // 0012 JMPF R5 #002F + 0x94140404, // 0013 GETIDX R5 R2 R4 + 0x88180B29, // 0014 GETMBR R6 R5 K41 + 0x881C012A, // 0015 GETMBR R7 R0 K42 + 0x1C180C07, // 0016 EQ R6 R6 R7 + 0x781A0014, // 0017 JMPF R6 #002D + 0x8C18012B, // 0018 GETMET R6 R0 K43 + 0x88200B2C, // 0019 GETMBR R8 R5 K44 + 0x7C180400, // 001A CALL R6 2 + 0x601C0013, // 001B GETGBL R7 G19 + 0x7C1C0000, // 001C CALL R7 0 + 0x8820012D, // 001D GETMBR R8 R0 K45 + 0x981C1006, // 001E SETIDX R7 R8 R6 + 0x8C20012E, // 001F GETMET R8 R0 K46 + 0x5C280E00, // 0020 MOVE R10 R7 + 0x7C200400, // 0021 CALL R8 2 + 0xB8221600, // 0022 GETNGBL R8 K11 + 0x60240018, // 0023 GETGBL R9 G24 + 0x5828002F, // 0024 LDCONST R10 K47 + 0x882C0130, // 0025 GETMBR R11 R0 K48 + 0x8830012D, // 0026 GETMBR R12 R0 K45 + 0x5C340E00, // 0027 MOVE R13 R7 + 0x7C240800, // 0028 CALL R9 4 + 0x5828000D, // 0029 LDCONST R10 K13 + 0x7C200400, // 002A CALL R8 2 + 0x4C200000, // 002B LDNIL R8 + 0x80041000, // 002C RET 1 R8 + 0x0010090A, // 002D ADD R4 R4 K10 + 0x7001FFDE, // 002E JMP #000E + 0x80000000, // 002F RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: web_values_prefix +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_web_values_prefix, /* name */ + be_nested_proto( + 10, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(web_values_prefix), + &be_const_str_solidified, + ( &(const binstruction[15]) { /* code */ + 0xA4061C00, // 0000 IMPORT R1 K14 + 0x8C080131, // 0001 GETMET R2 R0 K49 + 0x7C080200, // 0002 CALL R2 1 + 0x8C0C0310, // 0003 GETMET R3 R1 K16 + 0x60140018, // 0004 GETGBL R5 G24 + 0x88180132, // 0005 GETMBR R6 R0 K50 + 0x780A0003, // 0006 JMPF R2 #000B + 0x8C1C0333, // 0007 GETMET R7 R1 K51 + 0x5C240400, // 0008 MOVE R9 R2 + 0x7C1C0400, // 0009 CALL R7 2 + 0x70020000, // 000A JMP #000C + 0x581C0034, // 000B LDCONST R7 K52 + 0x7C140400, // 000C CALL R5 2 + 0x7C0C0400, // 000D CALL R3 2 + 0x80000000, // 000E RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_init, /* name */ + be_nested_proto( + 9, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[28]) { /* code */ + 0x88100135, // 0000 GETMBR R4 R0 K53 + 0x78120003, // 0001 JMPF R4 #0006 + 0x8C100336, // 0002 GETMET R4 R1 K54 + 0x5C180000, // 0003 MOVE R6 R0 + 0x7C100400, // 0004 CALL R4 2 + 0x90024E04, // 0005 SETMBR R0 K39 R4 + 0x60100003, // 0006 GETGBL R4 G3 + 0x5C140000, // 0007 MOVE R5 R0 + 0x7C100200, // 0008 CALL R4 1 + 0x8C100937, // 0009 GETMET R4 R4 K55 + 0x5C180200, // 000A MOVE R6 R1 + 0x5C1C0400, // 000B MOVE R7 R2 + 0x5C200600, // 000C MOVE R8 R3 + 0x7C100800, // 000D CALL R4 4 + 0x88100100, // 000E GETMBR R4 R0 K0 + 0x7812000A, // 000F JMPF R4 #001B + 0x8C100738, // 0010 GETMET R4 R3 K56 + 0x88180139, // 0011 GETMBR R6 R0 K57 + 0x7C100400, // 0012 CALL R4 2 + 0x88140115, // 0013 GETMBR R5 R0 K21 + 0x8C140B3A, // 0014 GETMET R5 R5 K58 + 0x5C1C0800, // 0015 MOVE R7 R4 + 0x8820013B, // 0016 GETMBR R8 R0 K59 + 0x7C140600, // 0017 CALL R5 3 + 0x90020A05, // 0018 SETMBR R0 K5 R5 + 0x8C14013C, // 0019 GETMET R5 R0 K60 + 0x7C140200, // 001A CALL R5 1 + 0x80000000, // 001B RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: read_attribute +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_read_attribute, /* name */ + be_nested_proto( + 17, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(read_attribute), + &be_const_str_solidified, + ( &(const binstruction[244]) { /* code */ + 0xB8123600, // 0000 GETNGBL R4 K27 + 0x8810091C, // 0001 GETMBR R4 R4 K28 + 0x8814051D, // 0002 GETMBR R5 R2 K29 + 0x8818053D, // 0003 GETMBR R6 R2 K61 + 0x1C1C0B0D, // 0004 EQ R7 R5 K13 + 0x781E000F, // 0005 JMPF R7 #0016 + 0x1C1C0D04, // 0006 EQ R7 R6 K4 + 0x781E0005, // 0007 JMPF R7 #000E + 0x8C1C073E, // 0008 GETMET R7 R3 K62 + 0x88240921, // 0009 GETMBR R9 R4 K33 + 0x58280004, // 000A LDCONST R10 K4 + 0x7C1C0600, // 000B CALL R7 3 + 0x80040E00, // 000C RET 1 R7 + 0x70020006, // 000D JMP #0015 + 0x1C1C0D0A, // 000E EQ R7 R6 K10 + 0x781E0004, // 000F JMPF R7 #0015 + 0x8C1C073E, // 0010 GETMET R7 R3 K62 + 0x8824093F, // 0011 GETMBR R9 R4 K63 + 0x58280004, // 0012 LDCONST R10 K4 + 0x7C1C0600, // 0013 CALL R7 3 + 0x80040E00, // 0014 RET 1 R7 + 0x700200D4, // 0015 JMP #00EB + 0x541E0003, // 0016 LDINT R7 4 + 0x1C1C0A07, // 0017 EQ R7 R5 R7 + 0x781E0004, // 0018 JMPF R7 #001E + 0x1C1C0D04, // 0019 EQ R7 R6 K4 + 0x781E0001, // 001A JMPF R7 #001D + 0x4C1C0000, // 001B LDNIL R7 + 0x80040E00, // 001C RET 1 R7 + 0x700200CC, // 001D JMP #00EB + 0x541E0004, // 001E LDINT R7 5 + 0x1C1C0A07, // 001F EQ R7 R5 R7 + 0x781E0000, // 0020 JMPF R7 #0022 + 0x700200C8, // 0021 JMP #00EB + 0x541E001C, // 0022 LDINT R7 29 + 0x1C1C0A07, // 0023 EQ R7 R5 R7 + 0x781E0034, // 0024 JMPF R7 #005A + 0x1C1C0D04, // 0025 EQ R7 R6 K4 + 0x781E0031, // 0026 JMPF R7 #0059 + 0x8C1C0940, // 0027 GETMET R7 R4 K64 + 0x7C1C0200, // 0028 CALL R7 1 + 0x88200141, // 0029 GETMBR R8 R0 K65 + 0x60240010, // 002A GETGBL R9 G16 + 0x8C281142, // 002B GETMET R10 R8 K66 + 0x7C280200, // 002C CALL R10 1 + 0x7C240200, // 002D CALL R9 1 + 0xA802000E, // 002E EXBLK 0 #003E + 0x5C281200, // 002F MOVE R10 R9 + 0x7C280000, // 0030 CALL R10 0 + 0x8C2C0F43, // 0031 GETMET R11 R7 K67 + 0x7C2C0200, // 0032 CALL R11 1 + 0x8C301720, // 0033 GETMET R12 R11 K32 + 0x58380004, // 0034 LDCONST R14 K4 + 0x883C0921, // 0035 GETMBR R15 R4 K33 + 0x5C401400, // 0036 MOVE R16 R10 + 0x7C300800, // 0037 CALL R12 4 + 0x8C301720, // 0038 GETMET R12 R11 K32 + 0x5838000A, // 0039 LDCONST R14 K10 + 0x883C0921, // 003A GETMBR R15 R4 K33 + 0x9440100A, // 003B GETIDX R16 R8 R10 + 0x7C300800, // 003C CALL R12 4 + 0x7001FFF0, // 003D JMP #002F + 0x58240044, // 003E LDCONST R9 K68 + 0xAC240200, // 003F CATCH R9 1 0 + 0xB0080000, // 0040 RAISE 2 R0 R0 + 0x88240145, // 0041 GETMBR R9 R0 K69 + 0x8C241338, // 0042 GETMET R9 R9 K56 + 0x8C2C0346, // 0043 GETMET R11 R1 K70 + 0x7C2C0200, // 0044 CALL R11 1 + 0x7C240400, // 0045 CALL R9 2 + 0x4C280000, // 0046 LDNIL R10 + 0x1C24120A, // 0047 EQ R9 R9 R10 + 0x7826000E, // 0048 JMPF R9 #0058 + 0x88240115, // 0049 GETMBR R9 R0 K21 + 0x88241347, // 004A GETMBR R9 R9 K71 + 0x7426000B, // 004B JMPT R9 #0058 + 0x8C240F43, // 004C GETMET R9 R7 K67 + 0x7C240200, // 004D CALL R9 1 + 0x8C281320, // 004E GETMET R10 R9 K32 + 0x58300004, // 004F LDCONST R12 K4 + 0x88340921, // 0050 GETMBR R13 R4 K33 + 0x543A0012, // 0051 LDINT R14 19 + 0x7C280800, // 0052 CALL R10 4 + 0x8C281320, // 0053 GETMET R10 R9 K32 + 0x5830000A, // 0054 LDCONST R12 K10 + 0x88340921, // 0055 GETMBR R13 R4 K33 + 0x5838000A, // 0056 LDCONST R14 K10 + 0x7C280800, // 0057 CALL R10 4 + 0x80040E00, // 0058 RET 1 R7 + 0x70020090, // 0059 JMP #00EB + 0x541E0038, // 005A LDINT R7 57 + 0x1C1C0A07, // 005B EQ R7 R5 R7 + 0x781E008D, // 005C JMPF R7 #00EB + 0xA41E9000, // 005D IMPORT R7 K72 + 0x1C200D0D, // 005E EQ R8 R6 K13 + 0x78220018, // 005F JMPF R8 #0079 + 0x88200100, // 0060 GETMBR R8 R0 K0 + 0x7822000B, // 0061 JMPF R8 #006E + 0x88200105, // 0062 GETMBR R8 R0 K5 + 0x8C201149, // 0063 GETMET R8 R8 K73 + 0x7C200200, // 0064 CALL R8 1 + 0x8C201138, // 0065 GETMET R8 R8 K56 + 0x5828004A, // 0066 LDCONST R10 K74 + 0x7C200400, // 0067 CALL R8 2 + 0x8C24074B, // 0068 GETMET R9 R3 K75 + 0x882C094C, // 0069 GETMBR R11 R4 K76 + 0x5C301000, // 006A MOVE R12 R8 + 0x7C240600, // 006B CALL R9 3 + 0x80041200, // 006C RET 1 R9 + 0x70020009, // 006D JMP #0078 + 0x8C20073E, // 006E GETMET R8 R3 K62 + 0x8828094C, // 006F GETMBR R10 R4 K76 + 0xB82E9A00, // 0070 GETNGBL R11 K77 + 0x8C2C174E, // 0071 GETMET R11 R11 K78 + 0x5834004F, // 0072 LDCONST R13 K79 + 0x50380200, // 0073 LDBOOL R14 1 0 + 0x7C2C0600, // 0074 CALL R11 3 + 0x942C174F, // 0075 GETIDX R11 R11 K79 + 0x7C200600, // 0076 CALL R8 3 + 0x80041000, // 0077 RET 1 R8 + 0x70020071, // 0078 JMP #00EB + 0x54220004, // 0079 LDINT R8 5 + 0x1C200C08, // 007A EQ R8 R6 R8 + 0x78220006, // 007B JMPF R8 #0083 + 0x8C20073E, // 007C GETMET R8 R3 K62 + 0x8828094C, // 007D GETMBR R10 R4 K76 + 0x8C2C0131, // 007E GETMET R11 R0 K49 + 0x7C2C0200, // 007F CALL R11 1 + 0x7C200600, // 0080 CALL R8 3 + 0x80041000, // 0081 RET 1 R8 + 0x70020067, // 0082 JMP #00EB + 0x54220009, // 0083 LDINT R8 10 + 0x1C200C08, // 0084 EQ R8 R6 R8 + 0x78220033, // 0085 JMPF R8 #00BA + 0x88200100, // 0086 GETMBR R8 R0 K0 + 0x7822001B, // 0087 JMPF R8 #00A4 + 0x88200105, // 0088 GETMBR R8 R0 K5 + 0x8C201149, // 0089 GETMET R8 R8 K73 + 0x7C200200, // 008A CALL R8 1 + 0x8C201138, // 008B GETMET R8 R8 K56 + 0x58280050, // 008C LDCONST R10 K80 + 0x7C200400, // 008D CALL R8 2 + 0x7822000E, // 008E JMPF R8 #009E + 0x8C240F38, // 008F GETMET R9 R7 K56 + 0x5C2C1000, // 0090 MOVE R11 R8 + 0x58300051, // 0091 LDCONST R12 K81 + 0x7C240600, // 0092 CALL R9 3 + 0x24281304, // 0093 GT R10 R9 K4 + 0x782A0002, // 0094 JMPF R10 #0098 + 0x0428130A, // 0095 SUB R10 R9 K10 + 0x402A080A, // 0096 CONNECT R10 K4 R10 + 0x9420100A, // 0097 GETIDX R8 R8 R10 + 0x8C28073E, // 0098 GETMET R10 R3 K62 + 0x8830094C, // 0099 GETMBR R12 R4 K76 + 0x5C341000, // 009A MOVE R13 R8 + 0x7C280600, // 009B CALL R10 3 + 0x80041400, // 009C RET 1 R10 + 0x70020004, // 009D JMP #00A3 + 0x8C24073E, // 009E GETMET R9 R3 K62 + 0x882C0952, // 009F GETMBR R11 R4 K82 + 0x4C300000, // 00A0 LDNIL R12 + 0x7C240600, // 00A1 CALL R9 3 + 0x80041200, // 00A2 RET 1 R9 + 0x70020014, // 00A3 JMP #00B9 + 0xB8229A00, // 00A4 GETNGBL R8 K77 + 0x8C20114E, // 00A5 GETMET R8 R8 K78 + 0x58280053, // 00A6 LDCONST R10 K83 + 0x502C0200, // 00A7 LDBOOL R11 1 0 + 0x7C200600, // 00A8 CALL R8 3 + 0x94201154, // 00A9 GETIDX R8 R8 K84 + 0x94201155, // 00AA GETIDX R8 R8 K85 + 0x8C240F38, // 00AB GETMET R9 R7 K56 + 0x5C2C1000, // 00AC MOVE R11 R8 + 0x58300051, // 00AD LDCONST R12 K81 + 0x7C240600, // 00AE CALL R9 3 + 0x24281304, // 00AF GT R10 R9 K4 + 0x782A0002, // 00B0 JMPF R10 #00B4 + 0x0428130A, // 00B1 SUB R10 R9 K10 + 0x402A080A, // 00B2 CONNECT R10 K4 R10 + 0x9420100A, // 00B3 GETIDX R8 R8 R10 + 0x8C28073E, // 00B4 GETMET R10 R3 K62 + 0x8830094C, // 00B5 GETMBR R12 R4 K76 + 0x5C341000, // 00B6 MOVE R13 R8 + 0x7C280600, // 00B7 CALL R10 3 + 0x80041400, // 00B8 RET 1 R10 + 0x70020030, // 00B9 JMP #00EB + 0x5422000E, // 00BA LDINT R8 15 + 0x1C200C08, // 00BB EQ R8 R6 R8 + 0x74220002, // 00BC JMPT R8 #00C0 + 0x54220011, // 00BD LDINT R8 18 + 0x1C200C08, // 00BE EQ R8 R6 R8 + 0x78220019, // 00BF JMPF R8 #00DA + 0x88200100, // 00C0 GETMBR R8 R0 K0 + 0x7822000B, // 00C1 JMPF R8 #00CE + 0x88200105, // 00C2 GETMBR R8 R0 K5 + 0x8C201149, // 00C3 GETMET R8 R8 K73 + 0x7C200200, // 00C4 CALL R8 1 + 0x8C201138, // 00C5 GETMET R8 R8 K56 + 0x58280056, // 00C6 LDCONST R10 K86 + 0x7C200400, // 00C7 CALL R8 2 + 0x8C24074B, // 00C8 GETMET R9 R3 K75 + 0x882C094C, // 00C9 GETMBR R11 R4 K76 + 0x5C301000, // 00CA MOVE R12 R8 + 0x7C240600, // 00CB CALL R9 3 + 0x80041200, // 00CC RET 1 R9 + 0x7002000A, // 00CD JMP #00D9 + 0x8C20073E, // 00CE GETMET R8 R3 K62 + 0x8828094C, // 00CF GETMBR R10 R4 K76 + 0xB82E9A00, // 00D0 GETNGBL R11 K77 + 0x8C2C1757, // 00D1 GETMET R11 R11 K87 + 0x7C2C0200, // 00D2 CALL R11 1 + 0x8C2C1738, // 00D3 GETMET R11 R11 K56 + 0x58340056, // 00D4 LDCONST R13 K86 + 0x58380034, // 00D5 LDCONST R14 K52 + 0x7C2C0600, // 00D6 CALL R11 3 + 0x7C200600, // 00D7 CALL R8 3 + 0x80041000, // 00D8 RET 1 R8 + 0x70020010, // 00D9 JMP #00EB + 0x54220010, // 00DA LDINT R8 17 + 0x1C200C08, // 00DB EQ R8 R6 R8 + 0x7822000D, // 00DC JMPF R8 #00EB + 0x88200100, // 00DD GETMBR R8 R0 K0 + 0x78220006, // 00DE JMPF R8 #00E6 + 0x8C20073E, // 00DF GETMET R8 R3 K62 + 0x88280958, // 00E0 GETMBR R10 R4 K88 + 0x882C0105, // 00E1 GETMBR R11 R0 K5 + 0x882C1759, // 00E2 GETMBR R11 R11 K89 + 0x7C200600, // 00E3 CALL R8 3 + 0x80041000, // 00E4 RET 1 R8 + 0x70020004, // 00E5 JMP #00EB + 0x8C20073E, // 00E6 GETMET R8 R3 K62 + 0x88280958, // 00E7 GETMBR R10 R4 K88 + 0x582C000A, // 00E8 LDCONST R11 K10 + 0x7C200600, // 00E9 CALL R8 3 + 0x80041000, // 00EA RET 1 R8 + 0x601C0003, // 00EB GETGBL R7 G3 + 0x5C200000, // 00EC MOVE R8 R0 + 0x7C1C0200, // 00ED CALL R7 1 + 0x8C1C0F5A, // 00EE GETMET R7 R7 K90 + 0x5C240200, // 00EF MOVE R9 R1 + 0x5C280400, // 00F0 MOVE R10 R2 + 0x5C2C0600, // 00F1 MOVE R11 R3 + 0x7C1C0800, // 00F2 CALL R7 4 + 0x80040E00, // 00F3 RET 1 R7 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: update_shadow +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_update_shadow, /* name */ + be_nested_proto( + 7, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(update_shadow), + &be_const_str_solidified, + ( &(const binstruction[20]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x7806000D, // 0001 JMPF R1 #0010 + 0x88040114, // 0002 GETMBR R1 R0 K20 + 0x88080115, // 0003 GETMBR R2 R0 K21 + 0x88080514, // 0004 GETMBR R2 R2 K20 + 0x20040202, // 0005 NE R1 R1 R2 + 0x78060008, // 0006 JMPF R1 #0010 + 0x8C04015B, // 0007 GETMET R1 R0 K91 + 0x880C0119, // 0008 GETMBR R3 R0 K25 + 0x7C040400, // 0009 CALL R1 2 + 0x78060004, // 000A JMPF R1 #0010 + 0x8C08015C, // 000B GETMET R2 R0 K92 + 0x5810000A, // 000C LDCONST R4 K10 + 0x5C140200, // 000D MOVE R5 R1 + 0x88180119, // 000E GETMBR R6 R0 K25 + 0x7C080800, // 000F CALL R2 4 + 0x88040115, // 0010 GETMBR R1 R0 K21 + 0x88040314, // 0011 GETMBR R1 R1 K20 + 0x90022801, // 0012 SETMBR R0 K20 R1 + 0x80000000, // 0013 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: web_value_onoff +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_web_value_onoff, /* name */ + be_nested_proto( + 3, /* nstack */ + 2, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(web_value_onoff), + &be_const_str_solidified, + ( &(const binstruction[10]) { /* code */ + 0x4C080000, // 0000 LDNIL R2 + 0x20080202, // 0001 NE R2 R1 R2 + 0x780A0004, // 0002 JMPF R2 #0008 + 0x78060001, // 0003 JMPF R1 #0006 + 0x5808005D, // 0004 LDCONST R2 K93 + 0x70020000, // 0005 JMP #0007 + 0x5808005E, // 0006 LDCONST R2 K94 + 0x70020000, // 0007 JMP #0009 + 0x58080034, // 0008 LDCONST R2 K52 + 0x80040400, // 0009 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: append_state_json ********************************************************************/ @@ -1172,98 +1258,98 @@ be_local_closure(class_Matter_Plugin_Device_append_state_json, /* name */ be_str_weak(append_state_json), &be_const_str_solidified, ( &(const binstruction[95]) { /* code */ - 0xA406A600, // 0000 IMPORT R1 K83 - 0xA40A1400, // 0001 IMPORT R2 K10 - 0x580C0041, // 0002 LDCONST R3 K65 + 0xA406BE00, // 0000 IMPORT R1 K95 + 0xA40A0200, // 0001 IMPORT R2 K1 + 0x580C0034, // 0002 LDCONST R3 K52 0x84100000, // 0003 CLOSURE R4 P0 - 0x8C140354, // 0004 GETMET R5 R1 K84 + 0x8C140360, // 0004 GETMET R5 R1 K96 0x5C1C0000, // 0005 MOVE R7 R0 - 0x58200055, // 0006 LDCONST R8 K85 + 0x5820002D, // 0006 LDCONST R8 K45 0x7C140600, // 0007 CALL R5 3 0x78160013, // 0008 JMPF R5 #001D - 0x8C180356, // 0009 GETMET R6 R1 K86 + 0x8C180361, // 0009 GETMET R6 R1 K97 0x5C200000, // 000A MOVE R8 R0 - 0x58240057, // 000B LDCONST R9 K87 + 0x58240062, // 000B LDCONST R9 K98 0x7C180600, // 000C CALL R6 3 0x781A000E, // 000D JMPF R6 #001D - 0x88180157, // 000E GETMBR R6 R0 K87 + 0x88180162, // 000E GETMBR R6 R0 K98 0x4C1C0000, // 000F LDNIL R7 0x20180C07, // 0010 NE R6 R6 R7 0x781A0003, // 0011 JMPF R6 #0016 - 0x8C180558, // 0012 GETMET R6 R2 K88 - 0x88200157, // 0013 GETMBR R8 R0 K87 + 0x8C180563, // 0012 GETMET R6 R2 K99 + 0x88200162, // 0013 GETMBR R8 R0 K98 0x7C180400, // 0014 CALL R6 2 0x70020000, // 0015 JMP #0017 - 0x58180059, // 0016 LDCONST R6 K89 + 0x58180064, // 0016 LDCONST R6 K100 0x601C0018, // 0017 GETGBL R7 G24 - 0x5820005A, // 0018 LDCONST R8 K90 + 0x58200065, // 0018 LDCONST R8 K101 0x5C240A00, // 0019 MOVE R9 R5 0x5C280C00, // 001A MOVE R10 R6 0x7C1C0600, // 001B CALL R7 3 0x000C0607, // 001C ADD R3 R3 R7 0x5C180800, // 001D MOVE R6 R4 - 0x581C005B, // 001E LDCONST R7 K91 - 0x5820005C, // 001F LDCONST R8 K92 + 0x581C0066, // 001E LDCONST R7 K102 + 0x58200067, // 001F LDCONST R8 K103 0x7C180400, // 0020 CALL R6 2 0x5C180800, // 0021 MOVE R6 R4 - 0x581C005D, // 0022 LDCONST R7 K93 - 0x5820005E, // 0023 LDCONST R8 K94 + 0x581C0068, // 0022 LDCONST R7 K104 + 0x58200069, // 0023 LDCONST R8 K105 0x7C180400, // 0024 CALL R6 2 0x5C180800, // 0025 MOVE R6 R4 - 0x581C005F, // 0026 LDCONST R7 K95 - 0x58200060, // 0027 LDCONST R8 K96 + 0x581C006A, // 0026 LDCONST R7 K106 + 0x5820006B, // 0027 LDCONST R8 K107 0x7C180400, // 0028 CALL R6 2 0x5C180800, // 0029 MOVE R6 R4 - 0x581C0061, // 002A LDCONST R7 K97 - 0x58200062, // 002B LDCONST R8 K98 + 0x581C006C, // 002A LDCONST R7 K108 + 0x5820006D, // 002B LDCONST R8 K109 0x7C180400, // 002C CALL R6 2 0x5C180800, // 002D MOVE R6 R4 - 0x581C0063, // 002E LDCONST R7 K99 - 0x58200064, // 002F LDCONST R8 K100 + 0x581C006E, // 002E LDCONST R7 K110 + 0x5820006F, // 002F LDCONST R8 K111 0x7C180400, // 0030 CALL R6 2 0x5C180800, // 0031 MOVE R6 R4 - 0x581C0065, // 0032 LDCONST R7 K101 - 0x58200066, // 0033 LDCONST R8 K102 + 0x581C0070, // 0032 LDCONST R7 K112 + 0x58200071, // 0033 LDCONST R8 K113 0x7C180400, // 0034 CALL R6 2 0x5C180800, // 0035 MOVE R6 R4 - 0x581C0067, // 0036 LDCONST R7 K103 - 0x58200068, // 0037 LDCONST R8 K104 + 0x581C0072, // 0036 LDCONST R7 K114 + 0x58200073, // 0037 LDCONST R8 K115 0x7C180400, // 0038 CALL R6 2 0x5C180800, // 0039 MOVE R6 R4 - 0x581C0069, // 003A LDCONST R7 K105 - 0x5820006A, // 003B LDCONST R8 K106 + 0x581C0074, // 003A LDCONST R7 K116 + 0x58200075, // 003B LDCONST R8 K117 0x7C180400, // 003C CALL R6 2 0x5C180800, // 003D MOVE R6 R4 - 0x581C006B, // 003E LDCONST R7 K107 - 0x5820006C, // 003F LDCONST R8 K108 + 0x581C0076, // 003E LDCONST R7 K118 + 0x58200077, // 003F LDCONST R8 K119 0x7C180400, // 0040 CALL R6 2 0x5C180800, // 0041 MOVE R6 R4 - 0x581C006D, // 0042 LDCONST R7 K109 - 0x5820006E, // 0043 LDCONST R8 K110 + 0x581C0078, // 0042 LDCONST R7 K120 + 0x58200079, // 0043 LDCONST R8 K121 0x7C180400, // 0044 CALL R6 2 0x5C180800, // 0045 MOVE R6 R4 - 0x581C006F, // 0046 LDCONST R7 K111 - 0x58200070, // 0047 LDCONST R8 K112 + 0x581C007A, // 0046 LDCONST R7 K122 + 0x5820007B, // 0047 LDCONST R8 K123 0x7C180400, // 0048 CALL R6 2 0x5C180800, // 0049 MOVE R6 R4 - 0x581C0071, // 004A LDCONST R7 K113 - 0x58200072, // 004B LDCONST R8 K114 + 0x581C007C, // 004A LDCONST R7 K124 + 0x5820007D, // 004B LDCONST R8 K125 0x7C180400, // 004C CALL R6 2 0x5C180800, // 004D MOVE R6 R4 - 0x581C0073, // 004E LDCONST R7 K115 - 0x58200074, // 004F LDCONST R8 K116 + 0x581C007E, // 004E LDCONST R7 K126 + 0x5820007F, // 004F LDCONST R8 K127 0x7C180400, // 0050 CALL R6 2 0x5C180800, // 0051 MOVE R6 R4 - 0x581C0075, // 0052 LDCONST R7 K117 - 0x58200076, // 0053 LDCONST R8 K118 + 0x581C0080, // 0052 LDCONST R7 K128 + 0x58200081, // 0053 LDCONST R8 K129 0x7C180400, // 0054 CALL R6 2 0x5C180800, // 0055 MOVE R6 R4 - 0x581C0077, // 0056 LDCONST R7 K119 - 0x58200078, // 0057 LDCONST R8 K120 + 0x581C0082, // 0056 LDCONST R7 K130 + 0x58200083, // 0057 LDCONST R8 K131 0x7C180400, // 0058 CALL R6 2 0x5C180800, // 0059 MOVE R6 R4 - 0x581C0079, // 005A LDCONST R7 K121 - 0x5820007A, // 005B LDCONST R8 K122 + 0x581C0084, // 005A LDCONST R7 K132 + 0x58200085, // 005B LDCONST R8 K133 0x7C180400, // 005C CALL R6 2 0xA0000000, // 005D CLOSE R0 0x80040600, // 005E RET 1 R3 @@ -1274,12 +1360,12 @@ be_local_closure(class_Matter_Plugin_Device_append_state_json, /* name */ /******************************************************************** -** Solidified function: parse_http_response +** Solidified function: value_changed ********************************************************************/ -be_local_closure(class_Matter_Plugin_Device_parse_http_response, /* name */ +be_local_closure(class_Matter_Plugin_Device_value_changed, /* name */ be_nested_proto( - 11, /* nstack */ - 4, /* argc */ + 1, /* nstack */ + 1, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -1287,23 +1373,66 @@ be_local_closure(class_Matter_Plugin_Device_parse_http_response, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Device, /* shared constants */ - be_str_weak(parse_http_response), + be_str_weak(value_changed), &be_const_str_solidified, - ( &(const binstruction[14]) { /* code */ - 0x88100100, // 0000 GETMBR R4 R0 K0 - 0x7812000A, // 0001 JMPF R4 #000D - 0x8810011C, // 0002 GETMBR R4 R0 K28 - 0x8810094B, // 0003 GETMBR R4 R4 K75 - 0x90029604, // 0004 SETMBR R0 K75 R4 - 0x88100101, // 0005 GETMBR R4 R0 K1 - 0x8C10097B, // 0006 GETMET R4 R4 K123 - 0x5C180200, // 0007 MOVE R6 R1 - 0x5C1C0400, // 0008 MOVE R7 R2 - 0x5C200600, // 0009 MOVE R8 R3 - 0x5C240000, // 000A MOVE R9 R0 - 0x8828017C, // 000B GETMBR R10 R0 K124 - 0x7C100C00, // 000C CALL R4 6 - 0x80000000, // 000D RET 0 + ( &(const binstruction[ 1]) { /* code */ + 0x80000000, // 0000 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: parse_configuration +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_parse_configuration, /* name */ + be_nested_proto( + 5, /* nstack */ + 2, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(parse_configuration), + &be_const_str_solidified, + ( &(const binstruction[ 9]) { /* code */ + 0x88080135, // 0000 GETMBR R2 R0 K53 + 0x780A0005, // 0001 JMPF R2 #0008 + 0x88080127, // 0002 GETMBR R2 R0 K39 + 0x780A0003, // 0003 JMPF R2 #0008 + 0x88080127, // 0004 GETMBR R2 R0 K39 + 0x8C080586, // 0005 GETMET R2 R2 K134 + 0x5C100200, // 0006 MOVE R4 R1 + 0x7C080400, // 0007 CALL R2 2 + 0x80000000, // 0008 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: parse_status +********************************************************************/ +be_local_closure(class_Matter_Plugin_Device_parse_status, /* name */ + be_nested_proto( + 3, /* nstack */ + 3, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Device, /* shared constants */ + be_str_weak(parse_status), + &be_const_str_solidified, + ( &(const binstruction[ 1]) { /* code */ + 0x80000000, // 0000 RET 0 }) ) ); @@ -1327,7 +1456,7 @@ be_local_closure(class_Matter_Plugin_Device__parse_sensor_entry, /* name */ be_str_weak(_parse_sensor_entry), &be_const_str_solidified, ( &(const binstruction[18]) { /* code */ - 0x8C1C031A, // 0000 GETMET R7 R1 K26 + 0x8C1C0338, // 0000 GETMET R7 R1 K56 0x5C240400, // 0001 MOVE R9 R2 0x7C1C0400, // 0002 CALL R7 2 0x4C200000, // 0003 LDNIL R8 @@ -1339,7 +1468,7 @@ be_local_closure(class_Matter_Plugin_Device__parse_sensor_entry, /* name */ 0x5C1C1000, // 0009 MOVE R7 R8 0x20200E03, // 000A NE R8 R7 R3 0x78220003, // 000B JMPF R8 #0010 - 0x8C20017D, // 000C GETMET R8 R0 K125 + 0x8C200187, // 000C GETMET R8 R0 K135 0x5C280A00, // 000D MOVE R10 R5 0x5C2C0C00, // 000E MOVE R11 R6 0x7C200600, // 000F CALL R8 3 @@ -1358,42 +1487,32 @@ extern const bclass be_class_Matter_Plugin; be_local_class(Matter_Plugin_Device, 1, &be_class_Matter_Plugin, - be_nested_map(25, + be_nested_map(28, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(every_250ms, 10), be_const_closure(class_Matter_Plugin_Device_every_250ms_closure) }, - { be_const_key_weak(_parse_sensor_entry, -1), be_const_closure(class_Matter_Plugin_Device__parse_sensor_entry_closure) }, - { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Device_web_values_closure) }, + { be_const_key_weak(_parse_sensor_entry, 1), be_const_closure(class_Matter_Plugin_Device__parse_sensor_entry_closure) }, { be_const_key_weak(parse_status, -1), be_const_closure(class_Matter_Plugin_Device_parse_status_closure) }, - { be_const_key_weak(call_remote_sync, 7), be_const_closure(class_Matter_Plugin_Device_call_remote_sync_closure) }, - { be_const_key_weak(init, -1), be_const_closure(class_Matter_Plugin_Device_init_closure) }, - { be_const_key_weak(invoke_request, -1), be_const_closure(class_Matter_Plugin_Device_invoke_request_closure) }, - { be_const_key_weak(PREFIX, -1), be_nested_str_weak(_X7C_X20_X3Ci_X3E_X25s_X3C_X2Fi_X3E_X20) }, - { be_const_key_weak(http_remote, -1), be_const_var(0) }, - { be_const_key_weak(UPDATE_CMD, -1), be_nested_str_weak(Status_X2011) }, - { be_const_key_weak(web_value_onoff, -1), be_const_closure(class_Matter_Plugin_Device_web_value_onoff_closure) }, - { be_const_key_weak(GetOptionReader, -1), be_const_class(be_class_GetOptionReader) }, - { be_const_key_weak(read_attribute, 6), be_const_closure(class_Matter_Plugin_Device_read_attribute_closure) }, - { be_const_key_weak(NON_BRIDGE_VENDOR, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + { be_const_key_weak(call_remote_sync, 16), be_const_closure(class_Matter_Plugin_Device_call_remote_sync_closure) }, + { be_const_key_weak(NON_BRIDGE_VENDOR, 0), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { be_const_list( * be_nested_list(2, ( (struct bvalue*) &(const bvalue[]) { be_const_int(4631), be_const_int(4993), })) ) } )) }, - { be_const_key_weak(update_shadow, -1), be_const_closure(class_Matter_Plugin_Device_update_shadow_closure) }, + { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Device_web_values_closure) }, + { be_const_key_weak(parse_http_response, 15), be_const_closure(class_Matter_Plugin_Device_parse_http_response_closure) }, + { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Device_web_values_prefix_closure) }, + { be_const_key_weak(invoke_request, -1), be_const_closure(class_Matter_Plugin_Device_invoke_request_closure) }, + { be_const_key_weak(pre_value, 27), be_const_closure(class_Matter_Plugin_Device_pre_value_closure) }, + { be_const_key_weak(GetOptionReader, -1), be_const_class(be_class_GetOptionReader) }, { 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(19, -1), be_const_int(1) }, })) ) } )) }, - { be_const_key_weak(register_cmd_cb, -1), be_const_closure(class_Matter_Plugin_Device_register_cmd_cb_closure) }, - { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Device_web_values_prefix_closure) }, - { be_const_key_weak(PROBE_TIMEOUT, 13), be_const_int(1700) }, - { be_const_key_weak(parse_configuration, 16), be_const_closure(class_Matter_Plugin_Device_parse_configuration_closure) }, - { be_const_key_weak(ARG_HTTP, -1), be_nested_str_weak(url) }, - { be_const_key_weak(append_state_json, -1), be_const_closure(class_Matter_Plugin_Device_append_state_json_closure) }, - { be_const_key_weak(parse_http_response, -1), be_const_closure(class_Matter_Plugin_Device_parse_http_response_closure) }, - { be_const_key_weak(SYNC_TIMEOUT, -1), be_const_int(500) }, - { be_const_key_weak(CLUSTERS, 1), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { + { be_const_key_weak(zigbee_received, -1), be_const_closure(class_Matter_Plugin_Device_zigbee_received_closure) }, + { be_const_key_weak(http_remote, 26), be_const_var(0) }, + { be_const_key_weak(register_cmd_cb, 23), be_const_closure(class_Matter_Plugin_Device_register_cmd_cb_closure) }, + { be_const_key_weak(CLUSTERS, 20), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { be_const_map( * be_nested_map(5, ( (struct bmapnode*) &(const bmapnode[]) { { be_const_key_int(5, -1), be_const_bytes_instance(000000010002000300040005FFF8FFF9FFFAFFFBFFFCFFFD) }, @@ -1402,6 +1521,19 @@ be_local_class(Matter_Plugin_Device, { be_const_key_int(3, -1), be_const_bytes_instance(00000001FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(4, 1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, + { be_const_key_weak(value_changed, -1), be_const_closure(class_Matter_Plugin_Device_value_changed_closure) }, + { be_const_key_weak(append_state_json, 24), be_const_closure(class_Matter_Plugin_Device_append_state_json_closure) }, + { be_const_key_weak(UPDATE_CMD, -1), be_nested_str_weak(Status_X2011) }, + { be_const_key_weak(update_shadow, -1), be_const_closure(class_Matter_Plugin_Device_update_shadow_closure) }, + { be_const_key_weak(init, 17), be_const_closure(class_Matter_Plugin_Device_init_closure) }, + { be_const_key_weak(read_attribute, -1), be_const_closure(class_Matter_Plugin_Device_read_attribute_closure) }, + { be_const_key_weak(PREFIX, 18), be_nested_str_weak(_X7C_X20_X3Ci_X3E_X25s_X3C_X2Fi_X3E_X20) }, + { be_const_key_weak(web_value_onoff, -1), be_const_closure(class_Matter_Plugin_Device_web_value_onoff_closure) }, + { be_const_key_weak(PROBE_TIMEOUT, 6), be_const_int(1700) }, + { be_const_key_weak(SYNC_TIMEOUT, -1), be_const_int(500) }, + { be_const_key_weak(parse_configuration, -1), be_const_closure(class_Matter_Plugin_Device_parse_configuration_closure) }, + { be_const_key_weak(ARG_HTTP, -1), be_nested_str_weak(url) }, + { be_const_key_weak(every_250ms, -1), be_const_closure(class_Matter_Plugin_Device_every_250ms_closure) }, })), be_str_weak(Matter_Plugin_Device) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Light0.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Light0.h index 5f255c9a3..0390a8125 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Light0.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Light0.h @@ -3,67 +3,80 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Light0' ktab size: 47, total: 87 (saved 320 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Light0[47] = { - /* K0 */ be_nested_str_weak(BRIDGE), - /* K1 */ be_nested_str_weak(call_remote_sync), - /* K2 */ be_nested_str_weak(Power), - /* K3 */ be_nested_str_weak(tasmota_relay_index), - /* K4 */ be_nested_str_weak(1), - /* K5 */ be_nested_str_weak(0), - /* K6 */ be_nested_str_weak(parse_status), - /* K7 */ be_nested_str_weak(VIRTUAL), - /* K8 */ be_nested_str_weak(shadow_onoff), - /* K9 */ be_nested_str_weak(attribute_updated), - /* K10 */ be_const_int(0), - /* K11 */ be_nested_str_weak(tasmota), - /* K12 */ be_nested_str_weak(set_power), - /* K13 */ be_const_int(1), - /* K14 */ be_nested_str_weak(update_shadow), - /* K15 */ be_nested_str_weak(light), - /* K16 */ be_nested_str_weak(set), - /* K17 */ be_nested_str_weak(power), - /* K18 */ be_nested_str_weak(light_index), - /* K19 */ be_nested_str_weak(webserver), - /* K20 */ be_nested_str_weak(web_values_prefix), - /* K21 */ be_nested_str_weak(content_send), - /* K22 */ be_nested_str_weak(_X25s), - /* K23 */ be_nested_str_weak(web_value_onoff), - /* K24 */ be_nested_str_weak(init), - /* K25 */ be_nested_str_weak(find), - /* K26 */ be_nested_str_weak(ARG), - /* K27 */ be_nested_str_weak(set_onoff), - /* K28 */ be_nested_str_weak(update_virtual), - /* K29 */ be_nested_str_weak(matter), - /* K30 */ be_nested_str_weak(TLV), - /* K31 */ be_nested_str_weak(cluster), - /* K32 */ be_nested_str_weak(attribute), - /* K33 */ be_nested_str_weak(update_shadow_lazy), - /* K34 */ be_nested_str_weak(BOOL), - /* K35 */ be_nested_str_weak(read_attribute), - /* K36 */ be_nested_str_weak(get_name), - /* K37 */ be_nested_str_weak(PREFIX), - /* K38 */ be_nested_str_weak(html_escape), - /* K39 */ be_nested_str_weak(), - /* K40 */ be_nested_str_weak(get_power), - /* K41 */ be_nested_str_weak(command), - /* K42 */ be_nested_str_weak(publish_command), - /* K43 */ be_const_int(2), - /* K44 */ be_nested_str_weak(contains), - /* K45 */ be_nested_str_weak(POWER), - /* K46 */ be_nested_str_weak(ON), +// compact class 'Matter_Plugin_Light0' ktab size: 60, total: 104 (saved 352 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Light0[60] = { + /* K0 */ be_nested_str_weak(math), + /* K1 */ be_nested_str_weak(log), + /* K2 */ be_nested_str_weak(MTR_X3A_X20zigbee_received_X20Ox_X2504X_X20attr_list_X3D_X25s_X20type_X28attr_list_X29_X3D_X25s), + /* K3 */ be_nested_str_weak(zigbee_mapper), + /* K4 */ be_nested_str_weak(shortaddr), + /* K5 */ be_const_int(3), + /* K6 */ be_const_int(0), + /* K7 */ be_nested_str_weak(key), + /* K8 */ be_nested_str_weak(Power), + /* K9 */ be_nested_str_weak(val), + /* K10 */ be_nested_str_weak(Dimmer), + /* K11 */ be_nested_str_weak(CT), + /* K12 */ be_const_int(1), + /* K13 */ be_nested_str_weak(update_virtual), + /* K14 */ be_nested_str_weak(MTR_X3A_X20_X5B_X2502X_X5D_X20Light2_X20updated_X20_X25s), + /* K15 */ be_nested_str_weak(endpoint), + /* K16 */ be_nested_str_weak(tasmota_relay_index), + /* K17 */ be_nested_str_weak(contains), + /* K18 */ be_nested_str_weak(POWER), + /* K19 */ be_nested_str_weak(find), + /* K20 */ be_nested_str_weak(ON), + /* K21 */ be_nested_str_weak(shadow_onoff), + /* K22 */ be_nested_str_weak(attribute_updated), + /* K23 */ be_nested_str_weak(VIRTUAL), + /* K24 */ be_nested_str_weak(BRIDGE), + /* K25 */ be_nested_str_weak(tasmota), + /* K26 */ be_nested_str_weak(get_power), + /* K27 */ be_nested_str_weak(update_shadow), + /* K28 */ be_nested_str_weak(webserver), + /* K29 */ be_nested_str_weak(web_values_prefix), + /* K30 */ be_nested_str_weak(content_send), + /* K31 */ be_nested_str_weak(_X25s), + /* K32 */ be_nested_str_weak(web_value_onoff), + /* K33 */ be_nested_str_weak(matter), + /* K34 */ be_nested_str_weak(TLV), + /* K35 */ be_nested_str_weak(cluster), + /* K36 */ be_nested_str_weak(command), + /* K37 */ be_nested_str_weak(update_shadow_lazy), + /* K38 */ be_nested_str_weak(set_onoff), + /* K39 */ be_nested_str_weak(publish_command), + /* K40 */ be_const_int(2), + /* K41 */ be_nested_str_weak(attribute), + /* K42 */ be_nested_str_weak(set), + /* K43 */ be_nested_str_weak(BOOL), + /* K44 */ be_nested_str_weak(read_attribute), + /* K45 */ be_nested_str_weak(parse_configuration), + /* K46 */ be_nested_str_weak(ARG), + /* K47 */ be_nested_str_weak(get_name), + /* K48 */ be_nested_str_weak(PREFIX), + /* K49 */ be_nested_str_weak(html_escape), + /* K50 */ be_nested_str_weak(), + /* K51 */ be_nested_str_weak(light_index), + /* K52 */ be_nested_str_weak(init), + /* K53 */ be_nested_str_weak(call_remote_sync), + /* K54 */ be_nested_str_weak(1), + /* K55 */ be_nested_str_weak(0), + /* K56 */ be_nested_str_weak(parse_status), + /* K57 */ be_nested_str_weak(set_power), + /* K58 */ be_nested_str_weak(light), + /* K59 */ be_nested_str_weak(power), }; extern const bclass be_class_Matter_Plugin_Light0; /******************************************************************** -** Solidified function: set_onoff +** Solidified function: zigbee_received ********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_set_onoff, /* name */ +be_local_closure(class_Matter_Plugin_Light0_zigbee_received, /* name */ be_nested_proto( - 7, /* nstack */ - 2, /* argc */ + 11, /* nstack */ + 3, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -71,65 +84,187 @@ be_local_closure(class_Matter_Plugin_Light0_set_onoff, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(set_onoff), + be_str_weak(zigbee_received), &be_const_str_solidified, - ( &(const binstruction[56]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x780A0011, // 0001 JMPF R2 #0014 - 0x8C080101, // 0002 GETMET R2 R0 K1 - 0x60100008, // 0003 GETGBL R4 G8 - 0x88140103, // 0004 GETMBR R5 R0 K3 - 0x7C100200, // 0005 CALL R4 1 - 0x00120404, // 0006 ADD R4 K2 R4 - 0x78060001, // 0007 JMPF R1 #000A - 0x58140004, // 0008 LDCONST R5 K4 - 0x70020000, // 0009 JMP #000B - 0x58140005, // 000A LDCONST R5 K5 - 0x7C080600, // 000B CALL R2 3 - 0x4C0C0000, // 000C LDNIL R3 - 0x200C0403, // 000D NE R3 R2 R3 - 0x780E0003, // 000E JMPF R3 #0013 - 0x8C0C0106, // 000F GETMET R3 R0 K6 - 0x5C140400, // 0010 MOVE R5 R2 - 0x541A000A, // 0011 LDINT R6 11 - 0x7C0C0600, // 0012 CALL R3 3 - 0x70020022, // 0013 JMP #0037 - 0x88080107, // 0014 GETMBR R2 R0 K7 - 0x780A0008, // 0015 JMPF R2 #001F - 0x88080108, // 0016 GETMBR R2 R0 K8 - 0x20080202, // 0017 NE R2 R1 R2 - 0x780A0004, // 0018 JMPF R2 #001E - 0x8C080109, // 0019 GETMET R2 R0 K9 - 0x54120005, // 001A LDINT R4 6 - 0x5814000A, // 001B LDCONST R5 K10 - 0x7C080600, // 001C CALL R2 3 - 0x90021001, // 001D SETMBR R0 K8 R1 - 0x70020017, // 001E JMP #0037 - 0x88080103, // 001F GETMBR R2 R0 K3 - 0x4C0C0000, // 0020 LDNIL R3 - 0x20080403, // 0021 NE R2 R2 R3 - 0x780A000A, // 0022 JMPF R2 #002E - 0xB80A1600, // 0023 GETNGBL R2 K11 - 0x8C08050C, // 0024 GETMET R2 R2 K12 - 0x88100103, // 0025 GETMBR R4 R0 K3 - 0x0410090D, // 0026 SUB R4 R4 K13 - 0x60140017, // 0027 GETGBL R5 G23 - 0x5C180200, // 0028 MOVE R6 R1 - 0x7C140200, // 0029 CALL R5 1 - 0x7C080600, // 002A CALL R2 3 - 0x8C08010E, // 002B GETMET R2 R0 K14 - 0x7C080200, // 002C CALL R2 1 - 0x70020008, // 002D JMP #0037 - 0xA40A1E00, // 002E IMPORT R2 K15 - 0x8C0C0510, // 002F GETMET R3 R2 K16 - 0x60140013, // 0030 GETGBL R5 G19 - 0x7C140000, // 0031 CALL R5 0 - 0x98162201, // 0032 SETIDX R5 K17 R1 - 0x88180112, // 0033 GETMBR R6 R0 K18 - 0x7C0C0600, // 0034 CALL R3 3 - 0x8C0C010E, // 0035 GETMET R3 R0 K14 - 0x7C0C0200, // 0036 CALL R3 1 - 0x80000000, // 0037 RET 0 + ( &(const binstruction[62]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0xB8120200, // 0001 GETNGBL R4 K1 + 0x60140018, // 0002 GETGBL R5 G24 + 0x58180002, // 0003 LDCONST R6 K2 + 0x881C0103, // 0004 GETMBR R7 R0 K3 + 0x881C0F04, // 0005 GETMBR R7 R7 K4 + 0x5C200400, // 0006 MOVE R8 R2 + 0x60240004, // 0007 GETGBL R9 G4 + 0x5C280400, // 0008 MOVE R10 R2 + 0x7C240200, // 0009 CALL R9 1 + 0x7C140800, // 000A CALL R5 4 + 0x58180005, // 000B LDCONST R6 K5 + 0x7C100400, // 000C CALL R4 2 + 0x58100006, // 000D LDCONST R4 K6 + 0x60140013, // 000E GETGBL R5 G19 + 0x7C140000, // 000F CALL R5 0 + 0x6018000C, // 0010 GETGBL R6 G12 + 0x5C1C0400, // 0011 MOVE R7 R2 + 0x7C180200, // 0012 CALL R6 1 + 0x14180806, // 0013 LT R6 R4 R6 + 0x781A0017, // 0014 JMPF R6 #002D + 0x94180404, // 0015 GETIDX R6 R2 R4 + 0x881C0D07, // 0016 GETMBR R7 R6 K7 + 0x1C1C0F08, // 0017 EQ R7 R7 K8 + 0x781E0003, // 0018 JMPF R7 #001D + 0x601C0009, // 0019 GETGBL R7 G9 + 0x88200D09, // 001A GETMBR R8 R6 K9 + 0x7C1C0200, // 001B CALL R7 1 + 0x98161007, // 001C SETIDX R5 K8 R7 + 0x881C0D07, // 001D GETMBR R7 R6 K7 + 0x1C1C0F0A, // 001E EQ R7 R7 K10 + 0x781E0003, // 001F JMPF R7 #0024 + 0x601C0009, // 0020 GETGBL R7 G9 + 0x88200D09, // 0021 GETMBR R8 R6 K9 + 0x7C1C0200, // 0022 CALL R7 1 + 0x98161407, // 0023 SETIDX R5 K10 R7 + 0x881C0D07, // 0024 GETMBR R7 R6 K7 + 0x1C1C0F0B, // 0025 EQ R7 R7 K11 + 0x781E0003, // 0026 JMPF R7 #002B + 0x601C0009, // 0027 GETGBL R7 G9 + 0x88200D09, // 0028 GETMBR R8 R6 K9 + 0x7C1C0200, // 0029 CALL R7 1 + 0x98161607, // 002A SETIDX R5 K11 R7 + 0x0010090C, // 002B ADD R4 R4 K12 + 0x7001FFE2, // 002C JMP #0010 + 0x6018000C, // 002D GETGBL R6 G12 + 0x5C1C0A00, // 002E MOVE R7 R5 + 0x7C180200, // 002F CALL R6 1 + 0x24180D06, // 0030 GT R6 R6 K6 + 0x781A000A, // 0031 JMPF R6 #003D + 0x8C18010D, // 0032 GETMET R6 R0 K13 + 0x5C200A00, // 0033 MOVE R8 R5 + 0x7C180400, // 0034 CALL R6 2 + 0xB81A0200, // 0035 GETNGBL R6 K1 + 0x601C0018, // 0036 GETGBL R7 G24 + 0x5820000E, // 0037 LDCONST R8 K14 + 0x8824010F, // 0038 GETMBR R9 R0 K15 + 0x5C280A00, // 0039 MOVE R10 R5 + 0x7C1C0600, // 003A CALL R7 3 + 0x58200005, // 003B LDCONST R8 K5 + 0x7C180400, // 003C CALL R6 2 + 0x80000000, // 003D RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: parse_status +********************************************************************/ +be_local_closure(class_Matter_Plugin_Light0_parse_status, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ + be_str_weak(parse_status), + &be_const_str_solidified, + ( &(const binstruction[37]) { /* code */ + 0x540E000A, // 0000 LDINT R3 11 + 0x1C0C0403, // 0001 EQ R3 R2 R3 + 0x780E0020, // 0002 JMPF R3 #0024 + 0x500C0000, // 0003 LDBOOL R3 0 0 + 0x88100110, // 0004 GETMBR R4 R0 K16 + 0x1C10090C, // 0005 EQ R4 R4 K12 + 0x78120009, // 0006 JMPF R4 #0011 + 0x8C100311, // 0007 GETMET R4 R1 K17 + 0x58180012, // 0008 LDCONST R6 K18 + 0x7C100400, // 0009 CALL R4 2 + 0x78120005, // 000A JMPF R4 #0011 + 0x8C100313, // 000B GETMET R4 R1 K19 + 0x58180012, // 000C LDCONST R6 K18 + 0x7C100400, // 000D CALL R4 2 + 0x1C100914, // 000E EQ R4 R4 K20 + 0x5C0C0800, // 000F MOVE R3 R4 + 0x70020007, // 0010 JMP #0019 + 0x8C100313, // 0011 GETMET R4 R1 K19 + 0x60180008, // 0012 GETGBL R6 G8 + 0x881C0110, // 0013 GETMBR R7 R0 K16 + 0x7C180200, // 0014 CALL R6 1 + 0x001A2406, // 0015 ADD R6 K18 R6 + 0x7C100400, // 0016 CALL R4 2 + 0x1C100914, // 0017 EQ R4 R4 K20 + 0x5C0C0800, // 0018 MOVE R3 R4 + 0x88100115, // 0019 GETMBR R4 R0 K21 + 0x60140017, // 001A GETGBL R5 G23 + 0x5C180600, // 001B MOVE R6 R3 + 0x7C140200, // 001C CALL R5 1 + 0x20100805, // 001D NE R4 R4 R5 + 0x78120004, // 001E JMPF R4 #0024 + 0x8C100116, // 001F GETMET R4 R0 K22 + 0x541A0005, // 0020 LDINT R6 6 + 0x581C0006, // 0021 LDCONST R7 K6 + 0x7C100600, // 0022 CALL R4 3 + 0x90022A03, // 0023 SETMBR R0 K21 R3 + 0x80000000, // 0024 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: update_shadow +********************************************************************/ +be_local_closure(class_Matter_Plugin_Light0_update_shadow, /* name */ + be_nested_proto( + 6, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ + be_str_weak(update_shadow), + &be_const_str_solidified, + ( &(const binstruction[33]) { /* code */ + 0x88040117, // 0000 GETMBR R1 R0 K23 + 0x74060018, // 0001 JMPT R1 #001B + 0x88040118, // 0002 GETMBR R1 R0 K24 + 0x74060016, // 0003 JMPT R1 #001B + 0x88040110, // 0004 GETMBR R1 R0 K16 + 0x4C080000, // 0005 LDNIL R2 + 0x20040202, // 0006 NE R1 R1 R2 + 0x78060012, // 0007 JMPF R1 #001B + 0xB8063200, // 0008 GETNGBL R1 K25 + 0x8C04031A, // 0009 GETMET R1 R1 K26 + 0x880C0110, // 000A GETMBR R3 R0 K16 + 0x040C070C, // 000B SUB R3 R3 K12 + 0x7C040400, // 000C CALL R1 2 + 0x4C080000, // 000D LDNIL R2 + 0x20080202, // 000E NE R2 R1 R2 + 0x780A000A, // 000F JMPF R2 #001B + 0x88080115, // 0010 GETMBR R2 R0 K21 + 0x600C0017, // 0011 GETGBL R3 G23 + 0x5C100200, // 0012 MOVE R4 R1 + 0x7C0C0200, // 0013 CALL R3 1 + 0x20080403, // 0014 NE R2 R2 R3 + 0x780A0003, // 0015 JMPF R2 #001A + 0x8C080116, // 0016 GETMET R2 R0 K22 + 0x54120005, // 0017 LDINT R4 6 + 0x58140006, // 0018 LDCONST R5 K6 + 0x7C080600, // 0019 CALL R2 3 + 0x90022A01, // 001A SETMBR R0 K21 R1 + 0x60040003, // 001B GETGBL R1 G3 + 0x5C080000, // 001C MOVE R2 R0 + 0x7C040200, // 001D CALL R1 1 + 0x8C04031B, // 001E GETMET R1 R1 K27 + 0x7C040200, // 001F CALL R1 1 + 0x80000000, // 0020 RET 0 }) ) ); @@ -153,14 +288,14 @@ be_local_closure(class_Matter_Plugin_Light0_web_values, /* name */ be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[12]) { /* code */ - 0xA4062600, // 0000 IMPORT R1 K19 - 0x8C080114, // 0001 GETMET R2 R0 K20 + 0xA4063800, // 0000 IMPORT R1 K28 + 0x8C08011D, // 0001 GETMET R2 R0 K29 0x7C080200, // 0002 CALL R2 1 - 0x8C080315, // 0003 GETMET R2 R1 K21 + 0x8C08031E, // 0003 GETMET R2 R1 K30 0x60100018, // 0004 GETGBL R4 G24 - 0x58140016, // 0005 LDCONST R5 K22 - 0x8C180117, // 0006 GETMET R6 R0 K23 - 0x88200108, // 0007 GETMBR R8 R0 K8 + 0x5814001F, // 0005 LDCONST R5 K31 + 0x8C180120, // 0006 GETMET R6 R0 K32 + 0x88200115, // 0007 GETMBR R8 R0 K21 0x7C180400, // 0008 CALL R6 2 0x7C100400, // 0009 CALL R4 2 0x7C080400, // 000A CALL R2 2 @@ -171,6 +306,219 @@ be_local_closure(class_Matter_Plugin_Light0_web_values, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: invoke_request +********************************************************************/ +be_local_closure(class_Matter_Plugin_Light0_invoke_request, /* name */ + be_nested_proto( + 11, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ + be_str_weak(invoke_request), + &be_const_str_solidified, + ( &(const binstruction[52]) { /* code */ + 0xB8124200, // 0000 GETNGBL R4 K33 + 0x88100922, // 0001 GETMBR R4 R4 K34 + 0x88140723, // 0002 GETMBR R5 R3 K35 + 0x88180724, // 0003 GETMBR R6 R3 K36 + 0x541E0005, // 0004 LDINT R7 6 + 0x1C1C0A07, // 0005 EQ R7 R5 R7 + 0x781E002B, // 0006 JMPF R7 #0033 + 0x8C1C0125, // 0007 GETMET R7 R0 K37 + 0x7C1C0200, // 0008 CALL R7 1 + 0x1C1C0D06, // 0009 EQ R7 R6 K6 + 0x781E0009, // 000A JMPF R7 #0015 + 0x8C1C0126, // 000B GETMET R7 R0 K38 + 0x50240000, // 000C LDBOOL R9 0 0 + 0x7C1C0400, // 000D CALL R7 2 + 0x8C1C0127, // 000E GETMET R7 R0 K39 + 0x58240008, // 000F LDCONST R9 K8 + 0x58280006, // 0010 LDCONST R10 K6 + 0x7C1C0600, // 0011 CALL R7 3 + 0x501C0200, // 0012 LDBOOL R7 1 0 + 0x80040E00, // 0013 RET 1 R7 + 0x7002001D, // 0014 JMP #0033 + 0x1C1C0D0C, // 0015 EQ R7 R6 K12 + 0x781E0009, // 0016 JMPF R7 #0021 + 0x8C1C0126, // 0017 GETMET R7 R0 K38 + 0x50240200, // 0018 LDBOOL R9 1 0 + 0x7C1C0400, // 0019 CALL R7 2 + 0x8C1C0127, // 001A GETMET R7 R0 K39 + 0x58240008, // 001B LDCONST R9 K8 + 0x5828000C, // 001C LDCONST R10 K12 + 0x7C1C0600, // 001D CALL R7 3 + 0x501C0200, // 001E LDBOOL R7 1 0 + 0x80040E00, // 001F RET 1 R7 + 0x70020011, // 0020 JMP #0033 + 0x1C1C0D28, // 0021 EQ R7 R6 K40 + 0x781E000F, // 0022 JMPF R7 #0033 + 0x8C1C0126, // 0023 GETMET R7 R0 K38 + 0x88240115, // 0024 GETMBR R9 R0 K21 + 0x78260000, // 0025 JMPF R9 #0027 + 0x50240001, // 0026 LDBOOL R9 0 1 + 0x50240200, // 0027 LDBOOL R9 1 0 + 0x7C1C0400, // 0028 CALL R7 2 + 0x8C1C0127, // 0029 GETMET R7 R0 K39 + 0x58240008, // 002A LDCONST R9 K8 + 0x88280115, // 002B GETMBR R10 R0 K21 + 0x782A0001, // 002C JMPF R10 #002F + 0x5828000C, // 002D LDCONST R10 K12 + 0x70020000, // 002E JMP #0030 + 0x58280006, // 002F LDCONST R10 K6 + 0x7C1C0600, // 0030 CALL R7 3 + 0x501C0200, // 0031 LDBOOL R7 1 0 + 0x80040E00, // 0032 RET 1 R7 + 0x80000000, // 0033 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: read_attribute +********************************************************************/ +be_local_closure(class_Matter_Plugin_Light0_read_attribute, /* name */ + be_nested_proto( + 12, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ + be_str_weak(read_attribute), + &be_const_str_solidified, + ( &(const binstruction[25]) { /* code */ + 0xB8124200, // 0000 GETNGBL R4 K33 + 0x88100922, // 0001 GETMBR R4 R4 K34 + 0x88140523, // 0002 GETMBR R5 R2 K35 + 0x88180529, // 0003 GETMBR R6 R2 K41 + 0x541E0005, // 0004 LDINT R7 6 + 0x1C1C0A07, // 0005 EQ R7 R5 R7 + 0x781E0008, // 0006 JMPF R7 #0010 + 0x8C1C0125, // 0007 GETMET R7 R0 K37 + 0x7C1C0200, // 0008 CALL R7 1 + 0x1C1C0D06, // 0009 EQ R7 R6 K6 + 0x781E0004, // 000A JMPF R7 #0010 + 0x8C1C072A, // 000B GETMET R7 R3 K42 + 0x8824092B, // 000C GETMBR R9 R4 K43 + 0x88280115, // 000D GETMBR R10 R0 K21 + 0x7C1C0600, // 000E CALL R7 3 + 0x80040E00, // 000F RET 1 R7 + 0x601C0003, // 0010 GETGBL R7 G3 + 0x5C200000, // 0011 MOVE R8 R0 + 0x7C1C0200, // 0012 CALL R7 1 + 0x8C1C0F2C, // 0013 GETMET R7 R7 K44 + 0x5C240200, // 0014 MOVE R9 R1 + 0x5C280400, // 0015 MOVE R10 R2 + 0x5C2C0600, // 0016 MOVE R11 R3 + 0x7C1C0800, // 0017 CALL R7 4 + 0x80040E00, // 0018 RET 1 R7 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: parse_configuration +********************************************************************/ +be_local_closure(class_Matter_Plugin_Light0_parse_configuration, /* name */ + be_nested_proto( + 7, /* nstack */ + 2, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ + be_str_weak(parse_configuration), + &be_const_str_solidified, + ( &(const binstruction[22]) { /* code */ + 0x60080003, // 0000 GETGBL R2 G3 + 0x5C0C0000, // 0001 MOVE R3 R0 + 0x7C080200, // 0002 CALL R2 1 + 0x8C08052D, // 0003 GETMET R2 R2 K45 + 0x5C100200, // 0004 MOVE R4 R1 + 0x7C080400, // 0005 CALL R2 2 + 0x60080009, // 0006 GETGBL R2 G9 + 0x8C0C0313, // 0007 GETMET R3 R1 K19 + 0x8814012E, // 0008 GETMBR R5 R0 K46 + 0x4C180000, // 0009 LDNIL R6 + 0x7C0C0600, // 000A CALL R3 3 + 0x7C080200, // 000B CALL R2 1 + 0x90022002, // 000C SETMBR R0 K16 R2 + 0x88080110, // 000D GETMBR R2 R0 K16 + 0x4C0C0000, // 000E LDNIL R3 + 0x20080403, // 000F NE R2 R2 R3 + 0x780A0003, // 0010 JMPF R2 #0015 + 0x88080110, // 0011 GETMBR R2 R0 K16 + 0x18080506, // 0012 LE R2 R2 K6 + 0x780A0000, // 0013 JMPF R2 #0015 + 0x9002210C, // 0014 SETMBR R0 K16 K12 + 0x80000000, // 0015 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: web_values_prefix +********************************************************************/ +be_local_closure(class_Matter_Plugin_Light0_web_values_prefix, /* name */ + be_nested_proto( + 10, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ + be_str_weak(web_values_prefix), + &be_const_str_solidified, + ( &(const binstruction[22]) { /* code */ + 0xA4063800, // 0000 IMPORT R1 K28 + 0x8C08012F, // 0001 GETMET R2 R0 K47 + 0x7C080200, // 0002 CALL R2 1 + 0x5C0C0400, // 0003 MOVE R3 R2 + 0x740E0004, // 0004 JMPT R3 #000A + 0x600C0008, // 0005 GETGBL R3 G8 + 0x88100110, // 0006 GETMBR R4 R0 K16 + 0x7C0C0200, // 0007 CALL R3 1 + 0x000E1003, // 0008 ADD R3 K8 R3 + 0x5C080600, // 0009 MOVE R2 R3 + 0x8C0C031E, // 000A GETMET R3 R1 K30 + 0x60140018, // 000B GETGBL R5 G24 + 0x88180130, // 000C GETMBR R6 R0 K48 + 0x780A0003, // 000D JMPF R2 #0012 + 0x8C1C0331, // 000E GETMET R7 R1 K49 + 0x5C240400, // 000F MOVE R9 R2 + 0x7C1C0400, // 0010 CALL R7 2 + 0x70020000, // 0011 JMP #0013 + 0x581C0032, // 0012 LDCONST R7 K50 + 0x7C140400, // 0013 CALL R5 2 + 0x7C0C0400, // 0014 CALL R3 2 + 0x80000000, // 0015 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: init ********************************************************************/ @@ -189,12 +537,12 @@ be_local_closure(class_Matter_Plugin_Light0_init, /* name */ &be_const_str_solidified, ( &(const binstruction[12]) { /* code */ 0x50100000, // 0000 LDBOOL R4 0 0 - 0x90021004, // 0001 SETMBR R0 K8 R4 - 0x9002250A, // 0002 SETMBR R0 K18 K10 + 0x90022A04, // 0001 SETMBR R0 K21 R4 + 0x90026706, // 0002 SETMBR R0 K51 K6 0x60100003, // 0003 GETGBL R4 G3 0x5C140000, // 0004 MOVE R5 R0 0x7C100200, // 0005 CALL R4 1 - 0x8C100918, // 0006 GETMET R4 R4 K24 + 0x8C100934, // 0006 GETMET R4 R4 K52 0x5C180200, // 0007 MOVE R6 R1 0x5C1C0400, // 0008 MOVE R7 R2 0x5C200600, // 0009 MOVE R8 R3 @@ -206,179 +554,6 @@ be_local_closure(class_Matter_Plugin_Light0_init, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: parse_configuration -********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_parse_configuration, /* name */ - be_nested_proto( - 7, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(parse_configuration), - &be_const_str_solidified, - ( &(const binstruction[16]) { /* code */ - 0x60080009, // 0000 GETGBL R2 G9 - 0x8C0C0319, // 0001 GETMET R3 R1 K25 - 0x8814011A, // 0002 GETMBR R5 R0 K26 - 0x4C180000, // 0003 LDNIL R6 - 0x7C0C0600, // 0004 CALL R3 3 - 0x7C080200, // 0005 CALL R2 1 - 0x90020602, // 0006 SETMBR R0 K3 R2 - 0x88080103, // 0007 GETMBR R2 R0 K3 - 0x4C0C0000, // 0008 LDNIL R3 - 0x20080403, // 0009 NE R2 R2 R3 - 0x780A0003, // 000A JMPF R2 #000F - 0x88080103, // 000B GETMBR R2 R0 K3 - 0x1808050A, // 000C LE R2 R2 K10 - 0x780A0000, // 000D JMPF R2 #000F - 0x9002070D, // 000E SETMBR R0 K3 K13 - 0x80000000, // 000F RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: update_virtual -********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_update_virtual, /* name */ - be_nested_proto( - 7, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(update_virtual), - &be_const_str_solidified, - ( &(const binstruction[18]) { /* code */ - 0x8C080319, // 0000 GETMET R2 R1 K25 - 0x58100002, // 0001 LDCONST R4 K2 - 0x7C080400, // 0002 CALL R2 2 - 0x4C0C0000, // 0003 LDNIL R3 - 0x200C0403, // 0004 NE R3 R2 R3 - 0x780E0004, // 0005 JMPF R3 #000B - 0x8C0C011B, // 0006 GETMET R3 R0 K27 - 0x60140017, // 0007 GETGBL R5 G23 - 0x5C180400, // 0008 MOVE R6 R2 - 0x7C140200, // 0009 CALL R5 1 - 0x7C0C0400, // 000A CALL R3 2 - 0x600C0003, // 000B GETGBL R3 G3 - 0x5C100000, // 000C MOVE R4 R0 - 0x7C0C0200, // 000D CALL R3 1 - 0x8C0C071C, // 000E GETMET R3 R3 K28 - 0x5C140200, // 000F MOVE R5 R1 - 0x7C0C0400, // 0010 CALL R3 2 - 0x80000000, // 0011 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: read_attribute -********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_read_attribute, /* name */ - be_nested_proto( - 12, /* nstack */ - 4, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(read_attribute), - &be_const_str_solidified, - ( &(const binstruction[25]) { /* code */ - 0xB8123A00, // 0000 GETNGBL R4 K29 - 0x8810091E, // 0001 GETMBR R4 R4 K30 - 0x8814051F, // 0002 GETMBR R5 R2 K31 - 0x88180520, // 0003 GETMBR R6 R2 K32 - 0x541E0005, // 0004 LDINT R7 6 - 0x1C1C0A07, // 0005 EQ R7 R5 R7 - 0x781E0008, // 0006 JMPF R7 #0010 - 0x8C1C0121, // 0007 GETMET R7 R0 K33 - 0x7C1C0200, // 0008 CALL R7 1 - 0x1C1C0D0A, // 0009 EQ R7 R6 K10 - 0x781E0004, // 000A JMPF R7 #0010 - 0x8C1C0710, // 000B GETMET R7 R3 K16 - 0x88240922, // 000C GETMBR R9 R4 K34 - 0x88280108, // 000D GETMBR R10 R0 K8 - 0x7C1C0600, // 000E CALL R7 3 - 0x80040E00, // 000F RET 1 R7 - 0x601C0003, // 0010 GETGBL R7 G3 - 0x5C200000, // 0011 MOVE R8 R0 - 0x7C1C0200, // 0012 CALL R7 1 - 0x8C1C0F23, // 0013 GETMET R7 R7 K35 - 0x5C240200, // 0014 MOVE R9 R1 - 0x5C280400, // 0015 MOVE R10 R2 - 0x5C2C0600, // 0016 MOVE R11 R3 - 0x7C1C0800, // 0017 CALL R7 4 - 0x80040E00, // 0018 RET 1 R7 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: web_values_prefix -********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_web_values_prefix, /* name */ - be_nested_proto( - 10, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(web_values_prefix), - &be_const_str_solidified, - ( &(const binstruction[22]) { /* code */ - 0xA4062600, // 0000 IMPORT R1 K19 - 0x8C080124, // 0001 GETMET R2 R0 K36 - 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 - 0x8C0C0315, // 000A GETMET R3 R1 K21 - 0x60140018, // 000B GETGBL R5 G24 - 0x88180125, // 000C GETMBR R6 R0 K37 - 0x780A0003, // 000D JMPF R2 #0012 - 0x8C1C0326, // 000E GETMET R7 R1 K38 - 0x5C240400, // 000F MOVE R9 R2 - 0x7C1C0400, // 0010 CALL R7 2 - 0x70020000, // 0011 JMP #0013 - 0x581C0027, // 0012 LDCONST R7 K39 - 0x7C140400, // 0013 CALL R5 2 - 0x7C0C0400, // 0014 CALL R3 2 - 0x80000000, // 0015 RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: ********************************************************************/ @@ -407,12 +582,12 @@ be_local_closure(class_Matter_Plugin_Light0__X3Clambda_X3E, /* name */ /******************************************************************** -** Solidified function: update_shadow +** Solidified function: set_onoff ********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_update_shadow, /* name */ +be_local_closure(class_Matter_Plugin_Light0_set_onoff, /* name */ be_nested_proto( - 6, /* nstack */ - 1, /* argc */ + 7, /* nstack */ + 2, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -420,42 +595,65 @@ be_local_closure(class_Matter_Plugin_Light0_update_shadow, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(update_shadow), + be_str_weak(set_onoff), &be_const_str_solidified, - ( &(const binstruction[33]) { /* code */ - 0x88040107, // 0000 GETMBR R1 R0 K7 - 0x74060018, // 0001 JMPT R1 #001B - 0x88040100, // 0002 GETMBR R1 R0 K0 - 0x74060016, // 0003 JMPT R1 #001B - 0x88040103, // 0004 GETMBR R1 R0 K3 - 0x4C080000, // 0005 LDNIL R2 - 0x20040202, // 0006 NE R1 R1 R2 - 0x78060012, // 0007 JMPF R1 #001B - 0xB8061600, // 0008 GETNGBL R1 K11 - 0x8C040328, // 0009 GETMET R1 R1 K40 - 0x880C0103, // 000A GETMBR R3 R0 K3 - 0x040C070D, // 000B SUB R3 R3 K13 - 0x7C040400, // 000C CALL R1 2 - 0x4C080000, // 000D LDNIL R2 - 0x20080202, // 000E NE R2 R1 R2 - 0x780A000A, // 000F JMPF R2 #001B - 0x88080108, // 0010 GETMBR R2 R0 K8 - 0x600C0017, // 0011 GETGBL R3 G23 - 0x5C100200, // 0012 MOVE R4 R1 - 0x7C0C0200, // 0013 CALL R3 1 - 0x20080403, // 0014 NE R2 R2 R3 - 0x780A0003, // 0015 JMPF R2 #001A - 0x8C080109, // 0016 GETMET R2 R0 K9 - 0x54120005, // 0017 LDINT R4 6 - 0x5814000A, // 0018 LDCONST R5 K10 - 0x7C080600, // 0019 CALL R2 3 - 0x90021001, // 001A SETMBR R0 K8 R1 - 0x60040003, // 001B GETGBL R1 G3 - 0x5C080000, // 001C MOVE R2 R0 - 0x7C040200, // 001D CALL R1 1 - 0x8C04030E, // 001E GETMET R1 R1 K14 - 0x7C040200, // 001F CALL R1 1 - 0x80000000, // 0020 RET 0 + ( &(const binstruction[56]) { /* code */ + 0x88080118, // 0000 GETMBR R2 R0 K24 + 0x780A0011, // 0001 JMPF R2 #0014 + 0x8C080135, // 0002 GETMET R2 R0 K53 + 0x60100008, // 0003 GETGBL R4 G8 + 0x88140110, // 0004 GETMBR R5 R0 K16 + 0x7C100200, // 0005 CALL R4 1 + 0x00121004, // 0006 ADD R4 K8 R4 + 0x78060001, // 0007 JMPF R1 #000A + 0x58140036, // 0008 LDCONST R5 K54 + 0x70020000, // 0009 JMP #000B + 0x58140037, // 000A LDCONST R5 K55 + 0x7C080600, // 000B CALL R2 3 + 0x4C0C0000, // 000C LDNIL R3 + 0x200C0403, // 000D NE R3 R2 R3 + 0x780E0003, // 000E JMPF R3 #0013 + 0x8C0C0138, // 000F GETMET R3 R0 K56 + 0x5C140400, // 0010 MOVE R5 R2 + 0x541A000A, // 0011 LDINT R6 11 + 0x7C0C0600, // 0012 CALL R3 3 + 0x70020022, // 0013 JMP #0037 + 0x88080117, // 0014 GETMBR R2 R0 K23 + 0x780A0008, // 0015 JMPF R2 #001F + 0x88080115, // 0016 GETMBR R2 R0 K21 + 0x20080202, // 0017 NE R2 R1 R2 + 0x780A0004, // 0018 JMPF R2 #001E + 0x8C080116, // 0019 GETMET R2 R0 K22 + 0x54120005, // 001A LDINT R4 6 + 0x58140006, // 001B LDCONST R5 K6 + 0x7C080600, // 001C CALL R2 3 + 0x90022A01, // 001D SETMBR R0 K21 R1 + 0x70020017, // 001E JMP #0037 + 0x88080110, // 001F GETMBR R2 R0 K16 + 0x4C0C0000, // 0020 LDNIL R3 + 0x20080403, // 0021 NE R2 R2 R3 + 0x780A000A, // 0022 JMPF R2 #002E + 0xB80A3200, // 0023 GETNGBL R2 K25 + 0x8C080539, // 0024 GETMET R2 R2 K57 + 0x88100110, // 0025 GETMBR R4 R0 K16 + 0x0410090C, // 0026 SUB R4 R4 K12 + 0x60140017, // 0027 GETGBL R5 G23 + 0x5C180200, // 0028 MOVE R6 R1 + 0x7C140200, // 0029 CALL R5 1 + 0x7C080600, // 002A CALL R2 3 + 0x8C08011B, // 002B GETMET R2 R0 K27 + 0x7C080200, // 002C CALL R2 1 + 0x70020008, // 002D JMP #0037 + 0xA40A7400, // 002E IMPORT R2 K58 + 0x8C0C052A, // 002F GETMET R3 R2 K42 + 0x60140013, // 0030 GETGBL R5 G19 + 0x7C140000, // 0031 CALL R5 0 + 0x98167601, // 0032 SETIDX R5 K59 R1 + 0x88180133, // 0033 GETMBR R6 R0 K51 + 0x7C0C0600, // 0034 CALL R3 3 + 0x8C0C011B, // 0035 GETMET R3 R0 K27 + 0x7C0C0200, // 0036 CALL R3 1 + 0x80000000, // 0037 RET 0 }) ) ); @@ -463,12 +661,12 @@ be_local_closure(class_Matter_Plugin_Light0_update_shadow, /* name */ /******************************************************************** -** Solidified function: invoke_request +** Solidified function: update_virtual ********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_invoke_request, /* name */ +be_local_closure(class_Matter_Plugin_Light0_update_virtual, /* name */ be_nested_proto( - 11, /* nstack */ - 4, /* argc */ + 7, /* nstack */ + 2, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -476,121 +674,27 @@ be_local_closure(class_Matter_Plugin_Light0_invoke_request, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(invoke_request), + be_str_weak(update_virtual), &be_const_str_solidified, - ( &(const binstruction[52]) { /* code */ - 0xB8123A00, // 0000 GETNGBL R4 K29 - 0x8810091E, // 0001 GETMBR R4 R4 K30 - 0x8814071F, // 0002 GETMBR R5 R3 K31 - 0x88180729, // 0003 GETMBR R6 R3 K41 - 0x541E0005, // 0004 LDINT R7 6 - 0x1C1C0A07, // 0005 EQ R7 R5 R7 - 0x781E002B, // 0006 JMPF R7 #0033 - 0x8C1C0121, // 0007 GETMET R7 R0 K33 - 0x7C1C0200, // 0008 CALL R7 1 - 0x1C1C0D0A, // 0009 EQ R7 R6 K10 - 0x781E0009, // 000A JMPF R7 #0015 - 0x8C1C011B, // 000B GETMET R7 R0 K27 - 0x50240000, // 000C LDBOOL R9 0 0 - 0x7C1C0400, // 000D CALL R7 2 - 0x8C1C012A, // 000E GETMET R7 R0 K42 - 0x58240002, // 000F LDCONST R9 K2 - 0x5828000A, // 0010 LDCONST R10 K10 - 0x7C1C0600, // 0011 CALL R7 3 - 0x501C0200, // 0012 LDBOOL R7 1 0 - 0x80040E00, // 0013 RET 1 R7 - 0x7002001D, // 0014 JMP #0033 - 0x1C1C0D0D, // 0015 EQ R7 R6 K13 - 0x781E0009, // 0016 JMPF R7 #0021 - 0x8C1C011B, // 0017 GETMET R7 R0 K27 - 0x50240200, // 0018 LDBOOL R9 1 0 - 0x7C1C0400, // 0019 CALL R7 2 - 0x8C1C012A, // 001A GETMET R7 R0 K42 - 0x58240002, // 001B LDCONST R9 K2 - 0x5828000D, // 001C LDCONST R10 K13 - 0x7C1C0600, // 001D CALL R7 3 - 0x501C0200, // 001E LDBOOL R7 1 0 - 0x80040E00, // 001F RET 1 R7 - 0x70020011, // 0020 JMP #0033 - 0x1C1C0D2B, // 0021 EQ R7 R6 K43 - 0x781E000F, // 0022 JMPF R7 #0033 - 0x8C1C011B, // 0023 GETMET R7 R0 K27 - 0x88240108, // 0024 GETMBR R9 R0 K8 - 0x78260000, // 0025 JMPF R9 #0027 - 0x50240001, // 0026 LDBOOL R9 0 1 - 0x50240200, // 0027 LDBOOL R9 1 0 - 0x7C1C0400, // 0028 CALL R7 2 - 0x8C1C012A, // 0029 GETMET R7 R0 K42 - 0x58240002, // 002A LDCONST R9 K2 - 0x88280108, // 002B GETMBR R10 R0 K8 - 0x782A0001, // 002C JMPF R10 #002F - 0x5828000D, // 002D LDCONST R10 K13 - 0x70020000, // 002E JMP #0030 - 0x5828000A, // 002F LDCONST R10 K10 - 0x7C1C0600, // 0030 CALL R7 3 - 0x501C0200, // 0031 LDBOOL R7 1 0 - 0x80040E00, // 0032 RET 1 R7 - 0x80000000, // 0033 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: parse_status -********************************************************************/ -be_local_closure(class_Matter_Plugin_Light0_parse_status, /* name */ - be_nested_proto( - 8, /* nstack */ - 3, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Light0, /* shared constants */ - be_str_weak(parse_status), - &be_const_str_solidified, - ( &(const binstruction[37]) { /* code */ - 0x540E000A, // 0000 LDINT R3 11 - 0x1C0C0403, // 0001 EQ R3 R2 R3 - 0x780E0020, // 0002 JMPF R3 #0024 - 0x500C0000, // 0003 LDBOOL R3 0 0 - 0x88100103, // 0004 GETMBR R4 R0 K3 - 0x1C10090D, // 0005 EQ R4 R4 K13 - 0x78120009, // 0006 JMPF R4 #0011 - 0x8C10032C, // 0007 GETMET R4 R1 K44 - 0x5818002D, // 0008 LDCONST R6 K45 - 0x7C100400, // 0009 CALL R4 2 - 0x78120005, // 000A JMPF R4 #0011 - 0x8C100319, // 000B GETMET R4 R1 K25 - 0x5818002D, // 000C LDCONST R6 K45 - 0x7C100400, // 000D CALL R4 2 - 0x1C10092E, // 000E EQ R4 R4 K46 - 0x5C0C0800, // 000F MOVE R3 R4 - 0x70020007, // 0010 JMP #0019 - 0x8C100319, // 0011 GETMET R4 R1 K25 - 0x60180008, // 0012 GETGBL R6 G8 - 0x881C0103, // 0013 GETMBR R7 R0 K3 - 0x7C180200, // 0014 CALL R6 1 - 0x001A5A06, // 0015 ADD R6 K45 R6 - 0x7C100400, // 0016 CALL R4 2 - 0x1C10092E, // 0017 EQ R4 R4 K46 - 0x5C0C0800, // 0018 MOVE R3 R4 - 0x88100108, // 0019 GETMBR R4 R0 K8 - 0x60140017, // 001A GETGBL R5 G23 - 0x5C180600, // 001B MOVE R6 R3 - 0x7C140200, // 001C CALL R5 1 - 0x20100805, // 001D NE R4 R4 R5 - 0x78120004, // 001E JMPF R4 #0024 - 0x8C100109, // 001F GETMET R4 R0 K9 - 0x541A0005, // 0020 LDINT R6 6 - 0x581C000A, // 0021 LDCONST R7 K10 - 0x7C100600, // 0022 CALL R4 3 - 0x90021003, // 0023 SETMBR R0 K8 R3 - 0x80000000, // 0024 RET 0 + ( &(const binstruction[18]) { /* code */ + 0x8C080313, // 0000 GETMET R2 R1 K19 + 0x58100008, // 0001 LDCONST R4 K8 + 0x7C080400, // 0002 CALL R2 2 + 0x4C0C0000, // 0003 LDNIL R3 + 0x200C0403, // 0004 NE R3 R2 R3 + 0x780E0004, // 0005 JMPF R3 #000B + 0x8C0C0126, // 0006 GETMET R3 R0 K38 + 0x60140017, // 0007 GETGBL R5 G23 + 0x5C180400, // 0008 MOVE R6 R2 + 0x7C140200, // 0009 CALL R5 1 + 0x7C0C0400, // 000A CALL R3 2 + 0x600C0003, // 000B GETGBL R3 G3 + 0x5C100000, // 000C MOVE R4 R0 + 0x7C0C0200, // 000D CALL R3 1 + 0x8C0C070D, // 000E GETMET R3 R3 K13 + 0x5C140200, // 000F MOVE R5 R1 + 0x7C0C0400, // 0010 CALL R3 2 + 0x80000000, // 0011 RET 0 }) ) ); @@ -604,15 +708,10 @@ extern const bclass be_class_Matter_Plugin_Device; be_local_class(Matter_Plugin_Light0, 3, &be_class_Matter_Plugin_Device, - be_nested_map(22, + be_nested_map(23, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(parse_status, 8), be_const_closure(class_Matter_Plugin_Light0_parse_status_closure) }, - { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Relay_X3Cx_X3E_X20number) }, - { be_const_key_weak(light_index, -1), be_const_var(1) }, - { be_const_key_weak(UPDATE_TIME, -1), be_const_int(250) }, - { be_const_key_weak(set_onoff, 18), be_const_closure(class_Matter_Plugin_Light0_set_onoff_closure) }, - { be_const_key_weak(tasmota_relay_index, -1), be_const_var(0) }, - { be_const_key_weak(CLUSTERS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { + { be_const_key_weak(update_virtual, 13), be_const_closure(class_Matter_Plugin_Light0_update_virtual_closure) }, + { be_const_key_weak(CLUSTERS, 15), 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(6, -1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, @@ -622,29 +721,35 @@ be_local_class(Matter_Plugin_Light0, { be_const_key_int(4, -1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(29, 1), be_const_bytes_instance(0000000100020003FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, - { be_const_key_weak(ARG, -1), be_nested_str_weak(relay) }, - { be_const_key_weak(invoke_request, 10), be_const_closure(class_Matter_Plugin_Light0_invoke_request_closure) }, - { be_const_key_weak(init, 5), be_const_closure(class_Matter_Plugin_Light0_init_closure) }, + { be_const_key_weak(zigbee_received, 0), be_const_closure(class_Matter_Plugin_Light0_zigbee_received_closure) }, + { be_const_key_weak(TYPE, -1), be_nested_str_weak(light0) }, + { be_const_key_weak(parse_status, -1), be_const_closure(class_Matter_Plugin_Light0_parse_status_closure) }, + { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Relay_X3Cx_X3E_X20number) }, + { be_const_key_weak(UPDATE_TIME, 11), be_const_int(250) }, + { be_const_key_weak(update_shadow, -1), be_const_closure(class_Matter_Plugin_Light0_update_shadow_closure) }, + { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Light0_web_values_closure) }, + { be_const_key_weak(invoke_request, -1), be_const_closure(class_Matter_Plugin_Light0_invoke_request_closure) }, + { be_const_key_weak(read_attribute, -1), be_const_closure(class_Matter_Plugin_Light0_read_attribute_closure) }, + { be_const_key_weak(tasmota_relay_index, -1), be_const_var(0) }, + { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Light0_web_values_prefix_closure) }, + { be_const_key_weak(ARG, 18), be_nested_str_weak(relay) }, + { be_const_key_weak(init, -1), be_const_closure(class_Matter_Plugin_Light0_init_closure) }, + { be_const_key_weak(TYPES, 21), 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(256, -1), be_const_int(2) }, + })) ) } )) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Light_X200_X20OnOff) }, + { be_const_key_weak(light_index, 1), be_const_var(1) }, + { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(class_Matter_Plugin_Light0__X3Clambda_X3E_closure) }, + { be_const_key_weak(set_onoff, -1), be_const_closure(class_Matter_Plugin_Light0_set_onoff_closure) }, + { be_const_key_weak(shadow_onoff, 5), be_const_var(2) }, + { be_const_key_weak(parse_configuration, 22), be_const_closure(class_Matter_Plugin_Light0_parse_configuration_closure) }, { 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(Power), })) ) } )) }, - { be_const_key_weak(read_attribute, -1), be_const_closure(class_Matter_Plugin_Light0_read_attribute_closure) }, - { be_const_key_weak(update_virtual, -1), be_const_closure(class_Matter_Plugin_Light0_update_virtual_closure) }, - { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Light0_web_values_prefix_closure) }, - { be_const_key_weak(shadow_onoff, 11), be_const_var(2) }, - { be_const_key_weak(TYPE, 13), be_nested_str_weak(light0) }, - { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(class_Matter_Plugin_Light0__X3Clambda_X3E_closure) }, - { be_const_key_weak(update_shadow, -1), be_const_closure(class_Matter_Plugin_Light0_update_shadow_closure) }, - { 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(256, -1), be_const_int(2) }, - })) ) } )) }, - { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Light_X200_X20On) }, - { be_const_key_weak(web_values, 3), be_const_closure(class_Matter_Plugin_Light0_web_values_closure) }, - { be_const_key_weak(parse_configuration, 0), be_const_closure(class_Matter_Plugin_Light0_parse_configuration_closure) }, })), be_str_weak(Matter_Plugin_Light0) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor.h index 30098c8c2..8bb80699b 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor.h @@ -3,255 +3,50 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor' ktab size: 49, total: 70 (saved 168 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor[49] = { - /* K0 */ be_nested_str_weak(find), - /* K1 */ be_nested_str_weak(JSON_NAME), - /* K2 */ be_nested_str_weak(bool), - /* K3 */ be_nested_str_weak(shadow_value), - /* K4 */ be_nested_str_weak(value_changed), - /* K5 */ be_nested_str_weak(update_virtual), - /* K6 */ be_nested_str_weak(contains), - /* K7 */ be_nested_str_weak(TempUnit), - /* K8 */ be_nested_str_weak(temp_unit), - /* K9 */ be_nested_str_weak(PressureUnit), - /* K10 */ be_nested_str_weak(pressure_unit), - /* K11 */ be_nested_str_weak(tasmota_sensor_matcher), - /* K12 */ be_nested_str_weak(pre_value), - /* K13 */ be_nested_str_weak(match), - /* K14 */ be_nested_str_weak(tasmota_sensor_filter), - /* K15 */ be_nested_str_weak(string), - /* K16 */ be_nested_str_weak(webserver), - /* K17 */ be_nested_str_weak(html_escape), - /* K18 */ be_nested_str_weak(split), - /* K19 */ be_nested_str_weak(_X23), - /* K20 */ be_const_int(0), - /* K21 */ be_nested_str_weak(), - /* K22 */ be_nested_str_weak(init), - /* K23 */ be_nested_str_weak(add_read_sensors_schedule), - /* K24 */ be_nested_str_weak(UPDATE_TIME), - /* K25 */ be_nested_str_weak(get_name), - /* K26 */ be_nested_str_weak(filter_name_html), - /* K27 */ be_nested_str_weak(content_send), - /* K28 */ be_nested_str_weak(PREFIX), - /* K29 */ be_nested_str_weak(parse_configuration), - /* K30 */ be_nested_str_weak(ARG), - /* K31 */ be_nested_str_weak(tasmota), - /* K32 */ be_nested_str_weak(Rule_Matcher), - /* K33 */ be_nested_str_weak(parse), - /* K34 */ be_nested_str_weak(TEMP_C), - /* K35 */ be_nested_str_weak(PRESSURE_HPA), - /* K36 */ be_nested_str_weak(VIRTUAL), - /* K37 */ be_nested_str_weak(math), - /* K38 */ be_nested_str_weak(log), - /* K39 */ be_nested_str_weak(MTR_X3A_X20zigbee_received_X20Ox_X2504X_X20attr_list_X3D_X25s_X20type_X28attr_list_X29_X3D_X25s), - /* K40 */ be_nested_str_weak(zigbee_mapper), - /* K41 */ be_nested_str_weak(shortaddr), - /* K42 */ be_const_int(3), - /* K43 */ be_nested_str_weak(key), - /* K44 */ be_nested_str_weak(ZIGBEE_NAME), - /* K45 */ be_nested_str_weak(val), - /* K46 */ be_nested_str_weak(MTR_X3A_X20_X5B_X2502X_X5D_X20_X25s_X20updated_X20_X25s), - /* K47 */ be_nested_str_weak(endpoint), - /* K48 */ be_const_int(1), +// compact class 'Matter_Plugin_Sensor' ktab size: 37, total: 54 (saved 136 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor[37] = { + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(add_read_sensors_schedule), + /* K2 */ be_nested_str_weak(UPDATE_TIME), + /* K3 */ be_nested_str_weak(find), + /* K4 */ be_nested_str_weak(JSON_NAME), + /* K5 */ be_nested_str_weak(bool), + /* K6 */ be_nested_str_weak(shadow_value), + /* K7 */ be_nested_str_weak(value_changed), + /* K8 */ be_nested_str_weak(update_virtual), + /* K9 */ be_nested_str_weak(parse_configuration), + /* K10 */ be_nested_str_weak(tasmota_sensor_filter), + /* K11 */ be_nested_str_weak(ARG), + /* K12 */ be_nested_str_weak(tasmota_sensor_matcher), + /* K13 */ be_nested_str_weak(tasmota), + /* K14 */ be_nested_str_weak(Rule_Matcher), + /* K15 */ be_nested_str_weak(parse), + /* K16 */ be_nested_str_weak(temp_unit), + /* K17 */ be_nested_str_weak(TEMP_C), + /* K18 */ be_nested_str_weak(pressure_unit), + /* K19 */ be_nested_str_weak(PRESSURE_HPA), + /* K20 */ be_nested_str_weak(webserver), + /* K21 */ be_nested_str_weak(get_name), + /* K22 */ be_nested_str_weak(filter_name_html), + /* K23 */ be_nested_str_weak(content_send), + /* K24 */ be_nested_str_weak(PREFIX), + /* K25 */ be_nested_str_weak(html_escape), + /* K26 */ be_nested_str_weak(), + /* K27 */ be_nested_str_weak(VIRTUAL), + /* K28 */ be_nested_str_weak(match), + /* K29 */ be_nested_str_weak(pre_value), + /* K30 */ be_nested_str_weak(string), + /* K31 */ be_nested_str_weak(split), + /* K32 */ be_nested_str_weak(_X23), + /* K33 */ be_const_int(0), + /* K34 */ be_nested_str_weak(contains), + /* K35 */ be_nested_str_weak(TempUnit), + /* K36 */ be_nested_str_weak(PressureUnit), }; extern const bclass be_class_Matter_Plugin_Sensor; -/******************************************************************** -** Solidified function: update_virtual -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_update_virtual, /* name */ - be_nested_proto( - 6, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(update_virtual), - &be_const_str_solidified, - ( &(const binstruction[28]) { /* code */ - 0x8C080300, // 0000 GETMET R2 R1 K0 - 0x88100101, // 0001 GETMBR R4 R0 K1 - 0x7C080400, // 0002 CALL R2 2 - 0x4C0C0000, // 0003 LDNIL R3 - 0x200C0403, // 0004 NE R3 R2 R3 - 0x780E000E, // 0005 JMPF R3 #0015 - 0x600C0004, // 0006 GETGBL R3 G4 - 0x5C100400, // 0007 MOVE R4 R2 - 0x7C0C0200, // 0008 CALL R3 1 - 0x1C0C0702, // 0009 EQ R3 R3 K2 - 0x780E0003, // 000A JMPF R3 #000F - 0x600C0009, // 000B GETGBL R3 G9 - 0x5C100400, // 000C MOVE R4 R2 - 0x7C0C0200, // 000D CALL R3 1 - 0x5C080600, // 000E MOVE R2 R3 - 0x880C0103, // 000F GETMBR R3 R0 K3 - 0x200C0602, // 0010 NE R3 R3 R2 - 0x780E0002, // 0011 JMPF R3 #0015 - 0x8C0C0104, // 0012 GETMET R3 R0 K4 - 0x7C0C0200, // 0013 CALL R3 1 - 0x90020602, // 0014 SETMBR R0 K3 R2 - 0x600C0003, // 0015 GETGBL R3 G3 - 0x5C100000, // 0016 MOVE R4 R0 - 0x7C0C0200, // 0017 CALL R3 1 - 0x8C0C0705, // 0018 GETMET R3 R3 K5 - 0x5C140200, // 0019 MOVE R5 R1 - 0x7C0C0400, // 001A CALL R3 2 - 0x80000000, // 001B RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: parse_status -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_parse_status, /* name */ - be_nested_proto( - 9, /* nstack */ - 3, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(parse_status), - &be_const_str_solidified, - ( &(const binstruction[35]) { /* code */ - 0x540E0009, // 0000 LDINT R3 10 - 0x1C0C0403, // 0001 EQ R3 R2 R3 - 0x780E001E, // 0002 JMPF R3 #0022 - 0x8C0C0306, // 0003 GETMET R3 R1 K6 - 0x58140007, // 0004 LDCONST R5 K7 - 0x7C0C0400, // 0005 CALL R3 2 - 0x780E0001, // 0006 JMPF R3 #0009 - 0x940C0307, // 0007 GETIDX R3 R1 K7 - 0x90021003, // 0008 SETMBR R0 K8 R3 - 0x8C0C0306, // 0009 GETMET R3 R1 K6 - 0x58140009, // 000A LDCONST R5 K9 - 0x7C0C0400, // 000B CALL R3 2 - 0x780E0001, // 000C JMPF R3 #000F - 0x940C0309, // 000D GETIDX R3 R1 K9 - 0x90021403, // 000E SETMBR R0 K10 R3 - 0x880C010B, // 000F GETMBR R3 R0 K11 - 0x780E0010, // 0010 JMPF R3 #0022 - 0x8C0C010C, // 0011 GETMET R3 R0 K12 - 0x6014000A, // 0012 GETGBL R5 G10 - 0x8818010B, // 0013 GETMBR R6 R0 K11 - 0x8C180D0D, // 0014 GETMET R6 R6 K13 - 0x5C200200, // 0015 MOVE R8 R1 - 0x7C180400, // 0016 CALL R6 2 - 0x7C140200, // 0017 CALL R5 1 - 0x7C0C0400, // 0018 CALL R3 2 - 0x4C100000, // 0019 LDNIL R4 - 0x20100604, // 001A NE R4 R3 R4 - 0x78120005, // 001B JMPF R4 #0022 - 0x88100103, // 001C GETMBR R4 R0 K3 - 0x20100604, // 001D NE R4 R3 R4 - 0x78120002, // 001E JMPF R4 #0022 - 0x8C100104, // 001F GETMET R4 R0 K4 - 0x7C100200, // 0020 CALL R4 1 - 0x90020603, // 0021 SETMBR R0 K3 R3 - 0x80000000, // 0022 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: pre_value -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_pre_value, /* name */ - be_nested_proto( - 2, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(pre_value), - &be_const_str_solidified, - ( &(const binstruction[ 1]) { /* code */ - 0x80040200, // 0000 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: filter_name_html -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_filter_name_html, /* name */ - be_nested_proto( - 9, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(filter_name_html), - &be_const_str_solidified, - ( &(const binstruction[13]) { /* code */ - 0x8804010E, // 0000 GETMBR R1 R0 K14 - 0x78060009, // 0001 JMPF R1 #000C - 0xA4061E00, // 0002 IMPORT R1 K15 - 0xA40A2000, // 0003 IMPORT R2 K16 - 0x8C0C0511, // 0004 GETMET R3 R2 K17 - 0x8C140312, // 0005 GETMET R5 R1 K18 - 0x881C010E, // 0006 GETMBR R7 R0 K14 - 0x58200013, // 0007 LDCONST R8 K19 - 0x7C140600, // 0008 CALL R5 3 - 0x94140B14, // 0009 GETIDX R5 R5 K20 - 0x7C0C0400, // 000A CALL R3 2 - 0x80040600, // 000B RET 1 R3 - 0x80062A00, // 000C RET 1 K21 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: value_changed -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_value_changed, /* name */ - be_nested_proto( - 1, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(value_changed), - &be_const_str_solidified, - ( &(const binstruction[ 1]) { /* code */ - 0x80000000, // 0000 RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: init ********************************************************************/ @@ -272,13 +67,13 @@ be_local_closure(class_Matter_Plugin_Sensor_init, /* name */ 0x60100003, // 0000 GETGBL R4 G3 0x5C140000, // 0001 MOVE R5 R0 0x7C100200, // 0002 CALL R4 1 - 0x8C100916, // 0003 GETMET R4 R4 K22 + 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 - 0x8C100317, // 0008 GETMET R4 R1 K23 - 0x88180118, // 0009 GETMBR R6 R0 K24 + 0x8C100301, // 0008 GETMET R4 R1 K1 + 0x88180102, // 0009 GETMBR R6 R0 K2 0x7C100400, // 000A CALL R4 2 0x80000000, // 000B RET 0 }) @@ -288,12 +83,12 @@ be_local_closure(class_Matter_Plugin_Sensor_init, /* name */ /******************************************************************** -** Solidified function: web_values_prefix +** Solidified function: update_virtual ********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_web_values_prefix, /* name */ +be_local_closure(class_Matter_Plugin_Sensor_update_virtual, /* name */ be_nested_proto( - 10, /* nstack */ - 1, /* argc */ + 6, /* nstack */ + 2, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -301,29 +96,37 @@ be_local_closure(class_Matter_Plugin_Sensor_web_values_prefix, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(web_values_prefix), + be_str_weak(update_virtual), &be_const_str_solidified, - ( &(const binstruction[20]) { /* code */ - 0xA4062000, // 0000 IMPORT R1 K16 - 0x8C080119, // 0001 GETMET R2 R0 K25 - 0x7C080200, // 0002 CALL R2 1 - 0x5C0C0400, // 0003 MOVE R3 R2 - 0x740E0002, // 0004 JMPT R3 #0008 - 0x8C0C011A, // 0005 GETMET R3 R0 K26 - 0x7C0C0200, // 0006 CALL R3 1 - 0x5C080600, // 0007 MOVE R2 R3 - 0x8C0C031B, // 0008 GETMET R3 R1 K27 - 0x60140018, // 0009 GETGBL R5 G24 - 0x8818011C, // 000A GETMBR R6 R0 K28 - 0x780A0003, // 000B JMPF R2 #0010 - 0x8C1C0311, // 000C GETMET R7 R1 K17 - 0x5C240400, // 000D MOVE R9 R2 - 0x7C1C0400, // 000E CALL R7 2 - 0x70020000, // 000F JMP #0011 - 0x581C0015, // 0010 LDCONST R7 K21 - 0x7C140400, // 0011 CALL R5 2 - 0x7C0C0400, // 0012 CALL R3 2 - 0x80000000, // 0013 RET 0 + ( &(const binstruction[28]) { /* code */ + 0x8C080303, // 0000 GETMET R2 R1 K3 + 0x88100104, // 0001 GETMBR R4 R0 K4 + 0x7C080400, // 0002 CALL R2 2 + 0x4C0C0000, // 0003 LDNIL R3 + 0x200C0403, // 0004 NE R3 R2 R3 + 0x780E000E, // 0005 JMPF R3 #0015 + 0x600C0004, // 0006 GETGBL R3 G4 + 0x5C100400, // 0007 MOVE R4 R2 + 0x7C0C0200, // 0008 CALL R3 1 + 0x1C0C0705, // 0009 EQ R3 R3 K5 + 0x780E0003, // 000A JMPF R3 #000F + 0x600C0009, // 000B GETGBL R3 G9 + 0x5C100400, // 000C MOVE R4 R2 + 0x7C0C0200, // 000D CALL R3 1 + 0x5C080600, // 000E MOVE R2 R3 + 0x880C0106, // 000F GETMBR R3 R0 K6 + 0x200C0602, // 0010 NE R3 R3 R2 + 0x780E0002, // 0011 JMPF R3 #0015 + 0x8C0C0107, // 0012 GETMET R3 R0 K7 + 0x7C0C0200, // 0013 CALL R3 1 + 0x90020C02, // 0014 SETMBR R0 K6 R2 + 0x600C0003, // 0015 GETGBL R3 G3 + 0x5C100000, // 0016 MOVE R4 R0 + 0x7C0C0200, // 0017 CALL R3 1 + 0x8C0C0708, // 0018 GETMET R3 R3 K8 + 0x5C140200, // 0019 MOVE R5 R1 + 0x7C0C0400, // 001A CALL R3 2 + 0x80000000, // 001B RET 0 }) ) ); @@ -350,25 +153,25 @@ be_local_closure(class_Matter_Plugin_Sensor_parse_configuration, /* name */ 0x60080003, // 0000 GETGBL R2 G3 0x5C0C0000, // 0001 MOVE R3 R0 0x7C080200, // 0002 CALL R2 1 - 0x8C08051D, // 0003 GETMET R2 R2 K29 + 0x8C080509, // 0003 GETMET R2 R2 K9 0x5C100200, // 0004 MOVE R4 R1 0x7C080400, // 0005 CALL R2 2 - 0x8C080300, // 0006 GETMET R2 R1 K0 - 0x8810011E, // 0007 GETMBR R4 R0 K30 + 0x8C080303, // 0006 GETMET R2 R1 K3 + 0x8810010B, // 0007 GETMBR R4 R0 K11 0x7C080400, // 0008 CALL R2 2 - 0x90021C02, // 0009 SETMBR R0 K14 R2 - 0x8808010E, // 000A GETMBR R2 R0 K14 + 0x90021402, // 0009 SETMBR R0 K10 R2 + 0x8808010A, // 000A GETMBR R2 R0 K10 0x780A0005, // 000B JMPF R2 #0012 - 0xB80A3E00, // 000C GETNGBL R2 K31 - 0x88080520, // 000D GETMBR R2 R2 K32 - 0x8C080521, // 000E GETMET R2 R2 K33 - 0x8810010E, // 000F GETMBR R4 R0 K14 + 0xB80A1A00, // 000C GETNGBL R2 K13 + 0x8808050E, // 000D GETMBR R2 R2 K14 + 0x8C08050F, // 000E GETMET R2 R2 K15 + 0x8810010A, // 000F GETMBR R4 R0 K10 0x7C080400, // 0010 CALL R2 2 - 0x90021602, // 0011 SETMBR R0 K11 R2 - 0x88080122, // 0012 GETMBR R2 R0 K34 - 0x90021002, // 0013 SETMBR R0 K8 R2 - 0x88080123, // 0014 GETMBR R2 R0 K35 - 0x90021402, // 0015 SETMBR R0 K10 R2 + 0x90021802, // 0011 SETMBR R0 K12 R2 + 0x88080111, // 0012 GETMBR R2 R0 K17 + 0x90022002, // 0013 SETMBR R0 K16 R2 + 0x88080113, // 0014 GETMBR R2 R0 K19 + 0x90022402, // 0015 SETMBR R0 K18 R2 0x80000000, // 0016 RET 0 }) ) @@ -376,6 +179,49 @@ be_local_closure(class_Matter_Plugin_Sensor_parse_configuration, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: web_values_prefix +********************************************************************/ +be_local_closure(class_Matter_Plugin_Sensor_web_values_prefix, /* name */ + be_nested_proto( + 10, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ + be_str_weak(web_values_prefix), + &be_const_str_solidified, + ( &(const binstruction[20]) { /* code */ + 0xA4062800, // 0000 IMPORT R1 K20 + 0x8C080115, // 0001 GETMET R2 R0 K21 + 0x7C080200, // 0002 CALL R2 1 + 0x5C0C0400, // 0003 MOVE R3 R2 + 0x740E0002, // 0004 JMPT R3 #0008 + 0x8C0C0116, // 0005 GETMET R3 R0 K22 + 0x7C0C0200, // 0006 CALL R3 1 + 0x5C080600, // 0007 MOVE R2 R3 + 0x8C0C0317, // 0008 GETMET R3 R1 K23 + 0x60140018, // 0009 GETGBL R5 G24 + 0x88180118, // 000A GETMBR R6 R0 K24 + 0x780A0003, // 000B JMPF R2 #0010 + 0x8C1C0319, // 000C GETMET R7 R1 K25 + 0x5C240400, // 000D MOVE R9 R2 + 0x7C1C0400, // 000E CALL R7 2 + 0x70020000, // 000F JMP #0011 + 0x581C001A, // 0010 LDCONST R7 K26 + 0x7C140400, // 0011 CALL R5 2 + 0x7C0C0400, // 0012 CALL R3 2 + 0x80000000, // 0013 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: parse_sensors ********************************************************************/ @@ -393,12 +239,12 @@ be_local_closure(class_Matter_Plugin_Sensor_parse_sensors, /* name */ be_str_weak(parse_sensors), &be_const_str_solidified, ( &(const binstruction[33]) { /* code */ - 0x88080124, // 0000 GETMBR R2 R0 K36 + 0x8808011B, // 0000 GETMBR R2 R0 K27 0x740A001D, // 0001 JMPT R2 #0020 - 0x8808010B, // 0002 GETMBR R2 R0 K11 + 0x8808010C, // 0002 GETMBR R2 R0 K12 0x780A001B, // 0003 JMPF R2 #0020 - 0x8808010B, // 0004 GETMBR R2 R0 K11 - 0x8C08050D, // 0005 GETMET R2 R2 K13 + 0x8808010C, // 0004 GETMBR R2 R0 K12 + 0x8C08051C, // 0005 GETMET R2 R2 K28 0x5C100200, // 0006 MOVE R4 R1 0x7C080400, // 0007 CALL R2 2 0x600C000F, // 0008 GETGBL R3 G15 @@ -406,11 +252,11 @@ be_local_closure(class_Matter_Plugin_Sensor_parse_sensors, /* name */ 0x60140013, // 000A GETGBL R5 G19 0x7C0C0400, // 000B CALL R3 2 0x780E0003, // 000C JMPF R3 #0011 - 0x8C0C0500, // 000D GETMET R3 R2 K0 - 0x88140101, // 000E GETMBR R5 R0 K1 + 0x8C0C0503, // 000D GETMET R3 R2 K3 + 0x88140104, // 000E GETMBR R5 R0 K4 0x7C0C0400, // 000F CALL R3 2 0x5C080600, // 0010 MOVE R2 R3 - 0x8C0C010C, // 0011 GETMET R3 R0 K12 + 0x8C0C011D, // 0011 GETMET R3 R0 K29 0x6014000A, // 0012 GETGBL R5 G10 0x5C180400, // 0013 MOVE R6 R2 0x7C140200, // 0014 CALL R5 1 @@ -419,12 +265,12 @@ be_local_closure(class_Matter_Plugin_Sensor_parse_sensors, /* name */ 0x4C0C0000, // 0017 LDNIL R3 0x200C0403, // 0018 NE R3 R2 R3 0x780E0005, // 0019 JMPF R3 #0020 - 0x880C0103, // 001A GETMBR R3 R0 K3 + 0x880C0106, // 001A GETMBR R3 R0 K6 0x200C0403, // 001B NE R3 R2 R3 0x780E0002, // 001C JMPF R3 #0020 - 0x8C0C0104, // 001D GETMET R3 R0 K4 + 0x8C0C0107, // 001D GETMET R3 R0 K7 0x7C0C0200, // 001E CALL R3 1 - 0x90020602, // 001F SETMBR R0 K3 R2 + 0x90020C02, // 001F SETMBR R0 K6 R2 0x80000000, // 0020 RET 0 }) ) @@ -433,11 +279,47 @@ be_local_closure(class_Matter_Plugin_Sensor_parse_sensors, /* name */ /******************************************************************** -** Solidified function: zigbee_received +** Solidified function: filter_name_html ********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_zigbee_received, /* name */ +be_local_closure(class_Matter_Plugin_Sensor_filter_name_html, /* name */ be_nested_proto( - 14, /* nstack */ + 9, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ + be_str_weak(filter_name_html), + &be_const_str_solidified, + ( &(const binstruction[13]) { /* code */ + 0x8804010A, // 0000 GETMBR R1 R0 K10 + 0x78060009, // 0001 JMPF R1 #000C + 0xA4063C00, // 0002 IMPORT R1 K30 + 0xA40A2800, // 0003 IMPORT R2 K20 + 0x8C0C0519, // 0004 GETMET R3 R2 K25 + 0x8C14031F, // 0005 GETMET R5 R1 K31 + 0x881C010A, // 0006 GETMBR R7 R0 K10 + 0x58200020, // 0007 LDCONST R8 K32 + 0x7C140600, // 0008 CALL R5 3 + 0x94140B21, // 0009 GETIDX R5 R5 K33 + 0x7C0C0400, // 000A CALL R3 2 + 0x80040600, // 000B RET 1 R3 + 0x80063400, // 000C RET 1 K26 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: parse_status +********************************************************************/ +be_local_closure(class_Matter_Plugin_Sensor_parse_status, /* name */ + be_nested_proto( + 9, /* nstack */ 3, /* argc */ 10, /* varg */ 0, /* has upvals */ @@ -446,57 +328,44 @@ be_local_closure(class_Matter_Plugin_Sensor_zigbee_received, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Sensor, /* shared constants */ - be_str_weak(zigbee_received), + be_str_weak(parse_status), &be_const_str_solidified, - ( &(const binstruction[48]) { /* code */ - 0xA40E4A00, // 0000 IMPORT R3 K37 - 0xB8124C00, // 0001 GETNGBL R4 K38 - 0x60140018, // 0002 GETGBL R5 G24 - 0x58180027, // 0003 LDCONST R6 K39 - 0x881C0128, // 0004 GETMBR R7 R0 K40 - 0x881C0F29, // 0005 GETMBR R7 R7 K41 - 0x5C200400, // 0006 MOVE R8 R2 - 0x60240004, // 0007 GETGBL R9 G4 - 0x5C280400, // 0008 MOVE R10 R2 - 0x7C240200, // 0009 CALL R9 1 - 0x7C140800, // 000A CALL R5 4 - 0x5818002A, // 000B LDCONST R6 K42 - 0x7C100400, // 000C CALL R4 2 - 0x58100014, // 000D LDCONST R4 K20 - 0x6014000C, // 000E GETGBL R5 G12 - 0x5C180400, // 000F MOVE R6 R2 - 0x7C140200, // 0010 CALL R5 1 - 0x14140805, // 0011 LT R5 R4 R5 - 0x7816001B, // 0012 JMPF R5 #002F - 0x94140404, // 0013 GETIDX R5 R2 R4 - 0x88180B2B, // 0014 GETMBR R6 R5 K43 - 0x881C012C, // 0015 GETMBR R7 R0 K44 - 0x1C180C07, // 0016 EQ R6 R6 R7 - 0x781A0014, // 0017 JMPF R6 #002D - 0x8C18010C, // 0018 GETMET R6 R0 K12 - 0x88200B2D, // 0019 GETMBR R8 R5 K45 - 0x7C180400, // 001A CALL R6 2 - 0x601C0013, // 001B GETGBL R7 G19 - 0x7C1C0000, // 001C CALL R7 0 - 0x88200101, // 001D GETMBR R8 R0 K1 - 0x981C1006, // 001E SETIDX R7 R8 R6 - 0x8C200105, // 001F GETMET R8 R0 K5 - 0x5C280E00, // 0020 MOVE R10 R7 - 0x7C200400, // 0021 CALL R8 2 - 0xB8224C00, // 0022 GETNGBL R8 K38 - 0x60240018, // 0023 GETGBL R9 G24 - 0x5828002E, // 0024 LDCONST R10 K46 - 0x882C012F, // 0025 GETMBR R11 R0 K47 - 0x88300101, // 0026 GETMBR R12 R0 K1 - 0x5C340E00, // 0027 MOVE R13 R7 - 0x7C240800, // 0028 CALL R9 4 - 0x5828002A, // 0029 LDCONST R10 K42 - 0x7C200400, // 002A CALL R8 2 - 0x4C200000, // 002B LDNIL R8 - 0x80041000, // 002C RET 1 R8 - 0x00100930, // 002D ADD R4 R4 K48 - 0x7001FFDE, // 002E JMP #000E - 0x80000000, // 002F RET 0 + ( &(const binstruction[35]) { /* code */ + 0x540E0009, // 0000 LDINT R3 10 + 0x1C0C0403, // 0001 EQ R3 R2 R3 + 0x780E001E, // 0002 JMPF R3 #0022 + 0x8C0C0322, // 0003 GETMET R3 R1 K34 + 0x58140023, // 0004 LDCONST R5 K35 + 0x7C0C0400, // 0005 CALL R3 2 + 0x780E0001, // 0006 JMPF R3 #0009 + 0x940C0323, // 0007 GETIDX R3 R1 K35 + 0x90022003, // 0008 SETMBR R0 K16 R3 + 0x8C0C0322, // 0009 GETMET R3 R1 K34 + 0x58140024, // 000A LDCONST R5 K36 + 0x7C0C0400, // 000B CALL R3 2 + 0x780E0001, // 000C JMPF R3 #000F + 0x940C0324, // 000D GETIDX R3 R1 K36 + 0x90022403, // 000E SETMBR R0 K18 R3 + 0x880C010C, // 000F GETMBR R3 R0 K12 + 0x780E0010, // 0010 JMPF R3 #0022 + 0x8C0C011D, // 0011 GETMET R3 R0 K29 + 0x6014000A, // 0012 GETGBL R5 G10 + 0x8818010C, // 0013 GETMBR R6 R0 K12 + 0x8C180D1C, // 0014 GETMET R6 R6 K28 + 0x5C200200, // 0015 MOVE R8 R1 + 0x7C180400, // 0016 CALL R6 2 + 0x7C140200, // 0017 CALL R5 1 + 0x7C0C0400, // 0018 CALL R3 2 + 0x4C100000, // 0019 LDNIL R4 + 0x20100604, // 001A NE R4 R3 R4 + 0x78120005, // 001B JMPF R4 #0022 + 0x88100106, // 001C GETMBR R4 R0 K6 + 0x20100604, // 001D NE R4 R3 R4 + 0x78120002, // 001E JMPF R4 #0022 + 0x8C100107, // 001F GETMET R4 R0 K7 + 0x7C100200, // 0020 CALL R4 1 + 0x90020C03, // 0021 SETMBR R0 K6 R3 + 0x80000000, // 0022 RET 0 }) ) ); @@ -510,33 +379,30 @@ extern const bclass be_class_Matter_Plugin_Device; be_local_class(Matter_Plugin_Sensor, 5, &be_class_Matter_Plugin_Device, - be_nested_map(25, + be_nested_map(22, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(JSON_NAME, -1), be_nested_str_weak() }, - { be_const_key_weak(pre_value, -1), be_const_closure(class_Matter_Plugin_Sensor_pre_value_closure) }, - { be_const_key_weak(zigbee_received, -1), be_const_closure(class_Matter_Plugin_Sensor_zigbee_received_closure) }, - { be_const_key_weak(parse_status, 2), be_const_closure(class_Matter_Plugin_Sensor_parse_status_closure) }, - { be_const_key_weak(TEMP_C, -1), be_nested_str_weak(C) }, - { be_const_key_weak(temp_unit, 23), be_const_var(3) }, - { be_const_key_weak(UPDATE_TIME, 10), be_const_int(5000) }, - { be_const_key_weak(TEMP_F, -1), be_nested_str_weak(F) }, + { be_const_key_weak(tasmota_sensor_filter, -1), be_const_var(0) }, + { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Filter_X20pattern) }, + { be_const_key_weak(parse_status, 4), be_const_closure(class_Matter_Plugin_Sensor_parse_status_closure) }, + { be_const_key_weak(update_virtual, -1), be_const_closure(class_Matter_Plugin_Sensor_update_virtual_closure) }, + { be_const_key_weak(parse_configuration, -1), be_const_closure(class_Matter_Plugin_Sensor_parse_configuration_closure) }, { be_const_key_weak(pressure_unit, -1), be_const_var(4) }, - { be_const_key_weak(UPDATE_CMD, -1), be_nested_str_weak(Status_X2010) }, - { be_const_key_weak(tasmota_sensor_filter, 1), be_const_var(0) }, - { be_const_key_weak(value_changed, 7), be_const_closure(class_Matter_Plugin_Sensor_value_changed_closure) }, - { be_const_key_weak(PRESSURE_INHG, -1), be_nested_str_weak(inHg) }, - { be_const_key_weak(parse_configuration, 22), be_const_closure(class_Matter_Plugin_Sensor_parse_configuration_closure) }, { be_const_key_weak(tasmota_sensor_matcher, -1), be_const_var(1) }, - { be_const_key_weak(update_virtual, 14), be_const_closure(class_Matter_Plugin_Sensor_update_virtual_closure) }, - { be_const_key_weak(PRESSURE_MMHG, -1), be_nested_str_weak(mmHg) }, - { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Sensor_web_values_prefix_closure) }, - { be_const_key_weak(shadow_value, -1), be_const_var(2) }, - { be_const_key_weak(filter_name_html, 13), be_const_closure(class_Matter_Plugin_Sensor_filter_name_html_closure) }, - { be_const_key_weak(ARG_HINT, 12), be_nested_str_weak(Filter_X20pattern) }, - { be_const_key_weak(parse_sensors, -1), be_const_closure(class_Matter_Plugin_Sensor_parse_sensors_closure) }, { be_const_key_weak(ARG, -1), be_nested_str_weak(filter) }, + { be_const_key_weak(PRESSURE_MMHG, -1), be_nested_str_weak(mmHg) }, { be_const_key_weak(init, -1), be_const_closure(class_Matter_Plugin_Sensor_init_closure) }, - { be_const_key_weak(PRESSURE_HPA, -1), be_nested_str_weak(hPa) }, + { be_const_key_weak(TEMP_F, -1), be_nested_str_weak(F) }, + { be_const_key_weak(TEMP_C, -1), be_nested_str_weak(C) }, + { be_const_key_weak(temp_unit, 3), be_const_var(3) }, + { be_const_key_weak(UPDATE_CMD, 16), be_nested_str_weak(Status_X2010) }, + { be_const_key_weak(PRESSURE_HPA, 10), be_nested_str_weak(hPa) }, + { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Sensor_web_values_prefix_closure) }, + { be_const_key_weak(PRESSURE_INHG, -1), be_nested_str_weak(inHg) }, + { be_const_key_weak(JSON_NAME, 13), be_nested_str_weak() }, + { be_const_key_weak(parse_sensors, -1), be_const_closure(class_Matter_Plugin_Sensor_parse_sensors_closure) }, + { be_const_key_weak(filter_name_html, -1), be_const_closure(class_Matter_Plugin_Sensor_filter_name_html_closure) }, + { be_const_key_weak(UPDATE_TIME, -1), be_const_int(5000) }, + { be_const_key_weak(shadow_value, 2), be_const_var(2) }, })), be_str_weak(Matter_Plugin_Sensor) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Air_Quality.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Air_Quality.h index 97bf2aad1..8991580dd 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Air_Quality.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Air_Quality.h @@ -3,8 +3,8 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_Air_Quality' ktab size: 36, total: 73 (saved 296 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_Air_Quality[36] = { +// compact class 'Matter_Plugin_Sensor_Air_Quality' ktab size: 37, total: 74 (saved 296 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_Air_Quality[37] = { /* K0 */ be_nested_str_weak(web_values_prefix), /* K1 */ be_nested_str_weak(Air), /* K2 */ be_nested_str_weak(shadow_air_quality), @@ -36,11 +36,12 @@ static const bvalue be_ktab_class_Matter_Plugin_Sensor_Air_Quality[36] = { /* K28 */ be_nested_str_weak(set_or_nil), /* K29 */ be_nested_str_weak(U1), /* K30 */ be_nested_str_weak(read_attribute), - /* K31 */ be_nested_str_weak(ARG), - /* K32 */ be_nested_str_weak(_parse_sensor_entry), - /* K33 */ be_nested_str_weak(CarbonDioxide), - /* K34 */ be_nested_str_weak(parse_sensors), - /* K35 */ be_nested_str_weak(attribute_updated), + /* K31 */ be_nested_str_weak(parse_configuration), + /* K32 */ be_nested_str_weak(ARG), + /* K33 */ be_nested_str_weak(_parse_sensor_entry), + /* K34 */ be_nested_str_weak(CarbonDioxide), + /* K35 */ be_nested_str_weak(parse_sensors), + /* K36 */ be_nested_str_weak(attribute_updated), }; @@ -520,14 +521,20 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_configuration, / &be_ktab_class_Matter_Plugin_Sensor_Air_Quality, /* shared constants */ be_str_weak(parse_configuration), &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x60080008, // 0000 GETGBL R2 G8 - 0x8C0C030F, // 0001 GETMET R3 R1 K15 - 0x8814011F, // 0002 GETMBR R5 R0 K31 - 0x7C0C0400, // 0003 CALL R3 2 - 0x7C080200, // 0004 CALL R2 1 - 0x90022002, // 0005 SETMBR R0 K16 R2 - 0x80000000, // 0006 RET 0 + ( &(const binstruction[13]) { /* code */ + 0x60080003, // 0000 GETGBL R2 G3 + 0x5C0C0000, // 0001 MOVE R3 R0 + 0x7C080200, // 0002 CALL R2 1 + 0x8C08051F, // 0003 GETMET R2 R2 K31 + 0x5C100200, // 0004 MOVE R4 R1 + 0x7C080400, // 0005 CALL R2 2 + 0x60080008, // 0006 GETGBL R2 G8 + 0x8C0C030F, // 0007 GETMET R3 R1 K15 + 0x88140120, // 0008 GETMBR R5 R0 K32 + 0x7C0C0400, // 0009 CALL R3 2 + 0x7C080200, // 000A CALL R2 1 + 0x90022002, // 000B SETMBR R0 K16 R2 + 0x80000000, // 000C RET 0 }) ) ); @@ -557,16 +564,16 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_sensors, /* name 0x4C0C0000, // 0003 LDNIL R3 0x200C0403, // 0004 NE R3 R2 R3 0x780E0035, // 0005 JMPF R3 #003C - 0x8C0C0120, // 0006 GETMET R3 R0 K32 + 0x8C0C0121, // 0006 GETMET R3 R0 K33 0x5C140400, // 0007 MOVE R5 R2 - 0x58180021, // 0008 LDCONST R6 K33 + 0x58180022, // 0008 LDCONST R6 K34 0x881C010A, // 0009 GETMBR R7 R0 K10 0x60200007, // 000A GETGBL R8 G7 0x5426040C, // 000B LDINT R9 1037 0x58280013, // 000C LDCONST R10 K19 0x7C0C0E00, // 000D CALL R3 7 0x90021403, // 000E SETMBR R0 K10 R3 - 0x8C0C0120, // 000F GETMET R3 R0 K32 + 0x8C0C0121, // 000F GETMET R3 R0 K33 0x5C140400, // 0010 MOVE R5 R2 0x58180003, // 0011 LDCONST R6 K3 0x881C0104, // 0012 GETMBR R7 R0 K4 @@ -575,7 +582,7 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_sensors, /* name 0x58280013, // 0015 LDCONST R10 K19 0x7C0C0E00, // 0016 CALL R3 7 0x90020803, // 0017 SETMBR R0 K4 R3 - 0x8C0C0120, // 0018 GETMET R3 R0 K32 + 0x8C0C0121, // 0018 GETMET R3 R0 K33 0x5C140400, // 0019 MOVE R5 R2 0x58180005, // 001A LDCONST R6 K5 0x881C0106, // 001B GETMBR R7 R0 K6 @@ -584,7 +591,7 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_sensors, /* name 0x58280013, // 001E LDCONST R10 K19 0x7C0C0E00, // 001F CALL R3 7 0x90020C03, // 0020 SETMBR R0 K6 R3 - 0x8C0C0120, // 0021 GETMET R3 R0 K32 + 0x8C0C0121, // 0021 GETMET R3 R0 K33 0x5C140400, // 0022 MOVE R5 R2 0x58180007, // 0023 LDCONST R6 K7 0x881C0108, // 0024 GETMBR R7 R0 K8 @@ -593,7 +600,7 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_sensors, /* name 0x58280013, // 0027 LDCONST R10 K19 0x7C0C0E00, // 0028 CALL R3 7 0x90021003, // 0029 SETMBR R0 K8 R3 - 0x8C0C0120, // 002A GETMET R3 R0 K32 + 0x8C0C0121, // 002A GETMET R3 R0 K33 0x5C140400, // 002B MOVE R5 R2 0x5818000D, // 002C LDCONST R6 K13 0x881C010E, // 002D GETMBR R7 R0 K14 @@ -602,7 +609,7 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_sensors, /* name 0x58280013, // 0030 LDCONST R10 K19 0x7C0C0E00, // 0031 CALL R3 7 0x90021C03, // 0032 SETMBR R0 K14 R3 - 0x8C0C0120, // 0033 GETMET R3 R0 K32 + 0x8C0C0121, // 0033 GETMET R3 R0 K33 0x5C140400, // 0034 MOVE R5 R2 0x5818000B, // 0035 LDCONST R6 K11 0x881C010C, // 0036 GETMBR R7 R0 K12 @@ -614,7 +621,7 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality_parse_sensors, /* name 0x600C0003, // 003C GETGBL R3 G3 0x5C100000, // 003D MOVE R4 R0 0x7C0C0200, // 003E CALL R3 1 - 0x8C0C0722, // 003F GETMET R3 R3 K34 + 0x8C0C0723, // 003F GETMET R3 R3 K35 0x5C140200, // 0040 MOVE R5 R1 0x7C0C0400, // 0041 CALL R3 2 0x80000000, // 0042 RET 0 @@ -656,7 +663,7 @@ be_local_closure(class_Matter_Plugin_Sensor_Air_Quality__parse_sensor_entry, / 0x78220005, // 000C JMPF R8 #0013 0x20200E03, // 000D NE R8 R7 R3 0x78220003, // 000E JMPF R8 #0013 - 0x8C200123, // 000F GETMET R8 R0 K35 + 0x8C200124, // 000F GETMET R8 R0 K36 0x5C280A00, // 0010 MOVE R10 R5 0x5C2C0C00, // 0011 MOVE R11 R6 0x7C200600, // 0012 CALL R8 3 diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Boolean.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Boolean.h index 673392504..d0d0585ff 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Boolean.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_Boolean.h @@ -3,37 +3,41 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_Boolean' ktab size: 17, total: 26 (saved 72 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_Boolean[17] = { - /* 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), - /* K5 */ be_nested_str_weak(update_shadow), - /* K6 */ be_nested_str_weak(VIRTUAL), - /* K7 */ be_nested_str_weak(Switch), - /* K8 */ be_nested_str_weak(tasmota), - /* K9 */ be_nested_str_weak(cmd), - /* K10 */ be_nested_str_weak(Status_X2010), - /* K11 */ be_nested_str_weak(StatusSNS), - /* K12 */ be_nested_str_weak(contains), - /* K13 */ be_nested_str_weak(ON), - /* K14 */ be_nested_str_weak(shadow_bool_value), - /* K15 */ be_nested_str_weak(value_updated), - /* K16 */ be_nested_str_weak(init), +// compact class 'Matter_Plugin_Sensor_Boolean' ktab size: 21, total: 32 (saved 88 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_Boolean[21] = { + /* 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_X2010), + /* 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_bool_value), + /* K12 */ be_nested_str_weak(value_updated), + /* K13 */ be_nested_str_weak(init), + /* K14 */ be_nested_str_weak(parse_configuration), + /* K15 */ be_nested_str_weak(ARG), + /* K16 */ be_const_int(1), + /* K17 */ be_const_int(0), + /* K18 */ be_nested_str_weak(_parse_update_virtual), + /* K19 */ be_nested_str_weak(JSON_NAME), + /* K20 */ be_nested_str_weak(update_virtual), }; extern const bclass be_class_Matter_Plugin_Sensor_Boolean; /******************************************************************** -** Solidified function: parse_configuration +** Solidified function: update_shadow ********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Boolean_parse_configuration, /* name */ +be_local_closure(class_Matter_Plugin_Sensor_Boolean_update_shadow, /* name */ be_nested_proto( - 7, /* nstack */ - 2, /* argc */ + 6, /* nstack */ + 1, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -41,21 +45,50 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean_parse_configuration, /* na NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Sensor_Boolean, /* shared constants */ - be_str_weak(parse_configuration), + be_str_weak(update_shadow), &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 + ( &(const binstruction[41]) { /* 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 + 0x74060020, // 0006 JMPT R1 #0028 + 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 + 0x780E000D, // 0019 JMPF R3 #0028 + 0x8C0C0509, // 001A GETMET R3 R2 K9 + 0x5C140200, // 001B MOVE R5 R1 + 0x7C0C0400, // 001C CALL R3 2 + 0x780E0009, // 001D JMPF R3 #0028 + 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 + 0x78120001, // 0024 JMPF R4 #0027 + 0x8C10010C, // 0025 GETMET R4 R0 K12 + 0x7C100200, // 0026 CALL R4 1 + 0x90021603, // 0027 SETMBR R0 K11 R3 + 0x80000000, // 0028 RET 0 }) ) ); @@ -86,6 +119,40 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean_value_updated, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(class_Matter_Plugin_Sensor_Boolean_init, /* name */ + be_nested_proto( + 9, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Sensor_Boolean, /* shared constants */ + 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 + 0x8C10090D, // 0003 GETMET R4 R4 K13 + 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 + 0x90021604, // 0009 SETMBR R0 K11 R4 + 0x80000000, // 000A RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: ********************************************************************/ @@ -114,12 +181,12 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean__X3Clambda_X3E, /* name */ /******************************************************************** -** Solidified function: update_shadow +** Solidified function: parse_configuration ********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Boolean_update_shadow, /* name */ +be_local_closure(class_Matter_Plugin_Sensor_Boolean_parse_configuration, /* name */ be_nested_proto( - 6, /* nstack */ - 1, /* argc */ + 7, /* nstack */ + 2, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -127,50 +194,27 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean_update_shadow, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Sensor_Boolean, /* shared constants */ - be_str_weak(update_shadow), + be_str_weak(parse_configuration), &be_const_str_solidified, - ( &(const binstruction[41]) { /* code */ - 0x60040003, // 0000 GETGBL R1 G3 - 0x5C080000, // 0001 MOVE R2 R0 - 0x7C040200, // 0002 CALL R1 1 - 0x8C040305, // 0003 GETMET R1 R1 K5 - 0x7C040200, // 0004 CALL R1 1 - 0x88040106, // 0005 GETMBR R1 R0 K6 - 0x74060020, // 0006 JMPT R1 #0028 - 0x60040008, // 0007 GETGBL R1 G8 - 0x88080100, // 0008 GETMBR R2 R0 K0 - 0x7C040200, // 0009 CALL R1 1 - 0x00060E01, // 000A ADD R1 K7 R1 - 0xB80A1000, // 000B GETNGBL R2 K8 - 0x8C080509, // 000C GETMET R2 R2 K9 - 0x5810000A, // 000D LDCONST R4 K10 - 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 - 0x8C0C0501, // 0013 GETMET R3 R2 K1 - 0x5814000B, // 0014 LDCONST R5 K11 - 0x7C0C0400, // 0015 CALL R3 2 - 0x5C080600, // 0016 MOVE R2 R3 - 0x4C0C0000, // 0017 LDNIL R3 - 0x200C0403, // 0018 NE R3 R2 R3 - 0x780E000D, // 0019 JMPF R3 #0028 - 0x8C0C050C, // 001A GETMET R3 R2 K12 - 0x5C140200, // 001B MOVE R5 R1 - 0x7C0C0400, // 001C CALL R3 2 - 0x780E0009, // 001D JMPF R3 #0028 - 0x8C0C0501, // 001E GETMET R3 R2 K1 - 0x5C140200, // 001F MOVE R5 R1 - 0x7C0C0400, // 0020 CALL R3 2 - 0x1C0C070D, // 0021 EQ R3 R3 K13 - 0x8810010E, // 0022 GETMBR R4 R0 K14 - 0x20100803, // 0023 NE R4 R4 R3 - 0x78120001, // 0024 JMPF R4 #0027 - 0x8C10010F, // 0025 GETMET R4 R0 K15 - 0x7C100200, // 0026 CALL R4 1 - 0x90021C03, // 0027 SETMBR R0 K14 R3 - 0x80000000, // 0028 RET 0 + ( &(const binstruction[18]) { /* code */ + 0x60080003, // 0000 GETGBL R2 G3 + 0x5C0C0000, // 0001 MOVE R3 R0 + 0x7C080200, // 0002 CALL R2 1 + 0x8C08050E, // 0003 GETMET R2 R2 K14 + 0x5C100200, // 0004 MOVE R4 R1 + 0x7C080400, // 0005 CALL R2 2 + 0x60080009, // 0006 GETGBL R2 G9 + 0x8C0C0307, // 0007 GETMET R3 R1 K7 + 0x8814010F, // 0008 GETMBR R5 R0 K15 + 0x58180010, // 0009 LDCONST R6 K16 + 0x7C0C0600, // 000A CALL R3 3 + 0x7C080200, // 000B CALL R2 1 + 0x90020602, // 000C SETMBR R0 K3 R2 + 0x88080103, // 000D GETMBR R2 R0 K3 + 0x18080511, // 000E LE R2 R2 K17 + 0x780A0000, // 000F JMPF R2 #0011 + 0x90020710, // 0010 SETMBR R0 K3 K16 + 0x80000000, // 0011 RET 0 }) ) ); @@ -178,12 +222,12 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean_update_shadow, /* name */ /******************************************************************** -** Solidified function: init +** Solidified function: update_virtual ********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Boolean_init, /* name */ +be_local_closure(class_Matter_Plugin_Sensor_Boolean_update_virtual, /* name */ be_nested_proto( - 9, /* nstack */ - 4, /* argc */ + 10, /* nstack */ + 2, /* argc */ 10, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -191,20 +235,27 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean_init, /* name */ NULL, /* no sub protos */ 1, /* has constants */ &be_ktab_class_Matter_Plugin_Sensor_Boolean, /* shared constants */ - be_str_weak(init), + be_str_weak(update_virtual), &be_const_str_solidified, - ( &(const binstruction[11]) { /* code */ - 0x60100003, // 0000 GETGBL R4 G3 - 0x5C140000, // 0001 MOVE R5 R0 - 0x7C100200, // 0002 CALL R4 1 - 0x8C100910, // 0003 GETMET R4 R4 K16 - 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 - 0x90021C04, // 0009 SETMBR R0 K14 R4 - 0x80000000, // 000A RET 0 + ( &(const binstruction[18]) { /* code */ + 0x8C080112, // 0000 GETMET R2 R0 K18 + 0x5C100200, // 0001 MOVE R4 R1 + 0x88140113, // 0002 GETMBR R5 R0 K19 + 0x8818010B, // 0003 GETMBR R6 R0 K11 + 0x601C0017, // 0004 GETGBL R7 G23 + 0x4C200000, // 0005 LDNIL R8 + 0x4C240000, // 0006 LDNIL R9 + 0x7C080E00, // 0007 CALL R2 7 + 0x90021602, // 0008 SETMBR R0 K11 R2 + 0x8C08010C, // 0009 GETMET R2 R0 K12 + 0x7C080200, // 000A CALL R2 1 + 0x60080003, // 000B GETGBL R2 G3 + 0x5C0C0000, // 000C MOVE R3 R0 + 0x7C080200, // 000D CALL R2 1 + 0x8C080514, // 000E GETMET R2 R2 K20 + 0x5C100200, // 000F MOVE R4 R1 + 0x7C080400, // 0010 CALL R2 2 + 0x80000000, // 0011 RET 0 }) ) ); @@ -232,27 +283,27 @@ be_local_closure(class_Matter_Plugin_Sensor_Boolean_parse_status, /* name */ 0x1C0C0403, // 0001 EQ R3 R2 R3 0x780E0015, // 0002 JMPF R3 #0019 0x500C0000, // 0003 LDBOOL R3 0 0 - 0x8C100301, // 0004 GETMET R4 R1 K1 + 0x8C100307, // 0004 GETMET R4 R1 K7 0x60180008, // 0005 GETGBL R6 G8 - 0x881C0100, // 0006 GETMBR R7 R0 K0 + 0x881C0103, // 0006 GETMBR R7 R0 K3 0x7C180200, // 0007 CALL R6 1 - 0x001A0E06, // 0008 ADD R6 K7 R6 + 0x001A0406, // 0008 ADD R6 K2 R6 0x7C100400, // 0009 CALL R4 2 - 0x1C10090D, // 000A EQ R4 R4 K13 + 0x1C10090A, // 000A EQ R4 R4 K10 0x5C0C0800, // 000B MOVE R3 R4 - 0x8810010E, // 000C GETMBR R4 R0 K14 + 0x8810010B, // 000C GETMBR R4 R0 K11 0x4C140000, // 000D LDNIL R5 0x20100805, // 000E NE R4 R4 R5 0x78120007, // 000F JMPF R4 #0018 - 0x8810010E, // 0010 GETMBR R4 R0 K14 + 0x8810010B, // 0010 GETMBR R4 R0 K11 0x60140017, // 0011 GETGBL R5 G23 0x5C180600, // 0012 MOVE R6 R3 0x7C140200, // 0013 CALL R5 1 0x20100805, // 0014 NE R4 R4 R5 0x78120001, // 0015 JMPF R4 #0018 - 0x8C10010F, // 0016 GETMET R4 R0 K15 + 0x8C10010C, // 0016 GETMET R4 R0 K12 0x7C100200, // 0017 CALL R4 1 - 0x90021C03, // 0018 SETMBR R0 K14 R3 + 0x90021603, // 0018 SETMBR R0 K11 R3 0x80000000, // 0019 RET 0 }) ) @@ -267,19 +318,20 @@ extern const bclass be_class_Matter_Plugin_Device; be_local_class(Matter_Plugin_Sensor_Boolean, 2, &be_class_Matter_Plugin_Device, - be_nested_map(11, + be_nested_map(12, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(shadow_bool_value, -1), be_const_var(1) }, - { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Switch_X3Cx_X3E_X20number) }, - { be_const_key_weak(parse_status, -1), be_const_closure(class_Matter_Plugin_Sensor_Boolean_parse_status_closure) }, - { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_Boolean_value_updated_closure) }, - { be_const_key_weak(tasmota_switch_index, -1), be_const_var(0) }, - { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(class_Matter_Plugin_Sensor_Boolean__X3Clambda_X3E_closure) }, - { be_const_key_weak(update_shadow, -1), be_const_closure(class_Matter_Plugin_Sensor_Boolean_update_shadow_closure) }, - { be_const_key_weak(ARG, -1), be_nested_str_weak(switch) }, { be_const_key_weak(UPDATE_TIME, -1), be_const_int(750) }, - { be_const_key_weak(init, 8), be_const_closure(class_Matter_Plugin_Sensor_Boolean_init_closure) }, - { be_const_key_weak(parse_configuration, 2), be_const_closure(class_Matter_Plugin_Sensor_Boolean_parse_configuration_closure) }, + { be_const_key_weak(update_shadow, 6), be_const_closure(class_Matter_Plugin_Sensor_Boolean_update_shadow_closure) }, + { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_Boolean_value_updated_closure) }, + { be_const_key_weak(init, 5), be_const_closure(class_Matter_Plugin_Sensor_Boolean_init_closure) }, + { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(class_Matter_Plugin_Sensor_Boolean__X3Clambda_X3E_closure) }, + { be_const_key_weak(parse_status, 11), be_const_closure(class_Matter_Plugin_Sensor_Boolean_parse_status_closure) }, + { be_const_key_weak(parse_configuration, -1), be_const_closure(class_Matter_Plugin_Sensor_Boolean_parse_configuration_closure) }, + { be_const_key_weak(update_virtual, -1), be_const_closure(class_Matter_Plugin_Sensor_Boolean_update_virtual_closure) }, + { be_const_key_weak(shadow_bool_value, 7), be_const_var(1) }, + { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Switch_X3Cx_X3E_X20number) }, + { be_const_key_weak(tasmota_switch_index, -1), be_const_var(0) }, + { be_const_key_weak(ARG, -1), be_nested_str_weak(switch) }, })), be_str_weak(Matter_Plugin_Sensor_Boolean) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_GenericSwitch_Btn.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_GenericSwitch_Btn.h index 7481aae2c..36cabbced 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_GenericSwitch_Btn.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Sensor_GenericSwitch_Btn.h @@ -3,8 +3,8 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_GenericSwitch_Btn' ktab size: 24, total: 35 (saved 88 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_GenericSwitch_Btn[24] = { +// compact class 'Matter_Plugin_Sensor_GenericSwitch_Btn' ktab size: 25, total: 36 (saved 88 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_GenericSwitch_Btn[25] = { /* K0 */ be_nested_str_weak(matter), /* K1 */ be_nested_str_weak(TLV), /* K2 */ be_nested_str_weak(cluster), @@ -19,16 +19,17 @@ static const bvalue be_ktab_class_Matter_Plugin_Sensor_GenericSwitch_Btn[24] = { /* K11 */ be_nested_str_weak(U4), /* K12 */ be_nested_str_weak(read_attribute), /* K13 */ be_nested_str_weak(attribute_updated), - /* K14 */ be_nested_str_weak(tasmota_switch_index), - /* K15 */ be_nested_str_weak(find), - /* K16 */ be_nested_str_weak(ARG), - /* K17 */ be_nested_str_weak(_X2C_X22Switch_X22_X3A_X25s), - /* K18 */ be_nested_str_weak(shadow_onoff), - /* K19 */ be_nested_str_weak(set_position), - /* K20 */ be_nested_str_weak(publish_event), - /* K21 */ be_nested_str_weak(EVENT_INFO), - /* K22 */ be_nested_str_weak(Matter_TLV_item), - /* K23 */ be_const_int(3), + /* K14 */ be_nested_str_weak(parse_configuration), + /* K15 */ be_nested_str_weak(tasmota_switch_index), + /* K16 */ be_nested_str_weak(find), + /* K17 */ be_nested_str_weak(ARG), + /* K18 */ be_nested_str_weak(_X2C_X22Switch_X22_X3A_X25s), + /* K19 */ be_nested_str_weak(shadow_onoff), + /* K20 */ be_nested_str_weak(set_position), + /* K21 */ be_nested_str_weak(publish_event), + /* K22 */ be_nested_str_weak(EVENT_INFO), + /* K23 */ be_nested_str_weak(Matter_TLV_item), + /* K24 */ be_const_int(3), }; @@ -180,19 +181,25 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_parse_configuratio &be_ktab_class_Matter_Plugin_Sensor_GenericSwitch_Btn, /* shared constants */ be_str_weak(parse_configuration), &be_const_str_solidified, - ( &(const binstruction[12]) { /* code */ - 0x60080009, // 0000 GETGBL R2 G9 - 0x8C0C030F, // 0001 GETMET R3 R1 K15 - 0x88140110, // 0002 GETMBR R5 R0 K16 - 0x58180008, // 0003 LDCONST R6 K8 - 0x7C0C0600, // 0004 CALL R3 3 - 0x7C080200, // 0005 CALL R2 1 - 0x90021C02, // 0006 SETMBR R0 K14 R2 - 0x8808010E, // 0007 GETMBR R2 R0 K14 - 0x18080504, // 0008 LE R2 R2 K4 - 0x780A0000, // 0009 JMPF R2 #000B - 0x90021D08, // 000A SETMBR R0 K14 K8 - 0x80000000, // 000B RET 0 + ( &(const binstruction[18]) { /* code */ + 0x60080003, // 0000 GETGBL R2 G3 + 0x5C0C0000, // 0001 MOVE R3 R0 + 0x7C080200, // 0002 CALL R2 1 + 0x8C08050E, // 0003 GETMET R2 R2 K14 + 0x5C100200, // 0004 MOVE R4 R1 + 0x7C080400, // 0005 CALL R2 2 + 0x60080009, // 0006 GETGBL R2 G9 + 0x8C0C0310, // 0007 GETMET R3 R1 K16 + 0x88140111, // 0008 GETMBR R5 R0 K17 + 0x58180008, // 0009 LDCONST R6 K8 + 0x7C0C0600, // 000A CALL R3 3 + 0x7C080200, // 000B CALL R2 1 + 0x90021E02, // 000C SETMBR R0 K15 R2 + 0x8808010F, // 000D GETMBR R2 R0 K15 + 0x18080504, // 000E LE R2 R2 K4 + 0x780A0000, // 000F JMPF R2 #0011 + 0x90021F08, // 0010 SETMBR R0 K15 K8 + 0x80000000, // 0011 RET 0 }) ) ); @@ -217,9 +224,9 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_append_state_json, &be_const_str_solidified, ( &(const binstruction[ 7]) { /* code */ 0x60040018, // 0000 GETGBL R1 G24 - 0x58080011, // 0001 LDCONST R2 K17 + 0x58080012, // 0001 LDCONST R2 K18 0x600C0009, // 0002 GETGBL R3 G9 - 0x88100112, // 0003 GETMBR R4 R0 K18 + 0x88100113, // 0003 GETMBR R4 R0 K19 0x7C0C0200, // 0004 CALL R3 1 0x7C040400, // 0005 CALL R1 2 0x80040200, // 0006 RET 1 R1 @@ -250,20 +257,20 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_button_handler, 0x74160001, // 0001 JMPT R5 #0004 0x1C140508, // 0002 EQ R5 R2 K8 0x78160002, // 0003 JMPF R5 #0007 - 0x8C140113, // 0004 GETMET R5 R0 K19 + 0x8C140114, // 0004 GETMET R5 R0 K20 0x5C1C0600, // 0005 MOVE R7 R3 0x7C140400, // 0006 CALL R5 2 0x1C140508, // 0007 EQ R5 R2 K8 0x78160040, // 0008 JMPF R5 #004A 0x780E0010, // 0009 JMPF R3 #001B - 0x8C140114, // 000A GETMET R5 R0 K20 + 0x8C140115, // 000A GETMET R5 R0 K21 0x541E003A, // 000B LDINT R7 59 0x58200008, // 000C LDCONST R8 K8 0xB8260000, // 000D GETNGBL R9 K0 - 0x88241315, // 000E GETMBR R9 R9 K21 + 0x88241316, // 000E GETMBR R9 R9 K22 0xB82A0000, // 000F GETNGBL R10 K0 0x88281501, // 0010 GETMBR R10 R10 K1 - 0x8C281516, // 0011 GETMET R10 R10 K22 + 0x8C281517, // 0011 GETMET R10 R10 K23 0x7C280200, // 0012 CALL R10 1 0x8C281505, // 0013 GETMET R10 R10 K5 0xB8320000, // 0014 GETNGBL R12 K0 @@ -273,14 +280,14 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_button_handler, 0x7C280600, // 0018 CALL R10 3 0x7C140A00, // 0019 CALL R5 5 0x7002000F, // 001A JMP #002B - 0x8C140114, // 001B GETMET R5 R0 K20 + 0x8C140115, // 001B GETMET R5 R0 K21 0x541E003A, // 001C LDINT R7 59 - 0x58200017, // 001D LDCONST R8 K23 + 0x58200018, // 001D LDCONST R8 K24 0xB8260000, // 001E GETNGBL R9 K0 - 0x88241315, // 001F GETMBR R9 R9 K21 + 0x88241316, // 001F GETMBR R9 R9 K22 0xB82A0000, // 0020 GETNGBL R10 K0 0x88281501, // 0021 GETMBR R10 R10 K1 - 0x8C281516, // 0022 GETMET R10 R10 K22 + 0x8C281517, // 0022 GETMET R10 R10 K23 0x7C280200, // 0023 CALL R10 1 0x8C281505, // 0024 GETMET R10 R10 K5 0xB8320000, // 0025 GETNGBL R12 K0 @@ -293,14 +300,14 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_button_handler, 0x7816001B, // 002C JMPF R5 #0049 0x24140904, // 002D GT R5 R4 K4 0x78160019, // 002E JMPF R5 #0049 - 0x8C140114, // 002F GETMET R5 R0 K20 + 0x8C140115, // 002F GETMET R5 R0 K21 0x541E003A, // 0030 LDINT R7 59 0x54220004, // 0031 LDINT R8 5 0xB8260000, // 0032 GETNGBL R9 K0 - 0x88241315, // 0033 GETMBR R9 R9 K21 + 0x88241316, // 0033 GETMBR R9 R9 K22 0xB82A0000, // 0034 GETNGBL R10 K0 0x88281501, // 0035 GETMBR R10 R10 K1 - 0x8C281516, // 0036 GETMET R10 R10 K22 + 0x8C281517, // 0036 GETMET R10 R10 K23 0x7C280200, // 0037 CALL R10 1 0x8C281505, // 0038 GETMET R10 R10 K5 0xB8320000, // 0039 GETNGBL R12 K0 @@ -310,7 +317,7 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_button_handler, 0x7C280600, // 003D CALL R10 3 0xB82E0000, // 003E GETNGBL R11 K0 0x882C1701, // 003F GETMBR R11 R11 K1 - 0x8C2C1716, // 0040 GETMET R11 R11 K22 + 0x8C2C1717, // 0040 GETMET R11 R11 K23 0x7C2C0200, // 0041 CALL R11 1 0x8C2C1705, // 0042 GETMET R11 R11 K5 0xB8360000, // 0043 GETNGBL R13 K0 @@ -324,14 +331,14 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_button_handler, 0x7816001B, // 004B JMPF R5 #0068 0x24140904, // 004C GT R5 R4 K4 0x78160019, // 004D JMPF R5 #0068 - 0x8C140114, // 004E GETMET R5 R0 K20 + 0x8C140115, // 004E GETMET R5 R0 K21 0x541E003A, // 004F LDINT R7 59 0x54220005, // 0050 LDINT R8 6 0xB8260000, // 0051 GETNGBL R9 K0 - 0x88241315, // 0052 GETMBR R9 R9 K21 + 0x88241316, // 0052 GETMBR R9 R9 K22 0xB82A0000, // 0053 GETNGBL R10 K0 0x88281501, // 0054 GETMBR R10 R10 K1 - 0x8C281516, // 0055 GETMET R10 R10 K22 + 0x8C281517, // 0055 GETMET R10 R10 K23 0x7C280200, // 0056 CALL R10 1 0x8C281505, // 0057 GETMET R10 R10 K5 0xB8320000, // 0058 GETNGBL R12 K0 @@ -341,7 +348,7 @@ be_local_closure(class_Matter_Plugin_Sensor_GenericSwitch_Btn_button_handler, 0x7C280600, // 005C CALL R10 3 0xB82E0000, // 005D GETNGBL R11 K0 0x882C1701, // 005E GETMBR R11 R11 K1 - 0x8C2C1716, // 005F GETMET R11 R11 K22 + 0x8C2C1717, // 005F GETMET R11 R11 K23 0x7C2C0200, // 0060 CALL R11 1 0x8C2C1705, // 0061 GETMET R11 R11 K5 0xB8360000, // 0062 GETNGBL R13 K0 diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Shutter.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Shutter.h index 9cdec61e1..7f968fc68 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Shutter.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_2_Shutter.h @@ -3,56 +3,57 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Shutter' ktab size: 48, total: 79 (saved 248 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Shutter[48] = { - /* K0 */ be_nested_str_weak(tasmota_shutter_index), - /* K1 */ be_nested_str_weak(find), - /* K2 */ be_nested_str_weak(ARG), - /* K3 */ be_const_int(0), - /* K4 */ be_nested_str_weak(shadow_shutter_inverted), - /* K5 */ be_nested_str_weak(light), - /* K6 */ be_nested_str_weak(matter), - /* K7 */ be_nested_str_weak(TLV), - /* K8 */ be_nested_str_weak(cluster), - /* K9 */ be_nested_str_weak(command), - /* K10 */ be_nested_str_weak(update_shadow_lazy), - /* K11 */ be_nested_str_weak(tasmota), - /* K12 */ be_nested_str_weak(cmd), - /* K13 */ be_nested_str_weak(ShutterStopOpen), - /* K14 */ be_const_int(1), - /* K15 */ be_nested_str_weak(update_shadow), - /* K16 */ be_nested_str_weak(ShutterStopClose), - /* K17 */ be_const_int(2), - /* K18 */ be_nested_str_weak(ShutterStop), - /* K19 */ be_nested_str_weak(log), - /* K20 */ be_nested_str_weak(MTR_X3A_X20Tilt_X20_X3D_X20), - /* K21 */ be_nested_str_weak(findsubval), - /* K22 */ be_nested_str_weak(ShutterPosition), - /* K23 */ be_nested_str_weak(_X20), - /* K24 */ be_nested_str_weak(pos_X25_X3A), - /* K25 */ be_nested_str_weak(invoke_request), - /* K26 */ be_nested_str_weak(attribute), - /* K27 */ be_nested_str_weak(update_inverted), - /* K28 */ be_nested_str_weak(set), - /* K29 */ be_nested_str_weak(U1), - /* K30 */ be_nested_str_weak(U2), - /* K31 */ be_nested_str_weak(shadow_shutter_pos), - /* K32 */ be_nested_str_weak(set_or_nil), - /* K33 */ be_nested_str_weak(shadow_shutter_direction), - /* K34 */ be_nested_str_weak(shadow_shutter_target), - /* K35 */ be_nested_str_weak(read_attribute), - /* K36 */ be_nested_str_weak(Shutter), - /* K37 */ be_nested_str_weak(contains), - /* K38 */ be_nested_str_weak(Position), - /* K39 */ be_nested_str_weak(attribute_updated), - /* K40 */ be_nested_str_weak(Direction), - /* K41 */ be_nested_str_weak(Target), - /* K42 */ be_nested_str_weak(Status_X2013), - /* K43 */ be_nested_str_weak(StatusSHT), - /* K44 */ be_nested_str_weak(SHT), - /* K45 */ be_nested_str_weak(Opt), - /* K46 */ be_nested_str_weak(VIRTUAL), - /* K47 */ be_nested_str_weak(parse_sensors), +// compact class 'Matter_Plugin_Shutter' ktab size: 49, total: 80 (saved 248 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Shutter[49] = { + /* K0 */ be_nested_str_weak(parse_configuration), + /* K1 */ be_nested_str_weak(tasmota_shutter_index), + /* K2 */ be_nested_str_weak(find), + /* K3 */ be_nested_str_weak(ARG), + /* K4 */ be_const_int(0), + /* K5 */ be_nested_str_weak(shadow_shutter_inverted), + /* K6 */ be_nested_str_weak(light), + /* K7 */ be_nested_str_weak(matter), + /* K8 */ be_nested_str_weak(TLV), + /* K9 */ be_nested_str_weak(cluster), + /* K10 */ be_nested_str_weak(command), + /* K11 */ be_nested_str_weak(update_shadow_lazy), + /* K12 */ be_nested_str_weak(tasmota), + /* K13 */ be_nested_str_weak(cmd), + /* K14 */ be_nested_str_weak(ShutterStopOpen), + /* K15 */ be_const_int(1), + /* K16 */ be_nested_str_weak(update_shadow), + /* K17 */ be_nested_str_weak(ShutterStopClose), + /* K18 */ be_const_int(2), + /* K19 */ be_nested_str_weak(ShutterStop), + /* K20 */ be_nested_str_weak(log), + /* K21 */ be_nested_str_weak(MTR_X3A_X20Tilt_X20_X3D_X20), + /* K22 */ be_nested_str_weak(findsubval), + /* K23 */ be_nested_str_weak(ShutterPosition), + /* K24 */ be_nested_str_weak(_X20), + /* K25 */ be_nested_str_weak(pos_X25_X3A), + /* K26 */ be_nested_str_weak(invoke_request), + /* K27 */ be_nested_str_weak(attribute), + /* K28 */ be_nested_str_weak(update_inverted), + /* K29 */ be_nested_str_weak(set), + /* K30 */ be_nested_str_weak(U1), + /* K31 */ be_nested_str_weak(U2), + /* K32 */ be_nested_str_weak(shadow_shutter_pos), + /* K33 */ be_nested_str_weak(set_or_nil), + /* K34 */ be_nested_str_weak(shadow_shutter_direction), + /* K35 */ be_nested_str_weak(shadow_shutter_target), + /* K36 */ be_nested_str_weak(read_attribute), + /* K37 */ be_nested_str_weak(Shutter), + /* K38 */ be_nested_str_weak(contains), + /* K39 */ be_nested_str_weak(Position), + /* K40 */ be_nested_str_weak(attribute_updated), + /* K41 */ be_nested_str_weak(Direction), + /* K42 */ be_nested_str_weak(Target), + /* K43 */ be_nested_str_weak(Status_X2013), + /* K44 */ be_nested_str_weak(StatusSHT), + /* K45 */ be_nested_str_weak(SHT), + /* K46 */ be_nested_str_weak(Opt), + /* K47 */ be_nested_str_weak(VIRTUAL), + /* K48 */ be_nested_str_weak(parse_sensors), }; @@ -74,19 +75,25 @@ be_local_closure(class_Matter_Plugin_Shutter_parse_configuration, /* name */ &be_ktab_class_Matter_Plugin_Shutter, /* shared constants */ be_str_weak(parse_configuration), &be_const_str_solidified, - ( &(const binstruction[12]) { /* code */ - 0x8C080301, // 0000 GETMET R2 R1 K1 - 0x88100102, // 0001 GETMBR R4 R0 K2 - 0x7C080400, // 0002 CALL R2 2 - 0x90020002, // 0003 SETMBR R0 K0 R2 - 0x88080100, // 0004 GETMBR R2 R0 K0 - 0x4C0C0000, // 0005 LDNIL R3 - 0x1C080403, // 0006 EQ R2 R2 R3 - 0x780A0000, // 0007 JMPF R2 #0009 - 0x90020103, // 0008 SETMBR R0 K0 K3 - 0x5409FFFE, // 0009 LDINT R2 -1 - 0x90020802, // 000A SETMBR R0 K4 R2 - 0x80000000, // 000B RET 0 + ( &(const binstruction[18]) { /* code */ + 0x60080003, // 0000 GETGBL R2 G3 + 0x5C0C0000, // 0001 MOVE R3 R0 + 0x7C080200, // 0002 CALL R2 1 + 0x8C080500, // 0003 GETMET R2 R2 K0 + 0x5C100200, // 0004 MOVE R4 R1 + 0x7C080400, // 0005 CALL R2 2 + 0x8C080302, // 0006 GETMET R2 R1 K2 + 0x88100103, // 0007 GETMBR R4 R0 K3 + 0x7C080400, // 0008 CALL R2 2 + 0x90020202, // 0009 SETMBR R0 K1 R2 + 0x88080101, // 000A GETMBR R2 R0 K1 + 0x4C0C0000, // 000B LDNIL R3 + 0x1C080403, // 000C EQ R2 R2 R3 + 0x780A0000, // 000D JMPF R2 #000F + 0x90020304, // 000E SETMBR R0 K1 K4 + 0x5409FFFE, // 000F LDINT R2 -1 + 0x90020A02, // 0010 SETMBR R0 K5 R2 + 0x80000000, // 0011 RET 0 }) ) ); @@ -110,60 +117,60 @@ be_local_closure(class_Matter_Plugin_Shutter_invoke_request, /* name */ be_str_weak(invoke_request), &be_const_str_solidified, ( &(const binstruction[115]) { /* code */ - 0xA4120A00, // 0000 IMPORT R4 K5 - 0xB8160C00, // 0001 GETNGBL R5 K6 - 0x88140B07, // 0002 GETMBR R5 R5 K7 - 0x88180708, // 0003 GETMBR R6 R3 K8 - 0x881C0709, // 0004 GETMBR R7 R3 K9 + 0xA4120C00, // 0000 IMPORT R4 K6 + 0xB8160E00, // 0001 GETNGBL R5 K7 + 0x88140B08, // 0002 GETMBR R5 R5 K8 + 0x88180709, // 0003 GETMBR R6 R3 K9 + 0x881C070A, // 0004 GETMBR R7 R3 K10 0x54220101, // 0005 LDINT R8 258 0x1C200C08, // 0006 EQ R8 R6 R8 0x78220060, // 0007 JMPF R8 #0069 - 0x8C20010A, // 0008 GETMET R8 R0 K10 + 0x8C20010B, // 0008 GETMET R8 R0 K11 0x7C200200, // 0009 CALL R8 1 - 0x1C200F03, // 000A EQ R8 R7 K3 + 0x1C200F04, // 000A EQ R8 R7 K4 0x7822000D, // 000B JMPF R8 #001A - 0xB8221600, // 000C GETNGBL R8 K11 - 0x8C20110C, // 000D GETMET R8 R8 K12 + 0xB8221800, // 000C GETNGBL R8 K12 + 0x8C20110D, // 000D GETMET R8 R8 K13 0x60280008, // 000E GETGBL R10 G8 - 0x882C0100, // 000F GETMBR R11 R0 K0 - 0x002C170E, // 0010 ADD R11 R11 K14 + 0x882C0101, // 000F GETMBR R11 R0 K1 + 0x002C170F, // 0010 ADD R11 R11 K15 0x7C280200, // 0011 CALL R10 1 - 0x002A1A0A, // 0012 ADD R10 K13 R10 + 0x002A1C0A, // 0012 ADD R10 K14 R10 0x502C0200, // 0013 LDBOOL R11 1 0 0x7C200600, // 0014 CALL R8 3 - 0x8C20010F, // 0015 GETMET R8 R0 K15 + 0x8C200110, // 0015 GETMET R8 R0 K16 0x7C200200, // 0016 CALL R8 1 0x50200200, // 0017 LDBOOL R8 1 0 0x80041000, // 0018 RET 1 R8 0x7002004D, // 0019 JMP #0068 - 0x1C200F0E, // 001A EQ R8 R7 K14 + 0x1C200F0F, // 001A EQ R8 R7 K15 0x7822000D, // 001B JMPF R8 #002A - 0xB8221600, // 001C GETNGBL R8 K11 - 0x8C20110C, // 001D GETMET R8 R8 K12 + 0xB8221800, // 001C GETNGBL R8 K12 + 0x8C20110D, // 001D GETMET R8 R8 K13 0x60280008, // 001E GETGBL R10 G8 - 0x882C0100, // 001F GETMBR R11 R0 K0 - 0x002C170E, // 0020 ADD R11 R11 K14 + 0x882C0101, // 001F GETMBR R11 R0 K1 + 0x002C170F, // 0020 ADD R11 R11 K15 0x7C280200, // 0021 CALL R10 1 - 0x002A200A, // 0022 ADD R10 K16 R10 + 0x002A220A, // 0022 ADD R10 K17 R10 0x502C0200, // 0023 LDBOOL R11 1 0 0x7C200600, // 0024 CALL R8 3 - 0x8C20010F, // 0025 GETMET R8 R0 K15 + 0x8C200110, // 0025 GETMET R8 R0 K16 0x7C200200, // 0026 CALL R8 1 0x50200200, // 0027 LDBOOL R8 1 0 0x80041000, // 0028 RET 1 R8 0x7002003D, // 0029 JMP #0068 - 0x1C200F11, // 002A EQ R8 R7 K17 + 0x1C200F12, // 002A EQ R8 R7 K18 0x7822000D, // 002B JMPF R8 #003A - 0xB8221600, // 002C GETNGBL R8 K11 - 0x8C20110C, // 002D GETMET R8 R8 K12 + 0xB8221800, // 002C GETNGBL R8 K12 + 0x8C20110D, // 002D GETMET R8 R8 K13 0x60280008, // 002E GETGBL R10 G8 - 0x882C0100, // 002F GETMBR R11 R0 K0 - 0x002C170E, // 0030 ADD R11 R11 K14 + 0x882C0101, // 002F GETMBR R11 R0 K1 + 0x002C170F, // 0030 ADD R11 R11 K15 0x7C280200, // 0031 CALL R10 1 - 0x002A240A, // 0032 ADD R10 K18 R10 + 0x002A260A, // 0032 ADD R10 K19 R10 0x502C0200, // 0033 LDBOOL R11 1 0 0x7C200600, // 0034 CALL R8 3 - 0x8C20010F, // 0035 GETMET R8 R0 K15 + 0x8C200110, // 0035 GETMET R8 R0 K16 0x7C200200, // 0036 CALL R8 1 0x50200200, // 0037 LDBOOL R8 1 0 0x80041000, // 0038 RET 1 R8 @@ -171,34 +178,34 @@ be_local_closure(class_Matter_Plugin_Shutter_invoke_request, /* name */ 0x54220004, // 003A LDINT R8 5 0x1C200E08, // 003B EQ R8 R7 R8 0x7822002A, // 003C JMPF R8 #0068 - 0xB8222600, // 003D GETNGBL R8 K19 + 0xB8222800, // 003D GETNGBL R8 K20 0x60240008, // 003E GETGBL R9 G8 0x5C280400, // 003F MOVE R10 R2 0x7C240200, // 0040 CALL R9 1 - 0x00262809, // 0041 ADD R9 K20 R9 - 0x58280011, // 0042 LDCONST R10 K17 + 0x00262A09, // 0041 ADD R9 K21 R9 + 0x58280012, // 0042 LDCONST R10 K18 0x7C200400, // 0043 CALL R8 2 - 0x8C200515, // 0044 GETMET R8 R2 K21 - 0x58280003, // 0045 LDCONST R10 K3 + 0x8C200516, // 0044 GETMET R8 R2 K22 + 0x58280004, // 0045 LDCONST R10 K4 0x7C200400, // 0046 CALL R8 2 0x4C240000, // 0047 LDNIL R9 0x20241009, // 0048 NE R9 R8 R9 0x7826001B, // 0049 JMPF R9 #0066 0x54260063, // 004A LDINT R9 100 0x0C201009, // 004B DIV R8 R8 R9 - 0x88240104, // 004C GETMBR R9 R0 K4 - 0x1C241303, // 004D EQ R9 R9 K3 + 0x88240105, // 004C GETMBR R9 R0 K5 + 0x1C241304, // 004D EQ R9 R9 K4 0x78260001, // 004E JMPF R9 #0051 0x54260063, // 004F LDINT R9 100 0x04201208, // 0050 SUB R8 R9 R8 - 0xB8261600, // 0051 GETNGBL R9 K11 - 0x8C24130C, // 0052 GETMET R9 R9 K12 + 0xB8261800, // 0051 GETNGBL R9 K12 + 0x8C24130D, // 0052 GETMET R9 R9 K13 0x602C0008, // 0053 GETGBL R11 G8 - 0x88300100, // 0054 GETMBR R12 R0 K0 - 0x0030190E, // 0055 ADD R12 R12 K14 + 0x88300101, // 0054 GETMBR R12 R0 K1 + 0x0030190F, // 0055 ADD R12 R12 K15 0x7C2C0200, // 0056 CALL R11 1 - 0x002E2C0B, // 0057 ADD R11 K22 R11 - 0x002C1717, // 0058 ADD R11 R11 K23 + 0x002E2E0B, // 0057 ADD R11 K23 R11 + 0x002C1718, // 0058 ADD R11 R11 K24 0x60300008, // 0059 GETGBL R12 G8 0x5C341000, // 005A MOVE R13 R8 0x7C300200, // 005B CALL R12 1 @@ -208,9 +215,9 @@ be_local_closure(class_Matter_Plugin_Shutter_invoke_request, /* name */ 0x60240008, // 005F GETGBL R9 G8 0x5C281000, // 0060 MOVE R10 R8 0x7C240200, // 0061 CALL R9 1 - 0x00263009, // 0062 ADD R9 K24 R9 - 0x900E2609, // 0063 SETMBR R3 K19 R9 - 0x8C24010F, // 0064 GETMET R9 R0 K15 + 0x00263209, // 0062 ADD R9 K25 R9 + 0x900E2809, // 0063 SETMBR R3 K20 R9 + 0x8C240110, // 0064 GETMET R9 R0 K16 0x7C240200, // 0065 CALL R9 1 0x50240200, // 0066 LDBOOL R9 1 0 0x80041200, // 0067 RET 1 R9 @@ -218,7 +225,7 @@ be_local_closure(class_Matter_Plugin_Shutter_invoke_request, /* name */ 0x60200003, // 0069 GETGBL R8 G3 0x5C240000, // 006A MOVE R9 R0 0x7C200200, // 006B CALL R8 1 - 0x8C201119, // 006C GETMET R8 R8 K25 + 0x8C20111A, // 006C GETMET R8 R8 K26 0x5C280200, // 006D MOVE R10 R1 0x5C2C0400, // 006E MOVE R11 R2 0x5C300600, // 006F MOVE R12 R3 @@ -248,22 +255,22 @@ be_local_closure(class_Matter_Plugin_Shutter_read_attribute, /* name */ be_str_weak(read_attribute), &be_const_str_solidified, ( &(const binstruction[145]) { /* code */ - 0xB8120C00, // 0000 GETNGBL R4 K6 - 0x88100907, // 0001 GETMBR R4 R4 K7 - 0x88140508, // 0002 GETMBR R5 R2 K8 - 0x8818051A, // 0003 GETMBR R6 R2 K26 + 0xB8120E00, // 0000 GETNGBL R4 K7 + 0x88100908, // 0001 GETMBR R4 R4 K8 + 0x88140509, // 0002 GETMBR R5 R2 K9 + 0x8818051B, // 0003 GETMBR R6 R2 K27 0x4C1C0000, // 0004 LDNIL R7 0x54220101, // 0005 LDINT R8 258 0x1C200A08, // 0006 EQ R8 R5 R8 0x7822007F, // 0007 JMPF R8 #0088 - 0x8C20010A, // 0008 GETMET R8 R0 K10 + 0x8C20010B, // 0008 GETMET R8 R0 K11 0x7C200200, // 0009 CALL R8 1 - 0x8C20011B, // 000A GETMET R8 R0 K27 + 0x8C20011C, // 000A GETMET R8 R0 K28 0x7C200200, // 000B CALL R8 1 - 0x1C200D03, // 000C EQ R8 R6 K3 + 0x1C200D04, // 000C EQ R8 R6 K4 0x78220005, // 000D JMPF R8 #0014 - 0x8C20071C, // 000E GETMET R8 R3 K28 - 0x8828091D, // 000F GETMBR R10 R4 K29 + 0x8C20071D, // 000E GETMET R8 R3 K29 + 0x8828091E, // 000F GETMBR R10 R4 K30 0x542E00FE, // 0010 LDINT R11 255 0x7C200600, // 0011 CALL R8 3 0x80041000, // 0012 RET 1 R8 @@ -271,27 +278,27 @@ be_local_closure(class_Matter_Plugin_Shutter_read_attribute, /* name */ 0x54220004, // 0014 LDINT R8 5 0x1C200C08, // 0015 EQ R8 R6 R8 0x78220005, // 0016 JMPF R8 #001D - 0x8C20071C, // 0017 GETMET R8 R3 K28 - 0x8828091E, // 0018 GETMBR R10 R4 K30 - 0x582C0003, // 0019 LDCONST R11 K3 + 0x8C20071D, // 0017 GETMET R8 R3 K29 + 0x8828091F, // 0018 GETMBR R10 R4 K31 + 0x582C0004, // 0019 LDCONST R11 K4 0x7C200600, // 001A CALL R8 3 0x80041000, // 001B RET 1 R8 0x7002006A, // 001C JMP #0088 0x54220006, // 001D LDINT R8 7 0x1C200C08, // 001E EQ R8 R6 R8 0x78220006, // 001F JMPF R8 #0027 - 0x8C20071C, // 0020 GETMET R8 R3 K28 - 0x8828091D, // 0021 GETMBR R10 R4 K29 + 0x8C20071D, // 0020 GETMET R8 R3 K29 + 0x8828091E, // 0021 GETMBR R10 R4 K30 0x542E0007, // 0022 LDINT R11 8 - 0x002E1C0B, // 0023 ADD R11 K14 R11 + 0x002E1E0B, // 0023 ADD R11 K15 R11 0x7C200600, // 0024 CALL R8 3 0x80041000, // 0025 RET 1 R8 0x70020060, // 0026 JMP #0088 0x5422000C, // 0027 LDINT R8 13 0x1C200C08, // 0028 EQ R8 R6 R8 0x78220005, // 0029 JMPF R8 #0030 - 0x8C20071C, // 002A GETMET R8 R3 K28 - 0x8828091D, // 002B GETMBR R10 R4 K29 + 0x8C20071D, // 002A GETMET R8 R3 K29 + 0x8828091E, // 002B GETMBR R10 R4 K30 0x542E00FE, // 002C LDINT R11 255 0x7C200600, // 002D CALL R8 3 0x80041000, // 002E RET 1 R8 @@ -299,26 +306,26 @@ be_local_closure(class_Matter_Plugin_Shutter_read_attribute, /* name */ 0x5422000D, // 0030 LDINT R8 14 0x1C200C08, // 0031 EQ R8 R6 R8 0x78220017, // 0032 JMPF R8 #004B - 0x8820011F, // 0033 GETMBR R8 R0 K31 + 0x88200120, // 0033 GETMBR R8 R0 K32 0x4C240000, // 0034 LDNIL R9 0x20201009, // 0035 NE R8 R8 R9 0x7822000D, // 0036 JMPF R8 #0045 - 0x88200104, // 0037 GETMBR R8 R0 K4 - 0x1C201103, // 0038 EQ R8 R8 K3 + 0x88200105, // 0037 GETMBR R8 R0 K5 + 0x1C201104, // 0038 EQ R8 R8 K4 0x78220006, // 0039 JMPF R8 #0041 0x54220063, // 003A LDINT R8 100 - 0x8824011F, // 003B GETMBR R9 R0 K31 + 0x88240120, // 003B GETMBR R9 R0 K32 0x04201009, // 003C SUB R8 R8 R9 0x54260063, // 003D LDINT R9 100 0x08201009, // 003E MUL R8 R8 R9 0x5C1C1000, // 003F MOVE R7 R8 0x70020003, // 0040 JMP #0045 - 0x8820011F, // 0041 GETMBR R8 R0 K31 + 0x88200120, // 0041 GETMBR R8 R0 K32 0x54260063, // 0042 LDINT R9 100 0x08201009, // 0043 MUL R8 R8 R9 0x5C1C1000, // 0044 MOVE R7 R8 - 0x8C200720, // 0045 GETMET R8 R3 K32 - 0x8828091E, // 0046 GETMBR R10 R4 K30 + 0x8C200721, // 0045 GETMET R8 R3 K33 + 0x8828091F, // 0046 GETMBR R10 R4 K31 0x5C2C0E00, // 0047 MOVE R11 R7 0x7C200600, // 0048 CALL R8 3 0x80041000, // 0049 RET 1 R8 @@ -327,24 +334,24 @@ be_local_closure(class_Matter_Plugin_Shutter_read_attribute, /* name */ 0x1C200C08, // 004C EQ R8 R6 R8 0x78220016, // 004D JMPF R8 #0065 0x4C200000, // 004E LDNIL R8 - 0x88240121, // 004F GETMBR R9 R0 K33 + 0x88240122, // 004F GETMBR R9 R0 K34 0x4C280000, // 0050 LDNIL R10 0x2024120A, // 0051 NE R9 R9 R10 0x7826000B, // 0052 JMPF R9 #005F - 0x88240121, // 0053 GETMBR R9 R0 K33 - 0x1C241303, // 0054 EQ R9 R9 K3 + 0x88240122, // 0053 GETMBR R9 R0 K34 + 0x1C241304, // 0054 EQ R9 R9 K4 0x78260001, // 0055 JMPF R9 #0058 - 0x58240003, // 0056 LDCONST R9 K3 + 0x58240004, // 0056 LDCONST R9 K4 0x70020005, // 0057 JMP #005E - 0x88240121, // 0058 GETMBR R9 R0 K33 - 0x24241303, // 0059 GT R9 R9 K3 + 0x88240122, // 0058 GETMBR R9 R0 K34 + 0x24241304, // 0059 GT R9 R9 K4 0x78260001, // 005A JMPF R9 #005D - 0x5824000E, // 005B LDCONST R9 K14 + 0x5824000F, // 005B LDCONST R9 K15 0x70020000, // 005C JMP #005E - 0x58240011, // 005D LDCONST R9 K17 + 0x58240012, // 005D LDCONST R9 K18 0x5C201200, // 005E MOVE R8 R9 - 0x8C240720, // 005F GETMET R9 R3 K32 - 0x882C091D, // 0060 GETMBR R11 R4 K29 + 0x8C240721, // 005F GETMET R9 R3 K33 + 0x882C091E, // 0060 GETMBR R11 R4 K30 0x5C301000, // 0061 MOVE R12 R8 0x7C240600, // 0062 CALL R9 3 0x80041200, // 0063 RET 1 R9 @@ -352,26 +359,26 @@ be_local_closure(class_Matter_Plugin_Shutter_read_attribute, /* name */ 0x5422000A, // 0065 LDINT R8 11 0x1C200C08, // 0066 EQ R8 R6 R8 0x78220017, // 0067 JMPF R8 #0080 - 0x88200122, // 0068 GETMBR R8 R0 K34 + 0x88200123, // 0068 GETMBR R8 R0 K35 0x4C240000, // 0069 LDNIL R9 0x20201009, // 006A NE R8 R8 R9 0x7822000D, // 006B JMPF R8 #007A - 0x88200104, // 006C GETMBR R8 R0 K4 - 0x1C201103, // 006D EQ R8 R8 K3 + 0x88200105, // 006C GETMBR R8 R0 K5 + 0x1C201104, // 006D EQ R8 R8 K4 0x78220006, // 006E JMPF R8 #0076 0x54220063, // 006F LDINT R8 100 - 0x88240122, // 0070 GETMBR R9 R0 K34 + 0x88240123, // 0070 GETMBR R9 R0 K35 0x04201009, // 0071 SUB R8 R8 R9 0x54260063, // 0072 LDINT R9 100 0x08201009, // 0073 MUL R8 R8 R9 0x5C1C1000, // 0074 MOVE R7 R8 0x70020003, // 0075 JMP #007A - 0x88200122, // 0076 GETMBR R8 R0 K34 + 0x88200123, // 0076 GETMBR R8 R0 K35 0x54260063, // 0077 LDINT R9 100 0x08201009, // 0078 MUL R8 R8 R9 0x5C1C1000, // 0079 MOVE R7 R8 - 0x8C200720, // 007A GETMET R8 R3 K32 - 0x8828091E, // 007B GETMBR R10 R4 K30 + 0x8C200721, // 007A GETMET R8 R3 K33 + 0x8828091F, // 007B GETMBR R10 R4 K31 0x5C2C0E00, // 007C MOVE R11 R7 0x7C200600, // 007D CALL R8 3 0x80041000, // 007E RET 1 R8 @@ -379,15 +386,15 @@ be_local_closure(class_Matter_Plugin_Shutter_read_attribute, /* name */ 0x54220016, // 0080 LDINT R8 23 0x1C200C08, // 0081 EQ R8 R6 R8 0x78220004, // 0082 JMPF R8 #0088 - 0x8C20071C, // 0083 GETMET R8 R3 K28 - 0x8828091D, // 0084 GETMBR R10 R4 K29 - 0x582C0003, // 0085 LDCONST R11 K3 + 0x8C20071D, // 0083 GETMET R8 R3 K29 + 0x8828091E, // 0084 GETMBR R10 R4 K30 + 0x582C0004, // 0085 LDCONST R11 K4 0x7C200600, // 0086 CALL R8 3 0x80041000, // 0087 RET 1 R8 0x60200003, // 0088 GETGBL R8 G3 0x5C240000, // 0089 MOVE R9 R0 0x7C200200, // 008A CALL R8 1 - 0x8C201123, // 008B GETMET R8 R8 K35 + 0x8C201124, // 008B GETMET R8 R8 K36 0x5C280200, // 008C MOVE R10 R1 0x5C2C0400, // 008D MOVE R11 R2 0x5C300600, // 008E MOVE R12 R3 @@ -444,57 +451,57 @@ be_local_closure(class_Matter_Plugin_Shutter_parse_sensors, /* name */ &be_const_str_solidified, ( &(const binstruction[53]) { /* code */ 0x60080008, // 0000 GETGBL R2 G8 - 0x880C0100, // 0001 GETMBR R3 R0 K0 - 0x000C070E, // 0002 ADD R3 R3 K14 + 0x880C0101, // 0001 GETMBR R3 R0 K1 + 0x000C070F, // 0002 ADD R3 R3 K15 0x7C080200, // 0003 CALL R2 1 - 0x000A4802, // 0004 ADD R2 K36 R2 - 0x8C0C0325, // 0005 GETMET R3 R1 K37 + 0x000A4A02, // 0004 ADD R2 K37 R2 + 0x8C0C0326, // 0005 GETMET R3 R1 K38 0x5C140400, // 0006 MOVE R5 R2 0x7C0C0400, // 0007 CALL R3 2 0x780E002A, // 0008 JMPF R3 #0034 0x940C0202, // 0009 GETIDX R3 R1 R2 - 0x8C100701, // 000A GETMET R4 R3 K1 - 0x58180026, // 000B LDCONST R6 K38 + 0x8C100702, // 000A GETMET R4 R3 K2 + 0x58180027, // 000B LDCONST R6 K39 0x7C100400, // 000C CALL R4 2 0x4C140000, // 000D LDNIL R5 0x20140805, // 000E NE R5 R4 R5 0x78160007, // 000F JMPF R5 #0018 - 0x8814011F, // 0010 GETMBR R5 R0 K31 + 0x88140120, // 0010 GETMBR R5 R0 K32 0x20140805, // 0011 NE R5 R4 R5 0x78160003, // 0012 JMPF R5 #0017 - 0x8C140127, // 0013 GETMET R5 R0 K39 + 0x8C140128, // 0013 GETMET R5 R0 K40 0x541E0101, // 0014 LDINT R7 258 0x5422000D, // 0015 LDINT R8 14 0x7C140600, // 0016 CALL R5 3 - 0x90023E04, // 0017 SETMBR R0 K31 R4 - 0x8C140701, // 0018 GETMET R5 R3 K1 - 0x581C0028, // 0019 LDCONST R7 K40 + 0x90024004, // 0017 SETMBR R0 K32 R4 + 0x8C140702, // 0018 GETMET R5 R3 K2 + 0x581C0029, // 0019 LDCONST R7 K41 0x7C140400, // 001A CALL R5 2 0x4C180000, // 001B LDNIL R6 0x20180A06, // 001C NE R6 R5 R6 0x781A0007, // 001D JMPF R6 #0026 - 0x88180121, // 001E GETMBR R6 R0 K33 + 0x88180122, // 001E GETMBR R6 R0 K34 0x20180A06, // 001F NE R6 R5 R6 0x781A0003, // 0020 JMPF R6 #0025 - 0x8C180127, // 0021 GETMET R6 R0 K39 + 0x8C180128, // 0021 GETMET R6 R0 K40 0x54220101, // 0022 LDINT R8 258 0x54260009, // 0023 LDINT R9 10 0x7C180600, // 0024 CALL R6 3 - 0x90024205, // 0025 SETMBR R0 K33 R5 - 0x8C180701, // 0026 GETMET R6 R3 K1 - 0x58200029, // 0027 LDCONST R8 K41 + 0x90024405, // 0025 SETMBR R0 K34 R5 + 0x8C180702, // 0026 GETMET R6 R3 K2 + 0x5820002A, // 0027 LDCONST R8 K42 0x7C180400, // 0028 CALL R6 2 0x4C1C0000, // 0029 LDNIL R7 0x201C0C07, // 002A NE R7 R6 R7 0x781E0007, // 002B JMPF R7 #0034 - 0x881C0122, // 002C GETMBR R7 R0 K34 + 0x881C0123, // 002C GETMBR R7 R0 K35 0x201C0C07, // 002D NE R7 R6 R7 0x781E0003, // 002E JMPF R7 #0033 - 0x8C1C0127, // 002F GETMET R7 R0 K39 + 0x8C1C0128, // 002F GETMET R7 R0 K40 0x54260101, // 0030 LDINT R9 258 0x542A000A, // 0031 LDINT R10 11 0x7C1C0600, // 0032 CALL R7 3 - 0x90024406, // 0033 SETMBR R0 K34 R6 + 0x90024606, // 0033 SETMBR R0 K35 R6 0x80000000, // 0034 RET 0 }) ) @@ -519,30 +526,30 @@ be_local_closure(class_Matter_Plugin_Shutter_update_inverted, /* name */ be_str_weak(update_inverted), &be_const_str_solidified, ( &(const binstruction[37]) { /* code */ - 0x88040104, // 0000 GETMBR R1 R0 K4 + 0x88040105, // 0000 GETMBR R1 R0 K5 0x5409FFFE, // 0001 LDINT R2 -1 0x1C040202, // 0002 EQ R1 R1 R2 0x7806001F, // 0003 JMPF R1 #0024 - 0xB8061600, // 0004 GETNGBL R1 K11 - 0x8C04030C, // 0005 GETMET R1 R1 K12 - 0x580C002A, // 0006 LDCONST R3 K42 + 0xB8061800, // 0004 GETNGBL R1 K12 + 0x8C04030D, // 0005 GETMET R1 R1 K13 + 0x580C002B, // 0006 LDCONST R3 K43 0x50100200, // 0007 LDBOOL R4 1 0 0x7C040600, // 0008 CALL R1 3 - 0x8C080325, // 0009 GETMET R2 R1 K37 - 0x5810002B, // 000A LDCONST R4 K43 + 0x8C080326, // 0009 GETMET R2 R1 K38 + 0x5810002C, // 000A LDCONST R4 K44 0x7C080400, // 000B CALL R2 2 0x780A0016, // 000C JMPF R2 #0024 - 0x9404032B, // 000D GETIDX R1 R1 K43 - 0x8C080301, // 000E GETMET R2 R1 K1 + 0x9404032C, // 000D GETIDX R1 R1 K44 + 0x8C080302, // 000E GETMET R2 R1 K2 0x60100008, // 000F GETGBL R4 G8 - 0x88140100, // 0010 GETMBR R5 R0 K0 + 0x88140101, // 0010 GETMBR R5 R0 K1 0x7C100200, // 0011 CALL R4 1 - 0x00125804, // 0012 ADD R4 K44 R4 + 0x00125A04, // 0012 ADD R4 K45 R4 0x60140013, // 0013 GETGBL R5 G19 0x7C140000, // 0014 CALL R5 0 0x7C080600, // 0015 CALL R2 3 - 0x8C080501, // 0016 GETMET R2 R2 K1 - 0x5810002D, // 0017 LDCONST R4 K45 + 0x8C080502, // 0016 GETMET R2 R2 K2 + 0x5810002E, // 0017 LDCONST R4 K46 0x7C080400, // 0018 CALL R2 2 0x4C0C0000, // 0019 LDNIL R3 0x200C0403, // 001A NE R3 R2 R3 @@ -551,10 +558,10 @@ be_local_closure(class_Matter_Plugin_Shutter_update_inverted, /* name */ 0x6010000C, // 001D GETGBL R4 G12 0x5C140400, // 001E MOVE R5 R2 0x7C100200, // 001F CALL R4 1 - 0x0410090E, // 0020 SUB R4 R4 K14 + 0x0410090F, // 0020 SUB R4 R4 K15 0x94100404, // 0021 GETIDX R4 R2 R4 0x7C0C0200, // 0022 CALL R3 1 - 0x90020803, // 0023 SETMBR R0 K4 R3 + 0x90020A03, // 0023 SETMBR R0 K5 R3 0x80000000, // 0024 RET 0 }) ) @@ -579,27 +586,27 @@ be_local_closure(class_Matter_Plugin_Shutter_update_shadow, /* name */ be_str_weak(update_shadow), &be_const_str_solidified, ( &(const binstruction[23]) { /* code */ - 0x8804012E, // 0000 GETMBR R1 R0 K46 + 0x8804012F, // 0000 GETMBR R1 R0 K47 0x7406000E, // 0001 JMPT R1 #0011 - 0x8C04011B, // 0002 GETMET R1 R0 K27 + 0x8C04011C, // 0002 GETMET R1 R0 K28 0x7C040200, // 0003 CALL R1 1 - 0xB8061600, // 0004 GETNGBL R1 K11 - 0x8C04030C, // 0005 GETMET R1 R1 K12 + 0xB8061800, // 0004 GETNGBL R1 K12 + 0x8C04030D, // 0005 GETMET R1 R1 K13 0x600C0008, // 0006 GETGBL R3 G8 - 0x88100100, // 0007 GETMBR R4 R0 K0 - 0x0010090E, // 0008 ADD R4 R4 K14 + 0x88100101, // 0007 GETMBR R4 R0 K1 + 0x0010090F, // 0008 ADD R4 R4 K15 0x7C0C0200, // 0009 CALL R3 1 - 0x000E2C03, // 000A ADD R3 K22 R3 + 0x000E2E03, // 000A ADD R3 K23 R3 0x50100200, // 000B LDBOOL R4 1 0 0x7C040600, // 000C CALL R1 3 0x78060002, // 000D JMPF R1 #0011 - 0x8C08012F, // 000E GETMET R2 R0 K47 + 0x8C080130, // 000E GETMET R2 R0 K48 0x5C100200, // 000F MOVE R4 R1 0x7C080400, // 0010 CALL R2 2 0x60040003, // 0011 GETGBL R1 G3 0x5C080000, // 0012 MOVE R2 R0 0x7C040200, // 0013 CALL R1 1 - 0x8C04030F, // 0014 GETMET R1 R1 K15 + 0x8C040310, // 0014 GETMET R1 R1 K16 0x7C040200, // 0015 CALL R1 1 0x80000000, // 0016 RET 0 }) diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Light1.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Light1.h index 63d9c8716..1a5eea0e6 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Light1.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Light1.h @@ -3,8 +3,8 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Light1' ktab size: 54, total: 108 (saved 432 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Light1[54] = { +// compact class 'Matter_Plugin_Light1' ktab size: 55, total: 109 (saved 432 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Light1[55] = { /* K0 */ be_const_int(0), /* K1 */ be_nested_str_weak(BRIDGE), /* K2 */ be_nested_str_weak(tasmota), @@ -44,21 +44,22 @@ static const bvalue be_ktab_class_Matter_Plugin_Light1[54] = { /* K36 */ be_nested_str_weak(attribute), /* K37 */ be_nested_str_weak(U1), /* K38 */ be_nested_str_weak(read_attribute), - /* K39 */ be_nested_str_weak(tasmota_relay_index), - /* K40 */ be_nested_str_weak(find), - /* K41 */ be_nested_str_weak(ARG), - /* K42 */ be_nested_str_weak(TYPE), - /* K43 */ be_nested_str_weak(light1), - /* K44 */ be_nested_str_weak(get_option), - /* K45 */ be_nested_str_weak(get), - /* K46 */ be_nested_str_weak(update_virtual), - /* K47 */ be_nested_str_weak(init), - /* K48 */ be_nested_str_weak(webserver), - /* K49 */ be_nested_str_weak(web_values_prefix), - /* K50 */ be_nested_str_weak(content_send), - /* K51 */ be_nested_str_weak(_X25s_X20_X25s), - /* K52 */ be_nested_str_weak(web_value_onoff), - /* K53 */ be_nested_str_weak(web_value_dimmer), + /* K39 */ be_nested_str_weak(parse_configuration), + /* K40 */ be_nested_str_weak(tasmota_relay_index), + /* K41 */ be_nested_str_weak(find), + /* K42 */ be_nested_str_weak(ARG), + /* K43 */ be_nested_str_weak(TYPE), + /* K44 */ be_nested_str_weak(light1), + /* K45 */ be_nested_str_weak(get_option), + /* K46 */ be_nested_str_weak(get), + /* K47 */ be_nested_str_weak(update_virtual), + /* K48 */ be_nested_str_weak(init), + /* K49 */ be_nested_str_weak(webserver), + /* K50 */ be_nested_str_weak(web_values_prefix), + /* K51 */ be_nested_str_weak(content_send), + /* K52 */ be_nested_str_weak(_X25s_X20_X25s), + /* K53 */ be_nested_str_weak(web_value_onoff), + /* K54 */ be_nested_str_weak(web_value_dimmer), }; @@ -226,7 +227,7 @@ be_local_closure(class_Matter_Plugin_Light1_web_value_dimmer, /* name */ ********************************************************************/ be_local_closure(class_Matter_Plugin_Light1_invoke_request, /* name */ be_nested_proto( - 22, /* nstack */ + 24, /* nstack */ 4, /* argc */ 10, /* varg */ 0, /* has upvals */ @@ -309,22 +310,22 @@ be_local_closure(class_Matter_Plugin_Light1_invoke_request, /* name */ 0x002A380A, // 0044 ADD R10 K28 R10 0x900E360A, // 0045 SETMBR R3 K27 R10 0x8C28011D, // 0046 GETMET R10 R0 K29 - 0x5830001E, // 0047 LDCONST R12 K30 - 0x5C341000, // 0048 MOVE R13 R8 - 0x58380005, // 0049 LDCONST R14 K5 - 0xB83E0400, // 004A GETNGBL R15 K2 - 0x8C3C1F03, // 004B GETMET R15 R15 K3 - 0x5C441000, // 004C MOVE R17 R8 - 0x58480000, // 004D LDCONST R18 K0 - 0x544E00FD, // 004E LDINT R19 254 - 0x58500000, // 004F LDCONST R20 K0 - 0x54560063, // 0050 LDINT R21 100 - 0x7C3C0C00, // 0051 CALL R15 6 - 0x58400022, // 0052 LDCONST R16 K34 - 0x78260001, // 0053 JMPF R9 #0056 - 0x5844001F, // 0054 LDCONST R17 K31 - 0x70020000, // 0055 JMP #0057 - 0x58440000, // 0056 LDCONST R17 K0 + 0x58300022, // 0047 LDCONST R12 K34 + 0x78260001, // 0048 JMPF R9 #004B + 0x5834001F, // 0049 LDCONST R13 K31 + 0x70020000, // 004A JMP #004C + 0x58340000, // 004B LDCONST R13 K0 + 0x5838001E, // 004C LDCONST R14 K30 + 0x5C3C1000, // 004D MOVE R15 R8 + 0x58400005, // 004E LDCONST R16 K5 + 0xB8460400, // 004F GETNGBL R17 K2 + 0x8C442303, // 0050 GETMET R17 R17 K3 + 0x5C4C1000, // 0051 MOVE R19 R8 + 0x58500000, // 0052 LDCONST R20 K0 + 0x545600FD, // 0053 LDINT R21 254 + 0x58580000, // 0054 LDCONST R22 K0 + 0x545E0063, // 0055 LDINT R23 100 + 0x7C440C00, // 0056 CALL R17 6 0x7C280E00, // 0057 CALL R10 7 0x50280200, // 0058 LDBOOL R10 1 0 0x80041400, // 0059 RET 1 R10 @@ -461,59 +462,65 @@ be_local_closure(class_Matter_Plugin_Light1_parse_configuration, /* name */ &be_ktab_class_Matter_Plugin_Light1, /* shared constants */ be_str_weak(parse_configuration), &be_const_str_solidified, - ( &(const binstruction[52]) { /* code */ - 0x88080101, // 0000 GETMBR R2 R0 K1 - 0x780A000F, // 0001 JMPF R2 #0012 - 0x60080009, // 0002 GETGBL R2 G9 - 0x8C0C0328, // 0003 GETMET R3 R1 K40 - 0x88140129, // 0004 GETMBR R5 R0 K41 - 0x4C180000, // 0005 LDNIL R6 - 0x7C0C0600, // 0006 CALL R3 3 - 0x7C080200, // 0007 CALL R2 1 - 0x90024E02, // 0008 SETMBR R0 K39 R2 - 0x88080127, // 0009 GETMBR R2 R0 K39 - 0x4C0C0000, // 000A LDNIL R3 - 0x20080403, // 000B NE R2 R2 R3 - 0x780A0003, // 000C JMPF R2 #0011 - 0x88080127, // 000D GETMBR R2 R0 K39 - 0x18080500, // 000E LE R2 R2 K0 - 0x780A0000, // 000F JMPF R2 #0011 - 0x90024F1F, // 0010 SETMBR R0 K39 K31 - 0x70020020, // 0011 JMP #0033 - 0x88080127, // 0012 GETMBR R2 R0 K39 - 0x4C0C0000, // 0013 LDNIL R3 - 0x1C080403, // 0014 EQ R2 R2 R3 - 0x780A001C, // 0015 JMPF R2 #0033 - 0x8808012A, // 0016 GETMBR R2 R0 K42 - 0x1C08052B, // 0017 EQ R2 R2 K43 - 0x780A0019, // 0018 JMPF R2 #0033 - 0x8C080328, // 0019 GETMET R2 R1 K40 - 0x88100129, // 001A GETMBR R4 R0 K41 - 0x7C080400, // 001B CALL R2 2 - 0x4C0C0000, // 001C LDNIL R3 - 0x1C0C0403, // 001D EQ R3 R2 R3 - 0x780E000E, // 001E JMPF R3 #002E - 0xB80E0400, // 001F GETNGBL R3 K2 - 0x8C0C072C, // 0020 GETMET R3 R3 K44 - 0x54160043, // 0021 LDINT R5 68 - 0x7C0C0400, // 0022 CALL R3 2 - 0x1C0C0700, // 0023 EQ R3 R3 K0 - 0x780E0007, // 0024 JMPF R3 #002D - 0xA40E1600, // 0025 IMPORT R3 K11 - 0x8C10072D, // 0026 GETMET R4 R3 K45 - 0x5818001F, // 0027 LDCONST R6 K31 - 0x7C100400, // 0028 CALL R4 2 - 0x4C140000, // 0029 LDNIL R5 - 0x20100805, // 002A NE R4 R4 R5 - 0x78120000, // 002B JMPF R4 #002D - 0x90021D1F, // 002C SETMBR R0 K14 K31 - 0x70020004, // 002D JMP #0033 - 0x600C0009, // 002E GETGBL R3 G9 - 0x5C100400, // 002F MOVE R4 R2 - 0x7C0C0200, // 0030 CALL R3 1 - 0x040C071F, // 0031 SUB R3 R3 K31 - 0x90021C03, // 0032 SETMBR R0 K14 R3 - 0x80000000, // 0033 RET 0 + ( &(const binstruction[58]) { /* code */ + 0x60080003, // 0000 GETGBL R2 G3 + 0x5C0C0000, // 0001 MOVE R3 R0 + 0x7C080200, // 0002 CALL R2 1 + 0x8C080527, // 0003 GETMET R2 R2 K39 + 0x5C100200, // 0004 MOVE R4 R1 + 0x7C080400, // 0005 CALL R2 2 + 0x88080101, // 0006 GETMBR R2 R0 K1 + 0x780A000F, // 0007 JMPF R2 #0018 + 0x60080009, // 0008 GETGBL R2 G9 + 0x8C0C0329, // 0009 GETMET R3 R1 K41 + 0x8814012A, // 000A GETMBR R5 R0 K42 + 0x4C180000, // 000B LDNIL R6 + 0x7C0C0600, // 000C CALL R3 3 + 0x7C080200, // 000D CALL R2 1 + 0x90025002, // 000E SETMBR R0 K40 R2 + 0x88080128, // 000F GETMBR R2 R0 K40 + 0x4C0C0000, // 0010 LDNIL R3 + 0x20080403, // 0011 NE R2 R2 R3 + 0x780A0003, // 0012 JMPF R2 #0017 + 0x88080128, // 0013 GETMBR R2 R0 K40 + 0x18080500, // 0014 LE R2 R2 K0 + 0x780A0000, // 0015 JMPF R2 #0017 + 0x9002511F, // 0016 SETMBR R0 K40 K31 + 0x70020020, // 0017 JMP #0039 + 0x88080128, // 0018 GETMBR R2 R0 K40 + 0x4C0C0000, // 0019 LDNIL R3 + 0x1C080403, // 001A EQ R2 R2 R3 + 0x780A001C, // 001B JMPF R2 #0039 + 0x8808012B, // 001C GETMBR R2 R0 K43 + 0x1C08052C, // 001D EQ R2 R2 K44 + 0x780A0019, // 001E JMPF R2 #0039 + 0x8C080329, // 001F GETMET R2 R1 K41 + 0x8810012A, // 0020 GETMBR R4 R0 K42 + 0x7C080400, // 0021 CALL R2 2 + 0x4C0C0000, // 0022 LDNIL R3 + 0x1C0C0403, // 0023 EQ R3 R2 R3 + 0x780E000E, // 0024 JMPF R3 #0034 + 0xB80E0400, // 0025 GETNGBL R3 K2 + 0x8C0C072D, // 0026 GETMET R3 R3 K45 + 0x54160043, // 0027 LDINT R5 68 + 0x7C0C0400, // 0028 CALL R3 2 + 0x1C0C0700, // 0029 EQ R3 R3 K0 + 0x780E0007, // 002A JMPF R3 #0033 + 0xA40E1600, // 002B IMPORT R3 K11 + 0x8C10072E, // 002C GETMET R4 R3 K46 + 0x5818001F, // 002D LDCONST R6 K31 + 0x7C100400, // 002E CALL R4 2 + 0x4C140000, // 002F LDNIL R5 + 0x20100805, // 0030 NE R4 R4 R5 + 0x78120000, // 0031 JMPF R4 #0033 + 0x90021D1F, // 0032 SETMBR R0 K14 K31 + 0x70020004, // 0033 JMP #0039 + 0x600C0009, // 0034 GETGBL R3 G9 + 0x5C100400, // 0035 MOVE R4 R2 + 0x7C0C0200, // 0036 CALL R3 1 + 0x040C071F, // 0037 SUB R3 R3 K31 + 0x90021C03, // 0038 SETMBR R0 K14 R3 + 0x80000000, // 0039 RET 0 }) ) ); @@ -537,10 +544,10 @@ be_local_closure(class_Matter_Plugin_Light1_update_virtual, /* name */ be_str_weak(update_virtual), &be_const_str_solidified, ( &(const binstruction[23]) { /* code */ - 0x8C080328, // 0000 GETMET R2 R1 K40 + 0x8C080329, // 0000 GETMET R2 R1 K41 0x58100022, // 0001 LDCONST R4 K34 0x7C080400, // 0002 CALL R2 2 - 0x8C0C0328, // 0003 GETMET R3 R1 K40 + 0x8C0C0329, // 0003 GETMET R3 R1 K41 0x5814001E, // 0004 LDCONST R5 K30 0x7C0C0400, // 0005 CALL R3 2 0x4C100000, // 0006 LDNIL R4 @@ -556,7 +563,7 @@ be_local_closure(class_Matter_Plugin_Light1_update_virtual, /* name */ 0x60100003, // 0010 GETGBL R4 G3 0x5C140000, // 0011 MOVE R5 R0 0x7C100200, // 0012 CALL R4 1 - 0x8C10092E, // 0013 GETMET R4 R4 K46 + 0x8C10092F, // 0013 GETMET R4 R4 K47 0x5C180200, // 0014 MOVE R6 R1 0x7C100400, // 0015 CALL R4 2 0x80000000, // 0016 RET 0 @@ -587,7 +594,7 @@ be_local_closure(class_Matter_Plugin_Light1_init, /* name */ 0x60100003, // 0001 GETGBL R4 G3 0x5C140000, // 0002 MOVE R5 R0 0x7C100200, // 0003 CALL R4 1 - 0x8C10092F, // 0004 GETMET R4 R4 K47 + 0x8C100930, // 0004 GETMET R4 R4 K48 0x5C180200, // 0005 MOVE R6 R1 0x5C1C0400, // 0006 MOVE R7 R2 0x5C200600, // 0007 MOVE R8 R3 @@ -616,16 +623,16 @@ be_local_closure(class_Matter_Plugin_Light1_web_values, /* name */ be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[14]) { /* code */ - 0xA4066000, // 0000 IMPORT R1 K48 - 0x8C080131, // 0001 GETMET R2 R0 K49 + 0xA4066200, // 0000 IMPORT R1 K49 + 0x8C080132, // 0001 GETMET R2 R0 K50 0x7C080200, // 0002 CALL R2 1 - 0x8C080332, // 0003 GETMET R2 R1 K50 + 0x8C080333, // 0003 GETMET R2 R1 K51 0x60100018, // 0004 GETGBL R4 G24 - 0x58140033, // 0005 LDCONST R5 K51 - 0x8C180134, // 0006 GETMET R6 R0 K52 + 0x58140034, // 0005 LDCONST R5 K52 + 0x8C180135, // 0006 GETMET R6 R0 K53 0x88200108, // 0007 GETMBR R8 R0 K8 0x7C180400, // 0008 CALL R6 2 - 0x8C1C0135, // 0009 GETMET R7 R0 K53 + 0x8C1C0136, // 0009 GETMET R7 R0 K54 0x7C1C0200, // 000A CALL R7 1 0x7C100600, // 000B CALL R4 3 0x7C080400, // 000C CALL R2 2 @@ -664,7 +671,7 @@ be_local_closure(class_Matter_Plugin_Light1_parse_status, /* name */ 0x1C0C0403, // 0008 EQ R3 R2 R3 0x780E0017, // 0009 JMPF R3 #0022 0x600C0009, // 000A GETGBL R3 G9 - 0x8C100328, // 000B GETMET R4 R1 K40 + 0x8C100329, // 000B GETMET R4 R1 K41 0x58180005, // 000C LDCONST R6 K5 0x7C100400, // 000D CALL R4 2 0x7C0C0200, // 000E CALL R3 1 @@ -716,13 +723,13 @@ be_local_closure(class_Matter_Plugin_Light1_update_shadow, /* name */ 0x88040101, // 0002 GETMBR R1 R0 K1 0x7406002A, // 0003 JMPT R1 #002F 0xA4061600, // 0004 IMPORT R1 K11 - 0x8C08032D, // 0005 GETMET R2 R1 K45 + 0x8C08032E, // 0005 GETMET R2 R1 K46 0x8810010E, // 0006 GETMBR R4 R0 K14 0x7C080400, // 0007 CALL R2 2 0x4C0C0000, // 0008 LDNIL R3 0x200C0403, // 0009 NE R3 R2 R3 0x780E0023, // 000A JMPF R3 #002F - 0x8C0C0528, // 000B GETMET R3 R2 K40 + 0x8C0C0529, // 000B GETMET R3 R2 K41 0x5814000F, // 000C LDCONST R5 K15 0x4C180000, // 000D LDNIL R6 0x7C0C0600, // 000E CALL R3 3 @@ -734,7 +741,7 @@ be_local_closure(class_Matter_Plugin_Light1_update_shadow, /* name */ 0x581C0000, // 0014 LDCONST R7 K0 0x7C100600, // 0015 CALL R4 3 0x90021003, // 0016 SETMBR R0 K8 R3 - 0x8C100528, // 0017 GETMET R4 R2 K40 + 0x8C100529, // 0017 GETMET R4 R2 K41 0x5818000D, // 0018 LDCONST R6 K13 0x4C1C0000, // 0019 LDNIL R7 0x7C100600, // 001A CALL R4 3 diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Contact.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Contact.h index 150a06f12..43058a902 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Contact.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Contact.h @@ -3,76 +3,34 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_Contact' ktab size: 24, total: 31 (saved 56 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_Contact[24] = { - /* K0 */ be_nested_str_weak(shadow_bool_value), - /* K1 */ be_nested_str_weak(_parse_update_virtual), - /* K2 */ be_nested_str_weak(Contact), - /* K3 */ be_const_int(0), - /* K4 */ be_nested_str_weak(update_virtual), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(TLV), - /* K7 */ be_nested_str_weak(cluster), - /* K8 */ be_nested_str_weak(attribute), - /* K9 */ be_nested_str_weak(set_or_nil), - /* K10 */ be_nested_str_weak(BOOL), - /* K11 */ be_nested_str_weak(read_attribute), - /* K12 */ be_nested_str_weak(webserver), - /* K13 */ be_nested_str_weak(web_values_prefix), - /* K14 */ be_nested_str_weak(content_send), - /* K15 */ be_nested_str_weak(Contact_X25i_X20_X25s), - /* K16 */ be_nested_str_weak(tasmota_switch_index), - /* K17 */ be_nested_str_weak(web_value_onoff), - /* K18 */ be_nested_str_weak(get_name), - /* K19 */ be_nested_str_weak(Switch), - /* K20 */ be_nested_str_weak(PREFIX), - /* K21 */ be_nested_str_weak(html_escape), - /* K22 */ be_nested_str_weak(), - /* K23 */ be_nested_str_weak(attribute_updated), +// compact class 'Matter_Plugin_Sensor_Contact' ktab size: 21, total: 26 (saved 40 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_Contact[21] = { + /* 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(set_or_nil), + /* K6 */ be_nested_str_weak(BOOL), + /* K7 */ be_nested_str_weak(shadow_bool_value), + /* K8 */ be_nested_str_weak(read_attribute), + /* K9 */ be_nested_str_weak(webserver), + /* K10 */ be_nested_str_weak(web_values_prefix), + /* K11 */ be_nested_str_weak(content_send), + /* K12 */ be_nested_str_weak(Contact_X25i_X20_X25s), + /* K13 */ be_nested_str_weak(tasmota_switch_index), + /* K14 */ be_nested_str_weak(web_value_onoff), + /* K15 */ be_nested_str_weak(get_name), + /* K16 */ be_nested_str_weak(Switch), + /* K17 */ be_nested_str_weak(PREFIX), + /* K18 */ be_nested_str_weak(html_escape), + /* K19 */ be_nested_str_weak(), + /* K20 */ be_nested_str_weak(attribute_updated), }; extern const bclass be_class_Matter_Plugin_Sensor_Contact; -/******************************************************************** -** Solidified function: update_virtual -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Contact_update_virtual, /* name */ - be_nested_proto( - 10, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor_Contact, /* shared constants */ - be_str_weak(update_virtual), - &be_const_str_solidified, - ( &(const binstruction[16]) { /* code */ - 0x8C080101, // 0000 GETMET R2 R0 K1 - 0x5C100200, // 0001 MOVE R4 R1 - 0x58140002, // 0002 LDCONST R5 K2 - 0x88180100, // 0003 GETMBR R6 R0 K0 - 0x601C0017, // 0004 GETGBL R7 G23 - 0x54220044, // 0005 LDINT R8 69 - 0x58240003, // 0006 LDCONST R9 K3 - 0x7C080E00, // 0007 CALL R2 7 - 0x90020002, // 0008 SETMBR R0 K0 R2 - 0x60080003, // 0009 GETGBL R2 G3 - 0x5C0C0000, // 000A MOVE R3 R0 - 0x7C080200, // 000B CALL R2 1 - 0x8C080504, // 000C GETMET R2 R2 K4 - 0x5C100200, // 000D MOVE R4 R1 - 0x7C080400, // 000E CALL R2 2 - 0x80000000, // 000F RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: read_attribute ********************************************************************/ @@ -90,24 +48,24 @@ be_local_closure(class_Matter_Plugin_Sensor_Contact_read_attribute, /* name */ be_str_weak(read_attribute), &be_const_str_solidified, ( &(const binstruction[23]) { /* code */ - 0xB8120A00, // 0000 GETNGBL R4 K5 - 0x88100906, // 0001 GETMBR R4 R4 K6 - 0x88140507, // 0002 GETMBR R5 R2 K7 - 0x88180508, // 0003 GETMBR R6 R2 K8 + 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 0x781E0006, // 0006 JMPF R7 #000E - 0x1C1C0D03, // 0007 EQ R7 R6 K3 + 0x1C1C0D04, // 0007 EQ R7 R6 K4 0x781E0004, // 0008 JMPF R7 #000E - 0x8C1C0709, // 0009 GETMET R7 R3 K9 - 0x8824090A, // 000A GETMBR R9 R4 K10 - 0x88280100, // 000B GETMBR R10 R0 K0 + 0x8C1C0705, // 0009 GETMET R7 R3 K5 + 0x88240906, // 000A GETMBR R9 R4 K6 + 0x88280107, // 000B GETMBR R10 R0 K7 0x7C1C0600, // 000C CALL R7 3 0x80040E00, // 000D RET 1 R7 0x601C0003, // 000E GETGBL R7 G3 0x5C200000, // 000F MOVE R8 R0 0x7C1C0200, // 0010 CALL R7 1 - 0x8C1C0F0B, // 0011 GETMET R7 R7 K11 + 0x8C1C0F08, // 0011 GETMET R7 R7 K8 0x5C240200, // 0012 MOVE R9 R1 0x5C280400, // 0013 MOVE R10 R2 0x5C2C0600, // 0014 MOVE R11 R3 @@ -136,15 +94,15 @@ be_local_closure(class_Matter_Plugin_Sensor_Contact_web_values, /* name */ be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[13]) { /* code */ - 0xA4061800, // 0000 IMPORT R1 K12 - 0x8C08010D, // 0001 GETMET R2 R0 K13 + 0xA4061200, // 0000 IMPORT R1 K9 + 0x8C08010A, // 0001 GETMET R2 R0 K10 0x7C080200, // 0002 CALL R2 1 - 0x8C08030E, // 0003 GETMET R2 R1 K14 + 0x8C08030B, // 0003 GETMET R2 R1 K11 0x60100018, // 0004 GETGBL R4 G24 - 0x5814000F, // 0005 LDCONST R5 K15 - 0x88180110, // 0006 GETMBR R6 R0 K16 - 0x8C1C0111, // 0007 GETMET R7 R0 K17 - 0x88240100, // 0008 GETMBR R9 R0 K0 + 0x5814000C, // 0005 LDCONST R5 K12 + 0x8818010D, // 0006 GETMBR R6 R0 K13 + 0x8C1C010E, // 0007 GETMET R7 R0 K14 + 0x88240107, // 0008 GETMBR R9 R0 K7 0x7C1C0400, // 0009 CALL R7 2 0x7C100600, // 000A CALL R4 3 0x7C080400, // 000B CALL R2 2 @@ -172,25 +130,25 @@ be_local_closure(class_Matter_Plugin_Sensor_Contact_web_values_prefix, /* name be_str_weak(web_values_prefix), &be_const_str_solidified, ( &(const binstruction[22]) { /* code */ - 0xA4061800, // 0000 IMPORT R1 K12 - 0x8C080112, // 0001 GETMET R2 R0 K18 + 0xA4061200, // 0000 IMPORT R1 K9 + 0x8C08010F, // 0001 GETMET R2 R0 K15 0x7C080200, // 0002 CALL R2 1 0x5C0C0400, // 0003 MOVE R3 R2 0x740E0004, // 0004 JMPT R3 #000A 0x600C0008, // 0005 GETGBL R3 G8 - 0x88100110, // 0006 GETMBR R4 R0 K16 + 0x8810010D, // 0006 GETMBR R4 R0 K13 0x7C0C0200, // 0007 CALL R3 1 - 0x000E2603, // 0008 ADD R3 K19 R3 + 0x000E2003, // 0008 ADD R3 K16 R3 0x5C080600, // 0009 MOVE R2 R3 - 0x8C0C030E, // 000A GETMET R3 R1 K14 + 0x8C0C030B, // 000A GETMET R3 R1 K11 0x60140018, // 000B GETGBL R5 G24 - 0x88180114, // 000C GETMBR R6 R0 K20 + 0x88180111, // 000C GETMBR R6 R0 K17 0x780A0003, // 000D JMPF R2 #0012 - 0x8C1C0315, // 000E GETMET R7 R1 K21 + 0x8C1C0312, // 000E GETMET R7 R1 K18 0x5C240400, // 000F MOVE R9 R2 0x7C1C0400, // 0010 CALL R7 2 0x70020000, // 0011 JMP #0013 - 0x581C0016, // 0012 LDCONST R7 K22 + 0x581C0013, // 0012 LDCONST R7 K19 0x7C140400, // 0013 CALL R5 2 0x7C0C0400, // 0014 CALL R3 2 0x80000000, // 0015 RET 0 @@ -217,9 +175,9 @@ be_local_closure(class_Matter_Plugin_Sensor_Contact_value_updated, /* name */ be_str_weak(value_updated), &be_const_str_solidified, ( &(const binstruction[ 5]) { /* code */ - 0x8C040117, // 0000 GETMET R1 R0 K23 + 0x8C040114, // 0000 GETMET R1 R0 K20 0x540E0044, // 0001 LDINT R3 69 - 0x58100003, // 0002 LDCONST R4 K3 + 0x58100004, // 0002 LDCONST R4 K4 0x7C040600, // 0003 CALL R1 3 0x80000000, // 0004 RET 0 }) @@ -237,9 +195,13 @@ be_local_class(Matter_Plugin_Sensor_Contact, &be_class_Matter_Plugin_Sensor_Boolean, be_nested_map(10, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(update_virtual, 6), be_const_closure(class_Matter_Plugin_Sensor_Contact_update_virtual_closure) }, + { 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(21, -1), be_const_int(1) }, + })) ) } )) }, { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Contact) }, - { be_const_key_weak(read_attribute, 5), be_const_closure(class_Matter_Plugin_Sensor_Contact_read_attribute_closure) }, + { be_const_key_weak(read_attribute, 6), be_const_closure(class_Matter_Plugin_Sensor_Contact_read_attribute_closure) }, { 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[]) { @@ -255,12 +217,8 @@ be_local_class(Matter_Plugin_Sensor_Contact, { be_const_key_int(4, -1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(29, 0), be_const_bytes_instance(0000000100020003FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, + { be_const_key_weak(JSON_NAME, -1), be_nested_str_weak(Contact) }, { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Sensor_Contact_web_values_closure) }, - { 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(21, -1), be_const_int(1) }, - })) ) } )) }, { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Sensor_Contact_web_values_prefix_closure) }, { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_Contact_value_updated_closure) }, { be_const_key_weak(TYPE, 3), be_nested_str_weak(contact) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Occupancy.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Occupancy.h index b1f8fd013..19e2467dd 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Occupancy.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Occupancy.h @@ -3,80 +3,38 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_Occupancy' ktab size: 28, total: 35 (saved 56 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_Occupancy[28] = { - /* K0 */ be_nested_str_weak(shadow_bool_value), - /* K1 */ be_nested_str_weak(_parse_update_virtual), - /* K2 */ be_nested_str_weak(Occupancy), - /* K3 */ be_const_int(0), - /* K4 */ be_nested_str_weak(update_virtual), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(TLV), - /* K7 */ be_nested_str_weak(cluster), - /* K8 */ be_nested_str_weak(attribute), - /* K9 */ be_nested_str_weak(set_or_nil), - /* K10 */ be_nested_str_weak(U1), - /* K11 */ be_const_int(1), - /* K12 */ be_nested_str_weak(set), - /* K13 */ be_const_int(3), - /* K14 */ be_const_int(2), - /* K15 */ be_nested_str_weak(read_attribute), - /* K16 */ be_nested_str_weak(webserver), - /* K17 */ be_nested_str_weak(web_values_prefix), - /* K18 */ be_nested_str_weak(content_send), - /* K19 */ be_nested_str_weak(Occupancy_X25i_X20_X25s), - /* K20 */ be_nested_str_weak(web_value_onoff), - /* K21 */ be_nested_str_weak(shadow_occupancy), - /* K22 */ be_nested_str_weak(get_name), - /* K23 */ be_nested_str_weak(Switch), - /* K24 */ be_nested_str_weak(PREFIX), - /* K25 */ be_nested_str_weak(html_escape), - /* K26 */ be_nested_str_weak(), - /* K27 */ be_nested_str_weak(attribute_updated), +// compact class 'Matter_Plugin_Sensor_Occupancy' ktab size: 25, total: 30 (saved 40 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_Occupancy[25] = { + /* 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(set_or_nil), + /* K6 */ be_nested_str_weak(U1), + /* K7 */ be_nested_str_weak(shadow_bool_value), + /* K8 */ be_const_int(1), + /* K9 */ be_nested_str_weak(set), + /* K10 */ be_const_int(3), + /* K11 */ be_const_int(2), + /* K12 */ be_nested_str_weak(read_attribute), + /* K13 */ be_nested_str_weak(webserver), + /* K14 */ be_nested_str_weak(web_values_prefix), + /* K15 */ be_nested_str_weak(content_send), + /* K16 */ be_nested_str_weak(Occupancy_X25i_X20_X25s), + /* K17 */ be_nested_str_weak(web_value_onoff), + /* K18 */ be_nested_str_weak(shadow_occupancy), + /* K19 */ be_nested_str_weak(get_name), + /* K20 */ be_nested_str_weak(Switch), + /* K21 */ be_nested_str_weak(PREFIX), + /* K22 */ be_nested_str_weak(html_escape), + /* K23 */ be_nested_str_weak(), + /* K24 */ be_nested_str_weak(attribute_updated), }; extern const bclass be_class_Matter_Plugin_Sensor_Occupancy; -/******************************************************************** -** Solidified function: update_virtual -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Occupancy_update_virtual, /* name */ - be_nested_proto( - 10, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor_Occupancy, /* shared constants */ - be_str_weak(update_virtual), - &be_const_str_solidified, - ( &(const binstruction[16]) { /* code */ - 0x8C080101, // 0000 GETMET R2 R0 K1 - 0x5C100200, // 0001 MOVE R4 R1 - 0x58140002, // 0002 LDCONST R5 K2 - 0x88180100, // 0003 GETMBR R6 R0 K0 - 0x601C0017, // 0004 GETGBL R7 G23 - 0x54220405, // 0005 LDINT R8 1030 - 0x58240003, // 0006 LDCONST R9 K3 - 0x7C080E00, // 0007 CALL R2 7 - 0x90020002, // 0008 SETMBR R0 K0 R2 - 0x60080003, // 0009 GETGBL R2 G3 - 0x5C0C0000, // 000A MOVE R3 R0 - 0x7C080200, // 000B CALL R2 1 - 0x8C080504, // 000C GETMET R2 R2 K4 - 0x5C100200, // 000D MOVE R4 R1 - 0x7C080400, // 000E CALL R2 2 - 0x80000000, // 000F RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: read_attribute ********************************************************************/ @@ -94,40 +52,40 @@ be_local_closure(class_Matter_Plugin_Sensor_Occupancy_read_attribute, /* name be_str_weak(read_attribute), &be_const_str_solidified, ( &(const binstruction[39]) { /* code */ - 0xB8120A00, // 0000 GETNGBL R4 K5 - 0x88100906, // 0001 GETMBR R4 R4 K6 - 0x88140507, // 0002 GETMBR R5 R2 K7 - 0x88180508, // 0003 GETMBR R6 R2 K8 + 0xB8120000, // 0000 GETNGBL R4 K0 + 0x88100901, // 0001 GETMBR R4 R4 K1 + 0x88140502, // 0002 GETMBR R5 R2 K2 + 0x88180503, // 0003 GETMBR R6 R2 K3 0x541E0405, // 0004 LDINT R7 1030 0x1C1C0A07, // 0005 EQ R7 R5 R7 0x781E0016, // 0006 JMPF R7 #001E - 0x1C1C0D03, // 0007 EQ R7 R6 K3 + 0x1C1C0D04, // 0007 EQ R7 R6 K4 0x781E0005, // 0008 JMPF R7 #000F - 0x8C1C0709, // 0009 GETMET R7 R3 K9 - 0x8824090A, // 000A GETMBR R9 R4 K10 - 0x88280100, // 000B GETMBR R10 R0 K0 + 0x8C1C0705, // 0009 GETMET R7 R3 K5 + 0x88240906, // 000A GETMBR R9 R4 K6 + 0x88280107, // 000B GETMBR R10 R0 K7 0x7C1C0600, // 000C CALL R7 3 0x80040E00, // 000D RET 1 R7 0x7002000E, // 000E JMP #001E - 0x1C1C0D0B, // 000F EQ R7 R6 K11 + 0x1C1C0D08, // 000F EQ R7 R6 K8 0x781E0005, // 0010 JMPF R7 #0017 - 0x8C1C070C, // 0011 GETMET R7 R3 K12 - 0x8824090A, // 0012 GETMBR R9 R4 K10 - 0x5828000D, // 0013 LDCONST R10 K13 + 0x8C1C0709, // 0011 GETMET R7 R3 K9 + 0x88240906, // 0012 GETMBR R9 R4 K6 + 0x5828000A, // 0013 LDCONST R10 K10 0x7C1C0600, // 0014 CALL R7 3 0x80040E00, // 0015 RET 1 R7 0x70020006, // 0016 JMP #001E - 0x1C1C0D0E, // 0017 EQ R7 R6 K14 + 0x1C1C0D0B, // 0017 EQ R7 R6 K11 0x781E0004, // 0018 JMPF R7 #001E - 0x8C1C070C, // 0019 GETMET R7 R3 K12 - 0x8824090A, // 001A GETMBR R9 R4 K10 - 0x58280003, // 001B LDCONST R10 K3 + 0x8C1C0709, // 0019 GETMET R7 R3 K9 + 0x88240906, // 001A GETMBR R9 R4 K6 + 0x58280004, // 001B LDCONST R10 K4 0x7C1C0600, // 001C CALL R7 3 0x80040E00, // 001D RET 1 R7 0x601C0003, // 001E GETGBL R7 G3 0x5C200000, // 001F MOVE R8 R0 0x7C1C0200, // 0020 CALL R7 1 - 0x8C1C0F0F, // 0021 GETMET R7 R7 K15 + 0x8C1C0F0C, // 0021 GETMET R7 R7 K12 0x5C240200, // 0022 MOVE R9 R1 0x5C280400, // 0023 MOVE R10 R2 0x5C2C0600, // 0024 MOVE R11 R3 @@ -156,15 +114,15 @@ be_local_closure(class_Matter_Plugin_Sensor_Occupancy_web_values, /* name */ be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[13]) { /* code */ - 0xA4062000, // 0000 IMPORT R1 K16 - 0x8C080111, // 0001 GETMET R2 R0 K17 + 0xA4061A00, // 0000 IMPORT R1 K13 + 0x8C08010E, // 0001 GETMET R2 R0 K14 0x7C080200, // 0002 CALL R2 1 - 0x8C080312, // 0003 GETMET R2 R1 K18 + 0x8C08030F, // 0003 GETMET R2 R1 K15 0x60100018, // 0004 GETGBL R4 G24 - 0x58140013, // 0005 LDCONST R5 K19 - 0x88180100, // 0006 GETMBR R6 R0 K0 - 0x8C1C0114, // 0007 GETMET R7 R0 K20 - 0x88240115, // 0008 GETMBR R9 R0 K21 + 0x58140010, // 0005 LDCONST R5 K16 + 0x88180107, // 0006 GETMBR R6 R0 K7 + 0x8C1C0111, // 0007 GETMET R7 R0 K17 + 0x88240112, // 0008 GETMBR R9 R0 K18 0x7C1C0400, // 0009 CALL R7 2 0x7C100600, // 000A CALL R4 3 0x7C080400, // 000B CALL R2 2 @@ -192,25 +150,25 @@ be_local_closure(class_Matter_Plugin_Sensor_Occupancy_web_values_prefix, /* na be_str_weak(web_values_prefix), &be_const_str_solidified, ( &(const binstruction[22]) { /* code */ - 0xA4062000, // 0000 IMPORT R1 K16 - 0x8C080116, // 0001 GETMET R2 R0 K22 + 0xA4061A00, // 0000 IMPORT R1 K13 + 0x8C080113, // 0001 GETMET R2 R0 K19 0x7C080200, // 0002 CALL R2 1 0x5C0C0400, // 0003 MOVE R3 R2 0x740E0004, // 0004 JMPT R3 #000A 0x600C0008, // 0005 GETGBL R3 G8 - 0x88100100, // 0006 GETMBR R4 R0 K0 + 0x88100107, // 0006 GETMBR R4 R0 K7 0x7C0C0200, // 0007 CALL R3 1 - 0x000E2E03, // 0008 ADD R3 K23 R3 + 0x000E2803, // 0008 ADD R3 K20 R3 0x5C080600, // 0009 MOVE R2 R3 - 0x8C0C0312, // 000A GETMET R3 R1 K18 + 0x8C0C030F, // 000A GETMET R3 R1 K15 0x60140018, // 000B GETGBL R5 G24 - 0x88180118, // 000C GETMBR R6 R0 K24 + 0x88180115, // 000C GETMBR R6 R0 K21 0x780A0003, // 000D JMPF R2 #0012 - 0x8C1C0319, // 000E GETMET R7 R1 K25 + 0x8C1C0316, // 000E GETMET R7 R1 K22 0x5C240400, // 000F MOVE R9 R2 0x7C1C0400, // 0010 CALL R7 2 0x70020000, // 0011 JMP #0013 - 0x581C001A, // 0012 LDCONST R7 K26 + 0x581C0017, // 0012 LDCONST R7 K23 0x7C140400, // 0013 CALL R5 2 0x7C0C0400, // 0014 CALL R3 2 0x80000000, // 0015 RET 0 @@ -237,9 +195,9 @@ be_local_closure(class_Matter_Plugin_Sensor_Occupancy_value_updated, /* name * be_str_weak(value_updated), &be_const_str_solidified, ( &(const binstruction[ 5]) { /* code */ - 0x8C04011B, // 0000 GETMET R1 R0 K27 + 0x8C040118, // 0000 GETMET R1 R0 K24 0x540E0405, // 0001 LDINT R3 1030 - 0x58100003, // 0002 LDCONST R4 K3 + 0x58100004, // 0002 LDCONST R4 K4 0x7C040600, // 0003 CALL R1 3 0x80000000, // 0004 RET 0 }) @@ -257,9 +215,13 @@ be_local_class(Matter_Plugin_Sensor_Occupancy, &be_class_Matter_Plugin_Sensor_Boolean, be_nested_map(10, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(update_virtual, 6), be_const_closure(class_Matter_Plugin_Sensor_Occupancy_update_virtual_closure) }, + { 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(263, -1), be_const_int(2) }, + })) ) } )) }, { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Occupancy) }, - { be_const_key_weak(read_attribute, 5), be_const_closure(class_Matter_Plugin_Sensor_Occupancy_read_attribute_closure) }, + { be_const_key_weak(read_attribute, 6), be_const_closure(class_Matter_Plugin_Sensor_Occupancy_read_attribute_closure) }, { 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[]) { @@ -275,12 +237,8 @@ be_local_class(Matter_Plugin_Sensor_Occupancy, { be_const_key_int(1030, 1), be_const_bytes_instance(000000010002FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(29, 0), be_const_bytes_instance(0000000100020003FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, + { be_const_key_weak(JSON_NAME, -1), be_nested_str_weak(Occupancy) }, { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Sensor_Occupancy_web_values_closure) }, - { 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(263, -1), be_const_int(2) }, - })) ) } )) }, { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Sensor_Occupancy_web_values_prefix_closure) }, { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_Occupancy_value_updated_closure) }, { be_const_key_weak(TYPE, 3), be_nested_str_weak(occupancy) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_OnOff.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_OnOff.h index 527cb8b1f..82e516422 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_OnOff.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_OnOff.h @@ -5,71 +5,23 @@ #include "be_constobj.h" // compact class 'Matter_Plugin_Sensor_OnOff' ktab size: 12, total: 14 (saved 16 bytes) static const bvalue be_ktab_class_Matter_Plugin_Sensor_OnOff[12] = { - /* 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_nested_str_weak(update_shadow_lazy), - /* K5 */ be_const_int(0), - /* K6 */ be_nested_str_weak(set), - /* K7 */ be_nested_str_weak(BOOL), - /* K8 */ be_nested_str_weak(shadow_bool_value), - /* K9 */ be_nested_str_weak(read_attribute), - /* K10 */ be_nested_str_weak(_X2C_X22OnOff_X22_X3A_X25s), + /* K0 */ be_nested_str_weak(_X2C_X22OnOff_X22_X3A_X25s), + /* K1 */ be_nested_str_weak(shadow_bool_value), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(TLV), + /* K4 */ be_nested_str_weak(cluster), + /* K5 */ be_nested_str_weak(attribute), + /* K6 */ be_nested_str_weak(update_shadow_lazy), + /* K7 */ be_const_int(0), + /* K8 */ be_nested_str_weak(set), + /* K9 */ be_nested_str_weak(BOOL), + /* K10 */ be_nested_str_weak(read_attribute), /* K11 */ be_nested_str_weak(attribute_updated), }; extern const bclass be_class_Matter_Plugin_Sensor_OnOff; -/******************************************************************** -** Solidified function: read_attribute -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_OnOff_read_attribute, /* name */ - be_nested_proto( - 12, /* nstack */ - 4, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor_OnOff, /* shared constants */ - be_str_weak(read_attribute), - &be_const_str_solidified, - ( &(const binstruction[25]) { /* code */ - 0xB8120000, // 0000 GETNGBL R4 K0 - 0x88100901, // 0001 GETMBR R4 R4 K1 - 0x88140502, // 0002 GETMBR R5 R2 K2 - 0x88180503, // 0003 GETMBR R6 R2 K3 - 0x541E0005, // 0004 LDINT R7 6 - 0x1C1C0A07, // 0005 EQ R7 R5 R7 - 0x781E0008, // 0006 JMPF R7 #0010 - 0x8C1C0104, // 0007 GETMET R7 R0 K4 - 0x7C1C0200, // 0008 CALL R7 1 - 0x1C1C0D05, // 0009 EQ R7 R6 K5 - 0x781E0004, // 000A JMPF R7 #0010 - 0x8C1C0706, // 000B GETMET R7 R3 K6 - 0x88240907, // 000C GETMBR R9 R4 K7 - 0x88280108, // 000D GETMBR R10 R0 K8 - 0x7C1C0600, // 000E CALL R7 3 - 0x80040E00, // 000F RET 1 R7 - 0x601C0003, // 0010 GETGBL R7 G3 - 0x5C200000, // 0011 MOVE R8 R0 - 0x7C1C0200, // 0012 CALL R7 1 - 0x8C1C0F09, // 0013 GETMET R7 R7 K9 - 0x5C240200, // 0014 MOVE R9 R1 - 0x5C280400, // 0015 MOVE R10 R2 - 0x5C2C0600, // 0016 MOVE R11 R3 - 0x7C1C0800, // 0017 CALL R7 4 - 0x80040E00, // 0018 RET 1 R7 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: append_state_json ********************************************************************/ @@ -88,9 +40,9 @@ be_local_closure(class_Matter_Plugin_Sensor_OnOff_append_state_json, /* name * &be_const_str_solidified, ( &(const binstruction[ 7]) { /* code */ 0x60040018, // 0000 GETGBL R1 G24 - 0x5808000A, // 0001 LDCONST R2 K10 + 0x58080000, // 0001 LDCONST R2 K0 0x600C0009, // 0002 GETGBL R3 G9 - 0x88100108, // 0003 GETMBR R4 R0 K8 + 0x88100101, // 0003 GETMBR R4 R0 K1 0x7C0C0200, // 0004 CALL R3 1 0x7C040400, // 0005 CALL R1 2 0x80040200, // 0006 RET 1 R1 @@ -100,6 +52,54 @@ be_local_closure(class_Matter_Plugin_Sensor_OnOff_append_state_json, /* name * /*******************************************************************/ +/******************************************************************** +** Solidified function: read_attribute +********************************************************************/ +be_local_closure(class_Matter_Plugin_Sensor_OnOff_read_attribute, /* name */ + be_nested_proto( + 12, /* nstack */ + 4, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Plugin_Sensor_OnOff, /* shared constants */ + be_str_weak(read_attribute), + &be_const_str_solidified, + ( &(const binstruction[25]) { /* code */ + 0xB8120400, // 0000 GETNGBL R4 K2 + 0x88100903, // 0001 GETMBR R4 R4 K3 + 0x88140504, // 0002 GETMBR R5 R2 K4 + 0x88180505, // 0003 GETMBR R6 R2 K5 + 0x541E0005, // 0004 LDINT R7 6 + 0x1C1C0A07, // 0005 EQ R7 R5 R7 + 0x781E0008, // 0006 JMPF R7 #0010 + 0x8C1C0106, // 0007 GETMET R7 R0 K6 + 0x7C1C0200, // 0008 CALL R7 1 + 0x1C1C0D07, // 0009 EQ R7 R6 K7 + 0x781E0004, // 000A JMPF R7 #0010 + 0x8C1C0708, // 000B GETMET R7 R3 K8 + 0x88240909, // 000C GETMBR R9 R4 K9 + 0x88280101, // 000D GETMBR R10 R0 K1 + 0x7C1C0600, // 000E CALL R7 3 + 0x80040E00, // 000F RET 1 R7 + 0x601C0003, // 0010 GETGBL R7 G3 + 0x5C200000, // 0011 MOVE R8 R0 + 0x7C1C0200, // 0012 CALL R7 1 + 0x8C1C0F0A, // 0013 GETMET R7 R7 K10 + 0x5C240200, // 0014 MOVE R9 R1 + 0x5C280400, // 0015 MOVE R10 R2 + 0x5C2C0600, // 0016 MOVE R11 R3 + 0x7C1C0800, // 0017 CALL R7 4 + 0x80040E00, // 0018 RET 1 R7 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: value_updated ********************************************************************/ @@ -119,7 +119,7 @@ be_local_closure(class_Matter_Plugin_Sensor_OnOff_value_updated, /* name */ ( &(const binstruction[ 5]) { /* code */ 0x8C04010B, // 0000 GETMET R1 R0 K11 0x540E0005, // 0001 LDINT R3 6 - 0x58100005, // 0002 LDCONST R4 K5 + 0x58100007, // 0002 LDCONST R4 K7 0x7C040600, // 0003 CALL R1 3 0x80000000, // 0004 RET 0 }) @@ -135,9 +135,20 @@ extern const bclass be_class_Matter_Plugin_Sensor_Boolean; be_local_class(Matter_Plugin_Sensor_OnOff, 0, &be_class_Matter_Plugin_Sensor_Boolean, - be_nested_map(7, + be_nested_map(9, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(read_attribute, 1), be_const_closure(class_Matter_Plugin_Sensor_OnOff_read_attribute_closure) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(OnOff_X20Sensor) }, + { be_const_key_weak(append_state_json, 7), be_const_closure(class_Matter_Plugin_Sensor_OnOff_append_state_json_closure) }, + { 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(2128, -1), be_const_int(2) }, + })) ) } )) }, + { 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(OnOff), + })) ) } )) }, { be_const_key_weak(CLUSTERS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { be_const_map( * be_nested_map(6, ( (struct bmapnode*) &(const bmapnode[]) { @@ -148,15 +159,10 @@ be_local_class(Matter_Plugin_Sensor_OnOff, { be_const_key_int(4, -1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(29, 1), be_const_bytes_instance(0000000100020003FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, - { be_const_key_weak(append_state_json, -1), be_const_closure(class_Matter_Plugin_Sensor_OnOff_append_state_json_closure) }, - { be_const_key_weak(TYPES, 6), 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(2128, -1), be_const_int(2) }, - })) ) } )) }, - { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_OnOff_value_updated_closure) }, - { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(OnOff_X20Sensor) }, + { be_const_key_weak(JSON_NAME, -1), be_nested_str_weak(OnOff) }, + { be_const_key_weak(read_attribute, -1), be_const_closure(class_Matter_Plugin_Sensor_OnOff_read_attribute_closure) }, { be_const_key_weak(TYPE, -1), be_nested_str_weak(onoff) }, + { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_OnOff_value_updated_closure) }, })), be_str_weak(Matter_Plugin_Sensor_OnOff) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Rain.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Rain.h index 23477d3f8..588eff2f7 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Rain.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Rain.h @@ -3,76 +3,34 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_Rain' ktab size: 24, total: 31 (saved 56 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_Rain[24] = { - /* K0 */ be_nested_str_weak(shadow_bool_value), - /* K1 */ be_nested_str_weak(_parse_update_virtual), - /* K2 */ be_nested_str_weak(Rain), - /* K3 */ be_const_int(0), - /* K4 */ be_nested_str_weak(update_virtual), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(TLV), - /* K7 */ be_nested_str_weak(cluster), - /* K8 */ be_nested_str_weak(attribute), - /* K9 */ be_nested_str_weak(set), - /* K10 */ be_nested_str_weak(BOOL), - /* K11 */ be_nested_str_weak(read_attribute), - /* K12 */ be_nested_str_weak(webserver), - /* K13 */ be_nested_str_weak(web_values_prefix), - /* K14 */ be_nested_str_weak(content_send), - /* K15 */ be_nested_str_weak(Rain_X25i_X20_X25s), - /* K16 */ be_nested_str_weak(tasmota_switch_index), - /* K17 */ be_nested_str_weak(web_value_onoff), - /* K18 */ be_nested_str_weak(get_name), - /* K19 */ be_nested_str_weak(Switch), - /* K20 */ be_nested_str_weak(PREFIX), - /* K21 */ be_nested_str_weak(html_escape), - /* K22 */ be_nested_str_weak(), - /* K23 */ be_nested_str_weak(attribute_updated), +// compact class 'Matter_Plugin_Sensor_Rain' ktab size: 21, total: 26 (saved 40 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_Rain[21] = { + /* 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(set), + /* K6 */ be_nested_str_weak(BOOL), + /* K7 */ be_nested_str_weak(shadow_bool_value), + /* K8 */ be_nested_str_weak(read_attribute), + /* K9 */ be_nested_str_weak(webserver), + /* K10 */ be_nested_str_weak(web_values_prefix), + /* K11 */ be_nested_str_weak(content_send), + /* K12 */ be_nested_str_weak(Rain_X25i_X20_X25s), + /* K13 */ be_nested_str_weak(tasmota_switch_index), + /* K14 */ be_nested_str_weak(web_value_onoff), + /* K15 */ be_nested_str_weak(get_name), + /* K16 */ be_nested_str_weak(Switch), + /* K17 */ be_nested_str_weak(PREFIX), + /* K18 */ be_nested_str_weak(html_escape), + /* K19 */ be_nested_str_weak(), + /* K20 */ be_nested_str_weak(attribute_updated), }; extern const bclass be_class_Matter_Plugin_Sensor_Rain; -/******************************************************************** -** Solidified function: update_virtual -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Rain_update_virtual, /* name */ - be_nested_proto( - 10, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor_Rain, /* shared constants */ - be_str_weak(update_virtual), - &be_const_str_solidified, - ( &(const binstruction[16]) { /* code */ - 0x8C080101, // 0000 GETMET R2 R0 K1 - 0x5C100200, // 0001 MOVE R4 R1 - 0x58140002, // 0002 LDCONST R5 K2 - 0x88180100, // 0003 GETMBR R6 R0 K0 - 0x601C0017, // 0004 GETGBL R7 G23 - 0x54220044, // 0005 LDINT R8 69 - 0x58240003, // 0006 LDCONST R9 K3 - 0x7C080E00, // 0007 CALL R2 7 - 0x90020002, // 0008 SETMBR R0 K0 R2 - 0x60080003, // 0009 GETGBL R2 G3 - 0x5C0C0000, // 000A MOVE R3 R0 - 0x7C080200, // 000B CALL R2 1 - 0x8C080504, // 000C GETMET R2 R2 K4 - 0x5C100200, // 000D MOVE R4 R1 - 0x7C080400, // 000E CALL R2 2 - 0x80000000, // 000F RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: read_attribute ********************************************************************/ @@ -90,24 +48,24 @@ be_local_closure(class_Matter_Plugin_Sensor_Rain_read_attribute, /* name */ be_str_weak(read_attribute), &be_const_str_solidified, ( &(const binstruction[23]) { /* code */ - 0xB8120A00, // 0000 GETNGBL R4 K5 - 0x88100906, // 0001 GETMBR R4 R4 K6 - 0x88140507, // 0002 GETMBR R5 R2 K7 - 0x88180508, // 0003 GETMBR R6 R2 K8 + 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 0x781E0006, // 0006 JMPF R7 #000E - 0x1C1C0D03, // 0007 EQ R7 R6 K3 + 0x1C1C0D04, // 0007 EQ R7 R6 K4 0x781E0004, // 0008 JMPF R7 #000E - 0x8C1C0709, // 0009 GETMET R7 R3 K9 - 0x8824090A, // 000A GETMBR R9 R4 K10 - 0x88280100, // 000B GETMBR R10 R0 K0 + 0x8C1C0705, // 0009 GETMET R7 R3 K5 + 0x88240906, // 000A GETMBR R9 R4 K6 + 0x88280107, // 000B GETMBR R10 R0 K7 0x7C1C0600, // 000C CALL R7 3 0x80040E00, // 000D RET 1 R7 0x601C0003, // 000E GETGBL R7 G3 0x5C200000, // 000F MOVE R8 R0 0x7C1C0200, // 0010 CALL R7 1 - 0x8C1C0F0B, // 0011 GETMET R7 R7 K11 + 0x8C1C0F08, // 0011 GETMET R7 R7 K8 0x5C240200, // 0012 MOVE R9 R1 0x5C280400, // 0013 MOVE R10 R2 0x5C2C0600, // 0014 MOVE R11 R3 @@ -136,15 +94,15 @@ be_local_closure(class_Matter_Plugin_Sensor_Rain_web_values, /* name */ be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[13]) { /* code */ - 0xA4061800, // 0000 IMPORT R1 K12 - 0x8C08010D, // 0001 GETMET R2 R0 K13 + 0xA4061200, // 0000 IMPORT R1 K9 + 0x8C08010A, // 0001 GETMET R2 R0 K10 0x7C080200, // 0002 CALL R2 1 - 0x8C08030E, // 0003 GETMET R2 R1 K14 + 0x8C08030B, // 0003 GETMET R2 R1 K11 0x60100018, // 0004 GETGBL R4 G24 - 0x5814000F, // 0005 LDCONST R5 K15 - 0x88180110, // 0006 GETMBR R6 R0 K16 - 0x8C1C0111, // 0007 GETMET R7 R0 K17 - 0x88240100, // 0008 GETMBR R9 R0 K0 + 0x5814000C, // 0005 LDCONST R5 K12 + 0x8818010D, // 0006 GETMBR R6 R0 K13 + 0x8C1C010E, // 0007 GETMET R7 R0 K14 + 0x88240107, // 0008 GETMBR R9 R0 K7 0x7C1C0400, // 0009 CALL R7 2 0x7C100600, // 000A CALL R4 3 0x7C080400, // 000B CALL R2 2 @@ -172,25 +130,25 @@ be_local_closure(class_Matter_Plugin_Sensor_Rain_web_values_prefix, /* name */ be_str_weak(web_values_prefix), &be_const_str_solidified, ( &(const binstruction[22]) { /* code */ - 0xA4061800, // 0000 IMPORT R1 K12 - 0x8C080112, // 0001 GETMET R2 R0 K18 + 0xA4061200, // 0000 IMPORT R1 K9 + 0x8C08010F, // 0001 GETMET R2 R0 K15 0x7C080200, // 0002 CALL R2 1 0x5C0C0400, // 0003 MOVE R3 R2 0x740E0004, // 0004 JMPT R3 #000A 0x600C0008, // 0005 GETGBL R3 G8 - 0x88100110, // 0006 GETMBR R4 R0 K16 + 0x8810010D, // 0006 GETMBR R4 R0 K13 0x7C0C0200, // 0007 CALL R3 1 - 0x000E2603, // 0008 ADD R3 K19 R3 + 0x000E2003, // 0008 ADD R3 K16 R3 0x5C080600, // 0009 MOVE R2 R3 - 0x8C0C030E, // 000A GETMET R3 R1 K14 + 0x8C0C030B, // 000A GETMET R3 R1 K11 0x60140018, // 000B GETGBL R5 G24 - 0x88180114, // 000C GETMBR R6 R0 K20 + 0x88180111, // 000C GETMBR R6 R0 K17 0x780A0003, // 000D JMPF R2 #0012 - 0x8C1C0315, // 000E GETMET R7 R1 K21 + 0x8C1C0312, // 000E GETMET R7 R1 K18 0x5C240400, // 000F MOVE R9 R2 0x7C1C0400, // 0010 CALL R7 2 0x70020000, // 0011 JMP #0013 - 0x581C0016, // 0012 LDCONST R7 K22 + 0x581C0013, // 0012 LDCONST R7 K19 0x7C140400, // 0013 CALL R5 2 0x7C0C0400, // 0014 CALL R3 2 0x80000000, // 0015 RET 0 @@ -217,9 +175,9 @@ be_local_closure(class_Matter_Plugin_Sensor_Rain_value_updated, /* name */ be_str_weak(value_updated), &be_const_str_solidified, ( &(const binstruction[ 5]) { /* code */ - 0x8C040117, // 0000 GETMET R1 R0 K23 + 0x8C040114, // 0000 GETMET R1 R0 K20 0x540E0044, // 0001 LDINT R3 69 - 0x58100003, // 0002 LDCONST R4 K3 + 0x58100004, // 0002 LDCONST R4 K4 0x7C040600, // 0003 CALL R1 3 0x80000000, // 0004 RET 0 }) @@ -237,9 +195,13 @@ be_local_class(Matter_Plugin_Sensor_Rain, &be_class_Matter_Plugin_Sensor_Boolean, be_nested_map(10, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(update_virtual, 6), be_const_closure(class_Matter_Plugin_Sensor_Rain_update_virtual_closure) }, + { 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(68, -1), be_const_int(1) }, + })) ) } )) }, { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Rain) }, - { be_const_key_weak(read_attribute, 5), be_const_closure(class_Matter_Plugin_Sensor_Rain_read_attribute_closure) }, + { be_const_key_weak(read_attribute, 6), be_const_closure(class_Matter_Plugin_Sensor_Rain_read_attribute_closure) }, { 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[]) { @@ -255,12 +217,8 @@ be_local_class(Matter_Plugin_Sensor_Rain, { be_const_key_int(4, -1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(29, 0), be_const_bytes_instance(0000000100020003FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, + { be_const_key_weak(JSON_NAME, -1), be_nested_str_weak(Rain) }, { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Sensor_Rain_web_values_closure) }, - { 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(68, -1), be_const_int(1) }, - })) ) } )) }, { be_const_key_weak(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Sensor_Rain_web_values_prefix_closure) }, { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_Rain_value_updated_closure) }, { be_const_key_weak(TYPE, 3), be_nested_str_weak(rain) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Waterleak.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Waterleak.h index c6e4fa7ed..8a8687e8f 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Waterleak.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_3_Sensor_Waterleak.h @@ -3,76 +3,34 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Plugin_Sensor_Waterleak' ktab size: 24, total: 31 (saved 56 bytes) -static const bvalue be_ktab_class_Matter_Plugin_Sensor_Waterleak[24] = { - /* K0 */ be_nested_str_weak(shadow_bool_value), - /* K1 */ be_nested_str_weak(_parse_update_virtual), - /* K2 */ be_nested_str_weak(Waterleak), - /* K3 */ be_const_int(0), - /* K4 */ be_nested_str_weak(update_virtual), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(TLV), - /* K7 */ be_nested_str_weak(cluster), - /* K8 */ be_nested_str_weak(attribute), - /* K9 */ be_nested_str_weak(set), - /* K10 */ be_nested_str_weak(BOOL), - /* K11 */ be_nested_str_weak(read_attribute), - /* K12 */ be_nested_str_weak(webserver), - /* K13 */ be_nested_str_weak(web_values_prefix), - /* K14 */ be_nested_str_weak(content_send), - /* K15 */ be_nested_str_weak(Waterleak_X25i_X20_X25s), - /* K16 */ be_nested_str_weak(tasmota_switch_index), - /* K17 */ be_nested_str_weak(web_value_onoff), - /* K18 */ be_nested_str_weak(get_name), - /* K19 */ be_nested_str_weak(Switch), - /* K20 */ be_nested_str_weak(PREFIX), - /* K21 */ be_nested_str_weak(html_escape), - /* K22 */ be_nested_str_weak(), - /* K23 */ be_nested_str_weak(attribute_updated), +// compact class 'Matter_Plugin_Sensor_Waterleak' ktab size: 21, total: 26 (saved 40 bytes) +static const bvalue be_ktab_class_Matter_Plugin_Sensor_Waterleak[21] = { + /* 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(set), + /* K6 */ be_nested_str_weak(BOOL), + /* K7 */ be_nested_str_weak(shadow_bool_value), + /* K8 */ be_nested_str_weak(read_attribute), + /* K9 */ be_nested_str_weak(webserver), + /* K10 */ be_nested_str_weak(web_values_prefix), + /* K11 */ be_nested_str_weak(content_send), + /* K12 */ be_nested_str_weak(Waterleak_X25i_X20_X25s), + /* K13 */ be_nested_str_weak(tasmota_switch_index), + /* K14 */ be_nested_str_weak(web_value_onoff), + /* K15 */ be_nested_str_weak(get_name), + /* K16 */ be_nested_str_weak(Switch), + /* K17 */ be_nested_str_weak(PREFIX), + /* K18 */ be_nested_str_weak(html_escape), + /* K19 */ be_nested_str_weak(), + /* K20 */ be_nested_str_weak(attribute_updated), }; extern const bclass be_class_Matter_Plugin_Sensor_Waterleak; -/******************************************************************** -** Solidified function: update_virtual -********************************************************************/ -be_local_closure(class_Matter_Plugin_Sensor_Waterleak_update_virtual, /* name */ - be_nested_proto( - 10, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Plugin_Sensor_Waterleak, /* shared constants */ - be_str_weak(update_virtual), - &be_const_str_solidified, - ( &(const binstruction[16]) { /* code */ - 0x8C080101, // 0000 GETMET R2 R0 K1 - 0x5C100200, // 0001 MOVE R4 R1 - 0x58140002, // 0002 LDCONST R5 K2 - 0x88180100, // 0003 GETMBR R6 R0 K0 - 0x601C0017, // 0004 GETGBL R7 G23 - 0x54220044, // 0005 LDINT R8 69 - 0x58240003, // 0006 LDCONST R9 K3 - 0x7C080E00, // 0007 CALL R2 7 - 0x90020002, // 0008 SETMBR R0 K0 R2 - 0x60080003, // 0009 GETGBL R2 G3 - 0x5C0C0000, // 000A MOVE R3 R0 - 0x7C080200, // 000B CALL R2 1 - 0x8C080504, // 000C GETMET R2 R2 K4 - 0x5C100200, // 000D MOVE R4 R1 - 0x7C080400, // 000E CALL R2 2 - 0x80000000, // 000F RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: read_attribute ********************************************************************/ @@ -90,24 +48,24 @@ be_local_closure(class_Matter_Plugin_Sensor_Waterleak_read_attribute, /* name be_str_weak(read_attribute), &be_const_str_solidified, ( &(const binstruction[23]) { /* code */ - 0xB8120A00, // 0000 GETNGBL R4 K5 - 0x88100906, // 0001 GETMBR R4 R4 K6 - 0x88140507, // 0002 GETMBR R5 R2 K7 - 0x88180508, // 0003 GETMBR R6 R2 K8 + 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 0x781E0006, // 0006 JMPF R7 #000E - 0x1C1C0D03, // 0007 EQ R7 R6 K3 + 0x1C1C0D04, // 0007 EQ R7 R6 K4 0x781E0004, // 0008 JMPF R7 #000E - 0x8C1C0709, // 0009 GETMET R7 R3 K9 - 0x8824090A, // 000A GETMBR R9 R4 K10 - 0x88280100, // 000B GETMBR R10 R0 K0 + 0x8C1C0705, // 0009 GETMET R7 R3 K5 + 0x88240906, // 000A GETMBR R9 R4 K6 + 0x88280107, // 000B GETMBR R10 R0 K7 0x7C1C0600, // 000C CALL R7 3 0x80040E00, // 000D RET 1 R7 0x601C0003, // 000E GETGBL R7 G3 0x5C200000, // 000F MOVE R8 R0 0x7C1C0200, // 0010 CALL R7 1 - 0x8C1C0F0B, // 0011 GETMET R7 R7 K11 + 0x8C1C0F08, // 0011 GETMET R7 R7 K8 0x5C240200, // 0012 MOVE R9 R1 0x5C280400, // 0013 MOVE R10 R2 0x5C2C0600, // 0014 MOVE R11 R3 @@ -136,15 +94,15 @@ be_local_closure(class_Matter_Plugin_Sensor_Waterleak_web_values, /* name */ be_str_weak(web_values), &be_const_str_solidified, ( &(const binstruction[13]) { /* code */ - 0xA4061800, // 0000 IMPORT R1 K12 - 0x8C08010D, // 0001 GETMET R2 R0 K13 + 0xA4061200, // 0000 IMPORT R1 K9 + 0x8C08010A, // 0001 GETMET R2 R0 K10 0x7C080200, // 0002 CALL R2 1 - 0x8C08030E, // 0003 GETMET R2 R1 K14 + 0x8C08030B, // 0003 GETMET R2 R1 K11 0x60100018, // 0004 GETGBL R4 G24 - 0x5814000F, // 0005 LDCONST R5 K15 - 0x88180110, // 0006 GETMBR R6 R0 K16 - 0x8C1C0111, // 0007 GETMET R7 R0 K17 - 0x88240100, // 0008 GETMBR R9 R0 K0 + 0x5814000C, // 0005 LDCONST R5 K12 + 0x8818010D, // 0006 GETMBR R6 R0 K13 + 0x8C1C010E, // 0007 GETMET R7 R0 K14 + 0x88240107, // 0008 GETMBR R9 R0 K7 0x7C1C0400, // 0009 CALL R7 2 0x7C100600, // 000A CALL R4 3 0x7C080400, // 000B CALL R2 2 @@ -172,25 +130,25 @@ be_local_closure(class_Matter_Plugin_Sensor_Waterleak_web_values_prefix, /* na be_str_weak(web_values_prefix), &be_const_str_solidified, ( &(const binstruction[22]) { /* code */ - 0xA4061800, // 0000 IMPORT R1 K12 - 0x8C080112, // 0001 GETMET R2 R0 K18 + 0xA4061200, // 0000 IMPORT R1 K9 + 0x8C08010F, // 0001 GETMET R2 R0 K15 0x7C080200, // 0002 CALL R2 1 0x5C0C0400, // 0003 MOVE R3 R2 0x740E0004, // 0004 JMPT R3 #000A 0x600C0008, // 0005 GETGBL R3 G8 - 0x88100110, // 0006 GETMBR R4 R0 K16 + 0x8810010D, // 0006 GETMBR R4 R0 K13 0x7C0C0200, // 0007 CALL R3 1 - 0x000E2603, // 0008 ADD R3 K19 R3 + 0x000E2003, // 0008 ADD R3 K16 R3 0x5C080600, // 0009 MOVE R2 R3 - 0x8C0C030E, // 000A GETMET R3 R1 K14 + 0x8C0C030B, // 000A GETMET R3 R1 K11 0x60140018, // 000B GETGBL R5 G24 - 0x88180114, // 000C GETMBR R6 R0 K20 + 0x88180111, // 000C GETMBR R6 R0 K17 0x780A0003, // 000D JMPF R2 #0012 - 0x8C1C0315, // 000E GETMET R7 R1 K21 + 0x8C1C0312, // 000E GETMET R7 R1 K18 0x5C240400, // 000F MOVE R9 R2 0x7C1C0400, // 0010 CALL R7 2 0x70020000, // 0011 JMP #0013 - 0x581C0016, // 0012 LDCONST R7 K22 + 0x581C0013, // 0012 LDCONST R7 K19 0x7C140400, // 0013 CALL R5 2 0x7C0C0400, // 0014 CALL R3 2 0x80000000, // 0015 RET 0 @@ -217,9 +175,9 @@ be_local_closure(class_Matter_Plugin_Sensor_Waterleak_value_updated, /* name * be_str_weak(value_updated), &be_const_str_solidified, ( &(const binstruction[ 5]) { /* code */ - 0x8C040117, // 0000 GETMET R1 R0 K23 + 0x8C040114, // 0000 GETMET R1 R0 K20 0x540E0044, // 0001 LDINT R3 69 - 0x58100003, // 0002 LDCONST R4 K3 + 0x58100004, // 0002 LDCONST R4 K4 0x7C040600, // 0003 CALL R1 3 0x80000000, // 0004 RET 0 }) @@ -237,9 +195,13 @@ be_local_class(Matter_Plugin_Sensor_Waterleak, &be_class_Matter_Plugin_Sensor_Boolean, be_nested_map(10, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(update_virtual, 6), be_const_closure(class_Matter_Plugin_Sensor_Waterleak_update_virtual_closure) }, + { 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(DISPLAY_NAME, -1), be_nested_str_weak(Waterleak) }, - { be_const_key_weak(read_attribute, 5), be_const_closure(class_Matter_Plugin_Sensor_Waterleak_read_attribute_closure) }, + { be_const_key_weak(read_attribute, 6), be_const_closure(class_Matter_Plugin_Sensor_Waterleak_read_attribute_closure) }, { 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[]) { @@ -255,12 +217,8 @@ be_local_class(Matter_Plugin_Sensor_Waterleak, { be_const_key_int(4, -1), be_const_bytes_instance(0000FFF8FFF9FFFAFFFBFFFCFFFD) }, { be_const_key_int(29, 0), be_const_bytes_instance(0000000100020003FFF8FFF9FFFAFFFBFFFCFFFD) }, })) ) } )) }, + { be_const_key_weak(JSON_NAME, -1), be_nested_str_weak(Waterleak) }, { be_const_key_weak(web_values, -1), be_const_closure(class_Matter_Plugin_Sensor_Waterleak_web_values_closure) }, - { 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(web_values_prefix, -1), be_const_closure(class_Matter_Plugin_Sensor_Waterleak_web_values_prefix_closure) }, { be_const_key_weak(value_updated, -1), be_const_closure(class_Matter_Plugin_Sensor_Waterleak_value_updated_closure) }, { be_const_key_weak(TYPE, 3), be_nested_str_weak(waterleak) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Virt_Light0.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Virt_Light0.h index 6e575fcbd..759f4fe3d 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Virt_Light0.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Virt_Light0.h @@ -16,7 +16,7 @@ be_local_class(Matter_Plugin_Virt_Light0, be_nested_map(5, ( (struct bmapnode*) &(const bmapnode[]) { { be_const_key_weak(VIRTUAL, 3), be_const_bool(1) }, - { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(v_X2ELight_X200_X20On) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(v_X2ELight_X200_X20OnOff) }, { be_const_key_weak(TYPE, -1), be_nested_str_weak(v_light0) }, { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(_Not_X20used_) }, { be_const_key_weak(ARG, 2), be_nested_str_weak() }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light0.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light0.h new file mode 100644 index 000000000..6cfbfb7fd --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light0.h @@ -0,0 +1,58 @@ +/* Solidification of Matter_Plugin_9_Zigbee_Light0.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_Plugin_Zigbee_Light0; + +/******************************************************************** +** Solidified function: +********************************************************************/ +be_local_closure(class_Matter_Plugin_Zigbee_Light0__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 */ + 0x60040008, // 0000 GETGBL R1 G8 + 0x5C080000, // 0001 MOVE R2 R0 + 0x7C040200, // 0002 CALL R1 1 + 0x80040200, // 0003 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_Plugin_Zigbee_Light0 +********************************************************************/ +extern const bclass be_class_Matter_Plugin_Light0; +be_local_class(Matter_Plugin_Zigbee_Light0, + 1, + &be_class_Matter_Plugin_Light0, + be_nested_map(9, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(ARG, 2), be_nested_str_weak(zigbee_device) }, + { be_const_key_weak(ARG_TYPE, 8), be_const_static_closure(class_Matter_Plugin_Zigbee_Light0__X3Clambda_X3E_closure) }, + { be_const_key_weak(ARG_HINT, 7), be_nested_str_weak(Device) }, + { be_const_key_weak(ZIGBEE, 6), be_const_bool(1) }, + { be_const_key_weak(ZIGBEE_NAME, -1), be_nested_str_weak(Power) }, + { be_const_key_weak(VIRTUAL, -1), be_const_bool(1) }, + { be_const_key_weak(zigbee_mapper, -1), be_const_var(0) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Zig_X20Light_X200_X20OnOff) }, + { be_const_key_weak(TYPE, -1), be_nested_str_weak(z_light0) }, + })), + be_str_weak(Matter_Plugin_Zigbee_Light0) +); +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light1.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light1.h new file mode 100644 index 000000000..92613b70c --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light1.h @@ -0,0 +1,57 @@ +/* Solidification of Matter_Plugin_9_Zigbee_Light1.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_Plugin_Zigbee_Light1; + +/******************************************************************** +** Solidified function: +********************************************************************/ +be_local_closure(class_Matter_Plugin_Zigbee_Light1__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 */ + 0x60040008, // 0000 GETGBL R1 G8 + 0x5C080000, // 0001 MOVE R2 R0 + 0x7C040200, // 0002 CALL R1 1 + 0x80040200, // 0003 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_Plugin_Zigbee_Light1 +********************************************************************/ +extern const bclass be_class_Matter_Plugin_Light1; +be_local_class(Matter_Plugin_Zigbee_Light1, + 1, + &be_class_Matter_Plugin_Light1, + be_nested_map(8, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(class_Matter_Plugin_Zigbee_Light1__X3Clambda_X3E_closure) }, + { be_const_key_weak(ARG_HINT, 2), be_nested_str_weak(Device) }, + { be_const_key_weak(zigbee_mapper, -1), be_const_var(0) }, + { be_const_key_weak(ZIGBEE, -1), be_const_bool(1) }, + { be_const_key_weak(VIRTUAL, -1), be_const_bool(1) }, + { be_const_key_weak(TYPE, 6), be_nested_str_weak(z_light1) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Zig_X20Light_X201_X20Dimmer) }, + { be_const_key_weak(ARG, -1), be_nested_str_weak(zigbee_device) }, + })), + be_str_weak(Matter_Plugin_Zigbee_Light1) +); +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light2.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light2.h new file mode 100644 index 000000000..39d892784 --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Light2.h @@ -0,0 +1,57 @@ +/* Solidification of Matter_Plugin_9_Zigbee_Light2.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_Plugin_Zigbee_Light2; + +/******************************************************************** +** Solidified function: +********************************************************************/ +be_local_closure(class_Matter_Plugin_Zigbee_Light2__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 */ + 0x60040008, // 0000 GETGBL R1 G8 + 0x5C080000, // 0001 MOVE R2 R0 + 0x7C040200, // 0002 CALL R1 1 + 0x80040200, // 0003 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_Plugin_Zigbee_Light2 +********************************************************************/ +extern const bclass be_class_Matter_Plugin_Light2; +be_local_class(Matter_Plugin_Zigbee_Light2, + 1, + &be_class_Matter_Plugin_Light2, + be_nested_map(8, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(class_Matter_Plugin_Zigbee_Light2__X3Clambda_X3E_closure) }, + { be_const_key_weak(ARG_HINT, 2), be_nested_str_weak(Device) }, + { be_const_key_weak(zigbee_mapper, -1), be_const_var(0) }, + { be_const_key_weak(ZIGBEE, -1), be_const_bool(1) }, + { be_const_key_weak(VIRTUAL, -1), be_const_bool(1) }, + { be_const_key_weak(TYPE, 6), be_nested_str_weak(z_light2) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Zig_X20Light_X202_X20CT) }, + { be_const_key_weak(ARG, -1), be_nested_str_weak(zigbee_device) }, + })), + be_str_weak(Matter_Plugin_Zigbee_Light2) +); +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Occupancy.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Occupancy.h new file mode 100644 index 000000000..d25b969ba --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_9_Zigbee_Occupancy.h @@ -0,0 +1,58 @@ +/* Solidification of Matter_Plugin_9_Zigbee_Occupancy.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_Plugin_Zigbee_Occupancy; + +/******************************************************************** +** Solidified function: +********************************************************************/ +be_local_closure(class_Matter_Plugin_Zigbee_Occupancy__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 */ + 0x60040008, // 0000 GETGBL R1 G8 + 0x5C080000, // 0001 MOVE R2 R0 + 0x7C040200, // 0002 CALL R1 1 + 0x80040200, // 0003 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_Plugin_Zigbee_Occupancy +********************************************************************/ +extern const bclass be_class_Matter_Plugin_Sensor_Occupancy; +be_local_class(Matter_Plugin_Zigbee_Occupancy, + 1, + &be_class_Matter_Plugin_Sensor_Occupancy, + be_nested_map(9, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(ARG, 2), be_nested_str_weak(zigbee_device) }, + { be_const_key_weak(ARG_TYPE, 8), be_const_static_closure(class_Matter_Plugin_Zigbee_Occupancy__X3Clambda_X3E_closure) }, + { be_const_key_weak(ARG_HINT, 7), be_nested_str_weak(Device) }, + { be_const_key_weak(ZIGBEE, 6), be_const_bool(1) }, + { be_const_key_weak(ZIGBEE_NAME, -1), be_nested_str_weak(Occupancy) }, + { be_const_key_weak(VIRTUAL, -1), be_const_bool(1) }, + { be_const_key_weak(zigbee_mapper, -1), be_const_var(0) }, + { be_const_key_weak(DISPLAY_NAME, -1), be_nested_str_weak(Zig_X20Occupancy) }, + { be_const_key_weak(TYPE, -1), be_nested_str_weak(z_occupancy) }, + })), + be_str_weak(Matter_Plugin_Zigbee_Occupancy) +); +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_z_Zigbee.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_z_Zigbee.h index f7361c409..a92918b5a 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_z_Zigbee.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_z_Zigbee.h @@ -3,34 +3,217 @@ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -// compact class 'Matter_Zigbee_Mapper' ktab size: 21, total: 32 (saved 88 bytes) -static const bvalue be_ktab_class_Matter_Zigbee_Mapper[21] = { - /* K0 */ be_nested_str_weak(zigbee), - /* K1 */ be_nested_str_weak(device_arg), - /* K2 */ be_nested_str_weak(shortaddr), - /* K3 */ be_nested_str_weak(zigbee_device), - /* K4 */ be_nested_str_weak(find), - /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20cannot_X20find_X20zigbee_X20device_X20_X27_X25s_X27), - /* K7 */ be_const_int(3), - /* K8 */ be_nested_str_weak(string), - /* K9 */ be_nested_str_weak(pi), - /* K10 */ be_nested_str_weak(ARG), - /* K11 */ be_nested_str_weak(startswith), - /* K12 */ be_nested_str_weak(0x), - /* K13 */ be_nested_str_weak(0X), - /* K14 */ be_nested_str_weak(tasmota), - /* K15 */ be_nested_str_weak(set_timer), - /* K16 */ be_nested_str_weak(resolve_zb_device), - /* K17 */ be_nested_str_weak(info), - /* K18 */ be_nested_str_weak(read_zb_info), - /* K19 */ be_nested_str_weak(MTR_X3A_X20Read_X20information_X20for_X20zigbee_X20device_X200x_X2504X), +// compact class 'Matter_Zigbee_Mapper' ktab size: 30, total: 45 (saved 120 bytes) +static const bvalue be_ktab_class_Matter_Zigbee_Mapper[30] = { + /* K0 */ be_nested_str_weak(resolve_zb_device), + /* K1 */ be_nested_str_weak(zigbee), + /* K2 */ be_nested_str_weak(find), + /* K3 */ be_nested_str_weak(shortaddr), + /* K4 */ be_nested_str_weak(info), + /* K5 */ be_nested_str_weak(Power), + /* K6 */ be_nested_str_weak(ZbSend_X20_X7B_X22Device_X22_X3A_X220x_X2504X_X22_X2C_X22Send_X22_X3A_X7B_X22Power_X22_X3A_X25i_X7D_X7D), + /* K7 */ be_nested_str_weak(Bri), + /* K8 */ be_nested_str_weak(ZbSend_X20_X7B_X22Device_X22_X3A_X220x_X2504X_X22_X2C_X22Send_X22_X3A_X7B_X22Dimmer_X22_X3A_X25i_X7D_X7D), + /* K9 */ be_nested_str_weak(CT), + /* K10 */ be_nested_str_weak(ZbSend_X20_X7B_X22Device_X22_X3A_X220x_X2504X_X22_X2C_X22Send_X22_X3A_X7B_X22CT_X22_X3A_X25i_X7D_X7D), + /* K11 */ be_nested_str_weak(tasmota), + /* K12 */ be_nested_str_weak(loglevel), + /* K13 */ be_const_int(3), + /* K14 */ be_nested_str_weak(log), + /* K15 */ be_nested_str_weak(MTR_X3A_X20_X27_X25s_X27), + /* K16 */ be_nested_str_weak(cmd), + /* K17 */ be_nested_str_weak(read_zb_info), + /* K18 */ be_nested_str_weak(MTR_X3A_X20Read_X20information_X20for_X20zigbee_X20device_X200x_X2504X), + /* K19 */ be_nested_str_weak(pi), /* K20 */ be_nested_str_weak(zigbee_received), + /* K21 */ be_nested_str_weak(device_arg), + /* K22 */ be_nested_str_weak(zigbee_device), + /* K23 */ be_nested_str_weak(MTR_X3A_X20cannot_X20find_X20zigbee_X20device_X20_X27_X25s_X27), + /* K24 */ be_nested_str_weak(string), + /* K25 */ be_nested_str_weak(ARG), + /* K26 */ be_nested_str_weak(startswith), + /* K27 */ be_nested_str_weak(0x), + /* K28 */ be_nested_str_weak(0X), + /* K29 */ be_nested_str_weak(set_timer), }; extern const bclass be_class_Matter_Zigbee_Mapper; +/******************************************************************** +** Solidified function: read_zb_info +********************************************************************/ +be_local_closure(class_Matter_Zigbee_Mapper_read_zb_info, /* name */ + be_nested_proto( + 5, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ + be_str_weak(read_zb_info), + &be_const_str_solidified, + ( &(const binstruction[14]) { /* code */ + 0x8C040100, // 0000 GETMET R1 R0 K0 + 0x7C040200, // 0001 CALL R1 1 + 0x78060009, // 0002 JMPF R1 #000D + 0xA4060200, // 0003 IMPORT R1 K1 + 0x8C080302, // 0004 GETMET R2 R1 K2 + 0x88100103, // 0005 GETMBR R4 R0 K3 + 0x7C080400, // 0006 CALL R2 2 + 0x4C0C0000, // 0007 LDNIL R3 + 0x200C0403, // 0008 NE R3 R2 R3 + 0x780E0002, // 0009 JMPF R3 #000D + 0x8C0C0504, // 000A GETMET R3 R2 K4 + 0x7C0C0200, // 000B CALL R3 1 + 0x80040600, // 000C RET 1 R3 + 0x80000000, // 000D RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: zb_single_command +********************************************************************/ +be_local_closure(class_Matter_Zigbee_Mapper_zb_single_command, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ + be_str_weak(zb_single_command), + &be_const_str_solidified, + ( &(const binstruction[48]) { /* code */ + 0x4C0C0000, // 0000 LDNIL R3 + 0x1C100305, // 0001 EQ R4 R1 K5 + 0x78120006, // 0002 JMPF R4 #000A + 0x60100018, // 0003 GETGBL R4 G24 + 0x58140006, // 0004 LDCONST R5 K6 + 0x88180103, // 0005 GETMBR R6 R0 K3 + 0x5C1C0400, // 0006 MOVE R7 R2 + 0x7C100600, // 0007 CALL R4 3 + 0x5C0C0800, // 0008 MOVE R3 R4 + 0x70020010, // 0009 JMP #001B + 0x1C100307, // 000A EQ R4 R1 K7 + 0x78120006, // 000B JMPF R4 #0013 + 0x60100018, // 000C GETGBL R4 G24 + 0x58140008, // 000D LDCONST R5 K8 + 0x88180103, // 000E GETMBR R6 R0 K3 + 0x5C1C0400, // 000F MOVE R7 R2 + 0x7C100600, // 0010 CALL R4 3 + 0x5C0C0800, // 0011 MOVE R3 R4 + 0x70020007, // 0012 JMP #001B + 0x1C100309, // 0013 EQ R4 R1 K9 + 0x78120005, // 0014 JMPF R4 #001B + 0x60100018, // 0015 GETGBL R4 G24 + 0x5814000A, // 0016 LDCONST R5 K10 + 0x88180103, // 0017 GETMBR R6 R0 K3 + 0x5C1C0400, // 0018 MOVE R7 R2 + 0x7C100600, // 0019 CALL R4 3 + 0x5C0C0800, // 001A MOVE R3 R4 + 0x4C100000, // 001B LDNIL R4 + 0x20100604, // 001C NE R4 R3 R4 + 0x78120010, // 001D JMPF R4 #002F + 0xB8121600, // 001E GETNGBL R4 K11 + 0x8C10090C, // 001F GETMET R4 R4 K12 + 0x5818000D, // 0020 LDCONST R6 K13 + 0x7C100400, // 0021 CALL R4 2 + 0x78120006, // 0022 JMPF R4 #002A + 0xB8121C00, // 0023 GETNGBL R4 K14 + 0x60140018, // 0024 GETGBL R5 G24 + 0x5818000F, // 0025 LDCONST R6 K15 + 0x5C1C0600, // 0026 MOVE R7 R3 + 0x7C140400, // 0027 CALL R5 2 + 0x5818000D, // 0028 LDCONST R6 K13 + 0x7C100400, // 0029 CALL R4 2 + 0xB8121600, // 002A GETNGBL R4 K11 + 0x8C100910, // 002B GETMET R4 R4 K16 + 0x5C180600, // 002C MOVE R6 R3 + 0x501C0200, // 002D LDBOOL R7 1 0 + 0x7C100600, // 002E CALL R4 3 + 0x80000000, // 002F RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: probe_zb_values +********************************************************************/ +be_local_closure(class_Matter_Zigbee_Mapper_probe_zb_values, /* name */ + be_nested_proto( + 6, /* nstack */ + 1, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ + be_str_weak(probe_zb_values), + &be_const_str_solidified, + ( &(const binstruction[18]) { /* code */ + 0x8C040111, // 0000 GETMET R1 R0 K17 + 0x7C040200, // 0001 CALL R1 1 + 0x4C080000, // 0002 LDNIL R2 + 0x20080202, // 0003 NE R2 R1 R2 + 0x780A000B, // 0004 JMPF R2 #0011 + 0xB80A1C00, // 0005 GETNGBL R2 K14 + 0x600C0018, // 0006 GETGBL R3 G24 + 0x58100012, // 0007 LDCONST R4 K18 + 0x88140103, // 0008 GETMBR R5 R0 K3 + 0x7C0C0400, // 0009 CALL R3 2 + 0x5810000D, // 000A LDCONST R4 K13 + 0x7C080400, // 000B CALL R2 2 + 0x88080113, // 000C GETMBR R2 R0 K19 + 0x8C080514, // 000D GETMET R2 R2 K20 + 0x4C100000, // 000E LDNIL R4 + 0x5C140200, // 000F MOVE R5 R1 + 0x7C080600, // 0010 CALL R2 3 + 0x80000000, // 0011 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(class_Matter_Zigbee_Mapper_init, /* name */ + be_nested_proto( + 2, /* nstack */ + 2, /* argc */ + 10, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x90022601, // 0000 SETMBR R0 K19 R1 + 0x80000000, // 0001 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: resolve_zb_device ********************************************************************/ @@ -48,37 +231,37 @@ be_local_closure(class_Matter_Zigbee_Mapper_resolve_zb_device, /* name */ be_str_weak(resolve_zb_device), &be_const_str_solidified, ( &(const binstruction[35]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x88080101, // 0001 GETMBR R2 R0 K1 + 0xA4060200, // 0000 IMPORT R1 K1 + 0x88080115, // 0001 GETMBR R2 R0 K21 0x4C0C0000, // 0002 LDNIL R3 0x1C080403, // 0003 EQ R2 R2 R3 0x780A0001, // 0004 JMPF R2 #0007 0x50080000, // 0005 LDBOOL R2 0 0 0x80040400, // 0006 RET 1 R2 - 0x88080102, // 0007 GETMBR R2 R0 K2 + 0x88080103, // 0007 GETMBR R2 R0 K3 0x4C0C0000, // 0008 LDNIL R3 0x20080403, // 0009 NE R2 R2 R3 0x780A0001, // 000A JMPF R2 #000D 0x50080200, // 000B LDBOOL R2 1 0 0x80040400, // 000C RET 1 R2 - 0x8C080304, // 000D GETMET R2 R1 K4 - 0x88100101, // 000E GETMBR R4 R0 K1 + 0x8C080302, // 000D GETMET R2 R1 K2 + 0x88100115, // 000E GETMBR R4 R0 K21 0x7C080400, // 000F CALL R2 2 - 0x90020602, // 0010 SETMBR R0 K3 R2 - 0x88080103, // 0011 GETMBR R2 R0 K3 + 0x90022C02, // 0010 SETMBR R0 K22 R2 + 0x88080116, // 0011 GETMBR R2 R0 K22 0x780A0005, // 0012 JMPF R2 #0019 - 0x88080103, // 0013 GETMBR R2 R0 K3 - 0x88080502, // 0014 GETMBR R2 R2 K2 - 0x90020402, // 0015 SETMBR R0 K2 R2 + 0x88080116, // 0013 GETMBR R2 R0 K22 + 0x88080503, // 0014 GETMBR R2 R2 K3 + 0x90020602, // 0015 SETMBR R0 K3 R2 0x50080200, // 0016 LDBOOL R2 1 0 0x80040400, // 0017 RET 1 R2 0x70020008, // 0018 JMP #0022 - 0xB80A0A00, // 0019 GETNGBL R2 K5 + 0xB80A1C00, // 0019 GETNGBL R2 K14 0x600C0018, // 001A GETGBL R3 G24 - 0x58100006, // 001B LDCONST R4 K6 - 0x88140101, // 001C GETMBR R5 R0 K1 + 0x58100017, // 001B LDCONST R4 K23 + 0x88140115, // 001C GETMBR R5 R0 K21 0x7C0C0400, // 001D CALL R3 2 - 0x58100007, // 001E LDCONST R4 K7 + 0x5810000D, // 001E LDCONST R4 K13 0x7C080400, // 001F CALL R2 2 0x50080000, // 0020 LDBOOL R2 0 0 0x80040400, // 0021 RET 1 R2 @@ -130,39 +313,39 @@ be_local_closure(class_Matter_Zigbee_Mapper_parse_configuration, /* name */ be_str_weak(parse_configuration), &be_const_str_solidified, ( &(const binstruction[38]) { /* code */ - 0xA40A0000, // 0000 IMPORT R2 K0 - 0xA40E1000, // 0001 IMPORT R3 K8 - 0x8C100304, // 0002 GETMET R4 R1 K4 - 0x88180109, // 0003 GETMBR R6 R0 K9 - 0x88180D0A, // 0004 GETMBR R6 R6 K10 + 0xA40A0200, // 0000 IMPORT R2 K1 + 0xA40E3000, // 0001 IMPORT R3 K24 + 0x8C100302, // 0002 GETMET R4 R1 K2 + 0x88180113, // 0003 GETMBR R6 R0 K19 + 0x88180D19, // 0004 GETMBR R6 R6 K25 0x4C1C0000, // 0005 LDNIL R7 0x7C100600, // 0006 CALL R4 3 - 0x90020204, // 0007 SETMBR R0 K1 R4 + 0x90022A04, // 0007 SETMBR R0 K21 R4 0x60100004, // 0008 GETGBL R4 G4 - 0x88140101, // 0009 GETMBR R5 R0 K1 + 0x88140115, // 0009 GETMBR R5 R0 K21 0x7C100200, // 000A CALL R4 1 - 0x1C100908, // 000B EQ R4 R4 K8 + 0x1C100918, // 000B EQ R4 R4 K24 0x7812000D, // 000C JMPF R4 #001B - 0x8C10070B, // 000D GETMET R4 R3 K11 - 0x88180101, // 000E GETMBR R6 R0 K1 - 0x581C000C, // 000F LDCONST R7 K12 + 0x8C10071A, // 000D GETMET R4 R3 K26 + 0x88180115, // 000E GETMBR R6 R0 K21 + 0x581C001B, // 000F LDCONST R7 K27 0x7C100600, // 0010 CALL R4 3 0x74120004, // 0011 JMPT R4 #0017 - 0x8C10070B, // 0012 GETMET R4 R3 K11 - 0x88180101, // 0013 GETMBR R6 R0 K1 - 0x581C000D, // 0014 LDCONST R7 K13 + 0x8C10071A, // 0012 GETMET R4 R3 K26 + 0x88180115, // 0013 GETMBR R6 R0 K21 + 0x581C001C, // 0014 LDCONST R7 K28 0x7C100600, // 0015 CALL R4 3 0x78120003, // 0016 JMPF R4 #001B 0x60100009, // 0017 GETGBL R4 G9 - 0x88140101, // 0018 GETMBR R5 R0 K1 + 0x88140115, // 0018 GETMBR R5 R0 K21 0x7C100200, // 0019 CALL R4 1 - 0x90020204, // 001A SETMBR R0 K1 R4 - 0x88100101, // 001B GETMBR R4 R0 K1 + 0x90022A04, // 001A SETMBR R0 K21 R4 + 0x88100115, // 001B GETMBR R4 R0 K21 0x4C140000, // 001C LDNIL R5 0x20100805, // 001D NE R4 R4 R5 0x78120004, // 001E JMPF R4 #0024 - 0xB8121C00, // 001F GETNGBL R4 K14 - 0x8C10090F, // 0020 GETMET R4 R4 K15 + 0xB8121600, // 001F GETNGBL R4 K11 + 0x8C10091D, // 0020 GETMET R4 R4 K29 0x541A0063, // 0021 LDINT R6 100 0x841C0000, // 0022 CLOSURE R7 P0 0x7C100600, // 0023 CALL R4 3 @@ -174,126 +357,24 @@ be_local_closure(class_Matter_Zigbee_Mapper_parse_configuration, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: read_zb_info -********************************************************************/ -be_local_closure(class_Matter_Zigbee_Mapper_read_zb_info, /* name */ - be_nested_proto( - 5, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ - be_str_weak(read_zb_info), - &be_const_str_solidified, - ( &(const binstruction[14]) { /* code */ - 0x8C040110, // 0000 GETMET R1 R0 K16 - 0x7C040200, // 0001 CALL R1 1 - 0x78060009, // 0002 JMPF R1 #000D - 0xA4060000, // 0003 IMPORT R1 K0 - 0x8C080304, // 0004 GETMET R2 R1 K4 - 0x88100102, // 0005 GETMBR R4 R0 K2 - 0x7C080400, // 0006 CALL R2 2 - 0x4C0C0000, // 0007 LDNIL R3 - 0x200C0403, // 0008 NE R3 R2 R3 - 0x780E0002, // 0009 JMPF R3 #000D - 0x8C0C0511, // 000A GETMET R3 R2 K17 - 0x7C0C0200, // 000B CALL R3 1 - 0x80040600, // 000C RET 1 R3 - 0x80000000, // 000D RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: init -********************************************************************/ -be_local_closure(class_Matter_Zigbee_Mapper_init, /* name */ - be_nested_proto( - 2, /* nstack */ - 2, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90021201, // 0000 SETMBR R0 K9 R1 - 0x80000000, // 0001 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: probe_zb_values -********************************************************************/ -be_local_closure(class_Matter_Zigbee_Mapper_probe_zb_values, /* name */ - be_nested_proto( - 6, /* nstack */ - 1, /* argc */ - 10, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - &be_ktab_class_Matter_Zigbee_Mapper, /* shared constants */ - be_str_weak(probe_zb_values), - &be_const_str_solidified, - ( &(const binstruction[18]) { /* code */ - 0x8C040112, // 0000 GETMET R1 R0 K18 - 0x7C040200, // 0001 CALL R1 1 - 0x4C080000, // 0002 LDNIL R2 - 0x20080202, // 0003 NE R2 R1 R2 - 0x780A000B, // 0004 JMPF R2 #0011 - 0xB80A0A00, // 0005 GETNGBL R2 K5 - 0x600C0018, // 0006 GETGBL R3 G24 - 0x58100013, // 0007 LDCONST R4 K19 - 0x88140102, // 0008 GETMBR R5 R0 K2 - 0x7C0C0400, // 0009 CALL R3 2 - 0x58100007, // 000A LDCONST R4 K7 - 0x7C080400, // 000B CALL R2 2 - 0x88080109, // 000C GETMBR R2 R0 K9 - 0x8C080514, // 000D GETMET R2 R2 K20 - 0x4C100000, // 000E LDNIL R4 - 0x5C140200, // 000F MOVE R5 R1 - 0x7C080600, // 0010 CALL R2 3 - 0x80000000, // 0011 RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified class: Matter_Zigbee_Mapper ********************************************************************/ be_local_class(Matter_Zigbee_Mapper, 4, NULL, - be_nested_map(9, + be_nested_map(10, ( (struct bmapnode*) &(const bmapnode[]) { { be_const_key_weak(shortaddr, -1), be_const_var(3) }, - { be_const_key_weak(resolve_zb_device, -1), be_const_closure(class_Matter_Zigbee_Mapper_resolve_zb_device_closure) }, - { be_const_key_weak(device_arg, -1), be_const_var(1) }, - { be_const_key_weak(read_zb_info, -1), be_const_closure(class_Matter_Zigbee_Mapper_read_zb_info_closure) }, - { be_const_key_weak(zigbee_device, -1), be_const_var(2) }, - { be_const_key_weak(probe_zb_values, 3), be_const_closure(class_Matter_Zigbee_Mapper_probe_zb_values_closure) }, - { be_const_key_weak(init, -1), be_const_closure(class_Matter_Zigbee_Mapper_init_closure) }, - { be_const_key_weak(parse_configuration, 5), be_const_closure(class_Matter_Zigbee_Mapper_parse_configuration_closure) }, + { be_const_key_weak(zb_single_command, 0), be_const_closure(class_Matter_Zigbee_Mapper_zb_single_command_closure) }, { be_const_key_weak(pi, -1), be_const_var(0) }, + { be_const_key_weak(resolve_zb_device, -1), be_const_closure(class_Matter_Zigbee_Mapper_resolve_zb_device_closure) }, + { be_const_key_weak(zigbee_device, 1), be_const_var(2) }, + { be_const_key_weak(probe_zb_values, 6), be_const_closure(class_Matter_Zigbee_Mapper_probe_zb_values_closure) }, + { be_const_key_weak(init, -1), be_const_closure(class_Matter_Zigbee_Mapper_init_closure) }, + { be_const_key_weak(read_zb_info, 3), be_const_closure(class_Matter_Zigbee_Mapper_read_zb_info_closure) }, + { be_const_key_weak(device_arg, -1), be_const_var(1) }, + { be_const_key_weak(parse_configuration, -1), be_const_closure(class_Matter_Zigbee_Mapper_parse_configuration_closure) }, })), be_str_weak(Matter_Zigbee_Mapper) ); @@ -433,7 +514,7 @@ be_local_class(Matter_Zigbee, { be_const_key_weak(init, 3), be_const_closure(class_Matter_Zigbee_init_closure) }, { be_const_key_weak(Matter_Zigbee_Mapper, 4), be_const_class(be_class_Matter_Zigbee_Mapper) }, { be_const_key_weak(attributes_final, -1), be_const_closure(class_Matter_Zigbee_attributes_final_closure) }, - { be_const_key_weak(_CLASSES_TYPES, -1), be_nested_str_weak(_X2Dzigbee_X7Cz_temp_X7Cz_pressure_X7Cz_humidity) }, + { be_const_key_weak(_CLASSES_TYPES, -1), be_nested_str_weak(_X2Dzigbee_X7Cz_light0_X7Cz_light1_X7Cz_light2_X7Cz_temp_X7Cz_pressure_X7Cz_humidity_X7Cz_occupancy) }, { be_const_key_weak(device, -1), be_const_var(0) }, })), be_str_weak(Matter_Zigbee) diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_zz_Device.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_zz_Device.h index 4c0011407..fe472bd9c 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_zz_Device.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_zz_Device.h @@ -3349,64 +3349,68 @@ be_local_class(Matter_Device, { be_const_key_weak(signal_endpoints_changed, 57), be_const_closure(class_Matter_Device_signal_endpoints_changed_closure) }, { be_const_key_weak(is_zigbee_present, 65), be_const_closure(class_Matter_Device_is_zigbee_present_closure) }, { be_const_key_weak(plugins_classes, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { - be_const_map( * be_nested_map(56, + be_const_map( * be_nested_map(60, ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(gensw_btn, -1), be_const_class(be_class_Matter_Plugin_Sensor_GenericSwitch_Btn) }, + { be_const_key_weak(pressure, -1), be_const_class(be_class_Matter_Plugin_Sensor_Pressure) }, + { be_const_key_weak(z_light0, 40), be_const_class(be_class_Matter_Plugin_Zigbee_Light0) }, + { be_const_key_weak(v_rain, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Rain) }, + { be_const_key_weak(http_temperature, 13), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Temp) }, + { be_const_key_weak(http_pressure, 25), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Pressure) }, + { be_const_key_weak(v_light2, -1), be_const_class(be_class_Matter_Plugin_Virt_Light2) }, + { be_const_key_weak(v_fan, -1), be_const_class(be_class_Matter_Plugin_Virt_Fan) }, { be_const_key_weak(v_temp, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Temp) }, + { be_const_key_weak(light1, -1), be_const_class(be_class_Matter_Plugin_Light1) }, + { be_const_key_weak(v_flow, 1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Flow) }, + { be_const_key_weak(v_occupancy, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Occupancy) }, + { be_const_key_weak(shutter_X2Btilt, -1), be_const_class(be_class_Matter_Plugin_ShutterTilt) }, + { be_const_key_weak(z_temp, -1), be_const_class(be_class_Matter_Plugin_Zigbee_Temperature) }, + { be_const_key_weak(fan, -1), be_const_class(be_class_Matter_Plugin_Fan) }, + { be_const_key_weak(z_humidity, 16), be_const_class(be_class_Matter_Plugin_Zigbee_Humidity) }, + { be_const_key_weak(v_airquality, 33), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Air_Quality) }, + { be_const_key_weak(light0, 54), be_const_class(be_class_Matter_Plugin_Light0) }, + { be_const_key_weak(http_contact, 9), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Contact) }, + { be_const_key_weak(http_airquality, 39), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Air_Quality) }, + { be_const_key_weak(light3, 45), be_const_class(be_class_Matter_Plugin_Light3) }, + { be_const_key_weak(v_waterleak, 44), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Waterleak) }, + { be_const_key_weak(occupancy, -1), be_const_class(be_class_Matter_Plugin_Sensor_Occupancy) }, + { be_const_key_weak(v_light1, -1), be_const_class(be_class_Matter_Plugin_Virt_Light1) }, + { be_const_key_weak(humidity, -1), be_const_class(be_class_Matter_Plugin_Sensor_Humidity) }, + { be_const_key_weak(flow, -1), be_const_class(be_class_Matter_Plugin_Sensor_Flow) }, + { be_const_key_weak(contact, -1), be_const_class(be_class_Matter_Plugin_Sensor_Contact) }, + { be_const_key_weak(waterleak, 34), be_const_class(be_class_Matter_Plugin_Sensor_Waterleak) }, + { be_const_key_weak(aggregator, -1), be_const_class(be_class_Matter_Plugin_Aggregator) }, + { be_const_key_weak(http_light1, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light1) }, + { be_const_key_weak(relay, 21), be_const_class(be_class_Matter_Plugin_OnOff) }, + { be_const_key_weak(http_light3, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light3) }, + { be_const_key_weak(http_light2, 3), be_const_class(be_class_Matter_Plugin_Bridge_Light2) }, + { be_const_key_weak(v_humidity, 36), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Humidity) }, + { be_const_key_weak(rain, -1), be_const_class(be_class_Matter_Plugin_Sensor_Rain) }, + { be_const_key_weak(http_illuminance, 26), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Illuminance) }, + { be_const_key_weak(http_occupancy, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Occupancy) }, + { be_const_key_weak(temperature, -1), be_const_class(be_class_Matter_Plugin_Sensor_Temp) }, + { be_const_key_weak(shutter, -1), be_const_class(be_class_Matter_Plugin_Shutter) }, + { be_const_key_weak(light2, -1), be_const_class(be_class_Matter_Plugin_Light2) }, + { be_const_key_weak(v_contact, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Contact) }, { be_const_key_weak(z_pressure, -1), be_const_class(be_class_Matter_Plugin_Zigbee_Pressure) }, { be_const_key_weak(http_flow, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Flow) }, - { be_const_key_weak(v_airquality, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Air_Quality) }, - { be_const_key_weak(z_temp, 28), be_const_class(be_class_Matter_Plugin_Zigbee_Temperature) }, - { be_const_key_weak(root, 11), be_const_class(be_class_Matter_Plugin_Root) }, - { be_const_key_weak(http_contact, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Contact) }, - { be_const_key_weak(http_airquality, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Air_Quality) }, - { be_const_key_weak(http_light2, 48), be_const_class(be_class_Matter_Plugin_Bridge_Light2) }, - { be_const_key_weak(http_light1, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light1) }, - { be_const_key_weak(v_pressure, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Pressure) }, - { be_const_key_weak(onoff, -1), be_const_class(be_class_Matter_Plugin_Sensor_OnOff) }, - { be_const_key_weak(light3, -1), be_const_class(be_class_Matter_Plugin_Light3) }, - { be_const_key_weak(light0, 10), be_const_class(be_class_Matter_Plugin_Light0) }, - { be_const_key_weak(v_fan, -1), be_const_class(be_class_Matter_Plugin_Virt_Fan) }, - { be_const_key_weak(v_light3, 32), be_const_class(be_class_Matter_Plugin_Virt_Light3) }, - { 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(v_light0, -1), be_const_class(be_class_Matter_Plugin_Virt_Light0) }, - { be_const_key_weak(http_humidity, 39), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Humidity) }, - { be_const_key_weak(aggregator, -1), be_const_class(be_class_Matter_Plugin_Aggregator) }, - { be_const_key_weak(flow, -1), be_const_class(be_class_Matter_Plugin_Sensor_Flow) }, - { be_const_key_weak(v_waterleak, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Waterleak) }, - { be_const_key_weak(v_occupancy, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Occupancy) }, - { be_const_key_weak(gensw_btn, -1), be_const_class(be_class_Matter_Plugin_Sensor_GenericSwitch_Btn) }, - { be_const_key_weak(v_light1, -1), be_const_class(be_class_Matter_Plugin_Virt_Light1) }, - { be_const_key_weak(fan, -1), be_const_class(be_class_Matter_Plugin_Fan) }, - { be_const_key_weak(v_illuminance, 37), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Illuminance) }, - { be_const_key_weak(http_rain, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Rain) }, - { be_const_key_weak(pressure, 45), be_const_class(be_class_Matter_Plugin_Sensor_Pressure) }, - { be_const_key_weak(http_light3, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light3) }, - { be_const_key_weak(light2, 33), be_const_class(be_class_Matter_Plugin_Light2) }, { be_const_key_weak(http_relay, -1), be_const_class(be_class_Matter_Plugin_Bridge_OnOff) }, - { be_const_key_weak(v_humidity, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Humidity) }, - { be_const_key_weak(http_waterleak, 29), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Waterleak) }, - { be_const_key_weak(v_relay, -1), be_const_class(be_class_Matter_Plugin_Virt_OnOff) }, - { be_const_key_weak(http_temperature, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Temp) }, - { be_const_key_weak(z_humidity, 30), be_const_class(be_class_Matter_Plugin_Zigbee_Humidity) }, - { be_const_key_weak(occupancy, -1), be_const_class(be_class_Matter_Plugin_Sensor_Occupancy) }, - { be_const_key_weak(rain, -1), be_const_class(be_class_Matter_Plugin_Sensor_Rain) }, - { be_const_key_weak(v_rain, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Rain) }, - { be_const_key_weak(http_pressure, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Pressure) }, - { be_const_key_weak(relay, -1), be_const_class(be_class_Matter_Plugin_OnOff) }, - { be_const_key_weak(contact, -1), be_const_class(be_class_Matter_Plugin_Sensor_Contact) }, - { be_const_key_weak(airquality, 17), be_const_class(be_class_Matter_Plugin_Sensor_Air_Quality) }, - { be_const_key_weak(v_contact, 18), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Contact) }, { be_const_key_weak(http_light0, -1), be_const_class(be_class_Matter_Plugin_Bridge_Light0) }, - { be_const_key_weak(waterleak, 7), be_const_class(be_class_Matter_Plugin_Sensor_Waterleak) }, - { be_const_key_weak(humidity, -1), be_const_class(be_class_Matter_Plugin_Sensor_Humidity) }, - { be_const_key_weak(v_flow, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Flow) }, - { be_const_key_weak(shutter, 16), be_const_class(be_class_Matter_Plugin_Shutter) }, - { be_const_key_weak(http_occupancy, 14), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Occupancy) }, - { be_const_key_weak(v_light2, -1), be_const_class(be_class_Matter_Plugin_Virt_Light2) }, - { be_const_key_weak(temperature, 25), be_const_class(be_class_Matter_Plugin_Sensor_Temp) }, - { be_const_key_weak(illuminance, 49), be_const_class(be_class_Matter_Plugin_Sensor_Illuminance) }, - { be_const_key_weak(http_illuminance, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Illuminance) }, + { be_const_key_weak(airquality, 12), be_const_class(be_class_Matter_Plugin_Sensor_Air_Quality) }, + { be_const_key_weak(http_waterleak, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Waterleak) }, + { be_const_key_weak(v_relay, 27), be_const_class(be_class_Matter_Plugin_Virt_OnOff) }, + { be_const_key_weak(z_occupancy, 59), be_const_class(be_class_Matter_Plugin_Zigbee_Occupancy) }, + { be_const_key_weak(z_light1, 23), be_const_class(be_class_Matter_Plugin_Zigbee_Light1) }, + { be_const_key_weak(v_light0, 2), be_const_class(be_class_Matter_Plugin_Virt_Light0) }, + { be_const_key_weak(v_illuminance, 48), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Illuminance) }, + { be_const_key_weak(z_light2, 6), be_const_class(be_class_Matter_Plugin_Zigbee_Light2) }, + { be_const_key_weak(root, 41), be_const_class(be_class_Matter_Plugin_Root) }, + { be_const_key_weak(onoff, -1), be_const_class(be_class_Matter_Plugin_Sensor_OnOff) }, + { be_const_key_weak(http_humidity, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Humidity) }, + { be_const_key_weak(http_rain, -1), be_const_class(be_class_Matter_Plugin_Bridge_Sensor_Rain) }, + { be_const_key_weak(v_pressure, -1), be_const_class(be_class_Matter_Plugin_Virt_Sensor_Pressure) }, + { be_const_key_weak(illuminance, -1), be_const_class(be_class_Matter_Plugin_Sensor_Illuminance) }, + { be_const_key_weak(v_light3, -1), be_const_class(be_class_Matter_Plugin_Virt_Light3) }, })) ) } )) }, { be_const_key_weak(adjust_next_ep, -1), be_const_closure(class_Matter_Device_adjust_next_ep_closure) }, { be_const_key_weak(remove_fabric, -1), be_const_closure(class_Matter_Device_remove_fabric_closure) }, diff --git a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino index 175b1e65b..d169629d7 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino @@ -415,10 +415,20 @@ extern "C" { be_pushreal(vm, (breal)attr->val.fval); break; case Za_type::Za_raw: - be_pushbytes(vm, attr->val.bval->getBuffer(), attr->val.bval->len()); + // `bval` can be `null`, avoid crashing + if (attr->val.bval) { + be_pushbytes(vm, attr->val.bval->getBuffer(), attr->val.bval->len()); + } else { + be_pushbytes(vm, nullptr, 0); + } break; case Za_type::Za_str: - be_pushstring(vm, attr->val.sval); + // `sval` can be `null`, avoid crashing + if (attr->val.sval) { + be_pushstring(vm, attr->val.sval); + } else { + be_pushstring(vm, ""); + } break; case Za_type::Za_obj: