From a26458a1363a26fa27029c820aec52d148e78c2e Mon Sep 17 00:00:00 2001 From: s-hadinger <49731213+s-hadinger@users.noreply.github.com> Date: Sun, 19 Feb 2023 21:37:33 +0100 Subject: [PATCH] Matter read/write and commands (#18000) --- .../generate/Matter_generate_c.be | 7 +- .../generate/be_matter_clusters.h | 1604 ++++----- .../berry_matter/src/be_matter_module.c | 53 +- .../src/embedded/Matter_Commissioning.be | 166 +- .../src/embedded/Matter_Commissioning_Data.be | 8 +- .../src/embedded/Matter_Device.be | 204 +- .../berry_matter/src/embedded/Matter_IM.be | 463 ++- .../src/embedded/Matter_IM_Data.be | 14 +- .../src/embedded/Matter_IM_Message.be | 281 ++ .../src/embedded/Matter_IM_Subscription.be | 180 + .../src/embedded/Matter_Message.be | 97 +- .../src/embedded/Matter_MessageHandler.be | 31 +- .../src/embedded/Matter_Plugin.be | 2 +- .../src/embedded/Matter_Plugin_OnOff.be | 156 + .../src/embedded/Matter_Plugin_Relay.be | 93 - ...r_Plugin_core.be => Matter_Plugin_Root.be} | 152 +- .../src/embedded/Matter_Session.be | 10 +- .../berry_matter/src/embedded/Matter_TLV.be | 266 +- .../src/embedded/Matter_UDPServer.be | 8 +- .../solidified_Matter_Commissioning.h | 1784 +++++----- .../solidified_Matter_Commissioning_Data.h | 91 +- .../src/solidify/solidified_Matter_Device.h | 3108 +++++++++-------- .../src/solidify/solidified_Matter_IM.h | 2476 +++++++------ .../src/solidify/solidified_Matter_IM_Data.h | 112 +- .../solidify/solidified_Matter_IM_Message.h | 1024 ++++++ .../solidified_Matter_IM_Subscription.h | 585 ++++ .../src/solidify/solidified_Matter_Message.h | 1459 ++++---- .../solidified_Matter_MessageHandler.h | 721 ++-- .../src/solidify/solidified_Matter_Plugin.h | 8 +- .../solidify/solidified_Matter_Plugin_OnOff.h | 389 +++ .../solidify/solidified_Matter_Plugin_Relay.h | 246 -- ...core.h => solidified_Matter_Plugin_Root.h} | 2137 +++++++----- .../src/solidify/solidified_Matter_Session.h | 1848 +++++----- .../src/solidify/solidified_Matter_TLV.h | 2104 ++++++----- .../solidify/solidified_Matter_UDPServer.h | 85 +- 35 files changed, 13060 insertions(+), 8912 deletions(-) create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_IM_Message.be create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_IM_Subscription.be create mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_Plugin_OnOff.be delete mode 100644 lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Relay.be rename lib/libesp32/berry_matter/src/embedded/{Matter_Plugin_core.be => Matter_Plugin_Root.be} (78%) create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Message.h create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Subscription.h create mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_OnOff.h delete mode 100644 lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Relay.h rename lib/libesp32/berry_matter/src/solidify/{solidified_Matter_Plugin_core.h => solidified_Matter_Plugin_Root.h} (76%) diff --git a/lib/libesp32/berry_matter/generate/Matter_generate_c.be b/lib/libesp32/berry_matter/generate/Matter_generate_c.be index 6c9c13170..86155ec1c 100644 --- a/lib/libesp32/berry_matter/generate/Matter_generate_c.be +++ b/lib/libesp32/berry_matter/generate/Matter_generate_c.be @@ -59,6 +59,8 @@ fprint("* Compact form for attributes and clusters") fprint("*") fprint("* Generated content, do not edit") fprint("\\*********************************************************************************/") +fprint("#include ") +fprint("#include ") fprint() fprint("typedef struct {") fprint(" uint16_t id;") @@ -89,7 +91,10 @@ for cl:cl_ids var attr_ids_local = k2l(attr_id_name) for attr_id:attr_ids_local - fprint(string.format(' { 0x%04X, %i, 0x%02X, "%s" },', attr_id, 0, 0, attributes[attr_id]['attributeName'])) + var reportable = attributes[attr_id].find('reportable', false) + var writable = attributes[attr_id].find('writable', false) + var flags = (writable ? 0x01 : 0x00) | (reportable ? 0x02 : 0x00) + fprint(string.format(' { 0x%04X, %i, 0x%02X, "%s" },', attr_id, 0, flags, attributes[attr_id]['attributeName'])) end fprint(' { 0xFFFF, 0, 0x00, NULL },') fprint("};") diff --git a/lib/libesp32/berry_matter/generate/be_matter_clusters.h b/lib/libesp32/berry_matter/generate/be_matter_clusters.h index fc9171ce6..e25982844 100644 --- a/lib/libesp32/berry_matter/generate/be_matter_clusters.h +++ b/lib/libesp32/berry_matter/generate/be_matter_clusters.h @@ -26,13 +26,13 @@ typedef struct { } matter_cluster_t; const matter_attribute_t matter_Attributes_0003[] = { - { 0x0000, 0, 0x00, "IdentifyTime" }, - { 0x0001, 0, 0x00, "IdentifyType" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "IdentifyTime" }, + { 0x0001, 0, 0x02, "IdentifyType" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -43,12 +43,12 @@ const matter_command_t matter_Commands_0003[] = { }; const matter_attribute_t matter_Attributes_0004[] = { - { 0x0000, 0, 0x00, "NameSupport" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "NameSupport" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -63,16 +63,16 @@ const matter_command_t matter_Commands_0004[] = { }; const matter_attribute_t matter_Attributes_0005[] = { - { 0x0000, 0, 0x00, "SceneCount" }, - { 0x0001, 0, 0x00, "CurrentScene" }, - { 0x0002, 0, 0x00, "CurrentGroup" }, - { 0x0003, 0, 0x00, "SceneValid" }, - { 0x0004, 0, 0x00, "NameSupport" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "SceneCount" }, + { 0x0001, 0, 0x02, "CurrentScene" }, + { 0x0002, 0, 0x02, "CurrentGroup" }, + { 0x0003, 0, 0x02, "SceneValid" }, + { 0x0004, 0, 0x02, "NameSupport" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -88,16 +88,16 @@ const matter_command_t matter_Commands_0005[] = { }; const matter_attribute_t matter_Attributes_0006[] = { - { 0x0000, 0, 0x00, "OnOff" }, - { 0x4000, 0, 0x00, "GlobalSceneControl" }, - { 0x4001, 0, 0x00, "OnTime" }, - { 0x4002, 0, 0x00, "OffWaitTime" }, - { 0x4003, 0, 0x00, "StartUpOnOff" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "OnOff" }, + { 0x4000, 0, 0x02, "GlobalSceneControl" }, + { 0x4001, 0, 0x03, "OnTime" }, + { 0x4002, 0, 0x03, "OffWaitTime" }, + { 0x4003, 0, 0x03, "StartUpOnOff" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -112,13 +112,13 @@ const matter_command_t matter_Commands_0006[] = { }; const matter_attribute_t matter_Attributes_0007[] = { - { 0x0000, 0, 0x00, "SwitchType" }, - { 0x0010, 0, 0x00, "SwitchActions" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "SwitchType" }, + { 0x0010, 0, 0x03, "SwitchActions" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -127,25 +127,25 @@ const matter_command_t matter_Commands_0007[] = { }; const matter_attribute_t matter_Attributes_0008[] = { - { 0x0000, 0, 0x00, "CurrentLevel" }, - { 0x0001, 0, 0x00, "RemainingTime" }, - { 0x0002, 0, 0x00, "MinLevel" }, - { 0x0003, 0, 0x00, "MaxLevel" }, - { 0x0004, 0, 0x00, "CurrentFrequency" }, - { 0x0005, 0, 0x00, "MinFrequency" }, - { 0x0006, 0, 0x00, "MaxFrequency" }, - { 0x000F, 0, 0x00, "Options" }, - { 0x0010, 0, 0x00, "OnOffTransitionTime" }, - { 0x0011, 0, 0x00, "OnLevel" }, - { 0x0012, 0, 0x00, "OnTransitionTime" }, - { 0x0013, 0, 0x00, "OffTransitionTime" }, - { 0x0014, 0, 0x00, "DefaultMoveRate" }, - { 0x4000, 0, 0x00, "StartUpCurrentLevel" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "CurrentLevel" }, + { 0x0001, 0, 0x02, "RemainingTime" }, + { 0x0002, 0, 0x02, "MinLevel" }, + { 0x0003, 0, 0x02, "MaxLevel" }, + { 0x0004, 0, 0x02, "CurrentFrequency" }, + { 0x0005, 0, 0x02, "MinFrequency" }, + { 0x0006, 0, 0x02, "MaxFrequency" }, + { 0x000F, 0, 0x03, "Options" }, + { 0x0010, 0, 0x03, "OnOffTransitionTime" }, + { 0x0011, 0, 0x03, "OnLevel" }, + { 0x0012, 0, 0x03, "OnTransitionTime" }, + { 0x0013, 0, 0x03, "OffTransitionTime" }, + { 0x0014, 0, 0x03, "DefaultMoveRate" }, + { 0x4000, 0, 0x03, "StartUpCurrentLevel" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -162,14 +162,14 @@ const matter_command_t matter_Commands_0008[] = { }; const matter_attribute_t matter_Attributes_000F[] = { - { 0x0051, 0, 0x00, "OutOfService" }, - { 0x0055, 0, 0x00, "PresentValue" }, - { 0x006F, 0, 0x00, "StatusFlags" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0051, 0, 0x03, "OutOfService" }, + { 0x0055, 0, 0x03, "PresentValue" }, + { 0x006F, 0, 0x02, "StatusFlags" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -178,15 +178,15 @@ const matter_command_t matter_Commands_000F[] = { }; const matter_attribute_t matter_Attributes_001D[] = { - { 0x0000, 0, 0x00, "DeviceTypeList" }, - { 0x0001, 0, 0x00, "ServerList" }, - { 0x0002, 0, 0x00, "ClientList" }, - { 0x0003, 0, 0x00, "PartsList" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "DeviceTypeList" }, + { 0x0001, 0, 0x02, "ServerList" }, + { 0x0002, 0, 0x02, "ClientList" }, + { 0x0003, 0, 0x02, "PartsList" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -195,12 +195,12 @@ const matter_command_t matter_Commands_001D[] = { }; const matter_attribute_t matter_Attributes_001E[] = { - { 0x0000, 0, 0x00, "Binding" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "Binding" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -209,16 +209,16 @@ const matter_command_t matter_Commands_001E[] = { }; const matter_attribute_t matter_Attributes_001F[] = { - { 0x0000, 0, 0x00, "Acl" }, - { 0x0001, 0, 0x00, "Extension" }, - { 0x0002, 0, 0x00, "SubjectsPerAccessControlEntry" }, - { 0x0003, 0, 0x00, "TargetsPerAccessControlEntry" }, - { 0x0004, 0, 0x00, "AccessControlEntriesPerFabric" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "Acl" }, + { 0x0001, 0, 0x03, "Extension" }, + { 0x0002, 0, 0x02, "SubjectsPerAccessControlEntry" }, + { 0x0003, 0, 0x02, "TargetsPerAccessControlEntry" }, + { 0x0004, 0, 0x02, "AccessControlEntriesPerFabric" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -227,14 +227,14 @@ const matter_command_t matter_Commands_001F[] = { }; const matter_attribute_t matter_Attributes_0025[] = { - { 0x0000, 0, 0x00, "ActionList" }, - { 0x0001, 0, 0x00, "EndpointLists" }, - { 0x0002, 0, 0x00, "SetupURL" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "ActionList" }, + { 0x0001, 0, 0x02, "EndpointLists" }, + { 0x0002, 0, 0x02, "SetupURL" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -255,31 +255,31 @@ const matter_command_t matter_Commands_0025[] = { }; const matter_attribute_t matter_Attributes_0028[] = { - { 0x0000, 0, 0x00, "DataModelRevision" }, - { 0x0001, 0, 0x00, "VendorName" }, - { 0x0002, 0, 0x00, "VendorID" }, - { 0x0003, 0, 0x00, "ProductName" }, - { 0x0004, 0, 0x00, "ProductID" }, - { 0x0005, 0, 0x00, "NodeLabel" }, - { 0x0006, 0, 0x00, "Location" }, - { 0x0007, 0, 0x00, "HardwareVersion" }, - { 0x0008, 0, 0x00, "HardwareVersionString" }, - { 0x0009, 0, 0x00, "SoftwareVersion" }, - { 0x000A, 0, 0x00, "SoftwareVersionString" }, - { 0x000B, 0, 0x00, "ManufacturingDate" }, - { 0x000C, 0, 0x00, "PartNumber" }, - { 0x000D, 0, 0x00, "ProductURL" }, - { 0x000E, 0, 0x00, "ProductLabel" }, - { 0x000F, 0, 0x00, "SerialNumber" }, - { 0x0010, 0, 0x00, "LocalConfigDisabled" }, - { 0x0011, 0, 0x00, "Reachable" }, - { 0x0012, 0, 0x00, "UniqueID" }, - { 0x0013, 0, 0x00, "CapabilityMinima" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "DataModelRevision" }, + { 0x0001, 0, 0x02, "VendorName" }, + { 0x0002, 0, 0x02, "VendorID" }, + { 0x0003, 0, 0x02, "ProductName" }, + { 0x0004, 0, 0x02, "ProductID" }, + { 0x0005, 0, 0x03, "NodeLabel" }, + { 0x0006, 0, 0x03, "Location" }, + { 0x0007, 0, 0x02, "HardwareVersion" }, + { 0x0008, 0, 0x02, "HardwareVersionString" }, + { 0x0009, 0, 0x02, "SoftwareVersion" }, + { 0x000A, 0, 0x02, "SoftwareVersionString" }, + { 0x000B, 0, 0x02, "ManufacturingDate" }, + { 0x000C, 0, 0x02, "PartNumber" }, + { 0x000D, 0, 0x02, "ProductURL" }, + { 0x000E, 0, 0x02, "ProductLabel" }, + { 0x000F, 0, 0x02, "SerialNumber" }, + { 0x0010, 0, 0x03, "LocalConfigDisabled" }, + { 0x0011, 0, 0x02, "Reachable" }, + { 0x0012, 0, 0x02, "UniqueID" }, + { 0x0013, 0, 0x02, "CapabilityMinima" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -288,9 +288,9 @@ const matter_command_t matter_Commands_0028[] = { }; const matter_attribute_t matter_Attributes_0029[] = { - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -302,13 +302,13 @@ const matter_command_t matter_Commands_0029[] = { }; const matter_attribute_t matter_Attributes_002A[] = { - { 0x0000, 0, 0x00, "DefaultOtaProviders" }, - { 0x0001, 0, 0x00, "UpdatePossible" }, - { 0x0002, 0, 0x00, "UpdateState" }, - { 0x0003, 0, 0x00, "UpdateStateProgress" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "DefaultOtaProviders" }, + { 0x0001, 0, 0x02, "UpdatePossible" }, + { 0x0002, 0, 0x02, "UpdateState" }, + { 0x0003, 0, 0x02, "UpdateStateProgress" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -318,12 +318,12 @@ const matter_command_t matter_Commands_002A[] = { }; const matter_attribute_t matter_Attributes_002B[] = { - { 0x0000, 0, 0x00, "ActiveLocale" }, - { 0x0001, 0, 0x00, "SupportedLocales" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "ActiveLocale" }, + { 0x0001, 0, 0x02, "SupportedLocales" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -332,13 +332,13 @@ const matter_command_t matter_Commands_002B[] = { }; const matter_attribute_t matter_Attributes_002C[] = { - { 0x0000, 0, 0x00, "HourFormat" }, - { 0x0001, 0, 0x00, "ActiveCalendarType" }, - { 0x0002, 0, 0x00, "SupportedCalendarTypes" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "HourFormat" }, + { 0x0001, 0, 0x03, "ActiveCalendarType" }, + { 0x0002, 0, 0x02, "SupportedCalendarTypes" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -347,10 +347,10 @@ const matter_command_t matter_Commands_002C[] = { }; const matter_attribute_t matter_Attributes_002D[] = { - { 0x0000, 0, 0x00, "TemperatureUnit" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "TemperatureUnit" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -359,12 +359,12 @@ const matter_command_t matter_Commands_002D[] = { }; const matter_attribute_t matter_Attributes_002E[] = { - { 0x0000, 0, 0x00, "Sources" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Sources" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -373,42 +373,42 @@ const matter_command_t matter_Commands_002E[] = { }; const matter_attribute_t matter_Attributes_002F[] = { - { 0x0000, 0, 0x00, "Status" }, - { 0x0001, 0, 0x00, "Order" }, - { 0x0002, 0, 0x00, "Description" }, - { 0x0003, 0, 0x00, "WiredAssessedInputVoltage" }, - { 0x0004, 0, 0x00, "WiredAssessedInputFrequency" }, - { 0x0005, 0, 0x00, "WiredCurrentType" }, - { 0x0006, 0, 0x00, "WiredAssessedCurrent" }, - { 0x0007, 0, 0x00, "WiredNominalVoltage" }, - { 0x0008, 0, 0x00, "WiredMaximumCurrent" }, - { 0x0009, 0, 0x00, "WiredPresent" }, - { 0x000A, 0, 0x00, "ActiveWiredFaults" }, - { 0x000B, 0, 0x00, "BatVoltage" }, - { 0x000C, 0, 0x00, "BatPercentRemaining" }, - { 0x000D, 0, 0x00, "BatTimeRemaining" }, - { 0x000E, 0, 0x00, "BatChargeLevel" }, - { 0x000F, 0, 0x00, "BatReplacementNeeded" }, - { 0x0010, 0, 0x00, "BatReplaceability" }, - { 0x0011, 0, 0x00, "BatPresent" }, - { 0x0012, 0, 0x00, "ActiveBatFaults" }, - { 0x0013, 0, 0x00, "BatReplacementDescription" }, - { 0x0014, 0, 0x00, "BatCommonDesignation" }, - { 0x0015, 0, 0x00, "BatANSIDesignation" }, - { 0x0016, 0, 0x00, "BatIECDesignation" }, - { 0x0017, 0, 0x00, "BatApprovedChemistry" }, - { 0x0018, 0, 0x00, "BatCapacity" }, - { 0x0019, 0, 0x00, "BatQuantity" }, - { 0x001A, 0, 0x00, "BatChargeState" }, - { 0x001B, 0, 0x00, "BatTimeToFullCharge" }, - { 0x001C, 0, 0x00, "BatFunctionalWhileCharging" }, - { 0x001D, 0, 0x00, "BatChargingCurrent" }, - { 0x001E, 0, 0x00, "ActiveBatChargeFaults" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Status" }, + { 0x0001, 0, 0x02, "Order" }, + { 0x0002, 0, 0x02, "Description" }, + { 0x0003, 0, 0x02, "WiredAssessedInputVoltage" }, + { 0x0004, 0, 0x02, "WiredAssessedInputFrequency" }, + { 0x0005, 0, 0x02, "WiredCurrentType" }, + { 0x0006, 0, 0x02, "WiredAssessedCurrent" }, + { 0x0007, 0, 0x02, "WiredNominalVoltage" }, + { 0x0008, 0, 0x02, "WiredMaximumCurrent" }, + { 0x0009, 0, 0x02, "WiredPresent" }, + { 0x000A, 0, 0x02, "ActiveWiredFaults" }, + { 0x000B, 0, 0x02, "BatVoltage" }, + { 0x000C, 0, 0x02, "BatPercentRemaining" }, + { 0x000D, 0, 0x02, "BatTimeRemaining" }, + { 0x000E, 0, 0x02, "BatChargeLevel" }, + { 0x000F, 0, 0x02, "BatReplacementNeeded" }, + { 0x0010, 0, 0x02, "BatReplaceability" }, + { 0x0011, 0, 0x02, "BatPresent" }, + { 0x0012, 0, 0x02, "ActiveBatFaults" }, + { 0x0013, 0, 0x02, "BatReplacementDescription" }, + { 0x0014, 0, 0x02, "BatCommonDesignation" }, + { 0x0015, 0, 0x02, "BatANSIDesignation" }, + { 0x0016, 0, 0x02, "BatIECDesignation" }, + { 0x0017, 0, 0x02, "BatApprovedChemistry" }, + { 0x0018, 0, 0x02, "BatCapacity" }, + { 0x0019, 0, 0x02, "BatQuantity" }, + { 0x001A, 0, 0x02, "BatChargeState" }, + { 0x001B, 0, 0x02, "BatTimeToFullCharge" }, + { 0x001C, 0, 0x02, "BatFunctionalWhileCharging" }, + { 0x001D, 0, 0x02, "BatChargingCurrent" }, + { 0x001E, 0, 0x02, "ActiveBatChargeFaults" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -417,16 +417,16 @@ const matter_command_t matter_Commands_002F[] = { }; const matter_attribute_t matter_Attributes_0030[] = { - { 0x0000, 0, 0x00, "Breadcrumb" }, - { 0x0001, 0, 0x00, "BasicCommissioningInfo" }, - { 0x0002, 0, 0x00, "RegulatoryConfig" }, - { 0x0003, 0, 0x00, "LocationCapability" }, - { 0x0004, 0, 0x00, "SupportsConcurrentConnection" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "Breadcrumb" }, + { 0x0001, 0, 0x02, "BasicCommissioningInfo" }, + { 0x0002, 0, 0x02, "RegulatoryConfig" }, + { 0x0003, 0, 0x02, "LocationCapability" }, + { 0x0004, 0, 0x02, "SupportsConcurrentConnection" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -441,18 +441,18 @@ const matter_command_t matter_Commands_0030[] = { }; const matter_attribute_t matter_Attributes_0031[] = { - { 0x0000, 0, 0x00, "MaxNetworks" }, - { 0x0001, 0, 0x00, "Networks" }, - { 0x0002, 0, 0x00, "ScanMaxTimeSeconds" }, - { 0x0003, 0, 0x00, "ConnectMaxTimeSeconds" }, - { 0x0004, 0, 0x00, "InterfaceEnabled" }, - { 0x0005, 0, 0x00, "LastNetworkingStatus" }, - { 0x0006, 0, 0x00, "LastNetworkID" }, - { 0x0007, 0, 0x00, "LastConnectErrorValue" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MaxNetworks" }, + { 0x0001, 0, 0x02, "Networks" }, + { 0x0002, 0, 0x02, "ScanMaxTimeSeconds" }, + { 0x0003, 0, 0x02, "ConnectMaxTimeSeconds" }, + { 0x0004, 0, 0x03, "InterfaceEnabled" }, + { 0x0005, 0, 0x02, "LastNetworkingStatus" }, + { 0x0006, 0, 0x02, "LastNetworkID" }, + { 0x0007, 0, 0x02, "LastConnectErrorValue" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -467,11 +467,11 @@ const matter_command_t matter_Commands_0031[] = { }; const matter_attribute_t matter_Attributes_0032[] = { - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -481,20 +481,20 @@ const matter_command_t matter_Commands_0032[] = { }; const matter_attribute_t matter_Attributes_0033[] = { - { 0x0000, 0, 0x00, "NetworkInterfaces" }, - { 0x0001, 0, 0x00, "RebootCount" }, - { 0x0002, 0, 0x00, "UpTime" }, - { 0x0003, 0, 0x00, "TotalOperationalHours" }, - { 0x0004, 0, 0x00, "BootReasons" }, - { 0x0005, 0, 0x00, "ActiveHardwareFaults" }, - { 0x0006, 0, 0x00, "ActiveRadioFaults" }, - { 0x0007, 0, 0x00, "ActiveNetworkFaults" }, - { 0x0008, 0, 0x00, "TestEventTriggersEnabled" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "NetworkInterfaces" }, + { 0x0001, 0, 0x02, "RebootCount" }, + { 0x0002, 0, 0x02, "UpTime" }, + { 0x0003, 0, 0x02, "TotalOperationalHours" }, + { 0x0004, 0, 0x02, "BootReasons" }, + { 0x0005, 0, 0x02, "ActiveHardwareFaults" }, + { 0x0006, 0, 0x02, "ActiveRadioFaults" }, + { 0x0007, 0, 0x02, "ActiveNetworkFaults" }, + { 0x0008, 0, 0x02, "TestEventTriggersEnabled" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -504,15 +504,15 @@ const matter_command_t matter_Commands_0033[] = { }; const matter_attribute_t matter_Attributes_0034[] = { - { 0x0000, 0, 0x00, "ThreadMetrics" }, - { 0x0001, 0, 0x00, "CurrentHeapFree" }, - { 0x0002, 0, 0x00, "CurrentHeapUsed" }, - { 0x0003, 0, 0x00, "CurrentHeapHighWatermark" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "ThreadMetrics" }, + { 0x0001, 0, 0x02, "CurrentHeapFree" }, + { 0x0002, 0, 0x02, "CurrentHeapUsed" }, + { 0x0003, 0, 0x02, "CurrentHeapHighWatermark" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -522,74 +522,74 @@ const matter_command_t matter_Commands_0034[] = { }; const matter_attribute_t matter_Attributes_0035[] = { - { 0x0000, 0, 0x00, "Channel" }, - { 0x0001, 0, 0x00, "RoutingRole" }, - { 0x0002, 0, 0x00, "NetworkName" }, - { 0x0003, 0, 0x00, "PanId" }, - { 0x0004, 0, 0x00, "ExtendedPanId" }, - { 0x0005, 0, 0x00, "MeshLocalPrefix" }, - { 0x0006, 0, 0x00, "OverrunCount" }, - { 0x0007, 0, 0x00, "NeighborTableList" }, - { 0x0008, 0, 0x00, "RouteTableList" }, - { 0x0009, 0, 0x00, "PartitionId" }, - { 0x000A, 0, 0x00, "Weighting" }, - { 0x000B, 0, 0x00, "DataVersion" }, - { 0x000C, 0, 0x00, "StableDataVersion" }, - { 0x000D, 0, 0x00, "LeaderRouterId" }, - { 0x000E, 0, 0x00, "DetachedRoleCount" }, - { 0x000F, 0, 0x00, "ChildRoleCount" }, - { 0x0010, 0, 0x00, "RouterRoleCount" }, - { 0x0011, 0, 0x00, "LeaderRoleCount" }, - { 0x0012, 0, 0x00, "AttachAttemptCount" }, - { 0x0013, 0, 0x00, "PartitionIdChangeCount" }, - { 0x0014, 0, 0x00, "BetterPartitionAttachAttemptCount" }, - { 0x0015, 0, 0x00, "ParentChangeCount" }, - { 0x0016, 0, 0x00, "TxTotalCount" }, - { 0x0017, 0, 0x00, "TxUnicastCount" }, - { 0x0018, 0, 0x00, "TxBroadcastCount" }, - { 0x0019, 0, 0x00, "TxAckRequestedCount" }, - { 0x001A, 0, 0x00, "TxAckedCount" }, - { 0x001B, 0, 0x00, "TxNoAckRequestedCount" }, - { 0x001C, 0, 0x00, "TxDataCount" }, - { 0x001D, 0, 0x00, "TxDataPollCount" }, - { 0x001E, 0, 0x00, "TxBeaconCount" }, - { 0x001F, 0, 0x00, "TxBeaconRequestCount" }, - { 0x0020, 0, 0x00, "TxOtherCount" }, - { 0x0021, 0, 0x00, "TxRetryCount" }, - { 0x0022, 0, 0x00, "TxDirectMaxRetryExpiryCount" }, - { 0x0023, 0, 0x00, "TxIndirectMaxRetryExpiryCount" }, - { 0x0024, 0, 0x00, "TxErrCcaCount" }, - { 0x0025, 0, 0x00, "TxErrAbortCount" }, - { 0x0026, 0, 0x00, "TxErrBusyChannelCount" }, - { 0x0027, 0, 0x00, "RxTotalCount" }, - { 0x0028, 0, 0x00, "RxUnicastCount" }, - { 0x0029, 0, 0x00, "RxBroadcastCount" }, - { 0x002A, 0, 0x00, "RxDataCount" }, - { 0x002B, 0, 0x00, "RxDataPollCount" }, - { 0x002C, 0, 0x00, "RxBeaconCount" }, - { 0x002D, 0, 0x00, "RxBeaconRequestCount" }, - { 0x002E, 0, 0x00, "RxOtherCount" }, - { 0x002F, 0, 0x00, "RxAddressFilteredCount" }, - { 0x0030, 0, 0x00, "RxDestAddrFilteredCount" }, - { 0x0031, 0, 0x00, "RxDuplicatedCount" }, - { 0x0032, 0, 0x00, "RxErrNoFrameCount" }, - { 0x0033, 0, 0x00, "RxErrUnknownNeighborCount" }, - { 0x0034, 0, 0x00, "RxErrInvalidSrcAddrCount" }, - { 0x0035, 0, 0x00, "RxErrSecCount" }, - { 0x0036, 0, 0x00, "RxErrFcsCount" }, - { 0x0037, 0, 0x00, "RxErrOtherCount" }, - { 0x0038, 0, 0x00, "ActiveTimestamp" }, - { 0x0039, 0, 0x00, "PendingTimestamp" }, - { 0x003A, 0, 0x00, "Delay" }, - { 0x003B, 0, 0x00, "SecurityPolicy" }, - { 0x003C, 0, 0x00, "ChannelPage0Mask" }, - { 0x003D, 0, 0x00, "OperationalDatasetComponents" }, - { 0x003E, 0, 0x00, "ActiveNetworkFaultsList" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Channel" }, + { 0x0001, 0, 0x02, "RoutingRole" }, + { 0x0002, 0, 0x02, "NetworkName" }, + { 0x0003, 0, 0x02, "PanId" }, + { 0x0004, 0, 0x02, "ExtendedPanId" }, + { 0x0005, 0, 0x02, "MeshLocalPrefix" }, + { 0x0006, 0, 0x02, "OverrunCount" }, + { 0x0007, 0, 0x02, "NeighborTableList" }, + { 0x0008, 0, 0x02, "RouteTableList" }, + { 0x0009, 0, 0x02, "PartitionId" }, + { 0x000A, 0, 0x02, "Weighting" }, + { 0x000B, 0, 0x02, "DataVersion" }, + { 0x000C, 0, 0x02, "StableDataVersion" }, + { 0x000D, 0, 0x02, "LeaderRouterId" }, + { 0x000E, 0, 0x02, "DetachedRoleCount" }, + { 0x000F, 0, 0x02, "ChildRoleCount" }, + { 0x0010, 0, 0x02, "RouterRoleCount" }, + { 0x0011, 0, 0x02, "LeaderRoleCount" }, + { 0x0012, 0, 0x02, "AttachAttemptCount" }, + { 0x0013, 0, 0x02, "PartitionIdChangeCount" }, + { 0x0014, 0, 0x02, "BetterPartitionAttachAttemptCount" }, + { 0x0015, 0, 0x02, "ParentChangeCount" }, + { 0x0016, 0, 0x02, "TxTotalCount" }, + { 0x0017, 0, 0x02, "TxUnicastCount" }, + { 0x0018, 0, 0x02, "TxBroadcastCount" }, + { 0x0019, 0, 0x02, "TxAckRequestedCount" }, + { 0x001A, 0, 0x02, "TxAckedCount" }, + { 0x001B, 0, 0x02, "TxNoAckRequestedCount" }, + { 0x001C, 0, 0x02, "TxDataCount" }, + { 0x001D, 0, 0x02, "TxDataPollCount" }, + { 0x001E, 0, 0x02, "TxBeaconCount" }, + { 0x001F, 0, 0x02, "TxBeaconRequestCount" }, + { 0x0020, 0, 0x02, "TxOtherCount" }, + { 0x0021, 0, 0x02, "TxRetryCount" }, + { 0x0022, 0, 0x02, "TxDirectMaxRetryExpiryCount" }, + { 0x0023, 0, 0x02, "TxIndirectMaxRetryExpiryCount" }, + { 0x0024, 0, 0x02, "TxErrCcaCount" }, + { 0x0025, 0, 0x02, "TxErrAbortCount" }, + { 0x0026, 0, 0x02, "TxErrBusyChannelCount" }, + { 0x0027, 0, 0x02, "RxTotalCount" }, + { 0x0028, 0, 0x02, "RxUnicastCount" }, + { 0x0029, 0, 0x02, "RxBroadcastCount" }, + { 0x002A, 0, 0x02, "RxDataCount" }, + { 0x002B, 0, 0x02, "RxDataPollCount" }, + { 0x002C, 0, 0x02, "RxBeaconCount" }, + { 0x002D, 0, 0x02, "RxBeaconRequestCount" }, + { 0x002E, 0, 0x02, "RxOtherCount" }, + { 0x002F, 0, 0x02, "RxAddressFilteredCount" }, + { 0x0030, 0, 0x02, "RxDestAddrFilteredCount" }, + { 0x0031, 0, 0x02, "RxDuplicatedCount" }, + { 0x0032, 0, 0x02, "RxErrNoFrameCount" }, + { 0x0033, 0, 0x02, "RxErrUnknownNeighborCount" }, + { 0x0034, 0, 0x02, "RxErrInvalidSrcAddrCount" }, + { 0x0035, 0, 0x02, "RxErrSecCount" }, + { 0x0036, 0, 0x02, "RxErrFcsCount" }, + { 0x0037, 0, 0x02, "RxErrOtherCount" }, + { 0x0038, 0, 0x02, "ActiveTimestamp" }, + { 0x0039, 0, 0x02, "PendingTimestamp" }, + { 0x003A, 0, 0x02, "Delay" }, + { 0x003B, 0, 0x02, "SecurityPolicy" }, + { 0x003C, 0, 0x02, "ChannelPage0Mask" }, + { 0x003D, 0, 0x02, "OperationalDatasetComponents" }, + { 0x003E, 0, 0x02, "ActiveNetworkFaultsList" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -599,24 +599,24 @@ const matter_command_t matter_Commands_0035[] = { }; const matter_attribute_t matter_Attributes_0036[] = { - { 0x0000, 0, 0x00, "Bssid" }, - { 0x0001, 0, 0x00, "SecurityType" }, - { 0x0002, 0, 0x00, "WiFiVersion" }, - { 0x0003, 0, 0x00, "ChannelNumber" }, - { 0x0004, 0, 0x00, "Rssi" }, - { 0x0005, 0, 0x00, "BeaconLostCount" }, - { 0x0006, 0, 0x00, "BeaconRxCount" }, - { 0x0007, 0, 0x00, "PacketMulticastRxCount" }, - { 0x0008, 0, 0x00, "PacketMulticastTxCount" }, - { 0x0009, 0, 0x00, "PacketUnicastRxCount" }, - { 0x000A, 0, 0x00, "PacketUnicastTxCount" }, - { 0x000B, 0, 0x00, "CurrentMaxRate" }, - { 0x000C, 0, 0x00, "OverrunCount" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Bssid" }, + { 0x0001, 0, 0x02, "SecurityType" }, + { 0x0002, 0, 0x02, "WiFiVersion" }, + { 0x0003, 0, 0x02, "ChannelNumber" }, + { 0x0004, 0, 0x02, "Rssi" }, + { 0x0005, 0, 0x02, "BeaconLostCount" }, + { 0x0006, 0, 0x02, "BeaconRxCount" }, + { 0x0007, 0, 0x02, "PacketMulticastRxCount" }, + { 0x0008, 0, 0x02, "PacketMulticastTxCount" }, + { 0x0009, 0, 0x02, "PacketUnicastRxCount" }, + { 0x000A, 0, 0x02, "PacketUnicastTxCount" }, + { 0x000B, 0, 0x02, "CurrentMaxRate" }, + { 0x000C, 0, 0x02, "OverrunCount" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -626,20 +626,20 @@ const matter_command_t matter_Commands_0036[] = { }; const matter_attribute_t matter_Attributes_0037[] = { - { 0x0000, 0, 0x00, "PHYRate" }, - { 0x0001, 0, 0x00, "FullDuplex" }, - { 0x0002, 0, 0x00, "PacketRxCount" }, - { 0x0003, 0, 0x00, "PacketTxCount" }, - { 0x0004, 0, 0x00, "TxErrCount" }, - { 0x0005, 0, 0x00, "CollisionCount" }, - { 0x0006, 0, 0x00, "OverrunCount" }, - { 0x0007, 0, 0x00, "CarrierDetect" }, - { 0x0008, 0, 0x00, "TimeSinceReset" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "PHYRate" }, + { 0x0001, 0, 0x02, "FullDuplex" }, + { 0x0002, 0, 0x02, "PacketRxCount" }, + { 0x0003, 0, 0x02, "PacketTxCount" }, + { 0x0004, 0, 0x02, "TxErrCount" }, + { 0x0005, 0, 0x02, "CollisionCount" }, + { 0x0006, 0, 0x02, "OverrunCount" }, + { 0x0007, 0, 0x02, "CarrierDetect" }, + { 0x0008, 0, 0x02, "TimeSinceReset" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -649,26 +649,26 @@ const matter_command_t matter_Commands_0037[] = { }; const matter_attribute_t matter_Attributes_0039[] = { - { 0x0001, 0, 0x00, "VendorName" }, - { 0x0002, 0, 0x00, "VendorID" }, - { 0x0003, 0, 0x00, "ProductName" }, - { 0x0005, 0, 0x00, "NodeLabel" }, - { 0x0007, 0, 0x00, "HardwareVersion" }, - { 0x0008, 0, 0x00, "HardwareVersionString" }, - { 0x0009, 0, 0x00, "SoftwareVersion" }, - { 0x000A, 0, 0x00, "SoftwareVersionString" }, - { 0x000B, 0, 0x00, "ManufacturingDate" }, - { 0x000C, 0, 0x00, "PartNumber" }, - { 0x000D, 0, 0x00, "ProductURL" }, - { 0x000E, 0, 0x00, "ProductLabel" }, - { 0x000F, 0, 0x00, "SerialNumber" }, - { 0x0011, 0, 0x00, "Reachable" }, - { 0x0012, 0, 0x00, "UniqueID" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0001, 0, 0x02, "VendorName" }, + { 0x0002, 0, 0x02, "VendorID" }, + { 0x0003, 0, 0x02, "ProductName" }, + { 0x0005, 0, 0x03, "NodeLabel" }, + { 0x0007, 0, 0x02, "HardwareVersion" }, + { 0x0008, 0, 0x02, "HardwareVersionString" }, + { 0x0009, 0, 0x02, "SoftwareVersion" }, + { 0x000A, 0, 0x02, "SoftwareVersionString" }, + { 0x000B, 0, 0x02, "ManufacturingDate" }, + { 0x000C, 0, 0x02, "PartNumber" }, + { 0x000D, 0, 0x02, "ProductURL" }, + { 0x000E, 0, 0x02, "ProductLabel" }, + { 0x000F, 0, 0x02, "SerialNumber" }, + { 0x0011, 0, 0x02, "Reachable" }, + { 0x0012, 0, 0x02, "UniqueID" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -677,14 +677,14 @@ const matter_command_t matter_Commands_0039[] = { }; const matter_attribute_t matter_Attributes_003B[] = { - { 0x0000, 0, 0x00, "NumberOfPositions" }, - { 0x0001, 0, 0x00, "CurrentPosition" }, - { 0x0002, 0, 0x00, "MultiPressMax" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "NumberOfPositions" }, + { 0x0001, 0, 0x02, "CurrentPosition" }, + { 0x0002, 0, 0x02, "MultiPressMax" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -693,14 +693,14 @@ const matter_command_t matter_Commands_003B[] = { }; const matter_attribute_t matter_Attributes_003C[] = { - { 0x0000, 0, 0x00, "WindowStatus" }, - { 0x0001, 0, 0x00, "AdminFabricIndex" }, - { 0x0002, 0, 0x00, "AdminVendorId" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "WindowStatus" }, + { 0x0001, 0, 0x02, "AdminFabricIndex" }, + { 0x0002, 0, 0x02, "AdminVendorId" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -712,17 +712,17 @@ const matter_command_t matter_Commands_003C[] = { }; const matter_attribute_t matter_Attributes_003E[] = { - { 0x0000, 0, 0x00, "NOCs" }, - { 0x0001, 0, 0x00, "Fabrics" }, - { 0x0002, 0, 0x00, "SupportedFabrics" }, - { 0x0003, 0, 0x00, "CommissionedFabrics" }, - { 0x0004, 0, 0x00, "TrustedRootCertificates" }, - { 0x0005, 0, 0x00, "CurrentFabricIndex" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "NOCs" }, + { 0x0001, 0, 0x02, "Fabrics" }, + { 0x0002, 0, 0x02, "SupportedFabrics" }, + { 0x0003, 0, 0x02, "CommissionedFabrics" }, + { 0x0004, 0, 0x02, "TrustedRootCertificates" }, + { 0x0005, 0, 0x02, "CurrentFabricIndex" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -743,15 +743,15 @@ const matter_command_t matter_Commands_003E[] = { }; const matter_attribute_t matter_Attributes_003F[] = { - { 0x0000, 0, 0x00, "GroupKeyMap" }, - { 0x0001, 0, 0x00, "GroupTable" }, - { 0x0002, 0, 0x00, "MaxGroupsPerFabric" }, - { 0x0003, 0, 0x00, "MaxGroupKeysPerFabric" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "GroupKeyMap" }, + { 0x0001, 0, 0x02, "GroupTable" }, + { 0x0002, 0, 0x02, "MaxGroupsPerFabric" }, + { 0x0003, 0, 0x02, "MaxGroupKeysPerFabric" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -764,12 +764,12 @@ const matter_command_t matter_Commands_003F[] = { }; const matter_attribute_t matter_Attributes_0040[] = { - { 0x0000, 0, 0x00, "LabelList" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "LabelList" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -778,11 +778,11 @@ const matter_command_t matter_Commands_0040[] = { }; const matter_attribute_t matter_Attributes_0041[] = { - { 0x0000, 0, 0x00, "LabelList" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "LabelList" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -791,12 +791,12 @@ const matter_command_t matter_Commands_0041[] = { }; const matter_attribute_t matter_Attributes_0045[] = { - { 0x0000, 0, 0x00, "StateValue" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "StateValue" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -805,17 +805,17 @@ const matter_command_t matter_Commands_0045[] = { }; const matter_attribute_t matter_Attributes_0050[] = { - { 0x0000, 0, 0x00, "Description" }, - { 0x0001, 0, 0x00, "StandardNamespace" }, - { 0x0002, 0, 0x00, "SupportedModes" }, - { 0x0003, 0, 0x00, "CurrentMode" }, - { 0x0004, 0, 0x00, "StartUpMode" }, - { 0x0005, 0, 0x00, "OnMode" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Description" }, + { 0x0001, 0, 0x02, "StandardNamespace" }, + { 0x0002, 0, 0x02, "SupportedModes" }, + { 0x0003, 0, 0x02, "CurrentMode" }, + { 0x0004, 0, 0x03, "StartUpMode" }, + { 0x0005, 0, 0x03, "OnMode" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -825,36 +825,36 @@ const matter_command_t matter_Commands_0050[] = { }; const matter_attribute_t matter_Attributes_0101[] = { - { 0x0000, 0, 0x00, "LockState" }, - { 0x0001, 0, 0x00, "LockType" }, - { 0x0002, 0, 0x00, "ActuatorEnabled" }, - { 0x0003, 0, 0x00, "DoorState" }, - { 0x0011, 0, 0x00, "NumberOfTotalUsersSupported" }, - { 0x0012, 0, 0x00, "NumberOfPINUsersSupported" }, - { 0x0013, 0, 0x00, "NumberOfRFIDUsersSupported" }, - { 0x0014, 0, 0x00, "NumberOfWeekDaySchedulesSupportedPerUser" }, - { 0x0015, 0, 0x00, "NumberOfYearDaySchedulesSupportedPerUser" }, - { 0x0016, 0, 0x00, "NumberOfHolidaySchedulesSupported" }, - { 0x0017, 0, 0x00, "MaxPINCodeLength" }, - { 0x0018, 0, 0x00, "MinPINCodeLength" }, - { 0x0019, 0, 0x00, "MaxRFIDCodeLength" }, - { 0x001A, 0, 0x00, "MinRFIDCodeLength" }, - { 0x001C, 0, 0x00, "NumberOfCredentialsSupportedPerUser" }, - { 0x0021, 0, 0x00, "Language" }, - { 0x0023, 0, 0x00, "AutoRelockTime" }, - { 0x0024, 0, 0x00, "SoundVolume" }, - { 0x0025, 0, 0x00, "OperatingMode" }, - { 0x0026, 0, 0x00, "SupportedOperatingModes" }, - { 0x0029, 0, 0x00, "EnableOneTouchLocking" }, - { 0x002B, 0, 0x00, "EnablePrivacyModeButton" }, - { 0x0030, 0, 0x00, "WrongCodeEntryLimit" }, - { 0x0031, 0, 0x00, "UserCodeTemporaryDisableTime" }, - { 0x0033, 0, 0x00, "RequirePINforRemoteOperation" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "LockState" }, + { 0x0001, 0, 0x02, "LockType" }, + { 0x0002, 0, 0x02, "ActuatorEnabled" }, + { 0x0003, 0, 0x02, "DoorState" }, + { 0x0011, 0, 0x02, "NumberOfTotalUsersSupported" }, + { 0x0012, 0, 0x02, "NumberOfPINUsersSupported" }, + { 0x0013, 0, 0x02, "NumberOfRFIDUsersSupported" }, + { 0x0014, 0, 0x02, "NumberOfWeekDaySchedulesSupportedPerUser" }, + { 0x0015, 0, 0x02, "NumberOfYearDaySchedulesSupportedPerUser" }, + { 0x0016, 0, 0x02, "NumberOfHolidaySchedulesSupported" }, + { 0x0017, 0, 0x02, "MaxPINCodeLength" }, + { 0x0018, 0, 0x02, "MinPINCodeLength" }, + { 0x0019, 0, 0x02, "MaxRFIDCodeLength" }, + { 0x001A, 0, 0x02, "MinRFIDCodeLength" }, + { 0x001C, 0, 0x02, "NumberOfCredentialsSupportedPerUser" }, + { 0x0021, 0, 0x03, "Language" }, + { 0x0023, 0, 0x03, "AutoRelockTime" }, + { 0x0024, 0, 0x03, "SoundVolume" }, + { 0x0025, 0, 0x03, "OperatingMode" }, + { 0x0026, 0, 0x02, "SupportedOperatingModes" }, + { 0x0029, 0, 0x03, "EnableOneTouchLocking" }, + { 0x002B, 0, 0x03, "EnablePrivacyModeButton" }, + { 0x0030, 0, 0x03, "WrongCodeEntryLimit" }, + { 0x0031, 0, 0x03, "UserCodeTemporaryDisableTime" }, + { 0x0033, 0, 0x01, "RequirePINforRemoteOperation" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -881,33 +881,33 @@ const matter_command_t matter_Commands_0101[] = { }; const matter_attribute_t matter_Attributes_0102[] = { - { 0x0000, 0, 0x00, "Type" }, - { 0x0001, 0, 0x00, "PhysicalClosedLimitLift" }, - { 0x0002, 0, 0x00, "PhysicalClosedLimitTilt" }, - { 0x0003, 0, 0x00, "CurrentPositionLift" }, - { 0x0004, 0, 0x00, "CurrentPositionTilt" }, - { 0x0005, 0, 0x00, "NumberOfActuationsLift" }, - { 0x0006, 0, 0x00, "NumberOfActuationsTilt" }, - { 0x0007, 0, 0x00, "ConfigStatus" }, - { 0x0008, 0, 0x00, "CurrentPositionLiftPercentage" }, - { 0x0009, 0, 0x00, "CurrentPositionTiltPercentage" }, - { 0x000A, 0, 0x00, "OperationalStatus" }, - { 0x000B, 0, 0x00, "TargetPositionLiftPercent100ths" }, - { 0x000C, 0, 0x00, "TargetPositionTiltPercent100ths" }, - { 0x000D, 0, 0x00, "EndProductType" }, - { 0x000E, 0, 0x00, "CurrentPositionLiftPercent100ths" }, - { 0x000F, 0, 0x00, "CurrentPositionTiltPercent100ths" }, - { 0x0010, 0, 0x00, "InstalledOpenLimitLift" }, - { 0x0011, 0, 0x00, "InstalledClosedLimitLift" }, - { 0x0012, 0, 0x00, "InstalledOpenLimitTilt" }, - { 0x0013, 0, 0x00, "InstalledClosedLimitTilt" }, - { 0x0017, 0, 0x00, "Mode" }, - { 0x001A, 0, 0x00, "SafetyStatus" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Type" }, + { 0x0001, 0, 0x02, "PhysicalClosedLimitLift" }, + { 0x0002, 0, 0x02, "PhysicalClosedLimitTilt" }, + { 0x0003, 0, 0x02, "CurrentPositionLift" }, + { 0x0004, 0, 0x02, "CurrentPositionTilt" }, + { 0x0005, 0, 0x02, "NumberOfActuationsLift" }, + { 0x0006, 0, 0x02, "NumberOfActuationsTilt" }, + { 0x0007, 0, 0x02, "ConfigStatus" }, + { 0x0008, 0, 0x02, "CurrentPositionLiftPercentage" }, + { 0x0009, 0, 0x02, "CurrentPositionTiltPercentage" }, + { 0x000A, 0, 0x02, "OperationalStatus" }, + { 0x000B, 0, 0x02, "TargetPositionLiftPercent100ths" }, + { 0x000C, 0, 0x02, "TargetPositionTiltPercent100ths" }, + { 0x000D, 0, 0x02, "EndProductType" }, + { 0x000E, 0, 0x02, "CurrentPositionLiftPercent100ths" }, + { 0x000F, 0, 0x02, "CurrentPositionTiltPercent100ths" }, + { 0x0010, 0, 0x02, "InstalledOpenLimitLift" }, + { 0x0011, 0, 0x02, "InstalledClosedLimitLift" }, + { 0x0012, 0, 0x02, "InstalledOpenLimitTilt" }, + { 0x0013, 0, 0x02, "InstalledClosedLimitTilt" }, + { 0x0017, 0, 0x03, "Mode" }, + { 0x001A, 0, 0x02, "SafetyStatus" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -923,15 +923,15 @@ const matter_command_t matter_Commands_0102[] = { }; const matter_attribute_t matter_Attributes_0103[] = { - { 0x0001, 0, 0x00, "BarrierMovingState" }, - { 0x0002, 0, 0x00, "BarrierSafetyStatus" }, - { 0x0003, 0, 0x00, "BarrierCapabilities" }, - { 0x000A, 0, 0x00, "BarrierPosition" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0001, 0, 0x02, "BarrierMovingState" }, + { 0x0002, 0, 0x02, "BarrierSafetyStatus" }, + { 0x0003, 0, 0x02, "BarrierCapabilities" }, + { 0x000A, 0, 0x02, "BarrierPosition" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -942,34 +942,34 @@ const matter_command_t matter_Commands_0103[] = { }; const matter_attribute_t matter_Attributes_0200[] = { - { 0x0000, 0, 0x00, "MaxPressure" }, - { 0x0001, 0, 0x00, "MaxSpeed" }, - { 0x0002, 0, 0x00, "MaxFlow" }, - { 0x0003, 0, 0x00, "MinConstPressure" }, - { 0x0004, 0, 0x00, "MaxConstPressure" }, - { 0x0005, 0, 0x00, "MinCompPressure" }, - { 0x0006, 0, 0x00, "MaxCompPressure" }, - { 0x0007, 0, 0x00, "MinConstSpeed" }, - { 0x0008, 0, 0x00, "MaxConstSpeed" }, - { 0x0009, 0, 0x00, "MinConstFlow" }, - { 0x000A, 0, 0x00, "MaxConstFlow" }, - { 0x000B, 0, 0x00, "MinConstTemp" }, - { 0x000C, 0, 0x00, "MaxConstTemp" }, - { 0x0010, 0, 0x00, "PumpStatus" }, - { 0x0011, 0, 0x00, "EffectiveOperationMode" }, - { 0x0012, 0, 0x00, "EffectiveControlMode" }, - { 0x0013, 0, 0x00, "Capacity" }, - { 0x0014, 0, 0x00, "Speed" }, - { 0x0015, 0, 0x00, "LifetimeRunningHours" }, - { 0x0016, 0, 0x00, "Power" }, - { 0x0017, 0, 0x00, "LifetimeEnergyConsumed" }, - { 0x0020, 0, 0x00, "OperationMode" }, - { 0x0021, 0, 0x00, "ControlMode" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MaxPressure" }, + { 0x0001, 0, 0x02, "MaxSpeed" }, + { 0x0002, 0, 0x02, "MaxFlow" }, + { 0x0003, 0, 0x02, "MinConstPressure" }, + { 0x0004, 0, 0x02, "MaxConstPressure" }, + { 0x0005, 0, 0x02, "MinCompPressure" }, + { 0x0006, 0, 0x02, "MaxCompPressure" }, + { 0x0007, 0, 0x02, "MinConstSpeed" }, + { 0x0008, 0, 0x02, "MaxConstSpeed" }, + { 0x0009, 0, 0x02, "MinConstFlow" }, + { 0x000A, 0, 0x02, "MaxConstFlow" }, + { 0x000B, 0, 0x02, "MinConstTemp" }, + { 0x000C, 0, 0x02, "MaxConstTemp" }, + { 0x0010, 0, 0x02, "PumpStatus" }, + { 0x0011, 0, 0x02, "EffectiveOperationMode" }, + { 0x0012, 0, 0x02, "EffectiveControlMode" }, + { 0x0013, 0, 0x02, "Capacity" }, + { 0x0014, 0, 0x02, "Speed" }, + { 0x0015, 0, 0x03, "LifetimeRunningHours" }, + { 0x0016, 0, 0x02, "Power" }, + { 0x0017, 0, 0x03, "LifetimeEnergyConsumed" }, + { 0x0020, 0, 0x03, "OperationMode" }, + { 0x0021, 0, 0x03, "ControlMode" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -978,26 +978,26 @@ const matter_command_t matter_Commands_0200[] = { }; const matter_attribute_t matter_Attributes_0201[] = { - { 0x0000, 0, 0x00, "LocalTemperature" }, - { 0x0003, 0, 0x00, "AbsMinHeatSetpointLimit" }, - { 0x0004, 0, 0x00, "AbsMaxHeatSetpointLimit" }, - { 0x0005, 0, 0x00, "AbsMinCoolSetpointLimit" }, - { 0x0006, 0, 0x00, "AbsMaxCoolSetpointLimit" }, - { 0x0011, 0, 0x00, "OccupiedCoolingSetpoint" }, - { 0x0012, 0, 0x00, "OccupiedHeatingSetpoint" }, - { 0x0015, 0, 0x00, "MinHeatSetpointLimit" }, - { 0x0016, 0, 0x00, "MaxHeatSetpointLimit" }, - { 0x0017, 0, 0x00, "MinCoolSetpointLimit" }, - { 0x0018, 0, 0x00, "MaxCoolSetpointLimit" }, - { 0x0019, 0, 0x00, "MinSetpointDeadBand" }, - { 0x001B, 0, 0x00, "ControlSequenceOfOperation" }, - { 0x001C, 0, 0x00, "SystemMode" }, - { 0x0020, 0, 0x00, "StartOfWeek" }, - { 0x0021, 0, 0x00, "NumberOfWeeklyTransitions" }, - { 0x0022, 0, 0x00, "NumberOfDailyTransitions" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "LocalTemperature" }, + { 0x0003, 0, 0x02, "AbsMinHeatSetpointLimit" }, + { 0x0004, 0, 0x02, "AbsMaxHeatSetpointLimit" }, + { 0x0005, 0, 0x02, "AbsMinCoolSetpointLimit" }, + { 0x0006, 0, 0x02, "AbsMaxCoolSetpointLimit" }, + { 0x0011, 0, 0x03, "OccupiedCoolingSetpoint" }, + { 0x0012, 0, 0x03, "OccupiedHeatingSetpoint" }, + { 0x0015, 0, 0x03, "MinHeatSetpointLimit" }, + { 0x0016, 0, 0x03, "MaxHeatSetpointLimit" }, + { 0x0017, 0, 0x03, "MinCoolSetpointLimit" }, + { 0x0018, 0, 0x03, "MaxCoolSetpointLimit" }, + { 0x0019, 0, 0x03, "MinSetpointDeadBand" }, + { 0x001B, 0, 0x03, "ControlSequenceOfOperation" }, + { 0x001C, 0, 0x03, "SystemMode" }, + { 0x0020, 0, 0x02, "StartOfWeek" }, + { 0x0021, 0, 0x02, "NumberOfWeeklyTransitions" }, + { 0x0022, 0, 0x02, "NumberOfDailyTransitions" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1010,22 +1010,22 @@ const matter_command_t matter_Commands_0201[] = { }; const matter_attribute_t matter_Attributes_0202[] = { - { 0x0000, 0, 0x00, "FanMode" }, - { 0x0001, 0, 0x00, "FanModeSequence" }, - { 0x0002, 0, 0x00, "PercentSetting" }, - { 0x0003, 0, 0x00, "PercentCurrent" }, - { 0x0004, 0, 0x00, "SpeedMax" }, - { 0x0005, 0, 0x00, "SpeedSetting" }, - { 0x0006, 0, 0x00, "SpeedCurrent" }, - { 0x0007, 0, 0x00, "RockSupport" }, - { 0x0008, 0, 0x00, "RockSetting" }, - { 0x0009, 0, 0x00, "WindSupport" }, - { 0x000A, 0, 0x00, "WindSetting" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "FanMode" }, + { 0x0001, 0, 0x03, "FanModeSequence" }, + { 0x0002, 0, 0x03, "PercentSetting" }, + { 0x0003, 0, 0x02, "PercentCurrent" }, + { 0x0004, 0, 0x02, "SpeedMax" }, + { 0x0005, 0, 0x03, "SpeedSetting" }, + { 0x0006, 0, 0x02, "SpeedCurrent" }, + { 0x0007, 0, 0x02, "RockSupport" }, + { 0x0008, 0, 0x03, "RockSetting" }, + { 0x0009, 0, 0x02, "WindSupport" }, + { 0x000A, 0, 0x03, "WindSetting" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1034,14 +1034,14 @@ const matter_command_t matter_Commands_0202[] = { }; const matter_attribute_t matter_Attributes_0204[] = { - { 0x0000, 0, 0x00, "TemperatureDisplayMode" }, - { 0x0001, 0, 0x00, "KeypadLockout" }, - { 0x0002, 0, 0x00, "ScheduleProgrammingVisibility" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x03, "TemperatureDisplayMode" }, + { 0x0001, 0, 0x03, "KeypadLockout" }, + { 0x0002, 0, 0x03, "ScheduleProgrammingVisibility" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1050,63 +1050,63 @@ const matter_command_t matter_Commands_0204[] = { }; const matter_attribute_t matter_Attributes_0300[] = { - { 0x0000, 0, 0x00, "CurrentHue" }, - { 0x0001, 0, 0x00, "CurrentSaturation" }, - { 0x0002, 0, 0x00, "RemainingTime" }, - { 0x0003, 0, 0x00, "CurrentX" }, - { 0x0004, 0, 0x00, "CurrentY" }, - { 0x0005, 0, 0x00, "DriftCompensation" }, - { 0x0006, 0, 0x00, "CompensationText" }, - { 0x0007, 0, 0x00, "ColorTemperatureMireds" }, - { 0x0008, 0, 0x00, "ColorMode" }, - { 0x000F, 0, 0x00, "Options" }, - { 0x0010, 0, 0x00, "NumberOfPrimaries" }, - { 0x0011, 0, 0x00, "Primary1X" }, - { 0x0012, 0, 0x00, "Primary1Y" }, - { 0x0013, 0, 0x00, "Primary1Intensity" }, - { 0x0015, 0, 0x00, "Primary2X" }, - { 0x0016, 0, 0x00, "Primary2Y" }, - { 0x0017, 0, 0x00, "Primary2Intensity" }, - { 0x0019, 0, 0x00, "Primary3X" }, - { 0x001A, 0, 0x00, "Primary3Y" }, - { 0x001B, 0, 0x00, "Primary3Intensity" }, - { 0x0020, 0, 0x00, "Primary4X" }, - { 0x0021, 0, 0x00, "Primary4Y" }, - { 0x0022, 0, 0x00, "Primary4Intensity" }, - { 0x0024, 0, 0x00, "Primary5X" }, - { 0x0025, 0, 0x00, "Primary5Y" }, - { 0x0026, 0, 0x00, "Primary5Intensity" }, - { 0x0028, 0, 0x00, "Primary6X" }, - { 0x0029, 0, 0x00, "Primary6Y" }, - { 0x002A, 0, 0x00, "Primary6Intensity" }, - { 0x0030, 0, 0x00, "WhitePointX" }, - { 0x0031, 0, 0x00, "WhitePointY" }, - { 0x0032, 0, 0x00, "ColorPointRX" }, - { 0x0033, 0, 0x00, "ColorPointRY" }, - { 0x0034, 0, 0x00, "ColorPointRIntensity" }, - { 0x0036, 0, 0x00, "ColorPointGX" }, - { 0x0037, 0, 0x00, "ColorPointGY" }, - { 0x0038, 0, 0x00, "ColorPointGIntensity" }, - { 0x003A, 0, 0x00, "ColorPointBX" }, - { 0x003B, 0, 0x00, "ColorPointBY" }, - { 0x003C, 0, 0x00, "ColorPointBIntensity" }, - { 0x4000, 0, 0x00, "EnhancedCurrentHue" }, - { 0x4001, 0, 0x00, "EnhancedColorMode" }, - { 0x4002, 0, 0x00, "ColorLoopActive" }, - { 0x4003, 0, 0x00, "ColorLoopDirection" }, - { 0x4004, 0, 0x00, "ColorLoopTime" }, - { 0x4005, 0, 0x00, "ColorLoopStartEnhancedHue" }, - { 0x4006, 0, 0x00, "ColorLoopStoredEnhancedHue" }, - { 0x400A, 0, 0x00, "ColorCapabilities" }, - { 0x400B, 0, 0x00, "ColorTempPhysicalMinMireds" }, - { 0x400C, 0, 0x00, "ColorTempPhysicalMaxMireds" }, - { 0x400D, 0, 0x00, "CoupleColorTempToLevelMinMireds" }, - { 0x4010, 0, 0x00, "StartUpColorTemperatureMireds" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "CurrentHue" }, + { 0x0001, 0, 0x02, "CurrentSaturation" }, + { 0x0002, 0, 0x02, "RemainingTime" }, + { 0x0003, 0, 0x02, "CurrentX" }, + { 0x0004, 0, 0x02, "CurrentY" }, + { 0x0005, 0, 0x02, "DriftCompensation" }, + { 0x0006, 0, 0x02, "CompensationText" }, + { 0x0007, 0, 0x02, "ColorTemperatureMireds" }, + { 0x0008, 0, 0x02, "ColorMode" }, + { 0x000F, 0, 0x03, "Options" }, + { 0x0010, 0, 0x02, "NumberOfPrimaries" }, + { 0x0011, 0, 0x02, "Primary1X" }, + { 0x0012, 0, 0x02, "Primary1Y" }, + { 0x0013, 0, 0x02, "Primary1Intensity" }, + { 0x0015, 0, 0x02, "Primary2X" }, + { 0x0016, 0, 0x02, "Primary2Y" }, + { 0x0017, 0, 0x02, "Primary2Intensity" }, + { 0x0019, 0, 0x02, "Primary3X" }, + { 0x001A, 0, 0x02, "Primary3Y" }, + { 0x001B, 0, 0x02, "Primary3Intensity" }, + { 0x0020, 0, 0x02, "Primary4X" }, + { 0x0021, 0, 0x02, "Primary4Y" }, + { 0x0022, 0, 0x02, "Primary4Intensity" }, + { 0x0024, 0, 0x02, "Primary5X" }, + { 0x0025, 0, 0x02, "Primary5Y" }, + { 0x0026, 0, 0x02, "Primary5Intensity" }, + { 0x0028, 0, 0x02, "Primary6X" }, + { 0x0029, 0, 0x02, "Primary6Y" }, + { 0x002A, 0, 0x02, "Primary6Intensity" }, + { 0x0030, 0, 0x03, "WhitePointX" }, + { 0x0031, 0, 0x03, "WhitePointY" }, + { 0x0032, 0, 0x03, "ColorPointRX" }, + { 0x0033, 0, 0x03, "ColorPointRY" }, + { 0x0034, 0, 0x03, "ColorPointRIntensity" }, + { 0x0036, 0, 0x03, "ColorPointGX" }, + { 0x0037, 0, 0x03, "ColorPointGY" }, + { 0x0038, 0, 0x03, "ColorPointGIntensity" }, + { 0x003A, 0, 0x03, "ColorPointBX" }, + { 0x003B, 0, 0x03, "ColorPointBY" }, + { 0x003C, 0, 0x03, "ColorPointBIntensity" }, + { 0x4000, 0, 0x02, "EnhancedCurrentHue" }, + { 0x4001, 0, 0x02, "EnhancedColorMode" }, + { 0x4002, 0, 0x02, "ColorLoopActive" }, + { 0x4003, 0, 0x02, "ColorLoopDirection" }, + { 0x4004, 0, 0x02, "ColorLoopTime" }, + { 0x4005, 0, 0x02, "ColorLoopStartEnhancedHue" }, + { 0x4006, 0, 0x02, "ColorLoopStoredEnhancedHue" }, + { 0x400A, 0, 0x02, "ColorCapabilities" }, + { 0x400B, 0, 0x02, "ColorTempPhysicalMinMireds" }, + { 0x400C, 0, 0x02, "ColorTempPhysicalMaxMireds" }, + { 0x400D, 0, 0x02, "CoupleColorTempToLevelMinMireds" }, + { 0x4010, 0, 0x03, "StartUpColorTemperatureMireds" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1134,25 +1134,25 @@ const matter_command_t matter_Commands_0300[] = { }; const matter_attribute_t matter_Attributes_0301[] = { - { 0x0000, 0, 0x00, "PhysicalMinLevel" }, - { 0x0001, 0, 0x00, "PhysicalMaxLevel" }, - { 0x0002, 0, 0x00, "BallastStatus" }, - { 0x0010, 0, 0x00, "MinLevel" }, - { 0x0011, 0, 0x00, "MaxLevel" }, - { 0x0014, 0, 0x00, "IntrinsicBalanceFactor" }, - { 0x0015, 0, 0x00, "BallastFactorAdjustment" }, - { 0x0020, 0, 0x00, "LampQuantity" }, - { 0x0030, 0, 0x00, "LampType" }, - { 0x0031, 0, 0x00, "LampManufacturer" }, - { 0x0032, 0, 0x00, "LampRatedHours" }, - { 0x0033, 0, 0x00, "LampBurnHours" }, - { 0x0034, 0, 0x00, "LampAlarmMode" }, - { 0x0035, 0, 0x00, "LampBurnHoursTripPoint" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "PhysicalMinLevel" }, + { 0x0001, 0, 0x02, "PhysicalMaxLevel" }, + { 0x0002, 0, 0x02, "BallastStatus" }, + { 0x0010, 0, 0x03, "MinLevel" }, + { 0x0011, 0, 0x03, "MaxLevel" }, + { 0x0014, 0, 0x03, "IntrinsicBalanceFactor" }, + { 0x0015, 0, 0x03, "BallastFactorAdjustment" }, + { 0x0020, 0, 0x02, "LampQuantity" }, + { 0x0030, 0, 0x03, "LampType" }, + { 0x0031, 0, 0x03, "LampManufacturer" }, + { 0x0032, 0, 0x03, "LampRatedHours" }, + { 0x0033, 0, 0x03, "LampBurnHours" }, + { 0x0034, 0, 0x03, "LampAlarmMode" }, + { 0x0035, 0, 0x03, "LampBurnHoursTripPoint" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1161,16 +1161,16 @@ const matter_command_t matter_Commands_0301[] = { }; const matter_attribute_t matter_Attributes_0400[] = { - { 0x0000, 0, 0x00, "MeasuredValue" }, - { 0x0001, 0, 0x00, "MinMeasuredValue" }, - { 0x0002, 0, 0x00, "MaxMeasuredValue" }, - { 0x0003, 0, 0x00, "Tolerance" }, - { 0x0004, 0, 0x00, "LightSensorType" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MeasuredValue" }, + { 0x0001, 0, 0x02, "MinMeasuredValue" }, + { 0x0002, 0, 0x02, "MaxMeasuredValue" }, + { 0x0003, 0, 0x02, "Tolerance" }, + { 0x0004, 0, 0x02, "LightSensorType" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1179,13 +1179,13 @@ const matter_command_t matter_Commands_0400[] = { }; const matter_attribute_t matter_Attributes_0402[] = { - { 0x0000, 0, 0x00, "MeasuredValue" }, - { 0x0001, 0, 0x00, "MinMeasuredValue" }, - { 0x0002, 0, 0x00, "MaxMeasuredValue" }, - { 0x0003, 0, 0x00, "Tolerance" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MeasuredValue" }, + { 0x0001, 0, 0x02, "MinMeasuredValue" }, + { 0x0002, 0, 0x02, "MaxMeasuredValue" }, + { 0x0003, 0, 0x02, "Tolerance" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1194,18 +1194,18 @@ const matter_command_t matter_Commands_0402[] = { }; const matter_attribute_t matter_Attributes_0403[] = { - { 0x0000, 0, 0x00, "MeasuredValue" }, - { 0x0001, 0, 0x00, "MinMeasuredValue" }, - { 0x0002, 0, 0x00, "MaxMeasuredValue" }, - { 0x0003, 0, 0x00, "Tolerance" }, - { 0x0010, 0, 0x00, "ScaledValue" }, - { 0x0011, 0, 0x00, "MinScaledValue" }, - { 0x0012, 0, 0x00, "MaxScaledValue" }, - { 0x0013, 0, 0x00, "ScaledTolerance" }, - { 0x0014, 0, 0x00, "Scale" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MeasuredValue" }, + { 0x0001, 0, 0x02, "MinMeasuredValue" }, + { 0x0002, 0, 0x02, "MaxMeasuredValue" }, + { 0x0003, 0, 0x02, "Tolerance" }, + { 0x0010, 0, 0x02, "ScaledValue" }, + { 0x0011, 0, 0x02, "MinScaledValue" }, + { 0x0012, 0, 0x02, "MaxScaledValue" }, + { 0x0013, 0, 0x02, "ScaledTolerance" }, + { 0x0014, 0, 0x02, "Scale" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1214,15 +1214,15 @@ const matter_command_t matter_Commands_0403[] = { }; const matter_attribute_t matter_Attributes_0404[] = { - { 0x0000, 0, 0x00, "MeasuredValue" }, - { 0x0001, 0, 0x00, "MinMeasuredValue" }, - { 0x0002, 0, 0x00, "MaxMeasuredValue" }, - { 0x0003, 0, 0x00, "Tolerance" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MeasuredValue" }, + { 0x0001, 0, 0x02, "MinMeasuredValue" }, + { 0x0002, 0, 0x02, "MaxMeasuredValue" }, + { 0x0003, 0, 0x02, "Tolerance" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1231,15 +1231,15 @@ const matter_command_t matter_Commands_0404[] = { }; const matter_attribute_t matter_Attributes_0405[] = { - { 0x0000, 0, 0x00, "MeasuredValue" }, - { 0x0001, 0, 0x00, "MinMeasuredValue" }, - { 0x0002, 0, 0x00, "MaxMeasuredValue" }, - { 0x0003, 0, 0x00, "Tolerance" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MeasuredValue" }, + { 0x0001, 0, 0x02, "MinMeasuredValue" }, + { 0x0002, 0, 0x02, "MaxMeasuredValue" }, + { 0x0003, 0, 0x02, "Tolerance" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1248,14 +1248,14 @@ const matter_command_t matter_Commands_0405[] = { }; const matter_attribute_t matter_Attributes_0406[] = { - { 0x0000, 0, 0x00, "Occupancy" }, - { 0x0001, 0, 0x00, "OccupancySensorType" }, - { 0x0002, 0, 0x00, "OccupancySensorTypeBitmap" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "Occupancy" }, + { 0x0001, 0, 0x02, "OccupancySensorType" }, + { 0x0002, 0, 0x02, "OccupancySensorTypeBitmap" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1264,12 +1264,12 @@ const matter_command_t matter_Commands_0406[] = { }; const matter_attribute_t matter_Attributes_0503[] = { - { 0x0000, 0, 0x00, "MACAddress" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MACAddress" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1278,14 +1278,14 @@ const matter_command_t matter_Commands_0503[] = { }; const matter_attribute_t matter_Attributes_0504[] = { - { 0x0000, 0, 0x00, "ChannelList" }, - { 0x0001, 0, 0x00, "Lineup" }, - { 0x0002, 0, 0x00, "CurrentChannel" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "ChannelList" }, + { 0x0001, 0, 0x02, "Lineup" }, + { 0x0002, 0, 0x02, "CurrentChannel" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1297,13 +1297,13 @@ const matter_command_t matter_Commands_0504[] = { }; const matter_attribute_t matter_Attributes_0505[] = { - { 0x0000, 0, 0x00, "TargetList" }, - { 0x0001, 0, 0x00, "CurrentTarget" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "TargetList" }, + { 0x0001, 0, 0x02, "CurrentTarget" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1313,18 +1313,18 @@ const matter_command_t matter_Commands_0505[] = { }; const matter_attribute_t matter_Attributes_0506[] = { - { 0x0000, 0, 0x00, "CurrentState" }, - { 0x0001, 0, 0x00, "StartTime" }, - { 0x0002, 0, 0x00, "Duration" }, - { 0x0003, 0, 0x00, "SampledPosition" }, - { 0x0004, 0, 0x00, "PlaybackSpeed" }, - { 0x0005, 0, 0x00, "SeekRangeEnd" }, - { 0x0006, 0, 0x00, "SeekRangeStart" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "CurrentState" }, + { 0x0001, 0, 0x02, "StartTime" }, + { 0x0002, 0, 0x02, "Duration" }, + { 0x0003, 0, 0x02, "SampledPosition" }, + { 0x0004, 0, 0x02, "PlaybackSpeed" }, + { 0x0005, 0, 0x02, "SeekRangeEnd" }, + { 0x0006, 0, 0x02, "SeekRangeStart" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1344,13 +1344,13 @@ const matter_command_t matter_Commands_0506[] = { }; const matter_attribute_t matter_Attributes_0507[] = { - { 0x0000, 0, 0x00, "InputList" }, - { 0x0001, 0, 0x00, "CurrentInput" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "InputList" }, + { 0x0001, 0, 0x02, "CurrentInput" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1363,11 +1363,11 @@ const matter_command_t matter_Commands_0507[] = { }; const matter_attribute_t matter_Attributes_0508[] = { - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1377,11 +1377,11 @@ const matter_command_t matter_Commands_0508[] = { }; const matter_attribute_t matter_Attributes_0509[] = { - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1391,13 +1391,13 @@ const matter_command_t matter_Commands_0509[] = { }; const matter_attribute_t matter_Attributes_050A[] = { - { 0x0000, 0, 0x00, "AcceptHeader" }, - { 0x0001, 0, 0x00, "SupportedStreamingProtocols" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "AcceptHeader" }, + { 0x0001, 0, 0x03, "SupportedStreamingProtocols" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1408,13 +1408,13 @@ const matter_command_t matter_Commands_050A[] = { }; const matter_attribute_t matter_Attributes_050B[] = { - { 0x0000, 0, 0x00, "OutputList" }, - { 0x0001, 0, 0x00, "CurrentOutput" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "OutputList" }, + { 0x0001, 0, 0x02, "CurrentOutput" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1425,13 +1425,13 @@ const matter_command_t matter_Commands_050B[] = { }; const matter_attribute_t matter_Attributes_050C[] = { - { 0x0000, 0, 0x00, "CatalogList" }, - { 0x0001, 0, 0x00, "CurrentApp" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "CatalogList" }, + { 0x0001, 0, 0x03, "CurrentApp" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1443,19 +1443,19 @@ const matter_command_t matter_Commands_050C[] = { }; const matter_attribute_t matter_Attributes_050D[] = { - { 0x0000, 0, 0x00, "VendorName" }, - { 0x0001, 0, 0x00, "VendorID" }, - { 0x0002, 0, 0x00, "ApplicationName" }, - { 0x0003, 0, 0x00, "ProductID" }, - { 0x0004, 0, 0x00, "Application" }, - { 0x0005, 0, 0x00, "Status" }, - { 0x0006, 0, 0x00, "ApplicationVersion" }, - { 0x0007, 0, 0x00, "AllowedVendorList" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "VendorName" }, + { 0x0001, 0, 0x02, "VendorID" }, + { 0x0002, 0, 0x02, "ApplicationName" }, + { 0x0003, 0, 0x02, "ProductID" }, + { 0x0004, 0, 0x02, "Application" }, + { 0x0005, 0, 0x02, "Status" }, + { 0x0006, 0, 0x02, "ApplicationVersion" }, + { 0x0007, 0, 0x02, "AllowedVendorList" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1464,11 +1464,11 @@ const matter_command_t matter_Commands_050D[] = { }; const matter_attribute_t matter_Attributes_050E[] = { - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; @@ -1480,22 +1480,22 @@ const matter_command_t matter_Commands_050E[] = { }; const matter_attribute_t matter_Attributes_0B04[] = { - { 0x0000, 0, 0x00, "MeasurementType" }, - { 0x0304, 0, 0x00, "TotalActivePower" }, - { 0x0505, 0, 0x00, "RmsVoltage" }, - { 0x0506, 0, 0x00, "RmsVoltageMin" }, - { 0x0507, 0, 0x00, "RmsVoltageMax" }, - { 0x0508, 0, 0x00, "RmsCurrent" }, - { 0x0509, 0, 0x00, "RmsCurrentMin" }, - { 0x050A, 0, 0x00, "RmsCurrentMax" }, - { 0x050B, 0, 0x00, "ActivePower" }, - { 0x050C, 0, 0x00, "ActivePowerMin" }, - { 0x050D, 0, 0x00, "ActivePowerMax" }, - { 0xFFF8, 0, 0x00, "GeneratedCommandList" }, - { 0xFFF9, 0, 0x00, "AcceptedCommandList" }, - { 0xFFFB, 0, 0x00, "AttributeList" }, - { 0xFFFC, 0, 0x00, "FeatureMap" }, - { 0xFFFD, 0, 0x00, "ClusterRevision" }, + { 0x0000, 0, 0x02, "MeasurementType" }, + { 0x0304, 0, 0x02, "TotalActivePower" }, + { 0x0505, 0, 0x02, "RmsVoltage" }, + { 0x0506, 0, 0x02, "RmsVoltageMin" }, + { 0x0507, 0, 0x02, "RmsVoltageMax" }, + { 0x0508, 0, 0x02, "RmsCurrent" }, + { 0x0509, 0, 0x02, "RmsCurrentMin" }, + { 0x050A, 0, 0x02, "RmsCurrentMax" }, + { 0x050B, 0, 0x02, "ActivePower" }, + { 0x050C, 0, 0x02, "ActivePowerMin" }, + { 0x050D, 0, 0x02, "ActivePowerMax" }, + { 0xFFF8, 0, 0x02, "GeneratedCommandList" }, + { 0xFFF9, 0, 0x02, "AcceptedCommandList" }, + { 0xFFFB, 0, 0x02, "AttributeList" }, + { 0xFFFC, 0, 0x02, "FeatureMap" }, + { 0xFFFD, 0, 0x02, "ClusterRevision" }, { 0xFFFF, 0, 0x00, NULL }, }; diff --git a/lib/libesp32/berry_matter/src/be_matter_module.c b/lib/libesp32/berry_matter/src/be_matter_module.c index dce07d4f7..3c65d9f84 100644 --- a/lib/libesp32/berry_matter/src/be_matter_module.c +++ b/lib/libesp32/berry_matter/src/be_matter_module.c @@ -80,6 +80,34 @@ const char* matter_get_attribute_name(uint16_t cluster, uint16_t attribute) { } BE_FUNC_CTYPE_DECLARE(matter_get_attribute_name, "s", "ii") +bbool matter_is_attribute_writable(uint16_t cluster, uint16_t attribute) { + for (const matter_cluster_t * cl = matterAllClusters; cl->id != 0xFFFF; cl++) { + if (cl->id == cluster) { + for (const matter_attribute_t * at = cl->attributes; at->id != 0xFFFF; at++) { + if (at->id == attribute) { + return (at->flags & 0x01) ? btrue : bfalse; + } + } + } + } + return bfalse; +} +BE_FUNC_CTYPE_DECLARE(matter_is_attribute_writable, "b", "ii") + +bbool matter_is_attribute_reportable(uint16_t cluster, uint16_t attribute) { + for (const matter_cluster_t * cl = matterAllClusters; cl->id != 0xFFFF; cl++) { + if (cl->id == cluster) { + for (const matter_attribute_t * at = cl->attributes; at->id != 0xFFFF; at++) { + if (at->id == attribute) { + return (at->flags & 0x02) ? btrue : bfalse; + } + } + } + } + return bfalse; +} +BE_FUNC_CTYPE_DECLARE(matter_is_attribute_reportable, "b", "ii") + const char* matter_get_command_name(uint16_t cluster, uint16_t command) { for (const matter_cluster_t * cl = matterAllClusters; cl->id != 0xFFFF; cl++) { if (cl->id == cluster) { @@ -110,6 +138,8 @@ extern const bclass be_class_Matter_TLV; // need to declare it upfront because #include "solidify/solidified_Matter_Commissioning.h" #include "solidify/solidified_Matter_Message.h" #include "solidify/solidified_Matter_MessageHandler.h" +#include "solidify/solidified_Matter_IM_Message.h" +#include "solidify/solidified_Matter_IM_Subscription.h" #include "solidify/solidified_Matter_IM.h" #include "solidify/solidified_Matter_Plugin.h" #include "solidify/solidified_Matter_Base38.h" @@ -118,8 +148,8 @@ extern const bclass be_class_Matter_TLV; // need to declare it upfront because #include "../generate/be_matter_certs.h" -#include "solidify/solidified_Matter_Plugin_core.h" -#include "solidify/solidified_Matter_Plugin_Relay.h" +#include "solidify/solidified_Matter_Plugin_Root.h" +#include "solidify/solidified_Matter_Plugin_OnOff.h" /*********************************************************************************************\ * Get a bytes() object of the certificate DAC/PAI_Cert @@ -158,6 +188,8 @@ module matter (scope: global) { get_cluster_name, ctype_func(matter_get_cluster_name) get_attribute_name, ctype_func(matter_get_attribute_name) + is_attribute_writable, ctype_func(matter_is_attribute_writable) + is_attribute_reportable, ctype_func(matter_is_attribute_reportable) get_command_name, ctype_func(matter_get_command_name) get_opcode_name, ctype_func(matter_get_opcode_name) TLV, class(be_class_Matter_TLV) @@ -247,9 +279,16 @@ module matter (scope: global) { MessageHandler, class(be_class_Matter_MessageHandler) // Interation Model - Response_container, class(be_class_Matter_Response_container) + Path, class(be_class_Matter_Path) + IM_Status, class(be_class_Matter_IM_Status) + IM_InvokeResponse, class(be_class_Matter_IM_InvokeResponse) + IM_WriteResponse, class(be_class_Matter_IM_WriteResponse) + IM_ReportData, class(be_class_Matter_IM_ReportData) + IM_ReportDataSubscribed, class(be_class_Matter_IM_ReportDataSubscribed) + IM_SubscribeResponse, class(be_class_Matter_IM_SubscribeResponse) + IM_Subscription, class(be_class_Matter_IM_Subscription) + IM_Subscription_Shop, class(be_class_Matter_IM_Subscription_Shop) IM, class(be_class_Matter_IM) - Plugin_core, class(be_class_Matter_Plugin_core) UI, class(be_class_Matter_UI) // Base38 for QR Code @@ -265,11 +304,11 @@ module matter (scope: global) { DAC_Cert_FFF1_8000, func(matter_DAC_Cert_FFF1_8000) DAC_Pub_FFF1_8000, func(matter_DAC_Pub_FFF1_8000) DAC_Priv_FFF1_8000, func(matter_DAC_Priv_FFF1_8000) - CD_FFF1_8000, func(matter_CD_FFF1_8000) // Certification Declaration + CD_FFF1_8000, func(matter_CD_FFF1_8000) // Certification Declaration // Plugins - Plugin_core, class(be_class_Matter_Plugin_core) // Generic behavior common to all devices - Plugin_Relay, class(be_class_Matter_Plugin_Relay) // Relay behavior (OnOff) + Plugin_Root, class(be_class_Matter_Plugin_Root) // Generic behavior common to all devices + Plugin_OnOff, class(be_class_Matter_Plugin_OnOff) // Relay/Light behavior (OnOff) } @const_object_info_end */ diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be b/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be index d2a5a0fa9..4dfddced7 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be @@ -113,9 +113,9 @@ class Matter_Commisioning_Context pbkdfparamresp.responderSessionId = self.future_local_session_id pbkdfparamresp.pbkdf_parameters_salt = self.device.salt pbkdfparamresp.pbkdf_parameters_iterations = self.device.iterations - tasmota.log("MTR: pbkdfparamresp: " + str(matter.inspect(pbkdfparamresp)), 3) + tasmota.log("MTR: pbkdfparamresp: " + str(matter.inspect(pbkdfparamresp)), 4) var pbkdfparamresp_raw = pbkdfparamresp.encode() - tasmota.log("MTR: pbkdfparamresp_raw: " + pbkdfparamresp_raw.tohex(), 3) + tasmota.log("MTR: pbkdfparamresp_raw: " + pbkdfparamresp_raw.tohex(), 4) self.PBKDFParamResponse = pbkdfparamresp_raw @@ -134,22 +134,22 @@ class Matter_Commisioning_Context var pake1 = matter.Pake1().parse(msg.raw, msg.app_payload_idx) self.pA = pake1.pA - tasmota.log("MTR: received pA=" + self.pA.tohex(), 3) + tasmota.log("MTR: received pA=" + self.pA.tohex(), 4) - tasmota.log("MTR: spake: " + matter.inspect(self.spake), 3) + tasmota.log("MTR: spake: " + matter.inspect(self.spake), 4) # instanciate SPAKE self.spake = crypto.SPAKE2P_Matter(self.device.w0, self.device.w1, self.device.L) # compute pB self.spake.compute_pB(self.y) self.pB = self.spake.pB - tasmota.log("MTR: y=" + self.y.tohex(), 3) - tasmota.log("MTR: pb=" + self.pB.tohex(), 3) + tasmota.log("MTR: y=" + self.y.tohex(), 4) + tasmota.log("MTR: pb=" + self.pB.tohex(), 4) # compute ZV self.spake.compute_ZV_verifier(self.pA) - tasmota.log("MTR: Z=" + self.spake.Z.tohex(), 3) - tasmota.log("MTR: V=" + self.spake.V.tohex(), 3) + tasmota.log("MTR: Z=" + self.spake.Z.tohex(), 4) + tasmota.log("MTR: V=" + self.spake.V.tohex(), 4) var context = crypto.SHA256() context.update(bytes().fromstring(self.Matter_Context_Prefix)) @@ -157,7 +157,7 @@ class Matter_Commisioning_Context context.update(self.PBKDFParamResponse) var context_hash = context.out() - tasmota.log("MTR: Context=" + context_hash.tohex(), 3) + tasmota.log("MTR: Context=" + context_hash.tohex(), 4) # add pA self.spake.pA = self.pA @@ -165,35 +165,33 @@ class Matter_Commisioning_Context self.spake.set_context(context_hash) self.spake.compute_TT_hash(true) # `true` to indicate it's Matter variant to SPAKE2+ - tasmota.log("MTR: ------------------------------", 3) - tasmota.log("MTR: Context = " + self.spake.Context.tohex(), 3) - tasmota.log("MTR: A = " + self.spake.A.tohex(), 3) - tasmota.log("MTR: B = " + self.spake.B.tohex(), 3) - tasmota.log("MTR: M = " + self.spake.M.tohex(), 3) - tasmota.log("MTR: N = " + self.spake.N.tohex(), 3) - tasmota.log("MTR: pA = " + self.spake.pA.tohex(), 3) - tasmota.log("MTR: pB = " + self.spake.pB.tohex(), 3) - tasmota.log("MTR: Z = " + self.spake.Z.tohex(), 3) - tasmota.log("MTR: V = " + self.spake.V.tohex(), 3) - tasmota.log("MTR: w0 = " + self.spake.w0.tohex(), 3) - tasmota.log("MTR: ------------------------------", 3) + tasmota.log("MTR: ------------------------------", 4) + tasmota.log("MTR: Context = " + self.spake.Context.tohex(), 4) + tasmota.log("MTR: M = " + self.spake.M.tohex(), 4) + tasmota.log("MTR: N = " + self.spake.N.tohex(), 4) + tasmota.log("MTR: pA = " + self.spake.pA.tohex(), 4) + tasmota.log("MTR: pB = " + self.spake.pB.tohex(), 4) + tasmota.log("MTR: Z = " + self.spake.Z.tohex(), 4) + tasmota.log("MTR: V = " + self.spake.V.tohex(), 4) + tasmota.log("MTR: w0 = " + self.spake.w0.tohex(), 4) + tasmota.log("MTR: ------------------------------", 4) - tasmota.log("MTR: Kmain =" + self.spake.Kmain.tohex(), 3) + tasmota.log("MTR: Kmain =" + self.spake.Kmain.tohex(), 4) - tasmota.log("MTR: KcA =" + self.spake.KcA.tohex(), 3) - tasmota.log("MTR: KcB =" + self.spake.KcB.tohex(), 3) - tasmota.log("MTR: K_shared=" + self.spake.K_shared.tohex(), 3) - tasmota.log("MTR: Ke =" + self.spake.Ke.tohex(), 3) + tasmota.log("MTR: KcA =" + self.spake.KcA.tohex(), 4) + tasmota.log("MTR: KcB =" + self.spake.KcB.tohex(), 4) + tasmota.log("MTR: K_shared=" + self.spake.K_shared.tohex(), 4) + tasmota.log("MTR: Ke =" + self.spake.Ke.tohex(), 4) self.cB = self.spake.cB self.Ke = self.spake.Ke - tasmota.log("MTR: cB=" + self.cB.tohex(), 3) + tasmota.log("MTR: cB=" + self.cB.tohex(), 4) var pake2 = matter.Pake2() pake2.pB = self.pB pake2.cB = self.cB - tasmota.log("MTR: pake2: " + matter.inspect(pake2), 3) + tasmota.log("MTR: pake2: " + matter.inspect(pake2), 4) var pake2_raw = pake2.encode() - tasmota.log("MTR: pake2_raw: " + pake2_raw.tohex(), 3) + tasmota.log("MTR: pake2_raw: " + pake2_raw.tohex(), 4) # now package the response message @@ -212,7 +210,7 @@ class Matter_Commisioning_Context var pake3 = matter.Pake3().parse(msg.raw, msg.app_payload_idx) self.cA = pake3.cA - tasmota.log("MTR: received cA=" + self.cA.tohex(), 3) + tasmota.log("MTR: received cA=" + self.cA.tohex(), 4) # check the value against computed if self.cA != self.spake.cA raise "protocol_error", "invalid cA received" end @@ -224,12 +222,12 @@ class Matter_Commisioning_Context self.R2IKey = session_keys[16..31] self.AttestationChallenge = session_keys[32..47] - tasmota.log("MTR: ******************************", 3) - tasmota.log("MTR: session_keys=" + session_keys.tohex(), 3) - tasmota.log("MTR: I2RKey =" + self.I2RKey.tohex(), 3) - tasmota.log("MTR: R2IKey =" + self.R2IKey.tohex(), 3) - tasmota.log("MTR: AC =" + self.AttestationChallenge.tohex(), 3) - tasmota.log("MTR: ******************************", 3) + tasmota.log("MTR: ******************************", 4) + tasmota.log("MTR: session_keys=" + session_keys.tohex(), 4) + tasmota.log("MTR: I2RKey =" + self.I2RKey.tohex(), 4) + tasmota.log("MTR: R2IKey =" + self.R2IKey.tohex(), 4) + tasmota.log("MTR: AC =" + self.AttestationChallenge.tohex(), 4) + tasmota.log("MTR: ******************************", 4) # now package the response message var resp = msg.build_response(0x40 #-StatusReport-#, false) # no reliable flag @@ -256,7 +254,7 @@ class Matter_Commisioning_Context var destinationMessage = initiatorRandom + session.get_ca_pub() + session.get_fabric() + session.get_deviceid() var key = session.get_ipk_group_key() tasmota.log("MTR: SIGMA1: destinationMessage=" + destinationMessage.tohex(), 3) - tasmota.log("MTR: SIGMA1: key_ipk=" + key.tohex(), 3) + tasmota.log("MTR: SIGMA1: key_ipk=" + key.tohex(), 4) var h = crypto.HMAC_SHA256(key) h.update(destinationMessage) var candidateDestinationId = h.out() @@ -315,12 +313,12 @@ class Matter_Commisioning_Context var Resume1MICPayload = ec.decrypt(encrypted) var decrypted_tag = ec.tag() - tasmota.log("****************************************", 3) - tasmota.log("MTR: * s1rk = " + s1rk.tohex(), 3) - tasmota.log("MTR: * tag = " + tag.tohex(), 3) - tasmota.log("MTR: * Resume1MICPayload = " + Resume1MICPayload.tohex(), 3) - tasmota.log("MTR: * decrypted_tag = " + decrypted_tag.tohex(), 3) - tasmota.log("****************************************", 3) + tasmota.log("****************************************", 4) + tasmota.log("MTR: * s1rk = " + s1rk.tohex(), 4) + tasmota.log("MTR: * tag = " + tag.tohex(), 4) + tasmota.log("MTR: * Resume1MICPayload = " + Resume1MICPayload.tohex(), 4) + tasmota.log("MTR: * decrypted_tag = " + decrypted_tag.tohex(), 4) + tasmota.log("****************************************", 4) if tag == decrypted_tag # Generate and Send Sigma2_Resume session.resumption_id = crypto.random(16) # generate a new resumption id @@ -349,15 +347,15 @@ class Matter_Commisioning_Context var ac = session_keys[32..47] var session_timestamp = tasmota.rtc()['utc'] - tasmota.log("MTR: ******************************", 3) - tasmota.log("MTR: I2RKey =" + i2r.tohex(), 3) - tasmota.log("MTR: R2IKey =" + r2i.tohex(), 3) - tasmota.log("MTR: AC =" + ac.tohex(), 3) - tasmota.log("MTR: ******************************", 3) + tasmota.log("MTR: ******************************", 4) + tasmota.log("MTR: I2RKey =" + i2r.tohex(), 4) + tasmota.log("MTR: R2IKey =" + r2i.tohex(), 4) + tasmota.log("MTR: AC =" + ac.tohex(), 4) + tasmota.log("MTR: ******************************", 4) var sigma2resume_raw = sigma2resume.encode() session._Msg1 = nil - tasmota.log("MTR: sigma2resume_raw: " + sigma2resume_raw.tohex(), 3) + tasmota.log("MTR: sigma2resume_raw: " + sigma2resume_raw.tohex(), 4) # now package the response message var resp = msg.build_response(0x33 #-sigma-2-resume-#, true) @@ -365,7 +363,7 @@ class Matter_Commisioning_Context self.responder.send_response(raw, msg.remote_ip, msg.remote_port, resp.message_counter) - session.close() + # session.close() session.set_keys(i2r, r2i, ac, session_timestamp) session.set_persist(true) # keep session on flash session.set_no_expiration() # never expire @@ -402,9 +400,9 @@ class Matter_Commisioning_Context sigma2_tbedata.add_TLV(4, matter.TLV.B2, session.resumption_id) # compute TranscriptHash = Crypto_Hash(message = Msg1) - tasmota.log("****************************************", 3) + tasmota.log("****************************************", 4) session._Msg1 = sigma1.Msg1 - tasmota.log("MTR: * MSG1 = " + session._Msg1.tohex(), 3) + tasmota.log("MTR: * MSG1 = " + session._Msg1.tohex(), 4) var TranscriptHash = crypto.SHA256().update(session._Msg1).out() # Compute S2K, p.175 @@ -412,27 +410,27 @@ class Matter_Commisioning_Context var s2k_salt = session.get_ipk_group_key() + responderRandom + self.ResponderEph_pub + TranscriptHash var s2k = crypto.HKDF_SHA256().derive(session.shared_secret, s2k_salt, s2k_info, 16) - tasmota.log("MTR: * SharedSecret = " + session.shared_secret.tohex(), 3) - tasmota.log("MTR: * s2k_salt = " + s2k_salt.tohex(), 3) - tasmota.log("MTR: * s2k = " + s2k.tohex(), 3) + tasmota.log("MTR: * SharedSecret = " + session.shared_secret.tohex(), 4) + tasmota.log("MTR: * s2k_salt = " + s2k_salt.tohex(), 4) + tasmota.log("MTR: * s2k = " + s2k.tohex(), 4) var sigma2_tbedata_raw = sigma2_tbedata.encode() # // `AES_CCM.init(secret_key:bytes(16 or 32), iv:bytes(7..13), aad:bytes(), data_len:int, tag_len:int) -> instance` var aes = crypto.AES_CCM(s2k, bytes().fromstring(self.TBEData2_Nonce), bytes(), size(sigma2_tbedata_raw), 16) var TBEData2Encrypted = aes.encrypt(sigma2_tbedata_raw) + aes.tag() - tasmota.log("MTR: * TBEData2Enc = " + TBEData2Encrypted.tohex(), 3) - tasmota.log("****************************************", 3) + tasmota.log("MTR: * TBEData2Enc = " + TBEData2Encrypted.tohex(), 4) + tasmota.log("****************************************", 4) var sigma2 = matter.Sigma2() sigma2.responderRandom = responderRandom sigma2.responderSessionId = self.future_local_session_id sigma2.responderEphPubKey = self.ResponderEph_pub sigma2.encrypted2 = TBEData2Encrypted - tasmota.log("MTR: sigma2: " + matter.inspect(sigma2), 3) + tasmota.log("MTR: sigma2: " + matter.inspect(sigma2), 4) var sigma2_raw = sigma2.encode() session._Msg2 = sigma2_raw - tasmota.log("MTR: sigma2_raw: " + sigma2_raw.tohex(), 3) + tasmota.log("MTR: sigma2_raw: " + sigma2_raw.tohex(), 4) # now package the response message var resp = msg.build_response(0x31 #-sigma-2-#, true) # no reliable flag @@ -454,23 +452,23 @@ class Matter_Commisioning_Context var session = msg.session var sigma3 = matter.Sigma3().parse(msg.raw, msg.app_payload_idx) - tasmota.log("****************************************", 3) + tasmota.log("****************************************", 4) # compute TranscriptHash = Crypto_Hash(message = Msg1 || Msg2) var TranscriptHash = crypto.SHA256().update(session._Msg1).update(session._Msg2).out() - tasmota.log("MTR: * session = " + str(session), 3) - tasmota.log("MTR: session.ipk_epoch_key " + str(session.ipk_epoch_key), 3) - tasmota.log("MTR: session.fabric_compressed " + str(session.fabric_compressed), 3) - tasmota.log("MTR: * ipk_group_key = " + session.get_ipk_group_key().tohex(), 3) - tasmota.log("MTR: * TranscriptHash= " + TranscriptHash.tohex(), 3) + tasmota.log("MTR: * session = " + str(session), 4) + tasmota.log("MTR: session.ipk_epoch_key " + str(session.ipk_epoch_key), 4) + tasmota.log("MTR: session.fabric_compressed " + str(session.fabric_compressed), 4) + tasmota.log("MTR: * ipk_group_key = " + session.get_ipk_group_key().tohex(), 4) + tasmota.log("MTR: * TranscriptHash= " + TranscriptHash.tohex(), 4) var s3k_info = bytes().fromstring(self.S3K_Info) var s3k = crypto.HKDF_SHA256().derive(session.shared_secret, session.get_ipk_group_key() + TranscriptHash, s3k_info, 16) - tasmota.log("****************************************", 3) + tasmota.log("****************************************", 4) # self.ipk_epoch_key == nil || self.fabric_compressed") - tasmota.log("MTR: * s3k_salt = " + (session.get_ipk_group_key() + TranscriptHash).tohex(), 3) - tasmota.log("MTR: * s3k = " + s3k.tohex(), 3) - tasmota.log("****************************************", 3) + tasmota.log("MTR: * s3k_salt = " + (session.get_ipk_group_key() + TranscriptHash).tohex(), 4) + tasmota.log("MTR: * s3k = " + s3k.tohex(), 4) + tasmota.log("****************************************", 4) # decrypt var encrypted = sigma3.TBEData3Encrypted[0..-17] @@ -478,10 +476,10 @@ class Matter_Commisioning_Context var ec = crypto.AES_CCM(s3k, bytes().fromstring(self.TBEData3_Nonce), bytes(), size(encrypted), 16) var TBEData3 = ec.decrypt(encrypted) var TBETag3 = ec.tag() - tasmota.log("MTR: * TBEData3 = " + TBEData3.tohex(), 3) - tasmota.log("MTR: * TBETag3 = " + TBETag3.tohex(), 3) - tasmota.log("MTR: * tag_sent = " + tag.tohex(), 3) - tasmota.log("****************************************", 3) + tasmota.log("MTR: * TBEData3 = " + TBEData3.tohex(), 4) + tasmota.log("MTR: * TBETag3 = " + TBETag3.tohex(), 4) + tasmota.log("MTR: * tag_sent = " + tag.tohex(), 4) + tasmota.log("****************************************", 4) if TBETag3 != tag raise "value_error", "tag do not match" end @@ -507,9 +505,9 @@ class Matter_Commisioning_Context sigma3_tbs.add_TLV(4, matter.TLV.B1, self.ResponderEph_pub) var sigma3_tbs_raw = sigma3_tbs.encode() - tasmota.log("MTR: * initiatorNOCPubKey = " + initiatorNOCPubKey.tohex(), 3) - tasmota.log("MTR: * ec_signature = " + ec_signature.tohex(), 3) - tasmota.log("****************************************", 3) + tasmota.log("MTR: * initiatorNOCPubKey = " + initiatorNOCPubKey.tohex(), 4) + tasmota.log("MTR: * ec_signature = " + ec_signature.tohex(), 4) + tasmota.log("****************************************", 4) # `crypto.EC_P256().ecdsa_verify_sha256(public_key:bytes(65), message:bytes(), hash:bytes()) -> bool` var sigma3_tbs_valid = crypto.EC_P256().ecdsa_verify_sha256(initiatorNOCPubKey, sigma3_tbs_raw, ec_signature) @@ -524,9 +522,9 @@ class Matter_Commisioning_Context session._Msg1 = nil session._Msg2 = nil - tasmota.log("MTR: ******************************", 3) - tasmota.log("MTR: shared_secret =" + session.shared_secret.tohex(), 3) - tasmota.log("MTR: ipk + hash =" + (session.get_ipk_group_key() + TranscriptHash).tohex(), 3) + tasmota.log("MTR: ******************************", 4) + tasmota.log("MTR: shared_secret =" + session.shared_secret.tohex(), 4) + tasmota.log("MTR: ipk + hash =" + (session.get_ipk_group_key() + TranscriptHash).tohex(), 4) # compute session key var session_keys = crypto.HKDF_SHA256().derive(session.shared_secret #- input key -#, session.get_ipk_group_key() + TranscriptHash #- salt -#, @@ -537,11 +535,11 @@ class Matter_Commisioning_Context var ac = session_keys[32..47] var session_timestamp = tasmota.rtc()['utc'] - tasmota.log("MTR: ******************************", 3) - tasmota.log("MTR: I2RKey =" + i2r.tohex(), 3) - tasmota.log("MTR: R2IKey =" + r2i.tohex(), 3) - tasmota.log("MTR: AC =" + ac.tohex(), 3) - tasmota.log("MTR: ******************************", 3) + tasmota.log("MTR: ******************************", 4) + tasmota.log("MTR: I2RKey =" + i2r.tohex(), 4) + tasmota.log("MTR: R2IKey =" + r2i.tohex(), 4) + tasmota.log("MTR: AC =" + ac.tohex(), 4) + tasmota.log("MTR: ******************************", 4) # Send success status report var resp = msg.build_response(0x40 #-StatusReport-#, true) # reliable flag diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning_Data.be b/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning_Data.be index 9aca4927c..f4ce7616d 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning_Data.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning_Data.be @@ -98,7 +98,7 @@ class Matter_Pake1 def parse(b, idx) if idx == nil idx = 0 end var val = matter.TLV.parse(b, idx) - tasmota.log("MTR: parsed TLV: " + str(val), 3) + tasmota.log("MTR: parsed TLV: " + str(val), 4) self.pA = val.getsubval(1) return self @@ -130,7 +130,7 @@ class Matter_Pake3 def parse(b, idx) if idx == nil idx = 0 end var val = matter.TLV.parse(b, idx) - tasmota.log("MTR: parsed TLV: " + str(val), 3) + tasmota.log("MTR: parsed TLV: " + str(val), 4) self.cA = val.getsubval(1) return self @@ -157,7 +157,7 @@ class Matter_Sigma1 if idx == nil idx = 0 end var val = matter.TLV.parse(b, idx) self.Msg1 = b[idx..] - tasmota.log("MTR: Sigma1 TLV=" + str(val), 3) + tasmota.log("MTR: Sigma1 TLV=" + str(val), 4) self.initiatorRandom = val.getsubval(1) self.initiator_session_id = val.getsubval(2) @@ -240,7 +240,7 @@ class Matter_Sigma3 if idx == nil idx = 0 end var val = matter.TLV.parse(b, idx) self.Msg3 = b[idx..] - tasmota.log("MTR: Sigma3 TLV=" + str(val), 3) + tasmota.log("MTR: Sigma3 TLV=" + str(val), 4) self.TBEData3Encrypted = val.getsubval(1) return self diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Device.be b/lib/libesp32/berry_matter/src/embedded/Matter_Device.be index 7765c16b8..3477d09fa 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Device.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Device.be @@ -28,7 +28,7 @@ class Matter_Device static var FILENAME = "_matter_device.json" var plugins # list of plugins var udp_server # `matter.UDPServer()` object - var msg_handler # `matter.MessageHandler()` object + var message_handler # `matter.MessageHandler()` object var sessions # `matter.Session_Store()` objet var ui # information about the device @@ -65,12 +65,12 @@ class Matter_Device self.sessions = matter.Session_Store() self.sessions.load() - self.msg_handler = matter.MessageHandler(self) + self.message_handler = matter.MessageHandler(self) self.ui = matter.UI(self) # add the default plugin - self.plugins.push(matter.Plugin_core(self)) - self.plugins.push(matter.Plugin_Relay(self)) + self.plugins.push(matter.Plugin_Root(self)) + self.plugins.push(matter.Plugin_OnOff(self)) self.start_mdns_announce_hostnames() @@ -167,7 +167,7 @@ class Matter_Device # dispatch every second click to sub-objects that need it def every_second() self.sessions.every_second() - self.msg_handler.every_second() + self.message_handler.every_second() end ############################################################# @@ -178,7 +178,7 @@ class Matter_Device ############################################################# # callback when message is received def msg_received(raw, addr, port) - return self.msg_handler.msg_received(raw, addr, port) + return self.message_handler.msg_received(raw, addr, port) end def msg_send(raw, addr, port, id) @@ -214,27 +214,6 @@ class Matter_Device tasmota.set_timer(0, /-> self.start_commissioning_complete(session)) end - ############################################################# - # Start UDP mDNS announcements for commissioning - # - # eth is `true` if ethernet turned up, `false` is wifi turned up - # def mdns_announce_commissioning() - # var services = { - # "VP":str(self.vendorid) + "+" + str(self.productid), - # "D": self.discriminator, - # "CM":1, # requires passcode - # "T":0, # no support for TCP - # "SII":5000, "SAI":300 - # } - - # if self.self.hostname_eth - # mdns.add_service("_matterc","_udp", 5540, services, self.commissioning_instance_eth, self.hostname_eth) - # end - # if self.self.hostname_wifi - # mdns.add_service("_matter","_tcp", 5540, services, self.commissioning_instance_wifi, self.hostname_wifi) - # end - # end - ############################################################# # Start Operational Discovery def start_operational_dicovery(session) @@ -265,28 +244,36 @@ class Matter_Device tasmota.log("MTR: *** Commissioning complete ***", 2) end - ############################################################# - # read an attribute - # - # def read_attribute(msg, ctx) - # # dispatch only to plugins that support this endpoint and cluster - # var endpoint = ctx.endpoint - # var cluster = ctx.cluster - # var idx = 0 - # while idx < size(self.plugins) - # var plugin = self.plugins[idx] - - # if plugin.has(cluster, endpoint) - # var ret = plugin.read_attribute(msg, ctx) - # if ret != nil - # return ret - # end - # end - - # idx += 1 - # end - # end + ################################################################################# + # Simple insertion sort - sorts the list in place, and returns the list + # remove duplicates + ################################################################################# + static def sort_distinct(l) + # insertion sort + for i:1..size(l)-1 + var k = l[i] + var j = i + while (j > 0) && (l[j-1] > k) + l[j] = l[j-1] + j -= 1 + end + l[j] = k + end + # remove duplicate now that it's sorted + var i = 1 + if size(l) <= 1 return l end # no duplicate if empty or 1 element + var prev = l[0] + while i < size(l) + if l[i] == prev + l.remove(i) + else + prev = l[i] + i += 1 + end + end + return l + end ############################################################# # expand attribute list based @@ -294,69 +281,94 @@ class Matter_Device # called only when expansion is needed, # so we don't need to report any error since they are ignored def process_attribute_expansion(ctx, cb) + ################################################################################# + # Returns the keys of a map as a sorted list + ################################################################################# + def keys_sorted(m) + var l = [] + for k: m.keys() + l.push(k) + end + # insertion sort + for i:1..size(l)-1 + var k = l[i] + var j = i + while (j > 0) && (l[j-1] > k) + l[j] = l[j-1] + j -= 1 + end + l[j] = k + end + return l + end + import string var endpoint = ctx.endpoint - var endpoint_mono = [ endpoint ] + # var endpoint_mono = [ endpoint ] var endpoint_found = false # did any endpoint match var cluster = ctx.cluster - var cluster_mono = [ cluster ] + # var cluster_mono = [ cluster ] var cluster_found = false var attribute = ctx.attribute - var attribute_mono = [ attribute ] + # var attribute_mono = [ attribute ] var attribute_found = false var direct = (ctx.endpoint != nil) && (ctx.cluster != nil) && (ctx.attribute != nil) # true if the target is a precise attribute, false if it results from an expansion and error are ignored - tasmota.log(string.format("MTR: process_attribute_expansion %s", str(ctx)), 3) + tasmota.log(string.format("MTR: process_attribute_expansion %s", str(ctx)), 4) + + # build the list of candidates + + # list of all endpoints + var all = {} # map of {endpoint: {cluster: {attributes:[pi]}} + tasmota.log(string.format("MTR: endpoint=%s cluster=%s attribute=%s", endpoint, cluster, attribute), 4) for pi: self.plugins var ep_list = pi.get_endpoints() # get supported endpoints for this plugin - tasmota.log(string.format("MTR: ep_list %s %s", str(pi), str(ep_list)), 3) - if endpoint != nil - # we have a specific endpoint, make sure it's in the list - if ep_list.find(endpoint) != nil - ep_list = endpoint_mono - endpoint_found = true - else - continue - end - end - # ep_list is the actual list of candidate endpoints for this plugin - # iterate on endpoints + tasmota.log(string.format("MTR: pi=%s ep_list=%s", str(pi), str(ep_list)), 4) for ep: ep_list - # now filter on clusters - var cluster_list = pi.get_cluster_list(ep) - tasmota.log(string.format("MTR: cluster_list %s %s", str(ep), str(cluster_list)), 3) - if cluster != nil - # we have a specific cluster, make sure it's in the list - if cluster_list.find(cluster) != nil - cluster_list = cluster_mono - cluster_found = true - else - continue + if endpoint != nil && ep != endpoint continue end # skip if specific endpoint and no match + # from now on, 'ep' is a good candidate + if !all.contains(ep) all[ep] = {} end # create empty structure if not already in the list + endpoint_found = true + + # now explore the cluster list for 'ep' + var cluster_list = pi.get_cluster_list(ep) # cluster_list is the actual list of candidate cluster for this pluging and endpoint + tasmota.log(string.format("MTR: pi=%s ep=%s cl_list=%s", str(pi), str(ep), str(cluster_list)), 4) + for cl: cluster_list + if cluster != nil && cl != cluster continue end # skip if specific cluster and no match + # from now on, 'cl' is a good candidate + if !all[ep].contains(cl) all[ep][cl] = {} end + cluster_found = true + + # now filter on attributes + var attr_list = pi.get_attribute_list(ep, cl) + tasmota.log(string.format("MTR: pi=%s ep=%s cl=%s at_list=%s", str(pi), str(ep), str(cl), str(attr_list)), 4) + for at: attr_list + if attribute != nil && at != attribute continue end # skip if specific attribiute and no match + # from now on, 'at' is a good candidate + if !all[ep][cl].contains(at) all[ep][cl][at] = [] end + attribute_found = true + + all[ep][cl][at].push(pi) # add plugin to the list end end - # cluster_list is the actual list of candidate cluster for this pluging and endpoint - for cl: cluster_list - # now filter on attribute - var attr_list = pi.get_attribute_list(ep, cluster) - tasmota.log(string.format("MTR: attr_list %s %s", str(cl), str(attr_list)), 3) - if attribute != nil - # we have a specific attribute, make sure it's in the list - if attr_list.find(attribute) != nil - attr_list = attribute_mono - attribute_found = true - else - continue - end - for at: attr_list - # we now have the complete candidate: ep/cl/at - tasmota.log(string.format("MTR: expansion [%02X]%04X/%04X", ep, cl, at), 3) - ctx.endpoint = ep - ctx.cluster = cl - ctx.attribute = at - var finished = cb(pi, ctx, direct) # call the callback with the plugin and the context - if finished return end - end + end + end + + # import json + # tasmota.log("MTR: all = " + json.dump(all), 2) + + # iterate on candidates + for ep: keys_sorted(all) + for cl: keys_sorted(all[ep]) + for at: keys_sorted(all[ep][cl]) + for pi: all[ep][cl][at] + tasmota.log(string.format("MTR: expansion [%02X]%04X/%04X", ep, cl, at), 3) + ctx.endpoint = ep + ctx.cluster = cl + ctx.attribute = at + var finished = cb(pi, ctx, direct) # call the callback with the plugin and the context + if direct && finished return end end end end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_IM.be b/lib/libesp32/berry_matter/src/embedded/Matter_IM.be index e03f17aeb..1aedb3b55 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_IM.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_IM.be @@ -19,50 +19,21 @@ import matter -#@ solidify:Matter_Response_container,weak #@ solidify:Matter_IM,weak -################################################################################# -# Matter_Response_container -# -# Used to store all the elements of the reponse to an attribute or command -################################################################################# -class Matter_Response_container - var endpoint - var cluster - var attribute - var command - var status - - def tostring() - try - import string - var s = "" - s += (self.endpoint != nil ? string.format("[%02X]", self.endpoint) : "[**]") - s += (self.cluster != nil ? string.format("%04X/", self.cluster) : "****/") - s += (self.attribute != nil ? string.format("%04X", self.attribute) : "") - s += (self.command != nil ? string.format("%04X", self.attribute) : "") - return s - except .. as e, m - return "Exception> " + str(e) + ", " + str(m) - end - end - -end -matter.Response_container = Matter_Response_container - ################################################################################# # Matter_IM class ################################################################################# class Matter_IM - static var MAX_MESSAGE = 1200 - static var MSG_TIMEOUT = 10000 # 10s - var responder var device + var subs # subscriptions shop - def init(responder, device) - self.responder = responder + var send_queue # list of IM_Message queued for sending as part of exchange-id + + def init(device) self.device = device + self.send_queue = [] + self.subs = matter.IM_Subscription_Shop(self) end def process_incoming(msg) @@ -74,7 +45,7 @@ class Matter_IM tasmota.log("MTR: IM TLV: " + str(val), 3) var InteractionModelRevision = val.findsubval(0xFF) - tasmota.log("MTR: InteractionModelRevision=" + (InteractionModelRevision != nil ? str(InteractionModelRevision) : "nil"), 3) + tasmota.log("MTR: InteractionModelRevision=" + (InteractionModelRevision != nil ? str(InteractionModelRevision) : "nil"), 4) var opcode = msg.opcode if opcode == 0x01 # Status Response @@ -102,26 +73,71 @@ class Matter_IM return false end + ############################################################# + # send enqueued responses + # + def send_enqueued(responder) + var idx = 0 + while idx < size(self.send_queue) + var message = self.send_queue[idx] + + if message.ready + var finish = message.send(responder) # send message + if finish + self.send_queue.remove(idx) + idx -= 1 + else + message.ready = false # needs more to proceed + end + end + + idx += 1 + end + end + + ############################################################# + # find in send_queue by exchangeid + # + def find_sendqueue_by_exchangeid(exchangeid) + if exchangeid == nil return nil end + var idx = 0 + while idx < size(self.send_queue) + var message = self.send_queue[idx] + if message.get_exchangeid() == exchangeid + return message + end + idx += 1 + end + return nil + end + + ############################################################# # process IM 0x01 Status Response # # val is the TLV structure - # returns `true` if processed, `false` if silently ignored, # or raises an exception def process_status_response(msg, val) import string var status = val.findsubval(0, 0xFF) - tasmota.log(string.format("MTR: Status Response = 0x%02X", status), 3) - return true + if status == matter.SUCCESS + tasmota.log("MTR: >Status", 2) # don't show 'SUCCESS' to not overflow logs with non-information + var message = self.find_sendqueue_by_exchangeid(msg.exchange_id) + if message + message.ack_received(msg) # re-arm the sending of next packets for the same exchange + return true + end + else + tasmota.log(string.format("MTR: >Status ERROR = 0x%02X", status), 2) + end + return false end ############################################################# - # process IM 0x02 Read Request + # Inner code shared between read_attributes and subscribe_request # - # val is the TLV structure - # returns `true` if processed, `false` if silently ignored, - # or raises an exception - def process_read_request(msg, val) + # query: `ReadRequestMessage` or `SubscribeRequestMessage` + def _inner_process_read_request(msg, query) var endpoints = self.device.get_active_endpoints() ### Inner function to be iterated upon @@ -150,7 +166,7 @@ class Matter_IM a1.attribute_data.data = res ret.attribute_reports.push(a1) - tasmota.log(string.format("MTR: Read_Attr %s%s - %s", str(ctx), attr_name, str(res)), 2) + tasmota.log(string.format("MTR: Read_Attr %s%s - %s", str(ctx), attr_name, str(res)), 2) return true # stop expansion since we have a value elif ctx.status != nil if direct @@ -164,105 +180,89 @@ class Matter_IM a1.attribute_status.status.status = ctx.status ret.attribute_reports.push(a1) - tasmota.log(string.format("MTR: Read_Attr %s%s - STATUS: 0x%02X %s", str(ctx), attr_name, ctx.status, ctx.status == matter.UNSUPPORTED_ATTRIBUTE ? "UNSUPPORTED_ATTRIBUTE" : ""), 2) + tasmota.log(string.format("MTR: Read_Attr %s%s - STATUS: 0x%02X %s", str(ctx), attr_name, ctx.status, ctx.status == matter.UNSUPPORTED_ATTRIBUTE ? "UNSUPPORTED_ATTRIBUTE" : ""), 2) return true end else - tasmota.log(string.format("MTR: Read_Attr %s%s - IGNORED", str(ctx), attr_name), 2) + tasmota.log(string.format("MTR: Read_Attr %s%s - IGNORED", str(ctx), attr_name), 2) # ignore if content is nil and status is undefined + return false end end # structure is `ReadRequestMessage` 10.6.2 p.558 - tasmota.log("MTR: IM:read_request processing start", 3) - var ctx = matter.Response_container() + var ctx = matter.Path() - var query = matter.ReadRequestMessage().from_TLV(val) - if query.attributes_requests != nil - # prepare the response - var ret = matter.ReportDataMessage() - # ret.suppress_response = true - ret.attribute_reports = [] + # prepare the response + var ret = matter.ReportDataMessage() + # ret.suppress_response = true + ret.attribute_reports = [] - for q:query.attributes_requests - # need to do expansion here - ctx.endpoint = q.endpoint - ctx.cluster = q.cluster - ctx.attribute = q.attribute - ctx.status = matter.UNSUPPORTED_ATTRIBUTE #default error if returned `nil` - - # expand endpoint - if ctx.endpoint == nil || ctx.cluster == nil || ctx.attribute == nil - # we need expansion, log first - if ctx.cluster != nil && ctx.attribute != nil - var attr_name = matter.get_attribute_name(ctx.cluster, ctx.attribute) - tasmota.log("MTR: Read_Attr " + str(ctx) + (attr_name ? " (" + attr_name + ")" : ""), 2) - else - tasmota.log("MTR: Read_Attr " + str(ctx), 2) - end - + for q:query.attributes_requests + # need to do expansion here + ctx.endpoint = q.endpoint + ctx.cluster = q.cluster + ctx.attribute = q.attribute + ctx.status = matter.UNSUPPORTED_ATTRIBUTE #default error if returned `nil` + + # expand endpoint + if ctx.endpoint == nil || ctx.cluster == nil || ctx.attribute == nil + # we need expansion, log first + if ctx.cluster != nil && ctx.attribute != nil + var attr_name = matter.get_attribute_name(ctx.cluster, ctx.attribute) + tasmota.log("MTR: Read_Attr " + str(ctx) + (attr_name ? " (" + attr_name + ")" : ""), 2) + else + tasmota.log("MTR: Read_Attr " + str(ctx), 2) end - - # implement concrete expansion - self.device.process_attribute_expansion(ctx, - / pi, ctx, direct -> read_single_attribute(ret, pi, ctx, direct) - ) + end - tasmota.log("MTR: ReportDataMessage=" + str(ret), 3) - tasmota.log("MTR: ReportDataMessageTLV=" + str(ret.to_TLV()), 3) + # implement concrete expansion + self.device.process_attribute_expansion(ctx, + / pi, ctx, direct -> read_single_attribute(ret, pi, ctx, direct) + ) + end - # send the reponse that may need to be chunked if too large to fit in a single UDP message - self.send_attr_report(msg, ret) + tasmota.log("MTR: ReportDataMessage=" + str(ret), 4) + tasmota.log("MTR: ReportDataMessageTLV=" + str(ret.to_TLV()), 3) + + return ret + end + + ############################################################# + # process IM 0x02 Read Request + # + # val is the TLV structure + # returns `true` if processed, `false` if silently ignored, + # or raises an exception + def process_read_request(msg, val) + var query = matter.ReadRequestMessage().from_TLV(val) + if query.attributes_requests != nil + var ret = self._inner_process_read_request(msg, query) + self.send_report_data(msg, ret) end return true end - def send_attr_report(msg, ret) - # class to keep the current chunked reponse - class Matter_Attr_Report - var ret # return structure as ReportDataMessage TLV structure - var resp # response Frame (to keep all fields like session or remote_ip/port) - var expiration - end - - # compute the acceptable size - - var msg_sz = 0 - var elements = 0 - if size(ret.attribute_reports) > 0 - msg_sz = size(ret.attribute_reports[0].to_TLV().encode()) - elements = 1 - end - while msg_sz < self.MAX_MESSAGE && elements < size(ret.attribute_reports) - var next_sz = size(ret.attribute_reports[elements].to_TLV().encode()) - if msg_sz + next_sz < self.MAX_MESSAGE - msg_sz += next_sz - elements += 1 - end - end - - var next_elemnts = ret.attribute_reports[elements .. ] - ret.attribute_reports = ret.attribute_reports[0 .. elements - 1] - - if size(next_elemnts) > 0 - ret.more_chunked_messages = true - end - - var resp = msg.build_response(0x05 #-Report Data-#, true) - resp.encode(ret.to_TLV().encode()) # payload in cleartext - resp.encrypt() - self.responder.send_response(resp.raw, msg.remote_ip, msg.remote_port, resp.message_counter) - - if size(next_elemnts) > 0 - ret.attribute_reports = next_elemnts - var chunked_next = Matter_Attr_Report() - chunked_next.ret = ret - chunked_next.resp = resp - chunked_next.expiration = tasmota.millis() + self.MSG_TIMEOUT + ############################################################# + # process IM 0x03 Subscribe Request + # + def subscribe_request(msg, val) + import string + var query = matter.SubscribeRequestMessage().from_TLV(val) + + if !query.keep_subscriptions + self.subs.remove_by_session(msg.session) # if `keep_subscriptions`, kill all subscriptions from current session end + tasmota.log("MTR: received SubscribeRequestMessage=" + str(query), 3) + var sub = self.subs.new_subscription(msg.session, query) + var ret = self._inner_process_read_request(msg, query) + # ret is of type `Matter_ReportDataMessage` + ret.subscription_id = sub.subscription_id # enrich with subscription id TODO + self.send_subscribe_response(msg, ret, sub) + return true end ############################################################# @@ -274,8 +274,8 @@ class Matter_IM def process_invoke_request(msg, val) import string # structure is `ReadRequestMessage` 10.6.2 p.558 - tasmota.log("MTR: IM:invoke_request processing start", 3) - var ctx = matter.Response_container() + tasmota.log("MTR: IM:invoke_request processing start", 4) + var ctx = matter.Path() var query = matter.InvokeRequestMessage().from_TLV(val) if query.invoke_requests != nil @@ -291,11 +291,19 @@ class Matter_IM ctx.status = matter.UNSUPPORTED_COMMAND #default error if returned `nil` var cmd_name = matter.get_command_name(ctx.cluster, ctx.command) - if cmd_name == nil cmd_name = string.format("0x%04X/0x02X", ctx.cluster, ctx.command) end - tasmota.log(string.format("MTR: >Received_cmd %s from [%s]:%i", cmd_name, msg.remote_ip, msg.remote_port), 2) - var res = self.responder.device.invoke_request(msg, q.command_fields, ctx) + tasmota.log(string.format("MTR: >Received %s %s from [%s]:%i", str(ctx), cmd_name ? cmd_name : "", msg.remote_ip, msg.remote_port), 2) + var res = self.device.invoke_request(msg, q.command_fields, ctx) var a1 = matter.InvokeResponseIB() - if res != nil + if res == true # special case, just respond ok + a1.status = matter.CommandStatusIB() + a1.status.command_path = matter.CommandPathIB() + a1.status.command_path.endpoint = ctx.endpoint + a1.status.command_path.cluster = ctx.cluster + a1.status.command_path.command = ctx.command + a1.status.status = matter.StatusIB() + a1.status.status.status = matter.SUCCESS + ret.invoke_responses.push(a1) + elif res != nil a1.command = matter.CommandDataIB() a1.command.command_path = matter.CommandPathIB() a1.command.command_path.endpoint = ctx.endpoint @@ -305,8 +313,7 @@ class Matter_IM ret.invoke_responses.push(a1) cmd_name = matter.get_command_name(ctx.cluster, ctx.command) - if cmd_name == nil cmd_name = string.format("0x%04X/0x%02X", ctx.cluster, ctx.command) end - tasmota.log(string.format("MTR: write_single_attribute(ret, pi, ctx, write_data, direct) + ) + end + + tasmota.log("MTR: ReportWriteMessage=" + str(ret), 4) + tasmota.log("MTR: ReportWriteMessageTLV=" + str(ret.to_TLV()), 3) + + # send the reponse that may need to be chunked if too large to fit in a single UDP message + if !suppress_response + self.send_write_response(msg, ret) + end + end + return true end ############################################################# @@ -387,7 +470,7 @@ class Matter_IM def process_write_response(msg, val) import string var query = matter.WriteResponseMessage().from_TLV(val) - tasmota.log("MTR: received WriteResponseMessage=" + str(query), 3) + tasmota.log("MTR: received WriteResponseMessage=" + str(query), 2) return false end @@ -397,7 +480,7 @@ class Matter_IM def process_invoke_response(msg, val) import string var query = matter.InvokeResponseMessage().from_TLV(val) - tasmota.log("MTR: received InvokeResponseMessage=" + str(query), 3) + tasmota.log("MTR: received InvokeResponseMessage=" + str(query), 2) return false end @@ -409,22 +492,70 @@ class Matter_IM var query = matter.TimedRequestMessage().from_TLV(val) tasmota.log("MTR: received TimedRequestMessage=" + str(query), 3) - tasmota.log(string.format("MTR: >Received_IM TimedRequest=%i from [%s]:%i", query.timeout, msg.remote_ip, msg.remote_port), 2) + tasmota.log(string.format("MTR: >Received TimedRequest=%i from [%s]:%i", query.timeout, msg.remote_ip, msg.remote_port), 2) # Send success status report - var sr = matter.StatusResponseMessage() - sr.status = matter.SUCCESS - var resp = msg.build_response(0x01 #-Status Response-#, true #-reliable-#) - resp.encode(sr.to_TLV().encode()) # payload in cleartext - resp.encrypt() - self.responder.send_response(resp.raw, msg.remote_ip, msg.remote_port, resp.message_counter) + self.send_status(msg, matter.SUCCESS) return true end + ############################################################# + # send regular update for data subscribed + # + def send_subscribe_update(sub) + import string + var session = sub.session + + var ret = matter.ReportDataMessage() + ret.subscription_id = sub.subscription_id + ret.attribute_reports = [] + ret.suppress_response = true # true for empy report, as per 8.6.2 p.425 + + self.send_queue.push(matter.IM_ReportDataSubscribed(self.device.message_handler, session, ret)) + + self.send_enqueued(self.device.message_handler) + end + + ############################################################# + # send_status + # + def send_status(msg, status) + self.send_queue.push(matter.IM_Status(msg, status)) + end + + ############################################################# + # send_invoke_response + # + def send_invoke_response(msg, data) + self.send_queue.push(matter.IM_InvokeResponse(msg, data)) + end + + ############################################################# + # send_invoke_response + # + def send_write_response(msg, data) + self.send_queue.push(matter.IM_WriteResponse(msg, data)) + end + + ############################################################# + # send_report_data + # + def send_report_data(msg, data) + self.send_queue.push(matter.IM_ReportData(msg, data)) + end + + ############################################################# + # send_report_data + # + def send_subscribe_response(msg, data, sub) + self.send_queue.push(matter.IM_SubscribeResponse(msg, data, sub)) + end + ############################################################# # placeholder, nothing to run for now def every_second() + self.subs.every_second() end end matter.IM = Matter_IM diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_IM_Data.be b/lib/libesp32/berry_matter/src/embedded/Matter_IM_Data.be index f1159ff36..6a566ab7a 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_IM_Data.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_IM_Data.be @@ -670,7 +670,7 @@ class Matter_SubscribeRequestMessage : Matter_IM_Message_base var keep_subscriptions # bool var min_interval_floor # u16 var max_interval_ceiling # u16 - var attribute_requests # array of AttributePathIB + var attributes_requests # array of AttributePathIB var event_requests # array of EventPathIB var event_filters # array of EventFilterIB var fabric_filtered # bool @@ -679,13 +679,13 @@ class Matter_SubscribeRequestMessage : Matter_IM_Message_base # decode from TLV def from_TLV(val) if val == nil return nil end - self.keep_subscriptions = val.findsubval(0) - self.min_interval_floor = val.findsubval(1) - self.max_interval_ceiling = val.findsubval(2) - self.attribute_requests = self.from_TLV_array(val.findsubval(3), matter.AttributePathIB) + self.keep_subscriptions = val.findsubval(0, false) + self.min_interval_floor = val.findsubval(1, 0) + self.max_interval_ceiling = val.findsubval(2, 60) + self.attributes_requests = self.from_TLV_array(val.findsubval(3), matter.AttributePathIB) self.event_requests = self.from_TLV_array(val.findsubval(4), matter.EventPathIB) self.event_filters = self.from_TLV_array(val.findsubval(5), matter.EventFilterIB) - self.fabric_filtered = val.findsubval(7) + self.fabric_filtered = val.findsubval(7, false) self.data_version_filters = self.from_TLV_array(val.findsubval(8), matter.DataVersionFilterIB) return self end @@ -696,7 +696,7 @@ class Matter_SubscribeRequestMessage : Matter_IM_Message_base s.add_TLV(0, TLV.BOOL, self.keep_subscriptions) s.add_TLV(1, TLV.U2, self.min_interval_floor) s.add_TLV(2, TLV.U2, self.max_interval_ceiling) - self.to_TLV_array(s, 3, self.attribute_requests) + self.to_TLV_array(s, 3, self.attributes_requests) self.to_TLV_array(s, 4, self.event_requests) self.to_TLV_array(s, 5, self.event_filters) s.add_TLV(7, TLV.BOOL, self.fabric_filtered) diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_IM_Message.be b/lib/libesp32/berry_matter/src/embedded/Matter_IM_Message.be new file mode 100644 index 000000000..72954d3fb --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_IM_Message.be @@ -0,0 +1,281 @@ +# +# Matter_IM_Message.be - suppport for Matter Interaction Model messages responses +# +# 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 + +#@ solidify:Matter_Path,weak +#@ solidify:Matter_IM_Message,weak +#@ solidify:Matter_IM_Status,weak +#@ solidify:Matter_IM_InvokeResponse,weak +#@ solidify:Matter_IM_WriteResponse,weak +#@ solidify:Matter_IM_ReportData,weak +#@ solidify:Matter_IM_ReportDataSubscribed,weak +#@ solidify:Matter_IM_SubscribeResponse,weak + +################################################################################# +# Matter_Path +# +# Used to store all the elements of the reponse to an attribute or command +################################################################################# +class Matter_Path + var endpoint # endpoint or `nil` if expansion + var cluster # cluster or `nil` if expansion + var attribute # attribute or `nil` if expansion + var command # command + var status # status to be returned (matter.SUCCESS or matter.) + + def tostring() + try + import string + var s = "" + s += (self.endpoint != nil ? string.format("[%02X]", self.endpoint) : "[**]") + s += (self.cluster != nil ? string.format("%04X/", self.cluster) : "****/") + s += (self.attribute != nil ? string.format("%04X", self.attribute) : "") + s += (self.command != nil ? string.format("%04X", self.command) : "") + if self.attribute == nil && self.command == nil s += "****" end + return s + except .. as e, m + return "Exception> " + str(e) + ", " + str(m) + end + end + +end +matter.Path = Matter_Path + +################################################################################# +# Matter_IM_Message +# +# Superclass for all IM responses +################################################################################# +class Matter_IM_Message + var resp # response Frame object + var ready # bool: ready to send (true) or wait (false) + var data # TLV data of the response (if any) + + # build a response message stub + def init(msg, opcode, reliable) + self.resp = msg.build_response(opcode, reliable) + self.ready = true + end + + # ack received for previous message, proceed to next (if any) + def ack_received(msg) + self.resp = msg.build_response(self.resp.opcode, self.resp.x_flag_r, self.resp) # update packet + self.ready = true + end + + # get the exchange-id for this message + def get_exchangeid() + return self.resp.exchange_id + end + + # return true if transaction is complete (remove object from queue) + # default responder for data + def send(responder) + var resp = self.resp + resp.encode(self.data.to_TLV().encode()) # payload in cleartext + resp.encrypt() + responder.send_response(resp.raw, resp.remote_ip, resp.remote_port, resp.message_counter) + return true + end + +end +matter.IM_Message = Matter_IM_Message + +################################################################################# +# Matter_IM_Status +# +# Send a simple Status Message +################################################################################# +class Matter_IM_Status : Matter_IM_Message + + def init(msg, status) + super(self).init(msg, 0x01 #-Status Response-#, true #-reliable-#) + var sr = matter.StatusResponseMessage() + sr.status = status + self.data = sr + self.ready = true # send immediately + end +end +matter.IM_Status = Matter_IM_Status + +################################################################################# +# Matter_IM_InvokeResponse +# +# Send a simple Status Message +################################################################################# +class Matter_IM_InvokeResponse : Matter_IM_Message + + def init(msg, data) + super(self).init(msg, 0x09 #-Invoke Response-#, true) + self.data = data + self.ready = true # send immediately + end +end +matter.IM_InvokeResponse = Matter_IM_InvokeResponse + +################################################################################# +# Matter_IM_WriteResponse +# +# Send a simple Status Message +################################################################################# +class Matter_IM_WriteResponse : Matter_IM_Message + + def init(msg, data) + super(self).init(msg, 0x07 #-Write Response-#, true) + self.data = data + self.ready = true # send immediately + end + +end +matter.IM_WriteResponse = Matter_IM_WriteResponse + +################################################################################# +# Matter_IM_ReportData +# +# Report Data for a Read Request +################################################################################# +class Matter_IM_ReportData : Matter_IM_Message + static var MAX_MESSAGE = 1200 # max bytes size for a single TLV worklaod + static var MSG_TIMEOUT = 10000 # 10s + var expiration # expiration time for the reporting + + def init(msg, data) + super(self).init(msg, 0x05 #-Report Data-#, true) + self.data = data + self.ready = true # send immediately + self.expiration = tasmota.millis() + self.MSG_TIMEOUT + end + + # return true if transaction is complete (remove object from queue) + # default responder for data + def send(responder) + import string + var resp = self.resp + var ret = self.data + var was_chunked = ret.more_chunked_messages # is this following a chunked packet? + + # compute the acceptable size + var msg_sz = 0 + var elements = 0 + if size(ret.attribute_reports) > 0 + msg_sz = ret.attribute_reports[0].to_TLV().encode_len() + elements = 1 + end + while msg_sz < self.MAX_MESSAGE && elements < size(ret.attribute_reports) + var next_sz = ret.attribute_reports[elements].to_TLV().encode_len() + if msg_sz + next_sz < self.MAX_MESSAGE + msg_sz += next_sz + elements += 1 + else + break + end + end + + tasmota.log(string.format("MTR: elements=%i msg_sz=%i total=%i", elements, msg_sz, size(ret.attribute_reports)), 3) + var next_elemnts = ret.attribute_reports[elements .. ] + ret.attribute_reports = ret.attribute_reports[0 .. elements - 1] + ret.more_chunked_messages = (size(next_elemnts) > 0) + + if was_chunked + tasmota.log(string.format("MTR: Read_Attr next_chunk exch=%i", self.get_exchangeid()), 3) + end + if ret.more_chunked_messages + if !was_chunked + tasmota.log(string.format("MTR: Read_Attr first_chunk exch=%i", self.get_exchangeid()), 3) + end + tasmota.log("MTR: sending TLV" + str(ret), 3) + end + + resp.encode(self.data.to_TLV().encode()) # payload in cleartext + resp.encrypt() + responder.send_response(resp.raw, resp.remote_ip, resp.remote_port, resp.message_counter) + + if size(next_elemnts) > 0 + ret.attribute_reports = next_elemnts + tasmota.log("MTR: to_be_sent_later TLV" + str(ret), 3) + self.expiration = tasmota.millis() + self.MSG_TIMEOUT # give more time + return false # keep alive + else + return true # finished, remove + end + end + +end +matter.IM_ReportData = Matter_IM_ReportData + + +################################################################################# +# Matter_IM_ReportDataSubscribed +# +# Main difference is that we are the spontaneous inititor +################################################################################# +class Matter_IM_ReportDataSubscribed : Matter_IM_ReportData + + def init(message_handler, session, data) + self.resp = matter.Frame.initiate_response(message_handler, session, 0x05 #-Report Data-#, true) + self.data = data + self.ready = true # send immediately + self.expiration = tasmota.millis() + self.MSG_TIMEOUT + end +end +matter.IM_ReportDataSubscribed = Matter_IM_ReportDataSubscribed + +################################################################################# +# Matter_IM_SubscribeResponse +# +# Report Data for a Read Request +################################################################################# +class Matter_IM_SubscribeResponse : Matter_IM_ReportData + var sub # subscription object + var report_data_phase # true during reportdata + + def init(msg, data, sub) + super(self).init(msg, data) + self.sub = sub + self.report_data_phase = true + end + + # return true if transaction is complete (remove object from queue) + # default responder for data + def send(responder) + if self.report_data_phase + var ret = super(self).send(responder) + if !ret return false end # ReportData needs to continue + # ReportData is finished + self.report_data_phase = false + return false + + else + # send the final SubscribeReponse + var resp = self.resp + var sr = matter.SubscribeResponseMessage() + sr.subscription_id = self.sub.subscription_id + sr.max_interval = self.sub.max_interval + + self.resp.opcode = 0x04 #- Subscribe Response -# + resp.encode(sr.to_TLV().encode()) # payload in cleartext + resp.encrypt() + responder.send_response(resp.raw, resp.remote_ip, resp.remote_port, resp.message_counter) + return true + end + end + +end +matter.IM_SubscribeResponse = Matter_IM_SubscribeResponse diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_IM_Subscription.be b/lib/libesp32/berry_matter/src/embedded/Matter_IM_Subscription.be new file mode 100644 index 000000000..f8ca285d6 --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_IM_Subscription.be @@ -0,0 +1,180 @@ +# +# Matter_IM_Subscription.be - suppport for Matter Interaction Model subscriptions +# +# 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 + +#@ solidify:Matter_IM_Subscription,weak +#@ solidify:Matter_IM_Subscription_Shop,weak + +################################################################################# +# Matter_IM_Subscription +# +# Individual subscription instance +################################################################################# +class Matter_IM_Subscription + static var MAX_INTERVAL_MARGIN = 10 # we always keep 10s margin + # parameters of the subscription + var subscription_id # id of the subcription as known by requester + var session # the session it belongs to + var path_list # list of path subscibed to + var min_interval # never send data more often than every `min_interval` seconds + var max_interval # always send data before `max_interal` seconds or the subscription is lost + var fabric_filtered + # manage time + var expiration # expiration epoch, we need to respond before + # updates + var updates + + # req: SubscribeRequestMessage + def init(id, session, req) + self.subscription_id = id + self.session = session + # check values for min_interval + var min_interval = req.min_interval_floor + if min_interval < 0 min_interval = 0 end + if min_interval > 60 min_interval = 60 end + self.min_interval = min_interval + # check values for max_interval + var max_interval = req.max_interval_ceiling + if max_interval < 60 max_interval = 60 end + if max_interval > 3600 max_interval = 3600 end + self.max_interval = max_interval + + self.fabric_filtered = req.fabric_filtered + + # get list of path from + self.path_list = [] + + for q: req.attributes_requests + var ctx = matter.Path() + ctx.endpoint = q.endpoint + ctx.cluster = q.cluster + ctx.attribute = q.attribute + self.path_list.push(ctx) + end + + # update next time interval + self.updates = [] + self.clear_and_arm() + + tasmota.log("MTR: new subsctiption " + matter.inspect(self), 2) + end + + # clear log after it was sent, and re-arm next expiration + def clear_and_arm() + self.updates.clear() + self.expiration = tasmota.millis() + (self.max_interval - self.MAX_INTERVAL_MARGIN) * 1000 + end + + # signal that an attribute was updated, to add to the list of reportable + def attribute_updated(ctx, fabric_specific) + var idx = 0 + while idx < size(self.path_list) + var filter = self.path_list[idx] + if (filter.endpoint == nil || filter.endpoint == ctx.endpoint) && + (filter.cluster == nil || filter.cluster == ctx.cluster) && + (filter.attribute == nil || filter.attribute == ctx.attribute) + + self.updates.push(ctx) + end + idx += 1 + end + end + +end +matter.IM_Subscription = Matter_IM_Subscription + +################################################################################# +# Matter_IM_Subscription_Shop (monad) +# +# Handles all subscriptions +################################################################################# +class Matter_IM_Subscription_Shop + var subs # list of subscriptions + var im # pointer to parent `im` object + + def init(im) + self.im = im + self.subs = [] + end + + ############################################################# + # create a new subscription + # + # session object + # SubscribeRequestMessage request + # returns: new subscription + def new_subscription(session, req) + import crypto + var id = crypto.random(2).get(0,2) + while self.get_by_id(id) + id = crypto.random(2).get(0,2) + end + + var sub = matter.IM_Subscription(id, session, req) + self.subs.push(sub) + + return sub + end + + def get_by_id(id) + var idx = 0 + while idx < size(self.subs) + if self.subs[idx].subscription_id == id + return self.subs[idx] + end + idx += 1 + end + end + + def remove_by_session(session) + var idx = 0 + while idx < size(self.subs) + if self.subs[idx].session == session + self.subs.remove(idx) + else + idx += 1 + end + end + end + + def every_second() + var idx = 0 + while idx < size(self.subs) + var sub = self.subs[idx] + if tasmota.time_reached(sub.expiration) + self.im.send_subscribe_update(sub) + sub.clear_and_arm() + end + idx += 1 + end + end + + # signal that an attribute was updated, to add to the list of reportable + def attribute_updated(ctx, fabric_specific) + # signal any relevant subscription + var idx = 0 + while idx < size(self.subs) + self.subs[idx].attribute_updated(ctx, fabric_specific) + idx += 1 + end + end + +end +matter.IM_Subscription_Shop = Matter_IM_Subscription_Shop diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Message.be b/lib/libesp32/berry_matter/src/embedded/Matter_Message.be index 8ca41200b..8f9e14fad 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Message.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Message.be @@ -232,6 +232,9 @@ class Matter_Frame # send back response var resp = classof(self)(self.message_handler) + resp.remote_ip = self.remote_ip + resp.remote_port = self.remote_port + if self.flag_s resp.flag_dsiz = 0x01 resp.dest_node_id_8 = self.source_node_id @@ -249,19 +252,23 @@ class Matter_Frame resp.protocol_id = 0 # PROTOCOL_ID_SECURE_CHANNEL resp.x_flag_a = 1 # ACK of previous message resp.ack_message_counter = self.message_counter - resp.x_flag_r = 0 + resp.x_flag_r = 1 - tasmota.log(string.format("MTR: Received %s from [%s]:%i", op_name, addr, port), 2) + tasmota.log(string.format("MTR: >Received %s from [%s]:%i", op_name, addr, port), 2) end self.commissioning.process_incoming(frame, addr, port) return true @@ -88,6 +92,8 @@ class Matter_MessageHandler tasmota.log("MTR: frame="+matter.inspect(frame), 3) return false end + if addr session.__ip = addr end + if port session.__port = port end frame.session = session # keep a pointer of the session in the message # check if it's a duplicate @@ -106,7 +112,7 @@ class Matter_MessageHandler # continue decoding tasmota.log(string.format("MTR: idx=%i clear=%s", frame.payload_idx, frame.raw.tohex()), 3) frame.decode_payload() - tasmota.log("MTR: decrypted message: protocol_id:"+str(frame.protocol_id)+" opcode="+str(frame.opcode)+" exchange_id"+str(frame.exchange_id), 3) + tasmota.log("MTR: decrypted message: protocol_id:"+str(frame.protocol_id)+" opcode="+str(frame.opcode)+" exchange_id="+str(frame.exchange_id), 3) self.device.packet_ack(frame.ack_message_counter) # acknowledge packet @@ -117,10 +123,22 @@ class Matter_MessageHandler tasmota.log("MTR: PROTOCOL_ID_SECURE_CHANNEL " + matter.inspect(frame), 3) # if frame.opcode == 0x10 # end - return true + ret = true elif protocol_id == 0x0001 # PROTOCOL_ID_INTERACTION_MODEL # dispatch to IM Protocol Messages - return self.im.process_incoming(frame, addr, port) + ret = self.im.process_incoming(frame, addr, port) + # if `ret` is true, we have something to send + if ret + self.im.send_enqueued(self) + + elif frame.x_flag_r # nothing to respond, check if we need a standalone ack + var resp = frame.build_standalone_ack() + resp.encode() + resp.encrypt() + # no ecnryption required for ACK + self.send_response(resp.raw, resp.remote_ip, resp.remote_port, resp.message_counter) + # send simple ack + end # -- PROTOCOL_ID_BDX is used for file transfer between devices, not used in Tasmota # elif protocol_id == 0x0002 # PROTOCOL_ID_BDX -- BDX not handled at all in Tasmota @@ -132,12 +150,11 @@ class Matter_MessageHandler # return false # ignore for now TODO else tasmota.log("MTR: ignoring unhandled protocol_id:"+str(protocol_id), 3) - return false end end - return true + return ret except .. as e, m tasmota.log("MTR: MessageHandler::msg_received exception: "+str(e)+";"+str(m)) import debug diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin.be index d66ecbe92..4e16d9464 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin.be @@ -91,7 +91,7 @@ class Matter_Plugin ############################################################# # write attribute - def write_attribute(msg, endpoint, cluster, attribute) + def write_attribute(msg, ctx, write_data) return nil end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_OnOff.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_OnOff.be new file mode 100644 index 000000000..e7827c5bf --- /dev/null +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_OnOff.be @@ -0,0 +1,156 @@ +# +# Matter_Plugin_OnOff.be - implements the behavior for a Relay (OnOff) +# +# 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 . +# + +# Matter plug-in for core behavior + +# dummy declaration for solidification +class Matter_Plugin end + +#@ solidify:Matter_Plugin_OnOff,weak + +class Matter_Plugin_OnOff : Matter_Plugin + static var ENDPOINTS = [ 1 ] + static var CLUSTERS = { + 0x001D: [0,1,2,3], # Descriptor Cluster 9.5 p.453 + 0x0003: [0,1], # Identify 1.2 p.16 + 0x0004: [0], # Groups 1.3 p.21 + 0x0005: [0,1,2,3,4,5], # Scenes 1.4 p.30 - no writable + 0x0006: [0,0xFFFC] # On/Off 1.5 p.48 + } + static var TYPES = [ 0x0100 ] # On/Off Light + + var onoff # fake status for now # TODO + + ############################################################# + # Constructor + def init(device) + super(self).init(device) + self.endpoints = self.ENDPOINTS + self.clusters = self.CLUSTERS + self.onoff = false # fake status for now # TODO + end + + ############################################################# + # read an attribute + # + def read_attribute(msg, ctx) + import string + var TLV = matter.TLV + var cluster = ctx.cluster + var attribute = ctx.attribute + + if cluster == 0x001D # ========== Descriptor Cluster 9.5 p.453 ========== + + if attribute == 0x0000 # ---------- DeviceTypeList / list[DeviceTypeStruct] ---------- + var dtl = TLV.Matter_TLV_array() + for dt: self.TYPES + var d1 = dtl.add_struct() + d1.add_TLV(0, TLV.U2, dt) # DeviceType + d1.add_TLV(1, TLV.U2, 1) # Revision + end + return dtl + elif attribute == 0x0001 # ---------- ServerList / list[cluster-id] ---------- + var sl = TLV.Matter_TLV_array() + for cl: self.get_cluster_list() + sl.add_TLV(nil, TLV.U4, cl) + end + return sl + elif attribute == 0x0002 # ---------- ClientList / list[cluster-id] ---------- + var cl = TLV.Matter_TLV_array() + cl.add_TLV(nil, TLV.U2, 0x0006) + return cl + elif attribute == 0x0003 # ---------- PartsList / list[endpoint-no]---------- + var pl = TLV.Matter_TLV_array() + return pl + end + + # ==================================================================================================== + elif cluster == 0x0003 # ========== Identify 1.2 p.16 ========== + if attribute == 0x0000 # ---------- IdentifyTime / u2 ---------- + return TLV.create_TLV(TLV.U2, 0) # no identification in progress + elif attribute == 0x0001 # ---------- IdentifyType / enum8 ---------- + return TLV.create_TLV(TLV.U1, 0) # IdentifyType = 0x00 None + end + + # ==================================================================================================== + elif cluster == 0x0006 # ========== On/Off 1.5 p.48 ========== + if attribute == 0x0000 # ---------- OnOff / bool ---------- + return TLV.create_TLV(TLV.BOOL, self.onoff) + elif attribute == 0xFFFC # ---------- FeatureMap / map32 ---------- + return TLV.create_TLV(TLV.U4, 0) # 0 = no Level Control for Lighting + end + + end + # no match found, return that the attribute is unsupported end + end + + ############################################################# + # Invoke a command + # + # returns a TLV object if successful, contains the response + # or an `int` to indicate a status + def invoke_request(msg, val, ctx) + var TLV = matter.TLV + var cluster = ctx.cluster + var command = ctx.command + var session = msg.session + + # ==================================================================================================== + if cluster == 0x0003 # ========== Identify 1.2 p.16 ========== + + if command == 0x0000 # ---------- Identify ---------- + # ignore + return true + elif command == 0x0001 # ---------- IdentifyQuery ---------- + # create IdentifyQueryResponse + # ID=1 + # 0=Certificate (octstr) + var iqr = TLV.Matter_TLV_struct() + iqr.add_TLV(0, TLV.U2, 0) # Timeout + ctx.command = 0x00 # IdentifyQueryResponse + return iqr + elif command == 0x0040 # ---------- TriggerEffect ---------- + # ignore + return true + end + # ==================================================================================================== + elif cluster == 0x0004 # ========== Groups 1.3 p.21 ========== + # TODO + return true + # ==================================================================================================== + elif cluster == 0x0005 # ========== Scenes 1.4 p.30 ========== + # TODO + return true + # ==================================================================================================== + elif cluster == 0x0006 # ========== On/Off 1.5 p.48 ========== + if command == 0x0000 # ---------- Off ---------- + self.onoff = false + return true + elif command == 0x0001 # ---------- On ---------- + self.onoff = true + return true + elif command == 0x0002 # ---------- Toggle ---------- + self.onoff = !self.onoff + return true + end + end + end +end +matter.Plugin_OnOff = Matter_Plugin_OnOff + \ No newline at end of file diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Relay.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Relay.be deleted file mode 100644 index 8721cca93..000000000 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Relay.be +++ /dev/null @@ -1,93 +0,0 @@ -# -# Matter_Plugin_Relay.be - implements the behavior for a Relay (OnOff) -# -# 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 . -# - -# Matter plug-in for core behavior - -# dummy declaration for solidification -class Matter_Plugin end - -#@ solidify:Matter_Plugin_Relay,weak - -class Matter_Plugin_Relay : Matter_Plugin - static var ENDPOINTS = [ 1 ] - static var CLUSTERS = { - 0x001D: [0,1,2,3], - 0x0003: [], - 0x0004: [], - 0x0005: [], - 0x0006: [0], - 0x0008: [], -# 0x0406: [] - } - static var TYPES = [ 0x0100 ] # On/Off Light - - ############################################################# - # Constructor - def init(device) - super(self).init(device) - self.endpoints = self.ENDPOINTS - self.clusters = self.CLUSTERS - end - - ############################################################# - # read an attribute - # - def read_attribute(msg, ctx) - import string - var TLV = matter.TLV - var cluster = ctx.cluster - var attribute = ctx.attribute - - if cluster == 0x001D # ========== Descriptor Cluster 9.5 p.453 ========== - - if attribute == 0x0000 # ---------- DeviceTypeList / list[DeviceTypeStruct] ---------- - var dtl = TLV.Matter_TLV_array() - var d1 = dtl.add_struct() - d1.add_TLV(0, TLV.U2, self.TYPES[0]) # DeviceType - d1.add_TLV(1, TLV.U2, 1) # Revision - return dtl - elif attribute == 0x0001 # ---------- ServerList / list[cluster-id] ---------- - var sl = TLV.Matter_TLV_array() - for cl: self.get_cluster_list() - sl.add_TLV(nil, TLV.U4, cl) - end - return sl - elif attribute == 0x0002 # ---------- ClientList / list[cluster-id] ---------- - var cl = TLV.Matter_TLV_array() - cl.add_TLV(nil, TLV.U2, 0x0006) - return cl - elif attribute == 0x0003 # ---------- PartsList / list[endpoint-no]---------- - var pl = TLV.Matter_TLV_array() - return pl - end - end - # no match found, return that the attribute is unsupported end - end - - ############################################################# - # Invoke a command - # - # returns a TLV object if successful, contains the response - # or an `int` to indicate a status - def invoke_request(msg, val, ctx) - # no match found, return that the command is unsupported - end -end -matter.Plugin_core = Matter_Plugin_core - \ No newline at end of file diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_core.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Root.be similarity index 78% rename from lib/libesp32/berry_matter/src/embedded/Matter_Plugin_core.be rename to lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Root.be index 4c8929cff..88ccfbb05 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_core.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Root.be @@ -1,5 +1,5 @@ # -# Matter_Plugin_core.be - implements the core features that a Matter device must implemment +# Matter_Plugin_Root.be - implements the core features that a Matter device must implemment # # Copyright (C) 2023 Stephan Hadinger & Theo Arends # @@ -17,30 +17,33 @@ # along with this program. If not, see . # -# Matter plug-in for core behavior +# Matter plug-in for root behavior # dummy declaration for solidification class Matter_Plugin end -#@ solidify:Matter_Plugin_core,weak +#@ solidify:Matter_Plugin_Root,weak -class Matter_Plugin_core : Matter_Plugin +class Matter_Plugin_Root : Matter_Plugin static var ENDPOINTS = [ 0 ] static var CLUSTERS = { - 0x001D: [0,1,2,3], - 0x0028: [0,1,2,3,4,5,6,7,8,9], - 0x002B: [0,1], - 0x002C: [0,1,2], - 0x0030: [0,1,2,3,4], - 0x0031: [3,0xFFFC], - 0x0032: [], - 0x0033: [0,1,2,8], - 0x0034: [], - 0x0038: [0,1,7], - 0x003E: [0,1,2,3,4,5], - 0x003C: [], - 0x003F: [] + 0x001D: [0,1,2,3], # Descriptor Cluster 9.5 p.453 + 0x001F: [0,2,3,4], # Access Control Cluster, p.461 + 0x0028: [0,1,2,3,4,5,6,7,8,9,0x12],# Basic Information Cluster cluster 11.1 p.565 + 0x002A: [0,1,2,3], # OTA Software Update Requestor Cluster Definition 11.19.7 p.762 + 0x002B: [0,1], # Localization Configuration Cluster 11.3 p.580 + 0x002C: [0,1,2], # Time Format Localization Cluster 11.4 p.581 + 0x0030: [0,1,2,3,4], # GeneralCommissioning cluster 11.9 p.627 + 0x0031: [3,4,0xFFFC], # Network Commissioning Cluster cluster 11.8 p.606 + 0x0032: [], # Diagnostic Logs Cluster 11.10 p.637 + 0x0033: [0,1,2,8], # General Diagnostics Cluster 11.11 p.642 + 0x0034: [], # Software Diagnostics Cluster 11.12 p.654 + 0x0038: [0,1,7], # Time Synchronization 11.16 p.689 + 0x003C: [], # Administrator Commissioning Cluster 11.18 p.725 + 0x003E: [0,1,2,3,4,5], # Node Operational Credentials Cluster 11.17 p.704 + 0x003F: [] # Group Key Management Cluster 11.2 p.572 } + static var TYPES = [ 0x0016 ] # On/Off Light ############################################################# # Constructor @@ -62,7 +65,7 @@ class Matter_Plugin_core : Matter_Plugin if cluster == 0x0030 # ========== GeneralCommissioning cluster 11.9 p.627 ========== if attribute == 0x0000 # ---------- Breadcrumb ---------- - return TLV.create_TLV(TLV.U8, msg.session.breadcrumb) + return TLV.create_TLV(TLV.U8, msg.session.__breadcrumb) elif attribute == 0x0001 # ---------- BasicCommissioningInfo / BasicCommissioningInfo---------- var bci = TLV.Matter_TLV_struct() bci.add_TLV(0, TLV.U2, 60) # FailSafeExpiryLengthSeconds @@ -211,19 +214,34 @@ class Matter_Plugin_core : Matter_Plugin return TLV.create_TLV(TLV.U2, 0) elif attribute == 0x000A # ---------- SoftwareVersionString / string ---------- return TLV.create_TLV(TLV.UTF1, tasmota.cmd("Status 2")['StatusFWR']['Version']) + elif attribute == 0x0012 # ---------- UniqueID / string 32 max ---------- + return TLV.create_TLV(TLV.UTF1, tasmota.wifi().find("mac", "")) end # ==================================================================================================== elif cluster == 0x003F # ========== Group Key Management Cluster 11.2 p.572 ========== # TODO + # ==================================================================================================== + elif cluster == 0x002A # ========== OTA Software Update Requestor Cluster Definition 11.19.7 p.762 ========== + + if attribute == 0x0000 # ---------- DefaultOTAProviders / list[ProviderLocationStruct] ---------- + return TLV.Matter_TLV_array() # empty list for now TODO + elif attribute == 0x0001 # ---------- UpdatePossible / bool ---------- + return TLV.create_TLV(TLV.BOOL, 0) # we claim that update is not possible, would require to go to Tasmota UI + elif attribute == 0x0002 # ---------- UpdateState / UpdateStateEnum ---------- + return TLV.create_TLV(TLV.U1, 1) # Idle + elif attribute == 0x0003 # ---------- UpdateStateProgress / uint8 ---------- + return TLV.create_TLV(TLV.NULL, nil) # null, nothing in process + end + # ==================================================================================================== elif cluster == 0x002B # ========== Localization Configuration Cluster 11.3 p.580 ========== if attribute == 0x0000 # ---------- ActiveLocale / string ---------- return TLV.create_TLV(TLV.UTF1, tasmota.locale()) elif attribute == 0x0001 # ---------- SupportedLocales / list[string] ---------- - var locl = TLV.Matter_TLV_list() + var locl = TLV.Matter_TLV_array() locl.add_TLV(nil, TLV.UTF1, tasmota.locale()) return locl end @@ -236,7 +254,7 @@ class Matter_Plugin_core : Matter_Plugin elif attribute == 0x0001 # ---------- ActiveCalendarType / CalendarType ---------- return TLV.create_TLV(TLV.U1, 4) # 4 = Gregorian elif attribute == 0x0002 # ---------- SupportedCalendarTypes / list[CalendarType] ---------- - var callist = TLV.Matter_TLV_list() + var callist = TLV.Matter_TLV_array() callist.add_TLV(nil, TLV.create_TLV(TLV.U1, 4)) return callist end @@ -252,6 +270,13 @@ class Matter_Plugin_core : Matter_Plugin # ==================================================================================================== elif cluster == 0x001D # ========== Descriptor Cluster 9.5 p.453 ========== if attribute == 0x0000 # ---------- DeviceTypeList / list[DeviceTypeStruct] ---------- + var dtl = TLV.Matter_TLV_array() + for dt: self.TYPES + var d1 = dtl.add_struct() + d1.add_TLV(0, TLV.U2, dt) # DeviceType + d1.add_TLV(1, TLV.U2, 1) # Revision + end + return dtl elif attribute == 0x0001 # ---------- ServerList / list[cluster-id] ---------- var sl = TLV.Matter_TLV_array() for cl: self.get_cluster_list() @@ -297,7 +322,7 @@ class Matter_Plugin_core : Matter_Plugin # 1=DebugText var ExpiryLengthSeconds = val.findsubval(0, 900) var Breadcrumb = val.findsubval(1, 0) - session.breadcrumb = Breadcrumb + session.__breadcrumb = Breadcrumb var afsr = TLV.Matter_TLV_struct() afsr.add_TLV(0, TLV.U1, 0) # ErrorCode = OK @@ -309,7 +334,7 @@ class Matter_Plugin_core : Matter_Plugin var NewRegulatoryConfig = val.findsubval(0) # RegulatoryLocationType Enum var CountryCode = val.findsubval(1, "XX") var Breadcrumb = val.findsubval(2, 0) - session.breadcrumb = Breadcrumb + session.__breadcrumb = Breadcrumb # create SetRegulatoryConfigResponse # ID=1 # 0=ErrorCode (OK=0) @@ -322,7 +347,7 @@ class Matter_Plugin_core : Matter_Plugin elif command == 0x0004 # ---------- CommissioningComplete p.636 ---------- # no data - session.breadcrumb = 0 # clear breadcrumb + session.__breadcrumb = 0 # clear breadcrumb session.set_no_expiration() # create CommissioningCompleteResponse @@ -487,6 +512,85 @@ class Matter_Plugin_core : Matter_Plugin end end + + ############################################################# + # write an attribute + # + def write_attribute(msg, ctx, write_data) + import string + var TLV = matter.TLV + var cluster = ctx.cluster + var attribute = ctx.attribute + + # 0x001D no writable attributes + # 0x0032 no attributes + # 0x0033 no writable attributes + # 0x0034 no writable attributes + # 0x0038 no mandatory writable attributes + # 0x003C no writable attributes + # 0x003E no writable attributes + + if cluster == 0x0030 # ========== GeneralCommissioning cluster 11.9 p.627 ========== + + if attribute == 0x0000 # ---------- Breadcrumb ---------- + if type(write_data) == 'int' || isinstance(write_data, int64) + msg.session.__breadcrumb = write_data + return true + else + ctx.status = matter.CONSTRAINT_ERROR + return false + end + end + + # ==================================================================================================== + elif cluster == 0x001F # ========== Access Control Cluster 9.10 p.461 ========== + if attribute == 0x0000 # ACL - list[AccessControlEntryStruct] + return true + end + + # ==================================================================================================== + elif cluster == 0x0028 # ========== Basic Information Cluster cluster 11.1 p.565 ========== + + if attribute == 0x0005 # ---------- NodeLabel / string ---------- + # TODO + return true + elif attribute == 0x0006 # ---------- Location / string ---------- + # TODO + return true + end + # ==================================================================================================== + elif cluster == 0x002A # ========== OTA Software Update Requestor Cluster Definition 11.19.7 p.762 ========== + + if attribute == 0x0000 # ---------- DefaultOTAProviders / list[ProviderLocationStruct] ---------- + return true # silently ignore + end + # ==================================================================================================== + elif cluster == 0x002B # ========== Localization Configuration Cluster 11.3 p.580 ========== + + if attribute == 0x0000 # ---------- ActiveLocale / string ---------- + ctx.status = matter.CONSTRAINT_ERROR # changing locale is not possible + return false + end + # ==================================================================================================== + elif cluster == 0x002C # ========== Time Format Localization Cluster 11.4 p.581 ========== + + if attribute == 0x0000 # ---------- HourFormat / HourFormat ---------- + # TODO + return true + elif attribute == 0x0001 # ---------- ActiveCalendarType / CalendarType ---------- + # TODO + return true + end + # ==================================================================================================== + elif cluster == 0x0031 # ========== Network Commissioning Cluster cluster 11.8 p.606 ========== + if attribute == 0x0004 # ---------- InterfaceEnabled / bool ---------- + ctx.status = matter.INVALID_ACTION + return false + end + + + end + end end -matter.Plugin_core = Matter_Plugin_core +matter.Plugin_Root = Matter_Plugin_Root \ No newline at end of file diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Session.be b/lib/libesp32/berry_matter/src/embedded/Matter_Session.be index 1f46e0f32..9d57e24ee 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Session.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Session.be @@ -47,6 +47,10 @@ class Matter_Session # counters var counter_rcv # counter for incoming messages var counter_snd # counter for outgoing messages + var __exchange_id # exchange id for locally initiated transaction, non-persistent + # keep track of last known IP/Port of the fabric + var __ip + var __port # non-session counters var _counter_insecure_rcv # counter for incoming messages var _counter_insecure_snd # counter for outgoing messages @@ -57,7 +61,7 @@ class Matter_Session var attestation_challenge # Attestation challenge var peer_node_id # breadcrumb - var breadcrumb # breadcrumb attribute for this session + var __breadcrumb # breadcrumb attribute for this session, prefix `__` so that it is not persisted and untouched # our own private key var no_private_key # private key of the device certificate (generated at commissioning) # NOC information @@ -90,6 +94,7 @@ class Matter_Session ############################################################# def init(store, local_session_id, initiator_session_id) + import crypto self.__store = store self.mode = 0 self.local_session_id = local_session_id @@ -98,7 +103,8 @@ class Matter_Session self.counter_snd = matter.Counter() self._counter_insecure_rcv = matter.Counter() self._counter_insecure_snd = matter.Counter() - self.breadcrumb = int64() + self.__breadcrumb = 0 + self.__exchange_id = crypto.random(2).get(0,2) # generate a random 16 bits number, then increment with rollover end ############################################################# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be b/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be index 8e927da7c..4296e83e0 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be @@ -297,6 +297,83 @@ class Matter_TLV return b end + ############################################################# + # compute the length in bytes of encoded TLV without actually + # allocating buffers (faster and no memory fragmentation) + # + # returns a number of bytes + def encode_len() + var TLV = self.TLV + var len = 0 + + # special case for bool + # we need to change the type according to the value + if self.typ == TLV.BFALSE || self.typ == TLV.BTRUE + self.typ = bool(self.val) ? TLV.BTRUE : TLV.BFALSE + # try to compress ints + elif self.typ >= TLV.I2 && self.typ <= TLV.I4 + var i = int(self.val) + if i <= 127 && i >= -128 self.typ = TLV.I1 + elif i <= 32767 && i >= -32768 self.typ = TLV.I2 + end + elif self.typ >= TLV.U2 && self.typ <= TLV.U4 + var i = int(self.val) + if i <= 255 && i >= 0 self.typ = TLV.U1 + elif i <= 65535 && i >= 0 self.typ = TLV.U2 + end + elif self.typ >= TLV.B1 && self.typ <= TLV.B8 # encode length as minimum possible + if size(self.val) <= 255 + self.typ = TLV.B1 + elif size(self.val) <= 65535 + self.typ = TLV.B2 + else + self.typ = TLV.B4 # B4 is unlikely, B8 is impossible + end + elif self.typ >= TLV.UTF1 && self.typ <= TLV.UTF8 + if size(self.val) <= 255 + self.typ = TLV.UTF1 + elif size(self.val) <= 65535 + self.typ = TLV.UTF2 + else + self.typ = TLV.UTF4 # UTF4 is unlikely, UTF8 is impossible + end + end + + # encode tag and type + len += self._encode_tag_len() + # encode value + + if self.typ == TLV.I1 || self.typ == TLV.U1 + len += 1 + elif self.typ == TLV.I2 || self.typ == TLV.U2 + len += 2 + elif self.typ == TLV.I4 || self.typ == TLV.U4 + len += 4 + elif self.typ == TLV.I8 || self.typ == TLV.U8 + len += 8 + elif self.typ == TLV.BFALSE || self.typ == TLV.BTRUE + # push nothing + elif self.typ == TLV.FLOAT + len += 4 + elif self.typ == TLV.DOUBLE + raise "value_error", "Unsupported type TLV.DOUBLE" + elif self.typ == TLV.UTF1 + len += 1 + size(self.val) + elif self.typ == TLV.UTF2 + len += 2 + size(self.val) + elif self.typ == TLV.B1 + len += 1 + size(self.val) + elif self.typ == TLV.B2 + len += 2 + size(self.val) + elif self.typ == TLV.NULL + # push nothing + else + raise "value_error", "unsupported type " + str(self.typ) + end + + return len + end + ############################################################# # internal_function # encode Tag+Type as the first bytes @@ -341,6 +418,39 @@ class Matter_TLV end end + ############################################################# + # internal_function + # compute len of Tag+Type as the first bytes + def _encode_tag_len() + var tag_number = self.tag_number != nil ? self.tag_number : 0 + var tag_huge = (tag_number >= 65536) || (tag_number < 0) + var tag_control = 0x00 + if self.tag_vendor != nil + # full encoding + if tag_huge + return 9 + else + return 7 + end + elif self.tag_profile == -1 # Matter Common profile + if tag_huge + return 5 + else + return 3 + end + elif self.tag_profile != nil + if tag_huge + return 5 + else + return 3 + end + elif self.tag_sub != nil + return 2 + else # anonymous tag + return 1 + end + end + ############################################################# # Compare the value index with an element # returns: @@ -494,16 +604,14 @@ class Matter_TLV end ############################################################# - # encode TLV - # - # appends to the bytes() object - def _encode_inner(b, is_struct) + # encode to bytes + def encode(b) if b == nil b = bytes() end # encode tag and type self._encode_tag(b) # sort values var val_list = self.val.copy() - if is_struct + if self.is_struct self.sort(val_list) end @@ -519,9 +627,22 @@ class Matter_TLV end ############################################################# - # encode to bytes - def encode(b) - return self._encode_inner(b, self.is_struct) + # compute the length in bytes of encoded TLV without actually + # allocating buffers (faster and no memory fragmentation) + # + # returns a number of bytes + def encode_len() + # tag and type + var len = self._encode_tag_len() + # output each one after the other, order doesn't infulence size + var idx = 0 + while idx < size(self.val) + len += self.val[idx].encode_len() + idx += 1 + end + # add 'end of container' + len += 1 + return len end ############################################################# @@ -760,117 +881,52 @@ matter.TLV = Matter_TLV # Test import matter -#load("Matter_TLV.be") +def test_TLV(b, s) + var m = matter.TLV.parse(b) + assert(m.tostring() == s) + assert(m.encode() == b) + assert(m.encode_len() == size(b)) +end -var m -m = matter.TLV.parse(bytes("2502054C")) -assert(m.tostring() == "2 = 19461U") -assert(m.encode() == bytes("2502054C")) +test_TLV(bytes("2502054C"), "2 = 19461U") +test_TLV(bytes("0001"), "1") +test_TLV(bytes("08"), "false") +test_TLV(bytes("09"), "true") -m = matter.TLV.parse(bytes("0001")) -assert(m.tostring() == "1") -assert(m.encode() == bytes("0001")) +test_TLV(bytes("00FF"), "-1") +test_TLV(bytes("05FFFF"), "65535U") -m = matter.TLV.parse(bytes("08")) -assert(m.tostring() == "false") -assert(m.encode() == bytes("08")) -m = matter.TLV.parse(bytes("09")) -assert(m.tostring() == "true") -assert(m.encode() == bytes("09")) - -m = matter.TLV.parse(bytes("01FFFF")) -assert(m.tostring() == "-1") -assert(m.encode() == bytes("00FF")) -m = matter.TLV.parse(bytes("05FFFF")) -assert(m.tostring() == "65535U") -assert(m.encode() == bytes("05FFFF")) - -m = matter.TLV.parse(bytes("0A0000C03F")) -assert(m.tostring() == "1.5") -assert(m.encode() == bytes("0A0000C03F")) - -m = matter.TLV.parse(bytes("0C06466f6f626172")) -assert(m.tostring() == '"Foobar"') -assert(m.encode() == bytes("0C06466f6f626172")) - -m = matter.TLV.parse(bytes("1006466f6f626172")) -assert(m.tostring() == "466F6F626172") -assert(m.encode() == bytes("1006466f6f626172")) - -m = matter.TLV.parse(bytes("e4f1ffeddeedfe55aa2a")) -assert(m.tostring() == "0xFFF1::0xDEED:0xAA55FEED = 42U") -assert(m.encode() == bytes("e4f1ffeddeedfe55aa2a")) - - -m = matter.TLV.parse(bytes("300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66")) -assert(m.tostring() == "1 = D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66") -assert(m.encode() == bytes("300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66")) +test_TLV(bytes("0A0000C03F"), "1.5") +test_TLV(bytes("0C06466f6f626172"), '"Foobar"') +test_TLV(bytes("1006466f6f626172"), "466F6F626172") +test_TLV(bytes("e4f1ffeddeedfe55aa2a"), "0xFFF1::0xDEED:0xAA55FEED = 42U") +test_TLV(bytes("300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66"), "1 = D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66") # context specific -m = matter.TLV.parse(bytes("24012a")) -assert(m.tostring() == "1 = 42U") -assert(m.encode() == bytes("24012a")) - -m = matter.TLV.parse(bytes("4401002a")) -assert(m.tostring() == "Matter::0x00000001 = 42U") -assert(m.encode() == bytes("4401002a")) +test_TLV(bytes("24012a"), "1 = 42U") +test_TLV(bytes("4401002a"), "Matter::0x00000001 = 42U") # int64 -m = matter.TLV.parse(bytes("030102000000000000")) -assert(m.tostring() == "513") -assert(m.encode() == bytes("030102000000000000")) - -m = matter.TLV.parse(bytes("070102000000000000")) -assert(m.tostring() == "513U") -assert(m.encode() == bytes("070102000000000000")) - -m = matter.TLV.parse(bytes("03FFFFFFFFFFFFFFFF")) -assert(m.tostring() == "-1") -assert(m.encode() == bytes("03FFFFFFFFFFFFFFFF")) - -m = matter.TLV.parse(bytes("07FFFFFFFFFFFFFF7F")) -assert(m.tostring() == "9223372036854775807U") -assert(m.encode() == bytes("07FFFFFFFFFFFFFF7F")) +test_TLV(bytes("030102000000000000"), "513") +test_TLV(bytes("070102000000000000"), "513U") +test_TLV(bytes("03FFFFFFFFFFFFFFFF"), "-1") +test_TLV(bytes("07FFFFFFFFFFFFFF7F"), "9223372036854775807U") # structure -m = matter.TLV.parse(bytes("1518")) -assert(m.tostring() == "{}") -assert(m.encode() == bytes("1518")) - -m = matter.TLV.parse(bytes("15300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D662502054C240300280418")) -assert(m.tostring() == "{1 = D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66, 2 = 19461U, 3 = 0U, 4 = false}") -assert(m.encode() == bytes("15300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D662502054C240300280418")) - -m = matter.TLV.parse(bytes("15300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D662502054C240300280435052501881325022C011818")) -assert(m.tostring() == "{1 = D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66, 2 = 19461U, 3 = 0U, 4 = false, 5 = {1 = 5000U, 2 = 300U}}") -assert(m.encode() == bytes("15300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D662502054C240300280435052501881325022C011818")) +test_TLV(bytes("1518"), "{}") +test_TLV(bytes("15300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D662502054C240300280418"), "{1 = D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66, 2 = 19461U, 3 = 0U, 4 = false}") +test_TLV(bytes("15300120D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D662502054C240300280435052501881325022C011818"), "{1 = D2DAEE8760C9B1D1B25E0E2E4DD6ECA8AEF6193C0203761356FCB06BBEDD7D66, 2 = 19461U, 3 = 0U, 4 = false, 5 = {1 = 5000U, 2 = 300U}}") # list -m = matter.TLV.parse(bytes("1718")) -assert(m.tostring() == "[[]]") -assert(m.encode() == bytes("1718")) - -m = matter.TLV.parse(bytes("17000120002a000200032000ef18")) -assert(m.tostring() == "[[1, 0 = 42, 2, 3, 0 = -17]]") -assert(m.encode() == bytes("17000120002a000200032000ef18")) - +test_TLV(bytes("1718"), "[[]]") +test_TLV(bytes("17000120002a000200032000ef18"), "[[1, 0 = 42, 2, 3, 0 = -17]]") # array -m = matter.TLV.parse(bytes("1618")) -assert(m.tostring() == "[]") -assert(m.encode() == bytes("1618")) - -m = matter.TLV.parse(bytes("160000000100020003000418")) -assert(m.tostring() == "[0, 1, 2, 3, 4]") -assert(m.encode() == bytes("160000000100020003000418")) +test_TLV(bytes("1618"), "[]") +test_TLV(bytes("160000000100020003000418"), "[0, 1, 2, 3, 4]") # mix -m = matter.TLV.parse(bytes("16002a02f067fdff15180a33338f410c0648656c6c6f2118")) -assert(m.tostring() == '[42, -170000, {}, 17.9, "Hello!"]') -assert(m.encode() == bytes("16002a02f067fdff15180a33338f410c0648656c6c6f2118")) - -m = matter.TLV.parse(bytes("153600172403312504FCFF18172402002403302404001817240200240330240401181724020024033024040218172402002403302404031817240200240328240402181724020024032824040418172403312404031818280324FF0118")) -assert(m.tostring() == '{0 = [[[3 = 49U, 4 = 65532U]], [[2 = 0U, 3 = 48U, 4 = 0U]], [[2 = 0U, 3 = 48U, 4 = 1U]], [[2 = 0U, 3 = 48U, 4 = 2U]], [[2 = 0U, 3 = 48U, 4 = 3U]], [[2 = 0U, 3 = 40U, 4 = 2U]], [[2 = 0U, 3 = 40U, 4 = 4U]], [[3 = 49U, 4 = 3U]]], 3 = false, 255 = 1U}') -assert(m.encode() == bytes("153600172403312504FCFF18172402002403302404001817240200240330240401181724020024033024040218172402002403302404031817240200240328240402181724020024032824040418172403312404031818280324FF0118")) +test_TLV(bytes("16002a02f067fdff15180a33338f410c0648656c6c6f2118"), '[42, -170000, {}, 17.9, "Hello!"]') +test_TLV(bytes("153600172403312504FCFF18172402002403302404001817240200240330240401181724020024033024040218172402002403302404031817240200240328240402181724020024032824040418172403312404031818280324FF0118"), '{0 = [[[3 = 49U, 4 = 65532U]], [[2 = 0U, 3 = 48U, 4 = 0U]], [[2 = 0U, 3 = 48U, 4 = 1U]], [[2 = 0U, 3 = 48U, 4 = 2U]], [[2 = 0U, 3 = 48U, 4 = 3U]], [[2 = 0U, 3 = 40U, 4 = 2U]], [[2 = 0U, 3 = 40U, 4 = 4U]], [[3 = 49U, 4 = 3U]]], 3 = false, 255 = 1U}') -# diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_UDPServer.be b/lib/libesp32/berry_matter/src/embedded/Matter_UDPServer.be index 75df885c3..3bd7d16a5 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_UDPServer.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_UDPServer.be @@ -55,9 +55,9 @@ class Matter_UDPPacket_sent import string var ok = udp_socket.send(self.addr ? self.addr : udp_socket.remote_ip, self.port ? self.port : udp_socket.remote_port, self.raw) if ok - tasmota.log(string.format("MTR: sending packet to '[%s]:%i'", self.addr, self.port), 3) + tasmota.log(string.format("MTR: sending packet to '[%s]:%i'", self.addr, self.port), 4) else - tasmota.log(string.format("MTR: failed to send packet to '[%s]:%i'", self.addr, self.port), 2) + tasmota.log(string.format("MTR: error sending packet to '[%s]:%i'", self.addr, self.port), 3) end end end @@ -144,7 +144,9 @@ class Matter_UDPServer packet.send(self.udp_socket) # resend packet.retries -= 1 if packet.retries <= 0 + import string self.packets_sent.remove(packet.msg_id) + tasmota.log(string.format("MTR: non-acked packet to '[%s]:%i'", packet.addr, packet.port), 3) else packet.next_try = tasmota.millis() + packet.RETRY_MS end @@ -158,7 +160,7 @@ class Matter_UDPServer if id == nil return end if self.packets_sent.contains(id) self.packets_sent.remove(id) - tasmota.log("MTR: removed packet from sending list id=" + str(id), 3) + tasmota.log("MTR: removed packet from sending list id=" + str(id), 4) end end diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning.h index 8888f26c3..17d55b2a0 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning.h @@ -19,7 +19,7 @@ be_local_closure(Matter_Commisioning_Context_parse_PBKDFParamRequest, /* name 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[48]) { /* constants */ + ( &(const bvalue[47]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(opcode), /* K2 */ be_nested_str_weak(local_session_id), @@ -58,16 +58,15 @@ be_local_closure(Matter_Commisioning_Context_parse_PBKDFParamRequest, /* name /* K35 */ be_nested_str_weak(log), /* K36 */ be_nested_str_weak(MTR_X3A_X20pbkdfparamresp_X3A_X20), /* K37 */ be_nested_str_weak(inspect), - /* K38 */ be_const_int(3), - /* K39 */ be_nested_str_weak(encode), - /* K40 */ be_nested_str_weak(MTR_X3A_X20pbkdfparamresp_raw_X3A_X20), - /* K41 */ be_nested_str_weak(tohex), - /* K42 */ be_nested_str_weak(build_response), - /* K43 */ be_nested_str_weak(responder), - /* K44 */ be_nested_str_weak(send_response), - /* K45 */ be_nested_str_weak(remote_ip), - /* K46 */ be_nested_str_weak(remote_port), - /* K47 */ be_nested_str_weak(message_counter), + /* K38 */ be_nested_str_weak(encode), + /* K39 */ be_nested_str_weak(MTR_X3A_X20pbkdfparamresp_raw_X3A_X20), + /* K40 */ be_nested_str_weak(tohex), + /* K41 */ be_nested_str_weak(build_response), + /* K42 */ be_nested_str_weak(responder), + /* K43 */ be_nested_str_weak(send_response), + /* K44 */ be_nested_str_weak(remote_ip), + /* K45 */ be_nested_str_weak(remote_port), + /* K46 */ be_nested_str_weak(message_counter), }), be_str_weak(parse_PBKDFParamRequest), &be_const_str_solidified, @@ -139,31 +138,31 @@ be_local_closure(Matter_Commisioning_Context_parse_PBKDFParamRequest, /* name 0x7C200400, // 0040 CALL R8 2 0x7C1C0200, // 0041 CALL R7 1 0x001E4807, // 0042 ADD R7 K36 R7 - 0x58200026, // 0043 LDCONST R8 K38 + 0x54220003, // 0043 LDINT R8 4 0x7C140600, // 0044 CALL R5 3 - 0x8C140927, // 0045 GETMET R5 R4 K39 + 0x8C140926, // 0045 GETMET R5 R4 K38 0x7C140200, // 0046 CALL R5 1 0xB81A4400, // 0047 GETNGBL R6 K34 0x8C180D23, // 0048 GETMET R6 R6 K35 - 0x8C200B29, // 0049 GETMET R8 R5 K41 + 0x8C200B28, // 0049 GETMET R8 R5 K40 0x7C200200, // 004A CALL R8 1 - 0x00225008, // 004B ADD R8 K40 R8 - 0x58240026, // 004C LDCONST R9 K38 + 0x00224E08, // 004B ADD R8 K39 R8 + 0x54260003, // 004C LDINT R9 4 0x7C180600, // 004D CALL R6 3 0x90023205, // 004E SETMBR R0 K25 R5 - 0x8C18032A, // 004F GETMET R6 R1 K42 + 0x8C180329, // 004F GETMET R6 R1 K41 0x54220020, // 0050 LDINT R8 33 0x50240200, // 0051 LDBOOL R9 1 0 0x7C180600, // 0052 CALL R6 3 - 0x8C1C0D27, // 0053 GETMET R7 R6 K39 + 0x8C1C0D26, // 0053 GETMET R7 R6 K38 0x5C240A00, // 0054 MOVE R9 R5 0x7C1C0400, // 0055 CALL R7 2 - 0x8820012B, // 0056 GETMBR R8 R0 K43 - 0x8C20112C, // 0057 GETMET R8 R8 K44 + 0x8820012A, // 0056 GETMBR R8 R0 K42 + 0x8C20112B, // 0057 GETMET R8 R8 K43 0x5C280E00, // 0058 MOVE R10 R7 - 0x882C032D, // 0059 GETMBR R11 R1 K45 - 0x8830032E, // 005A GETMBR R12 R1 K46 - 0x88340D2F, // 005B GETMBR R13 R6 K47 + 0x882C032C, // 0059 GETMBR R11 R1 K44 + 0x8830032D, // 005A GETMBR R12 R1 K45 + 0x88340D2E, // 005B GETMBR R13 R6 K46 0x7C200A00, // 005C CALL R8 5 0x80000000, // 005D RET 0 }) @@ -226,7 +225,7 @@ be_local_closure(Matter_Commisioning_Context_parse_Pake1, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[84]) { /* constants */ + ( &(const bvalue[79]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(opcode), /* K2 */ be_nested_str_weak(local_session_id), @@ -244,77 +243,72 @@ be_local_closure(Matter_Commisioning_Context_parse_Pake1, /* name */ /* K14 */ be_nested_str_weak(log), /* K15 */ be_nested_str_weak(MTR_X3A_X20received_X20pA_X3D), /* K16 */ be_nested_str_weak(tohex), - /* K17 */ be_const_int(3), - /* K18 */ be_nested_str_weak(MTR_X3A_X20spake_X3A_X20), - /* K19 */ be_nested_str_weak(inspect), - /* K20 */ be_nested_str_weak(spake), - /* K21 */ be_nested_str_weak(SPAKE2P_Matter), - /* K22 */ be_nested_str_weak(device), - /* K23 */ be_nested_str_weak(w0), - /* K24 */ be_nested_str_weak(w1), - /* K25 */ be_nested_str_weak(L), - /* K26 */ be_nested_str_weak(compute_pB), - /* K27 */ be_nested_str_weak(y), - /* K28 */ be_nested_str_weak(pB), - /* K29 */ be_nested_str_weak(MTR_X3A_X20y_X3D), - /* K30 */ be_nested_str_weak(MTR_X3A_X20pb_X3D), - /* K31 */ be_nested_str_weak(compute_ZV_verifier), - /* K32 */ be_nested_str_weak(MTR_X3A_X20Z_X3D), - /* K33 */ be_nested_str_weak(Z), - /* K34 */ be_nested_str_weak(MTR_X3A_X20V_X3D), - /* K35 */ be_nested_str_weak(V), - /* K36 */ be_nested_str_weak(SHA256), - /* K37 */ be_nested_str_weak(update), - /* K38 */ be_nested_str_weak(fromstring), - /* K39 */ be_nested_str_weak(Matter_Context_Prefix), - /* K40 */ be_nested_str_weak(PBKDFParamRequest), - /* K41 */ be_nested_str_weak(PBKDFParamResponse), - /* K42 */ be_nested_str_weak(out), - /* K43 */ be_nested_str_weak(MTR_X3A_X20Context_X3D), - /* K44 */ be_nested_str_weak(set_context), - /* K45 */ be_nested_str_weak(compute_TT_hash), - /* K46 */ be_nested_str_weak(MTR_X3A_X20_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D), - /* K47 */ be_nested_str_weak(MTR_X3A_X20Context_X20_X3D_X20), - /* K48 */ be_nested_str_weak(Context), - /* K49 */ be_nested_str_weak(MTR_X3A_X20A_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K50 */ be_nested_str_weak(A), - /* K51 */ be_nested_str_weak(MTR_X3A_X20B_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K52 */ be_nested_str_weak(B), - /* K53 */ be_nested_str_weak(MTR_X3A_X20M_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K54 */ be_nested_str_weak(M), - /* K55 */ be_nested_str_weak(MTR_X3A_X20N_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K56 */ be_nested_str_weak(N), - /* K57 */ be_nested_str_weak(MTR_X3A_X20pA_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K58 */ be_nested_str_weak(MTR_X3A_X20pB_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K59 */ be_nested_str_weak(MTR_X3A_X20Z_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K60 */ be_nested_str_weak(MTR_X3A_X20V_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K61 */ be_nested_str_weak(MTR_X3A_X20w0_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K62 */ be_nested_str_weak(MTR_X3A_X20Kmain_X20_X20_X20_X3D), - /* K63 */ be_nested_str_weak(Kmain), - /* K64 */ be_nested_str_weak(MTR_X3A_X20KcA_X20_X20_X20_X20_X20_X3D), - /* K65 */ be_nested_str_weak(KcA), - /* K66 */ be_nested_str_weak(MTR_X3A_X20KcB_X20_X20_X20_X20_X20_X3D), - /* K67 */ be_nested_str_weak(KcB), - /* K68 */ be_nested_str_weak(MTR_X3A_X20K_shared_X3D), - /* K69 */ be_nested_str_weak(K_shared), - /* K70 */ be_nested_str_weak(MTR_X3A_X20Ke_X20_X20_X20_X20_X20_X20_X3D), - /* K71 */ be_nested_str_weak(Ke), - /* K72 */ be_nested_str_weak(cB), - /* K73 */ be_nested_str_weak(MTR_X3A_X20cB_X3D), - /* K74 */ be_nested_str_weak(Pake2), - /* K75 */ be_nested_str_weak(MTR_X3A_X20pake2_X3A_X20), - /* K76 */ be_nested_str_weak(encode), - /* K77 */ be_nested_str_weak(MTR_X3A_X20pake2_raw_X3A_X20), - /* K78 */ be_nested_str_weak(build_response), - /* K79 */ be_nested_str_weak(responder), - /* K80 */ be_nested_str_weak(send_response), - /* K81 */ be_nested_str_weak(remote_ip), - /* K82 */ be_nested_str_weak(remote_port), - /* K83 */ be_nested_str_weak(message_counter), + /* K17 */ be_nested_str_weak(MTR_X3A_X20spake_X3A_X20), + /* K18 */ be_nested_str_weak(inspect), + /* K19 */ be_nested_str_weak(spake), + /* K20 */ be_nested_str_weak(SPAKE2P_Matter), + /* K21 */ be_nested_str_weak(device), + /* K22 */ be_nested_str_weak(w0), + /* K23 */ be_nested_str_weak(w1), + /* K24 */ be_nested_str_weak(L), + /* K25 */ be_nested_str_weak(compute_pB), + /* K26 */ be_nested_str_weak(y), + /* K27 */ be_nested_str_weak(pB), + /* K28 */ be_nested_str_weak(MTR_X3A_X20y_X3D), + /* K29 */ be_nested_str_weak(MTR_X3A_X20pb_X3D), + /* K30 */ be_nested_str_weak(compute_ZV_verifier), + /* K31 */ be_nested_str_weak(MTR_X3A_X20Z_X3D), + /* K32 */ be_nested_str_weak(Z), + /* K33 */ be_nested_str_weak(MTR_X3A_X20V_X3D), + /* K34 */ be_nested_str_weak(V), + /* K35 */ be_nested_str_weak(SHA256), + /* K36 */ be_nested_str_weak(update), + /* K37 */ be_nested_str_weak(fromstring), + /* K38 */ be_nested_str_weak(Matter_Context_Prefix), + /* K39 */ be_nested_str_weak(PBKDFParamRequest), + /* K40 */ be_nested_str_weak(PBKDFParamResponse), + /* K41 */ be_nested_str_weak(out), + /* K42 */ be_nested_str_weak(MTR_X3A_X20Context_X3D), + /* K43 */ be_nested_str_weak(set_context), + /* K44 */ be_nested_str_weak(compute_TT_hash), + /* K45 */ be_nested_str_weak(MTR_X3A_X20_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D_X2D), + /* K46 */ be_nested_str_weak(MTR_X3A_X20Context_X20_X3D_X20), + /* K47 */ be_nested_str_weak(Context), + /* K48 */ be_nested_str_weak(MTR_X3A_X20M_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K49 */ be_nested_str_weak(M), + /* K50 */ be_nested_str_weak(MTR_X3A_X20N_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K51 */ be_nested_str_weak(N), + /* K52 */ be_nested_str_weak(MTR_X3A_X20pA_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K53 */ be_nested_str_weak(MTR_X3A_X20pB_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K54 */ be_nested_str_weak(MTR_X3A_X20Z_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K55 */ be_nested_str_weak(MTR_X3A_X20V_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K56 */ be_nested_str_weak(MTR_X3A_X20w0_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K57 */ be_nested_str_weak(MTR_X3A_X20Kmain_X20_X20_X20_X3D), + /* K58 */ be_nested_str_weak(Kmain), + /* K59 */ be_nested_str_weak(MTR_X3A_X20KcA_X20_X20_X20_X20_X20_X3D), + /* K60 */ be_nested_str_weak(KcA), + /* K61 */ be_nested_str_weak(MTR_X3A_X20KcB_X20_X20_X20_X20_X20_X3D), + /* K62 */ be_nested_str_weak(KcB), + /* K63 */ be_nested_str_weak(MTR_X3A_X20K_shared_X3D), + /* K64 */ be_nested_str_weak(K_shared), + /* K65 */ be_nested_str_weak(MTR_X3A_X20Ke_X20_X20_X20_X20_X20_X20_X3D), + /* K66 */ be_nested_str_weak(Ke), + /* K67 */ be_nested_str_weak(cB), + /* K68 */ be_nested_str_weak(MTR_X3A_X20cB_X3D), + /* K69 */ be_nested_str_weak(Pake2), + /* K70 */ be_nested_str_weak(MTR_X3A_X20pake2_X3A_X20), + /* K71 */ be_nested_str_weak(encode), + /* K72 */ be_nested_str_weak(MTR_X3A_X20pake2_raw_X3A_X20), + /* K73 */ be_nested_str_weak(build_response), + /* K74 */ be_nested_str_weak(responder), + /* K75 */ be_nested_str_weak(send_response), + /* K76 */ be_nested_str_weak(remote_ip), + /* K77 */ be_nested_str_weak(remote_port), + /* K78 */ be_nested_str_weak(message_counter), }), be_str_weak(parse_Pake1), &be_const_str_solidified, - ( &(const binstruction[326]) { /* code */ + ( &(const binstruction[308]) { /* code */ 0xA40A0000, // 0000 IMPORT R2 K0 0x880C0301, // 0001 GETMBR R3 R1 K1 0x54120021, // 0002 LDINT R4 34 @@ -342,305 +336,287 @@ be_local_closure(Matter_Commisioning_Context_parse_Pake1, /* name */ 0x8C180D10, // 0018 GETMET R6 R6 K16 0x7C180200, // 0019 CALL R6 1 0x001A1E06, // 001A ADD R6 K15 R6 - 0x581C0011, // 001B LDCONST R7 K17 + 0x541E0003, // 001B LDINT R7 4 0x7C100600, // 001C CALL R4 3 0xB8121A00, // 001D GETNGBL R4 K13 0x8C10090E, // 001E GETMET R4 R4 K14 0xB81A0E00, // 001F GETNGBL R6 K7 - 0x8C180D13, // 0020 GETMET R6 R6 K19 - 0x88200114, // 0021 GETMBR R8 R0 K20 + 0x8C180D12, // 0020 GETMET R6 R6 K18 + 0x88200113, // 0021 GETMBR R8 R0 K19 0x7C180400, // 0022 CALL R6 2 - 0x001A2406, // 0023 ADD R6 K18 R6 - 0x581C0011, // 0024 LDCONST R7 K17 + 0x001A2206, // 0023 ADD R6 K17 R6 + 0x541E0003, // 0024 LDINT R7 4 0x7C100600, // 0025 CALL R4 3 - 0x8C100515, // 0026 GETMET R4 R2 K21 - 0x88180116, // 0027 GETMBR R6 R0 K22 - 0x88180D17, // 0028 GETMBR R6 R6 K23 - 0x881C0116, // 0029 GETMBR R7 R0 K22 - 0x881C0F18, // 002A GETMBR R7 R7 K24 - 0x88200116, // 002B GETMBR R8 R0 K22 - 0x88201119, // 002C GETMBR R8 R8 K25 + 0x8C100514, // 0026 GETMET R4 R2 K20 + 0x88180115, // 0027 GETMBR R6 R0 K21 + 0x88180D16, // 0028 GETMBR R6 R6 K22 + 0x881C0115, // 0029 GETMBR R7 R0 K21 + 0x881C0F17, // 002A GETMBR R7 R7 K23 + 0x88200115, // 002B GETMBR R8 R0 K21 + 0x88201118, // 002C GETMBR R8 R8 K24 0x7C100800, // 002D CALL R4 4 - 0x90022804, // 002E SETMBR R0 K20 R4 - 0x88100114, // 002F GETMBR R4 R0 K20 - 0x8C10091A, // 0030 GETMET R4 R4 K26 - 0x8818011B, // 0031 GETMBR R6 R0 K27 + 0x90022604, // 002E SETMBR R0 K19 R4 + 0x88100113, // 002F GETMBR R4 R0 K19 + 0x8C100919, // 0030 GETMET R4 R4 K25 + 0x8818011A, // 0031 GETMBR R6 R0 K26 0x7C100400, // 0032 CALL R4 2 - 0x88100114, // 0033 GETMBR R4 R0 K20 - 0x8810091C, // 0034 GETMBR R4 R4 K28 - 0x90023804, // 0035 SETMBR R0 K28 R4 + 0x88100113, // 0033 GETMBR R4 R0 K19 + 0x8810091B, // 0034 GETMBR R4 R4 K27 + 0x90023604, // 0035 SETMBR R0 K27 R4 0xB8121A00, // 0036 GETNGBL R4 K13 0x8C10090E, // 0037 GETMET R4 R4 K14 - 0x8818011B, // 0038 GETMBR R6 R0 K27 + 0x8818011A, // 0038 GETMBR R6 R0 K26 0x8C180D10, // 0039 GETMET R6 R6 K16 0x7C180200, // 003A CALL R6 1 - 0x001A3A06, // 003B ADD R6 K29 R6 - 0x581C0011, // 003C LDCONST R7 K17 + 0x001A3806, // 003B ADD R6 K28 R6 + 0x541E0003, // 003C LDINT R7 4 0x7C100600, // 003D CALL R4 3 0xB8121A00, // 003E GETNGBL R4 K13 0x8C10090E, // 003F GETMET R4 R4 K14 - 0x8818011C, // 0040 GETMBR R6 R0 K28 + 0x8818011B, // 0040 GETMBR R6 R0 K27 0x8C180D10, // 0041 GETMET R6 R6 K16 0x7C180200, // 0042 CALL R6 1 - 0x001A3C06, // 0043 ADD R6 K30 R6 - 0x581C0011, // 0044 LDCONST R7 K17 + 0x001A3A06, // 0043 ADD R6 K29 R6 + 0x541E0003, // 0044 LDINT R7 4 0x7C100600, // 0045 CALL R4 3 - 0x88100114, // 0046 GETMBR R4 R0 K20 - 0x8C10091F, // 0047 GETMET R4 R4 K31 + 0x88100113, // 0046 GETMBR R4 R0 K19 + 0x8C10091E, // 0047 GETMET R4 R4 K30 0x8818010C, // 0048 GETMBR R6 R0 K12 0x7C100400, // 0049 CALL R4 2 0xB8121A00, // 004A GETNGBL R4 K13 0x8C10090E, // 004B GETMET R4 R4 K14 - 0x88180114, // 004C GETMBR R6 R0 K20 - 0x88180D21, // 004D GETMBR R6 R6 K33 + 0x88180113, // 004C GETMBR R6 R0 K19 + 0x88180D20, // 004D GETMBR R6 R6 K32 0x8C180D10, // 004E GETMET R6 R6 K16 0x7C180200, // 004F CALL R6 1 - 0x001A4006, // 0050 ADD R6 K32 R6 - 0x581C0011, // 0051 LDCONST R7 K17 + 0x001A3E06, // 0050 ADD R6 K31 R6 + 0x541E0003, // 0051 LDINT R7 4 0x7C100600, // 0052 CALL R4 3 0xB8121A00, // 0053 GETNGBL R4 K13 0x8C10090E, // 0054 GETMET R4 R4 K14 - 0x88180114, // 0055 GETMBR R6 R0 K20 - 0x88180D23, // 0056 GETMBR R6 R6 K35 + 0x88180113, // 0055 GETMBR R6 R0 K19 + 0x88180D22, // 0056 GETMBR R6 R6 K34 0x8C180D10, // 0057 GETMET R6 R6 K16 0x7C180200, // 0058 CALL R6 1 - 0x001A4406, // 0059 ADD R6 K34 R6 - 0x581C0011, // 005A LDCONST R7 K17 + 0x001A4206, // 0059 ADD R6 K33 R6 + 0x541E0003, // 005A LDINT R7 4 0x7C100600, // 005B CALL R4 3 - 0x8C100524, // 005C GETMET R4 R2 K36 + 0x8C100523, // 005C GETMET R4 R2 K35 0x7C100200, // 005D CALL R4 1 - 0x8C140925, // 005E GETMET R5 R4 K37 + 0x8C140924, // 005E GETMET R5 R4 K36 0x601C0015, // 005F GETGBL R7 G21 0x7C1C0000, // 0060 CALL R7 0 - 0x8C1C0F26, // 0061 GETMET R7 R7 K38 - 0x88240127, // 0062 GETMBR R9 R0 K39 + 0x8C1C0F25, // 0061 GETMET R7 R7 K37 + 0x88240126, // 0062 GETMBR R9 R0 K38 0x7C1C0400, // 0063 CALL R7 2 0x7C140400, // 0064 CALL R5 2 - 0x8C140925, // 0065 GETMET R5 R4 K37 - 0x881C0128, // 0066 GETMBR R7 R0 K40 + 0x8C140924, // 0065 GETMET R5 R4 K36 + 0x881C0127, // 0066 GETMBR R7 R0 K39 0x7C140400, // 0067 CALL R5 2 - 0x8C140925, // 0068 GETMET R5 R4 K37 - 0x881C0129, // 0069 GETMBR R7 R0 K41 + 0x8C140924, // 0068 GETMET R5 R4 K36 + 0x881C0128, // 0069 GETMBR R7 R0 K40 0x7C140400, // 006A CALL R5 2 - 0x8C14092A, // 006B GETMET R5 R4 K42 + 0x8C140929, // 006B GETMET R5 R4 K41 0x7C140200, // 006C CALL R5 1 0xB81A1A00, // 006D GETNGBL R6 K13 0x8C180D0E, // 006E GETMET R6 R6 K14 0x8C200B10, // 006F GETMET R8 R5 K16 0x7C200200, // 0070 CALL R8 1 - 0x00225608, // 0071 ADD R8 K43 R8 - 0x58240011, // 0072 LDCONST R9 K17 + 0x00225408, // 0071 ADD R8 K42 R8 + 0x54260003, // 0072 LDINT R9 4 0x7C180600, // 0073 CALL R6 3 - 0x88180114, // 0074 GETMBR R6 R0 K20 + 0x88180113, // 0074 GETMBR R6 R0 K19 0x881C010C, // 0075 GETMBR R7 R0 K12 0x901A1807, // 0076 SETMBR R6 K12 R7 - 0x88180114, // 0077 GETMBR R6 R0 K20 - 0x8C180D2C, // 0078 GETMET R6 R6 K44 + 0x88180113, // 0077 GETMBR R6 R0 K19 + 0x8C180D2B, // 0078 GETMET R6 R6 K43 0x5C200A00, // 0079 MOVE R8 R5 0x7C180400, // 007A CALL R6 2 - 0x88180114, // 007B GETMBR R6 R0 K20 - 0x8C180D2D, // 007C GETMET R6 R6 K45 + 0x88180113, // 007B GETMBR R6 R0 K19 + 0x8C180D2C, // 007C GETMET R6 R6 K44 0x50200200, // 007D LDBOOL R8 1 0 0x7C180400, // 007E CALL R6 2 0xB81A1A00, // 007F GETNGBL R6 K13 0x8C180D0E, // 0080 GETMET R6 R6 K14 - 0x5820002E, // 0081 LDCONST R8 K46 - 0x58240011, // 0082 LDCONST R9 K17 + 0x5820002D, // 0081 LDCONST R8 K45 + 0x54260003, // 0082 LDINT R9 4 0x7C180600, // 0083 CALL R6 3 0xB81A1A00, // 0084 GETNGBL R6 K13 0x8C180D0E, // 0085 GETMET R6 R6 K14 - 0x88200114, // 0086 GETMBR R8 R0 K20 - 0x88201130, // 0087 GETMBR R8 R8 K48 + 0x88200113, // 0086 GETMBR R8 R0 K19 + 0x8820112F, // 0087 GETMBR R8 R8 K47 0x8C201110, // 0088 GETMET R8 R8 K16 0x7C200200, // 0089 CALL R8 1 - 0x00225E08, // 008A ADD R8 K47 R8 - 0x58240011, // 008B LDCONST R9 K17 + 0x00225C08, // 008A ADD R8 K46 R8 + 0x54260003, // 008B LDINT R9 4 0x7C180600, // 008C CALL R6 3 0xB81A1A00, // 008D GETNGBL R6 K13 0x8C180D0E, // 008E GETMET R6 R6 K14 - 0x88200114, // 008F GETMBR R8 R0 K20 - 0x88201132, // 0090 GETMBR R8 R8 K50 + 0x88200113, // 008F GETMBR R8 R0 K19 + 0x88201131, // 0090 GETMBR R8 R8 K49 0x8C201110, // 0091 GETMET R8 R8 K16 0x7C200200, // 0092 CALL R8 1 - 0x00226208, // 0093 ADD R8 K49 R8 - 0x58240011, // 0094 LDCONST R9 K17 + 0x00226008, // 0093 ADD R8 K48 R8 + 0x54260003, // 0094 LDINT R9 4 0x7C180600, // 0095 CALL R6 3 0xB81A1A00, // 0096 GETNGBL R6 K13 0x8C180D0E, // 0097 GETMET R6 R6 K14 - 0x88200114, // 0098 GETMBR R8 R0 K20 - 0x88201134, // 0099 GETMBR R8 R8 K52 + 0x88200113, // 0098 GETMBR R8 R0 K19 + 0x88201133, // 0099 GETMBR R8 R8 K51 0x8C201110, // 009A GETMET R8 R8 K16 0x7C200200, // 009B CALL R8 1 - 0x00226608, // 009C ADD R8 K51 R8 - 0x58240011, // 009D LDCONST R9 K17 + 0x00226408, // 009C ADD R8 K50 R8 + 0x54260003, // 009D LDINT R9 4 0x7C180600, // 009E CALL R6 3 0xB81A1A00, // 009F GETNGBL R6 K13 0x8C180D0E, // 00A0 GETMET R6 R6 K14 - 0x88200114, // 00A1 GETMBR R8 R0 K20 - 0x88201136, // 00A2 GETMBR R8 R8 K54 + 0x88200113, // 00A1 GETMBR R8 R0 K19 + 0x8820110C, // 00A2 GETMBR R8 R8 K12 0x8C201110, // 00A3 GETMET R8 R8 K16 0x7C200200, // 00A4 CALL R8 1 - 0x00226A08, // 00A5 ADD R8 K53 R8 - 0x58240011, // 00A6 LDCONST R9 K17 + 0x00226808, // 00A5 ADD R8 K52 R8 + 0x54260003, // 00A6 LDINT R9 4 0x7C180600, // 00A7 CALL R6 3 0xB81A1A00, // 00A8 GETNGBL R6 K13 0x8C180D0E, // 00A9 GETMET R6 R6 K14 - 0x88200114, // 00AA GETMBR R8 R0 K20 - 0x88201138, // 00AB GETMBR R8 R8 K56 + 0x88200113, // 00AA GETMBR R8 R0 K19 + 0x8820111B, // 00AB GETMBR R8 R8 K27 0x8C201110, // 00AC GETMET R8 R8 K16 0x7C200200, // 00AD CALL R8 1 - 0x00226E08, // 00AE ADD R8 K55 R8 - 0x58240011, // 00AF LDCONST R9 K17 + 0x00226A08, // 00AE ADD R8 K53 R8 + 0x54260003, // 00AF LDINT R9 4 0x7C180600, // 00B0 CALL R6 3 0xB81A1A00, // 00B1 GETNGBL R6 K13 0x8C180D0E, // 00B2 GETMET R6 R6 K14 - 0x88200114, // 00B3 GETMBR R8 R0 K20 - 0x8820110C, // 00B4 GETMBR R8 R8 K12 + 0x88200113, // 00B3 GETMBR R8 R0 K19 + 0x88201120, // 00B4 GETMBR R8 R8 K32 0x8C201110, // 00B5 GETMET R8 R8 K16 0x7C200200, // 00B6 CALL R8 1 - 0x00227208, // 00B7 ADD R8 K57 R8 - 0x58240011, // 00B8 LDCONST R9 K17 + 0x00226C08, // 00B7 ADD R8 K54 R8 + 0x54260003, // 00B8 LDINT R9 4 0x7C180600, // 00B9 CALL R6 3 0xB81A1A00, // 00BA GETNGBL R6 K13 0x8C180D0E, // 00BB GETMET R6 R6 K14 - 0x88200114, // 00BC GETMBR R8 R0 K20 - 0x8820111C, // 00BD GETMBR R8 R8 K28 + 0x88200113, // 00BC GETMBR R8 R0 K19 + 0x88201122, // 00BD GETMBR R8 R8 K34 0x8C201110, // 00BE GETMET R8 R8 K16 0x7C200200, // 00BF CALL R8 1 - 0x00227408, // 00C0 ADD R8 K58 R8 - 0x58240011, // 00C1 LDCONST R9 K17 + 0x00226E08, // 00C0 ADD R8 K55 R8 + 0x54260003, // 00C1 LDINT R9 4 0x7C180600, // 00C2 CALL R6 3 0xB81A1A00, // 00C3 GETNGBL R6 K13 0x8C180D0E, // 00C4 GETMET R6 R6 K14 - 0x88200114, // 00C5 GETMBR R8 R0 K20 - 0x88201121, // 00C6 GETMBR R8 R8 K33 + 0x88200113, // 00C5 GETMBR R8 R0 K19 + 0x88201116, // 00C6 GETMBR R8 R8 K22 0x8C201110, // 00C7 GETMET R8 R8 K16 0x7C200200, // 00C8 CALL R8 1 - 0x00227608, // 00C9 ADD R8 K59 R8 - 0x58240011, // 00CA LDCONST R9 K17 + 0x00227008, // 00C9 ADD R8 K56 R8 + 0x54260003, // 00CA LDINT R9 4 0x7C180600, // 00CB CALL R6 3 0xB81A1A00, // 00CC GETNGBL R6 K13 0x8C180D0E, // 00CD GETMET R6 R6 K14 - 0x88200114, // 00CE GETMBR R8 R0 K20 - 0x88201123, // 00CF GETMBR R8 R8 K35 - 0x8C201110, // 00D0 GETMET R8 R8 K16 - 0x7C200200, // 00D1 CALL R8 1 - 0x00227808, // 00D2 ADD R8 K60 R8 - 0x58240011, // 00D3 LDCONST R9 K17 - 0x7C180600, // 00D4 CALL R6 3 - 0xB81A1A00, // 00D5 GETNGBL R6 K13 - 0x8C180D0E, // 00D6 GETMET R6 R6 K14 - 0x88200114, // 00D7 GETMBR R8 R0 K20 - 0x88201117, // 00D8 GETMBR R8 R8 K23 - 0x8C201110, // 00D9 GETMET R8 R8 K16 - 0x7C200200, // 00DA CALL R8 1 - 0x00227A08, // 00DB ADD R8 K61 R8 - 0x58240011, // 00DC LDCONST R9 K17 - 0x7C180600, // 00DD CALL R6 3 - 0xB81A1A00, // 00DE GETNGBL R6 K13 - 0x8C180D0E, // 00DF GETMET R6 R6 K14 - 0x5820002E, // 00E0 LDCONST R8 K46 - 0x58240011, // 00E1 LDCONST R9 K17 + 0x5820002D, // 00CE LDCONST R8 K45 + 0x54260003, // 00CF LDINT R9 4 + 0x7C180600, // 00D0 CALL R6 3 + 0xB81A1A00, // 00D1 GETNGBL R6 K13 + 0x8C180D0E, // 00D2 GETMET R6 R6 K14 + 0x88200113, // 00D3 GETMBR R8 R0 K19 + 0x8820113A, // 00D4 GETMBR R8 R8 K58 + 0x8C201110, // 00D5 GETMET R8 R8 K16 + 0x7C200200, // 00D6 CALL R8 1 + 0x00227208, // 00D7 ADD R8 K57 R8 + 0x54260003, // 00D8 LDINT R9 4 + 0x7C180600, // 00D9 CALL R6 3 + 0xB81A1A00, // 00DA GETNGBL R6 K13 + 0x8C180D0E, // 00DB GETMET R6 R6 K14 + 0x88200113, // 00DC GETMBR R8 R0 K19 + 0x8820113C, // 00DD GETMBR R8 R8 K60 + 0x8C201110, // 00DE GETMET R8 R8 K16 + 0x7C200200, // 00DF CALL R8 1 + 0x00227608, // 00E0 ADD R8 K59 R8 + 0x54260003, // 00E1 LDINT R9 4 0x7C180600, // 00E2 CALL R6 3 0xB81A1A00, // 00E3 GETNGBL R6 K13 0x8C180D0E, // 00E4 GETMET R6 R6 K14 - 0x88200114, // 00E5 GETMBR R8 R0 K20 - 0x8820113F, // 00E6 GETMBR R8 R8 K63 + 0x88200113, // 00E5 GETMBR R8 R0 K19 + 0x8820113E, // 00E6 GETMBR R8 R8 K62 0x8C201110, // 00E7 GETMET R8 R8 K16 0x7C200200, // 00E8 CALL R8 1 - 0x00227C08, // 00E9 ADD R8 K62 R8 - 0x58240011, // 00EA LDCONST R9 K17 + 0x00227A08, // 00E9 ADD R8 K61 R8 + 0x54260003, // 00EA LDINT R9 4 0x7C180600, // 00EB CALL R6 3 0xB81A1A00, // 00EC GETNGBL R6 K13 0x8C180D0E, // 00ED GETMET R6 R6 K14 - 0x88200114, // 00EE GETMBR R8 R0 K20 - 0x88201141, // 00EF GETMBR R8 R8 K65 + 0x88200113, // 00EE GETMBR R8 R0 K19 + 0x88201140, // 00EF GETMBR R8 R8 K64 0x8C201110, // 00F0 GETMET R8 R8 K16 0x7C200200, // 00F1 CALL R8 1 - 0x00228008, // 00F2 ADD R8 K64 R8 - 0x58240011, // 00F3 LDCONST R9 K17 + 0x00227E08, // 00F2 ADD R8 K63 R8 + 0x54260003, // 00F3 LDINT R9 4 0x7C180600, // 00F4 CALL R6 3 0xB81A1A00, // 00F5 GETNGBL R6 K13 0x8C180D0E, // 00F6 GETMET R6 R6 K14 - 0x88200114, // 00F7 GETMBR R8 R0 K20 - 0x88201143, // 00F8 GETMBR R8 R8 K67 + 0x88200113, // 00F7 GETMBR R8 R0 K19 + 0x88201142, // 00F8 GETMBR R8 R8 K66 0x8C201110, // 00F9 GETMET R8 R8 K16 0x7C200200, // 00FA CALL R8 1 - 0x00228408, // 00FB ADD R8 K66 R8 - 0x58240011, // 00FC LDCONST R9 K17 + 0x00228208, // 00FB ADD R8 K65 R8 + 0x54260003, // 00FC LDINT R9 4 0x7C180600, // 00FD CALL R6 3 - 0xB81A1A00, // 00FE GETNGBL R6 K13 - 0x8C180D0E, // 00FF GETMET R6 R6 K14 - 0x88200114, // 0100 GETMBR R8 R0 K20 - 0x88201145, // 0101 GETMBR R8 R8 K69 - 0x8C201110, // 0102 GETMET R8 R8 K16 - 0x7C200200, // 0103 CALL R8 1 - 0x00228808, // 0104 ADD R8 K68 R8 - 0x58240011, // 0105 LDCONST R9 K17 - 0x7C180600, // 0106 CALL R6 3 - 0xB81A1A00, // 0107 GETNGBL R6 K13 - 0x8C180D0E, // 0108 GETMET R6 R6 K14 - 0x88200114, // 0109 GETMBR R8 R0 K20 - 0x88201147, // 010A GETMBR R8 R8 K71 - 0x8C201110, // 010B GETMET R8 R8 K16 - 0x7C200200, // 010C CALL R8 1 - 0x00228C08, // 010D ADD R8 K70 R8 - 0x58240011, // 010E LDCONST R9 K17 - 0x7C180600, // 010F CALL R6 3 - 0x88180114, // 0110 GETMBR R6 R0 K20 - 0x88180D48, // 0111 GETMBR R6 R6 K72 - 0x90029006, // 0112 SETMBR R0 K72 R6 - 0x88180114, // 0113 GETMBR R6 R0 K20 - 0x88180D47, // 0114 GETMBR R6 R6 K71 - 0x90028E06, // 0115 SETMBR R0 K71 R6 - 0xB81A1A00, // 0116 GETNGBL R6 K13 - 0x8C180D0E, // 0117 GETMET R6 R6 K14 - 0x88200148, // 0118 GETMBR R8 R0 K72 - 0x8C201110, // 0119 GETMET R8 R8 K16 - 0x7C200200, // 011A CALL R8 1 - 0x00229208, // 011B ADD R8 K73 R8 - 0x58240011, // 011C LDCONST R9 K17 - 0x7C180600, // 011D CALL R6 3 - 0xB81A0E00, // 011E GETNGBL R6 K7 - 0x8C180D4A, // 011F GETMET R6 R6 K74 - 0x7C180200, // 0120 CALL R6 1 - 0x881C011C, // 0121 GETMBR R7 R0 K28 - 0x901A3807, // 0122 SETMBR R6 K28 R7 - 0x881C0148, // 0123 GETMBR R7 R0 K72 - 0x901A9007, // 0124 SETMBR R6 K72 R7 - 0xB81E1A00, // 0125 GETNGBL R7 K13 - 0x8C1C0F0E, // 0126 GETMET R7 R7 K14 - 0xB8260E00, // 0127 GETNGBL R9 K7 - 0x8C241313, // 0128 GETMET R9 R9 K19 - 0x5C2C0C00, // 0129 MOVE R11 R6 - 0x7C240400, // 012A CALL R9 2 - 0x00269609, // 012B ADD R9 K75 R9 - 0x58280011, // 012C LDCONST R10 K17 - 0x7C1C0600, // 012D CALL R7 3 - 0x8C1C0D4C, // 012E GETMET R7 R6 K76 - 0x7C1C0200, // 012F CALL R7 1 - 0xB8221A00, // 0130 GETNGBL R8 K13 - 0x8C20110E, // 0131 GETMET R8 R8 K14 - 0x8C280F10, // 0132 GETMET R10 R7 K16 - 0x7C280200, // 0133 CALL R10 1 - 0x002A9A0A, // 0134 ADD R10 K77 R10 - 0x582C0011, // 0135 LDCONST R11 K17 - 0x7C200600, // 0136 CALL R8 3 - 0x8C20034E, // 0137 GETMET R8 R1 K78 - 0x542A0022, // 0138 LDINT R10 35 - 0x502C0200, // 0139 LDBOOL R11 1 0 - 0x7C200600, // 013A CALL R8 3 - 0x8C24114C, // 013B GETMET R9 R8 K76 - 0x5C2C0E00, // 013C MOVE R11 R7 - 0x7C240400, // 013D CALL R9 2 - 0x8828014F, // 013E GETMBR R10 R0 K79 - 0x8C281550, // 013F GETMET R10 R10 K80 - 0x5C301200, // 0140 MOVE R12 R9 - 0x88340351, // 0141 GETMBR R13 R1 K81 - 0x88380352, // 0142 GETMBR R14 R1 K82 - 0x883C1153, // 0143 GETMBR R15 R8 K83 - 0x7C280A00, // 0144 CALL R10 5 - 0x80000000, // 0145 RET 0 + 0x88180113, // 00FE GETMBR R6 R0 K19 + 0x88180D43, // 00FF GETMBR R6 R6 K67 + 0x90028606, // 0100 SETMBR R0 K67 R6 + 0x88180113, // 0101 GETMBR R6 R0 K19 + 0x88180D42, // 0102 GETMBR R6 R6 K66 + 0x90028406, // 0103 SETMBR R0 K66 R6 + 0xB81A1A00, // 0104 GETNGBL R6 K13 + 0x8C180D0E, // 0105 GETMET R6 R6 K14 + 0x88200143, // 0106 GETMBR R8 R0 K67 + 0x8C201110, // 0107 GETMET R8 R8 K16 + 0x7C200200, // 0108 CALL R8 1 + 0x00228808, // 0109 ADD R8 K68 R8 + 0x54260003, // 010A LDINT R9 4 + 0x7C180600, // 010B CALL R6 3 + 0xB81A0E00, // 010C GETNGBL R6 K7 + 0x8C180D45, // 010D GETMET R6 R6 K69 + 0x7C180200, // 010E CALL R6 1 + 0x881C011B, // 010F GETMBR R7 R0 K27 + 0x901A3607, // 0110 SETMBR R6 K27 R7 + 0x881C0143, // 0111 GETMBR R7 R0 K67 + 0x901A8607, // 0112 SETMBR R6 K67 R7 + 0xB81E1A00, // 0113 GETNGBL R7 K13 + 0x8C1C0F0E, // 0114 GETMET R7 R7 K14 + 0xB8260E00, // 0115 GETNGBL R9 K7 + 0x8C241312, // 0116 GETMET R9 R9 K18 + 0x5C2C0C00, // 0117 MOVE R11 R6 + 0x7C240400, // 0118 CALL R9 2 + 0x00268C09, // 0119 ADD R9 K70 R9 + 0x542A0003, // 011A LDINT R10 4 + 0x7C1C0600, // 011B CALL R7 3 + 0x8C1C0D47, // 011C GETMET R7 R6 K71 + 0x7C1C0200, // 011D CALL R7 1 + 0xB8221A00, // 011E GETNGBL R8 K13 + 0x8C20110E, // 011F GETMET R8 R8 K14 + 0x8C280F10, // 0120 GETMET R10 R7 K16 + 0x7C280200, // 0121 CALL R10 1 + 0x002A900A, // 0122 ADD R10 K72 R10 + 0x542E0003, // 0123 LDINT R11 4 + 0x7C200600, // 0124 CALL R8 3 + 0x8C200349, // 0125 GETMET R8 R1 K73 + 0x542A0022, // 0126 LDINT R10 35 + 0x502C0200, // 0127 LDBOOL R11 1 0 + 0x7C200600, // 0128 CALL R8 3 + 0x8C241147, // 0129 GETMET R9 R8 K71 + 0x5C2C0E00, // 012A MOVE R11 R7 + 0x7C240400, // 012B CALL R9 2 + 0x8828014A, // 012C GETMBR R10 R0 K74 + 0x8C28154B, // 012D GETMET R10 R10 K75 + 0x5C301200, // 012E MOVE R12 R9 + 0x8834034C, // 012F GETMBR R13 R1 K76 + 0x8838034D, // 0130 GETMBR R14 R1 K77 + 0x883C114E, // 0131 GETMBR R15 R8 K78 + 0x7C280A00, // 0132 CALL R10 5 + 0x80000000, // 0133 RET 0 }) ) ); @@ -739,7 +715,7 @@ be_local_closure(Matter_Commisioning_Context_find_session_by_destination_id, / 0x8C280F04, // 0031 GETMET R10 R7 K4 0x7C280200, // 0032 CALL R10 1 0x002A200A, // 0033 ADD R10 K16 R10 - 0x582C0005, // 0034 LDCONST R11 K5 + 0x542E0003, // 0034 LDINT R11 4 0x7C200600, // 0035 CALL R8 3 0x8C200711, // 0036 GETMET R8 R3 K17 0x5C280E00, // 0037 MOVE R10 R7 @@ -826,43 +802,43 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ /* K13 */ be_nested_str_weak(tasmota), /* K14 */ be_nested_str_weak(log), /* K15 */ be_nested_str_weak(_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), - /* K16 */ be_const_int(3), - /* K17 */ be_nested_str_weak(SHA256), - /* K18 */ be_nested_str_weak(update), - /* K19 */ be_nested_str_weak(_Msg1), - /* K20 */ be_nested_str_weak(_Msg2), - /* K21 */ be_nested_str_weak(out), - /* K22 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20session_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K23 */ be_nested_str_weak(MTR_X3A_X20session_X2Eipk_epoch_key_X20), - /* K24 */ be_nested_str_weak(ipk_epoch_key), - /* K25 */ be_nested_str_weak(MTR_X3A_X20session_X2Efabric_compressed_X20), - /* K26 */ be_nested_str_weak(fabric_compressed), - /* K27 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20ipk_group_key_X20_X3D_X20), - /* K28 */ be_nested_str_weak(get_ipk_group_key), - /* K29 */ be_nested_str_weak(tohex), - /* K30 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TranscriptHash_X3D_X20), - /* K31 */ be_nested_str_weak(fromstring), - /* K32 */ be_nested_str_weak(S3K_Info), - /* K33 */ be_nested_str_weak(HKDF_SHA256), - /* K34 */ be_nested_str_weak(derive), - /* K35 */ be_nested_str_weak(shared_secret), - /* K36 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s3k_salt_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K37 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s3k_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K38 */ be_nested_str_weak(TBEData3Encrypted), - /* K39 */ be_const_int(2147483647), - /* K40 */ be_nested_str_weak(AES_CCM), - /* K41 */ be_nested_str_weak(TBEData3_Nonce), - /* K42 */ be_nested_str_weak(decrypt), - /* K43 */ be_nested_str_weak(tag), - /* K44 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TBEData3_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K45 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TBETag3_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K46 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20tag_sent_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K47 */ be_nested_str_weak(value_error), - /* K48 */ be_nested_str_weak(tag_X20do_X20not_X20match), - /* K49 */ be_nested_str_weak(TLV), - /* K50 */ be_nested_str_weak(findsubval), - /* K51 */ be_const_int(1), - /* K52 */ be_const_int(2), + /* K16 */ be_nested_str_weak(SHA256), + /* K17 */ be_nested_str_weak(update), + /* K18 */ be_nested_str_weak(_Msg1), + /* K19 */ be_nested_str_weak(_Msg2), + /* K20 */ be_nested_str_weak(out), + /* K21 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20session_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K22 */ be_nested_str_weak(MTR_X3A_X20session_X2Eipk_epoch_key_X20), + /* K23 */ be_nested_str_weak(ipk_epoch_key), + /* K24 */ be_nested_str_weak(MTR_X3A_X20session_X2Efabric_compressed_X20), + /* K25 */ be_nested_str_weak(fabric_compressed), + /* K26 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20ipk_group_key_X20_X3D_X20), + /* K27 */ be_nested_str_weak(get_ipk_group_key), + /* K28 */ be_nested_str_weak(tohex), + /* K29 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TranscriptHash_X3D_X20), + /* K30 */ be_nested_str_weak(fromstring), + /* K31 */ be_nested_str_weak(S3K_Info), + /* K32 */ be_nested_str_weak(HKDF_SHA256), + /* K33 */ be_nested_str_weak(derive), + /* K34 */ be_nested_str_weak(shared_secret), + /* K35 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s3k_salt_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K36 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s3k_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K37 */ be_nested_str_weak(TBEData3Encrypted), + /* K38 */ be_const_int(2147483647), + /* K39 */ be_nested_str_weak(AES_CCM), + /* K40 */ be_nested_str_weak(TBEData3_Nonce), + /* K41 */ be_nested_str_weak(decrypt), + /* K42 */ be_nested_str_weak(tag), + /* K43 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TBEData3_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K44 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TBETag3_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K45 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20tag_sent_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K46 */ be_nested_str_weak(value_error), + /* K47 */ be_nested_str_weak(tag_X20do_X20not_X20match), + /* K48 */ be_nested_str_weak(TLV), + /* K49 */ be_nested_str_weak(findsubval), + /* K50 */ be_const_int(1), + /* K51 */ be_const_int(2), + /* K52 */ be_const_int(3), /* K53 */ be_nested_str_weak(MTR_X3A_X20initiatorNOCTLV_X20_X3D_X20), /* K54 */ be_nested_str_weak(findsub), /* K55 */ be_nested_str_weak(int), @@ -931,68 +907,68 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0xB8161A00, // 0014 GETNGBL R5 K13 0x8C140B0E, // 0015 GETMET R5 R5 K14 0x581C000F, // 0016 LDCONST R7 K15 - 0x58200010, // 0017 LDCONST R8 K16 + 0x54220003, // 0017 LDINT R8 4 0x7C140600, // 0018 CALL R5 3 - 0x8C140511, // 0019 GETMET R5 R2 K17 + 0x8C140510, // 0019 GETMET R5 R2 K16 0x7C140200, // 001A CALL R5 1 - 0x8C140B12, // 001B GETMET R5 R5 K18 - 0x881C0713, // 001C GETMBR R7 R3 K19 + 0x8C140B11, // 001B GETMET R5 R5 K17 + 0x881C0712, // 001C GETMBR R7 R3 K18 0x7C140400, // 001D CALL R5 2 - 0x8C140B12, // 001E GETMET R5 R5 K18 - 0x881C0714, // 001F GETMBR R7 R3 K20 + 0x8C140B11, // 001E GETMET R5 R5 K17 + 0x881C0713, // 001F GETMBR R7 R3 K19 0x7C140400, // 0020 CALL R5 2 - 0x8C140B15, // 0021 GETMET R5 R5 K21 + 0x8C140B14, // 0021 GETMET R5 R5 K20 0x7C140200, // 0022 CALL R5 1 0xB81A1A00, // 0023 GETNGBL R6 K13 0x8C180D0E, // 0024 GETMET R6 R6 K14 0x60200008, // 0025 GETGBL R8 G8 0x5C240600, // 0026 MOVE R9 R3 0x7C200200, // 0027 CALL R8 1 - 0x00222C08, // 0028 ADD R8 K22 R8 - 0x58240010, // 0029 LDCONST R9 K16 + 0x00222A08, // 0028 ADD R8 K21 R8 + 0x54260003, // 0029 LDINT R9 4 0x7C180600, // 002A CALL R6 3 0xB81A1A00, // 002B GETNGBL R6 K13 0x8C180D0E, // 002C GETMET R6 R6 K14 0x60200008, // 002D GETGBL R8 G8 - 0x88240718, // 002E GETMBR R9 R3 K24 + 0x88240717, // 002E GETMBR R9 R3 K23 0x7C200200, // 002F CALL R8 1 - 0x00222E08, // 0030 ADD R8 K23 R8 - 0x58240010, // 0031 LDCONST R9 K16 + 0x00222C08, // 0030 ADD R8 K22 R8 + 0x54260003, // 0031 LDINT R9 4 0x7C180600, // 0032 CALL R6 3 0xB81A1A00, // 0033 GETNGBL R6 K13 0x8C180D0E, // 0034 GETMET R6 R6 K14 0x60200008, // 0035 GETGBL R8 G8 - 0x8824071A, // 0036 GETMBR R9 R3 K26 + 0x88240719, // 0036 GETMBR R9 R3 K25 0x7C200200, // 0037 CALL R8 1 - 0x00223208, // 0038 ADD R8 K25 R8 - 0x58240010, // 0039 LDCONST R9 K16 + 0x00223008, // 0038 ADD R8 K24 R8 + 0x54260003, // 0039 LDINT R9 4 0x7C180600, // 003A CALL R6 3 0xB81A1A00, // 003B GETNGBL R6 K13 0x8C180D0E, // 003C GETMET R6 R6 K14 - 0x8C20071C, // 003D GETMET R8 R3 K28 + 0x8C20071B, // 003D GETMET R8 R3 K27 0x7C200200, // 003E CALL R8 1 - 0x8C20111D, // 003F GETMET R8 R8 K29 + 0x8C20111C, // 003F GETMET R8 R8 K28 0x7C200200, // 0040 CALL R8 1 - 0x00223608, // 0041 ADD R8 K27 R8 - 0x58240010, // 0042 LDCONST R9 K16 + 0x00223408, // 0041 ADD R8 K26 R8 + 0x54260003, // 0042 LDINT R9 4 0x7C180600, // 0043 CALL R6 3 0xB81A1A00, // 0044 GETNGBL R6 K13 0x8C180D0E, // 0045 GETMET R6 R6 K14 - 0x8C200B1D, // 0046 GETMET R8 R5 K29 + 0x8C200B1C, // 0046 GETMET R8 R5 K28 0x7C200200, // 0047 CALL R8 1 - 0x00223C08, // 0048 ADD R8 K30 R8 - 0x58240010, // 0049 LDCONST R9 K16 + 0x00223A08, // 0048 ADD R8 K29 R8 + 0x54260003, // 0049 LDINT R9 4 0x7C180600, // 004A CALL R6 3 0x60180015, // 004B GETGBL R6 G21 0x7C180000, // 004C CALL R6 0 - 0x8C180D1F, // 004D GETMET R6 R6 K31 - 0x88200120, // 004E GETMBR R8 R0 K32 + 0x8C180D1E, // 004D GETMET R6 R6 K30 + 0x8820011F, // 004E GETMBR R8 R0 K31 0x7C180400, // 004F CALL R6 2 - 0x8C1C0521, // 0050 GETMET R7 R2 K33 + 0x8C1C0520, // 0050 GETMET R7 R2 K32 0x7C1C0200, // 0051 CALL R7 1 - 0x8C1C0F22, // 0052 GETMET R7 R7 K34 - 0x88240723, // 0053 GETMBR R9 R3 K35 - 0x8C28071C, // 0054 GETMET R10 R3 K28 + 0x8C1C0F21, // 0052 GETMET R7 R7 K33 + 0x88240722, // 0053 GETMBR R9 R3 K34 + 0x8C28071B, // 0054 GETMET R10 R3 K27 0x7C280200, // 0055 CALL R10 1 0x00281405, // 0056 ADD R10 R10 R5 0x5C2C0C00, // 0057 MOVE R11 R6 @@ -1001,44 +977,44 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0xB8221A00, // 005A GETNGBL R8 K13 0x8C20110E, // 005B GETMET R8 R8 K14 0x5828000F, // 005C LDCONST R10 K15 - 0x582C0010, // 005D LDCONST R11 K16 + 0x542E0003, // 005D LDINT R11 4 0x7C200600, // 005E CALL R8 3 0xB8221A00, // 005F GETNGBL R8 K13 0x8C20110E, // 0060 GETMET R8 R8 K14 - 0x8C28071C, // 0061 GETMET R10 R3 K28 + 0x8C28071B, // 0061 GETMET R10 R3 K27 0x7C280200, // 0062 CALL R10 1 0x00281405, // 0063 ADD R10 R10 R5 - 0x8C28151D, // 0064 GETMET R10 R10 K29 + 0x8C28151C, // 0064 GETMET R10 R10 K28 0x7C280200, // 0065 CALL R10 1 - 0x002A480A, // 0066 ADD R10 K36 R10 - 0x582C0010, // 0067 LDCONST R11 K16 + 0x002A460A, // 0066 ADD R10 K35 R10 + 0x542E0003, // 0067 LDINT R11 4 0x7C200600, // 0068 CALL R8 3 0xB8221A00, // 0069 GETNGBL R8 K13 0x8C20110E, // 006A GETMET R8 R8 K14 - 0x8C280F1D, // 006B GETMET R10 R7 K29 + 0x8C280F1C, // 006B GETMET R10 R7 K28 0x7C280200, // 006C CALL R10 1 - 0x002A4A0A, // 006D ADD R10 K37 R10 - 0x582C0010, // 006E LDCONST R11 K16 + 0x002A480A, // 006D ADD R10 K36 R10 + 0x542E0003, // 006E LDINT R11 4 0x7C200600, // 006F CALL R8 3 0xB8221A00, // 0070 GETNGBL R8 K13 0x8C20110E, // 0071 GETMET R8 R8 K14 0x5828000F, // 0072 LDCONST R10 K15 - 0x582C0010, // 0073 LDCONST R11 K16 + 0x542E0003, // 0073 LDINT R11 4 0x7C200600, // 0074 CALL R8 3 0x5421FFEE, // 0075 LDINT R8 -17 0x40220608, // 0076 CONNECT R8 K3 R8 - 0x88240926, // 0077 GETMBR R9 R4 K38 + 0x88240925, // 0077 GETMBR R9 R4 K37 0x94201208, // 0078 GETIDX R8 R9 R8 0x5429FFEF, // 0079 LDINT R10 -16 - 0x40281527, // 007A CONNECT R10 R10 K39 - 0x882C0926, // 007B GETMBR R11 R4 K38 + 0x40281526, // 007A CONNECT R10 R10 K38 + 0x882C0925, // 007B GETMBR R11 R4 K37 0x9424160A, // 007C GETIDX R9 R11 R10 - 0x8C300528, // 007D GETMET R12 R2 K40 + 0x8C300527, // 007D GETMET R12 R2 K39 0x5C380E00, // 007E MOVE R14 R7 0x603C0015, // 007F GETGBL R15 G21 0x7C3C0000, // 0080 CALL R15 0 - 0x8C3C1F1F, // 0081 GETMET R15 R15 K31 - 0x88440129, // 0082 GETMBR R17 R0 K41 + 0x8C3C1F1E, // 0081 GETMET R15 R15 K30 + 0x88440128, // 0082 GETMBR R17 R0 K40 0x7C3C0400, // 0083 CALL R15 2 0x60400015, // 0084 GETGBL R16 G21 0x7C400000, // 0085 CALL R16 0 @@ -1048,57 +1024,57 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0x544A000F, // 0089 LDINT R18 16 0x7C300C00, // 008A CALL R12 6 0x5C281800, // 008B MOVE R10 R12 - 0x8C30152A, // 008C GETMET R12 R10 K42 + 0x8C301529, // 008C GETMET R12 R10 K41 0x5C381000, // 008D MOVE R14 R8 0x7C300400, // 008E CALL R12 2 0x5C2C1800, // 008F MOVE R11 R12 - 0x8C30152B, // 0090 GETMET R12 R10 K43 + 0x8C30152A, // 0090 GETMET R12 R10 K42 0x7C300200, // 0091 CALL R12 1 0xB8361A00, // 0092 GETNGBL R13 K13 0x8C341B0E, // 0093 GETMET R13 R13 K14 - 0x8C3C171D, // 0094 GETMET R15 R11 K29 + 0x8C3C171C, // 0094 GETMET R15 R11 K28 0x7C3C0200, // 0095 CALL R15 1 - 0x003E580F, // 0096 ADD R15 K44 R15 - 0x58400010, // 0097 LDCONST R16 K16 + 0x003E560F, // 0096 ADD R15 K43 R15 + 0x54420003, // 0097 LDINT R16 4 0x7C340600, // 0098 CALL R13 3 0xB8361A00, // 0099 GETNGBL R13 K13 0x8C341B0E, // 009A GETMET R13 R13 K14 - 0x8C3C191D, // 009B GETMET R15 R12 K29 + 0x8C3C191C, // 009B GETMET R15 R12 K28 0x7C3C0200, // 009C CALL R15 1 - 0x003E5A0F, // 009D ADD R15 K45 R15 - 0x58400010, // 009E LDCONST R16 K16 + 0x003E580F, // 009D ADD R15 K44 R15 + 0x54420003, // 009E LDINT R16 4 0x7C340600, // 009F CALL R13 3 0xB8361A00, // 00A0 GETNGBL R13 K13 0x8C341B0E, // 00A1 GETMET R13 R13 K14 - 0x8C3C131D, // 00A2 GETMET R15 R9 K29 + 0x8C3C131C, // 00A2 GETMET R15 R9 K28 0x7C3C0200, // 00A3 CALL R15 1 - 0x003E5C0F, // 00A4 ADD R15 K46 R15 - 0x58400010, // 00A5 LDCONST R16 K16 + 0x003E5A0F, // 00A4 ADD R15 K45 R15 + 0x54420003, // 00A5 LDINT R16 4 0x7C340600, // 00A6 CALL R13 3 0xB8361A00, // 00A7 GETNGBL R13 K13 0x8C341B0E, // 00A8 GETMET R13 R13 K14 0x583C000F, // 00A9 LDCONST R15 K15 - 0x58400010, // 00AA LDCONST R16 K16 + 0x54420003, // 00AA LDINT R16 4 0x7C340600, // 00AB CALL R13 3 0x20341809, // 00AC NE R13 R12 R9 0x78360000, // 00AD JMPF R13 #00AF - 0xB0065F30, // 00AE RAISE 1 K47 K48 + 0xB0065D2F, // 00AE RAISE 1 K46 K47 0xB8361000, // 00AF GETNGBL R13 K8 - 0x88341B31, // 00B0 GETMBR R13 R13 K49 + 0x88341B30, // 00B0 GETMBR R13 R13 K48 0x8C341B0A, // 00B1 GETMET R13 R13 K10 0x5C3C1600, // 00B2 MOVE R15 R11 0x7C340400, // 00B3 CALL R13 2 - 0x8C381B32, // 00B4 GETMET R14 R13 K50 - 0x58400033, // 00B5 LDCONST R16 K51 + 0x8C381B31, // 00B4 GETMET R14 R13 K49 + 0x58400032, // 00B5 LDCONST R16 K50 0x7C380400, // 00B6 CALL R14 2 - 0x8C3C1B32, // 00B7 GETMET R15 R13 K50 - 0x58440034, // 00B8 LDCONST R17 K52 + 0x8C3C1B31, // 00B7 GETMET R15 R13 K49 + 0x58440033, // 00B8 LDCONST R17 K51 0x7C3C0400, // 00B9 CALL R15 2 - 0x8C401B32, // 00BA GETMET R16 R13 K50 - 0x58480010, // 00BB LDCONST R18 K16 + 0x8C401B31, // 00BA GETMET R16 R13 K49 + 0x58480034, // 00BB LDCONST R18 K52 0x7C400400, // 00BC CALL R16 2 0xB8461000, // 00BD GETNGBL R17 K8 - 0x88442331, // 00BE GETMBR R17 R17 K49 + 0x88442330, // 00BE GETMBR R17 R17 K48 0x8C44230A, // 00BF GETMET R17 R17 K10 0x5C4C1C00, // 00C0 MOVE R19 R14 0x7C440400, // 00C1 CALL R17 2 @@ -1108,15 +1084,15 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0x5C542200, // 00C5 MOVE R21 R17 0x7C500200, // 00C6 CALL R20 1 0x00526A14, // 00C7 ADD R20 K53 R20 - 0x58540010, // 00C8 LDCONST R21 K16 + 0x58540034, // 00C8 LDCONST R21 K52 0x7C480600, // 00C9 CALL R18 3 - 0x8C482332, // 00CA GETMET R18 R17 K50 + 0x8C482331, // 00CA GETMET R18 R17 K49 0x54520008, // 00CB LDINT R20 9 0x7C480400, // 00CC CALL R18 2 0x8C4C2336, // 00CD GETMET R19 R17 K54 0x54560005, // 00CE LDINT R21 6 0x7C4C0400, // 00CF CALL R19 2 - 0x8C502732, // 00D0 GETMET R20 R19 K50 + 0x8C502731, // 00D0 GETMET R20 R19 K49 0x545A0010, // 00D1 LDINT R22 17 0x7C500400, // 00D2 CALL R20 2 0x60540004, // 00D3 GETGBL R21 G4 @@ -1137,37 +1113,37 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0x88600739, // 00E2 GETMBR R24 R3 K57 0x7C5C0200, // 00E3 CALL R23 1 0x005E7617, // 00E4 ADD R23 K59 R23 - 0x58600010, // 00E5 LDCONST R24 K16 + 0x58600034, // 00E5 LDCONST R24 K52 0x7C540600, // 00E6 CALL R21 3 0xB8561000, // 00E7 GETNGBL R21 K8 - 0x88542B31, // 00E8 GETMBR R21 R21 K49 + 0x88542B30, // 00E8 GETMBR R21 R21 K48 0x8C542B3C, // 00E9 GETMET R21 R21 K60 0x7C540200, // 00EA CALL R21 1 0x8C582B3D, // 00EB GETMET R22 R21 K61 - 0x58600033, // 00EC LDCONST R24 K51 + 0x58600032, // 00EC LDCONST R24 K50 0xB8661000, // 00ED GETNGBL R25 K8 - 0x88643331, // 00EE GETMBR R25 R25 K49 + 0x88643330, // 00EE GETMBR R25 R25 K48 0x8864333E, // 00EF GETMBR R25 R25 K62 0x5C681C00, // 00F0 MOVE R26 R14 0x7C580800, // 00F1 CALL R22 4 0x8C582B3D, // 00F2 GETMET R22 R21 K61 - 0x58600034, // 00F3 LDCONST R24 K52 + 0x58600033, // 00F3 LDCONST R24 K51 0xB8661000, // 00F4 GETNGBL R25 K8 - 0x88643331, // 00F5 GETMBR R25 R25 K49 + 0x88643330, // 00F5 GETMBR R25 R25 K48 0x8864333E, // 00F6 GETMBR R25 R25 K62 0x5C681E00, // 00F7 MOVE R26 R15 0x7C580800, // 00F8 CALL R22 4 0x8C582B3D, // 00F9 GETMET R22 R21 K61 - 0x58600010, // 00FA LDCONST R24 K16 + 0x58600034, // 00FA LDCONST R24 K52 0xB8661000, // 00FB GETNGBL R25 K8 - 0x88643331, // 00FC GETMBR R25 R25 K49 + 0x88643330, // 00FC GETMBR R25 R25 K48 0x8864333E, // 00FD GETMBR R25 R25 K62 0x8868013F, // 00FE GETMBR R26 R0 K63 0x7C580800, // 00FF CALL R22 4 0x8C582B3D, // 0100 GETMET R22 R21 K61 0x54620003, // 0101 LDINT R24 4 0xB8661000, // 0102 GETNGBL R25 K8 - 0x88643331, // 0103 GETMBR R25 R25 K49 + 0x88643330, // 0103 GETMBR R25 R25 K48 0x8864333E, // 0104 GETMBR R25 R25 K62 0x88680140, // 0105 GETMBR R26 R0 K64 0x7C580800, // 0106 CALL R22 4 @@ -1175,22 +1151,22 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0x7C580200, // 0108 CALL R22 1 0xB85E1A00, // 0109 GETNGBL R23 K13 0x8C5C2F0E, // 010A GETMET R23 R23 K14 - 0x8C64251D, // 010B GETMET R25 R18 K29 + 0x8C64251C, // 010B GETMET R25 R18 K28 0x7C640200, // 010C CALL R25 1 0x00668419, // 010D ADD R25 K66 R25 - 0x58680010, // 010E LDCONST R26 K16 + 0x546A0003, // 010E LDINT R26 4 0x7C5C0600, // 010F CALL R23 3 0xB85E1A00, // 0110 GETNGBL R23 K13 0x8C5C2F0E, // 0111 GETMET R23 R23 K14 - 0x8C64211D, // 0112 GETMET R25 R16 K29 + 0x8C64211C, // 0112 GETMET R25 R16 K28 0x7C640200, // 0113 CALL R25 1 0x00668619, // 0114 ADD R25 K67 R25 - 0x58680010, // 0115 LDCONST R26 K16 + 0x546A0003, // 0115 LDINT R26 4 0x7C5C0600, // 0116 CALL R23 3 0xB85E1A00, // 0117 GETNGBL R23 K13 0x8C5C2F0E, // 0118 GETMET R23 R23 K14 0x5864000F, // 0119 LDCONST R25 K15 - 0x58680010, // 011A LDCONST R26 K16 + 0x546A0003, // 011A LDINT R26 4 0x7C5C0600, // 011B CALL R23 3 0x8C5C0544, // 011C GETMET R23 R2 K68 0x7C5C0200, // 011D CALL R23 1 @@ -1201,63 +1177,63 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0x7C5C0800, // 0122 CALL R23 4 0x5C602E00, // 0123 MOVE R24 R23 0x74620000, // 0124 JMPT R24 #0126 - 0xB0065F46, // 0125 RAISE 1 K47 K70 + 0xB0065D46, // 0125 RAISE 1 K46 K70 0xB8621A00, // 0126 GETNGBL R24 K13 0x8C60310E, // 0127 GETMET R24 R24 K14 0x58680047, // 0128 LDCONST R26 K71 - 0x586C0010, // 0129 LDCONST R27 K16 + 0x586C0034, // 0129 LDCONST R27 K52 0x7C600600, // 012A CALL R24 3 - 0x8C600511, // 012B GETMET R24 R2 K17 + 0x8C600510, // 012B GETMET R24 R2 K16 0x7C600200, // 012C CALL R24 1 - 0x8C603112, // 012D GETMET R24 R24 K18 - 0x88680713, // 012E GETMBR R26 R3 K19 + 0x8C603111, // 012D GETMET R24 R24 K17 + 0x88680712, // 012E GETMBR R26 R3 K18 0x7C600400, // 012F CALL R24 2 - 0x8C603112, // 0130 GETMET R24 R24 K18 - 0x88680714, // 0131 GETMBR R26 R3 K20 + 0x8C603111, // 0130 GETMET R24 R24 K17 + 0x88680713, // 0131 GETMBR R26 R3 K19 0x7C600400, // 0132 CALL R24 2 - 0x8C603112, // 0133 GETMET R24 R24 K18 + 0x8C603111, // 0133 GETMET R24 R24 K17 0x88680948, // 0134 GETMBR R26 R4 K72 0x7C600400, // 0135 CALL R24 2 - 0x8C603115, // 0136 GETMET R24 R24 K21 + 0x8C603114, // 0136 GETMET R24 R24 K20 0x7C600200, // 0137 CALL R24 1 0x5C143000, // 0138 MOVE R5 R24 0x4C600000, // 0139 LDNIL R24 - 0x900E2618, // 013A SETMBR R3 K19 R24 + 0x900E2418, // 013A SETMBR R3 K18 R24 0x4C600000, // 013B LDNIL R24 - 0x900E2818, // 013C SETMBR R3 K20 R24 + 0x900E2618, // 013C SETMBR R3 K19 R24 0xB8621A00, // 013D GETNGBL R24 K13 0x8C60310E, // 013E GETMET R24 R24 K14 0x58680049, // 013F LDCONST R26 K73 - 0x586C0010, // 0140 LDCONST R27 K16 + 0x546E0003, // 0140 LDINT R27 4 0x7C600600, // 0141 CALL R24 3 0xB8621A00, // 0142 GETNGBL R24 K13 0x8C60310E, // 0143 GETMET R24 R24 K14 - 0x88680723, // 0144 GETMBR R26 R3 K35 - 0x8C68351D, // 0145 GETMET R26 R26 K29 + 0x88680722, // 0144 GETMBR R26 R3 K34 + 0x8C68351C, // 0145 GETMET R26 R26 K28 0x7C680200, // 0146 CALL R26 1 0x006A941A, // 0147 ADD R26 K74 R26 - 0x586C0010, // 0148 LDCONST R27 K16 + 0x546E0003, // 0148 LDINT R27 4 0x7C600600, // 0149 CALL R24 3 0xB8621A00, // 014A GETNGBL R24 K13 0x8C60310E, // 014B GETMET R24 R24 K14 - 0x8C68071C, // 014C GETMET R26 R3 K28 + 0x8C68071B, // 014C GETMET R26 R3 K27 0x7C680200, // 014D CALL R26 1 0x00683405, // 014E ADD R26 R26 R5 - 0x8C68351D, // 014F GETMET R26 R26 K29 + 0x8C68351C, // 014F GETMET R26 R26 K28 0x7C680200, // 0150 CALL R26 1 0x006A961A, // 0151 ADD R26 K75 R26 - 0x586C0010, // 0152 LDCONST R27 K16 + 0x546E0003, // 0152 LDINT R27 4 0x7C600600, // 0153 CALL R24 3 - 0x8C600521, // 0154 GETMET R24 R2 K33 + 0x8C600520, // 0154 GETMET R24 R2 K32 0x7C600200, // 0155 CALL R24 1 - 0x8C603122, // 0156 GETMET R24 R24 K34 - 0x88680723, // 0157 GETMBR R26 R3 K35 - 0x8C6C071C, // 0158 GETMET R27 R3 K28 + 0x8C603121, // 0156 GETMET R24 R24 K33 + 0x88680722, // 0157 GETMBR R26 R3 K34 + 0x8C6C071B, // 0158 GETMET R27 R3 K27 0x7C6C0200, // 0159 CALL R27 1 0x006C3605, // 015A ADD R27 R27 R5 0x60700015, // 015B GETGBL R28 G21 0x7C700000, // 015C CALL R28 0 - 0x8C70391F, // 015D GETMET R28 R28 K31 + 0x8C70391E, // 015D GETMET R28 R28 K30 0x8878014C, // 015E GETMBR R30 R0 K76 0x7C700400, // 015F CALL R28 2 0x5476002F, // 0160 LDINT R29 48 @@ -1280,33 +1256,33 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0xB8761A00, // 0171 GETNGBL R29 K13 0x8C743B0E, // 0172 GETMET R29 R29 K14 0x587C0049, // 0173 LDCONST R31 K73 - 0x58800010, // 0174 LDCONST R32 K16 + 0x54820003, // 0174 LDINT R32 4 0x7C740600, // 0175 CALL R29 3 0xB8761A00, // 0176 GETNGBL R29 K13 0x8C743B0E, // 0177 GETMET R29 R29 K14 - 0x8C7C331D, // 0178 GETMET R31 R25 K29 + 0x8C7C331C, // 0178 GETMET R31 R25 K28 0x7C7C0200, // 0179 CALL R31 1 0x007E9E1F, // 017A ADD R31 K79 R31 - 0x58800010, // 017B LDCONST R32 K16 + 0x54820003, // 017B LDINT R32 4 0x7C740600, // 017C CALL R29 3 0xB8761A00, // 017D GETNGBL R29 K13 0x8C743B0E, // 017E GETMET R29 R29 K14 - 0x8C7C351D, // 017F GETMET R31 R26 K29 + 0x8C7C351C, // 017F GETMET R31 R26 K28 0x7C7C0200, // 0180 CALL R31 1 0x007EA01F, // 0181 ADD R31 K80 R31 - 0x58800010, // 0182 LDCONST R32 K16 + 0x54820003, // 0182 LDINT R32 4 0x7C740600, // 0183 CALL R29 3 0xB8761A00, // 0184 GETNGBL R29 K13 0x8C743B0E, // 0185 GETMET R29 R29 K14 - 0x8C7C371D, // 0186 GETMET R31 R27 K29 + 0x8C7C371C, // 0186 GETMET R31 R27 K28 0x7C7C0200, // 0187 CALL R31 1 0x007EA21F, // 0188 ADD R31 K81 R31 - 0x58800010, // 0189 LDCONST R32 K16 + 0x54820003, // 0189 LDINT R32 4 0x7C740600, // 018A CALL R29 3 0xB8761A00, // 018B GETNGBL R29 K13 0x8C743B0E, // 018C GETMET R29 R29 K14 0x587C0049, // 018D LDCONST R31 K73 - 0x58800010, // 018E LDCONST R32 K16 + 0x54820003, // 018E LDINT R32 4 0x7C740600, // 018F CALL R29 3 0x8C740352, // 0190 GETMET R29 R1 K82 0x547E003F, // 0191 LDINT R31 64 @@ -1316,7 +1292,7 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma3, /* name */ 0x7C780000, // 0195 CALL R30 0 0x8C7C3D53, // 0196 GETMET R31 R30 K83 0x58840003, // 0197 LDCONST R33 K3 - 0x58880034, // 0198 LDCONST R34 K52 + 0x58880033, // 0198 LDCONST R34 K51 0x7C7C0600, // 0199 CALL R31 3 0x8C7C3D53, // 019A GETMET R31 R30 K83 0x58840003, // 019B LDCONST R33 K3 @@ -1372,7 +1348,7 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[119]) { /* constants */ + ( &(const bvalue[118]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(opcode), /* K2 */ be_nested_str_weak(local_session_id), @@ -1421,81 +1397,80 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ /* K45 */ be_nested_str_weak(tasmota), /* K46 */ be_nested_str_weak(log), /* K47 */ be_nested_str_weak(_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), - /* K48 */ be_const_int(3), - /* K49 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s1rk_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K50 */ be_nested_str_weak(tohex), - /* K51 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20tag_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K52 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20Resume1MICPayload_X20_X3D_X20), - /* K53 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20decrypted_tag_X20_X20_X20_X20_X20_X3D_X20), - /* K54 */ be_nested_str_weak(resumption_id), - /* K55 */ be_nested_str_weak(random), - /* K56 */ be_nested_str_weak(Sigma2_Resume), - /* K57 */ be_nested_str_weak(NCASE_SigmaR2), - /* K58 */ be_nested_str_weak(Sigma2Resume), - /* K59 */ be_nested_str_weak(responderSessionID), - /* K60 */ be_nested_str_weak(sigma2ResumeMIC), - /* K61 */ be_nested_str_weak(SessionResumptionKeys), - /* K62 */ be_nested_str_weak(rtc), - /* K63 */ be_nested_str_weak(utc), - /* K64 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), - /* K65 */ be_nested_str_weak(MTR_X3A_X20I2RKey_X20_X20_X20_X20_X20_X20_X3D), - /* K66 */ be_nested_str_weak(MTR_X3A_X20R2IKey_X20_X20_X20_X20_X20_X20_X3D), - /* K67 */ be_nested_str_weak(MTR_X3A_X20AC_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K68 */ be_nested_str_weak(encode), - /* K69 */ be_nested_str_weak(_Msg1), - /* K70 */ be_nested_str_weak(MTR_X3A_X20sigma2resume_raw_X3A_X20), - /* K71 */ be_nested_str_weak(build_response), - /* K72 */ be_nested_str_weak(responder), - /* K73 */ be_nested_str_weak(send_response), - /* K74 */ be_nested_str_weak(remote_ip), - /* K75 */ be_nested_str_weak(remote_port), - /* K76 */ be_nested_str_weak(message_counter), - /* K77 */ be_nested_str_weak(close), - /* K78 */ be_nested_str_weak(set_keys), - /* K79 */ be_nested_str_weak(set_persist), - /* K80 */ be_nested_str_weak(set_no_expiration), - /* K81 */ be_nested_str_weak(save), - /* K82 */ be_nested_str_weak(ResponderEph_priv), - /* K83 */ be_nested_str_weak(ResponderEph_pub), - /* K84 */ be_nested_str_weak(EC_P256), - /* K85 */ be_nested_str_weak(public_key), - /* K86 */ be_nested_str_weak(shared_key), - /* K87 */ be_nested_str_weak(TLV), - /* K88 */ be_nested_str_weak(Matter_TLV_struct), - /* K89 */ be_nested_str_weak(add_TLV), - /* K90 */ be_const_int(1), - /* K91 */ be_nested_str_weak(B2), - /* K92 */ be_nested_str_weak(get_noc), - /* K93 */ be_const_int(2), - /* K94 */ be_nested_str_weak(get_icac), - /* K95 */ be_nested_str_weak(ecdsa_sign_sha256), - /* K96 */ be_nested_str_weak(get_pk), - /* K97 */ be_nested_str_weak(Msg1), - /* K98 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20MSG1_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K99 */ be_nested_str_weak(SHA256), - /* K100 */ be_nested_str_weak(update), - /* K101 */ be_nested_str_weak(out), - /* K102 */ be_nested_str_weak(S2K_Info), - /* K103 */ be_nested_str_weak(get_ipk_group_key), - /* K104 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20SharedSecret_X20_X20_X3D_X20), - /* K105 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s2k_salt_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K106 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s2k_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), - /* K107 */ be_nested_str_weak(TBEData2_Nonce), - /* K108 */ be_nested_str_weak(encrypt), - /* K109 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TBEData2Enc_X20_X20_X20_X3D_X20), - /* K110 */ be_nested_str_weak(Sigma2), - /* K111 */ be_nested_str_weak(responderRandom), - /* K112 */ be_nested_str_weak(responderSessionId), - /* K113 */ be_nested_str_weak(responderEphPubKey), - /* K114 */ be_nested_str_weak(encrypted2), - /* K115 */ be_nested_str_weak(MTR_X3A_X20sigma2_X3A_X20), - /* K116 */ be_nested_str_weak(inspect), - /* K117 */ be_nested_str_weak(_Msg2), - /* K118 */ be_nested_str_weak(MTR_X3A_X20sigma2_raw_X3A_X20), + /* K48 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s1rk_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K49 */ be_nested_str_weak(tohex), + /* K50 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20tag_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K51 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20Resume1MICPayload_X20_X3D_X20), + /* K52 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20decrypted_tag_X20_X20_X20_X20_X20_X3D_X20), + /* K53 */ be_nested_str_weak(resumption_id), + /* K54 */ be_nested_str_weak(random), + /* K55 */ be_nested_str_weak(Sigma2_Resume), + /* K56 */ be_nested_str_weak(NCASE_SigmaR2), + /* K57 */ be_nested_str_weak(Sigma2Resume), + /* K58 */ be_nested_str_weak(responderSessionID), + /* K59 */ be_nested_str_weak(sigma2ResumeMIC), + /* K60 */ be_nested_str_weak(SessionResumptionKeys), + /* K61 */ be_nested_str_weak(rtc), + /* K62 */ be_nested_str_weak(utc), + /* K63 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), + /* K64 */ be_nested_str_weak(MTR_X3A_X20I2RKey_X20_X20_X20_X20_X20_X20_X3D), + /* K65 */ be_nested_str_weak(MTR_X3A_X20R2IKey_X20_X20_X20_X20_X20_X20_X3D), + /* K66 */ be_nested_str_weak(MTR_X3A_X20AC_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K67 */ be_nested_str_weak(encode), + /* K68 */ be_nested_str_weak(_Msg1), + /* K69 */ be_nested_str_weak(MTR_X3A_X20sigma2resume_raw_X3A_X20), + /* K70 */ be_nested_str_weak(build_response), + /* K71 */ be_nested_str_weak(responder), + /* K72 */ be_nested_str_weak(send_response), + /* K73 */ be_nested_str_weak(remote_ip), + /* K74 */ be_nested_str_weak(remote_port), + /* K75 */ be_nested_str_weak(message_counter), + /* K76 */ be_nested_str_weak(set_keys), + /* K77 */ be_nested_str_weak(set_persist), + /* K78 */ be_nested_str_weak(set_no_expiration), + /* K79 */ be_nested_str_weak(save), + /* K80 */ be_nested_str_weak(ResponderEph_priv), + /* K81 */ be_nested_str_weak(ResponderEph_pub), + /* K82 */ be_nested_str_weak(EC_P256), + /* K83 */ be_nested_str_weak(public_key), + /* K84 */ be_nested_str_weak(shared_key), + /* K85 */ be_nested_str_weak(TLV), + /* K86 */ be_nested_str_weak(Matter_TLV_struct), + /* K87 */ be_nested_str_weak(add_TLV), + /* K88 */ be_const_int(1), + /* K89 */ be_nested_str_weak(B2), + /* K90 */ be_nested_str_weak(get_noc), + /* K91 */ be_const_int(2), + /* K92 */ be_nested_str_weak(get_icac), + /* K93 */ be_const_int(3), + /* K94 */ be_nested_str_weak(ecdsa_sign_sha256), + /* K95 */ be_nested_str_weak(get_pk), + /* K96 */ be_nested_str_weak(Msg1), + /* K97 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20MSG1_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K98 */ be_nested_str_weak(SHA256), + /* K99 */ be_nested_str_weak(update), + /* K100 */ be_nested_str_weak(out), + /* K101 */ be_nested_str_weak(S2K_Info), + /* K102 */ be_nested_str_weak(get_ipk_group_key), + /* K103 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20SharedSecret_X20_X20_X3D_X20), + /* K104 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s2k_salt_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K105 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20s2k_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D_X20), + /* K106 */ be_nested_str_weak(TBEData2_Nonce), + /* K107 */ be_nested_str_weak(encrypt), + /* K108 */ be_nested_str_weak(MTR_X3A_X20_X2A_X20TBEData2Enc_X20_X20_X20_X3D_X20), + /* K109 */ be_nested_str_weak(Sigma2), + /* K110 */ be_nested_str_weak(responderRandom), + /* K111 */ be_nested_str_weak(responderSessionId), + /* K112 */ be_nested_str_weak(responderEphPubKey), + /* K113 */ be_nested_str_weak(encrypted2), + /* K114 */ be_nested_str_weak(MTR_X3A_X20sigma2_X3A_X20), + /* K115 */ be_nested_str_weak(inspect), + /* K116 */ be_nested_str_weak(_Msg2), + /* K117 */ be_nested_str_weak(MTR_X3A_X20sigma2_raw_X3A_X20), }), be_str_weak(parse_Sigma1), &be_const_str_solidified, - ( &(const binstruction[564]) { /* code */ + ( &(const binstruction[562]) { /* code */ 0xA40A0000, // 0000 IMPORT R2 K0 0x880C0301, // 0001 GETMBR R3 R1 K1 0x5412002F, // 0002 LDINT R4 48 @@ -1569,11 +1544,11 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0x90164006, // 0046 SETMBR R5 K32 R6 0x88180B20, // 0047 GETMBR R6 R5 K32 0x90024406, // 0048 SETMBR R0 K34 R6 - 0x781200EE, // 0049 JMPF R4 #0139 + 0x781200EC, // 0049 JMPF R4 #0137 0x88180B23, // 004A GETMBR R6 R5 K35 0x4C1C0000, // 004B LDNIL R7 0x20180C07, // 004C NE R6 R6 R7 - 0x781A00EA, // 004D JMPF R6 #0139 + 0x781A00E8, // 004D JMPF R6 #0137 0x88180715, // 004E GETMBR R6 R3 K21 0x881C070E, // 004F GETMBR R7 R3 K14 0x00180C07, // 0050 ADD R6 R6 R7 @@ -1623,53 +1598,53 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0xB83E5A00, // 007C GETNGBL R15 K45 0x8C3C1F2E, // 007D GETMET R15 R15 K46 0x5844002F, // 007E LDCONST R17 K47 - 0x58480030, // 007F LDCONST R18 K48 + 0x544A0003, // 007F LDINT R18 4 0x7C3C0600, // 0080 CALL R15 3 0xB83E5A00, // 0081 GETNGBL R15 K45 0x8C3C1F2E, // 0082 GETMET R15 R15 K46 - 0x8C441132, // 0083 GETMET R17 R8 K50 + 0x8C441131, // 0083 GETMET R17 R8 K49 0x7C440200, // 0084 CALL R17 1 - 0x00466211, // 0085 ADD R17 K49 R17 - 0x58480030, // 0086 LDCONST R18 K48 + 0x00466011, // 0085 ADD R17 K48 R17 + 0x544A0003, // 0086 LDINT R18 4 0x7C3C0600, // 0087 CALL R15 3 0xB83E5A00, // 0088 GETNGBL R15 K45 0x8C3C1F2E, // 0089 GETMET R15 R15 K46 - 0x8C441732, // 008A GETMET R17 R11 K50 + 0x8C441731, // 008A GETMET R17 R11 K49 0x7C440200, // 008B CALL R17 1 - 0x00466611, // 008C ADD R17 K51 R17 - 0x58480030, // 008D LDCONST R18 K48 + 0x00466411, // 008C ADD R17 K50 R17 + 0x544A0003, // 008D LDINT R18 4 0x7C3C0600, // 008E CALL R15 3 0xB83E5A00, // 008F GETNGBL R15 K45 0x8C3C1F2E, // 0090 GETMET R15 R15 K46 - 0x8C441B32, // 0091 GETMET R17 R13 K50 + 0x8C441B31, // 0091 GETMET R17 R13 K49 0x7C440200, // 0092 CALL R17 1 - 0x00466811, // 0093 ADD R17 K52 R17 - 0x58480030, // 0094 LDCONST R18 K48 + 0x00466611, // 0093 ADD R17 K51 R17 + 0x544A0003, // 0094 LDINT R18 4 0x7C3C0600, // 0095 CALL R15 3 0xB83E5A00, // 0096 GETNGBL R15 K45 0x8C3C1F2E, // 0097 GETMET R15 R15 K46 - 0x8C441D32, // 0098 GETMET R17 R14 K50 + 0x8C441D31, // 0098 GETMET R17 R14 K49 0x7C440200, // 0099 CALL R17 1 - 0x00466A11, // 009A ADD R17 K53 R17 - 0x58480030, // 009B LDCONST R18 K48 + 0x00466811, // 009A ADD R17 K52 R17 + 0x544A0003, // 009B LDINT R18 4 0x7C3C0600, // 009C CALL R15 3 0xB83E5A00, // 009D GETNGBL R15 K45 0x8C3C1F2E, // 009E GETMET R15 R15 K46 0x5844002F, // 009F LDCONST R17 K47 - 0x58480030, // 00A0 LDCONST R18 K48 + 0x544A0003, // 00A0 LDINT R18 4 0x7C3C0600, // 00A1 CALL R15 3 0x1C3C160E, // 00A2 EQ R15 R11 R14 - 0x783E0092, // 00A3 JMPF R15 #0137 - 0x8C3C0537, // 00A4 GETMET R15 R2 K55 + 0x783E0090, // 00A3 JMPF R15 #0135 + 0x8C3C0536, // 00A4 GETMET R15 R2 K54 0x5446000F, // 00A5 LDINT R17 16 0x7C3C0400, // 00A6 CALL R15 2 - 0x90166C0F, // 00A7 SETMBR R5 K54 R15 + 0x90166A0F, // 00A7 SETMBR R5 K53 R15 0x603C0015, // 00A8 GETGBL R15 G21 0x7C3C0000, // 00A9 CALL R15 0 0x8C3C1F24, // 00AA GETMET R15 R15 K36 - 0x58440038, // 00AB LDCONST R17 K56 + 0x58440037, // 00AB LDCONST R17 K55 0x7C3C0400, // 00AC CALL R15 2 - 0x88400B36, // 00AD GETMBR R16 R5 K54 + 0x88400B35, // 00AD GETMBR R16 R5 K53 0x003C1E10, // 00AE ADD R15 R15 R16 0x88400715, // 00AF GETMBR R16 R3 K21 0x8844070E, // 00B0 GETMBR R17 R3 K14 @@ -1687,7 +1662,7 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0x60540015, // 00BC GETGBL R21 G21 0x7C540000, // 00BD CALL R21 0 0x8C542B24, // 00BE GETMET R21 R21 K36 - 0x585C0039, // 00BF LDCONST R23 K57 + 0x585C0038, // 00BF LDCONST R23 K56 0x7C540400, // 00C0 CALL R21 2 0x60580015, // 00C1 GETGBL R22 G21 0x7C580000, // 00C2 CALL R22 0 @@ -1697,13 +1672,13 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0x8C4C252C, // 00C6 GETMET R19 R18 K44 0x7C4C0200, // 00C7 CALL R19 1 0xB8520E00, // 00C8 GETNGBL R20 K7 - 0x8C50293A, // 00C9 GETMET R20 R20 K58 + 0x8C502939, // 00C9 GETMET R20 R20 K57 0x7C500200, // 00CA CALL R20 1 - 0x88540B36, // 00CB GETMBR R21 R5 K54 + 0x88540B35, // 00CB GETMBR R21 R5 K53 0x90521C15, // 00CC SETMBR R20 K14 R21 0x88540B20, // 00CD GETMBR R21 R5 K32 - 0x90527615, // 00CE SETMBR R20 K59 R21 - 0x90527813, // 00CF SETMBR R20 K60 R19 + 0x90527415, // 00CE SETMBR R20 K58 R21 + 0x90527613, // 00CF SETMBR R20 K59 R19 0x8C540526, // 00D0 GETMET R21 R2 K38 0x7C540200, // 00D1 CALL R21 1 0x8C542B27, // 00D2 GETMET R21 R21 K39 @@ -1714,7 +1689,7 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0x60640015, // 00D7 GETGBL R25 G21 0x7C640000, // 00D8 CALL R25 0 0x8C643324, // 00D9 GETMET R25 R25 K36 - 0x586C003D, // 00DA LDCONST R27 K61 + 0x586C003C, // 00DA LDCONST R27 K60 0x7C640400, // 00DB CALL R25 2 0x546A002F, // 00DC LDINT R26 48 0x7C540A00, // 00DD CALL R21 5 @@ -1730,336 +1705,334 @@ be_local_closure(Matter_Commisioning_Context_parse_Sigma1, /* name */ 0x40603019, // 00E7 CONNECT R24 R24 R25 0x94602A18, // 00E8 GETIDX R24 R21 R24 0xB8665A00, // 00E9 GETNGBL R25 K45 - 0x8C64333E, // 00EA GETMET R25 R25 K62 + 0x8C64333D, // 00EA GETMET R25 R25 K61 0x7C640200, // 00EB CALL R25 1 - 0x9464333F, // 00EC GETIDX R25 R25 K63 + 0x9464333E, // 00EC GETIDX R25 R25 K62 0xB86A5A00, // 00ED GETNGBL R26 K45 0x8C68352E, // 00EE GETMET R26 R26 K46 - 0x58700040, // 00EF LDCONST R28 K64 - 0x58740030, // 00F0 LDCONST R29 K48 + 0x5870003F, // 00EF LDCONST R28 K63 + 0x54760003, // 00F0 LDINT R29 4 0x7C680600, // 00F1 CALL R26 3 0xB86A5A00, // 00F2 GETNGBL R26 K45 0x8C68352E, // 00F3 GETMET R26 R26 K46 - 0x8C702D32, // 00F4 GETMET R28 R22 K50 + 0x8C702D31, // 00F4 GETMET R28 R22 K49 0x7C700200, // 00F5 CALL R28 1 - 0x0072821C, // 00F6 ADD R28 K65 R28 - 0x58740030, // 00F7 LDCONST R29 K48 + 0x0072801C, // 00F6 ADD R28 K64 R28 + 0x54760003, // 00F7 LDINT R29 4 0x7C680600, // 00F8 CALL R26 3 0xB86A5A00, // 00F9 GETNGBL R26 K45 0x8C68352E, // 00FA GETMET R26 R26 K46 - 0x8C702F32, // 00FB GETMET R28 R23 K50 + 0x8C702F31, // 00FB GETMET R28 R23 K49 0x7C700200, // 00FC CALL R28 1 - 0x0072841C, // 00FD ADD R28 K66 R28 - 0x58740030, // 00FE LDCONST R29 K48 + 0x0072821C, // 00FD ADD R28 K65 R28 + 0x54760003, // 00FE LDINT R29 4 0x7C680600, // 00FF CALL R26 3 0xB86A5A00, // 0100 GETNGBL R26 K45 0x8C68352E, // 0101 GETMET R26 R26 K46 - 0x8C703132, // 0102 GETMET R28 R24 K50 + 0x8C703131, // 0102 GETMET R28 R24 K49 0x7C700200, // 0103 CALL R28 1 - 0x0072861C, // 0104 ADD R28 K67 R28 - 0x58740030, // 0105 LDCONST R29 K48 + 0x0072841C, // 0104 ADD R28 K66 R28 + 0x54760003, // 0105 LDINT R29 4 0x7C680600, // 0106 CALL R26 3 0xB86A5A00, // 0107 GETNGBL R26 K45 0x8C68352E, // 0108 GETMET R26 R26 K46 - 0x58700040, // 0109 LDCONST R28 K64 - 0x58740030, // 010A LDCONST R29 K48 + 0x5870003F, // 0109 LDCONST R28 K63 + 0x54760003, // 010A LDINT R29 4 0x7C680600, // 010B CALL R26 3 - 0x8C682944, // 010C GETMET R26 R20 K68 + 0x8C682943, // 010C GETMET R26 R20 K67 0x7C680200, // 010D CALL R26 1 0x4C6C0000, // 010E LDNIL R27 - 0x90168A1B, // 010F SETMBR R5 K69 R27 + 0x9016881B, // 010F SETMBR R5 K68 R27 0xB86E5A00, // 0110 GETNGBL R27 K45 0x8C6C372E, // 0111 GETMET R27 R27 K46 - 0x8C743532, // 0112 GETMET R29 R26 K50 + 0x8C743531, // 0112 GETMET R29 R26 K49 0x7C740200, // 0113 CALL R29 1 - 0x00768C1D, // 0114 ADD R29 K70 R29 - 0x58780030, // 0115 LDCONST R30 K48 + 0x00768A1D, // 0114 ADD R29 K69 R29 + 0x547A0003, // 0115 LDINT R30 4 0x7C6C0600, // 0116 CALL R27 3 - 0x8C6C0347, // 0117 GETMET R27 R1 K71 + 0x8C6C0346, // 0117 GETMET R27 R1 K70 0x54760032, // 0118 LDINT R29 51 0x50780200, // 0119 LDBOOL R30 1 0 0x7C6C0600, // 011A CALL R27 3 - 0x8C703744, // 011B GETMET R28 R27 K68 + 0x8C703743, // 011B GETMET R28 R27 K67 0x5C783400, // 011C MOVE R30 R26 0x7C700400, // 011D CALL R28 2 - 0x88740148, // 011E GETMBR R29 R0 K72 - 0x8C743B49, // 011F GETMET R29 R29 K73 + 0x88740147, // 011E GETMBR R29 R0 K71 + 0x8C743B48, // 011F GETMET R29 R29 K72 0x5C7C3800, // 0120 MOVE R31 R28 - 0x8880034A, // 0121 GETMBR R32 R1 K74 - 0x8884034B, // 0122 GETMBR R33 R1 K75 - 0x8888374C, // 0123 GETMBR R34 R27 K76 + 0x88800349, // 0121 GETMBR R32 R1 K73 + 0x8884034A, // 0122 GETMBR R33 R1 K74 + 0x8888374B, // 0123 GETMBR R34 R27 K75 0x7C740A00, // 0124 CALL R29 5 - 0x8C740B4D, // 0125 GETMET R29 R5 K77 - 0x7C740200, // 0126 CALL R29 1 - 0x8C740B4E, // 0127 GETMET R29 R5 K78 - 0x5C7C2C00, // 0128 MOVE R31 R22 - 0x5C802E00, // 0129 MOVE R32 R23 - 0x5C843000, // 012A MOVE R33 R24 - 0x5C883200, // 012B MOVE R34 R25 - 0x7C740A00, // 012C CALL R29 5 - 0x8C740B4F, // 012D GETMET R29 R5 K79 - 0x507C0200, // 012E LDBOOL R31 1 0 - 0x7C740400, // 012F CALL R29 2 - 0x8C740B50, // 0130 GETMET R29 R5 K80 + 0x8C740B4C, // 0125 GETMET R29 R5 K76 + 0x5C7C2C00, // 0126 MOVE R31 R22 + 0x5C802E00, // 0127 MOVE R32 R23 + 0x5C843000, // 0128 MOVE R33 R24 + 0x5C883200, // 0129 MOVE R34 R25 + 0x7C740A00, // 012A CALL R29 5 + 0x8C740B4D, // 012B GETMET R29 R5 K77 + 0x507C0200, // 012C LDBOOL R31 1 0 + 0x7C740400, // 012D CALL R29 2 + 0x8C740B4E, // 012E GETMET R29 R5 K78 + 0x7C740200, // 012F CALL R29 1 + 0x8C740B4F, // 0130 GETMET R29 R5 K79 0x7C740200, // 0131 CALL R29 1 - 0x8C740B51, // 0132 GETMET R29 R5 K81 - 0x7C740200, // 0133 CALL R29 1 - 0x50740200, // 0134 LDBOOL R29 1 0 - 0x80043A00, // 0135 RET 1 R29 - 0x70020001, // 0136 JMP #0139 - 0x4C3C0000, // 0137 LDNIL R15 - 0x900E1C0F, // 0138 SETMBR R3 K14 R15 - 0x8818070E, // 0139 GETMBR R6 R3 K14 - 0x4C1C0000, // 013A LDNIL R7 - 0x1C180C07, // 013B EQ R6 R6 R7 - 0x741A0003, // 013C JMPT R6 #0141 - 0x8818070F, // 013D GETMBR R6 R3 K15 - 0x4C1C0000, // 013E LDNIL R7 - 0x1C180C07, // 013F EQ R6 R6 R7 - 0x781A00F0, // 0140 JMPF R6 #0232 - 0x8C180537, // 0141 GETMET R6 R2 K55 - 0x5422000F, // 0142 LDINT R8 16 - 0x7C180400, // 0143 CALL R6 2 - 0x90166C06, // 0144 SETMBR R5 K54 R6 - 0x8C180537, // 0145 GETMET R6 R2 K55 - 0x5422001F, // 0146 LDINT R8 32 - 0x7C180400, // 0147 CALL R6 2 - 0x9002A406, // 0148 SETMBR R0 K82 R6 - 0x8C180554, // 0149 GETMET R6 R2 K84 - 0x7C180200, // 014A CALL R6 1 - 0x8C180D55, // 014B GETMET R6 R6 K85 - 0x88200152, // 014C GETMBR R8 R0 K82 - 0x7C180400, // 014D CALL R6 2 - 0x9002A606, // 014E SETMBR R0 K83 R6 - 0x8C180537, // 014F GETMET R6 R2 K55 - 0x5422001F, // 0150 LDINT R8 32 - 0x7C180400, // 0151 CALL R6 2 - 0x8C1C0554, // 0152 GETMET R7 R2 K84 - 0x7C1C0200, // 0153 CALL R7 1 - 0x8C1C0F56, // 0154 GETMET R7 R7 K86 - 0x88240152, // 0155 GETMBR R9 R0 K82 - 0x8828070D, // 0156 GETMBR R10 R3 K13 - 0x7C1C0600, // 0157 CALL R7 3 - 0x90164607, // 0158 SETMBR R5 K35 R7 - 0xB81E0E00, // 0159 GETNGBL R7 K7 - 0x881C0F57, // 015A GETMBR R7 R7 K87 - 0x8C1C0F58, // 015B GETMET R7 R7 K88 - 0x7C1C0200, // 015C CALL R7 1 - 0x8C200F59, // 015D GETMET R8 R7 K89 - 0x5828005A, // 015E LDCONST R10 K90 - 0xB82E0E00, // 015F GETNGBL R11 K7 - 0x882C1757, // 0160 GETMBR R11 R11 K87 - 0x882C175B, // 0161 GETMBR R11 R11 K91 - 0x8C300B5C, // 0162 GETMET R12 R5 K92 - 0x7C300200, // 0163 CALL R12 1 - 0x7C200800, // 0164 CALL R8 4 - 0x8C200F59, // 0165 GETMET R8 R7 K89 - 0x5828005D, // 0166 LDCONST R10 K93 - 0xB82E0E00, // 0167 GETNGBL R11 K7 - 0x882C1757, // 0168 GETMBR R11 R11 K87 - 0x882C175B, // 0169 GETMBR R11 R11 K91 - 0x8C300B5E, // 016A GETMET R12 R5 K94 - 0x7C300200, // 016B CALL R12 1 - 0x7C200800, // 016C CALL R8 4 - 0x8C200F59, // 016D GETMET R8 R7 K89 - 0x58280030, // 016E LDCONST R10 K48 - 0xB82E0E00, // 016F GETNGBL R11 K7 - 0x882C1757, // 0170 GETMBR R11 R11 K87 - 0x882C175B, // 0171 GETMBR R11 R11 K91 - 0x88300153, // 0172 GETMBR R12 R0 K83 - 0x7C200800, // 0173 CALL R8 4 - 0x8C200F59, // 0174 GETMET R8 R7 K89 - 0x542A0003, // 0175 LDINT R10 4 - 0xB82E0E00, // 0176 GETNGBL R11 K7 - 0x882C1757, // 0177 GETMBR R11 R11 K87 - 0x882C175B, // 0178 GETMBR R11 R11 K91 - 0x8830070D, // 0179 GETMBR R12 R3 K13 - 0x7C200800, // 017A CALL R8 4 - 0x8C200554, // 017B GETMET R8 R2 K84 - 0x7C200200, // 017C CALL R8 1 - 0x8C20115F, // 017D GETMET R8 R8 K95 - 0x8C280B60, // 017E GETMET R10 R5 K96 - 0x7C280200, // 017F CALL R10 1 - 0x8C2C0F44, // 0180 GETMET R11 R7 K68 - 0x7C2C0200, // 0181 CALL R11 1 - 0x7C200600, // 0182 CALL R8 3 - 0xB8260E00, // 0183 GETNGBL R9 K7 - 0x88241357, // 0184 GETMBR R9 R9 K87 - 0x8C241358, // 0185 GETMET R9 R9 K88 - 0x7C240200, // 0186 CALL R9 1 - 0x8C281359, // 0187 GETMET R10 R9 K89 - 0x5830005A, // 0188 LDCONST R12 K90 - 0xB8360E00, // 0189 GETNGBL R13 K7 - 0x88341B57, // 018A GETMBR R13 R13 K87 - 0x88341B5B, // 018B GETMBR R13 R13 K91 - 0x8C380B5C, // 018C GETMET R14 R5 K92 - 0x7C380200, // 018D CALL R14 1 - 0x7C280800, // 018E CALL R10 4 - 0x8C281359, // 018F GETMET R10 R9 K89 - 0x5830005D, // 0190 LDCONST R12 K93 - 0xB8360E00, // 0191 GETNGBL R13 K7 - 0x88341B57, // 0192 GETMBR R13 R13 K87 - 0x88341B5B, // 0193 GETMBR R13 R13 K91 - 0x8C380B5E, // 0194 GETMET R14 R5 K94 - 0x7C380200, // 0195 CALL R14 1 - 0x7C280800, // 0196 CALL R10 4 - 0x8C281359, // 0197 GETMET R10 R9 K89 - 0x58300030, // 0198 LDCONST R12 K48 - 0xB8360E00, // 0199 GETNGBL R13 K7 - 0x88341B57, // 019A GETMBR R13 R13 K87 - 0x88341B5B, // 019B GETMBR R13 R13 K91 - 0x5C381000, // 019C MOVE R14 R8 - 0x7C280800, // 019D CALL R10 4 - 0x8C281359, // 019E GETMET R10 R9 K89 - 0x54320003, // 019F LDINT R12 4 - 0xB8360E00, // 01A0 GETNGBL R13 K7 - 0x88341B57, // 01A1 GETMBR R13 R13 K87 - 0x88341B5B, // 01A2 GETMBR R13 R13 K91 - 0x88380B36, // 01A3 GETMBR R14 R5 K54 - 0x7C280800, // 01A4 CALL R10 4 - 0xB82A5A00, // 01A5 GETNGBL R10 K45 - 0x8C28152E, // 01A6 GETMET R10 R10 K46 - 0x5830002F, // 01A7 LDCONST R12 K47 - 0x58340030, // 01A8 LDCONST R13 K48 - 0x7C280600, // 01A9 CALL R10 3 - 0x88280761, // 01AA GETMBR R10 R3 K97 - 0x90168A0A, // 01AB SETMBR R5 K69 R10 - 0xB82A5A00, // 01AC GETNGBL R10 K45 - 0x8C28152E, // 01AD GETMET R10 R10 K46 - 0x88300B45, // 01AE GETMBR R12 R5 K69 - 0x8C301932, // 01AF GETMET R12 R12 K50 - 0x7C300200, // 01B0 CALL R12 1 - 0x0032C40C, // 01B1 ADD R12 K98 R12 - 0x58340030, // 01B2 LDCONST R13 K48 - 0x7C280600, // 01B3 CALL R10 3 - 0x8C280563, // 01B4 GETMET R10 R2 K99 - 0x7C280200, // 01B5 CALL R10 1 - 0x8C281564, // 01B6 GETMET R10 R10 K100 - 0x88300B45, // 01B7 GETMBR R12 R5 K69 - 0x7C280400, // 01B8 CALL R10 2 - 0x8C281565, // 01B9 GETMET R10 R10 K101 - 0x7C280200, // 01BA CALL R10 1 - 0x602C0015, // 01BB GETGBL R11 G21 - 0x7C2C0000, // 01BC CALL R11 0 - 0x8C2C1724, // 01BD GETMET R11 R11 K36 - 0x88340166, // 01BE GETMBR R13 R0 K102 - 0x7C2C0400, // 01BF CALL R11 2 - 0x8C300B67, // 01C0 GETMET R12 R5 K103 - 0x7C300200, // 01C1 CALL R12 1 - 0x00301806, // 01C2 ADD R12 R12 R6 - 0x88340153, // 01C3 GETMBR R13 R0 K83 - 0x0030180D, // 01C4 ADD R12 R12 R13 - 0x0030180A, // 01C5 ADD R12 R12 R10 - 0x8C340526, // 01C6 GETMET R13 R2 K38 - 0x7C340200, // 01C7 CALL R13 1 - 0x8C341B27, // 01C8 GETMET R13 R13 K39 - 0x883C0B23, // 01C9 GETMBR R15 R5 K35 - 0x5C401800, // 01CA MOVE R16 R12 - 0x5C441600, // 01CB MOVE R17 R11 - 0x544A000F, // 01CC LDINT R18 16 - 0x7C340A00, // 01CD CALL R13 5 - 0xB83A5A00, // 01CE GETNGBL R14 K45 - 0x8C381D2E, // 01CF GETMET R14 R14 K46 - 0x88400B23, // 01D0 GETMBR R16 R5 K35 - 0x8C402132, // 01D1 GETMET R16 R16 K50 - 0x7C400200, // 01D2 CALL R16 1 - 0x0042D010, // 01D3 ADD R16 K104 R16 - 0x58440030, // 01D4 LDCONST R17 K48 - 0x7C380600, // 01D5 CALL R14 3 - 0xB83A5A00, // 01D6 GETNGBL R14 K45 - 0x8C381D2E, // 01D7 GETMET R14 R14 K46 - 0x8C401932, // 01D8 GETMET R16 R12 K50 - 0x7C400200, // 01D9 CALL R16 1 - 0x0042D210, // 01DA ADD R16 K105 R16 - 0x58440030, // 01DB LDCONST R17 K48 - 0x7C380600, // 01DC CALL R14 3 - 0xB83A5A00, // 01DD GETNGBL R14 K45 - 0x8C381D2E, // 01DE GETMET R14 R14 K46 - 0x8C401B32, // 01DF GETMET R16 R13 K50 - 0x7C400200, // 01E0 CALL R16 1 - 0x0042D410, // 01E1 ADD R16 K106 R16 - 0x58440030, // 01E2 LDCONST R17 K48 - 0x7C380600, // 01E3 CALL R14 3 - 0x8C381344, // 01E4 GETMET R14 R9 K68 - 0x7C380200, // 01E5 CALL R14 1 - 0x8C3C052A, // 01E6 GETMET R15 R2 K42 - 0x5C441A00, // 01E7 MOVE R17 R13 - 0x60480015, // 01E8 GETGBL R18 G21 - 0x7C480000, // 01E9 CALL R18 0 - 0x8C482524, // 01EA GETMET R18 R18 K36 - 0x8850016B, // 01EB GETMBR R20 R0 K107 - 0x7C480400, // 01EC CALL R18 2 - 0x604C0015, // 01ED GETGBL R19 G21 - 0x7C4C0000, // 01EE CALL R19 0 - 0x6050000C, // 01EF GETGBL R20 G12 - 0x5C541C00, // 01F0 MOVE R21 R14 - 0x7C500200, // 01F1 CALL R20 1 - 0x5456000F, // 01F2 LDINT R21 16 - 0x7C3C0C00, // 01F3 CALL R15 6 - 0x8C401F6C, // 01F4 GETMET R16 R15 K108 - 0x5C481C00, // 01F5 MOVE R18 R14 - 0x7C400400, // 01F6 CALL R16 2 - 0x8C441F2C, // 01F7 GETMET R17 R15 K44 - 0x7C440200, // 01F8 CALL R17 1 - 0x00402011, // 01F9 ADD R16 R16 R17 - 0xB8465A00, // 01FA GETNGBL R17 K45 - 0x8C44232E, // 01FB GETMET R17 R17 K46 - 0x8C4C2132, // 01FC GETMET R19 R16 K50 - 0x7C4C0200, // 01FD CALL R19 1 - 0x004EDA13, // 01FE ADD R19 K109 R19 - 0x58500030, // 01FF LDCONST R20 K48 - 0x7C440600, // 0200 CALL R17 3 - 0xB8465A00, // 0201 GETNGBL R17 K45 - 0x8C44232E, // 0202 GETMET R17 R17 K46 - 0x584C002F, // 0203 LDCONST R19 K47 - 0x58500030, // 0204 LDCONST R20 K48 - 0x7C440600, // 0205 CALL R17 3 - 0xB8460E00, // 0206 GETNGBL R17 K7 - 0x8C44236E, // 0207 GETMET R17 R17 K110 - 0x7C440200, // 0208 CALL R17 1 - 0x9046DE06, // 0209 SETMBR R17 K111 R6 - 0x88480122, // 020A GETMBR R18 R0 K34 + 0x50740200, // 0132 LDBOOL R29 1 0 + 0x80043A00, // 0133 RET 1 R29 + 0x70020001, // 0134 JMP #0137 + 0x4C3C0000, // 0135 LDNIL R15 + 0x900E1C0F, // 0136 SETMBR R3 K14 R15 + 0x8818070E, // 0137 GETMBR R6 R3 K14 + 0x4C1C0000, // 0138 LDNIL R7 + 0x1C180C07, // 0139 EQ R6 R6 R7 + 0x741A0003, // 013A JMPT R6 #013F + 0x8818070F, // 013B GETMBR R6 R3 K15 + 0x4C1C0000, // 013C LDNIL R7 + 0x1C180C07, // 013D EQ R6 R6 R7 + 0x781A00F0, // 013E JMPF R6 #0230 + 0x8C180536, // 013F GETMET R6 R2 K54 + 0x5422000F, // 0140 LDINT R8 16 + 0x7C180400, // 0141 CALL R6 2 + 0x90166A06, // 0142 SETMBR R5 K53 R6 + 0x8C180536, // 0143 GETMET R6 R2 K54 + 0x5422001F, // 0144 LDINT R8 32 + 0x7C180400, // 0145 CALL R6 2 + 0x9002A006, // 0146 SETMBR R0 K80 R6 + 0x8C180552, // 0147 GETMET R6 R2 K82 + 0x7C180200, // 0148 CALL R6 1 + 0x8C180D53, // 0149 GETMET R6 R6 K83 + 0x88200150, // 014A GETMBR R8 R0 K80 + 0x7C180400, // 014B CALL R6 2 + 0x9002A206, // 014C SETMBR R0 K81 R6 + 0x8C180536, // 014D GETMET R6 R2 K54 + 0x5422001F, // 014E LDINT R8 32 + 0x7C180400, // 014F CALL R6 2 + 0x8C1C0552, // 0150 GETMET R7 R2 K82 + 0x7C1C0200, // 0151 CALL R7 1 + 0x8C1C0F54, // 0152 GETMET R7 R7 K84 + 0x88240150, // 0153 GETMBR R9 R0 K80 + 0x8828070D, // 0154 GETMBR R10 R3 K13 + 0x7C1C0600, // 0155 CALL R7 3 + 0x90164607, // 0156 SETMBR R5 K35 R7 + 0xB81E0E00, // 0157 GETNGBL R7 K7 + 0x881C0F55, // 0158 GETMBR R7 R7 K85 + 0x8C1C0F56, // 0159 GETMET R7 R7 K86 + 0x7C1C0200, // 015A CALL R7 1 + 0x8C200F57, // 015B GETMET R8 R7 K87 + 0x58280058, // 015C LDCONST R10 K88 + 0xB82E0E00, // 015D GETNGBL R11 K7 + 0x882C1755, // 015E GETMBR R11 R11 K85 + 0x882C1759, // 015F GETMBR R11 R11 K89 + 0x8C300B5A, // 0160 GETMET R12 R5 K90 + 0x7C300200, // 0161 CALL R12 1 + 0x7C200800, // 0162 CALL R8 4 + 0x8C200F57, // 0163 GETMET R8 R7 K87 + 0x5828005B, // 0164 LDCONST R10 K91 + 0xB82E0E00, // 0165 GETNGBL R11 K7 + 0x882C1755, // 0166 GETMBR R11 R11 K85 + 0x882C1759, // 0167 GETMBR R11 R11 K89 + 0x8C300B5C, // 0168 GETMET R12 R5 K92 + 0x7C300200, // 0169 CALL R12 1 + 0x7C200800, // 016A CALL R8 4 + 0x8C200F57, // 016B GETMET R8 R7 K87 + 0x5828005D, // 016C LDCONST R10 K93 + 0xB82E0E00, // 016D GETNGBL R11 K7 + 0x882C1755, // 016E GETMBR R11 R11 K85 + 0x882C1759, // 016F GETMBR R11 R11 K89 + 0x88300151, // 0170 GETMBR R12 R0 K81 + 0x7C200800, // 0171 CALL R8 4 + 0x8C200F57, // 0172 GETMET R8 R7 K87 + 0x542A0003, // 0173 LDINT R10 4 + 0xB82E0E00, // 0174 GETNGBL R11 K7 + 0x882C1755, // 0175 GETMBR R11 R11 K85 + 0x882C1759, // 0176 GETMBR R11 R11 K89 + 0x8830070D, // 0177 GETMBR R12 R3 K13 + 0x7C200800, // 0178 CALL R8 4 + 0x8C200552, // 0179 GETMET R8 R2 K82 + 0x7C200200, // 017A CALL R8 1 + 0x8C20115E, // 017B GETMET R8 R8 K94 + 0x8C280B5F, // 017C GETMET R10 R5 K95 + 0x7C280200, // 017D CALL R10 1 + 0x8C2C0F43, // 017E GETMET R11 R7 K67 + 0x7C2C0200, // 017F CALL R11 1 + 0x7C200600, // 0180 CALL R8 3 + 0xB8260E00, // 0181 GETNGBL R9 K7 + 0x88241355, // 0182 GETMBR R9 R9 K85 + 0x8C241356, // 0183 GETMET R9 R9 K86 + 0x7C240200, // 0184 CALL R9 1 + 0x8C281357, // 0185 GETMET R10 R9 K87 + 0x58300058, // 0186 LDCONST R12 K88 + 0xB8360E00, // 0187 GETNGBL R13 K7 + 0x88341B55, // 0188 GETMBR R13 R13 K85 + 0x88341B59, // 0189 GETMBR R13 R13 K89 + 0x8C380B5A, // 018A GETMET R14 R5 K90 + 0x7C380200, // 018B CALL R14 1 + 0x7C280800, // 018C CALL R10 4 + 0x8C281357, // 018D GETMET R10 R9 K87 + 0x5830005B, // 018E LDCONST R12 K91 + 0xB8360E00, // 018F GETNGBL R13 K7 + 0x88341B55, // 0190 GETMBR R13 R13 K85 + 0x88341B59, // 0191 GETMBR R13 R13 K89 + 0x8C380B5C, // 0192 GETMET R14 R5 K92 + 0x7C380200, // 0193 CALL R14 1 + 0x7C280800, // 0194 CALL R10 4 + 0x8C281357, // 0195 GETMET R10 R9 K87 + 0x5830005D, // 0196 LDCONST R12 K93 + 0xB8360E00, // 0197 GETNGBL R13 K7 + 0x88341B55, // 0198 GETMBR R13 R13 K85 + 0x88341B59, // 0199 GETMBR R13 R13 K89 + 0x5C381000, // 019A MOVE R14 R8 + 0x7C280800, // 019B CALL R10 4 + 0x8C281357, // 019C GETMET R10 R9 K87 + 0x54320003, // 019D LDINT R12 4 + 0xB8360E00, // 019E GETNGBL R13 K7 + 0x88341B55, // 019F GETMBR R13 R13 K85 + 0x88341B59, // 01A0 GETMBR R13 R13 K89 + 0x88380B35, // 01A1 GETMBR R14 R5 K53 + 0x7C280800, // 01A2 CALL R10 4 + 0xB82A5A00, // 01A3 GETNGBL R10 K45 + 0x8C28152E, // 01A4 GETMET R10 R10 K46 + 0x5830002F, // 01A5 LDCONST R12 K47 + 0x54360003, // 01A6 LDINT R13 4 + 0x7C280600, // 01A7 CALL R10 3 + 0x88280760, // 01A8 GETMBR R10 R3 K96 + 0x9016880A, // 01A9 SETMBR R5 K68 R10 + 0xB82A5A00, // 01AA GETNGBL R10 K45 + 0x8C28152E, // 01AB GETMET R10 R10 K46 + 0x88300B44, // 01AC GETMBR R12 R5 K68 + 0x8C301931, // 01AD GETMET R12 R12 K49 + 0x7C300200, // 01AE CALL R12 1 + 0x0032C20C, // 01AF ADD R12 K97 R12 + 0x54360003, // 01B0 LDINT R13 4 + 0x7C280600, // 01B1 CALL R10 3 + 0x8C280562, // 01B2 GETMET R10 R2 K98 + 0x7C280200, // 01B3 CALL R10 1 + 0x8C281563, // 01B4 GETMET R10 R10 K99 + 0x88300B44, // 01B5 GETMBR R12 R5 K68 + 0x7C280400, // 01B6 CALL R10 2 + 0x8C281564, // 01B7 GETMET R10 R10 K100 + 0x7C280200, // 01B8 CALL R10 1 + 0x602C0015, // 01B9 GETGBL R11 G21 + 0x7C2C0000, // 01BA CALL R11 0 + 0x8C2C1724, // 01BB GETMET R11 R11 K36 + 0x88340165, // 01BC GETMBR R13 R0 K101 + 0x7C2C0400, // 01BD CALL R11 2 + 0x8C300B66, // 01BE GETMET R12 R5 K102 + 0x7C300200, // 01BF CALL R12 1 + 0x00301806, // 01C0 ADD R12 R12 R6 + 0x88340151, // 01C1 GETMBR R13 R0 K81 + 0x0030180D, // 01C2 ADD R12 R12 R13 + 0x0030180A, // 01C3 ADD R12 R12 R10 + 0x8C340526, // 01C4 GETMET R13 R2 K38 + 0x7C340200, // 01C5 CALL R13 1 + 0x8C341B27, // 01C6 GETMET R13 R13 K39 + 0x883C0B23, // 01C7 GETMBR R15 R5 K35 + 0x5C401800, // 01C8 MOVE R16 R12 + 0x5C441600, // 01C9 MOVE R17 R11 + 0x544A000F, // 01CA LDINT R18 16 + 0x7C340A00, // 01CB CALL R13 5 + 0xB83A5A00, // 01CC GETNGBL R14 K45 + 0x8C381D2E, // 01CD GETMET R14 R14 K46 + 0x88400B23, // 01CE GETMBR R16 R5 K35 + 0x8C402131, // 01CF GETMET R16 R16 K49 + 0x7C400200, // 01D0 CALL R16 1 + 0x0042CE10, // 01D1 ADD R16 K103 R16 + 0x54460003, // 01D2 LDINT R17 4 + 0x7C380600, // 01D3 CALL R14 3 + 0xB83A5A00, // 01D4 GETNGBL R14 K45 + 0x8C381D2E, // 01D5 GETMET R14 R14 K46 + 0x8C401931, // 01D6 GETMET R16 R12 K49 + 0x7C400200, // 01D7 CALL R16 1 + 0x0042D010, // 01D8 ADD R16 K104 R16 + 0x54460003, // 01D9 LDINT R17 4 + 0x7C380600, // 01DA CALL R14 3 + 0xB83A5A00, // 01DB GETNGBL R14 K45 + 0x8C381D2E, // 01DC GETMET R14 R14 K46 + 0x8C401B31, // 01DD GETMET R16 R13 K49 + 0x7C400200, // 01DE CALL R16 1 + 0x0042D210, // 01DF ADD R16 K105 R16 + 0x54460003, // 01E0 LDINT R17 4 + 0x7C380600, // 01E1 CALL R14 3 + 0x8C381343, // 01E2 GETMET R14 R9 K67 + 0x7C380200, // 01E3 CALL R14 1 + 0x8C3C052A, // 01E4 GETMET R15 R2 K42 + 0x5C441A00, // 01E5 MOVE R17 R13 + 0x60480015, // 01E6 GETGBL R18 G21 + 0x7C480000, // 01E7 CALL R18 0 + 0x8C482524, // 01E8 GETMET R18 R18 K36 + 0x8850016A, // 01E9 GETMBR R20 R0 K106 + 0x7C480400, // 01EA CALL R18 2 + 0x604C0015, // 01EB GETGBL R19 G21 + 0x7C4C0000, // 01EC CALL R19 0 + 0x6050000C, // 01ED GETGBL R20 G12 + 0x5C541C00, // 01EE MOVE R21 R14 + 0x7C500200, // 01EF CALL R20 1 + 0x5456000F, // 01F0 LDINT R21 16 + 0x7C3C0C00, // 01F1 CALL R15 6 + 0x8C401F6B, // 01F2 GETMET R16 R15 K107 + 0x5C481C00, // 01F3 MOVE R18 R14 + 0x7C400400, // 01F4 CALL R16 2 + 0x8C441F2C, // 01F5 GETMET R17 R15 K44 + 0x7C440200, // 01F6 CALL R17 1 + 0x00402011, // 01F7 ADD R16 R16 R17 + 0xB8465A00, // 01F8 GETNGBL R17 K45 + 0x8C44232E, // 01F9 GETMET R17 R17 K46 + 0x8C4C2131, // 01FA GETMET R19 R16 K49 + 0x7C4C0200, // 01FB CALL R19 1 + 0x004ED813, // 01FC ADD R19 K108 R19 + 0x54520003, // 01FD LDINT R20 4 + 0x7C440600, // 01FE CALL R17 3 + 0xB8465A00, // 01FF GETNGBL R17 K45 + 0x8C44232E, // 0200 GETMET R17 R17 K46 + 0x584C002F, // 0201 LDCONST R19 K47 + 0x54520003, // 0202 LDINT R20 4 + 0x7C440600, // 0203 CALL R17 3 + 0xB8460E00, // 0204 GETNGBL R17 K7 + 0x8C44236D, // 0205 GETMET R17 R17 K109 + 0x7C440200, // 0206 CALL R17 1 + 0x9046DC06, // 0207 SETMBR R17 K110 R6 + 0x88480122, // 0208 GETMBR R18 R0 K34 + 0x9046DE12, // 0209 SETMBR R17 K111 R18 + 0x88480151, // 020A GETMBR R18 R0 K81 0x9046E012, // 020B SETMBR R17 K112 R18 - 0x88480153, // 020C GETMBR R18 R0 K83 - 0x9046E212, // 020D SETMBR R17 K113 R18 - 0x9046E410, // 020E SETMBR R17 K114 R16 - 0xB84A5A00, // 020F GETNGBL R18 K45 - 0x8C48252E, // 0210 GETMET R18 R18 K46 - 0xB8520E00, // 0211 GETNGBL R20 K7 - 0x8C502974, // 0212 GETMET R20 R20 K116 - 0x5C582200, // 0213 MOVE R22 R17 - 0x7C500400, // 0214 CALL R20 2 - 0x0052E614, // 0215 ADD R20 K115 R20 - 0x58540030, // 0216 LDCONST R21 K48 - 0x7C480600, // 0217 CALL R18 3 - 0x8C482344, // 0218 GETMET R18 R17 K68 - 0x7C480200, // 0219 CALL R18 1 - 0x9016EA12, // 021A SETMBR R5 K117 R18 - 0xB84E5A00, // 021B GETNGBL R19 K45 - 0x8C4C272E, // 021C GETMET R19 R19 K46 - 0x8C542532, // 021D GETMET R21 R18 K50 - 0x7C540200, // 021E CALL R21 1 - 0x0056EC15, // 021F ADD R21 K118 R21 - 0x58580030, // 0220 LDCONST R22 K48 - 0x7C4C0600, // 0221 CALL R19 3 - 0x8C4C0347, // 0222 GETMET R19 R1 K71 - 0x54560030, // 0223 LDINT R21 49 - 0x50580200, // 0224 LDBOOL R22 1 0 - 0x7C4C0600, // 0225 CALL R19 3 - 0x8C502744, // 0226 GETMET R20 R19 K68 - 0x5C582400, // 0227 MOVE R22 R18 - 0x7C500400, // 0228 CALL R20 2 - 0x88540148, // 0229 GETMBR R21 R0 K72 - 0x8C542B49, // 022A GETMET R21 R21 K73 - 0x5C5C2800, // 022B MOVE R23 R20 - 0x8860034A, // 022C GETMBR R24 R1 K74 - 0x8864034B, // 022D GETMBR R25 R1 K75 - 0x8868274C, // 022E GETMBR R26 R19 K76 - 0x7C540A00, // 022F CALL R21 5 - 0x50540200, // 0230 LDBOOL R21 1 0 - 0x80042A00, // 0231 RET 1 R21 - 0x50180200, // 0232 LDBOOL R6 1 0 - 0x80040C00, // 0233 RET 1 R6 + 0x9046E210, // 020C SETMBR R17 K113 R16 + 0xB84A5A00, // 020D GETNGBL R18 K45 + 0x8C48252E, // 020E GETMET R18 R18 K46 + 0xB8520E00, // 020F GETNGBL R20 K7 + 0x8C502973, // 0210 GETMET R20 R20 K115 + 0x5C582200, // 0211 MOVE R22 R17 + 0x7C500400, // 0212 CALL R20 2 + 0x0052E414, // 0213 ADD R20 K114 R20 + 0x54560003, // 0214 LDINT R21 4 + 0x7C480600, // 0215 CALL R18 3 + 0x8C482343, // 0216 GETMET R18 R17 K67 + 0x7C480200, // 0217 CALL R18 1 + 0x9016E812, // 0218 SETMBR R5 K116 R18 + 0xB84E5A00, // 0219 GETNGBL R19 K45 + 0x8C4C272E, // 021A GETMET R19 R19 K46 + 0x8C542531, // 021B GETMET R21 R18 K49 + 0x7C540200, // 021C CALL R21 1 + 0x0056EA15, // 021D ADD R21 K117 R21 + 0x545A0003, // 021E LDINT R22 4 + 0x7C4C0600, // 021F CALL R19 3 + 0x8C4C0346, // 0220 GETMET R19 R1 K70 + 0x54560030, // 0221 LDINT R21 49 + 0x50580200, // 0222 LDBOOL R22 1 0 + 0x7C4C0600, // 0223 CALL R19 3 + 0x8C502743, // 0224 GETMET R20 R19 K67 + 0x5C582400, // 0225 MOVE R22 R18 + 0x7C500400, // 0226 CALL R20 2 + 0x88540147, // 0227 GETMBR R21 R0 K71 + 0x8C542B48, // 0228 GETMET R21 R21 K72 + 0x5C5C2800, // 0229 MOVE R23 R20 + 0x88600349, // 022A GETMBR R24 R1 K73 + 0x8864034A, // 022B GETMBR R25 R1 K74 + 0x8868274B, // 022C GETMBR R26 R19 K75 + 0x7C540A00, // 022D CALL R21 5 + 0x50540200, // 022E LDBOOL R21 1 0 + 0x80042A00, // 022F RET 1 R21 + 0x50180200, // 0230 LDBOOL R6 1 0 + 0x80040C00, // 0231 RET 1 R6 }) ) ); @@ -2079,7 +2052,7 @@ be_local_closure(Matter_Commisioning_Context_parse_Pake3, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[47]) { /* constants */ + ( &(const bvalue[46]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(opcode), /* K2 */ be_nested_str_weak(local_session_id), @@ -2097,36 +2070,35 @@ be_local_closure(Matter_Commisioning_Context_parse_Pake3, /* name */ /* K14 */ be_nested_str_weak(log), /* K15 */ be_nested_str_weak(MTR_X3A_X20received_X20cA_X3D), /* K16 */ be_nested_str_weak(tohex), - /* K17 */ be_const_int(3), - /* K18 */ be_nested_str_weak(spake), - /* K19 */ be_nested_str_weak(invalid_X20cA_X20received), - /* K20 */ be_nested_str_weak(session_timestamp), - /* K21 */ be_nested_str_weak(rtc), - /* K22 */ be_nested_str_weak(utc), - /* K23 */ be_nested_str_weak(HKDF_SHA256), - /* K24 */ be_nested_str_weak(derive), - /* K25 */ be_nested_str_weak(Ke), - /* K26 */ be_nested_str_weak(fromstring), - /* K27 */ be_nested_str_weak(SEKeys_Info), - /* K28 */ be_nested_str_weak(I2RKey), - /* K29 */ be_nested_str_weak(R2IKey), - /* K30 */ be_nested_str_weak(AttestationChallenge), - /* K31 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), - /* K32 */ be_nested_str_weak(MTR_X3A_X20session_keys_X3D), - /* K33 */ be_nested_str_weak(MTR_X3A_X20I2RKey_X20_X20_X20_X20_X20_X20_X3D), - /* K34 */ be_nested_str_weak(MTR_X3A_X20R2IKey_X20_X20_X20_X20_X20_X20_X3D), - /* K35 */ be_nested_str_weak(MTR_X3A_X20AC_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K36 */ be_nested_str_weak(build_response), - /* K37 */ be_nested_str_weak(add), - /* K38 */ be_const_int(2), - /* K39 */ be_nested_str_weak(encode), - /* K40 */ be_nested_str_weak(responder), - /* K41 */ be_nested_str_weak(send_response), - /* K42 */ be_nested_str_weak(remote_ip), - /* K43 */ be_nested_str_weak(remote_port), - /* K44 */ be_nested_str_weak(add_session), - /* K45 */ be_nested_str_weak(future_local_session_id), - /* K46 */ be_nested_str_weak(future_initiator_session_id), + /* K17 */ be_nested_str_weak(spake), + /* K18 */ be_nested_str_weak(invalid_X20cA_X20received), + /* K19 */ be_nested_str_weak(session_timestamp), + /* K20 */ be_nested_str_weak(rtc), + /* K21 */ be_nested_str_weak(utc), + /* K22 */ be_nested_str_weak(HKDF_SHA256), + /* K23 */ be_nested_str_weak(derive), + /* K24 */ be_nested_str_weak(Ke), + /* K25 */ be_nested_str_weak(fromstring), + /* K26 */ be_nested_str_weak(SEKeys_Info), + /* K27 */ be_nested_str_weak(I2RKey), + /* K28 */ be_nested_str_weak(R2IKey), + /* K29 */ be_nested_str_weak(AttestationChallenge), + /* K30 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), + /* K31 */ be_nested_str_weak(MTR_X3A_X20session_keys_X3D), + /* K32 */ be_nested_str_weak(MTR_X3A_X20I2RKey_X20_X20_X20_X20_X20_X20_X3D), + /* K33 */ be_nested_str_weak(MTR_X3A_X20R2IKey_X20_X20_X20_X20_X20_X20_X3D), + /* K34 */ be_nested_str_weak(MTR_X3A_X20AC_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K35 */ be_nested_str_weak(build_response), + /* K36 */ be_nested_str_weak(add), + /* K37 */ be_const_int(2), + /* K38 */ be_nested_str_weak(encode), + /* K39 */ be_nested_str_weak(responder), + /* K40 */ be_nested_str_weak(send_response), + /* K41 */ be_nested_str_weak(remote_ip), + /* K42 */ be_nested_str_weak(remote_port), + /* K43 */ be_nested_str_weak(add_session), + /* K44 */ be_nested_str_weak(future_local_session_id), + /* K45 */ be_nested_str_weak(future_initiator_session_id), }), be_str_weak(parse_Pake3), &be_const_str_solidified, @@ -2158,123 +2130,123 @@ be_local_closure(Matter_Commisioning_Context_parse_Pake3, /* name */ 0x8C180D10, // 0018 GETMET R6 R6 K16 0x7C180200, // 0019 CALL R6 1 0x001A1E06, // 001A ADD R6 K15 R6 - 0x581C0011, // 001B LDCONST R7 K17 + 0x541E0003, // 001B LDINT R7 4 0x7C100600, // 001C CALL R4 3 0x8810010C, // 001D GETMBR R4 R0 K12 - 0x88140112, // 001E GETMBR R5 R0 K18 + 0x88140111, // 001E GETMBR R5 R0 K17 0x88140B0C, // 001F GETMBR R5 R5 K12 0x20100805, // 0020 NE R4 R4 R5 0x78120000, // 0021 JMPF R4 #0023 - 0xB0060B13, // 0022 RAISE 1 K5 K19 + 0xB0060B12, // 0022 RAISE 1 K5 K18 0xB8121A00, // 0023 GETNGBL R4 K13 - 0x8C100915, // 0024 GETMET R4 R4 K21 + 0x8C100914, // 0024 GETMET R4 R4 K20 0x7C100200, // 0025 CALL R4 1 - 0x94100916, // 0026 GETIDX R4 R4 K22 - 0x90022804, // 0027 SETMBR R0 K20 R4 - 0x8C100517, // 0028 GETMET R4 R2 K23 + 0x94100915, // 0026 GETIDX R4 R4 K21 + 0x90022604, // 0027 SETMBR R0 K19 R4 + 0x8C100516, // 0028 GETMET R4 R2 K22 0x7C100200, // 0029 CALL R4 1 - 0x8C100918, // 002A GETMET R4 R4 K24 - 0x88180119, // 002B GETMBR R6 R0 K25 + 0x8C100917, // 002A GETMET R4 R4 K23 + 0x88180118, // 002B GETMBR R6 R0 K24 0x601C0015, // 002C GETGBL R7 G21 0x7C1C0000, // 002D CALL R7 0 0x60200015, // 002E GETGBL R8 G21 0x7C200000, // 002F CALL R8 0 - 0x8C20111A, // 0030 GETMET R8 R8 K26 - 0x8828011B, // 0031 GETMBR R10 R0 K27 + 0x8C201119, // 0030 GETMET R8 R8 K25 + 0x8828011A, // 0031 GETMBR R10 R0 K26 0x7C200400, // 0032 CALL R8 2 0x5426002F, // 0033 LDINT R9 48 0x7C100A00, // 0034 CALL R4 5 0x5416000E, // 0035 LDINT R5 15 0x40160605, // 0036 CONNECT R5 K3 R5 0x94140805, // 0037 GETIDX R5 R4 R5 - 0x90023805, // 0038 SETMBR R0 K28 R5 + 0x90023605, // 0038 SETMBR R0 K27 R5 0x5416000F, // 0039 LDINT R5 16 0x541A001E, // 003A LDINT R6 31 0x40140A06, // 003B CONNECT R5 R5 R6 0x94140805, // 003C GETIDX R5 R4 R5 - 0x90023A05, // 003D SETMBR R0 K29 R5 + 0x90023805, // 003D SETMBR R0 K28 R5 0x5416001F, // 003E LDINT R5 32 0x541A002E, // 003F LDINT R6 47 0x40140A06, // 0040 CONNECT R5 R5 R6 0x94140805, // 0041 GETIDX R5 R4 R5 - 0x90023C05, // 0042 SETMBR R0 K30 R5 + 0x90023A05, // 0042 SETMBR R0 K29 R5 0xB8161A00, // 0043 GETNGBL R5 K13 0x8C140B0E, // 0044 GETMET R5 R5 K14 - 0x581C001F, // 0045 LDCONST R7 K31 - 0x58200011, // 0046 LDCONST R8 K17 + 0x581C001E, // 0045 LDCONST R7 K30 + 0x54220003, // 0046 LDINT R8 4 0x7C140600, // 0047 CALL R5 3 0xB8161A00, // 0048 GETNGBL R5 K13 0x8C140B0E, // 0049 GETMET R5 R5 K14 0x8C1C0910, // 004A GETMET R7 R4 K16 0x7C1C0200, // 004B CALL R7 1 - 0x001E4007, // 004C ADD R7 K32 R7 - 0x58200011, // 004D LDCONST R8 K17 + 0x001E3E07, // 004C ADD R7 K31 R7 + 0x54220003, // 004D LDINT R8 4 0x7C140600, // 004E CALL R5 3 0xB8161A00, // 004F GETNGBL R5 K13 0x8C140B0E, // 0050 GETMET R5 R5 K14 - 0x881C011C, // 0051 GETMBR R7 R0 K28 + 0x881C011B, // 0051 GETMBR R7 R0 K27 0x8C1C0F10, // 0052 GETMET R7 R7 K16 0x7C1C0200, // 0053 CALL R7 1 - 0x001E4207, // 0054 ADD R7 K33 R7 - 0x58200011, // 0055 LDCONST R8 K17 + 0x001E4007, // 0054 ADD R7 K32 R7 + 0x54220003, // 0055 LDINT R8 4 0x7C140600, // 0056 CALL R5 3 0xB8161A00, // 0057 GETNGBL R5 K13 0x8C140B0E, // 0058 GETMET R5 R5 K14 - 0x881C011D, // 0059 GETMBR R7 R0 K29 + 0x881C011C, // 0059 GETMBR R7 R0 K28 0x8C1C0F10, // 005A GETMET R7 R7 K16 0x7C1C0200, // 005B CALL R7 1 - 0x001E4407, // 005C ADD R7 K34 R7 - 0x58200011, // 005D LDCONST R8 K17 + 0x001E4207, // 005C ADD R7 K33 R7 + 0x54220003, // 005D LDINT R8 4 0x7C140600, // 005E CALL R5 3 0xB8161A00, // 005F GETNGBL R5 K13 0x8C140B0E, // 0060 GETMET R5 R5 K14 - 0x881C011E, // 0061 GETMBR R7 R0 K30 + 0x881C011D, // 0061 GETMBR R7 R0 K29 0x8C1C0F10, // 0062 GETMET R7 R7 K16 0x7C1C0200, // 0063 CALL R7 1 - 0x001E4607, // 0064 ADD R7 K35 R7 - 0x58200011, // 0065 LDCONST R8 K17 + 0x001E4407, // 0064 ADD R7 K34 R7 + 0x54220003, // 0065 LDINT R8 4 0x7C140600, // 0066 CALL R5 3 0xB8161A00, // 0067 GETNGBL R5 K13 0x8C140B0E, // 0068 GETMET R5 R5 K14 - 0x581C001F, // 0069 LDCONST R7 K31 - 0x58200011, // 006A LDCONST R8 K17 + 0x581C001E, // 0069 LDCONST R7 K30 + 0x54220003, // 006A LDINT R8 4 0x7C140600, // 006B CALL R5 3 - 0x8C140324, // 006C GETMET R5 R1 K36 + 0x8C140323, // 006C GETMET R5 R1 K35 0x541E003F, // 006D LDINT R7 64 0x50200000, // 006E LDBOOL R8 0 0 0x7C140600, // 006F CALL R5 3 0x60180015, // 0070 GETGBL R6 G21 0x7C180000, // 0071 CALL R6 0 - 0x8C1C0D25, // 0072 GETMET R7 R6 K37 + 0x8C1C0D24, // 0072 GETMET R7 R6 K36 0x58240003, // 0073 LDCONST R9 K3 - 0x58280026, // 0074 LDCONST R10 K38 + 0x58280025, // 0074 LDCONST R10 K37 0x7C1C0600, // 0075 CALL R7 3 - 0x8C1C0D25, // 0076 GETMET R7 R6 K37 + 0x8C1C0D24, // 0076 GETMET R7 R6 K36 0x58240003, // 0077 LDCONST R9 K3 0x542A0003, // 0078 LDINT R10 4 0x7C1C0600, // 0079 CALL R7 3 - 0x8C1C0D25, // 007A GETMET R7 R6 K37 + 0x8C1C0D24, // 007A GETMET R7 R6 K36 0x58240003, // 007B LDCONST R9 K3 0x542A0003, // 007C LDINT R10 4 0x7C1C0600, // 007D CALL R7 3 - 0x8C1C0B27, // 007E GETMET R7 R5 K39 + 0x8C1C0B26, // 007E GETMET R7 R5 K38 0x5C240C00, // 007F MOVE R9 R6 0x7C1C0400, // 0080 CALL R7 2 - 0x88200128, // 0081 GETMBR R8 R0 K40 - 0x8C201129, // 0082 GETMET R8 R8 K41 + 0x88200127, // 0081 GETMBR R8 R0 K39 + 0x8C201128, // 0082 GETMET R8 R8 K40 0x5C280E00, // 0083 MOVE R10 R7 - 0x882C032A, // 0084 GETMBR R11 R1 K42 - 0x8830032B, // 0085 GETMBR R12 R1 K43 + 0x882C0329, // 0084 GETMBR R11 R1 K41 + 0x8830032A, // 0085 GETMBR R12 R1 K42 0x4C340000, // 0086 LDNIL R13 0x7C200A00, // 0087 CALL R8 5 - 0x88200128, // 0088 GETMBR R8 R0 K40 - 0x8C20112C, // 0089 GETMET R8 R8 K44 - 0x8828012D, // 008A GETMBR R10 R0 K45 - 0x882C012E, // 008B GETMBR R11 R0 K46 - 0x8830011C, // 008C GETMBR R12 R0 K28 - 0x8834011D, // 008D GETMBR R13 R0 K29 - 0x8838011E, // 008E GETMBR R14 R0 K30 - 0x883C0114, // 008F GETMBR R15 R0 K20 + 0x88200127, // 0088 GETMBR R8 R0 K39 + 0x8C20112B, // 0089 GETMET R8 R8 K43 + 0x8828012C, // 008A GETMBR R10 R0 K44 + 0x882C012D, // 008B GETMBR R11 R0 K45 + 0x8830011B, // 008C GETMBR R12 R0 K27 + 0x8834011C, // 008D GETMBR R13 R0 K28 + 0x8838011D, // 008E GETMBR R14 R0 K29 + 0x883C0113, // 008F GETMBR R15 R0 K19 0x7C200E00, // 0090 CALL R8 7 0x80000000, // 0091 RET 0 }) diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning_Data.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning_Data.h index 2c2bb647a..e86db07ca 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning_Data.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning_Data.h @@ -270,7 +270,7 @@ be_local_closure(Matter_Pake1_parse, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[11]) { /* constants */ + ( &(const bvalue[10]) { /* constants */ /* K0 */ be_const_int(0), /* K1 */ be_nested_str_weak(matter), /* K2 */ be_nested_str_weak(TLV), @@ -278,10 +278,9 @@ be_local_closure(Matter_Pake1_parse, /* name */ /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), /* K6 */ be_nested_str_weak(MTR_X3A_X20parsed_X20TLV_X3A_X20), - /* K7 */ be_const_int(3), - /* K8 */ be_nested_str_weak(pA), - /* K9 */ be_nested_str_weak(getsubval), - /* K10 */ be_const_int(1), + /* K7 */ be_nested_str_weak(pA), + /* K8 */ be_nested_str_weak(getsubval), + /* K9 */ be_const_int(1), }), be_str_weak(parse), &be_const_str_solidified, @@ -302,12 +301,12 @@ be_local_closure(Matter_Pake1_parse, /* name */ 0x5C1C0600, // 000D MOVE R7 R3 0x7C180200, // 000E CALL R6 1 0x001A0C06, // 000F ADD R6 K6 R6 - 0x581C0007, // 0010 LDCONST R7 K7 + 0x541E0003, // 0010 LDINT R7 4 0x7C100600, // 0011 CALL R4 3 - 0x8C100709, // 0012 GETMET R4 R3 K9 - 0x5818000A, // 0013 LDCONST R6 K10 + 0x8C100708, // 0012 GETMET R4 R3 K8 + 0x58180009, // 0013 LDCONST R6 K9 0x7C100400, // 0014 CALL R4 2 - 0x90021004, // 0015 SETMBR R0 K8 R4 + 0x90020E04, // 0015 SETMBR R0 K7 R4 0x80040000, // 0016 RET 1 R0 }) ) @@ -430,7 +429,7 @@ be_local_closure(Matter_Pake3_parse, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[11]) { /* constants */ + ( &(const bvalue[10]) { /* constants */ /* K0 */ be_const_int(0), /* K1 */ be_nested_str_weak(matter), /* K2 */ be_nested_str_weak(TLV), @@ -438,10 +437,9 @@ be_local_closure(Matter_Pake3_parse, /* name */ /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), /* K6 */ be_nested_str_weak(MTR_X3A_X20parsed_X20TLV_X3A_X20), - /* K7 */ be_const_int(3), - /* K8 */ be_nested_str_weak(cA), - /* K9 */ be_nested_str_weak(getsubval), - /* K10 */ be_const_int(1), + /* K7 */ be_nested_str_weak(cA), + /* K8 */ be_nested_str_weak(getsubval), + /* K9 */ be_const_int(1), }), be_str_weak(parse), &be_const_str_solidified, @@ -462,12 +460,12 @@ be_local_closure(Matter_Pake3_parse, /* name */ 0x5C1C0600, // 000D MOVE R7 R3 0x7C180200, // 000E CALL R6 1 0x001A0C06, // 000F ADD R6 K6 R6 - 0x581C0007, // 0010 LDCONST R7 K7 + 0x541E0003, // 0010 LDINT R7 4 0x7C100600, // 0011 CALL R4 3 - 0x8C100709, // 0012 GETMET R4 R3 K9 - 0x5818000A, // 0013 LDCONST R6 K10 + 0x8C100708, // 0012 GETMET R4 R3 K8 + 0x58180009, // 0013 LDCONST R6 K9 0x7C100400, // 0014 CALL R4 2 - 0x90021004, // 0015 SETMBR R0 K8 R4 + 0x90020E04, // 0015 SETMBR R0 K7 R4 0x80040000, // 0016 RET 1 R0 }) ) @@ -521,13 +519,13 @@ be_local_closure(Matter_Sigma1_parse, /* name */ /* K6 */ be_nested_str_weak(tasmota), /* K7 */ be_nested_str_weak(log), /* K8 */ be_nested_str_weak(MTR_X3A_X20Sigma1_X20TLV_X3D), - /* K9 */ be_const_int(3), - /* K10 */ be_nested_str_weak(initiatorRandom), - /* K11 */ be_nested_str_weak(getsubval), - /* K12 */ be_const_int(1), - /* K13 */ be_nested_str_weak(initiator_session_id), - /* K14 */ be_const_int(2), - /* K15 */ be_nested_str_weak(destinationId), + /* K9 */ be_nested_str_weak(initiatorRandom), + /* K10 */ be_nested_str_weak(getsubval), + /* K11 */ be_const_int(1), + /* K12 */ be_nested_str_weak(initiator_session_id), + /* K13 */ be_const_int(2), + /* K14 */ be_nested_str_weak(destinationId), + /* K15 */ be_const_int(3), /* K16 */ be_nested_str_weak(initiatorEphPubKey), /* K17 */ be_nested_str_weak(findsub), /* K18 */ be_nested_str_weak(SLEEPY_IDLE_INTERVAL), @@ -556,21 +554,21 @@ be_local_closure(Matter_Sigma1_parse, /* name */ 0x5C1C0600, // 0010 MOVE R7 R3 0x7C180200, // 0011 CALL R6 1 0x001A1006, // 0012 ADD R6 K8 R6 - 0x581C0009, // 0013 LDCONST R7 K9 + 0x541E0003, // 0013 LDINT R7 4 0x7C100600, // 0014 CALL R4 3 - 0x8C10070B, // 0015 GETMET R4 R3 K11 - 0x5818000C, // 0016 LDCONST R6 K12 + 0x8C10070A, // 0015 GETMET R4 R3 K10 + 0x5818000B, // 0016 LDCONST R6 K11 0x7C100400, // 0017 CALL R4 2 - 0x90021404, // 0018 SETMBR R0 K10 R4 - 0x8C10070B, // 0019 GETMET R4 R3 K11 - 0x5818000E, // 001A LDCONST R6 K14 + 0x90021204, // 0018 SETMBR R0 K9 R4 + 0x8C10070A, // 0019 GETMET R4 R3 K10 + 0x5818000D, // 001A LDCONST R6 K13 0x7C100400, // 001B CALL R4 2 - 0x90021A04, // 001C SETMBR R0 K13 R4 - 0x8C10070B, // 001D GETMET R4 R3 K11 - 0x58180009, // 001E LDCONST R6 K9 + 0x90021804, // 001C SETMBR R0 K12 R4 + 0x8C10070A, // 001D GETMET R4 R3 K10 + 0x5818000F, // 001E LDCONST R6 K15 0x7C100400, // 001F CALL R4 2 - 0x90021E04, // 0020 SETMBR R0 K15 R4 - 0x8C10070B, // 0021 GETMET R4 R3 K11 + 0x90021C04, // 0020 SETMBR R0 K14 R4 + 0x8C10070A, // 0021 GETMET R4 R3 K10 0x541A0003, // 0022 LDINT R6 4 0x7C100400, // 0023 CALL R4 2 0x90022004, // 0024 SETMBR R0 K16 R4 @@ -581,11 +579,11 @@ be_local_closure(Matter_Sigma1_parse, /* name */ 0x20140805, // 0029 NE R5 R4 R5 0x78160007, // 002A JMPF R5 #0033 0x8C140913, // 002B GETMET R5 R4 K19 - 0x581C000C, // 002C LDCONST R7 K12 + 0x581C000B, // 002C LDCONST R7 K11 0x7C140400, // 002D CALL R5 2 0x90022405, // 002E SETMBR R0 K18 R5 0x8C140913, // 002F GETMET R5 R4 K19 - 0x581C000E, // 0030 LDCONST R7 K14 + 0x581C000D, // 0030 LDCONST R7 K13 0x7C140400, // 0031 CALL R5 2 0x90022805, // 0032 SETMBR R0 K20 R5 0x8C140711, // 0033 GETMET R5 R3 K17 @@ -895,7 +893,7 @@ be_local_closure(Matter_Sigma3_parse, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[13]) { /* constants */ + ( &(const bvalue[12]) { /* constants */ /* K0 */ be_const_int(0), /* K1 */ be_nested_str_weak(matter), /* K2 */ be_nested_str_weak(TLV), @@ -905,10 +903,9 @@ be_local_closure(Matter_Sigma3_parse, /* name */ /* K6 */ be_nested_str_weak(tasmota), /* K7 */ be_nested_str_weak(log), /* K8 */ be_nested_str_weak(MTR_X3A_X20Sigma3_X20TLV_X3D), - /* K9 */ be_const_int(3), - /* K10 */ be_nested_str_weak(TBEData3Encrypted), - /* K11 */ be_nested_str_weak(getsubval), - /* K12 */ be_const_int(1), + /* K9 */ be_nested_str_weak(TBEData3Encrypted), + /* K10 */ be_nested_str_weak(getsubval), + /* K11 */ be_const_int(1), }), be_str_weak(parse), &be_const_str_solidified, @@ -932,12 +929,12 @@ be_local_closure(Matter_Sigma3_parse, /* name */ 0x5C1C0600, // 0010 MOVE R7 R3 0x7C180200, // 0011 CALL R6 1 0x001A1006, // 0012 ADD R6 K8 R6 - 0x581C0009, // 0013 LDCONST R7 K9 + 0x541E0003, // 0013 LDINT R7 4 0x7C100600, // 0014 CALL R4 3 - 0x8C10070B, // 0015 GETMET R4 R3 K11 - 0x5818000C, // 0016 LDCONST R6 K12 + 0x8C10070A, // 0015 GETMET R4 R3 K10 + 0x5818000B, // 0016 LDCONST R6 K11 0x7C100400, // 0017 CALL R4 2 - 0x90021404, // 0018 SETMBR R0 K10 R4 + 0x90021204, // 0018 SETMBR R0 K9 R4 0x80040000, // 0019 RET 1 R0 }) ) diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Device.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Device.h index b52678302..7bdc6998d 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Device.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Device.h @@ -6,898 +6,6 @@ extern const bclass be_class_Matter_Device; -/******************************************************************** -** Solidified function: compute_manual_pairing_code -********************************************************************/ -be_local_closure(Matter_Device_compute_manual_pairing_code, /* name */ - be_nested_proto( - 11, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 8]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(discriminator), - /* K2 */ be_nested_str_weak(passcode), - /* K3 */ be_nested_str_weak(format), - /* K4 */ be_nested_str_weak(_X251i_X2505i_X2504i), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(Verhoeff), - /* K7 */ be_nested_str_weak(checksum), - }), - be_str_weak(compute_manual_pairing_code), - &be_const_str_solidified, - ( &(const binstruction[31]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x88080101, // 0001 GETMBR R2 R0 K1 - 0x540E0FFE, // 0002 LDINT R3 4095 - 0x2C080403, // 0003 AND R2 R2 R3 - 0x540E0009, // 0004 LDINT R3 10 - 0x3C080403, // 0005 SHR R2 R2 R3 - 0x880C0101, // 0006 GETMBR R3 R0 K1 - 0x541202FF, // 0007 LDINT R4 768 - 0x2C0C0604, // 0008 AND R3 R3 R4 - 0x54120005, // 0009 LDINT R4 6 - 0x380C0604, // 000A SHL R3 R3 R4 - 0x88100102, // 000B GETMBR R4 R0 K2 - 0x54163FFE, // 000C LDINT R5 16383 - 0x2C100805, // 000D AND R4 R4 R5 - 0x300C0604, // 000E OR R3 R3 R4 - 0x88100102, // 000F GETMBR R4 R0 K2 - 0x5416000D, // 0010 LDINT R5 14 - 0x3C100805, // 0011 SHR R4 R4 R5 - 0x8C140303, // 0012 GETMET R5 R1 K3 - 0x581C0004, // 0013 LDCONST R7 K4 - 0x5C200400, // 0014 MOVE R8 R2 - 0x5C240600, // 0015 MOVE R9 R3 - 0x5C280800, // 0016 MOVE R10 R4 - 0x7C140A00, // 0017 CALL R5 5 - 0xB81A0A00, // 0018 GETNGBL R6 K5 - 0x88180D06, // 0019 GETMBR R6 R6 K6 - 0x8C180D07, // 001A GETMET R6 R6 K7 - 0x5C200A00, // 001B MOVE R8 R5 - 0x7C180400, // 001C CALL R6 2 - 0x00140A06, // 001D ADD R5 R5 R6 - 0x80040A00, // 001E RET 1 R5 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: process_attribute_expansion -********************************************************************/ -be_local_closure(Matter_Device_process_attribute_expansion, /* name */ - be_nested_proto( - 33, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[25]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(endpoint), - /* K2 */ be_nested_str_weak(cluster), - /* K3 */ be_nested_str_weak(attribute), - /* K4 */ be_nested_str_weak(tasmota), - /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(format), - /* K7 */ be_nested_str_weak(MTR_X3A_X20process_attribute_expansion_X20_X25s), - /* K8 */ be_const_int(3), - /* K9 */ be_nested_str_weak(plugins), - /* K10 */ be_nested_str_weak(get_endpoints), - /* K11 */ be_nested_str_weak(MTR_X3A_X20ep_list_X20_X25s_X20_X25s), - /* K12 */ be_nested_str_weak(find), - /* K13 */ be_nested_str_weak(get_cluster_list), - /* K14 */ be_nested_str_weak(MTR_X3A_X20cluster_list_X20_X25s_X20_X25s), - /* K15 */ be_nested_str_weak(get_attribute_list), - /* K16 */ be_nested_str_weak(MTR_X3A_X20attr_list_X20_X25s_X20_X25s), - /* K17 */ be_nested_str_weak(MTR_X3A_X20expansion_X20_X5B_X2502X_X5D_X2504X_X2F_X2504X), - /* K18 */ be_nested_str_weak(stop_iteration), - /* K19 */ be_nested_str_weak(status), - /* K20 */ be_nested_str_weak(matter), - /* K21 */ be_nested_str_weak(UNSUPPORTED_ENDPOINT), - /* K22 */ be_nested_str_weak(UNSUPPORTED_CLUSTER), - /* K23 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), - /* K24 */ be_nested_str_weak(UNREPORTABLE_ATTRIBUTE), - }), - be_str_weak(process_attribute_expansion), - &be_const_str_solidified, - ( &(const binstruction[216]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0x88100301, // 0001 GETMBR R4 R1 K1 - 0x60140012, // 0002 GETGBL R5 G18 - 0x7C140000, // 0003 CALL R5 0 - 0x40180A04, // 0004 CONNECT R6 R5 R4 - 0x50180000, // 0005 LDBOOL R6 0 0 - 0x881C0302, // 0006 GETMBR R7 R1 K2 - 0x60200012, // 0007 GETGBL R8 G18 - 0x7C200000, // 0008 CALL R8 0 - 0x40241007, // 0009 CONNECT R9 R8 R7 - 0x50240000, // 000A LDBOOL R9 0 0 - 0x88280303, // 000B GETMBR R10 R1 K3 - 0x602C0012, // 000C GETGBL R11 G18 - 0x7C2C0000, // 000D CALL R11 0 - 0x4030160A, // 000E CONNECT R12 R11 R10 - 0x50300000, // 000F LDBOOL R12 0 0 - 0x88340301, // 0010 GETMBR R13 R1 K1 - 0x4C380000, // 0011 LDNIL R14 - 0x20341A0E, // 0012 NE R13 R13 R14 - 0x78360007, // 0013 JMPF R13 #001C - 0x88340302, // 0014 GETMBR R13 R1 K2 - 0x4C380000, // 0015 LDNIL R14 - 0x20341A0E, // 0016 NE R13 R13 R14 - 0x78360003, // 0017 JMPF R13 #001C - 0x88340303, // 0018 GETMBR R13 R1 K3 - 0x4C380000, // 0019 LDNIL R14 - 0x20341A0E, // 001A NE R13 R13 R14 - 0x74360000, // 001B JMPT R13 #001D - 0x50340001, // 001C LDBOOL R13 0 1 - 0x50340200, // 001D LDBOOL R13 1 0 - 0xB83A0800, // 001E GETNGBL R14 K4 - 0x8C381D05, // 001F GETMET R14 R14 K5 - 0x8C400706, // 0020 GETMET R16 R3 K6 - 0x58480007, // 0021 LDCONST R18 K7 - 0x604C0008, // 0022 GETGBL R19 G8 - 0x5C500200, // 0023 MOVE R20 R1 - 0x7C4C0200, // 0024 CALL R19 1 - 0x7C400600, // 0025 CALL R16 3 - 0x58440008, // 0026 LDCONST R17 K8 - 0x7C380600, // 0027 CALL R14 3 - 0x60380010, // 0028 GETGBL R14 G16 - 0x883C0109, // 0029 GETMBR R15 R0 K9 - 0x7C380200, // 002A CALL R14 1 - 0xA802008C, // 002B EXBLK 0 #00B9 - 0x5C3C1C00, // 002C MOVE R15 R14 - 0x7C3C0000, // 002D CALL R15 0 - 0x8C401F0A, // 002E GETMET R16 R15 K10 - 0x7C400200, // 002F CALL R16 1 - 0xB8460800, // 0030 GETNGBL R17 K4 - 0x8C442305, // 0031 GETMET R17 R17 K5 - 0x8C4C0706, // 0032 GETMET R19 R3 K6 - 0x5854000B, // 0033 LDCONST R21 K11 - 0x60580008, // 0034 GETGBL R22 G8 - 0x5C5C1E00, // 0035 MOVE R23 R15 - 0x7C580200, // 0036 CALL R22 1 - 0x605C0008, // 0037 GETGBL R23 G8 - 0x5C602000, // 0038 MOVE R24 R16 - 0x7C5C0200, // 0039 CALL R23 1 - 0x7C4C0800, // 003A CALL R19 4 - 0x58500008, // 003B LDCONST R20 K8 - 0x7C440600, // 003C CALL R17 3 - 0x4C440000, // 003D LDNIL R17 - 0x20440811, // 003E NE R17 R4 R17 - 0x78460009, // 003F JMPF R17 #004A - 0x8C44210C, // 0040 GETMET R17 R16 K12 - 0x5C4C0800, // 0041 MOVE R19 R4 - 0x7C440400, // 0042 CALL R17 2 - 0x4C480000, // 0043 LDNIL R18 - 0x20442212, // 0044 NE R17 R17 R18 - 0x78460002, // 0045 JMPF R17 #0049 - 0x5C400A00, // 0046 MOVE R16 R5 - 0x50180200, // 0047 LDBOOL R6 1 0 - 0x70020000, // 0048 JMP #004A - 0x7001FFE1, // 0049 JMP #002C - 0x60440010, // 004A GETGBL R17 G16 - 0x5C482000, // 004B MOVE R18 R16 - 0x7C440200, // 004C CALL R17 1 - 0xA8020066, // 004D EXBLK 0 #00B5 - 0x5C482200, // 004E MOVE R18 R17 - 0x7C480000, // 004F CALL R18 0 - 0x8C4C1F0D, // 0050 GETMET R19 R15 K13 - 0x5C542400, // 0051 MOVE R21 R18 - 0x7C4C0400, // 0052 CALL R19 2 - 0xB8520800, // 0053 GETNGBL R20 K4 - 0x8C502905, // 0054 GETMET R20 R20 K5 - 0x8C580706, // 0055 GETMET R22 R3 K6 - 0x5860000E, // 0056 LDCONST R24 K14 - 0x60640008, // 0057 GETGBL R25 G8 - 0x5C682400, // 0058 MOVE R26 R18 - 0x7C640200, // 0059 CALL R25 1 - 0x60680008, // 005A GETGBL R26 G8 - 0x5C6C2600, // 005B MOVE R27 R19 - 0x7C680200, // 005C CALL R26 1 - 0x7C580800, // 005D CALL R22 4 - 0x585C0008, // 005E LDCONST R23 K8 - 0x7C500600, // 005F CALL R20 3 - 0x4C500000, // 0060 LDNIL R20 - 0x20500E14, // 0061 NE R20 R7 R20 - 0x78520009, // 0062 JMPF R20 #006D - 0x8C50270C, // 0063 GETMET R20 R19 K12 - 0x5C580E00, // 0064 MOVE R22 R7 - 0x7C500400, // 0065 CALL R20 2 - 0x4C540000, // 0066 LDNIL R21 - 0x20502815, // 0067 NE R20 R20 R21 - 0x78520002, // 0068 JMPF R20 #006C - 0x5C4C1000, // 0069 MOVE R19 R8 - 0x50240200, // 006A LDBOOL R9 1 0 - 0x70020000, // 006B JMP #006D - 0x7001FFE0, // 006C JMP #004E - 0x60500010, // 006D GETGBL R20 G16 - 0x5C542600, // 006E MOVE R21 R19 - 0x7C500200, // 006F CALL R20 1 - 0xA802003F, // 0070 EXBLK 0 #00B1 - 0x5C542800, // 0071 MOVE R21 R20 - 0x7C540000, // 0072 CALL R21 0 - 0x8C581F0F, // 0073 GETMET R22 R15 K15 - 0x5C602400, // 0074 MOVE R24 R18 - 0x5C640E00, // 0075 MOVE R25 R7 - 0x7C580600, // 0076 CALL R22 3 - 0xB85E0800, // 0077 GETNGBL R23 K4 - 0x8C5C2F05, // 0078 GETMET R23 R23 K5 - 0x8C640706, // 0079 GETMET R25 R3 K6 - 0x586C0010, // 007A LDCONST R27 K16 - 0x60700008, // 007B GETGBL R28 G8 - 0x5C742A00, // 007C MOVE R29 R21 - 0x7C700200, // 007D CALL R28 1 - 0x60740008, // 007E GETGBL R29 G8 - 0x5C782C00, // 007F MOVE R30 R22 - 0x7C740200, // 0080 CALL R29 1 - 0x7C640800, // 0081 CALL R25 4 - 0x58680008, // 0082 LDCONST R26 K8 - 0x7C5C0600, // 0083 CALL R23 3 - 0x4C5C0000, // 0084 LDNIL R23 - 0x205C1417, // 0085 NE R23 R10 R23 - 0x785E0028, // 0086 JMPF R23 #00B0 - 0x8C5C2D0C, // 0087 GETMET R23 R22 K12 - 0x5C641400, // 0088 MOVE R25 R10 - 0x7C5C0400, // 0089 CALL R23 2 - 0x4C600000, // 008A LDNIL R24 - 0x205C2E18, // 008B NE R23 R23 R24 - 0x785E0002, // 008C JMPF R23 #0090 - 0x5C581600, // 008D MOVE R22 R11 - 0x50300200, // 008E LDBOOL R12 1 0 - 0x70020000, // 008F JMP #0091 - 0x7001FFDF, // 0090 JMP #0071 - 0x605C0010, // 0091 GETGBL R23 G16 - 0x5C602C00, // 0092 MOVE R24 R22 - 0x7C5C0200, // 0093 CALL R23 1 - 0xA8020017, // 0094 EXBLK 0 #00AD - 0x5C602E00, // 0095 MOVE R24 R23 - 0x7C600000, // 0096 CALL R24 0 - 0xB8660800, // 0097 GETNGBL R25 K4 - 0x8C643305, // 0098 GETMET R25 R25 K5 - 0x8C6C0706, // 0099 GETMET R27 R3 K6 - 0x58740011, // 009A LDCONST R29 K17 - 0x5C782400, // 009B MOVE R30 R18 - 0x5C7C2A00, // 009C MOVE R31 R21 - 0x5C803000, // 009D MOVE R32 R24 - 0x7C6C0A00, // 009E CALL R27 5 - 0x58700008, // 009F LDCONST R28 K8 - 0x7C640600, // 00A0 CALL R25 3 - 0x90060212, // 00A1 SETMBR R1 K1 R18 - 0x90060415, // 00A2 SETMBR R1 K2 R21 - 0x90060618, // 00A3 SETMBR R1 K3 R24 - 0x5C640400, // 00A4 MOVE R25 R2 - 0x5C681E00, // 00A5 MOVE R26 R15 - 0x5C6C0200, // 00A6 MOVE R27 R1 - 0x5C701A00, // 00A7 MOVE R28 R13 - 0x7C640600, // 00A8 CALL R25 3 - 0x78660001, // 00A9 JMPF R25 #00AC - 0xA8040004, // 00AA EXBLK 1 4 - 0x80003400, // 00AB RET 0 - 0x7001FFE7, // 00AC JMP #0095 - 0x585C0012, // 00AD LDCONST R23 K18 - 0xAC5C0200, // 00AE CATCH R23 1 0 - 0xB0080000, // 00AF RAISE 2 R0 R0 - 0x7001FFBF, // 00B0 JMP #0071 - 0x58500012, // 00B1 LDCONST R20 K18 - 0xAC500200, // 00B2 CATCH R20 1 0 - 0xB0080000, // 00B3 RAISE 2 R0 R0 - 0x7001FF98, // 00B4 JMP #004E - 0x58440012, // 00B5 LDCONST R17 K18 - 0xAC440200, // 00B6 CATCH R17 1 0 - 0xB0080000, // 00B7 RAISE 2 R0 R0 - 0x7001FF72, // 00B8 JMP #002C - 0x58380012, // 00B9 LDCONST R14 K18 - 0xAC380200, // 00BA CATCH R14 1 0 - 0xB0080000, // 00BB RAISE 2 R0 R0 - 0x78360019, // 00BC JMPF R13 #00D7 - 0x5C380C00, // 00BD MOVE R14 R6 - 0x743A0003, // 00BE JMPT R14 #00C3 - 0xB83A2800, // 00BF GETNGBL R14 K20 - 0x88381D15, // 00C0 GETMBR R14 R14 K21 - 0x9006260E, // 00C1 SETMBR R1 K19 R14 - 0x7002000E, // 00C2 JMP #00D2 - 0x5C381200, // 00C3 MOVE R14 R9 - 0x743A0003, // 00C4 JMPT R14 #00C9 - 0xB83A2800, // 00C5 GETNGBL R14 K20 - 0x88381D16, // 00C6 GETMBR R14 R14 K22 - 0x9006260E, // 00C7 SETMBR R1 K19 R14 - 0x70020008, // 00C8 JMP #00D2 - 0x5C381800, // 00C9 MOVE R14 R12 - 0x743A0003, // 00CA JMPT R14 #00CF - 0xB83A2800, // 00CB GETNGBL R14 K20 - 0x88381D17, // 00CC GETMBR R14 R14 K23 - 0x9006260E, // 00CD SETMBR R1 K19 R14 - 0x70020002, // 00CE JMP #00D2 - 0xB83A2800, // 00CF GETNGBL R14 K20 - 0x88381D18, // 00D0 GETMBR R14 R14 K24 - 0x9006260E, // 00D1 SETMBR R1 K19 R14 - 0x5C380400, // 00D2 MOVE R14 R2 - 0x4C3C0000, // 00D3 LDNIL R15 - 0x5C400200, // 00D4 MOVE R16 R1 - 0x50440200, // 00D5 LDBOOL R17 1 0 - 0x7C380600, // 00D6 CALL R14 3 - 0x80000000, // 00D7 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: save_param -********************************************************************/ -be_local_closure(Matter_Device_save_param, /* name */ - be_nested_proto( - 10, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[15]) { /* constants */ - /* K0 */ be_nested_str_weak(json), - /* K1 */ be_nested_str_weak(dump), - /* K2 */ be_nested_str_weak(distinguish), - /* K3 */ be_nested_str_weak(discriminator), - /* K4 */ be_nested_str_weak(passcode), - /* K5 */ be_nested_str_weak(string), - /* K6 */ be_nested_str_weak(FILENAME), - /* K7 */ be_nested_str_weak(w), - /* K8 */ be_nested_str_weak(write), - /* K9 */ be_nested_str_weak(close), - /* K10 */ be_nested_str_weak(tasmota), - /* K11 */ be_nested_str_weak(log), - /* K12 */ be_nested_str_weak(MTR_X3A_X20Session_Store_X3A_X3Asave_X20Exception_X3A), - /* K13 */ be_nested_str_weak(_X7C), - /* K14 */ be_const_int(2), - }), - be_str_weak(save_param), - &be_const_str_solidified, - ( &(const binstruction[43]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x8C080301, // 0001 GETMET R2 R1 K1 - 0x60100013, // 0002 GETGBL R4 G19 - 0x7C100000, // 0003 CALL R4 0 - 0x88140103, // 0004 GETMBR R5 R0 K3 - 0x98120405, // 0005 SETIDX R4 K2 R5 - 0x88140104, // 0006 GETMBR R5 R0 K4 - 0x98120805, // 0007 SETIDX R4 K4 R5 - 0x7C080400, // 0008 CALL R2 2 - 0xA802000D, // 0009 EXBLK 0 #0018 - 0xA40E0A00, // 000A IMPORT R3 K5 - 0x60100011, // 000B GETGBL R4 G17 - 0x88140106, // 000C GETMBR R5 R0 K6 - 0x58180007, // 000D LDCONST R6 K7 - 0x7C100400, // 000E CALL R4 2 - 0x8C140908, // 000F GETMET R5 R4 K8 - 0x5C1C0400, // 0010 MOVE R7 R2 - 0x7C140400, // 0011 CALL R5 2 - 0x8C140909, // 0012 GETMET R5 R4 K9 - 0x7C140200, // 0013 CALL R5 1 - 0xA8040001, // 0014 EXBLK 1 1 - 0x80040400, // 0015 RET 1 R2 - 0xA8040001, // 0016 EXBLK 1 1 - 0x70020011, // 0017 JMP #002A - 0xAC0C0002, // 0018 CATCH R3 0 2 - 0x7002000E, // 0019 JMP #0029 - 0xB8161400, // 001A GETNGBL R5 K10 - 0x8C140B0B, // 001B GETMET R5 R5 K11 - 0x601C0008, // 001C GETGBL R7 G8 - 0x5C200600, // 001D MOVE R8 R3 - 0x7C1C0200, // 001E CALL R7 1 - 0x001E1807, // 001F ADD R7 K12 R7 - 0x001C0F0D, // 0020 ADD R7 R7 K13 - 0x60200008, // 0021 GETGBL R8 G8 - 0x5C240800, // 0022 MOVE R9 R4 - 0x7C200200, // 0023 CALL R8 1 - 0x001C0E08, // 0024 ADD R7 R7 R8 - 0x5820000E, // 0025 LDCONST R8 K14 - 0x7C140600, // 0026 CALL R5 3 - 0x80040400, // 0027 RET 1 R2 - 0x70020000, // 0028 JMP #002A - 0xB0080000, // 0029 RAISE 2 R0 R0 - 0x80000000, // 002A RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: start_udp -********************************************************************/ -be_local_closure(Matter_Device_start_udp, /* name */ - be_nested_proto( - 6, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 1, /* has sup protos */ - ( &(const struct bproto*[ 1]) { - be_nested_proto( - 8, /* nstack */ - 3, /* argc */ - 0, /* varg */ - 1, /* has upvals */ - ( &(const bupvaldesc[ 1]) { /* upvals */ - be_local_const_upval(1, 0), - }), - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(msg_received), - }), - be_str_weak(_X3Clambda_X3E), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x680C0000, // 0000 GETUPV R3 U0 - 0x8C0C0700, // 0001 GETMET R3 R3 K0 - 0x5C140000, // 0002 MOVE R5 R0 - 0x5C180200, // 0003 MOVE R6 R1 - 0x5C1C0400, // 0004 MOVE R7 R2 - 0x7C0C0800, // 0005 CALL R3 4 - 0x80040600, // 0006 RET 1 R3 - }) - ), - }), - 1, /* has constants */ - ( &(const bvalue[ 9]) { /* constants */ - /* K0 */ be_nested_str_weak(udp_server), - /* K1 */ be_nested_str_weak(tasmota), - /* K2 */ be_nested_str_weak(log), - /* K3 */ be_nested_str_weak(MTR_X3A_X20starting_X20UDP_X20server_X20on_X20port_X3A_X20), - /* K4 */ be_const_int(2), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(UDPServer), - /* K7 */ be_nested_str_weak(), - /* K8 */ be_nested_str_weak(start), - }), - be_str_weak(start_udp), - &be_const_str_solidified, - ( &(const binstruction[27]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x780A0000, // 0001 JMPF R2 #0003 - 0x80000400, // 0002 RET 0 - 0x4C080000, // 0003 LDNIL R2 - 0x1C080202, // 0004 EQ R2 R1 R2 - 0x780A0000, // 0005 JMPF R2 #0007 - 0x540615A3, // 0006 LDINT R1 5540 - 0xB80A0200, // 0007 GETNGBL R2 K1 - 0x8C080502, // 0008 GETMET R2 R2 K2 - 0x60100008, // 0009 GETGBL R4 G8 - 0x5C140200, // 000A MOVE R5 R1 - 0x7C100200, // 000B CALL R4 1 - 0x00120604, // 000C ADD R4 K3 R4 - 0x58140004, // 000D LDCONST R5 K4 - 0x7C080600, // 000E CALL R2 3 - 0xB80A0A00, // 000F GETNGBL R2 K5 - 0x8C080506, // 0010 GETMET R2 R2 K6 - 0x58100007, // 0011 LDCONST R4 K7 - 0x5C140200, // 0012 MOVE R5 R1 - 0x7C080600, // 0013 CALL R2 3 - 0x90020002, // 0014 SETMBR R0 K0 R2 - 0x88080100, // 0015 GETMBR R2 R0 K0 - 0x8C080508, // 0016 GETMET R2 R2 K8 - 0x84100000, // 0017 CLOSURE R4 P0 - 0x7C080400, // 0018 CALL R2 2 - 0xA0000000, // 0019 CLOSE R0 - 0x80000000, // 001A RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: load_param -********************************************************************/ -be_local_closure(Matter_Device_load_param, /* name */ - be_nested_proto( - 10, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[22]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(crypto), - /* K2 */ be_nested_str_weak(FILENAME), - /* K3 */ be_nested_str_weak(read), - /* K4 */ be_nested_str_weak(close), - /* K5 */ be_nested_str_weak(json), - /* K6 */ be_nested_str_weak(load), - /* K7 */ be_nested_str_weak(discriminator), - /* K8 */ be_nested_str_weak(find), - /* K9 */ be_nested_str_weak(distinguish), - /* K10 */ be_nested_str_weak(passcode), - /* K11 */ be_nested_str_weak(io_error), - /* K12 */ be_nested_str_weak(tasmota), - /* K13 */ be_nested_str_weak(log), - /* K14 */ be_nested_str_weak(MTR_X3A_X20Session_Store_X3A_X3Aload_X20Exception_X3A), - /* K15 */ be_nested_str_weak(_X7C), - /* K16 */ be_const_int(2), - /* K17 */ be_nested_str_weak(random), - /* K18 */ be_nested_str_weak(get), - /* K19 */ be_const_int(0), - /* K20 */ be_nested_str_weak(PASSCODE_DEFAULT), - /* K21 */ be_nested_str_weak(save_param), - }), - be_str_weak(load_param), - &be_const_str_solidified, - ( &(const binstruction[70]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0xA40A0200, // 0001 IMPORT R2 K1 - 0xA8020014, // 0002 EXBLK 0 #0018 - 0x600C0011, // 0003 GETGBL R3 G17 - 0x88100102, // 0004 GETMBR R4 R0 K2 - 0x7C0C0200, // 0005 CALL R3 1 - 0x8C100703, // 0006 GETMET R4 R3 K3 - 0x7C100200, // 0007 CALL R4 1 - 0x8C140704, // 0008 GETMET R5 R3 K4 - 0x7C140200, // 0009 CALL R5 1 - 0xA4160A00, // 000A IMPORT R5 K5 - 0x8C180B06, // 000B GETMET R6 R5 K6 - 0x5C200800, // 000C MOVE R8 R4 - 0x7C180400, // 000D CALL R6 2 - 0x8C1C0D08, // 000E GETMET R7 R6 K8 - 0x58240009, // 000F LDCONST R9 K9 - 0x7C1C0400, // 0010 CALL R7 2 - 0x90020E07, // 0011 SETMBR R0 K7 R7 - 0x8C1C0D08, // 0012 GETMET R7 R6 K8 - 0x5824000A, // 0013 LDCONST R9 K10 - 0x7C1C0400, // 0014 CALL R7 2 - 0x90021407, // 0015 SETMBR R0 K10 R7 - 0xA8040001, // 0016 EXBLK 1 1 - 0x70020012, // 0017 JMP #002B - 0xAC0C0002, // 0018 CATCH R3 0 2 - 0x7002000F, // 0019 JMP #002A - 0x2014070B, // 001A NE R5 R3 K11 - 0x7816000C, // 001B JMPF R5 #0029 - 0xB8161800, // 001C GETNGBL R5 K12 - 0x8C140B0D, // 001D GETMET R5 R5 K13 - 0x601C0008, // 001E GETGBL R7 G8 - 0x5C200600, // 001F MOVE R8 R3 - 0x7C1C0200, // 0020 CALL R7 1 - 0x001E1C07, // 0021 ADD R7 K14 R7 - 0x001C0F0F, // 0022 ADD R7 R7 K15 - 0x60200008, // 0023 GETGBL R8 G8 - 0x5C240800, // 0024 MOVE R9 R4 - 0x7C200200, // 0025 CALL R8 1 - 0x001C0E08, // 0026 ADD R7 R7 R8 - 0x58200010, // 0027 LDCONST R8 K16 - 0x7C140600, // 0028 CALL R5 3 - 0x70020000, // 0029 JMP #002B - 0xB0080000, // 002A RAISE 2 R0 R0 - 0x500C0000, // 002B LDBOOL R3 0 0 - 0x88100107, // 002C GETMBR R4 R0 K7 - 0x4C140000, // 002D LDNIL R5 - 0x1C100805, // 002E EQ R4 R4 R5 - 0x7812000A, // 002F JMPF R4 #003B - 0x8C100511, // 0030 GETMET R4 R2 K17 - 0x58180010, // 0031 LDCONST R6 K16 - 0x7C100400, // 0032 CALL R4 2 - 0x8C100912, // 0033 GETMET R4 R4 K18 - 0x58180013, // 0034 LDCONST R6 K19 - 0x581C0010, // 0035 LDCONST R7 K16 - 0x7C100600, // 0036 CALL R4 3 - 0x54160FFE, // 0037 LDINT R5 4095 - 0x2C100805, // 0038 AND R4 R4 R5 - 0x90020E04, // 0039 SETMBR R0 K7 R4 - 0x500C0200, // 003A LDBOOL R3 1 0 - 0x8810010A, // 003B GETMBR R4 R0 K10 - 0x4C140000, // 003C LDNIL R5 - 0x1C100805, // 003D EQ R4 R4 R5 - 0x78120002, // 003E JMPF R4 #0042 - 0x88100114, // 003F GETMBR R4 R0 K20 - 0x90021404, // 0040 SETMBR R0 K10 R4 - 0x500C0200, // 0041 LDBOOL R3 1 0 - 0x780E0001, // 0042 JMPF R3 #0045 - 0x8C100115, // 0043 GETMET R4 R0 K21 - 0x7C100200, // 0044 CALL R4 1 - 0x80000000, // 0045 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: start_operational_dicovery_deferred -********************************************************************/ -be_local_closure(Matter_Device_start_operational_dicovery_deferred, /* name */ - be_nested_proto( - 6, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 1, /* has sup protos */ - ( &(const struct bproto*[ 1]) { - be_nested_proto( - 3, /* nstack */ - 0, /* argc */ - 0, /* varg */ - 1, /* has upvals */ - ( &(const bupvaldesc[ 2]) { /* upvals */ - be_local_const_upval(1, 0), - be_local_const_upval(1, 1), - }), - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(start_operational_dicovery), - }), - be_str_weak(_X3Clambda_X3E), - &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x68000000, // 0000 GETUPV R0 U0 - 0x8C000100, // 0001 GETMET R0 R0 K0 - 0x68080001, // 0002 GETUPV R2 U1 - 0x7C000400, // 0003 CALL R0 2 - 0x80040000, // 0004 RET 1 R0 - }) - ), - }), - 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(tasmota), - /* K1 */ be_nested_str_weak(set_timer), - /* K2 */ be_const_int(0), - }), - be_str_weak(start_operational_dicovery_deferred), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0xB80A0000, // 0000 GETNGBL R2 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x58100002, // 0002 LDCONST R4 K2 - 0x84140000, // 0003 CLOSURE R5 P0 - 0x7C080600, // 0004 CALL R2 3 - 0xA0000000, // 0005 CLOSE R0 - 0x80000000, // 0006 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: stop -********************************************************************/ -be_local_closure(Matter_Device_stop, /* name */ - be_nested_proto( - 3, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(udp_server), - /* K1 */ be_nested_str_weak(stop), - }), - be_str_weak(stop), - &be_const_str_solidified, - ( &(const binstruction[ 6]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x78060002, // 0001 JMPF R1 #0005 - 0x88040100, // 0002 GETMBR R1 R0 K0 - 0x8C040301, // 0003 GETMET R1 R1 K1 - 0x7C040200, // 0004 CALL R1 1 - 0x80000000, // 0005 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: invoke_request -********************************************************************/ -be_local_closure(Matter_Device_invoke_request, /* name */ - be_nested_proto( - 11, /* nstack */ - 4, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 7]) { /* constants */ - /* K0 */ be_const_int(0), - /* K1 */ be_nested_str_weak(plugins), - /* K2 */ be_nested_str_weak(invoke_request), - /* K3 */ be_nested_str_weak(status), - /* K4 */ be_nested_str_weak(matter), - /* K5 */ be_nested_str_weak(UNSUPPORTED_COMMAND), - /* K6 */ be_const_int(1), - }), - be_str_weak(invoke_request), - &be_const_str_solidified, - ( &(const binstruction[25]) { /* code */ - 0x58100000, // 0000 LDCONST R4 K0 - 0x6014000C, // 0001 GETGBL R5 G12 - 0x88180101, // 0002 GETMBR R6 R0 K1 - 0x7C140200, // 0003 CALL R5 1 - 0x14140805, // 0004 LT R5 R4 R5 - 0x78160011, // 0005 JMPF R5 #0018 - 0x88140101, // 0006 GETMBR R5 R0 K1 - 0x94140A04, // 0007 GETIDX R5 R5 R4 - 0x8C180B02, // 0008 GETMET R6 R5 K2 - 0x5C200200, // 0009 MOVE R8 R1 - 0x5C240400, // 000A MOVE R9 R2 - 0x5C280600, // 000B MOVE R10 R3 - 0x7C180800, // 000C CALL R6 4 - 0x4C1C0000, // 000D LDNIL R7 - 0x201C0C07, // 000E NE R7 R6 R7 - 0x741E0004, // 000F JMPT R7 #0015 - 0x881C0703, // 0010 GETMBR R7 R3 K3 - 0xB8220800, // 0011 GETNGBL R8 K4 - 0x88201105, // 0012 GETMBR R8 R8 K5 - 0x201C0E08, // 0013 NE R7 R7 R8 - 0x781E0000, // 0014 JMPF R7 #0016 - 0x80040C00, // 0015 RET 1 R6 - 0x00100906, // 0016 ADD R4 R4 K6 - 0x7001FFE8, // 0017 JMP #0001 - 0x80000000, // 0018 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: start_mdns_announce_hostnames -********************************************************************/ -be_local_closure(Matter_Device_start_mdns_announce_hostnames, /* name */ - be_nested_proto( - 6, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 1, /* has sup protos */ - ( &(const struct bproto*[ 2]) { - be_nested_proto( - 4, /* nstack */ - 0, /* argc */ - 0, /* varg */ - 1, /* has upvals */ - ( &(const bupvaldesc[ 1]) { /* upvals */ - be_local_const_upval(1, 0), - }), - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(_start_mdns_announce), - /* K1 */ be_nested_str_weak(tasmota), - /* K2 */ be_nested_str_weak(remove_rule), - /* K3 */ be_nested_str_weak(Wifi_X23Connected), - /* K4 */ be_nested_str_weak(matter_device_mdns), - }), - be_str_weak(_anonymous_), - &be_const_str_solidified, - ( &(const binstruction[10]) { /* code */ - 0x68000000, // 0000 GETUPV R0 U0 - 0x8C000100, // 0001 GETMET R0 R0 K0 - 0x50080000, // 0002 LDBOOL R2 0 0 - 0x7C000400, // 0003 CALL R0 2 - 0xB8020200, // 0004 GETNGBL R0 K1 - 0x8C000102, // 0005 GETMET R0 R0 K2 - 0x58080003, // 0006 LDCONST R2 K3 - 0x580C0004, // 0007 LDCONST R3 K4 - 0x7C000600, // 0008 CALL R0 3 - 0x80000000, // 0009 RET 0 - }) - ), - be_nested_proto( - 4, /* nstack */ - 0, /* argc */ - 0, /* varg */ - 1, /* has upvals */ - ( &(const bupvaldesc[ 1]) { /* upvals */ - be_local_const_upval(1, 0), - }), - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(_start_mdns_announce), - /* K1 */ be_nested_str_weak(tasmota), - /* K2 */ be_nested_str_weak(remove_rule), - /* K3 */ be_nested_str_weak(Eth_X23Connected), - /* K4 */ be_nested_str_weak(matter_device_mdns), - }), - be_str_weak(_anonymous_), - &be_const_str_solidified, - ( &(const binstruction[10]) { /* code */ - 0x68000000, // 0000 GETUPV R0 U0 - 0x8C000100, // 0001 GETMET R0 R0 K0 - 0x50080200, // 0002 LDBOOL R2 1 0 - 0x7C000400, // 0003 CALL R0 2 - 0xB8020200, // 0004 GETNGBL R0 K1 - 0x8C000102, // 0005 GETMET R0 R0 K2 - 0x58080003, // 0006 LDCONST R2 K3 - 0x580C0004, // 0007 LDCONST R3 K4 - 0x7C000600, // 0008 CALL R0 3 - 0x80000000, // 0009 RET 0 - }) - ), - }), - 1, /* has constants */ - ( &(const bvalue[ 8]) { /* constants */ - /* K0 */ be_nested_str_weak(tasmota), - /* K1 */ be_nested_str_weak(wifi), - /* K2 */ be_nested_str_weak(up), - /* K3 */ be_nested_str_weak(_start_mdns_announce), - /* K4 */ be_nested_str_weak(add_rule), - /* K5 */ be_nested_str_weak(Wifi_X23Connected), - /* K6 */ be_nested_str_weak(eth), - /* K7 */ be_nested_str_weak(Eth_X23Connected), - }), - be_str_weak(start_mdns_announce_hostnames), - &be_const_str_solidified, - ( &(const binstruction[32]) { /* code */ - 0xB8060000, // 0000 GETNGBL R1 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x7C040200, // 0002 CALL R1 1 - 0x94040302, // 0003 GETIDX R1 R1 K2 - 0x78060003, // 0004 JMPF R1 #0009 - 0x8C040103, // 0005 GETMET R1 R0 K3 - 0x500C0000, // 0006 LDBOOL R3 0 0 - 0x7C040400, // 0007 CALL R1 2 - 0x70020005, // 0008 JMP #000F - 0xB8060000, // 0009 GETNGBL R1 K0 - 0x8C040304, // 000A GETMET R1 R1 K4 - 0x580C0005, // 000B LDCONST R3 K5 - 0x84100000, // 000C CLOSURE R4 P0 - 0x5C140000, // 000D MOVE R5 R0 - 0x7C040800, // 000E CALL R1 4 - 0xB8060000, // 000F GETNGBL R1 K0 - 0x8C040306, // 0010 GETMET R1 R1 K6 - 0x7C040200, // 0011 CALL R1 1 - 0x94040302, // 0012 GETIDX R1 R1 K2 - 0x78060003, // 0013 JMPF R1 #0018 - 0x8C040103, // 0014 GETMET R1 R0 K3 - 0x500C0200, // 0015 LDBOOL R3 1 0 - 0x7C040400, // 0016 CALL R1 2 - 0x70020005, // 0017 JMP #001E - 0xB8060000, // 0018 GETNGBL R1 K0 - 0x8C040304, // 0019 GETMET R1 R1 K4 - 0x580C0007, // 001A LDCONST R3 K7 - 0x84100001, // 001B CLOSURE R4 P1 - 0x5C140000, // 001C MOVE R5 R0 - 0x7C040800, // 001D CALL R1 4 - 0xA0000000, // 001E CLOSE R0 - 0x80000000, // 001F RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: mdns_announce_op_discovery_all_sessions ********************************************************************/ @@ -949,33 +57,61 @@ be_local_closure(Matter_Device_mdns_announce_op_discovery_all_sessions, /* nam /******************************************************************** -** Solidified function: every_second +** Solidified function: start_operational_dicovery ********************************************************************/ -be_local_closure(Matter_Device_every_second, /* name */ +be_local_closure(Matter_Device_start_operational_dicovery, /* name */ be_nested_proto( - 3, /* nstack */ - 1, /* argc */ + 8, /* nstack */ + 2, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(sessions), - /* K1 */ be_nested_str_weak(every_second), - /* K2 */ be_nested_str_weak(msg_handler), + ( &(const bvalue[13]) { /* constants */ + /* K0 */ be_nested_str_weak(crypto), + /* K1 */ be_nested_str_weak(mdns), + /* K2 */ be_nested_str_weak(string), + /* K3 */ be_nested_str_weak(salt), + /* K4 */ be_nested_str_weak(w0), + /* K5 */ be_nested_str_weak(w1), + /* K6 */ be_nested_str_weak(L), + /* K7 */ be_nested_str_weak(set_no_expiration), + /* K8 */ be_nested_str_weak(set_persist), + /* K9 */ be_nested_str_weak(close), + /* K10 */ be_nested_str_weak(sessions), + /* K11 */ be_nested_str_weak(save), + /* K12 */ be_nested_str_weak(mdns_announce_op_discovery), }), - be_str_weak(every_second), + be_str_weak(start_operational_dicovery), &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x7C040200, // 0002 CALL R1 1 - 0x88040102, // 0003 GETMBR R1 R0 K2 - 0x8C040301, // 0004 GETMET R1 R1 K1 - 0x7C040200, // 0005 CALL R1 1 - 0x80000000, // 0006 RET 0 + ( &(const binstruction[25]) { /* code */ + 0xA40A0000, // 0000 IMPORT R2 K0 + 0xA40E0200, // 0001 IMPORT R3 K1 + 0xA4120400, // 0002 IMPORT R4 K2 + 0x4C140000, // 0003 LDNIL R5 + 0x90020605, // 0004 SETMBR R0 K3 R5 + 0x4C140000, // 0005 LDNIL R5 + 0x90020805, // 0006 SETMBR R0 K4 R5 + 0x4C140000, // 0007 LDNIL R5 + 0x90020A05, // 0008 SETMBR R0 K5 R5 + 0x4C140000, // 0009 LDNIL R5 + 0x90020C05, // 000A SETMBR R0 K6 R5 + 0x8C140307, // 000B GETMET R5 R1 K7 + 0x7C140200, // 000C CALL R5 1 + 0x8C140308, // 000D GETMET R5 R1 K8 + 0x501C0200, // 000E LDBOOL R7 1 0 + 0x7C140400, // 000F CALL R5 2 + 0x8C140309, // 0010 GETMET R5 R1 K9 + 0x7C140200, // 0011 CALL R5 1 + 0x8814010A, // 0012 GETMBR R5 R0 K10 + 0x8C140B0B, // 0013 GETMET R5 R5 K11 + 0x7C140200, // 0014 CALL R5 1 + 0x8C14010C, // 0015 GETMET R5 R0 K12 + 0x5C1C0200, // 0016 MOVE R7 R1 + 0x7C140400, // 0017 CALL R5 2 + 0x80000000, // 0018 RET 0 }) ) ); @@ -1089,12 +225,12 @@ be_local_closure(Matter_Device_init, /* name */ /* K19 */ be_nested_str_weak(sessions), /* K20 */ be_nested_str_weak(Session_Store), /* K21 */ be_nested_str_weak(load), - /* K22 */ be_nested_str_weak(msg_handler), + /* K22 */ be_nested_str_weak(message_handler), /* K23 */ be_nested_str_weak(MessageHandler), /* K24 */ be_nested_str_weak(ui), /* K25 */ be_nested_str_weak(push), - /* K26 */ be_nested_str_weak(Plugin_core), - /* K27 */ be_nested_str_weak(Plugin_Relay), + /* K26 */ be_nested_str_weak(Plugin_Root), + /* K27 */ be_nested_str_weak(Plugin_OnOff), /* K28 */ be_nested_str_weak(start_mdns_announce_hostnames), /* K29 */ be_nested_str_weak(wifi), /* K30 */ be_nested_str_weak(up), @@ -1223,467 +359,6 @@ be_local_closure(Matter_Device_init, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: start_basic_commissioning -********************************************************************/ -be_local_closure(Matter_Device_start_basic_commissioning, /* name */ - be_nested_proto( - 4, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(compute_pbkdf), - /* K1 */ be_nested_str_weak(passcode), - }), - be_str_weak(start_basic_commissioning), - &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ - 0x8C040100, // 0000 GETMET R1 R0 K0 - 0x880C0101, // 0001 GETMBR R3 R0 K1 - 0x7C040400, // 0002 CALL R1 2 - 0x80000000, // 0003 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: start_operational_dicovery -********************************************************************/ -be_local_closure(Matter_Device_start_operational_dicovery, /* name */ - be_nested_proto( - 8, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[13]) { /* constants */ - /* K0 */ be_nested_str_weak(crypto), - /* K1 */ be_nested_str_weak(mdns), - /* K2 */ be_nested_str_weak(string), - /* K3 */ be_nested_str_weak(salt), - /* K4 */ be_nested_str_weak(w0), - /* K5 */ be_nested_str_weak(w1), - /* K6 */ be_nested_str_weak(L), - /* K7 */ be_nested_str_weak(set_no_expiration), - /* K8 */ be_nested_str_weak(set_persist), - /* K9 */ be_nested_str_weak(close), - /* K10 */ be_nested_str_weak(sessions), - /* K11 */ be_nested_str_weak(save), - /* K12 */ be_nested_str_weak(mdns_announce_op_discovery), - }), - be_str_weak(start_operational_dicovery), - &be_const_str_solidified, - ( &(const binstruction[25]) { /* code */ - 0xA40A0000, // 0000 IMPORT R2 K0 - 0xA40E0200, // 0001 IMPORT R3 K1 - 0xA4120400, // 0002 IMPORT R4 K2 - 0x4C140000, // 0003 LDNIL R5 - 0x90020605, // 0004 SETMBR R0 K3 R5 - 0x4C140000, // 0005 LDNIL R5 - 0x90020805, // 0006 SETMBR R0 K4 R5 - 0x4C140000, // 0007 LDNIL R5 - 0x90020A05, // 0008 SETMBR R0 K5 R5 - 0x4C140000, // 0009 LDNIL R5 - 0x90020C05, // 000A SETMBR R0 K6 R5 - 0x8C140307, // 000B GETMET R5 R1 K7 - 0x7C140200, // 000C CALL R5 1 - 0x8C140308, // 000D GETMET R5 R1 K8 - 0x501C0200, // 000E LDBOOL R7 1 0 - 0x7C140400, // 000F CALL R5 2 - 0x8C140309, // 0010 GETMET R5 R1 K9 - 0x7C140200, // 0011 CALL R5 1 - 0x8814010A, // 0012 GETMBR R5 R0 K10 - 0x8C140B0B, // 0013 GETMET R5 R5 K11 - 0x7C140200, // 0014 CALL R5 1 - 0x8C14010C, // 0015 GETMET R5 R0 K12 - 0x5C1C0200, // 0016 MOVE R7 R1 - 0x7C140400, // 0017 CALL R5 2 - 0x80000000, // 0018 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: start_commissioning_complete -********************************************************************/ -be_local_closure(Matter_Device_start_commissioning_complete, /* name */ - be_nested_proto( - 6, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 4]) { /* constants */ - /* K0 */ be_nested_str_weak(tasmota), - /* K1 */ be_nested_str_weak(log), - /* K2 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X20Commissioning_X20complete_X20_X2A_X2A_X2A), - /* K3 */ be_const_int(2), - }), - be_str_weak(start_commissioning_complete), - &be_const_str_solidified, - ( &(const binstruction[ 6]) { /* code */ - 0xB80A0000, // 0000 GETNGBL R2 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x58100002, // 0002 LDCONST R4 K2 - 0x58140003, // 0003 LDCONST R5 K3 - 0x7C080600, // 0004 CALL R2 3 - 0x80000000, // 0005 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: compute_qrcode_content -********************************************************************/ -be_local_closure(Matter_Device_compute_qrcode_content, /* name */ - be_nested_proto( - 8, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[12]) { /* constants */ - /* K0 */ be_nested_str_weak(resize), - /* K1 */ be_nested_str_weak(setbits), - /* K2 */ be_const_int(3), - /* K3 */ be_nested_str_weak(vendorid), - /* K4 */ be_nested_str_weak(productid), - /* K5 */ be_nested_str_weak(discriminator), - /* K6 */ be_nested_str_weak(passcode), - /* K7 */ be_const_int(134217727), - /* K8 */ be_nested_str_weak(MT_X3A), - /* K9 */ be_nested_str_weak(matter), - /* K10 */ be_nested_str_weak(Base38), - /* K11 */ be_nested_str_weak(encode), - }), - be_str_weak(compute_qrcode_content), - &be_const_str_solidified, - ( &(const binstruction[40]) { /* code */ - 0x60040015, // 0000 GETGBL R1 G21 - 0x7C040000, // 0001 CALL R1 0 - 0x8C040300, // 0002 GETMET R1 R1 K0 - 0x540E000A, // 0003 LDINT R3 11 - 0x7C040400, // 0004 CALL R1 2 - 0x8C080301, // 0005 GETMET R2 R1 K1 - 0x58100002, // 0006 LDCONST R4 K2 - 0x5416000F, // 0007 LDINT R5 16 - 0x88180103, // 0008 GETMBR R6 R0 K3 - 0x7C080800, // 0009 CALL R2 4 - 0x8C080301, // 000A GETMET R2 R1 K1 - 0x54120012, // 000B LDINT R4 19 - 0x5416000F, // 000C LDINT R5 16 - 0x88180104, // 000D GETMBR R6 R0 K4 - 0x7C080800, // 000E CALL R2 4 - 0x8C080301, // 000F GETMET R2 R1 K1 - 0x54120024, // 0010 LDINT R4 37 - 0x54160007, // 0011 LDINT R5 8 - 0x541A0003, // 0012 LDINT R6 4 - 0x7C080800, // 0013 CALL R2 4 - 0x8C080301, // 0014 GETMET R2 R1 K1 - 0x5412002C, // 0015 LDINT R4 45 - 0x5416000B, // 0016 LDINT R5 12 - 0x88180105, // 0017 GETMBR R6 R0 K5 - 0x541E0FFE, // 0018 LDINT R7 4095 - 0x2C180C07, // 0019 AND R6 R6 R7 - 0x7C080800, // 001A CALL R2 4 - 0x8C080301, // 001B GETMET R2 R1 K1 - 0x54120038, // 001C LDINT R4 57 - 0x5416001A, // 001D LDINT R5 27 - 0x88180106, // 001E GETMBR R6 R0 K6 - 0x2C180D07, // 001F AND R6 R6 K7 - 0x7C080800, // 0020 CALL R2 4 - 0xB80A1200, // 0021 GETNGBL R2 K9 - 0x8808050A, // 0022 GETMBR R2 R2 K10 - 0x8C08050B, // 0023 GETMET R2 R2 K11 - 0x5C100200, // 0024 MOVE R4 R1 - 0x7C080400, // 0025 CALL R2 2 - 0x000A1002, // 0026 ADD R2 K8 R2 - 0x80040400, // 0027 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: finish_commissioning -********************************************************************/ -be_local_closure(Matter_Device_finish_commissioning, /* name */ - be_nested_proto( - 1, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 0, /* has constants */ - NULL, /* no const */ - be_str_weak(finish_commissioning), - &be_const_str_solidified, - ( &(const binstruction[ 1]) { /* code */ - 0x80000000, // 0000 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: mdns_announce_op_discovery -********************************************************************/ -be_local_closure(Matter_Device_mdns_announce_op_discovery, /* name */ - be_nested_proto( - 15, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[29]) { /* constants */ - /* K0 */ be_nested_str_weak(mdns), - /* K1 */ be_nested_str_weak(string), - /* K2 */ be_nested_str_weak(get_deviceid), - /* K3 */ be_nested_str_weak(copy), - /* K4 */ be_nested_str_weak(reverse), - /* K5 */ be_nested_str_weak(get_fabric_compressed), - /* K6 */ be_nested_str_weak(tohex), - /* K7 */ be_nested_str_weak(_X2D), - /* K8 */ be_nested_str_weak(tasmota), - /* K9 */ be_nested_str_weak(log), - /* K10 */ be_nested_str_weak(MTR_X3A_X20Operational_X20Discovery_X20node_X20_X3D_X20), - /* K11 */ be_const_int(2), - /* K12 */ be_nested_str_weak(eth), - /* K13 */ be_nested_str_weak(find), - /* K14 */ be_nested_str_weak(up), - /* K15 */ be_nested_str_weak(format), - /* K16 */ be_nested_str_weak(MTR_X3A_X20adding_X20mDNS_X20on_X20_X25s_X20_X27_X25s_X27_X20ptr_X20to_X20_X60_X25s_X2Elocal_X60), - /* K17 */ be_nested_str_weak(hostname_eth), - /* K18 */ be_const_int(3), - /* K19 */ be_nested_str_weak(add_service), - /* K20 */ be_nested_str_weak(_matter), - /* K21 */ be_nested_str_weak(_tcp), - /* K22 */ be_nested_str_weak(_I), - /* K23 */ be_nested_str_weak(MTR_X3A_X20adding_X20subtype_X3A_X20), - /* K24 */ be_nested_str_weak(add_subtype), - /* K25 */ be_nested_str_weak(wifi), - /* K26 */ be_nested_str_weak(hostname_wifi), - /* K27 */ be_nested_str_weak(MTR_X3A_X20Exception), - /* K28 */ be_nested_str_weak(_X7C), - }), - be_str_weak(mdns_announce_op_discovery), - &be_const_str_solidified, - ( &(const binstruction[122]) { /* code */ - 0xA40A0000, // 0000 IMPORT R2 K0 - 0xA40E0200, // 0001 IMPORT R3 K1 - 0xA8020064, // 0002 EXBLK 0 #0068 - 0x8C100302, // 0003 GETMET R4 R1 K2 - 0x7C100200, // 0004 CALL R4 1 - 0x8C100903, // 0005 GETMET R4 R4 K3 - 0x7C100200, // 0006 CALL R4 1 - 0x8C100904, // 0007 GETMET R4 R4 K4 - 0x7C100200, // 0008 CALL R4 1 - 0x8C140305, // 0009 GETMET R5 R1 K5 - 0x7C140200, // 000A CALL R5 1 - 0x8C180B06, // 000B GETMET R6 R5 K6 - 0x7C180200, // 000C CALL R6 1 - 0x00180D07, // 000D ADD R6 R6 K7 - 0x8C1C0906, // 000E GETMET R7 R4 K6 - 0x7C1C0200, // 000F CALL R7 1 - 0x00180C07, // 0010 ADD R6 R6 R7 - 0xB81E1000, // 0011 GETNGBL R7 K8 - 0x8C1C0F09, // 0012 GETMET R7 R7 K9 - 0x00261406, // 0013 ADD R9 K10 R6 - 0x5828000B, // 0014 LDCONST R10 K11 - 0x7C1C0600, // 0015 CALL R7 3 - 0xB81E1000, // 0016 GETNGBL R7 K8 - 0x8C1C0F0C, // 0017 GETMET R7 R7 K12 - 0x7C1C0200, // 0018 CALL R7 1 - 0x8C1C0F0D, // 0019 GETMET R7 R7 K13 - 0x5824000E, // 001A LDCONST R9 K14 - 0x7C1C0400, // 001B CALL R7 2 - 0x781E0020, // 001C JMPF R7 #003E - 0xB81E1000, // 001D GETNGBL R7 K8 - 0x8C1C0F09, // 001E GETMET R7 R7 K9 - 0x8C24070F, // 001F GETMET R9 R3 K15 - 0x582C0010, // 0020 LDCONST R11 K16 - 0x5830000C, // 0021 LDCONST R12 K12 - 0x5C340C00, // 0022 MOVE R13 R6 - 0x88380111, // 0023 GETMBR R14 R0 K17 - 0x7C240A00, // 0024 CALL R9 5 - 0x58280012, // 0025 LDCONST R10 K18 - 0x7C1C0600, // 0026 CALL R7 3 - 0x8C1C0513, // 0027 GETMET R7 R2 K19 - 0x58240014, // 0028 LDCONST R9 K20 - 0x58280015, // 0029 LDCONST R10 K21 - 0x542E15A3, // 002A LDINT R11 5540 - 0x4C300000, // 002B LDNIL R12 - 0x5C340C00, // 002C MOVE R13 R6 - 0x88380111, // 002D GETMBR R14 R0 K17 - 0x7C1C0E00, // 002E CALL R7 7 - 0x8C1C0B06, // 002F GETMET R7 R5 K6 - 0x7C1C0200, // 0030 CALL R7 1 - 0x001E2C07, // 0031 ADD R7 K22 R7 - 0xB8221000, // 0032 GETNGBL R8 K8 - 0x8C201109, // 0033 GETMET R8 R8 K9 - 0x002A2E07, // 0034 ADD R10 K23 R7 - 0x582C0012, // 0035 LDCONST R11 K18 - 0x7C200600, // 0036 CALL R8 3 - 0x8C200518, // 0037 GETMET R8 R2 K24 - 0x58280014, // 0038 LDCONST R10 K20 - 0x582C0015, // 0039 LDCONST R11 K21 - 0x5C300C00, // 003A MOVE R12 R6 - 0x88340111, // 003B GETMBR R13 R0 K17 - 0x5C380E00, // 003C MOVE R14 R7 - 0x7C200C00, // 003D CALL R8 6 - 0xB81E1000, // 003E GETNGBL R7 K8 - 0x8C1C0F19, // 003F GETMET R7 R7 K25 - 0x7C1C0200, // 0040 CALL R7 1 - 0x8C1C0F0D, // 0041 GETMET R7 R7 K13 - 0x5824000E, // 0042 LDCONST R9 K14 - 0x7C1C0400, // 0043 CALL R7 2 - 0x781E0020, // 0044 JMPF R7 #0066 - 0xB81E1000, // 0045 GETNGBL R7 K8 - 0x8C1C0F09, // 0046 GETMET R7 R7 K9 - 0x8C24070F, // 0047 GETMET R9 R3 K15 - 0x582C0010, // 0048 LDCONST R11 K16 - 0x58300019, // 0049 LDCONST R12 K25 - 0x5C340C00, // 004A MOVE R13 R6 - 0x8838011A, // 004B GETMBR R14 R0 K26 - 0x7C240A00, // 004C CALL R9 5 - 0x58280012, // 004D LDCONST R10 K18 - 0x7C1C0600, // 004E CALL R7 3 - 0x8C1C0513, // 004F GETMET R7 R2 K19 - 0x58240014, // 0050 LDCONST R9 K20 - 0x58280015, // 0051 LDCONST R10 K21 - 0x542E15A3, // 0052 LDINT R11 5540 - 0x4C300000, // 0053 LDNIL R12 - 0x5C340C00, // 0054 MOVE R13 R6 - 0x8838011A, // 0055 GETMBR R14 R0 K26 - 0x7C1C0E00, // 0056 CALL R7 7 - 0x8C1C0B06, // 0057 GETMET R7 R5 K6 - 0x7C1C0200, // 0058 CALL R7 1 - 0x001E2C07, // 0059 ADD R7 K22 R7 - 0xB8221000, // 005A GETNGBL R8 K8 - 0x8C201109, // 005B GETMET R8 R8 K9 - 0x002A2E07, // 005C ADD R10 K23 R7 - 0x582C0012, // 005D LDCONST R11 K18 - 0x7C200600, // 005E CALL R8 3 - 0x8C200518, // 005F GETMET R8 R2 K24 - 0x58280014, // 0060 LDCONST R10 K20 - 0x582C0015, // 0061 LDCONST R11 K21 - 0x5C300C00, // 0062 MOVE R12 R6 - 0x8834011A, // 0063 GETMBR R13 R0 K26 - 0x5C380E00, // 0064 MOVE R14 R7 - 0x7C200C00, // 0065 CALL R8 6 - 0xA8040001, // 0066 EXBLK 1 1 - 0x70020010, // 0067 JMP #0079 - 0xAC100002, // 0068 CATCH R4 0 2 - 0x7002000D, // 0069 JMP #0078 - 0xB81A1000, // 006A GETNGBL R6 K8 - 0x8C180D09, // 006B GETMET R6 R6 K9 - 0x60200008, // 006C GETGBL R8 G8 - 0x5C240800, // 006D MOVE R9 R4 - 0x7C200200, // 006E CALL R8 1 - 0x00223608, // 006F ADD R8 K27 R8 - 0x0020111C, // 0070 ADD R8 R8 K28 - 0x60240008, // 0071 GETGBL R9 G8 - 0x5C280A00, // 0072 MOVE R10 R5 - 0x7C240200, // 0073 CALL R9 1 - 0x00201009, // 0074 ADD R8 R8 R9 - 0x5824000B, // 0075 LDCONST R9 K11 - 0x7C180600, // 0076 CALL R6 3 - 0x70020000, // 0077 JMP #0079 - 0xB0080000, // 0078 RAISE 2 R0 R0 - 0x80000000, // 0079 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: start_commissioning_complete_deferred -********************************************************************/ -be_local_closure(Matter_Device_start_commissioning_complete_deferred, /* name */ - be_nested_proto( - 6, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 1, /* has sup protos */ - ( &(const struct bproto*[ 1]) { - be_nested_proto( - 3, /* nstack */ - 0, /* argc */ - 0, /* varg */ - 1, /* has upvals */ - ( &(const bupvaldesc[ 2]) { /* upvals */ - be_local_const_upval(1, 0), - be_local_const_upval(1, 1), - }), - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(start_commissioning_complete), - }), - be_str_weak(_X3Clambda_X3E), - &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x68000000, // 0000 GETUPV R0 U0 - 0x8C000100, // 0001 GETMET R0 R0 K0 - 0x68080001, // 0002 GETUPV R2 U1 - 0x7C000400, // 0003 CALL R0 2 - 0x80040000, // 0004 RET 1 R0 - }) - ), - }), - 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(tasmota), - /* K1 */ be_nested_str_weak(set_timer), - /* K2 */ be_const_int(0), - }), - be_str_weak(start_commissioning_complete_deferred), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0xB80A0000, // 0000 GETNGBL R2 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x58100002, // 0002 LDCONST R4 K2 - 0x84140000, // 0003 CLOSURE R5 P0 - 0x7C080600, // 0004 CALL R2 3 - 0xA0000000, // 0005 CLOSE R0 - 0x80000000, // 0006 RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: compute_pbkdf ********************************************************************/ @@ -1826,6 +501,148 @@ be_local_closure(Matter_Device_compute_pbkdf, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: save_param +********************************************************************/ +be_local_closure(Matter_Device_save_param, /* name */ + be_nested_proto( + 10, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[15]) { /* constants */ + /* K0 */ be_nested_str_weak(json), + /* K1 */ be_nested_str_weak(dump), + /* K2 */ be_nested_str_weak(distinguish), + /* K3 */ be_nested_str_weak(discriminator), + /* K4 */ be_nested_str_weak(passcode), + /* K5 */ be_nested_str_weak(string), + /* K6 */ be_nested_str_weak(FILENAME), + /* K7 */ be_nested_str_weak(w), + /* K8 */ be_nested_str_weak(write), + /* K9 */ be_nested_str_weak(close), + /* K10 */ be_nested_str_weak(tasmota), + /* K11 */ be_nested_str_weak(log), + /* K12 */ be_nested_str_weak(MTR_X3A_X20Session_Store_X3A_X3Asave_X20Exception_X3A), + /* K13 */ be_nested_str_weak(_X7C), + /* K14 */ be_const_int(2), + }), + be_str_weak(save_param), + &be_const_str_solidified, + ( &(const binstruction[43]) { /* code */ + 0xA4060000, // 0000 IMPORT R1 K0 + 0x8C080301, // 0001 GETMET R2 R1 K1 + 0x60100013, // 0002 GETGBL R4 G19 + 0x7C100000, // 0003 CALL R4 0 + 0x88140103, // 0004 GETMBR R5 R0 K3 + 0x98120405, // 0005 SETIDX R4 K2 R5 + 0x88140104, // 0006 GETMBR R5 R0 K4 + 0x98120805, // 0007 SETIDX R4 K4 R5 + 0x7C080400, // 0008 CALL R2 2 + 0xA802000D, // 0009 EXBLK 0 #0018 + 0xA40E0A00, // 000A IMPORT R3 K5 + 0x60100011, // 000B GETGBL R4 G17 + 0x88140106, // 000C GETMBR R5 R0 K6 + 0x58180007, // 000D LDCONST R6 K7 + 0x7C100400, // 000E CALL R4 2 + 0x8C140908, // 000F GETMET R5 R4 K8 + 0x5C1C0400, // 0010 MOVE R7 R2 + 0x7C140400, // 0011 CALL R5 2 + 0x8C140909, // 0012 GETMET R5 R4 K9 + 0x7C140200, // 0013 CALL R5 1 + 0xA8040001, // 0014 EXBLK 1 1 + 0x80040400, // 0015 RET 1 R2 + 0xA8040001, // 0016 EXBLK 1 1 + 0x70020011, // 0017 JMP #002A + 0xAC0C0002, // 0018 CATCH R3 0 2 + 0x7002000E, // 0019 JMP #0029 + 0xB8161400, // 001A GETNGBL R5 K10 + 0x8C140B0B, // 001B GETMET R5 R5 K11 + 0x601C0008, // 001C GETGBL R7 G8 + 0x5C200600, // 001D MOVE R8 R3 + 0x7C1C0200, // 001E CALL R7 1 + 0x001E1807, // 001F ADD R7 K12 R7 + 0x001C0F0D, // 0020 ADD R7 R7 K13 + 0x60200008, // 0021 GETGBL R8 G8 + 0x5C240800, // 0022 MOVE R9 R4 + 0x7C200200, // 0023 CALL R8 1 + 0x001C0E08, // 0024 ADD R7 R7 R8 + 0x5820000E, // 0025 LDCONST R8 K14 + 0x7C140600, // 0026 CALL R5 3 + 0x80040400, // 0027 RET 1 R2 + 0x70020000, // 0028 JMP #002A + 0xB0080000, // 0029 RAISE 2 R0 R0 + 0x80000000, // 002A RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: start_operational_dicovery_deferred +********************************************************************/ +be_local_closure(Matter_Device_start_operational_dicovery_deferred, /* name */ + be_nested_proto( + 6, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 1, /* has sup protos */ + ( &(const struct bproto*[ 1]) { + be_nested_proto( + 3, /* nstack */ + 0, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 2]) { /* upvals */ + be_local_const_upval(1, 0), + be_local_const_upval(1, 1), + }), + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(start_operational_dicovery), + }), + be_str_weak(_X3Clambda_X3E), + &be_const_str_solidified, + ( &(const binstruction[ 5]) { /* code */ + 0x68000000, // 0000 GETUPV R0 U0 + 0x8C000100, // 0001 GETMET R0 R0 K0 + 0x68080001, // 0002 GETUPV R2 U1 + 0x7C000400, // 0003 CALL R0 2 + 0x80040000, // 0004 RET 1 R0 + }) + ), + }), + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(tasmota), + /* K1 */ be_nested_str_weak(set_timer), + /* K2 */ be_const_int(0), + }), + be_str_weak(start_operational_dicovery_deferred), + &be_const_str_solidified, + ( &(const binstruction[ 7]) { /* code */ + 0xB80A0000, // 0000 GETNGBL R2 K0 + 0x8C080501, // 0001 GETMET R2 R2 K1 + 0x58100002, // 0002 LDCONST R4 K2 + 0x84140000, // 0003 CLOSURE R5 P0 + 0x7C080600, // 0004 CALL R2 3 + 0xA0000000, // 0005 CLOSE R0 + 0x80000000, // 0006 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: get_active_endpoints ********************************************************************/ @@ -1894,6 +711,1190 @@ be_local_closure(Matter_Device_get_active_endpoints, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: msg_send +********************************************************************/ +be_local_closure(Matter_Device_msg_send, /* name */ + be_nested_proto( + 11, /* nstack */ + 5, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(udp_server), + /* K1 */ be_nested_str_weak(send_response), + }), + be_str_weak(msg_send), + &be_const_str_solidified, + ( &(const binstruction[ 8]) { /* code */ + 0x88140100, // 0000 GETMBR R5 R0 K0 + 0x8C140B01, // 0001 GETMET R5 R5 K1 + 0x5C1C0200, // 0002 MOVE R7 R1 + 0x5C200400, // 0003 MOVE R8 R2 + 0x5C240600, // 0004 MOVE R9 R3 + 0x5C280800, // 0005 MOVE R10 R4 + 0x7C140A00, // 0006 CALL R5 5 + 0x80040A00, // 0007 RET 1 R5 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: finish_commissioning +********************************************************************/ +be_local_closure(Matter_Device_finish_commissioning, /* name */ + be_nested_proto( + 1, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 0, /* has constants */ + NULL, /* no const */ + be_str_weak(finish_commissioning), + &be_const_str_solidified, + ( &(const binstruction[ 1]) { /* code */ + 0x80000000, // 0000 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: every_second +********************************************************************/ +be_local_closure(Matter_Device_every_second, /* name */ + be_nested_proto( + 3, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(sessions), + /* K1 */ be_nested_str_weak(every_second), + /* K2 */ be_nested_str_weak(message_handler), + }), + be_str_weak(every_second), + &be_const_str_solidified, + ( &(const binstruction[ 7]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0x88040102, // 0003 GETMBR R1 R0 K2 + 0x8C040301, // 0004 GETMET R1 R1 K1 + 0x7C040200, // 0005 CALL R1 1 + 0x80000000, // 0006 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: stop +********************************************************************/ +be_local_closure(Matter_Device_stop, /* name */ + be_nested_proto( + 3, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(udp_server), + /* K1 */ be_nested_str_weak(stop), + }), + be_str_weak(stop), + &be_const_str_solidified, + ( &(const binstruction[ 6]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x78060002, // 0001 JMPF R1 #0005 + 0x88040100, // 0002 GETMBR R1 R0 K0 + 0x8C040301, // 0003 GETMET R1 R1 K1 + 0x7C040200, // 0004 CALL R1 1 + 0x80000000, // 0005 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: start_basic_commissioning +********************************************************************/ +be_local_closure(Matter_Device_start_basic_commissioning, /* name */ + be_nested_proto( + 4, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(compute_pbkdf), + /* K1 */ be_nested_str_weak(passcode), + }), + be_str_weak(start_basic_commissioning), + &be_const_str_solidified, + ( &(const binstruction[ 4]) { /* code */ + 0x8C040100, // 0000 GETMET R1 R0 K0 + 0x880C0101, // 0001 GETMBR R3 R0 K1 + 0x7C040400, // 0002 CALL R1 2 + 0x80000000, // 0003 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: load_param +********************************************************************/ +be_local_closure(Matter_Device_load_param, /* name */ + be_nested_proto( + 10, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[22]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(crypto), + /* K2 */ be_nested_str_weak(FILENAME), + /* K3 */ be_nested_str_weak(read), + /* K4 */ be_nested_str_weak(close), + /* K5 */ be_nested_str_weak(json), + /* K6 */ be_nested_str_weak(load), + /* K7 */ be_nested_str_weak(discriminator), + /* K8 */ be_nested_str_weak(find), + /* K9 */ be_nested_str_weak(distinguish), + /* K10 */ be_nested_str_weak(passcode), + /* K11 */ be_nested_str_weak(io_error), + /* K12 */ be_nested_str_weak(tasmota), + /* K13 */ be_nested_str_weak(log), + /* K14 */ be_nested_str_weak(MTR_X3A_X20Session_Store_X3A_X3Aload_X20Exception_X3A), + /* K15 */ be_nested_str_weak(_X7C), + /* K16 */ be_const_int(2), + /* K17 */ be_nested_str_weak(random), + /* K18 */ be_nested_str_weak(get), + /* K19 */ be_const_int(0), + /* K20 */ be_nested_str_weak(PASSCODE_DEFAULT), + /* K21 */ be_nested_str_weak(save_param), + }), + be_str_weak(load_param), + &be_const_str_solidified, + ( &(const binstruction[70]) { /* code */ + 0xA4060000, // 0000 IMPORT R1 K0 + 0xA40A0200, // 0001 IMPORT R2 K1 + 0xA8020014, // 0002 EXBLK 0 #0018 + 0x600C0011, // 0003 GETGBL R3 G17 + 0x88100102, // 0004 GETMBR R4 R0 K2 + 0x7C0C0200, // 0005 CALL R3 1 + 0x8C100703, // 0006 GETMET R4 R3 K3 + 0x7C100200, // 0007 CALL R4 1 + 0x8C140704, // 0008 GETMET R5 R3 K4 + 0x7C140200, // 0009 CALL R5 1 + 0xA4160A00, // 000A IMPORT R5 K5 + 0x8C180B06, // 000B GETMET R6 R5 K6 + 0x5C200800, // 000C MOVE R8 R4 + 0x7C180400, // 000D CALL R6 2 + 0x8C1C0D08, // 000E GETMET R7 R6 K8 + 0x58240009, // 000F LDCONST R9 K9 + 0x7C1C0400, // 0010 CALL R7 2 + 0x90020E07, // 0011 SETMBR R0 K7 R7 + 0x8C1C0D08, // 0012 GETMET R7 R6 K8 + 0x5824000A, // 0013 LDCONST R9 K10 + 0x7C1C0400, // 0014 CALL R7 2 + 0x90021407, // 0015 SETMBR R0 K10 R7 + 0xA8040001, // 0016 EXBLK 1 1 + 0x70020012, // 0017 JMP #002B + 0xAC0C0002, // 0018 CATCH R3 0 2 + 0x7002000F, // 0019 JMP #002A + 0x2014070B, // 001A NE R5 R3 K11 + 0x7816000C, // 001B JMPF R5 #0029 + 0xB8161800, // 001C GETNGBL R5 K12 + 0x8C140B0D, // 001D GETMET R5 R5 K13 + 0x601C0008, // 001E GETGBL R7 G8 + 0x5C200600, // 001F MOVE R8 R3 + 0x7C1C0200, // 0020 CALL R7 1 + 0x001E1C07, // 0021 ADD R7 K14 R7 + 0x001C0F0F, // 0022 ADD R7 R7 K15 + 0x60200008, // 0023 GETGBL R8 G8 + 0x5C240800, // 0024 MOVE R9 R4 + 0x7C200200, // 0025 CALL R8 1 + 0x001C0E08, // 0026 ADD R7 R7 R8 + 0x58200010, // 0027 LDCONST R8 K16 + 0x7C140600, // 0028 CALL R5 3 + 0x70020000, // 0029 JMP #002B + 0xB0080000, // 002A RAISE 2 R0 R0 + 0x500C0000, // 002B LDBOOL R3 0 0 + 0x88100107, // 002C GETMBR R4 R0 K7 + 0x4C140000, // 002D LDNIL R5 + 0x1C100805, // 002E EQ R4 R4 R5 + 0x7812000A, // 002F JMPF R4 #003B + 0x8C100511, // 0030 GETMET R4 R2 K17 + 0x58180010, // 0031 LDCONST R6 K16 + 0x7C100400, // 0032 CALL R4 2 + 0x8C100912, // 0033 GETMET R4 R4 K18 + 0x58180013, // 0034 LDCONST R6 K19 + 0x581C0010, // 0035 LDCONST R7 K16 + 0x7C100600, // 0036 CALL R4 3 + 0x54160FFE, // 0037 LDINT R5 4095 + 0x2C100805, // 0038 AND R4 R4 R5 + 0x90020E04, // 0039 SETMBR R0 K7 R4 + 0x500C0200, // 003A LDBOOL R3 1 0 + 0x8810010A, // 003B GETMBR R4 R0 K10 + 0x4C140000, // 003C LDNIL R5 + 0x1C100805, // 003D EQ R4 R4 R5 + 0x78120002, // 003E JMPF R4 #0042 + 0x88100114, // 003F GETMBR R4 R0 K20 + 0x90021404, // 0040 SETMBR R0 K10 R4 + 0x500C0200, // 0041 LDBOOL R3 1 0 + 0x780E0001, // 0042 JMPF R3 #0045 + 0x8C100115, // 0043 GETMET R4 R0 K21 + 0x7C100200, // 0044 CALL R4 1 + 0x80000000, // 0045 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: process_attribute_expansion +********************************************************************/ +be_local_closure(Matter_Device_process_attribute_expansion, /* name */ + be_nested_proto( + 32, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 1, /* has sup protos */ + ( &(const struct bproto*[ 1]) { + be_nested_proto( + 7, /* nstack */ + 1, /* argc */ + 0, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(keys), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(stop_iteration), + /* K3 */ be_const_int(1), + /* K4 */ be_const_int(0), + }), + be_str_weak(keys_sorted), + &be_const_str_solidified, + ( &(const binstruction[45]) { /* code */ + 0x60040012, // 0000 GETGBL R1 G18 + 0x7C040000, // 0001 CALL R1 0 + 0x60080010, // 0002 GETGBL R2 G16 + 0x8C0C0100, // 0003 GETMET R3 R0 K0 + 0x7C0C0200, // 0004 CALL R3 1 + 0x7C080200, // 0005 CALL R2 1 + 0xA8020005, // 0006 EXBLK 0 #000D + 0x5C0C0400, // 0007 MOVE R3 R2 + 0x7C0C0000, // 0008 CALL R3 0 + 0x8C100301, // 0009 GETMET R4 R1 K1 + 0x5C180600, // 000A MOVE R6 R3 + 0x7C100400, // 000B CALL R4 2 + 0x7001FFF9, // 000C JMP #0007 + 0x58080002, // 000D LDCONST R2 K2 + 0xAC080200, // 000E CATCH R2 1 0 + 0xB0080000, // 000F RAISE 2 R0 R0 + 0x60080010, // 0010 GETGBL R2 G16 + 0x600C000C, // 0011 GETGBL R3 G12 + 0x5C100200, // 0012 MOVE R4 R1 + 0x7C0C0200, // 0013 CALL R3 1 + 0x040C0703, // 0014 SUB R3 R3 K3 + 0x400E0603, // 0015 CONNECT R3 K3 R3 + 0x7C080200, // 0016 CALL R2 1 + 0xA8020010, // 0017 EXBLK 0 #0029 + 0x5C0C0400, // 0018 MOVE R3 R2 + 0x7C0C0000, // 0019 CALL R3 0 + 0x94100203, // 001A GETIDX R4 R1 R3 + 0x5C140600, // 001B MOVE R5 R3 + 0x24180B04, // 001C GT R6 R5 K4 + 0x781A0008, // 001D JMPF R6 #0027 + 0x04180B03, // 001E SUB R6 R5 K3 + 0x94180206, // 001F GETIDX R6 R1 R6 + 0x24180C04, // 0020 GT R6 R6 R4 + 0x781A0004, // 0021 JMPF R6 #0027 + 0x04180B03, // 0022 SUB R6 R5 K3 + 0x94180206, // 0023 GETIDX R6 R1 R6 + 0x98040A06, // 0024 SETIDX R1 R5 R6 + 0x04140B03, // 0025 SUB R5 R5 K3 + 0x7001FFF4, // 0026 JMP #001C + 0x98040A04, // 0027 SETIDX R1 R5 R4 + 0x7001FFEE, // 0028 JMP #0018 + 0x58080002, // 0029 LDCONST R2 K2 + 0xAC080200, // 002A CATCH R2 1 0 + 0xB0080000, // 002B RAISE 2 R0 R0 + 0x80040200, // 002C RET 1 R1 + }) + ), + }), + 1, /* has constants */ + ( &(const bvalue[27]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(endpoint), + /* K2 */ be_nested_str_weak(cluster), + /* K3 */ be_nested_str_weak(attribute), + /* K4 */ be_nested_str_weak(tasmota), + /* K5 */ be_nested_str_weak(log), + /* K6 */ be_nested_str_weak(format), + /* K7 */ be_nested_str_weak(MTR_X3A_X20process_attribute_expansion_X20_X25s), + /* K8 */ be_nested_str_weak(MTR_X3A_X20endpoint_X3D_X25s_X20cluster_X3D_X25s_X20attribute_X3D_X25s), + /* K9 */ be_nested_str_weak(plugins), + /* K10 */ be_nested_str_weak(get_endpoints), + /* K11 */ be_nested_str_weak(MTR_X3A_X20pi_X3D_X25s_X20ep_list_X3D_X25s), + /* K12 */ be_nested_str_weak(contains), + /* K13 */ be_nested_str_weak(get_cluster_list), + /* K14 */ be_nested_str_weak(MTR_X3A_X20pi_X3D_X25s_X20ep_X3D_X25s_X20cl_list_X3D_X25s), + /* K15 */ be_nested_str_weak(get_attribute_list), + /* K16 */ be_nested_str_weak(MTR_X3A_X20pi_X3D_X25s_X20ep_X3D_X25s_X20cl_X3D_X25s_X20at_list_X3D_X25s), + /* K17 */ be_nested_str_weak(push), + /* K18 */ be_nested_str_weak(stop_iteration), + /* K19 */ be_nested_str_weak(MTR_X3A_X20expansion_X20_X5B_X2502X_X5D_X2504X_X2F_X2504X), + /* K20 */ be_const_int(3), + /* K21 */ be_nested_str_weak(status), + /* K22 */ be_nested_str_weak(matter), + /* K23 */ be_nested_str_weak(UNSUPPORTED_ENDPOINT), + /* K24 */ be_nested_str_weak(UNSUPPORTED_CLUSTER), + /* K25 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), + /* K26 */ be_nested_str_weak(UNREPORTABLE_ATTRIBUTE), + }), + be_str_weak(process_attribute_expansion), + &be_const_str_solidified, + ( &(const binstruction[294]) { /* code */ + 0x840C0000, // 0000 CLOSURE R3 P0 + 0xA4120000, // 0001 IMPORT R4 K0 + 0x88140301, // 0002 GETMBR R5 R1 K1 + 0x50180000, // 0003 LDBOOL R6 0 0 + 0x881C0302, // 0004 GETMBR R7 R1 K2 + 0x50200000, // 0005 LDBOOL R8 0 0 + 0x88240303, // 0006 GETMBR R9 R1 K3 + 0x50280000, // 0007 LDBOOL R10 0 0 + 0x882C0301, // 0008 GETMBR R11 R1 K1 + 0x4C300000, // 0009 LDNIL R12 + 0x202C160C, // 000A NE R11 R11 R12 + 0x782E0007, // 000B JMPF R11 #0014 + 0x882C0302, // 000C GETMBR R11 R1 K2 + 0x4C300000, // 000D LDNIL R12 + 0x202C160C, // 000E NE R11 R11 R12 + 0x782E0003, // 000F JMPF R11 #0014 + 0x882C0303, // 0010 GETMBR R11 R1 K3 + 0x4C300000, // 0011 LDNIL R12 + 0x202C160C, // 0012 NE R11 R11 R12 + 0x742E0000, // 0013 JMPT R11 #0015 + 0x502C0001, // 0014 LDBOOL R11 0 1 + 0x502C0200, // 0015 LDBOOL R11 1 0 + 0xB8320800, // 0016 GETNGBL R12 K4 + 0x8C301905, // 0017 GETMET R12 R12 K5 + 0x8C380906, // 0018 GETMET R14 R4 K6 + 0x58400007, // 0019 LDCONST R16 K7 + 0x60440008, // 001A GETGBL R17 G8 + 0x5C480200, // 001B MOVE R18 R1 + 0x7C440200, // 001C CALL R17 1 + 0x7C380600, // 001D CALL R14 3 + 0x543E0003, // 001E LDINT R15 4 + 0x7C300600, // 001F CALL R12 3 + 0x60300013, // 0020 GETGBL R12 G19 + 0x7C300000, // 0021 CALL R12 0 + 0xB8360800, // 0022 GETNGBL R13 K4 + 0x8C341B05, // 0023 GETMET R13 R13 K5 + 0x8C3C0906, // 0024 GETMET R15 R4 K6 + 0x58440008, // 0025 LDCONST R17 K8 + 0x5C480A00, // 0026 MOVE R18 R5 + 0x5C4C0E00, // 0027 MOVE R19 R7 + 0x5C501200, // 0028 MOVE R20 R9 + 0x7C3C0A00, // 0029 CALL R15 5 + 0x54420003, // 002A LDINT R16 4 + 0x7C340600, // 002B CALL R13 3 + 0x60340010, // 002C GETGBL R13 G16 + 0x88380109, // 002D GETMBR R14 R0 K9 + 0x7C340200, // 002E CALL R13 1 + 0xA802008F, // 002F EXBLK 0 #00C0 + 0x5C381A00, // 0030 MOVE R14 R13 + 0x7C380000, // 0031 CALL R14 0 + 0x8C3C1D0A, // 0032 GETMET R15 R14 K10 + 0x7C3C0200, // 0033 CALL R15 1 + 0xB8420800, // 0034 GETNGBL R16 K4 + 0x8C402105, // 0035 GETMET R16 R16 K5 + 0x8C480906, // 0036 GETMET R18 R4 K6 + 0x5850000B, // 0037 LDCONST R20 K11 + 0x60540008, // 0038 GETGBL R21 G8 + 0x5C581C00, // 0039 MOVE R22 R14 + 0x7C540200, // 003A CALL R21 1 + 0x60580008, // 003B GETGBL R22 G8 + 0x5C5C1E00, // 003C MOVE R23 R15 + 0x7C580200, // 003D CALL R22 1 + 0x7C480800, // 003E CALL R18 4 + 0x544E0003, // 003F LDINT R19 4 + 0x7C400600, // 0040 CALL R16 3 + 0x60400010, // 0041 GETGBL R16 G16 + 0x5C441E00, // 0042 MOVE R17 R15 + 0x7C400200, // 0043 CALL R16 1 + 0xA8020076, // 0044 EXBLK 0 #00BC + 0x5C442000, // 0045 MOVE R17 R16 + 0x7C440000, // 0046 CALL R17 0 + 0x4C480000, // 0047 LDNIL R18 + 0x20480A12, // 0048 NE R18 R5 R18 + 0x784A0002, // 0049 JMPF R18 #004D + 0x20482205, // 004A NE R18 R17 R5 + 0x784A0000, // 004B JMPF R18 #004D + 0x7001FFF7, // 004C JMP #0045 + 0x8C48190C, // 004D GETMET R18 R12 K12 + 0x5C502200, // 004E MOVE R20 R17 + 0x7C480400, // 004F CALL R18 2 + 0x744A0002, // 0050 JMPT R18 #0054 + 0x60480013, // 0051 GETGBL R18 G19 + 0x7C480000, // 0052 CALL R18 0 + 0x98302212, // 0053 SETIDX R12 R17 R18 + 0x50180200, // 0054 LDBOOL R6 1 0 + 0x8C481D0D, // 0055 GETMET R18 R14 K13 + 0x5C502200, // 0056 MOVE R20 R17 + 0x7C480400, // 0057 CALL R18 2 + 0xB84E0800, // 0058 GETNGBL R19 K4 + 0x8C4C2705, // 0059 GETMET R19 R19 K5 + 0x8C540906, // 005A GETMET R21 R4 K6 + 0x585C000E, // 005B LDCONST R23 K14 + 0x60600008, // 005C GETGBL R24 G8 + 0x5C641C00, // 005D MOVE R25 R14 + 0x7C600200, // 005E CALL R24 1 + 0x60640008, // 005F GETGBL R25 G8 + 0x5C682200, // 0060 MOVE R26 R17 + 0x7C640200, // 0061 CALL R25 1 + 0x60680008, // 0062 GETGBL R26 G8 + 0x5C6C2400, // 0063 MOVE R27 R18 + 0x7C680200, // 0064 CALL R26 1 + 0x7C540A00, // 0065 CALL R21 5 + 0x545A0003, // 0066 LDINT R22 4 + 0x7C4C0600, // 0067 CALL R19 3 + 0x604C0010, // 0068 GETGBL R19 G16 + 0x5C502400, // 0069 MOVE R20 R18 + 0x7C4C0200, // 006A CALL R19 1 + 0xA802004B, // 006B EXBLK 0 #00B8 + 0x5C502600, // 006C MOVE R20 R19 + 0x7C500000, // 006D CALL R20 0 + 0x4C540000, // 006E LDNIL R21 + 0x20540E15, // 006F NE R21 R7 R21 + 0x78560002, // 0070 JMPF R21 #0074 + 0x20542807, // 0071 NE R21 R20 R7 + 0x78560000, // 0072 JMPF R21 #0074 + 0x7001FFF7, // 0073 JMP #006C + 0x94541811, // 0074 GETIDX R21 R12 R17 + 0x8C542B0C, // 0075 GETMET R21 R21 K12 + 0x5C5C2800, // 0076 MOVE R23 R20 + 0x7C540400, // 0077 CALL R21 2 + 0x74560003, // 0078 JMPT R21 #007D + 0x94541811, // 0079 GETIDX R21 R12 R17 + 0x60580013, // 007A GETGBL R22 G19 + 0x7C580000, // 007B CALL R22 0 + 0x98542816, // 007C SETIDX R21 R20 R22 + 0x50200200, // 007D LDBOOL R8 1 0 + 0x8C541D0F, // 007E GETMET R21 R14 K15 + 0x5C5C2200, // 007F MOVE R23 R17 + 0x5C602800, // 0080 MOVE R24 R20 + 0x7C540600, // 0081 CALL R21 3 + 0xB85A0800, // 0082 GETNGBL R22 K4 + 0x8C582D05, // 0083 GETMET R22 R22 K5 + 0x8C600906, // 0084 GETMET R24 R4 K6 + 0x58680010, // 0085 LDCONST R26 K16 + 0x606C0008, // 0086 GETGBL R27 G8 + 0x5C701C00, // 0087 MOVE R28 R14 + 0x7C6C0200, // 0088 CALL R27 1 + 0x60700008, // 0089 GETGBL R28 G8 + 0x5C742200, // 008A MOVE R29 R17 + 0x7C700200, // 008B CALL R28 1 + 0x60740008, // 008C GETGBL R29 G8 + 0x5C782800, // 008D MOVE R30 R20 + 0x7C740200, // 008E CALL R29 1 + 0x60780008, // 008F GETGBL R30 G8 + 0x5C7C2A00, // 0090 MOVE R31 R21 + 0x7C780200, // 0091 CALL R30 1 + 0x7C600C00, // 0092 CALL R24 6 + 0x54660003, // 0093 LDINT R25 4 + 0x7C580600, // 0094 CALL R22 3 + 0x60580010, // 0095 GETGBL R22 G16 + 0x5C5C2A00, // 0096 MOVE R23 R21 + 0x7C580200, // 0097 CALL R22 1 + 0xA802001A, // 0098 EXBLK 0 #00B4 + 0x5C5C2C00, // 0099 MOVE R23 R22 + 0x7C5C0000, // 009A CALL R23 0 + 0x4C600000, // 009B LDNIL R24 + 0x20601218, // 009C NE R24 R9 R24 + 0x78620002, // 009D JMPF R24 #00A1 + 0x20602E09, // 009E NE R24 R23 R9 + 0x78620000, // 009F JMPF R24 #00A1 + 0x7001FFF7, // 00A0 JMP #0099 + 0x94601811, // 00A1 GETIDX R24 R12 R17 + 0x94603014, // 00A2 GETIDX R24 R24 R20 + 0x8C60310C, // 00A3 GETMET R24 R24 K12 + 0x5C682E00, // 00A4 MOVE R26 R23 + 0x7C600400, // 00A5 CALL R24 2 + 0x74620004, // 00A6 JMPT R24 #00AC + 0x94601811, // 00A7 GETIDX R24 R12 R17 + 0x94603014, // 00A8 GETIDX R24 R24 R20 + 0x60640012, // 00A9 GETGBL R25 G18 + 0x7C640000, // 00AA CALL R25 0 + 0x98602E19, // 00AB SETIDX R24 R23 R25 + 0x50280200, // 00AC LDBOOL R10 1 0 + 0x94601811, // 00AD GETIDX R24 R12 R17 + 0x94603014, // 00AE GETIDX R24 R24 R20 + 0x94603017, // 00AF GETIDX R24 R24 R23 + 0x8C603111, // 00B0 GETMET R24 R24 K17 + 0x5C681C00, // 00B1 MOVE R26 R14 + 0x7C600400, // 00B2 CALL R24 2 + 0x7001FFE4, // 00B3 JMP #0099 + 0x58580012, // 00B4 LDCONST R22 K18 + 0xAC580200, // 00B5 CATCH R22 1 0 + 0xB0080000, // 00B6 RAISE 2 R0 R0 + 0x7001FFB3, // 00B7 JMP #006C + 0x584C0012, // 00B8 LDCONST R19 K18 + 0xAC4C0200, // 00B9 CATCH R19 1 0 + 0xB0080000, // 00BA RAISE 2 R0 R0 + 0x7001FF88, // 00BB JMP #0045 + 0x58400012, // 00BC LDCONST R16 K18 + 0xAC400200, // 00BD CATCH R16 1 0 + 0xB0080000, // 00BE RAISE 2 R0 R0 + 0x7001FF6F, // 00BF JMP #0030 + 0x58340012, // 00C0 LDCONST R13 K18 + 0xAC340200, // 00C1 CATCH R13 1 0 + 0xB0080000, // 00C2 RAISE 2 R0 R0 + 0x60340010, // 00C3 GETGBL R13 G16 + 0x5C380600, // 00C4 MOVE R14 R3 + 0x5C3C1800, // 00C5 MOVE R15 R12 + 0x7C380200, // 00C6 CALL R14 1 + 0x7C340200, // 00C7 CALL R13 1 + 0xA802003D, // 00C8 EXBLK 0 #0107 + 0x5C381A00, // 00C9 MOVE R14 R13 + 0x7C380000, // 00CA CALL R14 0 + 0x603C0010, // 00CB GETGBL R15 G16 + 0x5C400600, // 00CC MOVE R16 R3 + 0x9444180E, // 00CD GETIDX R17 R12 R14 + 0x7C400200, // 00CE CALL R16 1 + 0x7C3C0200, // 00CF CALL R15 1 + 0xA8020031, // 00D0 EXBLK 0 #0103 + 0x5C401E00, // 00D1 MOVE R16 R15 + 0x7C400000, // 00D2 CALL R16 0 + 0x60440010, // 00D3 GETGBL R17 G16 + 0x5C480600, // 00D4 MOVE R18 R3 + 0x944C180E, // 00D5 GETIDX R19 R12 R14 + 0x944C2610, // 00D6 GETIDX R19 R19 R16 + 0x7C480200, // 00D7 CALL R18 1 + 0x7C440200, // 00D8 CALL R17 1 + 0xA8020024, // 00D9 EXBLK 0 #00FF + 0x5C482200, // 00DA MOVE R18 R17 + 0x7C480000, // 00DB CALL R18 0 + 0x604C0010, // 00DC GETGBL R19 G16 + 0x9450180E, // 00DD GETIDX R20 R12 R14 + 0x94502810, // 00DE GETIDX R20 R20 R16 + 0x94502812, // 00DF GETIDX R20 R20 R18 + 0x7C4C0200, // 00E0 CALL R19 1 + 0xA8020018, // 00E1 EXBLK 0 #00FB + 0x5C502600, // 00E2 MOVE R20 R19 + 0x7C500000, // 00E3 CALL R20 0 + 0xB8560800, // 00E4 GETNGBL R21 K4 + 0x8C542B05, // 00E5 GETMET R21 R21 K5 + 0x8C5C0906, // 00E6 GETMET R23 R4 K6 + 0x58640013, // 00E7 LDCONST R25 K19 + 0x5C681C00, // 00E8 MOVE R26 R14 + 0x5C6C2000, // 00E9 MOVE R27 R16 + 0x5C702400, // 00EA MOVE R28 R18 + 0x7C5C0A00, // 00EB CALL R23 5 + 0x58600014, // 00EC LDCONST R24 K20 + 0x7C540600, // 00ED CALL R21 3 + 0x9006020E, // 00EE SETMBR R1 K1 R14 + 0x90060410, // 00EF SETMBR R1 K2 R16 + 0x90060612, // 00F0 SETMBR R1 K3 R18 + 0x5C540400, // 00F1 MOVE R21 R2 + 0x5C582800, // 00F2 MOVE R22 R20 + 0x5C5C0200, // 00F3 MOVE R23 R1 + 0x5C601600, // 00F4 MOVE R24 R11 + 0x7C540600, // 00F5 CALL R21 3 + 0x782E0002, // 00F6 JMPF R11 #00FA + 0x78560001, // 00F7 JMPF R21 #00FA + 0xA8040004, // 00F8 EXBLK 1 4 + 0x80002C00, // 00F9 RET 0 + 0x7001FFE6, // 00FA JMP #00E2 + 0x584C0012, // 00FB LDCONST R19 K18 + 0xAC4C0200, // 00FC CATCH R19 1 0 + 0xB0080000, // 00FD RAISE 2 R0 R0 + 0x7001FFDA, // 00FE JMP #00DA + 0x58440012, // 00FF LDCONST R17 K18 + 0xAC440200, // 0100 CATCH R17 1 0 + 0xB0080000, // 0101 RAISE 2 R0 R0 + 0x7001FFCD, // 0102 JMP #00D1 + 0x583C0012, // 0103 LDCONST R15 K18 + 0xAC3C0200, // 0104 CATCH R15 1 0 + 0xB0080000, // 0105 RAISE 2 R0 R0 + 0x7001FFC1, // 0106 JMP #00C9 + 0x58340012, // 0107 LDCONST R13 K18 + 0xAC340200, // 0108 CATCH R13 1 0 + 0xB0080000, // 0109 RAISE 2 R0 R0 + 0x782E0019, // 010A JMPF R11 #0125 + 0x5C340C00, // 010B MOVE R13 R6 + 0x74360003, // 010C JMPT R13 #0111 + 0xB8362C00, // 010D GETNGBL R13 K22 + 0x88341B17, // 010E GETMBR R13 R13 K23 + 0x90062A0D, // 010F SETMBR R1 K21 R13 + 0x7002000E, // 0110 JMP #0120 + 0x5C341000, // 0111 MOVE R13 R8 + 0x74360003, // 0112 JMPT R13 #0117 + 0xB8362C00, // 0113 GETNGBL R13 K22 + 0x88341B18, // 0114 GETMBR R13 R13 K24 + 0x90062A0D, // 0115 SETMBR R1 K21 R13 + 0x70020008, // 0116 JMP #0120 + 0x5C341400, // 0117 MOVE R13 R10 + 0x74360003, // 0118 JMPT R13 #011D + 0xB8362C00, // 0119 GETNGBL R13 K22 + 0x88341B19, // 011A GETMBR R13 R13 K25 + 0x90062A0D, // 011B SETMBR R1 K21 R13 + 0x70020002, // 011C JMP #0120 + 0xB8362C00, // 011D GETNGBL R13 K22 + 0x88341B1A, // 011E GETMBR R13 R13 K26 + 0x90062A0D, // 011F SETMBR R1 K21 R13 + 0x5C340400, // 0120 MOVE R13 R2 + 0x4C380000, // 0121 LDNIL R14 + 0x5C3C0200, // 0122 MOVE R15 R1 + 0x50400200, // 0123 LDBOOL R16 1 0 + 0x7C340600, // 0124 CALL R13 3 + 0x80000000, // 0125 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: sort_distinct +********************************************************************/ +be_local_closure(Matter_Device_sort_distinct, /* name */ + be_nested_proto( + 7, /* nstack */ + 1, /* argc */ + 4, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_const_class(be_class_Matter_Device), + /* K1 */ be_const_int(1), + /* K2 */ be_const_int(0), + /* K3 */ be_nested_str_weak(stop_iteration), + /* K4 */ be_nested_str_weak(remove), + }), + be_str_weak(sort_distinct), + &be_const_str_solidified, + ( &(const binstruction[53]) { /* code */ + 0x58040000, // 0000 LDCONST R1 K0 + 0x60080010, // 0001 GETGBL R2 G16 + 0x600C000C, // 0002 GETGBL R3 G12 + 0x5C100000, // 0003 MOVE R4 R0 + 0x7C0C0200, // 0004 CALL R3 1 + 0x040C0701, // 0005 SUB R3 R3 K1 + 0x400E0203, // 0006 CONNECT R3 K1 R3 + 0x7C080200, // 0007 CALL R2 1 + 0xA8020010, // 0008 EXBLK 0 #001A + 0x5C0C0400, // 0009 MOVE R3 R2 + 0x7C0C0000, // 000A CALL R3 0 + 0x94100003, // 000B GETIDX R4 R0 R3 + 0x5C140600, // 000C MOVE R5 R3 + 0x24180B02, // 000D GT R6 R5 K2 + 0x781A0008, // 000E JMPF R6 #0018 + 0x04180B01, // 000F SUB R6 R5 K1 + 0x94180006, // 0010 GETIDX R6 R0 R6 + 0x24180C04, // 0011 GT R6 R6 R4 + 0x781A0004, // 0012 JMPF R6 #0018 + 0x04180B01, // 0013 SUB R6 R5 K1 + 0x94180006, // 0014 GETIDX R6 R0 R6 + 0x98000A06, // 0015 SETIDX R0 R5 R6 + 0x04140B01, // 0016 SUB R5 R5 K1 + 0x7001FFF4, // 0017 JMP #000D + 0x98000A04, // 0018 SETIDX R0 R5 R4 + 0x7001FFEE, // 0019 JMP #0009 + 0x58080003, // 001A LDCONST R2 K3 + 0xAC080200, // 001B CATCH R2 1 0 + 0xB0080000, // 001C RAISE 2 R0 R0 + 0x58080001, // 001D LDCONST R2 K1 + 0x600C000C, // 001E GETGBL R3 G12 + 0x5C100000, // 001F MOVE R4 R0 + 0x7C0C0200, // 0020 CALL R3 1 + 0x180C0701, // 0021 LE R3 R3 K1 + 0x780E0000, // 0022 JMPF R3 #0024 + 0x80040000, // 0023 RET 1 R0 + 0x940C0102, // 0024 GETIDX R3 R0 K2 + 0x6010000C, // 0025 GETGBL R4 G12 + 0x5C140000, // 0026 MOVE R5 R0 + 0x7C100200, // 0027 CALL R4 1 + 0x14100404, // 0028 LT R4 R2 R4 + 0x78120009, // 0029 JMPF R4 #0034 + 0x94100002, // 002A GETIDX R4 R0 R2 + 0x1C100803, // 002B EQ R4 R4 R3 + 0x78120003, // 002C JMPF R4 #0031 + 0x8C100104, // 002D GETMET R4 R0 K4 + 0x5C180400, // 002E MOVE R6 R2 + 0x7C100400, // 002F CALL R4 2 + 0x70020001, // 0030 JMP #0033 + 0x940C0002, // 0031 GETIDX R3 R0 R2 + 0x00080501, // 0032 ADD R2 R2 K1 + 0x7001FFF0, // 0033 JMP #0025 + 0x80040000, // 0034 RET 1 R0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: compute_qrcode_content +********************************************************************/ +be_local_closure(Matter_Device_compute_qrcode_content, /* name */ + be_nested_proto( + 8, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[12]) { /* constants */ + /* K0 */ be_nested_str_weak(resize), + /* K1 */ be_nested_str_weak(setbits), + /* K2 */ be_const_int(3), + /* K3 */ be_nested_str_weak(vendorid), + /* K4 */ be_nested_str_weak(productid), + /* K5 */ be_nested_str_weak(discriminator), + /* K6 */ be_nested_str_weak(passcode), + /* K7 */ be_const_int(134217727), + /* K8 */ be_nested_str_weak(MT_X3A), + /* K9 */ be_nested_str_weak(matter), + /* K10 */ be_nested_str_weak(Base38), + /* K11 */ be_nested_str_weak(encode), + }), + be_str_weak(compute_qrcode_content), + &be_const_str_solidified, + ( &(const binstruction[40]) { /* code */ + 0x60040015, // 0000 GETGBL R1 G21 + 0x7C040000, // 0001 CALL R1 0 + 0x8C040300, // 0002 GETMET R1 R1 K0 + 0x540E000A, // 0003 LDINT R3 11 + 0x7C040400, // 0004 CALL R1 2 + 0x8C080301, // 0005 GETMET R2 R1 K1 + 0x58100002, // 0006 LDCONST R4 K2 + 0x5416000F, // 0007 LDINT R5 16 + 0x88180103, // 0008 GETMBR R6 R0 K3 + 0x7C080800, // 0009 CALL R2 4 + 0x8C080301, // 000A GETMET R2 R1 K1 + 0x54120012, // 000B LDINT R4 19 + 0x5416000F, // 000C LDINT R5 16 + 0x88180104, // 000D GETMBR R6 R0 K4 + 0x7C080800, // 000E CALL R2 4 + 0x8C080301, // 000F GETMET R2 R1 K1 + 0x54120024, // 0010 LDINT R4 37 + 0x54160007, // 0011 LDINT R5 8 + 0x541A0003, // 0012 LDINT R6 4 + 0x7C080800, // 0013 CALL R2 4 + 0x8C080301, // 0014 GETMET R2 R1 K1 + 0x5412002C, // 0015 LDINT R4 45 + 0x5416000B, // 0016 LDINT R5 12 + 0x88180105, // 0017 GETMBR R6 R0 K5 + 0x541E0FFE, // 0018 LDINT R7 4095 + 0x2C180C07, // 0019 AND R6 R6 R7 + 0x7C080800, // 001A CALL R2 4 + 0x8C080301, // 001B GETMET R2 R1 K1 + 0x54120038, // 001C LDINT R4 57 + 0x5416001A, // 001D LDINT R5 27 + 0x88180106, // 001E GETMBR R6 R0 K6 + 0x2C180D07, // 001F AND R6 R6 K7 + 0x7C080800, // 0020 CALL R2 4 + 0xB80A1200, // 0021 GETNGBL R2 K9 + 0x8808050A, // 0022 GETMBR R2 R2 K10 + 0x8C08050B, // 0023 GETMET R2 R2 K11 + 0x5C100200, // 0024 MOVE R4 R1 + 0x7C080400, // 0025 CALL R2 2 + 0x000A1002, // 0026 ADD R2 K8 R2 + 0x80040400, // 0027 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: start_mdns_announce_hostnames +********************************************************************/ +be_local_closure(Matter_Device_start_mdns_announce_hostnames, /* name */ + be_nested_proto( + 6, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 1, /* has sup protos */ + ( &(const struct bproto*[ 2]) { + be_nested_proto( + 4, /* nstack */ + 0, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 1]) { /* upvals */ + be_local_const_upval(1, 0), + }), + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(_start_mdns_announce), + /* K1 */ be_nested_str_weak(tasmota), + /* K2 */ be_nested_str_weak(remove_rule), + /* K3 */ be_nested_str_weak(Wifi_X23Connected), + /* K4 */ be_nested_str_weak(matter_device_mdns), + }), + be_str_weak(_anonymous_), + &be_const_str_solidified, + ( &(const binstruction[10]) { /* code */ + 0x68000000, // 0000 GETUPV R0 U0 + 0x8C000100, // 0001 GETMET R0 R0 K0 + 0x50080000, // 0002 LDBOOL R2 0 0 + 0x7C000400, // 0003 CALL R0 2 + 0xB8020200, // 0004 GETNGBL R0 K1 + 0x8C000102, // 0005 GETMET R0 R0 K2 + 0x58080003, // 0006 LDCONST R2 K3 + 0x580C0004, // 0007 LDCONST R3 K4 + 0x7C000600, // 0008 CALL R0 3 + 0x80000000, // 0009 RET 0 + }) + ), + be_nested_proto( + 4, /* nstack */ + 0, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 1]) { /* upvals */ + be_local_const_upval(1, 0), + }), + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(_start_mdns_announce), + /* K1 */ be_nested_str_weak(tasmota), + /* K2 */ be_nested_str_weak(remove_rule), + /* K3 */ be_nested_str_weak(Eth_X23Connected), + /* K4 */ be_nested_str_weak(matter_device_mdns), + }), + be_str_weak(_anonymous_), + &be_const_str_solidified, + ( &(const binstruction[10]) { /* code */ + 0x68000000, // 0000 GETUPV R0 U0 + 0x8C000100, // 0001 GETMET R0 R0 K0 + 0x50080200, // 0002 LDBOOL R2 1 0 + 0x7C000400, // 0003 CALL R0 2 + 0xB8020200, // 0004 GETNGBL R0 K1 + 0x8C000102, // 0005 GETMET R0 R0 K2 + 0x58080003, // 0006 LDCONST R2 K3 + 0x580C0004, // 0007 LDCONST R3 K4 + 0x7C000600, // 0008 CALL R0 3 + 0x80000000, // 0009 RET 0 + }) + ), + }), + 1, /* has constants */ + ( &(const bvalue[ 8]) { /* constants */ + /* K0 */ be_nested_str_weak(tasmota), + /* K1 */ be_nested_str_weak(wifi), + /* K2 */ be_nested_str_weak(up), + /* K3 */ be_nested_str_weak(_start_mdns_announce), + /* K4 */ be_nested_str_weak(add_rule), + /* K5 */ be_nested_str_weak(Wifi_X23Connected), + /* K6 */ be_nested_str_weak(eth), + /* K7 */ be_nested_str_weak(Eth_X23Connected), + }), + be_str_weak(start_mdns_announce_hostnames), + &be_const_str_solidified, + ( &(const binstruction[32]) { /* code */ + 0xB8060000, // 0000 GETNGBL R1 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0x94040302, // 0003 GETIDX R1 R1 K2 + 0x78060003, // 0004 JMPF R1 #0009 + 0x8C040103, // 0005 GETMET R1 R0 K3 + 0x500C0000, // 0006 LDBOOL R3 0 0 + 0x7C040400, // 0007 CALL R1 2 + 0x70020005, // 0008 JMP #000F + 0xB8060000, // 0009 GETNGBL R1 K0 + 0x8C040304, // 000A GETMET R1 R1 K4 + 0x580C0005, // 000B LDCONST R3 K5 + 0x84100000, // 000C CLOSURE R4 P0 + 0x5C140000, // 000D MOVE R5 R0 + 0x7C040800, // 000E CALL R1 4 + 0xB8060000, // 000F GETNGBL R1 K0 + 0x8C040306, // 0010 GETMET R1 R1 K6 + 0x7C040200, // 0011 CALL R1 1 + 0x94040302, // 0012 GETIDX R1 R1 K2 + 0x78060003, // 0013 JMPF R1 #0018 + 0x8C040103, // 0014 GETMET R1 R0 K3 + 0x500C0200, // 0015 LDBOOL R3 1 0 + 0x7C040400, // 0016 CALL R1 2 + 0x70020005, // 0017 JMP #001E + 0xB8060000, // 0018 GETNGBL R1 K0 + 0x8C040304, // 0019 GETMET R1 R1 K4 + 0x580C0007, // 001A LDCONST R3 K7 + 0x84100001, // 001B CLOSURE R4 P1 + 0x5C140000, // 001C MOVE R5 R0 + 0x7C040800, // 001D CALL R1 4 + 0xA0000000, // 001E CLOSE R0 + 0x80000000, // 001F RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: compute_manual_pairing_code +********************************************************************/ +be_local_closure(Matter_Device_compute_manual_pairing_code, /* name */ + be_nested_proto( + 11, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 8]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(discriminator), + /* K2 */ be_nested_str_weak(passcode), + /* K3 */ be_nested_str_weak(format), + /* K4 */ be_nested_str_weak(_X251i_X2505i_X2504i), + /* K5 */ be_nested_str_weak(matter), + /* K6 */ be_nested_str_weak(Verhoeff), + /* K7 */ be_nested_str_weak(checksum), + }), + be_str_weak(compute_manual_pairing_code), + &be_const_str_solidified, + ( &(const binstruction[31]) { /* code */ + 0xA4060000, // 0000 IMPORT R1 K0 + 0x88080101, // 0001 GETMBR R2 R0 K1 + 0x540E0FFE, // 0002 LDINT R3 4095 + 0x2C080403, // 0003 AND R2 R2 R3 + 0x540E0009, // 0004 LDINT R3 10 + 0x3C080403, // 0005 SHR R2 R2 R3 + 0x880C0101, // 0006 GETMBR R3 R0 K1 + 0x541202FF, // 0007 LDINT R4 768 + 0x2C0C0604, // 0008 AND R3 R3 R4 + 0x54120005, // 0009 LDINT R4 6 + 0x380C0604, // 000A SHL R3 R3 R4 + 0x88100102, // 000B GETMBR R4 R0 K2 + 0x54163FFE, // 000C LDINT R5 16383 + 0x2C100805, // 000D AND R4 R4 R5 + 0x300C0604, // 000E OR R3 R3 R4 + 0x88100102, // 000F GETMBR R4 R0 K2 + 0x5416000D, // 0010 LDINT R5 14 + 0x3C100805, // 0011 SHR R4 R4 R5 + 0x8C140303, // 0012 GETMET R5 R1 K3 + 0x581C0004, // 0013 LDCONST R7 K4 + 0x5C200400, // 0014 MOVE R8 R2 + 0x5C240600, // 0015 MOVE R9 R3 + 0x5C280800, // 0016 MOVE R10 R4 + 0x7C140A00, // 0017 CALL R5 5 + 0xB81A0A00, // 0018 GETNGBL R6 K5 + 0x88180D06, // 0019 GETMBR R6 R6 K6 + 0x8C180D07, // 001A GETMET R6 R6 K7 + 0x5C200A00, // 001B MOVE R8 R5 + 0x7C180400, // 001C CALL R6 2 + 0x00140A06, // 001D ADD R5 R5 R6 + 0x80040A00, // 001E RET 1 R5 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: start_commissioning_complete +********************************************************************/ +be_local_closure(Matter_Device_start_commissioning_complete, /* name */ + be_nested_proto( + 6, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(tasmota), + /* K1 */ be_nested_str_weak(log), + /* K2 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X20Commissioning_X20complete_X20_X2A_X2A_X2A), + /* K3 */ be_const_int(2), + }), + be_str_weak(start_commissioning_complete), + &be_const_str_solidified, + ( &(const binstruction[ 6]) { /* code */ + 0xB80A0000, // 0000 GETNGBL R2 K0 + 0x8C080501, // 0001 GETMET R2 R2 K1 + 0x58100002, // 0002 LDCONST R4 K2 + 0x58140003, // 0003 LDCONST R5 K3 + 0x7C080600, // 0004 CALL R2 3 + 0x80000000, // 0005 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: start_commissioning_complete_deferred +********************************************************************/ +be_local_closure(Matter_Device_start_commissioning_complete_deferred, /* name */ + be_nested_proto( + 6, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 1, /* has sup protos */ + ( &(const struct bproto*[ 1]) { + be_nested_proto( + 3, /* nstack */ + 0, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 2]) { /* upvals */ + be_local_const_upval(1, 0), + be_local_const_upval(1, 1), + }), + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(start_commissioning_complete), + }), + be_str_weak(_X3Clambda_X3E), + &be_const_str_solidified, + ( &(const binstruction[ 5]) { /* code */ + 0x68000000, // 0000 GETUPV R0 U0 + 0x8C000100, // 0001 GETMET R0 R0 K0 + 0x68080001, // 0002 GETUPV R2 U1 + 0x7C000400, // 0003 CALL R0 2 + 0x80040000, // 0004 RET 1 R0 + }) + ), + }), + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(tasmota), + /* K1 */ be_nested_str_weak(set_timer), + /* K2 */ be_const_int(0), + }), + be_str_weak(start_commissioning_complete_deferred), + &be_const_str_solidified, + ( &(const binstruction[ 7]) { /* code */ + 0xB80A0000, // 0000 GETNGBL R2 K0 + 0x8C080501, // 0001 GETMET R2 R2 K1 + 0x58100002, // 0002 LDCONST R4 K2 + 0x84140000, // 0003 CLOSURE R5 P0 + 0x7C080600, // 0004 CALL R2 3 + 0xA0000000, // 0005 CLOSE R0 + 0x80000000, // 0006 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: invoke_request +********************************************************************/ +be_local_closure(Matter_Device_invoke_request, /* name */ + be_nested_proto( + 11, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 7]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(plugins), + /* K2 */ be_nested_str_weak(invoke_request), + /* K3 */ be_nested_str_weak(status), + /* K4 */ be_nested_str_weak(matter), + /* K5 */ be_nested_str_weak(UNSUPPORTED_COMMAND), + /* K6 */ be_const_int(1), + }), + be_str_weak(invoke_request), + &be_const_str_solidified, + ( &(const binstruction[25]) { /* code */ + 0x58100000, // 0000 LDCONST R4 K0 + 0x6014000C, // 0001 GETGBL R5 G12 + 0x88180101, // 0002 GETMBR R6 R0 K1 + 0x7C140200, // 0003 CALL R5 1 + 0x14140805, // 0004 LT R5 R4 R5 + 0x78160011, // 0005 JMPF R5 #0018 + 0x88140101, // 0006 GETMBR R5 R0 K1 + 0x94140A04, // 0007 GETIDX R5 R5 R4 + 0x8C180B02, // 0008 GETMET R6 R5 K2 + 0x5C200200, // 0009 MOVE R8 R1 + 0x5C240400, // 000A MOVE R9 R2 + 0x5C280600, // 000B MOVE R10 R3 + 0x7C180800, // 000C CALL R6 4 + 0x4C1C0000, // 000D LDNIL R7 + 0x201C0C07, // 000E NE R7 R6 R7 + 0x741E0004, // 000F JMPT R7 #0015 + 0x881C0703, // 0010 GETMBR R7 R3 K3 + 0xB8220800, // 0011 GETNGBL R8 K4 + 0x88201105, // 0012 GETMBR R8 R8 K5 + 0x201C0E08, // 0013 NE R7 R7 R8 + 0x781E0000, // 0014 JMPF R7 #0016 + 0x80040C00, // 0015 RET 1 R6 + 0x00100906, // 0016 ADD R4 R4 K6 + 0x7001FFE8, // 0017 JMP #0001 + 0x80000000, // 0018 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: msg_received ********************************************************************/ @@ -1908,7 +1909,7 @@ be_local_closure(Matter_Device_msg_received, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(msg_handler), + /* K0 */ be_nested_str_weak(message_handler), /* K1 */ be_nested_str_weak(msg_received), }), be_str_weak(msg_received), @@ -2323,33 +2324,261 @@ be_local_closure(Matter_Device_packet_ack, /* name */ /******************************************************************** -** Solidified function: msg_send +** Solidified function: mdns_announce_op_discovery ********************************************************************/ -be_local_closure(Matter_Device_msg_send, /* name */ +be_local_closure(Matter_Device_mdns_announce_op_discovery, /* name */ be_nested_proto( - 11, /* nstack */ - 5, /* argc */ + 15, /* nstack */ + 2, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(udp_server), - /* K1 */ be_nested_str_weak(send_response), + ( &(const bvalue[29]) { /* constants */ + /* K0 */ be_nested_str_weak(mdns), + /* K1 */ be_nested_str_weak(string), + /* K2 */ be_nested_str_weak(get_deviceid), + /* K3 */ be_nested_str_weak(copy), + /* K4 */ be_nested_str_weak(reverse), + /* K5 */ be_nested_str_weak(get_fabric_compressed), + /* K6 */ be_nested_str_weak(tohex), + /* K7 */ be_nested_str_weak(_X2D), + /* K8 */ be_nested_str_weak(tasmota), + /* K9 */ be_nested_str_weak(log), + /* K10 */ be_nested_str_weak(MTR_X3A_X20Operational_X20Discovery_X20node_X20_X3D_X20), + /* K11 */ be_const_int(2), + /* K12 */ be_nested_str_weak(eth), + /* K13 */ be_nested_str_weak(find), + /* K14 */ be_nested_str_weak(up), + /* K15 */ be_nested_str_weak(format), + /* K16 */ be_nested_str_weak(MTR_X3A_X20adding_X20mDNS_X20on_X20_X25s_X20_X27_X25s_X27_X20ptr_X20to_X20_X60_X25s_X2Elocal_X60), + /* K17 */ be_nested_str_weak(hostname_eth), + /* K18 */ be_const_int(3), + /* K19 */ be_nested_str_weak(add_service), + /* K20 */ be_nested_str_weak(_matter), + /* K21 */ be_nested_str_weak(_tcp), + /* K22 */ be_nested_str_weak(_I), + /* K23 */ be_nested_str_weak(MTR_X3A_X20adding_X20subtype_X3A_X20), + /* K24 */ be_nested_str_weak(add_subtype), + /* K25 */ be_nested_str_weak(wifi), + /* K26 */ be_nested_str_weak(hostname_wifi), + /* K27 */ be_nested_str_weak(MTR_X3A_X20Exception), + /* K28 */ be_nested_str_weak(_X7C), }), - be_str_weak(msg_send), + be_str_weak(mdns_announce_op_discovery), &be_const_str_solidified, - ( &(const binstruction[ 8]) { /* code */ - 0x88140100, // 0000 GETMBR R5 R0 K0 - 0x8C140B01, // 0001 GETMET R5 R5 K1 - 0x5C1C0200, // 0002 MOVE R7 R1 - 0x5C200400, // 0003 MOVE R8 R2 - 0x5C240600, // 0004 MOVE R9 R3 - 0x5C280800, // 0005 MOVE R10 R4 - 0x7C140A00, // 0006 CALL R5 5 - 0x80040A00, // 0007 RET 1 R5 + ( &(const binstruction[122]) { /* code */ + 0xA40A0000, // 0000 IMPORT R2 K0 + 0xA40E0200, // 0001 IMPORT R3 K1 + 0xA8020064, // 0002 EXBLK 0 #0068 + 0x8C100302, // 0003 GETMET R4 R1 K2 + 0x7C100200, // 0004 CALL R4 1 + 0x8C100903, // 0005 GETMET R4 R4 K3 + 0x7C100200, // 0006 CALL R4 1 + 0x8C100904, // 0007 GETMET R4 R4 K4 + 0x7C100200, // 0008 CALL R4 1 + 0x8C140305, // 0009 GETMET R5 R1 K5 + 0x7C140200, // 000A CALL R5 1 + 0x8C180B06, // 000B GETMET R6 R5 K6 + 0x7C180200, // 000C CALL R6 1 + 0x00180D07, // 000D ADD R6 R6 K7 + 0x8C1C0906, // 000E GETMET R7 R4 K6 + 0x7C1C0200, // 000F CALL R7 1 + 0x00180C07, // 0010 ADD R6 R6 R7 + 0xB81E1000, // 0011 GETNGBL R7 K8 + 0x8C1C0F09, // 0012 GETMET R7 R7 K9 + 0x00261406, // 0013 ADD R9 K10 R6 + 0x5828000B, // 0014 LDCONST R10 K11 + 0x7C1C0600, // 0015 CALL R7 3 + 0xB81E1000, // 0016 GETNGBL R7 K8 + 0x8C1C0F0C, // 0017 GETMET R7 R7 K12 + 0x7C1C0200, // 0018 CALL R7 1 + 0x8C1C0F0D, // 0019 GETMET R7 R7 K13 + 0x5824000E, // 001A LDCONST R9 K14 + 0x7C1C0400, // 001B CALL R7 2 + 0x781E0020, // 001C JMPF R7 #003E + 0xB81E1000, // 001D GETNGBL R7 K8 + 0x8C1C0F09, // 001E GETMET R7 R7 K9 + 0x8C24070F, // 001F GETMET R9 R3 K15 + 0x582C0010, // 0020 LDCONST R11 K16 + 0x5830000C, // 0021 LDCONST R12 K12 + 0x5C340C00, // 0022 MOVE R13 R6 + 0x88380111, // 0023 GETMBR R14 R0 K17 + 0x7C240A00, // 0024 CALL R9 5 + 0x58280012, // 0025 LDCONST R10 K18 + 0x7C1C0600, // 0026 CALL R7 3 + 0x8C1C0513, // 0027 GETMET R7 R2 K19 + 0x58240014, // 0028 LDCONST R9 K20 + 0x58280015, // 0029 LDCONST R10 K21 + 0x542E15A3, // 002A LDINT R11 5540 + 0x4C300000, // 002B LDNIL R12 + 0x5C340C00, // 002C MOVE R13 R6 + 0x88380111, // 002D GETMBR R14 R0 K17 + 0x7C1C0E00, // 002E CALL R7 7 + 0x8C1C0B06, // 002F GETMET R7 R5 K6 + 0x7C1C0200, // 0030 CALL R7 1 + 0x001E2C07, // 0031 ADD R7 K22 R7 + 0xB8221000, // 0032 GETNGBL R8 K8 + 0x8C201109, // 0033 GETMET R8 R8 K9 + 0x002A2E07, // 0034 ADD R10 K23 R7 + 0x582C0012, // 0035 LDCONST R11 K18 + 0x7C200600, // 0036 CALL R8 3 + 0x8C200518, // 0037 GETMET R8 R2 K24 + 0x58280014, // 0038 LDCONST R10 K20 + 0x582C0015, // 0039 LDCONST R11 K21 + 0x5C300C00, // 003A MOVE R12 R6 + 0x88340111, // 003B GETMBR R13 R0 K17 + 0x5C380E00, // 003C MOVE R14 R7 + 0x7C200C00, // 003D CALL R8 6 + 0xB81E1000, // 003E GETNGBL R7 K8 + 0x8C1C0F19, // 003F GETMET R7 R7 K25 + 0x7C1C0200, // 0040 CALL R7 1 + 0x8C1C0F0D, // 0041 GETMET R7 R7 K13 + 0x5824000E, // 0042 LDCONST R9 K14 + 0x7C1C0400, // 0043 CALL R7 2 + 0x781E0020, // 0044 JMPF R7 #0066 + 0xB81E1000, // 0045 GETNGBL R7 K8 + 0x8C1C0F09, // 0046 GETMET R7 R7 K9 + 0x8C24070F, // 0047 GETMET R9 R3 K15 + 0x582C0010, // 0048 LDCONST R11 K16 + 0x58300019, // 0049 LDCONST R12 K25 + 0x5C340C00, // 004A MOVE R13 R6 + 0x8838011A, // 004B GETMBR R14 R0 K26 + 0x7C240A00, // 004C CALL R9 5 + 0x58280012, // 004D LDCONST R10 K18 + 0x7C1C0600, // 004E CALL R7 3 + 0x8C1C0513, // 004F GETMET R7 R2 K19 + 0x58240014, // 0050 LDCONST R9 K20 + 0x58280015, // 0051 LDCONST R10 K21 + 0x542E15A3, // 0052 LDINT R11 5540 + 0x4C300000, // 0053 LDNIL R12 + 0x5C340C00, // 0054 MOVE R13 R6 + 0x8838011A, // 0055 GETMBR R14 R0 K26 + 0x7C1C0E00, // 0056 CALL R7 7 + 0x8C1C0B06, // 0057 GETMET R7 R5 K6 + 0x7C1C0200, // 0058 CALL R7 1 + 0x001E2C07, // 0059 ADD R7 K22 R7 + 0xB8221000, // 005A GETNGBL R8 K8 + 0x8C201109, // 005B GETMET R8 R8 K9 + 0x002A2E07, // 005C ADD R10 K23 R7 + 0x582C0012, // 005D LDCONST R11 K18 + 0x7C200600, // 005E CALL R8 3 + 0x8C200518, // 005F GETMET R8 R2 K24 + 0x58280014, // 0060 LDCONST R10 K20 + 0x582C0015, // 0061 LDCONST R11 K21 + 0x5C300C00, // 0062 MOVE R12 R6 + 0x8834011A, // 0063 GETMBR R13 R0 K26 + 0x5C380E00, // 0064 MOVE R14 R7 + 0x7C200C00, // 0065 CALL R8 6 + 0xA8040001, // 0066 EXBLK 1 1 + 0x70020010, // 0067 JMP #0079 + 0xAC100002, // 0068 CATCH R4 0 2 + 0x7002000D, // 0069 JMP #0078 + 0xB81A1000, // 006A GETNGBL R6 K8 + 0x8C180D09, // 006B GETMET R6 R6 K9 + 0x60200008, // 006C GETGBL R8 G8 + 0x5C240800, // 006D MOVE R9 R4 + 0x7C200200, // 006E CALL R8 1 + 0x00223608, // 006F ADD R8 K27 R8 + 0x0020111C, // 0070 ADD R8 R8 K28 + 0x60240008, // 0071 GETGBL R9 G8 + 0x5C280A00, // 0072 MOVE R10 R5 + 0x7C240200, // 0073 CALL R9 1 + 0x00201009, // 0074 ADD R8 R8 R9 + 0x5824000B, // 0075 LDCONST R9 K11 + 0x7C180600, // 0076 CALL R6 3 + 0x70020000, // 0077 JMP #0079 + 0xB0080000, // 0078 RAISE 2 R0 R0 + 0x80000000, // 0079 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: start_udp +********************************************************************/ +be_local_closure(Matter_Device_start_udp, /* name */ + be_nested_proto( + 6, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 1, /* has sup protos */ + ( &(const struct bproto*[ 1]) { + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 1]) { /* upvals */ + be_local_const_upval(1, 0), + }), + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(msg_received), + }), + be_str_weak(_X3Clambda_X3E), + &be_const_str_solidified, + ( &(const binstruction[ 7]) { /* code */ + 0x680C0000, // 0000 GETUPV R3 U0 + 0x8C0C0700, // 0001 GETMET R3 R3 K0 + 0x5C140000, // 0002 MOVE R5 R0 + 0x5C180200, // 0003 MOVE R6 R1 + 0x5C1C0400, // 0004 MOVE R7 R2 + 0x7C0C0800, // 0005 CALL R3 4 + 0x80040600, // 0006 RET 1 R3 + }) + ), + }), + 1, /* has constants */ + ( &(const bvalue[ 9]) { /* constants */ + /* K0 */ be_nested_str_weak(udp_server), + /* K1 */ be_nested_str_weak(tasmota), + /* K2 */ be_nested_str_weak(log), + /* K3 */ be_nested_str_weak(MTR_X3A_X20starting_X20UDP_X20server_X20on_X20port_X3A_X20), + /* K4 */ be_const_int(2), + /* K5 */ be_nested_str_weak(matter), + /* K6 */ be_nested_str_weak(UDPServer), + /* K7 */ be_nested_str_weak(), + /* K8 */ be_nested_str_weak(start), + }), + be_str_weak(start_udp), + &be_const_str_solidified, + ( &(const binstruction[27]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x780A0000, // 0001 JMPF R2 #0003 + 0x80000400, // 0002 RET 0 + 0x4C080000, // 0003 LDNIL R2 + 0x1C080202, // 0004 EQ R2 R1 R2 + 0x780A0000, // 0005 JMPF R2 #0007 + 0x540615A3, // 0006 LDINT R1 5540 + 0xB80A0200, // 0007 GETNGBL R2 K1 + 0x8C080502, // 0008 GETMET R2 R2 K2 + 0x60100008, // 0009 GETGBL R4 G8 + 0x5C140200, // 000A MOVE R5 R1 + 0x7C100200, // 000B CALL R4 1 + 0x00120604, // 000C ADD R4 K3 R4 + 0x58140004, // 000D LDCONST R5 K4 + 0x7C080600, // 000E CALL R2 3 + 0xB80A0A00, // 000F GETNGBL R2 K5 + 0x8C080506, // 0010 GETMET R2 R2 K6 + 0x58100007, // 0011 LDCONST R4 K7 + 0x5C140200, // 0012 MOVE R5 R1 + 0x7C080600, // 0013 CALL R2 3 + 0x90020002, // 0014 SETMBR R0 K0 R2 + 0x88080100, // 0015 GETMBR R2 R0 K0 + 0x8C080508, // 0016 GETMET R2 R2 K8 + 0x84100000, // 0017 CLOSURE R4 P0 + 0x7C080400, // 0018 CALL R2 2 + 0xA0000000, // 0019 CLOSE R0 + 0x80000000, // 001A RET 0 }) ) ); @@ -2362,57 +2591,58 @@ be_local_closure(Matter_Device_msg_send, /* name */ be_local_class(Matter_Device, 18, NULL, - be_nested_map(49, + be_nested_map(50, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(compute_manual_pairing_code, 12), be_const_closure(Matter_Device_compute_manual_pairing_code_closure) }, - { be_const_key_weak(msg_handler, 45), be_const_var(2) }, - { be_const_key_weak(FILENAME, 20), be_nested_str_weak(_matter_device_X2Ejson) }, - { be_const_key_weak(plugins, 40), be_const_var(0) }, - { be_const_key_weak(process_attribute_expansion, -1), be_const_closure(Matter_Device_process_attribute_expansion_closure) }, - { be_const_key_weak(msg_send, -1), be_const_closure(Matter_Device_msg_send_closure) }, - { be_const_key_weak(packet_ack, -1), be_const_closure(Matter_Device_packet_ack_closure) }, - { be_const_key_weak(save_param, 48), be_const_closure(Matter_Device_save_param_closure) }, - { be_const_key_weak(_start_mdns_announce, -1), be_const_closure(Matter_Device__start_mdns_announce_closure) }, - { be_const_key_weak(start_operational_dicovery_deferred, -1), be_const_closure(Matter_Device_start_operational_dicovery_deferred_closure) }, - { be_const_key_weak(ui, 47), be_const_var(4) }, - { be_const_key_weak(w0, -1), be_const_var(15) }, - { be_const_key_weak(invoke_request, -1), be_const_closure(Matter_Device_invoke_request_closure) }, - { be_const_key_weak(passcode, 15), be_const_var(12) }, - { be_const_key_weak(start_mdns_announce_hostnames, -1), be_const_closure(Matter_Device_start_mdns_announce_hostnames_closure) }, - { be_const_key_weak(hostname_eth, 31), be_const_var(8) }, - { be_const_key_weak(L, -1), be_const_var(17) }, - { be_const_key_weak(every_second, 8), be_const_closure(Matter_Device_every_second_closure) }, - { be_const_key_weak(VENDOR_ID, -1), be_const_int(65521) }, - { be_const_key_weak(init, -1), be_const_closure(Matter_Device_init_closure) }, - { be_const_key_weak(get_active_endpoints, -1), be_const_closure(Matter_Device_get_active_endpoints_closure) }, - { be_const_key_weak(iterations, 43), be_const_var(13) }, - { be_const_key_weak(commissioning_instance_eth, -1), be_const_var(6) }, - { be_const_key_weak(start_operational_dicovery, 41), be_const_closure(Matter_Device_start_operational_dicovery_closure) }, - { be_const_key_weak(start_commissioning_complete, 16), be_const_closure(Matter_Device_start_commissioning_complete_closure) }, - { be_const_key_weak(start_basic_commissioning, 42), be_const_closure(Matter_Device_start_basic_commissioning_closure) }, - { be_const_key_weak(productid, -1), be_const_var(10) }, - { be_const_key_weak(PRODUCT_ID, -1), be_const_int(32768) }, - { be_const_key_weak(PBKDF_ITERATIONS, 36), be_const_int(1000) }, - { be_const_key_weak(salt, 5), be_const_var(14) }, - { be_const_key_weak(w1, -1), be_const_var(16) }, - { be_const_key_weak(start_commissioning_complete_deferred, -1), be_const_closure(Matter_Device_start_commissioning_complete_deferred_closure) }, - { be_const_key_weak(mdns_announce_op_discovery, 27), be_const_closure(Matter_Device_mdns_announce_op_discovery_closure) }, - { be_const_key_weak(discriminator, -1), be_const_var(11) }, - { be_const_key_weak(commissioning_instance_wifi, -1), be_const_var(5) }, - { be_const_key_weak(start_udp, 34), be_const_closure(Matter_Device_start_udp_closure) }, - { be_const_key_weak(UDP_PORT, -1), be_const_int(5540) }, - { be_const_key_weak(compute_pbkdf, -1), be_const_closure(Matter_Device_compute_pbkdf_closure) }, - { be_const_key_weak(hostname_wifi, -1), be_const_var(7) }, - { be_const_key_weak(udp_server, 2), be_const_var(1) }, - { be_const_key_weak(finish_commissioning, -1), be_const_closure(Matter_Device_finish_commissioning_closure) }, - { be_const_key_weak(compute_qrcode_content, -1), be_const_closure(Matter_Device_compute_qrcode_content_closure) }, - { be_const_key_weak(PASSCODE_DEFAULT, -1), be_const_int(20202021) }, - { be_const_key_weak(vendorid, 44), be_const_var(9) }, - { be_const_key_weak(sessions, -1), be_const_var(3) }, { be_const_key_weak(mdns_announce_op_discovery_all_sessions, -1), be_const_closure(Matter_Device_mdns_announce_op_discovery_all_sessions_closure) }, - { be_const_key_weak(msg_received, 6), be_const_closure(Matter_Device_msg_received_closure) }, - { be_const_key_weak(stop, -1), be_const_closure(Matter_Device_stop_closure) }, + { be_const_key_weak(salt, 31), be_const_var(14) }, + { be_const_key_weak(start_operational_dicovery, -1), be_const_closure(Matter_Device_start_operational_dicovery_closure) }, + { be_const_key_weak(w1, -1), be_const_var(16) }, + { be_const_key_weak(L, -1), be_const_var(17) }, + { be_const_key_weak(init, 42), be_const_closure(Matter_Device_init_closure) }, + { be_const_key_weak(compute_pbkdf, 12), be_const_closure(Matter_Device_compute_pbkdf_closure) }, + { be_const_key_weak(ui, 4), be_const_var(4) }, + { be_const_key_weak(UDP_PORT, -1), be_const_int(5540) }, + { be_const_key_weak(PASSCODE_DEFAULT, -1), be_const_int(20202021) }, + { be_const_key_weak(start_operational_dicovery_deferred, 43), be_const_closure(Matter_Device_start_operational_dicovery_deferred_closure) }, + { be_const_key_weak(productid, -1), be_const_var(10) }, + { be_const_key_weak(hostname_wifi, -1), be_const_var(7) }, + { be_const_key_weak(msg_send, -1), be_const_closure(Matter_Device_msg_send_closure) }, + { be_const_key_weak(finish_commissioning, -1), be_const_closure(Matter_Device_finish_commissioning_closure) }, + { be_const_key_weak(every_second, 27), be_const_closure(Matter_Device_every_second_closure) }, + { be_const_key_weak(commissioning_instance_wifi, -1), be_const_var(5) }, + { be_const_key_weak(stop, 29), be_const_closure(Matter_Device_stop_closure) }, + { be_const_key_weak(start_basic_commissioning, -1), be_const_closure(Matter_Device_start_basic_commissioning_closure) }, { be_const_key_weak(load_param, -1), be_const_closure(Matter_Device_load_param_closure) }, + { be_const_key_weak(udp_server, -1), be_const_var(1) }, + { be_const_key_weak(plugins, -1), be_const_var(0) }, + { be_const_key_weak(FILENAME, 26), be_nested_str_weak(_matter_device_X2Ejson) }, + { be_const_key_weak(process_attribute_expansion, 30), be_const_closure(Matter_Device_process_attribute_expansion_closure) }, + { be_const_key_weak(PRODUCT_ID, -1), be_const_int(32768) }, + { be_const_key_weak(iterations, -1), be_const_var(13) }, + { be_const_key_weak(mdns_announce_op_discovery, 32), be_const_closure(Matter_Device_mdns_announce_op_discovery_closure) }, + { be_const_key_weak(passcode, -1), be_const_var(12) }, + { be_const_key_weak(sessions, -1), be_const_var(3) }, + { be_const_key_weak(compute_qrcode_content, -1), be_const_closure(Matter_Device_compute_qrcode_content_closure) }, + { be_const_key_weak(packet_ack, -1), be_const_closure(Matter_Device_packet_ack_closure) }, + { be_const_key_weak(_start_mdns_announce, 36), be_const_closure(Matter_Device__start_mdns_announce_closure) }, + { be_const_key_weak(vendorid, 45), be_const_var(9) }, + { be_const_key_weak(discriminator, -1), be_const_var(11) }, + { be_const_key_weak(w0, -1), be_const_var(15) }, + { be_const_key_weak(start_commissioning_complete, -1), be_const_closure(Matter_Device_start_commissioning_complete_closure) }, + { be_const_key_weak(VENDOR_ID, -1), be_const_int(65521) }, + { be_const_key_weak(get_active_endpoints, 41), be_const_closure(Matter_Device_get_active_endpoints_closure) }, + { be_const_key_weak(msg_received, -1), be_const_closure(Matter_Device_msg_received_closure) }, + { be_const_key_weak(start_mdns_announce_hostnames, 40), be_const_closure(Matter_Device_start_mdns_announce_hostnames_closure) }, + { be_const_key_weak(message_handler, -1), be_const_var(2) }, + { be_const_key_weak(invoke_request, -1), be_const_closure(Matter_Device_invoke_request_closure) }, + { be_const_key_weak(start_commissioning_complete_deferred, -1), be_const_closure(Matter_Device_start_commissioning_complete_deferred_closure) }, + { be_const_key_weak(compute_manual_pairing_code, -1), be_const_closure(Matter_Device_compute_manual_pairing_code_closure) }, + { be_const_key_weak(hostname_eth, -1), be_const_var(8) }, + { be_const_key_weak(commissioning_instance_eth, 46), be_const_var(6) }, + { be_const_key_weak(sort_distinct, -1), be_const_static_closure(Matter_Device_sort_distinct_closure) }, + { be_const_key_weak(start_udp, -1), be_const_closure(Matter_Device_start_udp_closure) }, + { be_const_key_weak(save_param, 8), be_const_closure(Matter_Device_save_param_closure) }, + { be_const_key_weak(PBKDF_ITERATIONS, -1), be_const_int(1000) }, })), be_str_weak(Matter_Device) ); 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 1e828f15b..75e7dbe16 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h @@ -4,282 +4,40 @@ \********************************************************************/ #include "be_constobj.h" -extern const bclass be_class_Matter_Response_container; - -/******************************************************************** -** Solidified function: tostring -********************************************************************/ -be_local_closure(Matter_Response_container_tostring, /* name */ - be_nested_proto( - 7, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[14]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(), - /* K2 */ be_nested_str_weak(endpoint), - /* K3 */ be_nested_str_weak(format), - /* K4 */ be_nested_str_weak(_X5B_X2502X_X5D), - /* K5 */ be_nested_str_weak(_X5B_X2A_X2A_X5D), - /* K6 */ be_nested_str_weak(cluster), - /* K7 */ be_nested_str_weak(_X2504X_X2F), - /* K8 */ be_nested_str_weak(_X2A_X2A_X2A_X2A_X2F), - /* K9 */ be_nested_str_weak(attribute), - /* K10 */ be_nested_str_weak(_X2504X), - /* K11 */ be_nested_str_weak(command), - /* K12 */ be_nested_str_weak(Exception_X3E_X20), - /* K13 */ be_nested_str_weak(_X2C_X20), - }), - be_str_weak(tostring), - &be_const_str_solidified, - ( &(const binstruction[66]) { /* code */ - 0xA8020031, // 0000 EXBLK 0 #0033 - 0xA4060000, // 0001 IMPORT R1 K0 - 0x58080001, // 0002 LDCONST R2 K1 - 0x880C0102, // 0003 GETMBR R3 R0 K2 - 0x4C100000, // 0004 LDNIL R4 - 0x200C0604, // 0005 NE R3 R3 R4 - 0x780E0004, // 0006 JMPF R3 #000C - 0x8C0C0303, // 0007 GETMET R3 R1 K3 - 0x58140004, // 0008 LDCONST R5 K4 - 0x88180102, // 0009 GETMBR R6 R0 K2 - 0x7C0C0600, // 000A CALL R3 3 - 0x70020000, // 000B JMP #000D - 0x580C0005, // 000C LDCONST R3 K5 - 0x00080403, // 000D ADD R2 R2 R3 - 0x880C0106, // 000E GETMBR R3 R0 K6 - 0x4C100000, // 000F LDNIL R4 - 0x200C0604, // 0010 NE R3 R3 R4 - 0x780E0004, // 0011 JMPF R3 #0017 - 0x8C0C0303, // 0012 GETMET R3 R1 K3 - 0x58140007, // 0013 LDCONST R5 K7 - 0x88180106, // 0014 GETMBR R6 R0 K6 - 0x7C0C0600, // 0015 CALL R3 3 - 0x70020000, // 0016 JMP #0018 - 0x580C0008, // 0017 LDCONST R3 K8 - 0x00080403, // 0018 ADD R2 R2 R3 - 0x880C0109, // 0019 GETMBR R3 R0 K9 - 0x4C100000, // 001A LDNIL R4 - 0x200C0604, // 001B NE R3 R3 R4 - 0x780E0004, // 001C JMPF R3 #0022 - 0x8C0C0303, // 001D GETMET R3 R1 K3 - 0x5814000A, // 001E LDCONST R5 K10 - 0x88180109, // 001F GETMBR R6 R0 K9 - 0x7C0C0600, // 0020 CALL R3 3 - 0x70020000, // 0021 JMP #0023 - 0x580C0001, // 0022 LDCONST R3 K1 - 0x00080403, // 0023 ADD R2 R2 R3 - 0x880C010B, // 0024 GETMBR R3 R0 K11 - 0x4C100000, // 0025 LDNIL R4 - 0x200C0604, // 0026 NE R3 R3 R4 - 0x780E0004, // 0027 JMPF R3 #002D - 0x8C0C0303, // 0028 GETMET R3 R1 K3 - 0x5814000A, // 0029 LDCONST R5 K10 - 0x88180109, // 002A GETMBR R6 R0 K9 - 0x7C0C0600, // 002B CALL R3 3 - 0x70020000, // 002C JMP #002E - 0x580C0001, // 002D LDCONST R3 K1 - 0x00080403, // 002E ADD R2 R2 R3 - 0xA8040001, // 002F EXBLK 1 1 - 0x80040400, // 0030 RET 1 R2 - 0xA8040001, // 0031 EXBLK 1 1 - 0x7002000D, // 0032 JMP #0041 - 0xAC040002, // 0033 CATCH R1 0 2 - 0x7002000A, // 0034 JMP #0040 - 0x600C0008, // 0035 GETGBL R3 G8 - 0x5C100200, // 0036 MOVE R4 R1 - 0x7C0C0200, // 0037 CALL R3 1 - 0x000E1803, // 0038 ADD R3 K12 R3 - 0x000C070D, // 0039 ADD R3 R3 K13 - 0x60100008, // 003A GETGBL R4 G8 - 0x5C140400, // 003B MOVE R5 R2 - 0x7C100200, // 003C CALL R4 1 - 0x000C0604, // 003D ADD R3 R3 R4 - 0x80040600, // 003E RET 1 R3 - 0x70020000, // 003F JMP #0041 - 0xB0080000, // 0040 RAISE 2 R0 R0 - 0x80000000, // 0041 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified class: Matter_Response_container -********************************************************************/ -be_local_class(Matter_Response_container, - 5, - NULL, - be_nested_map(6, - ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(tostring, -1), be_const_closure(Matter_Response_container_tostring_closure) }, - { be_const_key_weak(cluster, 3), be_const_var(1) }, - { be_const_key_weak(command, -1), be_const_var(3) }, - { be_const_key_weak(status, 0), be_const_var(4) }, - { be_const_key_weak(endpoint, -1), be_const_var(0) }, - { be_const_key_weak(attribute, -1), be_const_var(2) }, - })), - be_str_weak(Matter_Response_container) -); -/*******************************************************************/ - -void be_load_Matter_Response_container_class(bvm *vm) { - be_pushntvclass(vm, &be_class_Matter_Response_container); - be_setglobal(vm, "Matter_Response_container"); - be_pop(vm, 1); -} - extern const bclass be_class_Matter_IM; /******************************************************************** -** Solidified function: process_timed_request +** Solidified function: send_subscribe_response ********************************************************************/ -be_local_closure(Matter_IM_process_timed_request, /* name */ - be_nested_proto( - 13, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[26]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(TimedRequestMessage), - /* K3 */ be_nested_str_weak(from_TLV), - /* K4 */ be_nested_str_weak(tasmota), - /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20TimedRequestMessage_X3D), - /* K7 */ be_const_int(3), - /* K8 */ be_nested_str_weak(format), - /* K9 */ be_nested_str_weak(MTR_X3A_X20_X3EReceived_IM_X20_X20_X20TimedRequest_X3D_X25i_X20from_X20_X5B_X25s_X5D_X3A_X25i), - /* K10 */ be_nested_str_weak(timeout), - /* K11 */ be_nested_str_weak(remote_ip), - /* K12 */ be_nested_str_weak(remote_port), - /* K13 */ be_const_int(2), - /* K14 */ be_nested_str_weak(StatusResponseMessage), - /* K15 */ be_nested_str_weak(status), - /* K16 */ be_nested_str_weak(SUCCESS), - /* K17 */ be_nested_str_weak(build_response), - /* K18 */ be_const_int(1), - /* K19 */ be_nested_str_weak(encode), - /* K20 */ be_nested_str_weak(to_TLV), - /* K21 */ be_nested_str_weak(encrypt), - /* K22 */ be_nested_str_weak(responder), - /* K23 */ be_nested_str_weak(send_response), - /* K24 */ be_nested_str_weak(raw), - /* K25 */ be_nested_str_weak(message_counter), - }), - be_str_weak(process_timed_request), - &be_const_str_solidified, - ( &(const binstruction[52]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0xB8120200, // 0001 GETNGBL R4 K1 - 0x8C100902, // 0002 GETMET R4 R4 K2 - 0x7C100200, // 0003 CALL R4 1 - 0x8C100903, // 0004 GETMET R4 R4 K3 - 0x5C180400, // 0005 MOVE R6 R2 - 0x7C100400, // 0006 CALL R4 2 - 0xB8160800, // 0007 GETNGBL R5 K4 - 0x8C140B05, // 0008 GETMET R5 R5 K5 - 0x601C0008, // 0009 GETGBL R7 G8 - 0x5C200800, // 000A MOVE R8 R4 - 0x7C1C0200, // 000B CALL R7 1 - 0x001E0C07, // 000C ADD R7 K6 R7 - 0x58200007, // 000D LDCONST R8 K7 - 0x7C140600, // 000E CALL R5 3 - 0xB8160800, // 000F GETNGBL R5 K4 - 0x8C140B05, // 0010 GETMET R5 R5 K5 - 0x8C1C0708, // 0011 GETMET R7 R3 K8 - 0x58240009, // 0012 LDCONST R9 K9 - 0x8828090A, // 0013 GETMBR R10 R4 K10 - 0x882C030B, // 0014 GETMBR R11 R1 K11 - 0x8830030C, // 0015 GETMBR R12 R1 K12 - 0x7C1C0A00, // 0016 CALL R7 5 - 0x5820000D, // 0017 LDCONST R8 K13 - 0x7C140600, // 0018 CALL R5 3 - 0xB8160200, // 0019 GETNGBL R5 K1 - 0x8C140B0E, // 001A GETMET R5 R5 K14 - 0x7C140200, // 001B CALL R5 1 - 0xB81A0200, // 001C GETNGBL R6 K1 - 0x88180D10, // 001D GETMBR R6 R6 K16 - 0x90161E06, // 001E SETMBR R5 K15 R6 - 0x8C180311, // 001F GETMET R6 R1 K17 - 0x58200012, // 0020 LDCONST R8 K18 - 0x50240200, // 0021 LDBOOL R9 1 0 - 0x7C180600, // 0022 CALL R6 3 - 0x8C1C0D13, // 0023 GETMET R7 R6 K19 - 0x8C240B14, // 0024 GETMET R9 R5 K20 - 0x7C240200, // 0025 CALL R9 1 - 0x8C241313, // 0026 GETMET R9 R9 K19 - 0x7C240200, // 0027 CALL R9 1 - 0x7C1C0400, // 0028 CALL R7 2 - 0x8C1C0D15, // 0029 GETMET R7 R6 K21 - 0x7C1C0200, // 002A CALL R7 1 - 0x881C0116, // 002B GETMBR R7 R0 K22 - 0x8C1C0F17, // 002C GETMET R7 R7 K23 - 0x88240D18, // 002D GETMBR R9 R6 K24 - 0x8828030B, // 002E GETMBR R10 R1 K11 - 0x882C030C, // 002F GETMBR R11 R1 K12 - 0x88300D19, // 0030 GETMBR R12 R6 K25 - 0x7C1C0A00, // 0031 CALL R7 5 - 0x501C0200, // 0032 LDBOOL R7 1 0 - 0x80040E00, // 0033 RET 1 R7 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: process_status_response -********************************************************************/ -be_local_closure(Matter_IM_process_status_response, /* name */ +be_local_closure(Matter_IM_send_subscribe_response, /* name */ be_nested_proto( 11, /* nstack */ - 3, /* argc */ + 4, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 8]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(findsubval), - /* K2 */ be_const_int(0), - /* K3 */ be_nested_str_weak(tasmota), - /* K4 */ be_nested_str_weak(log), - /* K5 */ be_nested_str_weak(format), - /* K6 */ be_nested_str_weak(MTR_X3A_X20Status_X20Response_X20_X3D_X200x_X2502X), - /* K7 */ be_const_int(3), + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(send_queue), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(IM_SubscribeResponse), }), - be_str_weak(process_status_response), + be_str_weak(send_subscribe_response), &be_const_str_solidified, - ( &(const binstruction[15]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0x8C100501, // 0001 GETMET R4 R2 K1 - 0x58180002, // 0002 LDCONST R6 K2 - 0x541E00FE, // 0003 LDINT R7 255 - 0x7C100600, // 0004 CALL R4 3 - 0xB8160600, // 0005 GETNGBL R5 K3 - 0x8C140B04, // 0006 GETMET R5 R5 K4 - 0x8C1C0705, // 0007 GETMET R7 R3 K5 - 0x58240006, // 0008 LDCONST R9 K6 - 0x5C280800, // 0009 MOVE R10 R4 - 0x7C1C0600, // 000A CALL R7 3 - 0x58200007, // 000B LDCONST R8 K7 - 0x7C140600, // 000C CALL R5 3 - 0x50140200, // 000D LDBOOL R5 1 0 - 0x80040A00, // 000E RET 1 R5 + ( &(const binstruction[10]) { /* code */ + 0x88100100, // 0000 GETMBR R4 R0 K0 + 0x8C100901, // 0001 GETMET R4 R4 K1 + 0xB81A0400, // 0002 GETNGBL R6 K2 + 0x8C180D03, // 0003 GETMET R6 R6 K3 + 0x5C200200, // 0004 MOVE R8 R1 + 0x5C240400, // 0005 MOVE R9 R2 + 0x5C280600, // 0006 MOVE R10 R3 + 0x7C180800, // 0007 CALL R6 4 + 0x7C100400, // 0008 CALL R4 2 + 0x80000000, // 0009 RET 0 }) ) ); @@ -287,55 +45,226 @@ be_local_closure(Matter_IM_process_status_response, /* name */ /******************************************************************** -** Solidified function: every_second +** Solidified function: process_write_request ********************************************************************/ -be_local_closure(Matter_IM_every_second, /* name */ +be_local_closure(Matter_IM_process_write_request, /* name */ be_nested_proto( - 1, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 0, /* has constants */ - NULL, /* no const */ - be_str_weak(every_second), - &be_const_str_solidified, - ( &(const binstruction[ 1]) { /* code */ - 0x80000000, // 0000 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: report_data -********************************************************************/ -be_local_closure(Matter_IM_report_data, /* name */ - be_nested_proto( - 9, /* nstack */ + 20, /* nstack */ 3, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ + 1, /* has sup protos */ + ( &(const struct bproto*[ 2]) { + be_nested_proto( + 19, /* nstack */ + 5, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 1]) { /* upvals */ + be_local_const_upval(1, 1), + }), + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[25]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(get_attribute_name), + /* K3 */ be_nested_str_weak(cluster), + /* K4 */ be_nested_str_weak(attribute), + /* K5 */ be_nested_str_weak(_X20_X28), + /* K6 */ be_nested_str_weak(_X29), + /* K7 */ be_nested_str_weak(), + /* K8 */ be_nested_str_weak(status), + /* K9 */ be_nested_str_weak(UNSUPPORTED_WRITE), + /* K10 */ be_nested_str_weak(write_attribute), + /* K11 */ be_nested_str_weak(SUCCESS), + /* K12 */ be_nested_str_weak(AttributeStatusIB), + /* K13 */ be_nested_str_weak(path), + /* K14 */ be_nested_str_weak(AttributePathIB), + /* K15 */ be_nested_str_weak(StatusIB), + /* K16 */ be_nested_str_weak(endpoint), + /* K17 */ be_nested_str_weak(write_responses), + /* K18 */ be_nested_str_weak(push), + /* K19 */ be_nested_str_weak(tasmota), + /* K20 */ be_nested_str_weak(log), + /* K21 */ be_nested_str_weak(format), + /* K22 */ be_nested_str_weak(MTR_X3A_X20Write_Attr_X20_X25s_X25s_X20_X2D_X20STATUS_X3A_X200x_X2502X_X20_X25s), + /* K23 */ be_const_int(2), + /* K24 */ be_nested_str_weak(MTR_X3A_X20Write_Attr_X20_X25s_X25s_X20_X2D_X20IGNORED), + }), + be_str_weak(write_single_attribute), + &be_const_str_solidified, + ( &(const binstruction[96]) { /* code */ + 0xA4160000, // 0000 IMPORT R5 K0 + 0xB81A0200, // 0001 GETNGBL R6 K1 + 0x8C180D02, // 0002 GETMET R6 R6 K2 + 0x88200503, // 0003 GETMBR R8 R2 K3 + 0x88240504, // 0004 GETMBR R9 R2 K4 + 0x7C180600, // 0005 CALL R6 3 + 0x781A0002, // 0006 JMPF R6 #000A + 0x001E0A06, // 0007 ADD R7 K5 R6 + 0x001C0F06, // 0008 ADD R7 R7 K6 + 0x70020000, // 0009 JMP #000B + 0x581C0007, // 000A LDCONST R7 K7 + 0x5C180E00, // 000B MOVE R6 R7 + 0xB81E0200, // 000C GETNGBL R7 K1 + 0x881C0F09, // 000D GETMBR R7 R7 K9 + 0x900A1007, // 000E SETMBR R2 K8 R7 + 0x4C1C0000, // 000F LDNIL R7 + 0x201C0207, // 0010 NE R7 R1 R7 + 0x781E0005, // 0011 JMPF R7 #0018 + 0x8C1C030A, // 0012 GETMET R7 R1 K10 + 0x68240000, // 0013 GETUPV R9 U0 + 0x5C280400, // 0014 MOVE R10 R2 + 0x5C2C0600, // 0015 MOVE R11 R3 + 0x7C1C0800, // 0016 CALL R7 4 + 0x70020000, // 0017 JMP #0019 + 0x4C1C0000, // 0018 LDNIL R7 + 0x781E0002, // 0019 JMPF R7 #001D + 0xB8220200, // 001A GETNGBL R8 K1 + 0x8820110B, // 001B GETMBR R8 R8 K11 + 0x900A1008, // 001C SETMBR R2 K8 R8 + 0x88200508, // 001D GETMBR R8 R2 K8 + 0x4C240000, // 001E LDNIL R9 + 0x20201009, // 001F NE R8 R8 R9 + 0x78220032, // 0020 JMPF R8 #0054 + 0x78120030, // 0021 JMPF R4 #0053 + 0xB8220200, // 0022 GETNGBL R8 K1 + 0x8C20110C, // 0023 GETMET R8 R8 K12 + 0x7C200200, // 0024 CALL R8 1 + 0xB8260200, // 0025 GETNGBL R9 K1 + 0x8C24130E, // 0026 GETMET R9 R9 K14 + 0x7C240200, // 0027 CALL R9 1 + 0x90221A09, // 0028 SETMBR R8 K13 R9 + 0xB8260200, // 0029 GETNGBL R9 K1 + 0x8C24130F, // 002A GETMET R9 R9 K15 + 0x7C240200, // 002B CALL R9 1 + 0x90221009, // 002C SETMBR R8 K8 R9 + 0x8824110D, // 002D GETMBR R9 R8 K13 + 0x88280510, // 002E GETMBR R10 R2 K16 + 0x9026200A, // 002F SETMBR R9 K16 R10 + 0x8824110D, // 0030 GETMBR R9 R8 K13 + 0x88280503, // 0031 GETMBR R10 R2 K3 + 0x9026060A, // 0032 SETMBR R9 K3 R10 + 0x8824110D, // 0033 GETMBR R9 R8 K13 + 0x88280504, // 0034 GETMBR R10 R2 K4 + 0x9026080A, // 0035 SETMBR R9 K4 R10 + 0x88241108, // 0036 GETMBR R9 R8 K8 + 0x88280508, // 0037 GETMBR R10 R2 K8 + 0x9026100A, // 0038 SETMBR R9 K8 R10 + 0x88240111, // 0039 GETMBR R9 R0 K17 + 0x8C241312, // 003A GETMET R9 R9 K18 + 0x5C2C1000, // 003B MOVE R11 R8 + 0x7C240400, // 003C CALL R9 2 + 0xB8262600, // 003D GETNGBL R9 K19 + 0x8C241314, // 003E GETMET R9 R9 K20 + 0x8C2C0B15, // 003F GETMET R11 R5 K21 + 0x58340016, // 0040 LDCONST R13 K22 + 0x60380008, // 0041 GETGBL R14 G8 + 0x5C3C0400, // 0042 MOVE R15 R2 + 0x7C380200, // 0043 CALL R14 1 + 0x5C3C0C00, // 0044 MOVE R15 R6 + 0x88400508, // 0045 GETMBR R16 R2 K8 + 0x88440508, // 0046 GETMBR R17 R2 K8 + 0xB84A0200, // 0047 GETNGBL R18 K1 + 0x8848250B, // 0048 GETMBR R18 R18 K11 + 0x1C442212, // 0049 EQ R17 R17 R18 + 0x78460001, // 004A JMPF R17 #004D + 0x5844000B, // 004B LDCONST R17 K11 + 0x70020000, // 004C JMP #004E + 0x58440007, // 004D LDCONST R17 K7 + 0x7C2C0C00, // 004E CALL R11 6 + 0x58300017, // 004F LDCONST R12 K23 + 0x7C240600, // 0050 CALL R9 3 + 0x50240200, // 0051 LDBOOL R9 1 0 + 0x80041200, // 0052 RET 1 R9 + 0x7002000A, // 0053 JMP #005F + 0xB8222600, // 0054 GETNGBL R8 K19 + 0x8C201114, // 0055 GETMET R8 R8 K20 + 0x8C280B15, // 0056 GETMET R10 R5 K21 + 0x58300018, // 0057 LDCONST R12 K24 + 0x60340008, // 0058 GETGBL R13 G8 + 0x5C380400, // 0059 MOVE R14 R2 + 0x7C340200, // 005A CALL R13 1 + 0x5C380C00, // 005B MOVE R14 R6 + 0x7C280800, // 005C CALL R10 4 + 0x582C0017, // 005D LDCONST R11 K23 + 0x7C200600, // 005E CALL R8 3 + 0x80000000, // 005F RET 0 + }) + ), + be_nested_proto( + 9, /* nstack */ + 3, /* argc */ + 0, /* varg */ + 1, /* has upvals */ + ( &(const bupvaldesc[ 3]) { /* upvals */ + be_local_const_upval(1, 7), + be_local_const_upval(1, 9), + be_local_const_upval(1, 13), + }), + 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[ 8]) { /* code */ + 0x680C0000, // 0000 GETUPV R3 U0 + 0x68100001, // 0001 GETUPV R4 U1 + 0x5C140000, // 0002 MOVE R5 R0 + 0x5C180200, // 0003 MOVE R6 R1 + 0x681C0002, // 0004 GETUPV R7 U2 + 0x5C200400, // 0005 MOVE R8 R2 + 0x7C0C0A00, // 0006 CALL R3 5 + 0x80040600, // 0007 RET 1 R3 + }) + ), + }), 1, /* has constants */ - ( &(const bvalue[ 8]) { /* constants */ + ( &(const bvalue[36]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(ReportDataMessage), + /* K2 */ be_nested_str_weak(WriteRequestMessage), /* K3 */ be_nested_str_weak(from_TLV), /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20ReportDataMessage_X3D), + /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20WriteRequestMessage_X3D), /* K7 */ be_const_int(3), + /* K8 */ be_nested_str_weak(suppress_response), + /* K9 */ be_nested_str_weak(device), + /* K10 */ be_nested_str_weak(get_active_endpoints), + /* K11 */ be_nested_str_weak(MTR_X3A_X20IM_X3Awrite_request_X20processing_X20start), + /* K12 */ be_nested_str_weak(Path), + /* K13 */ be_nested_str_weak(write_requests), + /* K14 */ be_nested_str_weak(WriteResponseMessage), + /* K15 */ be_nested_str_weak(write_responses), + /* K16 */ be_nested_str_weak(path), + /* K17 */ be_nested_str_weak(data), + /* K18 */ be_nested_str_weak(endpoint), + /* K19 */ be_nested_str_weak(cluster), + /* K20 */ be_nested_str_weak(attribute), + /* K21 */ be_nested_str_weak(status), + /* K22 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), + /* K23 */ be_nested_str_weak(INVALID_ACTION), + /* K24 */ be_nested_str_weak(get_attribute_name), + /* K25 */ be_nested_str_weak(MTR_X3A_X20Write_Attr_X20), + /* K26 */ be_nested_str_weak(_X20_X28), + /* K27 */ be_nested_str_weak(_X29), + /* K28 */ be_nested_str_weak(), + /* K29 */ be_const_int(2), + /* K30 */ be_nested_str_weak(process_attribute_expansion), + /* K31 */ be_nested_str_weak(stop_iteration), + /* K32 */ be_nested_str_weak(MTR_X3A_X20ReportWriteMessage_X3D), + /* K33 */ be_nested_str_weak(MTR_X3A_X20ReportWriteMessageTLV_X3D), + /* K34 */ be_nested_str_weak(to_TLV), + /* K35 */ be_nested_str_weak(send_write_response), }), - be_str_weak(report_data), + be_str_weak(process_write_request), &be_const_str_solidified, - ( &(const binstruction[17]) { /* code */ + ( &(const binstruction[134]) { /* code */ 0xA40E0000, // 0000 IMPORT R3 K0 0xB8120200, // 0001 GETNGBL R4 K1 0x8C100902, // 0002 GETMET R4 R4 K2 @@ -351,8 +280,125 @@ be_local_closure(Matter_IM_report_data, /* name */ 0x001E0C07, // 000C ADD R7 K6 R7 0x58200007, // 000D LDCONST R8 K7 0x7C140600, // 000E CALL R5 3 - 0x50140000, // 000F LDBOOL R5 0 0 - 0x80040A00, // 0010 RET 1 R5 + 0x88140908, // 000F GETMBR R5 R4 K8 + 0x88180109, // 0010 GETMBR R6 R0 K9 + 0x8C180D0A, // 0011 GETMET R6 R6 K10 + 0x7C180200, // 0012 CALL R6 1 + 0x841C0000, // 0013 CLOSURE R7 P0 + 0xB8220800, // 0014 GETNGBL R8 K4 + 0x8C201105, // 0015 GETMET R8 R8 K5 + 0x5828000B, // 0016 LDCONST R10 K11 + 0x542E0003, // 0017 LDINT R11 4 + 0x7C200600, // 0018 CALL R8 3 + 0xB8220200, // 0019 GETNGBL R8 K1 + 0x8C20110C, // 001A GETMET R8 R8 K12 + 0x7C200200, // 001B CALL R8 1 + 0x8824090D, // 001C GETMBR R9 R4 K13 + 0x4C280000, // 001D LDNIL R10 + 0x2024120A, // 001E NE R9 R9 R10 + 0x78260062, // 001F JMPF R9 #0083 + 0xB8260200, // 0020 GETNGBL R9 K1 + 0x8C24130E, // 0021 GETMET R9 R9 K14 + 0x7C240200, // 0022 CALL R9 1 + 0x60280012, // 0023 GETGBL R10 G18 + 0x7C280000, // 0024 CALL R10 0 + 0x90261E0A, // 0025 SETMBR R9 K15 R10 + 0x60280010, // 0026 GETGBL R10 G16 + 0x882C090D, // 0027 GETMBR R11 R4 K13 + 0x7C280200, // 0028 CALL R10 1 + 0xA802003D, // 0029 EXBLK 0 #0068 + 0x5C2C1400, // 002A MOVE R11 R10 + 0x7C2C0000, // 002B CALL R11 0 + 0x88301710, // 002C GETMBR R12 R11 K16 + 0x88341711, // 002D GETMBR R13 R11 K17 + 0x88381912, // 002E GETMBR R14 R12 K18 + 0x9022240E, // 002F SETMBR R8 K18 R14 + 0x88381913, // 0030 GETMBR R14 R12 K19 + 0x9022260E, // 0031 SETMBR R8 K19 R14 + 0x88381914, // 0032 GETMBR R14 R12 K20 + 0x9022280E, // 0033 SETMBR R8 K20 R14 + 0xB83A0200, // 0034 GETNGBL R14 K1 + 0x88381D16, // 0035 GETMBR R14 R14 K22 + 0x90222A0E, // 0036 SETMBR R8 K21 R14 + 0x88381113, // 0037 GETMBR R14 R8 K19 + 0x4C3C0000, // 0038 LDNIL R15 + 0x1C381C0F, // 0039 EQ R14 R14 R15 + 0x743A0003, // 003A JMPT R14 #003F + 0x88381114, // 003B GETMBR R14 R8 K20 + 0x4C3C0000, // 003C LDNIL R15 + 0x1C381C0F, // 003D EQ R14 R14 R15 + 0x783A000A, // 003E JMPF R14 #004A + 0xB83A0200, // 003F GETNGBL R14 K1 + 0x88381D17, // 0040 GETMBR R14 R14 K23 + 0x90222A0E, // 0041 SETMBR R8 K21 R14 + 0x5C380E00, // 0042 MOVE R14 R7 + 0x5C3C1200, // 0043 MOVE R15 R9 + 0x4C400000, // 0044 LDNIL R16 + 0x5C441000, // 0045 MOVE R17 R8 + 0x4C480000, // 0046 LDNIL R18 + 0x504C0200, // 0047 LDBOOL R19 1 0 + 0x7C380A00, // 0048 CALL R14 5 + 0x7001FFDF, // 0049 JMP #002A + 0x88381112, // 004A GETMBR R14 R8 K18 + 0x4C3C0000, // 004B LDNIL R15 + 0x1C381C0F, // 004C EQ R14 R14 R15 + 0x783A0012, // 004D JMPF R14 #0061 + 0xB83A0200, // 004E GETNGBL R14 K1 + 0x8C381D18, // 004F GETMET R14 R14 K24 + 0x88401113, // 0050 GETMBR R16 R8 K19 + 0x88441114, // 0051 GETMBR R17 R8 K20 + 0x7C380600, // 0052 CALL R14 3 + 0xB83E0800, // 0053 GETNGBL R15 K4 + 0x8C3C1F05, // 0054 GETMET R15 R15 K5 + 0x60440008, // 0055 GETGBL R17 G8 + 0x5C481000, // 0056 MOVE R18 R8 + 0x7C440200, // 0057 CALL R17 1 + 0x00463211, // 0058 ADD R17 K25 R17 + 0x783A0002, // 0059 JMPF R14 #005D + 0x004A340E, // 005A ADD R18 K26 R14 + 0x0048251B, // 005B ADD R18 R18 K27 + 0x70020000, // 005C JMP #005E + 0x5848001C, // 005D LDCONST R18 K28 + 0x00442212, // 005E ADD R17 R17 R18 + 0x5848001D, // 005F LDCONST R18 K29 + 0x7C3C0600, // 0060 CALL R15 3 + 0x88380109, // 0061 GETMBR R14 R0 K9 + 0x8C381D1E, // 0062 GETMET R14 R14 K30 + 0x5C401000, // 0063 MOVE R16 R8 + 0x84440001, // 0064 CLOSURE R17 P1 + 0x7C380600, // 0065 CALL R14 3 + 0xA0280000, // 0066 CLOSE R10 + 0x7001FFC1, // 0067 JMP #002A + 0x5828001F, // 0068 LDCONST R10 K31 + 0xAC280200, // 0069 CATCH R10 1 0 + 0xB0080000, // 006A RAISE 2 R0 R0 + 0xB82A0800, // 006B GETNGBL R10 K4 + 0x8C281505, // 006C GETMET R10 R10 K5 + 0x60300008, // 006D GETGBL R12 G8 + 0x5C341200, // 006E MOVE R13 R9 + 0x7C300200, // 006F CALL R12 1 + 0x0032400C, // 0070 ADD R12 K32 R12 + 0x54360003, // 0071 LDINT R13 4 + 0x7C280600, // 0072 CALL R10 3 + 0xB82A0800, // 0073 GETNGBL R10 K4 + 0x8C281505, // 0074 GETMET R10 R10 K5 + 0x60300008, // 0075 GETGBL R12 G8 + 0x8C341322, // 0076 GETMET R13 R9 K34 + 0x7C340200, // 0077 CALL R13 1 + 0x7C300200, // 0078 CALL R12 1 + 0x0032420C, // 0079 ADD R12 K33 R12 + 0x58340007, // 007A LDCONST R13 K7 + 0x7C280600, // 007B CALL R10 3 + 0x5C280A00, // 007C MOVE R10 R5 + 0x742A0003, // 007D JMPT R10 #0082 + 0x8C280123, // 007E GETMET R10 R0 K35 + 0x5C300200, // 007F MOVE R12 R1 + 0x5C341200, // 0080 MOVE R13 R9 + 0x7C280600, // 0081 CALL R10 3 + 0xA0240000, // 0082 CLOSE R9 + 0x50240200, // 0083 LDBOOL R9 1 0 + 0xA0000000, // 0084 CLOSE R0 + 0x80041200, // 0085 RET 1 R9 }) ) ); @@ -360,60 +406,11 @@ be_local_closure(Matter_IM_report_data, /* name */ /******************************************************************** -** Solidified function: process_invoke_response +** Solidified function: _inner_process_read_request ********************************************************************/ -be_local_closure(Matter_IM_process_invoke_response, /* name */ +be_local_closure(Matter_IM__inner_process_read_request, /* name */ be_nested_proto( - 9, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 8]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(InvokeResponseMessage), - /* K3 */ be_nested_str_weak(from_TLV), - /* K4 */ be_nested_str_weak(tasmota), - /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20InvokeResponseMessage_X3D), - /* K7 */ be_const_int(3), - }), - be_str_weak(process_invoke_response), - &be_const_str_solidified, - ( &(const binstruction[17]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0xB8120200, // 0001 GETNGBL R4 K1 - 0x8C100902, // 0002 GETMET R4 R4 K2 - 0x7C100200, // 0003 CALL R4 1 - 0x8C100903, // 0004 GETMET R4 R4 K3 - 0x5C180400, // 0005 MOVE R6 R2 - 0x7C100400, // 0006 CALL R4 2 - 0xB8160800, // 0007 GETNGBL R5 K4 - 0x8C140B05, // 0008 GETMET R5 R5 K5 - 0x601C0008, // 0009 GETGBL R7 G8 - 0x5C200800, // 000A MOVE R8 R4 - 0x7C1C0200, // 000B CALL R7 1 - 0x001E0C07, // 000C ADD R7 K6 R7 - 0x58200007, // 000D LDCONST R8 K7 - 0x7C140600, // 000E CALL R5 3 - 0x50140000, // 000F LDBOOL R5 0 0 - 0x80040A00, // 0010 RET 1 R5 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: process_read_request -********************************************************************/ -be_local_closure(Matter_IM_process_read_request, /* name */ - be_nested_proto( - 15, /* nstack */ + 14, /* nstack */ 3, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -455,19 +452,19 @@ be_local_closure(Matter_IM_process_read_request, /* name */ /* K20 */ be_nested_str_weak(tasmota), /* K21 */ be_nested_str_weak(log), /* K22 */ be_nested_str_weak(format), - /* K23 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X25s_X25s_X20_X2D_X20_X25s), + /* K23 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X20_X25s_X25s_X20_X2D_X20_X25s), /* K24 */ be_const_int(2), /* K25 */ be_nested_str_weak(status), /* K26 */ be_nested_str_weak(attribute_status), /* K27 */ be_nested_str_weak(AttributeStatusIB), /* K28 */ be_nested_str_weak(StatusIB), - /* K29 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X25s_X25s_X20_X2D_X20STATUS_X3A_X200x_X2502X_X20_X25s), + /* K29 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X20_X25s_X25s_X20_X2D_X20STATUS_X3A_X200x_X2502X_X20_X25s), /* K30 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), - /* K31 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X25s_X25s_X20_X2D_X20IGNORED), + /* K31 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X20_X25s_X25s_X20_X2D_X20IGNORED), }), be_str_weak(read_single_attribute), &be_const_str_solidified, - ( &(const binstruction[150]) { /* code */ + ( &(const binstruction[152]) { /* code */ 0xA4120000, // 0000 IMPORT R4 K0 0xB8160200, // 0001 GETNGBL R5 K1 0x8C140B02, // 0002 GETMET R5 R5 K2 @@ -540,7 +537,7 @@ be_local_closure(Matter_IM_process_read_request, /* name */ 0x7C200600, // 0045 CALL R8 3 0x50200200, // 0046 LDBOOL R8 1 0 0x80041000, // 0047 RET 1 R8 - 0x7002004B, // 0048 JMP #0095 + 0x7002004D, // 0048 JMP #0097 0x881C0519, // 0049 GETMBR R7 R2 K25 0x4C200000, // 004A LDNIL R8 0x201C0E08, // 004B NE R7 R7 R8 @@ -605,7 +602,7 @@ be_local_closure(Matter_IM_process_read_request, /* name */ 0x7C200600, // 0086 CALL R8 3 0x50200200, // 0087 LDBOOL R8 1 0 0x80041000, // 0088 RET 1 R8 - 0x7002000A, // 0089 JMP #0095 + 0x7002000C, // 0089 JMP #0097 0xB81E2800, // 008A GETNGBL R7 K20 0x8C1C0F15, // 008B GETMET R7 R7 K21 0x8C240916, // 008C GETMET R9 R4 K22 @@ -617,7 +614,9 @@ be_local_closure(Matter_IM_process_read_request, /* name */ 0x7C240800, // 0092 CALL R9 4 0x58280018, // 0093 LDCONST R10 K24 0x7C1C0600, // 0094 CALL R7 3 - 0x80000000, // 0095 RET 0 + 0x501C0000, // 0095 LDBOOL R7 0 0 + 0x80040E00, // 0096 RET 1 R7 + 0x80000000, // 0097 RET 0 }) ), be_nested_proto( @@ -627,7 +626,7 @@ be_local_closure(Matter_IM_process_read_request, /* name */ 1, /* has upvals */ ( &(const bupvaldesc[ 2]) { /* upvals */ be_local_const_upval(1, 4), - be_local_const_upval(1, 7), + be_local_const_upval(1, 6), }), 0, /* has sup protos */ NULL, /* no sub protos */ @@ -647,166 +646,141 @@ be_local_closure(Matter_IM_process_read_request, /* name */ ), }), 1, /* has constants */ - ( &(const bvalue[30]) { /* constants */ + ( &(const bvalue[26]) { /* constants */ /* K0 */ be_nested_str_weak(device), /* K1 */ be_nested_str_weak(get_active_endpoints), - /* K2 */ be_nested_str_weak(tasmota), - /* K3 */ be_nested_str_weak(log), - /* K4 */ be_nested_str_weak(MTR_X3A_X20IM_X3Aread_request_X20processing_X20start), - /* K5 */ be_const_int(3), - /* K6 */ be_nested_str_weak(matter), - /* K7 */ be_nested_str_weak(Response_container), - /* K8 */ be_nested_str_weak(ReadRequestMessage), - /* K9 */ be_nested_str_weak(from_TLV), - /* K10 */ be_nested_str_weak(attributes_requests), - /* K11 */ be_nested_str_weak(ReportDataMessage), - /* K12 */ be_nested_str_weak(attribute_reports), - /* K13 */ be_nested_str_weak(endpoint), - /* K14 */ be_nested_str_weak(cluster), - /* K15 */ be_nested_str_weak(attribute), - /* K16 */ be_nested_str_weak(status), - /* K17 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), - /* K18 */ be_nested_str_weak(get_attribute_name), - /* K19 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20), - /* K20 */ be_nested_str_weak(_X20_X28), - /* K21 */ be_nested_str_weak(_X29), - /* K22 */ be_nested_str_weak(), - /* K23 */ be_const_int(2), - /* K24 */ be_nested_str_weak(process_attribute_expansion), - /* K25 */ be_nested_str_weak(stop_iteration), - /* K26 */ be_nested_str_weak(MTR_X3A_X20ReportDataMessage_X3D), - /* K27 */ be_nested_str_weak(MTR_X3A_X20ReportDataMessageTLV_X3D), - /* K28 */ be_nested_str_weak(to_TLV), - /* K29 */ be_nested_str_weak(send_attr_report), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(Path), + /* K4 */ be_nested_str_weak(ReportDataMessage), + /* K5 */ be_nested_str_weak(attribute_reports), + /* K6 */ be_nested_str_weak(attributes_requests), + /* K7 */ be_nested_str_weak(endpoint), + /* K8 */ be_nested_str_weak(cluster), + /* K9 */ be_nested_str_weak(attribute), + /* K10 */ be_nested_str_weak(status), + /* K11 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), + /* K12 */ be_nested_str_weak(get_attribute_name), + /* K13 */ be_nested_str_weak(tasmota), + /* K14 */ be_nested_str_weak(log), + /* K15 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X20), + /* K16 */ be_nested_str_weak(_X20_X28), + /* K17 */ be_nested_str_weak(_X29), + /* K18 */ be_nested_str_weak(), + /* K19 */ be_const_int(2), + /* K20 */ be_nested_str_weak(process_attribute_expansion), + /* K21 */ be_nested_str_weak(stop_iteration), + /* K22 */ be_nested_str_weak(MTR_X3A_X20ReportDataMessage_X3D), + /* K23 */ be_nested_str_weak(MTR_X3A_X20ReportDataMessageTLV_X3D), + /* K24 */ be_nested_str_weak(to_TLV), + /* K25 */ be_const_int(3), }), - be_str_weak(process_read_request), + be_str_weak(_inner_process_read_request), &be_const_str_solidified, - ( &(const binstruction[125]) { /* code */ + ( &(const binstruction[104]) { /* code */ 0x880C0100, // 0000 GETMBR R3 R0 K0 0x8C0C0701, // 0001 GETMET R3 R3 K1 0x7C0C0200, // 0002 CALL R3 1 0x84100000, // 0003 CLOSURE R4 P0 0xB8160400, // 0004 GETNGBL R5 K2 0x8C140B03, // 0005 GETMET R5 R5 K3 - 0x581C0004, // 0006 LDCONST R7 K4 - 0x58200005, // 0007 LDCONST R8 K5 - 0x7C140600, // 0008 CALL R5 3 - 0xB8160C00, // 0009 GETNGBL R5 K6 - 0x8C140B07, // 000A GETMET R5 R5 K7 - 0x7C140200, // 000B CALL R5 1 - 0xB81A0C00, // 000C GETNGBL R6 K6 - 0x8C180D08, // 000D GETMET R6 R6 K8 - 0x7C180200, // 000E CALL R6 1 - 0x8C180D09, // 000F GETMET R6 R6 K9 - 0x5C200400, // 0010 MOVE R8 R2 - 0x7C180400, // 0011 CALL R6 2 - 0x881C0D0A, // 0012 GETMBR R7 R6 K10 - 0x4C200000, // 0013 LDNIL R8 - 0x201C0E08, // 0014 NE R7 R7 R8 - 0x781E0063, // 0015 JMPF R7 #007A - 0xB81E0C00, // 0016 GETNGBL R7 K6 - 0x8C1C0F0B, // 0017 GETMET R7 R7 K11 - 0x7C1C0200, // 0018 CALL R7 1 - 0x60200012, // 0019 GETGBL R8 G18 - 0x7C200000, // 001A CALL R8 0 - 0x901E1808, // 001B SETMBR R7 K12 R8 - 0x60200010, // 001C GETGBL R8 G16 - 0x88240D0A, // 001D GETMBR R9 R6 K10 - 0x7C200200, // 001E CALL R8 1 - 0xA8020040, // 001F EXBLK 0 #0061 - 0x5C241000, // 0020 MOVE R9 R8 - 0x7C240000, // 0021 CALL R9 0 - 0x8828130D, // 0022 GETMBR R10 R9 K13 - 0x90161A0A, // 0023 SETMBR R5 K13 R10 - 0x8828130E, // 0024 GETMBR R10 R9 K14 - 0x90161C0A, // 0025 SETMBR R5 K14 R10 - 0x8828130F, // 0026 GETMBR R10 R9 K15 - 0x90161E0A, // 0027 SETMBR R5 K15 R10 - 0xB82A0C00, // 0028 GETNGBL R10 K6 - 0x88281511, // 0029 GETMBR R10 R10 K17 - 0x9016200A, // 002A SETMBR R5 K16 R10 - 0x88280B0D, // 002B GETMBR R10 R5 K13 - 0x4C2C0000, // 002C LDNIL R11 - 0x1C28140B, // 002D EQ R10 R10 R11 - 0x742A0007, // 002E JMPT R10 #0037 - 0x88280B0E, // 002F GETMBR R10 R5 K14 - 0x4C2C0000, // 0030 LDNIL R11 - 0x1C28140B, // 0031 EQ R10 R10 R11 - 0x742A0003, // 0032 JMPT R10 #0037 - 0x88280B0F, // 0033 GETMBR R10 R5 K15 - 0x4C2C0000, // 0034 LDNIL R11 - 0x1C28140B, // 0035 EQ R10 R10 R11 - 0x782A0023, // 0036 JMPF R10 #005B - 0x88280B0E, // 0037 GETMBR R10 R5 K14 - 0x4C2C0000, // 0038 LDNIL R11 - 0x2028140B, // 0039 NE R10 R10 R11 - 0x782A0017, // 003A JMPF R10 #0053 - 0x88280B0F, // 003B GETMBR R10 R5 K15 - 0x4C2C0000, // 003C LDNIL R11 - 0x2028140B, // 003D NE R10 R10 R11 - 0x782A0013, // 003E JMPF R10 #0053 - 0xB82A0C00, // 003F GETNGBL R10 K6 - 0x8C281512, // 0040 GETMET R10 R10 K18 - 0x88300B0E, // 0041 GETMBR R12 R5 K14 - 0x88340B0F, // 0042 GETMBR R13 R5 K15 - 0x7C280600, // 0043 CALL R10 3 - 0xB82E0400, // 0044 GETNGBL R11 K2 - 0x8C2C1703, // 0045 GETMET R11 R11 K3 - 0x60340008, // 0046 GETGBL R13 G8 - 0x5C380A00, // 0047 MOVE R14 R5 - 0x7C340200, // 0048 CALL R13 1 - 0x0036260D, // 0049 ADD R13 K19 R13 - 0x782A0002, // 004A JMPF R10 #004E - 0x003A280A, // 004B ADD R14 K20 R10 - 0x00381D15, // 004C ADD R14 R14 K21 - 0x70020000, // 004D JMP #004F - 0x58380016, // 004E LDCONST R14 K22 - 0x00341A0E, // 004F ADD R13 R13 R14 - 0x58380017, // 0050 LDCONST R14 K23 - 0x7C2C0600, // 0051 CALL R11 3 - 0x70020007, // 0052 JMP #005B - 0xB82A0400, // 0053 GETNGBL R10 K2 - 0x8C281503, // 0054 GETMET R10 R10 K3 - 0x60300008, // 0055 GETGBL R12 G8 - 0x5C340A00, // 0056 MOVE R13 R5 - 0x7C300200, // 0057 CALL R12 1 - 0x0032260C, // 0058 ADD R12 K19 R12 - 0x58340017, // 0059 LDCONST R13 K23 - 0x7C280600, // 005A CALL R10 3 - 0x88280100, // 005B GETMBR R10 R0 K0 - 0x8C281518, // 005C GETMET R10 R10 K24 - 0x5C300A00, // 005D MOVE R12 R5 - 0x84340001, // 005E CLOSURE R13 P1 - 0x7C280600, // 005F CALL R10 3 - 0x7001FFBE, // 0060 JMP #0020 - 0x58200019, // 0061 LDCONST R8 K25 - 0xAC200200, // 0062 CATCH R8 1 0 - 0xB0080000, // 0063 RAISE 2 R0 R0 - 0xB8220400, // 0064 GETNGBL R8 K2 - 0x8C201103, // 0065 GETMET R8 R8 K3 - 0x60280008, // 0066 GETGBL R10 G8 - 0x5C2C0E00, // 0067 MOVE R11 R7 - 0x7C280200, // 0068 CALL R10 1 - 0x002A340A, // 0069 ADD R10 K26 R10 - 0x582C0005, // 006A LDCONST R11 K5 - 0x7C200600, // 006B CALL R8 3 - 0xB8220400, // 006C GETNGBL R8 K2 - 0x8C201103, // 006D GETMET R8 R8 K3 - 0x60280008, // 006E GETGBL R10 G8 - 0x8C2C0F1C, // 006F GETMET R11 R7 K28 - 0x7C2C0200, // 0070 CALL R11 1 - 0x7C280200, // 0071 CALL R10 1 - 0x002A360A, // 0072 ADD R10 K27 R10 - 0x582C0005, // 0073 LDCONST R11 K5 - 0x7C200600, // 0074 CALL R8 3 - 0x8C20011D, // 0075 GETMET R8 R0 K29 - 0x5C280200, // 0076 MOVE R10 R1 - 0x5C2C0E00, // 0077 MOVE R11 R7 - 0x7C200600, // 0078 CALL R8 3 - 0xA01C0000, // 0079 CLOSE R7 - 0x501C0200, // 007A LDBOOL R7 1 0 - 0xA0000000, // 007B CLOSE R0 - 0x80040E00, // 007C RET 1 R7 + 0x7C140200, // 0006 CALL R5 1 + 0xB81A0400, // 0007 GETNGBL R6 K2 + 0x8C180D04, // 0008 GETMET R6 R6 K4 + 0x7C180200, // 0009 CALL R6 1 + 0x601C0012, // 000A GETGBL R7 G18 + 0x7C1C0000, // 000B CALL R7 0 + 0x901A0A07, // 000C SETMBR R6 K5 R7 + 0x601C0010, // 000D GETGBL R7 G16 + 0x88200506, // 000E GETMBR R8 R2 K6 + 0x7C1C0200, // 000F CALL R7 1 + 0xA8020040, // 0010 EXBLK 0 #0052 + 0x5C200E00, // 0011 MOVE R8 R7 + 0x7C200000, // 0012 CALL R8 0 + 0x88241107, // 0013 GETMBR R9 R8 K7 + 0x90160E09, // 0014 SETMBR R5 K7 R9 + 0x88241108, // 0015 GETMBR R9 R8 K8 + 0x90161009, // 0016 SETMBR R5 K8 R9 + 0x88241109, // 0017 GETMBR R9 R8 K9 + 0x90161209, // 0018 SETMBR R5 K9 R9 + 0xB8260400, // 0019 GETNGBL R9 K2 + 0x8824130B, // 001A GETMBR R9 R9 K11 + 0x90161409, // 001B SETMBR R5 K10 R9 + 0x88240B07, // 001C GETMBR R9 R5 K7 + 0x4C280000, // 001D LDNIL R10 + 0x1C24120A, // 001E EQ R9 R9 R10 + 0x74260007, // 001F JMPT R9 #0028 + 0x88240B08, // 0020 GETMBR R9 R5 K8 + 0x4C280000, // 0021 LDNIL R10 + 0x1C24120A, // 0022 EQ R9 R9 R10 + 0x74260003, // 0023 JMPT R9 #0028 + 0x88240B09, // 0024 GETMBR R9 R5 K9 + 0x4C280000, // 0025 LDNIL R10 + 0x1C24120A, // 0026 EQ R9 R9 R10 + 0x78260023, // 0027 JMPF R9 #004C + 0x88240B08, // 0028 GETMBR R9 R5 K8 + 0x4C280000, // 0029 LDNIL R10 + 0x2024120A, // 002A NE R9 R9 R10 + 0x78260017, // 002B JMPF R9 #0044 + 0x88240B09, // 002C GETMBR R9 R5 K9 + 0x4C280000, // 002D LDNIL R10 + 0x2024120A, // 002E NE R9 R9 R10 + 0x78260013, // 002F JMPF R9 #0044 + 0xB8260400, // 0030 GETNGBL R9 K2 + 0x8C24130C, // 0031 GETMET R9 R9 K12 + 0x882C0B08, // 0032 GETMBR R11 R5 K8 + 0x88300B09, // 0033 GETMBR R12 R5 K9 + 0x7C240600, // 0034 CALL R9 3 + 0xB82A1A00, // 0035 GETNGBL R10 K13 + 0x8C28150E, // 0036 GETMET R10 R10 K14 + 0x60300008, // 0037 GETGBL R12 G8 + 0x5C340A00, // 0038 MOVE R13 R5 + 0x7C300200, // 0039 CALL R12 1 + 0x00321E0C, // 003A ADD R12 K15 R12 + 0x78260002, // 003B JMPF R9 #003F + 0x00362009, // 003C ADD R13 K16 R9 + 0x00341B11, // 003D ADD R13 R13 K17 + 0x70020000, // 003E JMP #0040 + 0x58340012, // 003F LDCONST R13 K18 + 0x0030180D, // 0040 ADD R12 R12 R13 + 0x58340013, // 0041 LDCONST R13 K19 + 0x7C280600, // 0042 CALL R10 3 + 0x70020007, // 0043 JMP #004C + 0xB8261A00, // 0044 GETNGBL R9 K13 + 0x8C24130E, // 0045 GETMET R9 R9 K14 + 0x602C0008, // 0046 GETGBL R11 G8 + 0x5C300A00, // 0047 MOVE R12 R5 + 0x7C2C0200, // 0048 CALL R11 1 + 0x002E1E0B, // 0049 ADD R11 K15 R11 + 0x58300013, // 004A LDCONST R12 K19 + 0x7C240600, // 004B CALL R9 3 + 0x88240100, // 004C GETMBR R9 R0 K0 + 0x8C241314, // 004D GETMET R9 R9 K20 + 0x5C2C0A00, // 004E MOVE R11 R5 + 0x84300001, // 004F CLOSURE R12 P1 + 0x7C240600, // 0050 CALL R9 3 + 0x7001FFBE, // 0051 JMP #0011 + 0x581C0015, // 0052 LDCONST R7 K21 + 0xAC1C0200, // 0053 CATCH R7 1 0 + 0xB0080000, // 0054 RAISE 2 R0 R0 + 0xB81E1A00, // 0055 GETNGBL R7 K13 + 0x8C1C0F0E, // 0056 GETMET R7 R7 K14 + 0x60240008, // 0057 GETGBL R9 G8 + 0x5C280C00, // 0058 MOVE R10 R6 + 0x7C240200, // 0059 CALL R9 1 + 0x00262C09, // 005A ADD R9 K22 R9 + 0x542A0003, // 005B LDINT R10 4 + 0x7C1C0600, // 005C CALL R7 3 + 0xB81E1A00, // 005D GETNGBL R7 K13 + 0x8C1C0F0E, // 005E GETMET R7 R7 K14 + 0x60240008, // 005F GETGBL R9 G8 + 0x8C280D18, // 0060 GETMET R10 R6 K24 + 0x7C280200, // 0061 CALL R10 1 + 0x7C240200, // 0062 CALL R9 1 + 0x00262E09, // 0063 ADD R9 K23 R9 + 0x58280019, // 0064 LDCONST R10 K25 + 0x7C1C0600, // 0065 CALL R7 3 + 0xA0000000, // 0066 CLOSE R0 + 0x80040C00, // 0067 RET 1 R6 }) ) ); @@ -814,9 +788,81 @@ be_local_closure(Matter_IM_process_read_request, /* name */ /******************************************************************** -** Solidified function: process_write_request +** Solidified function: process_timed_request ********************************************************************/ -be_local_closure(Matter_IM_process_write_request, /* name */ +be_local_closure(Matter_IM_process_timed_request, /* name */ + be_nested_proto( + 13, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[16]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(TimedRequestMessage), + /* K3 */ be_nested_str_weak(from_TLV), + /* K4 */ be_nested_str_weak(tasmota), + /* K5 */ be_nested_str_weak(log), + /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20TimedRequestMessage_X3D), + /* K7 */ be_const_int(3), + /* K8 */ be_nested_str_weak(format), + /* K9 */ be_nested_str_weak(MTR_X3A_X20_X3EReceived_X20_X20TimedRequest_X3D_X25i_X20from_X20_X5B_X25s_X5D_X3A_X25i), + /* K10 */ be_nested_str_weak(timeout), + /* K11 */ be_nested_str_weak(remote_ip), + /* K12 */ be_nested_str_weak(remote_port), + /* K13 */ be_const_int(2), + /* K14 */ be_nested_str_weak(send_status), + /* K15 */ be_nested_str_weak(SUCCESS), + }), + be_str_weak(process_timed_request), + &be_const_str_solidified, + ( &(const binstruction[32]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0xB8120200, // 0001 GETNGBL R4 K1 + 0x8C100902, // 0002 GETMET R4 R4 K2 + 0x7C100200, // 0003 CALL R4 1 + 0x8C100903, // 0004 GETMET R4 R4 K3 + 0x5C180400, // 0005 MOVE R6 R2 + 0x7C100400, // 0006 CALL R4 2 + 0xB8160800, // 0007 GETNGBL R5 K4 + 0x8C140B05, // 0008 GETMET R5 R5 K5 + 0x601C0008, // 0009 GETGBL R7 G8 + 0x5C200800, // 000A MOVE R8 R4 + 0x7C1C0200, // 000B CALL R7 1 + 0x001E0C07, // 000C ADD R7 K6 R7 + 0x58200007, // 000D LDCONST R8 K7 + 0x7C140600, // 000E CALL R5 3 + 0xB8160800, // 000F GETNGBL R5 K4 + 0x8C140B05, // 0010 GETMET R5 R5 K5 + 0x8C1C0708, // 0011 GETMET R7 R3 K8 + 0x58240009, // 0012 LDCONST R9 K9 + 0x8828090A, // 0013 GETMBR R10 R4 K10 + 0x882C030B, // 0014 GETMBR R11 R1 K11 + 0x8830030C, // 0015 GETMBR R12 R1 K12 + 0x7C1C0A00, // 0016 CALL R7 5 + 0x5820000D, // 0017 LDCONST R8 K13 + 0x7C140600, // 0018 CALL R5 3 + 0x8C14010E, // 0019 GETMET R5 R0 K14 + 0x5C1C0200, // 001A MOVE R7 R1 + 0xB8220200, // 001B GETNGBL R8 K1 + 0x8820110F, // 001C GETMBR R8 R8 K15 + 0x7C140600, // 001D CALL R5 3 + 0x50140200, // 001E LDBOOL R5 1 0 + 0x80040A00, // 001F RET 1 R5 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: process_write_response +********************************************************************/ +be_local_closure(Matter_IM_process_write_response, /* name */ be_nested_proto( 9, /* nstack */ 3, /* argc */ @@ -829,14 +875,14 @@ be_local_closure(Matter_IM_process_write_request, /* name */ ( &(const bvalue[ 8]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(WriteRequestMessage), + /* K2 */ be_nested_str_weak(WriteResponseMessage), /* K3 */ be_nested_str_weak(from_TLV), /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20WriteRequestMessage_X3D), - /* K7 */ be_const_int(3), + /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20WriteResponseMessage_X3D), + /* K7 */ be_const_int(2), }), - be_str_weak(process_write_request), + be_str_weak(process_write_response), &be_const_str_solidified, ( &(const binstruction[17]) { /* code */ 0xA40E0000, // 0000 IMPORT R3 K0 @@ -863,11 +909,11 @@ be_local_closure(Matter_IM_process_write_request, /* name */ /******************************************************************** -** Solidified function: process_invoke_request +** Solidified function: send_write_response ********************************************************************/ -be_local_closure(Matter_IM_process_invoke_request, /* name */ +be_local_closure(Matter_IM_send_write_response, /* name */ be_nested_proto( - 18, /* nstack */ + 9, /* nstack */ 3, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -875,305 +921,24 @@ be_local_closure(Matter_IM_process_invoke_request, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[52]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(tasmota), - /* K2 */ be_nested_str_weak(log), - /* K3 */ be_nested_str_weak(MTR_X3A_X20IM_X3Ainvoke_request_X20processing_X20start), - /* K4 */ be_const_int(3), - /* K5 */ be_nested_str_weak(matter), - /* K6 */ be_nested_str_weak(Response_container), - /* K7 */ be_nested_str_weak(InvokeRequestMessage), - /* K8 */ be_nested_str_weak(from_TLV), - /* K9 */ be_nested_str_weak(invoke_requests), - /* K10 */ be_nested_str_weak(InvokeResponseMessage), - /* K11 */ be_nested_str_weak(suppress_response), - /* K12 */ be_nested_str_weak(invoke_responses), - /* K13 */ be_nested_str_weak(endpoint), - /* K14 */ be_nested_str_weak(command_path), - /* K15 */ be_nested_str_weak(cluster), - /* K16 */ be_nested_str_weak(command), - /* K17 */ be_nested_str_weak(status), - /* K18 */ be_nested_str_weak(UNSUPPORTED_COMMAND), - /* K19 */ be_nested_str_weak(get_command_name), - /* K20 */ be_nested_str_weak(format), - /* K21 */ be_nested_str_weak(0x_X2504X_X2F0x02X), - /* K22 */ be_nested_str_weak(MTR_X3A_X20_X3EReceived_cmd_X20_X20_X25s_X20from_X20_X5B_X25s_X5D_X3A_X25i), - /* K23 */ be_nested_str_weak(remote_ip), - /* K24 */ be_nested_str_weak(remote_port), - /* K25 */ be_const_int(2), - /* K26 */ be_nested_str_weak(responder), - /* K27 */ be_nested_str_weak(device), - /* K28 */ be_nested_str_weak(invoke_request), - /* K29 */ be_nested_str_weak(command_fields), - /* K30 */ be_nested_str_weak(InvokeResponseIB), - /* K31 */ be_nested_str_weak(CommandDataIB), - /* K32 */ be_nested_str_weak(CommandPathIB), - /* K33 */ be_nested_str_weak(push), - /* K34 */ be_nested_str_weak(0x_X2504X_X2F0x_X2502X), - /* K35 */ be_nested_str_weak(MTR_X3A_X20_X3CReplied_cmd_X20_X20_X20_X25s), - /* K36 */ be_nested_str_weak(CommandStatusIB), - /* K37 */ be_nested_str_weak(StatusIB), - /* K38 */ be_nested_str_weak(stop_iteration), - /* K39 */ be_nested_str_weak(MTR_X3A_X20invoke_responses_X3D), - /* K40 */ be_const_int(0), - /* K41 */ be_nested_str_weak(MTR_X3A_X20InvokeResponse_X3D), - /* K42 */ be_nested_str_weak(MTR_X3A_X20InvokeResponseTLV_X3D), - /* K43 */ be_nested_str_weak(to_TLV), - /* K44 */ be_nested_str_weak(build_response), - /* K45 */ be_nested_str_weak(encode), - /* K46 */ be_nested_str_weak(encrypt), - /* K47 */ be_nested_str_weak(send_response), - /* K48 */ be_nested_str_weak(raw), - /* K49 */ be_nested_str_weak(message_counter), - /* K50 */ be_nested_str_weak(x_flag_r), - /* K51 */ be_nested_str_weak(build_standalone_ack), + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(send_queue), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(IM_WriteResponse), }), - be_str_weak(process_invoke_request), + be_str_weak(send_write_response), &be_const_str_solidified, - ( &(const binstruction[242]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0xB8120200, // 0001 GETNGBL R4 K1 - 0x8C100902, // 0002 GETMET R4 R4 K2 - 0x58180003, // 0003 LDCONST R6 K3 - 0x581C0004, // 0004 LDCONST R7 K4 - 0x7C100600, // 0005 CALL R4 3 - 0xB8120A00, // 0006 GETNGBL R4 K5 - 0x8C100906, // 0007 GETMET R4 R4 K6 - 0x7C100200, // 0008 CALL R4 1 - 0xB8160A00, // 0009 GETNGBL R5 K5 - 0x8C140B07, // 000A GETMET R5 R5 K7 - 0x7C140200, // 000B CALL R5 1 - 0x8C140B08, // 000C GETMET R5 R5 K8 - 0x5C1C0400, // 000D MOVE R7 R2 - 0x7C140400, // 000E CALL R5 2 - 0x88180B09, // 000F GETMBR R6 R5 K9 - 0x4C1C0000, // 0010 LDNIL R7 - 0x20180C07, // 0011 NE R6 R6 R7 - 0x781A00DD, // 0012 JMPF R6 #00F1 - 0xB81A0A00, // 0013 GETNGBL R6 K5 - 0x8C180D0A, // 0014 GETMET R6 R6 K10 - 0x7C180200, // 0015 CALL R6 1 - 0x501C0000, // 0016 LDBOOL R7 0 0 - 0x901A1607, // 0017 SETMBR R6 K11 R7 - 0x601C0012, // 0018 GETGBL R7 G18 - 0x7C1C0000, // 0019 CALL R7 0 - 0x901A1807, // 001A SETMBR R6 K12 R7 - 0x601C0010, // 001B GETGBL R7 G16 - 0x88200B09, // 001C GETMBR R8 R5 K9 - 0x7C1C0200, // 001D CALL R7 1 - 0xA802008D, // 001E EXBLK 0 #00AD - 0x5C200E00, // 001F MOVE R8 R7 - 0x7C200000, // 0020 CALL R8 0 - 0x8824110E, // 0021 GETMBR R9 R8 K14 - 0x8824130D, // 0022 GETMBR R9 R9 K13 - 0x90121A09, // 0023 SETMBR R4 K13 R9 - 0x8824110E, // 0024 GETMBR R9 R8 K14 - 0x8824130F, // 0025 GETMBR R9 R9 K15 - 0x90121E09, // 0026 SETMBR R4 K15 R9 - 0x8824110E, // 0027 GETMBR R9 R8 K14 - 0x88241310, // 0028 GETMBR R9 R9 K16 - 0x90122009, // 0029 SETMBR R4 K16 R9 - 0xB8260A00, // 002A GETNGBL R9 K5 - 0x88241312, // 002B GETMBR R9 R9 K18 - 0x90122209, // 002C SETMBR R4 K17 R9 - 0xB8260A00, // 002D GETNGBL R9 K5 - 0x8C241313, // 002E GETMET R9 R9 K19 - 0x882C090F, // 002F GETMBR R11 R4 K15 - 0x88300910, // 0030 GETMBR R12 R4 K16 - 0x7C240600, // 0031 CALL R9 3 - 0x4C280000, // 0032 LDNIL R10 - 0x1C28120A, // 0033 EQ R10 R9 R10 - 0x782A0005, // 0034 JMPF R10 #003B - 0x8C280714, // 0035 GETMET R10 R3 K20 - 0x58300015, // 0036 LDCONST R12 K21 - 0x8834090F, // 0037 GETMBR R13 R4 K15 - 0x88380910, // 0038 GETMBR R14 R4 K16 - 0x7C280800, // 0039 CALL R10 4 - 0x5C241400, // 003A MOVE R9 R10 - 0xB82A0200, // 003B GETNGBL R10 K1 - 0x8C281502, // 003C GETMET R10 R10 K2 - 0x8C300714, // 003D GETMET R12 R3 K20 - 0x58380016, // 003E LDCONST R14 K22 - 0x5C3C1200, // 003F MOVE R15 R9 - 0x88400317, // 0040 GETMBR R16 R1 K23 - 0x88440318, // 0041 GETMBR R17 R1 K24 - 0x7C300A00, // 0042 CALL R12 5 - 0x58340019, // 0043 LDCONST R13 K25 - 0x7C280600, // 0044 CALL R10 3 - 0x8828011A, // 0045 GETMBR R10 R0 K26 - 0x8828151B, // 0046 GETMBR R10 R10 K27 - 0x8C28151C, // 0047 GETMET R10 R10 K28 - 0x5C300200, // 0048 MOVE R12 R1 - 0x8834111D, // 0049 GETMBR R13 R8 K29 - 0x5C380800, // 004A MOVE R14 R4 - 0x7C280800, // 004B CALL R10 4 - 0xB82E0A00, // 004C GETNGBL R11 K5 - 0x8C2C171E, // 004D GETMET R11 R11 K30 - 0x7C2C0200, // 004E CALL R11 1 - 0x4C300000, // 004F LDNIL R12 - 0x2030140C, // 0050 NE R12 R10 R12 - 0x78320032, // 0051 JMPF R12 #0085 - 0xB8320A00, // 0052 GETNGBL R12 K5 - 0x8C30191F, // 0053 GETMET R12 R12 K31 - 0x7C300200, // 0054 CALL R12 1 - 0x902E200C, // 0055 SETMBR R11 K16 R12 - 0x88301710, // 0056 GETMBR R12 R11 K16 - 0xB8360A00, // 0057 GETNGBL R13 K5 - 0x8C341B20, // 0058 GETMET R13 R13 K32 - 0x7C340200, // 0059 CALL R13 1 - 0x90321C0D, // 005A SETMBR R12 K14 R13 - 0x88301710, // 005B GETMBR R12 R11 K16 - 0x8830190E, // 005C GETMBR R12 R12 K14 - 0x8834090D, // 005D GETMBR R13 R4 K13 - 0x90321A0D, // 005E SETMBR R12 K13 R13 - 0x88301710, // 005F GETMBR R12 R11 K16 - 0x8830190E, // 0060 GETMBR R12 R12 K14 - 0x8834090F, // 0061 GETMBR R13 R4 K15 - 0x90321E0D, // 0062 SETMBR R12 K15 R13 - 0x88301710, // 0063 GETMBR R12 R11 K16 - 0x8830190E, // 0064 GETMBR R12 R12 K14 - 0x88340910, // 0065 GETMBR R13 R4 K16 - 0x9032200D, // 0066 SETMBR R12 K16 R13 - 0x88301710, // 0067 GETMBR R12 R11 K16 - 0x90323A0A, // 0068 SETMBR R12 K29 R10 - 0x88300D0C, // 0069 GETMBR R12 R6 K12 - 0x8C301921, // 006A GETMET R12 R12 K33 - 0x5C381600, // 006B MOVE R14 R11 - 0x7C300400, // 006C CALL R12 2 - 0xB8320A00, // 006D GETNGBL R12 K5 - 0x8C301913, // 006E GETMET R12 R12 K19 - 0x8838090F, // 006F GETMBR R14 R4 K15 - 0x883C0910, // 0070 GETMBR R15 R4 K16 - 0x7C300600, // 0071 CALL R12 3 - 0x5C241800, // 0072 MOVE R9 R12 - 0x4C300000, // 0073 LDNIL R12 - 0x1C30120C, // 0074 EQ R12 R9 R12 - 0x78320005, // 0075 JMPF R12 #007C - 0x8C300714, // 0076 GETMET R12 R3 K20 - 0x58380022, // 0077 LDCONST R14 K34 - 0x883C090F, // 0078 GETMBR R15 R4 K15 - 0x88400910, // 0079 GETMBR R16 R4 K16 - 0x7C300800, // 007A CALL R12 4 - 0x5C241800, // 007B MOVE R9 R12 - 0xB8320200, // 007C GETNGBL R12 K1 - 0x8C301902, // 007D GETMET R12 R12 K2 - 0x8C380714, // 007E GETMET R14 R3 K20 - 0x58400023, // 007F LDCONST R16 K35 - 0x5C441200, // 0080 MOVE R17 R9 - 0x7C380600, // 0081 CALL R14 3 - 0x583C0019, // 0082 LDCONST R15 K25 - 0x7C300600, // 0083 CALL R12 3 - 0x70020026, // 0084 JMP #00AC - 0x88300911, // 0085 GETMBR R12 R4 K17 - 0x4C340000, // 0086 LDNIL R13 - 0x2030180D, // 0087 NE R12 R12 R13 - 0x78320022, // 0088 JMPF R12 #00AC - 0xB8320A00, // 0089 GETNGBL R12 K5 - 0x8C301924, // 008A GETMET R12 R12 K36 - 0x7C300200, // 008B CALL R12 1 - 0x902E220C, // 008C SETMBR R11 K17 R12 - 0x88301711, // 008D GETMBR R12 R11 K17 - 0xB8360A00, // 008E GETNGBL R13 K5 - 0x8C341B20, // 008F GETMET R13 R13 K32 - 0x7C340200, // 0090 CALL R13 1 - 0x90321C0D, // 0091 SETMBR R12 K14 R13 - 0x88301711, // 0092 GETMBR R12 R11 K17 - 0x8830190E, // 0093 GETMBR R12 R12 K14 - 0x8834090D, // 0094 GETMBR R13 R4 K13 - 0x90321A0D, // 0095 SETMBR R12 K13 R13 - 0x88301711, // 0096 GETMBR R12 R11 K17 - 0x8830190E, // 0097 GETMBR R12 R12 K14 - 0x8834090F, // 0098 GETMBR R13 R4 K15 - 0x90321E0D, // 0099 SETMBR R12 K15 R13 - 0x88301711, // 009A GETMBR R12 R11 K17 - 0x8830190E, // 009B GETMBR R12 R12 K14 - 0x88340910, // 009C GETMBR R13 R4 K16 - 0x9032200D, // 009D SETMBR R12 K16 R13 - 0x88301711, // 009E GETMBR R12 R11 K17 - 0xB8360A00, // 009F GETNGBL R13 K5 - 0x8C341B25, // 00A0 GETMET R13 R13 K37 - 0x7C340200, // 00A1 CALL R13 1 - 0x9032220D, // 00A2 SETMBR R12 K17 R13 - 0x88301711, // 00A3 GETMBR R12 R11 K17 - 0x88301911, // 00A4 GETMBR R12 R12 K17 - 0x88340911, // 00A5 GETMBR R13 R4 K17 - 0x9032220D, // 00A6 SETMBR R12 K17 R13 - 0x88300D0C, // 00A7 GETMBR R12 R6 K12 - 0x8C301921, // 00A8 GETMET R12 R12 K33 - 0x5C381600, // 00A9 MOVE R14 R11 - 0x7C300400, // 00AA CALL R12 2 - 0x7001FFFF, // 00AB JMP #00AC - 0x7001FF71, // 00AC JMP #001F - 0x581C0026, // 00AD LDCONST R7 K38 - 0xAC1C0200, // 00AE CATCH R7 1 0 - 0xB0080000, // 00AF RAISE 2 R0 R0 - 0xB81E0200, // 00B0 GETNGBL R7 K1 - 0x8C1C0F02, // 00B1 GETMET R7 R7 K2 - 0x60240008, // 00B2 GETGBL R9 G8 - 0x88280D0C, // 00B3 GETMBR R10 R6 K12 - 0x7C240200, // 00B4 CALL R9 1 - 0x00264E09, // 00B5 ADD R9 K39 R9 - 0x58280004, // 00B6 LDCONST R10 K4 - 0x7C1C0600, // 00B7 CALL R7 3 - 0x601C000C, // 00B8 GETGBL R7 G12 - 0x88200D0C, // 00B9 GETMBR R8 R6 K12 - 0x7C1C0200, // 00BA CALL R7 1 - 0x241C0F28, // 00BB GT R7 R7 K40 - 0x781E0024, // 00BC JMPF R7 #00E2 - 0xB81E0200, // 00BD GETNGBL R7 K1 - 0x8C1C0F02, // 00BE GETMET R7 R7 K2 - 0x60240008, // 00BF GETGBL R9 G8 - 0x5C280C00, // 00C0 MOVE R10 R6 - 0x7C240200, // 00C1 CALL R9 1 - 0x00265209, // 00C2 ADD R9 K41 R9 - 0x58280004, // 00C3 LDCONST R10 K4 - 0x7C1C0600, // 00C4 CALL R7 3 - 0xB81E0200, // 00C5 GETNGBL R7 K1 - 0x8C1C0F02, // 00C6 GETMET R7 R7 K2 - 0x60240008, // 00C7 GETGBL R9 G8 - 0x8C280D2B, // 00C8 GETMET R10 R6 K43 - 0x7C280200, // 00C9 CALL R10 1 - 0x7C240200, // 00CA CALL R9 1 - 0x00265409, // 00CB ADD R9 K42 R9 - 0x58280004, // 00CC LDCONST R10 K4 - 0x7C1C0600, // 00CD CALL R7 3 - 0x8C1C032C, // 00CE GETMET R7 R1 K44 - 0x54260008, // 00CF LDINT R9 9 - 0x50280200, // 00D0 LDBOOL R10 1 0 - 0x7C1C0600, // 00D1 CALL R7 3 - 0x8C200F2D, // 00D2 GETMET R8 R7 K45 - 0x8C280D2B, // 00D3 GETMET R10 R6 K43 - 0x7C280200, // 00D4 CALL R10 1 - 0x8C28152D, // 00D5 GETMET R10 R10 K45 - 0x7C280200, // 00D6 CALL R10 1 - 0x7C200400, // 00D7 CALL R8 2 - 0x8C200F2E, // 00D8 GETMET R8 R7 K46 - 0x7C200200, // 00D9 CALL R8 1 - 0x8820011A, // 00DA GETMBR R8 R0 K26 - 0x8C20112F, // 00DB GETMET R8 R8 K47 - 0x88280F30, // 00DC GETMBR R10 R7 K48 - 0x882C0317, // 00DD GETMBR R11 R1 K23 - 0x88300318, // 00DE GETMBR R12 R1 K24 - 0x88340F31, // 00DF GETMBR R13 R7 K49 - 0x7C200A00, // 00E0 CALL R8 5 - 0x7002000E, // 00E1 JMP #00F1 - 0x881C0332, // 00E2 GETMBR R7 R1 K50 - 0x781E000C, // 00E3 JMPF R7 #00F1 - 0x8C1C0333, // 00E4 GETMET R7 R1 K51 - 0x7C1C0200, // 00E5 CALL R7 1 - 0x8C200F2D, // 00E6 GETMET R8 R7 K45 - 0x7C200200, // 00E7 CALL R8 1 - 0x8C200F2E, // 00E8 GETMET R8 R7 K46 - 0x7C200200, // 00E9 CALL R8 1 - 0x8820011A, // 00EA GETMBR R8 R0 K26 - 0x8C20112F, // 00EB GETMET R8 R8 K47 - 0x88280F30, // 00EC GETMBR R10 R7 K48 - 0x882C0317, // 00ED GETMBR R11 R1 K23 - 0x88300318, // 00EE GETMBR R12 R1 K24 - 0x88340F31, // 00EF GETMBR R13 R7 K49 - 0x7C200A00, // 00F0 CALL R8 5 - 0x80000000, // 00F1 RET 0 + ( &(const binstruction[ 9]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0xB8160400, // 0002 GETNGBL R5 K2 + 0x8C140B03, // 0003 GETMET R5 R5 K3 + 0x5C1C0200, // 0004 MOVE R7 R1 + 0x5C200400, // 0005 MOVE R8 R2 + 0x7C140600, // 0006 CALL R5 3 + 0x7C0C0400, // 0007 CALL R3 2 + 0x80000000, // 0008 RET 0 }) ) ); @@ -1181,11 +946,11 @@ be_local_closure(Matter_IM_process_invoke_request, /* name */ /******************************************************************** -** Solidified function: init +** Solidified function: send_status ********************************************************************/ -be_local_closure(Matter_IM_init, /* name */ +be_local_closure(Matter_IM_send_status, /* name */ be_nested_proto( - 3, /* nstack */ + 9, /* nstack */ 3, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1193,173 +958,24 @@ be_local_closure(Matter_IM_init, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(responder), - /* K1 */ be_nested_str_weak(device), + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(send_queue), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(IM_Status), }), - be_str_weak(init), + be_str_weak(send_status), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x90020202, // 0001 SETMBR R0 K1 R2 - 0x80000000, // 0002 RET 0 - }) - ) -); -/*******************************************************************/ - - -extern const bclass be_class_Matter_Attr_Report; - -/******************************************************************** -** Solidified class: Matter_Attr_Report -********************************************************************/ -be_local_class(Matter_Attr_Report, - 3, - NULL, - be_nested_map(3, - ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(ret, 1), be_const_var(0) }, - { be_const_key_weak(expiration, 2), be_const_var(2) }, - { be_const_key_weak(resp, -1), be_const_var(1) }, - })), - be_str_weak(Matter_Attr_Report) -); - -/******************************************************************** -** Solidified function: send_attr_report -********************************************************************/ -be_local_closure(Matter_IM_send_attr_report, /* name */ - be_nested_proto( - 14, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[23]) { /* constants */ - /* K0 */ be_const_class(be_class_Matter_Attr_Report), - /* K1 */ be_const_int(0), - /* K2 */ be_nested_str_weak(attribute_reports), - /* K3 */ be_nested_str_weak(to_TLV), - /* K4 */ be_nested_str_weak(encode), - /* K5 */ be_const_int(1), - /* K6 */ be_nested_str_weak(MAX_MESSAGE), - /* K7 */ be_const_int(2147483647), - /* K8 */ be_nested_str_weak(more_chunked_messages), - /* K9 */ be_nested_str_weak(build_response), - /* K10 */ be_nested_str_weak(encrypt), - /* K11 */ be_nested_str_weak(responder), - /* K12 */ be_nested_str_weak(send_response), - /* K13 */ be_nested_str_weak(raw), - /* K14 */ be_nested_str_weak(remote_ip), - /* K15 */ be_nested_str_weak(remote_port), - /* K16 */ be_nested_str_weak(message_counter), - /* K17 */ be_nested_str_weak(ret), - /* K18 */ be_nested_str_weak(resp), - /* K19 */ be_nested_str_weak(expiration), - /* K20 */ be_nested_str_weak(tasmota), - /* K21 */ be_nested_str_weak(millis), - /* K22 */ be_nested_str_weak(MSG_TIMEOUT), - }), - be_str_weak(send_attr_report), - &be_const_str_solidified, - ( &(const binstruction[93]) { /* code */ - 0x580C0000, // 0000 LDCONST R3 K0 - 0xB4000000, // 0001 CLASS K0 - 0x58100001, // 0002 LDCONST R4 K1 - 0x58140001, // 0003 LDCONST R5 K1 - 0x6018000C, // 0004 GETGBL R6 G12 - 0x881C0502, // 0005 GETMBR R7 R2 K2 - 0x7C180200, // 0006 CALL R6 1 - 0x24180D01, // 0007 GT R6 R6 K1 - 0x781A0009, // 0008 JMPF R6 #0013 - 0x6018000C, // 0009 GETGBL R6 G12 - 0x881C0502, // 000A GETMBR R7 R2 K2 - 0x941C0F01, // 000B GETIDX R7 R7 K1 - 0x8C1C0F03, // 000C GETMET R7 R7 K3 - 0x7C1C0200, // 000D CALL R7 1 - 0x8C1C0F04, // 000E GETMET R7 R7 K4 - 0x7C1C0200, // 000F CALL R7 1 - 0x7C180200, // 0010 CALL R6 1 - 0x5C100C00, // 0011 MOVE R4 R6 - 0x58140005, // 0012 LDCONST R5 K5 - 0x88180106, // 0013 GETMBR R6 R0 K6 - 0x14180806, // 0014 LT R6 R4 R6 - 0x781A0013, // 0015 JMPF R6 #002A - 0x6018000C, // 0016 GETGBL R6 G12 - 0x881C0502, // 0017 GETMBR R7 R2 K2 - 0x7C180200, // 0018 CALL R6 1 - 0x14180A06, // 0019 LT R6 R5 R6 - 0x781A000E, // 001A JMPF R6 #002A - 0x6018000C, // 001B GETGBL R6 G12 - 0x881C0502, // 001C GETMBR R7 R2 K2 - 0x941C0E05, // 001D GETIDX R7 R7 R5 - 0x8C1C0F03, // 001E GETMET R7 R7 K3 - 0x7C1C0200, // 001F CALL R7 1 - 0x8C1C0F04, // 0020 GETMET R7 R7 K4 - 0x7C1C0200, // 0021 CALL R7 1 - 0x7C180200, // 0022 CALL R6 1 - 0x001C0806, // 0023 ADD R7 R4 R6 - 0x88200106, // 0024 GETMBR R8 R0 K6 - 0x141C0E08, // 0025 LT R7 R7 R8 - 0x781E0001, // 0026 JMPF R7 #0029 - 0x00100806, // 0027 ADD R4 R4 R6 - 0x00140B05, // 0028 ADD R5 R5 K5 - 0x7001FFE8, // 0029 JMP #0013 - 0x40180B07, // 002A CONNECT R6 R5 K7 - 0x881C0502, // 002B GETMBR R7 R2 K2 - 0x94180E06, // 002C GETIDX R6 R7 R6 - 0x04200B05, // 002D SUB R8 R5 K5 - 0x40220208, // 002E CONNECT R8 K1 R8 - 0x88240502, // 002F GETMBR R9 R2 K2 - 0x94201208, // 0030 GETIDX R8 R9 R8 - 0x900A0408, // 0031 SETMBR R2 K2 R8 - 0x6020000C, // 0032 GETGBL R8 G12 - 0x5C240C00, // 0033 MOVE R9 R6 - 0x7C200200, // 0034 CALL R8 1 - 0x24201101, // 0035 GT R8 R8 K1 - 0x78220001, // 0036 JMPF R8 #0039 - 0x50200200, // 0037 LDBOOL R8 1 0 - 0x900A1008, // 0038 SETMBR R2 K8 R8 - 0x8C1C0309, // 0039 GETMET R7 R1 K9 - 0x54260004, // 003A LDINT R9 5 - 0x50280200, // 003B LDBOOL R10 1 0 - 0x7C1C0600, // 003C CALL R7 3 - 0x8C200F04, // 003D GETMET R8 R7 K4 - 0x8C280503, // 003E GETMET R10 R2 K3 - 0x7C280200, // 003F CALL R10 1 - 0x8C281504, // 0040 GETMET R10 R10 K4 - 0x7C280200, // 0041 CALL R10 1 - 0x7C200400, // 0042 CALL R8 2 - 0x8C200F0A, // 0043 GETMET R8 R7 K10 - 0x7C200200, // 0044 CALL R8 1 - 0x8820010B, // 0045 GETMBR R8 R0 K11 - 0x8C20110C, // 0046 GETMET R8 R8 K12 - 0x88280F0D, // 0047 GETMBR R10 R7 K13 - 0x882C030E, // 0048 GETMBR R11 R1 K14 - 0x8830030F, // 0049 GETMBR R12 R1 K15 - 0x88340F10, // 004A GETMBR R13 R7 K16 - 0x7C200A00, // 004B CALL R8 5 - 0x6020000C, // 004C GETGBL R8 G12 - 0x5C240C00, // 004D MOVE R9 R6 - 0x7C200200, // 004E CALL R8 1 - 0x24201101, // 004F GT R8 R8 K1 - 0x7822000A, // 0050 JMPF R8 #005C - 0x900A0406, // 0051 SETMBR R2 K2 R6 - 0x5C200600, // 0052 MOVE R8 R3 - 0x7C200000, // 0053 CALL R8 0 - 0x90222202, // 0054 SETMBR R8 K17 R2 - 0x90222407, // 0055 SETMBR R8 K18 R7 - 0xB8262800, // 0056 GETNGBL R9 K20 - 0x8C241315, // 0057 GETMET R9 R9 K21 - 0x7C240200, // 0058 CALL R9 1 - 0x88280116, // 0059 GETMBR R10 R0 K22 - 0x0024120A, // 005A ADD R9 R9 R10 - 0x90222609, // 005B SETMBR R8 K19 R9 - 0x80000000, // 005C RET 0 + ( &(const binstruction[ 9]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0xB8160400, // 0002 GETNGBL R5 K2 + 0x8C140B03, // 0003 GETMET R5 R5 K3 + 0x5C1C0200, // 0004 MOVE R7 R1 + 0x5C200400, // 0005 MOVE R8 R2 + 0x7C140600, // 0006 CALL R5 3 + 0x7C0C0400, // 0007 CALL R3 2 + 0x80000000, // 0008 RET 0 }) ) ); @@ -1387,7 +1003,7 @@ be_local_closure(Matter_IM_subscribe_response, /* name */ /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20SubscribeResponsetMessage_X3D), - /* K7 */ be_const_int(3), + /* K7 */ be_const_int(2), }), be_str_weak(subscribe_response), &be_const_str_solidified, @@ -1415,10 +1031,586 @@ be_local_closure(Matter_IM_subscribe_response, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: process_read_request +********************************************************************/ +be_local_closure(Matter_IM_process_read_request, /* name */ + be_nested_proto( + 9, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 6]) { /* constants */ + /* K0 */ be_nested_str_weak(matter), + /* K1 */ be_nested_str_weak(ReadRequestMessage), + /* K2 */ be_nested_str_weak(from_TLV), + /* K3 */ be_nested_str_weak(attributes_requests), + /* K4 */ be_nested_str_weak(_inner_process_read_request), + /* K5 */ be_nested_str_weak(send_report_data), + }), + be_str_weak(process_read_request), + &be_const_str_solidified, + ( &(const binstruction[20]) { /* code */ + 0xB80E0000, // 0000 GETNGBL R3 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0x7C0C0200, // 0002 CALL R3 1 + 0x8C0C0702, // 0003 GETMET R3 R3 K2 + 0x5C140400, // 0004 MOVE R5 R2 + 0x7C0C0400, // 0005 CALL R3 2 + 0x88100703, // 0006 GETMBR R4 R3 K3 + 0x4C140000, // 0007 LDNIL R5 + 0x20100805, // 0008 NE R4 R4 R5 + 0x78120007, // 0009 JMPF R4 #0012 + 0x8C100104, // 000A GETMET R4 R0 K4 + 0x5C180200, // 000B MOVE R6 R1 + 0x5C1C0600, // 000C MOVE R7 R3 + 0x7C100600, // 000D CALL R4 3 + 0x8C140105, // 000E GETMET R5 R0 K5 + 0x5C1C0200, // 000F MOVE R7 R1 + 0x5C200800, // 0010 MOVE R8 R4 + 0x7C140600, // 0011 CALL R5 3 + 0x50100200, // 0012 LDBOOL R4 1 0 + 0x80040800, // 0013 RET 1 R4 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: send_report_data +********************************************************************/ +be_local_closure(Matter_IM_send_report_data, /* name */ + be_nested_proto( + 9, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(send_queue), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(IM_ReportData), + }), + be_str_weak(send_report_data), + &be_const_str_solidified, + ( &(const binstruction[ 9]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0xB8160400, // 0002 GETNGBL R5 K2 + 0x8C140B03, // 0003 GETMET R5 R5 K3 + 0x5C1C0200, // 0004 MOVE R7 R1 + 0x5C200400, // 0005 MOVE R8 R2 + 0x7C140600, // 0006 CALL R5 3 + 0x7C0C0400, // 0007 CALL R3 2 + 0x80000000, // 0008 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_init, /* name */ + be_nested_proto( + 5, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(device), + /* K1 */ be_nested_str_weak(send_queue), + /* K2 */ be_nested_str_weak(subs), + /* K3 */ be_nested_str_weak(matter), + /* K4 */ be_nested_str_weak(IM_Subscription_Shop), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[10]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x60080012, // 0001 GETGBL R2 G18 + 0x7C080000, // 0002 CALL R2 0 + 0x90020202, // 0003 SETMBR R0 K1 R2 + 0xB80A0600, // 0004 GETNGBL R2 K3 + 0x8C080504, // 0005 GETMET R2 R2 K4 + 0x5C100000, // 0006 MOVE R4 R0 + 0x7C080400, // 0007 CALL R2 2 + 0x90020402, // 0008 SETMBR R0 K2 R2 + 0x80000000, // 0009 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: subscribe_request ********************************************************************/ be_local_closure(Matter_IM_subscribe_request, /* name */ + be_nested_proto( + 12, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[16]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(SubscribeRequestMessage), + /* K3 */ be_nested_str_weak(from_TLV), + /* K4 */ be_nested_str_weak(keep_subscriptions), + /* K5 */ be_nested_str_weak(subs), + /* K6 */ be_nested_str_weak(remove_by_session), + /* K7 */ be_nested_str_weak(session), + /* K8 */ be_nested_str_weak(tasmota), + /* K9 */ be_nested_str_weak(log), + /* K10 */ be_nested_str_weak(MTR_X3A_X20received_X20SubscribeRequestMessage_X3D), + /* K11 */ be_const_int(3), + /* K12 */ be_nested_str_weak(new_subscription), + /* K13 */ be_nested_str_weak(_inner_process_read_request), + /* K14 */ be_nested_str_weak(subscription_id), + /* K15 */ be_nested_str_weak(send_subscribe_response), + }), + be_str_weak(subscribe_request), + &be_const_str_solidified, + ( &(const binstruction[39]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0xB8120200, // 0001 GETNGBL R4 K1 + 0x8C100902, // 0002 GETMET R4 R4 K2 + 0x7C100200, // 0003 CALL R4 1 + 0x8C100903, // 0004 GETMET R4 R4 K3 + 0x5C180400, // 0005 MOVE R6 R2 + 0x7C100400, // 0006 CALL R4 2 + 0x88140904, // 0007 GETMBR R5 R4 K4 + 0x74160003, // 0008 JMPT R5 #000D + 0x88140105, // 0009 GETMBR R5 R0 K5 + 0x8C140B06, // 000A GETMET R5 R5 K6 + 0x881C0307, // 000B GETMBR R7 R1 K7 + 0x7C140400, // 000C CALL R5 2 + 0xB8161000, // 000D GETNGBL R5 K8 + 0x8C140B09, // 000E GETMET R5 R5 K9 + 0x601C0008, // 000F GETGBL R7 G8 + 0x5C200800, // 0010 MOVE R8 R4 + 0x7C1C0200, // 0011 CALL R7 1 + 0x001E1407, // 0012 ADD R7 K10 R7 + 0x5820000B, // 0013 LDCONST R8 K11 + 0x7C140600, // 0014 CALL R5 3 + 0x88140105, // 0015 GETMBR R5 R0 K5 + 0x8C140B0C, // 0016 GETMET R5 R5 K12 + 0x881C0307, // 0017 GETMBR R7 R1 K7 + 0x5C200800, // 0018 MOVE R8 R4 + 0x7C140600, // 0019 CALL R5 3 + 0x8C18010D, // 001A GETMET R6 R0 K13 + 0x5C200200, // 001B MOVE R8 R1 + 0x5C240800, // 001C MOVE R9 R4 + 0x7C180600, // 001D CALL R6 3 + 0x881C0B0E, // 001E GETMBR R7 R5 K14 + 0x901A1C07, // 001F SETMBR R6 K14 R7 + 0x8C1C010F, // 0020 GETMET R7 R0 K15 + 0x5C240200, // 0021 MOVE R9 R1 + 0x5C280C00, // 0022 MOVE R10 R6 + 0x5C2C0A00, // 0023 MOVE R11 R5 + 0x7C1C0800, // 0024 CALL R7 4 + 0x501C0200, // 0025 LDBOOL R7 1 0 + 0x80040E00, // 0026 RET 1 R7 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: send_enqueued +********************************************************************/ +be_local_closure(Matter_IM_send_enqueued, /* name */ + be_nested_proto( + 8, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 6]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(send_queue), + /* K2 */ be_nested_str_weak(ready), + /* K3 */ be_nested_str_weak(send), + /* K4 */ be_nested_str_weak(remove), + /* K5 */ be_const_int(1), + }), + be_str_weak(send_enqueued), + &be_const_str_solidified, + ( &(const binstruction[25]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0x600C000C, // 0001 GETGBL R3 G12 + 0x88100101, // 0002 GETMBR R4 R0 K1 + 0x7C0C0200, // 0003 CALL R3 1 + 0x140C0403, // 0004 LT R3 R2 R3 + 0x780E0011, // 0005 JMPF R3 #0018 + 0x880C0101, // 0006 GETMBR R3 R0 K1 + 0x940C0602, // 0007 GETIDX R3 R3 R2 + 0x88100702, // 0008 GETMBR R4 R3 K2 + 0x7812000B, // 0009 JMPF R4 #0016 + 0x8C100703, // 000A GETMET R4 R3 K3 + 0x5C180200, // 000B MOVE R6 R1 + 0x7C100400, // 000C CALL R4 2 + 0x78120005, // 000D JMPF R4 #0014 + 0x88140101, // 000E GETMBR R5 R0 K1 + 0x8C140B04, // 000F GETMET R5 R5 K4 + 0x5C1C0400, // 0010 MOVE R7 R2 + 0x7C140400, // 0011 CALL R5 2 + 0x04080505, // 0012 SUB R2 R2 K5 + 0x70020001, // 0013 JMP #0016 + 0x50140000, // 0014 LDBOOL R5 0 0 + 0x900E0405, // 0015 SETMBR R3 K2 R5 + 0x00080505, // 0016 ADD R2 R2 K5 + 0x7001FFE8, // 0017 JMP #0001 + 0x80000000, // 0018 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: process_invoke_request +********************************************************************/ +be_local_closure(Matter_IM_process_invoke_request, /* name */ + be_nested_proto( + 19, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[44]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(tasmota), + /* K2 */ be_nested_str_weak(log), + /* K3 */ be_nested_str_weak(MTR_X3A_X20IM_X3Ainvoke_request_X20processing_X20start), + /* K4 */ be_nested_str_weak(matter), + /* K5 */ be_nested_str_weak(Path), + /* K6 */ be_nested_str_weak(InvokeRequestMessage), + /* K7 */ be_nested_str_weak(from_TLV), + /* K8 */ be_nested_str_weak(invoke_requests), + /* K9 */ be_nested_str_weak(InvokeResponseMessage), + /* K10 */ be_nested_str_weak(suppress_response), + /* K11 */ be_nested_str_weak(invoke_responses), + /* K12 */ be_nested_str_weak(endpoint), + /* K13 */ be_nested_str_weak(command_path), + /* K14 */ be_nested_str_weak(cluster), + /* K15 */ be_nested_str_weak(command), + /* K16 */ be_nested_str_weak(status), + /* K17 */ be_nested_str_weak(UNSUPPORTED_COMMAND), + /* K18 */ be_nested_str_weak(get_command_name), + /* K19 */ be_nested_str_weak(format), + /* K20 */ be_nested_str_weak(MTR_X3A_X20_X3EReceived_X20_X20_X25s_X20_X25s_X20from_X20_X5B_X25s_X5D_X3A_X25i), + /* K21 */ be_nested_str_weak(), + /* K22 */ be_nested_str_weak(remote_ip), + /* K23 */ be_nested_str_weak(remote_port), + /* K24 */ be_const_int(2), + /* K25 */ be_nested_str_weak(device), + /* K26 */ be_nested_str_weak(invoke_request), + /* K27 */ be_nested_str_weak(command_fields), + /* K28 */ be_nested_str_weak(InvokeResponseIB), + /* K29 */ be_nested_str_weak(CommandStatusIB), + /* K30 */ be_nested_str_weak(CommandPathIB), + /* K31 */ be_nested_str_weak(StatusIB), + /* K32 */ be_nested_str_weak(SUCCESS), + /* K33 */ be_nested_str_weak(push), + /* K34 */ be_nested_str_weak(CommandDataIB), + /* K35 */ be_nested_str_weak(MTR_X3A_X20_X3CReplied_X20_X20_X20_X25s_X20_X25s), + /* K36 */ be_nested_str_weak(stop_iteration), + /* K37 */ be_nested_str_weak(MTR_X3A_X20invoke_responses_X3D), + /* K38 */ be_const_int(0), + /* K39 */ be_nested_str_weak(MTR_X3A_X20InvokeResponse_X3D), + /* K40 */ be_nested_str_weak(MTR_X3A_X20InvokeResponseTLV_X3D), + /* K41 */ be_nested_str_weak(to_TLV), + /* K42 */ be_const_int(3), + /* K43 */ be_nested_str_weak(send_invoke_response), + }), + be_str_weak(process_invoke_request), + &be_const_str_solidified, + ( &(const binstruction[248]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0xB8120200, // 0001 GETNGBL R4 K1 + 0x8C100902, // 0002 GETMET R4 R4 K2 + 0x58180003, // 0003 LDCONST R6 K3 + 0x541E0003, // 0004 LDINT R7 4 + 0x7C100600, // 0005 CALL R4 3 + 0xB8120800, // 0006 GETNGBL R4 K4 + 0x8C100905, // 0007 GETMET R4 R4 K5 + 0x7C100200, // 0008 CALL R4 1 + 0xB8160800, // 0009 GETNGBL R5 K4 + 0x8C140B06, // 000A GETMET R5 R5 K6 + 0x7C140200, // 000B CALL R5 1 + 0x8C140B07, // 000C GETMET R5 R5 K7 + 0x5C1C0400, // 000D MOVE R7 R2 + 0x7C140400, // 000E CALL R5 2 + 0x88180B08, // 000F GETMBR R6 R5 K8 + 0x4C1C0000, // 0010 LDNIL R7 + 0x20180C07, // 0011 NE R6 R6 R7 + 0x781A00E3, // 0012 JMPF R6 #00F7 + 0xB81A0800, // 0013 GETNGBL R6 K4 + 0x8C180D09, // 0014 GETMET R6 R6 K9 + 0x7C180200, // 0015 CALL R6 1 + 0x501C0000, // 0016 LDBOOL R7 0 0 + 0x901A1407, // 0017 SETMBR R6 K10 R7 + 0x601C0012, // 0018 GETGBL R7 G18 + 0x7C1C0000, // 0019 CALL R7 0 + 0x901A1607, // 001A SETMBR R6 K11 R7 + 0x601C0010, // 001B GETGBL R7 G16 + 0x88200B08, // 001C GETMBR R8 R5 K8 + 0x7C1C0200, // 001D CALL R7 1 + 0xA80200AD, // 001E EXBLK 0 #00CD + 0x5C200E00, // 001F MOVE R8 R7 + 0x7C200000, // 0020 CALL R8 0 + 0x8824110D, // 0021 GETMBR R9 R8 K13 + 0x8824130C, // 0022 GETMBR R9 R9 K12 + 0x90121809, // 0023 SETMBR R4 K12 R9 + 0x8824110D, // 0024 GETMBR R9 R8 K13 + 0x8824130E, // 0025 GETMBR R9 R9 K14 + 0x90121C09, // 0026 SETMBR R4 K14 R9 + 0x8824110D, // 0027 GETMBR R9 R8 K13 + 0x8824130F, // 0028 GETMBR R9 R9 K15 + 0x90121E09, // 0029 SETMBR R4 K15 R9 + 0xB8260800, // 002A GETNGBL R9 K4 + 0x88241311, // 002B GETMBR R9 R9 K17 + 0x90122009, // 002C SETMBR R4 K16 R9 + 0xB8260800, // 002D GETNGBL R9 K4 + 0x8C241312, // 002E GETMET R9 R9 K18 + 0x882C090E, // 002F GETMBR R11 R4 K14 + 0x8830090F, // 0030 GETMBR R12 R4 K15 + 0x7C240600, // 0031 CALL R9 3 + 0xB82A0200, // 0032 GETNGBL R10 K1 + 0x8C281502, // 0033 GETMET R10 R10 K2 + 0x8C300713, // 0034 GETMET R12 R3 K19 + 0x58380014, // 0035 LDCONST R14 K20 + 0x603C0008, // 0036 GETGBL R15 G8 + 0x5C400800, // 0037 MOVE R16 R4 + 0x7C3C0200, // 0038 CALL R15 1 + 0x78260001, // 0039 JMPF R9 #003C + 0x5C401200, // 003A MOVE R16 R9 + 0x70020000, // 003B JMP #003D + 0x58400015, // 003C LDCONST R16 K21 + 0x88440316, // 003D GETMBR R17 R1 K22 + 0x88480317, // 003E GETMBR R18 R1 K23 + 0x7C300C00, // 003F CALL R12 6 + 0x58340018, // 0040 LDCONST R13 K24 + 0x7C280600, // 0041 CALL R10 3 + 0x88280119, // 0042 GETMBR R10 R0 K25 + 0x8C28151A, // 0043 GETMET R10 R10 K26 + 0x5C300200, // 0044 MOVE R12 R1 + 0x8834111B, // 0045 GETMBR R13 R8 K27 + 0x5C380800, // 0046 MOVE R14 R4 + 0x7C280800, // 0047 CALL R10 4 + 0xB82E0800, // 0048 GETNGBL R11 K4 + 0x8C2C171C, // 0049 GETMET R11 R11 K28 + 0x7C2C0200, // 004A CALL R11 1 + 0x50300200, // 004B LDBOOL R12 1 0 + 0x1C30140C, // 004C EQ R12 R10 R12 + 0x78320023, // 004D JMPF R12 #0072 + 0xB8320800, // 004E GETNGBL R12 K4 + 0x8C30191D, // 004F GETMET R12 R12 K29 + 0x7C300200, // 0050 CALL R12 1 + 0x902E200C, // 0051 SETMBR R11 K16 R12 + 0x88301710, // 0052 GETMBR R12 R11 K16 + 0xB8360800, // 0053 GETNGBL R13 K4 + 0x8C341B1E, // 0054 GETMET R13 R13 K30 + 0x7C340200, // 0055 CALL R13 1 + 0x90321A0D, // 0056 SETMBR R12 K13 R13 + 0x88301710, // 0057 GETMBR R12 R11 K16 + 0x8830190D, // 0058 GETMBR R12 R12 K13 + 0x8834090C, // 0059 GETMBR R13 R4 K12 + 0x9032180D, // 005A SETMBR R12 K12 R13 + 0x88301710, // 005B GETMBR R12 R11 K16 + 0x8830190D, // 005C GETMBR R12 R12 K13 + 0x8834090E, // 005D GETMBR R13 R4 K14 + 0x90321C0D, // 005E SETMBR R12 K14 R13 + 0x88301710, // 005F GETMBR R12 R11 K16 + 0x8830190D, // 0060 GETMBR R12 R12 K13 + 0x8834090F, // 0061 GETMBR R13 R4 K15 + 0x90321E0D, // 0062 SETMBR R12 K15 R13 + 0x88301710, // 0063 GETMBR R12 R11 K16 + 0xB8360800, // 0064 GETNGBL R13 K4 + 0x8C341B1F, // 0065 GETMET R13 R13 K31 + 0x7C340200, // 0066 CALL R13 1 + 0x9032200D, // 0067 SETMBR R12 K16 R13 + 0x88301710, // 0068 GETMBR R12 R11 K16 + 0x88301910, // 0069 GETMBR R12 R12 K16 + 0xB8360800, // 006A GETNGBL R13 K4 + 0x88341B20, // 006B GETMBR R13 R13 K32 + 0x9032200D, // 006C SETMBR R12 K16 R13 + 0x88300D0B, // 006D GETMBR R12 R6 K11 + 0x8C301921, // 006E GETMET R12 R12 K33 + 0x5C381600, // 006F MOVE R14 R11 + 0x7C300400, // 0070 CALL R12 2 + 0x70020059, // 0071 JMP #00CC + 0x4C300000, // 0072 LDNIL R12 + 0x2030140C, // 0073 NE R12 R10 R12 + 0x7832002F, // 0074 JMPF R12 #00A5 + 0xB8320800, // 0075 GETNGBL R12 K4 + 0x8C301922, // 0076 GETMET R12 R12 K34 + 0x7C300200, // 0077 CALL R12 1 + 0x902E1E0C, // 0078 SETMBR R11 K15 R12 + 0x8830170F, // 0079 GETMBR R12 R11 K15 + 0xB8360800, // 007A GETNGBL R13 K4 + 0x8C341B1E, // 007B GETMET R13 R13 K30 + 0x7C340200, // 007C CALL R13 1 + 0x90321A0D, // 007D SETMBR R12 K13 R13 + 0x8830170F, // 007E GETMBR R12 R11 K15 + 0x8830190D, // 007F GETMBR R12 R12 K13 + 0x8834090C, // 0080 GETMBR R13 R4 K12 + 0x9032180D, // 0081 SETMBR R12 K12 R13 + 0x8830170F, // 0082 GETMBR R12 R11 K15 + 0x8830190D, // 0083 GETMBR R12 R12 K13 + 0x8834090E, // 0084 GETMBR R13 R4 K14 + 0x90321C0D, // 0085 SETMBR R12 K14 R13 + 0x8830170F, // 0086 GETMBR R12 R11 K15 + 0x8830190D, // 0087 GETMBR R12 R12 K13 + 0x8834090F, // 0088 GETMBR R13 R4 K15 + 0x90321E0D, // 0089 SETMBR R12 K15 R13 + 0x8830170F, // 008A GETMBR R12 R11 K15 + 0x9032360A, // 008B SETMBR R12 K27 R10 + 0x88300D0B, // 008C GETMBR R12 R6 K11 + 0x8C301921, // 008D GETMET R12 R12 K33 + 0x5C381600, // 008E MOVE R14 R11 + 0x7C300400, // 008F CALL R12 2 + 0xB8320800, // 0090 GETNGBL R12 K4 + 0x8C301912, // 0091 GETMET R12 R12 K18 + 0x8838090E, // 0092 GETMBR R14 R4 K14 + 0x883C090F, // 0093 GETMBR R15 R4 K15 + 0x7C300600, // 0094 CALL R12 3 + 0x5C241800, // 0095 MOVE R9 R12 + 0xB8320200, // 0096 GETNGBL R12 K1 + 0x8C301902, // 0097 GETMET R12 R12 K2 + 0x8C380713, // 0098 GETMET R14 R3 K19 + 0x58400023, // 0099 LDCONST R16 K35 + 0x60440008, // 009A GETGBL R17 G8 + 0x5C480800, // 009B MOVE R18 R4 + 0x7C440200, // 009C CALL R17 1 + 0x78260001, // 009D JMPF R9 #00A0 + 0x5C481200, // 009E MOVE R18 R9 + 0x70020000, // 009F JMP #00A1 + 0x58480015, // 00A0 LDCONST R18 K21 + 0x7C380800, // 00A1 CALL R14 4 + 0x583C0018, // 00A2 LDCONST R15 K24 + 0x7C300600, // 00A3 CALL R12 3 + 0x70020026, // 00A4 JMP #00CC + 0x88300910, // 00A5 GETMBR R12 R4 K16 + 0x4C340000, // 00A6 LDNIL R13 + 0x2030180D, // 00A7 NE R12 R12 R13 + 0x78320022, // 00A8 JMPF R12 #00CC + 0xB8320800, // 00A9 GETNGBL R12 K4 + 0x8C30191D, // 00AA GETMET R12 R12 K29 + 0x7C300200, // 00AB CALL R12 1 + 0x902E200C, // 00AC SETMBR R11 K16 R12 + 0x88301710, // 00AD GETMBR R12 R11 K16 + 0xB8360800, // 00AE GETNGBL R13 K4 + 0x8C341B1E, // 00AF GETMET R13 R13 K30 + 0x7C340200, // 00B0 CALL R13 1 + 0x90321A0D, // 00B1 SETMBR R12 K13 R13 + 0x88301710, // 00B2 GETMBR R12 R11 K16 + 0x8830190D, // 00B3 GETMBR R12 R12 K13 + 0x8834090C, // 00B4 GETMBR R13 R4 K12 + 0x9032180D, // 00B5 SETMBR R12 K12 R13 + 0x88301710, // 00B6 GETMBR R12 R11 K16 + 0x8830190D, // 00B7 GETMBR R12 R12 K13 + 0x8834090E, // 00B8 GETMBR R13 R4 K14 + 0x90321C0D, // 00B9 SETMBR R12 K14 R13 + 0x88301710, // 00BA GETMBR R12 R11 K16 + 0x8830190D, // 00BB GETMBR R12 R12 K13 + 0x8834090F, // 00BC GETMBR R13 R4 K15 + 0x90321E0D, // 00BD SETMBR R12 K15 R13 + 0x88301710, // 00BE GETMBR R12 R11 K16 + 0xB8360800, // 00BF GETNGBL R13 K4 + 0x8C341B1F, // 00C0 GETMET R13 R13 K31 + 0x7C340200, // 00C1 CALL R13 1 + 0x9032200D, // 00C2 SETMBR R12 K16 R13 + 0x88301710, // 00C3 GETMBR R12 R11 K16 + 0x88301910, // 00C4 GETMBR R12 R12 K16 + 0x88340910, // 00C5 GETMBR R13 R4 K16 + 0x9032200D, // 00C6 SETMBR R12 K16 R13 + 0x88300D0B, // 00C7 GETMBR R12 R6 K11 + 0x8C301921, // 00C8 GETMET R12 R12 K33 + 0x5C381600, // 00C9 MOVE R14 R11 + 0x7C300400, // 00CA CALL R12 2 + 0x7001FFFF, // 00CB JMP #00CC + 0x7001FF51, // 00CC JMP #001F + 0x581C0024, // 00CD LDCONST R7 K36 + 0xAC1C0200, // 00CE CATCH R7 1 0 + 0xB0080000, // 00CF RAISE 2 R0 R0 + 0xB81E0200, // 00D0 GETNGBL R7 K1 + 0x8C1C0F02, // 00D1 GETMET R7 R7 K2 + 0x60240008, // 00D2 GETGBL R9 G8 + 0x88280D0B, // 00D3 GETMBR R10 R6 K11 + 0x7C240200, // 00D4 CALL R9 1 + 0x00264A09, // 00D5 ADD R9 K37 R9 + 0x542A0003, // 00D6 LDINT R10 4 + 0x7C1C0600, // 00D7 CALL R7 3 + 0x601C000C, // 00D8 GETGBL R7 G12 + 0x88200D0B, // 00D9 GETMBR R8 R6 K11 + 0x7C1C0200, // 00DA CALL R7 1 + 0x241C0F26, // 00DB GT R7 R7 K38 + 0x781E0015, // 00DC JMPF R7 #00F3 + 0xB81E0200, // 00DD GETNGBL R7 K1 + 0x8C1C0F02, // 00DE GETMET R7 R7 K2 + 0x60240008, // 00DF GETGBL R9 G8 + 0x5C280C00, // 00E0 MOVE R10 R6 + 0x7C240200, // 00E1 CALL R9 1 + 0x00264E09, // 00E2 ADD R9 K39 R9 + 0x542A0003, // 00E3 LDINT R10 4 + 0x7C1C0600, // 00E4 CALL R7 3 + 0xB81E0200, // 00E5 GETNGBL R7 K1 + 0x8C1C0F02, // 00E6 GETMET R7 R7 K2 + 0x60240008, // 00E7 GETGBL R9 G8 + 0x8C280D29, // 00E8 GETMET R10 R6 K41 + 0x7C280200, // 00E9 CALL R10 1 + 0x7C240200, // 00EA CALL R9 1 + 0x00265009, // 00EB ADD R9 K40 R9 + 0x5828002A, // 00EC LDCONST R10 K42 + 0x7C1C0600, // 00ED CALL R7 3 + 0x8C1C012B, // 00EE GETMET R7 R0 K43 + 0x5C240200, // 00EF MOVE R9 R1 + 0x5C280C00, // 00F0 MOVE R10 R6 + 0x7C1C0600, // 00F1 CALL R7 3 + 0x70020001, // 00F2 JMP #00F5 + 0x501C0000, // 00F3 LDBOOL R7 0 0 + 0x80040E00, // 00F4 RET 1 R7 + 0x501C0200, // 00F5 LDBOOL R7 1 0 + 0x80040E00, // 00F6 RET 1 R7 + 0x80000000, // 00F7 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: process_invoke_response +********************************************************************/ +be_local_closure(Matter_IM_process_invoke_response, /* name */ be_nested_proto( 9, /* nstack */ 3, /* argc */ @@ -1431,14 +1623,14 @@ be_local_closure(Matter_IM_subscribe_request, /* name */ ( &(const bvalue[ 8]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(SubscribeRequestMessage), + /* K2 */ be_nested_str_weak(InvokeResponseMessage), /* K3 */ be_nested_str_weak(from_TLV), /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20SubscribeRequestMessage_X3D), - /* K7 */ be_const_int(3), + /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20InvokeResponseMessage_X3D), + /* K7 */ be_const_int(2), }), - be_str_weak(subscribe_request), + be_str_weak(process_invoke_response), &be_const_str_solidified, ( &(const binstruction[17]) { /* code */ 0xA40E0000, // 0000 IMPORT R3 K0 @@ -1465,9 +1657,59 @@ be_local_closure(Matter_IM_subscribe_request, /* name */ /******************************************************************** -** Solidified function: process_write_response +** Solidified function: find_sendqueue_by_exchangeid ********************************************************************/ -be_local_closure(Matter_IM_process_write_response, /* name */ +be_local_closure(Matter_IM_find_sendqueue_by_exchangeid, /* name */ + be_nested_proto( + 6, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(send_queue), + /* K2 */ be_nested_str_weak(get_exchangeid), + /* K3 */ be_const_int(1), + }), + be_str_weak(find_sendqueue_by_exchangeid), + &be_const_str_solidified, + ( &(const binstruction[22]) { /* code */ + 0x4C080000, // 0000 LDNIL R2 + 0x1C080202, // 0001 EQ R2 R1 R2 + 0x780A0001, // 0002 JMPF R2 #0005 + 0x4C080000, // 0003 LDNIL R2 + 0x80040400, // 0004 RET 1 R2 + 0x58080000, // 0005 LDCONST R2 K0 + 0x600C000C, // 0006 GETGBL R3 G12 + 0x88100101, // 0007 GETMBR R4 R0 K1 + 0x7C0C0200, // 0008 CALL R3 1 + 0x140C0403, // 0009 LT R3 R2 R3 + 0x780E0008, // 000A JMPF R3 #0014 + 0x880C0101, // 000B GETMBR R3 R0 K1 + 0x940C0602, // 000C GETIDX R3 R3 R2 + 0x8C100702, // 000D GETMET R4 R3 K2 + 0x7C100200, // 000E CALL R4 1 + 0x1C100801, // 000F EQ R4 R4 R1 + 0x78120000, // 0010 JMPF R4 #0012 + 0x80040600, // 0011 RET 1 R3 + 0x00080503, // 0012 ADD R2 R2 K3 + 0x7001FFF1, // 0013 JMP #0006 + 0x4C0C0000, // 0014 LDNIL R3 + 0x80040600, // 0015 RET 1 R3 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: report_data +********************************************************************/ +be_local_closure(Matter_IM_report_data, /* name */ be_nested_proto( 9, /* nstack */ 3, /* argc */ @@ -1480,14 +1722,14 @@ be_local_closure(Matter_IM_process_write_response, /* name */ ( &(const bvalue[ 8]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(WriteResponseMessage), + /* K2 */ be_nested_str_weak(ReportDataMessage), /* K3 */ be_nested_str_weak(from_TLV), /* K4 */ be_nested_str_weak(tasmota), /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20WriteResponseMessage_X3D), - /* K7 */ be_const_int(3), + /* K6 */ be_nested_str_weak(MTR_X3A_X20received_X20ReportDataMessage_X3D), + /* K7 */ be_const_int(2), }), - be_str_weak(process_write_response), + be_str_weak(report_data), &be_const_str_solidified, ( &(const binstruction[17]) { /* code */ 0xA40E0000, // 0000 IMPORT R3 K0 @@ -1513,6 +1755,179 @@ be_local_closure(Matter_IM_process_write_response, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: send_invoke_response +********************************************************************/ +be_local_closure(Matter_IM_send_invoke_response, /* name */ + be_nested_proto( + 9, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(send_queue), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(IM_InvokeResponse), + }), + be_str_weak(send_invoke_response), + &be_const_str_solidified, + ( &(const binstruction[ 9]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0xB8160400, // 0002 GETNGBL R5 K2 + 0x8C140B03, // 0003 GETMET R5 R5 K3 + 0x5C1C0200, // 0004 MOVE R7 R1 + 0x5C200400, // 0005 MOVE R8 R2 + 0x7C140600, // 0006 CALL R5 3 + 0x7C0C0400, // 0007 CALL R3 2 + 0x80000000, // 0008 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: process_status_response +********************************************************************/ +be_local_closure(Matter_IM_process_status_response, /* name */ + be_nested_proto( + 11, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[14]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(findsubval), + /* K2 */ be_const_int(0), + /* K3 */ be_nested_str_weak(matter), + /* K4 */ be_nested_str_weak(SUCCESS), + /* K5 */ be_nested_str_weak(tasmota), + /* K6 */ be_nested_str_weak(log), + /* K7 */ be_nested_str_weak(MTR_X3A_X20_X3EStatus), + /* K8 */ be_const_int(2), + /* K9 */ be_nested_str_weak(find_sendqueue_by_exchangeid), + /* K10 */ be_nested_str_weak(exchange_id), + /* K11 */ be_nested_str_weak(ack_received), + /* K12 */ be_nested_str_weak(format), + /* K13 */ be_nested_str_weak(MTR_X3A_X20_X3EStatus_X20_X20_X20_X20ERROR_X20_X3D_X200x_X2502X), + }), + be_str_weak(process_status_response), + &be_const_str_solidified, + ( &(const binstruction[34]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0x8C100501, // 0001 GETMET R4 R2 K1 + 0x58180002, // 0002 LDCONST R6 K2 + 0x541E00FE, // 0003 LDINT R7 255 + 0x7C100600, // 0004 CALL R4 3 + 0xB8160600, // 0005 GETNGBL R5 K3 + 0x88140B04, // 0006 GETMBR R5 R5 K4 + 0x1C140805, // 0007 EQ R5 R4 R5 + 0x7816000E, // 0008 JMPF R5 #0018 + 0xB8160A00, // 0009 GETNGBL R5 K5 + 0x8C140B06, // 000A GETMET R5 R5 K6 + 0x581C0007, // 000B LDCONST R7 K7 + 0x58200008, // 000C LDCONST R8 K8 + 0x7C140600, // 000D CALL R5 3 + 0x8C140109, // 000E GETMET R5 R0 K9 + 0x881C030A, // 000F GETMBR R7 R1 K10 + 0x7C140400, // 0010 CALL R5 2 + 0x78160004, // 0011 JMPF R5 #0017 + 0x8C180B0B, // 0012 GETMET R6 R5 K11 + 0x5C200200, // 0013 MOVE R8 R1 + 0x7C180400, // 0014 CALL R6 2 + 0x50180200, // 0015 LDBOOL R6 1 0 + 0x80040C00, // 0016 RET 1 R6 + 0x70020007, // 0017 JMP #0020 + 0xB8160A00, // 0018 GETNGBL R5 K5 + 0x8C140B06, // 0019 GETMET R5 R5 K6 + 0x8C1C070C, // 001A GETMET R7 R3 K12 + 0x5824000D, // 001B LDCONST R9 K13 + 0x5C280800, // 001C MOVE R10 R4 + 0x7C1C0600, // 001D CALL R7 3 + 0x58200008, // 001E LDCONST R8 K8 + 0x7C140600, // 001F CALL R5 3 + 0x50140000, // 0020 LDBOOL R5 0 0 + 0x80040A00, // 0021 RET 1 R5 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: send_subscribe_update +********************************************************************/ +be_local_closure(Matter_IM_send_subscribe_update, /* name */ + be_nested_proto( + 12, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[13]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(session), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(ReportDataMessage), + /* K4 */ be_nested_str_weak(subscription_id), + /* K5 */ be_nested_str_weak(attribute_reports), + /* K6 */ be_nested_str_weak(suppress_response), + /* K7 */ be_nested_str_weak(send_queue), + /* K8 */ be_nested_str_weak(push), + /* K9 */ be_nested_str_weak(IM_ReportDataSubscribed), + /* K10 */ be_nested_str_weak(device), + /* K11 */ be_nested_str_weak(message_handler), + /* K12 */ be_nested_str_weak(send_enqueued), + }), + be_str_weak(send_subscribe_update), + &be_const_str_solidified, + ( &(const binstruction[27]) { /* code */ + 0xA40A0000, // 0000 IMPORT R2 K0 + 0x880C0301, // 0001 GETMBR R3 R1 K1 + 0xB8120400, // 0002 GETNGBL R4 K2 + 0x8C100903, // 0003 GETMET R4 R4 K3 + 0x7C100200, // 0004 CALL R4 1 + 0x88140304, // 0005 GETMBR R5 R1 K4 + 0x90120805, // 0006 SETMBR R4 K4 R5 + 0x60140012, // 0007 GETGBL R5 G18 + 0x7C140000, // 0008 CALL R5 0 + 0x90120A05, // 0009 SETMBR R4 K5 R5 + 0x50140200, // 000A LDBOOL R5 1 0 + 0x90120C05, // 000B SETMBR R4 K6 R5 + 0x88140107, // 000C GETMBR R5 R0 K7 + 0x8C140B08, // 000D GETMET R5 R5 K8 + 0xB81E0400, // 000E GETNGBL R7 K2 + 0x8C1C0F09, // 000F GETMET R7 R7 K9 + 0x8824010A, // 0010 GETMBR R9 R0 K10 + 0x8824130B, // 0011 GETMBR R9 R9 K11 + 0x5C280600, // 0012 MOVE R10 R3 + 0x5C2C0800, // 0013 MOVE R11 R4 + 0x7C1C0800, // 0014 CALL R7 4 + 0x7C140400, // 0015 CALL R5 2 + 0x8C14010C, // 0016 GETMET R5 R0 K12 + 0x881C010A, // 0017 GETMBR R7 R0 K10 + 0x881C0F0B, // 0018 GETMBR R7 R7 K11 + 0x7C140400, // 0019 CALL R5 2 + 0x80000000, // 001A RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: process_incoming ********************************************************************/ @@ -1595,7 +2010,7 @@ be_local_closure(Matter_IM_process_incoming, /* name */ 0x70020000, // 0022 JMP #0024 0x5818000D, // 0023 LDCONST R6 K13 0x001A1806, // 0024 ADD R6 K12 R6 - 0x581C0005, // 0025 LDCONST R7 K5 + 0x541E0003, // 0025 LDINT R7 4 0x7C100600, // 0026 CALL R4 3 0x8810030E, // 0027 GETMBR R4 R1 K14 0x1C14090F, // 0028 EQ R5 R4 K15 @@ -1692,32 +2107,69 @@ be_local_closure(Matter_IM_process_incoming, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: every_second +********************************************************************/ +be_local_closure(Matter_IM_every_second, /* name */ + be_nested_proto( + 3, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(subs), + /* K1 */ be_nested_str_weak(every_second), + }), + be_str_weak(every_second), + &be_const_str_solidified, + ( &(const binstruction[ 4]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0x80000000, // 0003 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified class: Matter_IM ********************************************************************/ be_local_class(Matter_IM, - 2, + 3, NULL, - be_nested_map(18, + be_nested_map(25, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(process_timed_request, 14), be_const_closure(Matter_IM_process_timed_request_closure) }, - { be_const_key_weak(responder, -1), be_const_var(0) }, - { be_const_key_weak(process_read_request, -1), be_const_closure(Matter_IM_process_read_request_closure) }, - { be_const_key_weak(every_second, 2), be_const_closure(Matter_IM_every_second_closure) }, - { be_const_key_weak(report_data, -1), be_const_closure(Matter_IM_report_data_closure) }, - { be_const_key_weak(process_invoke_response, -1), be_const_closure(Matter_IM_process_invoke_response_closure) }, - { be_const_key_weak(process_write_response, -1), be_const_closure(Matter_IM_process_write_response_closure) }, - { be_const_key_weak(device, -1), be_const_var(1) }, - { be_const_key_weak(subscribe_request, -1), be_const_closure(Matter_IM_subscribe_request_closure) }, - { be_const_key_weak(process_invoke_request, -1), be_const_closure(Matter_IM_process_invoke_request_closure) }, - { be_const_key_weak(MAX_MESSAGE, -1), be_const_int(1200) }, - { be_const_key_weak(process_status_response, 10), be_const_closure(Matter_IM_process_status_response_closure) }, - { be_const_key_weak(send_attr_report, -1), be_const_closure(Matter_IM_send_attr_report_closure) }, - { be_const_key_weak(subscribe_response, 8), be_const_closure(Matter_IM_subscribe_response_closure) }, + { be_const_key_weak(send_subscribe_response, -1), be_const_closure(Matter_IM_send_subscribe_response_closure) }, { be_const_key_weak(process_write_request, -1), be_const_closure(Matter_IM_process_write_request_closure) }, - { be_const_key_weak(init, 7), be_const_closure(Matter_IM_init_closure) }, - { be_const_key_weak(MSG_TIMEOUT, 6), be_const_int(10000) }, + { be_const_key_weak(_inner_process_read_request, -1), be_const_closure(Matter_IM__inner_process_read_request_closure) }, + { be_const_key_weak(process_timed_request, 10), be_const_closure(Matter_IM_process_timed_request_closure) }, + { be_const_key_weak(process_write_response, -1), be_const_closure(Matter_IM_process_write_response_closure) }, + { be_const_key_weak(send_write_response, 12), be_const_closure(Matter_IM_send_write_response_closure) }, + { be_const_key_weak(send_status, 9), be_const_closure(Matter_IM_send_status_closure) }, + { be_const_key_weak(subscribe_response, -1), be_const_closure(Matter_IM_subscribe_response_closure) }, + { be_const_key_weak(every_second, -1), be_const_closure(Matter_IM_every_second_closure) }, + { be_const_key_weak(send_report_data, -1), be_const_closure(Matter_IM_send_report_data_closure) }, + { be_const_key_weak(send_subscribe_update, 23), be_const_closure(Matter_IM_send_subscribe_update_closure) }, + { be_const_key_weak(device, 21), be_const_var(0) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_init_closure) }, + { be_const_key_weak(subscribe_request, -1), be_const_closure(Matter_IM_subscribe_request_closure) }, + { be_const_key_weak(send_enqueued, -1), be_const_closure(Matter_IM_send_enqueued_closure) }, + { be_const_key_weak(process_invoke_request, 8), be_const_closure(Matter_IM_process_invoke_request_closure) }, + { be_const_key_weak(process_invoke_response, -1), be_const_closure(Matter_IM_process_invoke_response_closure) }, + { be_const_key_weak(send_invoke_response, -1), be_const_closure(Matter_IM_send_invoke_response_closure) }, + { be_const_key_weak(report_data, -1), be_const_closure(Matter_IM_report_data_closure) }, + { be_const_key_weak(find_sendqueue_by_exchangeid, 17), be_const_closure(Matter_IM_find_sendqueue_by_exchangeid_closure) }, + { be_const_key_weak(process_status_response, -1), be_const_closure(Matter_IM_process_status_response_closure) }, + { be_const_key_weak(subs, -1), be_const_var(1) }, { be_const_key_weak(process_incoming, -1), be_const_closure(Matter_IM_process_incoming_closure) }, + { be_const_key_weak(process_read_request, 7), be_const_closure(Matter_IM_process_read_request_closure) }, + { be_const_key_weak(send_queue, -1), be_const_var(2) }, })), be_str_weak(Matter_IM) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Data.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Data.h index 738b9ec91..aecff66c6 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Data.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Data.h @@ -3026,7 +3026,7 @@ be_local_closure(Matter_SubscribeRequestMessage_from_TLV, /* name */ /* K4 */ be_const_int(1), /* K5 */ be_nested_str_weak(max_interval_ceiling), /* K6 */ be_const_int(2), - /* K7 */ be_nested_str_weak(attribute_requests), + /* K7 */ be_nested_str_weak(attributes_requests), /* K8 */ be_nested_str_weak(from_TLV_array), /* K9 */ be_const_int(3), /* K10 */ be_nested_str_weak(matter), @@ -3041,7 +3041,7 @@ be_local_closure(Matter_SubscribeRequestMessage_from_TLV, /* name */ }), be_str_weak(from_TLV), &be_const_str_solidified, - ( &(const binstruction[54]) { /* code */ + ( &(const binstruction[58]) { /* code */ 0x4C080000, // 0000 LDNIL R2 0x1C080202, // 0001 EQ R2 R1 R2 0x780A0001, // 0002 JMPF R2 #0005 @@ -3049,53 +3049,57 @@ be_local_closure(Matter_SubscribeRequestMessage_from_TLV, /* name */ 0x80040400, // 0004 RET 1 R2 0x8C080301, // 0005 GETMET R2 R1 K1 0x58100002, // 0006 LDCONST R4 K2 - 0x7C080400, // 0007 CALL R2 2 - 0x90020002, // 0008 SETMBR R0 K0 R2 - 0x8C080301, // 0009 GETMET R2 R1 K1 - 0x58100004, // 000A LDCONST R4 K4 - 0x7C080400, // 000B CALL R2 2 - 0x90020602, // 000C SETMBR R0 K3 R2 - 0x8C080301, // 000D GETMET R2 R1 K1 - 0x58100006, // 000E LDCONST R4 K6 - 0x7C080400, // 000F CALL R2 2 - 0x90020A02, // 0010 SETMBR R0 K5 R2 - 0x8C080108, // 0011 GETMET R2 R0 K8 - 0x8C100301, // 0012 GETMET R4 R1 K1 - 0x58180009, // 0013 LDCONST R6 K9 - 0x7C100400, // 0014 CALL R4 2 - 0xB8161400, // 0015 GETNGBL R5 K10 - 0x88140B0B, // 0016 GETMBR R5 R5 K11 - 0x7C080600, // 0017 CALL R2 3 - 0x90020E02, // 0018 SETMBR R0 K7 R2 - 0x8C080108, // 0019 GETMET R2 R0 K8 - 0x8C100301, // 001A GETMET R4 R1 K1 - 0x541A0003, // 001B LDINT R6 4 - 0x7C100400, // 001C CALL R4 2 - 0xB8161400, // 001D GETNGBL R5 K10 - 0x88140B0D, // 001E GETMBR R5 R5 K13 - 0x7C080600, // 001F CALL R2 3 - 0x90021802, // 0020 SETMBR R0 K12 R2 - 0x8C080108, // 0021 GETMET R2 R0 K8 - 0x8C100301, // 0022 GETMET R4 R1 K1 - 0x541A0004, // 0023 LDINT R6 5 - 0x7C100400, // 0024 CALL R4 2 - 0xB8161400, // 0025 GETNGBL R5 K10 - 0x88140B0F, // 0026 GETMBR R5 R5 K15 - 0x7C080600, // 0027 CALL R2 3 - 0x90021C02, // 0028 SETMBR R0 K14 R2 - 0x8C080301, // 0029 GETMET R2 R1 K1 - 0x54120006, // 002A LDINT R4 7 - 0x7C080400, // 002B CALL R2 2 - 0x90022002, // 002C SETMBR R0 K16 R2 - 0x8C080108, // 002D GETMET R2 R0 K8 - 0x8C100301, // 002E GETMET R4 R1 K1 - 0x541A0007, // 002F LDINT R6 8 - 0x7C100400, // 0030 CALL R4 2 - 0xB8161400, // 0031 GETNGBL R5 K10 - 0x88140B12, // 0032 GETMBR R5 R5 K18 - 0x7C080600, // 0033 CALL R2 3 - 0x90022202, // 0034 SETMBR R0 K17 R2 - 0x80040000, // 0035 RET 1 R0 + 0x50140000, // 0007 LDBOOL R5 0 0 + 0x7C080600, // 0008 CALL R2 3 + 0x90020002, // 0009 SETMBR R0 K0 R2 + 0x8C080301, // 000A GETMET R2 R1 K1 + 0x58100004, // 000B LDCONST R4 K4 + 0x58140002, // 000C LDCONST R5 K2 + 0x7C080600, // 000D CALL R2 3 + 0x90020602, // 000E SETMBR R0 K3 R2 + 0x8C080301, // 000F GETMET R2 R1 K1 + 0x58100006, // 0010 LDCONST R4 K6 + 0x5416003B, // 0011 LDINT R5 60 + 0x7C080600, // 0012 CALL R2 3 + 0x90020A02, // 0013 SETMBR R0 K5 R2 + 0x8C080108, // 0014 GETMET R2 R0 K8 + 0x8C100301, // 0015 GETMET R4 R1 K1 + 0x58180009, // 0016 LDCONST R6 K9 + 0x7C100400, // 0017 CALL R4 2 + 0xB8161400, // 0018 GETNGBL R5 K10 + 0x88140B0B, // 0019 GETMBR R5 R5 K11 + 0x7C080600, // 001A CALL R2 3 + 0x90020E02, // 001B SETMBR R0 K7 R2 + 0x8C080108, // 001C GETMET R2 R0 K8 + 0x8C100301, // 001D GETMET R4 R1 K1 + 0x541A0003, // 001E LDINT R6 4 + 0x7C100400, // 001F CALL R4 2 + 0xB8161400, // 0020 GETNGBL R5 K10 + 0x88140B0D, // 0021 GETMBR R5 R5 K13 + 0x7C080600, // 0022 CALL R2 3 + 0x90021802, // 0023 SETMBR R0 K12 R2 + 0x8C080108, // 0024 GETMET R2 R0 K8 + 0x8C100301, // 0025 GETMET R4 R1 K1 + 0x541A0004, // 0026 LDINT R6 5 + 0x7C100400, // 0027 CALL R4 2 + 0xB8161400, // 0028 GETNGBL R5 K10 + 0x88140B0F, // 0029 GETMBR R5 R5 K15 + 0x7C080600, // 002A CALL R2 3 + 0x90021C02, // 002B SETMBR R0 K14 R2 + 0x8C080301, // 002C GETMET R2 R1 K1 + 0x54120006, // 002D LDINT R4 7 + 0x50140000, // 002E LDBOOL R5 0 0 + 0x7C080600, // 002F CALL R2 3 + 0x90022002, // 0030 SETMBR R0 K16 R2 + 0x8C080108, // 0031 GETMET R2 R0 K8 + 0x8C100301, // 0032 GETMET R4 R1 K1 + 0x541A0007, // 0033 LDINT R6 8 + 0x7C100400, // 0034 CALL R4 2 + 0xB8161400, // 0035 GETNGBL R5 K10 + 0x88140B12, // 0036 GETMBR R5 R5 K18 + 0x7C080600, // 0037 CALL R2 3 + 0x90022202, // 0038 SETMBR R0 K17 R2 + 0x80040000, // 0039 RET 1 R0 }) ) ); @@ -3130,7 +3134,7 @@ be_local_closure(Matter_SubscribeRequestMessage_to_TLV, /* name */ /* K11 */ be_nested_str_weak(max_interval_ceiling), /* K12 */ be_nested_str_weak(to_TLV_array), /* K13 */ be_const_int(3), - /* K14 */ be_nested_str_weak(attribute_requests), + /* K14 */ be_nested_str_weak(attributes_requests), /* K15 */ be_nested_str_weak(event_requests), /* K16 */ be_nested_str_weak(event_filters), /* K17 */ be_nested_str_weak(fabric_filtered), @@ -3207,13 +3211,13 @@ be_local_class(Matter_SubscribeRequestMessage, be_nested_map(10, ( (struct bmapnode*) &(const bmapnode[]) { { be_const_key_weak(to_TLV, -1), be_const_closure(Matter_SubscribeRequestMessage_to_TLV_closure) }, - { be_const_key_weak(event_filters, -1), be_const_var(5) }, - { be_const_key_weak(event_requests, 6), be_const_var(4) }, + { be_const_key_weak(attributes_requests, 7), be_const_var(3) }, + { be_const_key_weak(fabric_filtered, 6), be_const_var(6) }, { be_const_key_weak(min_interval_floor, -1), be_const_var(1) }, { be_const_key_weak(data_version_filters, -1), be_const_var(7) }, { be_const_key_weak(max_interval_ceiling, -1), be_const_var(2) }, - { be_const_key_weak(attribute_requests, 7), be_const_var(3) }, - { be_const_key_weak(fabric_filtered, 3), be_const_var(6) }, + { be_const_key_weak(event_requests, 3), be_const_var(4) }, + { be_const_key_weak(event_filters, -1), be_const_var(5) }, { be_const_key_weak(from_TLV, -1), be_const_closure(Matter_SubscribeRequestMessage_from_TLV_closure) }, { be_const_key_weak(keep_subscriptions, 0), be_const_var(0) }, })), diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Message.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Message.h new file mode 100644 index 000000000..6eec4ee7c --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Message.h @@ -0,0 +1,1024 @@ +/* Solidification of Matter_IM_Message.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_Path; + +/******************************************************************** +** Solidified function: tostring +********************************************************************/ +be_local_closure(Matter_Path_tostring, /* name */ + be_nested_proto( + 7, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[15]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(), + /* K2 */ be_nested_str_weak(endpoint), + /* K3 */ be_nested_str_weak(format), + /* K4 */ be_nested_str_weak(_X5B_X2502X_X5D), + /* K5 */ be_nested_str_weak(_X5B_X2A_X2A_X5D), + /* K6 */ be_nested_str_weak(cluster), + /* K7 */ be_nested_str_weak(_X2504X_X2F), + /* K8 */ be_nested_str_weak(_X2A_X2A_X2A_X2A_X2F), + /* K9 */ be_nested_str_weak(attribute), + /* K10 */ be_nested_str_weak(_X2504X), + /* K11 */ be_nested_str_weak(command), + /* K12 */ be_nested_str_weak(_X2A_X2A_X2A_X2A), + /* K13 */ be_nested_str_weak(Exception_X3E_X20), + /* K14 */ be_nested_str_weak(_X2C_X20), + }), + be_str_weak(tostring), + &be_const_str_solidified, + ( &(const binstruction[75]) { /* code */ + 0xA802003A, // 0000 EXBLK 0 #003C + 0xA4060000, // 0001 IMPORT R1 K0 + 0x58080001, // 0002 LDCONST R2 K1 + 0x880C0102, // 0003 GETMBR R3 R0 K2 + 0x4C100000, // 0004 LDNIL R4 + 0x200C0604, // 0005 NE R3 R3 R4 + 0x780E0004, // 0006 JMPF R3 #000C + 0x8C0C0303, // 0007 GETMET R3 R1 K3 + 0x58140004, // 0008 LDCONST R5 K4 + 0x88180102, // 0009 GETMBR R6 R0 K2 + 0x7C0C0600, // 000A CALL R3 3 + 0x70020000, // 000B JMP #000D + 0x580C0005, // 000C LDCONST R3 K5 + 0x00080403, // 000D ADD R2 R2 R3 + 0x880C0106, // 000E GETMBR R3 R0 K6 + 0x4C100000, // 000F LDNIL R4 + 0x200C0604, // 0010 NE R3 R3 R4 + 0x780E0004, // 0011 JMPF R3 #0017 + 0x8C0C0303, // 0012 GETMET R3 R1 K3 + 0x58140007, // 0013 LDCONST R5 K7 + 0x88180106, // 0014 GETMBR R6 R0 K6 + 0x7C0C0600, // 0015 CALL R3 3 + 0x70020000, // 0016 JMP #0018 + 0x580C0008, // 0017 LDCONST R3 K8 + 0x00080403, // 0018 ADD R2 R2 R3 + 0x880C0109, // 0019 GETMBR R3 R0 K9 + 0x4C100000, // 001A LDNIL R4 + 0x200C0604, // 001B NE R3 R3 R4 + 0x780E0004, // 001C JMPF R3 #0022 + 0x8C0C0303, // 001D GETMET R3 R1 K3 + 0x5814000A, // 001E LDCONST R5 K10 + 0x88180109, // 001F GETMBR R6 R0 K9 + 0x7C0C0600, // 0020 CALL R3 3 + 0x70020000, // 0021 JMP #0023 + 0x580C0001, // 0022 LDCONST R3 K1 + 0x00080403, // 0023 ADD R2 R2 R3 + 0x880C010B, // 0024 GETMBR R3 R0 K11 + 0x4C100000, // 0025 LDNIL R4 + 0x200C0604, // 0026 NE R3 R3 R4 + 0x780E0004, // 0027 JMPF R3 #002D + 0x8C0C0303, // 0028 GETMET R3 R1 K3 + 0x5814000A, // 0029 LDCONST R5 K10 + 0x8818010B, // 002A GETMBR R6 R0 K11 + 0x7C0C0600, // 002B CALL R3 3 + 0x70020000, // 002C JMP #002E + 0x580C0001, // 002D LDCONST R3 K1 + 0x00080403, // 002E ADD R2 R2 R3 + 0x880C0109, // 002F GETMBR R3 R0 K9 + 0x4C100000, // 0030 LDNIL R4 + 0x1C0C0604, // 0031 EQ R3 R3 R4 + 0x780E0004, // 0032 JMPF R3 #0038 + 0x880C010B, // 0033 GETMBR R3 R0 K11 + 0x4C100000, // 0034 LDNIL R4 + 0x1C0C0604, // 0035 EQ R3 R3 R4 + 0x780E0000, // 0036 JMPF R3 #0038 + 0x0008050C, // 0037 ADD R2 R2 K12 + 0xA8040001, // 0038 EXBLK 1 1 + 0x80040400, // 0039 RET 1 R2 + 0xA8040001, // 003A EXBLK 1 1 + 0x7002000D, // 003B JMP #004A + 0xAC040002, // 003C CATCH R1 0 2 + 0x7002000A, // 003D JMP #0049 + 0x600C0008, // 003E GETGBL R3 G8 + 0x5C100200, // 003F MOVE R4 R1 + 0x7C0C0200, // 0040 CALL R3 1 + 0x000E1A03, // 0041 ADD R3 K13 R3 + 0x000C070E, // 0042 ADD R3 R3 K14 + 0x60100008, // 0043 GETGBL R4 G8 + 0x5C140400, // 0044 MOVE R5 R2 + 0x7C100200, // 0045 CALL R4 1 + 0x000C0604, // 0046 ADD R3 R3 R4 + 0x80040600, // 0047 RET 1 R3 + 0x70020000, // 0048 JMP #004A + 0xB0080000, // 0049 RAISE 2 R0 R0 + 0x80000000, // 004A RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_Path +********************************************************************/ +be_local_class(Matter_Path, + 5, + NULL, + be_nested_map(6, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(tostring, -1), be_const_closure(Matter_Path_tostring_closure) }, + { be_const_key_weak(cluster, 3), be_const_var(1) }, + { be_const_key_weak(command, -1), be_const_var(3) }, + { be_const_key_weak(status, 0), be_const_var(4) }, + { be_const_key_weak(endpoint, -1), be_const_var(0) }, + { be_const_key_weak(attribute, -1), be_const_var(2) }, + })), + be_str_weak(Matter_Path) +); +/*******************************************************************/ + +void be_load_Matter_Path_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_Path); + be_setglobal(vm, "Matter_Path"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_Message; + +/******************************************************************** +** Solidified function: send +********************************************************************/ +be_local_closure(Matter_IM_Message_send, /* name */ + be_nested_proto( + 9, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[10]) { /* constants */ + /* K0 */ be_nested_str_weak(resp), + /* K1 */ be_nested_str_weak(encode), + /* K2 */ be_nested_str_weak(data), + /* K3 */ be_nested_str_weak(to_TLV), + /* K4 */ be_nested_str_weak(encrypt), + /* K5 */ be_nested_str_weak(send_response), + /* K6 */ be_nested_str_weak(raw), + /* K7 */ be_nested_str_weak(remote_ip), + /* K8 */ be_nested_str_weak(remote_port), + /* K9 */ be_nested_str_weak(message_counter), + }), + be_str_weak(send), + &be_const_str_solidified, + ( &(const binstruction[18]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x8C0C0501, // 0001 GETMET R3 R2 K1 + 0x88140102, // 0002 GETMBR R5 R0 K2 + 0x8C140B03, // 0003 GETMET R5 R5 K3 + 0x7C140200, // 0004 CALL R5 1 + 0x8C140B01, // 0005 GETMET R5 R5 K1 + 0x7C140200, // 0006 CALL R5 1 + 0x7C0C0400, // 0007 CALL R3 2 + 0x8C0C0504, // 0008 GETMET R3 R2 K4 + 0x7C0C0200, // 0009 CALL R3 1 + 0x8C0C0305, // 000A GETMET R3 R1 K5 + 0x88140506, // 000B GETMBR R5 R2 K6 + 0x88180507, // 000C GETMBR R6 R2 K7 + 0x881C0508, // 000D GETMBR R7 R2 K8 + 0x88200509, // 000E GETMBR R8 R2 K9 + 0x7C0C0A00, // 000F CALL R3 5 + 0x500C0200, // 0010 LDBOOL R3 1 0 + 0x80040600, // 0011 RET 1 R3 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: ack_received +********************************************************************/ +be_local_closure(Matter_IM_Message_ack_received, /* name */ + be_nested_proto( + 7, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(resp), + /* K1 */ be_nested_str_weak(build_response), + /* K2 */ be_nested_str_weak(opcode), + /* K3 */ be_nested_str_weak(x_flag_r), + /* K4 */ be_nested_str_weak(ready), + }), + be_str_weak(ack_received), + &be_const_str_solidified, + ( &(const binstruction[11]) { /* code */ + 0x8C080301, // 0000 GETMET R2 R1 K1 + 0x88100100, // 0001 GETMBR R4 R0 K0 + 0x88100902, // 0002 GETMBR R4 R4 K2 + 0x88140100, // 0003 GETMBR R5 R0 K0 + 0x88140B03, // 0004 GETMBR R5 R5 K3 + 0x88180100, // 0005 GETMBR R6 R0 K0 + 0x7C080800, // 0006 CALL R2 4 + 0x90020002, // 0007 SETMBR R0 K0 R2 + 0x50080200, // 0008 LDBOOL R2 1 0 + 0x90020802, // 0009 SETMBR R0 K4 R2 + 0x80000000, // 000A RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_exchangeid +********************************************************************/ +be_local_closure(Matter_IM_Message_get_exchangeid, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(resp), + /* K1 */ be_nested_str_weak(exchange_id), + }), + be_str_weak(get_exchangeid), + &be_const_str_solidified, + ( &(const binstruction[ 3]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x88040301, // 0001 GETMBR R1 R1 K1 + 0x80040200, // 0002 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_Message_init, /* name */ + be_nested_proto( + 8, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(resp), + /* K1 */ be_nested_str_weak(build_response), + /* K2 */ be_nested_str_weak(ready), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[ 8]) { /* code */ + 0x8C100301, // 0000 GETMET R4 R1 K1 + 0x5C180400, // 0001 MOVE R6 R2 + 0x5C1C0600, // 0002 MOVE R7 R3 + 0x7C100600, // 0003 CALL R4 3 + 0x90020004, // 0004 SETMBR R0 K0 R4 + 0x50100200, // 0005 LDBOOL R4 1 0 + 0x90020404, // 0006 SETMBR R0 K2 R4 + 0x80000000, // 0007 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_Message +********************************************************************/ +be_local_class(Matter_IM_Message, + 3, + NULL, + be_nested_map(7, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(resp, -1), be_const_var(0) }, + { be_const_key_weak(ready, 6), be_const_var(1) }, + { be_const_key_weak(send, -1), be_const_closure(Matter_IM_Message_send_closure) }, + { be_const_key_weak(ack_received, -1), be_const_closure(Matter_IM_Message_ack_received_closure) }, + { be_const_key_weak(get_exchangeid, -1), be_const_closure(Matter_IM_Message_get_exchangeid_closure) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_Message_init_closure) }, + { be_const_key_weak(data, -1), be_const_var(2) }, + })), + be_str_weak(Matter_IM_Message) +); +/*******************************************************************/ + +void be_load_Matter_IM_Message_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_Message); + be_setglobal(vm, "Matter_IM_Message"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_Status; + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_Status_init, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 7]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_const_int(1), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(StatusResponseMessage), + /* K4 */ be_nested_str_weak(status), + /* K5 */ be_nested_str_weak(data), + /* K6 */ be_nested_str_weak(ready), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[16]) { /* code */ + 0x600C0003, // 0000 GETGBL R3 G3 + 0x5C100000, // 0001 MOVE R4 R0 + 0x7C0C0200, // 0002 CALL R3 1 + 0x8C0C0700, // 0003 GETMET R3 R3 K0 + 0x5C140200, // 0004 MOVE R5 R1 + 0x58180001, // 0005 LDCONST R6 K1 + 0x501C0200, // 0006 LDBOOL R7 1 0 + 0x7C0C0800, // 0007 CALL R3 4 + 0xB80E0400, // 0008 GETNGBL R3 K2 + 0x8C0C0703, // 0009 GETMET R3 R3 K3 + 0x7C0C0200, // 000A CALL R3 1 + 0x900E0802, // 000B SETMBR R3 K4 R2 + 0x90020A03, // 000C SETMBR R0 K5 R3 + 0x50100200, // 000D LDBOOL R4 1 0 + 0x90020C04, // 000E SETMBR R0 K6 R4 + 0x80000000, // 000F RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_Status +********************************************************************/ +extern const bclass be_class_Matter_IM_Message; +be_local_class(Matter_IM_Status, + 0, + &be_class_Matter_IM_Message, + be_nested_map(1, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_Status_init_closure) }, + })), + be_str_weak(Matter_IM_Status) +); +/*******************************************************************/ + +void be_load_Matter_IM_Status_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_Status); + be_setglobal(vm, "Matter_IM_Status"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_InvokeResponse; + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_InvokeResponse_init, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(data), + /* K2 */ be_nested_str_weak(ready), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[12]) { /* code */ + 0x600C0003, // 0000 GETGBL R3 G3 + 0x5C100000, // 0001 MOVE R4 R0 + 0x7C0C0200, // 0002 CALL R3 1 + 0x8C0C0700, // 0003 GETMET R3 R3 K0 + 0x5C140200, // 0004 MOVE R5 R1 + 0x541A0008, // 0005 LDINT R6 9 + 0x501C0200, // 0006 LDBOOL R7 1 0 + 0x7C0C0800, // 0007 CALL R3 4 + 0x90020202, // 0008 SETMBR R0 K1 R2 + 0x500C0200, // 0009 LDBOOL R3 1 0 + 0x90020403, // 000A SETMBR R0 K2 R3 + 0x80000000, // 000B RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_InvokeResponse +********************************************************************/ +extern const bclass be_class_Matter_IM_Message; +be_local_class(Matter_IM_InvokeResponse, + 0, + &be_class_Matter_IM_Message, + be_nested_map(1, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_InvokeResponse_init_closure) }, + })), + be_str_weak(Matter_IM_InvokeResponse) +); +/*******************************************************************/ + +void be_load_Matter_IM_InvokeResponse_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_InvokeResponse); + be_setglobal(vm, "Matter_IM_InvokeResponse"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_WriteResponse; + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_WriteResponse_init, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(data), + /* K2 */ be_nested_str_weak(ready), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[12]) { /* code */ + 0x600C0003, // 0000 GETGBL R3 G3 + 0x5C100000, // 0001 MOVE R4 R0 + 0x7C0C0200, // 0002 CALL R3 1 + 0x8C0C0700, // 0003 GETMET R3 R3 K0 + 0x5C140200, // 0004 MOVE R5 R1 + 0x541A0006, // 0005 LDINT R6 7 + 0x501C0200, // 0006 LDBOOL R7 1 0 + 0x7C0C0800, // 0007 CALL R3 4 + 0x90020202, // 0008 SETMBR R0 K1 R2 + 0x500C0200, // 0009 LDBOOL R3 1 0 + 0x90020403, // 000A SETMBR R0 K2 R3 + 0x80000000, // 000B RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_WriteResponse +********************************************************************/ +extern const bclass be_class_Matter_IM_Message; +be_local_class(Matter_IM_WriteResponse, + 0, + &be_class_Matter_IM_Message, + be_nested_map(1, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_WriteResponse_init_closure) }, + })), + be_str_weak(Matter_IM_WriteResponse) +); +/*******************************************************************/ + +void be_load_Matter_IM_WriteResponse_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_WriteResponse); + be_setglobal(vm, "Matter_IM_WriteResponse"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_ReportData; + +/******************************************************************** +** Solidified function: send +********************************************************************/ +be_local_closure(Matter_IM_ReportData_send, /* name */ + be_nested_proto( + 17, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[31]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(resp), + /* K2 */ be_nested_str_weak(data), + /* K3 */ be_nested_str_weak(more_chunked_messages), + /* K4 */ be_const_int(0), + /* K5 */ be_nested_str_weak(attribute_reports), + /* K6 */ be_nested_str_weak(to_TLV), + /* K7 */ be_nested_str_weak(encode_len), + /* K8 */ be_const_int(1), + /* K9 */ be_nested_str_weak(MAX_MESSAGE), + /* K10 */ be_nested_str_weak(tasmota), + /* K11 */ be_nested_str_weak(log), + /* K12 */ be_nested_str_weak(format), + /* K13 */ be_nested_str_weak(MTR_X3A_X20elements_X3D_X25i_X20msg_sz_X3D_X25i_X20total_X3D_X25i), + /* K14 */ be_const_int(3), + /* K15 */ be_const_int(2147483647), + /* K16 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X20next_chunk_X20exch_X3D_X25i), + /* K17 */ be_nested_str_weak(get_exchangeid), + /* K18 */ be_nested_str_weak(MTR_X3A_X20Read_Attr_X20_X20first_chunk_X20exch_X3D_X25i), + /* K19 */ be_nested_str_weak(MTR_X3A_X20sending_X20TLV), + /* K20 */ be_nested_str_weak(encode), + /* K21 */ be_nested_str_weak(encrypt), + /* K22 */ be_nested_str_weak(send_response), + /* K23 */ be_nested_str_weak(raw), + /* K24 */ be_nested_str_weak(remote_ip), + /* K25 */ be_nested_str_weak(remote_port), + /* K26 */ be_nested_str_weak(message_counter), + /* K27 */ be_nested_str_weak(MTR_X3A_X20to_be_sent_later_X20TLV), + /* K28 */ be_nested_str_weak(expiration), + /* K29 */ be_nested_str_weak(millis), + /* K30 */ be_nested_str_weak(MSG_TIMEOUT), + }), + be_str_weak(send), + &be_const_str_solidified, + ( &(const binstruction[139]) { /* code */ + 0xA40A0000, // 0000 IMPORT R2 K0 + 0x880C0101, // 0001 GETMBR R3 R0 K1 + 0x88100102, // 0002 GETMBR R4 R0 K2 + 0x88140903, // 0003 GETMBR R5 R4 K3 + 0x58180004, // 0004 LDCONST R6 K4 + 0x581C0004, // 0005 LDCONST R7 K4 + 0x6020000C, // 0006 GETGBL R8 G12 + 0x88240905, // 0007 GETMBR R9 R4 K5 + 0x7C200200, // 0008 CALL R8 1 + 0x24201104, // 0009 GT R8 R8 K4 + 0x78220007, // 000A JMPF R8 #0013 + 0x88200905, // 000B GETMBR R8 R4 K5 + 0x94201104, // 000C GETIDX R8 R8 K4 + 0x8C201106, // 000D GETMET R8 R8 K6 + 0x7C200200, // 000E CALL R8 1 + 0x8C201107, // 000F GETMET R8 R8 K7 + 0x7C200200, // 0010 CALL R8 1 + 0x5C181000, // 0011 MOVE R6 R8 + 0x581C0008, // 0012 LDCONST R7 K8 + 0x88200109, // 0013 GETMBR R8 R0 K9 + 0x14200C08, // 0014 LT R8 R6 R8 + 0x78220013, // 0015 JMPF R8 #002A + 0x6020000C, // 0016 GETGBL R8 G12 + 0x88240905, // 0017 GETMBR R9 R4 K5 + 0x7C200200, // 0018 CALL R8 1 + 0x14200E08, // 0019 LT R8 R7 R8 + 0x7822000E, // 001A JMPF R8 #002A + 0x88200905, // 001B GETMBR R8 R4 K5 + 0x94201007, // 001C GETIDX R8 R8 R7 + 0x8C201106, // 001D GETMET R8 R8 K6 + 0x7C200200, // 001E CALL R8 1 + 0x8C201107, // 001F GETMET R8 R8 K7 + 0x7C200200, // 0020 CALL R8 1 + 0x00240C08, // 0021 ADD R9 R6 R8 + 0x88280109, // 0022 GETMBR R10 R0 K9 + 0x1424120A, // 0023 LT R9 R9 R10 + 0x78260002, // 0024 JMPF R9 #0028 + 0x00180C08, // 0025 ADD R6 R6 R8 + 0x001C0F08, // 0026 ADD R7 R7 K8 + 0x70020000, // 0027 JMP #0029 + 0x70020000, // 0028 JMP #002A + 0x7001FFE8, // 0029 JMP #0013 + 0xB8221400, // 002A GETNGBL R8 K10 + 0x8C20110B, // 002B GETMET R8 R8 K11 + 0x8C28050C, // 002C GETMET R10 R2 K12 + 0x5830000D, // 002D LDCONST R12 K13 + 0x5C340E00, // 002E MOVE R13 R7 + 0x5C380C00, // 002F MOVE R14 R6 + 0x603C000C, // 0030 GETGBL R15 G12 + 0x88400905, // 0031 GETMBR R16 R4 K5 + 0x7C3C0200, // 0032 CALL R15 1 + 0x7C280A00, // 0033 CALL R10 5 + 0x582C000E, // 0034 LDCONST R11 K14 + 0x7C200600, // 0035 CALL R8 3 + 0x40200F0F, // 0036 CONNECT R8 R7 K15 + 0x88240905, // 0037 GETMBR R9 R4 K5 + 0x94201208, // 0038 GETIDX R8 R9 R8 + 0x04280F08, // 0039 SUB R10 R7 K8 + 0x402A080A, // 003A CONNECT R10 K4 R10 + 0x882C0905, // 003B GETMBR R11 R4 K5 + 0x9428160A, // 003C GETIDX R10 R11 R10 + 0x90120A0A, // 003D SETMBR R4 K5 R10 + 0x6028000C, // 003E GETGBL R10 G12 + 0x5C2C1000, // 003F MOVE R11 R8 + 0x7C280200, // 0040 CALL R10 1 + 0x24281504, // 0041 GT R10 R10 K4 + 0x9012060A, // 0042 SETMBR R4 K3 R10 + 0x78160008, // 0043 JMPF R5 #004D + 0xB82A1400, // 0044 GETNGBL R10 K10 + 0x8C28150B, // 0045 GETMET R10 R10 K11 + 0x8C30050C, // 0046 GETMET R12 R2 K12 + 0x58380010, // 0047 LDCONST R14 K16 + 0x8C3C0111, // 0048 GETMET R15 R0 K17 + 0x7C3C0200, // 0049 CALL R15 1 + 0x7C300600, // 004A CALL R12 3 + 0x5834000E, // 004B LDCONST R13 K14 + 0x7C280600, // 004C CALL R10 3 + 0x88240903, // 004D GETMBR R9 R4 K3 + 0x78260012, // 004E JMPF R9 #0062 + 0x5C240A00, // 004F MOVE R9 R5 + 0x74260008, // 0050 JMPT R9 #005A + 0xB8261400, // 0051 GETNGBL R9 K10 + 0x8C24130B, // 0052 GETMET R9 R9 K11 + 0x8C2C050C, // 0053 GETMET R11 R2 K12 + 0x58340012, // 0054 LDCONST R13 K18 + 0x8C380111, // 0055 GETMET R14 R0 K17 + 0x7C380200, // 0056 CALL R14 1 + 0x7C2C0600, // 0057 CALL R11 3 + 0x5830000E, // 0058 LDCONST R12 K14 + 0x7C240600, // 0059 CALL R9 3 + 0xB8261400, // 005A GETNGBL R9 K10 + 0x8C24130B, // 005B GETMET R9 R9 K11 + 0x602C0008, // 005C GETGBL R11 G8 + 0x5C300800, // 005D MOVE R12 R4 + 0x7C2C0200, // 005E CALL R11 1 + 0x002E260B, // 005F ADD R11 K19 R11 + 0x5830000E, // 0060 LDCONST R12 K14 + 0x7C240600, // 0061 CALL R9 3 + 0x8C240714, // 0062 GETMET R9 R3 K20 + 0x882C0102, // 0063 GETMBR R11 R0 K2 + 0x8C2C1706, // 0064 GETMET R11 R11 K6 + 0x7C2C0200, // 0065 CALL R11 1 + 0x8C2C1714, // 0066 GETMET R11 R11 K20 + 0x7C2C0200, // 0067 CALL R11 1 + 0x7C240400, // 0068 CALL R9 2 + 0x8C240715, // 0069 GETMET R9 R3 K21 + 0x7C240200, // 006A CALL R9 1 + 0x8C240316, // 006B GETMET R9 R1 K22 + 0x882C0717, // 006C GETMBR R11 R3 K23 + 0x88300718, // 006D GETMBR R12 R3 K24 + 0x88340719, // 006E GETMBR R13 R3 K25 + 0x8838071A, // 006F GETMBR R14 R3 K26 + 0x7C240A00, // 0070 CALL R9 5 + 0x6024000C, // 0071 GETGBL R9 G12 + 0x5C281000, // 0072 MOVE R10 R8 + 0x7C240200, // 0073 CALL R9 1 + 0x24241304, // 0074 GT R9 R9 K4 + 0x78260011, // 0075 JMPF R9 #0088 + 0x90120A08, // 0076 SETMBR R4 K5 R8 + 0xB8261400, // 0077 GETNGBL R9 K10 + 0x8C24130B, // 0078 GETMET R9 R9 K11 + 0x602C0008, // 0079 GETGBL R11 G8 + 0x5C300800, // 007A MOVE R12 R4 + 0x7C2C0200, // 007B CALL R11 1 + 0x002E360B, // 007C ADD R11 K27 R11 + 0x5830000E, // 007D LDCONST R12 K14 + 0x7C240600, // 007E CALL R9 3 + 0xB8261400, // 007F GETNGBL R9 K10 + 0x8C24131D, // 0080 GETMET R9 R9 K29 + 0x7C240200, // 0081 CALL R9 1 + 0x8828011E, // 0082 GETMBR R10 R0 K30 + 0x0024120A, // 0083 ADD R9 R9 R10 + 0x90023809, // 0084 SETMBR R0 K28 R9 + 0x50240000, // 0085 LDBOOL R9 0 0 + 0x80041200, // 0086 RET 1 R9 + 0x70020001, // 0087 JMP #008A + 0x50240200, // 0088 LDBOOL R9 1 0 + 0x80041200, // 0089 RET 1 R9 + 0x80000000, // 008A RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_ReportData_init, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 7]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(data), + /* K2 */ be_nested_str_weak(ready), + /* K3 */ be_nested_str_weak(expiration), + /* K4 */ be_nested_str_weak(tasmota), + /* K5 */ be_nested_str_weak(millis), + /* K6 */ be_nested_str_weak(MSG_TIMEOUT), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[18]) { /* code */ + 0x600C0003, // 0000 GETGBL R3 G3 + 0x5C100000, // 0001 MOVE R4 R0 + 0x7C0C0200, // 0002 CALL R3 1 + 0x8C0C0700, // 0003 GETMET R3 R3 K0 + 0x5C140200, // 0004 MOVE R5 R1 + 0x541A0004, // 0005 LDINT R6 5 + 0x501C0200, // 0006 LDBOOL R7 1 0 + 0x7C0C0800, // 0007 CALL R3 4 + 0x90020202, // 0008 SETMBR R0 K1 R2 + 0x500C0200, // 0009 LDBOOL R3 1 0 + 0x90020403, // 000A SETMBR R0 K2 R3 + 0xB80E0800, // 000B GETNGBL R3 K4 + 0x8C0C0705, // 000C GETMET R3 R3 K5 + 0x7C0C0200, // 000D CALL R3 1 + 0x88100106, // 000E GETMBR R4 R0 K6 + 0x000C0604, // 000F ADD R3 R3 R4 + 0x90020603, // 0010 SETMBR R0 K3 R3 + 0x80000000, // 0011 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_ReportData +********************************************************************/ +extern const bclass be_class_Matter_IM_Message; +be_local_class(Matter_IM_ReportData, + 1, + &be_class_Matter_IM_Message, + be_nested_map(5, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(expiration, 2), be_const_var(0) }, + { be_const_key_weak(send, -1), be_const_closure(Matter_IM_ReportData_send_closure) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_ReportData_init_closure) }, + { be_const_key_weak(MAX_MESSAGE, 4), be_const_int(1200) }, + { be_const_key_weak(MSG_TIMEOUT, -1), be_const_int(10000) }, + })), + be_str_weak(Matter_IM_ReportData) +); +/*******************************************************************/ + +void be_load_Matter_IM_ReportData_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_ReportData); + be_setglobal(vm, "Matter_IM_ReportData"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_ReportDataSubscribed; + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_ReportDataSubscribed_init, /* name */ + be_nested_proto( + 10, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[10]) { /* constants */ + /* K0 */ be_nested_str_weak(resp), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(Frame), + /* K3 */ be_nested_str_weak(initiate_response), + /* K4 */ be_nested_str_weak(data), + /* K5 */ be_nested_str_weak(ready), + /* K6 */ be_nested_str_weak(expiration), + /* K7 */ be_nested_str_weak(tasmota), + /* K8 */ be_nested_str_weak(millis), + /* K9 */ be_nested_str_weak(MSG_TIMEOUT), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[19]) { /* code */ + 0xB8120200, // 0000 GETNGBL R4 K1 + 0x88100902, // 0001 GETMBR R4 R4 K2 + 0x8C100903, // 0002 GETMET R4 R4 K3 + 0x5C180200, // 0003 MOVE R6 R1 + 0x5C1C0400, // 0004 MOVE R7 R2 + 0x54220004, // 0005 LDINT R8 5 + 0x50240200, // 0006 LDBOOL R9 1 0 + 0x7C100A00, // 0007 CALL R4 5 + 0x90020004, // 0008 SETMBR R0 K0 R4 + 0x90020803, // 0009 SETMBR R0 K4 R3 + 0x50100200, // 000A LDBOOL R4 1 0 + 0x90020A04, // 000B SETMBR R0 K5 R4 + 0xB8120E00, // 000C GETNGBL R4 K7 + 0x8C100908, // 000D GETMET R4 R4 K8 + 0x7C100200, // 000E CALL R4 1 + 0x88140109, // 000F GETMBR R5 R0 K9 + 0x00100805, // 0010 ADD R4 R4 R5 + 0x90020C04, // 0011 SETMBR R0 K6 R4 + 0x80000000, // 0012 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_ReportDataSubscribed +********************************************************************/ +extern const bclass be_class_Matter_IM_ReportData; +be_local_class(Matter_IM_ReportDataSubscribed, + 0, + &be_class_Matter_IM_ReportData, + be_nested_map(1, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_ReportDataSubscribed_init_closure) }, + })), + be_str_weak(Matter_IM_ReportDataSubscribed) +); +/*******************************************************************/ + +void be_load_Matter_IM_ReportDataSubscribed_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_ReportDataSubscribed); + be_setglobal(vm, "Matter_IM_ReportDataSubscribed"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_SubscribeResponse; + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_SubscribeResponse_init, /* name */ + be_nested_proto( + 8, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(sub), + /* K2 */ be_nested_str_weak(report_data_phase), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[11]) { /* code */ + 0x60100003, // 0000 GETGBL R4 G3 + 0x5C140000, // 0001 MOVE R5 R0 + 0x7C100200, // 0002 CALL R4 1 + 0x8C100900, // 0003 GETMET R4 R4 K0 + 0x5C180200, // 0004 MOVE R6 R1 + 0x5C1C0400, // 0005 MOVE R7 R2 + 0x7C100600, // 0006 CALL R4 3 + 0x90020203, // 0007 SETMBR R0 K1 R3 + 0x50100200, // 0008 LDBOOL R4 1 0 + 0x90020404, // 0009 SETMBR R0 K2 R4 + 0x80000000, // 000A RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: send +********************************************************************/ +be_local_closure(Matter_IM_SubscribeResponse_send, /* name */ + be_nested_proto( + 10, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[17]) { /* constants */ + /* K0 */ be_nested_str_weak(report_data_phase), + /* K1 */ be_nested_str_weak(send), + /* K2 */ be_nested_str_weak(resp), + /* K3 */ be_nested_str_weak(matter), + /* K4 */ be_nested_str_weak(SubscribeResponseMessage), + /* K5 */ be_nested_str_weak(subscription_id), + /* K6 */ be_nested_str_weak(sub), + /* K7 */ be_nested_str_weak(max_interval), + /* K8 */ be_nested_str_weak(opcode), + /* K9 */ be_nested_str_weak(encode), + /* K10 */ be_nested_str_weak(to_TLV), + /* K11 */ be_nested_str_weak(encrypt), + /* K12 */ be_nested_str_weak(send_response), + /* K13 */ be_nested_str_weak(raw), + /* K14 */ be_nested_str_weak(remote_ip), + /* K15 */ be_nested_str_weak(remote_port), + /* K16 */ be_nested_str_weak(message_counter), + }), + be_str_weak(send), + &be_const_str_solidified, + ( &(const binstruction[47]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x780A000E, // 0001 JMPF R2 #0011 + 0x60080003, // 0002 GETGBL R2 G3 + 0x5C0C0000, // 0003 MOVE R3 R0 + 0x7C080200, // 0004 CALL R2 1 + 0x8C080501, // 0005 GETMET R2 R2 K1 + 0x5C100200, // 0006 MOVE R4 R1 + 0x7C080400, // 0007 CALL R2 2 + 0x5C0C0400, // 0008 MOVE R3 R2 + 0x740E0001, // 0009 JMPT R3 #000C + 0x500C0000, // 000A LDBOOL R3 0 0 + 0x80040600, // 000B RET 1 R3 + 0x500C0000, // 000C LDBOOL R3 0 0 + 0x90020003, // 000D SETMBR R0 K0 R3 + 0x500C0000, // 000E LDBOOL R3 0 0 + 0x80040600, // 000F RET 1 R3 + 0x7002001C, // 0010 JMP #002E + 0x88080102, // 0011 GETMBR R2 R0 K2 + 0xB80E0600, // 0012 GETNGBL R3 K3 + 0x8C0C0704, // 0013 GETMET R3 R3 K4 + 0x7C0C0200, // 0014 CALL R3 1 + 0x88100106, // 0015 GETMBR R4 R0 K6 + 0x88100905, // 0016 GETMBR R4 R4 K5 + 0x900E0A04, // 0017 SETMBR R3 K5 R4 + 0x88100106, // 0018 GETMBR R4 R0 K6 + 0x88100907, // 0019 GETMBR R4 R4 K7 + 0x900E0E04, // 001A SETMBR R3 K7 R4 + 0x88100102, // 001B GETMBR R4 R0 K2 + 0x54160003, // 001C LDINT R5 4 + 0x90121005, // 001D SETMBR R4 K8 R5 + 0x8C100509, // 001E GETMET R4 R2 K9 + 0x8C18070A, // 001F GETMET R6 R3 K10 + 0x7C180200, // 0020 CALL R6 1 + 0x8C180D09, // 0021 GETMET R6 R6 K9 + 0x7C180200, // 0022 CALL R6 1 + 0x7C100400, // 0023 CALL R4 2 + 0x8C10050B, // 0024 GETMET R4 R2 K11 + 0x7C100200, // 0025 CALL R4 1 + 0x8C10030C, // 0026 GETMET R4 R1 K12 + 0x8818050D, // 0027 GETMBR R6 R2 K13 + 0x881C050E, // 0028 GETMBR R7 R2 K14 + 0x8820050F, // 0029 GETMBR R8 R2 K15 + 0x88240510, // 002A GETMBR R9 R2 K16 + 0x7C100A00, // 002B CALL R4 5 + 0x50100200, // 002C LDBOOL R4 1 0 + 0x80040800, // 002D RET 1 R4 + 0x80000000, // 002E RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_SubscribeResponse +********************************************************************/ +extern const bclass be_class_Matter_IM_ReportData; +be_local_class(Matter_IM_SubscribeResponse, + 2, + &be_class_Matter_IM_ReportData, + be_nested_map(4, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(report_data_phase, -1), be_const_var(1) }, + { be_const_key_weak(sub, -1), be_const_var(0) }, + { be_const_key_weak(send, -1), be_const_closure(Matter_IM_SubscribeResponse_send_closure) }, + { be_const_key_weak(init, 2), be_const_closure(Matter_IM_SubscribeResponse_init_closure) }, + })), + be_str_weak(Matter_IM_SubscribeResponse) +); +/*******************************************************************/ + +void be_load_Matter_IM_SubscribeResponse_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_SubscribeResponse); + be_setglobal(vm, "Matter_IM_SubscribeResponse"); + be_pop(vm, 1); +} +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Subscription.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Subscription.h new file mode 100644 index 000000000..cc1075706 --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM_Subscription.h @@ -0,0 +1,585 @@ +/* Solidification of Matter_IM_Subscription.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_IM_Subscription; + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_Subscription_init, /* name */ + be_nested_proto( + 12, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[24]) { /* constants */ + /* K0 */ be_nested_str_weak(subscription_id), + /* K1 */ be_nested_str_weak(session), + /* K2 */ be_nested_str_weak(min_interval_floor), + /* K3 */ be_const_int(0), + /* K4 */ be_nested_str_weak(min_interval), + /* K5 */ be_nested_str_weak(max_interval_ceiling), + /* K6 */ be_nested_str_weak(max_interval), + /* K7 */ be_nested_str_weak(fabric_filtered), + /* K8 */ be_nested_str_weak(path_list), + /* K9 */ be_nested_str_weak(attributes_requests), + /* K10 */ be_nested_str_weak(matter), + /* K11 */ be_nested_str_weak(Path), + /* K12 */ be_nested_str_weak(endpoint), + /* K13 */ be_nested_str_weak(cluster), + /* K14 */ be_nested_str_weak(attribute), + /* K15 */ be_nested_str_weak(push), + /* K16 */ be_nested_str_weak(stop_iteration), + /* K17 */ be_nested_str_weak(updates), + /* K18 */ be_nested_str_weak(clear_and_arm), + /* K19 */ be_nested_str_weak(tasmota), + /* K20 */ be_nested_str_weak(log), + /* K21 */ be_nested_str_weak(MTR_X3A_X20new_X20subsctiption_X20), + /* K22 */ be_nested_str_weak(inspect), + /* K23 */ be_const_int(2), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[64]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x90020202, // 0001 SETMBR R0 K1 R2 + 0x88100702, // 0002 GETMBR R4 R3 K2 + 0x14140903, // 0003 LT R5 R4 K3 + 0x78160000, // 0004 JMPF R5 #0006 + 0x58100003, // 0005 LDCONST R4 K3 + 0x5416003B, // 0006 LDINT R5 60 + 0x24140805, // 0007 GT R5 R4 R5 + 0x78160000, // 0008 JMPF R5 #000A + 0x5412003B, // 0009 LDINT R4 60 + 0x90020804, // 000A SETMBR R0 K4 R4 + 0x88140705, // 000B GETMBR R5 R3 K5 + 0x541A003B, // 000C LDINT R6 60 + 0x14180A06, // 000D LT R6 R5 R6 + 0x781A0000, // 000E JMPF R6 #0010 + 0x5416003B, // 000F LDINT R5 60 + 0x541A0E0F, // 0010 LDINT R6 3600 + 0x24180A06, // 0011 GT R6 R5 R6 + 0x781A0000, // 0012 JMPF R6 #0014 + 0x54160E0F, // 0013 LDINT R5 3600 + 0x90020C05, // 0014 SETMBR R0 K6 R5 + 0x88180707, // 0015 GETMBR R6 R3 K7 + 0x90020E06, // 0016 SETMBR R0 K7 R6 + 0x60180012, // 0017 GETGBL R6 G18 + 0x7C180000, // 0018 CALL R6 0 + 0x90021006, // 0019 SETMBR R0 K8 R6 + 0x60180010, // 001A GETGBL R6 G16 + 0x881C0709, // 001B GETMBR R7 R3 K9 + 0x7C180200, // 001C CALL R6 1 + 0xA802000F, // 001D EXBLK 0 #002E + 0x5C1C0C00, // 001E MOVE R7 R6 + 0x7C1C0000, // 001F CALL R7 0 + 0xB8221400, // 0020 GETNGBL R8 K10 + 0x8C20110B, // 0021 GETMET R8 R8 K11 + 0x7C200200, // 0022 CALL R8 1 + 0x88240F0C, // 0023 GETMBR R9 R7 K12 + 0x90221809, // 0024 SETMBR R8 K12 R9 + 0x88240F0D, // 0025 GETMBR R9 R7 K13 + 0x90221A09, // 0026 SETMBR R8 K13 R9 + 0x88240F0E, // 0027 GETMBR R9 R7 K14 + 0x90221C09, // 0028 SETMBR R8 K14 R9 + 0x88240108, // 0029 GETMBR R9 R0 K8 + 0x8C24130F, // 002A GETMET R9 R9 K15 + 0x5C2C1000, // 002B MOVE R11 R8 + 0x7C240400, // 002C CALL R9 2 + 0x7001FFEF, // 002D JMP #001E + 0x58180010, // 002E LDCONST R6 K16 + 0xAC180200, // 002F CATCH R6 1 0 + 0xB0080000, // 0030 RAISE 2 R0 R0 + 0x60180012, // 0031 GETGBL R6 G18 + 0x7C180000, // 0032 CALL R6 0 + 0x90022206, // 0033 SETMBR R0 K17 R6 + 0x8C180112, // 0034 GETMET R6 R0 K18 + 0x7C180200, // 0035 CALL R6 1 + 0xB81A2600, // 0036 GETNGBL R6 K19 + 0x8C180D14, // 0037 GETMET R6 R6 K20 + 0xB8221400, // 0038 GETNGBL R8 K10 + 0x8C201116, // 0039 GETMET R8 R8 K22 + 0x5C280000, // 003A MOVE R10 R0 + 0x7C200400, // 003B CALL R8 2 + 0x00222A08, // 003C ADD R8 K21 R8 + 0x58240017, // 003D LDCONST R9 K23 + 0x7C180600, // 003E CALL R6 3 + 0x80000000, // 003F RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: attribute_updated +********************************************************************/ +be_local_closure(Matter_IM_Subscription_attribute_updated, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 8]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(path_list), + /* K2 */ be_nested_str_weak(endpoint), + /* K3 */ be_nested_str_weak(cluster), + /* K4 */ be_nested_str_weak(attribute), + /* K5 */ be_nested_str_weak(updates), + /* K6 */ be_nested_str_weak(push), + /* K7 */ be_const_int(1), + }), + be_str_weak(attribute_updated), + &be_const_str_solidified, + ( &(const binstruction[39]) { /* code */ + 0x580C0000, // 0000 LDCONST R3 K0 + 0x6010000C, // 0001 GETGBL R4 G12 + 0x88140101, // 0002 GETMBR R5 R0 K1 + 0x7C100200, // 0003 CALL R4 1 + 0x14100604, // 0004 LT R4 R3 R4 + 0x7812001F, // 0005 JMPF R4 #0026 + 0x88100101, // 0006 GETMBR R4 R0 K1 + 0x94100803, // 0007 GETIDX R4 R4 R3 + 0x88140902, // 0008 GETMBR R5 R4 K2 + 0x4C180000, // 0009 LDNIL R6 + 0x1C140A06, // 000A EQ R5 R5 R6 + 0x74160003, // 000B JMPT R5 #0010 + 0x88140902, // 000C GETMBR R5 R4 K2 + 0x88180302, // 000D GETMBR R6 R1 K2 + 0x1C140A06, // 000E EQ R5 R5 R6 + 0x78160013, // 000F JMPF R5 #0024 + 0x88140903, // 0010 GETMBR R5 R4 K3 + 0x4C180000, // 0011 LDNIL R6 + 0x1C140A06, // 0012 EQ R5 R5 R6 + 0x74160003, // 0013 JMPT R5 #0018 + 0x88140903, // 0014 GETMBR R5 R4 K3 + 0x88180303, // 0015 GETMBR R6 R1 K3 + 0x1C140A06, // 0016 EQ R5 R5 R6 + 0x7816000B, // 0017 JMPF R5 #0024 + 0x88140904, // 0018 GETMBR R5 R4 K4 + 0x4C180000, // 0019 LDNIL R6 + 0x1C140A06, // 001A EQ R5 R5 R6 + 0x74160003, // 001B JMPT R5 #0020 + 0x88140904, // 001C GETMBR R5 R4 K4 + 0x88180304, // 001D GETMBR R6 R1 K4 + 0x1C140A06, // 001E EQ R5 R5 R6 + 0x78160003, // 001F JMPF R5 #0024 + 0x88140105, // 0020 GETMBR R5 R0 K5 + 0x8C140B06, // 0021 GETMET R5 R5 K6 + 0x5C1C0200, // 0022 MOVE R7 R1 + 0x7C140400, // 0023 CALL R5 2 + 0x000C0707, // 0024 ADD R3 R3 K7 + 0x7001FFDA, // 0025 JMP #0001 + 0x80000000, // 0026 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: clear_and_arm +********************************************************************/ +be_local_closure(Matter_IM_Subscription_clear_and_arm, /* name */ + be_nested_proto( + 4, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 7]) { /* constants */ + /* K0 */ be_nested_str_weak(updates), + /* K1 */ be_nested_str_weak(clear), + /* K2 */ be_nested_str_weak(expiration), + /* K3 */ be_nested_str_weak(tasmota), + /* K4 */ be_nested_str_weak(millis), + /* K5 */ be_nested_str_weak(max_interval), + /* K6 */ be_nested_str_weak(MAX_INTERVAL_MARGIN), + }), + be_str_weak(clear_and_arm), + &be_const_str_solidified, + ( &(const binstruction[14]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0xB8060600, // 0003 GETNGBL R1 K3 + 0x8C040304, // 0004 GETMET R1 R1 K4 + 0x7C040200, // 0005 CALL R1 1 + 0x88080105, // 0006 GETMBR R2 R0 K5 + 0x880C0106, // 0007 GETMBR R3 R0 K6 + 0x04080403, // 0008 SUB R2 R2 R3 + 0x540E03E7, // 0009 LDINT R3 1000 + 0x08080403, // 000A MUL R2 R2 R3 + 0x00040202, // 000B ADD R1 R1 R2 + 0x90020401, // 000C SETMBR R0 K2 R1 + 0x80000000, // 000D RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_Subscription +********************************************************************/ +be_local_class(Matter_IM_Subscription, + 8, + NULL, + be_nested_map(12, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(expiration, -1), be_const_var(6) }, + { be_const_key_weak(updates, 9), be_const_var(7) }, + { be_const_key_weak(fabric_filtered, -1), be_const_var(5) }, + { be_const_key_weak(max_interval, 10), be_const_var(4) }, + { be_const_key_weak(session, -1), be_const_var(1) }, + { be_const_key_weak(min_interval, -1), be_const_var(3) }, + { be_const_key_weak(MAX_INTERVAL_MARGIN, -1), be_const_int(10) }, + { be_const_key_weak(attribute_updated, 4), be_const_closure(Matter_IM_Subscription_attribute_updated_closure) }, + { be_const_key_weak(subscription_id, -1), be_const_var(0) }, + { be_const_key_weak(clear_and_arm, -1), be_const_closure(Matter_IM_Subscription_clear_and_arm_closure) }, + { be_const_key_weak(path_list, 11), be_const_var(2) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_IM_Subscription_init_closure) }, + })), + be_str_weak(Matter_IM_Subscription) +); +/*******************************************************************/ + +void be_load_Matter_IM_Subscription_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_Subscription); + be_setglobal(vm, "Matter_IM_Subscription"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_IM_Subscription_Shop; + +/******************************************************************** +** Solidified function: new_subscription +********************************************************************/ +be_local_closure(Matter_IM_Subscription_Shop_new_subscription, /* name */ + be_nested_proto( + 10, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[10]) { /* constants */ + /* K0 */ be_nested_str_weak(crypto), + /* K1 */ be_nested_str_weak(random), + /* K2 */ be_const_int(2), + /* K3 */ be_nested_str_weak(get), + /* K4 */ be_const_int(0), + /* K5 */ be_nested_str_weak(get_by_id), + /* K6 */ be_nested_str_weak(matter), + /* K7 */ be_nested_str_weak(IM_Subscription), + /* K8 */ be_nested_str_weak(subs), + /* K9 */ be_nested_str_weak(push), + }), + be_str_weak(new_subscription), + &be_const_str_solidified, + ( &(const binstruction[32]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0x8C100701, // 0001 GETMET R4 R3 K1 + 0x58180002, // 0002 LDCONST R6 K2 + 0x7C100400, // 0003 CALL R4 2 + 0x8C100903, // 0004 GETMET R4 R4 K3 + 0x58180004, // 0005 LDCONST R6 K4 + 0x581C0002, // 0006 LDCONST R7 K2 + 0x7C100600, // 0007 CALL R4 3 + 0x8C140105, // 0008 GETMET R5 R0 K5 + 0x5C1C0800, // 0009 MOVE R7 R4 + 0x7C140400, // 000A CALL R5 2 + 0x78160008, // 000B JMPF R5 #0015 + 0x8C140701, // 000C GETMET R5 R3 K1 + 0x581C0002, // 000D LDCONST R7 K2 + 0x7C140400, // 000E CALL R5 2 + 0x8C140B03, // 000F GETMET R5 R5 K3 + 0x581C0004, // 0010 LDCONST R7 K4 + 0x58200002, // 0011 LDCONST R8 K2 + 0x7C140600, // 0012 CALL R5 3 + 0x5C100A00, // 0013 MOVE R4 R5 + 0x7001FFF2, // 0014 JMP #0008 + 0xB8160C00, // 0015 GETNGBL R5 K6 + 0x8C140B07, // 0016 GETMET R5 R5 K7 + 0x5C1C0800, // 0017 MOVE R7 R4 + 0x5C200200, // 0018 MOVE R8 R1 + 0x5C240400, // 0019 MOVE R9 R2 + 0x7C140800, // 001A CALL R5 4 + 0x88180108, // 001B GETMBR R6 R0 K8 + 0x8C180D09, // 001C GETMET R6 R6 K9 + 0x5C200A00, // 001D MOVE R8 R5 + 0x7C180400, // 001E CALL R6 2 + 0x80040A00, // 001F RET 1 R5 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: every_second +********************************************************************/ +be_local_closure(Matter_IM_Subscription_Shop_every_second, /* name */ + be_nested_proto( + 6, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 9]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(subs), + /* K2 */ be_nested_str_weak(tasmota), + /* K3 */ be_nested_str_weak(time_reached), + /* K4 */ be_nested_str_weak(expiration), + /* K5 */ be_nested_str_weak(im), + /* K6 */ be_nested_str_weak(send_subscribe_update), + /* K7 */ be_nested_str_weak(clear_and_arm), + /* K8 */ be_const_int(1), + }), + be_str_weak(every_second), + &be_const_str_solidified, + ( &(const binstruction[22]) { /* code */ + 0x58040000, // 0000 LDCONST R1 K0 + 0x6008000C, // 0001 GETGBL R2 G12 + 0x880C0101, // 0002 GETMBR R3 R0 K1 + 0x7C080200, // 0003 CALL R2 1 + 0x14080202, // 0004 LT R2 R1 R2 + 0x780A000E, // 0005 JMPF R2 #0015 + 0x88080101, // 0006 GETMBR R2 R0 K1 + 0x94080401, // 0007 GETIDX R2 R2 R1 + 0xB80E0400, // 0008 GETNGBL R3 K2 + 0x8C0C0703, // 0009 GETMET R3 R3 K3 + 0x88140504, // 000A GETMBR R5 R2 K4 + 0x7C0C0400, // 000B CALL R3 2 + 0x780E0005, // 000C JMPF R3 #0013 + 0x880C0105, // 000D GETMBR R3 R0 K5 + 0x8C0C0706, // 000E GETMET R3 R3 K6 + 0x5C140400, // 000F MOVE R5 R2 + 0x7C0C0400, // 0010 CALL R3 2 + 0x8C0C0507, // 0011 GETMET R3 R2 K7 + 0x7C0C0200, // 0012 CALL R3 1 + 0x00040308, // 0013 ADD R1 R1 K8 + 0x7001FFEB, // 0014 JMP #0001 + 0x80000000, // 0015 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_IM_Subscription_Shop_init, /* name */ + be_nested_proto( + 3, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(im), + /* K1 */ be_nested_str_weak(subs), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[ 5]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x60080012, // 0001 GETGBL R2 G18 + 0x7C080000, // 0002 CALL R2 0 + 0x90020202, // 0003 SETMBR R0 K1 R2 + 0x80000000, // 0004 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: remove_by_session +********************************************************************/ +be_local_closure(Matter_IM_Subscription_Shop_remove_by_session, /* name */ + be_nested_proto( + 6, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(subs), + /* K2 */ be_nested_str_weak(session), + /* K3 */ be_nested_str_weak(remove), + /* K4 */ be_const_int(1), + }), + be_str_weak(remove_by_session), + &be_const_str_solidified, + ( &(const binstruction[19]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0x600C000C, // 0001 GETGBL R3 G12 + 0x88100101, // 0002 GETMBR R4 R0 K1 + 0x7C0C0200, // 0003 CALL R3 1 + 0x140C0403, // 0004 LT R3 R2 R3 + 0x780E000B, // 0005 JMPF R3 #0012 + 0x880C0101, // 0006 GETMBR R3 R0 K1 + 0x940C0602, // 0007 GETIDX R3 R3 R2 + 0x880C0702, // 0008 GETMBR R3 R3 K2 + 0x1C0C0601, // 0009 EQ R3 R3 R1 + 0x780E0004, // 000A JMPF R3 #0010 + 0x880C0101, // 000B GETMBR R3 R0 K1 + 0x8C0C0703, // 000C GETMET R3 R3 K3 + 0x5C140400, // 000D MOVE R5 R2 + 0x7C0C0400, // 000E CALL R3 2 + 0x70020000, // 000F JMP #0011 + 0x00080504, // 0010 ADD R2 R2 K4 + 0x7001FFEE, // 0011 JMP #0001 + 0x80000000, // 0012 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_by_id +********************************************************************/ +be_local_closure(Matter_IM_Subscription_Shop_get_by_id, /* name */ + be_nested_proto( + 5, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(subs), + /* K2 */ be_nested_str_weak(subscription_id), + /* K3 */ be_const_int(1), + }), + be_str_weak(get_by_id), + &be_const_str_solidified, + ( &(const binstruction[17]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0x600C000C, // 0001 GETGBL R3 G12 + 0x88100101, // 0002 GETMBR R4 R0 K1 + 0x7C0C0200, // 0003 CALL R3 1 + 0x140C0403, // 0004 LT R3 R2 R3 + 0x780E0009, // 0005 JMPF R3 #0010 + 0x880C0101, // 0006 GETMBR R3 R0 K1 + 0x940C0602, // 0007 GETIDX R3 R3 R2 + 0x880C0702, // 0008 GETMBR R3 R3 K2 + 0x1C0C0601, // 0009 EQ R3 R3 R1 + 0x780E0002, // 000A JMPF R3 #000E + 0x880C0101, // 000B GETMBR R3 R0 K1 + 0x940C0602, // 000C GETIDX R3 R3 R2 + 0x80040600, // 000D RET 1 R3 + 0x00080503, // 000E ADD R2 R2 K3 + 0x7001FFF0, // 000F JMP #0001 + 0x80000000, // 0010 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: attribute_updated +********************************************************************/ +be_local_closure(Matter_IM_Subscription_Shop_attribute_updated, /* name */ + be_nested_proto( + 8, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_const_int(0), + /* K1 */ be_nested_str_weak(subs), + /* K2 */ be_nested_str_weak(attribute_updated), + /* K3 */ be_const_int(1), + }), + be_str_weak(attribute_updated), + &be_const_str_solidified, + ( &(const binstruction[15]) { /* code */ + 0x580C0000, // 0000 LDCONST R3 K0 + 0x6010000C, // 0001 GETGBL R4 G12 + 0x88140101, // 0002 GETMBR R5 R0 K1 + 0x7C100200, // 0003 CALL R4 1 + 0x14100604, // 0004 LT R4 R3 R4 + 0x78120007, // 0005 JMPF R4 #000E + 0x88100101, // 0006 GETMBR R4 R0 K1 + 0x94100803, // 0007 GETIDX R4 R4 R3 + 0x8C100902, // 0008 GETMET R4 R4 K2 + 0x5C180200, // 0009 MOVE R6 R1 + 0x5C1C0400, // 000A MOVE R7 R2 + 0x7C100600, // 000B CALL R4 3 + 0x000C0703, // 000C ADD R3 R3 K3 + 0x7001FFF2, // 000D JMP #0001 + 0x80000000, // 000E RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_IM_Subscription_Shop +********************************************************************/ +be_local_class(Matter_IM_Subscription_Shop, + 2, + NULL, + be_nested_map(8, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(attribute_updated, -1), be_const_closure(Matter_IM_Subscription_Shop_attribute_updated_closure) }, + { be_const_key_weak(every_second, -1), be_const_closure(Matter_IM_Subscription_Shop_every_second_closure) }, + { be_const_key_weak(subs, -1), be_const_var(0) }, + { be_const_key_weak(init, 5), be_const_closure(Matter_IM_Subscription_Shop_init_closure) }, + { be_const_key_weak(remove_by_session, -1), be_const_closure(Matter_IM_Subscription_Shop_remove_by_session_closure) }, + { be_const_key_weak(im, 6), be_const_var(1) }, + { be_const_key_weak(get_by_id, -1), be_const_closure(Matter_IM_Subscription_Shop_get_by_id_closure) }, + { be_const_key_weak(new_subscription, 0), be_const_closure(Matter_IM_Subscription_Shop_new_subscription_closure) }, + })), + be_str_weak(Matter_IM_Subscription_Shop) +); +/*******************************************************************/ + +void be_load_Matter_IM_Subscription_Shop_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_IM_Subscription_Shop); + be_setglobal(vm, "Matter_IM_Subscription_Shop"); + be_pop(vm, 1); +} +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Message.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Message.h index 76f644b3a..d2b0f0b72 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Message.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Message.h @@ -6,6 +6,39 @@ extern const bclass be_class_Matter_Frame; +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_Frame_init, /* name */ + be_nested_proto( + 5, /* nstack */ + 5, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(message_handler), + /* K1 */ be_nested_str_weak(raw), + /* K2 */ be_nested_str_weak(remote_ip), + /* K3 */ be_nested_str_weak(remote_port), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[ 5]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x90020202, // 0001 SETMBR R0 K1 R2 + 0x90020403, // 0002 SETMBR R0 K2 R3 + 0x90020604, // 0003 SETMBR R0 K3 R4 + 0x80000000, // 0004 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: encrypt ********************************************************************/ @@ -19,7 +52,7 @@ be_local_closure(Matter_Frame_encrypt, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[30]) { /* constants */ + ( &(const bvalue[29]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(raw), /* K2 */ be_nested_str_weak(session), @@ -39,17 +72,16 @@ be_local_closure(Matter_Frame_encrypt, /* name */ /* K16 */ be_nested_str_weak(log), /* K17 */ be_nested_str_weak(MTR_X3A_X20cleartext_X3A_X20), /* K18 */ be_nested_str_weak(tohex), - /* K19 */ be_const_int(3), - /* K20 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), - /* K21 */ be_nested_str_weak(MTR_X3A_X20r2i_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K22 */ be_nested_str_weak(MTR_X3A_X20p_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K23 */ be_nested_str_weak(MTR_X3A_X20a_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K24 */ be_nested_str_weak(MTR_X3A_X20n_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K25 */ be_nested_str_weak(AES_CCM), - /* K26 */ be_nested_str_weak(encrypt), - /* K27 */ be_nested_str_weak(tag), - /* K28 */ be_nested_str_weak(MTR_X3A_X20ciphertext_X20_X20_X3D), - /* K29 */ be_nested_str_weak(MTR_X3A_X20tag_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K19 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), + /* K20 */ be_nested_str_weak(MTR_X3A_X20r2i_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K21 */ be_nested_str_weak(MTR_X3A_X20p_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K22 */ be_nested_str_weak(MTR_X3A_X20a_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K23 */ be_nested_str_weak(MTR_X3A_X20n_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K24 */ be_nested_str_weak(AES_CCM), + /* K25 */ be_nested_str_weak(encrypt), + /* K26 */ be_nested_str_weak(tag), + /* K27 */ be_nested_str_weak(MTR_X3A_X20ciphertext_X20_X20_X3D), + /* K28 */ be_nested_str_weak(MTR_X3A_X20tag_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), }), be_str_weak(encrypt), &be_const_str_solidified, @@ -94,42 +126,42 @@ be_local_closure(Matter_Frame_encrypt, /* name */ 0x8C281512, // 0025 GETMET R10 R10 K18 0x7C280200, // 0026 CALL R10 1 0x002A220A, // 0027 ADD R10 K17 R10 - 0x582C0013, // 0028 LDCONST R11 K19 + 0x542E0003, // 0028 LDINT R11 4 0x7C200600, // 0029 CALL R8 3 0xB8221E00, // 002A GETNGBL R8 K15 0x8C201110, // 002B GETMET R8 R8 K16 - 0x58280014, // 002C LDCONST R10 K20 - 0x582C0013, // 002D LDCONST R11 K19 + 0x58280013, // 002C LDCONST R10 K19 + 0x542E0003, // 002D LDINT R11 4 0x7C200600, // 002E CALL R8 3 0xB8221E00, // 002F GETNGBL R8 K15 0x8C201110, // 0030 GETMET R8 R8 K16 0x8C280912, // 0031 GETMET R10 R4 K18 0x7C280200, // 0032 CALL R10 1 - 0x002A2A0A, // 0033 ADD R10 K21 R10 - 0x582C0013, // 0034 LDCONST R11 K19 + 0x002A280A, // 0033 ADD R10 K20 R10 + 0x542E0003, // 0034 LDINT R11 4 0x7C200600, // 0035 CALL R8 3 0xB8221E00, // 0036 GETNGBL R8 K15 0x8C201110, // 0037 GETMET R8 R8 K16 0x8C280D12, // 0038 GETMET R10 R6 K18 0x7C280200, // 0039 CALL R10 1 - 0x002A2C0A, // 003A ADD R10 K22 R10 - 0x582C0013, // 003B LDCONST R11 K19 + 0x002A2A0A, // 003A ADD R10 K21 R10 + 0x542E0003, // 003B LDINT R11 4 0x7C200600, // 003C CALL R8 3 0xB8221E00, // 003D GETNGBL R8 K15 0x8C201110, // 003E GETMET R8 R8 K16 0x8C280B12, // 003F GETMET R10 R5 K18 0x7C280200, // 0040 CALL R10 1 - 0x002A2E0A, // 0041 ADD R10 K23 R10 - 0x582C0013, // 0042 LDCONST R11 K19 + 0x002A2C0A, // 0041 ADD R10 K22 R10 + 0x542E0003, // 0042 LDINT R11 4 0x7C200600, // 0043 CALL R8 3 0xB8221E00, // 0044 GETNGBL R8 K15 0x8C201110, // 0045 GETMET R8 R8 K16 0x8C280F12, // 0046 GETMET R10 R7 K18 0x7C280200, // 0047 CALL R10 1 - 0x002A300A, // 0048 ADD R10 K24 R10 - 0x582C0013, // 0049 LDCONST R11 K19 + 0x002A2E0A, // 0048 ADD R10 K23 R10 + 0x542E0003, // 0049 LDINT R11 4 0x7C200600, // 004A CALL R8 3 - 0x8C200319, // 004B GETMET R8 R1 K25 + 0x8C200318, // 004B GETMET R8 R1 K24 0x5C280800, // 004C MOVE R10 R4 0x5C2C0E00, // 004D MOVE R11 R7 0x5C300A00, // 004E MOVE R12 R5 @@ -138,34 +170,34 @@ be_local_closure(Matter_Frame_encrypt, /* name */ 0x7C340200, // 0051 CALL R13 1 0x543A000F, // 0052 LDINT R14 16 0x7C200C00, // 0053 CALL R8 6 - 0x8C24111A, // 0054 GETMET R9 R8 K26 + 0x8C241119, // 0054 GETMET R9 R8 K25 0x5C2C0C00, // 0055 MOVE R11 R6 0x7C240400, // 0056 CALL R9 2 - 0x8C28111B, // 0057 GETMET R10 R8 K27 + 0x8C28111A, // 0057 GETMET R10 R8 K26 0x7C280200, // 0058 CALL R10 1 0xB82E1E00, // 0059 GETNGBL R11 K15 0x8C2C1710, // 005A GETMET R11 R11 K16 - 0x58340014, // 005B LDCONST R13 K20 - 0x58380013, // 005C LDCONST R14 K19 + 0x58340013, // 005B LDCONST R13 K19 + 0x543A0003, // 005C LDINT R14 4 0x7C2C0600, // 005D CALL R11 3 0xB82E1E00, // 005E GETNGBL R11 K15 0x8C2C1710, // 005F GETMET R11 R11 K16 0x8C341312, // 0060 GETMET R13 R9 K18 0x7C340200, // 0061 CALL R13 1 - 0x0036380D, // 0062 ADD R13 K28 R13 - 0x58380013, // 0063 LDCONST R14 K19 + 0x0036360D, // 0062 ADD R13 K27 R13 + 0x543A0003, // 0063 LDINT R14 4 0x7C2C0600, // 0064 CALL R11 3 0xB82E1E00, // 0065 GETNGBL R11 K15 0x8C2C1710, // 0066 GETMET R11 R11 K16 0x8C341512, // 0067 GETMET R13 R10 K18 0x7C340200, // 0068 CALL R13 1 - 0x00363A0D, // 0069 ADD R13 K29 R13 - 0x58380013, // 006A LDCONST R14 K19 + 0x0036380D, // 0069 ADD R13 K28 R13 + 0x543A0003, // 006A LDINT R14 4 0x7C2C0600, // 006B CALL R11 3 0xB82E1E00, // 006C GETNGBL R11 K15 0x8C2C1710, // 006D GETMET R11 R11 K16 - 0x58340014, // 006E LDCONST R13 K20 - 0x58380013, // 006F LDCONST R14 K19 + 0x58340013, // 006E LDCONST R13 K19 + 0x543A0003, // 006F LDINT R14 4 0x7C2C0600, // 0070 CALL R11 3 0x882C0101, // 0071 GETMBR R11 R0 K1 0x8C2C170E, // 0072 GETMET R11 R11 K14 @@ -182,13 +214,168 @@ be_local_closure(Matter_Frame_encrypt, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: debug +********************************************************************/ +be_local_closure(Matter_Frame_debug, /* name */ + be_nested_proto( + 8, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 9]) { /* constants */ + /* K0 */ be_nested_str_weak(matter), + /* K1 */ be_nested_str_weak(Frame), + /* K2 */ be_nested_str_weak(message_handler), + /* K3 */ be_nested_str_weak(decode_header), + /* K4 */ be_nested_str_weak(decode_payload), + /* K5 */ be_nested_str_weak(tasmota), + /* K6 */ be_nested_str_weak(log), + /* K7 */ be_nested_str_weak(MTR_X3A_X20sending_X20decode_X3A_X20), + /* K8 */ be_nested_str_weak(inspect), + }), + be_str_weak(debug), + &be_const_str_solidified, + ( &(const binstruction[19]) { /* code */ + 0xB80A0000, // 0000 GETNGBL R2 K0 + 0x8C080501, // 0001 GETMET R2 R2 K1 + 0x88100102, // 0002 GETMBR R4 R0 K2 + 0x5C140200, // 0003 MOVE R5 R1 + 0x7C080600, // 0004 CALL R2 3 + 0x8C0C0503, // 0005 GETMET R3 R2 K3 + 0x7C0C0200, // 0006 CALL R3 1 + 0x8C0C0504, // 0007 GETMET R3 R2 K4 + 0x7C0C0200, // 0008 CALL R3 1 + 0xB80E0A00, // 0009 GETNGBL R3 K5 + 0x8C0C0706, // 000A GETMET R3 R3 K6 + 0xB8160000, // 000B GETNGBL R5 K0 + 0x8C140B08, // 000C GETMET R5 R5 K8 + 0x5C1C0400, // 000D MOVE R7 R2 + 0x7C140400, // 000E CALL R5 2 + 0x00160E05, // 000F ADD R5 K7 R5 + 0x541A0003, // 0010 LDINT R6 4 + 0x7C0C0600, // 0011 CALL R3 3 + 0x80000000, // 0012 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: build_standalone_ack +********************************************************************/ +be_local_closure(Matter_Frame_build_standalone_ack, /* name */ + be_nested_proto( + 11, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[30]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(message_handler), + /* K2 */ be_nested_str_weak(remote_ip), + /* K3 */ be_nested_str_weak(remote_port), + /* K4 */ be_nested_str_weak(flag_s), + /* K5 */ be_nested_str_weak(flag_dsiz), + /* K6 */ be_const_int(1), + /* K7 */ be_nested_str_weak(dest_node_id_8), + /* K8 */ be_nested_str_weak(source_node_id), + /* K9 */ be_const_int(0), + /* K10 */ be_nested_str_weak(session), + /* K11 */ be_nested_str_weak(message_counter), + /* K12 */ be_nested_str_weak(counter_snd), + /* K13 */ be_nested_str_weak(next), + /* K14 */ be_nested_str_weak(local_session_id), + /* K15 */ be_nested_str_weak(initiator_session_id), + /* K16 */ be_nested_str_weak(x_flag_i), + /* K17 */ be_nested_str_weak(opcode), + /* K18 */ be_nested_str_weak(exchange_id), + /* K19 */ be_nested_str_weak(protocol_id), + /* K20 */ be_nested_str_weak(x_flag_a), + /* K21 */ be_nested_str_weak(ack_message_counter), + /* K22 */ be_nested_str_weak(x_flag_r), + /* K23 */ be_nested_str_weak(tasmota), + /* K24 */ be_nested_str_weak(log), + /* K25 */ be_nested_str_weak(format), + /* K26 */ be_nested_str_weak(MTR_X3A_X20_X3CReplied_X20_X20_X20_X25s), + /* K27 */ be_nested_str_weak(matter), + /* K28 */ be_nested_str_weak(get_opcode_name), + /* K29 */ be_const_int(3), + }), + be_str_weak(build_standalone_ack), + &be_const_str_solidified, + ( &(const binstruction[49]) { /* code */ + 0xA4060000, // 0000 IMPORT R1 K0 + 0x60080006, // 0001 GETGBL R2 G6 + 0x5C0C0000, // 0002 MOVE R3 R0 + 0x7C080200, // 0003 CALL R2 1 + 0x880C0101, // 0004 GETMBR R3 R0 K1 + 0x7C080200, // 0005 CALL R2 1 + 0x880C0102, // 0006 GETMBR R3 R0 K2 + 0x900A0403, // 0007 SETMBR R2 K2 R3 + 0x880C0103, // 0008 GETMBR R3 R0 K3 + 0x900A0603, // 0009 SETMBR R2 K3 R3 + 0x880C0104, // 000A GETMBR R3 R0 K4 + 0x780E0003, // 000B JMPF R3 #0010 + 0x900A0B06, // 000C SETMBR R2 K5 K6 + 0x880C0108, // 000D GETMBR R3 R0 K8 + 0x900A0E03, // 000E SETMBR R2 K7 R3 + 0x70020000, // 000F JMP #0011 + 0x900A0B09, // 0010 SETMBR R2 K5 K9 + 0x880C010A, // 0011 GETMBR R3 R0 K10 + 0x900A1403, // 0012 SETMBR R2 K10 R3 + 0x880C010A, // 0013 GETMBR R3 R0 K10 + 0x880C070C, // 0014 GETMBR R3 R3 K12 + 0x8C0C070D, // 0015 GETMET R3 R3 K13 + 0x7C0C0200, // 0016 CALL R3 1 + 0x900A1603, // 0017 SETMBR R2 K11 R3 + 0x880C010A, // 0018 GETMBR R3 R0 K10 + 0x880C070F, // 0019 GETMBR R3 R3 K15 + 0x900A1C03, // 001A SETMBR R2 K14 R3 + 0x900A2109, // 001B SETMBR R2 K16 K9 + 0x540E000F, // 001C LDINT R3 16 + 0x900A2203, // 001D SETMBR R2 K17 R3 + 0x880C0112, // 001E GETMBR R3 R0 K18 + 0x900A2403, // 001F SETMBR R2 K18 R3 + 0x900A2709, // 0020 SETMBR R2 K19 K9 + 0x900A2906, // 0021 SETMBR R2 K20 K6 + 0x880C010B, // 0022 GETMBR R3 R0 K11 + 0x900A2A03, // 0023 SETMBR R2 K21 R3 + 0x900A2D06, // 0024 SETMBR R2 K22 K6 + 0xB80E2E00, // 0025 GETNGBL R3 K23 + 0x8C0C0718, // 0026 GETMET R3 R3 K24 + 0x8C140319, // 0027 GETMET R5 R1 K25 + 0x581C001A, // 0028 LDCONST R7 K26 + 0xB8223600, // 0029 GETNGBL R8 K27 + 0x8C20111C, // 002A GETMET R8 R8 K28 + 0x88280511, // 002B GETMBR R10 R2 K17 + 0x7C200400, // 002C CALL R8 2 + 0x7C140600, // 002D CALL R5 3 + 0x5818001D, // 002E LDCONST R6 K29 + 0x7C0C0600, // 002F CALL R3 3 + 0x80040400, // 0030 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: build_response ********************************************************************/ be_local_closure(Matter_Frame_build_response, /* name */ be_nested_proto( 12, /* nstack */ - 3, /* argc */ + 4, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -226,94 +413,98 @@ be_local_closure(Matter_Frame_build_response, /* name */ /* K27 */ be_nested_str_weak(0x_X2502X), /* K28 */ be_nested_str_weak(tasmota), /* K29 */ be_nested_str_weak(log), - /* K30 */ be_nested_str_weak(MTR_X3A_X20_X3CReplied_X20_X20_X20_X20_X20_X20_X20_X25s), + /* K30 */ be_nested_str_weak(MTR_X3A_X20_X3CReplied_X20_X20_X20_X25s), /* K31 */ be_const_int(2), }), be_str_weak(build_response), &be_const_str_solidified, - ( &(const binstruction[82]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0x60100006, // 0001 GETGBL R4 G6 - 0x5C140000, // 0002 MOVE R5 R0 - 0x7C100200, // 0003 CALL R4 1 - 0x88140101, // 0004 GETMBR R5 R0 K1 - 0x7C100200, // 0005 CALL R4 1 - 0x88140102, // 0006 GETMBR R5 R0 K2 - 0x90120405, // 0007 SETMBR R4 K2 R5 - 0x88140103, // 0008 GETMBR R5 R0 K3 - 0x90120605, // 0009 SETMBR R4 K3 R5 - 0x88140104, // 000A GETMBR R5 R0 K4 - 0x78160003, // 000B JMPF R5 #0010 - 0x90120B06, // 000C SETMBR R4 K5 K6 - 0x88140108, // 000D GETMBR R5 R0 K8 - 0x90120E05, // 000E SETMBR R4 K7 R5 - 0x70020000, // 000F JMP #0011 - 0x90120B09, // 0010 SETMBR R4 K5 K9 - 0x8814010A, // 0011 GETMBR R5 R0 K10 - 0x90121405, // 0012 SETMBR R4 K10 R5 - 0x8814010B, // 0013 GETMBR R5 R0 K11 - 0x20140B09, // 0014 NE R5 R5 K9 - 0x7816000E, // 0015 JMPF R5 #0025 - 0x8814010A, // 0016 GETMBR R5 R0 K10 - 0x7816000C, // 0017 JMPF R5 #0025 - 0x8814010A, // 0018 GETMBR R5 R0 K10 - 0x88140B0C, // 0019 GETMBR R5 R5 K12 - 0x20140B09, // 001A NE R5 R5 K9 - 0x78160008, // 001B JMPF R5 #0025 + ( &(const binstruction[86]) { /* code */ + 0xA4120000, // 0000 IMPORT R4 K0 + 0x4C140000, // 0001 LDNIL R5 + 0x1C140605, // 0002 EQ R5 R3 R5 + 0x78160005, // 0003 JMPF R5 #000A + 0x60140006, // 0004 GETGBL R5 G6 + 0x5C180000, // 0005 MOVE R6 R0 + 0x7C140200, // 0006 CALL R5 1 + 0x88180101, // 0007 GETMBR R6 R0 K1 + 0x7C140200, // 0008 CALL R5 1 + 0x5C0C0A00, // 0009 MOVE R3 R5 + 0x88140102, // 000A GETMBR R5 R0 K2 + 0x900E0405, // 000B SETMBR R3 K2 R5 + 0x88140103, // 000C GETMBR R5 R0 K3 + 0x900E0605, // 000D SETMBR R3 K3 R5 + 0x88140104, // 000E GETMBR R5 R0 K4 + 0x78160003, // 000F JMPF R5 #0014 + 0x900E0B06, // 0010 SETMBR R3 K5 K6 + 0x88140108, // 0011 GETMBR R5 R0 K8 + 0x900E0E05, // 0012 SETMBR R3 K7 R5 + 0x70020000, // 0013 JMP #0015 + 0x900E0B09, // 0014 SETMBR R3 K5 K9 + 0x8814010A, // 0015 GETMBR R5 R0 K10 + 0x900E1405, // 0016 SETMBR R3 K10 R5 + 0x8814010B, // 0017 GETMBR R5 R0 K11 + 0x20140B09, // 0018 NE R5 R5 K9 + 0x7816000E, // 0019 JMPF R5 #0029 + 0x8814010A, // 001A GETMBR R5 R0 K10 + 0x7816000C, // 001B JMPF R5 #0029 0x8814010A, // 001C GETMBR R5 R0 K10 - 0x88140B0E, // 001D GETMBR R5 R5 K14 - 0x8C140B0F, // 001E GETMET R5 R5 K15 - 0x7C140200, // 001F CALL R5 1 - 0x90121A05, // 0020 SETMBR R4 K13 R5 - 0x8814010A, // 0021 GETMBR R5 R0 K10 - 0x88140B0C, // 0022 GETMBR R5 R5 K12 - 0x90121605, // 0023 SETMBR R4 K11 R5 - 0x70020005, // 0024 JMP #002B + 0x88140B0C, // 001D GETMBR R5 R5 K12 + 0x20140B09, // 001E NE R5 R5 K9 + 0x78160008, // 001F JMPF R5 #0029 + 0x8814010A, // 0020 GETMBR R5 R0 K10 + 0x88140B0E, // 0021 GETMBR R5 R5 K14 + 0x8C140B0F, // 0022 GETMET R5 R5 K15 + 0x7C140200, // 0023 CALL R5 1 + 0x900E1A05, // 0024 SETMBR R3 K13 R5 0x8814010A, // 0025 GETMBR R5 R0 K10 - 0x88140B10, // 0026 GETMBR R5 R5 K16 - 0x8C140B0F, // 0027 GETMET R5 R5 K15 - 0x7C140200, // 0028 CALL R5 1 - 0x90121A05, // 0029 SETMBR R4 K13 R5 - 0x90121709, // 002A SETMBR R4 K11 K9 - 0x90122309, // 002B SETMBR R4 K17 K9 - 0x90122401, // 002C SETMBR R4 K18 R1 - 0x88140113, // 002D GETMBR R5 R0 K19 - 0x90122605, // 002E SETMBR R4 K19 R5 - 0x88140114, // 002F GETMBR R5 R0 K20 - 0x90122805, // 0030 SETMBR R4 K20 R5 - 0x88140115, // 0031 GETMBR R5 R0 K21 - 0x78160002, // 0032 JMPF R5 #0036 - 0x90122D06, // 0033 SETMBR R4 K22 K6 - 0x8814010D, // 0034 GETMBR R5 R0 K13 - 0x90122E05, // 0035 SETMBR R4 K23 R5 - 0x780A0001, // 0036 JMPF R2 #0039 - 0x58140006, // 0037 LDCONST R5 K6 - 0x70020000, // 0038 JMP #003A - 0x58140009, // 0039 LDCONST R5 K9 - 0x90122A05, // 003A SETMBR R4 K21 R5 - 0x8814090B, // 003B GETMBR R5 R4 K11 - 0x1C140B09, // 003C EQ R5 R5 K9 - 0x78160012, // 003D JMPF R5 #0051 - 0xB8163000, // 003E GETNGBL R5 K24 - 0x8C140B19, // 003F GETMET R5 R5 K25 - 0x881C0912, // 0040 GETMBR R7 R4 K18 - 0x7C140400, // 0041 CALL R5 2 - 0x5C180A00, // 0042 MOVE R6 R5 - 0x741A0004, // 0043 JMPT R6 #0049 - 0x8C18071A, // 0044 GETMET R6 R3 K26 - 0x5820001B, // 0045 LDCONST R8 K27 - 0x88240912, // 0046 GETMBR R9 R4 K18 - 0x7C180600, // 0047 CALL R6 3 - 0x5C140C00, // 0048 MOVE R5 R6 - 0xB81A3800, // 0049 GETNGBL R6 K28 - 0x8C180D1D, // 004A GETMET R6 R6 K29 - 0x8C20071A, // 004B GETMET R8 R3 K26 - 0x5828001E, // 004C LDCONST R10 K30 - 0x5C2C0A00, // 004D MOVE R11 R5 - 0x7C200600, // 004E CALL R8 3 - 0x5824001F, // 004F LDCONST R9 K31 - 0x7C180600, // 0050 CALL R6 3 - 0x80040800, // 0051 RET 1 R4 + 0x88140B0C, // 0026 GETMBR R5 R5 K12 + 0x900E1605, // 0027 SETMBR R3 K11 R5 + 0x70020005, // 0028 JMP #002F + 0x8814010A, // 0029 GETMBR R5 R0 K10 + 0x88140B10, // 002A GETMBR R5 R5 K16 + 0x8C140B0F, // 002B GETMET R5 R5 K15 + 0x7C140200, // 002C CALL R5 1 + 0x900E1A05, // 002D SETMBR R3 K13 R5 + 0x900E1709, // 002E SETMBR R3 K11 K9 + 0x900E2309, // 002F SETMBR R3 K17 K9 + 0x900E2401, // 0030 SETMBR R3 K18 R1 + 0x88140113, // 0031 GETMBR R5 R0 K19 + 0x900E2605, // 0032 SETMBR R3 K19 R5 + 0x88140114, // 0033 GETMBR R5 R0 K20 + 0x900E2805, // 0034 SETMBR R3 K20 R5 + 0x88140115, // 0035 GETMBR R5 R0 K21 + 0x78160002, // 0036 JMPF R5 #003A + 0x900E2D06, // 0037 SETMBR R3 K22 K6 + 0x8814010D, // 0038 GETMBR R5 R0 K13 + 0x900E2E05, // 0039 SETMBR R3 K23 R5 + 0x780A0001, // 003A JMPF R2 #003D + 0x58140006, // 003B LDCONST R5 K6 + 0x70020000, // 003C JMP #003E + 0x58140009, // 003D LDCONST R5 K9 + 0x900E2A05, // 003E SETMBR R3 K21 R5 + 0x8814070B, // 003F GETMBR R5 R3 K11 + 0x1C140B09, // 0040 EQ R5 R5 K9 + 0x78160012, // 0041 JMPF R5 #0055 + 0xB8163000, // 0042 GETNGBL R5 K24 + 0x8C140B19, // 0043 GETMET R5 R5 K25 + 0x881C0712, // 0044 GETMBR R7 R3 K18 + 0x7C140400, // 0045 CALL R5 2 + 0x5C180A00, // 0046 MOVE R6 R5 + 0x741A0004, // 0047 JMPT R6 #004D + 0x8C18091A, // 0048 GETMET R6 R4 K26 + 0x5820001B, // 0049 LDCONST R8 K27 + 0x88240712, // 004A GETMBR R9 R3 K18 + 0x7C180600, // 004B CALL R6 3 + 0x5C140C00, // 004C MOVE R5 R6 + 0xB81A3800, // 004D GETNGBL R6 K28 + 0x8C180D1D, // 004E GETMET R6 R6 K29 + 0x8C20091A, // 004F GETMET R8 R4 K26 + 0x5828001E, // 0050 LDCONST R10 K30 + 0x5C2C0A00, // 0051 MOVE R11 R5 + 0x7C200600, // 0052 CALL R8 3 + 0x5824001F, // 0053 LDCONST R9 K31 + 0x7C180600, // 0054 CALL R6 3 + 0x80040600, // 0055 RET 1 R3 }) ) ); @@ -321,32 +512,93 @@ be_local_closure(Matter_Frame_build_response, /* name */ /******************************************************************** -** Solidified function: init +** Solidified function: initiate_response ********************************************************************/ -be_local_closure(Matter_Frame_init, /* name */ +be_local_closure(Matter_Frame_initiate_response, /* name */ be_nested_proto( - 5, /* nstack */ + 10, /* nstack */ 5, /* argc */ - 2, /* varg */ + 4, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 4]) { /* constants */ - /* K0 */ be_nested_str_weak(message_handler), - /* K1 */ be_nested_str_weak(raw), - /* K2 */ be_nested_str_weak(remote_ip), - /* K3 */ be_nested_str_weak(remote_port), + ( &(const bvalue[24]) { /* constants */ + /* K0 */ be_const_class(be_class_Matter_Frame), + /* K1 */ be_nested_str_weak(string), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(Frame), + /* K4 */ be_nested_str_weak(remote_ip), + /* K5 */ be_nested_str_weak(__ip), + /* K6 */ be_nested_str_weak(remote_port), + /* K7 */ be_nested_str_weak(__port), + /* K8 */ be_nested_str_weak(flag_dsiz), + /* K9 */ be_const_int(0), + /* K10 */ be_nested_str_weak(session), + /* K11 */ be_nested_str_weak(initiator_session_id), + /* K12 */ be_nested_str_weak(message_counter), + /* K13 */ be_nested_str_weak(counter_snd), + /* K14 */ be_nested_str_weak(next), + /* K15 */ be_nested_str_weak(local_session_id), + /* K16 */ be_nested_str_weak(_counter_insecure_snd), + /* K17 */ be_nested_str_weak(x_flag_i), + /* K18 */ be_const_int(1), + /* K19 */ be_nested_str_weak(opcode), + /* K20 */ be_nested_str_weak(__exchange_id), + /* K21 */ be_nested_str_weak(exchange_id), + /* K22 */ be_nested_str_weak(protocol_id), + /* K23 */ be_nested_str_weak(x_flag_r), }), - be_str_weak(init), + be_str_weak(initiate_response), &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x90020202, // 0001 SETMBR R0 K1 R2 - 0x90020403, // 0002 SETMBR R0 K2 R3 - 0x90020604, // 0003 SETMBR R0 K3 R4 - 0x80000000, // 0004 RET 0 + ( &(const binstruction[46]) { /* code */ + 0x58140000, // 0000 LDCONST R5 K0 + 0xA41A0200, // 0001 IMPORT R6 K1 + 0x4C1C0000, // 0002 LDNIL R7 + 0x1C1C0807, // 0003 EQ R7 R4 R7 + 0x781E0004, // 0004 JMPF R7 #000A + 0xB81E0400, // 0005 GETNGBL R7 K2 + 0x8C1C0F03, // 0006 GETMET R7 R7 K3 + 0x5C240000, // 0007 MOVE R9 R0 + 0x7C1C0400, // 0008 CALL R7 2 + 0x5C100E00, // 0009 MOVE R4 R7 + 0x881C0305, // 000A GETMBR R7 R1 K5 + 0x90120807, // 000B SETMBR R4 K4 R7 + 0x881C0307, // 000C GETMBR R7 R1 K7 + 0x90120C07, // 000D SETMBR R4 K6 R7 + 0x90121109, // 000E SETMBR R4 K8 K9 + 0x90121401, // 000F SETMBR R4 K10 R1 + 0x78060009, // 0010 JMPF R1 #001B + 0x881C030B, // 0011 GETMBR R7 R1 K11 + 0x201C0F09, // 0012 NE R7 R7 K9 + 0x781E0006, // 0013 JMPF R7 #001B + 0x881C030D, // 0014 GETMBR R7 R1 K13 + 0x8C1C0F0E, // 0015 GETMET R7 R7 K14 + 0x7C1C0200, // 0016 CALL R7 1 + 0x90121807, // 0017 SETMBR R4 K12 R7 + 0x881C030B, // 0018 GETMBR R7 R1 K11 + 0x90121E07, // 0019 SETMBR R4 K15 R7 + 0x70020004, // 001A JMP #0020 + 0x881C0310, // 001B GETMBR R7 R1 K16 + 0x8C1C0F0E, // 001C GETMET R7 R7 K14 + 0x7C1C0200, // 001D CALL R7 1 + 0x90121807, // 001E SETMBR R4 K12 R7 + 0x90121F09, // 001F SETMBR R4 K15 K9 + 0x90122312, // 0020 SETMBR R4 K17 K18 + 0x90122602, // 0021 SETMBR R4 K19 R2 + 0x881C0314, // 0022 GETMBR R7 R1 K20 + 0x001C0F12, // 0023 ADD R7 R7 K18 + 0x90062807, // 0024 SETMBR R1 K20 R7 + 0x881C0314, // 0025 GETMBR R7 R1 K20 + 0x90122A07, // 0026 SETMBR R4 K21 R7 + 0x90122D12, // 0027 SETMBR R4 K22 K18 + 0x780E0001, // 0028 JMPF R3 #002B + 0x581C0012, // 0029 LDCONST R7 K18 + 0x70020000, // 002A JMP #002C + 0x581C0009, // 002B LDCONST R7 K9 + 0x90122E07, // 002C SETMBR R4 K23 R7 + 0x80040800, // 002D RET 1 R4 }) ) ); @@ -519,511 +771,6 @@ be_local_closure(Matter_Frame_decode_header, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: decode_payload -********************************************************************/ -be_local_closure(Matter_Frame_decode_payload, /* name */ - be_nested_proto( - 7, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[19]) { /* constants */ - /* K0 */ be_nested_str_weak(payload_idx), - /* K1 */ be_nested_str_weak(raw), - /* K2 */ be_nested_str_weak(x_flags), - /* K3 */ be_nested_str_weak(get), - /* K4 */ be_const_int(1), - /* K5 */ be_nested_str_weak(x_flag_v), - /* K6 */ be_nested_str_weak(getbits), - /* K7 */ be_nested_str_weak(x_flag_sx), - /* K8 */ be_const_int(3), - /* K9 */ be_nested_str_weak(x_flag_r), - /* K10 */ be_const_int(2), - /* K11 */ be_nested_str_weak(x_flag_a), - /* K12 */ be_nested_str_weak(x_flag_i), - /* K13 */ be_nested_str_weak(opcode), - /* K14 */ be_nested_str_weak(exchange_id), - /* K15 */ be_nested_str_weak(protocol_id), - /* K16 */ be_nested_str_weak(vendor_id), - /* K17 */ be_nested_str_weak(ack_message_counter), - /* K18 */ be_nested_str_weak(app_payload_idx), - }), - be_str_weak(decode_payload), - &be_const_str_solidified, - ( &(const binstruction[87]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88080101, // 0001 GETMBR R2 R0 K1 - 0x8C0C0503, // 0002 GETMET R3 R2 K3 - 0x5C140200, // 0003 MOVE R5 R1 - 0x58180004, // 0004 LDCONST R6 K4 - 0x7C0C0600, // 0005 CALL R3 3 - 0x90020403, // 0006 SETMBR R0 K2 R3 - 0x8C0C0506, // 0007 GETMET R3 R2 K6 - 0x54160007, // 0008 LDINT R5 8 - 0x08140205, // 0009 MUL R5 R1 R5 - 0x541A0003, // 000A LDINT R6 4 - 0x00140A06, // 000B ADD R5 R5 R6 - 0x58180004, // 000C LDCONST R6 K4 - 0x7C0C0600, // 000D CALL R3 3 - 0x90020A03, // 000E SETMBR R0 K5 R3 - 0x8C0C0506, // 000F GETMET R3 R2 K6 - 0x54160007, // 0010 LDINT R5 8 - 0x08140205, // 0011 MUL R5 R1 R5 - 0x00140B08, // 0012 ADD R5 R5 K8 - 0x58180004, // 0013 LDCONST R6 K4 - 0x7C0C0600, // 0014 CALL R3 3 - 0x90020E03, // 0015 SETMBR R0 K7 R3 - 0x8C0C0506, // 0016 GETMET R3 R2 K6 - 0x54160007, // 0017 LDINT R5 8 - 0x08140205, // 0018 MUL R5 R1 R5 - 0x00140B0A, // 0019 ADD R5 R5 K10 - 0x58180004, // 001A LDCONST R6 K4 - 0x7C0C0600, // 001B CALL R3 3 - 0x90021203, // 001C SETMBR R0 K9 R3 - 0x8C0C0506, // 001D GETMET R3 R2 K6 - 0x54160007, // 001E LDINT R5 8 - 0x08140205, // 001F MUL R5 R1 R5 - 0x00140B04, // 0020 ADD R5 R5 K4 - 0x58180004, // 0021 LDCONST R6 K4 - 0x7C0C0600, // 0022 CALL R3 3 - 0x90021603, // 0023 SETMBR R0 K11 R3 - 0x8C0C0506, // 0024 GETMET R3 R2 K6 - 0x54160007, // 0025 LDINT R5 8 - 0x08140205, // 0026 MUL R5 R1 R5 - 0x58180004, // 0027 LDCONST R6 K4 - 0x7C0C0600, // 0028 CALL R3 3 - 0x90021803, // 0029 SETMBR R0 K12 R3 - 0x8C0C0503, // 002A GETMET R3 R2 K3 - 0x00140304, // 002B ADD R5 R1 K4 - 0x58180004, // 002C LDCONST R6 K4 - 0x7C0C0600, // 002D CALL R3 3 - 0x90021A03, // 002E SETMBR R0 K13 R3 - 0x8C0C0503, // 002F GETMET R3 R2 K3 - 0x0014030A, // 0030 ADD R5 R1 K10 - 0x5818000A, // 0031 LDCONST R6 K10 - 0x7C0C0600, // 0032 CALL R3 3 - 0x90021C03, // 0033 SETMBR R0 K14 R3 - 0x8C0C0503, // 0034 GETMET R3 R2 K3 - 0x54160003, // 0035 LDINT R5 4 - 0x00140205, // 0036 ADD R5 R1 R5 - 0x5818000A, // 0037 LDCONST R6 K10 - 0x7C0C0600, // 0038 CALL R3 3 - 0x90021E03, // 0039 SETMBR R0 K15 R3 - 0x540E0005, // 003A LDINT R3 6 - 0x00040203, // 003B ADD R1 R1 R3 - 0x880C0105, // 003C GETMBR R3 R0 K5 - 0x780E0005, // 003D JMPF R3 #0044 - 0x8C0C0503, // 003E GETMET R3 R2 K3 - 0x5C140200, // 003F MOVE R5 R1 - 0x5818000A, // 0040 LDCONST R6 K10 - 0x7C0C0600, // 0041 CALL R3 3 - 0x90022003, // 0042 SETMBR R0 K16 R3 - 0x0004030A, // 0043 ADD R1 R1 K10 - 0x880C010B, // 0044 GETMBR R3 R0 K11 - 0x780E0006, // 0045 JMPF R3 #004D - 0x8C0C0503, // 0046 GETMET R3 R2 K3 - 0x5C140200, // 0047 MOVE R5 R1 - 0x541A0003, // 0048 LDINT R6 4 - 0x7C0C0600, // 0049 CALL R3 3 - 0x90022203, // 004A SETMBR R0 K17 R3 - 0x540E0003, // 004B LDINT R3 4 - 0x00040203, // 004C ADD R1 R1 R3 - 0x880C0107, // 004D GETMBR R3 R0 K7 - 0x780E0005, // 004E JMPF R3 #0055 - 0x8C0C0503, // 004F GETMET R3 R2 K3 - 0x5C140200, // 0050 MOVE R5 R1 - 0x5818000A, // 0051 LDCONST R6 K10 - 0x7C0C0600, // 0052 CALL R3 3 - 0x0010070A, // 0053 ADD R4 R3 K10 - 0x00040204, // 0054 ADD R1 R1 R4 - 0x90022401, // 0055 SETMBR R0 K18 R1 - 0x80040000, // 0056 RET 1 R0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: debug -********************************************************************/ -be_local_closure(Matter_Frame_debug, /* name */ - be_nested_proto( - 8, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[10]) { /* constants */ - /* K0 */ be_nested_str_weak(matter), - /* K1 */ be_nested_str_weak(Frame), - /* K2 */ be_nested_str_weak(message_handler), - /* K3 */ be_nested_str_weak(decode_header), - /* K4 */ be_nested_str_weak(decode_payload), - /* K5 */ be_nested_str_weak(tasmota), - /* K6 */ be_nested_str_weak(log), - /* K7 */ be_nested_str_weak(MTR_X3A_X20sending_X20decode_X3A_X20), - /* K8 */ be_nested_str_weak(inspect), - /* K9 */ be_const_int(3), - }), - be_str_weak(debug), - &be_const_str_solidified, - ( &(const binstruction[19]) { /* code */ - 0xB80A0000, // 0000 GETNGBL R2 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x88100102, // 0002 GETMBR R4 R0 K2 - 0x5C140200, // 0003 MOVE R5 R1 - 0x7C080600, // 0004 CALL R2 3 - 0x8C0C0503, // 0005 GETMET R3 R2 K3 - 0x7C0C0200, // 0006 CALL R3 1 - 0x8C0C0504, // 0007 GETMET R3 R2 K4 - 0x7C0C0200, // 0008 CALL R3 1 - 0xB80E0A00, // 0009 GETNGBL R3 K5 - 0x8C0C0706, // 000A GETMET R3 R3 K6 - 0xB8160000, // 000B GETNGBL R5 K0 - 0x8C140B08, // 000C GETMET R5 R5 K8 - 0x5C1C0400, // 000D MOVE R7 R2 - 0x7C140400, // 000E CALL R5 2 - 0x00160E05, // 000F ADD R5 K7 R5 - 0x58180009, // 0010 LDCONST R6 K9 - 0x7C0C0600, // 0011 CALL R3 3 - 0x80000000, // 0012 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: build_standalone_ack -********************************************************************/ -be_local_closure(Matter_Frame_build_standalone_ack, /* name */ - be_nested_proto( - 11, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[28]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(message_handler), - /* K2 */ be_nested_str_weak(flag_s), - /* K3 */ be_nested_str_weak(flag_dsiz), - /* K4 */ be_const_int(1), - /* K5 */ be_nested_str_weak(dest_node_id_8), - /* K6 */ be_nested_str_weak(source_node_id), - /* K7 */ be_const_int(0), - /* K8 */ be_nested_str_weak(session), - /* K9 */ be_nested_str_weak(message_counter), - /* K10 */ be_nested_str_weak(counter_snd), - /* K11 */ be_nested_str_weak(next), - /* K12 */ be_nested_str_weak(local_session_id), - /* K13 */ be_nested_str_weak(initiator_session_id), - /* K14 */ be_nested_str_weak(x_flag_i), - /* K15 */ be_nested_str_weak(opcode), - /* K16 */ be_nested_str_weak(exchange_id), - /* K17 */ be_nested_str_weak(protocol_id), - /* K18 */ be_nested_str_weak(x_flag_a), - /* K19 */ be_nested_str_weak(ack_message_counter), - /* K20 */ be_nested_str_weak(x_flag_r), - /* K21 */ be_nested_str_weak(tasmota), - /* K22 */ be_nested_str_weak(log), - /* K23 */ be_nested_str_weak(format), - /* K24 */ be_nested_str_weak(MTR_X3A_X20_X3CReplied_X20_X20_X20_X20_X20_X20_X20_X25s), - /* K25 */ be_nested_str_weak(matter), - /* K26 */ be_nested_str_weak(get_opcode_name), - /* K27 */ be_const_int(2), - }), - be_str_weak(build_standalone_ack), - &be_const_str_solidified, - ( &(const binstruction[45]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x60080006, // 0001 GETGBL R2 G6 - 0x5C0C0000, // 0002 MOVE R3 R0 - 0x7C080200, // 0003 CALL R2 1 - 0x880C0101, // 0004 GETMBR R3 R0 K1 - 0x7C080200, // 0005 CALL R2 1 - 0x880C0102, // 0006 GETMBR R3 R0 K2 - 0x780E0003, // 0007 JMPF R3 #000C - 0x900A0704, // 0008 SETMBR R2 K3 K4 - 0x880C0106, // 0009 GETMBR R3 R0 K6 - 0x900A0A03, // 000A SETMBR R2 K5 R3 - 0x70020000, // 000B JMP #000D - 0x900A0707, // 000C SETMBR R2 K3 K7 - 0x880C0108, // 000D GETMBR R3 R0 K8 - 0x900A1003, // 000E SETMBR R2 K8 R3 - 0x880C0108, // 000F GETMBR R3 R0 K8 - 0x880C070A, // 0010 GETMBR R3 R3 K10 - 0x8C0C070B, // 0011 GETMET R3 R3 K11 - 0x7C0C0200, // 0012 CALL R3 1 - 0x900A1203, // 0013 SETMBR R2 K9 R3 - 0x880C0108, // 0014 GETMBR R3 R0 K8 - 0x880C070D, // 0015 GETMBR R3 R3 K13 - 0x900A1803, // 0016 SETMBR R2 K12 R3 - 0x900A1D07, // 0017 SETMBR R2 K14 K7 - 0x540E000F, // 0018 LDINT R3 16 - 0x900A1E03, // 0019 SETMBR R2 K15 R3 - 0x880C0110, // 001A GETMBR R3 R0 K16 - 0x900A2003, // 001B SETMBR R2 K16 R3 - 0x900A2307, // 001C SETMBR R2 K17 K7 - 0x900A2504, // 001D SETMBR R2 K18 K4 - 0x880C0109, // 001E GETMBR R3 R0 K9 - 0x900A2603, // 001F SETMBR R2 K19 R3 - 0x900A2907, // 0020 SETMBR R2 K20 K7 - 0xB80E2A00, // 0021 GETNGBL R3 K21 - 0x8C0C0716, // 0022 GETMET R3 R3 K22 - 0x8C140317, // 0023 GETMET R5 R1 K23 - 0x581C0018, // 0024 LDCONST R7 K24 - 0xB8223200, // 0025 GETNGBL R8 K25 - 0x8C20111A, // 0026 GETMET R8 R8 K26 - 0x8828050F, // 0027 GETMBR R10 R2 K15 - 0x7C200400, // 0028 CALL R8 2 - 0x7C140600, // 0029 CALL R5 3 - 0x5818001B, // 002A LDCONST R6 K27 - 0x7C0C0600, // 002B CALL R3 3 - 0x80040400, // 002C RET 1 R2 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: decrypt -********************************************************************/ -be_local_closure(Matter_Frame_decrypt, /* name */ - be_nested_proto( - 16, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[36]) { /* constants */ - /* K0 */ be_nested_str_weak(crypto), - /* K1 */ be_nested_str_weak(session), - /* K2 */ be_nested_str_weak(raw), - /* K3 */ be_const_int(2147483647), - /* K4 */ be_nested_str_weak(get_i2r), - /* K5 */ be_nested_str_weak(sec_p), - /* K6 */ be_nested_str_weak(get_i2r_privacy), - /* K7 */ be_nested_str_weak(add), - /* K8 */ be_nested_str_weak(local_session_id), - /* K9 */ be_nested_str_weak(payload_idx), - /* K10 */ be_const_int(1), - /* K11 */ be_nested_str_weak(AES_CTR), - /* K12 */ be_nested_str_weak(decrypt), - /* K13 */ be_const_int(2), - /* K14 */ be_const_int(0), - /* K15 */ be_const_int(3), - /* K16 */ be_nested_str_weak(self), - /* K17 */ be_nested_str_weak(flags), - /* K18 */ be_nested_str_weak(message_counter), - /* K19 */ be_nested_str_weak(source_node_id), - /* K20 */ be_nested_str_weak(peer_node_id), - /* K21 */ be_nested_str_weak(resize), - /* K22 */ be_nested_str_weak(tasmota), - /* K23 */ be_nested_str_weak(log), - /* K24 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), - /* K25 */ be_nested_str_weak(MTR_X3A_X20i2r_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K26 */ be_nested_str_weak(tohex), - /* K27 */ be_nested_str_weak(MTR_X3A_X20p_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K28 */ be_nested_str_weak(MTR_X3A_X20a_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K29 */ be_nested_str_weak(MTR_X3A_X20n_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K30 */ be_nested_str_weak(MTR_X3A_X20mic_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K31 */ be_nested_str_weak(AES_CCM), - /* K32 */ be_nested_str_weak(tag), - /* K33 */ be_nested_str_weak(MTR_X3A_X20cleartext_X20_X20_X20_X3D), - /* K34 */ be_nested_str_weak(MTR_X3A_X20tag_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), - /* K35 */ be_nested_str_weak(MTR_X3A_X20rejected_X20packet_X20due_X20to_X20invalid_X20MIC), - }), - be_str_weak(decrypt), - &be_const_str_solidified, - ( &(const binstruction[165]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x88080101, // 0001 GETMBR R2 R0 K1 - 0x880C0102, // 0002 GETMBR R3 R0 K2 - 0x5411FFEF, // 0003 LDINT R4 -16 - 0x40100903, // 0004 CONNECT R4 R4 K3 - 0x94100604, // 0005 GETIDX R4 R3 R4 - 0x8C140504, // 0006 GETMET R5 R2 K4 - 0x7C140200, // 0007 CALL R5 1 - 0x88180105, // 0008 GETMBR R6 R0 K5 - 0x781A0025, // 0009 JMPF R6 #0030 - 0x8C180506, // 000A GETMET R6 R2 K6 - 0x7C180200, // 000B CALL R6 1 - 0x601C0015, // 000C GETGBL R7 G21 - 0x7C1C0000, // 000D CALL R7 0 - 0x8C1C0F07, // 000E GETMET R7 R7 K7 - 0x88240108, // 000F GETMBR R9 R0 K8 - 0x5429FFFD, // 0010 LDINT R10 -2 - 0x7C1C0600, // 0011 CALL R7 3 - 0x54220004, // 0012 LDINT R8 5 - 0x5426000E, // 0013 LDINT R9 15 - 0x40201009, // 0014 CONNECT R8 R8 R9 - 0x94200808, // 0015 GETIDX R8 R4 R8 - 0x001C0E08, // 0016 ADD R7 R7 R8 - 0x54220003, // 0017 LDINT R8 4 - 0x88240109, // 0018 GETMBR R9 R0 K9 - 0x0424130A, // 0019 SUB R9 R9 K10 - 0x40201009, // 001A CONNECT R8 R8 R9 - 0x88240102, // 001B GETMBR R9 R0 K2 - 0x94201208, // 001C GETIDX R8 R9 R8 - 0x8C28030B, // 001D GETMET R10 R1 K11 - 0x5C300C00, // 001E MOVE R12 R6 - 0x7C280400, // 001F CALL R10 2 - 0x8C28150C, // 0020 GETMET R10 R10 K12 - 0x5C301000, // 0021 MOVE R12 R8 - 0x5C340E00, // 0022 MOVE R13 R7 - 0x5838000D, // 0023 LDCONST R14 K13 - 0x7C280800, // 0024 CALL R10 4 - 0x5C241400, // 0025 MOVE R9 R10 - 0x402A1D0F, // 0026 CONNECT R10 K14 K15 - 0x882C0102, // 0027 GETMBR R11 R0 K2 - 0x9428160A, // 0028 GETIDX R10 R11 R10 - 0x00281409, // 0029 ADD R10 R10 R9 - 0x882C0110, // 002A GETMBR R11 R0 K16 - 0x882C1709, // 002B GETMBR R11 R11 K9 - 0x402C1703, // 002C CONNECT R11 R11 K3 - 0x942C100B, // 002D GETIDX R11 R8 R11 - 0x0028140B, // 002E ADD R10 R10 R11 - 0x9002040A, // 002F SETMBR R0 K2 R10 - 0x88180109, // 0030 GETMBR R6 R0 K9 - 0x04180D0A, // 0031 SUB R6 R6 K10 - 0x401A1C06, // 0032 CONNECT R6 K14 R6 - 0x94180606, // 0033 GETIDX R6 R3 R6 - 0x881C0109, // 0034 GETMBR R7 R0 K9 - 0x5421FFEE, // 0035 LDINT R8 -17 - 0x401C0E08, // 0036 CONNECT R7 R7 R8 - 0x941C0607, // 0037 GETIDX R7 R3 R7 - 0x60200015, // 0038 GETGBL R8 G21 - 0x7C200000, // 0039 CALL R8 0 - 0x8C241107, // 003A GETMET R9 R8 K7 - 0x882C0111, // 003B GETMBR R11 R0 K17 - 0x5830000A, // 003C LDCONST R12 K10 - 0x7C240600, // 003D CALL R9 3 - 0x8C241107, // 003E GETMET R9 R8 K7 - 0x882C0112, // 003F GETMBR R11 R0 K18 - 0x54320003, // 0040 LDINT R12 4 - 0x7C240600, // 0041 CALL R9 3 - 0x88240113, // 0042 GETMBR R9 R0 K19 - 0x78260001, // 0043 JMPF R9 #0046 - 0x40241103, // 0044 CONNECT R9 R8 K3 - 0x70020006, // 0045 JMP #004D - 0x88240514, // 0046 GETMBR R9 R2 K20 - 0x78260001, // 0047 JMPF R9 #004A - 0x88240514, // 0048 GETMBR R9 R2 K20 - 0x40241009, // 0049 CONNECT R9 R8 R9 - 0x8C241115, // 004A GETMET R9 R8 K21 - 0x542E000C, // 004B LDINT R11 13 - 0x7C240400, // 004C CALL R9 2 - 0xB8262C00, // 004D GETNGBL R9 K22 - 0x8C241317, // 004E GETMET R9 R9 K23 - 0x582C0018, // 004F LDCONST R11 K24 - 0x5830000F, // 0050 LDCONST R12 K15 - 0x7C240600, // 0051 CALL R9 3 - 0xB8262C00, // 0052 GETNGBL R9 K22 - 0x8C241317, // 0053 GETMET R9 R9 K23 - 0x8C2C0B1A, // 0054 GETMET R11 R5 K26 - 0x7C2C0200, // 0055 CALL R11 1 - 0x002E320B, // 0056 ADD R11 K25 R11 - 0x5830000F, // 0057 LDCONST R12 K15 - 0x7C240600, // 0058 CALL R9 3 - 0xB8262C00, // 0059 GETNGBL R9 K22 - 0x8C241317, // 005A GETMET R9 R9 K23 - 0x8C2C0F1A, // 005B GETMET R11 R7 K26 - 0x7C2C0200, // 005C CALL R11 1 - 0x002E360B, // 005D ADD R11 K27 R11 - 0x5830000F, // 005E LDCONST R12 K15 - 0x7C240600, // 005F CALL R9 3 - 0xB8262C00, // 0060 GETNGBL R9 K22 - 0x8C241317, // 0061 GETMET R9 R9 K23 - 0x8C2C0D1A, // 0062 GETMET R11 R6 K26 - 0x7C2C0200, // 0063 CALL R11 1 - 0x002E380B, // 0064 ADD R11 K28 R11 - 0x5830000F, // 0065 LDCONST R12 K15 - 0x7C240600, // 0066 CALL R9 3 - 0xB8262C00, // 0067 GETNGBL R9 K22 - 0x8C241317, // 0068 GETMET R9 R9 K23 - 0x8C2C111A, // 0069 GETMET R11 R8 K26 - 0x7C2C0200, // 006A CALL R11 1 - 0x002E3A0B, // 006B ADD R11 K29 R11 - 0x5830000F, // 006C LDCONST R12 K15 - 0x7C240600, // 006D CALL R9 3 - 0xB8262C00, // 006E GETNGBL R9 K22 - 0x8C241317, // 006F GETMET R9 R9 K23 - 0x8C2C091A, // 0070 GETMET R11 R4 K26 - 0x7C2C0200, // 0071 CALL R11 1 - 0x002E3C0B, // 0072 ADD R11 K30 R11 - 0x5830000F, // 0073 LDCONST R12 K15 - 0x7C240600, // 0074 CALL R9 3 - 0x8C24031F, // 0075 GETMET R9 R1 K31 - 0x5C2C0A00, // 0076 MOVE R11 R5 - 0x5C301000, // 0077 MOVE R12 R8 - 0x5C340C00, // 0078 MOVE R13 R6 - 0x6038000C, // 0079 GETGBL R14 G12 - 0x5C3C0E00, // 007A MOVE R15 R7 - 0x7C380200, // 007B CALL R14 1 - 0x543E000F, // 007C LDINT R15 16 - 0x7C240C00, // 007D CALL R9 6 - 0x8C28130C, // 007E GETMET R10 R9 K12 - 0x5C300E00, // 007F MOVE R12 R7 - 0x7C280400, // 0080 CALL R10 2 - 0x8C2C1320, // 0081 GETMET R11 R9 K32 - 0x7C2C0200, // 0082 CALL R11 1 - 0xB8322C00, // 0083 GETNGBL R12 K22 - 0x8C301917, // 0084 GETMET R12 R12 K23 - 0x58380018, // 0085 LDCONST R14 K24 - 0x583C000F, // 0086 LDCONST R15 K15 - 0x7C300600, // 0087 CALL R12 3 - 0xB8322C00, // 0088 GETNGBL R12 K22 - 0x8C301917, // 0089 GETMET R12 R12 K23 - 0x8C38151A, // 008A GETMET R14 R10 K26 - 0x7C380200, // 008B CALL R14 1 - 0x003A420E, // 008C ADD R14 K33 R14 - 0x583C000F, // 008D LDCONST R15 K15 - 0x7C300600, // 008E CALL R12 3 - 0xB8322C00, // 008F GETNGBL R12 K22 - 0x8C301917, // 0090 GETMET R12 R12 K23 - 0x8C38171A, // 0091 GETMET R14 R11 K26 - 0x7C380200, // 0092 CALL R14 1 - 0x003A440E, // 0093 ADD R14 K34 R14 - 0x583C000F, // 0094 LDCONST R15 K15 - 0x7C300600, // 0095 CALL R12 3 - 0xB8322C00, // 0096 GETNGBL R12 K22 - 0x8C301917, // 0097 GETMET R12 R12 K23 - 0x58380018, // 0098 LDCONST R14 K24 - 0x583C000F, // 0099 LDCONST R15 K15 - 0x7C300600, // 009A CALL R12 3 - 0x20301604, // 009B NE R12 R11 R4 - 0x78320006, // 009C JMPF R12 #00A4 - 0xB8322C00, // 009D GETNGBL R12 K22 - 0x8C301917, // 009E GETMET R12 R12 K23 - 0x58380023, // 009F LDCONST R14 K35 - 0x583C000F, // 00A0 LDCONST R15 K15 - 0x7C300600, // 00A1 CALL R12 3 - 0x4C300000, // 00A2 LDNIL R12 - 0x80041800, // 00A3 RET 1 R12 - 0x80041400, // 00A4 RET 1 R10 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: encode ********************************************************************/ @@ -1222,55 +969,411 @@ be_local_closure(Matter_Frame_encode, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: decode_payload +********************************************************************/ +be_local_closure(Matter_Frame_decode_payload, /* name */ + be_nested_proto( + 7, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[19]) { /* constants */ + /* K0 */ be_nested_str_weak(payload_idx), + /* K1 */ be_nested_str_weak(raw), + /* K2 */ be_nested_str_weak(x_flags), + /* K3 */ be_nested_str_weak(get), + /* K4 */ be_const_int(1), + /* K5 */ be_nested_str_weak(x_flag_v), + /* K6 */ be_nested_str_weak(getbits), + /* K7 */ be_nested_str_weak(x_flag_sx), + /* K8 */ be_const_int(3), + /* K9 */ be_nested_str_weak(x_flag_r), + /* K10 */ be_const_int(2), + /* K11 */ be_nested_str_weak(x_flag_a), + /* K12 */ be_nested_str_weak(x_flag_i), + /* K13 */ be_nested_str_weak(opcode), + /* K14 */ be_nested_str_weak(exchange_id), + /* K15 */ be_nested_str_weak(protocol_id), + /* K16 */ be_nested_str_weak(vendor_id), + /* K17 */ be_nested_str_weak(ack_message_counter), + /* K18 */ be_nested_str_weak(app_payload_idx), + }), + be_str_weak(decode_payload), + &be_const_str_solidified, + ( &(const binstruction[87]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x88080101, // 0001 GETMBR R2 R0 K1 + 0x8C0C0503, // 0002 GETMET R3 R2 K3 + 0x5C140200, // 0003 MOVE R5 R1 + 0x58180004, // 0004 LDCONST R6 K4 + 0x7C0C0600, // 0005 CALL R3 3 + 0x90020403, // 0006 SETMBR R0 K2 R3 + 0x8C0C0506, // 0007 GETMET R3 R2 K6 + 0x54160007, // 0008 LDINT R5 8 + 0x08140205, // 0009 MUL R5 R1 R5 + 0x541A0003, // 000A LDINT R6 4 + 0x00140A06, // 000B ADD R5 R5 R6 + 0x58180004, // 000C LDCONST R6 K4 + 0x7C0C0600, // 000D CALL R3 3 + 0x90020A03, // 000E SETMBR R0 K5 R3 + 0x8C0C0506, // 000F GETMET R3 R2 K6 + 0x54160007, // 0010 LDINT R5 8 + 0x08140205, // 0011 MUL R5 R1 R5 + 0x00140B08, // 0012 ADD R5 R5 K8 + 0x58180004, // 0013 LDCONST R6 K4 + 0x7C0C0600, // 0014 CALL R3 3 + 0x90020E03, // 0015 SETMBR R0 K7 R3 + 0x8C0C0506, // 0016 GETMET R3 R2 K6 + 0x54160007, // 0017 LDINT R5 8 + 0x08140205, // 0018 MUL R5 R1 R5 + 0x00140B0A, // 0019 ADD R5 R5 K10 + 0x58180004, // 001A LDCONST R6 K4 + 0x7C0C0600, // 001B CALL R3 3 + 0x90021203, // 001C SETMBR R0 K9 R3 + 0x8C0C0506, // 001D GETMET R3 R2 K6 + 0x54160007, // 001E LDINT R5 8 + 0x08140205, // 001F MUL R5 R1 R5 + 0x00140B04, // 0020 ADD R5 R5 K4 + 0x58180004, // 0021 LDCONST R6 K4 + 0x7C0C0600, // 0022 CALL R3 3 + 0x90021603, // 0023 SETMBR R0 K11 R3 + 0x8C0C0506, // 0024 GETMET R3 R2 K6 + 0x54160007, // 0025 LDINT R5 8 + 0x08140205, // 0026 MUL R5 R1 R5 + 0x58180004, // 0027 LDCONST R6 K4 + 0x7C0C0600, // 0028 CALL R3 3 + 0x90021803, // 0029 SETMBR R0 K12 R3 + 0x8C0C0503, // 002A GETMET R3 R2 K3 + 0x00140304, // 002B ADD R5 R1 K4 + 0x58180004, // 002C LDCONST R6 K4 + 0x7C0C0600, // 002D CALL R3 3 + 0x90021A03, // 002E SETMBR R0 K13 R3 + 0x8C0C0503, // 002F GETMET R3 R2 K3 + 0x0014030A, // 0030 ADD R5 R1 K10 + 0x5818000A, // 0031 LDCONST R6 K10 + 0x7C0C0600, // 0032 CALL R3 3 + 0x90021C03, // 0033 SETMBR R0 K14 R3 + 0x8C0C0503, // 0034 GETMET R3 R2 K3 + 0x54160003, // 0035 LDINT R5 4 + 0x00140205, // 0036 ADD R5 R1 R5 + 0x5818000A, // 0037 LDCONST R6 K10 + 0x7C0C0600, // 0038 CALL R3 3 + 0x90021E03, // 0039 SETMBR R0 K15 R3 + 0x540E0005, // 003A LDINT R3 6 + 0x00040203, // 003B ADD R1 R1 R3 + 0x880C0105, // 003C GETMBR R3 R0 K5 + 0x780E0005, // 003D JMPF R3 #0044 + 0x8C0C0503, // 003E GETMET R3 R2 K3 + 0x5C140200, // 003F MOVE R5 R1 + 0x5818000A, // 0040 LDCONST R6 K10 + 0x7C0C0600, // 0041 CALL R3 3 + 0x90022003, // 0042 SETMBR R0 K16 R3 + 0x0004030A, // 0043 ADD R1 R1 K10 + 0x880C010B, // 0044 GETMBR R3 R0 K11 + 0x780E0006, // 0045 JMPF R3 #004D + 0x8C0C0503, // 0046 GETMET R3 R2 K3 + 0x5C140200, // 0047 MOVE R5 R1 + 0x541A0003, // 0048 LDINT R6 4 + 0x7C0C0600, // 0049 CALL R3 3 + 0x90022203, // 004A SETMBR R0 K17 R3 + 0x540E0003, // 004B LDINT R3 4 + 0x00040203, // 004C ADD R1 R1 R3 + 0x880C0107, // 004D GETMBR R3 R0 K7 + 0x780E0005, // 004E JMPF R3 #0055 + 0x8C0C0503, // 004F GETMET R3 R2 K3 + 0x5C140200, // 0050 MOVE R5 R1 + 0x5818000A, // 0051 LDCONST R6 K10 + 0x7C0C0600, // 0052 CALL R3 3 + 0x0010070A, // 0053 ADD R4 R3 K10 + 0x00040204, // 0054 ADD R1 R1 R4 + 0x90022401, // 0055 SETMBR R0 K18 R1 + 0x80040000, // 0056 RET 1 R0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: decrypt +********************************************************************/ +be_local_closure(Matter_Frame_decrypt, /* name */ + be_nested_proto( + 16, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[36]) { /* constants */ + /* K0 */ be_nested_str_weak(crypto), + /* K1 */ be_nested_str_weak(session), + /* K2 */ be_nested_str_weak(raw), + /* K3 */ be_const_int(2147483647), + /* K4 */ be_nested_str_weak(get_i2r), + /* K5 */ be_nested_str_weak(sec_p), + /* K6 */ be_nested_str_weak(get_i2r_privacy), + /* K7 */ be_nested_str_weak(add), + /* K8 */ be_nested_str_weak(local_session_id), + /* K9 */ be_nested_str_weak(payload_idx), + /* K10 */ be_const_int(1), + /* K11 */ be_nested_str_weak(AES_CTR), + /* K12 */ be_nested_str_weak(decrypt), + /* K13 */ be_const_int(2), + /* K14 */ be_const_int(0), + /* K15 */ be_const_int(3), + /* K16 */ be_nested_str_weak(self), + /* K17 */ be_nested_str_weak(flags), + /* K18 */ be_nested_str_weak(message_counter), + /* K19 */ be_nested_str_weak(source_node_id), + /* K20 */ be_nested_str_weak(peer_node_id), + /* K21 */ be_nested_str_weak(resize), + /* K22 */ be_nested_str_weak(tasmota), + /* K23 */ be_nested_str_weak(log), + /* K24 */ be_nested_str_weak(MTR_X3A_X20_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A_X2A), + /* K25 */ be_nested_str_weak(MTR_X3A_X20i2r_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K26 */ be_nested_str_weak(tohex), + /* K27 */ be_nested_str_weak(MTR_X3A_X20p_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K28 */ be_nested_str_weak(MTR_X3A_X20a_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K29 */ be_nested_str_weak(MTR_X3A_X20n_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K30 */ be_nested_str_weak(MTR_X3A_X20mic_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K31 */ be_nested_str_weak(AES_CCM), + /* K32 */ be_nested_str_weak(tag), + /* K33 */ be_nested_str_weak(MTR_X3A_X20cleartext_X20_X20_X20_X3D), + /* K34 */ be_nested_str_weak(MTR_X3A_X20tag_X20_X20_X20_X20_X20_X20_X20_X20_X20_X3D), + /* K35 */ be_nested_str_weak(MTR_X3A_X20rejected_X20packet_X20due_X20to_X20invalid_X20MIC), + }), + be_str_weak(decrypt), + &be_const_str_solidified, + ( &(const binstruction[165]) { /* code */ + 0xA4060000, // 0000 IMPORT R1 K0 + 0x88080101, // 0001 GETMBR R2 R0 K1 + 0x880C0102, // 0002 GETMBR R3 R0 K2 + 0x5411FFEF, // 0003 LDINT R4 -16 + 0x40100903, // 0004 CONNECT R4 R4 K3 + 0x94100604, // 0005 GETIDX R4 R3 R4 + 0x8C140504, // 0006 GETMET R5 R2 K4 + 0x7C140200, // 0007 CALL R5 1 + 0x88180105, // 0008 GETMBR R6 R0 K5 + 0x781A0025, // 0009 JMPF R6 #0030 + 0x8C180506, // 000A GETMET R6 R2 K6 + 0x7C180200, // 000B CALL R6 1 + 0x601C0015, // 000C GETGBL R7 G21 + 0x7C1C0000, // 000D CALL R7 0 + 0x8C1C0F07, // 000E GETMET R7 R7 K7 + 0x88240108, // 000F GETMBR R9 R0 K8 + 0x5429FFFD, // 0010 LDINT R10 -2 + 0x7C1C0600, // 0011 CALL R7 3 + 0x54220004, // 0012 LDINT R8 5 + 0x5426000E, // 0013 LDINT R9 15 + 0x40201009, // 0014 CONNECT R8 R8 R9 + 0x94200808, // 0015 GETIDX R8 R4 R8 + 0x001C0E08, // 0016 ADD R7 R7 R8 + 0x54220003, // 0017 LDINT R8 4 + 0x88240109, // 0018 GETMBR R9 R0 K9 + 0x0424130A, // 0019 SUB R9 R9 K10 + 0x40201009, // 001A CONNECT R8 R8 R9 + 0x88240102, // 001B GETMBR R9 R0 K2 + 0x94201208, // 001C GETIDX R8 R9 R8 + 0x8C28030B, // 001D GETMET R10 R1 K11 + 0x5C300C00, // 001E MOVE R12 R6 + 0x7C280400, // 001F CALL R10 2 + 0x8C28150C, // 0020 GETMET R10 R10 K12 + 0x5C301000, // 0021 MOVE R12 R8 + 0x5C340E00, // 0022 MOVE R13 R7 + 0x5838000D, // 0023 LDCONST R14 K13 + 0x7C280800, // 0024 CALL R10 4 + 0x5C241400, // 0025 MOVE R9 R10 + 0x402A1D0F, // 0026 CONNECT R10 K14 K15 + 0x882C0102, // 0027 GETMBR R11 R0 K2 + 0x9428160A, // 0028 GETIDX R10 R11 R10 + 0x00281409, // 0029 ADD R10 R10 R9 + 0x882C0110, // 002A GETMBR R11 R0 K16 + 0x882C1709, // 002B GETMBR R11 R11 K9 + 0x402C1703, // 002C CONNECT R11 R11 K3 + 0x942C100B, // 002D GETIDX R11 R8 R11 + 0x0028140B, // 002E ADD R10 R10 R11 + 0x9002040A, // 002F SETMBR R0 K2 R10 + 0x88180109, // 0030 GETMBR R6 R0 K9 + 0x04180D0A, // 0031 SUB R6 R6 K10 + 0x401A1C06, // 0032 CONNECT R6 K14 R6 + 0x94180606, // 0033 GETIDX R6 R3 R6 + 0x881C0109, // 0034 GETMBR R7 R0 K9 + 0x5421FFEE, // 0035 LDINT R8 -17 + 0x401C0E08, // 0036 CONNECT R7 R7 R8 + 0x941C0607, // 0037 GETIDX R7 R3 R7 + 0x60200015, // 0038 GETGBL R8 G21 + 0x7C200000, // 0039 CALL R8 0 + 0x8C241107, // 003A GETMET R9 R8 K7 + 0x882C0111, // 003B GETMBR R11 R0 K17 + 0x5830000A, // 003C LDCONST R12 K10 + 0x7C240600, // 003D CALL R9 3 + 0x8C241107, // 003E GETMET R9 R8 K7 + 0x882C0112, // 003F GETMBR R11 R0 K18 + 0x54320003, // 0040 LDINT R12 4 + 0x7C240600, // 0041 CALL R9 3 + 0x88240113, // 0042 GETMBR R9 R0 K19 + 0x78260001, // 0043 JMPF R9 #0046 + 0x40241103, // 0044 CONNECT R9 R8 K3 + 0x70020006, // 0045 JMP #004D + 0x88240514, // 0046 GETMBR R9 R2 K20 + 0x78260001, // 0047 JMPF R9 #004A + 0x88240514, // 0048 GETMBR R9 R2 K20 + 0x40241009, // 0049 CONNECT R9 R8 R9 + 0x8C241115, // 004A GETMET R9 R8 K21 + 0x542E000C, // 004B LDINT R11 13 + 0x7C240400, // 004C CALL R9 2 + 0xB8262C00, // 004D GETNGBL R9 K22 + 0x8C241317, // 004E GETMET R9 R9 K23 + 0x582C0018, // 004F LDCONST R11 K24 + 0x54320003, // 0050 LDINT R12 4 + 0x7C240600, // 0051 CALL R9 3 + 0xB8262C00, // 0052 GETNGBL R9 K22 + 0x8C241317, // 0053 GETMET R9 R9 K23 + 0x8C2C0B1A, // 0054 GETMET R11 R5 K26 + 0x7C2C0200, // 0055 CALL R11 1 + 0x002E320B, // 0056 ADD R11 K25 R11 + 0x54320003, // 0057 LDINT R12 4 + 0x7C240600, // 0058 CALL R9 3 + 0xB8262C00, // 0059 GETNGBL R9 K22 + 0x8C241317, // 005A GETMET R9 R9 K23 + 0x8C2C0F1A, // 005B GETMET R11 R7 K26 + 0x7C2C0200, // 005C CALL R11 1 + 0x002E360B, // 005D ADD R11 K27 R11 + 0x54320003, // 005E LDINT R12 4 + 0x7C240600, // 005F CALL R9 3 + 0xB8262C00, // 0060 GETNGBL R9 K22 + 0x8C241317, // 0061 GETMET R9 R9 K23 + 0x8C2C0D1A, // 0062 GETMET R11 R6 K26 + 0x7C2C0200, // 0063 CALL R11 1 + 0x002E380B, // 0064 ADD R11 K28 R11 + 0x54320003, // 0065 LDINT R12 4 + 0x7C240600, // 0066 CALL R9 3 + 0xB8262C00, // 0067 GETNGBL R9 K22 + 0x8C241317, // 0068 GETMET R9 R9 K23 + 0x8C2C111A, // 0069 GETMET R11 R8 K26 + 0x7C2C0200, // 006A CALL R11 1 + 0x002E3A0B, // 006B ADD R11 K29 R11 + 0x54320003, // 006C LDINT R12 4 + 0x7C240600, // 006D CALL R9 3 + 0xB8262C00, // 006E GETNGBL R9 K22 + 0x8C241317, // 006F GETMET R9 R9 K23 + 0x8C2C091A, // 0070 GETMET R11 R4 K26 + 0x7C2C0200, // 0071 CALL R11 1 + 0x002E3C0B, // 0072 ADD R11 K30 R11 + 0x54320003, // 0073 LDINT R12 4 + 0x7C240600, // 0074 CALL R9 3 + 0x8C24031F, // 0075 GETMET R9 R1 K31 + 0x5C2C0A00, // 0076 MOVE R11 R5 + 0x5C301000, // 0077 MOVE R12 R8 + 0x5C340C00, // 0078 MOVE R13 R6 + 0x6038000C, // 0079 GETGBL R14 G12 + 0x5C3C0E00, // 007A MOVE R15 R7 + 0x7C380200, // 007B CALL R14 1 + 0x543E000F, // 007C LDINT R15 16 + 0x7C240C00, // 007D CALL R9 6 + 0x8C28130C, // 007E GETMET R10 R9 K12 + 0x5C300E00, // 007F MOVE R12 R7 + 0x7C280400, // 0080 CALL R10 2 + 0x8C2C1320, // 0081 GETMET R11 R9 K32 + 0x7C2C0200, // 0082 CALL R11 1 + 0xB8322C00, // 0083 GETNGBL R12 K22 + 0x8C301917, // 0084 GETMET R12 R12 K23 + 0x58380018, // 0085 LDCONST R14 K24 + 0x543E0003, // 0086 LDINT R15 4 + 0x7C300600, // 0087 CALL R12 3 + 0xB8322C00, // 0088 GETNGBL R12 K22 + 0x8C301917, // 0089 GETMET R12 R12 K23 + 0x8C38151A, // 008A GETMET R14 R10 K26 + 0x7C380200, // 008B CALL R14 1 + 0x003A420E, // 008C ADD R14 K33 R14 + 0x543E0003, // 008D LDINT R15 4 + 0x7C300600, // 008E CALL R12 3 + 0xB8322C00, // 008F GETNGBL R12 K22 + 0x8C301917, // 0090 GETMET R12 R12 K23 + 0x8C38171A, // 0091 GETMET R14 R11 K26 + 0x7C380200, // 0092 CALL R14 1 + 0x003A440E, // 0093 ADD R14 K34 R14 + 0x543E0003, // 0094 LDINT R15 4 + 0x7C300600, // 0095 CALL R12 3 + 0xB8322C00, // 0096 GETNGBL R12 K22 + 0x8C301917, // 0097 GETMET R12 R12 K23 + 0x58380018, // 0098 LDCONST R14 K24 + 0x543E0003, // 0099 LDINT R15 4 + 0x7C300600, // 009A CALL R12 3 + 0x20301604, // 009B NE R12 R11 R4 + 0x78320006, // 009C JMPF R12 #00A4 + 0xB8322C00, // 009D GETNGBL R12 K22 + 0x8C301917, // 009E GETMET R12 R12 K23 + 0x58380023, // 009F LDCONST R14 K35 + 0x583C000F, // 00A0 LDCONST R15 K15 + 0x7C300600, // 00A1 CALL R12 3 + 0x4C300000, // 00A2 LDNIL R12 + 0x80041800, // 00A3 RET 1 R12 + 0x80041400, // 00A4 RET 1 R10 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified class: Matter_Frame ********************************************************************/ be_local_class(Matter_Frame, 32, NULL, - be_nested_map(41, + be_nested_map(42, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(x_flag_a, 8), be_const_var(21) }, - { be_const_key_weak(x_flags, -1), be_const_var(17) }, - { be_const_key_weak(raw, 37), be_const_var(2) }, - { be_const_key_weak(sec_sesstype, 0), be_const_var(12) }, - { be_const_key_weak(build_response, 5), be_const_closure(Matter_Frame_build_response_closure) }, - { be_const_key_weak(sec_mx, -1), be_const_var(11) }, - { be_const_key_weak(dest_node_id_2, 32), be_const_var(15) }, - { be_const_key_weak(encode, -1), be_const_closure(Matter_Frame_encode_closure) }, + { be_const_key_weak(x_flag_i, -1), be_const_var(22) }, + { be_const_key_weak(dest_node_id_8, 7), be_const_var(16) }, + { be_const_key_weak(remote_ip, -1), be_const_var(30) }, + { be_const_key_weak(x_flag_a, -1), be_const_var(21) }, + { be_const_key_weak(exchange_id, -1), be_const_var(24) }, + { be_const_key_weak(opcode, -1), be_const_var(23) }, + { be_const_key_weak(sec_sesstype, -1), be_const_var(12) }, + { be_const_key_weak(app_payload_idx, -1), be_const_var(29) }, + { be_const_key_weak(payload_idx, -1), be_const_var(3) }, + { be_const_key_weak(ack_message_counter, 6), be_const_var(27) }, + { be_const_key_weak(sec_c, -1), be_const_var(10) }, + { be_const_key_weak(x_flag_v, -1), be_const_var(18) }, + { be_const_key_weak(x_flag_sx, 10), be_const_var(19) }, + { be_const_key_weak(encode, 28), be_const_closure(Matter_Frame_encode_closure) }, + { be_const_key_weak(local_session_id, -1), be_const_var(7) }, + { be_const_key_weak(flag_s, -1), be_const_var(5) }, + { be_const_key_weak(debug, -1), be_const_closure(Matter_Frame_debug_closure) }, + { be_const_key_weak(build_standalone_ack, 34), be_const_closure(Matter_Frame_build_standalone_ack_closure) }, + { be_const_key_weak(encrypt, 12), be_const_closure(Matter_Frame_encrypt_closure) }, + { be_const_key_weak(session, -1), be_const_var(1) }, + { be_const_key_weak(sec_flags, -1), be_const_var(8) }, + { be_const_key_weak(build_response, -1), be_const_closure(Matter_Frame_build_response_closure) }, + { be_const_key_weak(initiate_response, -1), be_const_static_closure(Matter_Frame_initiate_response_closure) }, + { be_const_key_weak(vendor_id, 32), be_const_var(26) }, + { be_const_key_weak(decode_header, -1), be_const_closure(Matter_Frame_decode_header_closure) }, + { be_const_key_weak(remote_port, 24), be_const_var(31) }, + { be_const_key_weak(flags, -1), be_const_var(4) }, + { be_const_key_weak(protocol_id, 23), be_const_var(25) }, + { be_const_key_weak(raw, -1), be_const_var(2) }, + { be_const_key_weak(source_node_id, 13), be_const_var(14) }, + { be_const_key_weak(flag_dsiz, -1), be_const_var(6) }, + { be_const_key_weak(x_flag_r, -1), be_const_var(20) }, + { be_const_key_weak(message_counter, -1), be_const_var(13) }, + { be_const_key_weak(init, 14), be_const_closure(Matter_Frame_init_closure) }, + { be_const_key_weak(message_handler, -1), be_const_var(0) }, + { be_const_key_weak(dest_node_id_2, -1), be_const_var(15) }, + { be_const_key_weak(decode_payload, -1), be_const_closure(Matter_Frame_decode_payload_closure) }, + { be_const_key_weak(sec_p, 8), be_const_var(9) }, { be_const_key_weak(decrypt, -1), be_const_closure(Matter_Frame_decrypt_closure) }, { be_const_key_weak(sec_extensions, -1), be_const_var(28) }, - { be_const_key_weak(remote_ip, 7), be_const_var(30) }, - { be_const_key_weak(message_counter, 33), be_const_var(13) }, - { be_const_key_weak(ack_message_counter, -1), be_const_var(27) }, - { be_const_key_weak(x_flag_i, -1), be_const_var(22) }, - { be_const_key_weak(dest_node_id_8, -1), be_const_var(16) }, - { be_const_key_weak(x_flag_r, 2), be_const_var(20) }, - { be_const_key_weak(x_flag_v, -1), be_const_var(18) }, - { be_const_key_weak(opcode, -1), be_const_var(23) }, - { be_const_key_weak(sec_c, 25), be_const_var(10) }, - { be_const_key_weak(sec_p, -1), be_const_var(9) }, - { be_const_key_weak(protocol_id, 29), be_const_var(25) }, - { be_const_key_weak(sec_flags, -1), be_const_var(8) }, - { be_const_key_weak(message_handler, -1), be_const_var(0) }, - { be_const_key_weak(init, -1), be_const_closure(Matter_Frame_init_closure) }, - { be_const_key_weak(encrypt, 19), be_const_closure(Matter_Frame_encrypt_closure) }, - { be_const_key_weak(build_standalone_ack, 27), be_const_closure(Matter_Frame_build_standalone_ack_closure) }, - { be_const_key_weak(decode_payload, -1), be_const_closure(Matter_Frame_decode_payload_closure) }, - { be_const_key_weak(remote_port, 36), be_const_var(31) }, - { be_const_key_weak(flag_dsiz, -1), be_const_var(6) }, - { be_const_key_weak(vendor_id, 16), be_const_var(26) }, - { be_const_key_weak(payload_idx, -1), be_const_var(3) }, - { be_const_key_weak(debug, -1), be_const_closure(Matter_Frame_debug_closure) }, - { be_const_key_weak(x_flag_sx, 39), be_const_var(19) }, - { be_const_key_weak(decode_header, -1), be_const_closure(Matter_Frame_decode_header_closure) }, - { be_const_key_weak(flag_s, -1), be_const_var(5) }, - { be_const_key_weak(app_payload_idx, -1), be_const_var(29) }, - { be_const_key_weak(source_node_id, -1), be_const_var(14) }, - { be_const_key_weak(session, -1), be_const_var(1) }, - { be_const_key_weak(flags, -1), be_const_var(4) }, - { be_const_key_weak(local_session_id, 40), be_const_var(7) }, - { be_const_key_weak(exchange_id, -1), be_const_var(24) }, + { be_const_key_weak(sec_mx, 3), be_const_var(11) }, + { be_const_key_weak(x_flags, 2), be_const_var(17) }, })), be_str_weak(Matter_Frame) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_MessageHandler.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_MessageHandler.h index 453348f65..34f73b98f 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_MessageHandler.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_MessageHandler.h @@ -45,7 +45,7 @@ be_local_closure(Matter_MessageHandler_send_response, /* name */ ********************************************************************/ be_local_closure(Matter_MessageHandler_msg_received, /* name */ be_nested_proto( - 17, /* nstack */ + 18, /* nstack */ 4, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -53,7 +53,7 @@ be_local_closure(Matter_MessageHandler_msg_received, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[59]) { /* constants */ + ( &(const bvalue[69]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(tasmota), /* K2 */ be_nested_str_weak(log), @@ -72,342 +72,374 @@ be_local_closure(Matter_MessageHandler_msg_received, /* name */ /* K15 */ be_nested_str_weak(MTR_X3A_X20find_X20session_X20by_X20source_node_id_X20_X3D_X20), /* K16 */ be_nested_str_weak(session_id_X20_X3D_X20), /* K17 */ be_const_int(3), - /* K18 */ be_nested_str_weak(session), - /* K19 */ be_nested_str_weak(counter_rcv), - /* K20 */ be_nested_str_weak(validate), - /* K21 */ be_nested_str_weak(message_counter), - /* K22 */ be_nested_str_weak(format), - /* K23 */ be_nested_str_weak(MTR_X3A_X20rejected_X20duplicate_X20unencrypted_X20message_X20_X3D_X20_X25i_X20ref_X20_X3D_X20_X25i), - /* K24 */ be_nested_str_weak(val), - /* K25 */ be_nested_str_weak(decode_payload), - /* K26 */ be_nested_str_weak(packet_ack), - /* K27 */ be_nested_str_weak(ack_message_counter), - /* K28 */ be_nested_str_weak(opcode), - /* K29 */ be_nested_str_weak(get_opcode_name), - /* K30 */ be_nested_str_weak(0x_X2502X), - /* K31 */ be_nested_str_weak(MTR_X3A_X20_X3EReceived_X20_X20_X20_X20_X20_X20_X25s_X20from_X20_X5B_X25s_X5D_X3A_X25i), - /* K32 */ be_const_int(2), - /* K33 */ be_nested_str_weak(commissioning), - /* K34 */ be_nested_str_weak(process_incoming), - /* K35 */ be_nested_str_weak(MTR_X3A_X20decode_X20header_X3A_X20local_session_id_X3D_X25i_X20message_counter_X3D_X25i), - /* K36 */ be_nested_str_weak(get_session_by_local_session_id), - /* K37 */ be_nested_str_weak(MTR_X3A_X20unknown_X20local_session_id_X20), - /* K38 */ be_nested_str_weak(MTR_X3A_X20frame_X3D), - /* K39 */ be_nested_str_weak(inspect), - /* K40 */ be_nested_str_weak(MTR_X3A_X20rejected_X20duplicate_X20encrypted_X20message_X20_X3D_X20), - /* K41 */ be_nested_str_weak(_X20counter_X3D), - /* K42 */ be_nested_str_weak(decrypt), - /* K43 */ be_nested_str_weak(raw), - /* K44 */ be_nested_str_weak(payload_idx), - /* K45 */ be_const_int(1), - /* K46 */ be_nested_str_weak(MTR_X3A_X20idx_X3D_X25i_X20clear_X3D_X25s), - /* K47 */ be_nested_str_weak(MTR_X3A_X20decrypted_X20message_X3A_X20protocol_id_X3A), - /* K48 */ be_nested_str_weak(protocol_id), - /* K49 */ be_nested_str_weak(_X20opcode_X3D), - /* K50 */ be_nested_str_weak(_X20exchange_id), - /* K51 */ be_nested_str_weak(exchange_id), - /* K52 */ be_nested_str_weak(MTR_X3A_X20PROTOCOL_ID_SECURE_CHANNEL_X20), - /* K53 */ be_nested_str_weak(im), - /* K54 */ be_nested_str_weak(MTR_X3A_X20ignoring_X20unhandled_X20protocol_id_X3A), - /* K55 */ be_nested_str_weak(MTR_X3A_X20MessageHandler_X3A_X3Amsg_received_X20exception_X3A_X20), - /* K56 */ be_nested_str_weak(_X3B), - /* K57 */ be_nested_str_weak(debug), - /* K58 */ be_nested_str_weak(traceback), + /* K18 */ be_nested_str_weak(__ip), + /* K19 */ be_nested_str_weak(__port), + /* K20 */ be_nested_str_weak(session), + /* K21 */ be_nested_str_weak(counter_rcv), + /* K22 */ be_nested_str_weak(validate), + /* K23 */ be_nested_str_weak(message_counter), + /* K24 */ be_nested_str_weak(format), + /* K25 */ be_nested_str_weak(MTR_X3A_X20rejected_X20duplicate_X20unencrypted_X20message_X20_X3D_X20_X25i_X20ref_X20_X3D_X20_X25i), + /* K26 */ be_nested_str_weak(val), + /* K27 */ be_nested_str_weak(decode_payload), + /* K28 */ be_nested_str_weak(packet_ack), + /* K29 */ be_nested_str_weak(ack_message_counter), + /* K30 */ be_nested_str_weak(opcode), + /* K31 */ be_nested_str_weak(get_opcode_name), + /* K32 */ be_nested_str_weak(0x_X2502X), + /* K33 */ be_nested_str_weak(MTR_X3A_X20_X3EReceived_X20_X20_X25s_X20from_X20_X5B_X25s_X5D_X3A_X25i), + /* K34 */ be_const_int(2), + /* K35 */ be_nested_str_weak(commissioning), + /* K36 */ be_nested_str_weak(process_incoming), + /* K37 */ be_nested_str_weak(MTR_X3A_X20decode_X20header_X3A_X20local_session_id_X3D_X25i_X20message_counter_X3D_X25i), + /* K38 */ be_nested_str_weak(get_session_by_local_session_id), + /* K39 */ be_nested_str_weak(MTR_X3A_X20unknown_X20local_session_id_X20), + /* K40 */ be_nested_str_weak(MTR_X3A_X20frame_X3D), + /* K41 */ be_nested_str_weak(inspect), + /* K42 */ be_nested_str_weak(MTR_X3A_X20rejected_X20duplicate_X20encrypted_X20message_X20_X3D_X20), + /* K43 */ be_nested_str_weak(_X20counter_X3D), + /* K44 */ be_nested_str_weak(decrypt), + /* K45 */ be_nested_str_weak(raw), + /* K46 */ be_nested_str_weak(payload_idx), + /* K47 */ be_const_int(1), + /* K48 */ be_nested_str_weak(MTR_X3A_X20idx_X3D_X25i_X20clear_X3D_X25s), + /* K49 */ be_nested_str_weak(MTR_X3A_X20decrypted_X20message_X3A_X20protocol_id_X3A), + /* K50 */ be_nested_str_weak(protocol_id), + /* K51 */ be_nested_str_weak(_X20opcode_X3D), + /* K52 */ be_nested_str_weak(_X20exchange_id_X3D), + /* K53 */ be_nested_str_weak(exchange_id), + /* K54 */ be_nested_str_weak(MTR_X3A_X20PROTOCOL_ID_SECURE_CHANNEL_X20), + /* K55 */ be_nested_str_weak(im), + /* K56 */ be_nested_str_weak(send_enqueued), + /* K57 */ be_nested_str_weak(x_flag_r), + /* K58 */ be_nested_str_weak(build_standalone_ack), + /* K59 */ be_nested_str_weak(encode), + /* K60 */ be_nested_str_weak(encrypt), + /* K61 */ be_nested_str_weak(send_response), + /* K62 */ be_nested_str_weak(remote_ip), + /* K63 */ be_nested_str_weak(remote_port), + /* K64 */ be_nested_str_weak(MTR_X3A_X20ignoring_X20unhandled_X20protocol_id_X3A), + /* K65 */ be_nested_str_weak(MTR_X3A_X20MessageHandler_X3A_X3Amsg_received_X20exception_X3A_X20), + /* K66 */ be_nested_str_weak(_X3B), + /* K67 */ be_nested_str_weak(debug), + /* K68 */ be_nested_str_weak(traceback), }), be_str_weak(msg_received), &be_const_str_solidified, - ( &(const binstruction[291]) { /* code */ + ( &(const binstruction[313]) { /* code */ 0xA4120000, // 0000 IMPORT R4 K0 - 0xA802010A, // 0001 EXBLK 0 #010D - 0xB8160200, // 0002 GETNGBL R5 K1 - 0x8C140B02, // 0003 GETMET R5 R5 K2 - 0x8C1C0304, // 0004 GETMET R7 R1 K4 - 0x7C1C0200, // 0005 CALL R7 1 - 0x001E0607, // 0006 ADD R7 K3 R7 - 0x54220003, // 0007 LDINT R8 4 - 0x7C140600, // 0008 CALL R5 3 - 0xB8160A00, // 0009 GETNGBL R5 K5 - 0x8C140B06, // 000A GETMET R5 R5 K6 - 0x5C1C0000, // 000B MOVE R7 R0 - 0x5C200200, // 000C MOVE R8 R1 - 0x5C240400, // 000D MOVE R9 R2 - 0x5C280600, // 000E MOVE R10 R3 - 0x7C140A00, // 000F CALL R5 5 - 0x8C180B07, // 0010 GETMET R6 R5 K7 - 0x7C180200, // 0011 CALL R6 1 - 0x5C1C0C00, // 0012 MOVE R7 R6 - 0x741E0002, // 0013 JMPT R7 #0017 - 0x501C0000, // 0014 LDBOOL R7 0 0 - 0xA8040001, // 0015 EXBLK 1 1 - 0x80040E00, // 0016 RET 1 R7 - 0x881C0B08, // 0017 GETMBR R7 R5 K8 - 0x1C1C0F09, // 0018 EQ R7 R7 K9 - 0x781E0057, // 0019 JMPF R7 #0072 - 0x881C0B0A, // 001A GETMBR R7 R5 K10 - 0x1C1C0F09, // 001B EQ R7 R7 K9 - 0x781E0054, // 001C JMPF R7 #0072 - 0x881C010B, // 001D GETMBR R7 R0 K11 - 0x881C0F0C, // 001E GETMBR R7 R7 K12 - 0x8C1C0F0D, // 001F GETMET R7 R7 K13 - 0x88240B0E, // 0020 GETMBR R9 R5 K14 - 0x542A0059, // 0021 LDINT R10 90 - 0x7C1C0600, // 0022 CALL R7 3 - 0xB8220200, // 0023 GETNGBL R8 K1 - 0x8C201102, // 0024 GETMET R8 R8 K2 - 0x60280008, // 0025 GETGBL R10 G8 - 0x882C0B0E, // 0026 GETMBR R11 R5 K14 - 0x7C280200, // 0027 CALL R10 1 - 0x002A1E0A, // 0028 ADD R10 K15 R10 - 0x00281510, // 0029 ADD R10 R10 K16 - 0x602C0008, // 002A GETGBL R11 G8 - 0x88300F08, // 002B GETMBR R12 R7 K8 - 0x7C2C0200, // 002C CALL R11 1 - 0x0028140B, // 002D ADD R10 R10 R11 - 0x582C0011, // 002E LDCONST R11 K17 - 0x7C200600, // 002F CALL R8 3 - 0x90162407, // 0030 SETMBR R5 K18 R7 - 0x88200113, // 0031 GETMBR R8 R0 K19 - 0x8C201114, // 0032 GETMET R8 R8 K20 - 0x88280B15, // 0033 GETMBR R10 R5 K21 - 0x502C0000, // 0034 LDBOOL R11 0 0 - 0x7C200600, // 0035 CALL R8 3 - 0x7422000D, // 0036 JMPT R8 #0045 - 0xB8220200, // 0037 GETNGBL R8 K1 - 0x8C201102, // 0038 GETMET R8 R8 K2 - 0x8C280916, // 0039 GETMET R10 R4 K22 - 0x58300017, // 003A LDCONST R12 K23 - 0x88340B15, // 003B GETMBR R13 R5 K21 - 0x88380113, // 003C GETMBR R14 R0 K19 - 0x8C381D18, // 003D GETMET R14 R14 K24 - 0x7C380200, // 003E CALL R14 1 - 0x7C280800, // 003F CALL R10 4 - 0x582C0011, // 0040 LDCONST R11 K17 - 0x7C200600, // 0041 CALL R8 3 - 0x50200000, // 0042 LDBOOL R8 0 0 - 0xA8040001, // 0043 EXBLK 1 1 - 0x80041000, // 0044 RET 1 R8 - 0x8C200B19, // 0045 GETMET R8 R5 K25 - 0x7C200200, // 0046 CALL R8 1 - 0x74220002, // 0047 JMPT R8 #004B - 0x50200000, // 0048 LDBOOL R8 0 0 - 0xA8040001, // 0049 EXBLK 1 1 - 0x80041000, // 004A RET 1 R8 - 0x8820010B, // 004B GETMBR R8 R0 K11 - 0x8C20111A, // 004C GETMET R8 R8 K26 - 0x88280B1B, // 004D GETMBR R10 R5 K27 - 0x7C200400, // 004E CALL R8 2 - 0x88200B1C, // 004F GETMBR R8 R5 K28 - 0x5426000F, // 0050 LDINT R9 16 - 0x20201009, // 0051 NE R8 R8 R9 - 0x78220014, // 0052 JMPF R8 #0068 - 0xB8220A00, // 0053 GETNGBL R8 K5 - 0x8C20111D, // 0054 GETMET R8 R8 K29 - 0x88280B1C, // 0055 GETMBR R10 R5 K28 - 0x7C200400, // 0056 CALL R8 2 - 0x5C241000, // 0057 MOVE R9 R8 - 0x74260004, // 0058 JMPT R9 #005E - 0x8C240916, // 0059 GETMET R9 R4 K22 - 0x582C001E, // 005A LDCONST R11 K30 - 0x88300B1C, // 005B GETMBR R12 R5 K28 - 0x7C240600, // 005C CALL R9 3 - 0x5C201200, // 005D MOVE R8 R9 - 0xB8260200, // 005E GETNGBL R9 K1 - 0x8C241302, // 005F GETMET R9 R9 K2 - 0x8C2C0916, // 0060 GETMET R11 R4 K22 - 0x5834001F, // 0061 LDCONST R13 K31 - 0x5C381000, // 0062 MOVE R14 R8 - 0x5C3C0400, // 0063 MOVE R15 R2 - 0x5C400600, // 0064 MOVE R16 R3 - 0x7C2C0A00, // 0065 CALL R11 5 - 0x58300020, // 0066 LDCONST R12 K32 - 0x7C240600, // 0067 CALL R9 3 - 0x88200121, // 0068 GETMBR R8 R0 K33 - 0x8C201122, // 0069 GETMET R8 R8 K34 - 0x5C280A00, // 006A MOVE R10 R5 - 0x5C2C0400, // 006B MOVE R11 R2 - 0x5C300600, // 006C MOVE R12 R3 - 0x7C200800, // 006D CALL R8 4 - 0x50200200, // 006E LDBOOL R8 1 0 - 0xA8040001, // 006F EXBLK 1 1 - 0x80041000, // 0070 RET 1 R8 - 0x70020095, // 0071 JMP #0108 - 0xB81E0200, // 0072 GETNGBL R7 K1 - 0x8C1C0F02, // 0073 GETMET R7 R7 K2 - 0x8C240916, // 0074 GETMET R9 R4 K22 - 0x582C0023, // 0075 LDCONST R11 K35 - 0x88300B08, // 0076 GETMBR R12 R5 K8 - 0x88340B15, // 0077 GETMBR R13 R5 K21 - 0x7C240800, // 0078 CALL R9 4 - 0x58280011, // 0079 LDCONST R10 K17 - 0x7C1C0600, // 007A CALL R7 3 - 0x881C010B, // 007B GETMBR R7 R0 K11 - 0x881C0F0C, // 007C GETMBR R7 R7 K12 - 0x8C1C0F24, // 007D GETMET R7 R7 K36 - 0x88240B08, // 007E GETMBR R9 R5 K8 - 0x7C1C0400, // 007F CALL R7 2 - 0x4C200000, // 0080 LDNIL R8 - 0x1C200E08, // 0081 EQ R8 R7 R8 - 0x78220013, // 0082 JMPF R8 #0097 - 0xB8220200, // 0083 GETNGBL R8 K1 - 0x8C201102, // 0084 GETMET R8 R8 K2 - 0x60280008, // 0085 GETGBL R10 G8 - 0x882C0B08, // 0086 GETMBR R11 R5 K8 - 0x7C280200, // 0087 CALL R10 1 - 0x002A4A0A, // 0088 ADD R10 K37 R10 - 0x582C0011, // 0089 LDCONST R11 K17 - 0x7C200600, // 008A CALL R8 3 - 0xB8220200, // 008B GETNGBL R8 K1 - 0x8C201102, // 008C GETMET R8 R8 K2 - 0xB82A0A00, // 008D GETNGBL R10 K5 - 0x8C281527, // 008E GETMET R10 R10 K39 - 0x5C300A00, // 008F MOVE R12 R5 - 0x7C280400, // 0090 CALL R10 2 - 0x002A4C0A, // 0091 ADD R10 K38 R10 - 0x582C0011, // 0092 LDCONST R11 K17 - 0x7C200600, // 0093 CALL R8 3 - 0x50200000, // 0094 LDBOOL R8 0 0 - 0xA8040001, // 0095 EXBLK 1 1 - 0x80041000, // 0096 RET 1 R8 - 0x90162407, // 0097 SETMBR R5 K18 R7 - 0x88200F13, // 0098 GETMBR R8 R7 K19 - 0x8C201114, // 0099 GETMET R8 R8 K20 - 0x88280B15, // 009A GETMBR R10 R5 K21 - 0x502C0200, // 009B LDBOOL R11 1 0 - 0x7C200600, // 009C CALL R8 3 - 0x74220011, // 009D JMPT R8 #00B0 - 0xB8220200, // 009E GETNGBL R8 K1 - 0x8C201102, // 009F GETMET R8 R8 K2 - 0x60280008, // 00A0 GETGBL R10 G8 - 0x882C0B15, // 00A1 GETMBR R11 R5 K21 - 0x7C280200, // 00A2 CALL R10 1 - 0x002A500A, // 00A3 ADD R10 K40 R10 - 0x00281529, // 00A4 ADD R10 R10 K41 - 0x602C0008, // 00A5 GETGBL R11 G8 - 0x88300F13, // 00A6 GETMBR R12 R7 K19 - 0x8C301918, // 00A7 GETMET R12 R12 K24 - 0x7C300200, // 00A8 CALL R12 1 - 0x7C2C0200, // 00A9 CALL R11 1 - 0x0028140B, // 00AA ADD R10 R10 R11 - 0x582C0011, // 00AB LDCONST R11 K17 - 0x7C200600, // 00AC CALL R8 3 - 0x50200000, // 00AD LDBOOL R8 0 0 - 0xA8040001, // 00AE EXBLK 1 1 - 0x80041000, // 00AF RET 1 R8 - 0x8C200B2A, // 00B0 GETMET R8 R5 K42 - 0x7C200200, // 00B1 CALL R8 1 - 0x5C241000, // 00B2 MOVE R9 R8 - 0x74260002, // 00B3 JMPT R9 #00B7 - 0x50240000, // 00B4 LDBOOL R9 0 0 - 0xA8040001, // 00B5 EXBLK 1 1 - 0x80041200, // 00B6 RET 1 R9 - 0x88240B2C, // 00B7 GETMBR R9 R5 K44 - 0x0424132D, // 00B8 SUB R9 R9 K45 - 0x40261209, // 00B9 CONNECT R9 K9 R9 - 0x88280B2B, // 00BA GETMBR R10 R5 K43 - 0x94241409, // 00BB GETIDX R9 R10 R9 - 0x90165609, // 00BC SETMBR R5 K43 R9 - 0x88240B2B, // 00BD GETMBR R9 R5 K43 - 0x40241208, // 00BE CONNECT R9 R9 R8 - 0xB8260200, // 00BF GETNGBL R9 K1 - 0x8C241302, // 00C0 GETMET R9 R9 K2 - 0x8C2C0916, // 00C1 GETMET R11 R4 K22 - 0x5834002E, // 00C2 LDCONST R13 K46 - 0x88380B2C, // 00C3 GETMBR R14 R5 K44 - 0x883C0B2B, // 00C4 GETMBR R15 R5 K43 - 0x8C3C1F04, // 00C5 GETMET R15 R15 K4 - 0x7C3C0200, // 00C6 CALL R15 1 - 0x7C2C0800, // 00C7 CALL R11 4 - 0x58300011, // 00C8 LDCONST R12 K17 - 0x7C240600, // 00C9 CALL R9 3 - 0x8C240B19, // 00CA GETMET R9 R5 K25 - 0x7C240200, // 00CB CALL R9 1 - 0xB8260200, // 00CC GETNGBL R9 K1 - 0x8C241302, // 00CD GETMET R9 R9 K2 - 0x602C0008, // 00CE GETGBL R11 G8 - 0x88300B30, // 00CF GETMBR R12 R5 K48 - 0x7C2C0200, // 00D0 CALL R11 1 - 0x002E5E0B, // 00D1 ADD R11 K47 R11 - 0x002C1731, // 00D2 ADD R11 R11 K49 - 0x60300008, // 00D3 GETGBL R12 G8 - 0x88340B1C, // 00D4 GETMBR R13 R5 K28 - 0x7C300200, // 00D5 CALL R12 1 - 0x002C160C, // 00D6 ADD R11 R11 R12 - 0x002C1732, // 00D7 ADD R11 R11 K50 - 0x60300008, // 00D8 GETGBL R12 G8 - 0x88340B33, // 00D9 GETMBR R13 R5 K51 - 0x7C300200, // 00DA CALL R12 1 - 0x002C160C, // 00DB ADD R11 R11 R12 - 0x58300011, // 00DC LDCONST R12 K17 - 0x7C240600, // 00DD CALL R9 3 - 0x8824010B, // 00DE GETMBR R9 R0 K11 - 0x8C24131A, // 00DF GETMET R9 R9 K26 - 0x882C0B1B, // 00E0 GETMBR R11 R5 K27 - 0x7C240400, // 00E1 CALL R9 2 - 0x88240B30, // 00E2 GETMBR R9 R5 K48 - 0x1C281309, // 00E3 EQ R10 R9 K9 - 0x782A000C, // 00E4 JMPF R10 #00F2 - 0xB82A0200, // 00E5 GETNGBL R10 K1 - 0x8C281502, // 00E6 GETMET R10 R10 K2 - 0xB8320A00, // 00E7 GETNGBL R12 K5 - 0x8C301927, // 00E8 GETMET R12 R12 K39 - 0x5C380A00, // 00E9 MOVE R14 R5 - 0x7C300400, // 00EA CALL R12 2 - 0x0032680C, // 00EB ADD R12 K52 R12 - 0x58340011, // 00EC LDCONST R13 K17 - 0x7C280600, // 00ED CALL R10 3 - 0x50280200, // 00EE LDBOOL R10 1 0 - 0xA8040001, // 00EF EXBLK 1 1 - 0x80041400, // 00F0 RET 1 R10 - 0x70020015, // 00F1 JMP #0108 - 0x1C28132D, // 00F2 EQ R10 R9 K45 - 0x782A0008, // 00F3 JMPF R10 #00FD - 0x88280135, // 00F4 GETMBR R10 R0 K53 - 0x8C281522, // 00F5 GETMET R10 R10 K34 - 0x5C300A00, // 00F6 MOVE R12 R5 - 0x5C340400, // 00F7 MOVE R13 R2 - 0x5C380600, // 00F8 MOVE R14 R3 - 0x7C280800, // 00F9 CALL R10 4 - 0xA8040001, // 00FA EXBLK 1 1 - 0x80041400, // 00FB RET 1 R10 - 0x7002000A, // 00FC JMP #0108 - 0xB82A0200, // 00FD GETNGBL R10 K1 - 0x8C281502, // 00FE GETMET R10 R10 K2 - 0x60300008, // 00FF GETGBL R12 G8 - 0x5C341200, // 0100 MOVE R13 R9 - 0x7C300200, // 0101 CALL R12 1 - 0x00326C0C, // 0102 ADD R12 K54 R12 - 0x58340011, // 0103 LDCONST R13 K17 - 0x7C280600, // 0104 CALL R10 3 - 0x50280000, // 0105 LDBOOL R10 0 0 - 0xA8040001, // 0106 EXBLK 1 1 - 0x80041400, // 0107 RET 1 R10 - 0x501C0200, // 0108 LDBOOL R7 1 0 - 0xA8040001, // 0109 EXBLK 1 1 - 0x80040E00, // 010A RET 1 R7 - 0xA8040001, // 010B EXBLK 1 1 - 0x70020014, // 010C JMP #0122 - 0xAC140002, // 010D CATCH R5 0 2 - 0x70020011, // 010E JMP #0121 - 0xB81E0200, // 010F GETNGBL R7 K1 - 0x8C1C0F02, // 0110 GETMET R7 R7 K2 - 0x60240008, // 0111 GETGBL R9 G8 - 0x5C280A00, // 0112 MOVE R10 R5 - 0x7C240200, // 0113 CALL R9 1 - 0x00266E09, // 0114 ADD R9 K55 R9 - 0x00241338, // 0115 ADD R9 R9 K56 - 0x60280008, // 0116 GETGBL R10 G8 - 0x5C2C0C00, // 0117 MOVE R11 R6 - 0x7C280200, // 0118 CALL R10 1 - 0x0024120A, // 0119 ADD R9 R9 R10 - 0x7C1C0400, // 011A CALL R7 2 - 0xA41E7200, // 011B IMPORT R7 K57 - 0x8C200F3A, // 011C GETMET R8 R7 K58 - 0x7C200200, // 011D CALL R8 1 - 0x50200000, // 011E LDBOOL R8 0 0 - 0x80041000, // 011F RET 1 R8 - 0x70020000, // 0120 JMP #0122 - 0xB0080000, // 0121 RAISE 2 R0 R0 - 0x80000000, // 0122 RET 0 + 0x50140000, // 0001 LDBOOL R5 0 0 + 0xA802011F, // 0002 EXBLK 0 #0123 + 0xB81A0200, // 0003 GETNGBL R6 K1 + 0x8C180D02, // 0004 GETMET R6 R6 K2 + 0x8C200304, // 0005 GETMET R8 R1 K4 + 0x7C200200, // 0006 CALL R8 1 + 0x00220608, // 0007 ADD R8 K3 R8 + 0x54260003, // 0008 LDINT R9 4 + 0x7C180600, // 0009 CALL R6 3 + 0xB81A0A00, // 000A GETNGBL R6 K5 + 0x8C180D06, // 000B GETMET R6 R6 K6 + 0x5C200000, // 000C MOVE R8 R0 + 0x5C240200, // 000D MOVE R9 R1 + 0x5C280400, // 000E MOVE R10 R2 + 0x5C2C0600, // 000F MOVE R11 R3 + 0x7C180A00, // 0010 CALL R6 5 + 0x8C1C0D07, // 0011 GETMET R7 R6 K7 + 0x7C1C0200, // 0012 CALL R7 1 + 0x5C200E00, // 0013 MOVE R8 R7 + 0x74220002, // 0014 JMPT R8 #0018 + 0x50200000, // 0015 LDBOOL R8 0 0 + 0xA8040001, // 0016 EXBLK 1 1 + 0x80041000, // 0017 RET 1 R8 + 0x88200D08, // 0018 GETMBR R8 R6 K8 + 0x1C201109, // 0019 EQ R8 R8 K9 + 0x7822005B, // 001A JMPF R8 #0077 + 0x88200D0A, // 001B GETMBR R8 R6 K10 + 0x1C201109, // 001C EQ R8 R8 K9 + 0x78220058, // 001D JMPF R8 #0077 + 0x8820010B, // 001E GETMBR R8 R0 K11 + 0x8820110C, // 001F GETMBR R8 R8 K12 + 0x8C20110D, // 0020 GETMET R8 R8 K13 + 0x88280D0E, // 0021 GETMBR R10 R6 K14 + 0x542E0059, // 0022 LDINT R11 90 + 0x7C200600, // 0023 CALL R8 3 + 0xB8260200, // 0024 GETNGBL R9 K1 + 0x8C241302, // 0025 GETMET R9 R9 K2 + 0x602C0008, // 0026 GETGBL R11 G8 + 0x88300D0E, // 0027 GETMBR R12 R6 K14 + 0x7C2C0200, // 0028 CALL R11 1 + 0x002E1E0B, // 0029 ADD R11 K15 R11 + 0x002C1710, // 002A ADD R11 R11 K16 + 0x60300008, // 002B GETGBL R12 G8 + 0x88341108, // 002C GETMBR R13 R8 K8 + 0x7C300200, // 002D CALL R12 1 + 0x002C160C, // 002E ADD R11 R11 R12 + 0x58300011, // 002F LDCONST R12 K17 + 0x7C240600, // 0030 CALL R9 3 + 0x780A0000, // 0031 JMPF R2 #0033 + 0x90222402, // 0032 SETMBR R8 K18 R2 + 0x780E0000, // 0033 JMPF R3 #0035 + 0x90222603, // 0034 SETMBR R8 K19 R3 + 0x901A2808, // 0035 SETMBR R6 K20 R8 + 0x88240115, // 0036 GETMBR R9 R0 K21 + 0x8C241316, // 0037 GETMET R9 R9 K22 + 0x882C0D17, // 0038 GETMBR R11 R6 K23 + 0x50300000, // 0039 LDBOOL R12 0 0 + 0x7C240600, // 003A CALL R9 3 + 0x7426000D, // 003B JMPT R9 #004A + 0xB8260200, // 003C GETNGBL R9 K1 + 0x8C241302, // 003D GETMET R9 R9 K2 + 0x8C2C0918, // 003E GETMET R11 R4 K24 + 0x58340019, // 003F LDCONST R13 K25 + 0x88380D17, // 0040 GETMBR R14 R6 K23 + 0x883C0115, // 0041 GETMBR R15 R0 K21 + 0x8C3C1F1A, // 0042 GETMET R15 R15 K26 + 0x7C3C0200, // 0043 CALL R15 1 + 0x7C2C0800, // 0044 CALL R11 4 + 0x58300011, // 0045 LDCONST R12 K17 + 0x7C240600, // 0046 CALL R9 3 + 0x50240000, // 0047 LDBOOL R9 0 0 + 0xA8040001, // 0048 EXBLK 1 1 + 0x80041200, // 0049 RET 1 R9 + 0x8C240D1B, // 004A GETMET R9 R6 K27 + 0x7C240200, // 004B CALL R9 1 + 0x74260002, // 004C JMPT R9 #0050 + 0x50240000, // 004D LDBOOL R9 0 0 + 0xA8040001, // 004E EXBLK 1 1 + 0x80041200, // 004F RET 1 R9 + 0x8824010B, // 0050 GETMBR R9 R0 K11 + 0x8C24131C, // 0051 GETMET R9 R9 K28 + 0x882C0D1D, // 0052 GETMBR R11 R6 K29 + 0x7C240400, // 0053 CALL R9 2 + 0x88240D1E, // 0054 GETMBR R9 R6 K30 + 0x542A000F, // 0055 LDINT R10 16 + 0x2024120A, // 0056 NE R9 R9 R10 + 0x78260014, // 0057 JMPF R9 #006D + 0xB8260A00, // 0058 GETNGBL R9 K5 + 0x8C24131F, // 0059 GETMET R9 R9 K31 + 0x882C0D1E, // 005A GETMBR R11 R6 K30 + 0x7C240400, // 005B CALL R9 2 + 0x5C281200, // 005C MOVE R10 R9 + 0x742A0004, // 005D JMPT R10 #0063 + 0x8C280918, // 005E GETMET R10 R4 K24 + 0x58300020, // 005F LDCONST R12 K32 + 0x88340D1E, // 0060 GETMBR R13 R6 K30 + 0x7C280600, // 0061 CALL R10 3 + 0x5C241400, // 0062 MOVE R9 R10 + 0xB82A0200, // 0063 GETNGBL R10 K1 + 0x8C281502, // 0064 GETMET R10 R10 K2 + 0x8C300918, // 0065 GETMET R12 R4 K24 + 0x58380021, // 0066 LDCONST R14 K33 + 0x5C3C1200, // 0067 MOVE R15 R9 + 0x5C400400, // 0068 MOVE R16 R2 + 0x5C440600, // 0069 MOVE R17 R3 + 0x7C300A00, // 006A CALL R12 5 + 0x58340022, // 006B LDCONST R13 K34 + 0x7C280600, // 006C CALL R10 3 + 0x88240123, // 006D GETMBR R9 R0 K35 + 0x8C241324, // 006E GETMET R9 R9 K36 + 0x5C2C0C00, // 006F MOVE R11 R6 + 0x5C300400, // 0070 MOVE R12 R2 + 0x5C340600, // 0071 MOVE R13 R3 + 0x7C240800, // 0072 CALL R9 4 + 0x50240200, // 0073 LDBOOL R9 1 0 + 0xA8040001, // 0074 EXBLK 1 1 + 0x80041200, // 0075 RET 1 R9 + 0x700200A7, // 0076 JMP #011F + 0xB8220200, // 0077 GETNGBL R8 K1 + 0x8C201102, // 0078 GETMET R8 R8 K2 + 0x8C280918, // 0079 GETMET R10 R4 K24 + 0x58300025, // 007A LDCONST R12 K37 + 0x88340D08, // 007B GETMBR R13 R6 K8 + 0x88380D17, // 007C GETMBR R14 R6 K23 + 0x7C280800, // 007D CALL R10 4 + 0x582C0011, // 007E LDCONST R11 K17 + 0x7C200600, // 007F CALL R8 3 + 0x8820010B, // 0080 GETMBR R8 R0 K11 + 0x8820110C, // 0081 GETMBR R8 R8 K12 + 0x8C201126, // 0082 GETMET R8 R8 K38 + 0x88280D08, // 0083 GETMBR R10 R6 K8 + 0x7C200400, // 0084 CALL R8 2 + 0x4C240000, // 0085 LDNIL R9 + 0x1C241009, // 0086 EQ R9 R8 R9 + 0x78260013, // 0087 JMPF R9 #009C + 0xB8260200, // 0088 GETNGBL R9 K1 + 0x8C241302, // 0089 GETMET R9 R9 K2 + 0x602C0008, // 008A GETGBL R11 G8 + 0x88300D08, // 008B GETMBR R12 R6 K8 + 0x7C2C0200, // 008C CALL R11 1 + 0x002E4E0B, // 008D ADD R11 K39 R11 + 0x58300011, // 008E LDCONST R12 K17 + 0x7C240600, // 008F CALL R9 3 + 0xB8260200, // 0090 GETNGBL R9 K1 + 0x8C241302, // 0091 GETMET R9 R9 K2 + 0xB82E0A00, // 0092 GETNGBL R11 K5 + 0x8C2C1729, // 0093 GETMET R11 R11 K41 + 0x5C340C00, // 0094 MOVE R13 R6 + 0x7C2C0400, // 0095 CALL R11 2 + 0x002E500B, // 0096 ADD R11 K40 R11 + 0x58300011, // 0097 LDCONST R12 K17 + 0x7C240600, // 0098 CALL R9 3 + 0x50240000, // 0099 LDBOOL R9 0 0 + 0xA8040001, // 009A EXBLK 1 1 + 0x80041200, // 009B RET 1 R9 + 0x780A0000, // 009C JMPF R2 #009E + 0x90222402, // 009D SETMBR R8 K18 R2 + 0x780E0000, // 009E JMPF R3 #00A0 + 0x90222603, // 009F SETMBR R8 K19 R3 + 0x901A2808, // 00A0 SETMBR R6 K20 R8 + 0x88241115, // 00A1 GETMBR R9 R8 K21 + 0x8C241316, // 00A2 GETMET R9 R9 K22 + 0x882C0D17, // 00A3 GETMBR R11 R6 K23 + 0x50300200, // 00A4 LDBOOL R12 1 0 + 0x7C240600, // 00A5 CALL R9 3 + 0x74260011, // 00A6 JMPT R9 #00B9 + 0xB8260200, // 00A7 GETNGBL R9 K1 + 0x8C241302, // 00A8 GETMET R9 R9 K2 + 0x602C0008, // 00A9 GETGBL R11 G8 + 0x88300D17, // 00AA GETMBR R12 R6 K23 + 0x7C2C0200, // 00AB CALL R11 1 + 0x002E540B, // 00AC ADD R11 K42 R11 + 0x002C172B, // 00AD ADD R11 R11 K43 + 0x60300008, // 00AE GETGBL R12 G8 + 0x88341115, // 00AF GETMBR R13 R8 K21 + 0x8C341B1A, // 00B0 GETMET R13 R13 K26 + 0x7C340200, // 00B1 CALL R13 1 + 0x7C300200, // 00B2 CALL R12 1 + 0x002C160C, // 00B3 ADD R11 R11 R12 + 0x58300011, // 00B4 LDCONST R12 K17 + 0x7C240600, // 00B5 CALL R9 3 + 0x50240000, // 00B6 LDBOOL R9 0 0 + 0xA8040001, // 00B7 EXBLK 1 1 + 0x80041200, // 00B8 RET 1 R9 + 0x8C240D2C, // 00B9 GETMET R9 R6 K44 + 0x7C240200, // 00BA CALL R9 1 + 0x5C281200, // 00BB MOVE R10 R9 + 0x742A0002, // 00BC JMPT R10 #00C0 + 0x50280000, // 00BD LDBOOL R10 0 0 + 0xA8040001, // 00BE EXBLK 1 1 + 0x80041400, // 00BF RET 1 R10 + 0x88280D2E, // 00C0 GETMBR R10 R6 K46 + 0x0428152F, // 00C1 SUB R10 R10 K47 + 0x402A120A, // 00C2 CONNECT R10 K9 R10 + 0x882C0D2D, // 00C3 GETMBR R11 R6 K45 + 0x9428160A, // 00C4 GETIDX R10 R11 R10 + 0x901A5A0A, // 00C5 SETMBR R6 K45 R10 + 0x88280D2D, // 00C6 GETMBR R10 R6 K45 + 0x40281409, // 00C7 CONNECT R10 R10 R9 + 0xB82A0200, // 00C8 GETNGBL R10 K1 + 0x8C281502, // 00C9 GETMET R10 R10 K2 + 0x8C300918, // 00CA GETMET R12 R4 K24 + 0x58380030, // 00CB LDCONST R14 K48 + 0x883C0D2E, // 00CC GETMBR R15 R6 K46 + 0x88400D2D, // 00CD GETMBR R16 R6 K45 + 0x8C402104, // 00CE GETMET R16 R16 K4 + 0x7C400200, // 00CF CALL R16 1 + 0x7C300800, // 00D0 CALL R12 4 + 0x58340011, // 00D1 LDCONST R13 K17 + 0x7C280600, // 00D2 CALL R10 3 + 0x8C280D1B, // 00D3 GETMET R10 R6 K27 + 0x7C280200, // 00D4 CALL R10 1 + 0xB82A0200, // 00D5 GETNGBL R10 K1 + 0x8C281502, // 00D6 GETMET R10 R10 K2 + 0x60300008, // 00D7 GETGBL R12 G8 + 0x88340D32, // 00D8 GETMBR R13 R6 K50 + 0x7C300200, // 00D9 CALL R12 1 + 0x0032620C, // 00DA ADD R12 K49 R12 + 0x00301933, // 00DB ADD R12 R12 K51 + 0x60340008, // 00DC GETGBL R13 G8 + 0x88380D1E, // 00DD GETMBR R14 R6 K30 + 0x7C340200, // 00DE CALL R13 1 + 0x0030180D, // 00DF ADD R12 R12 R13 + 0x00301934, // 00E0 ADD R12 R12 K52 + 0x60340008, // 00E1 GETGBL R13 G8 + 0x88380D35, // 00E2 GETMBR R14 R6 K53 + 0x7C340200, // 00E3 CALL R13 1 + 0x0030180D, // 00E4 ADD R12 R12 R13 + 0x58340011, // 00E5 LDCONST R13 K17 + 0x7C280600, // 00E6 CALL R10 3 + 0x8828010B, // 00E7 GETMBR R10 R0 K11 + 0x8C28151C, // 00E8 GETMET R10 R10 K28 + 0x88300D1D, // 00E9 GETMBR R12 R6 K29 + 0x7C280400, // 00EA CALL R10 2 + 0x88280D32, // 00EB GETMBR R10 R6 K50 + 0x1C2C1509, // 00EC EQ R11 R10 K9 + 0x782E000A, // 00ED JMPF R11 #00F9 + 0xB82E0200, // 00EE GETNGBL R11 K1 + 0x8C2C1702, // 00EF GETMET R11 R11 K2 + 0xB8360A00, // 00F0 GETNGBL R13 K5 + 0x8C341B29, // 00F1 GETMET R13 R13 K41 + 0x5C3C0C00, // 00F2 MOVE R15 R6 + 0x7C340400, // 00F3 CALL R13 2 + 0x00366C0D, // 00F4 ADD R13 K54 R13 + 0x58380011, // 00F5 LDCONST R14 K17 + 0x7C2C0600, // 00F6 CALL R11 3 + 0x50140200, // 00F7 LDBOOL R5 1 0 + 0x70020025, // 00F8 JMP #011F + 0x1C2C152F, // 00F9 EQ R11 R10 K47 + 0x782E001B, // 00FA JMPF R11 #0117 + 0x882C0137, // 00FB GETMBR R11 R0 K55 + 0x8C2C1724, // 00FC GETMET R11 R11 K36 + 0x5C340C00, // 00FD MOVE R13 R6 + 0x5C380400, // 00FE MOVE R14 R2 + 0x5C3C0600, // 00FF MOVE R15 R3 + 0x7C2C0800, // 0100 CALL R11 4 + 0x5C141600, // 0101 MOVE R5 R11 + 0x78160004, // 0102 JMPF R5 #0108 + 0x882C0137, // 0103 GETMBR R11 R0 K55 + 0x8C2C1738, // 0104 GETMET R11 R11 K56 + 0x5C340000, // 0105 MOVE R13 R0 + 0x7C2C0400, // 0106 CALL R11 2 + 0x7002000D, // 0107 JMP #0116 + 0x882C0D39, // 0108 GETMBR R11 R6 K57 + 0x782E000B, // 0109 JMPF R11 #0116 + 0x8C2C0D3A, // 010A GETMET R11 R6 K58 + 0x7C2C0200, // 010B CALL R11 1 + 0x8C30173B, // 010C GETMET R12 R11 K59 + 0x7C300200, // 010D CALL R12 1 + 0x8C30173C, // 010E GETMET R12 R11 K60 + 0x7C300200, // 010F CALL R12 1 + 0x8C30013D, // 0110 GETMET R12 R0 K61 + 0x8838172D, // 0111 GETMBR R14 R11 K45 + 0x883C173E, // 0112 GETMBR R15 R11 K62 + 0x8840173F, // 0113 GETMBR R16 R11 K63 + 0x88441717, // 0114 GETMBR R17 R11 K23 + 0x7C300A00, // 0115 CALL R12 5 + 0x70020007, // 0116 JMP #011F + 0xB82E0200, // 0117 GETNGBL R11 K1 + 0x8C2C1702, // 0118 GETMET R11 R11 K2 + 0x60340008, // 0119 GETGBL R13 G8 + 0x5C381400, // 011A MOVE R14 R10 + 0x7C340200, // 011B CALL R13 1 + 0x0036800D, // 011C ADD R13 K64 R13 + 0x58380011, // 011D LDCONST R14 K17 + 0x7C2C0600, // 011E CALL R11 3 + 0xA8040001, // 011F EXBLK 1 1 + 0x80040A00, // 0120 RET 1 R5 + 0xA8040001, // 0121 EXBLK 1 1 + 0x70020014, // 0122 JMP #0138 + 0xAC180002, // 0123 CATCH R6 0 2 + 0x70020011, // 0124 JMP #0137 + 0xB8220200, // 0125 GETNGBL R8 K1 + 0x8C201102, // 0126 GETMET R8 R8 K2 + 0x60280008, // 0127 GETGBL R10 G8 + 0x5C2C0C00, // 0128 MOVE R11 R6 + 0x7C280200, // 0129 CALL R10 1 + 0x002A820A, // 012A ADD R10 K65 R10 + 0x00281542, // 012B ADD R10 R10 K66 + 0x602C0008, // 012C GETGBL R11 G8 + 0x5C300E00, // 012D MOVE R12 R7 + 0x7C2C0200, // 012E CALL R11 1 + 0x0028140B, // 012F ADD R10 R10 R11 + 0x7C200400, // 0130 CALL R8 2 + 0xA4228600, // 0131 IMPORT R8 K67 + 0x8C241144, // 0132 GETMET R9 R8 K68 + 0x7C240200, // 0133 CALL R9 1 + 0x50240000, // 0134 LDBOOL R9 0 0 + 0x80041200, // 0135 RET 1 R9 + 0x70020000, // 0136 JMP #0138 + 0xB0080000, // 0137 RAISE 2 R0 R0 + 0x80000000, // 0138 RET 0 }) ) ); @@ -476,7 +508,7 @@ be_local_closure(Matter_MessageHandler_add_session, /* name */ ********************************************************************/ be_local_closure(Matter_MessageHandler_init, /* name */ be_nested_proto( - 6, /* nstack */ + 5, /* nstack */ 2, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -496,7 +528,7 @@ be_local_closure(Matter_MessageHandler_init, /* name */ }), be_str_weak(init), &be_const_str_solidified, - ( &(const binstruction[17]) { /* code */ + ( &(const binstruction[16]) { /* code */ 0x90020001, // 0000 SETMBR R0 K0 R1 0xB80A0400, // 0001 GETNGBL R2 K2 0x8C080503, // 0002 GETMET R2 R2 K3 @@ -505,15 +537,14 @@ be_local_closure(Matter_MessageHandler_init, /* name */ 0x90020202, // 0005 SETMBR R0 K1 R2 0xB80A0400, // 0006 GETNGBL R2 K2 0x8C080505, // 0007 GETMET R2 R2 K5 - 0x5C100000, // 0008 MOVE R4 R0 - 0x5C140200, // 0009 MOVE R5 R1 - 0x7C080600, // 000A CALL R2 3 - 0x90020802, // 000B SETMBR R0 K4 R2 - 0xB80A0400, // 000C GETNGBL R2 K2 - 0x8C080507, // 000D GETMET R2 R2 K7 - 0x7C080200, // 000E CALL R2 1 - 0x90020C02, // 000F SETMBR R0 K6 R2 - 0x80000000, // 0010 RET 0 + 0x5C100200, // 0008 MOVE R4 R1 + 0x7C080400, // 0009 CALL R2 2 + 0x90020802, // 000A SETMBR R0 K4 R2 + 0xB80A0400, // 000B GETNGBL R2 K2 + 0x8C080507, // 000C GETMET R2 R2 K7 + 0x7C080200, // 000D CALL R2 1 + 0x90020C02, // 000E SETMBR R0 K6 R2 + 0x80000000, // 000F RET 0 }) ) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin.h index 8091439a8..93432fe41 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin.h @@ -321,8 +321,8 @@ be_local_closure(Matter_Plugin_get_endpoints, /* name */ ********************************************************************/ be_local_closure(Matter_Plugin_write_attribute, /* name */ be_nested_proto( - 6, /* nstack */ - 5, /* argc */ + 5, /* nstack */ + 4, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -333,8 +333,8 @@ be_local_closure(Matter_Plugin_write_attribute, /* name */ be_str_weak(write_attribute), &be_const_str_solidified, ( &(const binstruction[ 2]) { /* code */ - 0x4C140000, // 0000 LDNIL R5 - 0x80040A00, // 0001 RET 1 R5 + 0x4C100000, // 0000 LDNIL R4 + 0x80040800, // 0001 RET 1 R4 }) ) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_OnOff.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_OnOff.h new file mode 100644 index 000000000..a21dbe805 --- /dev/null +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_OnOff.h @@ -0,0 +1,389 @@ +/* Solidification of Matter_Plugin_OnOff.h */ +/********************************************************************\ +* Generated code, don't edit * +\********************************************************************/ +#include "be_constobj.h" + +extern const bclass be_class_Matter_Plugin_OnOff; + +/******************************************************************** +** Solidified function: invoke_request +********************************************************************/ +be_local_closure(Matter_Plugin_OnOff_invoke_request, /* name */ + be_nested_proto( + 14, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[13]) { /* constants */ + /* K0 */ be_nested_str_weak(matter), + /* K1 */ be_nested_str_weak(TLV), + /* K2 */ be_nested_str_weak(cluster), + /* K3 */ be_nested_str_weak(command), + /* K4 */ be_nested_str_weak(session), + /* K5 */ be_const_int(3), + /* K6 */ be_const_int(0), + /* K7 */ be_const_int(1), + /* K8 */ be_nested_str_weak(Matter_TLV_struct), + /* K9 */ be_nested_str_weak(add_TLV), + /* K10 */ be_nested_str_weak(U2), + /* K11 */ be_nested_str_weak(onoff), + /* K12 */ be_const_int(2), + }), + be_str_weak(invoke_request), + &be_const_str_solidified, + ( &(const binstruction[69]) { /* code */ + 0xB8120000, // 0000 GETNGBL R4 K0 + 0x88100901, // 0001 GETMBR R4 R4 K1 + 0x88140702, // 0002 GETMBR R5 R3 K2 + 0x88180703, // 0003 GETMBR R6 R3 K3 + 0x881C0304, // 0004 GETMBR R7 R1 K4 + 0x1C200B05, // 0005 EQ R8 R5 K5 + 0x78220016, // 0006 JMPF R8 #001E + 0x1C200D06, // 0007 EQ R8 R6 K6 + 0x78220002, // 0008 JMPF R8 #000C + 0x50200200, // 0009 LDBOOL R8 1 0 + 0x80041000, // 000A RET 1 R8 + 0x70020010, // 000B JMP #001D + 0x1C200D07, // 000C EQ R8 R6 K7 + 0x78220009, // 000D JMPF R8 #0018 + 0x8C200908, // 000E GETMET R8 R4 K8 + 0x7C200200, // 000F CALL R8 1 + 0x8C241109, // 0010 GETMET R9 R8 K9 + 0x582C0006, // 0011 LDCONST R11 K6 + 0x8830090A, // 0012 GETMBR R12 R4 K10 + 0x58340006, // 0013 LDCONST R13 K6 + 0x7C240800, // 0014 CALL R9 4 + 0x900E0706, // 0015 SETMBR R3 K3 K6 + 0x80041000, // 0016 RET 1 R8 + 0x70020004, // 0017 JMP #001D + 0x5422003F, // 0018 LDINT R8 64 + 0x1C200C08, // 0019 EQ R8 R6 R8 + 0x78220001, // 001A JMPF R8 #001D + 0x50200200, // 001B LDBOOL R8 1 0 + 0x80041000, // 001C RET 1 R8 + 0x70020025, // 001D JMP #0044 + 0x54220003, // 001E LDINT R8 4 + 0x1C200A08, // 001F EQ R8 R5 R8 + 0x78220002, // 0020 JMPF R8 #0024 + 0x50200200, // 0021 LDBOOL R8 1 0 + 0x80041000, // 0022 RET 1 R8 + 0x7002001F, // 0023 JMP #0044 + 0x54220004, // 0024 LDINT R8 5 + 0x1C200A08, // 0025 EQ R8 R5 R8 + 0x78220002, // 0026 JMPF R8 #002A + 0x50200200, // 0027 LDBOOL R8 1 0 + 0x80041000, // 0028 RET 1 R8 + 0x70020019, // 0029 JMP #0044 + 0x54220005, // 002A LDINT R8 6 + 0x1C200A08, // 002B EQ R8 R5 R8 + 0x78220016, // 002C JMPF R8 #0044 + 0x1C200D06, // 002D EQ R8 R6 K6 + 0x78220004, // 002E JMPF R8 #0034 + 0x50200000, // 002F LDBOOL R8 0 0 + 0x90021608, // 0030 SETMBR R0 K11 R8 + 0x50200200, // 0031 LDBOOL R8 1 0 + 0x80041000, // 0032 RET 1 R8 + 0x7002000F, // 0033 JMP #0044 + 0x1C200D07, // 0034 EQ R8 R6 K7 + 0x78220004, // 0035 JMPF R8 #003B + 0x50200200, // 0036 LDBOOL R8 1 0 + 0x90021608, // 0037 SETMBR R0 K11 R8 + 0x50200200, // 0038 LDBOOL R8 1 0 + 0x80041000, // 0039 RET 1 R8 + 0x70020008, // 003A JMP #0044 + 0x1C200D0C, // 003B EQ R8 R6 K12 + 0x78220006, // 003C JMPF R8 #0044 + 0x8820010B, // 003D GETMBR R8 R0 K11 + 0x78220000, // 003E JMPF R8 #0040 + 0x50200001, // 003F LDBOOL R8 0 1 + 0x50200200, // 0040 LDBOOL R8 1 0 + 0x90021608, // 0041 SETMBR R0 K11 R8 + 0x50200200, // 0042 LDBOOL R8 1 0 + 0x80041000, // 0043 RET 1 R8 + 0x80000000, // 0044 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_Plugin_OnOff_init, /* name */ + be_nested_proto( + 5, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 6]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(endpoints), + /* K2 */ be_nested_str_weak(ENDPOINTS), + /* K3 */ be_nested_str_weak(clusters), + /* K4 */ be_nested_str_weak(CLUSTERS), + /* K5 */ be_nested_str_weak(onoff), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[13]) { /* 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 + 0x88080102, // 0006 GETMBR R2 R0 K2 + 0x90020202, // 0007 SETMBR R0 K1 R2 + 0x88080104, // 0008 GETMBR R2 R0 K4 + 0x90020602, // 0009 SETMBR R0 K3 R2 + 0x50080000, // 000A LDBOOL R2 0 0 + 0x90020A02, // 000B SETMBR R0 K5 R2 + 0x80000000, // 000C RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: read_attribute +********************************************************************/ +be_local_closure(Matter_Plugin_OnOff_read_attribute, /* name */ + be_nested_proto( + 16, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[21]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(TLV), + /* K3 */ be_nested_str_weak(cluster), + /* K4 */ be_nested_str_weak(attribute), + /* K5 */ be_const_int(0), + /* K6 */ be_nested_str_weak(Matter_TLV_array), + /* K7 */ be_nested_str_weak(TYPES), + /* K8 */ be_nested_str_weak(add_struct), + /* K9 */ be_nested_str_weak(add_TLV), + /* K10 */ be_nested_str_weak(U2), + /* K11 */ be_const_int(1), + /* K12 */ be_nested_str_weak(stop_iteration), + /* K13 */ be_nested_str_weak(get_cluster_list), + /* K14 */ be_nested_str_weak(U4), + /* K15 */ be_const_int(2), + /* K16 */ be_const_int(3), + /* K17 */ be_nested_str_weak(create_TLV), + /* K18 */ be_nested_str_weak(U1), + /* K19 */ be_nested_str_weak(BOOL), + /* K20 */ be_nested_str_weak(onoff), + }), + be_str_weak(read_attribute), + &be_const_str_solidified, + ( &(const binstruction[113]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0xB8120200, // 0001 GETNGBL R4 K1 + 0x88100902, // 0002 GETMBR R4 R4 K2 + 0x88140503, // 0003 GETMBR R5 R2 K3 + 0x88180504, // 0004 GETMBR R6 R2 K4 + 0x541E001C, // 0005 LDINT R7 29 + 0x1C1C0A07, // 0006 EQ R7 R5 R7 + 0x781E0042, // 0007 JMPF R7 #004B + 0x1C1C0D05, // 0008 EQ R7 R6 K5 + 0x781E0019, // 0009 JMPF R7 #0024 + 0x8C1C0906, // 000A GETMET R7 R4 K6 + 0x7C1C0200, // 000B CALL R7 1 + 0x60200010, // 000C GETGBL R8 G16 + 0x88240107, // 000D GETMBR R9 R0 K7 + 0x7C200200, // 000E CALL R8 1 + 0xA802000E, // 000F EXBLK 0 #001F + 0x5C241000, // 0010 MOVE R9 R8 + 0x7C240000, // 0011 CALL R9 0 + 0x8C280F08, // 0012 GETMET R10 R7 K8 + 0x7C280200, // 0013 CALL R10 1 + 0x8C2C1509, // 0014 GETMET R11 R10 K9 + 0x58340005, // 0015 LDCONST R13 K5 + 0x8838090A, // 0016 GETMBR R14 R4 K10 + 0x5C3C1200, // 0017 MOVE R15 R9 + 0x7C2C0800, // 0018 CALL R11 4 + 0x8C2C1509, // 0019 GETMET R11 R10 K9 + 0x5834000B, // 001A LDCONST R13 K11 + 0x8838090A, // 001B GETMBR R14 R4 K10 + 0x583C000B, // 001C LDCONST R15 K11 + 0x7C2C0800, // 001D CALL R11 4 + 0x7001FFF0, // 001E JMP #0010 + 0x5820000C, // 001F LDCONST R8 K12 + 0xAC200200, // 0020 CATCH R8 1 0 + 0xB0080000, // 0021 RAISE 2 R0 R0 + 0x80040E00, // 0022 RET 1 R7 + 0x70020025, // 0023 JMP #004A + 0x1C1C0D0B, // 0024 EQ R7 R6 K11 + 0x781E0013, // 0025 JMPF R7 #003A + 0x8C1C0906, // 0026 GETMET R7 R4 K6 + 0x7C1C0200, // 0027 CALL R7 1 + 0x60200010, // 0028 GETGBL R8 G16 + 0x8C24010D, // 0029 GETMET R9 R0 K13 + 0x7C240200, // 002A CALL R9 1 + 0x7C200200, // 002B CALL R8 1 + 0xA8020007, // 002C EXBLK 0 #0035 + 0x5C241000, // 002D MOVE R9 R8 + 0x7C240000, // 002E CALL R9 0 + 0x8C280F09, // 002F GETMET R10 R7 K9 + 0x4C300000, // 0030 LDNIL R12 + 0x8834090E, // 0031 GETMBR R13 R4 K14 + 0x5C381200, // 0032 MOVE R14 R9 + 0x7C280800, // 0033 CALL R10 4 + 0x7001FFF7, // 0034 JMP #002D + 0x5820000C, // 0035 LDCONST R8 K12 + 0xAC200200, // 0036 CATCH R8 1 0 + 0xB0080000, // 0037 RAISE 2 R0 R0 + 0x80040E00, // 0038 RET 1 R7 + 0x7002000F, // 0039 JMP #004A + 0x1C1C0D0F, // 003A EQ R7 R6 K15 + 0x781E0008, // 003B JMPF R7 #0045 + 0x8C1C0906, // 003C GETMET R7 R4 K6 + 0x7C1C0200, // 003D CALL R7 1 + 0x8C200F09, // 003E GETMET R8 R7 K9 + 0x4C280000, // 003F LDNIL R10 + 0x882C090A, // 0040 GETMBR R11 R4 K10 + 0x54320005, // 0041 LDINT R12 6 + 0x7C200800, // 0042 CALL R8 4 + 0x80040E00, // 0043 RET 1 R7 + 0x70020004, // 0044 JMP #004A + 0x1C1C0D10, // 0045 EQ R7 R6 K16 + 0x781E0002, // 0046 JMPF R7 #004A + 0x8C1C0906, // 0047 GETMET R7 R4 K6 + 0x7C1C0200, // 0048 CALL R7 1 + 0x80040E00, // 0049 RET 1 R7 + 0x70020024, // 004A JMP #0070 + 0x1C1C0B10, // 004B EQ R7 R5 K16 + 0x781E000F, // 004C JMPF R7 #005D + 0x1C1C0D05, // 004D EQ R7 R6 K5 + 0x781E0005, // 004E JMPF R7 #0055 + 0x8C1C0911, // 004F GETMET R7 R4 K17 + 0x8824090A, // 0050 GETMBR R9 R4 K10 + 0x58280005, // 0051 LDCONST R10 K5 + 0x7C1C0600, // 0052 CALL R7 3 + 0x80040E00, // 0053 RET 1 R7 + 0x70020006, // 0054 JMP #005C + 0x1C1C0D0B, // 0055 EQ R7 R6 K11 + 0x781E0004, // 0056 JMPF R7 #005C + 0x8C1C0911, // 0057 GETMET R7 R4 K17 + 0x88240912, // 0058 GETMBR R9 R4 K18 + 0x58280005, // 0059 LDCONST R10 K5 + 0x7C1C0600, // 005A CALL R7 3 + 0x80040E00, // 005B RET 1 R7 + 0x70020012, // 005C JMP #0070 + 0x541E0005, // 005D LDINT R7 6 + 0x1C1C0A07, // 005E EQ R7 R5 R7 + 0x781E000F, // 005F JMPF R7 #0070 + 0x1C1C0D05, // 0060 EQ R7 R6 K5 + 0x781E0005, // 0061 JMPF R7 #0068 + 0x8C1C0911, // 0062 GETMET R7 R4 K17 + 0x88240913, // 0063 GETMBR R9 R4 K19 + 0x88280114, // 0064 GETMBR R10 R0 K20 + 0x7C1C0600, // 0065 CALL R7 3 + 0x80040E00, // 0066 RET 1 R7 + 0x70020007, // 0067 JMP #0070 + 0x541EFFFB, // 0068 LDINT R7 65532 + 0x1C1C0C07, // 0069 EQ R7 R6 R7 + 0x781E0004, // 006A JMPF R7 #0070 + 0x8C1C0911, // 006B GETMET R7 R4 K17 + 0x8824090E, // 006C GETMBR R9 R4 K14 + 0x58280005, // 006D LDCONST R10 K5 + 0x7C1C0600, // 006E CALL R7 3 + 0x80040E00, // 006F RET 1 R7 + 0x80000000, // 0070 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified class: Matter_Plugin_OnOff +********************************************************************/ +extern const bclass be_class_Matter_Plugin; +be_local_class(Matter_Plugin_OnOff, + 1, + &be_class_Matter_Plugin, + be_nested_map(7, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(invoke_request, 1), be_const_closure(Matter_Plugin_OnOff_invoke_request_closure) }, + { be_const_key_weak(read_attribute, 4), be_const_closure(Matter_Plugin_OnOff_read_attribute_closure) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_OnOff_init_closure) }, + { be_const_key_weak(TYPES, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(1, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(256), + })) ) } )) }, + { be_const_key_weak(CLUSTERS, 6), 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_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(6, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(2), + be_const_int(3), + be_const_int(4), + be_const_int(5), + })) ) } )) }, + { be_const_key_int(6, -1), 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(0), + be_const_int(65532), + })) ) } )) }, + { be_const_key_int(29, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(4, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(2), + be_const_int(3), + })) ) } )) }, + { be_const_key_int(3, -1), 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(0), + be_const_int(1), + })) ) } )) }, + { be_const_key_int(4, 2), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(1, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + })) ) } )) }, + })) ) } )) }, + { be_const_key_weak(onoff, 2), be_const_var(0) }, + { be_const_key_weak(ENDPOINTS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(1, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(1), + })) ) } )) }, + })), + be_str_weak(Matter_Plugin_OnOff) +); +/*******************************************************************/ + +void be_load_Matter_Plugin_OnOff_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_Plugin_OnOff); + be_setglobal(vm, "Matter_Plugin_OnOff"); + be_pop(vm, 1); +} +/********************************************************************/ +/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Relay.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Relay.h deleted file mode 100644 index 8a68d6822..000000000 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Relay.h +++ /dev/null @@ -1,246 +0,0 @@ -/* Solidification of Matter_Plugin_Relay.h */ -/********************************************************************\ -* Generated code, don't edit * -\********************************************************************/ -#include "be_constobj.h" - -extern const bclass be_class_Matter_Plugin_Relay; - -/******************************************************************** -** Solidified function: read_attribute -********************************************************************/ -be_local_closure(Matter_Plugin_Relay_read_attribute, /* name */ - be_nested_proto( - 15, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[17]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(TLV), - /* K3 */ be_nested_str_weak(cluster), - /* K4 */ be_nested_str_weak(attribute), - /* K5 */ be_const_int(0), - /* K6 */ be_nested_str_weak(Matter_TLV_array), - /* K7 */ be_nested_str_weak(add_struct), - /* K8 */ be_nested_str_weak(add_TLV), - /* K9 */ be_nested_str_weak(U2), - /* K10 */ be_nested_str_weak(TYPES), - /* K11 */ be_const_int(1), - /* K12 */ be_nested_str_weak(get_cluster_list), - /* K13 */ be_nested_str_weak(U4), - /* K14 */ be_nested_str_weak(stop_iteration), - /* K15 */ be_const_int(2), - /* K16 */ be_const_int(3), - }), - be_str_weak(read_attribute), - &be_const_str_solidified, - ( &(const binstruction[66]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0xB8120200, // 0001 GETNGBL R4 K1 - 0x88100902, // 0002 GETMBR R4 R4 K2 - 0x88140503, // 0003 GETMBR R5 R2 K3 - 0x88180504, // 0004 GETMBR R6 R2 K4 - 0x541E001C, // 0005 LDINT R7 29 - 0x1C1C0A07, // 0006 EQ R7 R5 R7 - 0x781E0038, // 0007 JMPF R7 #0041 - 0x1C1C0D05, // 0008 EQ R7 R6 K5 - 0x781E0010, // 0009 JMPF R7 #001B - 0x8C1C0906, // 000A GETMET R7 R4 K6 - 0x7C1C0200, // 000B CALL R7 1 - 0x8C200F07, // 000C GETMET R8 R7 K7 - 0x7C200200, // 000D CALL R8 1 - 0x8C241108, // 000E GETMET R9 R8 K8 - 0x582C0005, // 000F LDCONST R11 K5 - 0x88300909, // 0010 GETMBR R12 R4 K9 - 0x8834010A, // 0011 GETMBR R13 R0 K10 - 0x94341B05, // 0012 GETIDX R13 R13 K5 - 0x7C240800, // 0013 CALL R9 4 - 0x8C241108, // 0014 GETMET R9 R8 K8 - 0x582C000B, // 0015 LDCONST R11 K11 - 0x88300909, // 0016 GETMBR R12 R4 K9 - 0x5834000B, // 0017 LDCONST R13 K11 - 0x7C240800, // 0018 CALL R9 4 - 0x80040E00, // 0019 RET 1 R7 - 0x70020025, // 001A JMP #0041 - 0x1C1C0D0B, // 001B EQ R7 R6 K11 - 0x781E0013, // 001C JMPF R7 #0031 - 0x8C1C0906, // 001D GETMET R7 R4 K6 - 0x7C1C0200, // 001E CALL R7 1 - 0x60200010, // 001F GETGBL R8 G16 - 0x8C24010C, // 0020 GETMET R9 R0 K12 - 0x7C240200, // 0021 CALL R9 1 - 0x7C200200, // 0022 CALL R8 1 - 0xA8020007, // 0023 EXBLK 0 #002C - 0x5C241000, // 0024 MOVE R9 R8 - 0x7C240000, // 0025 CALL R9 0 - 0x8C280F08, // 0026 GETMET R10 R7 K8 - 0x4C300000, // 0027 LDNIL R12 - 0x8834090D, // 0028 GETMBR R13 R4 K13 - 0x5C381200, // 0029 MOVE R14 R9 - 0x7C280800, // 002A CALL R10 4 - 0x7001FFF7, // 002B JMP #0024 - 0x5820000E, // 002C LDCONST R8 K14 - 0xAC200200, // 002D CATCH R8 1 0 - 0xB0080000, // 002E RAISE 2 R0 R0 - 0x80040E00, // 002F RET 1 R7 - 0x7002000F, // 0030 JMP #0041 - 0x1C1C0D0F, // 0031 EQ R7 R6 K15 - 0x781E0008, // 0032 JMPF R7 #003C - 0x8C1C0906, // 0033 GETMET R7 R4 K6 - 0x7C1C0200, // 0034 CALL R7 1 - 0x8C200F08, // 0035 GETMET R8 R7 K8 - 0x4C280000, // 0036 LDNIL R10 - 0x882C0909, // 0037 GETMBR R11 R4 K9 - 0x54320005, // 0038 LDINT R12 6 - 0x7C200800, // 0039 CALL R8 4 - 0x80040E00, // 003A RET 1 R7 - 0x70020004, // 003B JMP #0041 - 0x1C1C0D10, // 003C EQ R7 R6 K16 - 0x781E0002, // 003D JMPF R7 #0041 - 0x8C1C0906, // 003E GETMET R7 R4 K6 - 0x7C1C0200, // 003F CALL R7 1 - 0x80040E00, // 0040 RET 1 R7 - 0x80000000, // 0041 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: init -********************************************************************/ -be_local_closure(Matter_Plugin_Relay_init, /* name */ - be_nested_proto( - 5, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(init), - /* K1 */ be_nested_str_weak(endpoints), - /* K2 */ be_nested_str_weak(ENDPOINTS), - /* K3 */ be_nested_str_weak(clusters), - /* K4 */ be_nested_str_weak(CLUSTERS), - }), - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[11]) { /* 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 - 0x88080102, // 0006 GETMBR R2 R0 K2 - 0x90020202, // 0007 SETMBR R0 K1 R2 - 0x88080104, // 0008 GETMBR R2 R0 K4 - 0x90020602, // 0009 SETMBR R0 K3 R2 - 0x80000000, // 000A RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: invoke_request -********************************************************************/ -be_local_closure(Matter_Plugin_Relay_invoke_request, /* name */ - be_nested_proto( - 4, /* nstack */ - 4, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 0, /* has constants */ - NULL, /* no const */ - be_str_weak(invoke_request), - &be_const_str_solidified, - ( &(const binstruction[ 1]) { /* code */ - 0x80000000, // 0000 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified class: Matter_Plugin_Relay -********************************************************************/ -extern const bclass be_class_Matter_Plugin; -be_local_class(Matter_Plugin_Relay, - 0, - &be_class_Matter_Plugin, - be_nested_map(6, - ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(read_attribute, -1), be_const_closure(Matter_Plugin_Relay_read_attribute_closure) }, - { be_const_key_weak(ENDPOINTS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(1, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(1), - })) ) } )) }, - { be_const_key_weak(TYPES, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(1, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(256), - })) ) } )) }, - { be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_Relay_init_closure) }, - { 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[]) { - { be_const_key_int(6, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(1, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(0), - })) ) } )) }, - { be_const_key_int(29, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(4, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(0), - be_const_int(1), - be_const_int(2), - be_const_int(3), - })) ) } )) }, - { be_const_key_int(8, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(0, - ( (struct bvalue*) &(const bvalue[]) { - })) ) } )) }, - { be_const_key_int(3, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(0, - ( (struct bvalue*) &(const bvalue[]) { - })) ) } )) }, - { be_const_key_int(4, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(0, - ( (struct bvalue*) &(const bvalue[]) { - })) ) } )) }, - { be_const_key_int(5, 1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(0, - ( (struct bvalue*) &(const bvalue[]) { - })) ) } )) }, - })) ) } )) }, - { be_const_key_weak(invoke_request, -1), be_const_closure(Matter_Plugin_Relay_invoke_request_closure) }, - })), - be_str_weak(Matter_Plugin_Relay) -); -/*******************************************************************/ - -void be_load_Matter_Plugin_Relay_class(bvm *vm) { - be_pushntvclass(vm, &be_class_Matter_Plugin_Relay); - be_setglobal(vm, "Matter_Plugin_Relay"); - be_pop(vm, 1); -} -/********************************************************************/ -/* End of solidification */ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_core.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h similarity index 76% rename from lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_core.h rename to lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h index 10592a17a..ddf921c29 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_core.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h @@ -1,15 +1,1106 @@ -/* Solidification of Matter_Plugin_core.h */ +/* Solidification of Matter_Plugin_Root.h */ /********************************************************************\ * Generated code, don't edit * \********************************************************************/ #include "be_constobj.h" -extern const bclass be_class_Matter_Plugin_core; +extern const bclass be_class_Matter_Plugin_Root; + +/******************************************************************** +** Solidified function: read_attribute +********************************************************************/ +be_local_closure(Matter_Plugin_Root_read_attribute, /* name */ + be_nested_proto( + 24, /* nstack */ + 3, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[82]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(TLV), + /* K3 */ be_nested_str_weak(cluster), + /* K4 */ be_nested_str_weak(attribute), + /* K5 */ be_const_int(0), + /* K6 */ be_nested_str_weak(create_TLV), + /* K7 */ be_nested_str_weak(U8), + /* K8 */ be_nested_str_weak(session), + /* K9 */ be_nested_str_weak(__breadcrumb), + /* K10 */ be_const_int(1), + /* K11 */ be_nested_str_weak(Matter_TLV_struct), + /* K12 */ be_nested_str_weak(add_TLV), + /* K13 */ be_nested_str_weak(U2), + /* K14 */ be_const_int(2), + /* K15 */ be_nested_str_weak(U1), + /* K16 */ be_const_int(3), + /* K17 */ be_nested_str_weak(BOOL), + /* K18 */ be_nested_str_weak(Matter_TLV_array), + /* K19 */ be_nested_str_weak(tasmota), + /* K20 */ be_nested_str_weak(eth), + /* K21 */ be_nested_str_weak(up), + /* K22 */ be_nested_str_weak(add_struct), + /* K23 */ be_nested_str_weak(UTF1), + /* K24 */ be_nested_str_weak(ethernet), + /* K25 */ be_nested_str_weak(NULL), + /* K26 */ be_nested_str_weak(fromhex), + /* K27 */ be_nested_str_weak(replace), + /* K28 */ be_nested_str_weak(find), + /* K29 */ be_nested_str_weak(mac), + /* K30 */ be_nested_str_weak(), + /* K31 */ be_nested_str_weak(_X3A), + /* K32 */ be_nested_str_weak(B1), + /* K33 */ be_nested_str_weak(add_array), + /* K34 */ be_nested_str_weak(get_ip_bytes), + /* K35 */ be_nested_str_weak(ip), + /* K36 */ be_nested_str_weak(ip6local), + /* K37 */ be_nested_str_weak(ip6), + /* K38 */ be_nested_str_weak(wifi), + /* K39 */ be_nested_str_weak(cmd), + /* K40 */ be_nested_str_weak(Status_X201), + /* K41 */ be_nested_str_weak(StatusPRM), + /* K42 */ be_nested_str_weak(BootCount), + /* K43 */ be_nested_str_weak(U4), + /* K44 */ be_nested_str_weak(Status_X2011), + /* K45 */ be_nested_str_weak(StatusSTS), + /* K46 */ be_nested_str_weak(UptimeSec), + /* K47 */ be_nested_str_weak(int64), + /* K48 */ be_nested_str_weak(rtc), + /* K49 */ be_nested_str_weak(utc), + /* K50 */ be_const_int(1000000), + /* K51 */ be_nested_str_weak(local), + /* K52 */ be_nested_str_weak(device), + /* K53 */ be_nested_str_weak(sessions), + /* K54 */ be_nested_str_weak(sessions_active), + /* K55 */ be_nested_str_weak(B2), + /* K56 */ be_nested_str_weak(noc), + /* K57 */ be_nested_str_weak(icac), + /* K58 */ be_nested_str_weak(stop_iteration), + /* K59 */ be_nested_str_weak(parse), + /* K60 */ be_nested_str_weak(get_ca), + /* K61 */ be_nested_str_weak(findsubval), + /* K62 */ be_nested_str_weak(admin_vendor), + /* K63 */ be_nested_str_weak(fabric), + /* K64 */ be_nested_str_weak(deviceid), + /* K65 */ be_nested_str_weak(fabric_label), + /* K66 */ be_nested_str_weak(Tasmota), + /* K67 */ be_nested_str_weak(vendorid), + /* K68 */ be_nested_str_weak(DeviceName), + /* K69 */ be_nested_str_weak(FriendlyName), + /* K70 */ be_nested_str_weak(FriendlyName1), + /* K71 */ be_nested_str_weak(XX), + /* K72 */ be_nested_str_weak(Status_X202), + /* K73 */ be_nested_str_weak(StatusFWR), + /* K74 */ be_nested_str_weak(Hardware), + /* K75 */ be_nested_str_weak(Version), + /* K76 */ be_nested_str_weak(locale), + /* K77 */ be_nested_str_weak(TYPES), + /* K78 */ be_nested_str_weak(get_cluster_list), + /* K79 */ be_nested_str_weak(get_active_endpoints), + /* K80 */ be_nested_str_weak(status), + /* K81 */ be_nested_str_weak(UNSUPPORTED_CLUSTER), + }), + be_str_weak(read_attribute), + &be_const_str_solidified, + ( &(const binstruction[809]) { /* code */ + 0xA40E0000, // 0000 IMPORT R3 K0 + 0xB8120200, // 0001 GETNGBL R4 K1 + 0x88100902, // 0002 GETMBR R4 R4 K2 + 0x88140503, // 0003 GETMBR R5 R2 K3 + 0x88180504, // 0004 GETMBR R6 R2 K4 + 0x541E002F, // 0005 LDINT R7 48 + 0x1C1C0A07, // 0006 EQ R7 R5 R7 + 0x781E0031, // 0007 JMPF R7 #003A + 0x1C1C0D05, // 0008 EQ R7 R6 K5 + 0x781E0006, // 0009 JMPF R7 #0011 + 0x8C1C0906, // 000A GETMET R7 R4 K6 + 0x88240907, // 000B GETMBR R9 R4 K7 + 0x88280308, // 000C GETMBR R10 R1 K8 + 0x88281509, // 000D GETMBR R10 R10 K9 + 0x7C1C0600, // 000E CALL R7 3 + 0x80040E00, // 000F RET 1 R7 + 0x70020027, // 0010 JMP #0039 + 0x1C1C0D0A, // 0011 EQ R7 R6 K10 + 0x781E000D, // 0012 JMPF R7 #0021 + 0x8C1C090B, // 0013 GETMET R7 R4 K11 + 0x7C1C0200, // 0014 CALL R7 1 + 0x8C200F0C, // 0015 GETMET R8 R7 K12 + 0x58280005, // 0016 LDCONST R10 K5 + 0x882C090D, // 0017 GETMBR R11 R4 K13 + 0x5432003B, // 0018 LDINT R12 60 + 0x7C200800, // 0019 CALL R8 4 + 0x8C200F0C, // 001A GETMET R8 R7 K12 + 0x5828000A, // 001B LDCONST R10 K10 + 0x882C090D, // 001C GETMBR R11 R4 K13 + 0x54320383, // 001D LDINT R12 900 + 0x7C200800, // 001E CALL R8 4 + 0x80040E00, // 001F RET 1 R7 + 0x70020017, // 0020 JMP #0039 + 0x1C1C0D0E, // 0021 EQ R7 R6 K14 + 0x781E0005, // 0022 JMPF R7 #0029 + 0x8C1C0906, // 0023 GETMET R7 R4 K6 + 0x8824090F, // 0024 GETMBR R9 R4 K15 + 0x5828000E, // 0025 LDCONST R10 K14 + 0x7C1C0600, // 0026 CALL R7 3 + 0x80040E00, // 0027 RET 1 R7 + 0x7002000F, // 0028 JMP #0039 + 0x1C1C0D10, // 0029 EQ R7 R6 K16 + 0x781E0005, // 002A JMPF R7 #0031 + 0x8C1C0906, // 002B GETMET R7 R4 K6 + 0x8824090F, // 002C GETMBR R9 R4 K15 + 0x5828000E, // 002D LDCONST R10 K14 + 0x7C1C0600, // 002E CALL R7 3 + 0x80040E00, // 002F RET 1 R7 + 0x70020007, // 0030 JMP #0039 + 0x541E0003, // 0031 LDINT R7 4 + 0x1C1C0C07, // 0032 EQ R7 R6 R7 + 0x781E0004, // 0033 JMPF R7 #0039 + 0x8C1C0906, // 0034 GETMET R7 R4 K6 + 0x88240911, // 0035 GETMBR R9 R4 K17 + 0x50280000, // 0036 LDBOOL R10 0 0 + 0x7C1C0600, // 0037 CALL R7 3 + 0x80040E00, // 0038 RET 1 R7 + 0x700202ED, // 0039 JMP #0328 + 0x541E0031, // 003A LDINT R7 50 + 0x1C1C0A07, // 003B EQ R7 R5 R7 + 0x781E0000, // 003C JMPF R7 #003E + 0x700202E9, // 003D JMP #0328 + 0x541E0032, // 003E LDINT R7 51 + 0x1C1C0A07, // 003F EQ R7 R5 R7 + 0x781E00DA, // 0040 JMPF R7 #011C + 0x1C1C0D05, // 0041 EQ R7 R6 K5 + 0x781E00B5, // 0042 JMPF R7 #00F9 + 0x8C1C0912, // 0043 GETMET R7 R4 K18 + 0x7C1C0200, // 0044 CALL R7 1 + 0xB8222600, // 0045 GETNGBL R8 K19 + 0x8C201114, // 0046 GETMET R8 R8 K20 + 0x7C200200, // 0047 CALL R8 1 + 0x94241115, // 0048 GETIDX R9 R8 K21 + 0x78260053, // 0049 JMPF R9 #009E + 0x8C240F16, // 004A GETMET R9 R7 K22 + 0x4C2C0000, // 004B LDNIL R11 + 0x7C240400, // 004C CALL R9 2 + 0x8C28130C, // 004D GETMET R10 R9 K12 + 0x58300005, // 004E LDCONST R12 K5 + 0x88340917, // 004F GETMBR R13 R4 K23 + 0x58380018, // 0050 LDCONST R14 K24 + 0x7C280800, // 0051 CALL R10 4 + 0x8C28130C, // 0052 GETMET R10 R9 K12 + 0x5830000A, // 0053 LDCONST R12 K10 + 0x88340911, // 0054 GETMBR R13 R4 K17 + 0x5838000A, // 0055 LDCONST R14 K10 + 0x7C280800, // 0056 CALL R10 4 + 0x8C28130C, // 0057 GETMET R10 R9 K12 + 0x5830000E, // 0058 LDCONST R12 K14 + 0x88340911, // 0059 GETMBR R13 R4 K17 + 0x5838000A, // 005A LDCONST R14 K10 + 0x7C280800, // 005B CALL R10 4 + 0x8C28130C, // 005C GETMET R10 R9 K12 + 0x58300010, // 005D LDCONST R12 K16 + 0x88340919, // 005E GETMBR R13 R4 K25 + 0x4C380000, // 005F LDNIL R14 + 0x7C280800, // 0060 CALL R10 4 + 0x60280015, // 0061 GETGBL R10 G21 + 0x7C280000, // 0062 CALL R10 0 + 0x8C28151A, // 0063 GETMET R10 R10 K26 + 0x8C30071B, // 0064 GETMET R12 R3 K27 + 0x8C38111C, // 0065 GETMET R14 R8 K28 + 0x5840001D, // 0066 LDCONST R16 K29 + 0x5844001E, // 0067 LDCONST R17 K30 + 0x7C380600, // 0068 CALL R14 3 + 0x583C001F, // 0069 LDCONST R15 K31 + 0x5840001E, // 006A LDCONST R16 K30 + 0x7C300800, // 006B CALL R12 4 + 0x7C280400, // 006C CALL R10 2 + 0x8C2C130C, // 006D GETMET R11 R9 K12 + 0x54360003, // 006E LDINT R13 4 + 0x88380920, // 006F GETMBR R14 R4 K32 + 0x5C3C1400, // 0070 MOVE R15 R10 + 0x7C2C0800, // 0071 CALL R11 4 + 0x8C2C1321, // 0072 GETMET R11 R9 K33 + 0x54360004, // 0073 LDINT R13 5 + 0x7C2C0400, // 0074 CALL R11 2 + 0x8C30170C, // 0075 GETMET R12 R11 K12 + 0x4C380000, // 0076 LDNIL R14 + 0x883C0920, // 0077 GETMBR R15 R4 K32 + 0xB8420200, // 0078 GETNGBL R16 K1 + 0x8C402122, // 0079 GETMET R16 R16 K34 + 0x8C48111C, // 007A GETMET R18 R8 K28 + 0x58500023, // 007B LDCONST R20 K35 + 0x5854001E, // 007C LDCONST R21 K30 + 0x7C480600, // 007D CALL R18 3 + 0x7C400400, // 007E CALL R16 2 + 0x7C300800, // 007F CALL R12 4 + 0x8C301321, // 0080 GETMET R12 R9 K33 + 0x543A0005, // 0081 LDINT R14 6 + 0x7C300400, // 0082 CALL R12 2 + 0x8C34190C, // 0083 GETMET R13 R12 K12 + 0x4C3C0000, // 0084 LDNIL R15 + 0x88400920, // 0085 GETMBR R16 R4 K32 + 0xB8460200, // 0086 GETNGBL R17 K1 + 0x8C442322, // 0087 GETMET R17 R17 K34 + 0x8C4C111C, // 0088 GETMET R19 R8 K28 + 0x58540024, // 0089 LDCONST R21 K36 + 0x5858001E, // 008A LDCONST R22 K30 + 0x7C4C0600, // 008B CALL R19 3 + 0x7C440400, // 008C CALL R17 2 + 0x7C340800, // 008D CALL R13 4 + 0x8C34190C, // 008E GETMET R13 R12 K12 + 0x4C3C0000, // 008F LDNIL R15 + 0x88400920, // 0090 GETMBR R16 R4 K32 + 0xB8460200, // 0091 GETNGBL R17 K1 + 0x8C442322, // 0092 GETMET R17 R17 K34 + 0x8C4C111C, // 0093 GETMET R19 R8 K28 + 0x58540025, // 0094 LDCONST R21 K37 + 0x5858001E, // 0095 LDCONST R22 K30 + 0x7C4C0600, // 0096 CALL R19 3 + 0x7C440400, // 0097 CALL R17 2 + 0x7C340800, // 0098 CALL R13 4 + 0x8C34130C, // 0099 GETMET R13 R9 K12 + 0x543E0006, // 009A LDINT R15 7 + 0x8840090F, // 009B GETMBR R16 R4 K15 + 0x5844000E, // 009C LDCONST R17 K14 + 0x7C340800, // 009D CALL R13 4 + 0xB8262600, // 009E GETNGBL R9 K19 + 0x8C241326, // 009F GETMET R9 R9 K38 + 0x7C240200, // 00A0 CALL R9 1 + 0x94281315, // 00A1 GETIDX R10 R9 K21 + 0x782A0053, // 00A2 JMPF R10 #00F7 + 0x8C280F16, // 00A3 GETMET R10 R7 K22 + 0x4C300000, // 00A4 LDNIL R12 + 0x7C280400, // 00A5 CALL R10 2 + 0x8C2C150C, // 00A6 GETMET R11 R10 K12 + 0x58340005, // 00A7 LDCONST R13 K5 + 0x88380917, // 00A8 GETMBR R14 R4 K23 + 0x583C0026, // 00A9 LDCONST R15 K38 + 0x7C2C0800, // 00AA CALL R11 4 + 0x8C2C150C, // 00AB GETMET R11 R10 K12 + 0x5834000A, // 00AC LDCONST R13 K10 + 0x88380911, // 00AD GETMBR R14 R4 K17 + 0x583C000A, // 00AE LDCONST R15 K10 + 0x7C2C0800, // 00AF CALL R11 4 + 0x8C2C150C, // 00B0 GETMET R11 R10 K12 + 0x5834000E, // 00B1 LDCONST R13 K14 + 0x88380911, // 00B2 GETMBR R14 R4 K17 + 0x583C000A, // 00B3 LDCONST R15 K10 + 0x7C2C0800, // 00B4 CALL R11 4 + 0x8C2C150C, // 00B5 GETMET R11 R10 K12 + 0x58340010, // 00B6 LDCONST R13 K16 + 0x88380919, // 00B7 GETMBR R14 R4 K25 + 0x4C3C0000, // 00B8 LDNIL R15 + 0x7C2C0800, // 00B9 CALL R11 4 + 0x602C0015, // 00BA GETGBL R11 G21 + 0x7C2C0000, // 00BB CALL R11 0 + 0x8C2C171A, // 00BC GETMET R11 R11 K26 + 0x8C34071B, // 00BD GETMET R13 R3 K27 + 0x8C3C131C, // 00BE GETMET R15 R9 K28 + 0x5844001D, // 00BF LDCONST R17 K29 + 0x5848001E, // 00C0 LDCONST R18 K30 + 0x7C3C0600, // 00C1 CALL R15 3 + 0x5840001F, // 00C2 LDCONST R16 K31 + 0x5844001E, // 00C3 LDCONST R17 K30 + 0x7C340800, // 00C4 CALL R13 4 + 0x7C2C0400, // 00C5 CALL R11 2 + 0x8C30150C, // 00C6 GETMET R12 R10 K12 + 0x543A0003, // 00C7 LDINT R14 4 + 0x883C0920, // 00C8 GETMBR R15 R4 K32 + 0x5C401600, // 00C9 MOVE R16 R11 + 0x7C300800, // 00CA CALL R12 4 + 0x8C301521, // 00CB GETMET R12 R10 K33 + 0x543A0004, // 00CC LDINT R14 5 + 0x7C300400, // 00CD CALL R12 2 + 0x8C34190C, // 00CE GETMET R13 R12 K12 + 0x4C3C0000, // 00CF LDNIL R15 + 0x88400920, // 00D0 GETMBR R16 R4 K32 + 0xB8460200, // 00D1 GETNGBL R17 K1 + 0x8C442322, // 00D2 GETMET R17 R17 K34 + 0x8C4C131C, // 00D3 GETMET R19 R9 K28 + 0x58540023, // 00D4 LDCONST R21 K35 + 0x5858001E, // 00D5 LDCONST R22 K30 + 0x7C4C0600, // 00D6 CALL R19 3 + 0x7C440400, // 00D7 CALL R17 2 + 0x7C340800, // 00D8 CALL R13 4 + 0x8C341521, // 00D9 GETMET R13 R10 K33 + 0x543E0005, // 00DA LDINT R15 6 + 0x7C340400, // 00DB CALL R13 2 + 0x8C381B0C, // 00DC GETMET R14 R13 K12 + 0x4C400000, // 00DD LDNIL R16 + 0x88440920, // 00DE GETMBR R17 R4 K32 + 0xB84A0200, // 00DF GETNGBL R18 K1 + 0x8C482522, // 00E0 GETMET R18 R18 K34 + 0x8C50131C, // 00E1 GETMET R20 R9 K28 + 0x58580024, // 00E2 LDCONST R22 K36 + 0x585C001E, // 00E3 LDCONST R23 K30 + 0x7C500600, // 00E4 CALL R20 3 + 0x7C480400, // 00E5 CALL R18 2 + 0x7C380800, // 00E6 CALL R14 4 + 0x8C381B0C, // 00E7 GETMET R14 R13 K12 + 0x4C400000, // 00E8 LDNIL R16 + 0x88440920, // 00E9 GETMBR R17 R4 K32 + 0xB84A0200, // 00EA GETNGBL R18 K1 + 0x8C482522, // 00EB GETMET R18 R18 K34 + 0x8C50131C, // 00EC GETMET R20 R9 K28 + 0x58580025, // 00ED LDCONST R22 K37 + 0x585C001E, // 00EE LDCONST R23 K30 + 0x7C500600, // 00EF CALL R20 3 + 0x7C480400, // 00F0 CALL R18 2 + 0x7C380800, // 00F1 CALL R14 4 + 0x8C38150C, // 00F2 GETMET R14 R10 K12 + 0x54420006, // 00F3 LDINT R16 7 + 0x8844090F, // 00F4 GETMBR R17 R4 K15 + 0x5848000A, // 00F5 LDCONST R18 K10 + 0x7C380800, // 00F6 CALL R14 4 + 0x80040E00, // 00F7 RET 1 R7 + 0x70020021, // 00F8 JMP #011B + 0x1C1C0D0A, // 00F9 EQ R7 R6 K10 + 0x781E000A, // 00FA JMPF R7 #0106 + 0x8C1C0906, // 00FB GETMET R7 R4 K6 + 0x8824090D, // 00FC GETMBR R9 R4 K13 + 0xB82A2600, // 00FD GETNGBL R10 K19 + 0x8C281527, // 00FE GETMET R10 R10 K39 + 0x58300028, // 00FF LDCONST R12 K40 + 0x7C280400, // 0100 CALL R10 2 + 0x94281529, // 0101 GETIDX R10 R10 K41 + 0x9428152A, // 0102 GETIDX R10 R10 K42 + 0x7C1C0600, // 0103 CALL R7 3 + 0x80040E00, // 0104 RET 1 R7 + 0x70020014, // 0105 JMP #011B + 0x1C1C0D0E, // 0106 EQ R7 R6 K14 + 0x781E000A, // 0107 JMPF R7 #0113 + 0x8C1C0906, // 0108 GETMET R7 R4 K6 + 0x8824092B, // 0109 GETMBR R9 R4 K43 + 0xB82A2600, // 010A GETNGBL R10 K19 + 0x8C281527, // 010B GETMET R10 R10 K39 + 0x5830002C, // 010C LDCONST R12 K44 + 0x7C280400, // 010D CALL R10 2 + 0x9428152D, // 010E GETIDX R10 R10 K45 + 0x9428152E, // 010F GETIDX R10 R10 K46 + 0x7C1C0600, // 0110 CALL R7 3 + 0x80040E00, // 0111 RET 1 R7 + 0x70020007, // 0112 JMP #011B + 0x541E0007, // 0113 LDINT R7 8 + 0x1C1C0C07, // 0114 EQ R7 R6 R7 + 0x781E0004, // 0115 JMPF R7 #011B + 0x8C1C0906, // 0116 GETMET R7 R4 K6 + 0x88240911, // 0117 GETMBR R9 R4 K17 + 0x50280000, // 0118 LDBOOL R10 0 0 + 0x7C1C0600, // 0119 CALL R7 3 + 0x80040E00, // 011A RET 1 R7 + 0x7002020B, // 011B JMP #0328 + 0x541E0033, // 011C LDINT R7 52 + 0x1C1C0A07, // 011D EQ R7 R5 R7 + 0x781E0000, // 011E JMPF R7 #0120 + 0x70020207, // 011F JMP #0328 + 0x541E0037, // 0120 LDINT R7 56 + 0x1C1C0A07, // 0121 EQ R7 R5 R7 + 0x781E002C, // 0122 JMPF R7 #0150 + 0x1C1C0D05, // 0123 EQ R7 R6 K5 + 0x781E000F, // 0124 JMPF R7 #0135 + 0xB81E5E00, // 0125 GETNGBL R7 K47 + 0xB8222600, // 0126 GETNGBL R8 K19 + 0x8C201130, // 0127 GETMET R8 R8 K48 + 0x7C200200, // 0128 CALL R8 1 + 0x94201131, // 0129 GETIDX R8 R8 K49 + 0x7C1C0200, // 012A CALL R7 1 + 0xB8225E00, // 012B GETNGBL R8 K47 + 0x58240032, // 012C LDCONST R9 K50 + 0x7C200200, // 012D CALL R8 1 + 0x081C0E08, // 012E MUL R7 R7 R8 + 0x8C200906, // 012F GETMET R8 R4 K6 + 0x88280907, // 0130 GETMBR R10 R4 K7 + 0x5C2C0E00, // 0131 MOVE R11 R7 + 0x7C200600, // 0132 CALL R8 3 + 0x80041000, // 0133 RET 1 R8 + 0x70020019, // 0134 JMP #014F + 0x1C1C0D0A, // 0135 EQ R7 R6 K10 + 0x781E0005, // 0136 JMPF R7 #013D + 0x8C1C0906, // 0137 GETMET R7 R4 K6 + 0x8824090F, // 0138 GETMBR R9 R4 K15 + 0x58280010, // 0139 LDCONST R10 K16 + 0x7C1C0600, // 013A CALL R7 3 + 0x80040E00, // 013B RET 1 R7 + 0x70020011, // 013C JMP #014F + 0x541E0006, // 013D LDINT R7 7 + 0x1C1C0C07, // 013E EQ R7 R6 R7 + 0x781E000E, // 013F JMPF R7 #014F + 0xB81E5E00, // 0140 GETNGBL R7 K47 + 0xB8222600, // 0141 GETNGBL R8 K19 + 0x8C201130, // 0142 GETMET R8 R8 K48 + 0x7C200200, // 0143 CALL R8 1 + 0x94201133, // 0144 GETIDX R8 R8 K51 + 0x7C1C0200, // 0145 CALL R7 1 + 0xB8225E00, // 0146 GETNGBL R8 K47 + 0x58240032, // 0147 LDCONST R9 K50 + 0x7C200200, // 0148 CALL R8 1 + 0x081C0E08, // 0149 MUL R7 R7 R8 + 0x8C200906, // 014A GETMET R8 R4 K6 + 0x88280907, // 014B GETMBR R10 R4 K7 + 0x5C2C0E00, // 014C MOVE R11 R7 + 0x7C200600, // 014D CALL R8 3 + 0x80041000, // 014E RET 1 R8 + 0x700201D7, // 014F JMP #0328 + 0x541E003D, // 0150 LDINT R7 62 + 0x1C1C0A07, // 0151 EQ R7 R5 R7 + 0x781E0082, // 0152 JMPF R7 #01D6 + 0x1C1C0D05, // 0153 EQ R7 R6 K5 + 0x781E001D, // 0154 JMPF R7 #0173 + 0x8C1C0912, // 0155 GETMET R7 R4 K18 + 0x7C1C0200, // 0156 CALL R7 1 + 0x60200010, // 0157 GETGBL R8 G16 + 0x88240134, // 0158 GETMBR R9 R0 K52 + 0x88241335, // 0159 GETMBR R9 R9 K53 + 0x8C241336, // 015A GETMET R9 R9 K54 + 0x7C240200, // 015B CALL R9 1 + 0x7C200200, // 015C CALL R8 1 + 0xA802000F, // 015D EXBLK 0 #016E + 0x5C241000, // 015E MOVE R9 R8 + 0x7C240000, // 015F CALL R9 0 + 0x8C280F16, // 0160 GETMET R10 R7 K22 + 0x4C300000, // 0161 LDNIL R12 + 0x7C280400, // 0162 CALL R10 2 + 0x8C2C150C, // 0163 GETMET R11 R10 K12 + 0x5834000A, // 0164 LDCONST R13 K10 + 0x88380937, // 0165 GETMBR R14 R4 K55 + 0x883C1338, // 0166 GETMBR R15 R9 K56 + 0x7C2C0800, // 0167 CALL R11 4 + 0x8C2C150C, // 0168 GETMET R11 R10 K12 + 0x5834000E, // 0169 LDCONST R13 K14 + 0x88380937, // 016A GETMBR R14 R4 K55 + 0x883C1339, // 016B GETMBR R15 R9 K57 + 0x7C2C0800, // 016C CALL R11 4 + 0x7001FFEF, // 016D JMP #015E + 0x5820003A, // 016E LDCONST R8 K58 + 0xAC200200, // 016F CATCH R8 1 0 + 0xB0080000, // 0170 RAISE 2 R0 R0 + 0x80040E00, // 0171 RET 1 R7 + 0x70020061, // 0172 JMP #01D5 + 0x1C1C0D0A, // 0173 EQ R7 R6 K10 + 0x781E0032, // 0174 JMPF R7 #01A8 + 0x8C1C0912, // 0175 GETMET R7 R4 K18 + 0x7C1C0200, // 0176 CALL R7 1 + 0x60200010, // 0177 GETGBL R8 G16 + 0x88240134, // 0178 GETMBR R9 R0 K52 + 0x88241335, // 0179 GETMBR R9 R9 K53 + 0x8C241336, // 017A GETMET R9 R9 K54 + 0x7C240200, // 017B CALL R9 1 + 0x7C200200, // 017C CALL R8 1 + 0xA8020024, // 017D EXBLK 0 #01A3 + 0x5C241000, // 017E MOVE R9 R8 + 0x7C240000, // 017F CALL R9 0 + 0x8C28093B, // 0180 GETMET R10 R4 K59 + 0x8C30133C, // 0181 GETMET R12 R9 K60 + 0x7C300200, // 0182 CALL R12 1 + 0x7C280400, // 0183 CALL R10 2 + 0x8C2C0F16, // 0184 GETMET R11 R7 K22 + 0x4C340000, // 0185 LDNIL R13 + 0x7C2C0400, // 0186 CALL R11 2 + 0x8C30170C, // 0187 GETMET R12 R11 K12 + 0x5838000A, // 0188 LDCONST R14 K10 + 0x883C0937, // 0189 GETMBR R15 R4 K55 + 0x8C40153D, // 018A GETMET R16 R10 K61 + 0x544A0008, // 018B LDINT R18 9 + 0x7C400400, // 018C CALL R16 2 + 0x7C300800, // 018D CALL R12 4 + 0x8C30170C, // 018E GETMET R12 R11 K12 + 0x5838000E, // 018F LDCONST R14 K14 + 0x883C090D, // 0190 GETMBR R15 R4 K13 + 0x8840133E, // 0191 GETMBR R16 R9 K62 + 0x7C300800, // 0192 CALL R12 4 + 0x8C30170C, // 0193 GETMET R12 R11 K12 + 0x58380010, // 0194 LDCONST R14 K16 + 0x883C0907, // 0195 GETMBR R15 R4 K7 + 0x8840133F, // 0196 GETMBR R16 R9 K63 + 0x7C300800, // 0197 CALL R12 4 + 0x8C30170C, // 0198 GETMET R12 R11 K12 + 0x543A0003, // 0199 LDINT R14 4 + 0x883C0907, // 019A GETMBR R15 R4 K7 + 0x88401340, // 019B GETMBR R16 R9 K64 + 0x7C300800, // 019C CALL R12 4 + 0x8C30170C, // 019D GETMET R12 R11 K12 + 0x543A0004, // 019E LDINT R14 5 + 0x883C0917, // 019F GETMBR R15 R4 K23 + 0x88401341, // 01A0 GETMBR R16 R9 K65 + 0x7C300800, // 01A1 CALL R12 4 + 0x7001FFDA, // 01A2 JMP #017E + 0x5820003A, // 01A3 LDCONST R8 K58 + 0xAC200200, // 01A4 CATCH R8 1 0 + 0xB0080000, // 01A5 RAISE 2 R0 R0 + 0x80040E00, // 01A6 RET 1 R7 + 0x7002002C, // 01A7 JMP #01D5 + 0x1C1C0D0E, // 01A8 EQ R7 R6 K14 + 0x781E0005, // 01A9 JMPF R7 #01B0 + 0x8C1C0906, // 01AA GETMET R7 R4 K6 + 0x8824090F, // 01AB GETMBR R9 R4 K15 + 0x542A0004, // 01AC LDINT R10 5 + 0x7C1C0600, // 01AD CALL R7 3 + 0x80040E00, // 01AE RET 1 R7 + 0x70020024, // 01AF JMP #01D5 + 0x1C1C0D10, // 01B0 EQ R7 R6 K16 + 0x781E000B, // 01B1 JMPF R7 #01BE + 0x881C0134, // 01B2 GETMBR R7 R0 K52 + 0x881C0F35, // 01B3 GETMBR R7 R7 K53 + 0x8C1C0F36, // 01B4 GETMET R7 R7 K54 + 0x7C1C0200, // 01B5 CALL R7 1 + 0x8C200906, // 01B6 GETMET R8 R4 K6 + 0x8828090F, // 01B7 GETMBR R10 R4 K15 + 0x602C000C, // 01B8 GETGBL R11 G12 + 0x5C300E00, // 01B9 MOVE R12 R7 + 0x7C2C0200, // 01BA CALL R11 1 + 0x7C200600, // 01BB CALL R8 3 + 0x80041000, // 01BC RET 1 R8 + 0x70020016, // 01BD JMP #01D5 + 0x541E0003, // 01BE LDINT R7 4 + 0x1C1C0C07, // 01BF EQ R7 R6 R7 + 0x781E0000, // 01C0 JMPF R7 #01C2 + 0x70020012, // 01C1 JMP #01D5 + 0x541E0004, // 01C2 LDINT R7 5 + 0x1C1C0C07, // 01C3 EQ R7 R6 R7 + 0x781E000F, // 01C4 JMPF R7 #01D5 + 0x881C0134, // 01C5 GETMBR R7 R0 K52 + 0x881C0F35, // 01C6 GETMBR R7 R7 K53 + 0x8C1C0F36, // 01C7 GETMET R7 R7 K54 + 0x7C1C0200, // 01C8 CALL R7 1 + 0x8C200F1C, // 01C9 GETMET R8 R7 K28 + 0x88280308, // 01CA GETMBR R10 R1 K8 + 0x7C200400, // 01CB CALL R8 2 + 0x4C240000, // 01CC LDNIL R9 + 0x1C241009, // 01CD EQ R9 R8 R9 + 0x78260000, // 01CE JMPF R9 #01D0 + 0x58200005, // 01CF LDCONST R8 K5 + 0x8C240906, // 01D0 GETMET R9 R4 K6 + 0x882C090F, // 01D1 GETMBR R11 R4 K15 + 0x5C301000, // 01D2 MOVE R12 R8 + 0x7C240600, // 01D3 CALL R9 3 + 0x80041200, // 01D4 RET 1 R9 + 0x70020151, // 01D5 JMP #0328 + 0x541E003B, // 01D6 LDINT R7 60 + 0x1C1C0A07, // 01D7 EQ R7 R5 R7 + 0x781E0000, // 01D8 JMPF R7 #01DA + 0x7002014D, // 01D9 JMP #0328 + 0x541E0027, // 01DA LDINT R7 40 + 0x1C1C0A07, // 01DB EQ R7 R5 R7 + 0x781E0080, // 01DC JMPF R7 #025E + 0x1C1C0D05, // 01DD EQ R7 R6 K5 + 0x781E0005, // 01DE JMPF R7 #01E5 + 0x8C1C0906, // 01DF GETMET R7 R4 K6 + 0x8824090D, // 01E0 GETMBR R9 R4 K13 + 0x58280005, // 01E1 LDCONST R10 K5 + 0x7C1C0600, // 01E2 CALL R7 3 + 0x80040E00, // 01E3 RET 1 R7 + 0x70020077, // 01E4 JMP #025D + 0x1C1C0D0A, // 01E5 EQ R7 R6 K10 + 0x781E0005, // 01E6 JMPF R7 #01ED + 0x8C1C0906, // 01E7 GETMET R7 R4 K6 + 0x88240917, // 01E8 GETMBR R9 R4 K23 + 0x58280042, // 01E9 LDCONST R10 K66 + 0x7C1C0600, // 01EA CALL R7 3 + 0x80040E00, // 01EB RET 1 R7 + 0x7002006F, // 01EC JMP #025D + 0x1C1C0D0E, // 01ED EQ R7 R6 K14 + 0x781E0006, // 01EE JMPF R7 #01F6 + 0x8C1C0906, // 01EF GETMET R7 R4 K6 + 0x8824090D, // 01F0 GETMBR R9 R4 K13 + 0x88280134, // 01F1 GETMBR R10 R0 K52 + 0x88281543, // 01F2 GETMBR R10 R10 K67 + 0x7C1C0600, // 01F3 CALL R7 3 + 0x80040E00, // 01F4 RET 1 R7 + 0x70020066, // 01F5 JMP #025D + 0x1C1C0D10, // 01F6 EQ R7 R6 K16 + 0x781E0009, // 01F7 JMPF R7 #0202 + 0x8C1C0906, // 01F8 GETMET R7 R4 K6 + 0x88240917, // 01F9 GETMBR R9 R4 K23 + 0xB82A2600, // 01FA GETNGBL R10 K19 + 0x8C281527, // 01FB GETMET R10 R10 K39 + 0x58300044, // 01FC LDCONST R12 K68 + 0x7C280400, // 01FD CALL R10 2 + 0x94281544, // 01FE GETIDX R10 R10 K68 + 0x7C1C0600, // 01FF CALL R7 3 + 0x80040E00, // 0200 RET 1 R7 + 0x7002005A, // 0201 JMP #025D + 0x541E0003, // 0202 LDINT R7 4 + 0x1C1C0C07, // 0203 EQ R7 R6 R7 + 0x781E0005, // 0204 JMPF R7 #020B + 0x8C1C0906, // 0205 GETMET R7 R4 K6 + 0x8824090D, // 0206 GETMBR R9 R4 K13 + 0x542A7FFF, // 0207 LDINT R10 32768 + 0x7C1C0600, // 0208 CALL R7 3 + 0x80040E00, // 0209 RET 1 R7 + 0x70020051, // 020A JMP #025D + 0x541E0004, // 020B LDINT R7 5 + 0x1C1C0C07, // 020C EQ R7 R6 R7 + 0x781E0009, // 020D JMPF R7 #0218 + 0x8C1C0906, // 020E GETMET R7 R4 K6 + 0x88240917, // 020F GETMBR R9 R4 K23 + 0xB82A2600, // 0210 GETNGBL R10 K19 + 0x8C281527, // 0211 GETMET R10 R10 K39 + 0x58300045, // 0212 LDCONST R12 K69 + 0x7C280400, // 0213 CALL R10 2 + 0x94281546, // 0214 GETIDX R10 R10 K70 + 0x7C1C0600, // 0215 CALL R7 3 + 0x80040E00, // 0216 RET 1 R7 + 0x70020044, // 0217 JMP #025D + 0x541E0005, // 0218 LDINT R7 6 + 0x1C1C0C07, // 0219 EQ R7 R6 R7 + 0x781E0005, // 021A JMPF R7 #0221 + 0x8C1C0906, // 021B GETMET R7 R4 K6 + 0x88240917, // 021C GETMBR R9 R4 K23 + 0x58280047, // 021D LDCONST R10 K71 + 0x7C1C0600, // 021E CALL R7 3 + 0x80040E00, // 021F RET 1 R7 + 0x7002003B, // 0220 JMP #025D + 0x541E0006, // 0221 LDINT R7 7 + 0x1C1C0C07, // 0222 EQ R7 R6 R7 + 0x781E0005, // 0223 JMPF R7 #022A + 0x8C1C0906, // 0224 GETMET R7 R4 K6 + 0x8824090D, // 0225 GETMBR R9 R4 K13 + 0x58280005, // 0226 LDCONST R10 K5 + 0x7C1C0600, // 0227 CALL R7 3 + 0x80040E00, // 0228 RET 1 R7 + 0x70020032, // 0229 JMP #025D + 0x541E0007, // 022A LDINT R7 8 + 0x1C1C0C07, // 022B EQ R7 R6 R7 + 0x781E000A, // 022C JMPF R7 #0238 + 0x8C1C0906, // 022D GETMET R7 R4 K6 + 0x88240917, // 022E GETMBR R9 R4 K23 + 0xB82A2600, // 022F GETNGBL R10 K19 + 0x8C281527, // 0230 GETMET R10 R10 K39 + 0x58300048, // 0231 LDCONST R12 K72 + 0x7C280400, // 0232 CALL R10 2 + 0x94281549, // 0233 GETIDX R10 R10 K73 + 0x9428154A, // 0234 GETIDX R10 R10 K74 + 0x7C1C0600, // 0235 CALL R7 3 + 0x80040E00, // 0236 RET 1 R7 + 0x70020024, // 0237 JMP #025D + 0x541E0008, // 0238 LDINT R7 9 + 0x1C1C0C07, // 0239 EQ R7 R6 R7 + 0x781E0005, // 023A JMPF R7 #0241 + 0x8C1C0906, // 023B GETMET R7 R4 K6 + 0x8824090D, // 023C GETMBR R9 R4 K13 + 0x58280005, // 023D LDCONST R10 K5 + 0x7C1C0600, // 023E CALL R7 3 + 0x80040E00, // 023F RET 1 R7 + 0x7002001B, // 0240 JMP #025D + 0x541E0009, // 0241 LDINT R7 10 + 0x1C1C0C07, // 0242 EQ R7 R6 R7 + 0x781E000A, // 0243 JMPF R7 #024F + 0x8C1C0906, // 0244 GETMET R7 R4 K6 + 0x88240917, // 0245 GETMBR R9 R4 K23 + 0xB82A2600, // 0246 GETNGBL R10 K19 + 0x8C281527, // 0247 GETMET R10 R10 K39 + 0x58300048, // 0248 LDCONST R12 K72 + 0x7C280400, // 0249 CALL R10 2 + 0x94281549, // 024A GETIDX R10 R10 K73 + 0x9428154B, // 024B GETIDX R10 R10 K75 + 0x7C1C0600, // 024C CALL R7 3 + 0x80040E00, // 024D RET 1 R7 + 0x7002000D, // 024E JMP #025D + 0x541E0011, // 024F LDINT R7 18 + 0x1C1C0C07, // 0250 EQ R7 R6 R7 + 0x781E000A, // 0251 JMPF R7 #025D + 0x8C1C0906, // 0252 GETMET R7 R4 K6 + 0x88240917, // 0253 GETMBR R9 R4 K23 + 0xB82A2600, // 0254 GETNGBL R10 K19 + 0x8C281526, // 0255 GETMET R10 R10 K38 + 0x7C280200, // 0256 CALL R10 1 + 0x8C28151C, // 0257 GETMET R10 R10 K28 + 0x5830001D, // 0258 LDCONST R12 K29 + 0x5834001E, // 0259 LDCONST R13 K30 + 0x7C280600, // 025A CALL R10 3 + 0x7C1C0600, // 025B CALL R7 3 + 0x80040E00, // 025C RET 1 R7 + 0x700200C9, // 025D JMP #0328 + 0x541E003E, // 025E LDINT R7 63 + 0x1C1C0A07, // 025F EQ R7 R5 R7 + 0x781E0000, // 0260 JMPF R7 #0262 + 0x700200C5, // 0261 JMP #0328 + 0x541E0029, // 0262 LDINT R7 42 + 0x1C1C0A07, // 0263 EQ R7 R5 R7 + 0x781E001D, // 0264 JMPF R7 #0283 + 0x1C1C0D05, // 0265 EQ R7 R6 K5 + 0x781E0003, // 0266 JMPF R7 #026B + 0x8C1C0912, // 0267 GETMET R7 R4 K18 + 0x7C1C0200, // 0268 CALL R7 1 + 0x80040E00, // 0269 RET 1 R7 + 0x70020016, // 026A JMP #0282 + 0x1C1C0D0A, // 026B EQ R7 R6 K10 + 0x781E0005, // 026C JMPF R7 #0273 + 0x8C1C0906, // 026D GETMET R7 R4 K6 + 0x88240911, // 026E GETMBR R9 R4 K17 + 0x58280005, // 026F LDCONST R10 K5 + 0x7C1C0600, // 0270 CALL R7 3 + 0x80040E00, // 0271 RET 1 R7 + 0x7002000E, // 0272 JMP #0282 + 0x1C1C0D0E, // 0273 EQ R7 R6 K14 + 0x781E0005, // 0274 JMPF R7 #027B + 0x8C1C0906, // 0275 GETMET R7 R4 K6 + 0x8824090F, // 0276 GETMBR R9 R4 K15 + 0x5828000A, // 0277 LDCONST R10 K10 + 0x7C1C0600, // 0278 CALL R7 3 + 0x80040E00, // 0279 RET 1 R7 + 0x70020006, // 027A JMP #0282 + 0x1C1C0D10, // 027B EQ R7 R6 K16 + 0x781E0004, // 027C JMPF R7 #0282 + 0x8C1C0906, // 027D GETMET R7 R4 K6 + 0x88240919, // 027E GETMBR R9 R4 K25 + 0x4C280000, // 027F LDNIL R10 + 0x7C1C0600, // 0280 CALL R7 3 + 0x80040E00, // 0281 RET 1 R7 + 0x700200A4, // 0282 JMP #0328 + 0x541E002A, // 0283 LDINT R7 43 + 0x1C1C0A07, // 0284 EQ R7 R5 R7 + 0x781E0016, // 0285 JMPF R7 #029D + 0x1C1C0D05, // 0286 EQ R7 R6 K5 + 0x781E0007, // 0287 JMPF R7 #0290 + 0x8C1C0906, // 0288 GETMET R7 R4 K6 + 0x88240917, // 0289 GETMBR R9 R4 K23 + 0xB82A2600, // 028A GETNGBL R10 K19 + 0x8C28154C, // 028B GETMET R10 R10 K76 + 0x7C280200, // 028C CALL R10 1 + 0x7C1C0600, // 028D CALL R7 3 + 0x80040E00, // 028E RET 1 R7 + 0x7002000B, // 028F JMP #029C + 0x1C1C0D0A, // 0290 EQ R7 R6 K10 + 0x781E0009, // 0291 JMPF R7 #029C + 0x8C1C0912, // 0292 GETMET R7 R4 K18 + 0x7C1C0200, // 0293 CALL R7 1 + 0x8C200F0C, // 0294 GETMET R8 R7 K12 + 0x4C280000, // 0295 LDNIL R10 + 0x882C0917, // 0296 GETMBR R11 R4 K23 + 0xB8322600, // 0297 GETNGBL R12 K19 + 0x8C30194C, // 0298 GETMET R12 R12 K76 + 0x7C300200, // 0299 CALL R12 1 + 0x7C200800, // 029A CALL R8 4 + 0x80040E00, // 029B RET 1 R7 + 0x7002008A, // 029C JMP #0328 + 0x541E002B, // 029D LDINT R7 44 + 0x1C1C0A07, // 029E EQ R7 R5 R7 + 0x781E001C, // 029F JMPF R7 #02BD + 0x1C1C0D05, // 02A0 EQ R7 R6 K5 + 0x781E0005, // 02A1 JMPF R7 #02A8 + 0x8C1C0906, // 02A2 GETMET R7 R4 K6 + 0x8824090F, // 02A3 GETMBR R9 R4 K15 + 0x5828000A, // 02A4 LDCONST R10 K10 + 0x7C1C0600, // 02A5 CALL R7 3 + 0x80040E00, // 02A6 RET 1 R7 + 0x70020013, // 02A7 JMP #02BC + 0x1C1C0D0A, // 02A8 EQ R7 R6 K10 + 0x781E0005, // 02A9 JMPF R7 #02B0 + 0x8C1C0906, // 02AA GETMET R7 R4 K6 + 0x8824090F, // 02AB GETMBR R9 R4 K15 + 0x542A0003, // 02AC LDINT R10 4 + 0x7C1C0600, // 02AD CALL R7 3 + 0x80040E00, // 02AE RET 1 R7 + 0x7002000B, // 02AF JMP #02BC + 0x1C1C0D0E, // 02B0 EQ R7 R6 K14 + 0x781E0009, // 02B1 JMPF R7 #02BC + 0x8C1C0912, // 02B2 GETMET R7 R4 K18 + 0x7C1C0200, // 02B3 CALL R7 1 + 0x8C200F0C, // 02B4 GETMET R8 R7 K12 + 0x4C280000, // 02B5 LDNIL R10 + 0x8C2C0906, // 02B6 GETMET R11 R4 K6 + 0x8834090F, // 02B7 GETMBR R13 R4 K15 + 0x543A0003, // 02B8 LDINT R14 4 + 0x7C2C0600, // 02B9 CALL R11 3 + 0x7C200600, // 02BA CALL R8 3 + 0x80040E00, // 02BB RET 1 R7 + 0x7002006A, // 02BC JMP #0328 + 0x541E0030, // 02BD LDINT R7 49 + 0x1C1C0A07, // 02BE EQ R7 R5 R7 + 0x781E0010, // 02BF JMPF R7 #02D1 + 0x1C1C0D10, // 02C0 EQ R7 R6 K16 + 0x781E0005, // 02C1 JMPF R7 #02C8 + 0x8C1C0906, // 02C2 GETMET R7 R4 K6 + 0x8824090F, // 02C3 GETMBR R9 R4 K15 + 0x542A001D, // 02C4 LDINT R10 30 + 0x7C1C0600, // 02C5 CALL R7 3 + 0x80040E00, // 02C6 RET 1 R7 + 0x70020007, // 02C7 JMP #02D0 + 0x541EFFFB, // 02C8 LDINT R7 65532 + 0x1C1C0C07, // 02C9 EQ R7 R6 R7 + 0x781E0004, // 02CA JMPF R7 #02D0 + 0x8C1C0906, // 02CB GETMET R7 R4 K6 + 0x8824092B, // 02CC GETMBR R9 R4 K43 + 0x58280005, // 02CD LDCONST R10 K5 + 0x7C1C0600, // 02CE CALL R7 3 + 0x80040E00, // 02CF RET 1 R7 + 0x70020056, // 02D0 JMP #0328 + 0x541E001C, // 02D1 LDINT R7 29 + 0x1C1C0A07, // 02D2 EQ R7 R5 R7 + 0x781E0050, // 02D3 JMPF R7 #0325 + 0x1C1C0D05, // 02D4 EQ R7 R6 K5 + 0x781E0019, // 02D5 JMPF R7 #02F0 + 0x8C1C0912, // 02D6 GETMET R7 R4 K18 + 0x7C1C0200, // 02D7 CALL R7 1 + 0x60200010, // 02D8 GETGBL R8 G16 + 0x8824014D, // 02D9 GETMBR R9 R0 K77 + 0x7C200200, // 02DA CALL R8 1 + 0xA802000E, // 02DB EXBLK 0 #02EB + 0x5C241000, // 02DC MOVE R9 R8 + 0x7C240000, // 02DD CALL R9 0 + 0x8C280F16, // 02DE GETMET R10 R7 K22 + 0x7C280200, // 02DF CALL R10 1 + 0x8C2C150C, // 02E0 GETMET R11 R10 K12 + 0x58340005, // 02E1 LDCONST R13 K5 + 0x8838090D, // 02E2 GETMBR R14 R4 K13 + 0x5C3C1200, // 02E3 MOVE R15 R9 + 0x7C2C0800, // 02E4 CALL R11 4 + 0x8C2C150C, // 02E5 GETMET R11 R10 K12 + 0x5834000A, // 02E6 LDCONST R13 K10 + 0x8838090D, // 02E7 GETMBR R14 R4 K13 + 0x583C000A, // 02E8 LDCONST R15 K10 + 0x7C2C0800, // 02E9 CALL R11 4 + 0x7001FFF0, // 02EA JMP #02DC + 0x5820003A, // 02EB LDCONST R8 K58 + 0xAC200200, // 02EC CATCH R8 1 0 + 0xB0080000, // 02ED RAISE 2 R0 R0 + 0x80040E00, // 02EE RET 1 R7 + 0x70020033, // 02EF JMP #0324 + 0x1C1C0D0A, // 02F0 EQ R7 R6 K10 + 0x781E0013, // 02F1 JMPF R7 #0306 + 0x8C1C0912, // 02F2 GETMET R7 R4 K18 + 0x7C1C0200, // 02F3 CALL R7 1 + 0x60200010, // 02F4 GETGBL R8 G16 + 0x8C24014E, // 02F5 GETMET R9 R0 K78 + 0x7C240200, // 02F6 CALL R9 1 + 0x7C200200, // 02F7 CALL R8 1 + 0xA8020007, // 02F8 EXBLK 0 #0301 + 0x5C241000, // 02F9 MOVE R9 R8 + 0x7C240000, // 02FA CALL R9 0 + 0x8C280F0C, // 02FB GETMET R10 R7 K12 + 0x4C300000, // 02FC LDNIL R12 + 0x8834092B, // 02FD GETMBR R13 R4 K43 + 0x5C381200, // 02FE MOVE R14 R9 + 0x7C280800, // 02FF CALL R10 4 + 0x7001FFF7, // 0300 JMP #02F9 + 0x5820003A, // 0301 LDCONST R8 K58 + 0xAC200200, // 0302 CATCH R8 1 0 + 0xB0080000, // 0303 RAISE 2 R0 R0 + 0x80040E00, // 0304 RET 1 R7 + 0x7002001D, // 0305 JMP #0324 + 0x1C1C0D0E, // 0306 EQ R7 R6 K14 + 0x781E0003, // 0307 JMPF R7 #030C + 0x8C1C0912, // 0308 GETMET R7 R4 K18 + 0x7C1C0200, // 0309 CALL R7 1 + 0x80040E00, // 030A RET 1 R7 + 0x70020017, // 030B JMP #0324 + 0x1C1C0D10, // 030C EQ R7 R6 K16 + 0x781E0015, // 030D JMPF R7 #0324 + 0x881C0134, // 030E GETMBR R7 R0 K52 + 0x8C1C0F4F, // 030F GETMET R7 R7 K79 + 0x50240200, // 0310 LDBOOL R9 1 0 + 0x7C1C0400, // 0311 CALL R7 2 + 0x8C200912, // 0312 GETMET R8 R4 K18 + 0x7C200200, // 0313 CALL R8 1 + 0x60240010, // 0314 GETGBL R9 G16 + 0x5C280E00, // 0315 MOVE R10 R7 + 0x7C240200, // 0316 CALL R9 1 + 0xA8020007, // 0317 EXBLK 0 #0320 + 0x5C281200, // 0318 MOVE R10 R9 + 0x7C280000, // 0319 CALL R10 0 + 0x8C2C110C, // 031A GETMET R11 R8 K12 + 0x4C340000, // 031B LDNIL R13 + 0x8838090D, // 031C GETMBR R14 R4 K13 + 0x5C3C1400, // 031D MOVE R15 R10 + 0x7C2C0800, // 031E CALL R11 4 + 0x7001FFF7, // 031F JMP #0318 + 0x5824003A, // 0320 LDCONST R9 K58 + 0xAC240200, // 0321 CATCH R9 1 0 + 0xB0080000, // 0322 RAISE 2 R0 R0 + 0x80041000, // 0323 RET 1 R8 + 0x70020002, // 0324 JMP #0328 + 0xB81E0200, // 0325 GETNGBL R7 K1 + 0x881C0F51, // 0326 GETMBR R7 R7 K81 + 0x900AA007, // 0327 SETMBR R2 K80 R7 + 0x80000000, // 0328 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: write_attribute +********************************************************************/ +be_local_closure(Matter_Plugin_Root_write_attribute, /* name */ + be_nested_proto( + 11, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[14]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(TLV), + /* K3 */ be_nested_str_weak(cluster), + /* K4 */ be_nested_str_weak(attribute), + /* K5 */ be_const_int(0), + /* K6 */ be_nested_str_weak(int), + /* K7 */ be_nested_str_weak(int64), + /* K8 */ be_nested_str_weak(session), + /* K9 */ be_nested_str_weak(__breadcrumb), + /* K10 */ be_nested_str_weak(status), + /* K11 */ be_nested_str_weak(CONSTRAINT_ERROR), + /* K12 */ be_const_int(1), + /* K13 */ be_nested_str_weak(INVALID_ACTION), + }), + be_str_weak(write_attribute), + &be_const_str_solidified, + ( &(const binstruction[98]) { /* code */ + 0xA4120000, // 0000 IMPORT R4 K0 + 0xB8160200, // 0001 GETNGBL R5 K1 + 0x88140B02, // 0002 GETMBR R5 R5 K2 + 0x88180503, // 0003 GETMBR R6 R2 K3 + 0x881C0504, // 0004 GETMBR R7 R2 K4 + 0x5422002F, // 0005 LDINT R8 48 + 0x1C200C08, // 0006 EQ R8 R6 R8 + 0x78220016, // 0007 JMPF R8 #001F + 0x1C200F05, // 0008 EQ R8 R7 K5 + 0x78220013, // 0009 JMPF R8 #001E + 0x60200004, // 000A GETGBL R8 G4 + 0x5C240600, // 000B MOVE R9 R3 + 0x7C200200, // 000C CALL R8 1 + 0x1C201106, // 000D EQ R8 R8 K6 + 0x74220004, // 000E JMPT R8 #0014 + 0x6020000F, // 000F GETGBL R8 G15 + 0x5C240600, // 0010 MOVE R9 R3 + 0xB82A0E00, // 0011 GETNGBL R10 K7 + 0x7C200400, // 0012 CALL R8 2 + 0x78220004, // 0013 JMPF R8 #0019 + 0x88200308, // 0014 GETMBR R8 R1 K8 + 0x90221203, // 0015 SETMBR R8 K9 R3 + 0x50200200, // 0016 LDBOOL R8 1 0 + 0x80041000, // 0017 RET 1 R8 + 0x70020004, // 0018 JMP #001E + 0xB8220200, // 0019 GETNGBL R8 K1 + 0x8820110B, // 001A GETMBR R8 R8 K11 + 0x900A1408, // 001B SETMBR R2 K10 R8 + 0x50200000, // 001C LDBOOL R8 0 0 + 0x80041000, // 001D RET 1 R8 + 0x70020041, // 001E JMP #0061 + 0x5422001E, // 001F LDINT R8 31 + 0x1C200C08, // 0020 EQ R8 R6 R8 + 0x78220004, // 0021 JMPF R8 #0027 + 0x1C200F05, // 0022 EQ R8 R7 K5 + 0x78220001, // 0023 JMPF R8 #0026 + 0x50200200, // 0024 LDBOOL R8 1 0 + 0x80041000, // 0025 RET 1 R8 + 0x70020039, // 0026 JMP #0061 + 0x54220027, // 0027 LDINT R8 40 + 0x1C200C08, // 0028 EQ R8 R6 R8 + 0x7822000B, // 0029 JMPF R8 #0036 + 0x54220004, // 002A LDINT R8 5 + 0x1C200E08, // 002B EQ R8 R7 R8 + 0x78220002, // 002C JMPF R8 #0030 + 0x50200200, // 002D LDBOOL R8 1 0 + 0x80041000, // 002E RET 1 R8 + 0x70020004, // 002F JMP #0035 + 0x54220005, // 0030 LDINT R8 6 + 0x1C200E08, // 0031 EQ R8 R7 R8 + 0x78220001, // 0032 JMPF R8 #0035 + 0x50200200, // 0033 LDBOOL R8 1 0 + 0x80041000, // 0034 RET 1 R8 + 0x7002002A, // 0035 JMP #0061 + 0x54220029, // 0036 LDINT R8 42 + 0x1C200C08, // 0037 EQ R8 R6 R8 + 0x78220004, // 0038 JMPF R8 #003E + 0x1C200F05, // 0039 EQ R8 R7 K5 + 0x78220001, // 003A JMPF R8 #003D + 0x50200200, // 003B LDBOOL R8 1 0 + 0x80041000, // 003C RET 1 R8 + 0x70020022, // 003D JMP #0061 + 0x5422002A, // 003E LDINT R8 43 + 0x1C200C08, // 003F EQ R8 R6 R8 + 0x78220007, // 0040 JMPF R8 #0049 + 0x1C200F05, // 0041 EQ R8 R7 K5 + 0x78220004, // 0042 JMPF R8 #0048 + 0xB8220200, // 0043 GETNGBL R8 K1 + 0x8820110B, // 0044 GETMBR R8 R8 K11 + 0x900A1408, // 0045 SETMBR R2 K10 R8 + 0x50200000, // 0046 LDBOOL R8 0 0 + 0x80041000, // 0047 RET 1 R8 + 0x70020017, // 0048 JMP #0061 + 0x5422002B, // 0049 LDINT R8 44 + 0x1C200C08, // 004A EQ R8 R6 R8 + 0x78220009, // 004B JMPF R8 #0056 + 0x1C200F05, // 004C EQ R8 R7 K5 + 0x78220002, // 004D JMPF R8 #0051 + 0x50200200, // 004E LDBOOL R8 1 0 + 0x80041000, // 004F RET 1 R8 + 0x70020003, // 0050 JMP #0055 + 0x1C200F0C, // 0051 EQ R8 R7 K12 + 0x78220001, // 0052 JMPF R8 #0055 + 0x50200200, // 0053 LDBOOL R8 1 0 + 0x80041000, // 0054 RET 1 R8 + 0x7002000A, // 0055 JMP #0061 + 0x54220030, // 0056 LDINT R8 49 + 0x1C200C08, // 0057 EQ R8 R6 R8 + 0x78220007, // 0058 JMPF R8 #0061 + 0x54220003, // 0059 LDINT R8 4 + 0x1C200E08, // 005A EQ R8 R7 R8 + 0x78220004, // 005B JMPF R8 #0061 + 0xB8220200, // 005C GETNGBL R8 K1 + 0x8820110D, // 005D GETMBR R8 R8 K13 + 0x900A1408, // 005E SETMBR R2 K10 R8 + 0x50200000, // 005F LDBOOL R8 0 0 + 0x80041000, // 0060 RET 1 R8 + 0x80000000, // 0061 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_Plugin_Root_init, /* name */ + be_nested_proto( + 5, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(init), + /* K1 */ be_nested_str_weak(endpoints), + /* K2 */ be_nested_str_weak(ENDPOINTS), + /* K3 */ be_nested_str_weak(clusters), + /* K4 */ be_nested_str_weak(CLUSTERS), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[11]) { /* 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 + 0x88080102, // 0006 GETMBR R2 R0 K2 + 0x90020202, // 0007 SETMBR R0 K1 R2 + 0x88080104, // 0008 GETMBR R2 R0 K4 + 0x90020602, // 0009 SETMBR R0 K3 R2 + 0x80000000, // 000A RET 0 + }) + ) +); +/*******************************************************************/ + /******************************************************************** ** Solidified function: invoke_request ********************************************************************/ -be_local_closure(Matter_Plugin_core_invoke_request, /* name */ +be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ be_nested_proto( 29, /* nstack */ 4, /* argc */ @@ -29,7 +1120,7 @@ be_local_closure(Matter_Plugin_core_invoke_request, /* name */ /* K6 */ be_const_int(0), /* K7 */ be_nested_str_weak(findsubval), /* K8 */ be_const_int(1), - /* K9 */ be_nested_str_weak(breadcrumb), + /* K9 */ be_nested_str_weak(__breadcrumb), /* K10 */ be_nested_str_weak(Matter_TLV_struct), /* K11 */ be_nested_str_weak(add_TLV), /* K12 */ be_nested_str_weak(U1), @@ -599,952 +1690,30 @@ be_local_closure(Matter_Plugin_core_invoke_request, /* name */ /******************************************************************** -** Solidified function: read_attribute -********************************************************************/ -be_local_closure(Matter_Plugin_core_read_attribute, /* name */ - be_nested_proto( - 24, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[82]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(TLV), - /* K3 */ be_nested_str_weak(cluster), - /* K4 */ be_nested_str_weak(attribute), - /* K5 */ be_const_int(0), - /* K6 */ be_nested_str_weak(create_TLV), - /* K7 */ be_nested_str_weak(U8), - /* K8 */ be_nested_str_weak(session), - /* K9 */ be_nested_str_weak(breadcrumb), - /* K10 */ be_const_int(1), - /* K11 */ be_nested_str_weak(Matter_TLV_struct), - /* K12 */ be_nested_str_weak(add_TLV), - /* K13 */ be_nested_str_weak(U2), - /* K14 */ be_const_int(2), - /* K15 */ be_nested_str_weak(U1), - /* K16 */ be_const_int(3), - /* K17 */ be_nested_str_weak(BOOL), - /* K18 */ be_nested_str_weak(Matter_TLV_array), - /* K19 */ be_nested_str_weak(tasmota), - /* K20 */ be_nested_str_weak(eth), - /* K21 */ be_nested_str_weak(up), - /* K22 */ be_nested_str_weak(add_struct), - /* K23 */ be_nested_str_weak(UTF1), - /* K24 */ be_nested_str_weak(ethernet), - /* K25 */ be_nested_str_weak(NULL), - /* K26 */ be_nested_str_weak(fromhex), - /* K27 */ be_nested_str_weak(replace), - /* K28 */ be_nested_str_weak(find), - /* K29 */ be_nested_str_weak(mac), - /* K30 */ be_nested_str_weak(), - /* K31 */ be_nested_str_weak(_X3A), - /* K32 */ be_nested_str_weak(B1), - /* K33 */ be_nested_str_weak(add_array), - /* K34 */ be_nested_str_weak(get_ip_bytes), - /* K35 */ be_nested_str_weak(ip), - /* K36 */ be_nested_str_weak(ip6local), - /* K37 */ be_nested_str_weak(ip6), - /* K38 */ be_nested_str_weak(wifi), - /* K39 */ be_nested_str_weak(cmd), - /* K40 */ be_nested_str_weak(Status_X201), - /* K41 */ be_nested_str_weak(StatusPRM), - /* K42 */ be_nested_str_weak(BootCount), - /* K43 */ be_nested_str_weak(U4), - /* K44 */ be_nested_str_weak(Status_X2011), - /* K45 */ be_nested_str_weak(StatusSTS), - /* K46 */ be_nested_str_weak(UptimeSec), - /* K47 */ be_nested_str_weak(int64), - /* K48 */ be_nested_str_weak(rtc), - /* K49 */ be_nested_str_weak(utc), - /* K50 */ be_const_int(1000000), - /* K51 */ be_nested_str_weak(local), - /* K52 */ be_nested_str_weak(device), - /* K53 */ be_nested_str_weak(sessions), - /* K54 */ be_nested_str_weak(sessions_active), - /* K55 */ be_nested_str_weak(B2), - /* K56 */ be_nested_str_weak(noc), - /* K57 */ be_nested_str_weak(icac), - /* K58 */ be_nested_str_weak(stop_iteration), - /* K59 */ be_nested_str_weak(parse), - /* K60 */ be_nested_str_weak(get_ca), - /* K61 */ be_nested_str_weak(findsubval), - /* K62 */ be_nested_str_weak(admin_vendor), - /* K63 */ be_nested_str_weak(fabric), - /* K64 */ be_nested_str_weak(deviceid), - /* K65 */ be_nested_str_weak(fabric_label), - /* K66 */ be_nested_str_weak(Tasmota), - /* K67 */ be_nested_str_weak(vendorid), - /* K68 */ be_nested_str_weak(DeviceName), - /* K69 */ be_nested_str_weak(FriendlyName), - /* K70 */ be_nested_str_weak(FriendlyName1), - /* K71 */ be_nested_str_weak(XX), - /* K72 */ be_nested_str_weak(Status_X202), - /* K73 */ be_nested_str_weak(StatusFWR), - /* K74 */ be_nested_str_weak(Hardware), - /* K75 */ be_nested_str_weak(Version), - /* K76 */ be_nested_str_weak(locale), - /* K77 */ be_nested_str_weak(Matter_TLV_list), - /* K78 */ be_nested_str_weak(get_cluster_list), - /* K79 */ be_nested_str_weak(get_active_endpoints), - /* K80 */ be_nested_str_weak(status), - /* K81 */ be_nested_str_weak(UNSUPPORTED_CLUSTER), - }), - be_str_weak(read_attribute), - &be_const_str_solidified, - ( &(const binstruction[736]) { /* code */ - 0xA40E0000, // 0000 IMPORT R3 K0 - 0xB8120200, // 0001 GETNGBL R4 K1 - 0x88100902, // 0002 GETMBR R4 R4 K2 - 0x88140503, // 0003 GETMBR R5 R2 K3 - 0x88180504, // 0004 GETMBR R6 R2 K4 - 0x541E002F, // 0005 LDINT R7 48 - 0x1C1C0A07, // 0006 EQ R7 R5 R7 - 0x781E0031, // 0007 JMPF R7 #003A - 0x1C1C0D05, // 0008 EQ R7 R6 K5 - 0x781E0006, // 0009 JMPF R7 #0011 - 0x8C1C0906, // 000A GETMET R7 R4 K6 - 0x88240907, // 000B GETMBR R9 R4 K7 - 0x88280308, // 000C GETMBR R10 R1 K8 - 0x88281509, // 000D GETMBR R10 R10 K9 - 0x7C1C0600, // 000E CALL R7 3 - 0x80040E00, // 000F RET 1 R7 - 0x70020027, // 0010 JMP #0039 - 0x1C1C0D0A, // 0011 EQ R7 R6 K10 - 0x781E000D, // 0012 JMPF R7 #0021 - 0x8C1C090B, // 0013 GETMET R7 R4 K11 - 0x7C1C0200, // 0014 CALL R7 1 - 0x8C200F0C, // 0015 GETMET R8 R7 K12 - 0x58280005, // 0016 LDCONST R10 K5 - 0x882C090D, // 0017 GETMBR R11 R4 K13 - 0x5432003B, // 0018 LDINT R12 60 - 0x7C200800, // 0019 CALL R8 4 - 0x8C200F0C, // 001A GETMET R8 R7 K12 - 0x5828000A, // 001B LDCONST R10 K10 - 0x882C090D, // 001C GETMBR R11 R4 K13 - 0x54320383, // 001D LDINT R12 900 - 0x7C200800, // 001E CALL R8 4 - 0x80040E00, // 001F RET 1 R7 - 0x70020017, // 0020 JMP #0039 - 0x1C1C0D0E, // 0021 EQ R7 R6 K14 - 0x781E0005, // 0022 JMPF R7 #0029 - 0x8C1C0906, // 0023 GETMET R7 R4 K6 - 0x8824090F, // 0024 GETMBR R9 R4 K15 - 0x5828000E, // 0025 LDCONST R10 K14 - 0x7C1C0600, // 0026 CALL R7 3 - 0x80040E00, // 0027 RET 1 R7 - 0x7002000F, // 0028 JMP #0039 - 0x1C1C0D10, // 0029 EQ R7 R6 K16 - 0x781E0005, // 002A JMPF R7 #0031 - 0x8C1C0906, // 002B GETMET R7 R4 K6 - 0x8824090F, // 002C GETMBR R9 R4 K15 - 0x5828000E, // 002D LDCONST R10 K14 - 0x7C1C0600, // 002E CALL R7 3 - 0x80040E00, // 002F RET 1 R7 - 0x70020007, // 0030 JMP #0039 - 0x541E0003, // 0031 LDINT R7 4 - 0x1C1C0C07, // 0032 EQ R7 R6 R7 - 0x781E0004, // 0033 JMPF R7 #0039 - 0x8C1C0906, // 0034 GETMET R7 R4 K6 - 0x88240911, // 0035 GETMBR R9 R4 K17 - 0x50280000, // 0036 LDBOOL R10 0 0 - 0x7C1C0600, // 0037 CALL R7 3 - 0x80040E00, // 0038 RET 1 R7 - 0x700202A4, // 0039 JMP #02DF - 0x541E0031, // 003A LDINT R7 50 - 0x1C1C0A07, // 003B EQ R7 R5 R7 - 0x781E0000, // 003C JMPF R7 #003E - 0x700202A0, // 003D JMP #02DF - 0x541E0032, // 003E LDINT R7 51 - 0x1C1C0A07, // 003F EQ R7 R5 R7 - 0x781E00DA, // 0040 JMPF R7 #011C - 0x1C1C0D05, // 0041 EQ R7 R6 K5 - 0x781E00B5, // 0042 JMPF R7 #00F9 - 0x8C1C0912, // 0043 GETMET R7 R4 K18 - 0x7C1C0200, // 0044 CALL R7 1 - 0xB8222600, // 0045 GETNGBL R8 K19 - 0x8C201114, // 0046 GETMET R8 R8 K20 - 0x7C200200, // 0047 CALL R8 1 - 0x94241115, // 0048 GETIDX R9 R8 K21 - 0x78260053, // 0049 JMPF R9 #009E - 0x8C240F16, // 004A GETMET R9 R7 K22 - 0x4C2C0000, // 004B LDNIL R11 - 0x7C240400, // 004C CALL R9 2 - 0x8C28130C, // 004D GETMET R10 R9 K12 - 0x58300005, // 004E LDCONST R12 K5 - 0x88340917, // 004F GETMBR R13 R4 K23 - 0x58380018, // 0050 LDCONST R14 K24 - 0x7C280800, // 0051 CALL R10 4 - 0x8C28130C, // 0052 GETMET R10 R9 K12 - 0x5830000A, // 0053 LDCONST R12 K10 - 0x88340911, // 0054 GETMBR R13 R4 K17 - 0x5838000A, // 0055 LDCONST R14 K10 - 0x7C280800, // 0056 CALL R10 4 - 0x8C28130C, // 0057 GETMET R10 R9 K12 - 0x5830000E, // 0058 LDCONST R12 K14 - 0x88340911, // 0059 GETMBR R13 R4 K17 - 0x5838000A, // 005A LDCONST R14 K10 - 0x7C280800, // 005B CALL R10 4 - 0x8C28130C, // 005C GETMET R10 R9 K12 - 0x58300010, // 005D LDCONST R12 K16 - 0x88340919, // 005E GETMBR R13 R4 K25 - 0x4C380000, // 005F LDNIL R14 - 0x7C280800, // 0060 CALL R10 4 - 0x60280015, // 0061 GETGBL R10 G21 - 0x7C280000, // 0062 CALL R10 0 - 0x8C28151A, // 0063 GETMET R10 R10 K26 - 0x8C30071B, // 0064 GETMET R12 R3 K27 - 0x8C38111C, // 0065 GETMET R14 R8 K28 - 0x5840001D, // 0066 LDCONST R16 K29 - 0x5844001E, // 0067 LDCONST R17 K30 - 0x7C380600, // 0068 CALL R14 3 - 0x583C001F, // 0069 LDCONST R15 K31 - 0x5840001E, // 006A LDCONST R16 K30 - 0x7C300800, // 006B CALL R12 4 - 0x7C280400, // 006C CALL R10 2 - 0x8C2C130C, // 006D GETMET R11 R9 K12 - 0x54360003, // 006E LDINT R13 4 - 0x88380920, // 006F GETMBR R14 R4 K32 - 0x5C3C1400, // 0070 MOVE R15 R10 - 0x7C2C0800, // 0071 CALL R11 4 - 0x8C2C1321, // 0072 GETMET R11 R9 K33 - 0x54360004, // 0073 LDINT R13 5 - 0x7C2C0400, // 0074 CALL R11 2 - 0x8C30170C, // 0075 GETMET R12 R11 K12 - 0x4C380000, // 0076 LDNIL R14 - 0x883C0920, // 0077 GETMBR R15 R4 K32 - 0xB8420200, // 0078 GETNGBL R16 K1 - 0x8C402122, // 0079 GETMET R16 R16 K34 - 0x8C48111C, // 007A GETMET R18 R8 K28 - 0x58500023, // 007B LDCONST R20 K35 - 0x5854001E, // 007C LDCONST R21 K30 - 0x7C480600, // 007D CALL R18 3 - 0x7C400400, // 007E CALL R16 2 - 0x7C300800, // 007F CALL R12 4 - 0x8C301321, // 0080 GETMET R12 R9 K33 - 0x543A0005, // 0081 LDINT R14 6 - 0x7C300400, // 0082 CALL R12 2 - 0x8C34190C, // 0083 GETMET R13 R12 K12 - 0x4C3C0000, // 0084 LDNIL R15 - 0x88400920, // 0085 GETMBR R16 R4 K32 - 0xB8460200, // 0086 GETNGBL R17 K1 - 0x8C442322, // 0087 GETMET R17 R17 K34 - 0x8C4C111C, // 0088 GETMET R19 R8 K28 - 0x58540024, // 0089 LDCONST R21 K36 - 0x5858001E, // 008A LDCONST R22 K30 - 0x7C4C0600, // 008B CALL R19 3 - 0x7C440400, // 008C CALL R17 2 - 0x7C340800, // 008D CALL R13 4 - 0x8C34190C, // 008E GETMET R13 R12 K12 - 0x4C3C0000, // 008F LDNIL R15 - 0x88400920, // 0090 GETMBR R16 R4 K32 - 0xB8460200, // 0091 GETNGBL R17 K1 - 0x8C442322, // 0092 GETMET R17 R17 K34 - 0x8C4C111C, // 0093 GETMET R19 R8 K28 - 0x58540025, // 0094 LDCONST R21 K37 - 0x5858001E, // 0095 LDCONST R22 K30 - 0x7C4C0600, // 0096 CALL R19 3 - 0x7C440400, // 0097 CALL R17 2 - 0x7C340800, // 0098 CALL R13 4 - 0x8C34130C, // 0099 GETMET R13 R9 K12 - 0x543E0006, // 009A LDINT R15 7 - 0x8840090F, // 009B GETMBR R16 R4 K15 - 0x5844000E, // 009C LDCONST R17 K14 - 0x7C340800, // 009D CALL R13 4 - 0xB8262600, // 009E GETNGBL R9 K19 - 0x8C241326, // 009F GETMET R9 R9 K38 - 0x7C240200, // 00A0 CALL R9 1 - 0x94281315, // 00A1 GETIDX R10 R9 K21 - 0x782A0053, // 00A2 JMPF R10 #00F7 - 0x8C280F16, // 00A3 GETMET R10 R7 K22 - 0x4C300000, // 00A4 LDNIL R12 - 0x7C280400, // 00A5 CALL R10 2 - 0x8C2C150C, // 00A6 GETMET R11 R10 K12 - 0x58340005, // 00A7 LDCONST R13 K5 - 0x88380917, // 00A8 GETMBR R14 R4 K23 - 0x583C0026, // 00A9 LDCONST R15 K38 - 0x7C2C0800, // 00AA CALL R11 4 - 0x8C2C150C, // 00AB GETMET R11 R10 K12 - 0x5834000A, // 00AC LDCONST R13 K10 - 0x88380911, // 00AD GETMBR R14 R4 K17 - 0x583C000A, // 00AE LDCONST R15 K10 - 0x7C2C0800, // 00AF CALL R11 4 - 0x8C2C150C, // 00B0 GETMET R11 R10 K12 - 0x5834000E, // 00B1 LDCONST R13 K14 - 0x88380911, // 00B2 GETMBR R14 R4 K17 - 0x583C000A, // 00B3 LDCONST R15 K10 - 0x7C2C0800, // 00B4 CALL R11 4 - 0x8C2C150C, // 00B5 GETMET R11 R10 K12 - 0x58340010, // 00B6 LDCONST R13 K16 - 0x88380919, // 00B7 GETMBR R14 R4 K25 - 0x4C3C0000, // 00B8 LDNIL R15 - 0x7C2C0800, // 00B9 CALL R11 4 - 0x602C0015, // 00BA GETGBL R11 G21 - 0x7C2C0000, // 00BB CALL R11 0 - 0x8C2C171A, // 00BC GETMET R11 R11 K26 - 0x8C34071B, // 00BD GETMET R13 R3 K27 - 0x8C3C131C, // 00BE GETMET R15 R9 K28 - 0x5844001D, // 00BF LDCONST R17 K29 - 0x5848001E, // 00C0 LDCONST R18 K30 - 0x7C3C0600, // 00C1 CALL R15 3 - 0x5840001F, // 00C2 LDCONST R16 K31 - 0x5844001E, // 00C3 LDCONST R17 K30 - 0x7C340800, // 00C4 CALL R13 4 - 0x7C2C0400, // 00C5 CALL R11 2 - 0x8C30150C, // 00C6 GETMET R12 R10 K12 - 0x543A0003, // 00C7 LDINT R14 4 - 0x883C0920, // 00C8 GETMBR R15 R4 K32 - 0x5C401600, // 00C9 MOVE R16 R11 - 0x7C300800, // 00CA CALL R12 4 - 0x8C301521, // 00CB GETMET R12 R10 K33 - 0x543A0004, // 00CC LDINT R14 5 - 0x7C300400, // 00CD CALL R12 2 - 0x8C34190C, // 00CE GETMET R13 R12 K12 - 0x4C3C0000, // 00CF LDNIL R15 - 0x88400920, // 00D0 GETMBR R16 R4 K32 - 0xB8460200, // 00D1 GETNGBL R17 K1 - 0x8C442322, // 00D2 GETMET R17 R17 K34 - 0x8C4C131C, // 00D3 GETMET R19 R9 K28 - 0x58540023, // 00D4 LDCONST R21 K35 - 0x5858001E, // 00D5 LDCONST R22 K30 - 0x7C4C0600, // 00D6 CALL R19 3 - 0x7C440400, // 00D7 CALL R17 2 - 0x7C340800, // 00D8 CALL R13 4 - 0x8C341521, // 00D9 GETMET R13 R10 K33 - 0x543E0005, // 00DA LDINT R15 6 - 0x7C340400, // 00DB CALL R13 2 - 0x8C381B0C, // 00DC GETMET R14 R13 K12 - 0x4C400000, // 00DD LDNIL R16 - 0x88440920, // 00DE GETMBR R17 R4 K32 - 0xB84A0200, // 00DF GETNGBL R18 K1 - 0x8C482522, // 00E0 GETMET R18 R18 K34 - 0x8C50131C, // 00E1 GETMET R20 R9 K28 - 0x58580024, // 00E2 LDCONST R22 K36 - 0x585C001E, // 00E3 LDCONST R23 K30 - 0x7C500600, // 00E4 CALL R20 3 - 0x7C480400, // 00E5 CALL R18 2 - 0x7C380800, // 00E6 CALL R14 4 - 0x8C381B0C, // 00E7 GETMET R14 R13 K12 - 0x4C400000, // 00E8 LDNIL R16 - 0x88440920, // 00E9 GETMBR R17 R4 K32 - 0xB84A0200, // 00EA GETNGBL R18 K1 - 0x8C482522, // 00EB GETMET R18 R18 K34 - 0x8C50131C, // 00EC GETMET R20 R9 K28 - 0x58580025, // 00ED LDCONST R22 K37 - 0x585C001E, // 00EE LDCONST R23 K30 - 0x7C500600, // 00EF CALL R20 3 - 0x7C480400, // 00F0 CALL R18 2 - 0x7C380800, // 00F1 CALL R14 4 - 0x8C38150C, // 00F2 GETMET R14 R10 K12 - 0x54420006, // 00F3 LDINT R16 7 - 0x8844090F, // 00F4 GETMBR R17 R4 K15 - 0x5848000A, // 00F5 LDCONST R18 K10 - 0x7C380800, // 00F6 CALL R14 4 - 0x80040E00, // 00F7 RET 1 R7 - 0x70020021, // 00F8 JMP #011B - 0x1C1C0D0A, // 00F9 EQ R7 R6 K10 - 0x781E000A, // 00FA JMPF R7 #0106 - 0x8C1C0906, // 00FB GETMET R7 R4 K6 - 0x8824090D, // 00FC GETMBR R9 R4 K13 - 0xB82A2600, // 00FD GETNGBL R10 K19 - 0x8C281527, // 00FE GETMET R10 R10 K39 - 0x58300028, // 00FF LDCONST R12 K40 - 0x7C280400, // 0100 CALL R10 2 - 0x94281529, // 0101 GETIDX R10 R10 K41 - 0x9428152A, // 0102 GETIDX R10 R10 K42 - 0x7C1C0600, // 0103 CALL R7 3 - 0x80040E00, // 0104 RET 1 R7 - 0x70020014, // 0105 JMP #011B - 0x1C1C0D0E, // 0106 EQ R7 R6 K14 - 0x781E000A, // 0107 JMPF R7 #0113 - 0x8C1C0906, // 0108 GETMET R7 R4 K6 - 0x8824092B, // 0109 GETMBR R9 R4 K43 - 0xB82A2600, // 010A GETNGBL R10 K19 - 0x8C281527, // 010B GETMET R10 R10 K39 - 0x5830002C, // 010C LDCONST R12 K44 - 0x7C280400, // 010D CALL R10 2 - 0x9428152D, // 010E GETIDX R10 R10 K45 - 0x9428152E, // 010F GETIDX R10 R10 K46 - 0x7C1C0600, // 0110 CALL R7 3 - 0x80040E00, // 0111 RET 1 R7 - 0x70020007, // 0112 JMP #011B - 0x541E0007, // 0113 LDINT R7 8 - 0x1C1C0C07, // 0114 EQ R7 R6 R7 - 0x781E0004, // 0115 JMPF R7 #011B - 0x8C1C0906, // 0116 GETMET R7 R4 K6 - 0x88240911, // 0117 GETMBR R9 R4 K17 - 0x50280000, // 0118 LDBOOL R10 0 0 - 0x7C1C0600, // 0119 CALL R7 3 - 0x80040E00, // 011A RET 1 R7 - 0x700201C2, // 011B JMP #02DF - 0x541E0033, // 011C LDINT R7 52 - 0x1C1C0A07, // 011D EQ R7 R5 R7 - 0x781E0000, // 011E JMPF R7 #0120 - 0x700201BE, // 011F JMP #02DF - 0x541E0037, // 0120 LDINT R7 56 - 0x1C1C0A07, // 0121 EQ R7 R5 R7 - 0x781E002C, // 0122 JMPF R7 #0150 - 0x1C1C0D05, // 0123 EQ R7 R6 K5 - 0x781E000F, // 0124 JMPF R7 #0135 - 0xB81E5E00, // 0125 GETNGBL R7 K47 - 0xB8222600, // 0126 GETNGBL R8 K19 - 0x8C201130, // 0127 GETMET R8 R8 K48 - 0x7C200200, // 0128 CALL R8 1 - 0x94201131, // 0129 GETIDX R8 R8 K49 - 0x7C1C0200, // 012A CALL R7 1 - 0xB8225E00, // 012B GETNGBL R8 K47 - 0x58240032, // 012C LDCONST R9 K50 - 0x7C200200, // 012D CALL R8 1 - 0x081C0E08, // 012E MUL R7 R7 R8 - 0x8C200906, // 012F GETMET R8 R4 K6 - 0x88280907, // 0130 GETMBR R10 R4 K7 - 0x5C2C0E00, // 0131 MOVE R11 R7 - 0x7C200600, // 0132 CALL R8 3 - 0x80041000, // 0133 RET 1 R8 - 0x70020019, // 0134 JMP #014F - 0x1C1C0D0A, // 0135 EQ R7 R6 K10 - 0x781E0005, // 0136 JMPF R7 #013D - 0x8C1C0906, // 0137 GETMET R7 R4 K6 - 0x8824090F, // 0138 GETMBR R9 R4 K15 - 0x58280010, // 0139 LDCONST R10 K16 - 0x7C1C0600, // 013A CALL R7 3 - 0x80040E00, // 013B RET 1 R7 - 0x70020011, // 013C JMP #014F - 0x541E0006, // 013D LDINT R7 7 - 0x1C1C0C07, // 013E EQ R7 R6 R7 - 0x781E000E, // 013F JMPF R7 #014F - 0xB81E5E00, // 0140 GETNGBL R7 K47 - 0xB8222600, // 0141 GETNGBL R8 K19 - 0x8C201130, // 0142 GETMET R8 R8 K48 - 0x7C200200, // 0143 CALL R8 1 - 0x94201133, // 0144 GETIDX R8 R8 K51 - 0x7C1C0200, // 0145 CALL R7 1 - 0xB8225E00, // 0146 GETNGBL R8 K47 - 0x58240032, // 0147 LDCONST R9 K50 - 0x7C200200, // 0148 CALL R8 1 - 0x081C0E08, // 0149 MUL R7 R7 R8 - 0x8C200906, // 014A GETMET R8 R4 K6 - 0x88280907, // 014B GETMBR R10 R4 K7 - 0x5C2C0E00, // 014C MOVE R11 R7 - 0x7C200600, // 014D CALL R8 3 - 0x80041000, // 014E RET 1 R8 - 0x7002018E, // 014F JMP #02DF - 0x541E003D, // 0150 LDINT R7 62 - 0x1C1C0A07, // 0151 EQ R7 R5 R7 - 0x781E0082, // 0152 JMPF R7 #01D6 - 0x1C1C0D05, // 0153 EQ R7 R6 K5 - 0x781E001D, // 0154 JMPF R7 #0173 - 0x8C1C0912, // 0155 GETMET R7 R4 K18 - 0x7C1C0200, // 0156 CALL R7 1 - 0x60200010, // 0157 GETGBL R8 G16 - 0x88240134, // 0158 GETMBR R9 R0 K52 - 0x88241335, // 0159 GETMBR R9 R9 K53 - 0x8C241336, // 015A GETMET R9 R9 K54 - 0x7C240200, // 015B CALL R9 1 - 0x7C200200, // 015C CALL R8 1 - 0xA802000F, // 015D EXBLK 0 #016E - 0x5C241000, // 015E MOVE R9 R8 - 0x7C240000, // 015F CALL R9 0 - 0x8C280F16, // 0160 GETMET R10 R7 K22 - 0x4C300000, // 0161 LDNIL R12 - 0x7C280400, // 0162 CALL R10 2 - 0x8C2C150C, // 0163 GETMET R11 R10 K12 - 0x5834000A, // 0164 LDCONST R13 K10 - 0x88380937, // 0165 GETMBR R14 R4 K55 - 0x883C1338, // 0166 GETMBR R15 R9 K56 - 0x7C2C0800, // 0167 CALL R11 4 - 0x8C2C150C, // 0168 GETMET R11 R10 K12 - 0x5834000E, // 0169 LDCONST R13 K14 - 0x88380937, // 016A GETMBR R14 R4 K55 - 0x883C1339, // 016B GETMBR R15 R9 K57 - 0x7C2C0800, // 016C CALL R11 4 - 0x7001FFEF, // 016D JMP #015E - 0x5820003A, // 016E LDCONST R8 K58 - 0xAC200200, // 016F CATCH R8 1 0 - 0xB0080000, // 0170 RAISE 2 R0 R0 - 0x80040E00, // 0171 RET 1 R7 - 0x70020061, // 0172 JMP #01D5 - 0x1C1C0D0A, // 0173 EQ R7 R6 K10 - 0x781E0032, // 0174 JMPF R7 #01A8 - 0x8C1C0912, // 0175 GETMET R7 R4 K18 - 0x7C1C0200, // 0176 CALL R7 1 - 0x60200010, // 0177 GETGBL R8 G16 - 0x88240134, // 0178 GETMBR R9 R0 K52 - 0x88241335, // 0179 GETMBR R9 R9 K53 - 0x8C241336, // 017A GETMET R9 R9 K54 - 0x7C240200, // 017B CALL R9 1 - 0x7C200200, // 017C CALL R8 1 - 0xA8020024, // 017D EXBLK 0 #01A3 - 0x5C241000, // 017E MOVE R9 R8 - 0x7C240000, // 017F CALL R9 0 - 0x8C28093B, // 0180 GETMET R10 R4 K59 - 0x8C30133C, // 0181 GETMET R12 R9 K60 - 0x7C300200, // 0182 CALL R12 1 - 0x7C280400, // 0183 CALL R10 2 - 0x8C2C0F16, // 0184 GETMET R11 R7 K22 - 0x4C340000, // 0185 LDNIL R13 - 0x7C2C0400, // 0186 CALL R11 2 - 0x8C30170C, // 0187 GETMET R12 R11 K12 - 0x5838000A, // 0188 LDCONST R14 K10 - 0x883C0937, // 0189 GETMBR R15 R4 K55 - 0x8C40153D, // 018A GETMET R16 R10 K61 - 0x544A0008, // 018B LDINT R18 9 - 0x7C400400, // 018C CALL R16 2 - 0x7C300800, // 018D CALL R12 4 - 0x8C30170C, // 018E GETMET R12 R11 K12 - 0x5838000E, // 018F LDCONST R14 K14 - 0x883C090D, // 0190 GETMBR R15 R4 K13 - 0x8840133E, // 0191 GETMBR R16 R9 K62 - 0x7C300800, // 0192 CALL R12 4 - 0x8C30170C, // 0193 GETMET R12 R11 K12 - 0x58380010, // 0194 LDCONST R14 K16 - 0x883C0907, // 0195 GETMBR R15 R4 K7 - 0x8840133F, // 0196 GETMBR R16 R9 K63 - 0x7C300800, // 0197 CALL R12 4 - 0x8C30170C, // 0198 GETMET R12 R11 K12 - 0x543A0003, // 0199 LDINT R14 4 - 0x883C0907, // 019A GETMBR R15 R4 K7 - 0x88401340, // 019B GETMBR R16 R9 K64 - 0x7C300800, // 019C CALL R12 4 - 0x8C30170C, // 019D GETMET R12 R11 K12 - 0x543A0004, // 019E LDINT R14 5 - 0x883C0917, // 019F GETMBR R15 R4 K23 - 0x88401341, // 01A0 GETMBR R16 R9 K65 - 0x7C300800, // 01A1 CALL R12 4 - 0x7001FFDA, // 01A2 JMP #017E - 0x5820003A, // 01A3 LDCONST R8 K58 - 0xAC200200, // 01A4 CATCH R8 1 0 - 0xB0080000, // 01A5 RAISE 2 R0 R0 - 0x80040E00, // 01A6 RET 1 R7 - 0x7002002C, // 01A7 JMP #01D5 - 0x1C1C0D0E, // 01A8 EQ R7 R6 K14 - 0x781E0005, // 01A9 JMPF R7 #01B0 - 0x8C1C0906, // 01AA GETMET R7 R4 K6 - 0x8824090F, // 01AB GETMBR R9 R4 K15 - 0x542A0004, // 01AC LDINT R10 5 - 0x7C1C0600, // 01AD CALL R7 3 - 0x80040E00, // 01AE RET 1 R7 - 0x70020024, // 01AF JMP #01D5 - 0x1C1C0D10, // 01B0 EQ R7 R6 K16 - 0x781E000B, // 01B1 JMPF R7 #01BE - 0x881C0134, // 01B2 GETMBR R7 R0 K52 - 0x881C0F35, // 01B3 GETMBR R7 R7 K53 - 0x8C1C0F36, // 01B4 GETMET R7 R7 K54 - 0x7C1C0200, // 01B5 CALL R7 1 - 0x8C200906, // 01B6 GETMET R8 R4 K6 - 0x8828090F, // 01B7 GETMBR R10 R4 K15 - 0x602C000C, // 01B8 GETGBL R11 G12 - 0x5C300E00, // 01B9 MOVE R12 R7 - 0x7C2C0200, // 01BA CALL R11 1 - 0x7C200600, // 01BB CALL R8 3 - 0x80041000, // 01BC RET 1 R8 - 0x70020016, // 01BD JMP #01D5 - 0x541E0003, // 01BE LDINT R7 4 - 0x1C1C0C07, // 01BF EQ R7 R6 R7 - 0x781E0000, // 01C0 JMPF R7 #01C2 - 0x70020012, // 01C1 JMP #01D5 - 0x541E0004, // 01C2 LDINT R7 5 - 0x1C1C0C07, // 01C3 EQ R7 R6 R7 - 0x781E000F, // 01C4 JMPF R7 #01D5 - 0x881C0134, // 01C5 GETMBR R7 R0 K52 - 0x881C0F35, // 01C6 GETMBR R7 R7 K53 - 0x8C1C0F36, // 01C7 GETMET R7 R7 K54 - 0x7C1C0200, // 01C8 CALL R7 1 - 0x8C200F1C, // 01C9 GETMET R8 R7 K28 - 0x88280308, // 01CA GETMBR R10 R1 K8 - 0x7C200400, // 01CB CALL R8 2 - 0x4C240000, // 01CC LDNIL R9 - 0x1C241009, // 01CD EQ R9 R8 R9 - 0x78260000, // 01CE JMPF R9 #01D0 - 0x58200005, // 01CF LDCONST R8 K5 - 0x8C240906, // 01D0 GETMET R9 R4 K6 - 0x882C090F, // 01D1 GETMBR R11 R4 K15 - 0x5C301000, // 01D2 MOVE R12 R8 - 0x7C240600, // 01D3 CALL R9 3 - 0x80041200, // 01D4 RET 1 R9 - 0x70020108, // 01D5 JMP #02DF - 0x541E003B, // 01D6 LDINT R7 60 - 0x1C1C0A07, // 01D7 EQ R7 R5 R7 - 0x781E0000, // 01D8 JMPF R7 #01DA - 0x70020104, // 01D9 JMP #02DF - 0x541E0027, // 01DA LDINT R7 40 - 0x1C1C0A07, // 01DB EQ R7 R5 R7 - 0x781E0071, // 01DC JMPF R7 #024F - 0x1C1C0D05, // 01DD EQ R7 R6 K5 - 0x781E0005, // 01DE JMPF R7 #01E5 - 0x8C1C0906, // 01DF GETMET R7 R4 K6 - 0x8824090D, // 01E0 GETMBR R9 R4 K13 - 0x58280005, // 01E1 LDCONST R10 K5 - 0x7C1C0600, // 01E2 CALL R7 3 - 0x80040E00, // 01E3 RET 1 R7 - 0x70020068, // 01E4 JMP #024E - 0x1C1C0D0A, // 01E5 EQ R7 R6 K10 - 0x781E0005, // 01E6 JMPF R7 #01ED - 0x8C1C0906, // 01E7 GETMET R7 R4 K6 - 0x88240917, // 01E8 GETMBR R9 R4 K23 - 0x58280042, // 01E9 LDCONST R10 K66 - 0x7C1C0600, // 01EA CALL R7 3 - 0x80040E00, // 01EB RET 1 R7 - 0x70020060, // 01EC JMP #024E - 0x1C1C0D0E, // 01ED EQ R7 R6 K14 - 0x781E0006, // 01EE JMPF R7 #01F6 - 0x8C1C0906, // 01EF GETMET R7 R4 K6 - 0x8824090D, // 01F0 GETMBR R9 R4 K13 - 0x88280134, // 01F1 GETMBR R10 R0 K52 - 0x88281543, // 01F2 GETMBR R10 R10 K67 - 0x7C1C0600, // 01F3 CALL R7 3 - 0x80040E00, // 01F4 RET 1 R7 - 0x70020057, // 01F5 JMP #024E - 0x1C1C0D10, // 01F6 EQ R7 R6 K16 - 0x781E0009, // 01F7 JMPF R7 #0202 - 0x8C1C0906, // 01F8 GETMET R7 R4 K6 - 0x88240917, // 01F9 GETMBR R9 R4 K23 - 0xB82A2600, // 01FA GETNGBL R10 K19 - 0x8C281527, // 01FB GETMET R10 R10 K39 - 0x58300044, // 01FC LDCONST R12 K68 - 0x7C280400, // 01FD CALL R10 2 - 0x94281544, // 01FE GETIDX R10 R10 K68 - 0x7C1C0600, // 01FF CALL R7 3 - 0x80040E00, // 0200 RET 1 R7 - 0x7002004B, // 0201 JMP #024E - 0x541E0003, // 0202 LDINT R7 4 - 0x1C1C0C07, // 0203 EQ R7 R6 R7 - 0x781E0005, // 0204 JMPF R7 #020B - 0x8C1C0906, // 0205 GETMET R7 R4 K6 - 0x8824090D, // 0206 GETMBR R9 R4 K13 - 0x542A7FFF, // 0207 LDINT R10 32768 - 0x7C1C0600, // 0208 CALL R7 3 - 0x80040E00, // 0209 RET 1 R7 - 0x70020042, // 020A JMP #024E - 0x541E0004, // 020B LDINT R7 5 - 0x1C1C0C07, // 020C EQ R7 R6 R7 - 0x781E0009, // 020D JMPF R7 #0218 - 0x8C1C0906, // 020E GETMET R7 R4 K6 - 0x88240917, // 020F GETMBR R9 R4 K23 - 0xB82A2600, // 0210 GETNGBL R10 K19 - 0x8C281527, // 0211 GETMET R10 R10 K39 - 0x58300045, // 0212 LDCONST R12 K69 - 0x7C280400, // 0213 CALL R10 2 - 0x94281546, // 0214 GETIDX R10 R10 K70 - 0x7C1C0600, // 0215 CALL R7 3 - 0x80040E00, // 0216 RET 1 R7 - 0x70020035, // 0217 JMP #024E - 0x541E0005, // 0218 LDINT R7 6 - 0x1C1C0C07, // 0219 EQ R7 R6 R7 - 0x781E0005, // 021A JMPF R7 #0221 - 0x8C1C0906, // 021B GETMET R7 R4 K6 - 0x88240917, // 021C GETMBR R9 R4 K23 - 0x58280047, // 021D LDCONST R10 K71 - 0x7C1C0600, // 021E CALL R7 3 - 0x80040E00, // 021F RET 1 R7 - 0x7002002C, // 0220 JMP #024E - 0x541E0006, // 0221 LDINT R7 7 - 0x1C1C0C07, // 0222 EQ R7 R6 R7 - 0x781E0005, // 0223 JMPF R7 #022A - 0x8C1C0906, // 0224 GETMET R7 R4 K6 - 0x8824090D, // 0225 GETMBR R9 R4 K13 - 0x58280005, // 0226 LDCONST R10 K5 - 0x7C1C0600, // 0227 CALL R7 3 - 0x80040E00, // 0228 RET 1 R7 - 0x70020023, // 0229 JMP #024E - 0x541E0007, // 022A LDINT R7 8 - 0x1C1C0C07, // 022B EQ R7 R6 R7 - 0x781E000A, // 022C JMPF R7 #0238 - 0x8C1C0906, // 022D GETMET R7 R4 K6 - 0x88240917, // 022E GETMBR R9 R4 K23 - 0xB82A2600, // 022F GETNGBL R10 K19 - 0x8C281527, // 0230 GETMET R10 R10 K39 - 0x58300048, // 0231 LDCONST R12 K72 - 0x7C280400, // 0232 CALL R10 2 - 0x94281549, // 0233 GETIDX R10 R10 K73 - 0x9428154A, // 0234 GETIDX R10 R10 K74 - 0x7C1C0600, // 0235 CALL R7 3 - 0x80040E00, // 0236 RET 1 R7 - 0x70020015, // 0237 JMP #024E - 0x541E0008, // 0238 LDINT R7 9 - 0x1C1C0C07, // 0239 EQ R7 R6 R7 - 0x781E0005, // 023A JMPF R7 #0241 - 0x8C1C0906, // 023B GETMET R7 R4 K6 - 0x8824090D, // 023C GETMBR R9 R4 K13 - 0x58280005, // 023D LDCONST R10 K5 - 0x7C1C0600, // 023E CALL R7 3 - 0x80040E00, // 023F RET 1 R7 - 0x7002000C, // 0240 JMP #024E - 0x541E0009, // 0241 LDINT R7 10 - 0x1C1C0C07, // 0242 EQ R7 R6 R7 - 0x781E0009, // 0243 JMPF R7 #024E - 0x8C1C0906, // 0244 GETMET R7 R4 K6 - 0x88240917, // 0245 GETMBR R9 R4 K23 - 0xB82A2600, // 0246 GETNGBL R10 K19 - 0x8C281527, // 0247 GETMET R10 R10 K39 - 0x58300048, // 0248 LDCONST R12 K72 - 0x7C280400, // 0249 CALL R10 2 - 0x94281549, // 024A GETIDX R10 R10 K73 - 0x9428154B, // 024B GETIDX R10 R10 K75 - 0x7C1C0600, // 024C CALL R7 3 - 0x80040E00, // 024D RET 1 R7 - 0x7002008F, // 024E JMP #02DF - 0x541E003E, // 024F LDINT R7 63 - 0x1C1C0A07, // 0250 EQ R7 R5 R7 - 0x781E0000, // 0251 JMPF R7 #0253 - 0x7002008B, // 0252 JMP #02DF - 0x541E002A, // 0253 LDINT R7 43 - 0x1C1C0A07, // 0254 EQ R7 R5 R7 - 0x781E0016, // 0255 JMPF R7 #026D - 0x1C1C0D05, // 0256 EQ R7 R6 K5 - 0x781E0007, // 0257 JMPF R7 #0260 - 0x8C1C0906, // 0258 GETMET R7 R4 K6 - 0x88240917, // 0259 GETMBR R9 R4 K23 - 0xB82A2600, // 025A GETNGBL R10 K19 - 0x8C28154C, // 025B GETMET R10 R10 K76 - 0x7C280200, // 025C CALL R10 1 - 0x7C1C0600, // 025D CALL R7 3 - 0x80040E00, // 025E RET 1 R7 - 0x7002000B, // 025F JMP #026C - 0x1C1C0D0A, // 0260 EQ R7 R6 K10 - 0x781E0009, // 0261 JMPF R7 #026C - 0x8C1C094D, // 0262 GETMET R7 R4 K77 - 0x7C1C0200, // 0263 CALL R7 1 - 0x8C200F0C, // 0264 GETMET R8 R7 K12 - 0x4C280000, // 0265 LDNIL R10 - 0x882C0917, // 0266 GETMBR R11 R4 K23 - 0xB8322600, // 0267 GETNGBL R12 K19 - 0x8C30194C, // 0268 GETMET R12 R12 K76 - 0x7C300200, // 0269 CALL R12 1 - 0x7C200800, // 026A CALL R8 4 - 0x80040E00, // 026B RET 1 R7 - 0x70020071, // 026C JMP #02DF - 0x541E002B, // 026D LDINT R7 44 - 0x1C1C0A07, // 026E EQ R7 R5 R7 - 0x781E001C, // 026F JMPF R7 #028D - 0x1C1C0D05, // 0270 EQ R7 R6 K5 - 0x781E0005, // 0271 JMPF R7 #0278 - 0x8C1C0906, // 0272 GETMET R7 R4 K6 - 0x8824090F, // 0273 GETMBR R9 R4 K15 - 0x5828000A, // 0274 LDCONST R10 K10 - 0x7C1C0600, // 0275 CALL R7 3 - 0x80040E00, // 0276 RET 1 R7 - 0x70020013, // 0277 JMP #028C - 0x1C1C0D0A, // 0278 EQ R7 R6 K10 - 0x781E0005, // 0279 JMPF R7 #0280 - 0x8C1C0906, // 027A GETMET R7 R4 K6 - 0x8824090F, // 027B GETMBR R9 R4 K15 - 0x542A0003, // 027C LDINT R10 4 - 0x7C1C0600, // 027D CALL R7 3 - 0x80040E00, // 027E RET 1 R7 - 0x7002000B, // 027F JMP #028C - 0x1C1C0D0E, // 0280 EQ R7 R6 K14 - 0x781E0009, // 0281 JMPF R7 #028C - 0x8C1C094D, // 0282 GETMET R7 R4 K77 - 0x7C1C0200, // 0283 CALL R7 1 - 0x8C200F0C, // 0284 GETMET R8 R7 K12 - 0x4C280000, // 0285 LDNIL R10 - 0x8C2C0906, // 0286 GETMET R11 R4 K6 - 0x8834090F, // 0287 GETMBR R13 R4 K15 - 0x543A0003, // 0288 LDINT R14 4 - 0x7C2C0600, // 0289 CALL R11 3 - 0x7C200600, // 028A CALL R8 3 - 0x80040E00, // 028B RET 1 R7 - 0x70020051, // 028C JMP #02DF - 0x541E0030, // 028D LDINT R7 49 - 0x1C1C0A07, // 028E EQ R7 R5 R7 - 0x781E0010, // 028F JMPF R7 #02A1 - 0x1C1C0D10, // 0290 EQ R7 R6 K16 - 0x781E0005, // 0291 JMPF R7 #0298 - 0x8C1C0906, // 0292 GETMET R7 R4 K6 - 0x8824090F, // 0293 GETMBR R9 R4 K15 - 0x542A001D, // 0294 LDINT R10 30 - 0x7C1C0600, // 0295 CALL R7 3 - 0x80040E00, // 0296 RET 1 R7 - 0x70020007, // 0297 JMP #02A0 - 0x541EFFFB, // 0298 LDINT R7 65532 - 0x1C1C0C07, // 0299 EQ R7 R6 R7 - 0x781E0004, // 029A JMPF R7 #02A0 - 0x8C1C0906, // 029B GETMET R7 R4 K6 - 0x8824092B, // 029C GETMBR R9 R4 K43 - 0x58280005, // 029D LDCONST R10 K5 - 0x7C1C0600, // 029E CALL R7 3 - 0x80040E00, // 029F RET 1 R7 - 0x7002003D, // 02A0 JMP #02DF - 0x541E001C, // 02A1 LDINT R7 29 - 0x1C1C0A07, // 02A2 EQ R7 R5 R7 - 0x781E0037, // 02A3 JMPF R7 #02DC - 0x1C1C0D05, // 02A4 EQ R7 R6 K5 - 0x781E0000, // 02A5 JMPF R7 #02A7 - 0x70020033, // 02A6 JMP #02DB - 0x1C1C0D0A, // 02A7 EQ R7 R6 K10 - 0x781E0013, // 02A8 JMPF R7 #02BD - 0x8C1C0912, // 02A9 GETMET R7 R4 K18 - 0x7C1C0200, // 02AA CALL R7 1 - 0x60200010, // 02AB GETGBL R8 G16 - 0x8C24014E, // 02AC GETMET R9 R0 K78 - 0x7C240200, // 02AD CALL R9 1 - 0x7C200200, // 02AE CALL R8 1 - 0xA8020007, // 02AF EXBLK 0 #02B8 - 0x5C241000, // 02B0 MOVE R9 R8 - 0x7C240000, // 02B1 CALL R9 0 - 0x8C280F0C, // 02B2 GETMET R10 R7 K12 - 0x4C300000, // 02B3 LDNIL R12 - 0x8834092B, // 02B4 GETMBR R13 R4 K43 - 0x5C381200, // 02B5 MOVE R14 R9 - 0x7C280800, // 02B6 CALL R10 4 - 0x7001FFF7, // 02B7 JMP #02B0 - 0x5820003A, // 02B8 LDCONST R8 K58 - 0xAC200200, // 02B9 CATCH R8 1 0 - 0xB0080000, // 02BA RAISE 2 R0 R0 - 0x80040E00, // 02BB RET 1 R7 - 0x7002001D, // 02BC JMP #02DB - 0x1C1C0D0E, // 02BD EQ R7 R6 K14 - 0x781E0003, // 02BE JMPF R7 #02C3 - 0x8C1C0912, // 02BF GETMET R7 R4 K18 - 0x7C1C0200, // 02C0 CALL R7 1 - 0x80040E00, // 02C1 RET 1 R7 - 0x70020017, // 02C2 JMP #02DB - 0x1C1C0D10, // 02C3 EQ R7 R6 K16 - 0x781E0015, // 02C4 JMPF R7 #02DB - 0x881C0134, // 02C5 GETMBR R7 R0 K52 - 0x8C1C0F4F, // 02C6 GETMET R7 R7 K79 - 0x50240200, // 02C7 LDBOOL R9 1 0 - 0x7C1C0400, // 02C8 CALL R7 2 - 0x8C200912, // 02C9 GETMET R8 R4 K18 - 0x7C200200, // 02CA CALL R8 1 - 0x60240010, // 02CB GETGBL R9 G16 - 0x5C280E00, // 02CC MOVE R10 R7 - 0x7C240200, // 02CD CALL R9 1 - 0xA8020007, // 02CE EXBLK 0 #02D7 - 0x5C281200, // 02CF MOVE R10 R9 - 0x7C280000, // 02D0 CALL R10 0 - 0x8C2C110C, // 02D1 GETMET R11 R8 K12 - 0x4C340000, // 02D2 LDNIL R13 - 0x8838090D, // 02D3 GETMBR R14 R4 K13 - 0x5C3C1400, // 02D4 MOVE R15 R10 - 0x7C2C0800, // 02D5 CALL R11 4 - 0x7001FFF7, // 02D6 JMP #02CF - 0x5824003A, // 02D7 LDCONST R9 K58 - 0xAC240200, // 02D8 CATCH R9 1 0 - 0xB0080000, // 02D9 RAISE 2 R0 R0 - 0x80041000, // 02DA RET 1 R8 - 0x70020002, // 02DB JMP #02DF - 0xB81E0200, // 02DC GETNGBL R7 K1 - 0x881C0F51, // 02DD GETMBR R7 R7 K81 - 0x900AA007, // 02DE SETMBR R2 K80 R7 - 0x80000000, // 02DF RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: init -********************************************************************/ -be_local_closure(Matter_Plugin_core_init, /* name */ - be_nested_proto( - 5, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(init), - /* K1 */ be_nested_str_weak(endpoints), - /* K2 */ be_nested_str_weak(ENDPOINTS), - /* K3 */ be_nested_str_weak(clusters), - /* K4 */ be_nested_str_weak(CLUSTERS), - }), - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[11]) { /* 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 - 0x88080102, // 0006 GETMBR R2 R0 K2 - 0x90020202, // 0007 SETMBR R0 K1 R2 - 0x88080104, // 0008 GETMBR R2 R0 K4 - 0x90020602, // 0009 SETMBR R0 K3 R2 - 0x80000000, // 000A RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified class: Matter_Plugin_core +** Solidified class: Matter_Plugin_Root ********************************************************************/ extern const bclass be_class_Matter_Plugin; -be_local_class(Matter_Plugin_core, +be_local_class(Matter_Plugin_Root, 0, &be_class_Matter_Plugin, - be_nested_map(5, + be_nested_map(7, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(ENDPOINTS, 3), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(1, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(0), - })) ) } )) }, - { be_const_key_weak(read_attribute, -1), be_const_closure(Matter_Plugin_core_read_attribute_closure) }, - { be_const_key_weak(invoke_request, 1), be_const_closure(Matter_Plugin_core_invoke_request_closure) }, - { be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_core_init_closure) }, - { be_const_key_weak(CLUSTERS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { - be_const_map( * be_nested_map(13, + { be_const_key_weak(read_attribute, 1), be_const_closure(Matter_Plugin_Root_read_attribute_closure) }, + { be_const_key_weak(invoke_request, 2), be_const_closure(Matter_Plugin_Root_invoke_request_closure) }, + { be_const_key_weak(CLUSTERS, 6), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { + be_const_map( * be_nested_map(15, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_int(52, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + { be_const_key_int(60, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { be_const_list( * be_nested_list(0, ( (struct bvalue*) &(const bvalue[]) { })) ) } )) }, - { be_const_key_int(40, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(10, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(0), - be_const_int(1), - be_const_int(2), - be_const_int(3), - be_const_int(4), - be_const_int(5), - be_const_int(6), - be_const_int(7), - be_const_int(8), - be_const_int(9), - })) ) } )) }, - { be_const_key_int(43, -1), 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(0), - be_const_int(1), - })) ) } )) }, - { be_const_key_int(29, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + { be_const_key_int(31, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { be_const_list( * be_nested_list(4, ( (struct bvalue*) &(const bvalue[]) { be_const_int(0), - be_const_int(1), be_const_int(2), be_const_int(3), - })) ) } )) }, - { be_const_key_int(56, 2), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(3, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(0), - be_const_int(1), - be_const_int(7), - })) ) } )) }, - { be_const_key_int(44, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(3, - ( (struct bvalue*) &(const bvalue[]) { - be_const_int(0), - be_const_int(1), - be_const_int(2), + be_const_int(4), })) ) } )) }, { be_const_key_int(62, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { be_const_list( * be_nested_list(6, @@ -1556,15 +1725,7 @@ be_local_class(Matter_Plugin_core, be_const_int(4), be_const_int(5), })) ) } )) }, - { be_const_key_int(50, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(0, - ( (struct bvalue*) &(const bvalue[]) { - })) ) } )) }, - { be_const_key_int(60, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(0, - ( (struct bvalue*) &(const bvalue[]) { - })) ) } )) }, - { be_const_key_int(48, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + { be_const_key_int(48, 9), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { be_const_list( * be_nested_list(5, ( (struct bvalue*) &(const bvalue[]) { be_const_int(0), @@ -1573,13 +1734,14 @@ be_local_class(Matter_Plugin_core, be_const_int(3), be_const_int(4), })) ) } )) }, - { be_const_key_int(49, 6), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { - be_const_list( * be_nested_list(2, + { be_const_key_int(49, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(3, ( (struct bvalue*) &(const bvalue[]) { be_const_int(3), + be_const_int(4), be_const_int(65532), })) ) } )) }, - { be_const_key_int(63, 7), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + { be_const_key_int(50, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { be_const_list( * be_nested_list(0, ( (struct bvalue*) &(const bvalue[]) { })) ) } )) }, @@ -1591,15 +1753,86 @@ be_local_class(Matter_Plugin_core, be_const_int(2), be_const_int(8), })) ) } )) }, + { be_const_key_int(52, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(0, + ( (struct bvalue*) &(const bvalue[]) { + })) ) } )) }, + { be_const_key_int(29, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(4, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(2), + be_const_int(3), + })) ) } )) }, + { be_const_key_int(63, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(0, + ( (struct bvalue*) &(const bvalue[]) { + })) ) } )) }, + { be_const_key_int(40, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(11, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(2), + be_const_int(3), + be_const_int(4), + be_const_int(5), + be_const_int(6), + be_const_int(7), + be_const_int(8), + be_const_int(9), + be_const_int(18), + })) ) } )) }, + { be_const_key_int(56, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(3, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(7), + })) ) } )) }, + { be_const_key_int(42, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(4, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(2), + be_const_int(3), + })) ) } )) }, + { be_const_key_int(43, -1), 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(0), + be_const_int(1), + })) ) } )) }, + { be_const_key_int(44, 8), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(3, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), + be_const_int(1), + be_const_int(2), + })) ) } )) }, + })) ) } )) }, + { be_const_key_weak(TYPES, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(1, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(22), + })) ) } )) }, + { be_const_key_weak(write_attribute, -1), be_const_closure(Matter_Plugin_Root_write_attribute_closure) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_Root_init_closure) }, + { be_const_key_weak(ENDPOINTS, -1), be_const_simple_instance(be_nested_simple_instance(&be_class_list, { + be_const_list( * be_nested_list(1, + ( (struct bvalue*) &(const bvalue[]) { + be_const_int(0), })) ) } )) }, })), - be_str_weak(Matter_Plugin_core) + be_str_weak(Matter_Plugin_Root) ); /*******************************************************************/ -void be_load_Matter_Plugin_core_class(bvm *vm) { - be_pushntvclass(vm, &be_class_Matter_Plugin_core); - be_setglobal(vm, "Matter_Plugin_core"); +void be_load_Matter_Plugin_Root_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_Plugin_Root); + be_setglobal(vm, "Matter_Plugin_Root"); be_pop(vm, 1); } /********************************************************************/ diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session.h index 45fcfe981..6c610d038 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session.h @@ -7,12 +7,12 @@ extern const bclass be_class_Matter_Session; /******************************************************************** -** Solidified function: save +** Solidified function: set_fabric_label ********************************************************************/ -be_local_closure(Matter_Session_save, /* name */ +be_local_closure(Matter_Session_set_fabric_label, /* name */ be_nested_proto( - 3, /* nstack */ - 1, /* argc */ + 4, /* nstack */ + 2, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -20,16 +20,158 @@ be_local_closure(Matter_Session_save, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(__store), - /* K1 */ be_nested_str_weak(save), + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(fabric_label), }), - be_str_weak(save), + be_str_weak(set_fabric_label), &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ + ( &(const binstruction[ 7]) { /* code */ + 0x60080004, // 0000 GETGBL R2 G4 + 0x5C0C0200, // 0001 MOVE R3 R1 + 0x7C080200, // 0002 CALL R2 1 + 0x1C080500, // 0003 EQ R2 R2 K0 + 0x780A0000, // 0004 JMPF R2 #0006 + 0x90020201, // 0005 SETMBR R0 K1 R1 + 0x80000000, // 0006 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_no_expiration +********************************************************************/ +be_local_closure(Matter_Session_set_no_expiration, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(expiration), + }), + be_str_weak(set_no_expiration), + &be_const_str_solidified, + ( &(const binstruction[ 3]) { /* code */ + 0x4C040000, // 0000 LDNIL R1 + 0x90020001, // 0001 SETMBR R0 K0 R1 + 0x80000000, // 0002 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_mode +********************************************************************/ +be_local_closure(Matter_Session_set_mode, /* name */ + be_nested_proto( + 2, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(mode), + }), + be_str_weak(set_mode), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x80000000, // 0001 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_expire_time +********************************************************************/ +be_local_closure(Matter_Session_set_expire_time, /* name */ + be_nested_proto( + 4, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(expiration), + }), + be_str_weak(set_expire_time), + &be_const_str_solidified, + ( &(const binstruction[ 5]) { /* code */ + 0x60080009, // 0000 GETGBL R2 G9 + 0x5C0C0200, // 0001 MOVE R3 R1 + 0x7C080200, // 0002 CALL R2 1 + 0x90020002, // 0003 SETMBR R0 K0 R2 + 0x80000000, // 0004 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_i2r +********************************************************************/ +be_local_closure(Matter_Session_get_i2r, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(i2rkey), + }), + be_str_weak(get_i2r), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x7C040200, // 0002 CALL R1 1 - 0x80000000, // 0003 RET 0 + 0x80040200, // 0001 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_ipk_epoch_key +********************************************************************/ +be_local_closure(Matter_Session_get_ipk_epoch_key, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(ipk_epoch_key), + }), + be_str_weak(get_ipk_epoch_key), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -80,11 +222,38 @@ be_local_closure(Matter_Session_set_expire_in_seconds, /* name */ /******************************************************************** -** Solidified function: get_i2r_privacy +** Solidified function: set_ipk_epoch_key ********************************************************************/ -be_local_closure(Matter_Session_get_i2r_privacy, /* name */ +be_local_closure(Matter_Session_set_ipk_epoch_key, /* name */ be_nested_proto( - 9, /* nstack */ + 2, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(ipk_epoch_key), + }), + be_str_weak(set_ipk_epoch_key), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x80000000, // 0001 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_deviceid +********************************************************************/ +be_local_closure(Matter_Session_get_deviceid, /* name */ + be_nested_proto( + 2, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -92,40 +261,14 @@ be_local_closure(Matter_Session_get_i2r_privacy, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 7]) { /* constants */ - /* K0 */ be_nested_str_weak(_i2r_privacy), - /* K1 */ be_nested_str_weak(crypto), - /* K2 */ be_nested_str_weak(HKDF_SHA256), - /* K3 */ be_nested_str_weak(derive), - /* K4 */ be_nested_str_weak(get_i2r), - /* K5 */ be_nested_str_weak(fromstring), - /* K6 */ be_nested_str_weak(PrivacyKey), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(deviceid), }), - be_str_weak(get_i2r_privacy), + be_str_weak(get_deviceid), &be_const_str_solidified, - ( &(const binstruction[22]) { /* code */ + ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x4C080000, // 0001 LDNIL R2 - 0x1C040202, // 0002 EQ R1 R1 R2 - 0x7806000F, // 0003 JMPF R1 #0014 - 0xA4060200, // 0004 IMPORT R1 K1 - 0x8C080302, // 0005 GETMET R2 R1 K2 - 0x7C080200, // 0006 CALL R2 1 - 0x8C080503, // 0007 GETMET R2 R2 K3 - 0x8C100104, // 0008 GETMET R4 R0 K4 - 0x7C100200, // 0009 CALL R4 1 - 0x60140015, // 000A GETGBL R5 G21 - 0x7C140000, // 000B CALL R5 0 - 0x60180015, // 000C GETGBL R6 G21 - 0x7C180000, // 000D CALL R6 0 - 0x8C180D05, // 000E GETMET R6 R6 K5 - 0x58200006, // 000F LDCONST R8 K6 - 0x7C180400, // 0010 CALL R6 2 - 0x541E000F, // 0011 LDINT R7 16 - 0x7C080A00, // 0012 CALL R2 5 - 0x90020002, // 0013 SETMBR R0 K0 R2 - 0x88040100, // 0014 GETMBR R1 R0 K0 - 0x80040200, // 0015 RET 1 R1 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -177,9 +320,9 @@ be_local_closure(Matter_Session_has_expired, /* name */ /******************************************************************** -** Solidified function: get_icac +** Solidified function: get_r2i ********************************************************************/ -be_local_closure(Matter_Session_get_icac, /* name */ +be_local_closure(Matter_Session_get_r2i, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -190,9 +333,9 @@ be_local_closure(Matter_Session_get_icac, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(icac), + /* K0 */ be_nested_str_weak(r2ikey), }), - be_str_weak(get_icac), + be_str_weak(get_r2i), &be_const_str_solidified, ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -204,9 +347,9 @@ be_local_closure(Matter_Session_get_icac, /* name */ /******************************************************************** -** Solidified function: get_deviceid +** Solidified function: get_fabric ********************************************************************/ -be_local_closure(Matter_Session_get_deviceid, /* name */ +be_local_closure(Matter_Session_get_fabric, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -217,9 +360,9 @@ be_local_closure(Matter_Session_get_deviceid, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(deviceid), + /* K0 */ be_nested_str_weak(fabric), }), - be_str_weak(get_deviceid), + be_str_weak(get_fabric), &be_const_str_solidified, ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -231,291 +374,35 @@ be_local_closure(Matter_Session_get_deviceid, /* name */ /******************************************************************** -** Solidified function: get_noc +** Solidified function: set_keys ********************************************************************/ -be_local_closure(Matter_Session_get_noc, /* name */ +be_local_closure(Matter_Session_set_keys, /* name */ be_nested_proto( - 2, /* nstack */ - 1, /* argc */ + 6, /* nstack */ + 5, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(noc), + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(i2rkey), + /* K1 */ be_nested_str_weak(_i2r_privacy), + /* K2 */ be_nested_str_weak(r2ikey), + /* K3 */ be_nested_str_weak(attestation_challenge), + /* K4 */ be_nested_str_weak(session_timestamp), }), - be_str_weak(get_noc), + be_str_weak(set_keys), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: close -********************************************************************/ -be_local_closure(Matter_Session_close, /* name */ - be_nested_proto( - 9, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[24]) { /* constants */ - /* K0 */ be_nested_str_weak(_persist), - /* K1 */ be_nested_str_weak(local_session_id), - /* K2 */ be_nested_str_weak(_future_local_session_id), - /* K3 */ be_nested_str_weak(initiator_session_id), - /* K4 */ be_nested_str_weak(_future_initiator_session_id), - /* K5 */ be_nested_str_weak(source_node_id), - /* K6 */ be_nested_str_weak(counter_rcv), - /* K7 */ be_nested_str_weak(reset), - /* K8 */ be_nested_str_weak(counter_snd), - /* K9 */ be_nested_str_weak(i2rkey), - /* K10 */ be_nested_str_weak(_i2r_privacy), - /* K11 */ be_nested_str_weak(r2ikey), - /* K12 */ be_nested_str_weak(attestation_challenge), - /* K13 */ be_nested_str_weak(fabric_label), - /* K14 */ be_nested_str_weak(), - /* K15 */ be_nested_str_weak(introspect), - /* K16 */ be_nested_str_weak(members), - /* K17 */ be_nested_str_weak(get), - /* K18 */ be_nested_str_weak(function), - /* K19 */ be_nested_str_weak(instance), - /* K20 */ be_const_int(0), - /* K21 */ be_nested_str_weak(_), - /* K22 */ be_const_int(1), - /* K23 */ be_nested_str_weak(stop_iteration), - }), - be_str_weak(close), - &be_const_str_solidified, - ( &(const binstruction[59]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88080102, // 0001 GETMBR R2 R0 K2 - 0x90020202, // 0002 SETMBR R0 K1 R2 - 0x88080104, // 0003 GETMBR R2 R0 K4 - 0x90020602, // 0004 SETMBR R0 K3 R2 - 0x4C080000, // 0005 LDNIL R2 - 0x90020A02, // 0006 SETMBR R0 K5 R2 - 0x88080106, // 0007 GETMBR R2 R0 K6 - 0x8C080507, // 0008 GETMET R2 R2 K7 - 0x7C080200, // 0009 CALL R2 1 - 0x88080108, // 000A GETMBR R2 R0 K8 - 0x8C080507, // 000B GETMET R2 R2 K7 - 0x7C080200, // 000C CALL R2 1 - 0x4C080000, // 000D LDNIL R2 - 0x90021202, // 000E SETMBR R0 K9 R2 - 0x4C080000, // 000F LDNIL R2 - 0x90021402, // 0010 SETMBR R0 K10 R2 - 0x4C080000, // 0011 LDNIL R2 - 0x90021602, // 0012 SETMBR R0 K11 R2 - 0x4C080000, // 0013 LDNIL R2 - 0x90021802, // 0014 SETMBR R0 K12 R2 - 0x90021B0E, // 0015 SETMBR R0 K13 K14 - 0xA40A1E00, // 0016 IMPORT R2 K15 - 0x600C0010, // 0017 GETGBL R3 G16 - 0x8C100510, // 0018 GETMET R4 R2 K16 - 0x5C180000, // 0019 MOVE R6 R0 - 0x7C100400, // 001A CALL R4 2 - 0x7C0C0200, // 001B CALL R3 1 - 0xA8020018, // 001C EXBLK 0 #0036 - 0x5C100600, // 001D MOVE R4 R3 - 0x7C100000, // 001E CALL R4 0 - 0x8C140511, // 001F GETMET R5 R2 K17 - 0x5C1C0000, // 0020 MOVE R7 R0 - 0x5C200800, // 0021 MOVE R8 R4 - 0x7C140600, // 0022 CALL R5 3 - 0x60180004, // 0023 GETGBL R6 G4 - 0x5C1C0A00, // 0024 MOVE R7 R5 - 0x7C180200, // 0025 CALL R6 1 - 0x20180D12, // 0026 NE R6 R6 K18 - 0x781A000C, // 0027 JMPF R6 #0035 - 0x60180004, // 0028 GETGBL R6 G4 - 0x5C1C0A00, // 0029 MOVE R7 R5 - 0x7C180200, // 002A CALL R6 1 - 0x20180D13, // 002B NE R6 R6 K19 - 0x781A0007, // 002C JMPF R6 #0035 - 0x94180914, // 002D GETIDX R6 R4 K20 - 0x1C180D15, // 002E EQ R6 R6 K21 - 0x781A0004, // 002F JMPF R6 #0035 - 0x94180916, // 0030 GETIDX R6 R4 K22 - 0x20180D15, // 0031 NE R6 R6 K21 - 0x781A0001, // 0032 JMPF R6 #0035 - 0x4C180000, // 0033 LDNIL R6 - 0x90000806, // 0034 SETMBR R0 R4 R6 - 0x7001FFE6, // 0035 JMP #001D - 0x580C0017, // 0036 LDCONST R3 K23 - 0xAC0C0200, // 0037 CATCH R3 1 0 - 0xB0080000, // 0038 RAISE 2 R0 R0 - 0x90020001, // 0039 SETMBR R0 K0 R1 - 0x80000000, // 003A RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: fromjson -********************************************************************/ -be_local_closure(Matter_Session_fromjson, /* name */ - be_nested_proto( - 16, /* nstack */ - 2, /* argc */ - 4, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[19]) { /* constants */ - /* K0 */ be_const_class(be_class_Matter_Session), - /* K1 */ be_nested_str_weak(string), - /* K2 */ be_nested_str_weak(introspect), - /* K3 */ be_nested_str_weak(matter), - /* K4 */ be_nested_str_weak(Session), - /* K5 */ be_nested_str_weak(keys), - /* K6 */ be_nested_str_weak(counter_rcv), - /* K7 */ be_nested_str_weak(reset), - /* K8 */ be_nested_str_weak(counter_snd), - /* K9 */ be_nested_str_weak(find), - /* K10 */ be_nested_str_weak(0x), - /* K11 */ be_const_int(0), - /* K12 */ be_nested_str_weak(set), - /* K13 */ be_nested_str_weak(fromhex), - /* K14 */ be_const_int(2), - /* K15 */ be_const_int(2147483647), - /* K16 */ be_nested_str_weak(_X24_X24), - /* K17 */ be_nested_str_weak(fromb64), - /* K18 */ be_nested_str_weak(stop_iteration), - }), - be_str_weak(fromjson), - &be_const_str_solidified, - ( &(const binstruction[88]) { /* code */ - 0x58080000, // 0000 LDCONST R2 K0 - 0xA40E0200, // 0001 IMPORT R3 K1 - 0xA4120400, // 0002 IMPORT R4 K2 - 0xB8160600, // 0003 GETNGBL R5 K3 - 0x8C140B04, // 0004 GETMET R5 R5 K4 - 0x5C1C0000, // 0005 MOVE R7 R0 - 0x7C140400, // 0006 CALL R5 2 - 0x60180010, // 0007 GETGBL R6 G16 - 0x8C1C0305, // 0008 GETMET R7 R1 K5 - 0x7C1C0200, // 0009 CALL R7 1 - 0x7C180200, // 000A CALL R6 1 - 0xA8020047, // 000B EXBLK 0 #0054 - 0x5C1C0C00, // 000C MOVE R7 R6 - 0x7C1C0000, // 000D CALL R7 0 - 0x94200207, // 000E GETIDX R8 R1 R7 - 0x1C240F06, // 000F EQ R9 R7 K6 - 0x78260006, // 0010 JMPF R9 #0018 - 0x88240B06, // 0011 GETMBR R9 R5 K6 - 0x8C241307, // 0012 GETMET R9 R9 K7 - 0x602C0009, // 0013 GETGBL R11 G9 - 0x5C301000, // 0014 MOVE R12 R8 - 0x7C2C0200, // 0015 CALL R11 1 - 0x7C240400, // 0016 CALL R9 2 - 0x7002003A, // 0017 JMP #0053 - 0x1C240F08, // 0018 EQ R9 R7 K8 - 0x78260006, // 0019 JMPF R9 #0021 - 0x88240B08, // 001A GETMBR R9 R5 K8 - 0x8C241307, // 001B GETMET R9 R9 K7 - 0x602C0009, // 001C GETGBL R11 G9 - 0x5C301000, // 001D MOVE R12 R8 - 0x7C2C0200, // 001E CALL R11 1 - 0x7C240400, // 001F CALL R9 2 - 0x70020031, // 0020 JMP #0053 - 0x60240004, // 0021 GETGBL R9 G4 - 0x5C281000, // 0022 MOVE R10 R8 - 0x7C240200, // 0023 CALL R9 1 - 0x1C241301, // 0024 EQ R9 R9 K1 - 0x78260027, // 0025 JMPF R9 #004E - 0x8C240709, // 0026 GETMET R9 R3 K9 - 0x5C2C1000, // 0027 MOVE R11 R8 - 0x5830000A, // 0028 LDCONST R12 K10 - 0x7C240600, // 0029 CALL R9 3 - 0x1C24130B, // 002A EQ R9 R9 K11 - 0x7826000A, // 002B JMPF R9 #0037 - 0x8C24090C, // 002C GETMET R9 R4 K12 - 0x5C2C0A00, // 002D MOVE R11 R5 - 0x5C300E00, // 002E MOVE R12 R7 - 0x60340015, // 002F GETGBL R13 G21 - 0x7C340000, // 0030 CALL R13 0 - 0x8C341B0D, // 0031 GETMET R13 R13 K13 - 0x403E1D0F, // 0032 CONNECT R15 K14 K15 - 0x943C100F, // 0033 GETIDX R15 R8 R15 - 0x7C340400, // 0034 CALL R13 2 - 0x7C240800, // 0035 CALL R9 4 - 0x70020015, // 0036 JMP #004D - 0x8C240709, // 0037 GETMET R9 R3 K9 - 0x5C2C1000, // 0038 MOVE R11 R8 - 0x58300010, // 0039 LDCONST R12 K16 - 0x7C240600, // 003A CALL R9 3 - 0x1C24130B, // 003B EQ R9 R9 K11 - 0x7826000A, // 003C JMPF R9 #0048 - 0x8C24090C, // 003D GETMET R9 R4 K12 - 0x5C2C0A00, // 003E MOVE R11 R5 - 0x5C300E00, // 003F MOVE R12 R7 - 0x60340015, // 0040 GETGBL R13 G21 - 0x7C340000, // 0041 CALL R13 0 - 0x8C341B11, // 0042 GETMET R13 R13 K17 - 0x403E1D0F, // 0043 CONNECT R15 K14 K15 - 0x943C100F, // 0044 GETIDX R15 R8 R15 - 0x7C340400, // 0045 CALL R13 2 - 0x7C240800, // 0046 CALL R9 4 - 0x70020004, // 0047 JMP #004D - 0x8C24090C, // 0048 GETMET R9 R4 K12 - 0x5C2C0A00, // 0049 MOVE R11 R5 - 0x5C300E00, // 004A MOVE R12 R7 - 0x5C341000, // 004B MOVE R13 R8 - 0x7C240800, // 004C CALL R9 4 - 0x70020004, // 004D JMP #0053 - 0x8C24090C, // 004E GETMET R9 R4 K12 - 0x5C2C0A00, // 004F MOVE R11 R5 - 0x5C300E00, // 0050 MOVE R12 R7 - 0x5C341000, // 0051 MOVE R13 R8 - 0x7C240800, // 0052 CALL R9 4 - 0x7001FFB7, // 0053 JMP #000C - 0x58180012, // 0054 LDCONST R6 K18 - 0xAC180200, // 0055 CATCH R6 1 0 - 0xB0080000, // 0056 RAISE 2 R0 R0 - 0x80040A00, // 0057 RET 1 R5 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_ipk_epoch_key -********************************************************************/ -be_local_closure(Matter_Session_get_ipk_epoch_key, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(ipk_epoch_key), - }), - be_str_weak(get_ipk_epoch_key), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 + ( &(const binstruction[ 7]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x4C140000, // 0001 LDNIL R5 + 0x90020205, // 0002 SETMBR R0 K1 R5 + 0x90020402, // 0003 SETMBR R0 K2 R2 + 0x90020603, // 0004 SETMBR R0 K3 R3 + 0x90020804, // 0005 SETMBR R0 K4 R4 + 0x80000000, // 0006 RET 0 }) ) ); @@ -669,11 +556,11 @@ be_local_closure(Matter_Session_tojson, /* name */ /******************************************************************** -** Solidified function: get_ac +** Solidified function: get_ipk_group_key ********************************************************************/ -be_local_closure(Matter_Session_get_ac, /* name */ +be_local_closure(Matter_Session_get_ipk_group_key, /* name */ be_nested_proto( - 2, /* nstack */ + 10, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -681,152 +568,238 @@ be_local_closure(Matter_Session_get_ac, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(attestation_challenge), - }), - be_str_weak(get_ac), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_no_expiration -********************************************************************/ -be_local_closure(Matter_Session_set_no_expiration, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(expiration), - }), - be_str_weak(set_no_expiration), - &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ - 0x4C040000, // 0000 LDNIL R1 - 0x90020001, // 0001 SETMBR R0 K0 R1 - 0x80000000, // 0002 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_r2i -********************************************************************/ -be_local_closure(Matter_Session_get_r2i, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(r2ikey), - }), - be_str_weak(get_r2i), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_fabric_compressed -********************************************************************/ -be_local_closure(Matter_Session_get_fabric_compressed, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(fabric_compressed), - }), - be_str_weak(get_fabric_compressed), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_fabric_label -********************************************************************/ -be_local_closure(Matter_Session_set_fabric_label, /* name */ - be_nested_proto( - 4, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(fabric_label), - }), - be_str_weak(set_fabric_label), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x60080004, // 0000 GETGBL R2 G4 - 0x5C0C0200, // 0001 MOVE R3 R1 - 0x7C080200, // 0002 CALL R2 1 - 0x1C080500, // 0003 EQ R2 R2 K0 - 0x780A0000, // 0004 JMPF R2 #0006 - 0x90020201, // 0005 SETMBR R0 K1 R1 - 0x80000000, // 0006 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_ipk_epoch_key -********************************************************************/ -be_local_closure(Matter_Session_set_ipk_epoch_key, /* name */ - be_nested_proto( - 2, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ + ( &(const bvalue[ 7]) { /* constants */ /* K0 */ be_nested_str_weak(ipk_epoch_key), + /* K1 */ be_nested_str_weak(fabric_compressed), + /* K2 */ be_nested_str_weak(crypto), + /* K3 */ be_nested_str_weak(HKDF_SHA256), + /* K4 */ be_nested_str_weak(fromstring), + /* K5 */ be_nested_str_weak(__GROUP_KEY), + /* K6 */ be_nested_str_weak(derive), }), - be_str_weak(set_ipk_epoch_key), + be_str_weak(get_ipk_group_key), + &be_const_str_solidified, + ( &(const binstruction[25]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x4C080000, // 0001 LDNIL R2 + 0x1C040202, // 0002 EQ R1 R1 R2 + 0x74060003, // 0003 JMPT R1 #0008 + 0x88040101, // 0004 GETMBR R1 R0 K1 + 0x4C080000, // 0005 LDNIL R2 + 0x1C040202, // 0006 EQ R1 R1 R2 + 0x78060001, // 0007 JMPF R1 #000A + 0x4C040000, // 0008 LDNIL R1 + 0x80040200, // 0009 RET 1 R1 + 0xA4060400, // 000A IMPORT R1 K2 + 0x8C080303, // 000B GETMET R2 R1 K3 + 0x7C080200, // 000C CALL R2 1 + 0x600C0015, // 000D GETGBL R3 G21 + 0x7C0C0000, // 000E CALL R3 0 + 0x8C0C0704, // 000F GETMET R3 R3 K4 + 0x88140105, // 0010 GETMBR R5 R0 K5 + 0x7C0C0400, // 0011 CALL R3 2 + 0x8C100506, // 0012 GETMET R4 R2 K6 + 0x88180100, // 0013 GETMBR R6 R0 K0 + 0x881C0101, // 0014 GETMBR R7 R0 K1 + 0x5C200600, // 0015 MOVE R8 R3 + 0x5426000F, // 0016 LDINT R9 16 + 0x7C100A00, // 0017 CALL R4 5 + 0x80040800, // 0018 RET 1 R4 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_ca_pub +********************************************************************/ +be_local_closure(Matter_Session_get_ca_pub, /* name */ + be_nested_proto( + 5, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(root_ca_certificate), + /* K1 */ be_nested_str_weak(matter), + /* K2 */ be_nested_str_weak(TLV), + /* K3 */ be_nested_str_weak(parse), + /* K4 */ be_nested_str_weak(findsubval), + }), + be_str_weak(get_ca_pub), + &be_const_str_solidified, + ( &(const binstruction[12]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x78060008, // 0001 JMPF R1 #000B + 0xB8060200, // 0002 GETNGBL R1 K1 + 0x88040302, // 0003 GETMBR R1 R1 K2 + 0x8C040303, // 0004 GETMET R1 R1 K3 + 0x880C0100, // 0005 GETMBR R3 R0 K0 + 0x7C040400, // 0006 CALL R1 2 + 0x8C080304, // 0007 GETMET R2 R1 K4 + 0x54120008, // 0008 LDINT R4 9 + 0x7C080400, // 0009 CALL R2 2 + 0x80040400, // 000A RET 1 R2 + 0x80000000, // 000B RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: fromjson +********************************************************************/ +be_local_closure(Matter_Session_fromjson, /* name */ + be_nested_proto( + 16, /* nstack */ + 2, /* argc */ + 4, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[19]) { /* constants */ + /* K0 */ be_const_class(be_class_Matter_Session), + /* K1 */ be_nested_str_weak(string), + /* K2 */ be_nested_str_weak(introspect), + /* K3 */ be_nested_str_weak(matter), + /* K4 */ be_nested_str_weak(Session), + /* K5 */ be_nested_str_weak(keys), + /* K6 */ be_nested_str_weak(counter_rcv), + /* K7 */ be_nested_str_weak(reset), + /* K8 */ be_nested_str_weak(counter_snd), + /* K9 */ be_nested_str_weak(find), + /* K10 */ be_nested_str_weak(0x), + /* K11 */ be_const_int(0), + /* K12 */ be_nested_str_weak(set), + /* K13 */ be_nested_str_weak(fromhex), + /* K14 */ be_const_int(2), + /* K15 */ be_const_int(2147483647), + /* K16 */ be_nested_str_weak(_X24_X24), + /* K17 */ be_nested_str_weak(fromb64), + /* K18 */ be_nested_str_weak(stop_iteration), + }), + be_str_weak(fromjson), + &be_const_str_solidified, + ( &(const binstruction[88]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0xA40E0200, // 0001 IMPORT R3 K1 + 0xA4120400, // 0002 IMPORT R4 K2 + 0xB8160600, // 0003 GETNGBL R5 K3 + 0x8C140B04, // 0004 GETMET R5 R5 K4 + 0x5C1C0000, // 0005 MOVE R7 R0 + 0x7C140400, // 0006 CALL R5 2 + 0x60180010, // 0007 GETGBL R6 G16 + 0x8C1C0305, // 0008 GETMET R7 R1 K5 + 0x7C1C0200, // 0009 CALL R7 1 + 0x7C180200, // 000A CALL R6 1 + 0xA8020047, // 000B EXBLK 0 #0054 + 0x5C1C0C00, // 000C MOVE R7 R6 + 0x7C1C0000, // 000D CALL R7 0 + 0x94200207, // 000E GETIDX R8 R1 R7 + 0x1C240F06, // 000F EQ R9 R7 K6 + 0x78260006, // 0010 JMPF R9 #0018 + 0x88240B06, // 0011 GETMBR R9 R5 K6 + 0x8C241307, // 0012 GETMET R9 R9 K7 + 0x602C0009, // 0013 GETGBL R11 G9 + 0x5C301000, // 0014 MOVE R12 R8 + 0x7C2C0200, // 0015 CALL R11 1 + 0x7C240400, // 0016 CALL R9 2 + 0x7002003A, // 0017 JMP #0053 + 0x1C240F08, // 0018 EQ R9 R7 K8 + 0x78260006, // 0019 JMPF R9 #0021 + 0x88240B08, // 001A GETMBR R9 R5 K8 + 0x8C241307, // 001B GETMET R9 R9 K7 + 0x602C0009, // 001C GETGBL R11 G9 + 0x5C301000, // 001D MOVE R12 R8 + 0x7C2C0200, // 001E CALL R11 1 + 0x7C240400, // 001F CALL R9 2 + 0x70020031, // 0020 JMP #0053 + 0x60240004, // 0021 GETGBL R9 G4 + 0x5C281000, // 0022 MOVE R10 R8 + 0x7C240200, // 0023 CALL R9 1 + 0x1C241301, // 0024 EQ R9 R9 K1 + 0x78260027, // 0025 JMPF R9 #004E + 0x8C240709, // 0026 GETMET R9 R3 K9 + 0x5C2C1000, // 0027 MOVE R11 R8 + 0x5830000A, // 0028 LDCONST R12 K10 + 0x7C240600, // 0029 CALL R9 3 + 0x1C24130B, // 002A EQ R9 R9 K11 + 0x7826000A, // 002B JMPF R9 #0037 + 0x8C24090C, // 002C GETMET R9 R4 K12 + 0x5C2C0A00, // 002D MOVE R11 R5 + 0x5C300E00, // 002E MOVE R12 R7 + 0x60340015, // 002F GETGBL R13 G21 + 0x7C340000, // 0030 CALL R13 0 + 0x8C341B0D, // 0031 GETMET R13 R13 K13 + 0x403E1D0F, // 0032 CONNECT R15 K14 K15 + 0x943C100F, // 0033 GETIDX R15 R8 R15 + 0x7C340400, // 0034 CALL R13 2 + 0x7C240800, // 0035 CALL R9 4 + 0x70020015, // 0036 JMP #004D + 0x8C240709, // 0037 GETMET R9 R3 K9 + 0x5C2C1000, // 0038 MOVE R11 R8 + 0x58300010, // 0039 LDCONST R12 K16 + 0x7C240600, // 003A CALL R9 3 + 0x1C24130B, // 003B EQ R9 R9 K11 + 0x7826000A, // 003C JMPF R9 #0048 + 0x8C24090C, // 003D GETMET R9 R4 K12 + 0x5C2C0A00, // 003E MOVE R11 R5 + 0x5C300E00, // 003F MOVE R12 R7 + 0x60340015, // 0040 GETGBL R13 G21 + 0x7C340000, // 0041 CALL R13 0 + 0x8C341B11, // 0042 GETMET R13 R13 K17 + 0x403E1D0F, // 0043 CONNECT R15 K14 K15 + 0x943C100F, // 0044 GETIDX R15 R8 R15 + 0x7C340400, // 0045 CALL R13 2 + 0x7C240800, // 0046 CALL R9 4 + 0x70020004, // 0047 JMP #004D + 0x8C24090C, // 0048 GETMET R9 R4 K12 + 0x5C2C0A00, // 0049 MOVE R11 R5 + 0x5C300E00, // 004A MOVE R12 R7 + 0x5C341000, // 004B MOVE R13 R8 + 0x7C240800, // 004C CALL R9 4 + 0x70020004, // 004D JMP #0053 + 0x8C24090C, // 004E GETMET R9 R4 K12 + 0x5C2C0A00, // 004F MOVE R11 R5 + 0x5C300E00, // 0050 MOVE R12 R7 + 0x5C341000, // 0051 MOVE R13 R8 + 0x7C240800, // 0052 CALL R9 4 + 0x7001FFB7, // 0053 JMP #000C + 0x58180012, // 0054 LDCONST R6 K18 + 0xAC180200, // 0055 CATCH R6 1 0 + 0xB0080000, // 0056 RAISE 2 R0 R0 + 0x80040A00, // 0057 RET 1 R5 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_ca +********************************************************************/ +be_local_closure(Matter_Session_set_ca, /* name */ + be_nested_proto( + 2, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(root_ca_certificate), + }), + be_str_weak(set_ca), &be_const_str_solidified, ( &(const binstruction[ 2]) { /* code */ 0x90020001, // 0000 SETMBR R0 K0 R1 @@ -838,36 +811,35 @@ be_local_closure(Matter_Session_set_ipk_epoch_key, /* name */ /******************************************************************** -** Solidified function: set_fabric_device +** Solidified function: get_pk ********************************************************************/ -be_local_closure(Matter_Session_set_fabric_device, /* name */ +be_local_closure(Matter_Session_get_pk, /* name */ be_nested_proto( - 7, /* nstack */ - 4, /* argc */ + 5, /* nstack */ + 1, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(fabric), - /* K1 */ be_nested_str_weak(deviceid), - /* K2 */ be_nested_str_weak(fabric_compressed), - /* K3 */ be_nested_str_weak(__store), - /* K4 */ be_nested_str_weak(remove_redundant_session), + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(no_private_key), + /* K1 */ be_nested_str_weak(crypto), + /* K2 */ be_nested_str_weak(random), }), - be_str_weak(set_fabric_device), + be_str_weak(get_pk), &be_const_str_solidified, - ( &(const binstruction[ 8]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x90020202, // 0001 SETMBR R0 K1 R2 - 0x90020403, // 0002 SETMBR R0 K2 R3 - 0x88100103, // 0003 GETMBR R4 R0 K3 - 0x8C100904, // 0004 GETMET R4 R4 K4 - 0x5C180000, // 0005 MOVE R6 R0 - 0x7C100400, // 0006 CALL R4 2 - 0x80000000, // 0007 RET 0 + ( &(const binstruction[ 9]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x74060004, // 0001 JMPT R1 #0007 + 0xA4060200, // 0002 IMPORT R1 K1 + 0x8C080302, // 0003 GETMET R2 R1 K2 + 0x5412001F, // 0004 LDINT R4 32 + 0x7C080400, // 0005 CALL R2 2 + 0x90020002, // 0006 SETMBR R0 K0 R2 + 0x88040100, // 0007 GETMBR R1 R0 K0 + 0x80040200, // 0008 RET 1 R1 }) ) ); @@ -904,6 +876,113 @@ be_local_closure(Matter_Session_set_persist, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: close +********************************************************************/ +be_local_closure(Matter_Session_close, /* name */ + be_nested_proto( + 9, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[24]) { /* constants */ + /* K0 */ be_nested_str_weak(_persist), + /* K1 */ be_nested_str_weak(local_session_id), + /* K2 */ be_nested_str_weak(_future_local_session_id), + /* K3 */ be_nested_str_weak(initiator_session_id), + /* K4 */ be_nested_str_weak(_future_initiator_session_id), + /* K5 */ be_nested_str_weak(source_node_id), + /* K6 */ be_nested_str_weak(counter_rcv), + /* K7 */ be_nested_str_weak(reset), + /* K8 */ be_nested_str_weak(counter_snd), + /* K9 */ be_nested_str_weak(i2rkey), + /* K10 */ be_nested_str_weak(_i2r_privacy), + /* K11 */ be_nested_str_weak(r2ikey), + /* K12 */ be_nested_str_weak(attestation_challenge), + /* K13 */ be_nested_str_weak(fabric_label), + /* K14 */ be_nested_str_weak(), + /* K15 */ be_nested_str_weak(introspect), + /* K16 */ be_nested_str_weak(members), + /* K17 */ be_nested_str_weak(get), + /* K18 */ be_nested_str_weak(function), + /* K19 */ be_nested_str_weak(instance), + /* K20 */ be_const_int(0), + /* K21 */ be_nested_str_weak(_), + /* K22 */ be_const_int(1), + /* K23 */ be_nested_str_weak(stop_iteration), + }), + be_str_weak(close), + &be_const_str_solidified, + ( &(const binstruction[59]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x88080102, // 0001 GETMBR R2 R0 K2 + 0x90020202, // 0002 SETMBR R0 K1 R2 + 0x88080104, // 0003 GETMBR R2 R0 K4 + 0x90020602, // 0004 SETMBR R0 K3 R2 + 0x4C080000, // 0005 LDNIL R2 + 0x90020A02, // 0006 SETMBR R0 K5 R2 + 0x88080106, // 0007 GETMBR R2 R0 K6 + 0x8C080507, // 0008 GETMET R2 R2 K7 + 0x7C080200, // 0009 CALL R2 1 + 0x88080108, // 000A GETMBR R2 R0 K8 + 0x8C080507, // 000B GETMET R2 R2 K7 + 0x7C080200, // 000C CALL R2 1 + 0x4C080000, // 000D LDNIL R2 + 0x90021202, // 000E SETMBR R0 K9 R2 + 0x4C080000, // 000F LDNIL R2 + 0x90021402, // 0010 SETMBR R0 K10 R2 + 0x4C080000, // 0011 LDNIL R2 + 0x90021602, // 0012 SETMBR R0 K11 R2 + 0x4C080000, // 0013 LDNIL R2 + 0x90021802, // 0014 SETMBR R0 K12 R2 + 0x90021B0E, // 0015 SETMBR R0 K13 K14 + 0xA40A1E00, // 0016 IMPORT R2 K15 + 0x600C0010, // 0017 GETGBL R3 G16 + 0x8C100510, // 0018 GETMET R4 R2 K16 + 0x5C180000, // 0019 MOVE R6 R0 + 0x7C100400, // 001A CALL R4 2 + 0x7C0C0200, // 001B CALL R3 1 + 0xA8020018, // 001C EXBLK 0 #0036 + 0x5C100600, // 001D MOVE R4 R3 + 0x7C100000, // 001E CALL R4 0 + 0x8C140511, // 001F GETMET R5 R2 K17 + 0x5C1C0000, // 0020 MOVE R7 R0 + 0x5C200800, // 0021 MOVE R8 R4 + 0x7C140600, // 0022 CALL R5 3 + 0x60180004, // 0023 GETGBL R6 G4 + 0x5C1C0A00, // 0024 MOVE R7 R5 + 0x7C180200, // 0025 CALL R6 1 + 0x20180D12, // 0026 NE R6 R6 K18 + 0x781A000C, // 0027 JMPF R6 #0035 + 0x60180004, // 0028 GETGBL R6 G4 + 0x5C1C0A00, // 0029 MOVE R7 R5 + 0x7C180200, // 002A CALL R6 1 + 0x20180D13, // 002B NE R6 R6 K19 + 0x781A0007, // 002C JMPF R6 #0035 + 0x94180914, // 002D GETIDX R6 R4 K20 + 0x1C180D15, // 002E EQ R6 R6 K21 + 0x781A0004, // 002F JMPF R6 #0035 + 0x94180916, // 0030 GETIDX R6 R4 K22 + 0x20180D15, // 0031 NE R6 R6 K21 + 0x781A0001, // 0032 JMPF R6 #0035 + 0x4C180000, // 0033 LDNIL R6 + 0x90000806, // 0034 SETMBR R0 R4 R6 + 0x7001FFE6, // 0035 JMP #001D + 0x580C0017, // 0036 LDCONST R3 K23 + 0xAC0C0200, // 0037 CATCH R3 1 0 + 0xB0080000, // 0038 RAISE 2 R0 R0 + 0x90020001, // 0039 SETMBR R0 K0 R1 + 0x80000000, // 003A RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: gen_CSR ********************************************************************/ @@ -1013,347 +1092,6 @@ be_local_closure(Matter_Session_gen_CSR, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: set_ca -********************************************************************/ -be_local_closure(Matter_Session_set_ca, /* name */ - be_nested_proto( - 2, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(root_ca_certificate), - }), - be_str_weak(set_ca), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_expire_time -********************************************************************/ -be_local_closure(Matter_Session_set_expire_time, /* name */ - be_nested_proto( - 4, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(expiration), - }), - be_str_weak(set_expire_time), - &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x60080009, // 0000 GETGBL R2 G9 - 0x5C0C0200, // 0001 MOVE R3 R1 - 0x7C080200, // 0002 CALL R2 1 - 0x90020002, // 0003 SETMBR R0 K0 R2 - 0x80000000, // 0004 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_i2r -********************************************************************/ -be_local_closure(Matter_Session_get_i2r, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(i2rkey), - }), - be_str_weak(get_i2r), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_keys -********************************************************************/ -be_local_closure(Matter_Session_set_keys, /* name */ - be_nested_proto( - 6, /* nstack */ - 5, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(i2rkey), - /* K1 */ be_nested_str_weak(_i2r_privacy), - /* K2 */ be_nested_str_weak(r2ikey), - /* K3 */ be_nested_str_weak(attestation_challenge), - /* K4 */ be_nested_str_weak(session_timestamp), - }), - be_str_weak(set_keys), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x4C140000, // 0001 LDNIL R5 - 0x90020205, // 0002 SETMBR R0 K1 R5 - 0x90020402, // 0003 SETMBR R0 K2 R2 - 0x90020603, // 0004 SETMBR R0 K3 R3 - 0x90020804, // 0005 SETMBR R0 K4 R4 - 0x80000000, // 0006 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_ca -********************************************************************/ -be_local_closure(Matter_Session_get_ca, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(root_ca_certificate), - }), - be_str_weak(get_ca), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_pk -********************************************************************/ -be_local_closure(Matter_Session_get_pk, /* name */ - be_nested_proto( - 5, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(no_private_key), - /* K1 */ be_nested_str_weak(crypto), - /* K2 */ be_nested_str_weak(random), - }), - be_str_weak(get_pk), - &be_const_str_solidified, - ( &(const binstruction[ 9]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x74060004, // 0001 JMPT R1 #0007 - 0xA4060200, // 0002 IMPORT R1 K1 - 0x8C080302, // 0003 GETMET R2 R1 K2 - 0x5412001F, // 0004 LDINT R4 32 - 0x7C080400, // 0005 CALL R2 2 - 0x90020002, // 0006 SETMBR R0 K0 R2 - 0x88040100, // 0007 GETMBR R1 R0 K0 - 0x80040200, // 0008 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_ca_pub -********************************************************************/ -be_local_closure(Matter_Session_get_ca_pub, /* name */ - be_nested_proto( - 5, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(root_ca_certificate), - /* K1 */ be_nested_str_weak(matter), - /* K2 */ be_nested_str_weak(TLV), - /* K3 */ be_nested_str_weak(parse), - /* K4 */ be_nested_str_weak(findsubval), - }), - be_str_weak(get_ca_pub), - &be_const_str_solidified, - ( &(const binstruction[12]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x78060008, // 0001 JMPF R1 #000B - 0xB8060200, // 0002 GETNGBL R1 K1 - 0x88040302, // 0003 GETMBR R1 R1 K2 - 0x8C040303, // 0004 GETMET R1 R1 K3 - 0x880C0100, // 0005 GETMBR R3 R0 K0 - 0x7C040400, // 0006 CALL R1 2 - 0x8C080304, // 0007 GETMET R2 R1 K4 - 0x54120008, // 0008 LDINT R4 9 - 0x7C080400, // 0009 CALL R2 2 - 0x80040400, // 000A RET 1 R2 - 0x80000000, // 000B RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: init -********************************************************************/ -be_local_closure(Matter_Session_init, /* name */ - be_nested_proto( - 6, /* nstack */ - 4, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[13]) { /* constants */ - /* K0 */ be_nested_str_weak(__store), - /* K1 */ be_nested_str_weak(mode), - /* K2 */ be_const_int(0), - /* K3 */ be_nested_str_weak(local_session_id), - /* K4 */ be_nested_str_weak(initiator_session_id), - /* K5 */ be_nested_str_weak(counter_rcv), - /* K6 */ be_nested_str_weak(matter), - /* K7 */ be_nested_str_weak(Counter), - /* K8 */ be_nested_str_weak(counter_snd), - /* K9 */ be_nested_str_weak(_counter_insecure_rcv), - /* K10 */ be_nested_str_weak(_counter_insecure_snd), - /* K11 */ be_nested_str_weak(breadcrumb), - /* K12 */ be_nested_str_weak(int64), - }), - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[24]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x90020302, // 0001 SETMBR R0 K1 K2 - 0x90020602, // 0002 SETMBR R0 K3 R2 - 0x90020803, // 0003 SETMBR R0 K4 R3 - 0xB8120C00, // 0004 GETNGBL R4 K6 - 0x8C100907, // 0005 GETMET R4 R4 K7 - 0x7C100200, // 0006 CALL R4 1 - 0x90020A04, // 0007 SETMBR R0 K5 R4 - 0xB8120C00, // 0008 GETNGBL R4 K6 - 0x8C100907, // 0009 GETMET R4 R4 K7 - 0x7C100200, // 000A CALL R4 1 - 0x90021004, // 000B SETMBR R0 K8 R4 - 0xB8120C00, // 000C GETNGBL R4 K6 - 0x8C100907, // 000D GETMET R4 R4 K7 - 0x7C100200, // 000E CALL R4 1 - 0x90021204, // 000F SETMBR R0 K9 R4 - 0xB8120C00, // 0010 GETNGBL R4 K6 - 0x8C100907, // 0011 GETMET R4 R4 K7 - 0x7C100200, // 0012 CALL R4 1 - 0x90021404, // 0013 SETMBR R0 K10 R4 - 0xB8121800, // 0014 GETNGBL R4 K12 - 0x7C100000, // 0015 CALL R4 0 - 0x90021604, // 0016 SETMBR R0 K11 R4 - 0x80000000, // 0017 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_ipk_group_key -********************************************************************/ -be_local_closure(Matter_Session_get_ipk_group_key, /* name */ - be_nested_proto( - 10, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 7]) { /* constants */ - /* K0 */ be_nested_str_weak(ipk_epoch_key), - /* K1 */ be_nested_str_weak(fabric_compressed), - /* K2 */ be_nested_str_weak(crypto), - /* K3 */ be_nested_str_weak(HKDF_SHA256), - /* K4 */ be_nested_str_weak(fromstring), - /* K5 */ be_nested_str_weak(__GROUP_KEY), - /* K6 */ be_nested_str_weak(derive), - }), - be_str_weak(get_ipk_group_key), - &be_const_str_solidified, - ( &(const binstruction[25]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x4C080000, // 0001 LDNIL R2 - 0x1C040202, // 0002 EQ R1 R1 R2 - 0x74060003, // 0003 JMPT R1 #0008 - 0x88040101, // 0004 GETMBR R1 R0 K1 - 0x4C080000, // 0005 LDNIL R2 - 0x1C040202, // 0006 EQ R1 R1 R2 - 0x78060001, // 0007 JMPF R1 #000A - 0x4C040000, // 0008 LDNIL R1 - 0x80040200, // 0009 RET 1 R1 - 0xA4060400, // 000A IMPORT R1 K2 - 0x8C080303, // 000B GETMET R2 R1 K3 - 0x7C080200, // 000C CALL R2 1 - 0x600C0015, // 000D GETGBL R3 G21 - 0x7C0C0000, // 000E CALL R3 0 - 0x8C0C0704, // 000F GETMET R3 R3 K4 - 0x88140105, // 0010 GETMBR R5 R0 K5 - 0x7C0C0400, // 0011 CALL R3 2 - 0x8C100506, // 0012 GETMET R4 R2 K6 - 0x88180100, // 0013 GETMBR R6 R0 K0 - 0x881C0101, // 0014 GETMBR R7 R0 K1 - 0x5C200600, // 0015 MOVE R8 R3 - 0x5426000F, // 0016 LDINT R9 16 - 0x7C100A00, // 0017 CALL R4 5 - 0x80040800, // 0018 RET 1 R4 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: set_noc ********************************************************************/ @@ -1384,9 +1122,9 @@ be_local_closure(Matter_Session_set_noc, /* name */ /******************************************************************** -** Solidified function: get_fabric +** Solidified function: get_noc ********************************************************************/ -be_local_closure(Matter_Session_get_fabric, /* name */ +be_local_closure(Matter_Session_get_noc, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -1397,9 +1135,135 @@ be_local_closure(Matter_Session_get_fabric, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(fabric), + /* K0 */ be_nested_str_weak(noc), }), - be_str_weak(get_fabric), + be_str_weak(get_noc), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_ac +********************************************************************/ +be_local_closure(Matter_Session_get_ac, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(attestation_challenge), + }), + be_str_weak(get_ac), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_Session_init, /* name */ + be_nested_proto( + 9, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[17]) { /* constants */ + /* K0 */ be_nested_str_weak(crypto), + /* K1 */ be_nested_str_weak(__store), + /* K2 */ be_nested_str_weak(mode), + /* K3 */ be_const_int(0), + /* K4 */ be_nested_str_weak(local_session_id), + /* K5 */ be_nested_str_weak(initiator_session_id), + /* K6 */ be_nested_str_weak(counter_rcv), + /* K7 */ be_nested_str_weak(matter), + /* K8 */ be_nested_str_weak(Counter), + /* K9 */ be_nested_str_weak(counter_snd), + /* K10 */ be_nested_str_weak(_counter_insecure_rcv), + /* K11 */ be_nested_str_weak(_counter_insecure_snd), + /* K12 */ be_nested_str_weak(__breadcrumb), + /* K13 */ be_nested_str_weak(__exchange_id), + /* K14 */ be_nested_str_weak(random), + /* K15 */ be_const_int(2), + /* K16 */ be_nested_str_weak(get), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[31]) { /* code */ + 0xA4120000, // 0000 IMPORT R4 K0 + 0x90020201, // 0001 SETMBR R0 K1 R1 + 0x90020503, // 0002 SETMBR R0 K2 K3 + 0x90020802, // 0003 SETMBR R0 K4 R2 + 0x90020A03, // 0004 SETMBR R0 K5 R3 + 0xB8160E00, // 0005 GETNGBL R5 K7 + 0x8C140B08, // 0006 GETMET R5 R5 K8 + 0x7C140200, // 0007 CALL R5 1 + 0x90020C05, // 0008 SETMBR R0 K6 R5 + 0xB8160E00, // 0009 GETNGBL R5 K7 + 0x8C140B08, // 000A GETMET R5 R5 K8 + 0x7C140200, // 000B CALL R5 1 + 0x90021205, // 000C SETMBR R0 K9 R5 + 0xB8160E00, // 000D GETNGBL R5 K7 + 0x8C140B08, // 000E GETMET R5 R5 K8 + 0x7C140200, // 000F CALL R5 1 + 0x90021405, // 0010 SETMBR R0 K10 R5 + 0xB8160E00, // 0011 GETNGBL R5 K7 + 0x8C140B08, // 0012 GETMET R5 R5 K8 + 0x7C140200, // 0013 CALL R5 1 + 0x90021605, // 0014 SETMBR R0 K11 R5 + 0x90021903, // 0015 SETMBR R0 K12 K3 + 0x8C14090E, // 0016 GETMET R5 R4 K14 + 0x581C000F, // 0017 LDCONST R7 K15 + 0x7C140400, // 0018 CALL R5 2 + 0x8C140B10, // 0019 GETMET R5 R5 K16 + 0x581C0003, // 001A LDCONST R7 K3 + 0x5820000F, // 001B LDCONST R8 K15 + 0x7C140600, // 001C CALL R5 3 + 0x90021A05, // 001D SETMBR R0 K13 R5 + 0x80000000, // 001E RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_icac +********************************************************************/ +be_local_closure(Matter_Session_get_icac, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(icac), + }), + be_str_weak(get_icac), &be_const_str_solidified, ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -1438,12 +1302,102 @@ be_local_closure(Matter_Session_get_mode, /* name */ /******************************************************************** -** Solidified function: set_mode +** Solidified function: set_fabric_device ********************************************************************/ -be_local_closure(Matter_Session_set_mode, /* name */ +be_local_closure(Matter_Session_set_fabric_device, /* name */ + be_nested_proto( + 7, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(fabric), + /* K1 */ be_nested_str_weak(deviceid), + /* K2 */ be_nested_str_weak(fabric_compressed), + /* K3 */ be_nested_str_weak(__store), + /* K4 */ be_nested_str_weak(remove_redundant_session), + }), + be_str_weak(set_fabric_device), + &be_const_str_solidified, + ( &(const binstruction[ 8]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x90020202, // 0001 SETMBR R0 K1 R2 + 0x90020403, // 0002 SETMBR R0 K2 R3 + 0x88100103, // 0003 GETMBR R4 R0 K3 + 0x8C100904, // 0004 GETMET R4 R4 K4 + 0x5C180000, // 0005 MOVE R6 R0 + 0x7C100400, // 0006 CALL R4 2 + 0x80000000, // 0007 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_i2r_privacy +********************************************************************/ +be_local_closure(Matter_Session_get_i2r_privacy, /* name */ + be_nested_proto( + 9, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 7]) { /* constants */ + /* K0 */ be_nested_str_weak(_i2r_privacy), + /* K1 */ be_nested_str_weak(crypto), + /* K2 */ be_nested_str_weak(HKDF_SHA256), + /* K3 */ be_nested_str_weak(derive), + /* K4 */ be_nested_str_weak(get_i2r), + /* K5 */ be_nested_str_weak(fromstring), + /* K6 */ be_nested_str_weak(PrivacyKey), + }), + be_str_weak(get_i2r_privacy), + &be_const_str_solidified, + ( &(const binstruction[22]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x4C080000, // 0001 LDNIL R2 + 0x1C040202, // 0002 EQ R1 R1 R2 + 0x7806000F, // 0003 JMPF R1 #0014 + 0xA4060200, // 0004 IMPORT R1 K1 + 0x8C080302, // 0005 GETMET R2 R1 K2 + 0x7C080200, // 0006 CALL R2 1 + 0x8C080503, // 0007 GETMET R2 R2 K3 + 0x8C100104, // 0008 GETMET R4 R0 K4 + 0x7C100200, // 0009 CALL R4 1 + 0x60140015, // 000A GETGBL R5 G21 + 0x7C140000, // 000B CALL R5 0 + 0x60180015, // 000C GETGBL R6 G21 + 0x7C180000, // 000D CALL R6 0 + 0x8C180D05, // 000E GETMET R6 R6 K5 + 0x58200006, // 000F LDCONST R8 K6 + 0x7C180400, // 0010 CALL R6 2 + 0x541E000F, // 0011 LDINT R7 16 + 0x7C080A00, // 0012 CALL R2 5 + 0x90020002, // 0013 SETMBR R0 K0 R2 + 0x88040100, // 0014 GETMBR R1 R0 K0 + 0x80040200, // 0015 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_ca +********************************************************************/ +be_local_closure(Matter_Session_get_ca, /* name */ be_nested_proto( 2, /* nstack */ - 2, /* argc */ + 1, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -1451,13 +1405,70 @@ be_local_closure(Matter_Session_set_mode, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(mode), + /* K0 */ be_nested_str_weak(root_ca_certificate), }), - be_str_weak(set_mode), + be_str_weak(get_ca), &be_const_str_solidified, ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: save +********************************************************************/ +be_local_closure(Matter_Session_save, /* name */ + be_nested_proto( + 3, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(__store), + /* K1 */ be_nested_str_weak(save), + }), + be_str_weak(save), + &be_const_str_solidified, + ( &(const binstruction[ 4]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0x80000000, // 0003 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: get_fabric_compressed +********************************************************************/ +be_local_closure(Matter_Session_get_fabric_compressed, /* name */ + be_nested_proto( + 2, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(fabric_compressed), + }), + be_str_weak(get_fabric_compressed), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -1468,82 +1479,85 @@ be_local_closure(Matter_Session_set_mode, /* name */ ** Solidified class: Matter_Session ********************************************************************/ be_local_class(Matter_Session, - 36, + 39, NULL, - be_nested_map(72, + be_nested_map(75, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(save, -1), be_const_closure(Matter_Session_save_closure) }, + { be_const_key_weak(peer_node_id, -1), be_const_var(19) }, + { be_const_key_weak(fabric_label, -1), be_const_var(31) }, + { be_const_key_weak(set_fabric_label, 1), be_const_closure(Matter_Session_set_fabric_label_closure) }, + { be_const_key_weak(get_r2i, -1), be_const_closure(Matter_Session_get_r2i_closure) }, + { be_const_key_weak(get_ca, 61), be_const_closure(Matter_Session_get_ca_closure) }, { be_const_key_weak(set_mode, -1), be_const_closure(Matter_Session_set_mode_closure) }, - { be_const_key_weak(root_ca_certificate, -1), be_const_var(19) }, - { be_const_key_weak(admin_subject, 29), be_const_var(29) }, - { be_const_key_weak(get_i2r_privacy, 25), be_const_closure(Matter_Session_get_i2r_privacy_closure) }, - { be_const_key_weak(has_expired, -1), be_const_closure(Matter_Session_has_expired_closure) }, - { be_const_key_weak(set_no_expiration, -1), be_const_closure(Matter_Session_set_no_expiration_closure) }, - { be_const_key_weak(get_deviceid, 61), be_const_closure(Matter_Session_get_deviceid_closure) }, - { be_const_key_weak(local_session_id, -1), be_const_var(2) }, - { be_const_key_weak(get_mode, -1), be_const_closure(Matter_Session_get_mode_closure) }, - { be_const_key_weak(set_fabric_device, -1), be_const_closure(Matter_Session_set_fabric_device_closure) }, - { be_const_key_weak(fromjson, -1), be_const_static_closure(Matter_Session_fromjson_closure) }, - { be_const_key_weak(get_ipk_epoch_key, -1), be_const_closure(Matter_Session_get_ipk_epoch_key_closure) }, - { be_const_key_weak(get_fabric, 33), be_const_closure(Matter_Session_get_fabric_closure) }, - { be_const_key_weak(tojson, -1), be_const_closure(Matter_Session_tojson_closure) }, - { be_const_key_weak(set_noc, 37), be_const_closure(Matter_Session_set_noc_closure) }, - { be_const_key_weak(get_ac, -1), be_const_closure(Matter_Session_get_ac_closure) }, - { be_const_key_weak(_counter_insecure_snd, 6), be_const_var(11) }, - { be_const_key_weak(initiator_session_id, -1), be_const_var(3) }, - { be_const_key_weak(get_fabric_compressed, -1), be_const_closure(Matter_Session_get_fabric_compressed_closure) }, - { be_const_key_weak(set_fabric_label, -1), be_const_closure(Matter_Session_set_fabric_label_closure) }, - { be_const_key_weak(shared_secret, 8), be_const_var(24) }, - { be_const_key_weak(get_ipk_group_key, 43), be_const_closure(Matter_Session_get_ipk_group_key_closure) }, - { be_const_key_weak(init, 42), be_const_closure(Matter_Session_init_closure) }, - { be_const_key_weak(_chunked_attr_reports, -1), be_const_var(35) }, - { be_const_key_weak(set_persist, -1), be_const_closure(Matter_Session_set_persist_closure) }, - { be_const_key_weak(_future_initiator_session_id, -1), be_const_var(6) }, - { be_const_key_weak(_Msg2, -1), be_const_var(32) }, - { be_const_key_weak(fabric, -1), be_const_var(25) }, - { be_const_key_weak(close, -1), be_const_closure(Matter_Session_close_closure) }, - { be_const_key_weak(_i2r_privacy, -1), be_const_var(14) }, - { be_const_key_weak(ipk_epoch_key, -1), be_const_var(22) }, - { be_const_key_weak(get_ca, 10), be_const_closure(Matter_Session_get_ca_closure) }, - { be_const_key_weak(resumption_id, -1), be_const_var(23) }, - { be_const_key_weak(gen_CSR, 38), be_const_closure(Matter_Session_gen_CSR_closure) }, - { be_const_key_weak(source_node_id, -1), be_const_var(5) }, - { be_const_key_weak(set_ca, -1), be_const_closure(Matter_Session_set_ca_closure) }, - { be_const_key_weak(set_ipk_epoch_key, -1), be_const_closure(Matter_Session_set_ipk_epoch_key_closure) }, - { be_const_key_weak(_future_local_session_id, -1), be_const_var(7) }, - { be_const_key_weak(get_r2i, 31), be_const_closure(Matter_Session_get_r2i_closure) }, - { be_const_key_weak(icac, -1), be_const_var(21) }, - { be_const_key_weak(fabric_label, -1), be_const_var(28) }, - { be_const_key_weak(attestation_challenge, -1), be_const_var(15) }, - { be_const_key_weak(peer_node_id, 49), be_const_var(16) }, - { be_const_key_weak(get_noc, 53), be_const_closure(Matter_Session_get_noc_closure) }, - { be_const_key_weak(set_expire_time, 40), be_const_closure(Matter_Session_set_expire_time_closure) }, - { be_const_key_weak(deviceid, -1), be_const_var(27) }, + { be_const_key_weak(set_expire_time, -1), be_const_closure(Matter_Session_set_expire_time_closure) }, + { be_const_key_weak(get_i2r, -1), be_const_closure(Matter_Session_get_i2r_closure) }, { be_const_key_weak(__CASE, -1), be_const_int(2) }, - { be_const_key_weak(get_icac, 50), be_const_closure(Matter_Session_get_icac_closure) }, - { be_const_key_weak(_Msg1, -1), be_const_var(31) }, - { be_const_key_weak(set_keys, 58), be_const_closure(Matter_Session_set_keys_closure) }, - { be_const_key_weak(noc, 23), be_const_var(20) }, - { be_const_key_weak(__PASE, -1), be_const_int(1) }, - { be_const_key_weak(breadcrumb, 26), be_const_var(17) }, - { be_const_key_weak(__GROUP_KEY, -1), be_nested_str_weak(GroupKey_X20v1_X2E0) }, - { be_const_key_weak(counter_snd, -1), be_const_var(9) }, - { be_const_key_weak(fabric_compressed, 32), be_const_var(26) }, - { be_const_key_weak(get_pk, -1), be_const_closure(Matter_Session_get_pk_closure) }, - { be_const_key_weak(expiration, -1), be_const_var(34) }, - { be_const_key_weak(r2ikey, -1), be_const_var(13) }, - { be_const_key_weak(get_ca_pub, -1), be_const_closure(Matter_Session_get_ca_pub_closure) }, - { be_const_key_weak(counter_rcv, -1), be_const_var(8) }, - { be_const_key_weak(_persist, 22), be_const_var(33) }, - { be_const_key_weak(i2rkey, 18), be_const_var(12) }, - { be_const_key_weak(session_timestamp, 15), be_const_var(4) }, + { be_const_key_weak(get_ipk_epoch_key, -1), be_const_closure(Matter_Session_get_ipk_epoch_key_closure) }, + { be_const_key_weak(_future_local_session_id, -1), be_const_var(7) }, { be_const_key_weak(set_expire_in_seconds, 13), be_const_closure(Matter_Session_set_expire_in_seconds_closure) }, - { be_const_key_weak(mode, -1), be_const_var(1) }, - { be_const_key_weak(get_i2r, 9), be_const_closure(Matter_Session_get_i2r_closure) }, + { be_const_key_weak(admin_vendor, -1), be_const_var(33) }, + { be_const_key_weak(fromjson, -1), be_const_static_closure(Matter_Session_fromjson_closure) }, + { be_const_key_weak(set_ca, -1), be_const_closure(Matter_Session_set_ca_closure) }, + { be_const_key_weak(expiration, -1), be_const_var(37) }, + { be_const_key_weak(get_deviceid, 63), be_const_closure(Matter_Session_get_deviceid_closure) }, + { be_const_key_weak(has_expired, -1), be_const_closure(Matter_Session_has_expired_closure) }, + { be_const_key_weak(i2rkey, -1), be_const_var(15) }, + { be_const_key_weak(get_pk, -1), be_const_closure(Matter_Session_get_pk_closure) }, + { be_const_key_weak(get_fabric, -1), be_const_closure(Matter_Session_get_fabric_closure) }, + { be_const_key_weak(admin_subject, 34), be_const_var(32) }, + { be_const_key_weak(noc, -1), be_const_var(23) }, + { be_const_key_weak(get_ipk_group_key, -1), be_const_closure(Matter_Session_get_ipk_group_key_closure) }, + { be_const_key_weak(get_ca_pub, -1), be_const_closure(Matter_Session_get_ca_pub_closure) }, + { be_const_key_weak(ipk_epoch_key, 14), be_const_var(25) }, + { be_const_key_weak(tojson, 54), be_const_closure(Matter_Session_tojson_closure) }, + { be_const_key_weak(_i2r_privacy, 66), be_const_var(17) }, + { be_const_key_weak(get_icac, 39), be_const_closure(Matter_Session_get_icac_closure) }, + { be_const_key_weak(init, 35), be_const_closure(Matter_Session_init_closure) }, + { be_const_key_weak(shared_secret, 29), be_const_var(27) }, + { be_const_key_weak(set_persist, -1), be_const_closure(Matter_Session_set_persist_closure) }, + { be_const_key_weak(resumption_id, -1), be_const_var(26) }, + { be_const_key_weak(r2ikey, 38), be_const_var(16) }, + { be_const_key_weak(__breadcrumb, 60), be_const_var(20) }, + { be_const_key_weak(local_session_id, 19), be_const_var(2) }, + { be_const_key_weak(__GROUP_KEY, 22), be_nested_str_weak(GroupKey_X20v1_X2E0) }, + { be_const_key_weak(deviceid, -1), be_const_var(30) }, + { be_const_key_weak(source_node_id, -1), be_const_var(5) }, + { be_const_key_weak(attestation_challenge, 25), be_const_var(18) }, + { be_const_key_weak(no_private_key, 62), be_const_var(21) }, + { be_const_key_weak(_future_initiator_session_id, 4), be_const_var(6) }, + { be_const_key_weak(fabric, -1), be_const_var(28) }, + { be_const_key_weak(counter_rcv, -1), be_const_var(8) }, + { be_const_key_weak(__ip, -1), be_const_var(11) }, + { be_const_key_weak(_counter_insecure_rcv, -1), be_const_var(13) }, + { be_const_key_weak(gen_CSR, 59), be_const_closure(Matter_Session_gen_CSR_closure) }, + { be_const_key_weak(__port, 33), be_const_var(12) }, + { be_const_key_weak(mode, 28), be_const_var(1) }, + { be_const_key_weak(session_timestamp, 42), be_const_var(4) }, { be_const_key_weak(__store, -1), be_const_var(0) }, - { be_const_key_weak(_counter_insecure_rcv, -1), be_const_var(10) }, - { be_const_key_weak(no_private_key, 2), be_const_var(18) }, - { be_const_key_weak(admin_vendor, 1), be_const_var(30) }, + { be_const_key_weak(icac, -1), be_const_var(24) }, + { be_const_key_weak(counter_snd, -1), be_const_var(9) }, + { be_const_key_weak(_counter_insecure_snd, -1), be_const_var(14) }, + { be_const_key_weak(_Msg1, 12), be_const_var(34) }, + { be_const_key_weak(set_ipk_epoch_key, 44), be_const_closure(Matter_Session_set_ipk_epoch_key_closure) }, + { be_const_key_weak(get_noc, -1), be_const_closure(Matter_Session_get_noc_closure) }, + { be_const_key_weak(_Msg2, -1), be_const_var(35) }, + { be_const_key_weak(get_ac, -1), be_const_closure(Matter_Session_get_ac_closure) }, + { be_const_key_weak(set_noc, -1), be_const_closure(Matter_Session_set_noc_closure) }, + { be_const_key_weak(_chunked_attr_reports, 27), be_const_var(38) }, + { be_const_key_weak(_persist, -1), be_const_var(36) }, + { be_const_key_weak(__exchange_id, -1), be_const_var(10) }, + { be_const_key_weak(__PASE, -1), be_const_int(1) }, + { be_const_key_weak(get_mode, -1), be_const_closure(Matter_Session_get_mode_closure) }, + { be_const_key_weak(fabric_compressed, -1), be_const_var(29) }, + { be_const_key_weak(close, 71), be_const_closure(Matter_Session_close_closure) }, + { be_const_key_weak(root_ca_certificate, -1), be_const_var(22) }, + { be_const_key_weak(set_fabric_device, -1), be_const_closure(Matter_Session_set_fabric_device_closure) }, + { be_const_key_weak(initiator_session_id, -1), be_const_var(3) }, + { be_const_key_weak(get_i2r_privacy, -1), be_const_closure(Matter_Session_get_i2r_privacy_closure) }, + { be_const_key_weak(set_keys, 3), be_const_closure(Matter_Session_set_keys_closure) }, + { be_const_key_weak(save, -1), be_const_closure(Matter_Session_save_closure) }, + { be_const_key_weak(get_fabric_compressed, -1), be_const_closure(Matter_Session_get_fabric_compressed_closure) }, + { be_const_key_weak(set_no_expiration, 0), be_const_closure(Matter_Session_set_no_expiration_closure) }, })), be_str_weak(Matter_Session) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_TLV.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_TLV.h index dc225d633..bac1a044b 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_TLV.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_TLV.h @@ -6,6 +6,264 @@ extern const bclass be_class_Matter_TLV_item; +/******************************************************************** +** Solidified function: set_parent +********************************************************************/ +be_local_closure(Matter_TLV_item_set_parent, /* name */ + be_nested_proto( + 2, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(parent), + }), + be_str_weak(set_parent), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x80000000, // 0001 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: create_TLV +********************************************************************/ +be_local_closure(Matter_TLV_item_create_TLV, /* name */ + be_nested_proto( + 4, /* nstack */ + 2, /* argc */ + 4, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_const_class(be_class_Matter_TLV_item), + /* K1 */ be_nested_str_weak(typ), + /* K2 */ be_nested_str_weak(val), + }), + be_str_weak(create_TLV), + &be_const_str_solidified, + ( &(const binstruction[10]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0x4C0C0000, // 0001 LDNIL R3 + 0x200C0203, // 0002 NE R3 R1 R3 + 0x780E0004, // 0003 JMPF R3 #0009 + 0x5C0C0400, // 0004 MOVE R3 R2 + 0x7C0C0000, // 0005 CALL R3 0 + 0x900E0200, // 0006 SETMBR R3 K1 R0 + 0x900E0401, // 0007 SETMBR R3 K2 R1 + 0x80040600, // 0008 RET 1 R3 + 0x80000000, // 0009 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_anonymoustag +********************************************************************/ +be_local_closure(Matter_TLV_item_set_anonymoustag, /* name */ + be_nested_proto( + 3, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(set_fulltag), + }), + be_str_weak(set_anonymoustag), + &be_const_str_solidified, + ( &(const binstruction[ 3]) { /* code */ + 0x8C040100, // 0000 GETMET R1 R0 K0 + 0x7C040200, // 0001 CALL R1 1 + 0x80000000, // 0002 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: _encode_tag +********************************************************************/ +be_local_closure(Matter_TLV_item__encode_tag, /* name */ + be_nested_proto( + 9, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 9]) { /* constants */ + /* K0 */ be_nested_str_weak(tag_number), + /* K1 */ be_const_int(0), + /* K2 */ be_nested_str_weak(tag_vendor), + /* K3 */ be_nested_str_weak(add), + /* K4 */ be_nested_str_weak(typ), + /* K5 */ be_const_int(1), + /* K6 */ be_const_int(2), + /* K7 */ be_nested_str_weak(tag_profile), + /* K8 */ be_nested_str_weak(tag_sub), + }), + be_str_weak(_encode_tag), + &be_const_str_solidified, + ( &(const binstruction[133]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x4C0C0000, // 0001 LDNIL R3 + 0x20080403, // 0002 NE R2 R2 R3 + 0x780A0001, // 0003 JMPF R2 #0006 + 0x88080100, // 0004 GETMBR R2 R0 K0 + 0x70020000, // 0005 JMP #0007 + 0x58080001, // 0006 LDCONST R2 K1 + 0x540EFFFF, // 0007 LDINT R3 65536 + 0x280C0403, // 0008 GE R3 R2 R3 + 0x740E0002, // 0009 JMPT R3 #000D + 0x140C0501, // 000A LT R3 R2 K1 + 0x740E0000, // 000B JMPT R3 #000D + 0x500C0001, // 000C LDBOOL R3 0 1 + 0x500C0200, // 000D LDBOOL R3 1 0 + 0x58100001, // 000E LDCONST R4 K1 + 0x88140102, // 000F GETMBR R5 R0 K2 + 0x4C180000, // 0010 LDNIL R6 + 0x20140A06, // 0011 NE R5 R5 R6 + 0x78160026, // 0012 JMPF R5 #003A + 0x780E0012, // 0013 JMPF R3 #0027 + 0x8C140303, // 0014 GETMET R5 R1 K3 + 0x541E00DF, // 0015 LDINT R7 224 + 0x88200104, // 0016 GETMBR R8 R0 K4 + 0x001C0E08, // 0017 ADD R7 R7 R8 + 0x58200005, // 0018 LDCONST R8 K5 + 0x7C140600, // 0019 CALL R5 3 + 0x8C140303, // 001A GETMET R5 R1 K3 + 0x881C0102, // 001B GETMBR R7 R0 K2 + 0x58200006, // 001C LDCONST R8 K6 + 0x7C140600, // 001D CALL R5 3 + 0x8C140303, // 001E GETMET R5 R1 K3 + 0x881C0107, // 001F GETMBR R7 R0 K7 + 0x58200006, // 0020 LDCONST R8 K6 + 0x7C140600, // 0021 CALL R5 3 + 0x8C140303, // 0022 GETMET R5 R1 K3 + 0x881C0100, // 0023 GETMBR R7 R0 K0 + 0x54220003, // 0024 LDINT R8 4 + 0x7C140600, // 0025 CALL R5 3 + 0x70020011, // 0026 JMP #0039 + 0x8C140303, // 0027 GETMET R5 R1 K3 + 0x541E00BF, // 0028 LDINT R7 192 + 0x88200104, // 0029 GETMBR R8 R0 K4 + 0x001C0E08, // 002A ADD R7 R7 R8 + 0x58200005, // 002B LDCONST R8 K5 + 0x7C140600, // 002C CALL R5 3 + 0x8C140303, // 002D GETMET R5 R1 K3 + 0x881C0102, // 002E GETMBR R7 R0 K2 + 0x58200006, // 002F LDCONST R8 K6 + 0x7C140600, // 0030 CALL R5 3 + 0x8C140303, // 0031 GETMET R5 R1 K3 + 0x881C0107, // 0032 GETMBR R7 R0 K7 + 0x58200006, // 0033 LDCONST R8 K6 + 0x7C140600, // 0034 CALL R5 3 + 0x8C140303, // 0035 GETMET R5 R1 K3 + 0x881C0100, // 0036 GETMBR R7 R0 K0 + 0x58200006, // 0037 LDCONST R8 K6 + 0x7C140600, // 0038 CALL R5 3 + 0x70020049, // 0039 JMP #0084 + 0x88140107, // 003A GETMBR R5 R0 K7 + 0x5419FFFE, // 003B LDINT R6 -1 + 0x1C140A06, // 003C EQ R5 R5 R6 + 0x78160016, // 003D JMPF R5 #0055 + 0x780E000A, // 003E JMPF R3 #004A + 0x8C140303, // 003F GETMET R5 R1 K3 + 0x541E005F, // 0040 LDINT R7 96 + 0x88200104, // 0041 GETMBR R8 R0 K4 + 0x001C0E08, // 0042 ADD R7 R7 R8 + 0x58200005, // 0043 LDCONST R8 K5 + 0x7C140600, // 0044 CALL R5 3 + 0x8C140303, // 0045 GETMET R5 R1 K3 + 0x881C0100, // 0046 GETMBR R7 R0 K0 + 0x54220003, // 0047 LDINT R8 4 + 0x7C140600, // 0048 CALL R5 3 + 0x70020009, // 0049 JMP #0054 + 0x8C140303, // 004A GETMET R5 R1 K3 + 0x541E003F, // 004B LDINT R7 64 + 0x88200104, // 004C GETMBR R8 R0 K4 + 0x001C0E08, // 004D ADD R7 R7 R8 + 0x58200005, // 004E LDCONST R8 K5 + 0x7C140600, // 004F CALL R5 3 + 0x8C140303, // 0050 GETMET R5 R1 K3 + 0x881C0100, // 0051 GETMBR R7 R0 K0 + 0x58200006, // 0052 LDCONST R8 K6 + 0x7C140600, // 0053 CALL R5 3 + 0x7002002E, // 0054 JMP #0084 + 0x88140107, // 0055 GETMBR R5 R0 K7 + 0x4C180000, // 0056 LDNIL R6 + 0x20140A06, // 0057 NE R5 R5 R6 + 0x78160016, // 0058 JMPF R5 #0070 + 0x780E000A, // 0059 JMPF R3 #0065 + 0x8C140303, // 005A GETMET R5 R1 K3 + 0x541E009F, // 005B LDINT R7 160 + 0x88200104, // 005C GETMBR R8 R0 K4 + 0x001C0E08, // 005D ADD R7 R7 R8 + 0x58200005, // 005E LDCONST R8 K5 + 0x7C140600, // 005F CALL R5 3 + 0x8C140303, // 0060 GETMET R5 R1 K3 + 0x881C0100, // 0061 GETMBR R7 R0 K0 + 0x54220003, // 0062 LDINT R8 4 + 0x7C140600, // 0063 CALL R5 3 + 0x70020009, // 0064 JMP #006F + 0x8C140303, // 0065 GETMET R5 R1 K3 + 0x541E007F, // 0066 LDINT R7 128 + 0x88200104, // 0067 GETMBR R8 R0 K4 + 0x001C0E08, // 0068 ADD R7 R7 R8 + 0x58200005, // 0069 LDCONST R8 K5 + 0x7C140600, // 006A CALL R5 3 + 0x8C140303, // 006B GETMET R5 R1 K3 + 0x881C0100, // 006C GETMBR R7 R0 K0 + 0x58200006, // 006D LDCONST R8 K6 + 0x7C140600, // 006E CALL R5 3 + 0x70020013, // 006F JMP #0084 + 0x88140108, // 0070 GETMBR R5 R0 K8 + 0x4C180000, // 0071 LDNIL R6 + 0x20140A06, // 0072 NE R5 R5 R6 + 0x7816000A, // 0073 JMPF R5 #007F + 0x8C140303, // 0074 GETMET R5 R1 K3 + 0x541E001F, // 0075 LDINT R7 32 + 0x88200104, // 0076 GETMBR R8 R0 K4 + 0x001C0E08, // 0077 ADD R7 R7 R8 + 0x58200005, // 0078 LDCONST R8 K5 + 0x7C140600, // 0079 CALL R5 3 + 0x8C140303, // 007A GETMET R5 R1 K3 + 0x881C0108, // 007B GETMBR R7 R0 K8 + 0x58200005, // 007C LDCONST R8 K5 + 0x7C140600, // 007D CALL R5 3 + 0x70020004, // 007E JMP #0084 + 0x8C140303, // 007F GETMET R5 R1 K3 + 0x881C0104, // 0080 GETMBR R7 R0 K4 + 0x001E0207, // 0081 ADD R7 K1 R7 + 0x58200005, // 0082 LDCONST R8 K5 + 0x7C140600, // 0083 CALL R5 3 + 0x80000000, // 0084 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: set_commonprofile ********************************************************************/ @@ -37,6 +295,826 @@ be_local_closure(Matter_TLV_item_set_commonprofile, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: _cmp_gt +********************************************************************/ +be_local_closure(Matter_TLV_item__cmp_gt, /* name */ + be_nested_proto( + 4, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 6]) { /* constants */ + /* K0 */ be_nested_str_weak(tag_vendor), + /* K1 */ be_const_int(1), + /* K2 */ be_nested_str_weak(tag_profile), + /* K3 */ be_const_int(0), + /* K4 */ be_nested_str_weak(tag_number), + /* K5 */ be_nested_str_weak(tag_sub), + }), + be_str_weak(_cmp_gt), + &be_const_str_solidified, + ( &(const binstruction[72]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x4C0C0000, // 0001 LDNIL R3 + 0x20080403, // 0002 NE R2 R2 R3 + 0x780A0012, // 0003 JMPF R2 #0017 + 0x88080300, // 0004 GETMBR R2 R1 K0 + 0x4C0C0000, // 0005 LDNIL R3 + 0x1C080403, // 0006 EQ R2 R2 R3 + 0x780A0000, // 0007 JMPF R2 #0009 + 0x80060200, // 0008 RET 1 K1 + 0x88080100, // 0009 GETMBR R2 R0 K0 + 0x880C0300, // 000A GETMBR R3 R1 K0 + 0x24080403, // 000B GT R2 R2 R3 + 0x780A0000, // 000C JMPF R2 #000E + 0x80060200, // 000D RET 1 K1 + 0x88080100, // 000E GETMBR R2 R0 K0 + 0x880C0300, // 000F GETMBR R3 R1 K0 + 0x1C080403, // 0010 EQ R2 R2 R3 + 0x780A0004, // 0011 JMPF R2 #0017 + 0x88080102, // 0012 GETMBR R2 R0 K2 + 0x880C0302, // 0013 GETMBR R3 R1 K2 + 0x24080403, // 0014 GT R2 R2 R3 + 0x780A0000, // 0015 JMPF R2 #0017 + 0x80060200, // 0016 RET 1 K1 + 0x88080102, // 0017 GETMBR R2 R0 K2 + 0x540DFFFE, // 0018 LDINT R3 -1 + 0x1C080403, // 0019 EQ R2 R2 R3 + 0x780A0005, // 001A JMPF R2 #0021 + 0x88080302, // 001B GETMBR R2 R1 K2 + 0x4C0C0000, // 001C LDNIL R3 + 0x1C080403, // 001D EQ R2 R2 R3 + 0x780A0000, // 001E JMPF R2 #0020 + 0x80060200, // 001F RET 1 K1 + 0x70020008, // 0020 JMP #002A + 0x88080102, // 0021 GETMBR R2 R0 K2 + 0x4C0C0000, // 0022 LDNIL R3 + 0x1C080403, // 0023 EQ R2 R2 R3 + 0x780A0004, // 0024 JMPF R2 #002A + 0x88080302, // 0025 GETMBR R2 R1 K2 + 0x540DFFFE, // 0026 LDINT R3 -1 + 0x1C080403, // 0027 EQ R2 R2 R3 + 0x780A0000, // 0028 JMPF R2 #002A + 0x80060600, // 0029 RET 1 K3 + 0x88080104, // 002A GETMBR R2 R0 K4 + 0x4C0C0000, // 002B LDNIL R3 + 0x20080403, // 002C NE R2 R2 R3 + 0x780A000A, // 002D JMPF R2 #0039 + 0x88080304, // 002E GETMBR R2 R1 K4 + 0x4C0C0000, // 002F LDNIL R3 + 0x1C080403, // 0030 EQ R2 R2 R3 + 0x780A0000, // 0031 JMPF R2 #0033 + 0x80060200, // 0032 RET 1 K1 + 0x88080104, // 0033 GETMBR R2 R0 K4 + 0x880C0304, // 0034 GETMBR R3 R1 K4 + 0x24080403, // 0035 GT R2 R2 R3 + 0x780A0000, // 0036 JMPF R2 #0038 + 0x80060200, // 0037 RET 1 K1 + 0x80060600, // 0038 RET 1 K3 + 0x88080105, // 0039 GETMBR R2 R0 K5 + 0x4C0C0000, // 003A LDNIL R3 + 0x20080403, // 003B NE R2 R2 R3 + 0x780A0009, // 003C JMPF R2 #0047 + 0x88080305, // 003D GETMBR R2 R1 K5 + 0x4C0C0000, // 003E LDNIL R3 + 0x1C080403, // 003F EQ R2 R2 R3 + 0x780A0000, // 0040 JMPF R2 #0042 + 0x80060200, // 0041 RET 1 K1 + 0x88080105, // 0042 GETMBR R2 R0 K5 + 0x880C0305, // 0043 GETMBR R3 R1 K5 + 0x24080403, // 0044 GT R2 R2 R3 + 0x780A0000, // 0045 JMPF R2 #0047 + 0x80060200, // 0046 RET 1 K1 + 0x80060600, // 0047 RET 1 K3 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: tostring +********************************************************************/ +be_local_closure(Matter_TLV_item_tostring, /* name */ + be_nested_proto( + 8, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[35]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(), + /* K2 */ be_nested_str_weak(tag_profile), + /* K3 */ be_nested_str_weak(Matter_X3A_X3A), + /* K4 */ be_nested_str_weak(tag_number), + /* K5 */ be_nested_str_weak(format), + /* K6 */ be_nested_str_weak(0x_X2508X_X20), + /* K7 */ be_nested_str_weak(tag_vendor), + /* K8 */ be_nested_str_weak(0x_X2504X_X3A_X3A), + /* K9 */ be_nested_str_weak(0x_X2504X_X3A), + /* K10 */ be_nested_str_weak(tag_sub), + /* K11 */ be_nested_str_weak(_X25i_X20), + /* K12 */ be_const_int(0), + /* K13 */ be_nested_str_weak(_X3D_X20), + /* K14 */ be_nested_str_weak(val), + /* K15 */ be_nested_str_weak(int), + /* K16 */ be_nested_str_weak(_X25i), + /* K17 */ be_nested_str_weak(typ), + /* K18 */ be_nested_str_weak(TLV), + /* K19 */ be_nested_str_weak(U1), + /* K20 */ be_nested_str_weak(U8), + /* K21 */ be_nested_str_weak(U), + /* K22 */ be_nested_str_weak(bool), + /* K23 */ be_nested_str_weak(true), + /* K24 */ be_nested_str_weak(false), + /* K25 */ be_nested_str_weak(null), + /* K26 */ be_nested_str_weak(real), + /* K27 */ be_nested_str_weak(_X25g), + /* K28 */ be_nested_str_weak(_X22_X25s_X22), + /* K29 */ be_nested_str_weak(int64), + /* K30 */ be_nested_str_weak(tostring), + /* K31 */ be_nested_str_weak(instance), + /* K32 */ be_nested_str_weak(_X25s), + /* K33 */ be_nested_str_weak(tohex), + /* K34 */ be_nested_str_weak(_X20), + }), + be_str_weak(tostring), + &be_const_str_solidified, + ( &(const binstruction[165]) { /* code */ + 0xA4060000, // 0000 IMPORT R1 K0 + 0x58080001, // 0001 LDCONST R2 K1 + 0xA8020099, // 0002 EXBLK 0 #009D + 0x880C0102, // 0003 GETMBR R3 R0 K2 + 0x5411FFFE, // 0004 LDINT R4 -1 + 0x1C0C0604, // 0005 EQ R3 R3 R4 + 0x780E000A, // 0006 JMPF R3 #0012 + 0x00080503, // 0007 ADD R2 R2 K3 + 0x880C0104, // 0008 GETMBR R3 R0 K4 + 0x4C100000, // 0009 LDNIL R4 + 0x200C0604, // 000A NE R3 R3 R4 + 0x780E0004, // 000B JMPF R3 #0011 + 0x8C0C0305, // 000C GETMET R3 R1 K5 + 0x58140006, // 000D LDCONST R5 K6 + 0x88180104, // 000E GETMBR R6 R0 K4 + 0x7C0C0600, // 000F CALL R3 3 + 0x00080403, // 0010 ADD R2 R2 R3 + 0x70020023, // 0011 JMP #0036 + 0x880C0107, // 0012 GETMBR R3 R0 K7 + 0x4C100000, // 0013 LDNIL R4 + 0x200C0604, // 0014 NE R3 R3 R4 + 0x780E0004, // 0015 JMPF R3 #001B + 0x8C0C0305, // 0016 GETMET R3 R1 K5 + 0x58140008, // 0017 LDCONST R5 K8 + 0x88180107, // 0018 GETMBR R6 R0 K7 + 0x7C0C0600, // 0019 CALL R3 3 + 0x00080403, // 001A ADD R2 R2 R3 + 0x880C0102, // 001B GETMBR R3 R0 K2 + 0x4C100000, // 001C LDNIL R4 + 0x200C0604, // 001D NE R3 R3 R4 + 0x780E0004, // 001E JMPF R3 #0024 + 0x8C0C0305, // 001F GETMET R3 R1 K5 + 0x58140009, // 0020 LDCONST R5 K9 + 0x88180102, // 0021 GETMBR R6 R0 K2 + 0x7C0C0600, // 0022 CALL R3 3 + 0x00080403, // 0023 ADD R2 R2 R3 + 0x880C0104, // 0024 GETMBR R3 R0 K4 + 0x4C100000, // 0025 LDNIL R4 + 0x200C0604, // 0026 NE R3 R3 R4 + 0x780E0004, // 0027 JMPF R3 #002D + 0x8C0C0305, // 0028 GETMET R3 R1 K5 + 0x58140006, // 0029 LDCONST R5 K6 + 0x88180104, // 002A GETMBR R6 R0 K4 + 0x7C0C0600, // 002B CALL R3 3 + 0x00080403, // 002C ADD R2 R2 R3 + 0x880C010A, // 002D GETMBR R3 R0 K10 + 0x4C100000, // 002E LDNIL R4 + 0x200C0604, // 002F NE R3 R3 R4 + 0x780E0004, // 0030 JMPF R3 #0036 + 0x8C0C0305, // 0031 GETMET R3 R1 K5 + 0x5814000B, // 0032 LDCONST R5 K11 + 0x8818010A, // 0033 GETMBR R6 R0 K10 + 0x7C0C0600, // 0034 CALL R3 3 + 0x00080403, // 0035 ADD R2 R2 R3 + 0x600C000C, // 0036 GETGBL R3 G12 + 0x5C100400, // 0037 MOVE R4 R2 + 0x7C0C0200, // 0038 CALL R3 1 + 0x240C070C, // 0039 GT R3 R3 K12 + 0x780E0000, // 003A JMPF R3 #003C + 0x0008050D, // 003B ADD R2 R2 K13 + 0x600C0004, // 003C GETGBL R3 G4 + 0x8810010E, // 003D GETMBR R4 R0 K14 + 0x7C0C0200, // 003E CALL R3 1 + 0x1C0C070F, // 003F EQ R3 R3 K15 + 0x780E0010, // 0040 JMPF R3 #0052 + 0x8C0C0305, // 0041 GETMET R3 R1 K5 + 0x58140010, // 0042 LDCONST R5 K16 + 0x8818010E, // 0043 GETMBR R6 R0 K14 + 0x7C0C0600, // 0044 CALL R3 3 + 0x00080403, // 0045 ADD R2 R2 R3 + 0x880C0111, // 0046 GETMBR R3 R0 K17 + 0x88100112, // 0047 GETMBR R4 R0 K18 + 0x88100913, // 0048 GETMBR R4 R4 K19 + 0x280C0604, // 0049 GE R3 R3 R4 + 0x780E0005, // 004A JMPF R3 #0051 + 0x880C0111, // 004B GETMBR R3 R0 K17 + 0x88100112, // 004C GETMBR R4 R0 K18 + 0x88100914, // 004D GETMBR R4 R4 K20 + 0x180C0604, // 004E LE R3 R3 R4 + 0x780E0000, // 004F JMPF R3 #0051 + 0x00080515, // 0050 ADD R2 R2 K21 + 0x70020048, // 0051 JMP #009B + 0x600C0004, // 0052 GETGBL R3 G4 + 0x8810010E, // 0053 GETMBR R4 R0 K14 + 0x7C0C0200, // 0054 CALL R3 1 + 0x1C0C0716, // 0055 EQ R3 R3 K22 + 0x780E0006, // 0056 JMPF R3 #005E + 0x880C010E, // 0057 GETMBR R3 R0 K14 + 0x780E0001, // 0058 JMPF R3 #005B + 0x580C0017, // 0059 LDCONST R3 K23 + 0x70020000, // 005A JMP #005C + 0x580C0018, // 005B LDCONST R3 K24 + 0x00080403, // 005C ADD R2 R2 R3 + 0x7002003C, // 005D JMP #009B + 0x880C010E, // 005E GETMBR R3 R0 K14 + 0x4C100000, // 005F LDNIL R4 + 0x1C0C0604, // 0060 EQ R3 R3 R4 + 0x780E0001, // 0061 JMPF R3 #0064 + 0x00080519, // 0062 ADD R2 R2 K25 + 0x70020036, // 0063 JMP #009B + 0x600C0004, // 0064 GETGBL R3 G4 + 0x8810010E, // 0065 GETMBR R4 R0 K14 + 0x7C0C0200, // 0066 CALL R3 1 + 0x1C0C071A, // 0067 EQ R3 R3 K26 + 0x780E0005, // 0068 JMPF R3 #006F + 0x8C0C0305, // 0069 GETMET R3 R1 K5 + 0x5814001B, // 006A LDCONST R5 K27 + 0x8818010E, // 006B GETMBR R6 R0 K14 + 0x7C0C0600, // 006C CALL R3 3 + 0x00080403, // 006D ADD R2 R2 R3 + 0x7002002B, // 006E JMP #009B + 0x600C0004, // 006F GETGBL R3 G4 + 0x8810010E, // 0070 GETMBR R4 R0 K14 + 0x7C0C0200, // 0071 CALL R3 1 + 0x1C0C0700, // 0072 EQ R3 R3 K0 + 0x780E0005, // 0073 JMPF R3 #007A + 0x8C0C0305, // 0074 GETMET R3 R1 K5 + 0x5814001C, // 0075 LDCONST R5 K28 + 0x8818010E, // 0076 GETMBR R6 R0 K14 + 0x7C0C0600, // 0077 CALL R3 3 + 0x00080403, // 0078 ADD R2 R2 R3 + 0x70020020, // 0079 JMP #009B + 0x600C000F, // 007A GETGBL R3 G15 + 0x8810010E, // 007B GETMBR R4 R0 K14 + 0xB8163A00, // 007C GETNGBL R5 K29 + 0x7C0C0400, // 007D CALL R3 2 + 0x780E000F, // 007E JMPF R3 #008F + 0x880C010E, // 007F GETMBR R3 R0 K14 + 0x8C0C071E, // 0080 GETMET R3 R3 K30 + 0x7C0C0200, // 0081 CALL R3 1 + 0x00080403, // 0082 ADD R2 R2 R3 + 0x880C0111, // 0083 GETMBR R3 R0 K17 + 0x88100112, // 0084 GETMBR R4 R0 K18 + 0x88100913, // 0085 GETMBR R4 R4 K19 + 0x280C0604, // 0086 GE R3 R3 R4 + 0x780E0005, // 0087 JMPF R3 #008E + 0x880C0111, // 0088 GETMBR R3 R0 K17 + 0x88100112, // 0089 GETMBR R4 R0 K18 + 0x88100914, // 008A GETMBR R4 R4 K20 + 0x180C0604, // 008B LE R3 R3 R4 + 0x780E0000, // 008C JMPF R3 #008E + 0x00080515, // 008D ADD R2 R2 K21 + 0x7002000B, // 008E JMP #009B + 0x600C0004, // 008F GETGBL R3 G4 + 0x8810010E, // 0090 GETMBR R4 R0 K14 + 0x7C0C0200, // 0091 CALL R3 1 + 0x1C0C071F, // 0092 EQ R3 R3 K31 + 0x780E0006, // 0093 JMPF R3 #009B + 0x8C0C0305, // 0094 GETMET R3 R1 K5 + 0x58140020, // 0095 LDCONST R5 K32 + 0x8818010E, // 0096 GETMBR R6 R0 K14 + 0x8C180D21, // 0097 GETMET R6 R6 K33 + 0x7C180200, // 0098 CALL R6 1 + 0x7C0C0600, // 0099 CALL R3 3 + 0x00080403, // 009A ADD R2 R2 R3 + 0xA8040001, // 009B EXBLK 1 1 + 0x70020006, // 009C JMP #00A4 + 0xAC0C0002, // 009D CATCH R3 0 2 + 0x70020003, // 009E JMP #00A3 + 0x00140722, // 009F ADD R5 R3 K34 + 0x00140A04, // 00A0 ADD R5 R5 R4 + 0x80040A00, // 00A1 RET 1 R5 + 0x70020000, // 00A2 JMP #00A4 + 0xB0080000, // 00A3 RAISE 2 R0 R0 + 0x80040400, // 00A4 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: encode_len +********************************************************************/ +be_local_closure(Matter_TLV_item_encode_len, /* name */ + be_nested_proto( + 5, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[31]) { /* constants */ + /* K0 */ be_nested_str_weak(TLV), + /* K1 */ be_const_int(0), + /* K2 */ be_nested_str_weak(typ), + /* K3 */ be_nested_str_weak(BFALSE), + /* K4 */ be_nested_str_weak(BTRUE), + /* K5 */ be_nested_str_weak(val), + /* K6 */ be_nested_str_weak(I2), + /* K7 */ be_nested_str_weak(I4), + /* K8 */ be_nested_str_weak(I1), + /* K9 */ be_nested_str_weak(U2), + /* K10 */ be_nested_str_weak(U4), + /* K11 */ be_nested_str_weak(U1), + /* K12 */ be_nested_str_weak(B1), + /* K13 */ be_nested_str_weak(B8), + /* K14 */ be_nested_str_weak(B2), + /* K15 */ be_nested_str_weak(B4), + /* K16 */ be_nested_str_weak(UTF1), + /* K17 */ be_nested_str_weak(UTF8), + /* K18 */ be_nested_str_weak(UTF2), + /* K19 */ be_nested_str_weak(UTF4), + /* K20 */ be_nested_str_weak(_encode_tag_len), + /* K21 */ be_const_int(1), + /* K22 */ be_const_int(2), + /* K23 */ be_nested_str_weak(I8), + /* K24 */ be_nested_str_weak(U8), + /* K25 */ be_nested_str_weak(FLOAT), + /* K26 */ be_nested_str_weak(DOUBLE), + /* K27 */ be_nested_str_weak(value_error), + /* K28 */ be_nested_str_weak(Unsupported_X20type_X20TLV_X2EDOUBLE), + /* K29 */ be_nested_str_weak(NULL), + /* K30 */ be_nested_str_weak(unsupported_X20type_X20), + }), + be_str_weak(encode_len), + &be_const_str_solidified, + ( &(const binstruction[250]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x58080001, // 0001 LDCONST R2 K1 + 0x880C0102, // 0002 GETMBR R3 R0 K2 + 0x88100303, // 0003 GETMBR R4 R1 K3 + 0x1C0C0604, // 0004 EQ R3 R3 R4 + 0x740E0003, // 0005 JMPT R3 #000A + 0x880C0102, // 0006 GETMBR R3 R0 K2 + 0x88100304, // 0007 GETMBR R4 R1 K4 + 0x1C0C0604, // 0008 EQ R3 R3 R4 + 0x780E0008, // 0009 JMPF R3 #0013 + 0x600C0017, // 000A GETGBL R3 G23 + 0x88100105, // 000B GETMBR R4 R0 K5 + 0x7C0C0200, // 000C CALL R3 1 + 0x780E0001, // 000D JMPF R3 #0010 + 0x880C0304, // 000E GETMBR R3 R1 K4 + 0x70020000, // 000F JMP #0011 + 0x880C0303, // 0010 GETMBR R3 R1 K3 + 0x90020403, // 0011 SETMBR R0 K2 R3 + 0x70020070, // 0012 JMP #0084 + 0x880C0102, // 0013 GETMBR R3 R0 K2 + 0x88100306, // 0014 GETMBR R4 R1 K6 + 0x280C0604, // 0015 GE R3 R3 R4 + 0x780E0018, // 0016 JMPF R3 #0030 + 0x880C0102, // 0017 GETMBR R3 R0 K2 + 0x88100307, // 0018 GETMBR R4 R1 K7 + 0x180C0604, // 0019 LE R3 R3 R4 + 0x780E0014, // 001A JMPF R3 #0030 + 0x600C0009, // 001B GETGBL R3 G9 + 0x88100105, // 001C GETMBR R4 R0 K5 + 0x7C0C0200, // 001D CALL R3 1 + 0x5412007E, // 001E LDINT R4 127 + 0x18100604, // 001F LE R4 R3 R4 + 0x78120005, // 0020 JMPF R4 #0027 + 0x5411FF7F, // 0021 LDINT R4 -128 + 0x28100604, // 0022 GE R4 R3 R4 + 0x78120002, // 0023 JMPF R4 #0027 + 0x88100308, // 0024 GETMBR R4 R1 K8 + 0x90020404, // 0025 SETMBR R0 K2 R4 + 0x70020007, // 0026 JMP #002F + 0x54127FFE, // 0027 LDINT R4 32767 + 0x18100604, // 0028 LE R4 R3 R4 + 0x78120004, // 0029 JMPF R4 #002F + 0x54117FFF, // 002A LDINT R4 -32768 + 0x28100604, // 002B GE R4 R3 R4 + 0x78120001, // 002C JMPF R4 #002F + 0x88100306, // 002D GETMBR R4 R1 K6 + 0x90020404, // 002E SETMBR R0 K2 R4 + 0x70020053, // 002F JMP #0084 + 0x880C0102, // 0030 GETMBR R3 R0 K2 + 0x88100309, // 0031 GETMBR R4 R1 K9 + 0x280C0604, // 0032 GE R3 R3 R4 + 0x780E0016, // 0033 JMPF R3 #004B + 0x880C0102, // 0034 GETMBR R3 R0 K2 + 0x8810030A, // 0035 GETMBR R4 R1 K10 + 0x180C0604, // 0036 LE R3 R3 R4 + 0x780E0012, // 0037 JMPF R3 #004B + 0x600C0009, // 0038 GETGBL R3 G9 + 0x88100105, // 0039 GETMBR R4 R0 K5 + 0x7C0C0200, // 003A CALL R3 1 + 0x541200FE, // 003B LDINT R4 255 + 0x18100604, // 003C LE R4 R3 R4 + 0x78120004, // 003D JMPF R4 #0043 + 0x28100701, // 003E GE R4 R3 K1 + 0x78120002, // 003F JMPF R4 #0043 + 0x8810030B, // 0040 GETMBR R4 R1 K11 + 0x90020404, // 0041 SETMBR R0 K2 R4 + 0x70020006, // 0042 JMP #004A + 0x5412FFFE, // 0043 LDINT R4 65535 + 0x18100604, // 0044 LE R4 R3 R4 + 0x78120003, // 0045 JMPF R4 #004A + 0x28100701, // 0046 GE R4 R3 K1 + 0x78120001, // 0047 JMPF R4 #004A + 0x88100309, // 0048 GETMBR R4 R1 K9 + 0x90020404, // 0049 SETMBR R0 K2 R4 + 0x70020038, // 004A JMP #0084 + 0x880C0102, // 004B GETMBR R3 R0 K2 + 0x8810030C, // 004C GETMBR R4 R1 K12 + 0x280C0604, // 004D GE R3 R3 R4 + 0x780E0018, // 004E JMPF R3 #0068 + 0x880C0102, // 004F GETMBR R3 R0 K2 + 0x8810030D, // 0050 GETMBR R4 R1 K13 + 0x180C0604, // 0051 LE R3 R3 R4 + 0x780E0014, // 0052 JMPF R3 #0068 + 0x600C000C, // 0053 GETGBL R3 G12 + 0x88100105, // 0054 GETMBR R4 R0 K5 + 0x7C0C0200, // 0055 CALL R3 1 + 0x541200FE, // 0056 LDINT R4 255 + 0x180C0604, // 0057 LE R3 R3 R4 + 0x780E0002, // 0058 JMPF R3 #005C + 0x880C030C, // 0059 GETMBR R3 R1 K12 + 0x90020403, // 005A SETMBR R0 K2 R3 + 0x7002000A, // 005B JMP #0067 + 0x600C000C, // 005C GETGBL R3 G12 + 0x88100105, // 005D GETMBR R4 R0 K5 + 0x7C0C0200, // 005E CALL R3 1 + 0x5412FFFE, // 005F LDINT R4 65535 + 0x180C0604, // 0060 LE R3 R3 R4 + 0x780E0002, // 0061 JMPF R3 #0065 + 0x880C030E, // 0062 GETMBR R3 R1 K14 + 0x90020403, // 0063 SETMBR R0 K2 R3 + 0x70020001, // 0064 JMP #0067 + 0x880C030F, // 0065 GETMBR R3 R1 K15 + 0x90020403, // 0066 SETMBR R0 K2 R3 + 0x7002001B, // 0067 JMP #0084 + 0x880C0102, // 0068 GETMBR R3 R0 K2 + 0x88100310, // 0069 GETMBR R4 R1 K16 + 0x280C0604, // 006A GE R3 R3 R4 + 0x780E0017, // 006B JMPF R3 #0084 + 0x880C0102, // 006C GETMBR R3 R0 K2 + 0x88100311, // 006D GETMBR R4 R1 K17 + 0x180C0604, // 006E LE R3 R3 R4 + 0x780E0013, // 006F JMPF R3 #0084 + 0x600C000C, // 0070 GETGBL R3 G12 + 0x88100105, // 0071 GETMBR R4 R0 K5 + 0x7C0C0200, // 0072 CALL R3 1 + 0x541200FE, // 0073 LDINT R4 255 + 0x180C0604, // 0074 LE R3 R3 R4 + 0x780E0002, // 0075 JMPF R3 #0079 + 0x880C0310, // 0076 GETMBR R3 R1 K16 + 0x90020403, // 0077 SETMBR R0 K2 R3 + 0x7002000A, // 0078 JMP #0084 + 0x600C000C, // 0079 GETGBL R3 G12 + 0x88100105, // 007A GETMBR R4 R0 K5 + 0x7C0C0200, // 007B CALL R3 1 + 0x5412FFFE, // 007C LDINT R4 65535 + 0x180C0604, // 007D LE R3 R3 R4 + 0x780E0002, // 007E JMPF R3 #0082 + 0x880C0312, // 007F GETMBR R3 R1 K18 + 0x90020403, // 0080 SETMBR R0 K2 R3 + 0x70020001, // 0081 JMP #0084 + 0x880C0313, // 0082 GETMBR R3 R1 K19 + 0x90020403, // 0083 SETMBR R0 K2 R3 + 0x8C0C0114, // 0084 GETMET R3 R0 K20 + 0x7C0C0200, // 0085 CALL R3 1 + 0x00080403, // 0086 ADD R2 R2 R3 + 0x880C0102, // 0087 GETMBR R3 R0 K2 + 0x88100308, // 0088 GETMBR R4 R1 K8 + 0x1C0C0604, // 0089 EQ R3 R3 R4 + 0x740E0003, // 008A JMPT R3 #008F + 0x880C0102, // 008B GETMBR R3 R0 K2 + 0x8810030B, // 008C GETMBR R4 R1 K11 + 0x1C0C0604, // 008D EQ R3 R3 R4 + 0x780E0001, // 008E JMPF R3 #0091 + 0x00080515, // 008F ADD R2 R2 K21 + 0x70020067, // 0090 JMP #00F9 + 0x880C0102, // 0091 GETMBR R3 R0 K2 + 0x88100306, // 0092 GETMBR R4 R1 K6 + 0x1C0C0604, // 0093 EQ R3 R3 R4 + 0x740E0003, // 0094 JMPT R3 #0099 + 0x880C0102, // 0095 GETMBR R3 R0 K2 + 0x88100309, // 0096 GETMBR R4 R1 K9 + 0x1C0C0604, // 0097 EQ R3 R3 R4 + 0x780E0001, // 0098 JMPF R3 #009B + 0x00080516, // 0099 ADD R2 R2 K22 + 0x7002005D, // 009A JMP #00F9 + 0x880C0102, // 009B GETMBR R3 R0 K2 + 0x88100307, // 009C GETMBR R4 R1 K7 + 0x1C0C0604, // 009D EQ R3 R3 R4 + 0x740E0003, // 009E JMPT R3 #00A3 + 0x880C0102, // 009F GETMBR R3 R0 K2 + 0x8810030A, // 00A0 GETMBR R4 R1 K10 + 0x1C0C0604, // 00A1 EQ R3 R3 R4 + 0x780E0002, // 00A2 JMPF R3 #00A6 + 0x540E0003, // 00A3 LDINT R3 4 + 0x00080403, // 00A4 ADD R2 R2 R3 + 0x70020052, // 00A5 JMP #00F9 + 0x880C0102, // 00A6 GETMBR R3 R0 K2 + 0x88100317, // 00A7 GETMBR R4 R1 K23 + 0x1C0C0604, // 00A8 EQ R3 R3 R4 + 0x740E0003, // 00A9 JMPT R3 #00AE + 0x880C0102, // 00AA GETMBR R3 R0 K2 + 0x88100318, // 00AB GETMBR R4 R1 K24 + 0x1C0C0604, // 00AC EQ R3 R3 R4 + 0x780E0002, // 00AD JMPF R3 #00B1 + 0x540E0007, // 00AE LDINT R3 8 + 0x00080403, // 00AF ADD R2 R2 R3 + 0x70020047, // 00B0 JMP #00F9 + 0x880C0102, // 00B1 GETMBR R3 R0 K2 + 0x88100303, // 00B2 GETMBR R4 R1 K3 + 0x1C0C0604, // 00B3 EQ R3 R3 R4 + 0x740E0003, // 00B4 JMPT R3 #00B9 + 0x880C0102, // 00B5 GETMBR R3 R0 K2 + 0x88100304, // 00B6 GETMBR R4 R1 K4 + 0x1C0C0604, // 00B7 EQ R3 R3 R4 + 0x780E0000, // 00B8 JMPF R3 #00BA + 0x7002003E, // 00B9 JMP #00F9 + 0x880C0102, // 00BA GETMBR R3 R0 K2 + 0x88100319, // 00BB GETMBR R4 R1 K25 + 0x1C0C0604, // 00BC EQ R3 R3 R4 + 0x780E0002, // 00BD JMPF R3 #00C1 + 0x540E0003, // 00BE LDINT R3 4 + 0x00080403, // 00BF ADD R2 R2 R3 + 0x70020037, // 00C0 JMP #00F9 + 0x880C0102, // 00C1 GETMBR R3 R0 K2 + 0x8810031A, // 00C2 GETMBR R4 R1 K26 + 0x1C0C0604, // 00C3 EQ R3 R3 R4 + 0x780E0001, // 00C4 JMPF R3 #00C7 + 0xB006371C, // 00C5 RAISE 1 K27 K28 + 0x70020031, // 00C6 JMP #00F9 + 0x880C0102, // 00C7 GETMBR R3 R0 K2 + 0x88100310, // 00C8 GETMBR R4 R1 K16 + 0x1C0C0604, // 00C9 EQ R3 R3 R4 + 0x780E0005, // 00CA JMPF R3 #00D1 + 0x600C000C, // 00CB GETGBL R3 G12 + 0x88100105, // 00CC GETMBR R4 R0 K5 + 0x7C0C0200, // 00CD CALL R3 1 + 0x000E2A03, // 00CE ADD R3 K21 R3 + 0x00080403, // 00CF ADD R2 R2 R3 + 0x70020027, // 00D0 JMP #00F9 + 0x880C0102, // 00D1 GETMBR R3 R0 K2 + 0x88100312, // 00D2 GETMBR R4 R1 K18 + 0x1C0C0604, // 00D3 EQ R3 R3 R4 + 0x780E0005, // 00D4 JMPF R3 #00DB + 0x600C000C, // 00D5 GETGBL R3 G12 + 0x88100105, // 00D6 GETMBR R4 R0 K5 + 0x7C0C0200, // 00D7 CALL R3 1 + 0x000E2C03, // 00D8 ADD R3 K22 R3 + 0x00080403, // 00D9 ADD R2 R2 R3 + 0x7002001D, // 00DA JMP #00F9 + 0x880C0102, // 00DB GETMBR R3 R0 K2 + 0x8810030C, // 00DC GETMBR R4 R1 K12 + 0x1C0C0604, // 00DD EQ R3 R3 R4 + 0x780E0005, // 00DE JMPF R3 #00E5 + 0x600C000C, // 00DF GETGBL R3 G12 + 0x88100105, // 00E0 GETMBR R4 R0 K5 + 0x7C0C0200, // 00E1 CALL R3 1 + 0x000E2A03, // 00E2 ADD R3 K21 R3 + 0x00080403, // 00E3 ADD R2 R2 R3 + 0x70020013, // 00E4 JMP #00F9 + 0x880C0102, // 00E5 GETMBR R3 R0 K2 + 0x8810030E, // 00E6 GETMBR R4 R1 K14 + 0x1C0C0604, // 00E7 EQ R3 R3 R4 + 0x780E0005, // 00E8 JMPF R3 #00EF + 0x600C000C, // 00E9 GETGBL R3 G12 + 0x88100105, // 00EA GETMBR R4 R0 K5 + 0x7C0C0200, // 00EB CALL R3 1 + 0x000E2C03, // 00EC ADD R3 K22 R3 + 0x00080403, // 00ED ADD R2 R2 R3 + 0x70020009, // 00EE JMP #00F9 + 0x880C0102, // 00EF GETMBR R3 R0 K2 + 0x8810031D, // 00F0 GETMBR R4 R1 K29 + 0x1C0C0604, // 00F1 EQ R3 R3 R4 + 0x780E0000, // 00F2 JMPF R3 #00F4 + 0x70020004, // 00F3 JMP #00F9 + 0x600C0008, // 00F4 GETGBL R3 G8 + 0x88100102, // 00F5 GETMBR R4 R0 K2 + 0x7C0C0200, // 00F6 CALL R3 1 + 0x000E3C03, // 00F7 ADD R3 K30 R3 + 0xB0063603, // 00F8 RAISE 1 K27 R3 + 0x80040400, // 00F9 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_contextspecific +********************************************************************/ +be_local_closure(Matter_TLV_item_set_contextspecific, /* name */ + be_nested_proto( + 4, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(set_fulltag), + /* K1 */ be_nested_str_weak(tag_sub), + }), + be_str_weak(set_contextspecific), + &be_const_str_solidified, + ( &(const binstruction[ 7]) { /* code */ + 0x8C080100, // 0000 GETMET R2 R0 K0 + 0x7C080200, // 0001 CALL R2 1 + 0x60080009, // 0002 GETGBL R2 G9 + 0x5C0C0200, // 0003 MOVE R3 R1 + 0x7C080200, // 0004 CALL R2 1 + 0x90020202, // 0005 SETMBR R0 K1 R2 + 0x80000000, // 0006 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: set_fulltag +********************************************************************/ +be_local_closure(Matter_TLV_item_set_fulltag, /* name */ + be_nested_proto( + 6, /* nstack */ + 4, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(tag_vendor), + /* K1 */ be_nested_str_weak(tag_profile), + /* K2 */ be_nested_str_weak(tag_number), + /* K3 */ be_nested_str_weak(tag_sub), + }), + be_str_weak(set_fulltag), + &be_const_str_solidified, + ( &(const binstruction[15]) { /* code */ + 0x60100009, // 0000 GETGBL R4 G9 + 0x5C140200, // 0001 MOVE R5 R1 + 0x7C100200, // 0002 CALL R4 1 + 0x90020004, // 0003 SETMBR R0 K0 R4 + 0x60100009, // 0004 GETGBL R4 G9 + 0x5C140400, // 0005 MOVE R5 R2 + 0x7C100200, // 0006 CALL R4 1 + 0x90020204, // 0007 SETMBR R0 K1 R4 + 0x60100009, // 0008 GETGBL R4 G9 + 0x5C140600, // 0009 MOVE R5 R3 + 0x7C100200, // 000A CALL R4 1 + 0x90020404, // 000B SETMBR R0 K2 R4 + 0x4C100000, // 000C LDNIL R4 + 0x90020604, // 000D SETMBR R0 K3 R4 + 0x80000000, // 000E RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: _encode_tag_len +********************************************************************/ +be_local_closure(Matter_TLV_item__encode_tag_len, /* name */ + be_nested_proto( + 6, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 8]) { /* constants */ + /* K0 */ be_nested_str_weak(tag_number), + /* K1 */ be_const_int(0), + /* K2 */ be_nested_str_weak(tag_vendor), + /* K3 */ be_nested_str_weak(tag_profile), + /* K4 */ be_const_int(3), + /* K5 */ be_nested_str_weak(tag_sub), + /* K6 */ be_const_int(2), + /* K7 */ be_const_int(1), + }), + be_str_weak(_encode_tag_len), + &be_const_str_solidified, + ( &(const binstruction[54]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x4C080000, // 0001 LDNIL R2 + 0x20040202, // 0002 NE R1 R1 R2 + 0x78060001, // 0003 JMPF R1 #0006 + 0x88040100, // 0004 GETMBR R1 R0 K0 + 0x70020000, // 0005 JMP #0007 + 0x58040001, // 0006 LDCONST R1 K1 + 0x540AFFFF, // 0007 LDINT R2 65536 + 0x28080202, // 0008 GE R2 R1 R2 + 0x740A0002, // 0009 JMPT R2 #000D + 0x14080301, // 000A LT R2 R1 K1 + 0x740A0000, // 000B JMPT R2 #000D + 0x50080001, // 000C LDBOOL R2 0 1 + 0x50080200, // 000D LDBOOL R2 1 0 + 0x580C0001, // 000E LDCONST R3 K1 + 0x88100102, // 000F GETMBR R4 R0 K2 + 0x4C140000, // 0010 LDNIL R5 + 0x20100805, // 0011 NE R4 R4 R5 + 0x78120006, // 0012 JMPF R4 #001A + 0x780A0002, // 0013 JMPF R2 #0017 + 0x54120008, // 0014 LDINT R4 9 + 0x80040800, // 0015 RET 1 R4 + 0x70020001, // 0016 JMP #0019 + 0x54120006, // 0017 LDINT R4 7 + 0x80040800, // 0018 RET 1 R4 + 0x7002001A, // 0019 JMP #0035 + 0x88100103, // 001A GETMBR R4 R0 K3 + 0x5415FFFE, // 001B LDINT R5 -1 + 0x1C100805, // 001C EQ R4 R4 R5 + 0x78120005, // 001D JMPF R4 #0024 + 0x780A0002, // 001E JMPF R2 #0022 + 0x54120004, // 001F LDINT R4 5 + 0x80040800, // 0020 RET 1 R4 + 0x70020000, // 0021 JMP #0023 + 0x80060800, // 0022 RET 1 K4 + 0x70020010, // 0023 JMP #0035 + 0x88100103, // 0024 GETMBR R4 R0 K3 + 0x4C140000, // 0025 LDNIL R5 + 0x20100805, // 0026 NE R4 R4 R5 + 0x78120005, // 0027 JMPF R4 #002E + 0x780A0002, // 0028 JMPF R2 #002C + 0x54120004, // 0029 LDINT R4 5 + 0x80040800, // 002A RET 1 R4 + 0x70020000, // 002B JMP #002D + 0x80060800, // 002C RET 1 K4 + 0x70020006, // 002D JMP #0035 + 0x88100105, // 002E GETMBR R4 R0 K5 + 0x4C140000, // 002F LDNIL R5 + 0x20100805, // 0030 NE R4 R4 R5 + 0x78120001, // 0031 JMPF R4 #0034 + 0x80060C00, // 0032 RET 1 K6 + 0x70020000, // 0033 JMP #0035 + 0x80060E00, // 0034 RET 1 K7 + 0x80000000, // 0035 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: init +********************************************************************/ +be_local_closure(Matter_TLV_item_init, /* name */ + be_nested_proto( + 2, /* nstack */ + 2, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(parent), + }), + be_str_weak(init), + &be_const_str_solidified, + ( &(const binstruction[ 2]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x80000000, // 0001 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: encode ********************************************************************/ @@ -464,272 +1542,61 @@ be_local_closure(Matter_TLV_item_encode, /* name */ /******************************************************************** -** Solidified function: create_TLV +** Solidified function: sort ********************************************************************/ -be_local_closure(Matter_TLV_item_create_TLV, /* name */ +be_local_closure(Matter_TLV_item_sort, /* name */ be_nested_proto( - 4, /* nstack */ - 2, /* argc */ + 9, /* nstack */ + 1, /* argc */ 4, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ + ( &(const bvalue[ 5]) { /* constants */ /* K0 */ be_const_class(be_class_Matter_TLV_item), - /* K1 */ be_nested_str_weak(typ), - /* K2 */ be_nested_str_weak(val), + /* K1 */ be_const_int(1), + /* K2 */ be_const_int(0), + /* K3 */ be_nested_str_weak(_cmp_gt), + /* K4 */ be_nested_str_weak(stop_iteration), }), - be_str_weak(create_TLV), + be_str_weak(sort), &be_const_str_solidified, - ( &(const binstruction[10]) { /* code */ - 0x58080000, // 0000 LDCONST R2 K0 - 0x4C0C0000, // 0001 LDNIL R3 - 0x200C0203, // 0002 NE R3 R1 R3 - 0x780E0004, // 0003 JMPF R3 #0009 - 0x5C0C0400, // 0004 MOVE R3 R2 - 0x7C0C0000, // 0005 CALL R3 0 - 0x900E0200, // 0006 SETMBR R3 K1 R0 - 0x900E0401, // 0007 SETMBR R3 K2 R1 - 0x80040600, // 0008 RET 1 R3 - 0x80000000, // 0009 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: _encode_tag -********************************************************************/ -be_local_closure(Matter_TLV_item__encode_tag, /* name */ - be_nested_proto( - 9, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 9]) { /* constants */ - /* K0 */ be_nested_str_weak(tag_number), - /* K1 */ be_const_int(0), - /* K2 */ be_nested_str_weak(tag_vendor), - /* K3 */ be_nested_str_weak(add), - /* K4 */ be_nested_str_weak(typ), - /* K5 */ be_const_int(1), - /* K6 */ be_const_int(2), - /* K7 */ be_nested_str_weak(tag_profile), - /* K8 */ be_nested_str_weak(tag_sub), - }), - be_str_weak(_encode_tag), - &be_const_str_solidified, - ( &(const binstruction[133]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x4C0C0000, // 0001 LDNIL R3 - 0x20080403, // 0002 NE R2 R2 R3 - 0x780A0001, // 0003 JMPF R2 #0006 - 0x88080100, // 0004 GETMBR R2 R0 K0 - 0x70020000, // 0005 JMP #0007 - 0x58080001, // 0006 LDCONST R2 K1 - 0x540EFFFF, // 0007 LDINT R3 65536 - 0x280C0403, // 0008 GE R3 R2 R3 - 0x740E0002, // 0009 JMPT R3 #000D - 0x140C0501, // 000A LT R3 R2 K1 - 0x740E0000, // 000B JMPT R3 #000D - 0x500C0001, // 000C LDBOOL R3 0 1 - 0x500C0200, // 000D LDBOOL R3 1 0 - 0x58100001, // 000E LDCONST R4 K1 - 0x88140102, // 000F GETMBR R5 R0 K2 - 0x4C180000, // 0010 LDNIL R6 - 0x20140A06, // 0011 NE R5 R5 R6 - 0x78160026, // 0012 JMPF R5 #003A - 0x780E0012, // 0013 JMPF R3 #0027 - 0x8C140303, // 0014 GETMET R5 R1 K3 - 0x541E00DF, // 0015 LDINT R7 224 - 0x88200104, // 0016 GETMBR R8 R0 K4 - 0x001C0E08, // 0017 ADD R7 R7 R8 - 0x58200005, // 0018 LDCONST R8 K5 - 0x7C140600, // 0019 CALL R5 3 - 0x8C140303, // 001A GETMET R5 R1 K3 - 0x881C0102, // 001B GETMBR R7 R0 K2 - 0x58200006, // 001C LDCONST R8 K6 - 0x7C140600, // 001D CALL R5 3 - 0x8C140303, // 001E GETMET R5 R1 K3 - 0x881C0107, // 001F GETMBR R7 R0 K7 - 0x58200006, // 0020 LDCONST R8 K6 - 0x7C140600, // 0021 CALL R5 3 - 0x8C140303, // 0022 GETMET R5 R1 K3 - 0x881C0100, // 0023 GETMBR R7 R0 K0 - 0x54220003, // 0024 LDINT R8 4 - 0x7C140600, // 0025 CALL R5 3 - 0x70020011, // 0026 JMP #0039 - 0x8C140303, // 0027 GETMET R5 R1 K3 - 0x541E00BF, // 0028 LDINT R7 192 - 0x88200104, // 0029 GETMBR R8 R0 K4 - 0x001C0E08, // 002A ADD R7 R7 R8 - 0x58200005, // 002B LDCONST R8 K5 - 0x7C140600, // 002C CALL R5 3 - 0x8C140303, // 002D GETMET R5 R1 K3 - 0x881C0102, // 002E GETMBR R7 R0 K2 - 0x58200006, // 002F LDCONST R8 K6 - 0x7C140600, // 0030 CALL R5 3 - 0x8C140303, // 0031 GETMET R5 R1 K3 - 0x881C0107, // 0032 GETMBR R7 R0 K7 - 0x58200006, // 0033 LDCONST R8 K6 - 0x7C140600, // 0034 CALL R5 3 - 0x8C140303, // 0035 GETMET R5 R1 K3 - 0x881C0100, // 0036 GETMBR R7 R0 K0 - 0x58200006, // 0037 LDCONST R8 K6 - 0x7C140600, // 0038 CALL R5 3 - 0x70020049, // 0039 JMP #0084 - 0x88140107, // 003A GETMBR R5 R0 K7 - 0x5419FFFE, // 003B LDINT R6 -1 - 0x1C140A06, // 003C EQ R5 R5 R6 - 0x78160016, // 003D JMPF R5 #0055 - 0x780E000A, // 003E JMPF R3 #004A - 0x8C140303, // 003F GETMET R5 R1 K3 - 0x541E005F, // 0040 LDINT R7 96 - 0x88200104, // 0041 GETMBR R8 R0 K4 - 0x001C0E08, // 0042 ADD R7 R7 R8 - 0x58200005, // 0043 LDCONST R8 K5 - 0x7C140600, // 0044 CALL R5 3 - 0x8C140303, // 0045 GETMET R5 R1 K3 - 0x881C0100, // 0046 GETMBR R7 R0 K0 - 0x54220003, // 0047 LDINT R8 4 - 0x7C140600, // 0048 CALL R5 3 - 0x70020009, // 0049 JMP #0054 - 0x8C140303, // 004A GETMET R5 R1 K3 - 0x541E003F, // 004B LDINT R7 64 - 0x88200104, // 004C GETMBR R8 R0 K4 - 0x001C0E08, // 004D ADD R7 R7 R8 - 0x58200005, // 004E LDCONST R8 K5 - 0x7C140600, // 004F CALL R5 3 - 0x8C140303, // 0050 GETMET R5 R1 K3 - 0x881C0100, // 0051 GETMBR R7 R0 K0 - 0x58200006, // 0052 LDCONST R8 K6 - 0x7C140600, // 0053 CALL R5 3 - 0x7002002E, // 0054 JMP #0084 - 0x88140107, // 0055 GETMBR R5 R0 K7 - 0x4C180000, // 0056 LDNIL R6 - 0x20140A06, // 0057 NE R5 R5 R6 - 0x78160016, // 0058 JMPF R5 #0070 - 0x780E000A, // 0059 JMPF R3 #0065 - 0x8C140303, // 005A GETMET R5 R1 K3 - 0x541E009F, // 005B LDINT R7 160 - 0x88200104, // 005C GETMBR R8 R0 K4 - 0x001C0E08, // 005D ADD R7 R7 R8 - 0x58200005, // 005E LDCONST R8 K5 - 0x7C140600, // 005F CALL R5 3 - 0x8C140303, // 0060 GETMET R5 R1 K3 - 0x881C0100, // 0061 GETMBR R7 R0 K0 - 0x54220003, // 0062 LDINT R8 4 - 0x7C140600, // 0063 CALL R5 3 - 0x70020009, // 0064 JMP #006F - 0x8C140303, // 0065 GETMET R5 R1 K3 - 0x541E007F, // 0066 LDINT R7 128 - 0x88200104, // 0067 GETMBR R8 R0 K4 - 0x001C0E08, // 0068 ADD R7 R7 R8 - 0x58200005, // 0069 LDCONST R8 K5 - 0x7C140600, // 006A CALL R5 3 - 0x8C140303, // 006B GETMET R5 R1 K3 - 0x881C0100, // 006C GETMBR R7 R0 K0 - 0x58200006, // 006D LDCONST R8 K6 - 0x7C140600, // 006E CALL R5 3 - 0x70020013, // 006F JMP #0084 - 0x88140108, // 0070 GETMBR R5 R0 K8 - 0x4C180000, // 0071 LDNIL R6 - 0x20140A06, // 0072 NE R5 R5 R6 - 0x7816000A, // 0073 JMPF R5 #007F - 0x8C140303, // 0074 GETMET R5 R1 K3 - 0x541E001F, // 0075 LDINT R7 32 - 0x88200104, // 0076 GETMBR R8 R0 K4 - 0x001C0E08, // 0077 ADD R7 R7 R8 - 0x58200005, // 0078 LDCONST R8 K5 - 0x7C140600, // 0079 CALL R5 3 - 0x8C140303, // 007A GETMET R5 R1 K3 - 0x881C0108, // 007B GETMBR R7 R0 K8 - 0x58200005, // 007C LDCONST R8 K5 - 0x7C140600, // 007D CALL R5 3 - 0x70020004, // 007E JMP #0084 - 0x8C140303, // 007F GETMET R5 R1 K3 - 0x881C0104, // 0080 GETMBR R7 R0 K4 - 0x001E0207, // 0081 ADD R7 K1 R7 - 0x58200005, // 0082 LDCONST R8 K5 - 0x7C140600, // 0083 CALL R5 3 - 0x80000000, // 0084 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_parent -********************************************************************/ -be_local_closure(Matter_TLV_item_set_parent, /* name */ - be_nested_proto( - 2, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(parent), - }), - be_str_weak(set_parent), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_fulltag -********************************************************************/ -be_local_closure(Matter_TLV_item_set_fulltag, /* name */ - be_nested_proto( - 6, /* nstack */ - 4, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 4]) { /* constants */ - /* K0 */ be_nested_str_weak(tag_vendor), - /* K1 */ be_nested_str_weak(tag_profile), - /* K2 */ be_nested_str_weak(tag_number), - /* K3 */ be_nested_str_weak(tag_sub), - }), - be_str_weak(set_fulltag), - &be_const_str_solidified, - ( &(const binstruction[15]) { /* code */ - 0x60100009, // 0000 GETGBL R4 G9 - 0x5C140200, // 0001 MOVE R5 R1 - 0x7C100200, // 0002 CALL R4 1 - 0x90020004, // 0003 SETMBR R0 K0 R4 - 0x60100009, // 0004 GETGBL R4 G9 - 0x5C140400, // 0005 MOVE R5 R2 - 0x7C100200, // 0006 CALL R4 1 - 0x90020204, // 0007 SETMBR R0 K1 R4 - 0x60100009, // 0008 GETGBL R4 G9 - 0x5C140600, // 0009 MOVE R5 R3 - 0x7C100200, // 000A CALL R4 1 - 0x90020404, // 000B SETMBR R0 K2 R4 - 0x4C100000, // 000C LDNIL R4 - 0x90020604, // 000D SETMBR R0 K3 R4 - 0x80000000, // 000E RET 0 + ( &(const binstruction[33]) { /* code */ + 0x58040000, // 0000 LDCONST R1 K0 + 0x60080010, // 0001 GETGBL R2 G16 + 0x600C000C, // 0002 GETGBL R3 G12 + 0x5C100000, // 0003 MOVE R4 R0 + 0x7C0C0200, // 0004 CALL R3 1 + 0x040C0701, // 0005 SUB R3 R3 K1 + 0x400E0203, // 0006 CONNECT R3 K1 R3 + 0x7C080200, // 0007 CALL R2 1 + 0xA8020013, // 0008 EXBLK 0 #001D + 0x5C0C0400, // 0009 MOVE R3 R2 + 0x7C0C0000, // 000A CALL R3 0 + 0x94100003, // 000B GETIDX R4 R0 R3 + 0x5C140600, // 000C MOVE R5 R3 + 0x24180B02, // 000D GT R6 R5 K2 + 0x781A000B, // 000E JMPF R6 #001B + 0x04180B01, // 000F SUB R6 R5 K1 + 0x94180006, // 0010 GETIDX R6 R0 R6 + 0x8C180D03, // 0011 GETMET R6 R6 K3 + 0x5C200800, // 0012 MOVE R8 R4 + 0x7C180400, // 0013 CALL R6 2 + 0x24180D02, // 0014 GT R6 R6 K2 + 0x781A0004, // 0015 JMPF R6 #001B + 0x04180B01, // 0016 SUB R6 R5 K1 + 0x94180006, // 0017 GETIDX R6 R0 R6 + 0x98000A06, // 0018 SETIDX R0 R5 R6 + 0x04140B01, // 0019 SUB R5 R5 K1 + 0x7001FFF1, // 001A JMP #000D + 0x98000A04, // 001B SETIDX R0 R5 R4 + 0x7001FFEB, // 001C JMP #0009 + 0x58080004, // 001D LDCONST R2 K4 + 0xAC080200, // 001E CATCH R2 1 0 + 0xB0080000, // 001F RAISE 2 R0 R0 + 0x80040000, // 0020 RET 1 R0 }) ) ); @@ -760,230 +1627,6 @@ be_local_closure(Matter_TLV_item_to_TLV, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: tostring -********************************************************************/ -be_local_closure(Matter_TLV_item_tostring, /* name */ - be_nested_proto( - 8, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[35]) { /* constants */ - /* K0 */ be_nested_str_weak(string), - /* K1 */ be_nested_str_weak(), - /* K2 */ be_nested_str_weak(tag_profile), - /* K3 */ be_nested_str_weak(Matter_X3A_X3A), - /* K4 */ be_nested_str_weak(tag_number), - /* K5 */ be_nested_str_weak(format), - /* K6 */ be_nested_str_weak(0x_X2508X_X20), - /* K7 */ be_nested_str_weak(tag_vendor), - /* K8 */ be_nested_str_weak(0x_X2504X_X3A_X3A), - /* K9 */ be_nested_str_weak(0x_X2504X_X3A), - /* K10 */ be_nested_str_weak(tag_sub), - /* K11 */ be_nested_str_weak(_X25i_X20), - /* K12 */ be_const_int(0), - /* K13 */ be_nested_str_weak(_X3D_X20), - /* K14 */ be_nested_str_weak(val), - /* K15 */ be_nested_str_weak(int), - /* K16 */ be_nested_str_weak(_X25i), - /* K17 */ be_nested_str_weak(typ), - /* K18 */ be_nested_str_weak(TLV), - /* K19 */ be_nested_str_weak(U1), - /* K20 */ be_nested_str_weak(U8), - /* K21 */ be_nested_str_weak(U), - /* K22 */ be_nested_str_weak(bool), - /* K23 */ be_nested_str_weak(true), - /* K24 */ be_nested_str_weak(false), - /* K25 */ be_nested_str_weak(null), - /* K26 */ be_nested_str_weak(real), - /* K27 */ be_nested_str_weak(_X25g), - /* K28 */ be_nested_str_weak(_X22_X25s_X22), - /* K29 */ be_nested_str_weak(int64), - /* K30 */ be_nested_str_weak(tostring), - /* K31 */ be_nested_str_weak(instance), - /* K32 */ be_nested_str_weak(_X25s), - /* K33 */ be_nested_str_weak(tohex), - /* K34 */ be_nested_str_weak(_X20), - }), - be_str_weak(tostring), - &be_const_str_solidified, - ( &(const binstruction[165]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x58080001, // 0001 LDCONST R2 K1 - 0xA8020099, // 0002 EXBLK 0 #009D - 0x880C0102, // 0003 GETMBR R3 R0 K2 - 0x5411FFFE, // 0004 LDINT R4 -1 - 0x1C0C0604, // 0005 EQ R3 R3 R4 - 0x780E000A, // 0006 JMPF R3 #0012 - 0x00080503, // 0007 ADD R2 R2 K3 - 0x880C0104, // 0008 GETMBR R3 R0 K4 - 0x4C100000, // 0009 LDNIL R4 - 0x200C0604, // 000A NE R3 R3 R4 - 0x780E0004, // 000B JMPF R3 #0011 - 0x8C0C0305, // 000C GETMET R3 R1 K5 - 0x58140006, // 000D LDCONST R5 K6 - 0x88180104, // 000E GETMBR R6 R0 K4 - 0x7C0C0600, // 000F CALL R3 3 - 0x00080403, // 0010 ADD R2 R2 R3 - 0x70020023, // 0011 JMP #0036 - 0x880C0107, // 0012 GETMBR R3 R0 K7 - 0x4C100000, // 0013 LDNIL R4 - 0x200C0604, // 0014 NE R3 R3 R4 - 0x780E0004, // 0015 JMPF R3 #001B - 0x8C0C0305, // 0016 GETMET R3 R1 K5 - 0x58140008, // 0017 LDCONST R5 K8 - 0x88180107, // 0018 GETMBR R6 R0 K7 - 0x7C0C0600, // 0019 CALL R3 3 - 0x00080403, // 001A ADD R2 R2 R3 - 0x880C0102, // 001B GETMBR R3 R0 K2 - 0x4C100000, // 001C LDNIL R4 - 0x200C0604, // 001D NE R3 R3 R4 - 0x780E0004, // 001E JMPF R3 #0024 - 0x8C0C0305, // 001F GETMET R3 R1 K5 - 0x58140009, // 0020 LDCONST R5 K9 - 0x88180102, // 0021 GETMBR R6 R0 K2 - 0x7C0C0600, // 0022 CALL R3 3 - 0x00080403, // 0023 ADD R2 R2 R3 - 0x880C0104, // 0024 GETMBR R3 R0 K4 - 0x4C100000, // 0025 LDNIL R4 - 0x200C0604, // 0026 NE R3 R3 R4 - 0x780E0004, // 0027 JMPF R3 #002D - 0x8C0C0305, // 0028 GETMET R3 R1 K5 - 0x58140006, // 0029 LDCONST R5 K6 - 0x88180104, // 002A GETMBR R6 R0 K4 - 0x7C0C0600, // 002B CALL R3 3 - 0x00080403, // 002C ADD R2 R2 R3 - 0x880C010A, // 002D GETMBR R3 R0 K10 - 0x4C100000, // 002E LDNIL R4 - 0x200C0604, // 002F NE R3 R3 R4 - 0x780E0004, // 0030 JMPF R3 #0036 - 0x8C0C0305, // 0031 GETMET R3 R1 K5 - 0x5814000B, // 0032 LDCONST R5 K11 - 0x8818010A, // 0033 GETMBR R6 R0 K10 - 0x7C0C0600, // 0034 CALL R3 3 - 0x00080403, // 0035 ADD R2 R2 R3 - 0x600C000C, // 0036 GETGBL R3 G12 - 0x5C100400, // 0037 MOVE R4 R2 - 0x7C0C0200, // 0038 CALL R3 1 - 0x240C070C, // 0039 GT R3 R3 K12 - 0x780E0000, // 003A JMPF R3 #003C - 0x0008050D, // 003B ADD R2 R2 K13 - 0x600C0004, // 003C GETGBL R3 G4 - 0x8810010E, // 003D GETMBR R4 R0 K14 - 0x7C0C0200, // 003E CALL R3 1 - 0x1C0C070F, // 003F EQ R3 R3 K15 - 0x780E0010, // 0040 JMPF R3 #0052 - 0x8C0C0305, // 0041 GETMET R3 R1 K5 - 0x58140010, // 0042 LDCONST R5 K16 - 0x8818010E, // 0043 GETMBR R6 R0 K14 - 0x7C0C0600, // 0044 CALL R3 3 - 0x00080403, // 0045 ADD R2 R2 R3 - 0x880C0111, // 0046 GETMBR R3 R0 K17 - 0x88100112, // 0047 GETMBR R4 R0 K18 - 0x88100913, // 0048 GETMBR R4 R4 K19 - 0x280C0604, // 0049 GE R3 R3 R4 - 0x780E0005, // 004A JMPF R3 #0051 - 0x880C0111, // 004B GETMBR R3 R0 K17 - 0x88100112, // 004C GETMBR R4 R0 K18 - 0x88100914, // 004D GETMBR R4 R4 K20 - 0x180C0604, // 004E LE R3 R3 R4 - 0x780E0000, // 004F JMPF R3 #0051 - 0x00080515, // 0050 ADD R2 R2 K21 - 0x70020048, // 0051 JMP #009B - 0x600C0004, // 0052 GETGBL R3 G4 - 0x8810010E, // 0053 GETMBR R4 R0 K14 - 0x7C0C0200, // 0054 CALL R3 1 - 0x1C0C0716, // 0055 EQ R3 R3 K22 - 0x780E0006, // 0056 JMPF R3 #005E - 0x880C010E, // 0057 GETMBR R3 R0 K14 - 0x780E0001, // 0058 JMPF R3 #005B - 0x580C0017, // 0059 LDCONST R3 K23 - 0x70020000, // 005A JMP #005C - 0x580C0018, // 005B LDCONST R3 K24 - 0x00080403, // 005C ADD R2 R2 R3 - 0x7002003C, // 005D JMP #009B - 0x880C010E, // 005E GETMBR R3 R0 K14 - 0x4C100000, // 005F LDNIL R4 - 0x1C0C0604, // 0060 EQ R3 R3 R4 - 0x780E0001, // 0061 JMPF R3 #0064 - 0x00080519, // 0062 ADD R2 R2 K25 - 0x70020036, // 0063 JMP #009B - 0x600C0004, // 0064 GETGBL R3 G4 - 0x8810010E, // 0065 GETMBR R4 R0 K14 - 0x7C0C0200, // 0066 CALL R3 1 - 0x1C0C071A, // 0067 EQ R3 R3 K26 - 0x780E0005, // 0068 JMPF R3 #006F - 0x8C0C0305, // 0069 GETMET R3 R1 K5 - 0x5814001B, // 006A LDCONST R5 K27 - 0x8818010E, // 006B GETMBR R6 R0 K14 - 0x7C0C0600, // 006C CALL R3 3 - 0x00080403, // 006D ADD R2 R2 R3 - 0x7002002B, // 006E JMP #009B - 0x600C0004, // 006F GETGBL R3 G4 - 0x8810010E, // 0070 GETMBR R4 R0 K14 - 0x7C0C0200, // 0071 CALL R3 1 - 0x1C0C0700, // 0072 EQ R3 R3 K0 - 0x780E0005, // 0073 JMPF R3 #007A - 0x8C0C0305, // 0074 GETMET R3 R1 K5 - 0x5814001C, // 0075 LDCONST R5 K28 - 0x8818010E, // 0076 GETMBR R6 R0 K14 - 0x7C0C0600, // 0077 CALL R3 3 - 0x00080403, // 0078 ADD R2 R2 R3 - 0x70020020, // 0079 JMP #009B - 0x600C000F, // 007A GETGBL R3 G15 - 0x8810010E, // 007B GETMBR R4 R0 K14 - 0xB8163A00, // 007C GETNGBL R5 K29 - 0x7C0C0400, // 007D CALL R3 2 - 0x780E000F, // 007E JMPF R3 #008F - 0x880C010E, // 007F GETMBR R3 R0 K14 - 0x8C0C071E, // 0080 GETMET R3 R3 K30 - 0x7C0C0200, // 0081 CALL R3 1 - 0x00080403, // 0082 ADD R2 R2 R3 - 0x880C0111, // 0083 GETMBR R3 R0 K17 - 0x88100112, // 0084 GETMBR R4 R0 K18 - 0x88100913, // 0085 GETMBR R4 R4 K19 - 0x280C0604, // 0086 GE R3 R3 R4 - 0x780E0005, // 0087 JMPF R3 #008E - 0x880C0111, // 0088 GETMBR R3 R0 K17 - 0x88100112, // 0089 GETMBR R4 R0 K18 - 0x88100914, // 008A GETMBR R4 R4 K20 - 0x180C0604, // 008B LE R3 R3 R4 - 0x780E0000, // 008C JMPF R3 #008E - 0x00080515, // 008D ADD R2 R2 K21 - 0x7002000B, // 008E JMP #009B - 0x600C0004, // 008F GETGBL R3 G4 - 0x8810010E, // 0090 GETMBR R4 R0 K14 - 0x7C0C0200, // 0091 CALL R3 1 - 0x1C0C071F, // 0092 EQ R3 R3 K31 - 0x780E0006, // 0093 JMPF R3 #009B - 0x8C0C0305, // 0094 GETMET R3 R1 K5 - 0x58140020, // 0095 LDCONST R5 K32 - 0x8818010E, // 0096 GETMBR R6 R0 K14 - 0x8C180D21, // 0097 GETMET R6 R6 K33 - 0x7C180200, // 0098 CALL R6 1 - 0x7C0C0600, // 0099 CALL R3 3 - 0x00080403, // 009A ADD R2 R2 R3 - 0xA8040001, // 009B EXBLK 1 1 - 0x70020006, // 009C JMP #00A4 - 0xAC0C0002, // 009D CATCH R3 0 2 - 0x70020003, // 009E JMP #00A3 - 0x00140722, // 009F ADD R5 R3 K34 - 0x00140A04, // 00A0 ADD R5 R5 R4 - 0x80040A00, // 00A1 RET 1 R5 - 0x70020000, // 00A2 JMP #00A4 - 0xB0080000, // 00A3 RAISE 2 R0 R0 - 0x80040400, // 00A4 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: parse ********************************************************************/ @@ -1138,289 +1781,39 @@ be_local_closure(Matter_TLV_item_parse, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: init -********************************************************************/ -be_local_closure(Matter_TLV_item_init, /* name */ - be_nested_proto( - 2, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(parent), - }), - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: _cmp_gt -********************************************************************/ -be_local_closure(Matter_TLV_item__cmp_gt, /* name */ - be_nested_proto( - 4, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 6]) { /* constants */ - /* K0 */ be_nested_str_weak(tag_vendor), - /* K1 */ be_const_int(1), - /* K2 */ be_nested_str_weak(tag_profile), - /* K3 */ be_const_int(0), - /* K4 */ be_nested_str_weak(tag_number), - /* K5 */ be_nested_str_weak(tag_sub), - }), - be_str_weak(_cmp_gt), - &be_const_str_solidified, - ( &(const binstruction[72]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x4C0C0000, // 0001 LDNIL R3 - 0x20080403, // 0002 NE R2 R2 R3 - 0x780A0012, // 0003 JMPF R2 #0017 - 0x88080300, // 0004 GETMBR R2 R1 K0 - 0x4C0C0000, // 0005 LDNIL R3 - 0x1C080403, // 0006 EQ R2 R2 R3 - 0x780A0000, // 0007 JMPF R2 #0009 - 0x80060200, // 0008 RET 1 K1 - 0x88080100, // 0009 GETMBR R2 R0 K0 - 0x880C0300, // 000A GETMBR R3 R1 K0 - 0x24080403, // 000B GT R2 R2 R3 - 0x780A0000, // 000C JMPF R2 #000E - 0x80060200, // 000D RET 1 K1 - 0x88080100, // 000E GETMBR R2 R0 K0 - 0x880C0300, // 000F GETMBR R3 R1 K0 - 0x1C080403, // 0010 EQ R2 R2 R3 - 0x780A0004, // 0011 JMPF R2 #0017 - 0x88080102, // 0012 GETMBR R2 R0 K2 - 0x880C0302, // 0013 GETMBR R3 R1 K2 - 0x24080403, // 0014 GT R2 R2 R3 - 0x780A0000, // 0015 JMPF R2 #0017 - 0x80060200, // 0016 RET 1 K1 - 0x88080102, // 0017 GETMBR R2 R0 K2 - 0x540DFFFE, // 0018 LDINT R3 -1 - 0x1C080403, // 0019 EQ R2 R2 R3 - 0x780A0005, // 001A JMPF R2 #0021 - 0x88080302, // 001B GETMBR R2 R1 K2 - 0x4C0C0000, // 001C LDNIL R3 - 0x1C080403, // 001D EQ R2 R2 R3 - 0x780A0000, // 001E JMPF R2 #0020 - 0x80060200, // 001F RET 1 K1 - 0x70020008, // 0020 JMP #002A - 0x88080102, // 0021 GETMBR R2 R0 K2 - 0x4C0C0000, // 0022 LDNIL R3 - 0x1C080403, // 0023 EQ R2 R2 R3 - 0x780A0004, // 0024 JMPF R2 #002A - 0x88080302, // 0025 GETMBR R2 R1 K2 - 0x540DFFFE, // 0026 LDINT R3 -1 - 0x1C080403, // 0027 EQ R2 R2 R3 - 0x780A0000, // 0028 JMPF R2 #002A - 0x80060600, // 0029 RET 1 K3 - 0x88080104, // 002A GETMBR R2 R0 K4 - 0x4C0C0000, // 002B LDNIL R3 - 0x20080403, // 002C NE R2 R2 R3 - 0x780A000A, // 002D JMPF R2 #0039 - 0x88080304, // 002E GETMBR R2 R1 K4 - 0x4C0C0000, // 002F LDNIL R3 - 0x1C080403, // 0030 EQ R2 R2 R3 - 0x780A0000, // 0031 JMPF R2 #0033 - 0x80060200, // 0032 RET 1 K1 - 0x88080104, // 0033 GETMBR R2 R0 K4 - 0x880C0304, // 0034 GETMBR R3 R1 K4 - 0x24080403, // 0035 GT R2 R2 R3 - 0x780A0000, // 0036 JMPF R2 #0038 - 0x80060200, // 0037 RET 1 K1 - 0x80060600, // 0038 RET 1 K3 - 0x88080105, // 0039 GETMBR R2 R0 K5 - 0x4C0C0000, // 003A LDNIL R3 - 0x20080403, // 003B NE R2 R2 R3 - 0x780A0009, // 003C JMPF R2 #0047 - 0x88080305, // 003D GETMBR R2 R1 K5 - 0x4C0C0000, // 003E LDNIL R3 - 0x1C080403, // 003F EQ R2 R2 R3 - 0x780A0000, // 0040 JMPF R2 #0042 - 0x80060200, // 0041 RET 1 K1 - 0x88080105, // 0042 GETMBR R2 R0 K5 - 0x880C0305, // 0043 GETMBR R3 R1 K5 - 0x24080403, // 0044 GT R2 R2 R3 - 0x780A0000, // 0045 JMPF R2 #0047 - 0x80060200, // 0046 RET 1 K1 - 0x80060600, // 0047 RET 1 K3 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: sort -********************************************************************/ -be_local_closure(Matter_TLV_item_sort, /* name */ - be_nested_proto( - 9, /* nstack */ - 1, /* argc */ - 4, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_const_class(be_class_Matter_TLV_item), - /* K1 */ be_const_int(1), - /* K2 */ be_const_int(0), - /* K3 */ be_nested_str_weak(_cmp_gt), - /* K4 */ be_nested_str_weak(stop_iteration), - }), - be_str_weak(sort), - &be_const_str_solidified, - ( &(const binstruction[33]) { /* code */ - 0x58040000, // 0000 LDCONST R1 K0 - 0x60080010, // 0001 GETGBL R2 G16 - 0x600C000C, // 0002 GETGBL R3 G12 - 0x5C100000, // 0003 MOVE R4 R0 - 0x7C0C0200, // 0004 CALL R3 1 - 0x040C0701, // 0005 SUB R3 R3 K1 - 0x400E0203, // 0006 CONNECT R3 K1 R3 - 0x7C080200, // 0007 CALL R2 1 - 0xA8020013, // 0008 EXBLK 0 #001D - 0x5C0C0400, // 0009 MOVE R3 R2 - 0x7C0C0000, // 000A CALL R3 0 - 0x94100003, // 000B GETIDX R4 R0 R3 - 0x5C140600, // 000C MOVE R5 R3 - 0x24180B02, // 000D GT R6 R5 K2 - 0x781A000B, // 000E JMPF R6 #001B - 0x04180B01, // 000F SUB R6 R5 K1 - 0x94180006, // 0010 GETIDX R6 R0 R6 - 0x8C180D03, // 0011 GETMET R6 R6 K3 - 0x5C200800, // 0012 MOVE R8 R4 - 0x7C180400, // 0013 CALL R6 2 - 0x24180D02, // 0014 GT R6 R6 K2 - 0x781A0004, // 0015 JMPF R6 #001B - 0x04180B01, // 0016 SUB R6 R5 K1 - 0x94180006, // 0017 GETIDX R6 R0 R6 - 0x98000A06, // 0018 SETIDX R0 R5 R6 - 0x04140B01, // 0019 SUB R5 R5 K1 - 0x7001FFF1, // 001A JMP #000D - 0x98000A04, // 001B SETIDX R0 R5 R4 - 0x7001FFEB, // 001C JMP #0009 - 0x58080004, // 001D LDCONST R2 K4 - 0xAC080200, // 001E CATCH R2 1 0 - 0xB0080000, // 001F RAISE 2 R0 R0 - 0x80040000, // 0020 RET 1 R0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_anonymoustag -********************************************************************/ -be_local_closure(Matter_TLV_item_set_anonymoustag, /* name */ - be_nested_proto( - 3, /* nstack */ - 1, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(set_fulltag), - }), - be_str_weak(set_anonymoustag), - &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ - 0x8C040100, // 0000 GETMET R1 R0 K0 - 0x7C040200, // 0001 CALL R1 1 - 0x80000000, // 0002 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: set_contextspecific -********************************************************************/ -be_local_closure(Matter_TLV_item_set_contextspecific, /* name */ - be_nested_proto( - 4, /* nstack */ - 2, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(set_fulltag), - /* K1 */ be_nested_str_weak(tag_sub), - }), - be_str_weak(set_contextspecific), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x8C080100, // 0000 GETMET R2 R0 K0 - 0x7C080200, // 0001 CALL R2 1 - 0x60080009, // 0002 GETGBL R2 G9 - 0x5C0C0200, // 0003 MOVE R3 R1 - 0x7C080200, // 0004 CALL R2 1 - 0x90020202, // 0005 SETMBR R0 K1 R2 - 0x80000000, // 0006 RET 0 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified class: Matter_TLV_item ********************************************************************/ be_local_class(Matter_TLV_item, 8, NULL, - be_nested_map(23, + be_nested_map(25, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(set_commonprofile, -1), be_const_closure(Matter_TLV_item_set_commonprofile_closure) }, { be_const_key_weak(set_parent, -1), be_const_closure(Matter_TLV_item_set_parent_closure) }, - { be_const_key_weak(tag_profile, 3), be_const_var(3) }, - { be_const_key_weak(set_anonymoustag, 8), be_const_closure(Matter_TLV_item_set_anonymoustag_closure) }, { be_const_key_weak(create_TLV, -1), be_const_static_closure(Matter_TLV_item_create_TLV_closure) }, - { be_const_key_weak(_encode_tag, -1), be_const_closure(Matter_TLV_item__encode_tag_closure) }, - { be_const_key_weak(val, -1), be_const_var(7) }, - { be_const_key_weak(TLV, 20), be_const_class(be_class_Matter_TLV) }, - { be_const_key_weak(tag_vendor, 1), be_const_var(2) }, - { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_item_tostring_closure) }, - { be_const_key_weak(parse, -1), be_const_closure(Matter_TLV_item_parse_closure) }, - { be_const_key_weak(tag_number, -1), be_const_var(4) }, - { be_const_key_weak(sort, -1), be_const_static_closure(Matter_TLV_item_sort_closure) }, { be_const_key_weak(next_idx, -1), be_const_var(1) }, - { be_const_key_weak(init, -1), be_const_closure(Matter_TLV_item_init_closure) }, - { be_const_key_weak(_cmp_gt, -1), be_const_closure(Matter_TLV_item__cmp_gt_closure) }, - { be_const_key_weak(encode, 12), be_const_closure(Matter_TLV_item_encode_closure) }, - { be_const_key_weak(typ, -1), be_const_var(6) }, - { be_const_key_weak(parent, -1), be_const_var(0) }, - { be_const_key_weak(to_TLV, 6), be_const_closure(Matter_TLV_item_to_TLV_closure) }, + { be_const_key_weak(TLV, -1), be_const_class(be_class_Matter_TLV) }, + { be_const_key_weak(_encode_tag, 10), be_const_closure(Matter_TLV_item__encode_tag_closure) }, + { be_const_key_weak(set_anonymoustag, 17), be_const_closure(Matter_TLV_item_set_anonymoustag_closure) }, + { be_const_key_weak(val, -1), be_const_var(7) }, + { be_const_key_weak(parse, -1), be_const_closure(Matter_TLV_item_parse_closure) }, + { be_const_key_weak(to_TLV, -1), be_const_closure(Matter_TLV_item_to_TLV_closure) }, + { be_const_key_weak(_cmp_gt, 8), be_const_closure(Matter_TLV_item__cmp_gt_closure) }, + { be_const_key_weak(tag_vendor, -1), be_const_var(2) }, + { be_const_key_weak(encode_len, 19), be_const_closure(Matter_TLV_item_encode_len_closure) }, + { be_const_key_weak(set_contextspecific, 7), be_const_closure(Matter_TLV_item_set_contextspecific_closure) }, { be_const_key_weak(set_fulltag, -1), be_const_closure(Matter_TLV_item_set_fulltag_closure) }, - { be_const_key_weak(tag_sub, 2), be_const_var(5) }, - { be_const_key_weak(set_contextspecific, -1), be_const_closure(Matter_TLV_item_set_contextspecific_closure) }, + { be_const_key_weak(parent, -1), be_const_var(0) }, + { be_const_key_weak(encode, 18), be_const_closure(Matter_TLV_item_encode_closure) }, + { be_const_key_weak(tag_sub, -1), be_const_var(5) }, + { be_const_key_weak(init, 23), be_const_closure(Matter_TLV_item_init_closure) }, + { be_const_key_weak(_encode_tag_len, 22), be_const_closure(Matter_TLV_item__encode_tag_len_closure) }, + { be_const_key_weak(tag_profile, -1), be_const_var(3) }, + { be_const_key_weak(set_commonprofile, 15), be_const_closure(Matter_TLV_item_set_commonprofile_closure) }, + { be_const_key_weak(sort, -1), be_const_static_closure(Matter_TLV_item_sort_closure) }, + { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_item_tostring_closure) }, + { be_const_key_weak(tag_number, 16), be_const_var(4) }, + { be_const_key_weak(typ, 3), be_const_var(6) }, })), be_str_weak(Matter_TLV_item) ); @@ -1711,7 +2104,7 @@ be_local_closure(Matter_TLV_list_findsubtyp, /* name */ ********************************************************************/ be_local_closure(Matter_TLV_list_encode, /* name */ be_nested_proto( - 6, /* nstack */ + 8, /* nstack */ 2, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1719,18 +2112,58 @@ be_local_closure(Matter_TLV_list_encode, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(_encode_inner), - /* K1 */ be_nested_str_weak(is_struct), + ( &(const bvalue[11]) { /* constants */ + /* K0 */ be_nested_str_weak(_encode_tag), + /* K1 */ be_nested_str_weak(val), + /* K2 */ be_nested_str_weak(copy), + /* K3 */ be_nested_str_weak(is_struct), + /* K4 */ be_nested_str_weak(sort), + /* K5 */ be_nested_str_weak(encode), + /* K6 */ be_nested_str_weak(stop_iteration), + /* K7 */ be_nested_str_weak(add), + /* K8 */ be_nested_str_weak(TLV), + /* K9 */ be_nested_str_weak(EOC), + /* K10 */ be_const_int(1), }), be_str_weak(encode), &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x8C080100, // 0000 GETMET R2 R0 K0 - 0x5C100200, // 0001 MOVE R4 R1 - 0x88140101, // 0002 GETMBR R5 R0 K1 - 0x7C080600, // 0003 CALL R2 3 - 0x80040400, // 0004 RET 1 R2 + ( &(const binstruction[36]) { /* code */ + 0x4C080000, // 0000 LDNIL R2 + 0x1C080202, // 0001 EQ R2 R1 R2 + 0x780A0002, // 0002 JMPF R2 #0006 + 0x60080015, // 0003 GETGBL R2 G21 + 0x7C080000, // 0004 CALL R2 0 + 0x5C040400, // 0005 MOVE R1 R2 + 0x8C080100, // 0006 GETMET R2 R0 K0 + 0x5C100200, // 0007 MOVE R4 R1 + 0x7C080400, // 0008 CALL R2 2 + 0x88080101, // 0009 GETMBR R2 R0 K1 + 0x8C080502, // 000A GETMET R2 R2 K2 + 0x7C080200, // 000B CALL R2 1 + 0x880C0103, // 000C GETMBR R3 R0 K3 + 0x780E0002, // 000D JMPF R3 #0011 + 0x8C0C0104, // 000E GETMET R3 R0 K4 + 0x5C140400, // 000F MOVE R5 R2 + 0x7C0C0400, // 0010 CALL R3 2 + 0x600C0010, // 0011 GETGBL R3 G16 + 0x5C100400, // 0012 MOVE R4 R2 + 0x7C0C0200, // 0013 CALL R3 1 + 0xA8020005, // 0014 EXBLK 0 #001B + 0x5C100600, // 0015 MOVE R4 R3 + 0x7C100000, // 0016 CALL R4 0 + 0x8C140905, // 0017 GETMET R5 R4 K5 + 0x5C1C0200, // 0018 MOVE R7 R1 + 0x7C140400, // 0019 CALL R5 2 + 0x7001FFF9, // 001A JMP #0015 + 0x580C0006, // 001B LDCONST R3 K6 + 0xAC0C0200, // 001C CATCH R3 1 0 + 0xB0080000, // 001D RAISE 2 R0 R0 + 0x8C0C0307, // 001E GETMET R3 R1 K7 + 0x88140108, // 001F GETMBR R5 R0 K8 + 0x88140B09, // 0020 GETMBR R5 R5 K9 + 0x5818000A, // 0021 LDCONST R6 K10 + 0x7C0C0600, // 0022 CALL R3 3 + 0x80040200, // 0023 RET 1 R1 }) ) ); @@ -1865,11 +2298,11 @@ be_local_closure(Matter_TLV_list_tostring_inner, /* name */ /******************************************************************** -** Solidified function: tostring +** Solidified function: encode_len ********************************************************************/ -be_local_closure(Matter_TLV_list_tostring, /* name */ +be_local_closure(Matter_TLV_list_encode_len, /* name */ be_nested_proto( - 6, /* nstack */ + 5, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1877,20 +2310,33 @@ be_local_closure(Matter_TLV_list_tostring, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(tostring_inner), - /* K1 */ be_nested_str_weak(_X5B_X5B), - /* K2 */ be_nested_str_weak(_X5D_X5D), + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(_encode_tag_len), + /* K1 */ be_const_int(0), + /* K2 */ be_nested_str_weak(val), + /* K3 */ be_nested_str_weak(encode_len), + /* K4 */ be_const_int(1), }), - be_str_weak(tostring), + be_str_weak(encode_len), &be_const_str_solidified, - ( &(const binstruction[ 6]) { /* code */ + ( &(const binstruction[17]) { /* code */ 0x8C040100, // 0000 GETMET R1 R0 K0 - 0x500C0000, // 0001 LDBOOL R3 0 0 - 0x58100001, // 0002 LDCONST R4 K1 - 0x58140002, // 0003 LDCONST R5 K2 - 0x7C040800, // 0004 CALL R1 4 - 0x80040200, // 0005 RET 1 R1 + 0x7C040200, // 0001 CALL R1 1 + 0x58080001, // 0002 LDCONST R2 K1 + 0x600C000C, // 0003 GETGBL R3 G12 + 0x88100102, // 0004 GETMBR R4 R0 K2 + 0x7C0C0200, // 0005 CALL R3 1 + 0x140C0403, // 0006 LT R3 R2 R3 + 0x780E0006, // 0007 JMPF R3 #000F + 0x880C0102, // 0008 GETMBR R3 R0 K2 + 0x940C0602, // 0009 GETIDX R3 R3 R2 + 0x8C0C0703, // 000A GETMET R3 R3 K3 + 0x7C0C0200, // 000B CALL R3 1 + 0x00040203, // 000C ADD R1 R1 R3 + 0x00080504, // 000D ADD R2 R2 K4 + 0x7001FFF3, // 000E JMP #0003 + 0x00040304, // 000F ADD R1 R1 K4 + 0x80040200, // 0010 RET 1 R1 }) ) ); @@ -2093,75 +2539,6 @@ be_local_closure(Matter_TLV_list_setitem, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: _encode_inner -********************************************************************/ -be_local_closure(Matter_TLV_list__encode_inner, /* name */ - be_nested_proto( - 9, /* nstack */ - 3, /* argc */ - 2, /* varg */ - 0, /* has upvals */ - NULL, /* no upvals */ - 0, /* has sup protos */ - NULL, /* no sub protos */ - 1, /* has constants */ - ( &(const bvalue[10]) { /* constants */ - /* K0 */ be_nested_str_weak(_encode_tag), - /* K1 */ be_nested_str_weak(val), - /* K2 */ be_nested_str_weak(copy), - /* K3 */ be_nested_str_weak(sort), - /* K4 */ be_nested_str_weak(encode), - /* K5 */ be_nested_str_weak(stop_iteration), - /* K6 */ be_nested_str_weak(add), - /* K7 */ be_nested_str_weak(TLV), - /* K8 */ be_nested_str_weak(EOC), - /* K9 */ be_const_int(1), - }), - be_str_weak(_encode_inner), - &be_const_str_solidified, - ( &(const binstruction[35]) { /* code */ - 0x4C0C0000, // 0000 LDNIL R3 - 0x1C0C0203, // 0001 EQ R3 R1 R3 - 0x780E0002, // 0002 JMPF R3 #0006 - 0x600C0015, // 0003 GETGBL R3 G21 - 0x7C0C0000, // 0004 CALL R3 0 - 0x5C040600, // 0005 MOVE R1 R3 - 0x8C0C0100, // 0006 GETMET R3 R0 K0 - 0x5C140200, // 0007 MOVE R5 R1 - 0x7C0C0400, // 0008 CALL R3 2 - 0x880C0101, // 0009 GETMBR R3 R0 K1 - 0x8C0C0702, // 000A GETMET R3 R3 K2 - 0x7C0C0200, // 000B CALL R3 1 - 0x780A0002, // 000C JMPF R2 #0010 - 0x8C100103, // 000D GETMET R4 R0 K3 - 0x5C180600, // 000E MOVE R6 R3 - 0x7C100400, // 000F CALL R4 2 - 0x60100010, // 0010 GETGBL R4 G16 - 0x5C140600, // 0011 MOVE R5 R3 - 0x7C100200, // 0012 CALL R4 1 - 0xA8020005, // 0013 EXBLK 0 #001A - 0x5C140800, // 0014 MOVE R5 R4 - 0x7C140000, // 0015 CALL R5 0 - 0x8C180B04, // 0016 GETMET R6 R5 K4 - 0x5C200200, // 0017 MOVE R8 R1 - 0x7C180400, // 0018 CALL R6 2 - 0x7001FFF9, // 0019 JMP #0014 - 0x58100005, // 001A LDCONST R4 K5 - 0xAC100200, // 001B CATCH R4 1 0 - 0xB0080000, // 001C RAISE 2 R0 R0 - 0x8C100306, // 001D GETMET R4 R1 K6 - 0x88180107, // 001E GETMBR R6 R0 K7 - 0x88180D08, // 001F GETMBR R6 R6 K8 - 0x581C0009, // 0020 LDCONST R7 K9 - 0x7C100600, // 0021 CALL R4 3 - 0x80040200, // 0022 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified function: findsub ********************************************************************/ @@ -2205,6 +2582,39 @@ be_local_closure(Matter_TLV_list_findsub, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: tostring +********************************************************************/ +be_local_closure(Matter_TLV_list_tostring, /* name */ + be_nested_proto( + 6, /* nstack */ + 1, /* argc */ + 2, /* varg */ + 0, /* has upvals */ + NULL, /* no upvals */ + 0, /* has sup protos */ + NULL, /* no sub protos */ + 1, /* has constants */ + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(tostring_inner), + /* K1 */ be_nested_str_weak(_X5B_X5B), + /* K2 */ be_nested_str_weak(_X5D_X5D), + }), + be_str_weak(tostring), + &be_const_str_solidified, + ( &(const binstruction[ 6]) { /* code */ + 0x8C040100, // 0000 GETMET R1 R0 K0 + 0x500C0000, // 0001 LDBOOL R3 0 0 + 0x58100001, // 0002 LDCONST R4 K1 + 0x58140002, // 0003 LDCONST R5 K2 + 0x7C040800, // 0004 CALL R1 4 + 0x80040200, // 0005 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: parse ********************************************************************/ @@ -2310,13 +2720,13 @@ be_local_class(Matter_TLV_list, { be_const_key_weak(findsubtyp, -1), be_const_closure(Matter_TLV_list_findsubtyp_closure) }, { be_const_key_weak(encode, -1), be_const_closure(Matter_TLV_list_encode_closure) }, { be_const_key_weak(tostring_inner, 4), be_const_closure(Matter_TLV_list_tostring_inner_closure) }, - { be_const_key_weak(tostring, 16), be_const_closure(Matter_TLV_list_tostring_closure) }, + { be_const_key_weak(encode_len, 15), be_const_closure(Matter_TLV_list_encode_len_closure) }, { be_const_key_weak(findsubval, -1), be_const_closure(Matter_TLV_list_findsubval_closure) }, { be_const_key_weak(init, -1), be_const_closure(Matter_TLV_list_init_closure) }, - { be_const_key_weak(add_array, 15), be_const_closure(Matter_TLV_list_add_array_closure) }, + { be_const_key_weak(add_array, 16), be_const_closure(Matter_TLV_list_add_array_closure) }, { be_const_key_weak(add_TLV, 18), be_const_closure(Matter_TLV_list_add_TLV_closure) }, + { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_list_tostring_closure) }, { be_const_key_weak(findsub, -1), be_const_closure(Matter_TLV_list_findsub_closure) }, - { be_const_key_weak(_encode_inner, -1), be_const_closure(Matter_TLV_list__encode_inner_closure) }, { be_const_key_weak(is_struct, -1), be_const_bool(0) }, { be_const_key_weak(setitem, -1), be_const_closure(Matter_TLV_list_setitem_closure) }, { be_const_key_weak(item, 5), be_const_closure(Matter_TLV_list_item_closure) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_UDPServer.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_UDPServer.h index 9cf11d294..7e6dd5547 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_UDPServer.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_UDPServer.h @@ -66,7 +66,7 @@ be_local_closure(Matter_UDPPacket_sent_send, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[14]) { /* constants */ + ( &(const bvalue[13]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(send), /* K2 */ be_nested_str_weak(addr), @@ -78,9 +78,8 @@ be_local_closure(Matter_UDPPacket_sent_send, /* name */ /* K8 */ be_nested_str_weak(log), /* K9 */ be_nested_str_weak(format), /* K10 */ be_nested_str_weak(MTR_X3A_X20sending_X20packet_X20to_X20_X27_X5B_X25s_X5D_X3A_X25i_X27), - /* K11 */ be_const_int(3), - /* K12 */ be_nested_str_weak(MTR_X3A_X20failed_X20to_X20send_X20packet_X20to_X20_X27_X5B_X25s_X5D_X3A_X25i_X27), - /* K13 */ be_const_int(2), + /* K11 */ be_nested_str_weak(MTR_X3A_X20error_X20sending_X20packet_X20to_X20_X27_X5B_X25s_X5D_X3A_X25i_X27), + /* K12 */ be_const_int(3), }), be_str_weak(send), &be_const_str_solidified, @@ -107,17 +106,17 @@ be_local_closure(Matter_UDPPacket_sent_send, /* name */ 0x88240102, // 0013 GETMBR R9 R0 K2 0x88280104, // 0014 GETMBR R10 R0 K4 0x7C180800, // 0015 CALL R6 4 - 0x581C000B, // 0016 LDCONST R7 K11 + 0x541E0003, // 0016 LDINT R7 4 0x7C100600, // 0017 CALL R4 3 0x70020008, // 0018 JMP #0022 0xB8120E00, // 0019 GETNGBL R4 K7 0x8C100908, // 001A GETMET R4 R4 K8 0x8C180509, // 001B GETMET R6 R2 K9 - 0x5820000C, // 001C LDCONST R8 K12 + 0x5820000B, // 001C LDCONST R8 K11 0x88240102, // 001D GETMBR R9 R0 K2 0x88280104, // 001E GETMBR R10 R0 K4 0x7C180800, // 001F CALL R6 4 - 0x581C000D, // 0020 LDCONST R7 K13 + 0x581C000C, // 0020 LDCONST R7 K12 0x7C100600, // 0021 CALL R4 3 0x80000000, // 0022 RET 0 }) @@ -357,7 +356,7 @@ be_local_closure(Matter_UDPServer_every_50ms, /* name */ ********************************************************************/ be_local_closure(Matter_UDPServer_resend_packets, /* name */ be_nested_proto( - 7, /* nstack */ + 11, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -365,7 +364,7 @@ be_local_closure(Matter_UDPServer_resend_packets, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[17]) { /* constants */ + ( &(const bvalue[22]) { /* constants */ /* K0 */ be_nested_str_weak(packets_sent), /* K1 */ be_nested_str_weak(tasmota), /* K2 */ be_nested_str_weak(time_reached), @@ -379,25 +378,30 @@ be_local_closure(Matter_UDPServer_resend_packets, /* name */ /* K10 */ be_nested_str_weak(retries), /* K11 */ be_const_int(1), /* K12 */ be_const_int(0), - /* K13 */ be_nested_str_weak(remove), - /* K14 */ be_nested_str_weak(millis), - /* K15 */ be_nested_str_weak(RETRY_MS), - /* K16 */ be_nested_str_weak(stop_iteration), + /* K13 */ be_nested_str_weak(string), + /* K14 */ be_nested_str_weak(remove), + /* K15 */ be_nested_str_weak(format), + /* K16 */ be_nested_str_weak(MTR_X3A_X20non_X2Dacked_X20packet_X20to_X20_X27_X5B_X25s_X5D_X3A_X25i_X27), + /* K17 */ be_nested_str_weak(addr), + /* K18 */ be_nested_str_weak(port), + /* K19 */ be_nested_str_weak(millis), + /* K20 */ be_nested_str_weak(RETRY_MS), + /* K21 */ be_nested_str_weak(stop_iteration), }), be_str_weak(resend_packets), &be_const_str_solidified, - ( &(const binstruction[44]) { /* code */ + ( &(const binstruction[54]) { /* code */ 0x60040010, // 0000 GETGBL R1 G16 0x88080100, // 0001 GETMBR R2 R0 K0 0x7C040200, // 0002 CALL R1 1 - 0xA8020023, // 0003 EXBLK 0 #0028 + 0xA802002D, // 0003 EXBLK 0 #0032 0x5C080200, // 0004 MOVE R2 R1 0x7C080000, // 0005 CALL R2 0 0xB80E0200, // 0006 GETNGBL R3 K1 0x8C0C0702, // 0007 GETMET R3 R3 K2 0x88140503, // 0008 GETMBR R5 R2 K3 0x7C0C0400, // 0009 CALL R3 2 - 0x780E001B, // 000A JMPF R3 #0027 + 0x780E0025, // 000A JMPF R3 #0031 0xB80E0200, // 000B GETNGBL R3 K1 0x8C0C0704, // 000C GETMET R3 R3 K4 0x60140008, // 000D GETGBL R5 G8 @@ -414,23 +418,33 @@ be_local_closure(Matter_UDPServer_resend_packets, /* name */ 0x900A1403, // 0018 SETMBR R2 K10 R3 0x880C050A, // 0019 GETMBR R3 R2 K10 0x180C070C, // 001A LE R3 R3 K12 - 0x780E0004, // 001B JMPF R3 #0021 - 0x880C0100, // 001C GETMBR R3 R0 K0 - 0x8C0C070D, // 001D GETMET R3 R3 K13 - 0x88140506, // 001E GETMBR R5 R2 K6 - 0x7C0C0400, // 001F CALL R3 2 - 0x70020005, // 0020 JMP #0027 - 0xB80E0200, // 0021 GETNGBL R3 K1 - 0x8C0C070E, // 0022 GETMET R3 R3 K14 - 0x7C0C0200, // 0023 CALL R3 1 - 0x8810050F, // 0024 GETMBR R4 R2 K15 - 0x000C0604, // 0025 ADD R3 R3 R4 - 0x900A0603, // 0026 SETMBR R2 K3 R3 - 0x7001FFDB, // 0027 JMP #0004 - 0x58040010, // 0028 LDCONST R1 K16 - 0xAC040200, // 0029 CATCH R1 1 0 - 0xB0080000, // 002A RAISE 2 R0 R0 - 0x80000000, // 002B RET 0 + 0x780E000E, // 001B JMPF R3 #002B + 0xA40E1A00, // 001C IMPORT R3 K13 + 0x88100100, // 001D GETMBR R4 R0 K0 + 0x8C10090E, // 001E GETMET R4 R4 K14 + 0x88180506, // 001F GETMBR R6 R2 K6 + 0x7C100400, // 0020 CALL R4 2 + 0xB8120200, // 0021 GETNGBL R4 K1 + 0x8C100904, // 0022 GETMET R4 R4 K4 + 0x8C18070F, // 0023 GETMET R6 R3 K15 + 0x58200010, // 0024 LDCONST R8 K16 + 0x88240511, // 0025 GETMBR R9 R2 K17 + 0x88280512, // 0026 GETMBR R10 R2 K18 + 0x7C180800, // 0027 CALL R6 4 + 0x581C0007, // 0028 LDCONST R7 K7 + 0x7C100600, // 0029 CALL R4 3 + 0x70020005, // 002A JMP #0031 + 0xB80E0200, // 002B GETNGBL R3 K1 + 0x8C0C0713, // 002C GETMET R3 R3 K19 + 0x7C0C0200, // 002D CALL R3 1 + 0x88100514, // 002E GETMBR R4 R2 K20 + 0x000C0604, // 002F ADD R3 R3 R4 + 0x900A0603, // 0030 SETMBR R2 K3 R3 + 0x7001FFD1, // 0031 JMP #0004 + 0x58040015, // 0032 LDCONST R1 K21 + 0xAC040200, // 0033 CATCH R1 1 0 + 0xB0080000, // 0034 RAISE 2 R0 R0 + 0x80000000, // 0035 RET 0 }) ) ); @@ -549,14 +563,13 @@ be_local_closure(Matter_UDPServer_packet_ack, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 7]) { /* constants */ + ( &(const bvalue[ 6]) { /* constants */ /* K0 */ be_nested_str_weak(packets_sent), /* K1 */ be_nested_str_weak(contains), /* K2 */ be_nested_str_weak(remove), /* K3 */ be_nested_str_weak(tasmota), /* K4 */ be_nested_str_weak(log), /* K5 */ be_nested_str_weak(MTR_X3A_X20removed_X20packet_X20from_X20sending_X20list_X20id_X3D), - /* K6 */ be_const_int(3), }), be_str_weak(packet_ack), &be_const_str_solidified, @@ -580,7 +593,7 @@ be_local_closure(Matter_UDPServer_packet_ack, /* name */ 0x5C140200, // 0010 MOVE R5 R1 0x7C100200, // 0011 CALL R4 1 0x00120A04, // 0012 ADD R4 K5 R4 - 0x58140006, // 0013 LDCONST R5 K6 + 0x54160003, // 0013 LDINT R5 4 0x7C080600, // 0014 CALL R2 3 0x80000000, // 0015 RET 0 })