diff --git a/CHANGELOG.md b/CHANGELOG.md index 1b2050d403d4..93bafed739bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,23 +3,46 @@ All notable changes to this project will be documented in this file. ## [Unreleased] - Development -## [13.0.0.3] +## [13.0.0.4] ### Added -- Support for MAX17043 fuel-gauge systems Lipo batteries (#18788) -- Support for multiple PCA9685 with extended functionality (#18805) +- ESP32 prepare for Arduino Core v3 and esp-idf v5 (#19264) ### Breaking Changed +### Changed +- Console height from default 318 pixels to viewport (#19241) +- Shutter button hold behaviour with grouptopic (#19263) + +### Fixed + +### Removed + +## [13.0.0.3] 20230805 +### Added +- Support for MAX17043 fuel-gauge systems Lipo batteries (#18788) +- Support for multiple PCA9685 with extended functionality (#18805) +- Zigbee decode Aqara 0000/FF01 attribute 03 as Temperature (#19210) +- Berry bytes `get` and `set` work for 3 bytes values (#19225) +- Matter support for fabric_filtered request (for Google compatibility) (#19249) + ### Changed - Initial ``DisplayMode`` from 1 to 0 and ``DisplayDimmmer`` from 10% to 50% (#19138) -- ESP32 Framework (Core) from v2.0.10 to v2.0.11 -- Berry `mqtt.publish` now distinguishes between `string` and `bytes` +- ESP32 Framework (Arduino Core) from v2.0.10 to v2.0.11 +- Berry `mqtt.publish` now distinguishes between `string` and `bytes` (#19196) +- IRremoteESP8266 library from v2.8.5 to v2.8.6 +- ESP32 autodetect flashsize and adjust filesystem (#19215) +- Reduced log level for TeleInfo (#19216) +- Matter increased polling frequency for local switches/occupancy (#19242) ### Fixed - Initial battery level percentage (#19160) - Berry SK6812_GRBW crash (#19166) - -### Removed +- ESP8266 SPI initialization for scripter, filesystem and MFRC522 (#19209) +- Zero cross dimmer minimum interrupt time (#19211) +- Fade would fail when the difference between start and target would be too small (#19248) +- Inverted shutter (#19243) +- Matter support for large atribute responses (#19252) +- Matter auto-configuration Relay indices (#19255) ## [13.0.0.2] 20230721 ### Added @@ -134,7 +157,7 @@ All notable changes to this project will be documented in this file. ### Added - Matter support for Shutters with Tilt - Matter POC for remote Relay -- Support for Zero-Cross Dimmer on ESP32, changed calculation on EPS8266, high resolution control e.g. Solar: `ZCDimmerSet` +- Support for Zero-Cross Dimmer on ESP32, changed calculation on ESP8266, high resolution control e.g. Solar: `ZCDimmerSet` - ESP32 Enhanced Shutterbuttons functionality to control tilt position, additionally incr/decr possible to position and tilt. - ESP32 command ``Shuttersetup`` for "Shelly 2.5 pro" automatic calibration and setup (experimental) - Berry `tcpclientasync` class for non-blocking TCP client diff --git a/RELEASENOTES.md b/RELEASENOTES.md index 8c1519789fb1..427f29da8751 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -110,7 +110,7 @@ The latter links can be used for OTA upgrades too like ``OtaUrl https://ota.tasm [Complete list](BUILDS.md) of available feature and sensors. -## Changelog v13.0.0.3 +## Changelog v13.0.0.4 ### Added - Command ``BrRestart`` to restart the Berry VM (experimental) [#19003](https://github.com/arendst/Tasmota/issues/19003) - Command ``Delay -1`` to wait until next second [#18984](https://github.com/arendst/Tasmota/issues/18984) @@ -119,37 +119,53 @@ The latter links can be used for OTA upgrades too like ``OtaUrl https://ota.tasm - Support for multiple PCA9685 with extended functionality [#18805](https://github.com/arendst/Tasmota/issues/18805) - Support for SGP41 TVOC/NOx Sensor [#18880](https://github.com/arendst/Tasmota/issues/18880) - Support for DeepSleep battery level percentage [#19134](https://github.com/arendst/Tasmota/issues/19134) +- Zigbee decode Aqara 0000/FF01 attribute 03 as Temperature [#19210](https://github.com/arendst/Tasmota/issues/19210) +- ESP32 prepare for Arduino Core v3 and esp-idf v5 [#19264](https://github.com/arendst/Tasmota/issues/19264) - Berry `getgbl` performance counter to `debug.counters()` [#19070](https://github.com/arendst/Tasmota/issues/19070) - Berry `_class` can be used in `static var` initialization code [#19088](https://github.com/arendst/Tasmota/issues/19088) - Berry `energy.update_total()` to call `EnergyUpdateTotal()` from energy driver [#19117](https://github.com/arendst/Tasmota/issues/19117) - Berry `tasmota.loglevel()` and `tasmota.rtc_utc()` for faster performance [#19152](https://github.com/arendst/Tasmota/issues/19152) - Berry metrics for memory allocation/deallocation/reallocation [#19150](https://github.com/arendst/Tasmota/issues/19150) - Berry AES CCM decrypting in a single call to avoid any object allocation [#19153](https://github.com/arendst/Tasmota/issues/19153) +- Berry bytes `get` and `set` work for 3 bytes values [#19225](https://github.com/arendst/Tasmota/issues/19225) - Partition Wizard is now able to convert to safeboot from Shelly partition layout [#19034](https://github.com/arendst/Tasmota/issues/19034) - Matter option to disable bridge mode [#18992](https://github.com/arendst/Tasmota/issues/18992) - Matter mini-profiler [#19075](https://github.com/arendst/Tasmota/issues/19075) +- Matter support for fabric_filtered request (for Google compatibility) [#19249](https://github.com/arendst/Tasmota/issues/19249) ### Breaking Changed - Berry `bool( [] )` and `bool( {} )` now evaluate as `false` [#18986](https://github.com/arendst/Tasmota/issues/18986) - Berry `import strict` now detects useless expression without side effects [#18997](https://github.com/arendst/Tasmota/issues/18997) ### Changed -- ESP32 Framework (Core) from v2.0.10 to v2.0.11 +- IRremoteESP8266 library from v2.8.5 to v2.8.6 +- ESP32 Framework (Arduino Core) from v2.0.10 to v2.0.11 - ESP32 LVGL library from v8.3.7 to v8.3.8 (no functional change) - Initial ``DisplayMode`` from 1 to 0 and ``DisplayDimmmer`` from 10% to 50% [#19138](https://github.com/arendst/Tasmota/issues/19138) -- Configuration backup and restore now backup and restore ``.xdrvsetXXX`` files too [#18295](https://github.com/arendst/Tasmota/issues/18295) +- Configuration backup and restore now supports ``.xdrvsetXXX`` files too [#18295](https://github.com/arendst/Tasmota/issues/18295) +- Reduced log level for TeleInfo [#19216](https://github.com/arendst/Tasmota/issues/19216) +- Console height from default 318 pixels to viewport [#19241](https://github.com/arendst/Tasmota/issues/19241) +- Shutter button hold behaviour with grouptopic [#19263](https://github.com/arendst/Tasmota/issues/19263) - ESP32 shutter driver support up to 16 shutters [#18295](https://github.com/arendst/Tasmota/issues/18295) +- ESP32 autodetect flashsize and adjust filesystem [#19215](https://github.com/arendst/Tasmota/issues/19215) - Berry extend `range(lower, upper, incr)` to arbitrary increment [#19120](https://github.com/arendst/Tasmota/issues/19120) - Berry updated syntax highlighting plugin for VSCode [#19123](https://github.com/arendst/Tasmota/issues/19123) +- Berry `mqtt.publish` now distinguishes between `string` and `bytes` [#19196](https://github.com/arendst/Tasmota/issues/19196) - Matter support for temperature in Fahrenheit (`SetOption8 1`) [#18987](https://github.com/arendst/Tasmota/issues/18987) - Matter improve responsiveness [#19002](https://github.com/arendst/Tasmota/issues/19002) - Matter improve latency for remote commands [#19072](https://github.com/arendst/Tasmota/issues/19072) - Matter improve latency for single attribute reads and single commands [#19158](https://github.com/arendst/Tasmota/issues/19158) - +- Matter increased polling frequency for local switches/occupancy [#19242](https://github.com/arendst/Tasmota/issues/19242) ### Fixed - Berry Walrus Operator [#18982](https://github.com/arendst/Tasmota/issues/18982) - MiElHVAC power commands regression from v12.4.0.1 [#18923](https://github.com/arendst/Tasmota/issues/18923) +- Zero cross dimmer minimum interrupt time [#19211](https://github.com/arendst/Tasmota/issues/19211) +- Fade would fail when the difference between start and target would be too small [#19248](https://github.com/arendst/Tasmota/issues/19248) +- Inverted shutter [#19243](https://github.com/arendst/Tasmota/issues/19243) +- ESP8266 SPI initialization for scripter, filesystem and MFRC522 [#19209](https://github.com/arendst/Tasmota/issues/19209) +- Matter support for large atribute responses [#19252](https://github.com/arendst/Tasmota/issues/19252) +- Matter auto-configuration Relay indices [#19255](https://github.com/arendst/Tasmota/issues/19255) ### Removed - Support for ESP32-C3 with chip revision below 3 (old development boards) diff --git a/lib/default/TasmotaSerial-3.6.0/src/TasmotaSerial.cpp b/lib/default/TasmotaSerial-3.6.0/src/TasmotaSerial.cpp index 18cfee1e08f2..9bdfb9733e71 100644 --- a/lib/default/TasmotaSerial-3.6.0/src/TasmotaSerial.cpp +++ b/lib/default/TasmotaSerial-3.6.0/src/TasmotaSerial.cpp @@ -39,6 +39,8 @@ TasmotaSerial *tms_obj_list[16]; #ifdef ESP32 #include "driver/uart.h" +#include "driver/gpio.h" +#include "esp_rom_gpio.h" static uint32_t tasmota_serial_uart_bitmap = 0; // Assigned UARTs @@ -466,6 +468,7 @@ size_t TasmotaSerial::write(uint8_t b) { return size; } +#ifdef ESP8266 void IRAM_ATTR TasmotaSerial::rxRead(void) { if (!m_nwmode) { uint32_t start = ESP.getCycleCount(); @@ -586,3 +589,4 @@ void IRAM_ATTR TasmotaSerial::rxRead(void) { } } } +#endif // ESP8266 diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README.md b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README.md index 47178861a86d..5eac39e4b86b 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README.md +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README.md @@ -10,8 +10,8 @@ This library enables you to **send _and_ receive** infra-red signals on an [ESP8266](https://github.com/esp8266/Arduino) or an [ESP32](https://github.com/espressif/arduino-esp32) using the [Arduino framework](https://www.arduino.cc/) using common 940nm IR LEDs and common IR receiver modules. e.g. TSOP{17,22,24,36,38,44,48}* demodulators etc. -## v2.8.5 Now Available -Version 2.8.5 of the library is now [available](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). You can view the [Release Notes](ReleaseNotes.md) for all the significant changes. +## v2.8.6 Now Available +Version 2.8.6 of the library is now [available](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). You can view the [Release Notes](ReleaseNotes.md) for all the significant changes. #### Upgrading from pre-v2.0 Usage of the library has been slightly changed in v2.0. You will need to change your usage to work with v2.0 and beyond. You can read more about the changes required on our [Upgrade to v2.0](https://github.com/crankyoldgit/IRremoteESP8266/wiki/Upgrading-to-v2.0) page. diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_de.md b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_de.md index f558605284f8..9e584bb84b6f 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_de.md +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_de.md @@ -11,8 +11,8 @@ Diese Programmbibliothek ermöglicht das **Senden _und_ Empfangen** von Infrarotsignalen mit [ESP8266](https://github.com/esp8266/Arduino)- und [ESP32](https://github.com/espressif/arduino-esp32)-Mikrocontrollern mithilfe des [Arduino-Frameworks](https://www.arduino.cc/) und handelsüblichen 940nm Infrarot-LEDs undIR-Empfängermodulen, wie zum Beispiel TSOP{17,22,24,36,38,44,48}*-Demodulatoren. -## v2.8.5 jetzt verfügbar -Version 2.8.5 der Bibliothek ist nun [verfügbar](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). Die [Versionshinweise](ReleaseNotes.md) enthalten alle wichtigen Neuerungen. +## v2.8.6 jetzt verfügbar +Version 2.8.6 der Bibliothek ist nun [verfügbar](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). Die [Versionshinweise](ReleaseNotes.md) enthalten alle wichtigen Neuerungen. #### Hinweis für Nutzer von Versionen vor v2.0 Die Benutzung der Bibliothek hat sich mit Version 2.0 leicht geändert. Einige Anpassungen im aufrufenden Code werden nötig sein, um mit Version ab 2.0 korrekt zu funktionieren. Mehr zu den Anpassungen finden sich auf unserer [Upgrade to v2.0](https://github.com/crankyoldgit/IRremoteESP8266/wiki/Upgrading-to-v2.0)-Seite. diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_fr.md b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_fr.md index 430d32de3813..f7bd69eaf838 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_fr.md +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_fr.md @@ -10,8 +10,8 @@ Cette librairie vous permetra de **recevoir et d'envoyer des signaux** infrarouge sur le protocole [ESP8266](https://github.com/esp8266/Arduino) ou sur le protocole [ESP32](https://github.com/espressif/arduino-esp32) en utilisant le [Arduino framework](https://www.arduino.cc/) qui utilise la norme 940nm IR LEDs et le module basique de reception d'onde IR. Exemple : TSOP{17,22,24,36,38,44,48}* modules etc. -## v2.8.5 disponible -Version 2.8.5 de la libraire est maintenant [disponible](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). Vous pouvez voir le [Release Notes](ReleaseNotes.md) pour tous les changements importants. +## v2.8.6 disponible +Version 2.8.6 de la libraire est maintenant [disponible](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). Vous pouvez voir le [Release Notes](ReleaseNotes.md) pour tous les changements importants. #### mise à jour depuis pre-v2.0 L'utilisation de la librairie à un peu changer depuis la version in v2.0. Si vous voulez l'utiliser vous devrez changer votre utilisation aussi. Vous pouvez vous renseigner sur les précondition d'utilisation ici : [Upgrade to v2.0](https://github.com/crankyoldgit/IRremoteESP8266/wiki/Upgrading-to-v2.0) page. diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_nl.md b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_nl.md index fdea85caed18..8c4cb8e08c7e 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_nl.md +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/README_nl.md @@ -10,8 +10,8 @@ Deze library maakt het mogelijk om Infraroodsignalen **te versturen en ontvangen** via het [Arduino framework](https://www.arduino.cc/) met veelgebruikte 940nm IR LEDs en IR ontvang modules. b.v. TSOP{17,22,24,36,38,44,48}* demodulatoren enz. -## v2.8.5 nu beschikbaar -Versie 2.8.5 van de bibliotheek is nu [beschikbaar](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). Bekijk de [Release Notes](ReleaseNotes.md) voor alle belangrijke veranderingen. +## v2.8.6 nu beschikbaar +Versie 2.8.6 van de bibliotheek is nu [beschikbaar](https://github.com/crankyoldgit/IRremoteESP8266/releases/latest). Bekijk de [Release Notes](ReleaseNotes.md) voor alle belangrijke veranderingen. #### Upgraden vanaf pre-v2.0 Het gebruik van de bibliotheek is enigszins gewijzigd in v2.0. Je zult het gebruik moeten aanpassen om te kunnen werken met v2.0 en hoger. Je kunt meer lezen over de vereiste aanpassingen op onze [Upgraden naar v2.0](https://github.com/crankyoldgit/IRremoteESP8266/wiki/Upgrading-to-v2.0) pagina. diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/ReleaseNotes.md b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/ReleaseNotes.md index d9e86c7e3503..27b5b3fac250 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/ReleaseNotes.md +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/ReleaseNotes.md @@ -1,5 +1,23 @@ # Release Notes +## _v2.8.6 (20230727)_ + +**[Bug Fixes]** +- Ensure `IRCoolixAC::toCommon()` returns `kNoTempValue` when no sensor temp is detected. (#2015 #2012) +- Fix compilation dependency of LG on Samsung send protocol (#2011 #2010) +- Fix missing parameter in call to `IRac::gree()` (#2008 #2007) + +**[Features]** +- IRac: Ensure the `sleep` parameter is used for the `FUJITSU_AC` protocol. (#1992 #1991) + +**[Misc]** +- Allow the BlynkIRRemote.ino code to compile again. (#2016) +- do not list WHIRLPOOL_AC unconditionally as supported protocol (#2003) +- IRUtils:typeToString() — simplify (#2002) +- Fix brand Green -> Gree (#1994) +- Fix undefined `std::round` compilation error (#1989) + + ## _v2.8.5 (20230508)_ **[Bug Fixes]** diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/SupportedProtocols.md b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/SupportedProtocols.md index 46b65ca5ef9a..3c6d38a03498 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/SupportedProtocols.md +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/SupportedProtocols.md @@ -1,6 +1,6 @@ + Last generated: Thu 27 Jul 2023 05:37:11 +0000 ---> # IR Protocols supported by this library | Protocol | Brand | Model | A/C Model | Detailed A/C Support | @@ -65,8 +65,7 @@ | [JVC](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_JVC.cpp) | **JVC** | PTU94023B remote | | - | | [Kelon](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelon.cpp) | **[Hisense](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelon.h)** | AST-09UW4RVETG00A A/C (KELON168) | | Yes | | [Kelon](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelon.cpp) | **[Kelon](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelon.h)** | AST-09UW4RVETG00A A/C (KELON168)
DG11R2-01 remote (KELON168)
ON/OFF 9000-12000 (KELON) | | Yes | -| [Kelvinator](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.cpp) | **[Gree](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.h)** | YAP0F8 remote | | Yes | -| [Kelvinator](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.cpp) | **[Green](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.h)** | YAPOF3 remote | | Yes | +| [Kelvinator](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.cpp) | **[Gree](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.h)** | YAP0F8 remote
YAPOF3 remote | | Yes | | [Kelvinator](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.cpp) | **[Kelvinator](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.h)** | KSV26CRC A/C
KSV26HRC A/C
KSV35CRC A/C
KSV35HRC A/C
KSV53HRC A/C
KSV62HRC A/C
KSV70CRC A/C
KSV70HRC A/C
KSV80HRC A/C
YALIF Remote | | Yes | | [Kelvinator](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.cpp) | **[Sharp](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_Kelvinator.h)** | A5VEY A/C
YB1FA remote | | Yes | | [LG](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_LG.cpp) | **[General Electric](https://github.com/crankyoldgit/IRremoteESP8266/blob/master/src/ir_LG.h)** | 6711AR2853M Remote (LG - GE6711AR2853M)
AG1BH09AW101 A/C (LG - GE6711AR2853M) | | Yes | diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/BlynkIrRemote/BlynkIrRemote.ino b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/BlynkIrRemote/BlynkIrRemote.ino index 6e659bd6433f..1948f3c4ccee 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/BlynkIrRemote/BlynkIrRemote.ino +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/BlynkIrRemote/BlynkIrRemote.ino @@ -104,6 +104,8 @@ /* Comment this out to disable prints and save space */ #define BLYNK_PRINT Serial +#define BLYNK_TEMPLATE_ID "TMPL••••••••" // Made up values. Please Change. +#define BLYNK_TEMPLATE_NAME "My First Device" // Please Change. #if defined(ESP8266) #include diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/IRrecvDumpV2/platformio.ini b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/IRrecvDumpV2/platformio.ini index b56304f66b4a..eca7c917e99e 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/IRrecvDumpV2/platformio.ini +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/IRrecvDumpV2/platformio.ini @@ -64,4 +64,9 @@ build_flags = -D_IR_LOCALE_=zh-CN ; Chinese (Simplified) ; Build the library with all protocols disabled to flush out #if/#ifdef issues & ; any compiler warnings, by turning them into errors. [env:shakedown_no_protocols] -build_flags = -D_IR_ENABLE_DEFAULT_=false -Werror -Wno-error=switch +build_flags = + ${env.build_flags} + -Werror + -Wno-error=switch + -Wno-error=switch-unreachable + -D_IR_ENABLE_DEFAULT_=false diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/SmartIRRepeater/platformio.ini b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/SmartIRRepeater/platformio.ini index 0db3d6dc868c..88a7e8a17de5 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/SmartIRRepeater/platformio.ini +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/examples/SmartIRRepeater/platformio.ini @@ -34,4 +34,5 @@ build_flags = ${env.build_flags} -Werror -Wno-error=switch + -Wno-error=switch-unreachable -D_IR_ENABLE_DEFAULT_=false diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.json b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.json index 302372566d0e..60c4811529d5 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.json +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.json @@ -1,6 +1,6 @@ { "name": "IRremoteESP8266", - "version": "2.8.5", + "version": "2.8.6", "keywords": "infrared, ir, remote, esp8266, esp32", "description": "Send and receive infrared signals with multiple protocols (ESP8266/ESP32)", "repository": diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.properties b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.properties index 769cbc1fa355..faed00b7545e 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.properties +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/library.properties @@ -1,5 +1,5 @@ name=IRremoteESP8266 -version=2.8.5 +version=2.8.6 author=David Conran, Sebastien Warin, Mark Szabo, Ken Shirriff maintainer=David Conran, Mark Szabo, Sebastien Warin, Roi Dayan, Massimiliano Pinto, Christian Nilsson sentence=Send and receive infrared signals with multiple protocols (ESP8266/ESP32) diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRac.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRac.cpp index 8826bc1ae913..67c218c1ed52 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRac.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRac.cpp @@ -13,6 +13,11 @@ #include #endif #include +#if __cplusplus >= 201103L && defined(_GLIBCXX_USE_C99_MATH_TR1) + using std::roundf; +#else + using ::roundf; +#endif #include "IRsend.h" #include "IRremoteESP8266.h" #include "IRtext.h" @@ -366,7 +371,9 @@ bool IRac::isProtocolSupported(const decode_type_t protocol) { #if SEND_YORK case decode_type_t::YORK: #endif +#if SEND_WHIRLPOOL_AC case decode_type_t::WHIRLPOOL_AC: +#endif return true; default: return false; @@ -489,9 +496,9 @@ void IRac::argo(IRArgoAC *ac, ac->begin(); ac->setPower(on); ac->setMode(ac->convertMode(mode)); - ac->setTemp(static_cast(std::round(degrees))); + ac->setTemp(static_cast(roundf(degrees))); if (sensorTemp != kNoTempValue) { - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); } ac->setiFeel(iFeel); ac->setFan(ac->convertFan(fan)); @@ -537,7 +544,7 @@ void IRac::argoWrem3_ACCommand(IRArgoAC_WREM3 *ac, const bool on, ac->setMode(ac->convertMode(mode)); ac->setTemp(degrees); if (sensorTemp != kNoTempValue) { - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); } ac->setiFeel(iFeel); ac->setFan(ac->convertFan(fan)); @@ -563,7 +570,7 @@ void IRac::argoWrem3_ACCommand(IRArgoAC_WREM3 *ac, const bool on, void IRac::argoWrem3_iFeelReport(IRArgoAC_WREM3 *ac, const float sensorTemp) { ac->begin(); ac->setMessageType(argoIrMessageType_t::IFEEL_TEMP_REPORT); - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); ac->send(); } @@ -738,7 +745,7 @@ void IRac::coolix(IRCoolixAC *ac, // No Econo setting available. // No Quiet setting available. if (sensorTemp != kNoTempValue) { - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); } else { ac->clearSensorTemp(); } @@ -1128,7 +1135,7 @@ void IRac::ecoclim(IREcoclimAc *ac, ac->setTemp(degrees); ac->setFan(ac->convertFan(fan)); if (sensorTemp != kNoTempValue) { - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); } else { ac->setSensorTemp(degrees); //< Set to the desired temp // until we can disable. @@ -1174,7 +1181,7 @@ void IRac::electra(IRElectraAc *ac, ac->setMode(ac->convertMode(mode)); ac->setTemp(degrees); if (sensorTemp != kNoTempValue) { - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); } ac->setFan(ac->convertFan(fan)); ac->setSwingV(swingv != stdAc::swingv_t::kOff); @@ -2288,7 +2295,7 @@ void IRac::sanyo(IRSanyoAc *ac, ac->setMode(ac->convertMode(mode)); ac->setTemp(degrees); if (sensorTemp != kNoTempValue) { - ac->setSensorTemp(static_cast(std::round(sensorTemp))); + ac->setSensorTemp(static_cast(roundf(sensorTemp))); } else { ac->setSensorTemp(degrees); // Set the sensor temp to the desired // (normal) temp. @@ -3229,7 +3236,7 @@ bool IRac::sendAc(const stdAc::state_t desired, const stdAc::state_t *prev) { fujitsu(&ac, (fujitsu_ac_remote_model_t)send.model, send.power, send.mode, send.celsius, send.degrees, send.fanspeed, send.swingv, send.swingh, send.quiet, - send.turbo, send.econo, send.filter, send.clean); + send.turbo, send.econo, send.filter, send.clean, send.sleep); break; } #endif // SEND_FUJITSU_AC @@ -3249,7 +3256,8 @@ bool IRac::sendAc(const stdAc::state_t desired, const stdAc::state_t *prev) { _modulation); gree(&ac, (gree_ac_remote_model_t)send.model, send.power, send.mode, send.celsius, send.degrees, send.fanspeed, send.swingv, send.swingh, - send.turbo, send.econo, send.light, send.clean, send.sleep); + send.iFeel, send.turbo, send.econo, send.light, send.clean, + send.sleep); break; } #endif // SEND_GREE diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRrecv.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRrecv.cpp index ecb8a382bf15..173526104b67 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRrecv.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRrecv.cpp @@ -412,10 +412,6 @@ void IRrecv::pause(void) { params.rcvstate = kStopState; params.rawlen = 0; params.overflow = false; -#if defined(ESP8266) - os_timer_disarm(&timer); - detachInterrupt(params.recvpin); -#endif #if defined(ESP32) gpio_intr_disable((gpio_num_t)params.recvpin); #endif // ESP32 @@ -429,10 +425,6 @@ void IRrecv::resume(void) { params.rcvstate = kIdleState; params.rawlen = 0; params.overflow = false; -#if defined(ESP8266) - os_timer_setfn(&timer, reinterpret_cast(read_timeout),NULL); - attachInterrupt(params.recvpin, gpio_intr, CHANGE); -#endif #if defined(ESP32) timerAlarmDisable(timer); gpio_intr_enable((gpio_num_t)params.recvpin); diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRremoteESP8266.h b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRremoteESP8266.h index 133d507b8e92..949de1ecf408 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRremoteESP8266.h +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRremoteESP8266.h @@ -58,7 +58,7 @@ // Minor version number (x.X.x) #define _IRREMOTEESP8266_VERSION_MINOR 8 // Patch version number (x.x.X) -#define _IRREMOTEESP8266_VERSION_PATCH 5 +#define _IRREMOTEESP8266_VERSION_PATCH 6 // Macro to convert version info into an integer #define _IRREMOTEESP8266_VERSION_VAL(major, minor, patch) \ (((major) << 16) | ((minor) << 8) | (patch)) diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRsend.h b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRsend.h index f8a447197e79..38491372aa5d 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRsend.h +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRsend.h @@ -310,11 +310,12 @@ class IRsend { void sendSherwood(uint64_t data, uint16_t nbits = kSherwoodBits, uint16_t repeat = kSherwoodMinRepeat); #endif -#if SEND_SAMSUNG + // `sendSAMSUNG()` is required by `sendLG()` +#if (SEND_SAMSUNG || SEND_LG) void sendSAMSUNG(const uint64_t data, const uint16_t nbits = kSamsungBits, const uint16_t repeat = kNoRepeat); uint32_t encodeSAMSUNG(const uint8_t customer, const uint8_t command); -#endif +#endif // (SEND_SAMSUNG || SEND_LG) #if SEND_SAMSUNG36 void sendSamsung36(const uint64_t data, const uint16_t nbits = kSamsung36Bits, const uint16_t repeat = kNoRepeat); diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRutils.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRutils.cpp index 4c713c87b4af..e9af0b28fe00 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRutils.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/IRutils.cpp @@ -145,16 +145,12 @@ String typeToString(const decode_type_t protocol, const bool isRepeat) { result = kUnknownStr; } else { auto *ptr = reinterpret_cast(kAllProtocolNamesStr); - if (protocol > kLastDecodeType || protocol == decode_type_t::UNKNOWN) { - result = kUnknownStr; - } else { - for (uint16_t i = 0; i <= protocol && STRLEN(ptr); i++) { - if (i == protocol) { - result = FPSTR(ptr); - break; - } - ptr += STRLEN(ptr) + 1; + for (uint16_t i = 0; i <= protocol && STRLEN(ptr); i++) { + if (i == protocol) { + result = FPSTR(ptr); + break; } + ptr += STRLEN(ptr) + 1; } } if (isRepeat) { diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Coolix.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Coolix.cpp index 3fb4e8d0a520..6769ebb79d0e 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Coolix.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Coolix.cpp @@ -549,6 +549,9 @@ stdAc::state_t IRCoolixAC::toCommon(const stdAc::state_t *prev) const { result.mode = toCommonMode(getMode()); result.degrees = getTemp(); result.sensorTemperature = getSensorTemp(); + if (result.sensorTemperature == kCoolixSensorTempIgnoreCode) { + result.sensorTemperature = kNoTempValue; + } result.iFeel = getZoneFollow(); result.fanspeed = toCommonFanSpeed(getFan()); return result; diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Kelvinator.h b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Kelvinator.h index 32cb3e1fa0ea..342c60592d9e 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Kelvinator.h +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Kelvinator.h @@ -13,7 +13,7 @@ // Brand: Kelvinator, Model: KSV70CRC A/C // Brand: Kelvinator, Model: KSV70HRC A/C // Brand: Kelvinator, Model: KSV80HRC A/C -// Brand: Green, Model: YAPOF3 remote +// Brand: Gree, Model: YAPOF3 remote // Brand: Gree, Model: YAP0F8 remote // Brand: Sharp, Model: YB1FA remote // Brand: Sharp, Model: A5VEY A/C diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Samsung.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Samsung.cpp index b3fe2a860106..958f2665bdd7 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Samsung.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/src/ir_Samsung.cpp @@ -82,7 +82,8 @@ using irutils::addTempToString; using irutils::addToggleToString; using irutils::minsToString; -#if SEND_SAMSUNG +// This sending protocol is used by some other protocols. e.g. LG. +#if (SEND_SAMSUNG || SEND_LG) /// Send a 32-bit Samsung formatted message. /// Status: STABLE / Should be working. /// @param[in] data The message to be sent. @@ -112,7 +113,7 @@ uint32_t IRsend::encodeSAMSUNG(const uint8_t customer, const uint8_t command) { return ((revcommand ^ 0xFF) | (revcommand << 8) | (revcustomer << 16) | (revcustomer << 24)); } -#endif +#endif // (SEND_SAMSUNG || SEND_LG) #if DECODE_SAMSUNG /// Decode the supplied Samsung 32-bit message. diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/IRac_test.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/IRac_test.cpp index 32a745a31199..8d6274c65da2 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/IRac_test.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/IRac_test.cpp @@ -669,7 +669,8 @@ TEST(TestIRac, Fujitsu) { false, // Turbo (Powerful) false, // Econo true, // Filter - true); // Clean + true, // Clean + -1); // Sleep ASSERT_EQ(ardb1_expected, ac.toString()); ac._irsend.makeDecodeResult(); EXPECT_TRUE(capture.decode(&ac._irsend.capture)); @@ -719,7 +720,8 @@ TEST(TestIRac, Fujitsu) { false, // Turbo (Powerful) false, // Econo true, // Filter - true); // Clean + true, // Clean + -1); // Sleep ASSERT_EQ(arry4_expected, ac.toString()); ac._irsend.makeDecodeResult(); EXPECT_TRUE(capture.decode(&ac._irsend.capture)); @@ -742,8 +744,9 @@ TEST(TestIRac, Fujitsu) { false, // Quiet false, // Turbo (Powerful) false, // Econo - false, // Filter - false); // Clean + false, // Filter + false, // Clean + -1); // Sleep ASSERT_EQ(arrew4e_expected, ac.toString()); ac._irsend.makeDecodeResult(); EXPECT_TRUE(capture.decode(&ac._irsend.capture)); diff --git a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/ir_Coolix_test.cpp b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/ir_Coolix_test.cpp index ba3610bc7f02..101fab654670 100644 --- a/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/ir_Coolix_test.cpp +++ b/lib/lib_basic/IRremoteESP8266/IRremoteESP8266/test/ir_Coolix_test.cpp @@ -492,6 +492,9 @@ TEST(TestCoolixACClass, SetGetClearSensorTempAndZoneFollow) { EXPECT_EQ( "Power: On, Mode: 3 (Heat), Fan: 6 (Zone Follow), Temp: 24C, " "Zone Follow: On, Sensor Temp: 19C", ac.toString()); + // For #Issue2012 + EXPECT_EQ(19, ac.getSensorTemp()); + EXPECT_EQ(19, ac.toCommon().sensorTemperature); } TEST(TestCoolixACClass, SpecialModesAndReset) { @@ -1068,3 +1071,36 @@ TEST(TestDecodeCoolix48, SyntheticSelfDecode) { "m552s5244", irsend.outputStr()); } + +// Test for issue https://github.com/crankyoldgit/IRremoteESP8266/issues/2012#issuecomment-1650098971 +TEST(TestCoolixACClass, Issue2012) { + IRrecv irrecv(kGpioUnused); + IRCoolixAC ac(kGpioUnused); + + ac.stateReset(); + ac.setRaw(0xB21FD8); + EXPECT_EQ( + "Power: On, Mode: 2 (Auto), Fan: 0 (Auto0), Temp: 26C, " + "Zone Follow: Off, Sensor Temp: Off", + ac.toString()); + EXPECT_EQ(kNoTempValue, ac.toCommon().sensorTemperature); + + ac.setRaw(0xB21F98); + EXPECT_EQ( + "Power: On, Mode: 2 (Auto), Fan: 0 (Auto0), Temp: 27C, " + "Zone Follow: Off, Sensor Temp: Off", + ac.toString()); + EXPECT_EQ(kNoTempValue, ac.toCommon().sensorTemperature); + + ac.setRaw(0xB21F88); + EXPECT_EQ( + "Power: On, Mode: 2 (Auto), Fan: 0 (Auto0), Temp: 28C, " + "Zone Follow: Off, Sensor Temp: Off", + ac.toString()); + EXPECT_EQ(kNoTempValue, ac.toCommon().sensorTemperature); + ac.setRaw(0xB27BE0); + EXPECT_EQ( + "Power: Off", + ac.toString()); + EXPECT_EQ(kNoTempValue, ac.toCommon().sensorTemperature); +} diff --git a/lib/lib_basic/IRremoteESP8266/library.json b/lib/lib_basic/IRremoteESP8266/library.json index 476000469410..87c32e6870b2 100644 --- a/lib/lib_basic/IRremoteESP8266/library.json +++ b/lib/lib_basic/IRremoteESP8266/library.json @@ -1,6 +1,6 @@ { "name": "IRremoteESP8266", - "version": "2.8.5", + "version": "2.8.6", "keywords": "infrared, ir, remote, esp8266, esp32", "description": "Send and receive infrared signals with multiple protocols (ESP8266/ESP32)", "repository": diff --git a/lib/lib_i2c/DFRobot_MAX17043/DFRobot_MAX17043.cpp b/lib/lib_i2c/DFRobot_MAX17043/DFRobot_MAX17043.cpp deleted file mode 100644 index b24f686af68c..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/DFRobot_MAX17043.cpp +++ /dev/null @@ -1,68 +0,0 @@ -/*! - * @file DFRobot_MAX17043.cpp - * - * @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - * @license The MIT License (MIT) - * @author [ouki.wang](ouki.wang@dfrobot.com) - * @version V1.0 - * @date 2018-4-14 - * @url https://github.com/DFRobot/DFRobot_MAX17043 - */ - -#include "DFRobot_MAX17043.h" - -DFRobot_MAX17043::DFRobot_MAX17043() {} - -int DFRobot_MAX17043::begin() -{ - // write16(MAX17043_COMMAND, 0x0054); //power on reset - write16(MAX17043_COMMAND, 0x5400); //power on reset - delay(10); - _DBG_CODE(Serial.print("\nbegin: ")); - _DBG_CODE(Serial.println(read16(MAX17043_CONFIG), HEX)); - if(read16(MAX17043_CONFIG) == 0x971c) { //default 0x971c - write16(MAX17043_MODE, 0x4000); //quick start - write16(MAX17043_CONFIG, 0x9700); - _DBG_CODE(Serial.println(read16(MAX17043_CONFIG), HEX)); - delay(10); - return 0; - } - return -1; -} - -float DFRobot_MAX17043::readVoltage() -{ - return (1.25f * (float)(read16(MAX17043_VCELL) >> 4)); -} - -float DFRobot_MAX17043::readPercentage() -{ - uint16_t per = read16(MAX17043_SOC); - return (float)((per >> 8) + 0.003906f * (per & 0x00ff)); -} - -void DFRobot_MAX17043::setInterrupt(uint8_t per) -{ - uint16_t temp; - if(per > 32) - temp = 32; - else if(per < 1) - temp = 1; - temp = 32 - temp; - writeRegBits(MAX17043_CONFIG, temp, 0x01f, 0); -} - -void DFRobot_MAX17043::clearInterrupt() -{ - writeRegBits(MAX17043_CONFIG, 0, 0x01, 5); -} - -void DFRobot_MAX17043::setSleep() -{ - writeRegBits(MAX17043_CONFIG, 1, 0x01, 7); -} - -void DFRobot_MAX17043::setWakeUp() -{ - writeRegBits(MAX17043_CONFIG, 0, 0x01, 7); -} diff --git a/lib/lib_i2c/DFRobot_MAX17043/DFRobot_MAX17043.h b/lib/lib_i2c/DFRobot_MAX17043/DFRobot_MAX17043.h deleted file mode 100644 index f4147ba6988c..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/DFRobot_MAX17043.h +++ /dev/null @@ -1,121 +0,0 @@ -/*! - * @file DFRobot_MAX17043.h - * - * @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - * @license The MIT License (MIT) - * @author [ouki.wang](ouki.wang@dfrobot.com) - * @version V1.0 - * @date 2018-4-14 - * @url https://github.com/DFRobot/DFRobot_MAX17043 - */ - -#ifndef __DFROBOT_MAX17043_H -#define __DFROBOT_MAX17043_H - -#include "Arduino.h" -#include "Wire.h" - -#define _DBG 0 - -#if(_DBG) - #define _DBG_CODE(x) x -#else - #define _DBG_CODE(x) -#endif - -#define MAX17043_ADDRESS 0x36 - -#define MAX17043_VCELL 0x02 -#define MAX17043_SOC 0x04 -#define MAX17043_MODE 0x06 -#define MAX17043_VERSION 0x08 -#define MAX17043_CONFIG 0x0c -#define MAX17043_COMMAND 0xfe - -class DFRobot_MAX17043 { -public: - /** - * @fn DFRobot_MAX17043 - * @brief create MAX17043 object - * @return MAX17043 object - */ - DFRobot_MAX17043(); - /** - * @fn begin - * @brief MAX17043 begin and test moudle - * - * @return initialization result - * @retval 0 successful - * @retval -1 faild - */ - int begin(); - /** - * @fn readVoltage - * @brief read battery voltage in mV - * @return voltage in mV - */ - float readVoltage(); - /** - * @fn readPercentage - * @brief read battery remaining capacity in percentage - * - * @return battery remaining capacity in percentage - */ - float readPercentage(); - /** - * @fn setInterrupt - * @brief set MAX17043 interrput threshold - * - * @param per interrupt threshold as %1 - 32% (integer) - */ - void setInterrupt(uint8_t per); - /** - * @fn clearInterrupt - * @brief clear MAX17043 interrupt - */ - void clearInterrupt(); - /** - * @fn setSleep - * @brief set MAX17043 in sleep mode - * - */ - void setSleep(); - /** - * @fn setWakeUp - * @brief weak up MAX17043 - * - */ - void setWakeUp(); - - private: - void write16(uint8_t reg, uint16_t dat) { - Wire.begin(); - Wire.beginTransmission(MAX17043_ADDRESS); - Wire.write(reg); - Wire.write(dat >> 8); - Wire.write(dat); - Wire.endTransmission(); - } - - uint16_t read16(uint8_t reg) { - uint16_t temp; - Wire.begin(); - Wire.beginTransmission(MAX17043_ADDRESS); - Wire.write(reg); - Wire.endTransmission(); - Wire.requestFrom(MAX17043_ADDRESS, 2); - temp = (uint16_t)Wire.read() << 8; - temp |= (uint16_t)Wire.read(); - Wire.endTransmission(); - return temp; - } - - void writeRegBits(uint8_t reg, uint16_t dat, uint16_t bits, uint8_t offset) { - uint16_t temp; - temp = read16(reg); - temp = (temp & (~(bits << offset))) | (dat << offset); - write16(reg, temp); - } -}; - -#endif diff --git a/lib/lib_i2c/DFRobot_MAX17043/LICENSE b/lib/lib_i2c/DFRobot_MAX17043/LICENSE deleted file mode 100644 index 79f310082f42..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/LICENSE +++ /dev/null @@ -1,7 +0,0 @@ -Copyright 2010 DFRobot Co.Ltd - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/lib/lib_i2c/DFRobot_MAX17043/README_CN.md b/lib/lib_i2c/DFRobot_MAX17043/README_CN.md deleted file mode 100644 index 85d1f9c878bf..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/README_CN.md +++ /dev/null @@ -1,121 +0,0 @@ -# DFRobot_MAX17043 - -* [English Version](./README.md) - -Gravity 3.7V锂电池电量计使用Gravity I2C接口,超低工作电流,通过Maxim专利算法,实时跟踪电池的相对充电状态(SOC,State-Of-Charge),无需充放电学习过程,无积累误差,即插即用,准确地测量锂电池的当前电压和剩余电量。模块预留低电量报警中断引脚,当电池电量低于指定电量时,该引脚产生一个下跳脉冲,触发主控的外部中断。 - -![产品效果图](./resources/images/DFR0563.jpg) - - -## 产品链接([https://www.dfrobot.com.cn/goods-1743.html](https://www.dfrobot.com.cn/goods-1743.html)) - SKU: DFR0563 - -## 目录 - -* [概述](#概述) -* [连接](连接) -* [库安装](#库安装) -* [方法](#方法) -* [兼容性](#兼容性) -* [历史](#历史) -* [创作者](#创作者) - -## 概述 - -提供 Arduino 库,用于通过 I2C 读取和解释 MAX17043 数据。 - -## 连接 -相同颜色的线连接在一起,我们只举例说明主板是如何连接到电量计的。接线时要注意管脚的对应关系,接线图如下: - -* Arduino UNO -
- -
- -* ESP32 -
- -
- - -## 库安装 - -这里有2种安装方法: -1. 使用此库前,请首先下载库文件,将其粘贴到\Arduino\libraries目录中,然后打开examples文件夹并在该文件夹中运行演示。 -2. 直接在Arduino软件库管理中搜索下载 DFRobot_MAX17043 库 - -## 方法 - -```C++ - /** - * @fn DFRobot_MAX17043 - * @brief 构造MAX17043对象 - * @return MAX17043 类对象 - */ - DFRobot_MAX17043(); - /** - * @fn begin - * @brief MAX17043 初始化 - * - * @return 初始化结果 - * @retval 0 成功 - * @retval -1 失败 - */ - int begin(); - /** - * @fn readVoltage - * @brief 读电池电压,单位: mV - * @return 电池电压,单位:mV - */ - float readVoltage(); - /** - * @fn readPercentage - * @brief 读取剩余电池容量的百分比 - * - * @return 剩余电池容量的百分比 - */ - float readPercentage(); - /** - * @fn setInterrupt - * @brief 设置 MAX17043 中断阈值 - * - * @param per 中断阈值范围: %1 - 32% (整数) - */ - void setInterrupt(uint8_t per); - /** - * @fn clearInterrupt - * @brief 清除 MAX17043 中断 - */ - void clearInterrupt(); - /** - * @fn setSleep - * @brief 设置 MAX17043 进入睡眠模式 - * - */ - void setSleep(); - /** - * @fn setWakeUp - * @brief 唤醒 MAX17043 - */ - void setWakeUp(); -``` - -## 兼容性 - -| MCU | Work Well | Work Wrong | Untested | Remarks | -| ------------------ | :-------: | :--------: | :------: | ------- | -| FireBeetle-ESP32 | √ | | | -| FireBeetle-ESP8266 | √ | | | -| Arduino uno | √ | | | - -## 历史 - -- 2018/04/14 - 1.0.0 版本 - -## 创作者 - -Written by ouki.wang(ouki.wang@dfrobot.com), 2018. (Welcome to our [website](https://www.dfrobot.com/)) - - - - diff --git a/lib/lib_i2c/DFRobot_MAX17043/examples/DFRobot_MAX17043/DFRobot_MAX17043.ino b/lib/lib_i2c/DFRobot_MAX17043/examples/DFRobot_MAX17043/DFRobot_MAX17043.ino deleted file mode 100644 index 746f166fe1c9..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/examples/DFRobot_MAX17043/DFRobot_MAX17043.ino +++ /dev/null @@ -1,74 +0,0 @@ -/*! - * @file DFRobot_MAX17043.ino - * @brief connect gauge I2C interface with your board (please reference board compatibility) - * @n Voltage, percentage will be printed via serial. - * @n Use API to config alaram and sleep (please reference to the readme in lib) - * - * @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - * @license The MIT License (MIT) - * @author [ouki.wang](ouki.wang@dfrobot.com) - * @version V1.0 - * @date 2018-4-14 - * @url https://github.com/DFRobot/DFRobot_MAX17043 - */ - -#include "DFRobot_MAX17043.h" -#include "Wire.h" - -#ifdef __AVR__ - #define ALR_PIN 2 -#else - #define ALR_PIN D2 -#endif - -#define PRINT_INTERVAL 2000 - -DFRobot_MAX17043 gauge; -uint8_t intFlag = 0; - -void interruptCallBack() -{ - intFlag = 1; -} - -void setup() -{ - Serial.begin(115200); - while(!Serial); - Serial.println(); - Serial.println(); - pinMode(ALR_PIN, INPUT_PULLUP); - attachInterrupt(ALR_PIN, interruptCallBack, FALLING); //default alert is 32% - - while(gauge.begin() != 0) { - Serial.println("gauge begin faild!"); - delay(2000); - } - delay(2); - Serial.println("gauge begin successful!"); - //gauge.setInterrupt(32); //use this to modify alert threshold as 1% - 32% (integer) -} - -void loop() -{ - static unsigned long lastMillis = 0; - if((millis() - lastMillis) > PRINT_INTERVAL) { - lastMillis = millis(); - Serial.println(); - - Serial.print("voltage: "); - Serial.print(gauge.readVoltage()); - Serial.println(" mV"); - - Serial.print("precentage: "); - Serial.print(gauge.readPercentage()); - Serial.println(" %"); - } - - if(intFlag == 1) { - intFlag = 0; - gauge.clearInterrupt(); - Serial.println("Low power alert interrupt!"); - //put your battery low power alert interrupt service routine here - } -} diff --git a/lib/lib_i2c/DFRobot_MAX17043/keywords.txt b/lib/lib_i2c/DFRobot_MAX17043/keywords.txt deleted file mode 100644 index bcb479a57948..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/keywords.txt +++ /dev/null @@ -1,9 +0,0 @@ -DFRobot_MAX17043 KEYWORD1 - -begin KEYWORD2 -readVoltage KEYWORD2 -readPercentage KEYWORD2 -setInterrupt KEYWORD2 -clearInterrupt KEYWORD2 -setSleep KEYWORD2 -setWakeUp KEYWORD2 \ No newline at end of file diff --git a/lib/lib_i2c/DFRobot_MAX17043/library.properties b/lib/lib_i2c/DFRobot_MAX17043/library.properties deleted file mode 100644 index c769e3bef282..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/library.properties +++ /dev/null @@ -1,9 +0,0 @@ -name=DFRobot_MAX17043 -version=1.0.0 -author=DFRobot -maintainer=ouki.wang -sentence=DFRobot Standard library(SKU:DFR0563). -paragraph=Gravity: I2C 3.7V Li Battery Fuel Gauge. -category=Sensors -url=https://github.com/DFRobot/DFRobot_MAX17043 -architectures=* diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/DFRobot_MAX17043.py b/lib/lib_i2c/DFRobot_MAX17043/python/micropython/DFRobot_MAX17043.py deleted file mode 100644 index b7ac8b9e8ba0..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/DFRobot_MAX17043.py +++ /dev/null @@ -1,111 +0,0 @@ -'''! - @file DFRobot_MAX17043.py - @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - @license The MIT License (MIT) - @author [ouki.wang](ouki.wang@dfrobot.com) - @version V1.0 - @date 2018-4-14 - @url https://github.com/DFRobot/DFRobot_MAX17043 -''' - -import time - -from machine import I2C, Pin - -## Get I2C bus -i2c = I2C(scl = Pin(22), sda = Pin(21), freq=400000) - -MAX17043_ADDR = 0x36 -MAX17043_VCELL = 0x02 -MAX17043_SOC = 0x04 -MAX17043_MODE = 0x06 -MAX17043_VERSION = 0x08 -MAX17043_CONFIG = 0x0c -MAX17043_COMMAND = 0xfe - -class DFRobot_MAX17043(): - - def __init__(self): - '''! - @brief create MAX17043 object - @return MAX17043 object - ''' - pass - - def begin(self): - '''! - @brief MAX17043 begin and test moudle - @return initialization result: - @retval 0 successful - @retval -1 faild - ''' - self._write16(MAX17043_COMMAND, 0x5400) - time.sleep(0.01) - if self._read16(MAX17043_CONFIG) == 0x971c: - self._write16(MAX17043_MODE, 0x4000) - time.sleep(0.01) - self._write16(MAX17043_CONFIG, 0x9700) - return 0 - else: - return -1 - - def read_voltage(self): - '''! - @brief read battery voltage in mV - @return voltage in mV - ''' - return (1.25 * (self._read16(MAX17043_VCELL) >> 4)) - - def read_percentage(self): - '''! - @brief read battery remaining capacity in percentage - @return battery remaining capacity in percentage - ''' - tmp = self._read16(MAX17043_SOC) - return ((tmp >> 8) + 0.003906 * (tmp & 0x00ff)) - - def set_Interrupt(self, per): - '''! - @brief set MAX17043 interrput threshold - @param per interrupt threshold as %1 - 32% (integer) - ''' - if per > 32: - per = 32 - elif per < 1: - per = 1 - per = 32 - int(per) - self._write_reg_bits(MAX17043_CONFIG, per, 0x01f, 0) - - def clear_interrupt(self): - '''! - @brief clear MAX17043 interrupt. - ''' - self._write_reg_bits(MAX17043_CONFIG, 0, 0x01, 5) - - def set_sleep(self): - '''! - @brief set MAX17043 in sleep mode. - ''' - self._write_reg_bits(MAX17043_CONFIG, 1, 0x01, 7) - - def set_wakeup(self): - '''! - @brief wake up MAX17043. - ''' - self._write_reg_bits(MAX17043_CONFIG, 0, 0x01, 7) - - def _write16(self, reg, dat): - buf = bytearray(2) - buf[0] = dat >> 8 - buf[1] = dat & 0x00ff - i2c.writeto_mem(MAX17043_ADDR, reg, buf) - - def _read16(self, reg): - buf = i2c.readfrom_mem(MAX17043_ADDR, reg, 2) - return ((buf[0] << 8) | buf[1]) - - def _write_reg_bits(self, reg, dat, bits, offset): - tmp = self._read16(reg) - tmp = (tmp & (~(bits << offset))) | (dat << offset) - self._write16(reg, tmp) - diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/README.md b/lib/lib_i2c/DFRobot_MAX17043/python/micropython/README.md deleted file mode 100644 index 106363df48c9..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/README.md +++ /dev/null @@ -1,100 +0,0 @@ -# DFRobot_MAX17043 - -* [中文版](./README_CN.md) - -The MAX17043 is ultra-compact, low-cost,host-side fuel-gauge systems for lithium-ion (Li+) batter-ies in handheld and portable -equpiment.It employs Gravity I2C interface,ultra-low opearting current, and real-time tracking of the relative state of charge -(SOC) of the battery through Maxim's patented algorithm,eliminating the need for full-to-empty relearning and offset accumualtion -errors.Plug and play to accurately measure the voltage and remaining power of the battery. The module also features as a low -battery power alert interrupt function. When the battery power falls below specified threshold, the ALR pin generates a falling -pluse to trigger the external interrupt of the controller.One thing should mention that the default value of the battery low power -interrupt alert threshold is 32%, this threshold can be set by the function set_interrupt(). - -![产品效果图](../../resources/images/DFR0563.jpg) - -## Product Link([https://www.dfrobot.com/product-1734.html](https://www.dfrobot.com/product-1734.html)) - SKU: DFR0563 - -## Table of Contents -* [Summary](#summary) -* [connection](connection) -* [Installation](#installation) -* [Methods](#methods) -* [Compatibility](#compatibility) -* [History](#history) -* [Credits](#credits) - -## Summary -Provides a microPython library for reading and interperting MAX17043 data over I2C. - -## Connection -Wires of the same color are linked together,and We only exemplify how this board is connected to the Fuel Gauge. -When connecting , it is necessary to pay attention to the correspondence among pins, the connection diagram is as fellows. - -* ESP32 - -
- -
- - -## Installation - -To use this library download the zip file, uncomperss it to a folder named DFRobot_MAX17043 in your upyCraft workspace. - -## Methods - -```python - '''! - @brief MAX17043 begin and test moudle - @return initialization result: - @retval 0 successful - @retval -1 faild - ''' - def begin(self): - - '''! - @brief read battery voltage in mV - @return voltage in mV - ''' - def read_voltage(self): - - '''! - @brief read battery remaining capacity in percentage - @return battery remaining capacity in percentage - ''' - def read_percentage(self): - '''! - @brief set MAX17043 interrput threshold - @param per interrupt threshold as %1 - 32% (integer) - ''' - def set_interrupt(self, per): - - '''! - @brief clear MAX17043 interrupt. - ''' - def clear_interrupt(self): - - '''! - @brief set MAX17043 in sleep mode. - ''' - def set_sleep(self): - - '''! - @brief wake up MAX17043. - ''' - -``` -## Compatibility - -| MCU | Work Well | Work Wrong | Untested | Remarks | -| ------------------ | :-------: | :--------: | :------: | ------- | -| ESP32 | √ | | | - -## History - -- 2018/04/14 - Version 1.0.0 released. - -## Credits - -Written by ouki.wang(ouki.wang@dfrobot.com), 2018. (Welcome to our [website](https://www.dfrobot.com/)) diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/README_CN.md b/lib/lib_i2c/DFRobot_MAX17043/python/micropython/README_CN.md deleted file mode 100644 index 48af8058c065..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/README_CN.md +++ /dev/null @@ -1,97 +0,0 @@ -# DFRobot_MAX17043 - -* [English Version](./README.md) - -Gravity 3.7V锂电池电量计使用Gravity I2C接口,超低工作电流,通过Maxim专利算法,实时跟踪电池的相对充电状态(SOC,State-Of-Charge),无需充放电学习过程,无积累误差,即插即用,准确地测量锂电池的当前电压和剩余电量。模块预留低电量报警中断引脚,当电池电量低于指定电量时,该引脚产生一个下跳脉冲,触发主控的外部中断。 - -![产品效果图](../../resources/images/DFR0563.jpg) - - -## 产品链接([https://www.dfrobot.com.cn/goods-1743.html](https://www.dfrobot.com.cn/goods-1743.html)) - SKU: DFR0563 - -## 目录 - -* [概述](#概述) -* [连接](连接) -* [库安装](#库安装) -* [方法](#方法) -* [兼容性](#兼容性) -* [历史](#历史) -* [创作者](#创作者) - -## 概述 -提供 microPython 库,用于通过 I2C 读取和解释 MAX17043 数据 - -## 连接 -相同颜色的线连接在一起,我们只举例说明主板是如何连接到电量计的。接线时要注意管脚的对应关系,接线图如下: - -* ESP32 - -
- -
- - -## 库安装 - -要使用此库,请下载 zip 文件,将其解压缩到 upyCraft 工作区中名为 DFRobot_MAX17043 的文件夹中。 - -## 方法 - -```python - '''! - @brief 构造MAX17043对象 - @return MAX17043 初始化 - @retval 0 成功 - @retval -1 失败 - ''' - def begin(self): - - '''! - @brief 读电池电压,单位: mV - @return 电池电压,单位:mV - ''' - def read_voltage(self): - - '''! - @brief 读取剩余电池容量的百分比 - @return 剩余电池容量的百分比 - ''' - def read_percentage(self): - '''! - @brief 设置 MAX17043 中断阈值 - @param per 中断阈值范围: %1 - 32% (整数) - ''' - def set_interrupt(self, per): - - '''! - @brief 清除 MAX17043 中断. - ''' - def clear_interrupt(self): - - '''! - @brief 设置 MAX17043 进入睡眠模式 - ''' - def set_sleep(self): - - '''! - @brief 唤醒 MAX17043 - ''' - def set_wakeup(self): -``` - -## 兼容性 - -| MCU | Work Well | Work Wrong | Untested | Remarks | -| ------------------ | :-------: | :--------: | :------: | ------- | -| ESP32 | √ | | | - -## 历史 - -- 2018/04/14 - 1.0.0 版本 - -## 创作者 - -Written by ouki.wang(ouki.wang@dfrobot.com), 2018. (Welcome to our [website](https://www.dfrobot.com/)) - diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/demo_MAX17043.py b/lib/lib_i2c/DFRobot_MAX17043/python/micropython/demo_MAX17043.py deleted file mode 100644 index d6d5e2f549a5..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/micropython/demo_MAX17043.py +++ /dev/null @@ -1,38 +0,0 @@ -'''! - @file demo_MAX17043.py - @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - @license The MIT License (MIT) - @author [ouki.wang](ouki.wang@dfrobot.com) - @version V1.0 - @date 2018-4-14 - @url https://github.com/DFRobot/DFRobot_MAX17043 -''' - -import time -from machine import Pin -from DFRobot_MAX17043 import DFRobot_MAX17043 - -gauge = DFRobot_MAX17043() - -def interruptCallBack(channel): - gauge.clear_interrupt() - print('Low power alert interrupt!') - #put your battery low power alert interrupt service routine here - -pin_irq = Pin(25, Pin.IN) -pin_irq.irq(trigger = Pin.IRQ_FALLING, handler = interruptCallBack) - -rslt = gauge.begin() - -while rslt != 0: - print('gauge begin faild') - time.sleep(2) - rslt = gauge.begin() - -#gauge.set_Interrupt(32) #use this to modify alert threshold as 1% - 32% (integer) -print('gauge begin successful') - -while True: - time.sleep(2) - print('voltage: ' + str(gauge.read_voltage()) + 'mV') - print('percentage: ' + str(round(gauge.read_percentage(), 2)) + '%') diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/DFRobot_MAX17043.py b/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/DFRobot_MAX17043.py deleted file mode 100644 index 1ddc751caf7e..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/DFRobot_MAX17043.py +++ /dev/null @@ -1,109 +0,0 @@ -'''! - @file DFRobot_MAX17043.py - @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - @license The MIT License (MIT) - @author [ouki.wang](ouki.wang@dfrobot.com) - @version V1.0 - @date 2018-4-14 - @url https://github.com/DFRobot/DFRobot_MAX17043 -''' - -import smbus -import time -import datetime - -# Get I2C bus -bus = smbus.SMBus(1) - -MAX17043_ADDR = 0x36 -MAX17043_VCELL = 0x02 -MAX17043_SOC = 0x04 -MAX17043_MODE = 0x06 -MAX17043_VERSION = 0x08 -MAX17043_CONFIG = 0x0c -MAX17043_COMMAND = 0xfe - -class DFRobot_MAX17043(): - - def __init__(self): - '''! - @brief create MAX17043 object - @return MAX17043 object - ''' - pass - - def begin(self): - '''! - @brief MAX17043 begin and test moudle - @return initialization result: - @retval 0 successful - @retval -1 faild - ''' - self._write16(MAX17043_COMMAND, 0x5400) - time.sleep(0.01) - if self._read16(MAX17043_CONFIG) == 0x971c: - self._write16(MAX17043_MODE, 0x4000) - time.sleep(0.01) - self._write16(MAX17043_CONFIG, 0x9700) - return 0 - else: - return -1 - - def read_voltage(self): - '''! - @brief read battery voltage in mV - @return voltage in mV - ''' - return (1.25 * (self._read16(MAX17043_VCELL) >> 4)) - - def read_percentage(self): - '''! - @brief read battery remaining capacity in percentage - @return battery remaining capacity in percentage - ''' - tmp = self._read16(MAX17043_SOC) - return ((tmp >> 8) + 0.003906 * (tmp & 0x00ff)) - - def set_interrupt(self, per): - '''! - @brief set MAX17043 interrput threshold - @param per interrupt threshold as %1 - 32% (integer) - ''' - if per > 32: - per = 32 - elif per < 1: - per = 1 - per = 32 - int(per) - self._write_reg_bits(MAX17043_CONFIG, per, 0x01f, 0) - - def clear_interrupt(self): - '''! - @brief clear MAX17043 interrupt. - ''' - self._write_reg_bits(MAX17043_CONFIG, 0, 0x01, 5) - - def set_sleep(self): - '''! - @brief set MAX17043 in sleep mode. - ''' - self._write_reg_bits(MAX17043_CONFIG, 1, 0x01, 7) - - def set_wakeup(self): - '''! - @brief wake up MAX17043. - ''' - self._write_reg_bits(MAX17043_CONFIG, 0, 0x01, 7) - - def _write16(self, reg, dat): - buf = [dat >> 8, dat & 0x00ff] - bus.write_i2c_block_data(MAX17043_ADDR, reg, buf) - - def _read16(self, reg): - buf = bus.read_i2c_block_data(MAX17043_ADDR, reg, 2) - return ((buf[0] << 8) | buf[1]) - - def _write_reg_bits(self, reg, dat, bits, offset): - tmp = self._read16(reg) - tmp = (tmp & (~(bits << offset))) | (dat << offset) - self._write16(reg, tmp) - diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/README.md b/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/README.md deleted file mode 100644 index 47bd4267868e..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/README.md +++ /dev/null @@ -1,128 +0,0 @@ -# DFRobot_MAX17043 - -* [中文版](./README_CN.md) - -The MAX17043 is ultra-compact, low-cost,host-side fuel-gauge systems for lithium-ion (Li+) batter-ies in handheld and portable -equpiment.It employs Gravity I2C interface,ultra-low opearting current, and real-time tracking of the relative state of charge -(SOC) of the battery through Maxim's patented algorithm,eliminating the need for full-to-empty relearning and offset accumualtion -errors.Plug and play to accurately measure the voltage and remaining power of the battery. The module also features as a low -battery power alert interrupt function. When the battery power falls below specified threshold, the ALR pin generates a falling -pluse to trigger the external interrupt of the controller.One thing should mention that the default value of the battery low power -interrupt alert threshold is 32%, this threshold can be set by the function set_interrupt(). - -![产品效果图](../../resources/images/DFR0563.jpg) - -## Product Link([https://www.dfrobot.com/product-1734.html](https://www.dfrobot.com/product-1734.html)) - SKU: DFR0563 - -## Table of Contents -* [Summary](#summary) -* [connection](connection) -* [Installation](#installation) -* [Methods](#methods) -* [Compatibility](#compatibility) -* [History](#history) -* [Credits](#credits) - -## Summary - -Provides an Raspberry pi library for reading and interperting MAX17043 data over I2C. - -## Connection -Wires of the same color are linked together,and We only exemplify how these three boards are connected to the Fuel Gauge. -When connecting , it is necessary to pay attention to the correspondence among pins, the connection diagram is as fellows. - -* Raspberry Pi -
- -
- -## Installation - -Download and install smbus library on Raspberry pi. Steps to install smbus are provided at: - -```python -$> sudo apt-get install -y python-smbus -$> sudo apt-get install -y i2c-tools -``` - -1. To use this library, first download the library file
-```python -sudo git clone https://github.com/DFRobot/DFRobot_MAX17043 -``` -2. Open and run the routine. To execute a routine demo_x.py, enter python demo_x.py in the command line. For example, to execute the demo_read_and_int.py.py routine, you need to enter :
- -```python -python demo_read_and_int.py.py -or -python2 demo_read_and_int.py.py -``` - -## Methods - -```python - '''! - @brief MAX17043 begin and test moudle - @return initialization result: - @retval 0 successful - @retval -1 faild - ''' - def begin(self): - - '''! - @brief read battery voltage in mV - @return voltage in mV - ''' - def read_voltage(self): - - '''! - @brief read battery remaining capacity in percentage - @return battery remaining capacity in percentage - ''' - def read_percentage(self): - '''! - @brief set MAX17043 interrput threshold - @param per interrupt threshold as %1 - 32% (integer) - ''' - def set_interrupt(self, per): - - '''! - @brief clear MAX17043 interrupt. - ''' - def clear_interrupt(self): - - '''! - @brief set MAX17043 in sleep mode. - ''' - def set_sleep(self): - - '''! - @brief wake up MAX17043. - ''' - def set_wakeup(self): - - -``` - -## Compatibility - -| 主板 | 通过 | 未通过 | 未测试 | 备注 | -| ------------ | :--: | :----: | :----: | :--: | -| RaspberryPi2 | | | √ | | -| RaspberryPi3 | | | √ | | -| RaspberryPi4 | √ | | | | - -* Python 版本 - -| Python | 通过 | 未通过 | 未测试 | 备注 | -| ------- | :--: | :----: | :----: | ---- | -| Python2 | √ | | | | -| Python3 | | | √ | | - -## History - -- 2018/04/14 - Version 1.0.0 released. - -## Credits - -Written by ouki.wang(ouki.wang@dfrobot.com), 2018. (Welcome to our [website](https://www.dfrobot.com/)) diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/README_CN.md b/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/README_CN.md deleted file mode 100644 index 00894b09a262..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/README_CN.md +++ /dev/null @@ -1,119 +0,0 @@ -# DFRobot_MAX17043 - -* [English Version](./README.md) - -Gravity 3.7V锂电池电量计使用Gravity I2C接口,超低工作电流,通过Maxim专利算法,实时跟踪电池的相对充电状态(SOC,State-Of-Charge),无需充放电学习过程,无积累误差,即插即用,准确地测量锂电池的当前电压和剩余电量。模块预留低电量报警中断引脚,当电池电量低于指定电量时,该引脚产生一个下跳脉冲,触发主控的外部中断。 - -![产品效果图](../../resources/images/DFR0563.jpg) - - -## 产品链接([https://www.dfrobot.com.cn/goods-1743.html](https://www.dfrobot.com.cn/goods-1743.html)) - SKU: DFR0563 - -## 目录 - -* [概述](#概述) -* [连接](连接) -* [库安装](#库安装) -* [方法](#方法) -* [兼容性](#兼容性) -* [历史](#历史) -* [创作者](#创作者) - -## 概述 - -提供 python 库,用于通过 I2C 读取和解释 MAX17043 数据。 - -## 连接 -相同颜色的线连接在一起,我们只举例说明主板是如何连接到电量计的。接线时要注意管脚的对应关系,接线图如下: - -* Raspberry Pi -
- -
- -## 库安装 -1. 下载库至树莓派,要使用这个库,首先要将库下载到Raspberry Pi,命令下载方法如下:
-```python -sudo git clone https://github.com/DFRobot/DFRobot_MAX17043 -``` -2. 打开并运行例程,要执行一个例程demo_x.py,请在命令行中输入python demo_x.py。例如,要执行 demo_read_and_int.py例程,你需要输入:
- -```python -python demo_read_and_int.py -或 -python2 demo_read_and_int.py -``` - -## 方法 - -```python - '''! - @brief 构造MAX17043对象 - @return MAX17043 初始化 - @retval 0 成功 - @retval -1 失败 - ''' - def begin(self): - - '''! - @brief 读电池电压,单位: mV - @return 电池电压,单位:mV - ''' - def read_voltage(self): - - '''! - @brief 读取剩余电池容量的百分比 - @return 剩余电池容量的百分比 - ''' - def read_percentage(self): - '''! - @brief 设置 MAX17043 中断阈值 - @param per 中断阈值范围: %1 - 32% (整数) - ''' - def set_interrupt(self, per): - - '''! - @brief 清除 MAX17043 中断. - ''' - def clear_interrupt(self): - - '''! - @brief 设置 MAX17043 进入睡眠模式 - ''' - def set_sleep(self): - - '''! - @brief 唤醒 MAX17043 - ''' - def set_wakeup(self): -``` - -## 兼容性 - -| 主板 | 通过 | 未通过 | 未测试 | 备注 | -| ------------ | :--: | :----: | :----: | :--: | -| RaspberryPi2 | | | √ | | -| RaspberryPi3 | | | √ | | -| RaspberryPi4 | √ | | | | - -* Python 版本 - -| Python | 通过 | 未通过 | 未测试 | 备注 | -| ------- | :--: | :----: | :----: | ---- | -| Python2 | √ | | | | -| Python3 | | | √ | | - -## 历史 - -- 2018/04/14 - 1.0.0 版本 - -## 创作者 - -Written by ouki.wang(ouki.wang@dfrobot.com), 2018. (Welcome to our [website](https://www.dfrobot.com/)) - - - - - - diff --git a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/examples/demo_read_and_int.py b/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/examples/demo_read_and_int.py deleted file mode 100644 index dd328c6402d6..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/python/raspberry/examples/demo_read_and_int.py +++ /dev/null @@ -1,44 +0,0 @@ -'''! - @file demo_read_and_int.py - @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com) - @license The MIT License (MIT) - @author [ouki.wang](ouki.wang@dfrobot.com) - @version V1.0 - @date 2018-4-14 - @url https://github.com/DFRobot/DFRobot_MAX17043 -''' - -import sys -sys.path.append('../') -import time - -sys.path.append(os.path.dirname(os.path.dirname(os.path.realpath(__file__)))) -from DFRobot_MAX17043 import DFRobot_MAX17043 -import RPi.GPIO as GPIO - -gauge = DFRobot_MAX17043() - -GPIO.setmode(GPIO.BOARD) -GPIO.setup(7, GPIO.IN) - -def interruptCallBack(channel): - gauge.clear_interrupt() - print('Low power alert interrupt!') - #put your battery low power alert interrupt service routine here - -GPIO.add_event_detect(7, GPIO.FALLING, callback = interruptCallBack, bouncetime = 5) - -rslt = gauge.begin() - -while rslt != 0: - print('gauge begin faild') - time.sleep(2) - rslt = gauge.begin() - -gauge.set_interrupt(32) #use this to modify alert threshold as 1% - 32% (integer) -print('gauge begin successful') - -while True: - time.sleep(2) - print('voltage: ' + str(gauge.read_voltage()) + 'mV') - print('percentage: ' + str(round(gauge.read_percentage(), 2)) + '%') diff --git a/lib/lib_i2c/DFRobot_MAX17043/readme.md b/lib/lib_i2c/DFRobot_MAX17043/readme.md deleted file mode 100644 index fdc79ac77b4f..000000000000 --- a/lib/lib_i2c/DFRobot_MAX17043/readme.md +++ /dev/null @@ -1,122 +0,0 @@ -# DFRobot_MAX17043 - -* [中文版](./README_CN.md) - - The MAX17043 is ultra-compact, low-cost,host-side fuel-gauge systems for lithium-ion (Li+) batter-ies in handheld and portable -equipment.It employs Gravity I2C interface,ultra-low opearting current, and real-time tracking of the relative state of charge (SOC) -of the battery through Maxim's patented algorithm,eliminating the need for full-to-empty relearning and offset accumualtion errors. -Plug and play to accurately measure the voltage and remaining power of the battery. The module also features as a low battery power -alert interrupt function. When the battery power falls below specified threshold, the ALR pin generates a falling pluse to trigger -the external interrupt of the controller.One thing should mention that the default value of the battery low power interrupt alert -threshold is 32%, this threshold can be set by the function setInterrupt(). - -![产品效果图](./resources/images/DFR0563.jpg) - -## Product Link([https://www.dfrobot.com/product-1734.html](https://www.dfrobot.com/product-1734.html)) - SKU: DFR0563 - -## Table of Contents -* [Summary](#summary) -* [connection](connection) -* [Installation](#installation) -* [Methods](#methods) -* [Compatibility](#compatibility) -* [History](#history) -* [Credits](#credits) - -## Summary - -Provides an Arduino library for reading and interperting MAX17043 data over I2C. - -## Connection -Wires of the same color are linked together,and We only exemplify how these the boards are connected to the Fuel Gauge. -When connecting , it is necessary to pay attention to the correspondence among pins, the connection diagram is as fellows. - -* Arduino UNO -
- -
- -* ESP32 -
- -
- - -## Installation - -To use this library download the zip file, uncomperss it to a folder named DFRobot_MAX17043 in Arduino library. -## Methods - -```C++ - /** - * @fn DFRobot_MAX17043 - * @brief create MAX17043 object - * @return MAX17043 object - */ - DFRobot_MAX17043(); - /** - * @fn begin - * @brief MAX17043 begin and test moudle - * - * @return initialization result - * @retval 0 successful - * @retval -1 faild - */ - int begin(); - /** - * @fn readVoltage - * @brief read battery voltage in mV - * @return voltage in mV - */ - float readVoltage(); - /** - * @fn readPercentage - * @brief read battery remaining capacity in percentage - * - * @return battery remaining capacity in percentage - */ - float readPercentage(); - /** - * @fn setInterrupt - * @brief set MAX17043 interrput threshold - * - * @param per interrupt threshold as %1 - 32% (integer) - */ - void setInterrupt(uint8_t per); - /** - * @fn clearInterrupt - * @brief clear MAX17043 interrupt - */ - void clearInterrupt(); - /** - * @fn setSleep - * @brief set MAX17043 in sleep mode - * - */ - void setSleep(); - /** - * @fn setWakeUp - * @brief wake up MAX17043 - * - */ - void setWakeUp(); - -``` - -## Compatibility - -| MCU | Work Well | Work Wrong | Untested | Remarks | -| ------------------ | :-------: | :--------: | :------: | ------- | -| FireBeetle-ESP32 | √ | | | -| FireBeetle-ESP8266 | √ | | | -| Arduino uno | √ | | | - -## History - -- 2018/04/14 - Version 1.0.0 released. - -## Credits - -Written by ouki.wang(ouki.wang@dfrobot.com), 2018. (Welcome to our [website](https://www.dfrobot.com/)) - diff --git a/lib/lib_i2c/DFRobot_MAX17043/resources/images/DFR0563.jpg b/lib/lib_i2c/DFRobot_MAX17043/resources/images/DFR0563.jpg deleted file mode 100644 index eb0370a56c7a..000000000000 Binary files a/lib/lib_i2c/DFRobot_MAX17043/resources/images/DFR0563.jpg and /dev/null differ diff --git a/lib/lib_i2c/DFRobot_MAX17043/resources/images/Raspberry Pi.jpg b/lib/lib_i2c/DFRobot_MAX17043/resources/images/Raspberry Pi.jpg deleted file mode 100644 index 3ab96c2cde7f..000000000000 Binary files a/lib/lib_i2c/DFRobot_MAX17043/resources/images/Raspberry Pi.jpg and /dev/null differ diff --git a/lib/lib_i2c/DFRobot_MAX17043/resources/images/UNO.jpg b/lib/lib_i2c/DFRobot_MAX17043/resources/images/UNO.jpg deleted file mode 100644 index 8c3d66b65330..000000000000 Binary files a/lib/lib_i2c/DFRobot_MAX17043/resources/images/UNO.jpg and /dev/null differ diff --git a/lib/lib_i2c/DFRobot_MAX17043/resources/images/esp32.jpg b/lib/lib_i2c/DFRobot_MAX17043/resources/images/esp32.jpg deleted file mode 100644 index 41b163cfd552..000000000000 Binary files a/lib/lib_i2c/DFRobot_MAX17043/resources/images/esp32.jpg and /dev/null differ diff --git a/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP32Wifi.cpp b/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP32Wifi.cpp index d5d8edb3c33e..ea288d5478ed 100644 --- a/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP32Wifi.cpp +++ b/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP32Wifi.cpp @@ -111,18 +111,6 @@ void WiFiClass32::scrubDNS(void) { } else { dns_setserver(i, IP4_ADDR_ANY); } -#else // USE_IPV6 - uint32_t ip_dns = ip_addr_get_ip4_u32(dns_getserver(i)); - // Step 1. save valid values from DNS - if (has_v4 && (uint32_t)ip_dns != 0) { - ip_addr_set_ip4_u32_val(dns_save4[i], ip_dns); - } - // Step 2. scrub addresses not supported - if (!has_v4) { - ip_addr_set_ip4_u32_val(dns_save4[i], 0L); - } - // Step 3. restore saved value - dns_setserver(i, &dns_save4[i]); #endif // USE_IPV6 } // AddLog(LOG_LEVEL_DEBUG, "IP>: DNS: from(%s %s) to (%s %s) has4/6:%i-%i", dns_entry0.c_str(), dns_entry1.c_str(), IPAddress(dns_getserver(0)).toString().c_str(), IPAddress(dns_getserver(1)).toString().c_str(), has_v4, has_v6); diff --git a/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP8266WiFi.h b/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP8266WiFi.h index 943b89e9aad5..94cf3d6c1a21 100644 --- a/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP8266WiFi.h +++ b/lib/libesp32/ESP32-to-ESP8266-compat/src/ESP8266WiFi.h @@ -76,8 +76,8 @@ class WiFiClass32 : public WiFiClass void scrubDNS(void); protected: - ip_addr_t dns_save4[DNS_MAX_SERVERS] = {}; // IPv4 DNS servers #ifdef USE_IPV6 + ip_addr_t dns_save4[DNS_MAX_SERVERS] = {}; // IPv4 DNS servers ip_addr_t dns_save6[DNS_MAX_SERVERS] = {}; // IPv6 DNS servers #endif // USE_IPV6 }; diff --git a/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.cpp b/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.cpp index dfc8c3dab0f8..c886a666da3a 100644 --- a/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.cpp +++ b/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.cpp @@ -16,6 +16,7 @@ #ifdef ESP32 #include "Arduino.h" +#include "esp_idf_version.h" #include "esp8266toEsp32.h" #include "driver/ledc.h" @@ -33,7 +34,11 @@ enum LoggingLevels {LOG_LEVEL_NONE, LOG_LEVEL_ERROR, LOG_LEVEL_INFO, LOG_LEVEL_D #else #define LEDC_DEFAULT_CLK LEDC_AUTO_CLK #endif -#define LEDC_MAX_BIT_WIDTH SOC_LEDC_TIMER_BIT_WIDE_NUM +#if (ESP_IDF_VERSION_MAJOR >= 5) + #define LEDC_MAX_BIT_WIDTH SOC_LEDC_TIMER_BIT_WIDTH +#else + #define LEDC_MAX_BIT_WIDTH SOC_LEDC_TIMER_BIT_WIDE_NUM +#endif // define our limits to ease any change from esp-idf #define MAX_TIMERS LEDC_TIMER_MAX // 4 timers for all ESP32 variants diff --git a/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.h b/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.h index c544d5d30379..07bc9c2d5c2e 100644 --- a/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.h +++ b/lib/libesp32/ESP32-to-ESP8266-compat/src/esp8266toEsp32.h @@ -53,7 +53,7 @@ uint8_t ledcReadResolution(uint8_t chan); // was not yet attached. // // Returns: hardware channel number, or -1 if it failed -int analogAttach(uint32_t pin, bool output_invert = false); // returns the ledc channel, or -1 if failed. This is implicitly called by analogWrite if the channel was not already allocated +int32_t analogAttach(uint32_t pin, bool output_invert = false); // returns the ledc channel, or -1 if failed. This is implicitly called by analogWrite if the channel was not already allocated // change both freq and range // `0`: set to global value diff --git a/lib/libesp32/berry/src/be_byteslib.c b/lib/libesp32/berry/src/be_byteslib.c index 665d630f3a3e..0a5c1747e6ea 100644 --- a/lib/libesp32/berry/src/be_byteslib.c +++ b/lib/libesp32/berry/src/be_byteslib.c @@ -356,6 +356,40 @@ static uint16_t buf_get2_be(buf_impl* attr, size_t offset) return 0; } +static uint32_t buf_get3_le(buf_impl* attr, size_t offset) +{ + if ((int32_t)offset + 2 < attr->len) { + return attr->bufptr[offset] | (attr->bufptr[offset+1] << 8) | (attr->bufptr[offset+2] << 16); + } + return 0; +} + +static uint16_t buf_get3_be(buf_impl* attr, size_t offset) +{ + if ((int32_t)offset + 2 < attr->len) { + return attr->bufptr[offset+2] | (attr->bufptr[offset+1] << 8) | (attr->bufptr[offset] << 16); + } + return 0; +} + +static void buf_set3_le(buf_impl* attr, size_t offset, uint32_t data) +{ + if ((int32_t)offset + 2 < attr->len) { + attr->bufptr[offset] = data & 0xFF; + attr->bufptr[offset+1] = (data >> 8) & 0xFF; + attr->bufptr[offset+2] = (data >> 16) & 0xFF; + } +} + +static void buf_set3_be(buf_impl* attr, size_t offset, uint32_t data) +{ + if ((int32_t)offset + 2 < attr->len) { + attr->bufptr[offset+2] = data & 0xFF; + attr->bufptr[offset+1] = (data >> 8) & 0xFF; + attr->bufptr[offset] = (data >> 16) & 0xFF; + } +} + static void buf_set4_le(buf_impl* attr, size_t offset, uint32_t data) { if ((int32_t)offset + 3 < attr->len) { @@ -832,12 +866,18 @@ static int m_get(bvm *vm, bbool sign) case 2: ret = buf_get2_le(&attr, idx); if (sign) { ret = (int16_t)(uint16_t) ret; } break; + case 3: ret = buf_get3_le(&attr, idx); + if (sign & (ret & 0x800000)) { ret = ret | 0xFF000000; } + break; case 4: ret = buf_get4_le(&attr, idx); break; case -2: ret = buf_get2_be(&attr, idx); if (sign) { ret = (int16_t)(uint16_t) ret; } break; + case -3: ret = buf_get3_be(&attr, idx); + if (sign & (ret & 0x800000)) { ret = ret | 0xFF000000; } + break; case -4: ret = buf_get4_be(&attr, idx); break; - default: be_raise(vm, "type_error", "size must be -4, -2, -1, 0, 1, 2 or 4."); + default: be_raise(vm, "type_error", "size must be -4, -3, -2, -1, 0, 1, 2, 3 or 4."); } be_pop(vm, argc - 1); if (vsize != 0) { @@ -911,10 +951,12 @@ static int m_set(bvm *vm) case -1: /* fallback below */ case 1: buf_set1(&attr, idx, value); break; case 2: buf_set2_le(&attr, idx, value); break; + case 3: buf_set3_le(&attr, idx, value); break; case 4: buf_set4_le(&attr, idx, value); break; case -2: buf_set2_be(&attr, idx, value); break; + case -3: buf_set3_be(&attr, idx, value); break; case -4: buf_set4_be(&attr, idx, value); break; - default: be_raise(vm, "type_error", "size must be -4, -2, -1, 0, 1, 2 or 4."); + default: be_raise(vm, "type_error", "size must be -4, -3, -2, -1, 0, 1, 2, 3 or 4."); } be_pop(vm, argc - 1); m_write_attributes(vm, 1, &attr); /* update attributes */ diff --git a/lib/libesp32/berry_mapping/src/be_cb_module.c b/lib/libesp32/berry_mapping/src/be_cb_module.c index 7bf729a0b018..111ba95e052d 100644 --- a/lib/libesp32/berry_mapping/src/be_cb_module.c +++ b/lib/libesp32/berry_mapping/src/be_cb_module.c @@ -22,10 +22,10 @@ enum LoggingLevels {LOG_LEVEL_NONE, LOG_LEVEL_ERROR, LOG_LEVEL_INFO, LOG_LEVEL_D * We allow 4 parameters, or 3 if method (first arg is `self`) * This could be extended if needed \*********************************************************************************************/ -typedef int32_t (*berry_callback_t)(int32_t v0, int32_t v1, int32_t v2, int32_t v3); -static int32_t call_berry_cb(int32_t num, int32_t v0, int32_t v1, int32_t v2, int32_t v3); +typedef int (*berry_callback_t)(int v0, int v1, int v2, int v3); +static int call_berry_cb(int num, int v0, int v1, int v2, int v3); -#define BERRY_CB(n) int32_t berry_cb_##n(int32_t v0, int32_t v1, int32_t v2, int32_t v3) { return call_berry_cb(n, v0, v1, v2, v3); } +#define BERRY_CB(n) int berry_cb_##n(int v0, int v1, int v2, int v3) { return call_berry_cb(n, v0, v1, v2, v3); } // list the callbacks BERRY_CB(0); BERRY_CB(1); @@ -85,7 +85,7 @@ typedef struct be_callback_handler_list_t { static be_callback_hook be_cb_hooks[BE_MAX_CB] = {0}; -static int32_t be_cb_gen_cb(bvm *vm); +static int be_cb_gen_cb(bvm *vm); static be_callback_handler_list_t be_callback_default_gen_cb = { NULL, be_const_func(&be_cb_gen_cb), @@ -102,7 +102,7 @@ static be_callback_handler_list_t *be_callback_handler_list_head = &be_callback_ * * arg1: function (or closure) \*********************************************************************************************/ -static int32_t be_cb_add_handler(bvm *vm) { +static int be_cb_add_handler(bvm *vm) { int32_t top = be_top(vm); if (top >= 1 && be_isfunction(vm, 1)) { bvalue *v = be_indexof(vm, 1); @@ -129,7 +129,7 @@ static int32_t be_cb_add_handler(bvm *vm) { * * No args \*********************************************************************************************/ -static int32_t be_cb_list_handlers(bvm *vm) { +static int be_cb_list_handlers(bvm *vm) { be_newobject(vm, "list"); for (be_callback_handler_list_t *elt = be_callback_handler_list_head; elt != NULL; elt = elt->next) { if (elt->vm == vm) { /* on purpose don't show the default handler, just pretend it's not there since it's default */ @@ -153,7 +153,7 @@ static int32_t be_cb_list_handlers(bvm *vm) { * arg2: type name for callback (optional) * argN: any other callback specific arguments (unlimited number, passed as-is) \*********************************************************************************************/ -static int32_t be_cb_make_cb(bvm *vm) { +static int be_cb_make_cb(bvm *vm) { int32_t argc = be_top(vm); if (argc >= 1 && be_isfunction(vm, 1)) { @@ -187,7 +187,7 @@ static int32_t be_cb_make_cb(bvm *vm) { * * arg1: function (or closure) \*********************************************************************************************/ -static int32_t be_cb_gen_cb(bvm *vm) { +static int be_cb_gen_cb(bvm *vm) { int32_t top = be_top(vm); // tasmota_log_C(LOG_LEVEL_DEBUG, "BRY: gen_cb() called"); if (top >= 1 && be_isfunction(vm, 1)) { @@ -217,7 +217,7 @@ static int32_t be_cb_gen_cb(bvm *vm) { * `get_cb_list`: Return the list of callbacks for this vm * \*********************************************************************************************/ -static int32_t be_cb_get_cb_list(bvm *vm) { +static int be_cb_get_cb_list(bvm *vm) { be_newobject(vm, "list"); for (uint32_t i=0; i < BE_MAX_CB; i++) { if (be_cb_hooks[i].vm) { @@ -242,7 +242,7 @@ static int32_t be_cb_get_cb_list(bvm *vm) { * We allow 4 parameters, or 3 if method (first arg is `self`) * This could be extended if needed \*********************************************************************************************/ -static int32_t call_berry_cb(int32_t num, int32_t v0, int32_t v1, int32_t v2, int32_t v3) { +static int call_berry_cb(int num, int v0, int v1, int v2, int v3) { // call berry cb dispatcher int32_t ret = 0; // retrieve vm and function diff --git a/lib/libesp32/berry_matter/src/be_matter_misc.cpp b/lib/libesp32/berry_matter/src/be_matter_misc.cpp index 2ec805183294..0e57c2aa54f8 100644 --- a/lib/libesp32/berry_matter/src/be_matter_misc.cpp +++ b/lib/libesp32/berry_matter/src/be_matter_misc.cpp @@ -31,6 +31,7 @@ static uint8_t ip_bytes[16] = {}; extern "C" const void* matter_get_ip_bytes(const char* ip_str, size_t* ret_len) { IPAddress ip; if (ip.fromString(ip_str)) { +#ifdef USE_IPV6 if (ip.isV4()) { uint32_t ip_32 = ip; memcpy(ip_bytes, &ip_32, 4); @@ -39,6 +40,11 @@ extern "C" const void* matter_get_ip_bytes(const char* ip_str, size_t* ret_len) memcpy(ip_bytes, ip.raw6(), 16); *ret_len = 16; } +#else + uint32_t ip_32 = ip; + memcpy(ip_bytes, &ip_32, 4); + *ret_len = 4; +#endif return ip_bytes; } else { *ret_len = 0; diff --git a/lib/libesp32/berry_matter/src/be_matter_qrcode.c b/lib/libesp32/berry_matter/src/be_matter_qrcode.c index 5bcddef86c72..9892cda93be4 100644 --- a/lib/libesp32/berry_matter/src/be_matter_qrcode.c +++ b/lib/libesp32/berry_matter/src/be_matter_qrcode.c @@ -32,7 +32,7 @@ // `matter.QRCode.encode_str(content:string) -> map` // -int32_t qr_encode_str(bvm *vm) { +int qr_encode_str(bvm *vm) { int32_t argc = be_top(vm); if (argc >= 1 && be_isstring(vm, 1)) { const char * data_str = be_tostring(vm, 1); diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be b/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be index 0ccc062c3f94..db7bc669ee25 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Commissioning.be @@ -289,18 +289,22 @@ class Matter_Commisioning_Context import crypto # Validate Sigma1 Destination ID, p.162 # traverse all existing fabrics - tasmota.log("MTR: SEARCHING: destinationId=" + destinationId.tohex(), 4) + if tasmota.loglevel(4) + tasmota.log("MTR: SEARCHING: destinationId=" + destinationId.tohex(), 4) + end for fabric : self.device.sessions.fabrics if fabric.noc == nil || fabric.fabric_id == nil || fabric.device_id == nil continue end # compute candidateDestinationId, Section 4.13.2.4.1, “Destination Identifier” var destinationMessage = initiatorRandom + fabric.get_ca_pub() + fabric.fabric_id + fabric.device_id var key = fabric.get_ipk_group_key() - tasmota.log("MTR: SIGMA1: destinationMessage=" + destinationMessage.tohex(), 4) + # tasmota.log("MTR: SIGMA1: destinationMessage=" + destinationMessage.tohex(), 4) # tasmota.log("MTR: SIGMA1: key_ipk=" + key.tohex(), 4) var h = crypto.HMAC_SHA256(key) h.update(destinationMessage) var candidateDestinationId = h.out() - tasmota.log("MTR: SIGMA1: candidateDestinationId=" + candidateDestinationId.tohex(), 4) + if tasmota.loglevel(4) + tasmota.log("MTR: SIGMA1: candidateDestinationId=" + candidateDestinationId.tohex(), 4) + end if candidateDestinationId == destinationId return fabric end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Device.be b/lib/libesp32/berry_matter/src/embedded/Matter_Device.be index 1a157549018e..d272c4061e43 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Device.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Device.be @@ -176,18 +176,24 @@ class Matter_Device ##################################################################### # Remove a fabric and clean all corresponding values and mDNS entries - def remove_fabric(fabric_parent) - var sub_fabrics = self.sessions.find_children_fabrics(fabric_parent.get_fabric_index()) - if sub_fabrics == nil return end - for fabric_index : sub_fabrics - var fabric = self.sessions.find_fabric_by_index(fabric_index) - if fabric != nil - tasmota.log("MTR: removing fabric " + fabric.get_fabric_id().copy().reverse().tohex(), 2) - self.message_handler.im.subs_shop.remove_by_fabric(fabric) - self.mdns_remove_op_discovery(fabric) - self.sessions.remove_fabric(fabric) - end + def remove_fabric(fabric) + if fabric != nil + tasmota.log("MTR: removing fabric " + fabric.get_fabric_id().copy().reverse().tohex(), 2) + self.message_handler.im.subs_shop.remove_by_fabric(fabric) + self.mdns_remove_op_discovery(fabric) + self.sessions.remove_fabric(fabric) end + # var sub_fabrics = self.sessions.find_children_fabrics(fabric_parent.get_fabric_index()) + # if sub_fabrics == nil return end + # for fabric_index : sub_fabrics + # var fabric = self.sessions.find_fabric_by_index(fabric_index) + # if fabric != nil + # tasmota.log("MTR: removing fabric " + fabric.get_fabric_id().copy().reverse().tohex(), 2) + # self.message_handler.im.subs_shop.remove_by_fabric(fabric) + # self.mdns_remove_op_discovery(fabric) + # self.sessions.remove_fabric(fabric) + # end + # end self.sessions.save_fabrics() end @@ -431,7 +437,7 @@ class Matter_Device var fabric = session.get_fabric() var fabric_id = fabric.get_fabric_id().copy().reverse().tohex() var vendor_name = fabric.get_admin_vendor_name() - tasmota.log(format("MTR: --- Commissioning complete for Fabric '%s' (Vendor %s) ---", fabric_id, vendor_name), 2) + tasmota.log(f"MTR: --- Commissioning complete for Fabric '{fabric_id}' (Vendor {vendor_name}) ---", 2) self.stop_basic_commissioning() # by default close commissioning when it's complete end @@ -1146,13 +1152,13 @@ class Matter_Device if !r_st13.contains(k) break end # no more SHTxxx var d = r_st13[k] tasmota.log(format("MTR: '%s' = %s", k, str(d)), 3) - var relay1 = d.find('Relay1', 0) - 1 # relay base 0 or -1 if none - var relay2 = d.find('Relay2', 0) - 1 # relay base 0 or -1 if none + var relay1 = d.find('Relay1', -1) # relay base 1 or -1 if none + var relay2 = d.find('Relay2', -1) # relay base 1 or -1 if none - if relay1 >= 0 relays_reserved.push(relay1) end # mark relay1/2 as non-relays - if relay2 >= 0 relays_reserved.push(relay2) end + if relay1 > 0 relays_reserved.push(relay1 - 1) end # mark relay1/2 as non-relays + if relay2 > 0 relays_reserved.push(relay2 - 1) end - tasmota.log(format("MTR: relay1 = %s, relay2 = %s", relay1, relay2), 3) + tasmota.log(f"MTR: {relay1=} {relay2=}", 3) # is there tilt support var tilt_array = d.find('TiltConfig') var tilt_config = tilt_array && (tilt_array[2] > 0) @@ -1171,7 +1177,7 @@ class Matter_Device while relay_index < relay_count if relays_reserved.find(relay_index) == nil # if relay is actual relay - m[str(endpoint)] = {'type':'relay','relay':relay_index} + m[str(endpoint)] = {'type':'relay','relay':relay_index + 1} # Relay index start with 1 endpoint += 1 end relay_index += 1 diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_IM.be b/lib/libesp32/berry_matter/src/embedded/Matter_IM.be index 1f60e6b511ff..016115fc81bb 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_IM.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_IM.be @@ -225,7 +225,7 @@ class Matter_IM # Inner code shared between read_attributes and subscribe_request # # query: `ReadRequestMessage` or `SubscribeRequestMessage` - def _inner_process_read_request(session, query, no_log) + def _inner_process_read_request(session, query, msg, no_log) ### Inner function to be iterated upon # ret is the ReportDataMessage list to send back @@ -243,22 +243,47 @@ class Matter_IM # Special case to report unsupported item, if pi==nil var res = (pi != nil) ? pi.read_attribute(session, ctx, self.tlv_solo) : nil var found = true # stop expansion since we have a value - var a1_raw # this is the bytes() block we need to add to response (or nil) + var a1_raw_or_list # contains either a bytes() buffer to append, or a list of bytes(), or nil if res != nil - var res_str = res.to_str_val() # get the value with anonymous tag before it is tagged, for logging + var res_str = "" + if !no_log + res_str = res.to_str_val() # get the value with anonymous tag before it is tagged, for logging + end - # encode directly raw bytes() - a1_raw = bytes(48) # pre-reserve 48 bytes - self.attributedata2raw(a1_raw, ctx, res) + # check if too big to encode as a single packet + if (res.is_list || res.is_array) && res.encode_len() > matter.IM_ReportData.MAX_MESSAGE + # tasmota.log(f"MTR: >>>>>> long response", 3) + a1_raw_or_list = [] # we return a list of block + var a1_raw = bytes(48) + var empty_list = TLV.Matter_TLV_array() + self.attributedata2raw(a1_raw, ctx, empty_list, false) + a1_raw_or_list.push(a1_raw) + # tasmota.log(f"MTR: >>>>>> long response global DELETE {a1_raw.tohex()}", 3) + + for elt:res.val + a1_raw = bytes(48) + # var list_item = TLV.Matter_TLV_array() + # list_item.val.push(elt) + self.attributedata2raw(a1_raw, ctx, elt, true #- add ListIndex:null -#) + # tasmota.log(f"MTR: >>>>>> long response global ADD {a1_raw.tohex()}", 3) + a1_raw_or_list.push(a1_raw) + end + # tasmota.log(f"MTR: >>>>>> long response global {a1_raw_or_list}", 3) + else + # normal encoding + # encode directly raw bytes() + a1_raw_or_list = bytes(48) # pre-reserve 48 bytes + self.attributedata2raw(a1_raw_or_list, ctx, res) + end if !no_log - tasmota.log(format("MTR: >Read_Attr (%6i) %s%s - %s", session.local_session_id, str(ctx), attr_name, res_str), 3) + tasmota.log(f"MTR: >Read_Attr ({session.local_session_id:6i}) {ctx}{attr_name} - {res_str}", 3) end elif ctx.status != nil if direct # we report an error only if a concrete direct read, not with wildcards # encode directly raw bytes() - a1_raw = bytes(48) # pre-reserve 48 bytes - self.attributestatus2raw(a1_raw, ctx, ctx.status) + a1_raw_or_list = bytes(48) # pre-reserve 48 bytes + self.attributestatus2raw(a1_raw_or_list, ctx, ctx.status) if tasmota.loglevel(3) tasmota.log(format("MTR: >Read_Attr (%6i) %s%s - STATUS: 0x%02X %s", session.local_session_id, str(ctx), attr_name, ctx.status, ctx.status == matter.UNSUPPORTED_ATTRIBUTE ? "UNSUPPORTED_ATTRIBUTE" : ""), 3) @@ -270,27 +295,55 @@ class Matter_IM found = false end - # check if we still have enough room in last block - if a1_raw # do we have bytes to add, and it's not zero size + # a1_raw_or_list if either nil, bytes(), of list(bytes()) + var idx = isinstance(a1_raw_or_list, list) ? 0 : nil # index in list, or nil if non-list + while a1_raw_or_list != nil + var elt = (idx == nil) ? a1_raw_or_list : a1_raw_or_list[idx] # dereference + if size(ret.attribute_reports) == 0 - ret.attribute_reports.push(a1_raw) # push raw binary instead of a TLV + ret.attribute_reports.push(elt) # push raw binary instead of a TLV else # already blocks present, see if we can add to the latest, or need to create a new block var last_block = ret.attribute_reports[-1] - if size(last_block) + size(a1_raw) <= matter.IM_ReportData.MAX_MESSAGE + if size(last_block) + size(elt) <= matter.IM_ReportData.MAX_MESSAGE # add to last block - last_block .. a1_raw + last_block .. elt else - ret.attribute_reports.push(a1_raw) # push raw binary instead of a TLV + ret.attribute_reports.push(elt) # push raw binary instead of a TLV + end + end + + if idx == nil + a1_raw_or_list = nil # stop loop + else + idx += 1 + if idx >= size(a1_raw_or_list) + a1_raw_or_list = nil # stop loop end end end + # check if we still have enough room in last block + # if a1_raw_or_list # do we have bytes to add, and it's not zero size + # if size(ret.attribute_reports) == 0 + # ret.attribute_reports.push(a1_raw_or_list) # push raw binary instead of a TLV + # else # already blocks present, see if we can add to the latest, or need to create a new block + # var last_block = ret.attribute_reports[-1] + # if size(last_block) + size(a1_raw_or_list) <= matter.IM_ReportData.MAX_MESSAGE + # # add to last block + # last_block .. a1_raw_or_list + # else + # ret.attribute_reports.push(a1_raw_or_list) # push raw binary instead of a TLV + # end + # end + # end + return found # return true if we had a match end var endpoints = self.device.get_active_endpoints() # structure is `ReadRequestMessage` 10.6.2 p.558 var ctx = matter.Path() + ctx.msg = msg # prepare the response var ret = matter.ReportDataMessage() @@ -302,6 +355,7 @@ class Matter_IM ctx.endpoint = q.endpoint ctx.cluster = q.cluster ctx.attribute = q.attribute + ctx.fabric_filtered = query.fabric_filtered ctx.status = matter.UNSUPPORTED_ATTRIBUTE #default error if returned `nil` # expand endpoint @@ -346,8 +400,10 @@ class Matter_IM # 2402 01 2 = 1U (U1) # 2403 39 3 = 0x39U (U1) # 2404 11 4 = 0x11U (U1) + # [OPTIONAL ListIndex] + # 3405 5 = NULL # 18 - def path2raw(raw, ctx, sub_tag) + def path2raw(raw, ctx, sub_tag, list_index_null) # open struct raw.add(0x37, 1) # add 37 raw.add(sub_tag, 1) # add sub_tag @@ -381,6 +437,11 @@ class Matter_IM raw.add(0x2604, -2) # add 2604 raw.add(ctx.attribute, 4) end + # do we add ListIndex: null + if list_index_null + raw.add(0x3405, -2) # add 3405 + end + # close raw.add(0x18, 1) # add 18 end @@ -417,15 +478,18 @@ class Matter_IM # 2402 01 2 = 1U (U1) # 2403 39 3 = 0x39U (U1) # 2404 11 4 = 0x11U (U1) + # [OPTIONAL ListIndex] + # 3405 5 = NULL + # # 18 # 2902 2 = True # 18 # 18 - def attributedata2raw(raw, ctx, val) + def attributedata2raw(raw, ctx, val, list_index_null) raw.add(0x15350124, -4) # add 15350124 raw.add(0x0001, -2) # add 0001 - self.path2raw(raw, ctx, 0x01) + self.path2raw(raw, ctx, 0x01, list_index_null) # add value with tag 2 val.tag_sub = 2 @@ -614,7 +678,7 @@ class Matter_IM var query = matter.ReadRequestMessage().from_TLV(val) # matter.profiler.log(str(query)) if query.attributes_requests != nil - var ret = self._inner_process_read_request(msg.session, query) + var ret = self._inner_process_read_request(msg.session, query, msg) self.send_report_data(msg, ret) end @@ -628,15 +692,10 @@ class Matter_IM # returns `true` if processed, `false` if silently ignored, # or raises an exception def process_read_request_solo(msg, ctx) - # matter.profiler.log("read_request_solo start") - # matter.profiler.log(str(val)) - # var query = matter.ReadRequestMessage().from_TLV(val) - # matter.profiler.log("read_request_start-TLV") - # prepare fallback error ctx.status = matter.INVALID_ACTION + ctx.msg = msg - # TODO # find pi for this endpoint/cluster/attribute var pi = self.device.process_attribute_read_solo(ctx) var res = nil @@ -652,6 +711,15 @@ class Matter_IM if res != nil + # check if the payload is a complex structure and too long to fit in a single response packet + if (res.is_list || res.is_array) && res.encode_len() > matter.IM_ReportData.MAX_MESSAGE + # revert to standard + # the attribute will be read again, but it's hard to avoid it + res = nil # indicated to GC that we don't need it again + tasmota.log(f"MTR: Response to big, revert to non-solo", 3) + var val = matter.TLV.parse(msg.raw, msg.app_payload_idx) + return self.process_read_request(msg, val) + end # encode directly raw bytes() raw = bytes(48) # pre-reserve 48 bytes @@ -664,8 +732,6 @@ class Matter_IM raw.add(0x1824FF01, -4) # add 1824FF01 raw.add(0x18, 1) # add 18 - # matter.profiler.log("read_request_solo raw done") - elif ctx.status != nil # encode directly raw bytes() @@ -685,31 +751,14 @@ class Matter_IM return false end - # matter.profiler.log("read_request_solo res ready") - # tasmota.log(f"MTR: process_read_request_solo {raw=}") - # send packet - # self.send_report_data_solo(msg, ret) - # var report_solo = matter.IM_ReportData_solo(msg, ret) var resp = msg.build_response(0x05 #-Report Data-#, true) - # super(self).reset(msg, 0x05 #-Report Data-#, true) - # matter.profiler.log("read_request_solo report_solo") - - # send_im() - # report_solo.send_im(self.device.message_handler) var responder = self.device.message_handler - # matter.profiler.log("read_request_solo send_im-1") - # if tasmota.loglevel(3) # TODO remove before flight - # tasmota.log(f">>>: data_raw={raw.tohex()}", 3) - # end - # matter.profiler.log("read_request_solo send_im-2") var msg_raw = msg.raw msg_raw.clear() resp.encode_frame(raw, msg_raw) # payload in cleartext - # matter.profiler.log("read_request_solo send_im-3") resp.encrypt() - # matter.profiler.log("read_request_solo send_im-encrypted") if tasmota.loglevel(4) tasmota.log(format("MTR: Subscribe (%6i) %s (min=%i, max=%i, keep=%i) sub=%i", - msg.session.local_session_id, attr_req.concat(" "), sub.min_interval, sub.max_interval, query.keep_subscriptions ? 1 : 0, sub.subscription_id), 3) + tasmota.log(format("MTR: >Subscribe (%6i) %s (min=%i, max=%i, keep=%i) sub=%i fabric_filtered=%s", + msg.session.local_session_id, attr_req.concat(" "), sub.min_interval, sub.max_interval, query.keep_subscriptions ? 1 : 0, sub.subscription_id, query.fabric_filtered), 3) + if query.event_requests != nil && size(query.event_requests) > 0 + tasmota.log(f"MTR: >Subscribe (%6i) event_requests_size={size(query.event_requests)}", 3) + end - var ret = self._inner_process_read_request(msg.session, query, true #-no_log-#) + var ret = self._inner_process_read_request(msg.session, query, msg, true #-no_log-#) # ret is of type `Matter_ReportDataMessage` ret.subscription_id = sub.subscription_id # enrich with subscription id TODO self.send_subscribe_response(msg, ret, sub) @@ -849,11 +901,7 @@ class Matter_IM end end - # tasmota.log("MTR: invoke_responses="+str(ret.invoke_responses), 4) if size(ret.invoke_responses) > 0 - # tasmota.log("MTR: InvokeResponse=" + str(ret), 4) - # tasmota.log("MTR: InvokeResponseTLV=" + str(ret.to_TLV()), 3) - self.send_invoke_response(msg, ret) else return false # we don't send anything, hence the responder sends a simple packet ack @@ -1005,6 +1053,7 @@ class Matter_IM # structure is `ReadRequestMessage` 10.6.2 p.558 # tasmota.log("MTR: IM:write_request processing start", 4) var ctx = matter.Path() + ctx.msg = msg if query.write_requests != nil # prepare the response @@ -1108,7 +1157,7 @@ class Matter_IM tasmota.log(format("MTR: int(x) # function to convert argument to the right type - static var UPDATE_TIME = 5000 # update every 250ms + static var UPDATE_TIME = 750 # update every 750ms static var CLUSTERS = { 0x0045: [0,0xFFFC,0xFFFD], # Boolean State p.70 - no writable } diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_Occupancy.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_Occupancy.be index 1400c55b044e..6d21068491e3 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_Occupancy.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_Occupancy.be @@ -32,7 +32,7 @@ class Matter_Plugin_Sensor_Occupancy : Matter_Plugin_Device static var ARG = "switch" # additional argument name (or empty if none) static var ARG_HINT = "Switch number" static var ARG_TYPE = / x -> int(x) # function to convert argument to the right type - static var UPDATE_TIME = 5000 # update every 250ms + static var UPDATE_TIME = 750 # update every 750ms static var CLUSTERS = { 0x0406: [0,1,2,0xFFFC,0xFFFD], # Occupancy Sensing p.105 - no writable } diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_OnOff.be b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_OnOff.be index 5f2858d681d2..0746ee49fd19 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_OnOff.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Plugin_Sensor_OnOff.be @@ -30,7 +30,7 @@ class Matter_Plugin_Sensor_OnOff : Matter_Plugin_Device static var ARG = "switch" # additional argument name (or empty if none) static var ARG_HINT = "Switch number" static var ARG_TYPE = / x -> int(x) # function to convert argument to the right type - static var UPDATE_TIME = 5000 # update every 250ms + static var UPDATE_TIME = 750 # update every 750ms static var CLUSTERS = { 0x0006: [0,0xFFFC,0xFFFD], # On/Off 1.5 p.48 } diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Session.be b/lib/libesp32/berry_matter/src/embedded/Matter_Session.be index 558da861ed28..dd17a0df0fe3 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Session.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Session.be @@ -254,7 +254,8 @@ class Matter_Session : Matter_Expirable def get_icac() return self._fabric.icac end def get_ipk_epoch_key() return self._fabric.ipk_epoch_key end def get_fabric_id() return self._fabric.fabric_id end - def get_device_id() return self._fabric.device_id end + def get_fabric_index() return self._fabric ? self._fabric.fabric_index : nil end + def get_device_id() return self._fabric ? self._fabric.device_id : nil end def get_fabric_compressed() return self._fabric.fabric_compressed end def get_fabric_label() return self._fabric.fabric_label end def get_admin_subject() return self._fabric.admin_subject end diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_Session_Store.be b/lib/libesp32/berry_matter/src/embedded/Matter_Session_Store.be index 9acc749e0d76..0c819b906152 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_Session_Store.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_Session_Store.be @@ -313,19 +313,24 @@ class Matter_Session_Store try self.remove_expired() # clean before saving var sessions_saved = 0 + var fabrics_saved = 0 - var fabs = [] - for f : self.fabrics.persistables() - for _ : f._sessions.persistables() sessions_saved += 1 end # count persitable sessions - fabs.push(f.tojson()) + var f = open(self._FABRICS, "w") + + f.write("[") + for fab : self.fabrics.persistables() + for _ : fab._sessions.persistables() sessions_saved += 1 end # count persitable sessions + if fabrics_saved > 0 + f.write(",") + end + var f_json = fab.tojson() + f.write(f_json) + fabrics_saved += 1 end - var fabs_size = size(fabs) - fabs = "[" + fabs.concat(",") + "]" + f.write("]") - var f = open(self._FABRICS, "w") - f.write(fabs) f.close() - tasmota.log(format("MTR: =Saved %i fabric(s) and %i session(s)", fabs_size, sessions_saved), 2) + tasmota.log(f"MTR: =Saved {fabrics_saved} fabric(s) and {sessions_saved} session(s)", 2) self.device.event_fabrics_saved() # signal event except .. as e, m tasmota.log("MTR: Session_Store::save Exception:" + str(e) + "|" + str(m), 2) diff --git a/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be b/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be index 13d723b39315..9c19e0b36712 100644 --- a/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be +++ b/lib/libesp32/berry_matter/src/embedded/Matter_TLV.be @@ -94,6 +94,9 @@ class Matter_TLV static class Matter_TLV_item # we keep a shortcut reference to the Matter_TLV class static var TLV = Matter_TLV + static var is_list = false + static var is_array = false + static var is_struct = false # parent tag to inherit vendor/profile/tag var parent var next_idx # next idx in buffer (when parsing) @@ -607,7 +610,10 @@ class Matter_TLV # class Matter_TLV_struct var _ end static class Matter_TLV_list : Matter_TLV_item - static var is_struct = false + # inherited + static var is_list = true + # static var is_array = false + # static var is_struct = false ################################################################################# def init(parent) @@ -825,6 +831,8 @@ class Matter_TLV # Matter_TLV_struct class ################################################################################# static class Matter_TLV_struct : Matter_TLV_list + static var is_list = false + # static var is_array = false static var is_struct = true def init(parent) @@ -843,6 +851,10 @@ class Matter_TLV # Matter_TLV_array class ################################################################################# static class Matter_TLV_array : Matter_TLV_list + static var is_list = false + static var is_array = true + # static var is_struct = false + def init(parent) super(self).init(parent) self.typ = self.TLV.ARRAY 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 978e5a3aa851..d4d7f5a9ef1d 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Commissioning.h @@ -69,18 +69,18 @@ be_local_closure(Matter_Commisioning_Context_find_fabric_by_destination_id, /* ( &(const bvalue[19]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(tasmota), - /* K2 */ be_nested_str_weak(log), - /* K3 */ be_nested_str_weak(MTR_X3A_X20SEARCHING_X3A_X20destinationId_X3D), - /* K4 */ be_nested_str_weak(tohex), - /* K5 */ be_nested_str_weak(device), - /* K6 */ be_nested_str_weak(sessions), - /* K7 */ be_nested_str_weak(fabrics), - /* K8 */ be_nested_str_weak(noc), - /* K9 */ be_nested_str_weak(fabric_id), - /* K10 */ be_nested_str_weak(device_id), - /* K11 */ be_nested_str_weak(get_ca_pub), - /* K12 */ be_nested_str_weak(get_ipk_group_key), - /* K13 */ be_nested_str_weak(MTR_X3A_X20SIGMA1_X3A_X20destinationMessage_X3D), + /* K2 */ be_nested_str_weak(loglevel), + /* K3 */ be_nested_str_weak(log), + /* K4 */ be_nested_str_weak(MTR_X3A_X20SEARCHING_X3A_X20destinationId_X3D), + /* K5 */ be_nested_str_weak(tohex), + /* K6 */ be_nested_str_weak(device), + /* K7 */ be_nested_str_weak(sessions), + /* K8 */ be_nested_str_weak(fabrics), + /* K9 */ be_nested_str_weak(noc), + /* K10 */ be_nested_str_weak(fabric_id), + /* K11 */ be_nested_str_weak(device_id), + /* K12 */ be_nested_str_weak(get_ca_pub), + /* K13 */ be_nested_str_weak(get_ipk_group_key), /* K14 */ be_nested_str_weak(HMAC_SHA256), /* K15 */ be_nested_str_weak(update), /* K16 */ be_nested_str_weak(out), @@ -89,77 +89,80 @@ be_local_closure(Matter_Commisioning_Context_find_fabric_by_destination_id, /* }), be_str_weak(find_fabric_by_destination_id), &be_const_str_solidified, - ( &(const binstruction[70]) { /* code */ + ( &(const binstruction[73]) { /* code */ 0xA40E0000, // 0000 IMPORT R3 K0 0xB8120200, // 0001 GETNGBL R4 K1 0x8C100902, // 0002 GETMET R4 R4 K2 - 0x8C180304, // 0003 GETMET R6 R1 K4 - 0x7C180200, // 0004 CALL R6 1 - 0x001A0606, // 0005 ADD R6 K3 R6 - 0x541E0003, // 0006 LDINT R7 4 - 0x7C100600, // 0007 CALL R4 3 - 0x60100010, // 0008 GETGBL R4 G16 - 0x88140105, // 0009 GETMBR R5 R0 K5 - 0x88140B06, // 000A GETMBR R5 R5 K6 - 0x88140B07, // 000B GETMBR R5 R5 K7 - 0x7C100200, // 000C CALL R4 1 - 0xA8020032, // 000D EXBLK 0 #0041 - 0x5C140800, // 000E MOVE R5 R4 - 0x7C140000, // 000F CALL R5 0 - 0x88180B08, // 0010 GETMBR R6 R5 K8 - 0x4C1C0000, // 0011 LDNIL R7 - 0x1C180C07, // 0012 EQ R6 R6 R7 - 0x741A0007, // 0013 JMPT R6 #001C - 0x88180B09, // 0014 GETMBR R6 R5 K9 - 0x4C1C0000, // 0015 LDNIL R7 - 0x1C180C07, // 0016 EQ R6 R6 R7 - 0x741A0003, // 0017 JMPT R6 #001C - 0x88180B0A, // 0018 GETMBR R6 R5 K10 - 0x4C1C0000, // 0019 LDNIL R7 - 0x1C180C07, // 001A EQ R6 R6 R7 - 0x781A0000, // 001B JMPF R6 #001D - 0x7001FFF0, // 001C JMP #000E - 0x8C180B0B, // 001D GETMET R6 R5 K11 - 0x7C180200, // 001E CALL R6 1 - 0x00180406, // 001F ADD R6 R2 R6 - 0x881C0B09, // 0020 GETMBR R7 R5 K9 - 0x00180C07, // 0021 ADD R6 R6 R7 - 0x881C0B0A, // 0022 GETMBR R7 R5 K10 - 0x00180C07, // 0023 ADD R6 R6 R7 - 0x8C1C0B0C, // 0024 GETMET R7 R5 K12 - 0x7C1C0200, // 0025 CALL R7 1 - 0xB8220200, // 0026 GETNGBL R8 K1 - 0x8C201102, // 0027 GETMET R8 R8 K2 - 0x8C280D04, // 0028 GETMET R10 R6 K4 - 0x7C280200, // 0029 CALL R10 1 - 0x002A1A0A, // 002A ADD R10 K13 R10 - 0x542E0003, // 002B LDINT R11 4 - 0x7C200600, // 002C CALL R8 3 - 0x8C20070E, // 002D GETMET R8 R3 K14 - 0x5C280E00, // 002E MOVE R10 R7 - 0x7C200400, // 002F CALL R8 2 - 0x8C24110F, // 0030 GETMET R9 R8 K15 - 0x5C2C0C00, // 0031 MOVE R11 R6 - 0x7C240400, // 0032 CALL R9 2 - 0x8C241110, // 0033 GETMET R9 R8 K16 - 0x7C240200, // 0034 CALL R9 1 - 0xB82A0200, // 0035 GETNGBL R10 K1 - 0x8C281502, // 0036 GETMET R10 R10 K2 - 0x8C301304, // 0037 GETMET R12 R9 K4 - 0x7C300200, // 0038 CALL R12 1 - 0x0032220C, // 0039 ADD R12 K17 R12 - 0x54360003, // 003A LDINT R13 4 - 0x7C280600, // 003B CALL R10 3 - 0x1C281201, // 003C EQ R10 R9 R1 - 0x782A0001, // 003D JMPF R10 #0040 - 0xA8040001, // 003E EXBLK 1 1 - 0x80040A00, // 003F RET 1 R5 - 0x7001FFCC, // 0040 JMP #000E - 0x58100012, // 0041 LDCONST R4 K18 - 0xAC100200, // 0042 CATCH R4 1 0 - 0xB0080000, // 0043 RAISE 2 R0 R0 - 0x4C100000, // 0044 LDNIL R4 - 0x80040800, // 0045 RET 1 R4 + 0x541A0003, // 0003 LDINT R6 4 + 0x7C100400, // 0004 CALL R4 2 + 0x78120006, // 0005 JMPF R4 #000D + 0xB8120200, // 0006 GETNGBL R4 K1 + 0x8C100903, // 0007 GETMET R4 R4 K3 + 0x8C180305, // 0008 GETMET R6 R1 K5 + 0x7C180200, // 0009 CALL R6 1 + 0x001A0806, // 000A ADD R6 K4 R6 + 0x541E0003, // 000B LDINT R7 4 + 0x7C100600, // 000C CALL R4 3 + 0x60100010, // 000D GETGBL R4 G16 + 0x88140106, // 000E GETMBR R5 R0 K6 + 0x88140B07, // 000F GETMBR R5 R5 K7 + 0x88140B08, // 0010 GETMBR R5 R5 K8 + 0x7C100200, // 0011 CALL R4 1 + 0xA8020030, // 0012 EXBLK 0 #0044 + 0x5C140800, // 0013 MOVE R5 R4 + 0x7C140000, // 0014 CALL R5 0 + 0x88180B09, // 0015 GETMBR R6 R5 K9 + 0x4C1C0000, // 0016 LDNIL R7 + 0x1C180C07, // 0017 EQ R6 R6 R7 + 0x741A0007, // 0018 JMPT R6 #0021 + 0x88180B0A, // 0019 GETMBR R6 R5 K10 + 0x4C1C0000, // 001A LDNIL R7 + 0x1C180C07, // 001B EQ R6 R6 R7 + 0x741A0003, // 001C JMPT R6 #0021 + 0x88180B0B, // 001D GETMBR R6 R5 K11 + 0x4C1C0000, // 001E LDNIL R7 + 0x1C180C07, // 001F EQ R6 R6 R7 + 0x781A0000, // 0020 JMPF R6 #0022 + 0x7001FFF0, // 0021 JMP #0013 + 0x8C180B0C, // 0022 GETMET R6 R5 K12 + 0x7C180200, // 0023 CALL R6 1 + 0x00180406, // 0024 ADD R6 R2 R6 + 0x881C0B0A, // 0025 GETMBR R7 R5 K10 + 0x00180C07, // 0026 ADD R6 R6 R7 + 0x881C0B0B, // 0027 GETMBR R7 R5 K11 + 0x00180C07, // 0028 ADD R6 R6 R7 + 0x8C1C0B0D, // 0029 GETMET R7 R5 K13 + 0x7C1C0200, // 002A CALL R7 1 + 0x8C20070E, // 002B GETMET R8 R3 K14 + 0x5C280E00, // 002C MOVE R10 R7 + 0x7C200400, // 002D CALL R8 2 + 0x8C24110F, // 002E GETMET R9 R8 K15 + 0x5C2C0C00, // 002F MOVE R11 R6 + 0x7C240400, // 0030 CALL R9 2 + 0x8C241110, // 0031 GETMET R9 R8 K16 + 0x7C240200, // 0032 CALL R9 1 + 0xB82A0200, // 0033 GETNGBL R10 K1 + 0x8C281502, // 0034 GETMET R10 R10 K2 + 0x54320003, // 0035 LDINT R12 4 + 0x7C280400, // 0036 CALL R10 2 + 0x782A0006, // 0037 JMPF R10 #003F + 0xB82A0200, // 0038 GETNGBL R10 K1 + 0x8C281503, // 0039 GETMET R10 R10 K3 + 0x8C301305, // 003A GETMET R12 R9 K5 + 0x7C300200, // 003B CALL R12 1 + 0x0032220C, // 003C ADD R12 K17 R12 + 0x54360003, // 003D LDINT R13 4 + 0x7C280600, // 003E CALL R10 3 + 0x1C281201, // 003F EQ R10 R9 R1 + 0x782A0001, // 0040 JMPF R10 #0043 + 0xA8040001, // 0041 EXBLK 1 1 + 0x80040A00, // 0042 RET 1 R5 + 0x7001FFCE, // 0043 JMP #0013 + 0x58100012, // 0044 LDCONST R4 K18 + 0xAC100200, // 0045 CATCH R4 1 0 + 0xB0080000, // 0046 RAISE 2 R0 R0 + 0x4C100000, // 0047 LDNIL R4 + 0x80040800, // 0048 RET 1 R4 }) ) ); 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 ce96a72604d1..32377c2c9f30 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Device.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Device.h @@ -3101,7 +3101,7 @@ be_local_closure(Matter_Device_autoconf_device_map, /* name */ /* K23 */ be_nested_str_weak(Relay1), /* K24 */ be_nested_str_weak(Relay2), /* K25 */ be_nested_str_weak(push), - /* K26 */ be_nested_str_weak(MTR_X3A_X20relay1_X20_X3D_X20_X25s_X2C_X20relay2_X20_X3D_X20_X25s), + /* K26 */ be_nested_str_weak(MTR_X3A_X20relay1_X3D_X25s_X20relay2_X3D_X25s), /* K27 */ be_nested_str_weak(TiltConfig), /* K28 */ be_nested_str_weak(shutter_X2Btilt), /* K29 */ be_nested_str_weak(shutter), @@ -3114,7 +3114,7 @@ be_local_closure(Matter_Device_autoconf_device_map, /* name */ }), be_str_weak(autoconf_device_map), &be_const_str_solidified, - ( &(const binstruction[199]) { /* code */ + ( &(const binstruction[198]) { /* code */ 0xA4060000, // 0000 IMPORT R1 K0 0x60080013, // 0001 GETGBL R2 G19 0x7C080000, // 0002 CALL R2 0 @@ -3180,15 +3180,15 @@ be_local_closure(Matter_Device_autoconf_device_map, /* name */ 0x7C240600, // 003E CALL R9 3 0x4C240000, // 003F LDNIL R9 0x20240E09, // 0040 NE R9 R7 R9 - 0x78260051, // 0041 JMPF R9 #0094 + 0x7826004F, // 0041 JMPF R9 #0092 0x8C240F13, // 0042 GETMET R9 R7 K19 0x582C0014, // 0043 LDCONST R11 K20 0x7C240400, // 0044 CALL R9 2 - 0x7826004D, // 0045 JMPF R9 #0094 + 0x7826004B, // 0045 JMPF R9 #0092 0x941C0F14, // 0046 GETIDX R7 R7 K20 0x58240007, // 0047 LDCONST R9 K7 0x50280200, // 0048 LDBOOL R10 1 0 - 0x782A0049, // 0049 JMPF R10 #0094 + 0x782A0047, // 0049 JMPF R10 #0092 0x60280008, // 004A GETGBL R10 G8 0x5C2C1200, // 004B MOVE R11 R9 0x7C280200, // 004C CALL R10 1 @@ -3197,7 +3197,7 @@ be_local_closure(Matter_Device_autoconf_device_map, /* name */ 0x5C341400, // 004F MOVE R13 R10 0x7C2C0400, // 0050 CALL R11 2 0x742E0000, // 0051 JMPT R11 #0053 - 0x70020040, // 0052 JMP #0094 + 0x7002003E, // 0052 JMP #0092 0x942C0E0A, // 0053 GETIDX R11 R7 R10 0xB8321A00, // 0054 GETNGBL R12 K13 0x8C301910, // 0055 GETMET R12 R12 K16 @@ -3212,108 +3212,107 @@ be_local_closure(Matter_Device_autoconf_device_map, /* name */ 0x7C300600, // 005E CALL R12 3 0x8C301704, // 005F GETMET R12 R11 K4 0x58380017, // 0060 LDCONST R14 K23 - 0x583C0007, // 0061 LDCONST R15 K7 + 0x543DFFFE, // 0061 LDINT R15 -1 0x7C300600, // 0062 CALL R12 3 - 0x04301901, // 0063 SUB R12 R12 K1 - 0x8C341704, // 0064 GETMET R13 R11 K4 - 0x583C0018, // 0065 LDCONST R15 K24 - 0x58400007, // 0066 LDCONST R16 K7 - 0x7C340600, // 0067 CALL R13 3 - 0x04341B01, // 0068 SUB R13 R13 K1 - 0x28381907, // 0069 GE R14 R12 K7 - 0x783A0002, // 006A JMPF R14 #006E - 0x8C381119, // 006B GETMET R14 R8 K25 - 0x5C401800, // 006C MOVE R16 R12 - 0x7C380400, // 006D CALL R14 2 - 0x28381B07, // 006E GE R14 R13 K7 - 0x783A0002, // 006F JMPF R14 #0073 - 0x8C381119, // 0070 GETMET R14 R8 K25 - 0x5C401A00, // 0071 MOVE R16 R13 - 0x7C380400, // 0072 CALL R14 2 - 0xB83A1A00, // 0073 GETNGBL R14 K13 - 0x8C381D10, // 0074 GETMET R14 R14 K16 - 0x60400018, // 0075 GETGBL R16 G24 - 0x5844001A, // 0076 LDCONST R17 K26 - 0x5C481800, // 0077 MOVE R18 R12 - 0x5C4C1A00, // 0078 MOVE R19 R13 - 0x7C400600, // 0079 CALL R16 3 - 0x58440012, // 007A LDCONST R17 K18 - 0x7C380600, // 007B CALL R14 3 - 0x8C381704, // 007C GETMET R14 R11 K4 - 0x5840001B, // 007D LDCONST R16 K27 - 0x7C380400, // 007E CALL R14 2 - 0x783A0002, // 007F JMPF R14 #0083 - 0x943C1D0A, // 0080 GETIDX R15 R14 K10 - 0x243C1F07, // 0081 GT R15 R15 K7 - 0x743E0000, // 0082 JMPT R15 #0084 - 0x503C0001, // 0083 LDBOOL R15 0 1 - 0x503C0200, // 0084 LDBOOL R15 1 0 - 0x60400008, // 0085 GETGBL R16 G8 - 0x5C440600, // 0086 MOVE R17 R3 - 0x7C400200, // 0087 CALL R16 1 - 0x60440013, // 0088 GETGBL R17 G19 - 0x7C440000, // 0089 CALL R17 0 - 0x783E0001, // 008A JMPF R15 #008D - 0x5848001C, // 008B LDCONST R18 K28 - 0x70020000, // 008C JMP #008E - 0x5848001D, // 008D LDCONST R18 K29 - 0x98461012, // 008E SETIDX R17 K8 R18 - 0x98463A09, // 008F SETIDX R17 K29 R9 - 0x98082011, // 0090 SETIDX R2 R16 R17 - 0x000C0701, // 0091 ADD R3 R3 K1 - 0x00241301, // 0092 ADD R9 R9 K1 - 0x7001FFB3, // 0093 JMP #0048 - 0x6024000C, // 0094 GETGBL R9 G12 - 0xB82A1A00, // 0095 GETNGBL R10 K13 - 0x8C28151E, // 0096 GETMET R10 R10 K30 - 0x7C280200, // 0097 CALL R10 1 - 0x7C240200, // 0098 CALL R9 1 - 0x58280007, // 0099 LDCONST R10 K7 - 0x78120000, // 009A JMPF R4 #009C - 0x04241301, // 009B SUB R9 R9 K1 - 0x142C1409, // 009C LT R11 R10 R9 - 0x782E0010, // 009D JMPF R11 #00AF - 0x8C2C1104, // 009E GETMET R11 R8 K4 - 0x5C341400, // 009F MOVE R13 R10 - 0x7C2C0400, // 00A0 CALL R11 2 - 0x4C300000, // 00A1 LDNIL R12 - 0x1C2C160C, // 00A2 EQ R11 R11 R12 - 0x782E0008, // 00A3 JMPF R11 #00AD - 0x602C0008, // 00A4 GETGBL R11 G8 - 0x5C300600, // 00A5 MOVE R12 R3 - 0x7C2C0200, // 00A6 CALL R11 1 - 0x60300013, // 00A7 GETGBL R12 G19 - 0x7C300000, // 00A8 CALL R12 0 - 0x9832111F, // 00A9 SETIDX R12 K8 K31 - 0x98323E0A, // 00AA SETIDX R12 K31 R10 - 0x9808160C, // 00AB SETIDX R2 R11 R12 - 0x000C0701, // 00AC ADD R3 R3 K1 - 0x00281501, // 00AD ADD R10 R10 K1 - 0x7001FFEC, // 00AE JMP #009C - 0x8C2C0320, // 00AF GETMET R11 R1 K32 - 0xB8361A00, // 00B0 GETNGBL R13 K13 - 0x8C341B21, // 00B1 GETMET R13 R13 K33 - 0x7C340200, // 00B2 CALL R13 1 - 0x7C2C0400, // 00B3 CALL R11 2 - 0x8C300122, // 00B4 GETMET R12 R0 K34 - 0x5C381600, // 00B5 MOVE R14 R11 - 0x7C300400, // 00B6 CALL R12 2 - 0x60340010, // 00B7 GETGBL R13 G16 - 0x5C381800, // 00B8 MOVE R14 R12 - 0x7C340200, // 00B9 CALL R13 1 - 0xA8020007, // 00BA EXBLK 0 #00C3 - 0x5C381A00, // 00BB MOVE R14 R13 - 0x7C380000, // 00BC CALL R14 0 - 0x603C0008, // 00BD GETGBL R15 G8 - 0x5C400600, // 00BE MOVE R16 R3 - 0x7C3C0200, // 00BF CALL R15 1 - 0x98081E0E, // 00C0 SETIDX R2 R15 R14 - 0x000C0701, // 00C1 ADD R3 R3 K1 - 0x7001FFF7, // 00C2 JMP #00BB - 0x58340023, // 00C3 LDCONST R13 K35 - 0xAC340200, // 00C4 CATCH R13 1 0 - 0xB0080000, // 00C5 RAISE 2 R0 R0 - 0x80040400, // 00C6 RET 1 R2 + 0x8C341704, // 0063 GETMET R13 R11 K4 + 0x583C0018, // 0064 LDCONST R15 K24 + 0x5441FFFE, // 0065 LDINT R16 -1 + 0x7C340600, // 0066 CALL R13 3 + 0x24381907, // 0067 GT R14 R12 K7 + 0x783A0002, // 0068 JMPF R14 #006C + 0x8C381119, // 0069 GETMET R14 R8 K25 + 0x04401901, // 006A SUB R16 R12 K1 + 0x7C380400, // 006B CALL R14 2 + 0x24381B07, // 006C GT R14 R13 K7 + 0x783A0002, // 006D JMPF R14 #0071 + 0x8C381119, // 006E GETMET R14 R8 K25 + 0x04401B01, // 006F SUB R16 R13 K1 + 0x7C380400, // 0070 CALL R14 2 + 0xB83A1A00, // 0071 GETNGBL R14 K13 + 0x8C381D10, // 0072 GETMET R14 R14 K16 + 0x60400018, // 0073 GETGBL R16 G24 + 0x5844001A, // 0074 LDCONST R17 K26 + 0x5C481800, // 0075 MOVE R18 R12 + 0x5C4C1A00, // 0076 MOVE R19 R13 + 0x7C400600, // 0077 CALL R16 3 + 0x58440012, // 0078 LDCONST R17 K18 + 0x7C380600, // 0079 CALL R14 3 + 0x8C381704, // 007A GETMET R14 R11 K4 + 0x5840001B, // 007B LDCONST R16 K27 + 0x7C380400, // 007C CALL R14 2 + 0x783A0002, // 007D JMPF R14 #0081 + 0x943C1D0A, // 007E GETIDX R15 R14 K10 + 0x243C1F07, // 007F GT R15 R15 K7 + 0x743E0000, // 0080 JMPT R15 #0082 + 0x503C0001, // 0081 LDBOOL R15 0 1 + 0x503C0200, // 0082 LDBOOL R15 1 0 + 0x60400008, // 0083 GETGBL R16 G8 + 0x5C440600, // 0084 MOVE R17 R3 + 0x7C400200, // 0085 CALL R16 1 + 0x60440013, // 0086 GETGBL R17 G19 + 0x7C440000, // 0087 CALL R17 0 + 0x783E0001, // 0088 JMPF R15 #008B + 0x5848001C, // 0089 LDCONST R18 K28 + 0x70020000, // 008A JMP #008C + 0x5848001D, // 008B LDCONST R18 K29 + 0x98461012, // 008C SETIDX R17 K8 R18 + 0x98463A09, // 008D SETIDX R17 K29 R9 + 0x98082011, // 008E SETIDX R2 R16 R17 + 0x000C0701, // 008F ADD R3 R3 K1 + 0x00241301, // 0090 ADD R9 R9 K1 + 0x7001FFB5, // 0091 JMP #0048 + 0x6024000C, // 0092 GETGBL R9 G12 + 0xB82A1A00, // 0093 GETNGBL R10 K13 + 0x8C28151E, // 0094 GETMET R10 R10 K30 + 0x7C280200, // 0095 CALL R10 1 + 0x7C240200, // 0096 CALL R9 1 + 0x58280007, // 0097 LDCONST R10 K7 + 0x78120000, // 0098 JMPF R4 #009A + 0x04241301, // 0099 SUB R9 R9 K1 + 0x142C1409, // 009A LT R11 R10 R9 + 0x782E0011, // 009B JMPF R11 #00AE + 0x8C2C1104, // 009C GETMET R11 R8 K4 + 0x5C341400, // 009D MOVE R13 R10 + 0x7C2C0400, // 009E CALL R11 2 + 0x4C300000, // 009F LDNIL R12 + 0x1C2C160C, // 00A0 EQ R11 R11 R12 + 0x782E0009, // 00A1 JMPF R11 #00AC + 0x602C0008, // 00A2 GETGBL R11 G8 + 0x5C300600, // 00A3 MOVE R12 R3 + 0x7C2C0200, // 00A4 CALL R11 1 + 0x60300013, // 00A5 GETGBL R12 G19 + 0x7C300000, // 00A6 CALL R12 0 + 0x9832111F, // 00A7 SETIDX R12 K8 K31 + 0x00341501, // 00A8 ADD R13 R10 K1 + 0x98323E0D, // 00A9 SETIDX R12 K31 R13 + 0x9808160C, // 00AA SETIDX R2 R11 R12 + 0x000C0701, // 00AB ADD R3 R3 K1 + 0x00281501, // 00AC ADD R10 R10 K1 + 0x7001FFEB, // 00AD JMP #009A + 0x8C2C0320, // 00AE GETMET R11 R1 K32 + 0xB8361A00, // 00AF GETNGBL R13 K13 + 0x8C341B21, // 00B0 GETMET R13 R13 K33 + 0x7C340200, // 00B1 CALL R13 1 + 0x7C2C0400, // 00B2 CALL R11 2 + 0x8C300122, // 00B3 GETMET R12 R0 K34 + 0x5C381600, // 00B4 MOVE R14 R11 + 0x7C300400, // 00B5 CALL R12 2 + 0x60340010, // 00B6 GETGBL R13 G16 + 0x5C381800, // 00B7 MOVE R14 R12 + 0x7C340200, // 00B8 CALL R13 1 + 0xA8020007, // 00B9 EXBLK 0 #00C2 + 0x5C381A00, // 00BA MOVE R14 R13 + 0x7C380000, // 00BB CALL R14 0 + 0x603C0008, // 00BC GETGBL R15 G8 + 0x5C400600, // 00BD MOVE R16 R3 + 0x7C3C0200, // 00BE CALL R15 1 + 0x98081E0E, // 00BF SETIDX R2 R15 R14 + 0x000C0701, // 00C0 ADD R3 R3 K1 + 0x7001FFF7, // 00C1 JMP #00BA + 0x58340023, // 00C2 LDCONST R13 K35 + 0xAC340200, // 00C3 CATCH R13 1 0 + 0xB0080000, // 00C4 RAISE 2 R0 R0 + 0x80040400, // 00C5 RET 1 R2 }) ) ); @@ -5507,7 +5506,7 @@ be_local_closure(Matter_Device_autoconf_device, /* name */ ********************************************************************/ be_local_closure(Matter_Device_remove_fabric, /* name */ be_nested_proto( - 10, /* nstack */ + 6, /* nstack */ 2, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -5515,87 +5514,60 @@ be_local_closure(Matter_Device_remove_fabric, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[20]) { /* constants */ - /* K0 */ be_nested_str_weak(sessions), - /* K1 */ be_nested_str_weak(find_children_fabrics), - /* K2 */ be_nested_str_weak(get_fabric_index), - /* K3 */ be_nested_str_weak(find_fabric_by_index), - /* K4 */ be_nested_str_weak(tasmota), - /* K5 */ be_nested_str_weak(log), - /* K6 */ be_nested_str_weak(MTR_X3A_X20removing_X20fabric_X20), - /* K7 */ be_nested_str_weak(get_fabric_id), - /* K8 */ be_nested_str_weak(copy), - /* K9 */ be_nested_str_weak(reverse), - /* K10 */ be_nested_str_weak(tohex), - /* K11 */ be_const_int(2), - /* K12 */ be_nested_str_weak(message_handler), - /* K13 */ be_nested_str_weak(im), - /* K14 */ be_nested_str_weak(subs_shop), - /* K15 */ be_nested_str_weak(remove_by_fabric), - /* K16 */ be_nested_str_weak(mdns_remove_op_discovery), - /* K17 */ be_nested_str_weak(remove_fabric), - /* K18 */ be_nested_str_weak(stop_iteration), - /* K19 */ be_nested_str_weak(save_fabrics), + ( &(const bvalue[16]) { /* constants */ + /* K0 */ be_nested_str_weak(tasmota), + /* K1 */ be_nested_str_weak(log), + /* K2 */ be_nested_str_weak(MTR_X3A_X20removing_X20fabric_X20), + /* K3 */ be_nested_str_weak(get_fabric_id), + /* K4 */ be_nested_str_weak(copy), + /* K5 */ be_nested_str_weak(reverse), + /* K6 */ be_nested_str_weak(tohex), + /* K7 */ be_const_int(2), + /* K8 */ be_nested_str_weak(message_handler), + /* K9 */ be_nested_str_weak(im), + /* K10 */ be_nested_str_weak(subs_shop), + /* K11 */ be_nested_str_weak(remove_by_fabric), + /* K12 */ be_nested_str_weak(mdns_remove_op_discovery), + /* K13 */ be_nested_str_weak(sessions), + /* K14 */ be_nested_str_weak(remove_fabric), + /* K15 */ be_nested_str_weak(save_fabrics), }), be_str_weak(remove_fabric), &be_const_str_solidified, - ( &(const binstruction[56]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x8C100302, // 0002 GETMET R4 R1 K2 - 0x7C100200, // 0003 CALL R4 1 - 0x7C080400, // 0004 CALL R2 2 - 0x4C0C0000, // 0005 LDNIL R3 - 0x1C0C0403, // 0006 EQ R3 R2 R3 - 0x780E0000, // 0007 JMPF R3 #0009 - 0x80000600, // 0008 RET 0 - 0x600C0010, // 0009 GETGBL R3 G16 - 0x5C100400, // 000A MOVE R4 R2 - 0x7C0C0200, // 000B CALL R3 1 - 0xA8020023, // 000C EXBLK 0 #0031 - 0x5C100600, // 000D MOVE R4 R3 - 0x7C100000, // 000E CALL R4 0 - 0x88140100, // 000F GETMBR R5 R0 K0 - 0x8C140B03, // 0010 GETMET R5 R5 K3 - 0x5C1C0800, // 0011 MOVE R7 R4 - 0x7C140400, // 0012 CALL R5 2 - 0x4C180000, // 0013 LDNIL R6 - 0x20180A06, // 0014 NE R6 R5 R6 - 0x781A0019, // 0015 JMPF R6 #0030 - 0xB81A0800, // 0016 GETNGBL R6 K4 - 0x8C180D05, // 0017 GETMET R6 R6 K5 - 0x8C200B07, // 0018 GETMET R8 R5 K7 - 0x7C200200, // 0019 CALL R8 1 - 0x8C201108, // 001A GETMET R8 R8 K8 - 0x7C200200, // 001B CALL R8 1 - 0x8C201109, // 001C GETMET R8 R8 K9 - 0x7C200200, // 001D CALL R8 1 - 0x8C20110A, // 001E GETMET R8 R8 K10 - 0x7C200200, // 001F CALL R8 1 - 0x00220C08, // 0020 ADD R8 K6 R8 - 0x5824000B, // 0021 LDCONST R9 K11 - 0x7C180600, // 0022 CALL R6 3 - 0x8818010C, // 0023 GETMBR R6 R0 K12 - 0x88180D0D, // 0024 GETMBR R6 R6 K13 - 0x88180D0E, // 0025 GETMBR R6 R6 K14 - 0x8C180D0F, // 0026 GETMET R6 R6 K15 - 0x5C200A00, // 0027 MOVE R8 R5 - 0x7C180400, // 0028 CALL R6 2 - 0x8C180110, // 0029 GETMET R6 R0 K16 - 0x5C200A00, // 002A MOVE R8 R5 - 0x7C180400, // 002B CALL R6 2 - 0x88180100, // 002C GETMBR R6 R0 K0 - 0x8C180D11, // 002D GETMET R6 R6 K17 - 0x5C200A00, // 002E MOVE R8 R5 - 0x7C180400, // 002F CALL R6 2 - 0x7001FFDB, // 0030 JMP #000D - 0x580C0012, // 0031 LDCONST R3 K18 - 0xAC0C0200, // 0032 CATCH R3 1 0 - 0xB0080000, // 0033 RAISE 2 R0 R0 - 0x880C0100, // 0034 GETMBR R3 R0 K0 - 0x8C0C0713, // 0035 GETMET R3 R3 K19 - 0x7C0C0200, // 0036 CALL R3 1 - 0x80000000, // 0037 RET 0 + ( &(const binstruction[33]) { /* code */ + 0x4C080000, // 0000 LDNIL R2 + 0x20080202, // 0001 NE R2 R1 R2 + 0x780A0019, // 0002 JMPF R2 #001D + 0xB80A0000, // 0003 GETNGBL R2 K0 + 0x8C080501, // 0004 GETMET R2 R2 K1 + 0x8C100303, // 0005 GETMET R4 R1 K3 + 0x7C100200, // 0006 CALL R4 1 + 0x8C100904, // 0007 GETMET R4 R4 K4 + 0x7C100200, // 0008 CALL R4 1 + 0x8C100905, // 0009 GETMET R4 R4 K5 + 0x7C100200, // 000A CALL R4 1 + 0x8C100906, // 000B GETMET R4 R4 K6 + 0x7C100200, // 000C CALL R4 1 + 0x00120404, // 000D ADD R4 K2 R4 + 0x58140007, // 000E LDCONST R5 K7 + 0x7C080600, // 000F CALL R2 3 + 0x88080108, // 0010 GETMBR R2 R0 K8 + 0x88080509, // 0011 GETMBR R2 R2 K9 + 0x8808050A, // 0012 GETMBR R2 R2 K10 + 0x8C08050B, // 0013 GETMET R2 R2 K11 + 0x5C100200, // 0014 MOVE R4 R1 + 0x7C080400, // 0015 CALL R2 2 + 0x8C08010C, // 0016 GETMET R2 R0 K12 + 0x5C100200, // 0017 MOVE R4 R1 + 0x7C080400, // 0018 CALL R2 2 + 0x8808010D, // 0019 GETMBR R2 R0 K13 + 0x8C08050E, // 001A GETMET R2 R2 K14 + 0x5C100200, // 001B MOVE R4 R1 + 0x7C080400, // 001C CALL R2 2 + 0x8808010D, // 001D GETMBR R2 R0 K13 + 0x8C08050F, // 001E GETMET R2 R2 K15 + 0x7C080200, // 001F CALL R2 1 + 0x80000000, // 0020 RET 0 }) ) ); 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 ec19acea4476..e9a29ad821f2 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_IM.h @@ -292,8 +292,8 @@ be_local_closure(Matter_IM_process_timed_request, /* name */ ********************************************************************/ be_local_closure(Matter_IM_attributedata2raw, /* name */ be_nested_proto( - 9, /* nstack */ - 4, /* argc */ + 11, /* nstack */ + 5, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -311,29 +311,30 @@ be_local_closure(Matter_IM_attributedata2raw, /* name */ }), be_str_weak(attributedata2raw), &be_const_str_solidified, - ( &(const binstruction[22]) { /* code */ - 0x8C100300, // 0000 GETMET R4 R1 K0 - 0x58180001, // 0001 LDCONST R6 K1 - 0x541DFFFB, // 0002 LDINT R7 -4 - 0x7C100600, // 0003 CALL R4 3 - 0x8C100300, // 0004 GETMET R4 R1 K0 - 0x58180002, // 0005 LDCONST R6 K2 - 0x541DFFFD, // 0006 LDINT R7 -2 - 0x7C100600, // 0007 CALL R4 3 - 0x8C100103, // 0008 GETMET R4 R0 K3 - 0x5C180200, // 0009 MOVE R6 R1 - 0x5C1C0400, // 000A MOVE R7 R2 - 0x58200002, // 000B LDCONST R8 K2 - 0x7C100800, // 000C CALL R4 4 - 0x900E0905, // 000D SETMBR R3 K4 K5 - 0x8C100706, // 000E GETMET R4 R3 K6 - 0x5C180200, // 000F MOVE R6 R1 - 0x7C100400, // 0010 CALL R4 2 - 0x8C100300, // 0011 GETMET R4 R1 K0 - 0x541A1817, // 0012 LDINT R6 6168 - 0x541DFFFD, // 0013 LDINT R7 -2 - 0x7C100600, // 0014 CALL R4 3 - 0x80000000, // 0015 RET 0 + ( &(const binstruction[23]) { /* code */ + 0x8C140300, // 0000 GETMET R5 R1 K0 + 0x581C0001, // 0001 LDCONST R7 K1 + 0x5421FFFB, // 0002 LDINT R8 -4 + 0x7C140600, // 0003 CALL R5 3 + 0x8C140300, // 0004 GETMET R5 R1 K0 + 0x581C0002, // 0005 LDCONST R7 K2 + 0x5421FFFD, // 0006 LDINT R8 -2 + 0x7C140600, // 0007 CALL R5 3 + 0x8C140103, // 0008 GETMET R5 R0 K3 + 0x5C1C0200, // 0009 MOVE R7 R1 + 0x5C200400, // 000A MOVE R8 R2 + 0x58240002, // 000B LDCONST R9 K2 + 0x5C280800, // 000C MOVE R10 R4 + 0x7C140A00, // 000D CALL R5 5 + 0x900E0905, // 000E SETMBR R3 K4 K5 + 0x8C140706, // 000F GETMET R5 R3 K6 + 0x5C1C0200, // 0010 MOVE R7 R1 + 0x7C140400, // 0011 CALL R5 2 + 0x8C140300, // 0012 GETMET R5 R1 K0 + 0x541E1817, // 0013 LDINT R7 6168 + 0x5421FFFD, // 0014 LDINT R8 -2 + 0x7C140600, // 0015 CALL R5 3 + 0x80000000, // 0016 RET 0 }) ) ); @@ -1177,7 +1178,7 @@ be_local_closure(Matter_IM_process_read_request, /* name */ }), be_str_weak(process_read_request), &be_const_str_solidified, - ( &(const binstruction[25]) { /* code */ + ( &(const binstruction[26]) { /* code */ 0xB80E0000, // 0000 GETNGBL R3 K0 0x880C0701, // 0001 GETMBR R3 R3 K1 0x8C0C0702, // 0002 GETMET R3 R3 K2 @@ -1192,17 +1193,18 @@ be_local_closure(Matter_IM_process_read_request, /* name */ 0x88100706, // 000B GETMBR R4 R3 K6 0x4C140000, // 000C LDNIL R5 0x20100805, // 000D NE R4 R4 R5 - 0x78120007, // 000E JMPF R4 #0017 + 0x78120008, // 000E JMPF R4 #0018 0x8C100107, // 000F GETMET R4 R0 K7 0x88180308, // 0010 GETMBR R6 R1 K8 0x5C1C0600, // 0011 MOVE R7 R3 - 0x7C100600, // 0012 CALL R4 3 - 0x8C140109, // 0013 GETMET R5 R0 K9 - 0x5C1C0200, // 0014 MOVE R7 R1 - 0x5C200800, // 0015 MOVE R8 R4 - 0x7C140600, // 0016 CALL R5 3 - 0x50100200, // 0017 LDBOOL R4 1 0 - 0x80040800, // 0018 RET 1 R4 + 0x5C200200, // 0012 MOVE R8 R1 + 0x7C100800, // 0013 CALL R4 4 + 0x8C140109, // 0014 GETMET R5 R0 K9 + 0x5C1C0200, // 0015 MOVE R7 R1 + 0x5C200800, // 0016 MOVE R8 R4 + 0x7C140600, // 0017 CALL R5 3 + 0x50100200, // 0018 LDBOOL R4 1 0 + 0x80040800, // 0019 RET 1 R4 }) ) ); @@ -1469,7 +1471,7 @@ be_local_closure(Matter_IM_process_write_request, /* name */ ), }), 1, /* has constants */ - ( &(const bvalue[29]) { /* constants */ + ( &(const bvalue[30]) { /* constants */ /* K0 */ be_nested_str_weak(matter), /* K1 */ be_nested_str_weak(WriteRequestMessage), /* K2 */ be_nested_str_weak(from_TLV), @@ -1477,32 +1479,33 @@ be_local_closure(Matter_IM_process_write_request, /* name */ /* K4 */ be_nested_str_weak(device), /* K5 */ be_nested_str_weak(get_active_endpoints), /* K6 */ be_nested_str_weak(Path), - /* K7 */ be_nested_str_weak(write_requests), - /* K8 */ be_nested_str_weak(WriteResponseMessage), - /* K9 */ be_nested_str_weak(write_responses), - /* K10 */ be_nested_str_weak(path), - /* K11 */ be_nested_str_weak(data), - /* K12 */ be_nested_str_weak(endpoint), - /* K13 */ be_nested_str_weak(cluster), - /* K14 */ be_nested_str_weak(attribute), - /* K15 */ be_nested_str_weak(status), - /* K16 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), - /* K17 */ be_nested_str_weak(INVALID_ACTION), - /* K18 */ be_nested_str_weak(get_attribute_name), - /* K19 */ be_nested_str_weak(tasmota), - /* K20 */ be_nested_str_weak(log), - /* K21 */ be_nested_str_weak(MTR_X3A_X20Write_Attr_X20), - /* K22 */ be_nested_str_weak(_X20_X28), - /* K23 */ be_nested_str_weak(_X29), - /* K24 */ be_nested_str_weak(), - /* K25 */ be_const_int(3), - /* K26 */ be_nested_str_weak(process_attribute_expansion), - /* K27 */ be_nested_str_weak(stop_iteration), - /* K28 */ be_nested_str_weak(send_write_response), + /* K7 */ be_nested_str_weak(msg), + /* K8 */ be_nested_str_weak(write_requests), + /* K9 */ be_nested_str_weak(WriteResponseMessage), + /* K10 */ be_nested_str_weak(write_responses), + /* K11 */ be_nested_str_weak(path), + /* K12 */ be_nested_str_weak(data), + /* 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(INVALID_ACTION), + /* K19 */ be_nested_str_weak(get_attribute_name), + /* K20 */ be_nested_str_weak(tasmota), + /* K21 */ be_nested_str_weak(log), + /* K22 */ be_nested_str_weak(MTR_X3A_X20Write_Attr_X20), + /* K23 */ be_nested_str_weak(_X20_X28), + /* K24 */ be_nested_str_weak(_X29), + /* K25 */ be_nested_str_weak(), + /* K26 */ be_const_int(3), + /* K27 */ be_nested_str_weak(process_attribute_expansion), + /* K28 */ be_nested_str_weak(stop_iteration), + /* K29 */ be_nested_str_weak(send_write_response), }), be_str_weak(process_write_request), &be_const_str_solidified, - ( &(const binstruction[103]) { /* code */ + ( &(const binstruction[104]) { /* code */ 0xB80E0000, // 0000 GETNGBL R3 K0 0x8C0C0701, // 0001 GETMET R3 R3 K1 0x7C0C0200, // 0002 CALL R3 1 @@ -1517,95 +1520,96 @@ be_local_closure(Matter_IM_process_write_request, /* name */ 0xB81E0000, // 000B GETNGBL R7 K0 0x8C1C0F06, // 000C GETMET R7 R7 K6 0x7C1C0200, // 000D CALL R7 1 - 0x88200707, // 000E GETMBR R8 R3 K7 - 0x4C240000, // 000F LDNIL R9 - 0x20201009, // 0010 NE R8 R8 R9 - 0x78220051, // 0011 JMPF R8 #0064 - 0xB8220000, // 0012 GETNGBL R8 K0 - 0x8C201108, // 0013 GETMET R8 R8 K8 - 0x7C200200, // 0014 CALL R8 1 - 0x60240012, // 0015 GETGBL R9 G18 - 0x7C240000, // 0016 CALL R9 0 - 0x90221209, // 0017 SETMBR R8 K9 R9 - 0x60240010, // 0018 GETGBL R9 G16 - 0x88280707, // 0019 GETMBR R10 R3 K7 - 0x7C240200, // 001A CALL R9 1 - 0xA802003D, // 001B EXBLK 0 #005A - 0x5C281200, // 001C MOVE R10 R9 - 0x7C280000, // 001D CALL R10 0 - 0x882C150A, // 001E GETMBR R11 R10 K10 - 0x8830150B, // 001F GETMBR R12 R10 K11 - 0x8834170C, // 0020 GETMBR R13 R11 K12 - 0x901E180D, // 0021 SETMBR R7 K12 R13 - 0x8834170D, // 0022 GETMBR R13 R11 K13 - 0x901E1A0D, // 0023 SETMBR R7 K13 R13 - 0x8834170E, // 0024 GETMBR R13 R11 K14 - 0x901E1C0D, // 0025 SETMBR R7 K14 R13 - 0xB8360000, // 0026 GETNGBL R13 K0 - 0x88341B10, // 0027 GETMBR R13 R13 K16 - 0x901E1E0D, // 0028 SETMBR R7 K15 R13 - 0x88340F0D, // 0029 GETMBR R13 R7 K13 - 0x4C380000, // 002A LDNIL R14 - 0x1C341A0E, // 002B EQ R13 R13 R14 - 0x74360003, // 002C JMPT R13 #0031 - 0x88340F0E, // 002D GETMBR R13 R7 K14 - 0x4C380000, // 002E LDNIL R14 - 0x1C341A0E, // 002F EQ R13 R13 R14 - 0x7836000A, // 0030 JMPF R13 #003C - 0xB8360000, // 0031 GETNGBL R13 K0 - 0x88341B11, // 0032 GETMBR R13 R13 K17 - 0x901E1E0D, // 0033 SETMBR R7 K15 R13 - 0x5C340C00, // 0034 MOVE R13 R6 - 0x5C381000, // 0035 MOVE R14 R8 - 0x4C3C0000, // 0036 LDNIL R15 - 0x5C400E00, // 0037 MOVE R16 R7 - 0x4C440000, // 0038 LDNIL R17 - 0x50480200, // 0039 LDBOOL R18 1 0 - 0x7C340A00, // 003A CALL R13 5 - 0x7001FFDF, // 003B JMP #001C - 0x88340F0C, // 003C GETMBR R13 R7 K12 - 0x4C380000, // 003D LDNIL R14 - 0x1C341A0E, // 003E EQ R13 R13 R14 - 0x78360012, // 003F JMPF R13 #0053 - 0xB8360000, // 0040 GETNGBL R13 K0 - 0x8C341B12, // 0041 GETMET R13 R13 K18 - 0x883C0F0D, // 0042 GETMBR R15 R7 K13 - 0x88400F0E, // 0043 GETMBR R16 R7 K14 - 0x7C340600, // 0044 CALL R13 3 - 0xB83A2600, // 0045 GETNGBL R14 K19 - 0x8C381D14, // 0046 GETMET R14 R14 K20 - 0x60400008, // 0047 GETGBL R16 G8 - 0x5C440E00, // 0048 MOVE R17 R7 - 0x7C400200, // 0049 CALL R16 1 - 0x00422A10, // 004A ADD R16 K21 R16 - 0x78360002, // 004B JMPF R13 #004F - 0x00462C0D, // 004C ADD R17 K22 R13 - 0x00442317, // 004D ADD R17 R17 K23 - 0x70020000, // 004E JMP #0050 - 0x58440018, // 004F LDCONST R17 K24 - 0x00402011, // 0050 ADD R16 R16 R17 - 0x58440019, // 0051 LDCONST R17 K25 - 0x7C380600, // 0052 CALL R14 3 - 0x88340104, // 0053 GETMBR R13 R0 K4 - 0x8C341B1A, // 0054 GETMET R13 R13 K26 - 0x5C3C0E00, // 0055 MOVE R15 R7 - 0x84400001, // 0056 CLOSURE R16 P1 - 0x7C340600, // 0057 CALL R13 3 - 0xA0240000, // 0058 CLOSE R9 - 0x7001FFC1, // 0059 JMP #001C - 0x5824001B, // 005A LDCONST R9 K27 - 0xAC240200, // 005B CATCH R9 1 0 - 0xB0080000, // 005C RAISE 2 R0 R0 - 0x5C240800, // 005D MOVE R9 R4 - 0x74260003, // 005E JMPT R9 #0063 - 0x8C24011C, // 005F GETMET R9 R0 K28 - 0x5C2C0200, // 0060 MOVE R11 R1 - 0x5C301000, // 0061 MOVE R12 R8 - 0x7C240600, // 0062 CALL R9 3 - 0xA0200000, // 0063 CLOSE R8 - 0x50200200, // 0064 LDBOOL R8 1 0 - 0xA0000000, // 0065 CLOSE R0 - 0x80041000, // 0066 RET 1 R8 + 0x901E0E01, // 000E SETMBR R7 K7 R1 + 0x88200708, // 000F GETMBR R8 R3 K8 + 0x4C240000, // 0010 LDNIL R9 + 0x20201009, // 0011 NE R8 R8 R9 + 0x78220051, // 0012 JMPF R8 #0065 + 0xB8220000, // 0013 GETNGBL R8 K0 + 0x8C201109, // 0014 GETMET R8 R8 K9 + 0x7C200200, // 0015 CALL R8 1 + 0x60240012, // 0016 GETGBL R9 G18 + 0x7C240000, // 0017 CALL R9 0 + 0x90221409, // 0018 SETMBR R8 K10 R9 + 0x60240010, // 0019 GETGBL R9 G16 + 0x88280708, // 001A GETMBR R10 R3 K8 + 0x7C240200, // 001B CALL R9 1 + 0xA802003D, // 001C EXBLK 0 #005B + 0x5C281200, // 001D MOVE R10 R9 + 0x7C280000, // 001E CALL R10 0 + 0x882C150B, // 001F GETMBR R11 R10 K11 + 0x8830150C, // 0020 GETMBR R12 R10 K12 + 0x8834170D, // 0021 GETMBR R13 R11 K13 + 0x901E1A0D, // 0022 SETMBR R7 K13 R13 + 0x8834170E, // 0023 GETMBR R13 R11 K14 + 0x901E1C0D, // 0024 SETMBR R7 K14 R13 + 0x8834170F, // 0025 GETMBR R13 R11 K15 + 0x901E1E0D, // 0026 SETMBR R7 K15 R13 + 0xB8360000, // 0027 GETNGBL R13 K0 + 0x88341B11, // 0028 GETMBR R13 R13 K17 + 0x901E200D, // 0029 SETMBR R7 K16 R13 + 0x88340F0E, // 002A GETMBR R13 R7 K14 + 0x4C380000, // 002B LDNIL R14 + 0x1C341A0E, // 002C EQ R13 R13 R14 + 0x74360003, // 002D JMPT R13 #0032 + 0x88340F0F, // 002E GETMBR R13 R7 K15 + 0x4C380000, // 002F LDNIL R14 + 0x1C341A0E, // 0030 EQ R13 R13 R14 + 0x7836000A, // 0031 JMPF R13 #003D + 0xB8360000, // 0032 GETNGBL R13 K0 + 0x88341B12, // 0033 GETMBR R13 R13 K18 + 0x901E200D, // 0034 SETMBR R7 K16 R13 + 0x5C340C00, // 0035 MOVE R13 R6 + 0x5C381000, // 0036 MOVE R14 R8 + 0x4C3C0000, // 0037 LDNIL R15 + 0x5C400E00, // 0038 MOVE R16 R7 + 0x4C440000, // 0039 LDNIL R17 + 0x50480200, // 003A LDBOOL R18 1 0 + 0x7C340A00, // 003B CALL R13 5 + 0x7001FFDF, // 003C JMP #001D + 0x88340F0D, // 003D GETMBR R13 R7 K13 + 0x4C380000, // 003E LDNIL R14 + 0x1C341A0E, // 003F EQ R13 R13 R14 + 0x78360012, // 0040 JMPF R13 #0054 + 0xB8360000, // 0041 GETNGBL R13 K0 + 0x8C341B13, // 0042 GETMET R13 R13 K19 + 0x883C0F0E, // 0043 GETMBR R15 R7 K14 + 0x88400F0F, // 0044 GETMBR R16 R7 K15 + 0x7C340600, // 0045 CALL R13 3 + 0xB83A2800, // 0046 GETNGBL R14 K20 + 0x8C381D15, // 0047 GETMET R14 R14 K21 + 0x60400008, // 0048 GETGBL R16 G8 + 0x5C440E00, // 0049 MOVE R17 R7 + 0x7C400200, // 004A CALL R16 1 + 0x00422C10, // 004B ADD R16 K22 R16 + 0x78360002, // 004C JMPF R13 #0050 + 0x00462E0D, // 004D ADD R17 K23 R13 + 0x00442318, // 004E ADD R17 R17 K24 + 0x70020000, // 004F JMP #0051 + 0x58440019, // 0050 LDCONST R17 K25 + 0x00402011, // 0051 ADD R16 R16 R17 + 0x5844001A, // 0052 LDCONST R17 K26 + 0x7C380600, // 0053 CALL R14 3 + 0x88340104, // 0054 GETMBR R13 R0 K4 + 0x8C341B1B, // 0055 GETMET R13 R13 K27 + 0x5C3C0E00, // 0056 MOVE R15 R7 + 0x84400001, // 0057 CLOSURE R16 P1 + 0x7C340600, // 0058 CALL R13 3 + 0xA0240000, // 0059 CLOSE R9 + 0x7001FFC1, // 005A JMP #001D + 0x5824001C, // 005B LDCONST R9 K28 + 0xAC240200, // 005C CATCH R9 1 0 + 0xB0080000, // 005D RAISE 2 R0 R0 + 0x5C240800, // 005E MOVE R9 R4 + 0x74260003, // 005F JMPT R9 #0064 + 0x8C24011D, // 0060 GETMET R9 R0 K29 + 0x5C2C0200, // 0061 MOVE R11 R1 + 0x5C301000, // 0062 MOVE R12 R8 + 0x7C240600, // 0063 CALL R9 3 + 0xA0200000, // 0064 CLOSE R8 + 0x50200200, // 0065 LDBOOL R8 1 0 + 0xA0000000, // 0066 CLOSE R0 + 0x80041000, // 0067 RET 1 R8 }) ) ); @@ -1617,8 +1621,8 @@ be_local_closure(Matter_IM_process_write_request, /* name */ ********************************************************************/ be_local_closure(Matter_IM_path2raw, /* name */ be_nested_proto( - 8, /* nstack */ - 4, /* argc */ + 9, /* nstack */ + 5, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ @@ -1635,109 +1639,114 @@ be_local_closure(Matter_IM_path2raw, /* name */ }), be_str_weak(path2raw), &be_const_str_solidified, - ( &(const binstruction[102]) { /* code */ - 0x8C100300, // 0000 GETMET R4 R1 K0 - 0x541A0036, // 0001 LDINT R6 55 - 0x581C0001, // 0002 LDCONST R7 K1 - 0x7C100600, // 0003 CALL R4 3 - 0x8C100300, // 0004 GETMET R4 R1 K0 - 0x5C180600, // 0005 MOVE R6 R3 - 0x581C0001, // 0006 LDCONST R7 K1 - 0x7C100600, // 0007 CALL R4 3 - 0x88100502, // 0008 GETMBR R4 R2 K2 - 0x541600FE, // 0009 LDINT R5 255 - 0x18100805, // 000A LE R4 R4 R5 - 0x78120008, // 000B JMPF R4 #0015 - 0x8C100300, // 000C GETMET R4 R1 K0 - 0x541A2401, // 000D LDINT R6 9218 - 0x541DFFFD, // 000E LDINT R7 -2 - 0x7C100600, // 000F CALL R4 3 - 0x8C100300, // 0010 GETMET R4 R1 K0 - 0x88180502, // 0011 GETMBR R6 R2 K2 - 0x581C0001, // 0012 LDCONST R7 K1 - 0x7C100600, // 0013 CALL R4 3 + ( &(const binstruction[107]) { /* code */ + 0x8C140300, // 0000 GETMET R5 R1 K0 + 0x541E0036, // 0001 LDINT R7 55 + 0x58200001, // 0002 LDCONST R8 K1 + 0x7C140600, // 0003 CALL R5 3 + 0x8C140300, // 0004 GETMET R5 R1 K0 + 0x5C1C0600, // 0005 MOVE R7 R3 + 0x58200001, // 0006 LDCONST R8 K1 + 0x7C140600, // 0007 CALL R5 3 + 0x88140502, // 0008 GETMBR R5 R2 K2 + 0x541A00FE, // 0009 LDINT R6 255 + 0x18140A06, // 000A LE R5 R5 R6 + 0x78160008, // 000B JMPF R5 #0015 + 0x8C140300, // 000C GETMET R5 R1 K0 + 0x541E2401, // 000D LDINT R7 9218 + 0x5421FFFD, // 000E LDINT R8 -2 + 0x7C140600, // 000F CALL R5 3 + 0x8C140300, // 0010 GETMET R5 R1 K0 + 0x881C0502, // 0011 GETMBR R7 R2 K2 + 0x58200001, // 0012 LDCONST R8 K1 + 0x7C140600, // 0013 CALL R5 3 0x70020007, // 0014 JMP #001D - 0x8C100300, // 0015 GETMET R4 R1 K0 - 0x541A2501, // 0016 LDINT R6 9474 - 0x541DFFFD, // 0017 LDINT R7 -2 - 0x7C100600, // 0018 CALL R4 3 - 0x8C100300, // 0019 GETMET R4 R1 K0 - 0x88180502, // 001A GETMBR R6 R2 K2 - 0x581C0003, // 001B LDCONST R7 K3 - 0x7C100600, // 001C CALL R4 3 - 0x88100504, // 001D GETMBR R4 R2 K4 - 0x541600FE, // 001E LDINT R5 255 - 0x18100805, // 001F LE R4 R4 R5 - 0x78120008, // 0020 JMPF R4 #002A - 0x8C100300, // 0021 GETMET R4 R1 K0 - 0x541A2402, // 0022 LDINT R6 9219 - 0x541DFFFD, // 0023 LDINT R7 -2 - 0x7C100600, // 0024 CALL R4 3 - 0x8C100300, // 0025 GETMET R4 R1 K0 - 0x88180504, // 0026 GETMBR R6 R2 K4 - 0x581C0001, // 0027 LDCONST R7 K1 - 0x7C100600, // 0028 CALL R4 3 + 0x8C140300, // 0015 GETMET R5 R1 K0 + 0x541E2501, // 0016 LDINT R7 9474 + 0x5421FFFD, // 0017 LDINT R8 -2 + 0x7C140600, // 0018 CALL R5 3 + 0x8C140300, // 0019 GETMET R5 R1 K0 + 0x881C0502, // 001A GETMBR R7 R2 K2 + 0x58200003, // 001B LDCONST R8 K3 + 0x7C140600, // 001C CALL R5 3 + 0x88140504, // 001D GETMBR R5 R2 K4 + 0x541A00FE, // 001E LDINT R6 255 + 0x18140A06, // 001F LE R5 R5 R6 + 0x78160008, // 0020 JMPF R5 #002A + 0x8C140300, // 0021 GETMET R5 R1 K0 + 0x541E2402, // 0022 LDINT R7 9219 + 0x5421FFFD, // 0023 LDINT R8 -2 + 0x7C140600, // 0024 CALL R5 3 + 0x8C140300, // 0025 GETMET R5 R1 K0 + 0x881C0504, // 0026 GETMBR R7 R2 K4 + 0x58200001, // 0027 LDCONST R8 K1 + 0x7C140600, // 0028 CALL R5 3 0x70020014, // 0029 JMP #003F - 0x88100504, // 002A GETMBR R4 R2 K4 - 0x5416FFFE, // 002B LDINT R5 65535 - 0x18100805, // 002C LE R4 R4 R5 - 0x78120008, // 002D JMPF R4 #0037 - 0x8C100300, // 002E GETMET R4 R1 K0 - 0x541A2502, // 002F LDINT R6 9475 - 0x541DFFFD, // 0030 LDINT R7 -2 - 0x7C100600, // 0031 CALL R4 3 - 0x8C100300, // 0032 GETMET R4 R1 K0 - 0x88180504, // 0033 GETMBR R6 R2 K4 - 0x581C0003, // 0034 LDCONST R7 K3 - 0x7C100600, // 0035 CALL R4 3 + 0x88140504, // 002A GETMBR R5 R2 K4 + 0x541AFFFE, // 002B LDINT R6 65535 + 0x18140A06, // 002C LE R5 R5 R6 + 0x78160008, // 002D JMPF R5 #0037 + 0x8C140300, // 002E GETMET R5 R1 K0 + 0x541E2502, // 002F LDINT R7 9475 + 0x5421FFFD, // 0030 LDINT R8 -2 + 0x7C140600, // 0031 CALL R5 3 + 0x8C140300, // 0032 GETMET R5 R1 K0 + 0x881C0504, // 0033 GETMBR R7 R2 K4 + 0x58200003, // 0034 LDCONST R8 K3 + 0x7C140600, // 0035 CALL R5 3 0x70020007, // 0036 JMP #003F - 0x8C100300, // 0037 GETMET R4 R1 K0 - 0x541A2602, // 0038 LDINT R6 9731 - 0x541DFFFD, // 0039 LDINT R7 -2 - 0x7C100600, // 003A CALL R4 3 - 0x8C100300, // 003B GETMET R4 R1 K0 - 0x88180504, // 003C GETMBR R6 R2 K4 - 0x541E0003, // 003D LDINT R7 4 - 0x7C100600, // 003E CALL R4 3 - 0x88100505, // 003F GETMBR R4 R2 K5 - 0x541600FE, // 0040 LDINT R5 255 - 0x18100805, // 0041 LE R4 R4 R5 - 0x78120008, // 0042 JMPF R4 #004C - 0x8C100300, // 0043 GETMET R4 R1 K0 - 0x541A2403, // 0044 LDINT R6 9220 - 0x541DFFFD, // 0045 LDINT R7 -2 - 0x7C100600, // 0046 CALL R4 3 - 0x8C100300, // 0047 GETMET R4 R1 K0 - 0x88180505, // 0048 GETMBR R6 R2 K5 - 0x581C0001, // 0049 LDCONST R7 K1 - 0x7C100600, // 004A CALL R4 3 + 0x8C140300, // 0037 GETMET R5 R1 K0 + 0x541E2602, // 0038 LDINT R7 9731 + 0x5421FFFD, // 0039 LDINT R8 -2 + 0x7C140600, // 003A CALL R5 3 + 0x8C140300, // 003B GETMET R5 R1 K0 + 0x881C0504, // 003C GETMBR R7 R2 K4 + 0x54220003, // 003D LDINT R8 4 + 0x7C140600, // 003E CALL R5 3 + 0x88140505, // 003F GETMBR R5 R2 K5 + 0x541A00FE, // 0040 LDINT R6 255 + 0x18140A06, // 0041 LE R5 R5 R6 + 0x78160008, // 0042 JMPF R5 #004C + 0x8C140300, // 0043 GETMET R5 R1 K0 + 0x541E2403, // 0044 LDINT R7 9220 + 0x5421FFFD, // 0045 LDINT R8 -2 + 0x7C140600, // 0046 CALL R5 3 + 0x8C140300, // 0047 GETMET R5 R1 K0 + 0x881C0505, // 0048 GETMBR R7 R2 K5 + 0x58200001, // 0049 LDCONST R8 K1 + 0x7C140600, // 004A CALL R5 3 0x70020014, // 004B JMP #0061 - 0x88100505, // 004C GETMBR R4 R2 K5 - 0x5416FFFE, // 004D LDINT R5 65535 - 0x18100805, // 004E LE R4 R4 R5 - 0x78120008, // 004F JMPF R4 #0059 - 0x8C100300, // 0050 GETMET R4 R1 K0 - 0x541A2503, // 0051 LDINT R6 9476 - 0x541DFFFD, // 0052 LDINT R7 -2 - 0x7C100600, // 0053 CALL R4 3 - 0x8C100300, // 0054 GETMET R4 R1 K0 - 0x88180505, // 0055 GETMBR R6 R2 K5 - 0x581C0003, // 0056 LDCONST R7 K3 - 0x7C100600, // 0057 CALL R4 3 + 0x88140505, // 004C GETMBR R5 R2 K5 + 0x541AFFFE, // 004D LDINT R6 65535 + 0x18140A06, // 004E LE R5 R5 R6 + 0x78160008, // 004F JMPF R5 #0059 + 0x8C140300, // 0050 GETMET R5 R1 K0 + 0x541E2503, // 0051 LDINT R7 9476 + 0x5421FFFD, // 0052 LDINT R8 -2 + 0x7C140600, // 0053 CALL R5 3 + 0x8C140300, // 0054 GETMET R5 R1 K0 + 0x881C0505, // 0055 GETMBR R7 R2 K5 + 0x58200003, // 0056 LDCONST R8 K3 + 0x7C140600, // 0057 CALL R5 3 0x70020007, // 0058 JMP #0061 - 0x8C100300, // 0059 GETMET R4 R1 K0 - 0x541A2603, // 005A LDINT R6 9732 - 0x541DFFFD, // 005B LDINT R7 -2 - 0x7C100600, // 005C CALL R4 3 - 0x8C100300, // 005D GETMET R4 R1 K0 - 0x88180505, // 005E GETMBR R6 R2 K5 - 0x541E0003, // 005F LDINT R7 4 - 0x7C100600, // 0060 CALL R4 3 - 0x8C100300, // 0061 GETMET R4 R1 K0 - 0x541A0017, // 0062 LDINT R6 24 - 0x581C0001, // 0063 LDCONST R7 K1 - 0x7C100600, // 0064 CALL R4 3 - 0x80000000, // 0065 RET 0 + 0x8C140300, // 0059 GETMET R5 R1 K0 + 0x541E2603, // 005A LDINT R7 9732 + 0x5421FFFD, // 005B LDINT R8 -2 + 0x7C140600, // 005C CALL R5 3 + 0x8C140300, // 005D GETMET R5 R1 K0 + 0x881C0505, // 005E GETMBR R7 R2 K5 + 0x54220003, // 005F LDINT R8 4 + 0x7C140600, // 0060 CALL R5 3 + 0x78120003, // 0061 JMPF R4 #0066 + 0x8C140300, // 0062 GETMET R5 R1 K0 + 0x541E3404, // 0063 LDINT R7 13317 + 0x5421FFFD, // 0064 LDINT R8 -2 + 0x7C140600, // 0065 CALL R5 3 + 0x8C140300, // 0066 GETMET R5 R1 K0 + 0x541E0017, // 0067 LDINT R7 24 + 0x58200001, // 0068 LDCONST R8 K1 + 0x7C140600, // 0069 CALL R5 3 + 0x80000000, // 006A RET 0 }) ) ); @@ -1786,7 +1795,7 @@ be_local_closure(Matter_IM_send_subscribe_update, /* name */ }), be_str_weak(send_subscribe_update), &be_const_str_solidified, - ( &(const binstruction[66]) { /* code */ + ( &(const binstruction[67]) { /* code */ 0x88080300, // 0000 GETMBR R2 R1 K0 0xB80E0200, // 0001 GETNGBL R3 K1 0x8C0C0702, // 0002 GETMET R3 R3 K2 @@ -1833,26 +1842,27 @@ be_local_closure(Matter_IM_send_subscribe_update, /* name */ 0x8C100113, // 002B GETMET R4 R0 K19 0x5C180400, // 002C MOVE R6 R2 0x5C1C0600, // 002D MOVE R7 R3 - 0x7C100600, // 002E CALL R4 3 - 0x50140000, // 002F LDBOOL R5 0 0 - 0x90122805, // 0030 SETMBR R4 K20 R5 - 0x88140310, // 0031 GETMBR R5 R1 K16 - 0x90122005, // 0032 SETMBR R4 K16 R5 - 0xB8160200, // 0033 GETNGBL R5 K1 - 0x8C140B15, // 0034 GETMET R5 R5 K21 - 0x881C0516, // 0035 GETMBR R7 R2 K22 - 0x5C200400, // 0036 MOVE R8 R2 - 0x5C240800, // 0037 MOVE R9 R4 - 0x5C280200, // 0038 MOVE R10 R1 - 0x7C140A00, // 0039 CALL R5 5 - 0x88180117, // 003A GETMBR R6 R0 K23 - 0x8C180D0A, // 003B GETMET R6 R6 K10 - 0x5C200A00, // 003C MOVE R8 R5 - 0x7C180400, // 003D CALL R6 2 - 0x8C180118, // 003E GETMET R6 R0 K24 - 0x88200516, // 003F GETMBR R8 R2 K22 - 0x7C180400, // 0040 CALL R6 2 - 0x80000000, // 0041 RET 0 + 0x4C200000, // 002E LDNIL R8 + 0x7C100800, // 002F CALL R4 4 + 0x50140000, // 0030 LDBOOL R5 0 0 + 0x90122805, // 0031 SETMBR R4 K20 R5 + 0x88140310, // 0032 GETMBR R5 R1 K16 + 0x90122005, // 0033 SETMBR R4 K16 R5 + 0xB8160200, // 0034 GETNGBL R5 K1 + 0x8C140B15, // 0035 GETMET R5 R5 K21 + 0x881C0516, // 0036 GETMBR R7 R2 K22 + 0x5C200400, // 0037 MOVE R8 R2 + 0x5C240800, // 0038 MOVE R9 R4 + 0x5C280200, // 0039 MOVE R10 R1 + 0x7C140A00, // 003A CALL R5 5 + 0x88180117, // 003B GETMBR R6 R0 K23 + 0x8C180D0A, // 003C GETMET R6 R6 K10 + 0x5C200A00, // 003D MOVE R8 R5 + 0x7C180400, // 003E CALL R6 2 + 0x8C180118, // 003F GETMET R6 R0 K24 + 0x88200516, // 0040 GETMBR R8 R2 K22 + 0x7C180400, // 0041 CALL R6 2 + 0x80000000, // 0042 RET 0 }) ) ); @@ -2199,27 +2209,27 @@ be_local_closure(Matter_IM_send_status, /* name */ ********************************************************************/ be_local_closure(Matter_IM__inner_process_read_request, /* name */ be_nested_proto( - 18, /* nstack */ - 4, /* argc */ + 19, /* nstack */ + 5, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 1, /* has sup protos */ ( &(const struct bproto*[ 2]) { be_nested_proto( - 19, /* nstack */ + 20, /* nstack */ 4, /* argc */ 0, /* varg */ 1, /* has upvals */ ( &(const bupvaldesc[ 3]) { /* upvals */ be_local_const_upval(1, 1), be_local_const_upval(1, 0), - be_local_const_upval(1, 3), + be_local_const_upval(1, 4), }), 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[28]) { /* constants */ + ( &(const bvalue[35]) { /* constants */ /* K0 */ be_nested_str_weak(matter), /* K1 */ be_nested_str_weak(TLV), /* K2 */ be_nested_str_weak(get_attribute_name), @@ -2231,27 +2241,34 @@ be_local_closure(Matter_IM__inner_process_read_request, /* name */ /* K8 */ be_nested_str_weak(read_attribute), /* K9 */ be_nested_str_weak(tlv_solo), /* K10 */ be_nested_str_weak(to_str_val), - /* K11 */ be_nested_str_weak(attributedata2raw), - /* K12 */ be_nested_str_weak(tasmota), - /* K13 */ be_nested_str_weak(log), - /* K14 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20_X25s), - /* K15 */ be_nested_str_weak(local_session_id), - /* K16 */ be_const_int(3), - /* K17 */ be_nested_str_weak(status), - /* K18 */ be_nested_str_weak(attributestatus2raw), - /* K19 */ be_nested_str_weak(loglevel), - /* K20 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20STATUS_X3A_X200x_X2502X_X20_X25s), - /* K21 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), - /* K22 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20IGNORED), - /* K23 */ be_nested_str_weak(attribute_reports), - /* K24 */ be_const_int(0), - /* K25 */ be_nested_str_weak(push), - /* K26 */ be_nested_str_weak(IM_ReportData), - /* K27 */ be_nested_str_weak(MAX_MESSAGE), + /* K11 */ be_nested_str_weak(is_list), + /* K12 */ be_nested_str_weak(is_array), + /* K13 */ be_nested_str_weak(encode_len), + /* K14 */ be_nested_str_weak(IM_ReportData), + /* K15 */ be_nested_str_weak(MAX_MESSAGE), + /* K16 */ be_nested_str_weak(Matter_TLV_array), + /* K17 */ be_nested_str_weak(attributedata2raw), + /* K18 */ be_nested_str_weak(push), + /* K19 */ be_nested_str_weak(val), + /* K20 */ be_nested_str_weak(stop_iteration), + /* K21 */ be_nested_str_weak(tasmota), + /* K22 */ be_nested_str_weak(log), + /* K23 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20_X25s), + /* K24 */ be_nested_str_weak(local_session_id), + /* K25 */ be_const_int(3), + /* K26 */ be_nested_str_weak(status), + /* K27 */ be_nested_str_weak(attributestatus2raw), + /* K28 */ be_nested_str_weak(loglevel), + /* K29 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_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_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20IGNORED), + /* K32 */ be_const_int(0), + /* K33 */ be_nested_str_weak(attribute_reports), + /* K34 */ be_const_int(1), }), be_str_weak(read_single_attribute), &be_const_str_solidified, - ( &(const binstruction[148]) { /* code */ + ( &(const binstruction[233]) { /* code */ 0xB8120000, // 0000 GETNGBL R4 K0 0x88100901, // 0001 GETMBR R4 R4 K1 0xB8160000, // 0002 GETNGBL R5 K0 @@ -2280,126 +2297,211 @@ be_local_closure(Matter_IM__inner_process_read_request, /* name */ 0x4C200000, // 0019 LDNIL R8 0x4C240000, // 001A LDNIL R9 0x20240C09, // 001B NE R9 R6 R9 - 0x7826001C, // 001C JMPF R9 #003A - 0x8C240D0A, // 001D GETMET R9 R6 K10 - 0x7C240200, // 001E CALL R9 1 - 0x60280015, // 001F GETGBL R10 G21 - 0x542E002F, // 0020 LDINT R11 48 + 0x78260054, // 001C JMPF R9 #0072 + 0x58240007, // 001D LDCONST R9 K7 + 0x68280002, // 001E GETUPV R10 U2 + 0x742A0002, // 001F JMPT R10 #0023 + 0x8C280D0A, // 0020 GETMET R10 R6 K10 0x7C280200, // 0021 CALL R10 1 - 0x5C201400, // 0022 MOVE R8 R10 - 0x68280001, // 0023 GETUPV R10 U1 - 0x8C28150B, // 0024 GETMET R10 R10 K11 - 0x5C301000, // 0025 MOVE R12 R8 - 0x5C340400, // 0026 MOVE R13 R2 - 0x5C380C00, // 0027 MOVE R14 R6 - 0x7C280800, // 0028 CALL R10 4 - 0x68280002, // 0029 GETUPV R10 U2 - 0x742A000D, // 002A JMPT R10 #0039 - 0xB82A1800, // 002B GETNGBL R10 K12 - 0x8C28150D, // 002C GETMET R10 R10 K13 - 0x60300018, // 002D GETGBL R12 G24 - 0x5834000E, // 002E LDCONST R13 K14 - 0x68380000, // 002F GETUPV R14 U0 - 0x88381D0F, // 0030 GETMBR R14 R14 K15 - 0x603C0008, // 0031 GETGBL R15 G8 - 0x5C400400, // 0032 MOVE R16 R2 - 0x7C3C0200, // 0033 CALL R15 1 - 0x5C400A00, // 0034 MOVE R16 R5 - 0x5C441200, // 0035 MOVE R17 R9 - 0x7C300A00, // 0036 CALL R12 5 - 0x58340010, // 0037 LDCONST R13 K16 - 0x7C280600, // 0038 CALL R10 3 - 0x70020038, // 0039 JMP #0073 - 0x88240511, // 003A GETMBR R9 R2 K17 - 0x4C280000, // 003B LDNIL R10 - 0x2024120A, // 003C NE R9 R9 R10 - 0x78260026, // 003D JMPF R9 #0065 - 0x780E0024, // 003E JMPF R3 #0064 - 0x60240015, // 003F GETGBL R9 G21 - 0x542A002F, // 0040 LDINT R10 48 - 0x7C240200, // 0041 CALL R9 1 - 0x5C201200, // 0042 MOVE R8 R9 - 0x68240001, // 0043 GETUPV R9 U1 - 0x8C241312, // 0044 GETMET R9 R9 K18 - 0x5C2C1000, // 0045 MOVE R11 R8 - 0x5C300400, // 0046 MOVE R12 R2 - 0x88340511, // 0047 GETMBR R13 R2 K17 - 0x7C240800, // 0048 CALL R9 4 - 0xB8261800, // 0049 GETNGBL R9 K12 - 0x8C241313, // 004A GETMET R9 R9 K19 - 0x582C0010, // 004B LDCONST R11 K16 - 0x7C240400, // 004C CALL R9 2 - 0x78260015, // 004D JMPF R9 #0064 - 0xB8261800, // 004E GETNGBL R9 K12 - 0x8C24130D, // 004F GETMET R9 R9 K13 - 0x602C0018, // 0050 GETGBL R11 G24 - 0x58300014, // 0051 LDCONST R12 K20 - 0x68340000, // 0052 GETUPV R13 U0 - 0x88341B0F, // 0053 GETMBR R13 R13 K15 - 0x60380008, // 0054 GETGBL R14 G8 - 0x5C3C0400, // 0055 MOVE R15 R2 - 0x7C380200, // 0056 CALL R14 1 - 0x5C3C0A00, // 0057 MOVE R15 R5 - 0x88400511, // 0058 GETMBR R16 R2 K17 - 0x88440511, // 0059 GETMBR R17 R2 K17 - 0xB84A0000, // 005A GETNGBL R18 K0 - 0x88482515, // 005B GETMBR R18 R18 K21 - 0x1C442212, // 005C EQ R17 R17 R18 - 0x78460001, // 005D JMPF R17 #0060 - 0x58440015, // 005E LDCONST R17 K21 - 0x70020000, // 005F JMP #0061 - 0x58440007, // 0060 LDCONST R17 K7 - 0x7C2C0C00, // 0061 CALL R11 6 - 0x58300010, // 0062 LDCONST R12 K16 - 0x7C240600, // 0063 CALL R9 3 - 0x7002000D, // 0064 JMP #0073 - 0xB8261800, // 0065 GETNGBL R9 K12 - 0x8C24130D, // 0066 GETMET R9 R9 K13 - 0x602C0018, // 0067 GETGBL R11 G24 - 0x58300016, // 0068 LDCONST R12 K22 - 0x68340000, // 0069 GETUPV R13 U0 - 0x88341B0F, // 006A GETMBR R13 R13 K15 - 0x60380008, // 006B GETGBL R14 G8 - 0x5C3C0400, // 006C MOVE R15 R2 - 0x7C380200, // 006D CALL R14 1 - 0x5C3C0A00, // 006E MOVE R15 R5 - 0x7C2C0800, // 006F CALL R11 4 - 0x58300010, // 0070 LDCONST R12 K16 - 0x7C240600, // 0071 CALL R9 3 - 0x501C0000, // 0072 LDBOOL R7 0 0 - 0x7822001E, // 0073 JMPF R8 #0093 - 0x6024000C, // 0074 GETGBL R9 G12 - 0x88280117, // 0075 GETMBR R10 R0 K23 - 0x7C240200, // 0076 CALL R9 1 - 0x1C241318, // 0077 EQ R9 R9 K24 - 0x78260004, // 0078 JMPF R9 #007E - 0x88240117, // 0079 GETMBR R9 R0 K23 - 0x8C241319, // 007A GETMET R9 R9 K25 - 0x5C2C1000, // 007B MOVE R11 R8 - 0x7C240400, // 007C CALL R9 2 - 0x70020014, // 007D JMP #0093 - 0x5425FFFE, // 007E LDINT R9 -1 - 0x88280117, // 007F GETMBR R10 R0 K23 - 0x94241409, // 0080 GETIDX R9 R10 R9 - 0x602C000C, // 0081 GETGBL R11 G12 - 0x5C301200, // 0082 MOVE R12 R9 - 0x7C2C0200, // 0083 CALL R11 1 - 0x6030000C, // 0084 GETGBL R12 G12 - 0x5C341000, // 0085 MOVE R13 R8 - 0x7C300200, // 0086 CALL R12 1 - 0x002C160C, // 0087 ADD R11 R11 R12 - 0xB8320000, // 0088 GETNGBL R12 K0 - 0x8830191A, // 0089 GETMBR R12 R12 K26 - 0x8830191B, // 008A GETMBR R12 R12 K27 - 0x182C160C, // 008B LE R11 R11 R12 - 0x782E0001, // 008C JMPF R11 #008F - 0x402C1208, // 008D CONNECT R11 R9 R8 - 0x70020003, // 008E JMP #0093 - 0x88280117, // 008F GETMBR R10 R0 K23 - 0x8C281519, // 0090 GETMET R10 R10 K25 - 0x5C301000, // 0091 MOVE R12 R8 - 0x7C280400, // 0092 CALL R10 2 - 0x80040E00, // 0093 RET 1 R7 + 0x5C241400, // 0022 MOVE R9 R10 + 0x88280D0B, // 0023 GETMBR R10 R6 K11 + 0x742A0001, // 0024 JMPT R10 #0027 + 0x88280D0C, // 0025 GETMBR R10 R6 K12 + 0x782A0031, // 0026 JMPF R10 #0059 + 0x8C280D0D, // 0027 GETMET R10 R6 K13 + 0x7C280200, // 0028 CALL R10 1 + 0xB82E0000, // 0029 GETNGBL R11 K0 + 0x882C170E, // 002A GETMBR R11 R11 K14 + 0x882C170F, // 002B GETMBR R11 R11 K15 + 0x2428140B, // 002C GT R10 R10 R11 + 0x782A002A, // 002D JMPF R10 #0059 + 0x60280012, // 002E GETGBL R10 G18 + 0x7C280000, // 002F CALL R10 0 + 0x5C201400, // 0030 MOVE R8 R10 + 0x60280015, // 0031 GETGBL R10 G21 + 0x542E002F, // 0032 LDINT R11 48 + 0x7C280200, // 0033 CALL R10 1 + 0x8C2C0910, // 0034 GETMET R11 R4 K16 + 0x7C2C0200, // 0035 CALL R11 1 + 0x68300001, // 0036 GETUPV R12 U1 + 0x8C301911, // 0037 GETMET R12 R12 K17 + 0x5C381400, // 0038 MOVE R14 R10 + 0x5C3C0400, // 0039 MOVE R15 R2 + 0x5C401600, // 003A MOVE R16 R11 + 0x50440000, // 003B LDBOOL R17 0 0 + 0x7C300A00, // 003C CALL R12 5 + 0x8C301112, // 003D GETMET R12 R8 K18 + 0x5C381400, // 003E MOVE R14 R10 + 0x7C300400, // 003F CALL R12 2 + 0x60300010, // 0040 GETGBL R12 G16 + 0x88340D13, // 0041 GETMBR R13 R6 K19 + 0x7C300200, // 0042 CALL R12 1 + 0xA8020010, // 0043 EXBLK 0 #0055 + 0x5C341800, // 0044 MOVE R13 R12 + 0x7C340000, // 0045 CALL R13 0 + 0x60380015, // 0046 GETGBL R14 G21 + 0x543E002F, // 0047 LDINT R15 48 + 0x7C380200, // 0048 CALL R14 1 + 0x5C281C00, // 0049 MOVE R10 R14 + 0x68380001, // 004A GETUPV R14 U1 + 0x8C381D11, // 004B GETMET R14 R14 K17 + 0x5C401400, // 004C MOVE R16 R10 + 0x5C440400, // 004D MOVE R17 R2 + 0x5C481A00, // 004E MOVE R18 R13 + 0x504C0200, // 004F LDBOOL R19 1 0 + 0x7C380A00, // 0050 CALL R14 5 + 0x8C381112, // 0051 GETMET R14 R8 K18 + 0x5C401400, // 0052 MOVE R16 R10 + 0x7C380400, // 0053 CALL R14 2 + 0x7001FFEE, // 0054 JMP #0044 + 0x58300014, // 0055 LDCONST R12 K20 + 0xAC300200, // 0056 CATCH R12 1 0 + 0xB0080000, // 0057 RAISE 2 R0 R0 + 0x70020009, // 0058 JMP #0063 + 0x60280015, // 0059 GETGBL R10 G21 + 0x542E002F, // 005A LDINT R11 48 + 0x7C280200, // 005B CALL R10 1 + 0x5C201400, // 005C MOVE R8 R10 + 0x68280001, // 005D GETUPV R10 U1 + 0x8C281511, // 005E GETMET R10 R10 K17 + 0x5C301000, // 005F MOVE R12 R8 + 0x5C340400, // 0060 MOVE R13 R2 + 0x5C380C00, // 0061 MOVE R14 R6 + 0x7C280800, // 0062 CALL R10 4 + 0x68280002, // 0063 GETUPV R10 U2 + 0x742A000B, // 0064 JMPT R10 #0071 + 0xB82A2A00, // 0065 GETNGBL R10 K21 + 0x8C281516, // 0066 GETMET R10 R10 K22 + 0x60300018, // 0067 GETGBL R12 G24 + 0x58340017, // 0068 LDCONST R13 K23 + 0x68380000, // 0069 GETUPV R14 U0 + 0x88381D18, // 006A GETMBR R14 R14 K24 + 0x5C3C0400, // 006B MOVE R15 R2 + 0x5C400A00, // 006C MOVE R16 R5 + 0x5C441200, // 006D MOVE R17 R9 + 0x7C300A00, // 006E CALL R12 5 + 0x58340019, // 006F LDCONST R13 K25 + 0x7C280600, // 0070 CALL R10 3 + 0x70020038, // 0071 JMP #00AB + 0x8824051A, // 0072 GETMBR R9 R2 K26 + 0x4C280000, // 0073 LDNIL R10 + 0x2024120A, // 0074 NE R9 R9 R10 + 0x78260026, // 0075 JMPF R9 #009D + 0x780E0024, // 0076 JMPF R3 #009C + 0x60240015, // 0077 GETGBL R9 G21 + 0x542A002F, // 0078 LDINT R10 48 + 0x7C240200, // 0079 CALL R9 1 + 0x5C201200, // 007A MOVE R8 R9 + 0x68240001, // 007B GETUPV R9 U1 + 0x8C24131B, // 007C GETMET R9 R9 K27 + 0x5C2C1000, // 007D MOVE R11 R8 + 0x5C300400, // 007E MOVE R12 R2 + 0x8834051A, // 007F GETMBR R13 R2 K26 + 0x7C240800, // 0080 CALL R9 4 + 0xB8262A00, // 0081 GETNGBL R9 K21 + 0x8C24131C, // 0082 GETMET R9 R9 K28 + 0x582C0019, // 0083 LDCONST R11 K25 + 0x7C240400, // 0084 CALL R9 2 + 0x78260015, // 0085 JMPF R9 #009C + 0xB8262A00, // 0086 GETNGBL R9 K21 + 0x8C241316, // 0087 GETMET R9 R9 K22 + 0x602C0018, // 0088 GETGBL R11 G24 + 0x5830001D, // 0089 LDCONST R12 K29 + 0x68340000, // 008A GETUPV R13 U0 + 0x88341B18, // 008B GETMBR R13 R13 K24 + 0x60380008, // 008C GETGBL R14 G8 + 0x5C3C0400, // 008D MOVE R15 R2 + 0x7C380200, // 008E CALL R14 1 + 0x5C3C0A00, // 008F MOVE R15 R5 + 0x8840051A, // 0090 GETMBR R16 R2 K26 + 0x8844051A, // 0091 GETMBR R17 R2 K26 + 0xB84A0000, // 0092 GETNGBL R18 K0 + 0x8848251E, // 0093 GETMBR R18 R18 K30 + 0x1C442212, // 0094 EQ R17 R17 R18 + 0x78460001, // 0095 JMPF R17 #0098 + 0x5844001E, // 0096 LDCONST R17 K30 + 0x70020000, // 0097 JMP #0099 + 0x58440007, // 0098 LDCONST R17 K7 + 0x7C2C0C00, // 0099 CALL R11 6 + 0x58300019, // 009A LDCONST R12 K25 + 0x7C240600, // 009B CALL R9 3 + 0x7002000D, // 009C JMP #00AB + 0xB8262A00, // 009D GETNGBL R9 K21 + 0x8C241316, // 009E GETMET R9 R9 K22 + 0x602C0018, // 009F GETGBL R11 G24 + 0x5830001F, // 00A0 LDCONST R12 K31 + 0x68340000, // 00A1 GETUPV R13 U0 + 0x88341B18, // 00A2 GETMBR R13 R13 K24 + 0x60380008, // 00A3 GETGBL R14 G8 + 0x5C3C0400, // 00A4 MOVE R15 R2 + 0x7C380200, // 00A5 CALL R14 1 + 0x5C3C0A00, // 00A6 MOVE R15 R5 + 0x7C2C0800, // 00A7 CALL R11 4 + 0x58300019, // 00A8 LDCONST R12 K25 + 0x7C240600, // 00A9 CALL R9 3 + 0x501C0000, // 00AA LDBOOL R7 0 0 + 0x6024000F, // 00AB GETGBL R9 G15 + 0x5C281000, // 00AC MOVE R10 R8 + 0x602C0012, // 00AD GETGBL R11 G18 + 0x7C240400, // 00AE CALL R9 2 + 0x78260001, // 00AF JMPF R9 #00B2 + 0x58240020, // 00B0 LDCONST R9 K32 + 0x70020000, // 00B1 JMP #00B3 + 0x4C240000, // 00B2 LDNIL R9 + 0x4C280000, // 00B3 LDNIL R10 + 0x2028100A, // 00B4 NE R10 R8 R10 + 0x782A0031, // 00B5 JMPF R10 #00E8 + 0x4C280000, // 00B6 LDNIL R10 + 0x1C28120A, // 00B7 EQ R10 R9 R10 + 0x782A0001, // 00B8 JMPF R10 #00BB + 0x5C281000, // 00B9 MOVE R10 R8 + 0x70020000, // 00BA JMP #00BC + 0x94281009, // 00BB GETIDX R10 R8 R9 + 0x602C000C, // 00BC GETGBL R11 G12 + 0x88300121, // 00BD GETMBR R12 R0 K33 + 0x7C2C0200, // 00BE CALL R11 1 + 0x1C2C1720, // 00BF EQ R11 R11 K32 + 0x782E0004, // 00C0 JMPF R11 #00C6 + 0x882C0121, // 00C1 GETMBR R11 R0 K33 + 0x8C2C1712, // 00C2 GETMET R11 R11 K18 + 0x5C341400, // 00C3 MOVE R13 R10 + 0x7C2C0400, // 00C4 CALL R11 2 + 0x70020014, // 00C5 JMP #00DB + 0x542DFFFE, // 00C6 LDINT R11 -1 + 0x88300121, // 00C7 GETMBR R12 R0 K33 + 0x942C180B, // 00C8 GETIDX R11 R12 R11 + 0x6034000C, // 00C9 GETGBL R13 G12 + 0x5C381600, // 00CA MOVE R14 R11 + 0x7C340200, // 00CB CALL R13 1 + 0x6038000C, // 00CC GETGBL R14 G12 + 0x5C3C1400, // 00CD MOVE R15 R10 + 0x7C380200, // 00CE CALL R14 1 + 0x00341A0E, // 00CF ADD R13 R13 R14 + 0xB83A0000, // 00D0 GETNGBL R14 K0 + 0x88381D0E, // 00D1 GETMBR R14 R14 K14 + 0x88381D0F, // 00D2 GETMBR R14 R14 K15 + 0x18341A0E, // 00D3 LE R13 R13 R14 + 0x78360001, // 00D4 JMPF R13 #00D7 + 0x4034160A, // 00D5 CONNECT R13 R11 R10 + 0x70020003, // 00D6 JMP #00DB + 0x88300121, // 00D7 GETMBR R12 R0 K33 + 0x8C301912, // 00D8 GETMET R12 R12 K18 + 0x5C381400, // 00D9 MOVE R14 R10 + 0x7C300400, // 00DA CALL R12 2 + 0x4C2C0000, // 00DB LDNIL R11 + 0x1C2C120B, // 00DC EQ R11 R9 R11 + 0x782E0001, // 00DD JMPF R11 #00E0 + 0x4C200000, // 00DE LDNIL R8 + 0x70020006, // 00DF JMP #00E7 + 0x00241322, // 00E0 ADD R9 R9 K34 + 0x602C000C, // 00E1 GETGBL R11 G12 + 0x5C301000, // 00E2 MOVE R12 R8 + 0x7C2C0200, // 00E3 CALL R11 1 + 0x282C120B, // 00E4 GE R11 R9 R11 + 0x782E0000, // 00E5 JMPF R11 #00E7 + 0x4C200000, // 00E6 LDNIL R8 + 0x7001FFCA, // 00E7 JMP #00B3 + 0x80040E00, // 00E8 RET 1 R7 }) ), be_nested_proto( @@ -2408,8 +2510,8 @@ be_local_closure(Matter_IM__inner_process_read_request, /* name */ 0, /* varg */ 1, /* has upvals */ ( &(const bupvaldesc[ 2]) { /* upvals */ - be_local_const_upval(1, 4), - be_local_const_upval(1, 7), + be_local_const_upval(1, 5), + be_local_const_upval(1, 8), }), 0, /* has sup protos */ NULL, /* no sub protos */ @@ -2429,127 +2531,132 @@ be_local_closure(Matter_IM__inner_process_read_request, /* name */ ), }), 1, /* has constants */ - ( &(const bvalue[23]) { /* constants */ + ( &(const bvalue[25]) { /* constants */ /* K0 */ be_nested_str_weak(device), /* K1 */ be_nested_str_weak(get_active_endpoints), /* 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_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s), - /* K16 */ be_nested_str_weak(local_session_id), - /* K17 */ be_nested_str_weak(_X20_X28), - /* K18 */ be_nested_str_weak(_X29), - /* K19 */ be_nested_str_weak(), - /* K20 */ be_const_int(3), - /* K21 */ be_nested_str_weak(process_attribute_expansion), - /* K22 */ be_nested_str_weak(stop_iteration), + /* K4 */ be_nested_str_weak(msg), + /* K5 */ be_nested_str_weak(ReportDataMessage), + /* K6 */ be_nested_str_weak(attribute_reports), + /* K7 */ be_nested_str_weak(attributes_requests), + /* K8 */ be_nested_str_weak(endpoint), + /* K9 */ be_nested_str_weak(cluster), + /* K10 */ be_nested_str_weak(attribute), + /* K11 */ be_nested_str_weak(fabric_filtered), + /* K12 */ be_nested_str_weak(status), + /* K13 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), + /* K14 */ be_nested_str_weak(get_attribute_name), + /* K15 */ be_nested_str_weak(tasmota), + /* K16 */ be_nested_str_weak(log), + /* K17 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s), + /* K18 */ be_nested_str_weak(local_session_id), + /* K19 */ be_nested_str_weak(_X20_X28), + /* K20 */ be_nested_str_weak(_X29), + /* K21 */ be_nested_str_weak(), + /* K22 */ be_const_int(3), + /* K23 */ be_nested_str_weak(process_attribute_expansion), + /* K24 */ be_nested_str_weak(stop_iteration), }), be_str_weak(_inner_process_read_request), &be_const_str_solidified, - ( &(const binstruction[93]) { /* code */ - 0x84100000, // 0000 CLOSURE R4 P0 - 0x88140100, // 0001 GETMBR R5 R0 K0 - 0x8C140B01, // 0002 GETMET R5 R5 K1 - 0x7C140200, // 0003 CALL R5 1 - 0xB81A0400, // 0004 GETNGBL R6 K2 - 0x8C180D03, // 0005 GETMET R6 R6 K3 - 0x7C180200, // 0006 CALL R6 1 - 0xB81E0400, // 0007 GETNGBL R7 K2 - 0x8C1C0F04, // 0008 GETMET R7 R7 K4 - 0x7C1C0200, // 0009 CALL R7 1 - 0x60200012, // 000A GETGBL R8 G18 - 0x7C200000, // 000B CALL R8 0 - 0x901E0A08, // 000C SETMBR R7 K5 R8 - 0x60200010, // 000D GETGBL R8 G16 - 0x88240506, // 000E GETMBR R9 R2 K6 - 0x7C200200, // 000F CALL R8 1 - 0xA8020046, // 0010 EXBLK 0 #0058 - 0x5C241000, // 0011 MOVE R9 R8 - 0x7C240000, // 0012 CALL R9 0 - 0x88281307, // 0013 GETMBR R10 R9 K7 - 0x901A0E0A, // 0014 SETMBR R6 K7 R10 - 0x88281308, // 0015 GETMBR R10 R9 K8 - 0x901A100A, // 0016 SETMBR R6 K8 R10 - 0x88281309, // 0017 GETMBR R10 R9 K9 - 0x901A120A, // 0018 SETMBR R6 K9 R10 - 0xB82A0400, // 0019 GETNGBL R10 K2 - 0x8828150B, // 001A GETMBR R10 R10 K11 - 0x901A140A, // 001B SETMBR R6 K10 R10 - 0x88280D07, // 001C GETMBR R10 R6 K7 - 0x4C2C0000, // 001D LDNIL R11 - 0x1C28140B, // 001E EQ R10 R10 R11 - 0x742A0007, // 001F JMPT R10 #0028 - 0x88280D08, // 0020 GETMBR R10 R6 K8 - 0x4C2C0000, // 0021 LDNIL R11 - 0x1C28140B, // 0022 EQ R10 R10 R11 - 0x742A0003, // 0023 JMPT R10 #0028 - 0x88280D09, // 0024 GETMBR R10 R6 K9 - 0x4C2C0000, // 0025 LDNIL R11 - 0x1C28140B, // 0026 EQ R10 R10 R11 - 0x782A0029, // 0027 JMPF R10 #0052 - 0x88280D08, // 0028 GETMBR R10 R6 K8 - 0x4C2C0000, // 0029 LDNIL R11 - 0x2028140B, // 002A NE R10 R10 R11 - 0x782A001A, // 002B JMPF R10 #0047 - 0x88280D09, // 002C GETMBR R10 R6 K9 - 0x4C2C0000, // 002D LDNIL R11 - 0x2028140B, // 002E NE R10 R10 R11 - 0x782A0016, // 002F JMPF R10 #0047 - 0xB82A0400, // 0030 GETNGBL R10 K2 - 0x8C28150C, // 0031 GETMET R10 R10 K12 - 0x88300D08, // 0032 GETMBR R12 R6 K8 - 0x88340D09, // 0033 GETMBR R13 R6 K9 - 0x7C280600, // 0034 CALL R10 3 - 0xB82E1A00, // 0035 GETNGBL R11 K13 - 0x8C2C170E, // 0036 GETMET R11 R11 K14 - 0x60340018, // 0037 GETGBL R13 G24 - 0x5838000F, // 0038 LDCONST R14 K15 - 0x883C0310, // 0039 GETMBR R15 R1 K16 - 0x60400008, // 003A GETGBL R16 G8 - 0x5C440C00, // 003B MOVE R17 R6 - 0x7C400200, // 003C CALL R16 1 - 0x782A0002, // 003D JMPF R10 #0041 - 0x0046220A, // 003E ADD R17 K17 R10 - 0x00442312, // 003F ADD R17 R17 K18 - 0x70020000, // 0040 JMP #0042 - 0x58440013, // 0041 LDCONST R17 K19 - 0x00402011, // 0042 ADD R16 R16 R17 - 0x7C340600, // 0043 CALL R13 3 - 0x58380014, // 0044 LDCONST R14 K20 - 0x7C2C0600, // 0045 CALL R11 3 - 0x7002000A, // 0046 JMP #0052 - 0xB82A1A00, // 0047 GETNGBL R10 K13 - 0x8C28150E, // 0048 GETMET R10 R10 K14 - 0x60300018, // 0049 GETGBL R12 G24 - 0x5834000F, // 004A LDCONST R13 K15 - 0x88380310, // 004B GETMBR R14 R1 K16 - 0x603C0008, // 004C GETGBL R15 G8 - 0x5C400C00, // 004D MOVE R16 R6 - 0x7C3C0200, // 004E CALL R15 1 - 0x7C300600, // 004F CALL R12 3 - 0x58340014, // 0050 LDCONST R13 K20 - 0x7C280600, // 0051 CALL R10 3 - 0x88280100, // 0052 GETMBR R10 R0 K0 - 0x8C281515, // 0053 GETMET R10 R10 K21 - 0x5C300C00, // 0054 MOVE R12 R6 - 0x84340001, // 0055 CLOSURE R13 P1 - 0x7C280600, // 0056 CALL R10 3 - 0x7001FFB8, // 0057 JMP #0011 - 0x58200016, // 0058 LDCONST R8 K22 - 0xAC200200, // 0059 CATCH R8 1 0 - 0xB0080000, // 005A RAISE 2 R0 R0 - 0xA0000000, // 005B CLOSE R0 - 0x80040E00, // 005C RET 1 R7 + ( &(const binstruction[96]) { /* code */ + 0x84140000, // 0000 CLOSURE R5 P0 + 0x88180100, // 0001 GETMBR R6 R0 K0 + 0x8C180D01, // 0002 GETMET R6 R6 K1 + 0x7C180200, // 0003 CALL R6 1 + 0xB81E0400, // 0004 GETNGBL R7 K2 + 0x8C1C0F03, // 0005 GETMET R7 R7 K3 + 0x7C1C0200, // 0006 CALL R7 1 + 0x901E0803, // 0007 SETMBR R7 K4 R3 + 0xB8220400, // 0008 GETNGBL R8 K2 + 0x8C201105, // 0009 GETMET R8 R8 K5 + 0x7C200200, // 000A CALL R8 1 + 0x60240012, // 000B GETGBL R9 G18 + 0x7C240000, // 000C CALL R9 0 + 0x90220C09, // 000D SETMBR R8 K6 R9 + 0x60240010, // 000E GETGBL R9 G16 + 0x88280507, // 000F GETMBR R10 R2 K7 + 0x7C240200, // 0010 CALL R9 1 + 0xA8020048, // 0011 EXBLK 0 #005B + 0x5C281200, // 0012 MOVE R10 R9 + 0x7C280000, // 0013 CALL R10 0 + 0x882C1508, // 0014 GETMBR R11 R10 K8 + 0x901E100B, // 0015 SETMBR R7 K8 R11 + 0x882C1509, // 0016 GETMBR R11 R10 K9 + 0x901E120B, // 0017 SETMBR R7 K9 R11 + 0x882C150A, // 0018 GETMBR R11 R10 K10 + 0x901E140B, // 0019 SETMBR R7 K10 R11 + 0x882C050B, // 001A GETMBR R11 R2 K11 + 0x901E160B, // 001B SETMBR R7 K11 R11 + 0xB82E0400, // 001C GETNGBL R11 K2 + 0x882C170D, // 001D GETMBR R11 R11 K13 + 0x901E180B, // 001E SETMBR R7 K12 R11 + 0x882C0F08, // 001F GETMBR R11 R7 K8 + 0x4C300000, // 0020 LDNIL R12 + 0x1C2C160C, // 0021 EQ R11 R11 R12 + 0x742E0007, // 0022 JMPT R11 #002B + 0x882C0F09, // 0023 GETMBR R11 R7 K9 + 0x4C300000, // 0024 LDNIL R12 + 0x1C2C160C, // 0025 EQ R11 R11 R12 + 0x742E0003, // 0026 JMPT R11 #002B + 0x882C0F0A, // 0027 GETMBR R11 R7 K10 + 0x4C300000, // 0028 LDNIL R12 + 0x1C2C160C, // 0029 EQ R11 R11 R12 + 0x782E0029, // 002A JMPF R11 #0055 + 0x882C0F09, // 002B GETMBR R11 R7 K9 + 0x4C300000, // 002C LDNIL R12 + 0x202C160C, // 002D NE R11 R11 R12 + 0x782E001A, // 002E JMPF R11 #004A + 0x882C0F0A, // 002F GETMBR R11 R7 K10 + 0x4C300000, // 0030 LDNIL R12 + 0x202C160C, // 0031 NE R11 R11 R12 + 0x782E0016, // 0032 JMPF R11 #004A + 0xB82E0400, // 0033 GETNGBL R11 K2 + 0x8C2C170E, // 0034 GETMET R11 R11 K14 + 0x88340F09, // 0035 GETMBR R13 R7 K9 + 0x88380F0A, // 0036 GETMBR R14 R7 K10 + 0x7C2C0600, // 0037 CALL R11 3 + 0xB8321E00, // 0038 GETNGBL R12 K15 + 0x8C301910, // 0039 GETMET R12 R12 K16 + 0x60380018, // 003A GETGBL R14 G24 + 0x583C0011, // 003B LDCONST R15 K17 + 0x88400312, // 003C GETMBR R16 R1 K18 + 0x60440008, // 003D GETGBL R17 G8 + 0x5C480E00, // 003E MOVE R18 R7 + 0x7C440200, // 003F CALL R17 1 + 0x782E0002, // 0040 JMPF R11 #0044 + 0x004A260B, // 0041 ADD R18 K19 R11 + 0x00482514, // 0042 ADD R18 R18 K20 + 0x70020000, // 0043 JMP #0045 + 0x58480015, // 0044 LDCONST R18 K21 + 0x00442212, // 0045 ADD R17 R17 R18 + 0x7C380600, // 0046 CALL R14 3 + 0x583C0016, // 0047 LDCONST R15 K22 + 0x7C300600, // 0048 CALL R12 3 + 0x7002000A, // 0049 JMP #0055 + 0xB82E1E00, // 004A GETNGBL R11 K15 + 0x8C2C1710, // 004B GETMET R11 R11 K16 + 0x60340018, // 004C GETGBL R13 G24 + 0x58380011, // 004D LDCONST R14 K17 + 0x883C0312, // 004E GETMBR R15 R1 K18 + 0x60400008, // 004F GETGBL R16 G8 + 0x5C440E00, // 0050 MOVE R17 R7 + 0x7C400200, // 0051 CALL R16 1 + 0x7C340600, // 0052 CALL R13 3 + 0x58380016, // 0053 LDCONST R14 K22 + 0x7C2C0600, // 0054 CALL R11 3 + 0x882C0100, // 0055 GETMBR R11 R0 K0 + 0x8C2C1717, // 0056 GETMET R11 R11 K23 + 0x5C340E00, // 0057 MOVE R13 R7 + 0x84380001, // 0058 CLOSURE R14 P1 + 0x7C2C0600, // 0059 CALL R11 3 + 0x7001FFB6, // 005A JMP #0012 + 0x58240018, // 005B LDCONST R9 K24 + 0xAC240200, // 005C CATCH R9 1 0 + 0xB0080000, // 005D RAISE 2 R0 R0 + 0xA0000000, // 005E CLOSE R0 + 0x80041000, // 005F RET 1 R8 }) ) ); @@ -2806,275 +2913,317 @@ be_local_closure(Matter_IM_process_read_request_solo, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[44]) { /* constants */ + ( &(const bvalue[55]) { /* constants */ /* K0 */ be_nested_str_weak(status), /* K1 */ be_nested_str_weak(matter), /* K2 */ be_nested_str_weak(INVALID_ACTION), - /* K3 */ be_nested_str_weak(device), - /* K4 */ be_nested_str_weak(process_attribute_read_solo), - /* K5 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), - /* K6 */ be_nested_str_weak(read_attribute), - /* K7 */ be_nested_str_weak(session), - /* K8 */ be_nested_str_weak(tlv_solo), - /* K9 */ be_nested_str_weak(profiler), - /* K10 */ be_nested_str_weak(log), - /* K11 */ be_nested_str_weak(read_request_solo_X20read_X20done), - /* K12 */ be_nested_str_weak(add), - /* K13 */ be_const_int(1), - /* K14 */ be_nested_str_weak(attributedata2raw), - /* K15 */ be_const_int(405077761), - /* K16 */ be_nested_str_weak(attributestatus2raw), - /* K17 */ be_nested_str_weak(tasmota), - /* K18 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X20_X2D_X20IGNORED), - /* K19 */ be_nested_str_weak(local_session_id), + /* K3 */ be_nested_str_weak(msg), + /* K4 */ be_nested_str_weak(device), + /* K5 */ be_nested_str_weak(process_attribute_read_solo), + /* K6 */ be_nested_str_weak(UNSUPPORTED_ATTRIBUTE), + /* K7 */ be_nested_str_weak(read_attribute), + /* K8 */ be_nested_str_weak(session), + /* K9 */ be_nested_str_weak(tlv_solo), + /* K10 */ be_nested_str_weak(profiler), + /* K11 */ be_nested_str_weak(log), + /* K12 */ be_nested_str_weak(read_request_solo_X20read_X20done), + /* K13 */ be_nested_str_weak(is_list), + /* K14 */ be_nested_str_weak(is_array), + /* K15 */ be_nested_str_weak(encode_len), + /* K16 */ be_nested_str_weak(IM_ReportData), + /* K17 */ be_nested_str_weak(MAX_MESSAGE), + /* K18 */ be_nested_str_weak(tasmota), + /* K19 */ be_nested_str_weak(MTR_X3A_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20Response_X20to_X20big_X2C_X20revert_X20to_X20non_X2Dsolo), /* K20 */ be_const_int(3), - /* K21 */ be_nested_str_weak(build_response), - /* K22 */ be_nested_str_weak(message_handler), + /* K21 */ be_nested_str_weak(TLV), + /* K22 */ be_nested_str_weak(parse), /* K23 */ be_nested_str_weak(raw), - /* K24 */ be_nested_str_weak(clear), - /* K25 */ be_nested_str_weak(encode_frame), - /* K26 */ be_nested_str_weak(encrypt), - /* K27 */ be_nested_str_weak(loglevel), - /* K28 */ be_nested_str_weak(MTR_X3A_X20_X3Csnd_X20_X20_X20_X20_X20_X20_X20_X28_X256i_X29_X20id_X3D_X25i_X20exch_X3D_X25i_X20rack_X3D_X25s), - /* K29 */ be_nested_str_weak(message_counter), - /* K30 */ be_nested_str_weak(exchange_id), - /* K31 */ be_nested_str_weak(ack_message_counter), - /* K32 */ be_nested_str_weak(send_response_frame), - /* K33 */ be_nested_str_weak(RESPONSE_X20SENT), - /* K34 */ be_nested_str_weak(get_attribute_name), - /* K35 */ be_nested_str_weak(cluster), - /* K36 */ be_nested_str_weak(attribute), - /* K37 */ be_nested_str_weak(_X20_X28), - /* K38 */ be_nested_str_weak(_X29), - /* K39 */ be_nested_str_weak(), - /* K40 */ be_nested_str_weak(to_str_val), - /* K41 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr1_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20_X25s), - /* K42 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr1_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20STATUS_X3A_X200x_X2502X_X20_X25s), - /* K43 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr1_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20IGNORED), + /* K24 */ be_nested_str_weak(app_payload_idx), + /* K25 */ be_nested_str_weak(process_read_request), + /* K26 */ be_nested_str_weak(add), + /* K27 */ be_const_int(1), + /* K28 */ be_nested_str_weak(attributedata2raw), + /* K29 */ be_const_int(405077761), + /* K30 */ be_nested_str_weak(attributestatus2raw), + /* K31 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr_X20_X28_X256i_X29_X20_X25s_X20_X2D_X20IGNORED), + /* K32 */ be_nested_str_weak(local_session_id), + /* K33 */ be_nested_str_weak(build_response), + /* K34 */ be_nested_str_weak(message_handler), + /* K35 */ be_nested_str_weak(clear), + /* K36 */ be_nested_str_weak(encode_frame), + /* K37 */ be_nested_str_weak(encrypt), + /* K38 */ be_nested_str_weak(loglevel), + /* K39 */ be_nested_str_weak(MTR_X3A_X20_X3Csnd_X20_X20_X20_X20_X20_X20_X20_X28_X256i_X29_X20id_X3D_X25i_X20exch_X3D_X25i_X20rack_X3D_X25s), + /* K40 */ be_nested_str_weak(message_counter), + /* K41 */ be_nested_str_weak(exchange_id), + /* K42 */ be_nested_str_weak(ack_message_counter), + /* K43 */ be_nested_str_weak(send_response_frame), + /* K44 */ be_nested_str_weak(RESPONSE_X20SENT), + /* K45 */ be_nested_str_weak(get_attribute_name), + /* K46 */ be_nested_str_weak(cluster), + /* K47 */ be_nested_str_weak(attribute), + /* K48 */ be_nested_str_weak(_X20_X28), + /* K49 */ be_nested_str_weak(_X29), + /* K50 */ be_nested_str_weak(), + /* K51 */ be_nested_str_weak(to_str_val), + /* K52 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr1_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20_X25s), + /* K53 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr1_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20STATUS_X3A_X200x_X2502X_X20_X25s), + /* K54 */ be_nested_str_weak(MTR_X3A_X20_X3ERead_Attr1_X28_X256i_X29_X20_X25s_X25s_X20_X2D_X20IGNORED), }), be_str_weak(process_read_request_solo), &be_const_str_solidified, - ( &(const binstruction[220]) { /* code */ + ( &(const binstruction[251]) { /* code */ 0xB80E0200, // 0000 GETNGBL R3 K1 0x880C0702, // 0001 GETMBR R3 R3 K2 0x900A0003, // 0002 SETMBR R2 K0 R3 - 0x880C0103, // 0003 GETMBR R3 R0 K3 - 0x8C0C0704, // 0004 GETMET R3 R3 K4 - 0x5C140400, // 0005 MOVE R5 R2 - 0x7C0C0400, // 0006 CALL R3 2 - 0x4C100000, // 0007 LDNIL R4 - 0x4C140000, // 0008 LDNIL R5 - 0x4C180000, // 0009 LDNIL R6 - 0x20180606, // 000A NE R6 R3 R6 - 0x781A0008, // 000B JMPF R6 #0015 - 0xB81A0200, // 000C GETNGBL R6 K1 - 0x88180D05, // 000D GETMBR R6 R6 K5 - 0x900A0006, // 000E SETMBR R2 K0 R6 - 0x8C180706, // 000F GETMET R6 R3 K6 - 0x88200307, // 0010 GETMBR R8 R1 K7 - 0x5C240400, // 0011 MOVE R9 R2 - 0x88280108, // 0012 GETMBR R10 R0 K8 - 0x7C180800, // 0013 CALL R6 4 - 0x5C100C00, // 0014 MOVE R4 R6 - 0xB81A0200, // 0015 GETNGBL R6 K1 - 0x88180D09, // 0016 GETMBR R6 R6 K9 - 0x8C180D0A, // 0017 GETMET R6 R6 K10 - 0x5820000B, // 0018 LDCONST R8 K11 - 0x7C180400, // 0019 CALL R6 2 - 0x4C180000, // 001A LDNIL R6 - 0x20180806, // 001B NE R6 R4 R6 - 0x781A0019, // 001C JMPF R6 #0037 - 0x60180015, // 001D GETGBL R6 G21 - 0x541E002F, // 001E LDINT R7 48 - 0x7C180200, // 001F CALL R6 1 - 0x5C140C00, // 0020 MOVE R5 R6 - 0x8C180B0C, // 0021 GETMET R6 R5 K12 - 0x54220014, // 0022 LDINT R8 21 - 0x5824000D, // 0023 LDCONST R9 K13 - 0x7C180600, // 0024 CALL R6 3 - 0x8C180B0C, // 0025 GETMET R6 R5 K12 - 0x54223600, // 0026 LDINT R8 13825 - 0x5425FFFD, // 0027 LDINT R9 -2 - 0x7C180600, // 0028 CALL R6 3 - 0x8C18010E, // 0029 GETMET R6 R0 K14 - 0x5C200A00, // 002A MOVE R8 R5 - 0x5C240400, // 002B MOVE R9 R2 - 0x5C280800, // 002C MOVE R10 R4 - 0x7C180800, // 002D CALL R6 4 - 0x8C180B0C, // 002E GETMET R6 R5 K12 - 0x5820000F, // 002F LDCONST R8 K15 - 0x5425FFFB, // 0030 LDINT R9 -4 - 0x7C180600, // 0031 CALL R6 3 - 0x8C180B0C, // 0032 GETMET R6 R5 K12 - 0x54220017, // 0033 LDINT R8 24 - 0x5824000D, // 0034 LDCONST R9 K13 - 0x7C180600, // 0035 CALL R6 3 - 0x70020029, // 0036 JMP #0061 - 0x88180500, // 0037 GETMBR R6 R2 K0 - 0x4C1C0000, // 0038 LDNIL R7 - 0x20180C07, // 0039 NE R6 R6 R7 - 0x781A0019, // 003A JMPF R6 #0055 - 0x60180015, // 003B GETGBL R6 G21 - 0x541E002F, // 003C LDINT R7 48 - 0x7C180200, // 003D CALL R6 1 - 0x5C140C00, // 003E MOVE R5 R6 - 0x8C180B0C, // 003F GETMET R6 R5 K12 - 0x54220014, // 0040 LDINT R8 21 - 0x5824000D, // 0041 LDCONST R9 K13 - 0x7C180600, // 0042 CALL R6 3 - 0x8C180B0C, // 0043 GETMET R6 R5 K12 - 0x54223600, // 0044 LDINT R8 13825 - 0x5425FFFD, // 0045 LDINT R9 -2 - 0x7C180600, // 0046 CALL R6 3 - 0x8C180110, // 0047 GETMET R6 R0 K16 - 0x5C200A00, // 0048 MOVE R8 R5 - 0x5C240400, // 0049 MOVE R9 R2 - 0x88280500, // 004A GETMBR R10 R2 K0 - 0x7C180800, // 004B CALL R6 4 - 0x8C180B0C, // 004C GETMET R6 R5 K12 - 0x5820000F, // 004D LDCONST R8 K15 - 0x5425FFFB, // 004E LDINT R9 -4 - 0x7C180600, // 004F CALL R6 3 - 0x8C180B0C, // 0050 GETMET R6 R5 K12 - 0x54220017, // 0051 LDINT R8 24 - 0x5824000D, // 0052 LDCONST R9 K13 - 0x7C180600, // 0053 CALL R6 3 - 0x7002000B, // 0054 JMP #0061 - 0xB81A2200, // 0055 GETNGBL R6 K17 - 0x8C180D0A, // 0056 GETMET R6 R6 K10 - 0x60200018, // 0057 GETGBL R8 G24 - 0x58240012, // 0058 LDCONST R9 K18 - 0x88280307, // 0059 GETMBR R10 R1 K7 - 0x88281513, // 005A GETMBR R10 R10 K19 - 0x5C2C0400, // 005B MOVE R11 R2 - 0x7C200600, // 005C CALL R8 3 - 0x58240014, // 005D LDCONST R9 K20 - 0x7C180600, // 005E CALL R6 3 - 0x50180000, // 005F LDBOOL R6 0 0 - 0x80040C00, // 0060 RET 1 R6 - 0x8C180315, // 0061 GETMET R6 R1 K21 - 0x54220004, // 0062 LDINT R8 5 - 0x50240200, // 0063 LDBOOL R9 1 0 - 0x7C180600, // 0064 CALL R6 3 - 0x881C0103, // 0065 GETMBR R7 R0 K3 - 0x881C0F16, // 0066 GETMBR R7 R7 K22 - 0x88200317, // 0067 GETMBR R8 R1 K23 - 0x8C241118, // 0068 GETMET R9 R8 K24 - 0x7C240200, // 0069 CALL R9 1 - 0x8C240D19, // 006A GETMET R9 R6 K25 - 0x5C2C0A00, // 006B MOVE R11 R5 - 0x5C301000, // 006C MOVE R12 R8 - 0x7C240600, // 006D CALL R9 3 - 0x8C240D1A, // 006E GETMET R9 R6 K26 - 0x7C240200, // 006F CALL R9 1 - 0xB8262200, // 0070 GETNGBL R9 K17 - 0x8C24131B, // 0071 GETMET R9 R9 K27 - 0x542E0003, // 0072 LDINT R11 4 - 0x7C240400, // 0073 CALL R9 2 - 0x7826000B, // 0074 JMPF R9 #0081 - 0xB8262200, // 0075 GETNGBL R9 K17 - 0x8C24130A, // 0076 GETMET R9 R9 K10 - 0x602C0018, // 0077 GETGBL R11 G24 - 0x5830001C, // 0078 LDCONST R12 K28 - 0x88340D07, // 0079 GETMBR R13 R6 K7 - 0x88341B13, // 007A GETMBR R13 R13 K19 - 0x88380D1D, // 007B GETMBR R14 R6 K29 - 0x883C0D1E, // 007C GETMBR R15 R6 K30 - 0x88400D1F, // 007D GETMBR R16 R6 K31 - 0x7C2C0A00, // 007E CALL R11 5 - 0x54320003, // 007F LDINT R12 4 - 0x7C240600, // 0080 CALL R9 3 - 0x8C240F20, // 0081 GETMET R9 R7 K32 - 0x5C2C0C00, // 0082 MOVE R11 R6 - 0x7C240400, // 0083 CALL R9 2 - 0xB8260200, // 0084 GETNGBL R9 K1 - 0x88241309, // 0085 GETMBR R9 R9 K9 - 0x8C24130A, // 0086 GETMET R9 R9 K10 - 0x582C0021, // 0087 LDCONST R11 K33 - 0x7C240400, // 0088 CALL R9 2 - 0xB8260200, // 0089 GETNGBL R9 K1 - 0x8C241322, // 008A GETMET R9 R9 K34 - 0x882C0523, // 008B GETMBR R11 R2 K35 - 0x88300524, // 008C GETMBR R12 R2 K36 - 0x7C240600, // 008D CALL R9 3 - 0x78260002, // 008E JMPF R9 #0092 - 0x002A4A09, // 008F ADD R10 K37 R9 - 0x00281526, // 0090 ADD R10 R10 K38 - 0x70020000, // 0091 JMP #0093 - 0x58280027, // 0092 LDCONST R10 K39 - 0x5C241400, // 0093 MOVE R9 R10 - 0x4C280000, // 0094 LDNIL R10 - 0x2028080A, // 0095 NE R10 R4 R10 - 0x782A0013, // 0096 JMPF R10 #00AB - 0x8C280928, // 0097 GETMET R10 R4 K40 - 0x7C280200, // 0098 CALL R10 1 - 0xB82E2200, // 0099 GETNGBL R11 K17 - 0x8C2C171B, // 009A GETMET R11 R11 K27 - 0x58340014, // 009B LDCONST R13 K20 - 0x7C2C0400, // 009C CALL R11 2 - 0x782E000B, // 009D JMPF R11 #00AA - 0xB82E2200, // 009E GETNGBL R11 K17 - 0x8C2C170A, // 009F GETMET R11 R11 K10 - 0x60340018, // 00A0 GETGBL R13 G24 - 0x58380029, // 00A1 LDCONST R14 K41 - 0x883C0307, // 00A2 GETMBR R15 R1 K7 - 0x883C1F13, // 00A3 GETMBR R15 R15 K19 - 0x5C400400, // 00A4 MOVE R16 R2 - 0x5C441200, // 00A5 MOVE R17 R9 - 0x5C481400, // 00A6 MOVE R18 R10 - 0x7C340A00, // 00A7 CALL R13 5 - 0x58380014, // 00A8 LDCONST R14 K20 - 0x7C2C0600, // 00A9 CALL R11 3 - 0x7002002E, // 00AA JMP #00DA - 0x88280500, // 00AB GETMBR R10 R2 K0 - 0x4C2C0000, // 00AC LDNIL R11 - 0x2028140B, // 00AD NE R10 R10 R11 - 0x782A001A, // 00AE JMPF R10 #00CA - 0x88280500, // 00AF GETMBR R10 R2 K0 - 0xB82E0200, // 00B0 GETNGBL R11 K1 - 0x882C1705, // 00B1 GETMBR R11 R11 K5 - 0x1C28140B, // 00B2 EQ R10 R10 R11 - 0x782A0001, // 00B3 JMPF R10 #00B6 - 0x58280005, // 00B4 LDCONST R10 K5 - 0x70020000, // 00B5 JMP #00B7 - 0x58280027, // 00B6 LDCONST R10 K39 - 0xB82E2200, // 00B7 GETNGBL R11 K17 - 0x8C2C171B, // 00B8 GETMET R11 R11 K27 - 0x58340014, // 00B9 LDCONST R13 K20 - 0x7C2C0400, // 00BA CALL R11 2 - 0x782E000C, // 00BB JMPF R11 #00C9 - 0xB82E2200, // 00BC GETNGBL R11 K17 - 0x8C2C170A, // 00BD GETMET R11 R11 K10 - 0x60340018, // 00BE GETGBL R13 G24 - 0x5838002A, // 00BF LDCONST R14 K42 - 0x883C0307, // 00C0 GETMBR R15 R1 K7 - 0x883C1F13, // 00C1 GETMBR R15 R15 K19 - 0x5C400400, // 00C2 MOVE R16 R2 - 0x5C441200, // 00C3 MOVE R17 R9 - 0x88480500, // 00C4 GETMBR R18 R2 K0 - 0x5C4C1400, // 00C5 MOVE R19 R10 - 0x7C340C00, // 00C6 CALL R13 6 + 0x900A0601, // 0003 SETMBR R2 K3 R1 + 0x880C0104, // 0004 GETMBR R3 R0 K4 + 0x8C0C0705, // 0005 GETMET R3 R3 K5 + 0x5C140400, // 0006 MOVE R5 R2 + 0x7C0C0400, // 0007 CALL R3 2 + 0x4C100000, // 0008 LDNIL R4 + 0x4C140000, // 0009 LDNIL R5 + 0x4C180000, // 000A LDNIL R6 + 0x20180606, // 000B NE R6 R3 R6 + 0x781A0008, // 000C JMPF R6 #0016 + 0xB81A0200, // 000D GETNGBL R6 K1 + 0x88180D06, // 000E GETMBR R6 R6 K6 + 0x900A0006, // 000F SETMBR R2 K0 R6 + 0x8C180707, // 0010 GETMET R6 R3 K7 + 0x88200308, // 0011 GETMBR R8 R1 K8 + 0x5C240400, // 0012 MOVE R9 R2 + 0x88280109, // 0013 GETMBR R10 R0 K9 + 0x7C180800, // 0014 CALL R6 4 + 0x5C100C00, // 0015 MOVE R4 R6 + 0xB81A0200, // 0016 GETNGBL R6 K1 + 0x88180D0A, // 0017 GETMBR R6 R6 K10 + 0x8C180D0B, // 0018 GETMET R6 R6 K11 + 0x5820000C, // 0019 LDCONST R8 K12 + 0x7C180400, // 001A CALL R6 2 + 0x4C180000, // 001B LDNIL R6 + 0x20180806, // 001C NE R6 R4 R6 + 0x781A0037, // 001D JMPF R6 #0056 + 0x8818090D, // 001E GETMBR R6 R4 K13 + 0x741A0001, // 001F JMPT R6 #0022 + 0x8818090E, // 0020 GETMBR R6 R4 K14 + 0x781A0019, // 0021 JMPF R6 #003C + 0x8C18090F, // 0022 GETMET R6 R4 K15 + 0x7C180200, // 0023 CALL R6 1 + 0xB81E0200, // 0024 GETNGBL R7 K1 + 0x881C0F10, // 0025 GETMBR R7 R7 K16 + 0x881C0F11, // 0026 GETMBR R7 R7 K17 + 0x24180C07, // 0027 GT R6 R6 R7 + 0x781A0012, // 0028 JMPF R6 #003C + 0x4C100000, // 0029 LDNIL R4 + 0xB81A2400, // 002A GETNGBL R6 K18 + 0x8C180D0B, // 002B GETMET R6 R6 K11 + 0x60200018, // 002C GETGBL R8 G24 + 0x58240013, // 002D LDCONST R9 K19 + 0x7C200200, // 002E CALL R8 1 + 0x58240014, // 002F LDCONST R9 K20 + 0x7C180600, // 0030 CALL R6 3 + 0xB81A0200, // 0031 GETNGBL R6 K1 + 0x88180D15, // 0032 GETMBR R6 R6 K21 + 0x8C180D16, // 0033 GETMET R6 R6 K22 + 0x88200317, // 0034 GETMBR R8 R1 K23 + 0x88240318, // 0035 GETMBR R9 R1 K24 + 0x7C180600, // 0036 CALL R6 3 + 0x8C1C0119, // 0037 GETMET R7 R0 K25 + 0x5C240200, // 0038 MOVE R9 R1 + 0x5C280C00, // 0039 MOVE R10 R6 + 0x7C1C0600, // 003A CALL R7 3 + 0x80040E00, // 003B RET 1 R7 + 0x60180015, // 003C GETGBL R6 G21 + 0x541E002F, // 003D LDINT R7 48 + 0x7C180200, // 003E CALL R6 1 + 0x5C140C00, // 003F MOVE R5 R6 + 0x8C180B1A, // 0040 GETMET R6 R5 K26 + 0x54220014, // 0041 LDINT R8 21 + 0x5824001B, // 0042 LDCONST R9 K27 + 0x7C180600, // 0043 CALL R6 3 + 0x8C180B1A, // 0044 GETMET R6 R5 K26 + 0x54223600, // 0045 LDINT R8 13825 + 0x5425FFFD, // 0046 LDINT R9 -2 + 0x7C180600, // 0047 CALL R6 3 + 0x8C18011C, // 0048 GETMET R6 R0 K28 + 0x5C200A00, // 0049 MOVE R8 R5 + 0x5C240400, // 004A MOVE R9 R2 + 0x5C280800, // 004B MOVE R10 R4 + 0x7C180800, // 004C CALL R6 4 + 0x8C180B1A, // 004D GETMET R6 R5 K26 + 0x5820001D, // 004E LDCONST R8 K29 + 0x5425FFFB, // 004F LDINT R9 -4 + 0x7C180600, // 0050 CALL R6 3 + 0x8C180B1A, // 0051 GETMET R6 R5 K26 + 0x54220017, // 0052 LDINT R8 24 + 0x5824001B, // 0053 LDCONST R9 K27 + 0x7C180600, // 0054 CALL R6 3 + 0x70020029, // 0055 JMP #0080 + 0x88180500, // 0056 GETMBR R6 R2 K0 + 0x4C1C0000, // 0057 LDNIL R7 + 0x20180C07, // 0058 NE R6 R6 R7 + 0x781A0019, // 0059 JMPF R6 #0074 + 0x60180015, // 005A GETGBL R6 G21 + 0x541E002F, // 005B LDINT R7 48 + 0x7C180200, // 005C CALL R6 1 + 0x5C140C00, // 005D MOVE R5 R6 + 0x8C180B1A, // 005E GETMET R6 R5 K26 + 0x54220014, // 005F LDINT R8 21 + 0x5824001B, // 0060 LDCONST R9 K27 + 0x7C180600, // 0061 CALL R6 3 + 0x8C180B1A, // 0062 GETMET R6 R5 K26 + 0x54223600, // 0063 LDINT R8 13825 + 0x5425FFFD, // 0064 LDINT R9 -2 + 0x7C180600, // 0065 CALL R6 3 + 0x8C18011E, // 0066 GETMET R6 R0 K30 + 0x5C200A00, // 0067 MOVE R8 R5 + 0x5C240400, // 0068 MOVE R9 R2 + 0x88280500, // 0069 GETMBR R10 R2 K0 + 0x7C180800, // 006A CALL R6 4 + 0x8C180B1A, // 006B GETMET R6 R5 K26 + 0x5820001D, // 006C LDCONST R8 K29 + 0x5425FFFB, // 006D LDINT R9 -4 + 0x7C180600, // 006E CALL R6 3 + 0x8C180B1A, // 006F GETMET R6 R5 K26 + 0x54220017, // 0070 LDINT R8 24 + 0x5824001B, // 0071 LDCONST R9 K27 + 0x7C180600, // 0072 CALL R6 3 + 0x7002000B, // 0073 JMP #0080 + 0xB81A2400, // 0074 GETNGBL R6 K18 + 0x8C180D0B, // 0075 GETMET R6 R6 K11 + 0x60200018, // 0076 GETGBL R8 G24 + 0x5824001F, // 0077 LDCONST R9 K31 + 0x88280308, // 0078 GETMBR R10 R1 K8 + 0x88281520, // 0079 GETMBR R10 R10 K32 + 0x5C2C0400, // 007A MOVE R11 R2 + 0x7C200600, // 007B CALL R8 3 + 0x58240014, // 007C LDCONST R9 K20 + 0x7C180600, // 007D CALL R6 3 + 0x50180000, // 007E LDBOOL R6 0 0 + 0x80040C00, // 007F RET 1 R6 + 0x8C180321, // 0080 GETMET R6 R1 K33 + 0x54220004, // 0081 LDINT R8 5 + 0x50240200, // 0082 LDBOOL R9 1 0 + 0x7C180600, // 0083 CALL R6 3 + 0x881C0104, // 0084 GETMBR R7 R0 K4 + 0x881C0F22, // 0085 GETMBR R7 R7 K34 + 0x88200317, // 0086 GETMBR R8 R1 K23 + 0x8C241123, // 0087 GETMET R9 R8 K35 + 0x7C240200, // 0088 CALL R9 1 + 0x8C240D24, // 0089 GETMET R9 R6 K36 + 0x5C2C0A00, // 008A MOVE R11 R5 + 0x5C301000, // 008B MOVE R12 R8 + 0x7C240600, // 008C CALL R9 3 + 0x8C240D25, // 008D GETMET R9 R6 K37 + 0x7C240200, // 008E CALL R9 1 + 0xB8262400, // 008F GETNGBL R9 K18 + 0x8C241326, // 0090 GETMET R9 R9 K38 + 0x542E0003, // 0091 LDINT R11 4 + 0x7C240400, // 0092 CALL R9 2 + 0x7826000B, // 0093 JMPF R9 #00A0 + 0xB8262400, // 0094 GETNGBL R9 K18 + 0x8C24130B, // 0095 GETMET R9 R9 K11 + 0x602C0018, // 0096 GETGBL R11 G24 + 0x58300027, // 0097 LDCONST R12 K39 + 0x88340D08, // 0098 GETMBR R13 R6 K8 + 0x88341B20, // 0099 GETMBR R13 R13 K32 + 0x88380D28, // 009A GETMBR R14 R6 K40 + 0x883C0D29, // 009B GETMBR R15 R6 K41 + 0x88400D2A, // 009C GETMBR R16 R6 K42 + 0x7C2C0A00, // 009D CALL R11 5 + 0x54320003, // 009E LDINT R12 4 + 0x7C240600, // 009F CALL R9 3 + 0x8C240F2B, // 00A0 GETMET R9 R7 K43 + 0x5C2C0C00, // 00A1 MOVE R11 R6 + 0x7C240400, // 00A2 CALL R9 2 + 0xB8260200, // 00A3 GETNGBL R9 K1 + 0x8824130A, // 00A4 GETMBR R9 R9 K10 + 0x8C24130B, // 00A5 GETMET R9 R9 K11 + 0x582C002C, // 00A6 LDCONST R11 K44 + 0x7C240400, // 00A7 CALL R9 2 + 0xB8260200, // 00A8 GETNGBL R9 K1 + 0x8C24132D, // 00A9 GETMET R9 R9 K45 + 0x882C052E, // 00AA GETMBR R11 R2 K46 + 0x8830052F, // 00AB GETMBR R12 R2 K47 + 0x7C240600, // 00AC CALL R9 3 + 0x78260002, // 00AD JMPF R9 #00B1 + 0x002A6009, // 00AE ADD R10 K48 R9 + 0x00281531, // 00AF ADD R10 R10 K49 + 0x70020000, // 00B0 JMP #00B2 + 0x58280032, // 00B1 LDCONST R10 K50 + 0x5C241400, // 00B2 MOVE R9 R10 + 0x4C280000, // 00B3 LDNIL R10 + 0x2028080A, // 00B4 NE R10 R4 R10 + 0x782A0013, // 00B5 JMPF R10 #00CA + 0x8C280933, // 00B6 GETMET R10 R4 K51 + 0x7C280200, // 00B7 CALL R10 1 + 0xB82E2400, // 00B8 GETNGBL R11 K18 + 0x8C2C1726, // 00B9 GETMET R11 R11 K38 + 0x58340014, // 00BA LDCONST R13 K20 + 0x7C2C0400, // 00BB CALL R11 2 + 0x782E000B, // 00BC JMPF R11 #00C9 + 0xB82E2400, // 00BD GETNGBL R11 K18 + 0x8C2C170B, // 00BE GETMET R11 R11 K11 + 0x60340018, // 00BF GETGBL R13 G24 + 0x58380034, // 00C0 LDCONST R14 K52 + 0x883C0308, // 00C1 GETMBR R15 R1 K8 + 0x883C1F20, // 00C2 GETMBR R15 R15 K32 + 0x5C400400, // 00C3 MOVE R16 R2 + 0x5C441200, // 00C4 MOVE R17 R9 + 0x5C481400, // 00C5 MOVE R18 R10 + 0x7C340A00, // 00C6 CALL R13 5 0x58380014, // 00C7 LDCONST R14 K20 0x7C2C0600, // 00C8 CALL R11 3 - 0x7002000F, // 00C9 JMP #00DA - 0xB82A2200, // 00CA GETNGBL R10 K17 - 0x8C28151B, // 00CB GETMET R10 R10 K27 - 0x58300014, // 00CC LDCONST R12 K20 - 0x7C280400, // 00CD CALL R10 2 - 0x782A000A, // 00CE JMPF R10 #00DA - 0xB82A2200, // 00CF GETNGBL R10 K17 - 0x8C28150A, // 00D0 GETMET R10 R10 K10 - 0x60300018, // 00D1 GETGBL R12 G24 - 0x5834002B, // 00D2 LDCONST R13 K43 - 0x88380307, // 00D3 GETMBR R14 R1 K7 - 0x88381D13, // 00D4 GETMBR R14 R14 K19 - 0x5C3C0400, // 00D5 MOVE R15 R2 - 0x5C401200, // 00D6 MOVE R16 R9 - 0x7C300800, // 00D7 CALL R12 4 + 0x7002002E, // 00C9 JMP #00F9 + 0x88280500, // 00CA GETMBR R10 R2 K0 + 0x4C2C0000, // 00CB LDNIL R11 + 0x2028140B, // 00CC NE R10 R10 R11 + 0x782A001A, // 00CD JMPF R10 #00E9 + 0x88280500, // 00CE GETMBR R10 R2 K0 + 0xB82E0200, // 00CF GETNGBL R11 K1 + 0x882C1706, // 00D0 GETMBR R11 R11 K6 + 0x1C28140B, // 00D1 EQ R10 R10 R11 + 0x782A0001, // 00D2 JMPF R10 #00D5 + 0x58280006, // 00D3 LDCONST R10 K6 + 0x70020000, // 00D4 JMP #00D6 + 0x58280032, // 00D5 LDCONST R10 K50 + 0xB82E2400, // 00D6 GETNGBL R11 K18 + 0x8C2C1726, // 00D7 GETMET R11 R11 K38 0x58340014, // 00D8 LDCONST R13 K20 - 0x7C280600, // 00D9 CALL R10 3 - 0x50280200, // 00DA LDBOOL R10 1 0 - 0x80041400, // 00DB RET 1 R10 + 0x7C2C0400, // 00D9 CALL R11 2 + 0x782E000C, // 00DA JMPF R11 #00E8 + 0xB82E2400, // 00DB GETNGBL R11 K18 + 0x8C2C170B, // 00DC GETMET R11 R11 K11 + 0x60340018, // 00DD GETGBL R13 G24 + 0x58380035, // 00DE LDCONST R14 K53 + 0x883C0308, // 00DF GETMBR R15 R1 K8 + 0x883C1F20, // 00E0 GETMBR R15 R15 K32 + 0x5C400400, // 00E1 MOVE R16 R2 + 0x5C441200, // 00E2 MOVE R17 R9 + 0x88480500, // 00E3 GETMBR R18 R2 K0 + 0x5C4C1400, // 00E4 MOVE R19 R10 + 0x7C340C00, // 00E5 CALL R13 6 + 0x58380014, // 00E6 LDCONST R14 K20 + 0x7C2C0600, // 00E7 CALL R11 3 + 0x7002000F, // 00E8 JMP #00F9 + 0xB82A2400, // 00E9 GETNGBL R10 K18 + 0x8C281526, // 00EA GETMET R10 R10 K38 + 0x58300014, // 00EB LDCONST R12 K20 + 0x7C280400, // 00EC CALL R10 2 + 0x782A000A, // 00ED JMPF R10 #00F9 + 0xB82A2400, // 00EE GETNGBL R10 K18 + 0x8C28150B, // 00EF GETMET R10 R10 K11 + 0x60300018, // 00F0 GETGBL R12 G24 + 0x58340036, // 00F1 LDCONST R13 K54 + 0x88380308, // 00F2 GETMBR R14 R1 K8 + 0x88381D20, // 00F3 GETMBR R14 R14 K32 + 0x5C3C0400, // 00F4 MOVE R15 R2 + 0x5C401200, // 00F5 MOVE R16 R9 + 0x7C300800, // 00F6 CALL R12 4 + 0x58340014, // 00F7 LDCONST R13 K20 + 0x7C280600, // 00F8 CALL R10 3 + 0x50280200, // 00F9 LDBOOL R10 1 0 + 0x80041400, // 00FA RET 1 R10 }) ) ); @@ -3271,7 +3420,7 @@ be_local_closure(Matter_IM_expire_sendqueue, /* name */ ********************************************************************/ be_local_closure(Matter_IM_subscribe_request, /* name */ be_nested_proto( - 17, /* nstack */ + 18, /* nstack */ 3, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -3279,7 +3428,7 @@ be_local_closure(Matter_IM_subscribe_request, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[30]) { /* constants */ + ( &(const bvalue[33]) { /* constants */ /* K0 */ be_nested_str_weak(matter), /* K1 */ be_nested_str_weak(SubscribeRequestMessage), /* K2 */ be_nested_str_weak(from_TLV), @@ -3298,7 +3447,7 @@ be_local_closure(Matter_IM_subscribe_request, /* name */ /* K15 */ be_nested_str_weak(stop_iteration), /* K16 */ be_nested_str_weak(tasmota), /* K17 */ be_nested_str_weak(log), - /* K18 */ be_nested_str_weak(MTR_X3A_X20_X3ESubscribe_X20_X28_X256i_X29_X20_X25s_X20_X28min_X3D_X25i_X2C_X20max_X3D_X25i_X2C_X20keep_X3D_X25i_X29_X20sub_X3D_X25i), + /* K18 */ be_nested_str_weak(MTR_X3A_X20_X3ESubscribe_X20_X28_X256i_X29_X20_X25s_X20_X28min_X3D_X25i_X2C_X20max_X3D_X25i_X2C_X20keep_X3D_X25i_X29_X20sub_X3D_X25i_X20fabric_filtered_X3D_X25s), /* K19 */ be_nested_str_weak(local_session_id), /* K20 */ be_nested_str_weak(concat), /* K21 */ be_nested_str_weak(_X20), @@ -3307,13 +3456,16 @@ be_local_closure(Matter_IM_subscribe_request, /* name */ /* K24 */ be_const_int(1), /* K25 */ be_const_int(0), /* K26 */ be_nested_str_weak(subscription_id), - /* K27 */ be_const_int(3), - /* K28 */ be_nested_str_weak(_inner_process_read_request), - /* K29 */ be_nested_str_weak(send_subscribe_response), + /* K27 */ be_nested_str_weak(fabric_filtered), + /* K28 */ be_const_int(3), + /* K29 */ be_nested_str_weak(event_requests), + /* K30 */ be_nested_str_weak(MTR_X3A_X20_X3ESubscribe_X20_X28_X25_X256i_X29_X20event_requests_size_X3D_X25s), + /* K31 */ be_nested_str_weak(_inner_process_read_request), + /* K32 */ be_nested_str_weak(send_subscribe_response), }), be_str_weak(subscribe_request), &be_const_str_solidified, - ( &(const binstruction[78]) { /* code */ + ( &(const binstruction[99]) { /* code */ 0xB80E0000, // 0000 GETNGBL R3 K0 0x8C0C0701, // 0001 GETMET R3 R3 K1 0x7C0C0200, // 0002 CALL R3 1 @@ -3375,23 +3527,44 @@ be_local_closure(Matter_IM_subscribe_request, /* name */ 0x70020000, // 003A JMP #003C 0x583C0019, // 003B LDCONST R15 K25 0x8840091A, // 003C GETMBR R16 R4 K26 - 0x7C240E00, // 003D CALL R9 7 - 0x5828001B, // 003E LDCONST R10 K27 - 0x7C1C0600, // 003F CALL R7 3 - 0x8C1C011C, // 0040 GETMET R7 R0 K28 - 0x88240306, // 0041 GETMBR R9 R1 K6 - 0x5C280600, // 0042 MOVE R10 R3 - 0x502C0200, // 0043 LDBOOL R11 1 0 - 0x7C1C0800, // 0044 CALL R7 4 - 0x8820091A, // 0045 GETMBR R8 R4 K26 - 0x901E3408, // 0046 SETMBR R7 K26 R8 - 0x8C20011D, // 0047 GETMET R8 R0 K29 - 0x5C280200, // 0048 MOVE R10 R1 - 0x5C2C0E00, // 0049 MOVE R11 R7 - 0x5C300800, // 004A MOVE R12 R4 - 0x7C200800, // 004B CALL R8 4 - 0x50200200, // 004C LDBOOL R8 1 0 - 0x80041000, // 004D RET 1 R8 + 0x8844071B, // 003D GETMBR R17 R3 K27 + 0x7C241000, // 003E CALL R9 8 + 0x5828001C, // 003F LDCONST R10 K28 + 0x7C1C0600, // 0040 CALL R7 3 + 0x881C071D, // 0041 GETMBR R7 R3 K29 + 0x4C200000, // 0042 LDNIL R8 + 0x201C0E08, // 0043 NE R7 R7 R8 + 0x781E000E, // 0044 JMPF R7 #0054 + 0x601C000C, // 0045 GETGBL R7 G12 + 0x8820071D, // 0046 GETMBR R8 R3 K29 + 0x7C1C0200, // 0047 CALL R7 1 + 0x241C0F19, // 0048 GT R7 R7 K25 + 0x781E0009, // 0049 JMPF R7 #0054 + 0xB81E2000, // 004A GETNGBL R7 K16 + 0x8C1C0F11, // 004B GETMET R7 R7 K17 + 0x60240018, // 004C GETGBL R9 G24 + 0x5828001E, // 004D LDCONST R10 K30 + 0x602C000C, // 004E GETGBL R11 G12 + 0x8830071D, // 004F GETMBR R12 R3 K29 + 0x7C2C0200, // 0050 CALL R11 1 + 0x7C240400, // 0051 CALL R9 2 + 0x5828001C, // 0052 LDCONST R10 K28 + 0x7C1C0600, // 0053 CALL R7 3 + 0x8C1C011F, // 0054 GETMET R7 R0 K31 + 0x88240306, // 0055 GETMBR R9 R1 K6 + 0x5C280600, // 0056 MOVE R10 R3 + 0x5C2C0200, // 0057 MOVE R11 R1 + 0x50300200, // 0058 LDBOOL R12 1 0 + 0x7C1C0A00, // 0059 CALL R7 5 + 0x8820091A, // 005A GETMBR R8 R4 K26 + 0x901E3408, // 005B SETMBR R7 K26 R8 + 0x8C200120, // 005C GETMET R8 R0 K32 + 0x5C280200, // 005D MOVE R10 R1 + 0x5C2C0E00, // 005E MOVE R11 R7 + 0x5C300800, // 005F MOVE R12 R4 + 0x7C200800, // 0060 CALL R8 4 + 0x50200200, // 0061 LDBOOL R8 1 0 + 0x80041000, // 0062 RET 1 R8 }) ) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Path.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Path.h index b299cc24bfa2..bab7d9909e67 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Path.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Path.h @@ -19,7 +19,7 @@ be_local_closure(Matter_Path_tostring, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[13]) { /* constants */ + ( &(const bvalue[15]) { /* constants */ /* K0 */ be_nested_str_weak(), /* K1 */ be_nested_str_weak(endpoint), /* K2 */ be_nested_str_weak(_X5B_X2502X_X5D), @@ -30,14 +30,16 @@ be_local_closure(Matter_Path_tostring, /* name */ /* K7 */ be_nested_str_weak(attribute), /* K8 */ be_nested_str_weak(_X2504X), /* K9 */ be_nested_str_weak(command), - /* K10 */ be_nested_str_weak(_X2A_X2A_X2A_X2A), - /* K11 */ be_nested_str_weak(Exception_X3E_X20), - /* K12 */ be_nested_str_weak(_X2C_X20), + /* K10 */ be_nested_str_weak(fabric_filtered), + /* K11 */ be_nested_str_weak(_X21), + /* 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[74]) { /* code */ - 0xA8020039, // 0000 EXBLK 0 #003B + ( &(const binstruction[77]) { /* code */ + 0xA802003C, // 0000 EXBLK 0 #003E 0x58040000, // 0001 LDCONST R1 K0 0x88080101, // 0002 GETMBR R2 R0 K1 0x4C0C0000, // 0003 LDNIL R3 @@ -83,34 +85,37 @@ be_local_closure(Matter_Path_tostring, /* name */ 0x70020000, // 002B JMP #002D 0x58080000, // 002C LDCONST R2 K0 0x00040202, // 002D ADD R1 R1 R2 - 0x88080107, // 002E GETMBR R2 R0 K7 - 0x4C0C0000, // 002F LDNIL R3 - 0x1C080403, // 0030 EQ R2 R2 R3 - 0x780A0004, // 0031 JMPF R2 #0037 - 0x88080109, // 0032 GETMBR R2 R0 K9 - 0x4C0C0000, // 0033 LDNIL R3 - 0x1C080403, // 0034 EQ R2 R2 R3 - 0x780A0000, // 0035 JMPF R2 #0037 - 0x0004030A, // 0036 ADD R1 R1 K10 - 0xA8040001, // 0037 EXBLK 1 1 - 0x80040200, // 0038 RET 1 R1 - 0xA8040001, // 0039 EXBLK 1 1 - 0x7002000D, // 003A JMP #0049 - 0xAC040002, // 003B CATCH R1 0 2 - 0x7002000A, // 003C JMP #0048 - 0x600C0008, // 003D GETGBL R3 G8 - 0x5C100200, // 003E MOVE R4 R1 - 0x7C0C0200, // 003F CALL R3 1 - 0x000E1603, // 0040 ADD R3 K11 R3 - 0x000C070C, // 0041 ADD R3 R3 K12 - 0x60100008, // 0042 GETGBL R4 G8 - 0x5C140400, // 0043 MOVE R5 R2 - 0x7C100200, // 0044 CALL R4 1 - 0x000C0604, // 0045 ADD R3 R3 R4 - 0x80040600, // 0046 RET 1 R3 - 0x70020000, // 0047 JMP #0049 - 0xB0080000, // 0048 RAISE 2 R0 R0 - 0x80000000, // 0049 RET 0 + 0x8808010A, // 002E GETMBR R2 R0 K10 + 0x780A0000, // 002F JMPF R2 #0031 + 0x0004030B, // 0030 ADD R1 R1 K11 + 0x88080107, // 0031 GETMBR R2 R0 K7 + 0x4C0C0000, // 0032 LDNIL R3 + 0x1C080403, // 0033 EQ R2 R2 R3 + 0x780A0004, // 0034 JMPF R2 #003A + 0x88080109, // 0035 GETMBR R2 R0 K9 + 0x4C0C0000, // 0036 LDNIL R3 + 0x1C080403, // 0037 EQ R2 R2 R3 + 0x780A0000, // 0038 JMPF R2 #003A + 0x0004030C, // 0039 ADD R1 R1 K12 + 0xA8040001, // 003A EXBLK 1 1 + 0x80040200, // 003B RET 1 R1 + 0xA8040001, // 003C EXBLK 1 1 + 0x7002000D, // 003D JMP #004C + 0xAC040002, // 003E CATCH R1 0 2 + 0x7002000A, // 003F JMP #004B + 0x600C0008, // 0040 GETGBL R3 G8 + 0x5C100200, // 0041 MOVE R4 R1 + 0x7C0C0200, // 0042 CALL R3 1 + 0x000E1A03, // 0043 ADD R3 K13 R3 + 0x000C070E, // 0044 ADD R3 R3 K14 + 0x60100008, // 0045 GETGBL R4 G8 + 0x5C140400, // 0046 MOVE R5 R2 + 0x7C100200, // 0047 CALL R4 1 + 0x000C0604, // 0048 ADD R3 R3 R4 + 0x80040600, // 0049 RET 1 R3 + 0x70020000, // 004A JMP #004C + 0xB0080000, // 004B RAISE 2 R0 R0 + 0x80000000, // 004C 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 1796b621680d..806c7361feec 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin.h @@ -295,6 +295,49 @@ be_local_closure(Matter_Plugin_parse_sensors, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: has +********************************************************************/ +be_local_closure(Matter_Plugin_has, /* name */ + be_nested_proto( + 6, /* 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(clusters), + /* K1 */ be_nested_str_weak(contains), + /* K2 */ be_nested_str_weak(endpoints), + /* K3 */ be_nested_str_weak(find), + }), + be_str_weak(has), + &be_const_str_solidified, + ( &(const binstruction[15]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0x5C140200, // 0002 MOVE R5 R1 + 0x7C0C0400, // 0003 CALL R3 2 + 0x780E0006, // 0004 JMPF R3 #000C + 0x880C0102, // 0005 GETMBR R3 R0 K2 + 0x8C0C0703, // 0006 GETMET R3 R3 K3 + 0x5C140400, // 0007 MOVE R5 R2 + 0x7C0C0400, // 0008 CALL R3 2 + 0x4C100000, // 0009 LDNIL R4 + 0x200C0604, // 000A NE R3 R3 R4 + 0x740E0000, // 000B JMPT R3 #000D + 0x500C0001, // 000C LDBOOL R3 0 1 + 0x500C0200, // 000D LDBOOL R3 1 0 + 0x80040600, // 000E RET 1 R3 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: parse_configuration ********************************************************************/ @@ -382,69 +425,41 @@ be_local_closure(Matter_Plugin_subscribe_attribute, /* name */ /******************************************************************** -** Solidified function: has +** Solidified function: ack_request ********************************************************************/ -be_local_closure(Matter_Plugin_has, /* name */ +be_local_closure(Matter_Plugin_ack_request, /* name */ be_nested_proto( 6, /* 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(clusters), - /* K1 */ be_nested_str_weak(contains), - /* K2 */ be_nested_str_weak(endpoints), - /* K3 */ be_nested_str_weak(find), - }), - be_str_weak(has), - &be_const_str_solidified, - ( &(const binstruction[15]) { /* code */ - 0x880C0100, // 0000 GETMBR R3 R0 K0 - 0x8C0C0701, // 0001 GETMET R3 R3 K1 - 0x5C140200, // 0002 MOVE R5 R1 - 0x7C0C0400, // 0003 CALL R3 2 - 0x780E0006, // 0004 JMPF R3 #000C - 0x880C0102, // 0005 GETMBR R3 R0 K2 - 0x8C0C0703, // 0006 GETMET R3 R3 K3 - 0x5C140400, // 0007 MOVE R5 R2 - 0x7C0C0400, // 0008 CALL R3 2 - 0x4C100000, // 0009 LDNIL R4 - 0x200C0604, // 000A NE R3 R3 R4 - 0x740E0000, // 000B JMPT R3 #000D - 0x500C0001, // 000C LDBOOL R3 0 1 - 0x500C0200, // 000D LDBOOL R3 1 0 - 0x80040600, // 000E RET 1 R3 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_endpoint -********************************************************************/ -be_local_closure(Matter_Plugin_get_endpoint, /* name */ - be_nested_proto( - 2, /* nstack */ - 1, /* argc */ + 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(endpoint), + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(msg), + /* K1 */ be_nested_str_weak(device), + /* K2 */ be_nested_str_weak(message_handler), + /* K3 */ be_nested_str_weak(im), + /* K4 */ be_nested_str_weak(send_ack_now), }), - be_str_weak(get_endpoint), + be_str_weak(ack_request), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 + ( &(const binstruction[13]) { /* code */ + 0x88080300, // 0000 GETMBR R2 R1 K0 + 0x4C0C0000, // 0001 LDNIL R3 + 0x200C0403, // 0002 NE R3 R2 R3 + 0x780E0005, // 0003 JMPF R3 #000A + 0x880C0101, // 0004 GETMBR R3 R0 K1 + 0x880C0702, // 0005 GETMBR R3 R3 K2 + 0x880C0703, // 0006 GETMBR R3 R3 K3 + 0x8C0C0704, // 0007 GETMET R3 R3 K4 + 0x5C140400, // 0008 MOVE R5 R2 + 0x7C0C0400, // 0009 CALL R3 2 + 0x4C0C0000, // 000A LDNIL R3 + 0x90060003, // 000B SETMBR R1 K0 R3 + 0x80000000, // 000C RET 0 }) ) ); @@ -687,34 +702,26 @@ be_local_closure(Matter_Plugin_contains_cluster, /* name */ /******************************************************************** -** Solidified function: send_ack_now +** Solidified function: ********************************************************************/ -be_local_closure(Matter_Plugin_send_ack_now, /* name */ +be_local_closure(Matter_Plugin__X3Clambda_X3E, /* name */ be_nested_proto( - 5, /* nstack */ - 2, /* argc */ - 2, /* varg */ + 3, /* nstack */ + 1, /* argc */ + 0, /* 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(device), - /* K1 */ be_nested_str_weak(message_handler), - /* K2 */ be_nested_str_weak(im), - /* K3 */ be_nested_str_weak(send_ack_now), - }), - be_str_weak(send_ack_now), + 0, /* has constants */ + NULL, /* no const */ + be_str_weak(_X3Clambda_X3E), &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x88080501, // 0001 GETMBR R2 R2 K1 - 0x88080502, // 0002 GETMBR R2 R2 K2 - 0x8C080503, // 0003 GETMET R2 R2 K3 - 0x5C100200, // 0004 MOVE R4 R1 - 0x7C080400, // 0005 CALL R2 2 - 0x80000000, // 0006 RET 0 + ( &(const binstruction[ 4]) { /* code */ + 0x60040008, // 0000 GETGBL R1 G8 + 0x5C080000, // 0001 MOVE R2 R0 + 0x7C040200, // 0002 CALL R1 1 + 0x80040200, // 0003 RET 1 R1 }) ) ); @@ -820,26 +827,26 @@ be_local_closure(Matter_Plugin_update_shadow_lazy, /* name */ /******************************************************************** -** Solidified function: +** Solidified function: get_endpoint ********************************************************************/ -be_local_closure(Matter_Plugin__X3Clambda_X3E, /* name */ +be_local_closure(Matter_Plugin_get_endpoint, /* name */ be_nested_proto( - 3, /* nstack */ + 2, /* nstack */ 1, /* argc */ - 0, /* varg */ + 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(_X3Clambda_X3E), + 1, /* has constants */ + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(endpoint), + }), + be_str_weak(get_endpoint), &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ - 0x60040008, // 0000 GETGBL R1 G8 - 0x5C080000, // 0001 MOVE R2 R0 - 0x7C040200, // 0002 CALL R1 1 - 0x80040200, // 0003 RET 1 R1 + ( &(const binstruction[ 2]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -1071,13 +1078,16 @@ be_local_class(Matter_Plugin, be_nested_map(37, ( (struct bmapnode*) &(const bmapnode[]) { { be_const_key_weak(init, -1), be_const_closure(Matter_Plugin_init_closure) }, - { be_const_key_weak(read_event, 8), be_const_closure(Matter_Plugin_read_event_closure) }, + { be_const_key_weak(read_event, 11), be_const_closure(Matter_Plugin_read_event_closure) }, { be_const_key_weak(tick, -1), be_const_var(4) }, { be_const_key_weak(is_local_device, 18), be_const_closure(Matter_Plugin_is_local_device_closure) }, { be_const_key_weak(UPDATE_TIME, -1), be_const_int(5000) }, { be_const_key_weak(get_attribute_list, -1), be_const_closure(Matter_Plugin_get_attribute_list_closure) }, - { be_const_key_weak(ui_conf_to_string, 28), be_const_static_closure(Matter_Plugin_ui_conf_to_string_closure) }, + { be_const_key_weak(ui_conf_to_string, 26), be_const_static_closure(Matter_Plugin_ui_conf_to_string_closure) }, { be_const_key_weak(every_250ms, -1), be_const_closure(Matter_Plugin_every_250ms_closure) }, + { be_const_key_weak(ack_request, -1), be_const_closure(Matter_Plugin_ack_request_closure) }, + { be_const_key_weak(NAME, -1), be_nested_str_weak() }, + { be_const_key_weak(parse_sensors, -1), be_const_closure(Matter_Plugin_parse_sensors_closure) }, { be_const_key_weak(CLUSTERS, 36), be_const_simple_instance(be_nested_simple_instance(&be_class_map, { be_const_map( * be_nested_map(2, ( (struct bmapnode*) &(const bmapnode[]) { @@ -1097,28 +1107,25 @@ be_local_class(Matter_Plugin, be_const_int(17), })) ) } )) }, })) ) } )) }, - { be_const_key_weak(NAME, -1), be_nested_str_weak() }, - { be_const_key_weak(parse_sensors, -1), be_const_closure(Matter_Plugin_parse_sensors_closure) }, - { be_const_key_weak(get_endpoint, -1), be_const_closure(Matter_Plugin_get_endpoint_closure) }, { be_const_key_weak(parse_configuration, -1), be_const_closure(Matter_Plugin_parse_configuration_closure) }, { be_const_key_weak(ui_string_to_conf, -1), be_const_static_closure(Matter_Plugin_ui_string_to_conf_closure) }, { be_const_key_weak(contains_cluster, -1), be_const_closure(Matter_Plugin_contains_cluster_closure) }, - { be_const_key_weak(attribute_updated, 11), be_const_closure(Matter_Plugin_attribute_updated_closure) }, - { be_const_key_weak(has, -1), be_const_closure(Matter_Plugin_has_closure) }, + { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(Matter_Plugin__X3Clambda_X3E_closure) }, + { be_const_key_weak(has, 8), be_const_closure(Matter_Plugin_has_closure) }, { be_const_key_weak(device, 4), be_const_var(1) }, { be_const_key_weak(timed_request, -1), be_const_closure(Matter_Plugin_timed_request_closure) }, { be_const_key_weak(get_cluster_list, -1), be_const_closure(Matter_Plugin_get_cluster_list_closure) }, { be_const_key_weak(read_attribute, -1), be_const_closure(Matter_Plugin_read_attribute_closure) }, { be_const_key_weak(ARG, 14), be_nested_str_weak() }, - { be_const_key_weak(send_ack_now, -1), be_const_closure(Matter_Plugin_send_ack_now_closure) }, - { be_const_key_weak(subscribe_attribute, 26), be_const_closure(Matter_Plugin_subscribe_attribute_closure) }, - { be_const_key_weak(clusters, -1), be_const_var(3) }, - { be_const_key_weak(write_attribute, 24), be_const_closure(Matter_Plugin_write_attribute_closure) }, - { be_const_key_weak(ARG_TYPE, 15), be_const_static_closure(Matter_Plugin__X3Clambda_X3E_closure) }, + { be_const_key_weak(invoke_request, -1), be_const_closure(Matter_Plugin_invoke_request_closure) }, + { be_const_key_weak(subscribe_attribute, 24), be_const_closure(Matter_Plugin_subscribe_attribute_closure) }, + { be_const_key_weak(get_endpoint, 30), be_const_closure(Matter_Plugin_get_endpoint_closure) }, + { be_const_key_weak(write_attribute, 28), be_const_closure(Matter_Plugin_write_attribute_closure) }, + { be_const_key_weak(ARG_HINT, 22), be_nested_str_weak(_Not_X20used_) }, { be_const_key_weak(update_shadow_lazy, -1), be_const_closure(Matter_Plugin_update_shadow_lazy_closure) }, - { be_const_key_weak(invoke_request, 30), be_const_closure(Matter_Plugin_invoke_request_closure) }, + { be_const_key_weak(clusters, -1), be_const_var(3) }, { be_const_key_weak(endpoint, -1), be_const_var(2) }, - { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(_Not_X20used_) }, + { be_const_key_weak(attribute_updated, 15), be_const_closure(Matter_Plugin_attribute_updated_closure) }, { be_const_key_weak(subscribe_event, -1), be_const_closure(Matter_Plugin_subscribe_event_closure) }, { be_const_key_weak(update_shadow, -1), be_const_closure(Matter_Plugin_update_shadow_closure) }, { be_const_key_weak(consolidate_clusters, -1), be_const_closure(Matter_Plugin_consolidate_clusters_closure) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h index 56c6ff30320b..0532fdda0a3b 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Root.h @@ -47,7 +47,7 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ ), }), 1, /* has constants */ - ( &(const bvalue[101]) { /* constants */ + ( &(const bvalue[100]) { /* constants */ /* K0 */ be_nested_str_weak(crypto), /* K1 */ be_nested_str_weak(matter), /* K2 */ be_nested_str_weak(TLV), @@ -65,90 +65,89 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ /* K14 */ be_const_int(2), /* K15 */ be_nested_str_weak(XX), /* K16 */ be_const_int(3), - /* K17 */ be_nested_str_weak(send_ack_now), - /* K18 */ be_nested_str_weak(msg), - /* K19 */ be_nested_str_weak(_fabric), - /* K20 */ be_nested_str_weak(fabric_completed), - /* K21 */ be_nested_str_weak(set_no_expiration), - /* K22 */ be_nested_str_weak(save), - /* K23 */ be_nested_str_weak(device), - /* K24 */ be_nested_str_weak(start_commissioning_complete_deferred), - /* K25 */ be_nested_str_weak(context_error), - /* K26 */ be_nested_str_weak(CommissioningComplete_X3A_X20no_X20fabric_X20attached), - /* K27 */ be_nested_str_weak(status), - /* K28 */ be_nested_str_weak(UNSUPPORTED_COMMAND), - /* K29 */ be_nested_str_weak(B2), - /* K30 */ be_nested_str_weak(DAC_Cert_FFF1_8000), - /* K31 */ be_nested_str_weak(PAI_Cert_FFF1), - /* K32 */ be_nested_str_weak(CD_FFF1_8000), - /* K33 */ be_nested_str_weak(B1), - /* K34 */ be_nested_str_weak(U4), - /* K35 */ be_nested_str_weak(tasmota), - /* K36 */ be_nested_str_weak(rtc_utc), - /* K37 */ be_nested_str_weak(tlv2raw), - /* K38 */ be_nested_str_weak(get_ac), - /* K39 */ be_nested_str_weak(EC_P256), - /* K40 */ be_nested_str_weak(ecdsa_sign_sha256), - /* K41 */ be_nested_str_weak(DAC_Priv_FFF1_8000), - /* K42 */ be_nested_str_weak(gen_CSR), - /* K43 */ be_nested_str_weak(set_temp_ca), - /* K44 */ be_nested_str_weak(SUCCESS), - /* K45 */ be_nested_str_weak(log), - /* K46 */ be_nested_str_weak(MTR_X3A_X20AddNoc_X20Args_X3D), - /* K47 */ be_nested_str_weak(get_temp_ca), - /* K48 */ be_nested_str_weak(MTR_X3A_X20Error_X3A_X20AdNOC_X20without_X20CA), - /* K49 */ be_nested_str_weak(sessions), - /* K50 */ be_nested_str_weak(create_fabric), - /* K51 */ be_nested_str_weak(set_ca), - /* K52 */ be_nested_str_weak(set_noc_icac), - /* K53 */ be_nested_str_weak(set_ipk_epoch_key), - /* K54 */ be_nested_str_weak(set_admin_subject_vendor), - /* K55 */ be_nested_str_weak(set_pk), - /* K56 */ be_nested_str_weak(get_pk), - /* K57 */ be_nested_str_weak(parse), - /* K58 */ be_nested_str_weak(findsub), - /* K59 */ be_nested_str_weak(MTR_X3A_X20Error_X3A_X20no_X20fabricid_X20nor_X20deviceid_X20in_X20NOC_X20certificate), - /* K60 */ be_nested_str_weak(int), - /* K61 */ be_nested_str_weak(int64), - /* K62 */ be_nested_str_weak(fromu32), - /* K63 */ be_nested_str_weak(tobytes), - /* K64 */ be_nested_str_weak(get_temp_ca_pub), - /* K65 */ be_const_int(2147483647), - /* K66 */ be_nested_str_weak(fromstring), - /* K67 */ be_nested_str_weak(CompressedFabric), - /* K68 */ be_nested_str_weak(HKDF_SHA256), - /* K69 */ be_nested_str_weak(copy), - /* K70 */ be_nested_str_weak(reverse), - /* K71 */ be_nested_str_weak(derive), - /* K72 */ be_nested_str_weak(commissioning_admin_fabric), - /* K73 */ be_nested_str_weak(set_fabric_device), - /* K74 */ be_nested_str_weak(fabric_candidate), - /* K75 */ be_nested_str_weak(start_operational_discovery_deferred), - /* K76 */ be_nested_str_weak(is_PASE), - /* K77 */ be_nested_str_weak(set_expire_in_seconds), - /* K78 */ be_nested_str_weak(log_new_fabric), - /* K79 */ be_nested_str_weak(set_fabric_label), - /* K80 */ be_nested_str_weak(MTR_X3A_X20_X2E_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20Update_X20fabric_X20_X27_X25s_X27_X20label_X3D_X27_X25s_X27), - /* K81 */ be_nested_str_weak(get_fabric_id), - /* K82 */ be_nested_str_weak(tohex), - /* K83 */ be_nested_str_weak(fabric_index_X3A), - /* K84 */ be_nested_str_weak(active_fabrics), - /* K85 */ be_nested_str_weak(get_fabric_index), - /* K86 */ be_nested_str_weak(set_timer), - /* K87 */ be_nested_str_weak(stop_iteration), - /* K88 */ be_nested_str_weak(MTR_X3A_X20RemoveFabric_X20fabric_X28), - /* K89 */ be_nested_str_weak(_X29_X20not_X20found), - /* K90 */ be_nested_str_weak(INVALID_ACTION), - /* K91 */ be_nested_str_weak(MTR_X3A_X20OpenCommissioningWindow_X28timeout_X3D_X25i_X2C_X20passcode_X3D_X25s_X2C_X20discriminator_X3D_X25i_X2C_X20iterations_X3D_X25i_X2C_X20salt_X3D_X25s_X29), - /* K92 */ be_nested_str_weak(INVALID_DATA_TYPE), - /* K93 */ be_nested_str_weak(MTR_X3A_X20wrong_X20size_X20for_X20PAKE_X20parameters), - /* K94 */ be_nested_str_weak(CONSTRAINT_ERROR), - /* K95 */ be_nested_str_weak(start_basic_commissioning), - /* K96 */ be_nested_str_weak(get_fabric), - /* K97 */ be_nested_str_weak(MTR_X3A_X20OpenBasicCommissioningWindow_X20commissioning_timeout_X3D), - /* K98 */ be_nested_str_weak(start_root_basic_commissioning), - /* K99 */ be_nested_str_weak(stop_basic_commissioning), - /* K100 */ be_nested_str_weak(invoke_request), + /* K17 */ be_nested_str_weak(ack_request), + /* K18 */ be_nested_str_weak(_fabric), + /* K19 */ be_nested_str_weak(fabric_completed), + /* K20 */ be_nested_str_weak(set_no_expiration), + /* K21 */ be_nested_str_weak(save), + /* K22 */ be_nested_str_weak(device), + /* K23 */ be_nested_str_weak(start_commissioning_complete_deferred), + /* K24 */ be_nested_str_weak(context_error), + /* K25 */ be_nested_str_weak(CommissioningComplete_X3A_X20no_X20fabric_X20attached), + /* K26 */ be_nested_str_weak(status), + /* K27 */ be_nested_str_weak(UNSUPPORTED_COMMAND), + /* K28 */ be_nested_str_weak(B2), + /* K29 */ be_nested_str_weak(DAC_Cert_FFF1_8000), + /* K30 */ be_nested_str_weak(PAI_Cert_FFF1), + /* K31 */ be_nested_str_weak(CD_FFF1_8000), + /* K32 */ be_nested_str_weak(B1), + /* K33 */ be_nested_str_weak(U4), + /* K34 */ be_nested_str_weak(tasmota), + /* K35 */ be_nested_str_weak(rtc_utc), + /* K36 */ be_nested_str_weak(tlv2raw), + /* K37 */ be_nested_str_weak(get_ac), + /* K38 */ be_nested_str_weak(EC_P256), + /* K39 */ be_nested_str_weak(ecdsa_sign_sha256), + /* K40 */ be_nested_str_weak(DAC_Priv_FFF1_8000), + /* K41 */ be_nested_str_weak(gen_CSR), + /* K42 */ be_nested_str_weak(set_temp_ca), + /* K43 */ be_nested_str_weak(SUCCESS), + /* K44 */ be_nested_str_weak(log), + /* K45 */ be_nested_str_weak(MTR_X3A_X20AddNoc_X20Args_X3D), + /* K46 */ be_nested_str_weak(get_temp_ca), + /* K47 */ be_nested_str_weak(MTR_X3A_X20Error_X3A_X20AdNOC_X20without_X20CA), + /* K48 */ be_nested_str_weak(sessions), + /* K49 */ be_nested_str_weak(create_fabric), + /* K50 */ be_nested_str_weak(set_ca), + /* K51 */ be_nested_str_weak(set_noc_icac), + /* K52 */ be_nested_str_weak(set_ipk_epoch_key), + /* K53 */ be_nested_str_weak(set_admin_subject_vendor), + /* K54 */ be_nested_str_weak(set_pk), + /* K55 */ be_nested_str_weak(get_pk), + /* K56 */ be_nested_str_weak(parse), + /* K57 */ be_nested_str_weak(findsub), + /* K58 */ be_nested_str_weak(MTR_X3A_X20Error_X3A_X20no_X20fabricid_X20nor_X20deviceid_X20in_X20NOC_X20certificate), + /* K59 */ be_nested_str_weak(int), + /* K60 */ be_nested_str_weak(int64), + /* K61 */ be_nested_str_weak(fromu32), + /* K62 */ be_nested_str_weak(tobytes), + /* K63 */ be_nested_str_weak(get_temp_ca_pub), + /* K64 */ be_const_int(2147483647), + /* K65 */ be_nested_str_weak(fromstring), + /* K66 */ be_nested_str_weak(CompressedFabric), + /* K67 */ be_nested_str_weak(HKDF_SHA256), + /* K68 */ be_nested_str_weak(copy), + /* K69 */ be_nested_str_weak(reverse), + /* K70 */ be_nested_str_weak(derive), + /* K71 */ be_nested_str_weak(commissioning_admin_fabric), + /* K72 */ be_nested_str_weak(set_fabric_device), + /* K73 */ be_nested_str_weak(fabric_candidate), + /* K74 */ be_nested_str_weak(start_operational_discovery_deferred), + /* K75 */ be_nested_str_weak(is_PASE), + /* K76 */ be_nested_str_weak(set_expire_in_seconds), + /* K77 */ be_nested_str_weak(log_new_fabric), + /* K78 */ be_nested_str_weak(set_fabric_label), + /* K79 */ be_nested_str_weak(MTR_X3A_X20_X2E_X20_X20_X20_X20_X20_X20_X20_X20_X20_X20Update_X20fabric_X20_X27_X25s_X27_X20label_X3D_X27_X25s_X27), + /* K80 */ be_nested_str_weak(get_fabric_id), + /* K81 */ be_nested_str_weak(tohex), + /* K82 */ be_nested_str_weak(fabric_index_X3A), + /* K83 */ be_nested_str_weak(active_fabrics), + /* K84 */ be_nested_str_weak(get_fabric_index), + /* K85 */ be_nested_str_weak(set_timer), + /* K86 */ be_nested_str_weak(stop_iteration), + /* K87 */ be_nested_str_weak(MTR_X3A_X20RemoveFabric_X20fabric_X28), + /* K88 */ be_nested_str_weak(_X29_X20not_X20found), + /* K89 */ be_nested_str_weak(INVALID_ACTION), + /* K90 */ be_nested_str_weak(MTR_X3A_X20OpenCommissioningWindow_X28timeout_X3D_X25i_X2C_X20passcode_X3D_X25s_X2C_X20discriminator_X3D_X25i_X2C_X20iterations_X3D_X25i_X2C_X20salt_X3D_X25s_X29), + /* K91 */ be_nested_str_weak(INVALID_DATA_TYPE), + /* K92 */ be_nested_str_weak(MTR_X3A_X20wrong_X20size_X20for_X20PAKE_X20parameters), + /* K93 */ be_nested_str_weak(CONSTRAINT_ERROR), + /* K94 */ be_nested_str_weak(start_basic_commissioning), + /* K95 */ be_nested_str_weak(get_fabric), + /* K96 */ be_nested_str_weak(MTR_X3A_X20OpenBasicCommissioningWindow_X20commissioning_timeout_X3D), + /* K97 */ be_nested_str_weak(start_root_basic_commissioning), + /* K98 */ be_nested_str_weak(stop_basic_commissioning), + /* K99 */ be_nested_str_weak(invoke_request), }), be_str_weak(invoke_request), &be_const_str_solidified, @@ -220,17 +219,17 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x1C200E08, // 0040 EQ R8 R7 R8 0x78220021, // 0041 JMPF R8 #0064 0x8C200111, // 0042 GETMET R8 R0 K17 - 0x88280712, // 0043 GETMBR R10 R3 K18 + 0x5C280600, // 0043 MOVE R10 R3 0x7C200400, // 0044 CALL R8 2 - 0x88200313, // 0045 GETMBR R8 R1 K19 + 0x88200312, // 0045 GETMBR R8 R1 K18 0x7822001B, // 0046 JMPF R8 #0063 0x90061105, // 0047 SETMBR R1 K8 K5 - 0x88200313, // 0048 GETMBR R8 R1 K19 - 0x8C201114, // 0049 GETMET R8 R8 K20 + 0x88200312, // 0048 GETMBR R8 R1 K18 + 0x8C201113, // 0049 GETMET R8 R8 K19 0x7C200200, // 004A CALL R8 1 - 0x8C200315, // 004B GETMET R8 R1 K21 + 0x8C200314, // 004B GETMET R8 R1 K20 0x7C200200, // 004C CALL R8 1 - 0x8C200316, // 004D GETMET R8 R1 K22 + 0x8C200315, // 004D GETMET R8 R1 K21 0x7C200200, // 004E CALL R8 1 0x8C200B09, // 004F GETMET R8 R5 K9 0x7C200200, // 0050 CALL R8 1 @@ -246,13 +245,13 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x7C240800, // 005A CALL R9 4 0x54260004, // 005B LDINT R9 5 0x900E0809, // 005C SETMBR R3 K4 R9 - 0x88240117, // 005D GETMBR R9 R0 K23 - 0x8C241318, // 005E GETMET R9 R9 K24 + 0x88240116, // 005D GETMBR R9 R0 K22 + 0x8C241317, // 005E GETMET R9 R9 K23 0x5C2C0200, // 005F MOVE R11 R1 0x7C240400, // 0060 CALL R9 2 0x80041000, // 0061 RET 1 R8 0x70020000, // 0062 JMP #0064 - 0xB006331A, // 0063 RAISE 1 K25 K26 + 0xB0063119, // 0063 RAISE 1 K24 K25 0x70020261, // 0064 JMP #02C7 0x5422003D, // 0065 LDINT R8 62 0x1C200C08, // 0066 EQ R8 R6 R8 @@ -267,23 +266,23 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x2024110E, // 006F NE R9 R8 K14 0x78260004, // 0070 JMPF R9 #0076 0xB8260200, // 0071 GETNGBL R9 K1 - 0x8824131C, // 0072 GETMBR R9 R9 K28 - 0x900E3609, // 0073 SETMBR R3 K27 R9 + 0x8824131B, // 0072 GETMBR R9 R9 K27 + 0x900E3409, // 0073 SETMBR R3 K26 R9 0x4C240000, // 0074 LDNIL R9 0x80041200, // 0075 RET 1 R9 0x8C240B09, // 0076 GETMET R9 R5 K9 0x7C240200, // 0077 CALL R9 1 0x8C28130A, // 0078 GETMET R10 R9 K10 0x58300005, // 0079 LDCONST R12 K5 - 0x88340B1D, // 007A GETMBR R13 R5 K29 + 0x88340B1C, // 007A GETMBR R13 R5 K28 0x1C381107, // 007B EQ R14 R8 K7 0x783A0003, // 007C JMPF R14 #0081 0xB83A0200, // 007D GETNGBL R14 K1 - 0x8C381D1E, // 007E GETMET R14 R14 K30 + 0x8C381D1D, // 007E GETMET R14 R14 K29 0x7C380200, // 007F CALL R14 1 0x70020002, // 0080 JMP #0084 0xB83A0200, // 0081 GETNGBL R14 K1 - 0x8C381D1F, // 0082 GETMET R14 R14 K31 + 0x8C381D1E, // 0082 GETMET R14 R14 K30 0x7C380200, // 0083 CALL R14 1 0x7C280800, // 0084 CALL R10 4 0x900E0910, // 0085 SETMBR R3 K4 K16 @@ -307,33 +306,33 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x7C240200, // 0097 CALL R9 1 0x8C28130A, // 0098 GETMET R10 R9 K10 0x58300007, // 0099 LDCONST R12 K7 - 0x88340B1D, // 009A GETMBR R13 R5 K29 + 0x88340B1C, // 009A GETMBR R13 R5 K28 0xB83A0200, // 009B GETNGBL R14 K1 - 0x8C381D20, // 009C GETMET R14 R14 K32 + 0x8C381D1F, // 009C GETMET R14 R14 K31 0x7C380200, // 009D CALL R14 1 0x7C280800, // 009E CALL R10 4 0x8C28130A, // 009F GETMET R10 R9 K10 0x5830000E, // 00A0 LDCONST R12 K14 - 0x88340B21, // 00A1 GETMBR R13 R5 K33 + 0x88340B20, // 00A1 GETMBR R13 R5 K32 0x5C381000, // 00A2 MOVE R14 R8 0x7C280800, // 00A3 CALL R10 4 0x8C28130A, // 00A4 GETMET R10 R9 K10 0x58300010, // 00A5 LDCONST R12 K16 - 0x88340B22, // 00A6 GETMBR R13 R5 K34 - 0xB83A4600, // 00A7 GETNGBL R14 K35 - 0x8C381D24, // 00A8 GETMET R14 R14 K36 + 0x88340B21, // 00A6 GETMBR R13 R5 K33 + 0xB83A4400, // 00A7 GETNGBL R14 K34 + 0x8C381D23, // 00A8 GETMET R14 R14 K35 0x7C380200, // 00A9 CALL R14 1 0x7C280800, // 00AA CALL R10 4 - 0x8C281325, // 00AB GETMET R10 R9 K37 + 0x8C281324, // 00AB GETMET R10 R9 K36 0x7C280200, // 00AC CALL R10 1 - 0x8C2C0326, // 00AD GETMET R11 R1 K38 + 0x8C2C0325, // 00AD GETMET R11 R1 K37 0x7C2C0200, // 00AE CALL R11 1 0x0030140B, // 00AF ADD R12 R10 R11 - 0x8C340927, // 00B0 GETMET R13 R4 K39 + 0x8C340926, // 00B0 GETMET R13 R4 K38 0x7C340200, // 00B1 CALL R13 1 - 0x8C341B28, // 00B2 GETMET R13 R13 K40 + 0x8C341B27, // 00B2 GETMET R13 R13 K39 0xB83E0200, // 00B3 GETNGBL R15 K1 - 0x8C3C1F29, // 00B4 GETMET R15 R15 K41 + 0x8C3C1F28, // 00B4 GETMET R15 R15 K40 0x7C3C0200, // 00B5 CALL R15 1 0x5C401800, // 00B6 MOVE R16 R12 0x7C340600, // 00B7 CALL R13 3 @@ -341,12 +340,12 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x7C380200, // 00B9 CALL R14 1 0x8C3C1D0A, // 00BA GETMET R15 R14 K10 0x58440005, // 00BB LDCONST R17 K5 - 0x88480B1D, // 00BC GETMBR R18 R5 K29 + 0x88480B1C, // 00BC GETMBR R18 R5 K28 0x5C4C1400, // 00BD MOVE R19 R10 0x7C3C0800, // 00BE CALL R15 4 0x8C3C1D0A, // 00BF GETMET R15 R14 K10 0x58440007, // 00C0 LDCONST R17 K7 - 0x88480B21, // 00C1 GETMBR R18 R5 K33 + 0x88480B20, // 00C1 GETMBR R18 R5 K32 0x5C4C1A00, // 00C2 MOVE R19 R13 0x7C3C0800, // 00C3 CALL R15 4 0x900E0907, // 00C4 SETMBR R3 K4 K7 @@ -356,7 +355,7 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x1C200E08, // 00C8 EQ R8 R7 R8 0x7822003C, // 00C9 JMPF R8 #0107 0x8C200111, // 00CA GETMET R8 R0 K17 - 0x88280712, // 00CB GETMBR R10 R3 K18 + 0x5C280600, // 00CB MOVE R10 R3 0x7C200400, // 00CC CALL R8 2 0x8C200506, // 00CD GETMET R8 R2 K6 0x58280005, // 00CE LDCONST R10 K5 @@ -373,30 +372,30 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x582C0007, // 00D9 LDCONST R11 K7 0x50300000, // 00DA LDBOOL R12 0 0 0x7C240600, // 00DB CALL R9 3 - 0x8C28032A, // 00DC GETMET R10 R1 K42 + 0x8C280329, // 00DC GETMET R10 R1 K41 0x7C280200, // 00DD CALL R10 1 0x8C2C0B09, // 00DE GETMET R11 R5 K9 0x7C2C0200, // 00DF CALL R11 1 0x8C30170A, // 00E0 GETMET R12 R11 K10 0x58380007, // 00E1 LDCONST R14 K7 - 0x883C0B1D, // 00E2 GETMBR R15 R5 K29 + 0x883C0B1C, // 00E2 GETMBR R15 R5 K28 0x5C401400, // 00E3 MOVE R16 R10 0x7C300800, // 00E4 CALL R12 4 0x8C30170A, // 00E5 GETMET R12 R11 K10 0x5838000E, // 00E6 LDCONST R14 K14 - 0x883C0B21, // 00E7 GETMBR R15 R5 K33 + 0x883C0B20, // 00E7 GETMBR R15 R5 K32 0x5C401000, // 00E8 MOVE R16 R8 0x7C300800, // 00E9 CALL R12 4 - 0x8C301725, // 00EA GETMET R12 R11 K37 + 0x8C301724, // 00EA GETMET R12 R11 K36 0x7C300200, // 00EB CALL R12 1 - 0x8C340326, // 00EC GETMET R13 R1 K38 + 0x8C340325, // 00EC GETMET R13 R1 K37 0x7C340200, // 00ED CALL R13 1 0x0034180D, // 00EE ADD R13 R12 R13 - 0x8C380927, // 00EF GETMET R14 R4 K39 + 0x8C380926, // 00EF GETMET R14 R4 K38 0x7C380200, // 00F0 CALL R14 1 - 0x8C381D28, // 00F1 GETMET R14 R14 K40 + 0x8C381D27, // 00F1 GETMET R14 R14 K39 0xB8420200, // 00F2 GETNGBL R16 K1 - 0x8C402129, // 00F3 GETMET R16 R16 K41 + 0x8C402128, // 00F3 GETMET R16 R16 K40 0x7C400200, // 00F4 CALL R16 1 0x5C441A00, // 00F5 MOVE R17 R13 0x7C380600, // 00F6 CALL R14 3 @@ -404,12 +403,12 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x7C3C0200, // 00F8 CALL R15 1 0x8C401F0A, // 00F9 GETMET R16 R15 K10 0x58480005, // 00FA LDCONST R18 K5 - 0x884C0B1D, // 00FB GETMBR R19 R5 K29 + 0x884C0B1C, // 00FB GETMBR R19 R5 K28 0x5C501800, // 00FC MOVE R20 R12 0x7C400800, // 00FD CALL R16 4 0x8C401F0A, // 00FE GETMET R16 R15 K10 0x58480007, // 00FF LDCONST R18 K7 - 0x884C0B21, // 0100 GETMBR R19 R5 K33 + 0x884C0B20, // 0100 GETMBR R19 R5 K32 0x5C501C00, // 0101 MOVE R20 R14 0x7C400800, // 0102 CALL R16 4 0x54420004, // 0103 LDINT R16 5 @@ -422,24 +421,24 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x8C200506, // 010A GETMET R8 R2 K6 0x58280005, // 010B LDCONST R10 K5 0x7C200400, // 010C CALL R8 2 - 0x8C24032B, // 010D GETMET R9 R1 K43 + 0x8C24032A, // 010D GETMET R9 R1 K42 0x5C2C1000, // 010E MOVE R11 R8 0x7C240400, // 010F CALL R9 2 0xB8260200, // 0110 GETNGBL R9 K1 - 0x8824132C, // 0111 GETMBR R9 R9 K44 - 0x900E3609, // 0112 SETMBR R3 K27 R9 + 0x8824132B, // 0111 GETMBR R9 R9 K43 + 0x900E3409, // 0112 SETMBR R3 K26 R9 0x4C240000, // 0113 LDNIL R9 0x80041200, // 0114 RET 1 R9 0x70020113, // 0115 JMP #022A 0x54220005, // 0116 LDINT R8 6 0x1C200E08, // 0117 EQ R8 R7 R8 0x782200B9, // 0118 JMPF R8 #01D3 - 0xB8224600, // 0119 GETNGBL R8 K35 - 0x8C20112D, // 011A GETMET R8 R8 K45 + 0xB8224400, // 0119 GETNGBL R8 K34 + 0x8C20112C, // 011A GETMET R8 R8 K44 0x60280008, // 011B GETGBL R10 G8 0x5C2C0400, // 011C MOVE R11 R2 0x7C280200, // 011D CALL R10 1 - 0x002A5C0A, // 011E ADD R10 K46 R10 + 0x002A5A0A, // 011E ADD R10 K45 R10 0x542E0003, // 011F LDINT R11 4 0x7C200600, // 0120 CALL R8 3 0x8C200506, // 0121 GETMET R8 R2 K6 @@ -463,47 +462,47 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x8C300506, // 0133 GETMET R12 R2 K6 0x543A0003, // 0134 LDINT R14 4 0x7C300400, // 0135 CALL R12 2 - 0x8C34032F, // 0136 GETMET R13 R1 K47 + 0x8C34032E, // 0136 GETMET R13 R1 K46 0x7C340200, // 0137 CALL R13 1 0x4C380000, // 0138 LDNIL R14 0x1C341A0E, // 0139 EQ R13 R13 R14 0x78360006, // 013A JMPF R13 #0142 - 0xB8364600, // 013B GETNGBL R13 K35 - 0x8C341B2D, // 013C GETMET R13 R13 K45 - 0x583C0030, // 013D LDCONST R15 K48 + 0xB8364400, // 013B GETNGBL R13 K34 + 0x8C341B2C, // 013C GETMET R13 R13 K44 + 0x583C002F, // 013D LDCONST R15 K47 0x5840000E, // 013E LDCONST R16 K14 0x7C340600, // 013F CALL R13 3 0x4C340000, // 0140 LDNIL R13 0x80041A00, // 0141 RET 1 R13 - 0x88340117, // 0142 GETMBR R13 R0 K23 - 0x88341B31, // 0143 GETMBR R13 R13 K49 - 0x8C341B32, // 0144 GETMET R13 R13 K50 + 0x88340116, // 0142 GETMBR R13 R0 K22 + 0x88341B30, // 0143 GETMBR R13 R13 K48 + 0x8C341B31, // 0144 GETMET R13 R13 K49 0x7C340200, // 0145 CALL R13 1 - 0x8C381B33, // 0146 GETMET R14 R13 K51 - 0x8C40032F, // 0147 GETMET R16 R1 K47 + 0x8C381B32, // 0146 GETMET R14 R13 K50 + 0x8C40032E, // 0147 GETMET R16 R1 K46 0x7C400200, // 0148 CALL R16 1 0x7C380400, // 0149 CALL R14 2 - 0x8C381B34, // 014A GETMET R14 R13 K52 + 0x8C381B33, // 014A GETMET R14 R13 K51 0x5C401000, // 014B MOVE R16 R8 0x5C441200, // 014C MOVE R17 R9 0x7C380600, // 014D CALL R14 3 - 0x8C381B35, // 014E GETMET R14 R13 K53 + 0x8C381B34, // 014E GETMET R14 R13 K52 0x5C401400, // 014F MOVE R16 R10 0x7C380400, // 0150 CALL R14 2 - 0x8C381B36, // 0151 GETMET R14 R13 K54 + 0x8C381B35, // 0151 GETMET R14 R13 K53 0x5C401600, // 0152 MOVE R16 R11 0x5C441800, // 0153 MOVE R17 R12 0x7C380600, // 0154 CALL R14 3 - 0x8C381B37, // 0155 GETMET R14 R13 K55 - 0x8C400338, // 0156 GETMET R16 R1 K56 + 0x8C381B36, // 0155 GETMET R14 R13 K54 + 0x8C400337, // 0156 GETMET R16 R1 K55 0x7C400200, // 0157 CALL R16 1 0x7C380400, // 0158 CALL R14 2 0xB83A0200, // 0159 GETNGBL R14 K1 0x88381D02, // 015A GETMBR R14 R14 K2 - 0x8C381D39, // 015B GETMET R14 R14 K57 + 0x8C381D38, // 015B GETMET R14 R14 K56 0x5C401000, // 015C MOVE R16 R8 0x7C380400, // 015D CALL R14 2 - 0x8C3C1D3A, // 015E GETMET R15 R14 K58 + 0x8C3C1D39, // 015E GETMET R15 R14 K57 0x54460005, // 015F LDINT R17 6 0x7C3C0400, // 0160 CALL R15 2 0x8C401F06, // 0161 GETMET R16 R15 K6 @@ -516,9 +515,9 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x784A0001, // 0168 JMPF R18 #016B 0x5C482200, // 0169 MOVE R18 R17 0x744A0006, // 016A JMPT R18 #0172 - 0xB84A4600, // 016B GETNGBL R18 K35 - 0x8C48252D, // 016C GETMET R18 R18 K45 - 0x5850003B, // 016D LDCONST R20 K59 + 0xB84A4400, // 016B GETNGBL R18 K34 + 0x8C48252C, // 016C GETMET R18 R18 K44 + 0x5850003A, // 016D LDCONST R20 K58 0x5854000E, // 016E LDCONST R21 K14 0x7C480600, // 016F CALL R18 3 0x50480000, // 0170 LDBOOL R18 0 0 @@ -526,82 +525,82 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x60480004, // 0172 GETGBL R18 G4 0x5C4C2000, // 0173 MOVE R19 R16 0x7C480200, // 0174 CALL R18 1 - 0x1C48253C, // 0175 EQ R18 R18 K60 + 0x1C48253B, // 0175 EQ R18 R18 K59 0x784A0007, // 0176 JMPF R18 #017F - 0xB84A7A00, // 0177 GETNGBL R18 K61 - 0x8C48253E, // 0178 GETMET R18 R18 K62 + 0xB84A7800, // 0177 GETNGBL R18 K60 + 0x8C48253D, // 0178 GETMET R18 R18 K61 0x5C502000, // 0179 MOVE R20 R16 0x7C480400, // 017A CALL R18 2 - 0x8C48253F, // 017B GETMET R18 R18 K63 + 0x8C48253E, // 017B GETMET R18 R18 K62 0x7C480200, // 017C CALL R18 1 0x5C402400, // 017D MOVE R16 R18 0x70020002, // 017E JMP #0182 - 0x8C48213F, // 017F GETMET R18 R16 K63 + 0x8C48213E, // 017F GETMET R18 R16 K62 0x7C480200, // 0180 CALL R18 1 0x5C402400, // 0181 MOVE R16 R18 0x60480004, // 0182 GETGBL R18 G4 0x5C4C2200, // 0183 MOVE R19 R17 0x7C480200, // 0184 CALL R18 1 - 0x1C48253C, // 0185 EQ R18 R18 K60 + 0x1C48253B, // 0185 EQ R18 R18 K59 0x784A0007, // 0186 JMPF R18 #018F - 0xB84A7A00, // 0187 GETNGBL R18 K61 - 0x8C48253E, // 0188 GETMET R18 R18 K62 + 0xB84A7800, // 0187 GETNGBL R18 K60 + 0x8C48253D, // 0188 GETMET R18 R18 K61 0x5C502200, // 0189 MOVE R20 R17 0x7C480400, // 018A CALL R18 2 - 0x8C48253F, // 018B GETMET R18 R18 K63 + 0x8C48253E, // 018B GETMET R18 R18 K62 0x7C480200, // 018C CALL R18 1 0x5C442400, // 018D MOVE R17 R18 0x70020002, // 018E JMP #0192 - 0x8C48233F, // 018F GETMET R18 R17 K63 + 0x8C48233E, // 018F GETMET R18 R17 K62 0x7C480200, // 0190 CALL R18 1 0x5C442400, // 0191 MOVE R17 R18 - 0x8C480340, // 0192 GETMET R18 R1 K64 + 0x8C48033F, // 0192 GETMET R18 R1 K63 0x7C480200, // 0193 CALL R18 1 - 0x404E0F41, // 0194 CONNECT R19 K7 K65 + 0x404E0F40, // 0194 CONNECT R19 K7 K64 0x94482413, // 0195 GETIDX R18 R18 R19 0x60500015, // 0196 GETGBL R20 G21 0x7C500000, // 0197 CALL R20 0 - 0x8C502942, // 0198 GETMET R20 R20 K66 - 0x58580043, // 0199 LDCONST R22 K67 + 0x8C502941, // 0198 GETMET R20 R20 K65 + 0x58580042, // 0199 LDCONST R22 K66 0x7C500400, // 019A CALL R20 2 0x5C4C2800, // 019B MOVE R19 R20 - 0x8C500944, // 019C GETMET R20 R4 K68 + 0x8C500943, // 019C GETMET R20 R4 K67 0x7C500200, // 019D CALL R20 1 - 0x8C542145, // 019E GETMET R21 R16 K69 + 0x8C542144, // 019E GETMET R21 R16 K68 0x7C540200, // 019F CALL R21 1 - 0x8C542B46, // 01A0 GETMET R21 R21 K70 + 0x8C542B45, // 01A0 GETMET R21 R21 K69 0x7C540200, // 01A1 CALL R21 1 - 0x8C582947, // 01A2 GETMET R22 R20 K71 + 0x8C582946, // 01A2 GETMET R22 R20 K70 0x5C602400, // 01A3 MOVE R24 R18 0x5C642A00, // 01A4 MOVE R25 R21 0x5C682600, // 01A5 MOVE R26 R19 0x546E0007, // 01A6 LDINT R27 8 0x7C580A00, // 01A7 CALL R22 5 - 0x885C0313, // 01A8 GETMBR R23 R1 K19 + 0x885C0312, // 01A8 GETMBR R23 R1 K18 0x785E0001, // 01A9 JMPF R23 #01AC - 0x885C0313, // 01AA GETMBR R23 R1 K19 + 0x885C0312, // 01AA GETMBR R23 R1 K18 0x70020001, // 01AB JMP #01AE - 0x885C0117, // 01AC GETMBR R23 R0 K23 - 0x885C2F48, // 01AD GETMBR R23 R23 K72 - 0x8C601B49, // 01AE GETMET R24 R13 K73 + 0x885C0116, // 01AC GETMBR R23 R0 K22 + 0x885C2F47, // 01AD GETMBR R23 R23 K71 + 0x8C601B48, // 01AE GETMET R24 R13 K72 0x5C682000, // 01AF MOVE R26 R16 0x5C6C2200, // 01B0 MOVE R27 R17 0x5C702C00, // 01B1 MOVE R28 R22 0x5C742E00, // 01B2 MOVE R29 R23 0x7C600A00, // 01B3 CALL R24 5 - 0x8C601B4A, // 01B4 GETMET R24 R13 K74 + 0x8C601B49, // 01B4 GETMET R24 R13 K73 0x7C600200, // 01B5 CALL R24 1 - 0x88600117, // 01B6 GETMBR R24 R0 K23 - 0x8C60314B, // 01B7 GETMET R24 R24 K75 + 0x88600116, // 01B6 GETMBR R24 R0 K22 + 0x8C60314A, // 01B7 GETMET R24 R24 K74 0x5C681A00, // 01B8 MOVE R26 R13 0x7C600400, // 01B9 CALL R24 2 - 0x8C60034C, // 01BA GETMET R24 R1 K76 + 0x8C60034B, // 01BA GETMET R24 R1 K75 0x7C600200, // 01BB CALL R24 1 0x78620002, // 01BC JMPF R24 #01C0 - 0x8C60034D, // 01BD GETMET R24 R1 K77 + 0x8C60034C, // 01BD GETMET R24 R1 K76 0x546A003B, // 01BE LDINT R26 60 0x7C600400, // 01BF CALL R24 2 - 0x8C601B4E, // 01C0 GETMET R24 R13 K78 + 0x8C601B4D, // 01C0 GETMET R24 R13 K77 0x7C600200, // 01C1 CALL R24 1 0x8C600B09, // 01C2 GETMET R24 R5 K9 0x7C600200, // 01C3 CALL R24 1 @@ -609,7 +608,7 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x586C0005, // 01C5 LDCONST R27 K5 0x88700B0B, // 01C6 GETMBR R28 R5 K11 0xB8760200, // 01C7 GETNGBL R29 K1 - 0x88743B2C, // 01C8 GETMBR R29 R29 K44 + 0x88743B2B, // 01C8 GETMBR R29 R29 K43 0x7C640800, // 01C9 CALL R25 4 0x8C64310A, // 01CA GETMET R25 R24 K10 0x586C0007, // 01CB LDCONST R27 K7 @@ -626,21 +625,21 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x8C200506, // 01D6 GETMET R8 R2 K6 0x58280005, // 01D7 LDCONST R10 K5 0x7C200400, // 01D8 CALL R8 2 - 0x8C24034F, // 01D9 GETMET R9 R1 K79 + 0x8C24034E, // 01D9 GETMET R9 R1 K78 0x5C2C1000, // 01DA MOVE R11 R8 0x7C240400, // 01DB CALL R9 2 - 0xB8264600, // 01DC GETNGBL R9 K35 - 0x8C24132D, // 01DD GETMET R9 R9 K45 + 0xB8264400, // 01DC GETNGBL R9 K34 + 0x8C24132C, // 01DD GETMET R9 R9 K44 0x602C0018, // 01DE GETGBL R11 G24 - 0x58300050, // 01DF LDCONST R12 K80 - 0x88340313, // 01E0 GETMBR R13 R1 K19 - 0x8C341B51, // 01E1 GETMET R13 R13 K81 + 0x5830004F, // 01DF LDCONST R12 K79 + 0x88340312, // 01E0 GETMBR R13 R1 K18 + 0x8C341B50, // 01E1 GETMET R13 R13 K80 0x7C340200, // 01E2 CALL R13 1 - 0x8C341B45, // 01E3 GETMET R13 R13 K69 + 0x8C341B44, // 01E3 GETMET R13 R13 K68 0x7C340200, // 01E4 CALL R13 1 - 0x8C341B46, // 01E5 GETMET R13 R13 K70 + 0x8C341B45, // 01E5 GETMET R13 R13 K69 0x7C340200, // 01E6 CALL R13 1 - 0x8C341B52, // 01E7 GETMET R13 R13 K82 + 0x8C341B51, // 01E7 GETMET R13 R13 K81 0x7C340200, // 01E8 CALL R13 1 0x60380008, // 01E9 GETGBL R14 G8 0x5C3C1000, // 01EA MOVE R15 R8 @@ -649,8 +648,8 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x58300010, // 01ED LDCONST R12 K16 0x7C240600, // 01EE CALL R9 3 0xB8260200, // 01EF GETNGBL R9 K1 - 0x8824132C, // 01F0 GETMBR R9 R9 K44 - 0x900E3609, // 01F1 SETMBR R3 K27 R9 + 0x8824132B, // 01F0 GETMBR R9 R9 K43 + 0x900E3409, // 01F1 SETMBR R3 K26 R9 0x4C240000, // 01F2 LDNIL R9 0x80041200, // 01F3 RET 1 R9 0x70020034, // 01F4 JMP #022A @@ -663,23 +662,23 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x60240008, // 01FB GETGBL R9 G8 0x5C281000, // 01FC MOVE R10 R8 0x7C240200, // 01FD CALL R9 1 - 0x0026A609, // 01FE ADD R9 K83 R9 - 0x900E5A09, // 01FF SETMBR R3 K45 R9 + 0x0026A409, // 01FE ADD R9 K82 R9 + 0x900E5809, // 01FF SETMBR R3 K44 R9 0x60240010, // 0200 GETGBL R9 G16 - 0x88280117, // 0201 GETMBR R10 R0 K23 - 0x88281531, // 0202 GETMBR R10 R10 K49 - 0x8C281554, // 0203 GETMET R10 R10 K84 + 0x88280116, // 0201 GETMBR R10 R0 K22 + 0x88281530, // 0202 GETMBR R10 R10 K48 + 0x8C281553, // 0203 GETMET R10 R10 K83 0x7C280200, // 0204 CALL R10 1 0x7C240200, // 0205 CALL R9 1 0xA8020010, // 0206 EXBLK 0 #0218 0x5C281200, // 0207 MOVE R10 R9 0x7C280000, // 0208 CALL R10 0 - 0x8C2C1555, // 0209 GETMET R11 R10 K85 + 0x8C2C1554, // 0209 GETMET R11 R10 K84 0x7C2C0200, // 020A CALL R11 1 0x1C2C1608, // 020B EQ R11 R11 R8 0x782E0008, // 020C JMPF R11 #0216 - 0xB82E4600, // 020D GETNGBL R11 K35 - 0x8C2C1756, // 020E GETMET R11 R11 K86 + 0xB82E4400, // 020D GETNGBL R11 K34 + 0x8C2C1755, // 020E GETMET R11 R11 K85 0x543607CF, // 020F LDINT R13 2000 0x84380000, // 0210 CLOSURE R14 P0 0x7C2C0600, // 0211 CALL R11 3 @@ -689,21 +688,21 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x80041600, // 0215 RET 1 R11 0xA0240000, // 0216 CLOSE R9 0x7001FFEE, // 0217 JMP #0207 - 0x58240057, // 0218 LDCONST R9 K87 + 0x58240056, // 0218 LDCONST R9 K86 0xAC240200, // 0219 CATCH R9 1 0 0xB0080000, // 021A RAISE 2 R0 R0 - 0xB8264600, // 021B GETNGBL R9 K35 - 0x8C24132D, // 021C GETMET R9 R9 K45 + 0xB8264400, // 021B GETNGBL R9 K34 + 0x8C24132C, // 021C GETMET R9 R9 K44 0x602C0008, // 021D GETGBL R11 G8 0x5C301000, // 021E MOVE R12 R8 0x7C2C0200, // 021F CALL R11 1 - 0x002EB00B, // 0220 ADD R11 K88 R11 - 0x002C1759, // 0221 ADD R11 R11 K89 + 0x002EAE0B, // 0220 ADD R11 K87 R11 + 0x002C1758, // 0221 ADD R11 R11 K88 0x5830000E, // 0222 LDCONST R12 K14 0x7C240600, // 0223 CALL R9 3 0xB8260200, // 0224 GETNGBL R9 K1 - 0x8824135A, // 0225 GETMBR R9 R9 K90 - 0x900E3609, // 0226 SETMBR R3 K27 R9 + 0x88241359, // 0225 GETMBR R9 R9 K89 + 0x900E3409, // 0226 SETMBR R3 K26 R9 0x4C240000, // 0227 LDNIL R9 0xA0000000, // 0228 CLOSE R0 0x80041200, // 0229 RET 1 R9 @@ -728,16 +727,16 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x8C300506, // 023C GETMET R12 R2 K6 0x543A0003, // 023D LDINT R14 4 0x7C300400, // 023E CALL R12 2 - 0xB8364600, // 023F GETNGBL R13 K35 - 0x8C341B2D, // 0240 GETMET R13 R13 K45 + 0xB8364400, // 023F GETNGBL R13 K34 + 0x8C341B2C, // 0240 GETMET R13 R13 K44 0x603C0018, // 0241 GETGBL R15 G24 - 0x5840005B, // 0242 LDCONST R16 K91 + 0x5840005A, // 0242 LDCONST R16 K90 0x5C441000, // 0243 MOVE R17 R8 - 0x8C481352, // 0244 GETMET R18 R9 K82 + 0x8C481351, // 0244 GETMET R18 R9 K81 0x7C480200, // 0245 CALL R18 1 0x5C4C1400, // 0246 MOVE R19 R10 0x5C501600, // 0247 MOVE R20 R11 - 0x8C541952, // 0248 GETMET R21 R12 K82 + 0x8C541951, // 0248 GETMET R21 R12 K81 0x7C540200, // 0249 CALL R21 1 0x7C3C0C00, // 024A CALL R15 6 0x54420003, // 024B LDINT R16 4 @@ -758,8 +757,8 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x1C34180D, // 025A EQ R13 R12 R13 0x78360005, // 025B JMPF R13 #0262 0xB8360200, // 025C GETNGBL R13 K1 - 0x88341B5C, // 025D GETMBR R13 R13 K92 - 0x900E360D, // 025E SETMBR R3 K27 R13 + 0x88341B5B, // 025D GETMBR R13 R13 K91 + 0x900E340D, // 025E SETMBR R3 K26 R13 0x4C340000, // 025F LDNIL R13 0xA0000000, // 0260 CLOSE R0 0x80041A00, // 0261 RET 1 R13 @@ -783,14 +782,14 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x543A001F, // 0273 LDINT R14 32 0x24341A0E, // 0274 GT R13 R13 R14 0x7836000A, // 0275 JMPF R13 #0281 - 0xB8364600, // 0276 GETNGBL R13 K35 - 0x8C341B2D, // 0277 GETMET R13 R13 K45 - 0x583C005D, // 0278 LDCONST R15 K93 + 0xB8364400, // 0276 GETNGBL R13 K34 + 0x8C341B2C, // 0277 GETMET R13 R13 K44 + 0x583C005C, // 0278 LDCONST R15 K92 0x5840000E, // 0279 LDCONST R16 K14 0x7C340600, // 027A CALL R13 3 0xB8360200, // 027B GETNGBL R13 K1 - 0x88341B5E, // 027C GETMBR R13 R13 K94 - 0x900E360D, // 027D SETMBR R3 K27 R13 + 0x88341B5D, // 027C GETMBR R13 R13 K93 + 0x900E340D, // 027D SETMBR R3 K26 R13 0x4C340000, // 027E LDNIL R13 0xA0000000, // 027F CLOSE R0 0x80041A00, // 0280 RET 1 R13 @@ -798,17 +797,17 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x40360A0D, // 0282 CONNECT R13 K5 R13 0x9434120D, // 0283 GETIDX R13 R9 R13 0x543A001F, // 0284 LDINT R14 32 - 0x40381D41, // 0285 CONNECT R14 R14 K65 + 0x40381D40, // 0285 CONNECT R14 R14 K64 0x9438120E, // 0286 GETIDX R14 R9 R14 - 0x883C0117, // 0287 GETMBR R15 R0 K23 - 0x8C3C1F5F, // 0288 GETMET R15 R15 K95 + 0x883C0116, // 0287 GETMBR R15 R0 K22 + 0x8C3C1F5E, // 0288 GETMET R15 R15 K94 0x5C441000, // 0289 MOVE R17 R8 0x5C481600, // 028A MOVE R18 R11 0x5C4C1400, // 028B MOVE R19 R10 0x5C501800, // 028C MOVE R20 R12 0x5C541A00, // 028D MOVE R21 R13 0x5C581C00, // 028E MOVE R22 R14 - 0x8C5C0360, // 028F GETMET R23 R1 K96 + 0x8C5C035F, // 028F GETMET R23 R1 K95 0x7C5C0200, // 0290 CALL R23 1 0x7C3C1000, // 0291 CALL R15 8 0x503C0200, // 0292 LDBOOL R15 1 0 @@ -820,16 +819,16 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x8C200506, // 0298 GETMET R8 R2 K6 0x58280005, // 0299 LDCONST R10 K5 0x7C200400, // 029A CALL R8 2 - 0xB8264600, // 029B GETNGBL R9 K35 - 0x8C24132D, // 029C GETMET R9 R9 K45 + 0xB8264400, // 029B GETNGBL R9 K34 + 0x8C24132C, // 029C GETMET R9 R9 K44 0x602C0008, // 029D GETGBL R11 G8 0x5C301000, // 029E MOVE R12 R8 0x7C2C0200, // 029F CALL R11 1 - 0x002EC20B, // 02A0 ADD R11 K97 R11 + 0x002EC00B, // 02A0 ADD R11 K96 R11 0x58300010, // 02A1 LDCONST R12 K16 0x7C240600, // 02A2 CALL R9 3 - 0x88240117, // 02A3 GETMBR R9 R0 K23 - 0x8C241362, // 02A4 GETMET R9 R9 K98 + 0x88240116, // 02A3 GETMBR R9 R0 K22 + 0x8C241361, // 02A4 GETMET R9 R9 K97 0x5C2C1000, // 02A5 MOVE R11 R8 0x7C240400, // 02A6 CALL R9 2 0x50240200, // 02A7 LDBOOL R9 1 0 @@ -838,8 +837,8 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x70020007, // 02AA JMP #02B3 0x1C200F0E, // 02AB EQ R8 R7 K14 0x78220005, // 02AC JMPF R8 #02B3 - 0x88200117, // 02AD GETMBR R8 R0 K23 - 0x8C201163, // 02AE GETMET R8 R8 K99 + 0x88200116, // 02AD GETMBR R8 R0 K22 + 0x8C201162, // 02AE GETMET R8 R8 K98 0x7C200200, // 02AF CALL R8 1 0x50200200, // 02B0 LDBOOL R8 1 0 0xA0000000, // 02B1 CLOSE R0 @@ -857,7 +856,7 @@ be_local_closure(Matter_Plugin_Root_invoke_request, /* name */ 0x60200003, // 02BD GETGBL R8 G3 0x5C240000, // 02BE MOVE R9 R0 0x7C200200, // 02BF CALL R8 1 - 0x8C201164, // 02C0 GETMET R8 R8 K100 + 0x8C201163, // 02C0 GETMET R8 R8 K99 0x5C280200, // 02C1 MOVE R10 R1 0x5C2C0400, // 02C2 MOVE R11 R2 0x5C300600, // 02C3 MOVE R12 R3 @@ -885,7 +884,7 @@ be_local_closure(Matter_Plugin_Root_read_attribute, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[91]) { /* constants */ + ( &(const bvalue[92]) { /* constants */ /* K0 */ be_nested_str_weak(string), /* K1 */ be_nested_str_weak(matter), /* K2 */ be_nested_str_weak(TLV), @@ -937,50 +936,51 @@ be_local_closure(Matter_Plugin_Root_read_attribute, /* name */ /* K48 */ be_const_int(1000000), /* K49 */ be_nested_str_weak(rtc), /* K50 */ be_nested_str_weak(local), - /* K51 */ be_nested_str_weak(send_ack_now), - /* K52 */ be_nested_str_weak(msg), - /* K53 */ be_nested_str_weak(device), - /* K54 */ be_nested_str_weak(sessions), - /* K55 */ be_nested_str_weak(active_fabrics), - /* K56 */ be_nested_str_weak(B2), - /* K57 */ be_nested_str_weak(get_noc), - /* K58 */ be_nested_str_weak(get_icac), - /* K59 */ be_nested_str_weak(get_fabric_index), - /* K60 */ be_nested_str_weak(stop_iteration), - /* K61 */ be_nested_str_weak(parse), - /* K62 */ be_nested_str_weak(get_ca), - /* K63 */ be_nested_str_weak(findsubval), - /* K64 */ be_nested_str_weak(get_admin_vendor), - /* K65 */ be_nested_str_weak(get_fabric_id), - /* K66 */ be_nested_str_weak(get_device_id), - /* K67 */ be_nested_str_weak(get_fabric_label), - /* K68 */ be_nested_str_weak(Fabric), - /* K69 */ be_nested_str_weak(_MAX_CASE), - /* K70 */ be_nested_str_weak(count_active_fabrics), - /* K71 */ be_nested_str_weak(_fabric), - /* K72 */ be_nested_str_weak(is_commissioning_open), - /* K73 */ be_nested_str_weak(is_root_commissioning_open), - /* K74 */ be_nested_str_weak(commissioning_admin_fabric), - /* K75 */ be_nested_str_weak(Tasmota), - /* K76 */ be_nested_str_weak(vendorid), - /* K77 */ be_nested_str_weak(DeviceName), - /* K78 */ be_nested_str_weak(FriendlyName), - /* K79 */ be_nested_str_weak(FriendlyName1), - /* K80 */ be_nested_str_weak(XX), - /* K81 */ be_nested_str_weak(Status_X202), - /* K82 */ be_nested_str_weak(StatusFWR), - /* K83 */ be_nested_str_weak(Hardware), - /* K84 */ be_nested_str_weak(Version), - /* K85 */ be_nested_str_weak(_X28), - /* K86 */ be_nested_str_weak(locale), - /* K87 */ be_nested_str_weak(create_TLV), - /* K88 */ be_nested_str_weak(get_active_endpoints), - /* K89 */ be_nested_str_weak(disable_bridge_mode), - /* K90 */ be_nested_str_weak(read_attribute), + /* K51 */ be_nested_str_weak(ack_request), + /* K52 */ be_nested_str_weak(fabric_filtered), + /* K53 */ be_nested_str_weak(get_fabric), + /* K54 */ be_nested_str_weak(device), + /* K55 */ be_nested_str_weak(sessions), + /* K56 */ be_nested_str_weak(active_fabrics), + /* K57 */ be_nested_str_weak(B2), + /* K58 */ be_nested_str_weak(get_noc), + /* K59 */ be_nested_str_weak(get_icac), + /* K60 */ be_nested_str_weak(get_fabric_index), + /* K61 */ be_nested_str_weak(stop_iteration), + /* K62 */ be_nested_str_weak(parse), + /* K63 */ be_nested_str_weak(get_ca), + /* K64 */ be_nested_str_weak(findsubval), + /* K65 */ be_nested_str_weak(get_admin_vendor), + /* K66 */ be_nested_str_weak(get_fabric_id), + /* K67 */ be_nested_str_weak(get_device_id), + /* K68 */ be_nested_str_weak(get_fabric_label), + /* K69 */ be_nested_str_weak(Fabric), + /* K70 */ be_nested_str_weak(_MAX_CASE), + /* K71 */ be_nested_str_weak(count_active_fabrics), + /* K72 */ be_nested_str_weak(_fabric), + /* K73 */ be_nested_str_weak(is_commissioning_open), + /* K74 */ be_nested_str_weak(is_root_commissioning_open), + /* K75 */ be_nested_str_weak(commissioning_admin_fabric), + /* K76 */ be_nested_str_weak(Tasmota), + /* K77 */ be_nested_str_weak(vendorid), + /* K78 */ be_nested_str_weak(DeviceName), + /* K79 */ be_nested_str_weak(FriendlyName), + /* K80 */ be_nested_str_weak(FriendlyName1), + /* K81 */ be_nested_str_weak(XX), + /* K82 */ be_nested_str_weak(Status_X202), + /* K83 */ be_nested_str_weak(StatusFWR), + /* K84 */ be_nested_str_weak(Hardware), + /* K85 */ be_nested_str_weak(Version), + /* K86 */ be_nested_str_weak(_X28), + /* K87 */ be_nested_str_weak(locale), + /* K88 */ be_nested_str_weak(create_TLV), + /* K89 */ be_nested_str_weak(get_active_endpoints), + /* K90 */ be_nested_str_weak(disable_bridge_mode), + /* K91 */ be_nested_str_weak(read_attribute), }), be_str_weak(read_attribute), &be_const_str_solidified, - ( &(const binstruction[911]) { /* code */ + ( &(const binstruction[937]) { /* code */ 0xA4120000, // 0000 IMPORT R4 K0 0xB8160200, // 0001 GETNGBL R5 K1 0x88140B02, // 0002 GETMBR R5 R5 K2 @@ -1037,11 +1037,11 @@ be_local_closure(Matter_Plugin_Root_read_attribute, /* name */ 0x502C0000, // 0035 LDBOOL R11 0 0 0x7C200600, // 0036 CALL R8 3 0x80041000, // 0037 RET 1 R8 - 0x70020354, // 0038 JMP #038E + 0x7002036E, // 0038 JMP #03A8 0x54220031, // 0039 LDINT R8 50 0x1C200C08, // 003A EQ R8 R6 R8 0x78220000, // 003B JMPF R8 #003D - 0x70020350, // 003C JMP #038E + 0x7002036A, // 003C JMP #03A8 0x54220032, // 003D LDINT R8 51 0x1C200C08, // 003E EQ R8 R6 R8 0x782200DC, // 003F JMPF R8 #011D @@ -1265,11 +1265,11 @@ be_local_closure(Matter_Plugin_Root_read_attribute, /* name */ 0x502C0000, // 0119 LDBOOL R11 0 0 0x7C200600, // 011A CALL R8 3 0x80041000, // 011B RET 1 R8 - 0x70020270, // 011C JMP #038E + 0x7002028A, // 011C JMP #03A8 0x54220033, // 011D LDINT R8 52 0x1C200C08, // 011E EQ R8 R6 R8 0x78220000, // 011F JMPF R8 #0121 - 0x7002026C, // 0120 JMP #038E + 0x70020286, // 0120 JMP #03A8 0x54220037, // 0121 LDINT R8 56 0x1C200C08, // 0122 EQ R8 R6 R8 0x7822002B, // 0123 JMPF R8 #0150 @@ -1316,582 +1316,608 @@ be_local_closure(Matter_Plugin_Root_read_attribute, /* name */ 0x5C301000, // 014C MOVE R12 R8 0x7C240600, // 014D CALL R9 3 0x80041200, // 014E RET 1 R9 - 0x7002023D, // 014F JMP #038E + 0x70020257, // 014F JMP #03A8 0x5422003D, // 0150 LDINT R8 62 0x1C200C08, // 0151 EQ R8 R6 R8 - 0x78220093, // 0152 JMPF R8 #01E7 + 0x782200AD, // 0152 JMPF R8 #0201 0x8C200133, // 0153 GETMET R8 R0 K51 - 0x88280534, // 0154 GETMBR R10 R2 K52 + 0x5C280400, // 0154 MOVE R10 R2 0x7C200400, // 0155 CALL R8 2 0x1C200F05, // 0156 EQ R8 R7 K5 - 0x78220025, // 0157 JMPF R8 #017E + 0x78220032, // 0157 JMPF R8 #018B 0x8C200B11, // 0158 GETMET R8 R5 K17 0x7C200200, // 0159 CALL R8 1 - 0x60240010, // 015A GETGBL R9 G16 - 0x88280135, // 015B GETMBR R10 R0 K53 - 0x88281536, // 015C GETMBR R10 R10 K54 - 0x8C281537, // 015D GETMET R10 R10 K55 - 0x7C280200, // 015E CALL R10 1 - 0x7C240200, // 015F CALL R9 1 - 0xA8020017, // 0160 EXBLK 0 #0179 - 0x5C281200, // 0161 MOVE R10 R9 - 0x7C280000, // 0162 CALL R10 0 - 0x8C2C1115, // 0163 GETMET R11 R8 K21 - 0x4C340000, // 0164 LDNIL R13 - 0x7C2C0400, // 0165 CALL R11 2 - 0x8C30170B, // 0166 GETMET R12 R11 K11 - 0x58380009, // 0167 LDCONST R14 K9 - 0x883C0B38, // 0168 GETMBR R15 R5 K56 - 0x8C401539, // 0169 GETMET R16 R10 K57 - 0x7C400200, // 016A CALL R16 1 - 0x7C300800, // 016B CALL R12 4 - 0x8C30170B, // 016C GETMET R12 R11 K11 - 0x5838000D, // 016D LDCONST R14 K13 - 0x883C0B38, // 016E GETMBR R15 R5 K56 - 0x8C40153A, // 016F GETMET R16 R10 K58 - 0x7C400200, // 0170 CALL R16 1 - 0x7C300800, // 0171 CALL R12 4 - 0x8C30170B, // 0172 GETMET R12 R11 K11 - 0x543A00FD, // 0173 LDINT R14 254 - 0x883C0B0C, // 0174 GETMBR R15 R5 K12 - 0x8C40153B, // 0175 GETMET R16 R10 K59 - 0x7C400200, // 0176 CALL R16 1 - 0x7C300800, // 0177 CALL R12 4 - 0x7001FFE7, // 0178 JMP #0161 - 0x5824003C, // 0179 LDCONST R9 K60 - 0xAC240200, // 017A CATCH R9 1 0 - 0xB0080000, // 017B RAISE 2 R0 R0 - 0x80041000, // 017C RET 1 R8 - 0x70020067, // 017D JMP #01E6 - 0x1C200F09, // 017E EQ R8 R7 K9 - 0x7822003C, // 017F JMPF R8 #01BD - 0x8C200B11, // 0180 GETMET R8 R5 K17 - 0x7C200200, // 0181 CALL R8 1 - 0x60240010, // 0182 GETGBL R9 G16 - 0x88280135, // 0183 GETMBR R10 R0 K53 - 0x88281536, // 0184 GETMBR R10 R10 K54 - 0x8C281537, // 0185 GETMET R10 R10 K55 - 0x7C280200, // 0186 CALL R10 1 - 0x7C240200, // 0187 CALL R9 1 - 0xA802002E, // 0188 EXBLK 0 #01B8 - 0x5C281200, // 0189 MOVE R10 R9 - 0x7C280000, // 018A CALL R10 0 - 0x8C2C0B3D, // 018B GETMET R11 R5 K61 - 0x8C34153E, // 018C GETMET R13 R10 K62 - 0x7C340200, // 018D CALL R13 1 - 0x7C2C0400, // 018E CALL R11 2 - 0x8C301115, // 018F GETMET R12 R8 K21 - 0x4C380000, // 0190 LDNIL R14 - 0x7C300400, // 0191 CALL R12 2 - 0x8C34190B, // 0192 GETMET R13 R12 K11 - 0x583C0009, // 0193 LDCONST R15 K9 - 0x88400B38, // 0194 GETMBR R16 R5 K56 - 0x8C44173F, // 0195 GETMET R17 R11 K63 - 0x544E0008, // 0196 LDINT R19 9 - 0x7C440400, // 0197 CALL R17 2 - 0x7C340800, // 0198 CALL R13 4 - 0x8C34190B, // 0199 GETMET R13 R12 K11 - 0x583C000D, // 019A LDCONST R15 K13 - 0x88400B0C, // 019B GETMBR R16 R5 K12 - 0x8C441540, // 019C GETMET R17 R10 K64 - 0x7C440200, // 019D CALL R17 1 - 0x7C340800, // 019E CALL R13 4 - 0x8C34190B, // 019F GETMET R13 R12 K11 - 0x583C000F, // 01A0 LDCONST R15 K15 - 0x88400B07, // 01A1 GETMBR R16 R5 K7 - 0x8C441541, // 01A2 GETMET R17 R10 K65 - 0x7C440200, // 01A3 CALL R17 1 - 0x7C340800, // 01A4 CALL R13 4 - 0x8C34190B, // 01A5 GETMET R13 R12 K11 - 0x543E0003, // 01A6 LDINT R15 4 - 0x88400B07, // 01A7 GETMBR R16 R5 K7 - 0x8C441542, // 01A8 GETMET R17 R10 K66 - 0x7C440200, // 01A9 CALL R17 1 - 0x7C340800, // 01AA CALL R13 4 - 0x8C34190B, // 01AB GETMET R13 R12 K11 - 0x543E0004, // 01AC LDINT R15 5 - 0x88400B16, // 01AD GETMBR R16 R5 K22 - 0x8C441543, // 01AE GETMET R17 R10 K67 - 0x7C440200, // 01AF CALL R17 1 - 0x7C340800, // 01B0 CALL R13 4 - 0x8C34190B, // 01B1 GETMET R13 R12 K11 - 0x543E00FD, // 01B2 LDINT R15 254 - 0x88400B0C, // 01B3 GETMBR R16 R5 K12 - 0x8C44153B, // 01B4 GETMET R17 R10 K59 - 0x7C440200, // 01B5 CALL R17 1 - 0x7C340800, // 01B6 CALL R13 4 - 0x7001FFD0, // 01B7 JMP #0189 - 0x5824003C, // 01B8 LDCONST R9 K60 - 0xAC240200, // 01B9 CATCH R9 1 0 - 0xB0080000, // 01BA RAISE 2 R0 R0 - 0x80041000, // 01BB RET 1 R8 - 0x70020028, // 01BC JMP #01E6 - 0x1C200F0D, // 01BD EQ R8 R7 K13 - 0x78220007, // 01BE JMPF R8 #01C7 - 0x8C200706, // 01BF GETMET R8 R3 K6 - 0x88280B0E, // 01C0 GETMBR R10 R5 K14 - 0xB82E0200, // 01C1 GETNGBL R11 K1 - 0x882C1744, // 01C2 GETMBR R11 R11 K68 - 0x882C1745, // 01C3 GETMBR R11 R11 K69 - 0x7C200600, // 01C4 CALL R8 3 - 0x80041000, // 01C5 RET 1 R8 - 0x7002001E, // 01C6 JMP #01E6 - 0x1C200F0F, // 01C7 EQ R8 R7 K15 - 0x78220009, // 01C8 JMPF R8 #01D3 - 0x88200135, // 01C9 GETMBR R8 R0 K53 - 0x88201136, // 01CA GETMBR R8 R8 K54 - 0x8C201146, // 01CB GETMET R8 R8 K70 - 0x7C200200, // 01CC CALL R8 1 - 0x8C240706, // 01CD GETMET R9 R3 K6 - 0x882C0B0E, // 01CE GETMBR R11 R5 K14 - 0x5C301000, // 01CF MOVE R12 R8 - 0x7C240600, // 01D0 CALL R9 3 - 0x80041200, // 01D1 RET 1 R9 - 0x70020012, // 01D2 JMP #01E6 - 0x54220003, // 01D3 LDINT R8 4 - 0x1C200E08, // 01D4 EQ R8 R7 R8 - 0x78220000, // 01D5 JMPF R8 #01D7 - 0x7002000E, // 01D6 JMP #01E6 - 0x54220004, // 01D7 LDINT R8 5 - 0x1C200E08, // 01D8 EQ R8 R7 R8 - 0x7822000B, // 01D9 JMPF R8 #01E6 - 0x88200347, // 01DA GETMBR R8 R1 K71 - 0x8C20113B, // 01DB GETMET R8 R8 K59 - 0x7C200200, // 01DC CALL R8 1 - 0x4C240000, // 01DD LDNIL R9 - 0x1C241009, // 01DE EQ R9 R8 R9 - 0x78260000, // 01DF JMPF R9 #01E1 - 0x58200005, // 01E0 LDCONST R8 K5 - 0x8C240706, // 01E1 GETMET R9 R3 K6 - 0x882C0B0E, // 01E2 GETMBR R11 R5 K14 - 0x5C301000, // 01E3 MOVE R12 R8 - 0x7C240600, // 01E4 CALL R9 3 - 0x80041200, // 01E5 RET 1 R9 - 0x700201A6, // 01E6 JMP #038E - 0x5422003B, // 01E7 LDINT R8 60 - 0x1C200C08, // 01E8 EQ R8 R6 R8 - 0x7822003C, // 01E9 JMPF R8 #0227 - 0x1C200F05, // 01EA EQ R8 R7 K5 - 0x78220012, // 01EB JMPF R8 #01FF - 0x88200135, // 01EC GETMBR R8 R0 K53 - 0x8C201148, // 01ED GETMET R8 R8 K72 - 0x7C200200, // 01EE CALL R8 1 - 0x88240135, // 01EF GETMBR R9 R0 K53 - 0x8C241349, // 01F0 GETMET R9 R9 K73 - 0x7C240200, // 01F1 CALL R9 1 - 0x78220004, // 01F2 JMPF R8 #01F8 - 0x78260001, // 01F3 JMPF R9 #01F6 - 0x5828000D, // 01F4 LDCONST R10 K13 - 0x70020000, // 01F5 JMP #01F7 - 0x58280009, // 01F6 LDCONST R10 K9 - 0x70020000, // 01F7 JMP #01F9 - 0x58280005, // 01F8 LDCONST R10 K5 - 0x8C2C0706, // 01F9 GETMET R11 R3 K6 - 0x88340B0E, // 01FA GETMBR R13 R5 K14 - 0x5C381400, // 01FB MOVE R14 R10 - 0x7C2C0600, // 01FC CALL R11 3 - 0x80041600, // 01FD RET 1 R11 - 0x70020026, // 01FE JMP #0226 - 0x1C200F09, // 01FF EQ R8 R7 K9 - 0x78220011, // 0200 JMPF R8 #0213 - 0x88200135, // 0201 GETMBR R8 R0 K53 - 0x8820114A, // 0202 GETMBR R8 R8 K74 - 0x4C240000, // 0203 LDNIL R9 - 0x20241009, // 0204 NE R9 R8 R9 - 0x78260006, // 0205 JMPF R9 #020D - 0x8C240706, // 0206 GETMET R9 R3 K6 - 0x882C0B0C, // 0207 GETMBR R11 R5 K12 - 0x8C30113B, // 0208 GETMET R12 R8 K59 - 0x7C300200, // 0209 CALL R12 1 - 0x7C240600, // 020A CALL R9 3 - 0x80041200, // 020B RET 1 R9 - 0x70020004, // 020C JMP #0212 - 0x8C240706, // 020D GETMET R9 R3 K6 - 0x882C0B18, // 020E GETMBR R11 R5 K24 - 0x4C300000, // 020F LDNIL R12 - 0x7C240600, // 0210 CALL R9 3 - 0x80041200, // 0211 RET 1 R9 - 0x70020012, // 0212 JMP #0226 - 0x1C200F0D, // 0213 EQ R8 R7 K13 - 0x78220010, // 0214 JMPF R8 #0226 - 0x88200135, // 0215 GETMBR R8 R0 K53 - 0x8820114A, // 0216 GETMBR R8 R8 K74 - 0x4C240000, // 0217 LDNIL R9 - 0x20241009, // 0218 NE R9 R8 R9 - 0x78260006, // 0219 JMPF R9 #0221 - 0x8C240706, // 021A GETMET R9 R3 K6 - 0x882C0B0C, // 021B GETMBR R11 R5 K12 - 0x8C301140, // 021C GETMET R12 R8 K64 - 0x7C300200, // 021D CALL R12 1 - 0x7C240600, // 021E CALL R9 3 - 0x80041200, // 021F RET 1 R9 - 0x70020004, // 0220 JMP #0226 - 0x8C240706, // 0221 GETMET R9 R3 K6 - 0x882C0B18, // 0222 GETMBR R11 R5 K24 - 0x4C300000, // 0223 LDNIL R12 + 0x88240534, // 015A GETMBR R9 R2 K52 + 0x78260005, // 015B JMPF R9 #0162 + 0x60240012, // 015C GETGBL R9 G18 + 0x7C240000, // 015D CALL R9 0 + 0x8C280335, // 015E GETMET R10 R1 K53 + 0x7C280200, // 015F CALL R10 1 + 0x4028120A, // 0160 CONNECT R10 R9 R10 + 0x70020003, // 0161 JMP #0166 + 0x88240136, // 0162 GETMBR R9 R0 K54 + 0x88241337, // 0163 GETMBR R9 R9 K55 + 0x8C241338, // 0164 GETMET R9 R9 K56 + 0x7C240200, // 0165 CALL R9 1 + 0x60280010, // 0166 GETGBL R10 G16 + 0x5C2C1200, // 0167 MOVE R11 R9 + 0x7C280200, // 0168 CALL R10 1 + 0xA802001B, // 0169 EXBLK 0 #0186 + 0x5C2C1400, // 016A MOVE R11 R10 + 0x7C2C0000, // 016B CALL R11 0 + 0x4C300000, // 016C LDNIL R12 + 0x1C30160C, // 016D EQ R12 R11 R12 + 0x78320000, // 016E JMPF R12 #0170 + 0x7001FFF9, // 016F JMP #016A + 0x8C301115, // 0170 GETMET R12 R8 K21 + 0x4C380000, // 0171 LDNIL R14 + 0x7C300400, // 0172 CALL R12 2 + 0x8C34190B, // 0173 GETMET R13 R12 K11 + 0x583C0009, // 0174 LDCONST R15 K9 + 0x88400B39, // 0175 GETMBR R16 R5 K57 + 0x8C44173A, // 0176 GETMET R17 R11 K58 + 0x7C440200, // 0177 CALL R17 1 + 0x7C340800, // 0178 CALL R13 4 + 0x8C34190B, // 0179 GETMET R13 R12 K11 + 0x583C000D, // 017A LDCONST R15 K13 + 0x88400B39, // 017B GETMBR R16 R5 K57 + 0x8C44173B, // 017C GETMET R17 R11 K59 + 0x7C440200, // 017D CALL R17 1 + 0x7C340800, // 017E CALL R13 4 + 0x8C34190B, // 017F GETMET R13 R12 K11 + 0x543E00FD, // 0180 LDINT R15 254 + 0x88400B0C, // 0181 GETMBR R16 R5 K12 + 0x8C44173C, // 0182 GETMET R17 R11 K60 + 0x7C440200, // 0183 CALL R17 1 + 0x7C340800, // 0184 CALL R13 4 + 0x7001FFE3, // 0185 JMP #016A + 0x5828003D, // 0186 LDCONST R10 K61 + 0xAC280200, // 0187 CATCH R10 1 0 + 0xB0080000, // 0188 RAISE 2 R0 R0 + 0x80041000, // 0189 RET 1 R8 + 0x70020074, // 018A JMP #0200 + 0x1C200F09, // 018B EQ R8 R7 K9 + 0x78220049, // 018C JMPF R8 #01D7 + 0x8C200B11, // 018D GETMET R8 R5 K17 + 0x7C200200, // 018E CALL R8 1 + 0x88240534, // 018F GETMBR R9 R2 K52 + 0x78260005, // 0190 JMPF R9 #0197 + 0x60240012, // 0191 GETGBL R9 G18 + 0x7C240000, // 0192 CALL R9 0 + 0x8C280335, // 0193 GETMET R10 R1 K53 + 0x7C280200, // 0194 CALL R10 1 + 0x4028120A, // 0195 CONNECT R10 R9 R10 + 0x70020003, // 0196 JMP #019B + 0x88240136, // 0197 GETMBR R9 R0 K54 + 0x88241337, // 0198 GETMBR R9 R9 K55 + 0x8C241338, // 0199 GETMET R9 R9 K56 + 0x7C240200, // 019A CALL R9 1 + 0x60280010, // 019B GETGBL R10 G16 + 0x5C2C1200, // 019C MOVE R11 R9 + 0x7C280200, // 019D CALL R10 1 + 0xA8020032, // 019E EXBLK 0 #01D2 + 0x5C2C1400, // 019F MOVE R11 R10 + 0x7C2C0000, // 01A0 CALL R11 0 + 0x4C300000, // 01A1 LDNIL R12 + 0x1C30160C, // 01A2 EQ R12 R11 R12 + 0x78320000, // 01A3 JMPF R12 #01A5 + 0x7001FFF9, // 01A4 JMP #019F + 0x8C300B3E, // 01A5 GETMET R12 R5 K62 + 0x8C38173F, // 01A6 GETMET R14 R11 K63 + 0x7C380200, // 01A7 CALL R14 1 + 0x7C300400, // 01A8 CALL R12 2 + 0x8C341115, // 01A9 GETMET R13 R8 K21 + 0x4C3C0000, // 01AA LDNIL R15 + 0x7C340400, // 01AB CALL R13 2 + 0x8C381B0B, // 01AC GETMET R14 R13 K11 + 0x58400009, // 01AD LDCONST R16 K9 + 0x88440B39, // 01AE GETMBR R17 R5 K57 + 0x8C481940, // 01AF GETMET R18 R12 K64 + 0x54520008, // 01B0 LDINT R20 9 + 0x7C480400, // 01B1 CALL R18 2 + 0x7C380800, // 01B2 CALL R14 4 + 0x8C381B0B, // 01B3 GETMET R14 R13 K11 + 0x5840000D, // 01B4 LDCONST R16 K13 + 0x88440B0C, // 01B5 GETMBR R17 R5 K12 + 0x8C481741, // 01B6 GETMET R18 R11 K65 + 0x7C480200, // 01B7 CALL R18 1 + 0x7C380800, // 01B8 CALL R14 4 + 0x8C381B0B, // 01B9 GETMET R14 R13 K11 + 0x5840000F, // 01BA LDCONST R16 K15 + 0x88440B07, // 01BB GETMBR R17 R5 K7 + 0x8C481742, // 01BC GETMET R18 R11 K66 + 0x7C480200, // 01BD CALL R18 1 + 0x7C380800, // 01BE CALL R14 4 + 0x8C381B0B, // 01BF GETMET R14 R13 K11 + 0x54420003, // 01C0 LDINT R16 4 + 0x88440B07, // 01C1 GETMBR R17 R5 K7 + 0x8C481743, // 01C2 GETMET R18 R11 K67 + 0x7C480200, // 01C3 CALL R18 1 + 0x7C380800, // 01C4 CALL R14 4 + 0x8C381B0B, // 01C5 GETMET R14 R13 K11 + 0x54420004, // 01C6 LDINT R16 5 + 0x88440B16, // 01C7 GETMBR R17 R5 K22 + 0x8C481744, // 01C8 GETMET R18 R11 K68 + 0x7C480200, // 01C9 CALL R18 1 + 0x7C380800, // 01CA CALL R14 4 + 0x8C381B0B, // 01CB GETMET R14 R13 K11 + 0x544200FD, // 01CC LDINT R16 254 + 0x88440B0C, // 01CD GETMBR R17 R5 K12 + 0x8C48173C, // 01CE GETMET R18 R11 K60 + 0x7C480200, // 01CF CALL R18 1 + 0x7C380800, // 01D0 CALL R14 4 + 0x7001FFCC, // 01D1 JMP #019F + 0x5828003D, // 01D2 LDCONST R10 K61 + 0xAC280200, // 01D3 CATCH R10 1 0 + 0xB0080000, // 01D4 RAISE 2 R0 R0 + 0x80041000, // 01D5 RET 1 R8 + 0x70020028, // 01D6 JMP #0200 + 0x1C200F0D, // 01D7 EQ R8 R7 K13 + 0x78220007, // 01D8 JMPF R8 #01E1 + 0x8C200706, // 01D9 GETMET R8 R3 K6 + 0x88280B0E, // 01DA GETMBR R10 R5 K14 + 0xB82E0200, // 01DB GETNGBL R11 K1 + 0x882C1745, // 01DC GETMBR R11 R11 K69 + 0x882C1746, // 01DD GETMBR R11 R11 K70 + 0x7C200600, // 01DE CALL R8 3 + 0x80041000, // 01DF RET 1 R8 + 0x7002001E, // 01E0 JMP #0200 + 0x1C200F0F, // 01E1 EQ R8 R7 K15 + 0x78220009, // 01E2 JMPF R8 #01ED + 0x88200136, // 01E3 GETMBR R8 R0 K54 + 0x88201137, // 01E4 GETMBR R8 R8 K55 + 0x8C201147, // 01E5 GETMET R8 R8 K71 + 0x7C200200, // 01E6 CALL R8 1 + 0x8C240706, // 01E7 GETMET R9 R3 K6 + 0x882C0B0E, // 01E8 GETMBR R11 R5 K14 + 0x5C301000, // 01E9 MOVE R12 R8 + 0x7C240600, // 01EA CALL R9 3 + 0x80041200, // 01EB RET 1 R9 + 0x70020012, // 01EC JMP #0200 + 0x54220003, // 01ED LDINT R8 4 + 0x1C200E08, // 01EE EQ R8 R7 R8 + 0x78220000, // 01EF JMPF R8 #01F1 + 0x7002000E, // 01F0 JMP #0200 + 0x54220004, // 01F1 LDINT R8 5 + 0x1C200E08, // 01F2 EQ R8 R7 R8 + 0x7822000B, // 01F3 JMPF R8 #0200 + 0x88200348, // 01F4 GETMBR R8 R1 K72 + 0x8C20113C, // 01F5 GETMET R8 R8 K60 + 0x7C200200, // 01F6 CALL R8 1 + 0x4C240000, // 01F7 LDNIL R9 + 0x1C241009, // 01F8 EQ R9 R8 R9 + 0x78260000, // 01F9 JMPF R9 #01FB + 0x58200005, // 01FA LDCONST R8 K5 + 0x8C240706, // 01FB GETMET R9 R3 K6 + 0x882C0B0E, // 01FC GETMBR R11 R5 K14 + 0x5C301000, // 01FD MOVE R12 R8 + 0x7C240600, // 01FE CALL R9 3 + 0x80041200, // 01FF RET 1 R9 + 0x700201A6, // 0200 JMP #03A8 + 0x5422003B, // 0201 LDINT R8 60 + 0x1C200C08, // 0202 EQ R8 R6 R8 + 0x7822003C, // 0203 JMPF R8 #0241 + 0x1C200F05, // 0204 EQ R8 R7 K5 + 0x78220012, // 0205 JMPF R8 #0219 + 0x88200136, // 0206 GETMBR R8 R0 K54 + 0x8C201149, // 0207 GETMET R8 R8 K73 + 0x7C200200, // 0208 CALL R8 1 + 0x88240136, // 0209 GETMBR R9 R0 K54 + 0x8C24134A, // 020A GETMET R9 R9 K74 + 0x7C240200, // 020B CALL R9 1 + 0x78220004, // 020C JMPF R8 #0212 + 0x78260001, // 020D JMPF R9 #0210 + 0x5828000D, // 020E LDCONST R10 K13 + 0x70020000, // 020F JMP #0211 + 0x58280009, // 0210 LDCONST R10 K9 + 0x70020000, // 0211 JMP #0213 + 0x58280005, // 0212 LDCONST R10 K5 + 0x8C2C0706, // 0213 GETMET R11 R3 K6 + 0x88340B0E, // 0214 GETMBR R13 R5 K14 + 0x5C381400, // 0215 MOVE R14 R10 + 0x7C2C0600, // 0216 CALL R11 3 + 0x80041600, // 0217 RET 1 R11 + 0x70020026, // 0218 JMP #0240 + 0x1C200F09, // 0219 EQ R8 R7 K9 + 0x78220011, // 021A JMPF R8 #022D + 0x88200136, // 021B GETMBR R8 R0 K54 + 0x8820114B, // 021C GETMBR R8 R8 K75 + 0x4C240000, // 021D LDNIL R9 + 0x20241009, // 021E NE R9 R8 R9 + 0x78260006, // 021F JMPF R9 #0227 + 0x8C240706, // 0220 GETMET R9 R3 K6 + 0x882C0B0C, // 0221 GETMBR R11 R5 K12 + 0x8C30113C, // 0222 GETMET R12 R8 K60 + 0x7C300200, // 0223 CALL R12 1 0x7C240600, // 0224 CALL R9 3 0x80041200, // 0225 RET 1 R9 - 0x70020166, // 0226 JMP #038E - 0x54220027, // 0227 LDINT R8 40 - 0x1C200C08, // 0228 EQ R8 R6 R8 - 0x782200BA, // 0229 JMPF R8 #02E5 - 0x8C200133, // 022A GETMET R8 R0 K51 - 0x88280534, // 022B GETMBR R10 R2 K52 - 0x7C200400, // 022C CALL R8 2 - 0x1C200F05, // 022D EQ R8 R7 K5 - 0x78220005, // 022E JMPF R8 #0235 - 0x8C200706, // 022F GETMET R8 R3 K6 - 0x88280B0C, // 0230 GETMBR R10 R5 K12 - 0x582C0009, // 0231 LDCONST R11 K9 - 0x7C200600, // 0232 CALL R8 3 - 0x80041000, // 0233 RET 1 R8 - 0x700200AE, // 0234 JMP #02E4 - 0x1C200F09, // 0235 EQ R8 R7 K9 - 0x78220005, // 0236 JMPF R8 #023D - 0x8C200706, // 0237 GETMET R8 R3 K6 - 0x88280B16, // 0238 GETMBR R10 R5 K22 - 0x582C004B, // 0239 LDCONST R11 K75 - 0x7C200600, // 023A CALL R8 3 - 0x80041000, // 023B RET 1 R8 - 0x700200A6, // 023C JMP #02E4 - 0x1C200F0D, // 023D EQ R8 R7 K13 - 0x78220006, // 023E JMPF R8 #0246 - 0x8C200706, // 023F GETMET R8 R3 K6 - 0x88280B0C, // 0240 GETMBR R10 R5 K12 - 0x882C0135, // 0241 GETMBR R11 R0 K53 - 0x882C174C, // 0242 GETMBR R11 R11 K76 - 0x7C200600, // 0243 CALL R8 3 - 0x80041000, // 0244 RET 1 R8 - 0x7002009D, // 0245 JMP #02E4 - 0x1C200F0F, // 0246 EQ R8 R7 K15 - 0x7822000A, // 0247 JMPF R8 #0253 - 0x8C200706, // 0248 GETMET R8 R3 K6 - 0x88280B16, // 0249 GETMBR R10 R5 K22 - 0xB82E2400, // 024A GETNGBL R11 K18 - 0x8C2C1726, // 024B GETMET R11 R11 K38 - 0x5834004D, // 024C LDCONST R13 K77 - 0x50380200, // 024D LDBOOL R14 1 0 - 0x7C2C0600, // 024E CALL R11 3 - 0x942C174D, // 024F GETIDX R11 R11 K77 - 0x7C200600, // 0250 CALL R8 3 - 0x80041000, // 0251 RET 1 R8 - 0x70020090, // 0252 JMP #02E4 - 0x54220003, // 0253 LDINT R8 4 - 0x1C200E08, // 0254 EQ R8 R7 R8 - 0x78220005, // 0255 JMPF R8 #025C - 0x8C200706, // 0256 GETMET R8 R3 K6 - 0x88280B0C, // 0257 GETMBR R10 R5 K12 - 0x542E7FFF, // 0258 LDINT R11 32768 - 0x7C200600, // 0259 CALL R8 3 - 0x80041000, // 025A RET 1 R8 - 0x70020087, // 025B JMP #02E4 - 0x54220004, // 025C LDINT R8 5 - 0x1C200E08, // 025D EQ R8 R7 R8 - 0x7822000A, // 025E JMPF R8 #026A - 0x8C200706, // 025F GETMET R8 R3 K6 - 0x88280B16, // 0260 GETMBR R10 R5 K22 - 0xB82E2400, // 0261 GETNGBL R11 K18 - 0x8C2C1726, // 0262 GETMET R11 R11 K38 - 0x5834004E, // 0263 LDCONST R13 K78 - 0x50380200, // 0264 LDBOOL R14 1 0 - 0x7C2C0600, // 0265 CALL R11 3 - 0x942C174F, // 0266 GETIDX R11 R11 K79 - 0x7C200600, // 0267 CALL R8 3 - 0x80041000, // 0268 RET 1 R8 - 0x70020079, // 0269 JMP #02E4 - 0x54220005, // 026A LDINT R8 6 - 0x1C200E08, // 026B EQ R8 R7 R8 - 0x78220005, // 026C JMPF R8 #0273 - 0x8C200706, // 026D GETMET R8 R3 K6 - 0x88280B16, // 026E GETMBR R10 R5 K22 - 0x582C0050, // 026F LDCONST R11 K80 - 0x7C200600, // 0270 CALL R8 3 - 0x80041000, // 0271 RET 1 R8 - 0x70020070, // 0272 JMP #02E4 - 0x54220006, // 0273 LDINT R8 7 - 0x1C200E08, // 0274 EQ R8 R7 R8 - 0x78220005, // 0275 JMPF R8 #027C - 0x8C200706, // 0276 GETMET R8 R3 K6 - 0x88280B0C, // 0277 GETMBR R10 R5 K12 - 0x582C0005, // 0278 LDCONST R11 K5 - 0x7C200600, // 0279 CALL R8 3 - 0x80041000, // 027A RET 1 R8 - 0x70020067, // 027B JMP #02E4 - 0x54220007, // 027C LDINT R8 8 - 0x1C200E08, // 027D EQ R8 R7 R8 - 0x7822000B, // 027E JMPF R8 #028B - 0x8C200706, // 027F GETMET R8 R3 K6 - 0x88280B16, // 0280 GETMBR R10 R5 K22 - 0xB82E2400, // 0281 GETNGBL R11 K18 - 0x8C2C1726, // 0282 GETMET R11 R11 K38 - 0x58340051, // 0283 LDCONST R13 K81 - 0x50380200, // 0284 LDBOOL R14 1 0 - 0x7C2C0600, // 0285 CALL R11 3 - 0x942C1752, // 0286 GETIDX R11 R11 K82 - 0x942C1753, // 0287 GETIDX R11 R11 K83 - 0x7C200600, // 0288 CALL R8 3 - 0x80041000, // 0289 RET 1 R8 - 0x70020058, // 028A JMP #02E4 - 0x54220008, // 028B LDINT R8 9 - 0x1C200E08, // 028C EQ R8 R7 R8 - 0x78220005, // 028D JMPF R8 #0294 - 0x8C200706, // 028E GETMET R8 R3 K6 - 0x88280B0C, // 028F GETMBR R10 R5 K12 - 0x582C0009, // 0290 LDCONST R11 K9 - 0x7C200600, // 0291 CALL R8 3 - 0x80041000, // 0292 RET 1 R8 - 0x7002004F, // 0293 JMP #02E4 - 0x54220009, // 0294 LDINT R8 10 - 0x1C200E08, // 0295 EQ R8 R7 R8 - 0x78220015, // 0296 JMPF R8 #02AD - 0xB8222400, // 0297 GETNGBL R8 K18 - 0x8C201126, // 0298 GETMET R8 R8 K38 - 0x58280051, // 0299 LDCONST R10 K81 - 0x502C0200, // 029A LDBOOL R11 1 0 - 0x7C200600, // 029B CALL R8 3 - 0x94201152, // 029C GETIDX R8 R8 K82 - 0x94201154, // 029D GETIDX R8 R8 K84 - 0x8C24091B, // 029E GETMET R9 R4 K27 - 0x5C2C1000, // 029F MOVE R11 R8 - 0x58300055, // 02A0 LDCONST R12 K85 - 0x7C240600, // 02A1 CALL R9 3 - 0x24281305, // 02A2 GT R10 R9 K5 - 0x782A0002, // 02A3 JMPF R10 #02A7 - 0x04281309, // 02A4 SUB R10 R9 K9 - 0x402A0A0A, // 02A5 CONNECT R10 K5 R10 - 0x9420100A, // 02A6 GETIDX R8 R8 R10 - 0x8C280706, // 02A7 GETMET R10 R3 K6 - 0x88300B16, // 02A8 GETMBR R12 R5 K22 - 0x5C341000, // 02A9 MOVE R13 R8 - 0x7C280600, // 02AA CALL R10 3 - 0x80041400, // 02AB RET 1 R10 - 0x70020036, // 02AC JMP #02E4 - 0x5422000E, // 02AD LDINT R8 15 - 0x1C200E08, // 02AE EQ R8 R7 R8 - 0x7822000B, // 02AF JMPF R8 #02BC - 0x8C200706, // 02B0 GETMET R8 R3 K6 - 0x88280B16, // 02B1 GETMBR R10 R5 K22 - 0xB82E2400, // 02B2 GETNGBL R11 K18 - 0x8C2C1725, // 02B3 GETMET R11 R11 K37 - 0x7C2C0200, // 02B4 CALL R11 1 - 0x8C2C171B, // 02B5 GETMET R11 R11 K27 - 0x5834001C, // 02B6 LDCONST R13 K28 - 0x5838001D, // 02B7 LDCONST R14 K29 - 0x7C2C0600, // 02B8 CALL R11 3 - 0x7C200600, // 02B9 CALL R8 3 - 0x80041000, // 02BA RET 1 R8 - 0x70020027, // 02BB JMP #02E4 - 0x54220010, // 02BC LDINT R8 17 - 0x1C200E08, // 02BD EQ R8 R7 R8 - 0x78220005, // 02BE JMPF R8 #02C5 - 0x8C200706, // 02BF GETMET R8 R3 K6 - 0x88280B10, // 02C0 GETMBR R10 R5 K16 - 0x582C0009, // 02C1 LDCONST R11 K9 - 0x7C200600, // 02C2 CALL R8 3 - 0x80041000, // 02C3 RET 1 R8 - 0x7002001E, // 02C4 JMP #02E4 - 0x54220011, // 02C5 LDINT R8 18 - 0x1C200E08, // 02C6 EQ R8 R7 R8 - 0x7822000B, // 02C7 JMPF R8 #02D4 - 0x8C200706, // 02C8 GETMET R8 R3 K6 - 0x88280B16, // 02C9 GETMBR R10 R5 K22 - 0xB82E2400, // 02CA GETNGBL R11 K18 - 0x8C2C1725, // 02CB GETMET R11 R11 K37 - 0x7C2C0200, // 02CC CALL R11 1 - 0x8C2C171B, // 02CD GETMET R11 R11 K27 - 0x5834001C, // 02CE LDCONST R13 K28 - 0x5838001D, // 02CF LDCONST R14 K29 - 0x7C2C0600, // 02D0 CALL R11 3 - 0x7C200600, // 02D1 CALL R8 3 - 0x80041000, // 02D2 RET 1 R8 - 0x7002000F, // 02D3 JMP #02E4 - 0x54220012, // 02D4 LDINT R8 19 - 0x1C200E08, // 02D5 EQ R8 R7 R8 - 0x7822000C, // 02D6 JMPF R8 #02E4 - 0x8C200B0A, // 02D7 GETMET R8 R5 K10 - 0x7C200200, // 02D8 CALL R8 1 - 0x8C24110B, // 02D9 GETMET R9 R8 K11 - 0x582C0005, // 02DA LDCONST R11 K5 - 0x88300B0C, // 02DB GETMBR R12 R5 K12 - 0x5834000F, // 02DC LDCONST R13 K15 - 0x7C240800, // 02DD CALL R9 4 - 0x8C24110B, // 02DE GETMET R9 R8 K11 - 0x582C0009, // 02DF LDCONST R11 K9 - 0x88300B0C, // 02E0 GETMBR R12 R5 K12 - 0x5834000F, // 02E1 LDCONST R13 K15 - 0x7C240800, // 02E2 CALL R9 4 - 0x80041000, // 02E3 RET 1 R8 - 0x700200A8, // 02E4 JMP #038E - 0x5422003E, // 02E5 LDINT R8 63 - 0x1C200C08, // 02E6 EQ R8 R6 R8 - 0x78220000, // 02E7 JMPF R8 #02E9 - 0x700200A4, // 02E8 JMP #038E - 0x54220029, // 02E9 LDINT R8 42 - 0x1C200C08, // 02EA EQ R8 R6 R8 - 0x7822001D, // 02EB JMPF R8 #030A - 0x1C200F05, // 02EC EQ R8 R7 K5 - 0x78220003, // 02ED JMPF R8 #02F2 - 0x8C200B11, // 02EE GETMET R8 R5 K17 - 0x7C200200, // 02EF CALL R8 1 - 0x80041000, // 02F0 RET 1 R8 - 0x70020016, // 02F1 JMP #0309 - 0x1C200F09, // 02F2 EQ R8 R7 K9 - 0x78220005, // 02F3 JMPF R8 #02FA - 0x8C200706, // 02F4 GETMET R8 R3 K6 - 0x88280B10, // 02F5 GETMBR R10 R5 K16 - 0x582C0005, // 02F6 LDCONST R11 K5 - 0x7C200600, // 02F7 CALL R8 3 - 0x80041000, // 02F8 RET 1 R8 - 0x7002000E, // 02F9 JMP #0309 - 0x1C200F0D, // 02FA EQ R8 R7 K13 - 0x78220005, // 02FB JMPF R8 #0302 - 0x8C200706, // 02FC GETMET R8 R3 K6 - 0x88280B0E, // 02FD GETMBR R10 R5 K14 - 0x582C0009, // 02FE LDCONST R11 K9 - 0x7C200600, // 02FF CALL R8 3 - 0x80041000, // 0300 RET 1 R8 - 0x70020006, // 0301 JMP #0309 - 0x1C200F0F, // 0302 EQ R8 R7 K15 - 0x78220004, // 0303 JMPF R8 #0309 - 0x8C200706, // 0304 GETMET R8 R3 K6 - 0x88280B18, // 0305 GETMBR R10 R5 K24 - 0x4C2C0000, // 0306 LDNIL R11 - 0x7C200600, // 0307 CALL R8 3 - 0x80041000, // 0308 RET 1 R8 - 0x70020083, // 0309 JMP #038E - 0x5422002A, // 030A LDINT R8 43 - 0x1C200C08, // 030B EQ R8 R6 R8 - 0x78220016, // 030C JMPF R8 #0324 - 0x1C200F05, // 030D EQ R8 R7 K5 - 0x78220007, // 030E JMPF R8 #0317 - 0x8C200706, // 030F GETMET R8 R3 K6 - 0x88280B16, // 0310 GETMBR R10 R5 K22 - 0xB82E2400, // 0311 GETNGBL R11 K18 - 0x8C2C1756, // 0312 GETMET R11 R11 K86 - 0x7C2C0200, // 0313 CALL R11 1 - 0x7C200600, // 0314 CALL R8 3 - 0x80041000, // 0315 RET 1 R8 - 0x7002000B, // 0316 JMP #0323 - 0x1C200F09, // 0317 EQ R8 R7 K9 - 0x78220009, // 0318 JMPF R8 #0323 - 0x8C200B11, // 0319 GETMET R8 R5 K17 - 0x7C200200, // 031A CALL R8 1 - 0x8C24110B, // 031B GETMET R9 R8 K11 - 0x4C2C0000, // 031C LDNIL R11 - 0x88300B16, // 031D GETMBR R12 R5 K22 - 0xB8362400, // 031E GETNGBL R13 K18 - 0x8C341B56, // 031F GETMET R13 R13 K86 - 0x7C340200, // 0320 CALL R13 1 - 0x7C240800, // 0321 CALL R9 4 + 0x70020004, // 0226 JMP #022C + 0x8C240706, // 0227 GETMET R9 R3 K6 + 0x882C0B18, // 0228 GETMBR R11 R5 K24 + 0x4C300000, // 0229 LDNIL R12 + 0x7C240600, // 022A CALL R9 3 + 0x80041200, // 022B RET 1 R9 + 0x70020012, // 022C JMP #0240 + 0x1C200F0D, // 022D EQ R8 R7 K13 + 0x78220010, // 022E JMPF R8 #0240 + 0x88200136, // 022F GETMBR R8 R0 K54 + 0x8820114B, // 0230 GETMBR R8 R8 K75 + 0x4C240000, // 0231 LDNIL R9 + 0x20241009, // 0232 NE R9 R8 R9 + 0x78260006, // 0233 JMPF R9 #023B + 0x8C240706, // 0234 GETMET R9 R3 K6 + 0x882C0B0C, // 0235 GETMBR R11 R5 K12 + 0x8C301141, // 0236 GETMET R12 R8 K65 + 0x7C300200, // 0237 CALL R12 1 + 0x7C240600, // 0238 CALL R9 3 + 0x80041200, // 0239 RET 1 R9 + 0x70020004, // 023A JMP #0240 + 0x8C240706, // 023B GETMET R9 R3 K6 + 0x882C0B18, // 023C GETMBR R11 R5 K24 + 0x4C300000, // 023D LDNIL R12 + 0x7C240600, // 023E CALL R9 3 + 0x80041200, // 023F RET 1 R9 + 0x70020166, // 0240 JMP #03A8 + 0x54220027, // 0241 LDINT R8 40 + 0x1C200C08, // 0242 EQ R8 R6 R8 + 0x782200BA, // 0243 JMPF R8 #02FF + 0x8C200133, // 0244 GETMET R8 R0 K51 + 0x5C280400, // 0245 MOVE R10 R2 + 0x7C200400, // 0246 CALL R8 2 + 0x1C200F05, // 0247 EQ R8 R7 K5 + 0x78220005, // 0248 JMPF R8 #024F + 0x8C200706, // 0249 GETMET R8 R3 K6 + 0x88280B0C, // 024A GETMBR R10 R5 K12 + 0x582C0009, // 024B LDCONST R11 K9 + 0x7C200600, // 024C CALL R8 3 + 0x80041000, // 024D RET 1 R8 + 0x700200AE, // 024E JMP #02FE + 0x1C200F09, // 024F EQ R8 R7 K9 + 0x78220005, // 0250 JMPF R8 #0257 + 0x8C200706, // 0251 GETMET R8 R3 K6 + 0x88280B16, // 0252 GETMBR R10 R5 K22 + 0x582C004C, // 0253 LDCONST R11 K76 + 0x7C200600, // 0254 CALL R8 3 + 0x80041000, // 0255 RET 1 R8 + 0x700200A6, // 0256 JMP #02FE + 0x1C200F0D, // 0257 EQ R8 R7 K13 + 0x78220006, // 0258 JMPF R8 #0260 + 0x8C200706, // 0259 GETMET R8 R3 K6 + 0x88280B0C, // 025A GETMBR R10 R5 K12 + 0x882C0136, // 025B GETMBR R11 R0 K54 + 0x882C174D, // 025C GETMBR R11 R11 K77 + 0x7C200600, // 025D CALL R8 3 + 0x80041000, // 025E RET 1 R8 + 0x7002009D, // 025F JMP #02FE + 0x1C200F0F, // 0260 EQ R8 R7 K15 + 0x7822000A, // 0261 JMPF R8 #026D + 0x8C200706, // 0262 GETMET R8 R3 K6 + 0x88280B16, // 0263 GETMBR R10 R5 K22 + 0xB82E2400, // 0264 GETNGBL R11 K18 + 0x8C2C1726, // 0265 GETMET R11 R11 K38 + 0x5834004E, // 0266 LDCONST R13 K78 + 0x50380200, // 0267 LDBOOL R14 1 0 + 0x7C2C0600, // 0268 CALL R11 3 + 0x942C174E, // 0269 GETIDX R11 R11 K78 + 0x7C200600, // 026A CALL R8 3 + 0x80041000, // 026B RET 1 R8 + 0x70020090, // 026C JMP #02FE + 0x54220003, // 026D LDINT R8 4 + 0x1C200E08, // 026E EQ R8 R7 R8 + 0x78220005, // 026F JMPF R8 #0276 + 0x8C200706, // 0270 GETMET R8 R3 K6 + 0x88280B0C, // 0271 GETMBR R10 R5 K12 + 0x542E7FFF, // 0272 LDINT R11 32768 + 0x7C200600, // 0273 CALL R8 3 + 0x80041000, // 0274 RET 1 R8 + 0x70020087, // 0275 JMP #02FE + 0x54220004, // 0276 LDINT R8 5 + 0x1C200E08, // 0277 EQ R8 R7 R8 + 0x7822000A, // 0278 JMPF R8 #0284 + 0x8C200706, // 0279 GETMET R8 R3 K6 + 0x88280B16, // 027A GETMBR R10 R5 K22 + 0xB82E2400, // 027B GETNGBL R11 K18 + 0x8C2C1726, // 027C GETMET R11 R11 K38 + 0x5834004F, // 027D LDCONST R13 K79 + 0x50380200, // 027E LDBOOL R14 1 0 + 0x7C2C0600, // 027F CALL R11 3 + 0x942C1750, // 0280 GETIDX R11 R11 K80 + 0x7C200600, // 0281 CALL R8 3 + 0x80041000, // 0282 RET 1 R8 + 0x70020079, // 0283 JMP #02FE + 0x54220005, // 0284 LDINT R8 6 + 0x1C200E08, // 0285 EQ R8 R7 R8 + 0x78220005, // 0286 JMPF R8 #028D + 0x8C200706, // 0287 GETMET R8 R3 K6 + 0x88280B16, // 0288 GETMBR R10 R5 K22 + 0x582C0051, // 0289 LDCONST R11 K81 + 0x7C200600, // 028A CALL R8 3 + 0x80041000, // 028B RET 1 R8 + 0x70020070, // 028C JMP #02FE + 0x54220006, // 028D LDINT R8 7 + 0x1C200E08, // 028E EQ R8 R7 R8 + 0x78220005, // 028F JMPF R8 #0296 + 0x8C200706, // 0290 GETMET R8 R3 K6 + 0x88280B0C, // 0291 GETMBR R10 R5 K12 + 0x582C0005, // 0292 LDCONST R11 K5 + 0x7C200600, // 0293 CALL R8 3 + 0x80041000, // 0294 RET 1 R8 + 0x70020067, // 0295 JMP #02FE + 0x54220007, // 0296 LDINT R8 8 + 0x1C200E08, // 0297 EQ R8 R7 R8 + 0x7822000B, // 0298 JMPF R8 #02A5 + 0x8C200706, // 0299 GETMET R8 R3 K6 + 0x88280B16, // 029A GETMBR R10 R5 K22 + 0xB82E2400, // 029B GETNGBL R11 K18 + 0x8C2C1726, // 029C GETMET R11 R11 K38 + 0x58340052, // 029D LDCONST R13 K82 + 0x50380200, // 029E LDBOOL R14 1 0 + 0x7C2C0600, // 029F CALL R11 3 + 0x942C1753, // 02A0 GETIDX R11 R11 K83 + 0x942C1754, // 02A1 GETIDX R11 R11 K84 + 0x7C200600, // 02A2 CALL R8 3 + 0x80041000, // 02A3 RET 1 R8 + 0x70020058, // 02A4 JMP #02FE + 0x54220008, // 02A5 LDINT R8 9 + 0x1C200E08, // 02A6 EQ R8 R7 R8 + 0x78220005, // 02A7 JMPF R8 #02AE + 0x8C200706, // 02A8 GETMET R8 R3 K6 + 0x88280B0C, // 02A9 GETMBR R10 R5 K12 + 0x582C0009, // 02AA LDCONST R11 K9 + 0x7C200600, // 02AB CALL R8 3 + 0x80041000, // 02AC RET 1 R8 + 0x7002004F, // 02AD JMP #02FE + 0x54220009, // 02AE LDINT R8 10 + 0x1C200E08, // 02AF EQ R8 R7 R8 + 0x78220015, // 02B0 JMPF R8 #02C7 + 0xB8222400, // 02B1 GETNGBL R8 K18 + 0x8C201126, // 02B2 GETMET R8 R8 K38 + 0x58280052, // 02B3 LDCONST R10 K82 + 0x502C0200, // 02B4 LDBOOL R11 1 0 + 0x7C200600, // 02B5 CALL R8 3 + 0x94201153, // 02B6 GETIDX R8 R8 K83 + 0x94201155, // 02B7 GETIDX R8 R8 K85 + 0x8C24091B, // 02B8 GETMET R9 R4 K27 + 0x5C2C1000, // 02B9 MOVE R11 R8 + 0x58300056, // 02BA LDCONST R12 K86 + 0x7C240600, // 02BB CALL R9 3 + 0x24281305, // 02BC GT R10 R9 K5 + 0x782A0002, // 02BD JMPF R10 #02C1 + 0x04281309, // 02BE SUB R10 R9 K9 + 0x402A0A0A, // 02BF CONNECT R10 K5 R10 + 0x9420100A, // 02C0 GETIDX R8 R8 R10 + 0x8C280706, // 02C1 GETMET R10 R3 K6 + 0x88300B16, // 02C2 GETMBR R12 R5 K22 + 0x5C341000, // 02C3 MOVE R13 R8 + 0x7C280600, // 02C4 CALL R10 3 + 0x80041400, // 02C5 RET 1 R10 + 0x70020036, // 02C6 JMP #02FE + 0x5422000E, // 02C7 LDINT R8 15 + 0x1C200E08, // 02C8 EQ R8 R7 R8 + 0x7822000B, // 02C9 JMPF R8 #02D6 + 0x8C200706, // 02CA GETMET R8 R3 K6 + 0x88280B16, // 02CB GETMBR R10 R5 K22 + 0xB82E2400, // 02CC GETNGBL R11 K18 + 0x8C2C1725, // 02CD GETMET R11 R11 K37 + 0x7C2C0200, // 02CE CALL R11 1 + 0x8C2C171B, // 02CF GETMET R11 R11 K27 + 0x5834001C, // 02D0 LDCONST R13 K28 + 0x5838001D, // 02D1 LDCONST R14 K29 + 0x7C2C0600, // 02D2 CALL R11 3 + 0x7C200600, // 02D3 CALL R8 3 + 0x80041000, // 02D4 RET 1 R8 + 0x70020027, // 02D5 JMP #02FE + 0x54220010, // 02D6 LDINT R8 17 + 0x1C200E08, // 02D7 EQ R8 R7 R8 + 0x78220005, // 02D8 JMPF R8 #02DF + 0x8C200706, // 02D9 GETMET R8 R3 K6 + 0x88280B10, // 02DA GETMBR R10 R5 K16 + 0x582C0009, // 02DB LDCONST R11 K9 + 0x7C200600, // 02DC CALL R8 3 + 0x80041000, // 02DD RET 1 R8 + 0x7002001E, // 02DE JMP #02FE + 0x54220011, // 02DF LDINT R8 18 + 0x1C200E08, // 02E0 EQ R8 R7 R8 + 0x7822000B, // 02E1 JMPF R8 #02EE + 0x8C200706, // 02E2 GETMET R8 R3 K6 + 0x88280B16, // 02E3 GETMBR R10 R5 K22 + 0xB82E2400, // 02E4 GETNGBL R11 K18 + 0x8C2C1725, // 02E5 GETMET R11 R11 K37 + 0x7C2C0200, // 02E6 CALL R11 1 + 0x8C2C171B, // 02E7 GETMET R11 R11 K27 + 0x5834001C, // 02E8 LDCONST R13 K28 + 0x5838001D, // 02E9 LDCONST R14 K29 + 0x7C2C0600, // 02EA CALL R11 3 + 0x7C200600, // 02EB CALL R8 3 + 0x80041000, // 02EC RET 1 R8 + 0x7002000F, // 02ED JMP #02FE + 0x54220012, // 02EE LDINT R8 19 + 0x1C200E08, // 02EF EQ R8 R7 R8 + 0x7822000C, // 02F0 JMPF R8 #02FE + 0x8C200B0A, // 02F1 GETMET R8 R5 K10 + 0x7C200200, // 02F2 CALL R8 1 + 0x8C24110B, // 02F3 GETMET R9 R8 K11 + 0x582C0005, // 02F4 LDCONST R11 K5 + 0x88300B0C, // 02F5 GETMBR R12 R5 K12 + 0x5834000F, // 02F6 LDCONST R13 K15 + 0x7C240800, // 02F7 CALL R9 4 + 0x8C24110B, // 02F8 GETMET R9 R8 K11 + 0x582C0009, // 02F9 LDCONST R11 K9 + 0x88300B0C, // 02FA GETMBR R12 R5 K12 + 0x5834000F, // 02FB LDCONST R13 K15 + 0x7C240800, // 02FC CALL R9 4 + 0x80041000, // 02FD RET 1 R8 + 0x700200A8, // 02FE JMP #03A8 + 0x5422003E, // 02FF LDINT R8 63 + 0x1C200C08, // 0300 EQ R8 R6 R8 + 0x78220000, // 0301 JMPF R8 #0303 + 0x700200A4, // 0302 JMP #03A8 + 0x54220029, // 0303 LDINT R8 42 + 0x1C200C08, // 0304 EQ R8 R6 R8 + 0x7822001D, // 0305 JMPF R8 #0324 + 0x1C200F05, // 0306 EQ R8 R7 K5 + 0x78220003, // 0307 JMPF R8 #030C + 0x8C200B11, // 0308 GETMET R8 R5 K17 + 0x7C200200, // 0309 CALL R8 1 + 0x80041000, // 030A RET 1 R8 + 0x70020016, // 030B JMP #0323 + 0x1C200F09, // 030C EQ R8 R7 K9 + 0x78220005, // 030D JMPF R8 #0314 + 0x8C200706, // 030E GETMET R8 R3 K6 + 0x88280B10, // 030F GETMBR R10 R5 K16 + 0x582C0005, // 0310 LDCONST R11 K5 + 0x7C200600, // 0311 CALL R8 3 + 0x80041000, // 0312 RET 1 R8 + 0x7002000E, // 0313 JMP #0323 + 0x1C200F0D, // 0314 EQ R8 R7 K13 + 0x78220005, // 0315 JMPF R8 #031C + 0x8C200706, // 0316 GETMET R8 R3 K6 + 0x88280B0E, // 0317 GETMBR R10 R5 K14 + 0x582C0009, // 0318 LDCONST R11 K9 + 0x7C200600, // 0319 CALL R8 3 + 0x80041000, // 031A RET 1 R8 + 0x70020006, // 031B JMP #0323 + 0x1C200F0F, // 031C EQ R8 R7 K15 + 0x78220004, // 031D JMPF R8 #0323 + 0x8C200706, // 031E GETMET R8 R3 K6 + 0x88280B18, // 031F GETMBR R10 R5 K24 + 0x4C2C0000, // 0320 LDNIL R11 + 0x7C200600, // 0321 CALL R8 3 0x80041000, // 0322 RET 1 R8 - 0x70020069, // 0323 JMP #038E - 0x5422002B, // 0324 LDINT R8 44 + 0x70020083, // 0323 JMP #03A8 + 0x5422002A, // 0324 LDINT R8 43 0x1C200C08, // 0325 EQ R8 R6 R8 - 0x7822001C, // 0326 JMPF R8 #0344 + 0x78220016, // 0326 JMPF R8 #033E 0x1C200F05, // 0327 EQ R8 R7 K5 - 0x78220005, // 0328 JMPF R8 #032F + 0x78220007, // 0328 JMPF R8 #0331 0x8C200706, // 0329 GETMET R8 R3 K6 - 0x88280B0E, // 032A GETMBR R10 R5 K14 - 0x582C0009, // 032B LDCONST R11 K9 - 0x7C200600, // 032C CALL R8 3 - 0x80041000, // 032D RET 1 R8 - 0x70020013, // 032E JMP #0343 - 0x1C200F09, // 032F EQ R8 R7 K9 - 0x78220005, // 0330 JMPF R8 #0337 - 0x8C200706, // 0331 GETMET R8 R3 K6 - 0x88280B0E, // 0332 GETMBR R10 R5 K14 - 0x542E0003, // 0333 LDINT R11 4 - 0x7C200600, // 0334 CALL R8 3 - 0x80041000, // 0335 RET 1 R8 - 0x7002000B, // 0336 JMP #0343 - 0x1C200F0D, // 0337 EQ R8 R7 K13 - 0x78220009, // 0338 JMPF R8 #0343 - 0x8C200B11, // 0339 GETMET R8 R5 K17 - 0x7C200200, // 033A CALL R8 1 - 0x8C24110B, // 033B GETMET R9 R8 K11 - 0x4C2C0000, // 033C LDNIL R11 - 0x8C300B57, // 033D GETMET R12 R5 K87 - 0x88380B0E, // 033E GETMBR R14 R5 K14 - 0x543E0003, // 033F LDINT R15 4 - 0x7C300600, // 0340 CALL R12 3 - 0x7C240600, // 0341 CALL R9 3 - 0x80041000, // 0342 RET 1 R8 - 0x70020049, // 0343 JMP #038E - 0x54220030, // 0344 LDINT R8 49 - 0x1C200C08, // 0345 EQ R8 R6 R8 - 0x78220010, // 0346 JMPF R8 #0358 - 0x1C200F0F, // 0347 EQ R8 R7 K15 - 0x78220005, // 0348 JMPF R8 #034F - 0x8C200706, // 0349 GETMET R8 R3 K6 - 0x88280B0E, // 034A GETMBR R10 R5 K14 - 0x542E001D, // 034B LDINT R11 30 - 0x7C200600, // 034C CALL R8 3 - 0x80041000, // 034D RET 1 R8 - 0x70020007, // 034E JMP #0357 - 0x5422FFFB, // 034F LDINT R8 65532 - 0x1C200E08, // 0350 EQ R8 R7 R8 - 0x78220004, // 0351 JMPF R8 #0357 - 0x8C200706, // 0352 GETMET R8 R3 K6 - 0x88280B2A, // 0353 GETMBR R10 R5 K42 - 0x542E0003, // 0354 LDINT R11 4 - 0x7C200600, // 0355 CALL R8 3 - 0x80041000, // 0356 RET 1 R8 - 0x70020035, // 0357 JMP #038E - 0x5422001C, // 0358 LDINT R8 29 - 0x1C200C08, // 0359 EQ R8 R6 R8 - 0x78220029, // 035A JMPF R8 #0385 - 0x1C200F0F, // 035B EQ R8 R7 K15 - 0x7822001D, // 035C JMPF R8 #037B - 0x8C200B11, // 035D GETMET R8 R5 K17 - 0x7C200200, // 035E CALL R8 1 - 0x88240135, // 035F GETMBR R9 R0 K53 - 0x8C241358, // 0360 GETMET R9 R9 K88 - 0x502C0200, // 0361 LDBOOL R11 1 0 - 0x7C240400, // 0362 CALL R9 2 - 0x88280135, // 0363 GETMBR R10 R0 K53 - 0x88281559, // 0364 GETMBR R10 R10 K89 - 0x602C0010, // 0365 GETGBL R11 G16 - 0x5C301200, // 0366 MOVE R12 R9 - 0x7C2C0200, // 0367 CALL R11 1 - 0xA802000C, // 0368 EXBLK 0 #0376 - 0x5C301600, // 0369 MOVE R12 R11 - 0x7C300000, // 036A CALL R12 0 - 0x5C341400, // 036B MOVE R13 R10 - 0x78360002, // 036C JMPF R13 #0370 - 0x5436FEFF, // 036D LDINT R13 65280 - 0x1434180D, // 036E LT R13 R12 R13 - 0x78360004, // 036F JMPF R13 #0375 - 0x8C34110B, // 0370 GETMET R13 R8 K11 - 0x4C3C0000, // 0371 LDNIL R15 - 0x88400B0C, // 0372 GETMBR R16 R5 K12 - 0x5C441800, // 0373 MOVE R17 R12 - 0x7C340800, // 0374 CALL R13 4 - 0x7001FFF2, // 0375 JMP #0369 - 0x582C003C, // 0376 LDCONST R11 K60 - 0xAC2C0200, // 0377 CATCH R11 1 0 - 0xB0080000, // 0378 RAISE 2 R0 R0 - 0x80041000, // 0379 RET 1 R8 - 0x70020008, // 037A JMP #0384 - 0x60200003, // 037B GETGBL R8 G3 - 0x5C240000, // 037C MOVE R9 R0 - 0x7C200200, // 037D CALL R8 1 - 0x8C20115A, // 037E GETMET R8 R8 K90 - 0x5C280200, // 037F MOVE R10 R1 - 0x5C2C0400, // 0380 MOVE R11 R2 - 0x5C300600, // 0381 MOVE R12 R3 - 0x7C200800, // 0382 CALL R8 4 - 0x80041000, // 0383 RET 1 R8 - 0x70020008, // 0384 JMP #038E - 0x60200003, // 0385 GETGBL R8 G3 - 0x5C240000, // 0386 MOVE R9 R0 - 0x7C200200, // 0387 CALL R8 1 - 0x8C20115A, // 0388 GETMET R8 R8 K90 - 0x5C280200, // 0389 MOVE R10 R1 - 0x5C2C0400, // 038A MOVE R11 R2 - 0x5C300600, // 038B MOVE R12 R3 - 0x7C200800, // 038C CALL R8 4 - 0x80041000, // 038D RET 1 R8 - 0x80000000, // 038E RET 0 + 0x88280B16, // 032A GETMBR R10 R5 K22 + 0xB82E2400, // 032B GETNGBL R11 K18 + 0x8C2C1757, // 032C GETMET R11 R11 K87 + 0x7C2C0200, // 032D CALL R11 1 + 0x7C200600, // 032E CALL R8 3 + 0x80041000, // 032F RET 1 R8 + 0x7002000B, // 0330 JMP #033D + 0x1C200F09, // 0331 EQ R8 R7 K9 + 0x78220009, // 0332 JMPF R8 #033D + 0x8C200B11, // 0333 GETMET R8 R5 K17 + 0x7C200200, // 0334 CALL R8 1 + 0x8C24110B, // 0335 GETMET R9 R8 K11 + 0x4C2C0000, // 0336 LDNIL R11 + 0x88300B16, // 0337 GETMBR R12 R5 K22 + 0xB8362400, // 0338 GETNGBL R13 K18 + 0x8C341B57, // 0339 GETMET R13 R13 K87 + 0x7C340200, // 033A CALL R13 1 + 0x7C240800, // 033B CALL R9 4 + 0x80041000, // 033C RET 1 R8 + 0x70020069, // 033D JMP #03A8 + 0x5422002B, // 033E LDINT R8 44 + 0x1C200C08, // 033F EQ R8 R6 R8 + 0x7822001C, // 0340 JMPF R8 #035E + 0x1C200F05, // 0341 EQ R8 R7 K5 + 0x78220005, // 0342 JMPF R8 #0349 + 0x8C200706, // 0343 GETMET R8 R3 K6 + 0x88280B0E, // 0344 GETMBR R10 R5 K14 + 0x582C0009, // 0345 LDCONST R11 K9 + 0x7C200600, // 0346 CALL R8 3 + 0x80041000, // 0347 RET 1 R8 + 0x70020013, // 0348 JMP #035D + 0x1C200F09, // 0349 EQ R8 R7 K9 + 0x78220005, // 034A JMPF R8 #0351 + 0x8C200706, // 034B GETMET R8 R3 K6 + 0x88280B0E, // 034C GETMBR R10 R5 K14 + 0x542E0003, // 034D LDINT R11 4 + 0x7C200600, // 034E CALL R8 3 + 0x80041000, // 034F RET 1 R8 + 0x7002000B, // 0350 JMP #035D + 0x1C200F0D, // 0351 EQ R8 R7 K13 + 0x78220009, // 0352 JMPF R8 #035D + 0x8C200B11, // 0353 GETMET R8 R5 K17 + 0x7C200200, // 0354 CALL R8 1 + 0x8C24110B, // 0355 GETMET R9 R8 K11 + 0x4C2C0000, // 0356 LDNIL R11 + 0x8C300B58, // 0357 GETMET R12 R5 K88 + 0x88380B0E, // 0358 GETMBR R14 R5 K14 + 0x543E0003, // 0359 LDINT R15 4 + 0x7C300600, // 035A CALL R12 3 + 0x7C240600, // 035B CALL R9 3 + 0x80041000, // 035C RET 1 R8 + 0x70020049, // 035D JMP #03A8 + 0x54220030, // 035E LDINT R8 49 + 0x1C200C08, // 035F EQ R8 R6 R8 + 0x78220010, // 0360 JMPF R8 #0372 + 0x1C200F0F, // 0361 EQ R8 R7 K15 + 0x78220005, // 0362 JMPF R8 #0369 + 0x8C200706, // 0363 GETMET R8 R3 K6 + 0x88280B0E, // 0364 GETMBR R10 R5 K14 + 0x542E001D, // 0365 LDINT R11 30 + 0x7C200600, // 0366 CALL R8 3 + 0x80041000, // 0367 RET 1 R8 + 0x70020007, // 0368 JMP #0371 + 0x5422FFFB, // 0369 LDINT R8 65532 + 0x1C200E08, // 036A EQ R8 R7 R8 + 0x78220004, // 036B JMPF R8 #0371 + 0x8C200706, // 036C GETMET R8 R3 K6 + 0x88280B2A, // 036D GETMBR R10 R5 K42 + 0x542E0003, // 036E LDINT R11 4 + 0x7C200600, // 036F CALL R8 3 + 0x80041000, // 0370 RET 1 R8 + 0x70020035, // 0371 JMP #03A8 + 0x5422001C, // 0372 LDINT R8 29 + 0x1C200C08, // 0373 EQ R8 R6 R8 + 0x78220029, // 0374 JMPF R8 #039F + 0x1C200F0F, // 0375 EQ R8 R7 K15 + 0x7822001D, // 0376 JMPF R8 #0395 + 0x8C200B11, // 0377 GETMET R8 R5 K17 + 0x7C200200, // 0378 CALL R8 1 + 0x88240136, // 0379 GETMBR R9 R0 K54 + 0x8C241359, // 037A GETMET R9 R9 K89 + 0x502C0200, // 037B LDBOOL R11 1 0 + 0x7C240400, // 037C CALL R9 2 + 0x88280136, // 037D GETMBR R10 R0 K54 + 0x8828155A, // 037E GETMBR R10 R10 K90 + 0x602C0010, // 037F GETGBL R11 G16 + 0x5C301200, // 0380 MOVE R12 R9 + 0x7C2C0200, // 0381 CALL R11 1 + 0xA802000C, // 0382 EXBLK 0 #0390 + 0x5C301600, // 0383 MOVE R12 R11 + 0x7C300000, // 0384 CALL R12 0 + 0x5C341400, // 0385 MOVE R13 R10 + 0x78360002, // 0386 JMPF R13 #038A + 0x5436FEFF, // 0387 LDINT R13 65280 + 0x1434180D, // 0388 LT R13 R12 R13 + 0x78360004, // 0389 JMPF R13 #038F + 0x8C34110B, // 038A GETMET R13 R8 K11 + 0x4C3C0000, // 038B LDNIL R15 + 0x88400B0C, // 038C GETMBR R16 R5 K12 + 0x5C441800, // 038D MOVE R17 R12 + 0x7C340800, // 038E CALL R13 4 + 0x7001FFF2, // 038F JMP #0383 + 0x582C003D, // 0390 LDCONST R11 K61 + 0xAC2C0200, // 0391 CATCH R11 1 0 + 0xB0080000, // 0392 RAISE 2 R0 R0 + 0x80041000, // 0393 RET 1 R8 + 0x70020008, // 0394 JMP #039E + 0x60200003, // 0395 GETGBL R8 G3 + 0x5C240000, // 0396 MOVE R9 R0 + 0x7C200200, // 0397 CALL R8 1 + 0x8C20115B, // 0398 GETMET R8 R8 K91 + 0x5C280200, // 0399 MOVE R10 R1 + 0x5C2C0400, // 039A MOVE R11 R2 + 0x5C300600, // 039B MOVE R12 R3 + 0x7C200800, // 039C CALL R8 4 + 0x80041000, // 039D RET 1 R8 + 0x70020008, // 039E JMP #03A8 + 0x60200003, // 039F GETGBL R8 G3 + 0x5C240000, // 03A0 MOVE R9 R0 + 0x7C200200, // 03A1 CALL R8 1 + 0x8C20115B, // 03A2 GETMET R8 R8 K91 + 0x5C280200, // 03A3 MOVE R10 R1 + 0x5C2C0400, // 03A4 MOVE R11 R2 + 0x5C300600, // 03A5 MOVE R12 R3 + 0x7C200800, // 03A6 CALL R8 4 + 0x80041000, // 03A7 RET 1 R8 + 0x80000000, // 03A8 RET 0 }) ) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Contact.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Contact.h index 3382434a33e6..00e5c533cbd5 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Contact.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Contact.h @@ -258,7 +258,7 @@ be_local_class(Matter_Plugin_Sensor_Contact, { be_const_key_weak(shadow_contact, -1), be_const_var(1) }, { be_const_key_weak(TYPE, -1), be_nested_str_weak(contact) }, { be_const_key_weak(ARG_TYPE, 5), be_const_static_closure(Matter_Plugin_Sensor_Contact__X3Clambda_X3E_closure) }, - { be_const_key_weak(UPDATE_TIME, -1), be_const_int(5000) }, + { be_const_key_weak(UPDATE_TIME, -1), be_const_int(750) }, { be_const_key_weak(ARG_HINT, 1), be_nested_str_weak(Switch_X3Cx_X3E_X20number) }, { be_const_key_weak(NAME, -1), be_nested_str_weak(Contact) }, { be_const_key_weak(parse_configuration, 8), be_const_closure(Matter_Plugin_Sensor_Contact_parse_configuration_closure) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Occupancy.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Occupancy.h index 18a99659f050..7d9f5f042c7e 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Occupancy.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_Occupancy.h @@ -272,7 +272,7 @@ be_local_class(Matter_Plugin_Sensor_Occupancy, { be_const_key_weak(ARG_TYPE, -1), be_const_static_closure(Matter_Plugin_Sensor_Occupancy__X3Clambda_X3E_closure) }, { be_const_key_weak(TYPE, -1), be_nested_str_weak(occupancy) }, { be_const_key_weak(ARG_HINT, 1), be_nested_str_weak(Switch_X3Cx_X3E_X20number) }, - { be_const_key_weak(UPDATE_TIME, -1), be_const_int(5000) }, + { be_const_key_weak(UPDATE_TIME, -1), be_const_int(750) }, { be_const_key_weak(parse_configuration, -1), be_const_closure(Matter_Plugin_Sensor_Occupancy_parse_configuration_closure) }, { be_const_key_weak(tasmota_switch_index, -1), be_const_var(0) }, { be_const_key_weak(shadow_occupancy, 8), be_const_var(1) }, diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_OnOff.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_OnOff.h index 5e5c6a0548ad..98a98f080987 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_OnOff.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Plugin_Sensor_OnOff.h @@ -245,7 +245,7 @@ be_local_class(Matter_Plugin_Sensor_OnOff, { be_const_key_weak(ARG_HINT, -1), be_nested_str_weak(Switch_X3Cx_X3E_X20number) }, { be_const_key_weak(TYPE, -1), be_nested_str_weak(onoff) }, { be_const_key_weak(ARG_TYPE, 1), be_const_static_closure(Matter_Plugin_Sensor_OnOff__X3Clambda_X3E_closure) }, - { be_const_key_weak(UPDATE_TIME, -1), be_const_int(5000) }, + { be_const_key_weak(UPDATE_TIME, -1), be_const_int(750) }, { be_const_key_weak(update_shadow, -1), be_const_closure(Matter_Plugin_Sensor_OnOff_update_shadow_closure) }, { be_const_key_weak(NAME, -1), be_nested_str_weak(OnOff_X20Sensor) }, { be_const_key_weak(parse_configuration, 5), be_const_closure(Matter_Plugin_Sensor_OnOff_parse_configuration_closure) }, 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 d1685288e88e..b0e498421e13 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session.h @@ -7,49 +7,11 @@ extern const bclass be_class_Matter_Session; /******************************************************************** -** Solidified function: before_remove -********************************************************************/ -be_local_closure(Matter_Session_before_remove, /* 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[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(tasmota), - /* K1 */ be_nested_str_weak(log), - /* K2 */ be_nested_str_weak(MTR_X3A_X20_X2DSession_X20_X20_X20_X28_X256i_X29_X20_X28removed_X29), - /* K3 */ be_nested_str_weak(local_session_id), - /* K4 */ be_const_int(3), - }), - be_str_weak(before_remove), - &be_const_str_solidified, - ( &(const binstruction[ 9]) { /* code */ - 0xB8060000, // 0000 GETNGBL R1 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x600C0018, // 0002 GETGBL R3 G24 - 0x58100002, // 0003 LDCONST R4 K2 - 0x88140103, // 0004 GETMBR R5 R0 K3 - 0x7C0C0400, // 0005 CALL R3 2 - 0x58100004, // 0006 LDCONST R4 K4 - 0x7C040600, // 0007 CALL R1 3 - 0x80000000, // 0008 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: get_pk +** Solidified function: close ********************************************************************/ -be_local_closure(Matter_Session_get_pk, /* name */ +be_local_closure(Matter_Session_close, /* name */ be_nested_proto( - 5, /* nstack */ + 8, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -57,33 +19,93 @@ be_local_closure(Matter_Session_get_pk, /* name */ 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(get_pk), - /* K2 */ be_nested_str_weak(_temp_pk), - /* K3 */ be_nested_str_weak(crypto), - /* K4 */ be_nested_str_weak(random), + ( &(const bvalue[23]) { /* constants */ + /* K0 */ be_nested_str_weak(local_session_id), + /* K1 */ be_nested_str_weak(__future_local_session_id), + /* K2 */ be_nested_str_weak(initiator_session_id), + /* K3 */ be_nested_str_weak(__future_initiator_session_id), + /* K4 */ be_nested_str_weak(_counter_rcv_impl), + /* K5 */ be_nested_str_weak(reset), + /* K6 */ be_nested_str_weak(_counter_snd_impl), + /* K7 */ be_nested_str_weak(counter_rcv), + /* K8 */ be_const_int(0), + /* K9 */ be_nested_str_weak(counter_snd), + /* K10 */ be_nested_str_weak(next), + /* K11 */ be_nested_str_weak(i2rkey), + /* K12 */ be_nested_str_weak(_i2r_privacy), + /* K13 */ be_nested_str_weak(r2ikey), + /* K14 */ be_nested_str_weak(attestation_challenge), + /* 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_nested_str_weak(_), + /* K21 */ be_const_int(1), + /* K22 */ be_nested_str_weak(stop_iteration), }), - be_str_weak(get_pk), + be_str_weak(close), &be_const_str_solidified, - ( &(const binstruction[17]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x78060004, // 0001 JMPF R1 #0007 - 0x88040100, // 0002 GETMBR R1 R0 K0 - 0x8C040301, // 0003 GETMET R1 R1 K1 - 0x7C040200, // 0004 CALL R1 1 - 0x80040200, // 0005 RET 1 R1 - 0x70020008, // 0006 JMP #0010 - 0x88040102, // 0007 GETMBR R1 R0 K2 - 0x74060004, // 0008 JMPT R1 #000E - 0xA4060600, // 0009 IMPORT R1 K3 - 0x8C080304, // 000A GETMET R2 R1 K4 - 0x5412001F, // 000B LDINT R4 32 - 0x7C080400, // 000C CALL R2 2 - 0x90020402, // 000D SETMBR R0 K2 R2 - 0x88040102, // 000E GETMBR R1 R0 K2 - 0x80040200, // 000F RET 1 R1 - 0x80000000, // 0010 RET 0 + ( &(const binstruction[59]) { /* code */ + 0x88040101, // 0000 GETMBR R1 R0 K1 + 0x90020001, // 0001 SETMBR R0 K0 R1 + 0x88040103, // 0002 GETMBR R1 R0 K3 + 0x90020401, // 0003 SETMBR R0 K2 R1 + 0x88040104, // 0004 GETMBR R1 R0 K4 + 0x8C040305, // 0005 GETMET R1 R1 K5 + 0x7C040200, // 0006 CALL R1 1 + 0x88040106, // 0007 GETMBR R1 R0 K6 + 0x8C040305, // 0008 GETMET R1 R1 K5 + 0x7C040200, // 0009 CALL R1 1 + 0x90020F08, // 000A SETMBR R0 K7 K8 + 0x88040106, // 000B GETMBR R1 R0 K6 + 0x8C04030A, // 000C GETMET R1 R1 K10 + 0x7C040200, // 000D CALL R1 1 + 0x90021201, // 000E SETMBR R0 K9 R1 + 0x4C040000, // 000F LDNIL R1 + 0x90021601, // 0010 SETMBR R0 K11 R1 + 0x4C040000, // 0011 LDNIL R1 + 0x90021801, // 0012 SETMBR R0 K12 R1 + 0x4C040000, // 0013 LDNIL R1 + 0x90021A01, // 0014 SETMBR R0 K13 R1 + 0x4C040000, // 0015 LDNIL R1 + 0x90021C01, // 0016 SETMBR R0 K14 R1 + 0xA4061E00, // 0017 IMPORT R1 K15 + 0x60080010, // 0018 GETGBL R2 G16 + 0x8C0C0310, // 0019 GETMET R3 R1 K16 + 0x5C140000, // 001A MOVE R5 R0 + 0x7C0C0400, // 001B CALL R3 2 + 0x7C080200, // 001C CALL R2 1 + 0xA8020018, // 001D EXBLK 0 #0037 + 0x5C0C0400, // 001E MOVE R3 R2 + 0x7C0C0000, // 001F CALL R3 0 + 0x8C100311, // 0020 GETMET R4 R1 K17 + 0x5C180000, // 0021 MOVE R6 R0 + 0x5C1C0600, // 0022 MOVE R7 R3 + 0x7C100600, // 0023 CALL R4 3 + 0x60140004, // 0024 GETGBL R5 G4 + 0x5C180800, // 0025 MOVE R6 R4 + 0x7C140200, // 0026 CALL R5 1 + 0x20140B12, // 0027 NE R5 R5 K18 + 0x7816000C, // 0028 JMPF R5 #0036 + 0x60140004, // 0029 GETGBL R5 G4 + 0x5C180800, // 002A MOVE R6 R4 + 0x7C140200, // 002B CALL R5 1 + 0x20140B13, // 002C NE R5 R5 K19 + 0x78160007, // 002D JMPF R5 #0036 + 0x94140708, // 002E GETIDX R5 R3 K8 + 0x1C140B14, // 002F EQ R5 R5 K20 + 0x78160004, // 0030 JMPF R5 #0036 + 0x94140715, // 0031 GETIDX R5 R3 K21 + 0x1C140B14, // 0032 EQ R5 R5 K20 + 0x78160001, // 0033 JMPF R5 #0036 + 0x4C140000, // 0034 LDNIL R5 + 0x90000605, // 0035 SETMBR R0 R3 R5 + 0x7001FFE6, // 0036 JMP #001E + 0x58080016, // 0037 LDCONST R2 K22 + 0xAC080200, // 0038 CATCH R2 1 0 + 0xB0080000, // 0039 RAISE 2 R0 R0 + 0x80000000, // 003A RET 0 }) ) ); @@ -91,11 +113,11 @@ be_local_closure(Matter_Session_get_pk, /* name */ /******************************************************************** -** Solidified function: set_mode_CASE +** Solidified function: update ********************************************************************/ -be_local_closure(Matter_Session_set_mode_CASE, /* name */ +be_local_closure(Matter_Session_update, /* name */ be_nested_proto( - 4, /* nstack */ + 3, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -103,17 +125,19 @@ be_local_closure(Matter_Session_set_mode_CASE, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(set_mode), - /* K1 */ be_nested_str_weak(_CASE), + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(last_used), + /* K1 */ be_nested_str_weak(tasmota), + /* K2 */ be_nested_str_weak(rtc_utc), }), - be_str_weak(set_mode_CASE), + be_str_weak(update), &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 + ( &(const binstruction[ 5]) { /* code */ + 0xB8060200, // 0000 GETNGBL R1 K1 + 0x8C040302, // 0001 GETMET R1 R1 K2 + 0x7C040200, // 0002 CALL R1 1 + 0x90020001, // 0003 SETMBR R0 K0 R1 + 0x80000000, // 0004 RET 0 }) ) ); @@ -121,9 +145,9 @@ be_local_closure(Matter_Session_set_mode_CASE, /* name */ /******************************************************************** -** Solidified function: get_noc +** Solidified function: get_ac ********************************************************************/ -be_local_closure(Matter_Session_get_noc, /* name */ +be_local_closure(Matter_Session_get_ac, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -133,16 +157,14 @@ be_local_closure(Matter_Session_get_noc, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(noc), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(attestation_challenge), }), - be_str_weak(get_noc), + be_str_weak(get_ac), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ + ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88040301, // 0001 GETMBR R1 R1 K1 - 0x80040200, // 0002 RET 1 R1 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -150,11 +172,11 @@ be_local_closure(Matter_Session_get_noc, /* name */ /******************************************************************** -** Solidified function: get_temp_ca_pub +** Solidified function: get_fabric ********************************************************************/ -be_local_closure(Matter_Session_get_temp_ca_pub, /* name */ +be_local_closure(Matter_Session_get_fabric, /* name */ be_nested_proto( - 6, /* nstack */ + 2, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -162,28 +184,14 @@ be_local_closure(Matter_Session_get_temp_ca_pub, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 5]) { /* constants */ - /* K0 */ be_nested_str_weak(_temp_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), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), }), - be_str_weak(get_temp_ca_pub), + be_str_weak(get_fabric), &be_const_str_solidified, - ( &(const binstruction[12]) { /* code */ + ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x78060008, // 0001 JMPF R1 #000B - 0xB80A0200, // 0002 GETNGBL R2 K1 - 0x88080502, // 0003 GETMBR R2 R2 K2 - 0x8C080503, // 0004 GETMET R2 R2 K3 - 0x5C100200, // 0005 MOVE R4 R1 - 0x7C080400, // 0006 CALL R2 2 - 0x8C0C0504, // 0007 GETMET R3 R2 K4 - 0x54160008, // 0008 LDINT R5 9 - 0x7C0C0400, // 0009 CALL R3 2 - 0x80040600, // 000A RET 1 R3 - 0x80000000, // 000B RET 0 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -191,9 +199,9 @@ be_local_closure(Matter_Session_get_temp_ca_pub, /* name */ /******************************************************************** -** Solidified function: get_fabric_compressed +** Solidified function: get_noc ********************************************************************/ -be_local_closure(Matter_Session_get_fabric_compressed, /* name */ +be_local_closure(Matter_Session_get_noc, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -205,9 +213,9 @@ be_local_closure(Matter_Session_get_fabric_compressed, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(fabric_compressed), + /* K1 */ be_nested_str_weak(noc), }), - be_str_weak(get_fabric_compressed), + be_str_weak(get_noc), &be_const_str_solidified, ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -220,9 +228,9 @@ be_local_closure(Matter_Session_get_fabric_compressed, /* name */ /******************************************************************** -** Solidified function: get_fabric_label +** Solidified function: get_device_id ********************************************************************/ -be_local_closure(Matter_Session_get_fabric_label, /* name */ +be_local_closure(Matter_Session_get_device_id, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -234,14 +242,18 @@ be_local_closure(Matter_Session_get_fabric_label, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(fabric_label), + /* K1 */ be_nested_str_weak(device_id), }), - be_str_weak(get_fabric_label), + be_str_weak(get_device_id), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ + ( &(const binstruction[ 7]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88040301, // 0001 GETMBR R1 R1 K1 - 0x80040200, // 0002 RET 1 R1 + 0x78060002, // 0001 JMPF R1 #0005 + 0x88040100, // 0002 GETMBR R1 R0 K0 + 0x88040301, // 0003 GETMBR R1 R1 K1 + 0x70020000, // 0004 JMP #0006 + 0x4C040000, // 0005 LDNIL R1 + 0x80040200, // 0006 RET 1 R1 }) ) ); @@ -249,95 +261,34 @@ be_local_closure(Matter_Session_get_fabric_label, /* name */ /******************************************************************** -** Solidified function: set_keys +** Solidified function: set_fabric_label ********************************************************************/ -be_local_closure(Matter_Session_set_keys, /* name */ +be_local_closure(Matter_Session_set_fabric_label, /* name */ be_nested_proto( - 6, /* nstack */ - 5, /* argc */ + 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[ 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(created), - }), - 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: set_mode_PASE -********************************************************************/ -be_local_closure(Matter_Session_set_mode_PASE, /* 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(set_mode), - /* K1 */ be_nested_str_weak(_PASE), - }), - be_str_weak(set_mode_PASE), - &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: is_CASE -********************************************************************/ -be_local_closure(Matter_Session_is_CASE, /* 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(mode), - /* K1 */ be_nested_str_weak(_CASE), + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(string), + /* K1 */ be_nested_str_weak(_fabric), + /* K2 */ be_nested_str_weak(fabric_label), }), - be_str_weak(is_CASE), + be_str_weak(set_fabric_label), &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88080101, // 0001 GETMBR R2 R0 K1 - 0x1C040202, // 0002 EQ R1 R1 R2 - 0x80040200, // 0003 RET 1 R1 + ( &(const binstruction[ 8]) { /* code */ + 0x60080004, // 0000 GETGBL R2 G4 + 0x5C0C0200, // 0001 MOVE R3 R1 + 0x7C080200, // 0002 CALL R2 1 + 0x1C080500, // 0003 EQ R2 R2 K0 + 0x780A0001, // 0004 JMPF R2 #0007 + 0x88080101, // 0005 GETMBR R2 R0 K1 + 0x900A0401, // 0006 SETMBR R2 K2 R1 + 0x80000000, // 0007 RET 0 }) ) ); @@ -345,26 +296,35 @@ be_local_closure(Matter_Session_is_CASE, /* name */ /******************************************************************** -** Solidified function: get_mode +** Solidified function: set_keys ********************************************************************/ -be_local_closure(Matter_Session_get_mode, /* 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(mode), + ( &(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(created), }), - be_str_weak(get_mode), + be_str_weak(set_keys), &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 }) ) ); @@ -540,26 +500,115 @@ be_local_closure(Matter_Session_tojson, /* name */ /******************************************************************** -** Solidified function: get_i2r +** Solidified function: fromjson ********************************************************************/ -be_local_closure(Matter_Session_get_i2r, /* name */ +be_local_closure(Matter_Session_fromjson, /* name */ be_nested_proto( - 2, /* nstack */ - 1, /* argc */ - 2, /* varg */ + 17, /* nstack */ + 3, /* argc */ + 4, /* 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), + ( &(const bvalue[17]) { /* 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(find), + /* K7 */ be_nested_str_weak(0x), + /* K8 */ be_const_int(0), + /* K9 */ be_nested_str_weak(set), + /* K10 */ be_nested_str_weak(fromhex), + /* K11 */ be_const_int(2), + /* K12 */ be_const_int(2147483647), + /* K13 */ be_nested_str_weak(_X24_X24), + /* K14 */ be_nested_str_weak(fromb64), + /* K15 */ be_nested_str_weak(stop_iteration), + /* K16 */ be_nested_str_weak(hydrate_post), }), - be_str_weak(get_i2r), + be_str_weak(fromjson), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 + ( &(const binstruction[75]) { /* code */ + 0x580C0000, // 0000 LDCONST R3 K0 + 0xA4120200, // 0001 IMPORT R4 K1 + 0xA4160400, // 0002 IMPORT R5 K2 + 0xB81A0600, // 0003 GETNGBL R6 K3 + 0x8C180D04, // 0004 GETMET R6 R6 K4 + 0x5C200000, // 0005 MOVE R8 R0 + 0x4C240000, // 0006 LDNIL R9 + 0x4C280000, // 0007 LDNIL R10 + 0x5C2C0400, // 0008 MOVE R11 R2 + 0x7C180A00, // 0009 CALL R6 5 + 0x601C0010, // 000A GETGBL R7 G16 + 0x8C200305, // 000B GETMET R8 R1 K5 + 0x7C200200, // 000C CALL R8 1 + 0x7C1C0200, // 000D CALL R7 1 + 0xA8020035, // 000E EXBLK 0 #0045 + 0x5C200E00, // 000F MOVE R8 R7 + 0x7C200000, // 0010 CALL R8 0 + 0x94240208, // 0011 GETIDX R9 R1 R8 + 0x60280004, // 0012 GETGBL R10 G4 + 0x5C2C1200, // 0013 MOVE R11 R9 + 0x7C280200, // 0014 CALL R10 1 + 0x1C281501, // 0015 EQ R10 R10 K1 + 0x782A0027, // 0016 JMPF R10 #003F + 0x8C280906, // 0017 GETMET R10 R4 K6 + 0x5C301200, // 0018 MOVE R12 R9 + 0x58340007, // 0019 LDCONST R13 K7 + 0x7C280600, // 001A CALL R10 3 + 0x1C281508, // 001B EQ R10 R10 K8 + 0x782A000A, // 001C JMPF R10 #0028 + 0x8C280B09, // 001D GETMET R10 R5 K9 + 0x5C300C00, // 001E MOVE R12 R6 + 0x5C341000, // 001F MOVE R13 R8 + 0x60380015, // 0020 GETGBL R14 G21 + 0x7C380000, // 0021 CALL R14 0 + 0x8C381D0A, // 0022 GETMET R14 R14 K10 + 0x4042170C, // 0023 CONNECT R16 K11 K12 + 0x94401210, // 0024 GETIDX R16 R9 R16 + 0x7C380400, // 0025 CALL R14 2 + 0x7C280800, // 0026 CALL R10 4 + 0x70020015, // 0027 JMP #003E + 0x8C280906, // 0028 GETMET R10 R4 K6 + 0x5C301200, // 0029 MOVE R12 R9 + 0x5834000D, // 002A LDCONST R13 K13 + 0x7C280600, // 002B CALL R10 3 + 0x1C281508, // 002C EQ R10 R10 K8 + 0x782A000A, // 002D JMPF R10 #0039 + 0x8C280B09, // 002E GETMET R10 R5 K9 + 0x5C300C00, // 002F MOVE R12 R6 + 0x5C341000, // 0030 MOVE R13 R8 + 0x60380015, // 0031 GETGBL R14 G21 + 0x7C380000, // 0032 CALL R14 0 + 0x8C381D0E, // 0033 GETMET R14 R14 K14 + 0x4042170C, // 0034 CONNECT R16 K11 K12 + 0x94401210, // 0035 GETIDX R16 R9 R16 + 0x7C380400, // 0036 CALL R14 2 + 0x7C280800, // 0037 CALL R10 4 + 0x70020004, // 0038 JMP #003E + 0x8C280B09, // 0039 GETMET R10 R5 K9 + 0x5C300C00, // 003A MOVE R12 R6 + 0x5C341000, // 003B MOVE R13 R8 + 0x5C381200, // 003C MOVE R14 R9 + 0x7C280800, // 003D CALL R10 4 + 0x70020004, // 003E JMP #0044 + 0x8C280B09, // 003F GETMET R10 R5 K9 + 0x5C300C00, // 0040 MOVE R12 R6 + 0x5C341000, // 0041 MOVE R13 R8 + 0x5C381200, // 0042 MOVE R14 R9 + 0x7C280800, // 0043 CALL R10 4 + 0x7001FFC9, // 0044 JMP #000F + 0x581C000F, // 0045 LDCONST R7 K15 + 0xAC1C0200, // 0046 CATCH R7 1 0 + 0xB0080000, // 0047 RAISE 2 R0 R0 + 0x8C1C0D10, // 0048 GETMET R7 R6 K16 + 0x7C1C0200, // 0049 CALL R7 1 + 0x80040C00, // 004A RET 1 R6 }) ) ); @@ -567,11 +616,11 @@ be_local_closure(Matter_Session_get_i2r, /* name */ /******************************************************************** -** Solidified function: is_PASE +** Solidified function: gen_CSR ********************************************************************/ -be_local_closure(Matter_Session_is_PASE, /* name */ +be_local_closure(Matter_Session_gen_CSR, /* name */ be_nested_proto( - 3, /* nstack */ + 15, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -579,51 +628,21 @@ be_local_closure(Matter_Session_is_PASE, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(mode), - /* K1 */ be_nested_str_weak(_PASE), + ( &(const bvalue[12]) { /* constants */ + /* K0 */ be_nested_str_weak(get_pk), + /* K1 */ be_nested_str_weak(crypto), + /* K2 */ be_nested_str_weak(EC_P256), + /* K3 */ be_nested_str_weak(public_key), + /* K4 */ be_nested_str_weak(3070020100300E310C300A060355040A0C034353523059301306072A8648CE3D020106082A8648CE3D030107034200), + /* K5 */ be_nested_str_weak(A000), + /* K6 */ be_nested_str_weak(300C06082A8648CE3D0403020500), + /* K7 */ be_nested_str_weak(ecdsa_sign_sha256_asn1), + /* K8 */ be_nested_str_weak(add), + /* K9 */ be_const_int(3), + /* K10 */ be_const_int(1), + /* K11 */ be_const_int(0), }), - be_str_weak(is_PASE), - &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88080101, // 0001 GETMBR R2 R0 K1 - 0x1C040202, // 0002 EQ R1 R1 R2 - 0x80040200, // 0003 RET 1 R1 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: gen_CSR -********************************************************************/ -be_local_closure(Matter_Session_gen_CSR, /* name */ - be_nested_proto( - 15, /* 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(get_pk), - /* K1 */ be_nested_str_weak(crypto), - /* K2 */ be_nested_str_weak(EC_P256), - /* K3 */ be_nested_str_weak(public_key), - /* K4 */ be_nested_str_weak(3070020100300E310C300A060355040A0C034353523059301306072A8648CE3D020106082A8648CE3D030107034200), - /* K5 */ be_nested_str_weak(A000), - /* K6 */ be_nested_str_weak(300C06082A8648CE3D0403020500), - /* K7 */ be_nested_str_weak(ecdsa_sign_sha256_asn1), - /* K8 */ be_nested_str_weak(add), - /* K9 */ be_const_int(3), - /* K10 */ be_const_int(1), - /* K11 */ be_const_int(0), - }), - be_str_weak(gen_CSR), + be_str_weak(gen_CSR), &be_const_str_solidified, ( &(const binstruction[73]) { /* code */ 0x8C040100, // 0000 GETMET R1 R0 K0 @@ -706,9 +725,9 @@ be_local_closure(Matter_Session_gen_CSR, /* name */ /******************************************************************** -** Solidified function: get_temp_ca +** Solidified function: get_ipk_epoch_key ********************************************************************/ -be_local_closure(Matter_Session_get_temp_ca, /* name */ +be_local_closure(Matter_Session_get_ipk_epoch_key, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -718,14 +737,16 @@ be_local_closure(Matter_Session_get_temp_ca, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(_temp_root_ca_certificate), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(ipk_epoch_key), }), - be_str_weak(get_temp_ca), + be_str_weak(get_ipk_epoch_key), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ + ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 + 0x88040301, // 0001 GETMBR R1 R1 K1 + 0x80040200, // 0002 RET 1 R1 }) ) ); @@ -733,105 +754,38 @@ be_local_closure(Matter_Session_get_temp_ca, /* name */ /******************************************************************** -** Solidified function: close +** Solidified function: counter_rcv_validate ********************************************************************/ -be_local_closure(Matter_Session_close, /* name */ +be_local_closure(Matter_Session_counter_rcv_validate, /* name */ be_nested_proto( - 8, /* nstack */ - 1, /* argc */ + 7, /* 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_nested_str_weak(local_session_id), - /* K1 */ be_nested_str_weak(__future_local_session_id), - /* K2 */ be_nested_str_weak(initiator_session_id), - /* K3 */ be_nested_str_weak(__future_initiator_session_id), - /* K4 */ be_nested_str_weak(_counter_rcv_impl), - /* K5 */ be_nested_str_weak(reset), - /* K6 */ be_nested_str_weak(_counter_snd_impl), - /* K7 */ be_nested_str_weak(counter_rcv), - /* K8 */ be_const_int(0), - /* K9 */ be_nested_str_weak(counter_snd), - /* K10 */ be_nested_str_weak(next), - /* K11 */ be_nested_str_weak(i2rkey), - /* K12 */ be_nested_str_weak(_i2r_privacy), - /* K13 */ be_nested_str_weak(r2ikey), - /* K14 */ be_nested_str_weak(attestation_challenge), - /* 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_nested_str_weak(_), - /* K21 */ be_const_int(1), - /* K22 */ be_nested_str_weak(stop_iteration), + ( &(const bvalue[ 4]) { /* constants */ + /* K0 */ be_nested_str_weak(_counter_rcv_impl), + /* K1 */ be_nested_str_weak(validate), + /* K2 */ be_nested_str_weak(counter_rcv), + /* K3 */ be_nested_str_weak(val), }), - be_str_weak(close), + be_str_weak(counter_rcv_validate), &be_const_str_solidified, - ( &(const binstruction[59]) { /* code */ - 0x88040101, // 0000 GETMBR R1 R0 K1 - 0x90020001, // 0001 SETMBR R0 K0 R1 - 0x88040103, // 0002 GETMBR R1 R0 K3 - 0x90020401, // 0003 SETMBR R0 K2 R1 - 0x88040104, // 0004 GETMBR R1 R0 K4 - 0x8C040305, // 0005 GETMET R1 R1 K5 - 0x7C040200, // 0006 CALL R1 1 - 0x88040106, // 0007 GETMBR R1 R0 K6 - 0x8C040305, // 0008 GETMET R1 R1 K5 - 0x7C040200, // 0009 CALL R1 1 - 0x90020F08, // 000A SETMBR R0 K7 K8 - 0x88040106, // 000B GETMBR R1 R0 K6 - 0x8C04030A, // 000C GETMET R1 R1 K10 - 0x7C040200, // 000D CALL R1 1 - 0x90021201, // 000E SETMBR R0 K9 R1 - 0x4C040000, // 000F LDNIL R1 - 0x90021601, // 0010 SETMBR R0 K11 R1 - 0x4C040000, // 0011 LDNIL R1 - 0x90021801, // 0012 SETMBR R0 K12 R1 - 0x4C040000, // 0013 LDNIL R1 - 0x90021A01, // 0014 SETMBR R0 K13 R1 - 0x4C040000, // 0015 LDNIL R1 - 0x90021C01, // 0016 SETMBR R0 K14 R1 - 0xA4061E00, // 0017 IMPORT R1 K15 - 0x60080010, // 0018 GETGBL R2 G16 - 0x8C0C0310, // 0019 GETMET R3 R1 K16 - 0x5C140000, // 001A MOVE R5 R0 - 0x7C0C0400, // 001B CALL R3 2 - 0x7C080200, // 001C CALL R2 1 - 0xA8020018, // 001D EXBLK 0 #0037 - 0x5C0C0400, // 001E MOVE R3 R2 - 0x7C0C0000, // 001F CALL R3 0 - 0x8C100311, // 0020 GETMET R4 R1 K17 - 0x5C180000, // 0021 MOVE R6 R0 - 0x5C1C0600, // 0022 MOVE R7 R3 - 0x7C100600, // 0023 CALL R4 3 - 0x60140004, // 0024 GETGBL R5 G4 - 0x5C180800, // 0025 MOVE R6 R4 - 0x7C140200, // 0026 CALL R5 1 - 0x20140B12, // 0027 NE R5 R5 K18 - 0x7816000C, // 0028 JMPF R5 #0036 - 0x60140004, // 0029 GETGBL R5 G4 - 0x5C180800, // 002A MOVE R6 R4 - 0x7C140200, // 002B CALL R5 1 - 0x20140B13, // 002C NE R5 R5 K19 - 0x78160007, // 002D JMPF R5 #0036 - 0x94140708, // 002E GETIDX R5 R3 K8 - 0x1C140B14, // 002F EQ R5 R5 K20 - 0x78160004, // 0030 JMPF R5 #0036 - 0x94140715, // 0031 GETIDX R5 R3 K21 - 0x1C140B14, // 0032 EQ R5 R5 K20 - 0x78160001, // 0033 JMPF R5 #0036 - 0x4C140000, // 0034 LDNIL R5 - 0x90000605, // 0035 SETMBR R0 R3 R5 - 0x7001FFE6, // 0036 JMP #001E - 0x58080016, // 0037 LDCONST R2 K22 - 0xAC080200, // 0038 CATCH R2 1 0 - 0xB0080000, // 0039 RAISE 2 R0 R0 - 0x80000000, // 003A RET 0 + ( &(const binstruction[11]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x8C0C0701, // 0001 GETMET R3 R3 K1 + 0x5C140200, // 0002 MOVE R5 R1 + 0x5C180400, // 0003 MOVE R6 R2 + 0x7C0C0600, // 0004 CALL R3 3 + 0x780E0003, // 0005 JMPF R3 #000A + 0x88100100, // 0006 GETMBR R4 R0 K0 + 0x8C100903, // 0007 GETMET R4 R4 K3 + 0x7C100200, // 0008 CALL R4 1 + 0x90020404, // 0009 SETMBR R0 K2 R4 + 0x80040600, // 000A RET 1 R3 }) ) ); @@ -839,11 +793,11 @@ be_local_closure(Matter_Session_close, /* name */ /******************************************************************** -** Solidified function: update +** Solidified function: get_admin_subject ********************************************************************/ -be_local_closure(Matter_Session_update, /* name */ +be_local_closure(Matter_Session_get_admin_subject, /* name */ be_nested_proto( - 3, /* nstack */ + 2, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -851,19 +805,16 @@ be_local_closure(Matter_Session_update, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(last_used), - /* K1 */ be_nested_str_weak(tasmota), - /* K2 */ be_nested_str_weak(rtc_utc), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(admin_subject), }), - be_str_weak(update), + be_str_weak(get_admin_subject), &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0xB8060200, // 0000 GETNGBL R1 K1 - 0x8C040302, // 0001 GETMET R1 R1 K2 - 0x7C040200, // 0002 CALL R1 1 - 0x90020001, // 0003 SETMBR R0 K0 R1 - 0x80000000, // 0004 RET 0 + ( &(const binstruction[ 3]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x88040301, // 0001 GETMBR R1 R1 K1 + 0x80040200, // 0002 RET 1 R1 }) ) ); @@ -871,9 +822,9 @@ be_local_closure(Matter_Session_update, /* name */ /******************************************************************** -** Solidified function: get_admin_vendor +** Solidified function: get_fabric_compressed ********************************************************************/ -be_local_closure(Matter_Session_get_admin_vendor, /* name */ +be_local_closure(Matter_Session_get_fabric_compressed, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -885,9 +836,9 @@ be_local_closure(Matter_Session_get_admin_vendor, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(admin_vendor), + /* K1 */ be_nested_str_weak(fabric_compressed), }), - be_str_weak(get_admin_vendor), + be_str_weak(get_fabric_compressed), &be_const_str_solidified, ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -900,11 +851,11 @@ be_local_closure(Matter_Session_get_admin_vendor, /* name */ /******************************************************************** -** Solidified function: get_fabric +** Solidified function: persist_to_fabric ********************************************************************/ -be_local_closure(Matter_Session_get_fabric, /* name */ +be_local_closure(Matter_Session_persist_to_fabric, /* name */ be_nested_proto( - 2, /* nstack */ + 4, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -912,14 +863,18 @@ be_local_closure(Matter_Session_get_fabric, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ + ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(add_session), }), - be_str_weak(get_fabric), + be_str_weak(persist_to_fabric), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ + ( &(const binstruction[ 5]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x5C0C0000, // 0002 MOVE R3 R0 + 0x7C040400, // 0003 CALL R1 2 + 0x80000000, // 0004 RET 0 }) ) ); @@ -927,9 +882,9 @@ be_local_closure(Matter_Session_get_fabric, /* name */ /******************************************************************** -** Solidified function: get_admin_subject +** Solidified function: get_ca ********************************************************************/ -be_local_closure(Matter_Session_get_admin_subject, /* name */ +be_local_closure(Matter_Session_get_ca, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -941,9 +896,9 @@ be_local_closure(Matter_Session_get_admin_subject, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(admin_subject), + /* K1 */ be_nested_str_weak(root_ca_certificate), }), - be_str_weak(get_admin_subject), + be_str_weak(get_ca), &be_const_str_solidified, ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -956,9 +911,9 @@ be_local_closure(Matter_Session_get_admin_subject, /* name */ /******************************************************************** -** Solidified function: get_ipk_group_key +** Solidified function: is_PASE ********************************************************************/ -be_local_closure(Matter_Session_get_ipk_group_key, /* name */ +be_local_closure(Matter_Session_is_PASE, /* name */ be_nested_proto( 3, /* nstack */ 1, /* argc */ @@ -969,15 +924,15 @@ be_local_closure(Matter_Session_get_ipk_group_key, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(get_ipk_group_key), + /* K0 */ be_nested_str_weak(mode), + /* K1 */ be_nested_str_weak(_PASE), }), - be_str_weak(get_ipk_group_key), + be_str_weak(is_PASE), &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 + 0x88080101, // 0001 GETMBR R2 R0 K1 + 0x1C040202, // 0002 EQ R1 R1 R2 0x80040200, // 0003 RET 1 R1 }) ) @@ -986,87 +941,29 @@ be_local_closure(Matter_Session_get_ipk_group_key, /* name */ /******************************************************************** -** Solidified function: init +** Solidified function: is_CASE ********************************************************************/ -be_local_closure(Matter_Session_init, /* name */ +be_local_closure(Matter_Session_is_CASE, /* name */ be_nested_proto( - 10, /* nstack */ - 5, /* argc */ + 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[23]) { /* 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_snd_impl), - /* K7 */ be_nested_str_weak(matter), - /* K8 */ be_nested_str_weak(Counter), - /* K9 */ be_nested_str_weak(_counter_rcv_impl), - /* K10 */ be_nested_str_weak(counter_rcv), - /* K11 */ be_nested_str_weak(counter_snd), - /* K12 */ be_nested_str_weak(next), - /* K13 */ be_nested_str_weak(_COUNTER_SND_INCR), - /* K14 */ be_nested_str_weak(_counter_insecure_rcv), - /* K15 */ be_nested_str_weak(_counter_insecure_snd), - /* K16 */ be_nested_str_weak(_breadcrumb), - /* K17 */ be_nested_str_weak(_exchange_id), - /* K18 */ be_nested_str_weak(random), - /* K19 */ be_const_int(2), - /* K20 */ be_nested_str_weak(get), - /* K21 */ be_nested_str_weak(_fabric), - /* K22 */ be_nested_str_weak(update), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(mode), + /* K1 */ be_nested_str_weak(_CASE), }), - be_str_weak(init), + be_str_weak(is_CASE), &be_const_str_solidified, - ( &(const binstruction[41]) { /* code */ - 0xA4160000, // 0000 IMPORT R5 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 - 0xB81A0E00, // 0005 GETNGBL R6 K7 - 0x8C180D08, // 0006 GETMET R6 R6 K8 - 0x7C180200, // 0007 CALL R6 1 - 0x90020C06, // 0008 SETMBR R0 K6 R6 - 0xB81A0E00, // 0009 GETNGBL R6 K7 - 0x8C180D08, // 000A GETMET R6 R6 K8 - 0x7C180200, // 000B CALL R6 1 - 0x90021206, // 000C SETMBR R0 K9 R6 - 0x90021503, // 000D SETMBR R0 K10 K3 - 0x88180106, // 000E GETMBR R6 R0 K6 - 0x8C180D0C, // 000F GETMET R6 R6 K12 - 0x7C180200, // 0010 CALL R6 1 - 0x881C010D, // 0011 GETMBR R7 R0 K13 - 0x00180C07, // 0012 ADD R6 R6 R7 - 0x90021606, // 0013 SETMBR R0 K11 R6 - 0xB81A0E00, // 0014 GETNGBL R6 K7 - 0x8C180D08, // 0015 GETMET R6 R6 K8 - 0x7C180200, // 0016 CALL R6 1 - 0x90021C06, // 0017 SETMBR R0 K14 R6 - 0xB81A0E00, // 0018 GETNGBL R6 K7 - 0x8C180D08, // 0019 GETMET R6 R6 K8 - 0x7C180200, // 001A CALL R6 1 - 0x90021E06, // 001B SETMBR R0 K15 R6 - 0x90022103, // 001C SETMBR R0 K16 K3 - 0x8C180B12, // 001D GETMET R6 R5 K18 - 0x58200013, // 001E LDCONST R8 K19 - 0x7C180400, // 001F CALL R6 2 - 0x8C180D14, // 0020 GETMET R6 R6 K20 - 0x58200003, // 0021 LDCONST R8 K3 - 0x58240013, // 0022 LDCONST R9 K19 - 0x7C180600, // 0023 CALL R6 3 - 0x90022206, // 0024 SETMBR R0 K17 R6 - 0x90022A04, // 0025 SETMBR R0 K21 R4 - 0x8C180116, // 0026 GETMET R6 R0 K22 - 0x7C180200, // 0027 CALL R6 1 - 0x80000000, // 0028 RET 0 + ( &(const binstruction[ 4]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x88080101, // 0001 GETMBR R2 R0 K1 + 0x1C040202, // 0002 EQ R1 R1 R2 + 0x80040200, // 0003 RET 1 R1 }) ) ); @@ -1074,9 +971,77 @@ be_local_closure(Matter_Session_init, /* name */ /******************************************************************** -** Solidified function: get_device_id +** Solidified function: before_remove ********************************************************************/ -be_local_closure(Matter_Session_get_device_id, /* name */ +be_local_closure(Matter_Session_before_remove, /* 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[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(tasmota), + /* K1 */ be_nested_str_weak(log), + /* K2 */ be_nested_str_weak(MTR_X3A_X20_X2DSession_X20_X20_X20_X28_X256i_X29_X20_X28removed_X29), + /* K3 */ be_nested_str_weak(local_session_id), + /* K4 */ be_const_int(3), + }), + be_str_weak(before_remove), + &be_const_str_solidified, + ( &(const binstruction[ 9]) { /* code */ + 0xB8060000, // 0000 GETNGBL R1 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x600C0018, // 0002 GETGBL R3 G24 + 0x58100002, // 0003 LDCONST R4 K2 + 0x88140103, // 0004 GETMBR R5 R0 K3 + 0x7C0C0400, // 0005 CALL R3 2 + 0x58100004, // 0006 LDCONST R4 K4 + 0x7C040600, // 0007 CALL R1 3 + 0x80000000, // 0008 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** 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_fabrics), + }), + 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_id +********************************************************************/ +be_local_closure(Matter_Session_get_fabric_id, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -1088,9 +1053,9 @@ be_local_closure(Matter_Session_get_device_id, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(device_id), + /* K1 */ be_nested_str_weak(fabric_id), }), - be_str_weak(get_device_id), + be_str_weak(get_fabric_id), &be_const_str_solidified, ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -1103,34 +1068,29 @@ be_local_closure(Matter_Session_get_device_id, /* name */ /******************************************************************** -** Solidified function: set_fabric_label +** Solidified function: get_ipk_group_key ********************************************************************/ -be_local_closure(Matter_Session_set_fabric_label, /* name */ +be_local_closure(Matter_Session_get_ipk_group_key, /* name */ be_nested_proto( - 4, /* nstack */ - 2, /* argc */ + 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(string), - /* K1 */ be_nested_str_weak(_fabric), - /* K2 */ be_nested_str_weak(fabric_label), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(get_ipk_group_key), }), - be_str_weak(set_fabric_label), + be_str_weak(get_ipk_group_key), &be_const_str_solidified, - ( &(const binstruction[ 8]) { /* code */ - 0x60080004, // 0000 GETGBL R2 G4 - 0x5C0C0200, // 0001 MOVE R3 R1 - 0x7C080200, // 0002 CALL R2 1 - 0x1C080500, // 0003 EQ R2 R2 K0 - 0x780A0001, // 0004 JMPF R2 #0007 - 0x88080101, // 0005 GETMBR R2 R0 K1 - 0x900A0401, // 0006 SETMBR R2 K2 R1 - 0x80000000, // 0007 RET 0 + ( &(const binstruction[ 4]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0x80040200, // 0003 RET 1 R1 }) ) ); @@ -1138,11 +1098,11 @@ be_local_closure(Matter_Session_set_fabric_label, /* name */ /******************************************************************** -** Solidified function: hydrate_post +** Solidified function: get_temp_ca_pub ********************************************************************/ -be_local_closure(Matter_Session_hydrate_post, /* name */ +be_local_closure(Matter_Session_get_temp_ca_pub, /* name */ be_nested_proto( - 4, /* nstack */ + 6, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1150,34 +1110,28 @@ be_local_closure(Matter_Session_hydrate_post, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 6]) { /* constants */ - /* K0 */ be_nested_str_weak(_counter_snd_impl), - /* K1 */ be_nested_str_weak(reset), - /* K2 */ be_nested_str_weak(counter_snd), - /* K3 */ be_nested_str_weak(_counter_rcv_impl), - /* K4 */ be_nested_str_weak(counter_rcv), - /* K5 */ be_nested_str_weak(val), + ( &(const bvalue[ 5]) { /* constants */ + /* K0 */ be_nested_str_weak(_temp_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(hydrate_post), + be_str_weak(get_temp_ca_pub), &be_const_str_solidified, - ( &(const binstruction[17]) { /* code */ + ( &(const binstruction[12]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x880C0102, // 0002 GETMBR R3 R0 K2 - 0x7C040400, // 0003 CALL R1 2 - 0x88040103, // 0004 GETMBR R1 R0 K3 - 0x8C040301, // 0005 GETMET R1 R1 K1 - 0x880C0104, // 0006 GETMBR R3 R0 K4 - 0x7C040400, // 0007 CALL R1 2 - 0x88040100, // 0008 GETMBR R1 R0 K0 - 0x8C040305, // 0009 GETMET R1 R1 K5 - 0x7C040200, // 000A CALL R1 1 - 0x90020401, // 000B SETMBR R0 K2 R1 - 0x88040103, // 000C GETMBR R1 R0 K3 - 0x8C040305, // 000D GETMET R1 R1 K5 - 0x7C040200, // 000E CALL R1 1 - 0x90020801, // 000F SETMBR R0 K4 R1 - 0x80000000, // 0010 RET 0 + 0x78060008, // 0001 JMPF R1 #000B + 0xB80A0200, // 0002 GETNGBL R2 K1 + 0x88080502, // 0003 GETMBR R2 R2 K2 + 0x8C080503, // 0004 GETMET R2 R2 K3 + 0x5C100200, // 0005 MOVE R4 R1 + 0x7C080400, // 0006 CALL R2 2 + 0x8C0C0504, // 0007 GETMET R3 R2 K4 + 0x54160008, // 0008 LDINT R5 9 + 0x7C0C0400, // 0009 CALL R3 2 + 0x80040600, // 000A RET 1 R3 + 0x80000000, // 000B RET 0 }) ) ); @@ -1185,115 +1139,29 @@ be_local_closure(Matter_Session_hydrate_post, /* name */ /******************************************************************** -** Solidified function: fromjson +** Solidified function: get_ca_pub ********************************************************************/ -be_local_closure(Matter_Session_fromjson, /* name */ +be_local_closure(Matter_Session_get_ca_pub, /* name */ be_nested_proto( - 17, /* nstack */ - 3, /* argc */ - 4, /* varg */ + 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[17]) { /* 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(find), - /* K7 */ be_nested_str_weak(0x), - /* K8 */ be_const_int(0), - /* K9 */ be_nested_str_weak(set), - /* K10 */ be_nested_str_weak(fromhex), - /* K11 */ be_const_int(2), - /* K12 */ be_const_int(2147483647), - /* K13 */ be_nested_str_weak(_X24_X24), - /* K14 */ be_nested_str_weak(fromb64), - /* K15 */ be_nested_str_weak(stop_iteration), - /* K16 */ be_nested_str_weak(hydrate_post), - }), - be_str_weak(fromjson), - &be_const_str_solidified, - ( &(const binstruction[75]) { /* code */ - 0x580C0000, // 0000 LDCONST R3 K0 - 0xA4120200, // 0001 IMPORT R4 K1 - 0xA4160400, // 0002 IMPORT R5 K2 - 0xB81A0600, // 0003 GETNGBL R6 K3 - 0x8C180D04, // 0004 GETMET R6 R6 K4 - 0x5C200000, // 0005 MOVE R8 R0 - 0x4C240000, // 0006 LDNIL R9 - 0x4C280000, // 0007 LDNIL R10 - 0x5C2C0400, // 0008 MOVE R11 R2 - 0x7C180A00, // 0009 CALL R6 5 - 0x601C0010, // 000A GETGBL R7 G16 - 0x8C200305, // 000B GETMET R8 R1 K5 - 0x7C200200, // 000C CALL R8 1 - 0x7C1C0200, // 000D CALL R7 1 - 0xA8020035, // 000E EXBLK 0 #0045 - 0x5C200E00, // 000F MOVE R8 R7 - 0x7C200000, // 0010 CALL R8 0 - 0x94240208, // 0011 GETIDX R9 R1 R8 - 0x60280004, // 0012 GETGBL R10 G4 - 0x5C2C1200, // 0013 MOVE R11 R9 - 0x7C280200, // 0014 CALL R10 1 - 0x1C281501, // 0015 EQ R10 R10 K1 - 0x782A0027, // 0016 JMPF R10 #003F - 0x8C280906, // 0017 GETMET R10 R4 K6 - 0x5C301200, // 0018 MOVE R12 R9 - 0x58340007, // 0019 LDCONST R13 K7 - 0x7C280600, // 001A CALL R10 3 - 0x1C281508, // 001B EQ R10 R10 K8 - 0x782A000A, // 001C JMPF R10 #0028 - 0x8C280B09, // 001D GETMET R10 R5 K9 - 0x5C300C00, // 001E MOVE R12 R6 - 0x5C341000, // 001F MOVE R13 R8 - 0x60380015, // 0020 GETGBL R14 G21 - 0x7C380000, // 0021 CALL R14 0 - 0x8C381D0A, // 0022 GETMET R14 R14 K10 - 0x4042170C, // 0023 CONNECT R16 K11 K12 - 0x94401210, // 0024 GETIDX R16 R9 R16 - 0x7C380400, // 0025 CALL R14 2 - 0x7C280800, // 0026 CALL R10 4 - 0x70020015, // 0027 JMP #003E - 0x8C280906, // 0028 GETMET R10 R4 K6 - 0x5C301200, // 0029 MOVE R12 R9 - 0x5834000D, // 002A LDCONST R13 K13 - 0x7C280600, // 002B CALL R10 3 - 0x1C281508, // 002C EQ R10 R10 K8 - 0x782A000A, // 002D JMPF R10 #0039 - 0x8C280B09, // 002E GETMET R10 R5 K9 - 0x5C300C00, // 002F MOVE R12 R6 - 0x5C341000, // 0030 MOVE R13 R8 - 0x60380015, // 0031 GETGBL R14 G21 - 0x7C380000, // 0032 CALL R14 0 - 0x8C381D0E, // 0033 GETMET R14 R14 K14 - 0x4042170C, // 0034 CONNECT R16 K11 K12 - 0x94401210, // 0035 GETIDX R16 R9 R16 - 0x7C380400, // 0036 CALL R14 2 - 0x7C280800, // 0037 CALL R10 4 - 0x70020004, // 0038 JMP #003E - 0x8C280B09, // 0039 GETMET R10 R5 K9 - 0x5C300C00, // 003A MOVE R12 R6 - 0x5C341000, // 003B MOVE R13 R8 - 0x5C381200, // 003C MOVE R14 R9 - 0x7C280800, // 003D CALL R10 4 - 0x70020004, // 003E JMP #0044 - 0x8C280B09, // 003F GETMET R10 R5 K9 - 0x5C300C00, // 0040 MOVE R12 R6 - 0x5C341000, // 0041 MOVE R13 R8 - 0x5C381200, // 0042 MOVE R14 R9 - 0x7C280800, // 0043 CALL R10 4 - 0x7001FFC9, // 0044 JMP #000F - 0x581C000F, // 0045 LDCONST R7 K15 - 0xAC1C0200, // 0046 CATCH R7 1 0 - 0xB0080000, // 0047 RAISE 2 R0 R0 - 0x8C1C0D10, // 0048 GETMET R7 R6 K16 - 0x7C1C0200, // 0049 CALL R7 1 - 0x80040C00, // 004A RET 1 R6 + 1, /* has constants */ + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(get_ca_pub), + }), + be_str_weak(get_ca_pub), + &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 + 0x80040200, // 0003 RET 1 R1 }) ) ); @@ -1301,11 +1169,11 @@ be_local_closure(Matter_Session_fromjson, /* name */ /******************************************************************** -** Solidified function: save +** Solidified function: get_mode ********************************************************************/ -be_local_closure(Matter_Session_save, /* name */ +be_local_closure(Matter_Session_get_mode, /* name */ be_nested_proto( - 3, /* nstack */ + 2, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1313,17 +1181,61 @@ be_local_closure(Matter_Session_save, /* name */ 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_fabrics), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(mode), }), - be_str_weak(save), + be_str_weak(get_mode), &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ + ( &(const binstruction[ 2]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x80040200, // 0001 RET 1 R1 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: hydrate_post +********************************************************************/ +be_local_closure(Matter_Session_hydrate_post, /* 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[ 6]) { /* constants */ + /* K0 */ be_nested_str_weak(_counter_snd_impl), + /* K1 */ be_nested_str_weak(reset), + /* K2 */ be_nested_str_weak(counter_snd), + /* K3 */ be_nested_str_weak(_counter_rcv_impl), + /* K4 */ be_nested_str_weak(counter_rcv), + /* K5 */ be_nested_str_weak(val), + }), + be_str_weak(hydrate_post), + &be_const_str_solidified, + ( &(const binstruction[17]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x7C040200, // 0002 CALL R1 1 - 0x80000000, // 0003 RET 0 + 0x880C0102, // 0002 GETMBR R3 R0 K2 + 0x7C040400, // 0003 CALL R1 2 + 0x88040103, // 0004 GETMBR R1 R0 K3 + 0x8C040301, // 0005 GETMET R1 R1 K1 + 0x880C0104, // 0006 GETMBR R3 R0 K4 + 0x7C040400, // 0007 CALL R1 2 + 0x88040100, // 0008 GETMBR R1 R0 K0 + 0x8C040305, // 0009 GETMET R1 R1 K5 + 0x7C040200, // 000A CALL R1 1 + 0x90020401, // 000B SETMBR R0 K2 R1 + 0x88040103, // 000C GETMBR R1 R0 K3 + 0x8C040305, // 000D GETMET R1 R1 K5 + 0x7C040200, // 000E CALL R1 1 + 0x90020801, // 000F SETMBR R0 K4 R1 + 0x80000000, // 0010 RET 0 }) ) ); @@ -1331,9 +1243,9 @@ be_local_closure(Matter_Session_save, /* name */ /******************************************************************** -** Solidified function: get_fabric_id +** Solidified function: get_fabric_label ********************************************************************/ -be_local_closure(Matter_Session_get_fabric_id, /* name */ +be_local_closure(Matter_Session_get_fabric_label, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -1345,9 +1257,9 @@ be_local_closure(Matter_Session_get_fabric_id, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(fabric_id), + /* K1 */ be_nested_str_weak(fabric_label), }), - be_str_weak(get_fabric_id), + be_str_weak(get_fabric_label), &be_const_str_solidified, ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 @@ -1360,26 +1272,28 @@ be_local_closure(Matter_Session_get_fabric_id, /* name */ /******************************************************************** -** Solidified function: set_mode +** Solidified function: get_icac ********************************************************************/ -be_local_closure(Matter_Session_set_mode, /* name */ +be_local_closure(Matter_Session_get_icac, /* name */ be_nested_proto( 2, /* nstack */ - 2, /* argc */ + 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(mode), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(icac), }), - be_str_weak(set_mode), + be_str_weak(get_icac), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 + ( &(const binstruction[ 3]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x88040301, // 0001 GETMBR R1 R1 K1 + 0x80040200, // 0002 RET 1 R1 }) ) ); @@ -1387,26 +1301,81 @@ be_local_closure(Matter_Session_set_mode, /* name */ /******************************************************************** -** Solidified function: set_temp_ca +** Solidified function: set_mode_CASE ********************************************************************/ -be_local_closure(Matter_Session_set_temp_ca, /* name */ +be_local_closure(Matter_Session_set_mode_CASE, /* name */ be_nested_proto( - 2, /* nstack */ - 2, /* argc */ + 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[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(_temp_root_ca_certificate), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(set_mode), + /* K1 */ be_nested_str_weak(_CASE), }), - be_str_weak(set_temp_ca), + be_str_weak(set_mode_CASE), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 + ( &(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: counter_snd_next +********************************************************************/ +be_local_closure(Matter_Session_counter_snd_next, /* 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_nested_str_weak(_counter_snd_impl), + /* K1 */ be_nested_str_weak(next), + /* K2 */ be_nested_str_weak(matter), + /* K3 */ be_nested_str_weak(Counter), + /* K4 */ be_nested_str_weak(is_greater), + /* K5 */ be_nested_str_weak(counter_snd), + /* K6 */ be_nested_str_weak(_COUNTER_SND_INCR), + /* K7 */ be_nested_str_weak(does_persist), + /* K8 */ be_nested_str_weak(save), + }), + be_str_weak(counter_snd_next), + &be_const_str_solidified, + ( &(const binstruction[19]) { /* code */ + 0x88040100, // 0000 GETMBR R1 R0 K0 + 0x8C040301, // 0001 GETMET R1 R1 K1 + 0x7C040200, // 0002 CALL R1 1 + 0xB80A0400, // 0003 GETNGBL R2 K2 + 0x88080503, // 0004 GETMBR R2 R2 K3 + 0x8C080504, // 0005 GETMET R2 R2 K4 + 0x5C100200, // 0006 MOVE R4 R1 + 0x88140105, // 0007 GETMBR R5 R0 K5 + 0x7C080600, // 0008 CALL R2 3 + 0x780A0007, // 0009 JMPF R2 #0012 + 0x88080106, // 000A GETMBR R2 R0 K6 + 0x00080202, // 000B ADD R2 R1 R2 + 0x90020A02, // 000C SETMBR R0 K5 R2 + 0x8C080107, // 000D GETMET R2 R0 K7 + 0x7C080200, // 000E CALL R2 1 + 0x780A0001, // 000F JMPF R2 #0012 + 0x8C080108, // 0010 GETMET R2 R0 K8 + 0x7C080200, // 0011 CALL R2 1 + 0x80040200, // 0012 RET 1 R1 }) ) ); @@ -1467,9 +1436,9 @@ be_local_closure(Matter_Session_get_i2r_privacy, /* name */ /******************************************************************** -** Solidified function: get_ca +** Solidified function: get_i2r ********************************************************************/ -be_local_closure(Matter_Session_get_ca, /* name */ +be_local_closure(Matter_Session_get_i2r, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -1479,16 +1448,14 @@ be_local_closure(Matter_Session_get_ca, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(root_ca_certificate), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(i2rkey), }), - be_str_weak(get_ca), + be_str_weak(get_i2r), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ + ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88040301, // 0001 GETMBR R1 R1 K1 - 0x80040200, // 0002 RET 1 R1 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -1496,9 +1463,9 @@ be_local_closure(Matter_Session_get_ca, /* name */ /******************************************************************** -** Solidified function: get_ac +** Solidified function: get_admin_vendor ********************************************************************/ -be_local_closure(Matter_Session_get_ac, /* name */ +be_local_closure(Matter_Session_get_admin_vendor, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -1508,14 +1475,16 @@ 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), + ( &(const bvalue[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(_fabric), + /* K1 */ be_nested_str_weak(admin_vendor), }), - be_str_weak(get_ac), + be_str_weak(get_admin_vendor), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ + ( &(const binstruction[ 3]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x80040200, // 0001 RET 1 R1 + 0x88040301, // 0001 GETMBR R1 R1 K1 + 0x80040200, // 0002 RET 1 R1 }) ) ); @@ -1523,51 +1492,26 @@ be_local_closure(Matter_Session_get_ac, /* name */ /******************************************************************** -** Solidified function: counter_snd_next +** Solidified function: set_temp_ca ********************************************************************/ -be_local_closure(Matter_Session_counter_snd_next, /* name */ +be_local_closure(Matter_Session_set_temp_ca, /* name */ be_nested_proto( - 6, /* nstack */ - 1, /* argc */ + 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[ 9]) { /* constants */ - /* K0 */ be_nested_str_weak(_counter_snd_impl), - /* K1 */ be_nested_str_weak(next), - /* K2 */ be_nested_str_weak(matter), - /* K3 */ be_nested_str_weak(Counter), - /* K4 */ be_nested_str_weak(is_greater), - /* K5 */ be_nested_str_weak(counter_snd), - /* K6 */ be_nested_str_weak(_COUNTER_SND_INCR), - /* K7 */ be_nested_str_weak(does_persist), - /* K8 */ be_nested_str_weak(save), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(_temp_root_ca_certificate), }), - be_str_weak(counter_snd_next), + be_str_weak(set_temp_ca), &be_const_str_solidified, - ( &(const binstruction[19]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x7C040200, // 0002 CALL R1 1 - 0xB80A0400, // 0003 GETNGBL R2 K2 - 0x88080503, // 0004 GETMBR R2 R2 K3 - 0x8C080504, // 0005 GETMET R2 R2 K4 - 0x5C100200, // 0006 MOVE R4 R1 - 0x88140105, // 0007 GETMBR R5 R0 K5 - 0x7C080600, // 0008 CALL R2 3 - 0x780A0007, // 0009 JMPF R2 #0012 - 0x88080106, // 000A GETMBR R2 R0 K6 - 0x00080202, // 000B ADD R2 R1 R2 - 0x90020A02, // 000C SETMBR R0 K5 R2 - 0x8C080107, // 000D GETMET R2 R0 K7 - 0x7C080200, // 000E CALL R2 1 - 0x780A0001, // 000F JMPF R2 #0012 - 0x8C080108, // 0010 GETMET R2 R0 K8 - 0x7C080200, // 0011 CALL R2 1 - 0x80040200, // 0012 RET 1 R1 + ( &(const binstruction[ 2]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x80000000, // 0001 RET 0 }) ) ); @@ -1575,38 +1519,87 @@ be_local_closure(Matter_Session_counter_snd_next, /* name */ /******************************************************************** -** Solidified function: counter_rcv_validate +** Solidified function: init ********************************************************************/ -be_local_closure(Matter_Session_counter_rcv_validate, /* name */ +be_local_closure(Matter_Session_init, /* name */ be_nested_proto( - 7, /* nstack */ - 3, /* argc */ + 10, /* 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(_counter_rcv_impl), - /* K1 */ be_nested_str_weak(validate), - /* K2 */ be_nested_str_weak(counter_rcv), - /* K3 */ be_nested_str_weak(val), + ( &(const bvalue[23]) { /* 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_snd_impl), + /* K7 */ be_nested_str_weak(matter), + /* K8 */ be_nested_str_weak(Counter), + /* K9 */ be_nested_str_weak(_counter_rcv_impl), + /* K10 */ be_nested_str_weak(counter_rcv), + /* K11 */ be_nested_str_weak(counter_snd), + /* K12 */ be_nested_str_weak(next), + /* K13 */ be_nested_str_weak(_COUNTER_SND_INCR), + /* K14 */ be_nested_str_weak(_counter_insecure_rcv), + /* K15 */ be_nested_str_weak(_counter_insecure_snd), + /* K16 */ be_nested_str_weak(_breadcrumb), + /* K17 */ be_nested_str_weak(_exchange_id), + /* K18 */ be_nested_str_weak(random), + /* K19 */ be_const_int(2), + /* K20 */ be_nested_str_weak(get), + /* K21 */ be_nested_str_weak(_fabric), + /* K22 */ be_nested_str_weak(update), }), - be_str_weak(counter_rcv_validate), + be_str_weak(init), &be_const_str_solidified, - ( &(const binstruction[11]) { /* code */ - 0x880C0100, // 0000 GETMBR R3 R0 K0 - 0x8C0C0701, // 0001 GETMET R3 R3 K1 - 0x5C140200, // 0002 MOVE R5 R1 - 0x5C180400, // 0003 MOVE R6 R2 - 0x7C0C0600, // 0004 CALL R3 3 - 0x780E0003, // 0005 JMPF R3 #000A - 0x88100100, // 0006 GETMBR R4 R0 K0 - 0x8C100903, // 0007 GETMET R4 R4 K3 - 0x7C100200, // 0008 CALL R4 1 - 0x90020404, // 0009 SETMBR R0 K2 R4 - 0x80040600, // 000A RET 1 R3 + ( &(const binstruction[41]) { /* code */ + 0xA4160000, // 0000 IMPORT R5 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 + 0xB81A0E00, // 0005 GETNGBL R6 K7 + 0x8C180D08, // 0006 GETMET R6 R6 K8 + 0x7C180200, // 0007 CALL R6 1 + 0x90020C06, // 0008 SETMBR R0 K6 R6 + 0xB81A0E00, // 0009 GETNGBL R6 K7 + 0x8C180D08, // 000A GETMET R6 R6 K8 + 0x7C180200, // 000B CALL R6 1 + 0x90021206, // 000C SETMBR R0 K9 R6 + 0x90021503, // 000D SETMBR R0 K10 K3 + 0x88180106, // 000E GETMBR R6 R0 K6 + 0x8C180D0C, // 000F GETMET R6 R6 K12 + 0x7C180200, // 0010 CALL R6 1 + 0x881C010D, // 0011 GETMBR R7 R0 K13 + 0x00180C07, // 0012 ADD R6 R6 R7 + 0x90021606, // 0013 SETMBR R0 K11 R6 + 0xB81A0E00, // 0014 GETNGBL R6 K7 + 0x8C180D08, // 0015 GETMET R6 R6 K8 + 0x7C180200, // 0016 CALL R6 1 + 0x90021C06, // 0017 SETMBR R0 K14 R6 + 0xB81A0E00, // 0018 GETNGBL R6 K7 + 0x8C180D08, // 0019 GETMET R6 R6 K8 + 0x7C180200, // 001A CALL R6 1 + 0x90021E06, // 001B SETMBR R0 K15 R6 + 0x90022103, // 001C SETMBR R0 K16 K3 + 0x8C180B12, // 001D GETMET R6 R5 K18 + 0x58200013, // 001E LDCONST R8 K19 + 0x7C180400, // 001F CALL R6 2 + 0x8C180D14, // 0020 GETMET R6 R6 K20 + 0x58200003, // 0021 LDCONST R8 K3 + 0x58240013, // 0022 LDCONST R9 K19 + 0x7C180600, // 0023 CALL R6 3 + 0x90022206, // 0024 SETMBR R0 K17 R6 + 0x90022A04, // 0025 SETMBR R0 K21 R4 + 0x8C180116, // 0026 GETMET R6 R0 K22 + 0x7C180200, // 0027 CALL R6 1 + 0x80000000, // 0028 RET 0 }) ) ); @@ -1614,9 +1607,9 @@ be_local_closure(Matter_Session_counter_rcv_validate, /* name */ /******************************************************************** -** Solidified function: get_icac +** Solidified function: get_fabric_index ********************************************************************/ -be_local_closure(Matter_Session_get_icac, /* name */ +be_local_closure(Matter_Session_get_fabric_index, /* name */ be_nested_proto( 2, /* nstack */ 1, /* argc */ @@ -1628,14 +1621,18 @@ be_local_closure(Matter_Session_get_icac, /* name */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(icac), + /* K1 */ be_nested_str_weak(fabric_index), }), - be_str_weak(get_icac), + be_str_weak(get_fabric_index), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ + ( &(const binstruction[ 7]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88040301, // 0001 GETMBR R1 R1 K1 - 0x80040200, // 0002 RET 1 R1 + 0x78060002, // 0001 JMPF R1 #0005 + 0x88040100, // 0002 GETMBR R1 R0 K0 + 0x88040301, // 0003 GETMBR R1 R1 K1 + 0x70020000, // 0004 JMP #0006 + 0x4C040000, // 0005 LDNIL R1 + 0x80040200, // 0006 RET 1 R1 }) ) ); @@ -1643,11 +1640,11 @@ be_local_closure(Matter_Session_get_icac, /* name */ /******************************************************************** -** Solidified function: get_ca_pub +** Solidified function: get_temp_ca ********************************************************************/ -be_local_closure(Matter_Session_get_ca_pub, /* name */ +be_local_closure(Matter_Session_get_temp_ca, /* name */ be_nested_proto( - 3, /* nstack */ + 2, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1655,17 +1652,14 @@ be_local_closure(Matter_Session_get_ca_pub, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(get_ca_pub), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(_temp_root_ca_certificate), }), - be_str_weak(get_ca_pub), + be_str_weak(get_temp_ca), &be_const_str_solidified, - ( &(const binstruction[ 4]) { /* code */ + ( &(const binstruction[ 2]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x7C040200, // 0002 CALL R1 1 - 0x80040200, // 0003 RET 1 R1 + 0x80040200, // 0001 RET 1 R1 }) ) ); @@ -1673,11 +1667,11 @@ be_local_closure(Matter_Session_get_ca_pub, /* name */ /******************************************************************** -** Solidified function: get_ipk_epoch_key +** Solidified function: get_pk ********************************************************************/ -be_local_closure(Matter_Session_get_ipk_epoch_key, /* name */ +be_local_closure(Matter_Session_get_pk, /* name */ be_nested_proto( - 2, /* nstack */ + 5, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1685,16 +1679,33 @@ be_local_closure(Matter_Session_get_ipk_epoch_key, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ + ( &(const bvalue[ 5]) { /* constants */ /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(ipk_epoch_key), + /* K1 */ be_nested_str_weak(get_pk), + /* K2 */ be_nested_str_weak(_temp_pk), + /* K3 */ be_nested_str_weak(crypto), + /* K4 */ be_nested_str_weak(random), }), - be_str_weak(get_ipk_epoch_key), + be_str_weak(get_pk), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ + ( &(const binstruction[17]) { /* code */ 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x88040301, // 0001 GETMBR R1 R1 K1 - 0x80040200, // 0002 RET 1 R1 + 0x78060004, // 0001 JMPF R1 #0007 + 0x88040100, // 0002 GETMBR R1 R0 K0 + 0x8C040301, // 0003 GETMET R1 R1 K1 + 0x7C040200, // 0004 CALL R1 1 + 0x80040200, // 0005 RET 1 R1 + 0x70020008, // 0006 JMP #0010 + 0x88040102, // 0007 GETMBR R1 R0 K2 + 0x74060004, // 0008 JMPT R1 #000E + 0xA4060600, // 0009 IMPORT R1 K3 + 0x8C080304, // 000A GETMET R2 R1 K4 + 0x5412001F, // 000B LDINT R4 32 + 0x7C080400, // 000C CALL R2 2 + 0x90020402, // 000D SETMBR R0 K2 R2 + 0x88040102, // 000E GETMBR R1 R0 K2 + 0x80040200, // 000F RET 1 R1 + 0x80000000, // 0010 RET 0 }) ) ); @@ -1702,9 +1713,9 @@ be_local_closure(Matter_Session_get_ipk_epoch_key, /* name */ /******************************************************************** -** Solidified function: persist_to_fabric +** Solidified function: set_mode_PASE ********************************************************************/ -be_local_closure(Matter_Session_persist_to_fabric, /* name */ +be_local_closure(Matter_Session_set_mode_PASE, /* name */ be_nested_proto( 4, /* nstack */ 1, /* argc */ @@ -1715,17 +1726,43 @@ be_local_closure(Matter_Session_persist_to_fabric, /* name */ NULL, /* no sub protos */ 1, /* has constants */ ( &(const bvalue[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(_fabric), - /* K1 */ be_nested_str_weak(add_session), + /* K0 */ be_nested_str_weak(set_mode), + /* K1 */ be_nested_str_weak(_PASE), }), - be_str_weak(persist_to_fabric), + be_str_weak(set_mode_PASE), &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x88040100, // 0000 GETMBR R1 R0 K0 - 0x8C040301, // 0001 GETMET R1 R1 K1 - 0x5C0C0000, // 0002 MOVE R3 R0 - 0x7C040400, // 0003 CALL R1 2 - 0x80000000, // 0004 RET 0 + ( &(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: 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 }) ) ); @@ -1739,91 +1776,92 @@ extern const bclass be_class_Matter_Expirable; be_local_class(Matter_Session, 38, &be_class_Matter_Expirable, - be_nested_map(83, + be_nested_map(84, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(resumption_id, -1), be_const_var(28) }, - { be_const_key_weak(mode, 4), be_const_var(1) }, - { be_const_key_weak(get_pk, -1), be_const_closure(Matter_Session_get_pk_closure) }, - { be_const_key_weak(set_mode_CASE, 65), be_const_closure(Matter_Session_set_mode_CASE_closure) }, - { be_const_key_weak(__spake_cA, 22), be_const_var(33) }, - { be_const_key_weak(__initiator_pub, -1), be_const_var(32) }, - { be_const_key_weak(get_temp_ca_pub, 55), be_const_closure(Matter_Session_get_temp_ca_pub_closure) }, - { be_const_key_weak(get_i2r, -1), be_const_closure(Matter_Session_get_i2r_closure) }, - { be_const_key_weak(_ip, 82), be_const_var(17) }, - { be_const_key_weak(__Msg2, -1), be_const_var(36) }, - { be_const_key_weak(get_fabric_label, 59), be_const_closure(Matter_Session_get_fabric_label_closure) }, - { be_const_key_weak(__future_initiator_session_id, -1), be_const_var(10) }, - { be_const_key_weak(set_keys, 0), be_const_closure(Matter_Session_set_keys_closure) }, - { be_const_key_weak(set_mode_PASE, -1), be_const_closure(Matter_Session_set_mode_PASE_closure) }, - { be_const_key_weak(_fabric, 7), be_const_var(2) }, - { be_const_key_weak(get_temp_ca, -1), be_const_closure(Matter_Session_get_temp_ca_closure) }, - { be_const_key_weak(attestation_challenge, -1), be_const_var(25) }, - { be_const_key_weak(_temp_pk, -1), be_const_var(9) }, - { be_const_key_weak(last_used, -1), be_const_var(6) }, - { be_const_key_weak(peer_node_id, -1), be_const_var(26) }, - { be_const_key_weak(is_CASE, -1), be_const_closure(Matter_Session_is_CASE_closure) }, - { be_const_key_weak(get_ipk_epoch_key, 80), be_const_closure(Matter_Session_get_ipk_epoch_key_closure) }, + { be_const_key_weak(set_mode, 6), be_const_closure(Matter_Session_set_mode_closure) }, + { be_const_key_weak(set_mode_PASE, 57), be_const_closure(Matter_Session_set_mode_PASE_closure) }, + { be_const_key_weak(_counter_rcv_impl, 79), be_const_var(14) }, + { be_const_key_weak(attestation_challenge, 56), be_const_var(25) }, + { be_const_key_weak(get_ac, -1), be_const_closure(Matter_Session_get_ac_closure) }, + { be_const_key_weak(get_fabric, -1), be_const_closure(Matter_Session_get_fabric_closure) }, + { be_const_key_weak(get_temp_ca, 69), be_const_closure(Matter_Session_get_temp_ca_closure) }, + { be_const_key_weak(_COUNTER_SND_INCR, -1), be_const_int(1024) }, + { be_const_key_weak(_CASE, -1), be_const_int(2) }, + { be_const_key_weak(_counter_insecure_rcv, 2), be_const_var(20) }, + { be_const_key_weak(_breadcrumb, -1), be_const_var(27) }, + { be_const_key_weak(r2ikey, 82), be_const_var(23) }, + { be_const_key_weak(set_keys, 52), be_const_closure(Matter_Session_set_keys_closure) }, { be_const_key_weak(_exchange_id, -1), be_const_var(16) }, - { be_const_key_weak(__chunked_attr_reports, -1), be_const_var(37) }, - { be_const_key_weak(counter_snd, -1), be_const_var(13) }, - { be_const_key_weak(_i2r_privacy, -1), be_const_var(24) }, - { 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(get_icac, 53), be_const_closure(Matter_Session_get_icac_closure) }, - { be_const_key_weak(is_PASE, -1), be_const_closure(Matter_Session_is_PASE_closure) }, - { be_const_key_weak(gen_CSR, -1), be_const_closure(Matter_Session_gen_CSR_closure) }, - { be_const_key_weak(_message_handler, 51), be_const_var(19) }, - { be_const_key_weak(__spake_Ke, -1), be_const_var(34) }, - { be_const_key_weak(get_admin_subject, -1), be_const_closure(Matter_Session_get_admin_subject_closure) }, - { be_const_key_weak(before_remove, 73), be_const_closure(Matter_Session_before_remove_closure) }, - { be_const_key_weak(__responder_pub, -1), be_const_var(31) }, - { be_const_key_weak(i2rkey, -1), be_const_var(22) }, + { be_const_key_weak(peer_node_id, 8), be_const_var(26) }, + { be_const_key_weak(last_used, 80), be_const_var(6) }, + { be_const_key_weak(_source_node_id, 48), be_const_var(7) }, + { be_const_key_weak(init, 36), be_const_closure(Matter_Session_init_closure) }, + { be_const_key_weak(set_temp_ca, -1), be_const_closure(Matter_Session_set_temp_ca_closure) }, { be_const_key_weak(created, -1), be_const_var(5) }, - { be_const_key_weak(_CASE, -1), be_const_int(2) }, - { be_const_key_weak(_port, -1), be_const_var(18) }, + { be_const_key_weak(persist_to_fabric, -1), be_const_closure(Matter_Session_persist_to_fabric_closure) }, + { be_const_key_weak(__initiator_pub, -1), be_const_var(32) }, + { be_const_key_weak(gen_CSR, -1), be_const_closure(Matter_Session_gen_CSR_closure) }, { be_const_key_weak(_store, -1), be_const_var(0) }, - { be_const_key_weak(get_device_id, -1), be_const_closure(Matter_Session_get_device_id_closure) }, - { be_const_key_weak(get_admin_vendor, -1), be_const_closure(Matter_Session_get_admin_vendor_closure) }, - { be_const_key_weak(get_fabric, -1), be_const_closure(Matter_Session_get_fabric_closure) }, - { be_const_key_weak(_counter_insecure_rcv, 28), be_const_var(20) }, - { be_const_key_weak(get_ipk_group_key, -1), be_const_closure(Matter_Session_get_ipk_group_key_closure) }, - { be_const_key_weak(__responder_priv, -1), be_const_var(30) }, - { be_const_key_weak(_GROUP_KEY, 56), be_nested_str_weak(GroupKey_X20v1_X2E0) }, + { be_const_key_weak(get_ipk_epoch_key, 49), be_const_closure(Matter_Session_get_ipk_epoch_key_closure) }, + { be_const_key_weak(__responder_priv, 7), be_const_var(30) }, + { be_const_key_weak(counter_rcv_validate, -1), be_const_closure(Matter_Session_counter_rcv_validate_closure) }, + { be_const_key_weak(_ip, -1), be_const_var(17) }, + { be_const_key_weak(get_admin_subject, 40), be_const_closure(Matter_Session_get_admin_subject_closure) }, + { be_const_key_weak(resumption_id, -1), be_const_var(28) }, + { be_const_key_weak(_i2r_privacy, -1), be_const_var(24) }, + { be_const_key_weak(get_fabric_compressed, -1), be_const_closure(Matter_Session_get_fabric_compressed_closure) }, + { be_const_key_weak(_temp_pk, -1), be_const_var(9) }, + { be_const_key_weak(shared_secret, 74), be_const_var(29) }, { be_const_key_weak(_temp_root_ca_certificate, -1), be_const_var(8) }, - { be_const_key_weak(init, -1), be_const_closure(Matter_Session_init_closure) }, - { be_const_key_weak(get_noc, 41), be_const_closure(Matter_Session_get_noc_closure) }, - { be_const_key_weak(set_fabric_label, 15), be_const_closure(Matter_Session_set_fabric_label_closure) }, - { be_const_key_weak(shared_secret, -1), be_const_var(29) }, - { be_const_key_weak(hydrate_post, 33), be_const_closure(Matter_Session_hydrate_post_closure) }, - { be_const_key_weak(fromjson, -1), be_const_static_closure(Matter_Session_fromjson_closure) }, - { be_const_key_weak(save, -1), be_const_closure(Matter_Session_save_closure) }, - { be_const_key_weak(_source_node_id, -1), be_const_var(7) }, - { be_const_key_weak(set_mode, 25), be_const_closure(Matter_Session_set_mode_closure) }, - { be_const_key_weak(_counter_snd_impl, -1), be_const_var(15) }, - { be_const_key_weak(__Msg1, 81), be_const_var(35) }, - { be_const_key_weak(set_temp_ca, -1), be_const_closure(Matter_Session_set_temp_ca_closure) }, + { be_const_key_weak(get_ca, -1), be_const_closure(Matter_Session_get_ca_closure) }, + { be_const_key_weak(_fabric, 10), be_const_var(2) }, + { be_const_key_weak(__spake_cA, -1), be_const_var(33) }, + { be_const_key_weak(get_ipk_group_key, -1), be_const_closure(Matter_Session_get_ipk_group_key_closure) }, + { be_const_key_weak(initiator_session_id, 18), be_const_var(4) }, { be_const_key_weak(get_i2r_privacy, -1), be_const_closure(Matter_Session_get_i2r_privacy_closure) }, - { be_const_key_weak(initiator_session_id, -1), be_const_var(4) }, - { be_const_key_weak(__future_local_session_id, -1), be_const_var(11) }, - { be_const_key_weak(r2ikey, -1), be_const_var(23) }, - { be_const_key_weak(get_fabric_id, 72), be_const_closure(Matter_Session_get_fabric_id_closure) }, - { be_const_key_weak(get_ac, -1), be_const_closure(Matter_Session_get_ac_closure) }, - { be_const_key_weak(local_session_id, -1), be_const_var(3) }, - { be_const_key_weak(counter_snd_next, -1), be_const_closure(Matter_Session_counter_snd_next_closure) }, - { be_const_key_weak(counter_rcv_validate, -1), be_const_closure(Matter_Session_counter_rcv_validate_closure) }, - { be_const_key_weak(get_ca, 35), be_const_closure(Matter_Session_get_ca_closure) }, - { be_const_key_weak(_counter_rcv_impl, -1), be_const_var(14) }, - { be_const_key_weak(update, -1), be_const_closure(Matter_Session_update_closure) }, - { be_const_key_weak(close, 23), be_const_closure(Matter_Session_close_closure) }, + { be_const_key_weak(__chunked_attr_reports, -1), be_const_var(37) }, { be_const_key_weak(get_ca_pub, -1), be_const_closure(Matter_Session_get_ca_pub_closure) }, - { be_const_key_weak(_breadcrumb, -1), be_const_var(27) }, - { be_const_key_weak(_COUNTER_SND_INCR, 21), be_const_int(1024) }, + { be_const_key_weak(counter_snd, 20), be_const_var(13) }, + { be_const_key_weak(set_fabric_label, 35), be_const_closure(Matter_Session_set_fabric_label_closure) }, + { be_const_key_weak(_counter_snd_impl, 71), be_const_var(15) }, + { be_const_key_weak(is_CASE, -1), be_const_closure(Matter_Session_is_CASE_closure) }, + { be_const_key_weak(before_remove, -1), be_const_closure(Matter_Session_before_remove_closure) }, + { be_const_key_weak(set_mode_CASE, -1), be_const_closure(Matter_Session_set_mode_CASE_closure) }, + { be_const_key_weak(get_icac, -1), be_const_closure(Matter_Session_get_icac_closure) }, + { be_const_key_weak(tojson, 61), be_const_closure(Matter_Session_tojson_closure) }, + { be_const_key_weak(close, 1), be_const_closure(Matter_Session_close_closure) }, + { be_const_key_weak(get_fabric_label, 42), be_const_closure(Matter_Session_get_fabric_label_closure) }, { be_const_key_weak(_counter_insecure_snd, -1), be_const_var(21) }, - { be_const_key_weak(persist_to_fabric, -1), be_const_closure(Matter_Session_persist_to_fabric_closure) }, - { be_const_key_weak(counter_rcv, 5), be_const_var(12) }, - { be_const_key_weak(tojson, -1), be_const_closure(Matter_Session_tojson_closure) }, + { be_const_key_weak(get_device_id, 63), be_const_closure(Matter_Session_get_device_id_closure) }, + { be_const_key_weak(counter_rcv, 62), be_const_var(12) }, + { be_const_key_weak(__Msg1, -1), be_const_var(35) }, + { be_const_key_weak(hydrate_post, 66), be_const_closure(Matter_Session_hydrate_post_closure) }, + { be_const_key_weak(_message_handler, -1), be_const_var(19) }, + { be_const_key_weak(__future_initiator_session_id, -1), be_const_var(10) }, + { be_const_key_weak(__spake_Ke, 32), be_const_var(34) }, + { be_const_key_weak(__Msg2, 38), be_const_var(36) }, + { be_const_key_weak(get_mode, -1), be_const_closure(Matter_Session_get_mode_closure) }, + { be_const_key_weak(mode, -1), be_const_var(1) }, + { be_const_key_weak(update, 16), be_const_closure(Matter_Session_update_closure) }, + { be_const_key_weak(counter_snd_next, -1), be_const_closure(Matter_Session_counter_snd_next_closure) }, + { be_const_key_weak(get_temp_ca_pub, -1), be_const_closure(Matter_Session_get_temp_ca_pub_closure) }, + { be_const_key_weak(get_i2r, -1), be_const_closure(Matter_Session_get_i2r_closure) }, + { be_const_key_weak(get_noc, 37), be_const_closure(Matter_Session_get_noc_closure) }, + { be_const_key_weak(get_fabric_id, -1), be_const_closure(Matter_Session_get_fabric_id_closure) }, + { be_const_key_weak(get_admin_vendor, -1), be_const_closure(Matter_Session_get_admin_vendor_closure) }, + { be_const_key_weak(is_PASE, -1), be_const_closure(Matter_Session_is_PASE_closure) }, + { be_const_key_weak(save, 21), be_const_closure(Matter_Session_save_closure) }, + { be_const_key_weak(_GROUP_KEY, -1), be_nested_str_weak(GroupKey_X20v1_X2E0) }, + { be_const_key_weak(local_session_id, 76), be_const_var(3) }, + { be_const_key_weak(i2rkey, 17), be_const_var(22) }, + { be_const_key_weak(__future_local_session_id, -1), be_const_var(11) }, + { be_const_key_weak(_PASE, -1), be_const_int(1) }, + { be_const_key_weak(get_fabric_index, -1), be_const_closure(Matter_Session_get_fabric_index_closure) }, + { be_const_key_weak(_port, -1), be_const_var(18) }, { be_const_key_weak(get_r2i, -1), be_const_closure(Matter_Session_get_r2i_closure) }, - { be_const_key_weak(get_fabric_compressed, -1), be_const_closure(Matter_Session_get_fabric_compressed_closure) }, + { be_const_key_weak(get_pk, -1), be_const_closure(Matter_Session_get_pk_closure) }, + { be_const_key_weak(__responder_pub, -1), be_const_var(31) }, + { be_const_key_weak(fromjson, 0), be_const_static_closure(Matter_Session_fromjson_closure) }, })), be_str_weak(Matter_Session) ); diff --git a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session_Store.h b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session_Store.h index b462b8ac3cec..e4ccf468a5fe 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session_Store.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_Session_Store.h @@ -1156,7 +1156,7 @@ be_local_closure(Matter_Session_Store_find_session_by_resumption_id, /* name * ********************************************************************/ be_local_closure(Matter_Session_Store_save_fabrics, /* name */ be_nested_proto( - 12, /* nstack */ + 11, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -1164,33 +1164,31 @@ be_local_closure(Matter_Session_Store_save_fabrics, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[26]) { /* constants */ + ( &(const bvalue[24]) { /* constants */ /* K0 */ be_nested_str_weak(json), /* K1 */ be_nested_str_weak(remove_expired), /* K2 */ be_const_int(0), - /* K3 */ be_nested_str_weak(fabrics), - /* K4 */ be_nested_str_weak(persistables), - /* K5 */ be_nested_str_weak(_sessions), - /* K6 */ be_const_int(1), - /* K7 */ be_nested_str_weak(stop_iteration), - /* K8 */ be_nested_str_weak(push), - /* K9 */ be_nested_str_weak(tojson), - /* K10 */ be_nested_str_weak(_X5B), - /* K11 */ be_nested_str_weak(concat), + /* K3 */ be_nested_str_weak(_FABRICS), + /* K4 */ be_nested_str_weak(w), + /* K5 */ be_nested_str_weak(write), + /* K6 */ be_nested_str_weak(_X5B), + /* K7 */ be_nested_str_weak(fabrics), + /* K8 */ be_nested_str_weak(persistables), + /* K9 */ be_nested_str_weak(_sessions), + /* K10 */ be_const_int(1), + /* K11 */ be_nested_str_weak(stop_iteration), /* K12 */ be_nested_str_weak(_X2C), - /* K13 */ be_nested_str_weak(_X5D), - /* K14 */ be_nested_str_weak(_FABRICS), - /* K15 */ be_nested_str_weak(w), - /* K16 */ be_nested_str_weak(write), - /* K17 */ be_nested_str_weak(close), - /* K18 */ be_nested_str_weak(tasmota), - /* K19 */ be_nested_str_weak(log), - /* K20 */ be_nested_str_weak(MTR_X3A_X20_X3DSaved_X20_X20_X20_X20_X20_X25i_X20fabric_X28s_X29_X20and_X20_X25i_X20session_X28s_X29), - /* K21 */ be_const_int(2), - /* K22 */ be_nested_str_weak(device), - /* K23 */ be_nested_str_weak(event_fabrics_saved), - /* K24 */ be_nested_str_weak(MTR_X3A_X20Session_Store_X3A_X3Asave_X20Exception_X3A), - /* K25 */ be_nested_str_weak(_X7C), + /* K13 */ be_nested_str_weak(tojson), + /* K14 */ be_nested_str_weak(_X5D), + /* K15 */ be_nested_str_weak(close), + /* K16 */ be_nested_str_weak(tasmota), + /* K17 */ be_nested_str_weak(log), + /* K18 */ be_nested_str_weak(MTR_X3A_X20_X3DSaved_X20_X20_X20_X20_X20_X25s_X20fabric_X28s_X29_X20and_X20_X25s_X20session_X28s_X29), + /* K19 */ be_const_int(2), + /* K20 */ be_nested_str_weak(device), + /* K21 */ be_nested_str_weak(event_fabrics_saved), + /* K22 */ be_nested_str_weak(MTR_X3A_X20Session_Store_X3A_X3Asave_X20Exception_X3A), + /* K23 */ be_nested_str_weak(_X7C), }), be_str_weak(save_fabrics), &be_const_str_solidified, @@ -1200,83 +1198,83 @@ be_local_closure(Matter_Session_Store_save_fabrics, /* name */ 0x8C080101, // 0002 GETMET R2 R0 K1 0x7C080200, // 0003 CALL R2 1 0x58080002, // 0004 LDCONST R2 K2 - 0x600C0012, // 0005 GETGBL R3 G18 - 0x7C0C0000, // 0006 CALL R3 0 - 0x60100010, // 0007 GETGBL R4 G16 - 0x88140103, // 0008 GETMBR R5 R0 K3 - 0x8C140B04, // 0009 GETMET R5 R5 K4 - 0x7C140200, // 000A CALL R5 1 - 0x7C100200, // 000B CALL R4 1 - 0xA8020013, // 000C EXBLK 0 #0021 - 0x5C140800, // 000D MOVE R5 R4 - 0x7C140000, // 000E CALL R5 0 - 0x60180010, // 000F GETGBL R6 G16 - 0x881C0B05, // 0010 GETMBR R7 R5 K5 - 0x8C1C0F04, // 0011 GETMET R7 R7 K4 - 0x7C1C0200, // 0012 CALL R7 1 - 0x7C180200, // 0013 CALL R6 1 - 0xA8020003, // 0014 EXBLK 0 #0019 - 0x5C1C0C00, // 0015 MOVE R7 R6 - 0x7C1C0000, // 0016 CALL R7 0 - 0x00080506, // 0017 ADD R2 R2 K6 - 0x7001FFFB, // 0018 JMP #0015 - 0x58180007, // 0019 LDCONST R6 K7 - 0xAC180200, // 001A CATCH R6 1 0 - 0xB0080000, // 001B RAISE 2 R0 R0 - 0x8C180708, // 001C GETMET R6 R3 K8 - 0x8C200B09, // 001D GETMET R8 R5 K9 - 0x7C200200, // 001E CALL R8 1 - 0x7C180400, // 001F CALL R6 2 - 0x7001FFEB, // 0020 JMP #000D - 0x58100007, // 0021 LDCONST R4 K7 - 0xAC100200, // 0022 CATCH R4 1 0 - 0xB0080000, // 0023 RAISE 2 R0 R0 - 0x6010000C, // 0024 GETGBL R4 G12 - 0x5C140600, // 0025 MOVE R5 R3 - 0x7C100200, // 0026 CALL R4 1 - 0x8C14070B, // 0027 GETMET R5 R3 K11 - 0x581C000C, // 0028 LDCONST R7 K12 - 0x7C140400, // 0029 CALL R5 2 - 0x00161405, // 002A ADD R5 K10 R5 - 0x00140B0D, // 002B ADD R5 R5 K13 - 0x5C0C0A00, // 002C MOVE R3 R5 - 0x60140011, // 002D GETGBL R5 G17 - 0x8818010E, // 002E GETMBR R6 R0 K14 - 0x581C000F, // 002F LDCONST R7 K15 - 0x7C140400, // 0030 CALL R5 2 - 0x8C180B10, // 0031 GETMET R6 R5 K16 - 0x5C200600, // 0032 MOVE R8 R3 - 0x7C180400, // 0033 CALL R6 2 - 0x8C180B11, // 0034 GETMET R6 R5 K17 - 0x7C180200, // 0035 CALL R6 1 - 0xB81A2400, // 0036 GETNGBL R6 K18 - 0x8C180D13, // 0037 GETMET R6 R6 K19 - 0x60200018, // 0038 GETGBL R8 G24 - 0x58240014, // 0039 LDCONST R9 K20 - 0x5C280800, // 003A MOVE R10 R4 - 0x5C2C0400, // 003B MOVE R11 R2 - 0x7C200600, // 003C CALL R8 3 - 0x58240015, // 003D LDCONST R9 K21 - 0x7C180600, // 003E CALL R6 3 - 0x88180116, // 003F GETMBR R6 R0 K22 - 0x8C180D17, // 0040 GETMET R6 R6 K23 - 0x7C180200, // 0041 CALL R6 1 + 0x580C0002, // 0005 LDCONST R3 K2 + 0x60100011, // 0006 GETGBL R4 G17 + 0x88140103, // 0007 GETMBR R5 R0 K3 + 0x58180004, // 0008 LDCONST R6 K4 + 0x7C100400, // 0009 CALL R4 2 + 0x8C140905, // 000A GETMET R5 R4 K5 + 0x581C0006, // 000B LDCONST R7 K6 + 0x7C140400, // 000C CALL R5 2 + 0x60140010, // 000D GETGBL R5 G16 + 0x88180107, // 000E GETMBR R6 R0 K7 + 0x8C180D08, // 000F GETMET R6 R6 K8 + 0x7C180200, // 0010 CALL R6 1 + 0x7C140200, // 0011 CALL R5 1 + 0xA802001A, // 0012 EXBLK 0 #002E + 0x5C180A00, // 0013 MOVE R6 R5 + 0x7C180000, // 0014 CALL R6 0 + 0x601C0010, // 0015 GETGBL R7 G16 + 0x88200D09, // 0016 GETMBR R8 R6 K9 + 0x8C201108, // 0017 GETMET R8 R8 K8 + 0x7C200200, // 0018 CALL R8 1 + 0x7C1C0200, // 0019 CALL R7 1 + 0xA8020003, // 001A EXBLK 0 #001F + 0x5C200E00, // 001B MOVE R8 R7 + 0x7C200000, // 001C CALL R8 0 + 0x0008050A, // 001D ADD R2 R2 K10 + 0x7001FFFB, // 001E JMP #001B + 0x581C000B, // 001F LDCONST R7 K11 + 0xAC1C0200, // 0020 CATCH R7 1 0 + 0xB0080000, // 0021 RAISE 2 R0 R0 + 0x241C0702, // 0022 GT R7 R3 K2 + 0x781E0002, // 0023 JMPF R7 #0027 + 0x8C1C0905, // 0024 GETMET R7 R4 K5 + 0x5824000C, // 0025 LDCONST R9 K12 + 0x7C1C0400, // 0026 CALL R7 2 + 0x8C1C0D0D, // 0027 GETMET R7 R6 K13 + 0x7C1C0200, // 0028 CALL R7 1 + 0x8C200905, // 0029 GETMET R8 R4 K5 + 0x5C280E00, // 002A MOVE R10 R7 + 0x7C200400, // 002B CALL R8 2 + 0x000C070A, // 002C ADD R3 R3 K10 + 0x7001FFE4, // 002D JMP #0013 + 0x5814000B, // 002E LDCONST R5 K11 + 0xAC140200, // 002F CATCH R5 1 0 + 0xB0080000, // 0030 RAISE 2 R0 R0 + 0x8C140905, // 0031 GETMET R5 R4 K5 + 0x581C000E, // 0032 LDCONST R7 K14 + 0x7C140400, // 0033 CALL R5 2 + 0x8C14090F, // 0034 GETMET R5 R4 K15 + 0x7C140200, // 0035 CALL R5 1 + 0xB8162000, // 0036 GETNGBL R5 K16 + 0x8C140B11, // 0037 GETMET R5 R5 K17 + 0x601C0018, // 0038 GETGBL R7 G24 + 0x58200012, // 0039 LDCONST R8 K18 + 0x5C240600, // 003A MOVE R9 R3 + 0x5C280400, // 003B MOVE R10 R2 + 0x7C1C0600, // 003C CALL R7 3 + 0x58200013, // 003D LDCONST R8 K19 + 0x7C140600, // 003E CALL R5 3 + 0x88140114, // 003F GETMBR R5 R0 K20 + 0x8C140B15, // 0040 GETMET R5 R5 K21 + 0x7C140200, // 0041 CALL R5 1 0xA8040001, // 0042 EXBLK 1 1 0x70020010, // 0043 JMP #0055 0xAC080002, // 0044 CATCH R2 0 2 0x7002000D, // 0045 JMP #0054 - 0xB8122400, // 0046 GETNGBL R4 K18 - 0x8C100913, // 0047 GETMET R4 R4 K19 + 0xB8122000, // 0046 GETNGBL R4 K16 + 0x8C100911, // 0047 GETMET R4 R4 K17 0x60180008, // 0048 GETGBL R6 G8 0x5C1C0400, // 0049 MOVE R7 R2 0x7C180200, // 004A CALL R6 1 - 0x001A3006, // 004B ADD R6 K24 R6 - 0x00180D19, // 004C ADD R6 R6 K25 + 0x001A2C06, // 004B ADD R6 K22 R6 + 0x00180D17, // 004C ADD R6 R6 K23 0x601C0008, // 004D GETGBL R7 G8 0x5C200600, // 004E MOVE R8 R3 0x7C1C0200, // 004F CALL R7 1 0x00180C07, // 0050 ADD R6 R6 R7 - 0x581C0015, // 0051 LDCONST R7 K21 + 0x581C0013, // 0051 LDCONST R7 K19 0x7C100600, // 0052 CALL R4 3 0x70020000, // 0053 JMP #0055 0xB0080000, // 0054 RAISE 2 R0 R0 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 b42a7facfd00..c829d034672d 100644 --- a/lib/libesp32/berry_matter/src/solidify/solidified_Matter_TLV.h +++ b/lib/libesp32/berry_matter/src/solidify/solidified_Matter_TLV.h @@ -7,65 +7,392 @@ extern const bclass be_class_Matter_TLV_item; /******************************************************************** -** Solidified function: encode_len +** Solidified function: to_TLV ********************************************************************/ -be_local_closure(Matter_TLV_item_encode_len, /* name */ +be_local_closure(Matter_TLV_item_to_TLV, /* name */ be_nested_proto( - 5, /* nstack */ + 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(to_TLV), + &be_const_str_solidified, + ( &(const binstruction[ 1]) { /* code */ + 0x80040000, // 0000 RET 1 R0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** 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[32]) { /* constants */ - /* K0 */ be_nested_str_weak(TLV), - /* K1 */ be_const_int(0), + ( &(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 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** 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: 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: to_str_val +********************************************************************/ +be_local_closure(Matter_TLV_item_to_str_val, /* 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[16]) { /* constants */ + /* K0 */ be_nested_str_weak(val), + /* K1 */ be_nested_str_weak(int), /* K2 */ be_nested_str_weak(typ), - /* K3 */ be_nested_str_weak(RAW), - /* K4 */ be_nested_str_weak(val), - /* K5 */ be_nested_str_weak(BFALSE), - /* K6 */ be_nested_str_weak(BTRUE), - /* K7 */ be_nested_str_weak(I2), - /* K8 */ be_nested_str_weak(I4), - /* K9 */ be_nested_str_weak(I1), - /* K10 */ be_nested_str_weak(U2), - /* K11 */ be_nested_str_weak(U4), - /* K12 */ be_nested_str_weak(U1), - /* K13 */ be_nested_str_weak(B1), - /* K14 */ be_nested_str_weak(B8), - /* K15 */ be_nested_str_weak(B2), - /* K16 */ be_nested_str_weak(B4), - /* K17 */ be_nested_str_weak(UTF1), - /* K18 */ be_nested_str_weak(UTF8), - /* K19 */ be_nested_str_weak(UTF2), - /* K20 */ be_nested_str_weak(UTF4), - /* K21 */ be_nested_str_weak(_encode_tag_len), - /* K22 */ be_const_int(1), - /* K23 */ be_const_int(2), - /* K24 */ be_nested_str_weak(I8), - /* K25 */ be_nested_str_weak(U8), - /* K26 */ be_nested_str_weak(FLOAT), - /* K27 */ be_nested_str_weak(DOUBLE), - /* K28 */ be_nested_str_weak(value_error), - /* K29 */ be_nested_str_weak(Unsupported_X20type_X20TLV_X2EDOUBLE), - /* K30 */ be_nested_str_weak(NULL), - /* K31 */ be_nested_str_weak(unsupported_X20type_X20), + /* K3 */ be_nested_str_weak(TLV), + /* K4 */ be_nested_str_weak(U1), + /* K5 */ be_nested_str_weak(U8), + /* K6 */ be_nested_str_weak(U), + /* K7 */ be_nested_str_weak(bool), + /* K8 */ be_nested_str_weak(true), + /* K9 */ be_nested_str_weak(false), + /* K10 */ be_nested_str_weak(null), + /* K11 */ be_nested_str_weak(real), + /* K12 */ be_nested_str_weak(string), + /* K13 */ be_nested_str_weak(int64), + /* K14 */ be_nested_str_weak(tostring), + /* K15 */ be_nested_str_weak(instance), }), - be_str_weak(encode_len), + be_str_weak(to_str_val), &be_const_str_solidified, - ( &(const binstruction[258]) { /* 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 - 0x780E0003, // 0005 JMPF R3 #000A - 0x600C000C, // 0006 GETGBL R3 G12 - 0x88100104, // 0007 GETMBR R4 R0 K4 - 0x7C0C0200, // 0008 CALL R3 1 - 0x80040600, // 0009 RET 1 R3 + ( &(const binstruction[98]) { /* code */ + 0x60040004, // 0000 GETGBL R1 G4 + 0x88080100, // 0001 GETMBR R2 R0 K0 + 0x7C040200, // 0002 CALL R1 1 + 0x1C040301, // 0003 EQ R1 R1 K1 + 0x78060014, // 0004 JMPF R1 #001A + 0x88040102, // 0005 GETMBR R1 R0 K2 + 0x88080103, // 0006 GETMBR R2 R0 K3 + 0x88080504, // 0007 GETMBR R2 R2 K4 + 0x28040202, // 0008 GE R1 R1 R2 + 0x7806000A, // 0009 JMPF R1 #0015 + 0x88040102, // 000A GETMBR R1 R0 K2 + 0x88080103, // 000B GETMBR R2 R0 K3 + 0x88080505, // 000C GETMBR R2 R2 K5 + 0x18040202, // 000D LE R1 R1 R2 + 0x78060005, // 000E JMPF R1 #0015 + 0x60040008, // 000F GETGBL R1 G8 + 0x88080100, // 0010 GETMBR R2 R0 K0 + 0x7C040200, // 0011 CALL R1 1 + 0x00040306, // 0012 ADD R1 R1 K6 + 0x80040200, // 0013 RET 1 R1 + 0x70020003, // 0014 JMP #0019 + 0x60040008, // 0015 GETGBL R1 G8 + 0x88080100, // 0016 GETMBR R2 R0 K0 + 0x7C040200, // 0017 CALL R1 1 + 0x80040200, // 0018 RET 1 R1 + 0x70020046, // 0019 JMP #0061 + 0x60040004, // 001A GETGBL R1 G4 + 0x88080100, // 001B GETMBR R2 R0 K0 + 0x7C040200, // 001C CALL R1 1 + 0x1C040307, // 001D EQ R1 R1 K7 + 0x78060006, // 001E JMPF R1 #0026 + 0x88040100, // 001F GETMBR R1 R0 K0 + 0x78060001, // 0020 JMPF R1 #0023 + 0x58040008, // 0021 LDCONST R1 K8 + 0x70020000, // 0022 JMP #0024 + 0x58040009, // 0023 LDCONST R1 K9 + 0x80040200, // 0024 RET 1 R1 + 0x7002003A, // 0025 JMP #0061 + 0x88040100, // 0026 GETMBR R1 R0 K0 + 0x4C080000, // 0027 LDNIL R2 + 0x1C040202, // 0028 EQ R1 R1 R2 + 0x78060001, // 0029 JMPF R1 #002C + 0x80061400, // 002A RET 1 K10 + 0x70020034, // 002B JMP #0061 + 0x60040004, // 002C GETGBL R1 G4 + 0x88080100, // 002D GETMBR R2 R0 K0 + 0x7C040200, // 002E CALL R1 1 + 0x1C04030B, // 002F EQ R1 R1 K11 + 0x78060004, // 0030 JMPF R1 #0036 + 0x60040008, // 0031 GETGBL R1 G8 + 0x88080100, // 0032 GETMBR R2 R0 K0 + 0x7C040200, // 0033 CALL R1 1 + 0x80040200, // 0034 RET 1 R1 + 0x7002002A, // 0035 JMP #0061 + 0x60040004, // 0036 GETGBL R1 G4 + 0x88080100, // 0037 GETMBR R2 R0 K0 + 0x7C040200, // 0038 CALL R1 1 + 0x1C04030C, // 0039 EQ R1 R1 K12 + 0x78060002, // 003A JMPF R1 #003E + 0x88040100, // 003B GETMBR R1 R0 K0 + 0x80040200, // 003C RET 1 R1 + 0x70020022, // 003D JMP #0061 + 0x6004000F, // 003E GETGBL R1 G15 + 0x88080100, // 003F GETMBR R2 R0 K0 + 0xB80E1A00, // 0040 GETNGBL R3 K13 + 0x7C040400, // 0041 CALL R1 2 + 0x78060014, // 0042 JMPF R1 #0058 + 0x88040102, // 0043 GETMBR R1 R0 K2 + 0x88080103, // 0044 GETMBR R2 R0 K3 + 0x88080504, // 0045 GETMBR R2 R2 K4 + 0x28040202, // 0046 GE R1 R1 R2 + 0x7806000A, // 0047 JMPF R1 #0053 + 0x88040102, // 0048 GETMBR R1 R0 K2 + 0x88080103, // 0049 GETMBR R2 R0 K3 + 0x88080505, // 004A GETMBR R2 R2 K5 + 0x18040202, // 004B LE R1 R1 R2 + 0x78060005, // 004C JMPF R1 #0053 + 0x88040100, // 004D GETMBR R1 R0 K0 + 0x8C04030E, // 004E GETMET R1 R1 K14 + 0x7C040200, // 004F CALL R1 1 + 0x00040306, // 0050 ADD R1 R1 K6 + 0x80040200, // 0051 RET 1 R1 + 0x70020003, // 0052 JMP #0057 + 0x88040100, // 0053 GETMBR R1 R0 K0 + 0x8C04030E, // 0054 GETMET R1 R1 K14 + 0x7C040200, // 0055 CALL R1 1 + 0x80040200, // 0056 RET 1 R1 + 0x70020008, // 0057 JMP #0061 + 0x60040004, // 0058 GETGBL R1 G4 + 0x88080100, // 0059 GETMBR R2 R0 K0 + 0x7C040200, // 005A CALL R1 1 + 0x1C04030F, // 005B EQ R1 R1 K15 + 0x78060003, // 005C JMPF R1 #0061 + 0x8C04010E, // 005D GETMET R1 R0 K14 + 0x500C0200, // 005E LDBOOL R3 1 0 + 0x7C040400, // 005F CALL R1 2 + 0x80040200, // 0060 RET 1 R1 + 0x80000000, // 0061 RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** 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[32]) { /* constants */ + /* K0 */ be_nested_str_weak(TLV), + /* K1 */ be_const_int(0), + /* K2 */ be_nested_str_weak(typ), + /* K3 */ be_nested_str_weak(RAW), + /* K4 */ be_nested_str_weak(val), + /* K5 */ be_nested_str_weak(BFALSE), + /* K6 */ be_nested_str_weak(BTRUE), + /* K7 */ be_nested_str_weak(I2), + /* K8 */ be_nested_str_weak(I4), + /* K9 */ be_nested_str_weak(I1), + /* K10 */ be_nested_str_weak(U2), + /* K11 */ be_nested_str_weak(U4), + /* K12 */ be_nested_str_weak(U1), + /* K13 */ be_nested_str_weak(B1), + /* K14 */ be_nested_str_weak(B8), + /* K15 */ be_nested_str_weak(B2), + /* K16 */ be_nested_str_weak(B4), + /* K17 */ be_nested_str_weak(UTF1), + /* K18 */ be_nested_str_weak(UTF8), + /* K19 */ be_nested_str_weak(UTF2), + /* K20 */ be_nested_str_weak(UTF4), + /* K21 */ be_nested_str_weak(_encode_tag_len), + /* K22 */ be_const_int(1), + /* K23 */ be_const_int(2), + /* K24 */ be_nested_str_weak(I8), + /* K25 */ be_nested_str_weak(U8), + /* K26 */ be_nested_str_weak(FLOAT), + /* K27 */ be_nested_str_weak(DOUBLE), + /* K28 */ be_nested_str_weak(value_error), + /* K29 */ be_nested_str_weak(Unsupported_X20type_X20TLV_X2EDOUBLE), + /* K30 */ be_nested_str_weak(NULL), + /* K31 */ be_nested_str_weak(unsupported_X20type_X20), + }), + be_str_weak(encode_len), + &be_const_str_solidified, + ( &(const binstruction[258]) { /* 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 + 0x780E0003, // 0005 JMPF R3 #000A + 0x600C000C, // 0006 GETGBL R3 G12 + 0x88100104, // 0007 GETMBR R4 R0 K4 + 0x7C0C0200, // 0008 CALL R3 1 + 0x80040600, // 0009 RET 1 R3 0x880C0102, // 000A GETMBR R3 R0 K2 0x88100305, // 000B GETMBR R4 R1 K5 0x1C0C0604, // 000C EQ R3 R3 R4 @@ -311,1065 +638,9 @@ be_local_closure(Matter_TLV_item_encode_len, /* name */ 0x600C0008, // 00FC GETGBL R3 G8 0x88100102, // 00FD GETMBR R4 R0 K2 0x7C0C0200, // 00FE CALL R3 1 - 0x000E3E03, // 00FF ADD R3 K31 R3 - 0xB0063803, // 0100 RAISE 1 K28 R3 - 0x80040400, // 0101 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: to_str_val -********************************************************************/ -be_local_closure(Matter_TLV_item_to_str_val, /* 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[16]) { /* constants */ - /* K0 */ be_nested_str_weak(val), - /* K1 */ be_nested_str_weak(int), - /* K2 */ be_nested_str_weak(typ), - /* K3 */ be_nested_str_weak(TLV), - /* K4 */ be_nested_str_weak(U1), - /* K5 */ be_nested_str_weak(U8), - /* K6 */ be_nested_str_weak(U), - /* K7 */ be_nested_str_weak(bool), - /* K8 */ be_nested_str_weak(true), - /* K9 */ be_nested_str_weak(false), - /* K10 */ be_nested_str_weak(null), - /* K11 */ be_nested_str_weak(real), - /* K12 */ be_nested_str_weak(string), - /* K13 */ be_nested_str_weak(int64), - /* K14 */ be_nested_str_weak(tostring), - /* K15 */ be_nested_str_weak(instance), - }), - be_str_weak(to_str_val), - &be_const_str_solidified, - ( &(const binstruction[98]) { /* code */ - 0x60040004, // 0000 GETGBL R1 G4 - 0x88080100, // 0001 GETMBR R2 R0 K0 - 0x7C040200, // 0002 CALL R1 1 - 0x1C040301, // 0003 EQ R1 R1 K1 - 0x78060014, // 0004 JMPF R1 #001A - 0x88040102, // 0005 GETMBR R1 R0 K2 - 0x88080103, // 0006 GETMBR R2 R0 K3 - 0x88080504, // 0007 GETMBR R2 R2 K4 - 0x28040202, // 0008 GE R1 R1 R2 - 0x7806000A, // 0009 JMPF R1 #0015 - 0x88040102, // 000A GETMBR R1 R0 K2 - 0x88080103, // 000B GETMBR R2 R0 K3 - 0x88080505, // 000C GETMBR R2 R2 K5 - 0x18040202, // 000D LE R1 R1 R2 - 0x78060005, // 000E JMPF R1 #0015 - 0x60040008, // 000F GETGBL R1 G8 - 0x88080100, // 0010 GETMBR R2 R0 K0 - 0x7C040200, // 0011 CALL R1 1 - 0x00040306, // 0012 ADD R1 R1 K6 - 0x80040200, // 0013 RET 1 R1 - 0x70020003, // 0014 JMP #0019 - 0x60040008, // 0015 GETGBL R1 G8 - 0x88080100, // 0016 GETMBR R2 R0 K0 - 0x7C040200, // 0017 CALL R1 1 - 0x80040200, // 0018 RET 1 R1 - 0x70020046, // 0019 JMP #0061 - 0x60040004, // 001A GETGBL R1 G4 - 0x88080100, // 001B GETMBR R2 R0 K0 - 0x7C040200, // 001C CALL R1 1 - 0x1C040307, // 001D EQ R1 R1 K7 - 0x78060006, // 001E JMPF R1 #0026 - 0x88040100, // 001F GETMBR R1 R0 K0 - 0x78060001, // 0020 JMPF R1 #0023 - 0x58040008, // 0021 LDCONST R1 K8 - 0x70020000, // 0022 JMP #0024 - 0x58040009, // 0023 LDCONST R1 K9 - 0x80040200, // 0024 RET 1 R1 - 0x7002003A, // 0025 JMP #0061 - 0x88040100, // 0026 GETMBR R1 R0 K0 - 0x4C080000, // 0027 LDNIL R2 - 0x1C040202, // 0028 EQ R1 R1 R2 - 0x78060001, // 0029 JMPF R1 #002C - 0x80061400, // 002A RET 1 K10 - 0x70020034, // 002B JMP #0061 - 0x60040004, // 002C GETGBL R1 G4 - 0x88080100, // 002D GETMBR R2 R0 K0 - 0x7C040200, // 002E CALL R1 1 - 0x1C04030B, // 002F EQ R1 R1 K11 - 0x78060004, // 0030 JMPF R1 #0036 - 0x60040008, // 0031 GETGBL R1 G8 - 0x88080100, // 0032 GETMBR R2 R0 K0 - 0x7C040200, // 0033 CALL R1 1 - 0x80040200, // 0034 RET 1 R1 - 0x7002002A, // 0035 JMP #0061 - 0x60040004, // 0036 GETGBL R1 G4 - 0x88080100, // 0037 GETMBR R2 R0 K0 - 0x7C040200, // 0038 CALL R1 1 - 0x1C04030C, // 0039 EQ R1 R1 K12 - 0x78060002, // 003A JMPF R1 #003E - 0x88040100, // 003B GETMBR R1 R0 K0 - 0x80040200, // 003C RET 1 R1 - 0x70020022, // 003D JMP #0061 - 0x6004000F, // 003E GETGBL R1 G15 - 0x88080100, // 003F GETMBR R2 R0 K0 - 0xB80E1A00, // 0040 GETNGBL R3 K13 - 0x7C040400, // 0041 CALL R1 2 - 0x78060014, // 0042 JMPF R1 #0058 - 0x88040102, // 0043 GETMBR R1 R0 K2 - 0x88080103, // 0044 GETMBR R2 R0 K3 - 0x88080504, // 0045 GETMBR R2 R2 K4 - 0x28040202, // 0046 GE R1 R1 R2 - 0x7806000A, // 0047 JMPF R1 #0053 - 0x88040102, // 0048 GETMBR R1 R0 K2 - 0x88080103, // 0049 GETMBR R2 R0 K3 - 0x88080505, // 004A GETMBR R2 R2 K5 - 0x18040202, // 004B LE R1 R1 R2 - 0x78060005, // 004C JMPF R1 #0053 - 0x88040100, // 004D GETMBR R1 R0 K0 - 0x8C04030E, // 004E GETMET R1 R1 K14 - 0x7C040200, // 004F CALL R1 1 - 0x00040306, // 0050 ADD R1 R1 K6 - 0x80040200, // 0051 RET 1 R1 - 0x70020003, // 0052 JMP #0057 - 0x88040100, // 0053 GETMBR R1 R0 K0 - 0x8C04030E, // 0054 GETMET R1 R1 K14 - 0x7C040200, // 0055 CALL R1 1 - 0x80040200, // 0056 RET 1 R1 - 0x70020008, // 0057 JMP #0061 - 0x60040004, // 0058 GETGBL R1 G4 - 0x88080100, // 0059 GETMBR R2 R0 K0 - 0x7C040200, // 005A CALL R1 1 - 0x1C04030F, // 005B EQ R1 R1 K15 - 0x78060003, // 005C JMPF R1 #0061 - 0x8C04010E, // 005D GETMET R1 R0 K14 - 0x500C0200, // 005E LDBOOL R3 1 0 - 0x7C040400, // 005F CALL R1 2 - 0x80040200, // 0060 RET 1 R1 - 0x80000000, // 0061 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: parse -********************************************************************/ -be_local_closure(Matter_TLV_item_parse, /* 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[25]) { /* constants */ - /* K0 */ be_nested_str_weak(typ), - /* K1 */ be_nested_str_weak(TLV), - /* K2 */ be_nested_str_weak(_len), - /* K3 */ be_nested_str_weak(val), - /* K4 */ be_nested_str_weak(int64), - /* K5 */ be_nested_str_weak(frombytes), - /* K6 */ be_nested_str_weak(BFALSE), - /* K7 */ be_nested_str_weak(BTRUE), - /* K8 */ be_nested_str_weak(U8), - /* K9 */ be_nested_str_weak(I8), - /* K10 */ be_nested_str_weak(geti), - /* K11 */ be_nested_str_weak(get), - /* K12 */ be_nested_str_weak(FLOAT), - /* K13 */ be_nested_str_weak(getfloat), - /* K14 */ be_const_int(1), - /* K15 */ be_nested_str_weak(UTF8), - /* K16 */ be_nested_str_weak(asstring), - /* K17 */ be_nested_str_weak(NULL), - /* K18 */ be_nested_str_weak(EOC), - /* K19 */ be_nested_str_weak(tasmota), - /* K20 */ be_nested_str_weak(log), - /* K21 */ be_nested_str_weak(MTR_X3A_X20unexpected_X20eoc), - /* K22 */ be_const_int(3), - /* K23 */ be_nested_str_weak(MTR_X3A_X20unexpected_X20type_X3A_X20), - /* K24 */ be_nested_str_weak(next_idx), - }), - be_str_weak(parse), - &be_const_str_solidified, - ( &(const binstruction[105]) { /* code */ - 0x880C0100, // 0000 GETMBR R3 R0 K0 - 0x88100101, // 0001 GETMBR R4 R0 K1 - 0x88140902, // 0002 GETMBR R5 R4 K2 - 0x94140A03, // 0003 GETIDX R5 R5 R3 - 0x541A0007, // 0004 LDINT R6 8 - 0x1C180A06, // 0005 EQ R6 R5 R6 - 0x781A000A, // 0006 JMPF R6 #0012 - 0xB81A0800, // 0007 GETNGBL R6 K4 - 0x7C180000, // 0008 CALL R6 0 - 0x90020606, // 0009 SETMBR R0 K3 R6 - 0x88180103, // 000A GETMBR R6 R0 K3 - 0x8C180D05, // 000B GETMET R6 R6 K5 - 0x5C200200, // 000C MOVE R8 R1 - 0x5C240400, // 000D MOVE R9 R2 - 0x7C180600, // 000E CALL R6 3 - 0x541A0007, // 000F LDINT R6 8 - 0x00080406, // 0010 ADD R2 R2 R6 - 0x70020054, // 0011 JMP #0067 - 0x88180906, // 0012 GETMBR R6 R4 K6 - 0x1C180606, // 0013 EQ R6 R3 R6 - 0x741A0002, // 0014 JMPT R6 #0018 - 0x88180907, // 0015 GETMBR R6 R4 K7 - 0x1C180606, // 0016 EQ R6 R3 R6 - 0x781A0003, // 0017 JMPF R6 #001C - 0x88180907, // 0018 GETMBR R6 R4 K7 - 0x1C180606, // 0019 EQ R6 R3 R6 - 0x90020606, // 001A SETMBR R0 K3 R6 - 0x7002004A, // 001B JMP #0067 - 0x88180908, // 001C GETMBR R6 R4 K8 - 0x14180606, // 001D LT R6 R3 R6 - 0x781A000E, // 001E JMPF R6 #002E - 0x88180909, // 001F GETMBR R6 R4 K9 - 0x18180606, // 0020 LE R6 R3 R6 - 0x781A0004, // 0021 JMPF R6 #0027 - 0x8C18030A, // 0022 GETMET R6 R1 K10 - 0x5C200400, // 0023 MOVE R8 R2 - 0x5C240A00, // 0024 MOVE R9 R5 - 0x7C180600, // 0025 CALL R6 3 - 0x70020003, // 0026 JMP #002B - 0x8C18030B, // 0027 GETMET R6 R1 K11 - 0x5C200400, // 0028 MOVE R8 R2 - 0x5C240A00, // 0029 MOVE R9 R5 - 0x7C180600, // 002A CALL R6 3 - 0x90020606, // 002B SETMBR R0 K3 R6 - 0x00080405, // 002C ADD R2 R2 R5 - 0x70020038, // 002D JMP #0067 - 0x8818090C, // 002E GETMBR R6 R4 K12 - 0x1C180606, // 002F EQ R6 R3 R6 - 0x781A0006, // 0030 JMPF R6 #0038 - 0x8C18030D, // 0031 GETMET R6 R1 K13 - 0x5C200400, // 0032 MOVE R8 R2 - 0x7C180400, // 0033 CALL R6 2 - 0x90020606, // 0034 SETMBR R0 K3 R6 - 0x541A0003, // 0035 LDINT R6 4 - 0x00080406, // 0036 ADD R2 R2 R6 - 0x7002002E, // 0037 JMP #0067 - 0x5419FFF7, // 0038 LDINT R6 -8 - 0x28180A06, // 0039 GE R6 R5 R6 - 0x781A0016, // 003A JMPF R6 #0052 - 0x5419FFFE, // 003B LDINT R6 -1 - 0x18180A06, // 003C LE R6 R5 R6 - 0x781A0013, // 003D JMPF R6 #0052 - 0x8C18030B, // 003E GETMET R6 R1 K11 - 0x5C200400, // 003F MOVE R8 R2 - 0x44240A00, // 0040 NEG R9 R5 - 0x7C180600, // 0041 CALL R6 3 - 0x441C0A00, // 0042 NEG R7 R5 - 0x00080407, // 0043 ADD R2 R2 R7 - 0x001C0406, // 0044 ADD R7 R2 R6 - 0x041C0F0E, // 0045 SUB R7 R7 K14 - 0x401C0407, // 0046 CONNECT R7 R2 R7 - 0x941C0207, // 0047 GETIDX R7 R1 R7 - 0x90020607, // 0048 SETMBR R0 K3 R7 - 0x00080406, // 0049 ADD R2 R2 R6 - 0x881C090F, // 004A GETMBR R7 R4 K15 - 0x181C0607, // 004B LE R7 R3 R7 - 0x781E0003, // 004C JMPF R7 #0051 - 0x881C0103, // 004D GETMBR R7 R0 K3 - 0x8C1C0F10, // 004E GETMET R7 R7 K16 - 0x7C1C0200, // 004F CALL R7 1 - 0x90020607, // 0050 SETMBR R0 K3 R7 - 0x70020014, // 0051 JMP #0067 - 0x88180911, // 0052 GETMBR R6 R4 K17 - 0x1C180606, // 0053 EQ R6 R3 R6 - 0x781A0000, // 0054 JMPF R6 #0056 - 0x70020010, // 0055 JMP #0067 - 0x88180912, // 0056 GETMBR R6 R4 K18 - 0x1C180606, // 0057 EQ R6 R3 R6 - 0x781A0005, // 0058 JMPF R6 #005F - 0xB81A2600, // 0059 GETNGBL R6 K19 - 0x8C180D14, // 005A GETMET R6 R6 K20 - 0x58200015, // 005B LDCONST R8 K21 - 0x58240016, // 005C LDCONST R9 K22 - 0x7C180600, // 005D CALL R6 3 - 0x70020007, // 005E JMP #0067 - 0xB81A2600, // 005F GETNGBL R6 K19 - 0x8C180D14, // 0060 GETMET R6 R6 K20 - 0x60200008, // 0061 GETGBL R8 G8 - 0x5C240600, // 0062 MOVE R9 R3 - 0x7C200200, // 0063 CALL R8 1 - 0x00222E08, // 0064 ADD R8 K23 R8 - 0x58240016, // 0065 LDCONST R9 K22 - 0x7C180600, // 0066 CALL R6 3 - 0x90023002, // 0067 SETMBR R0 K24 R2 - 0x80040400, // 0068 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** 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: 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[13]) { /* code */ - 0x58080000, // 0000 LDCONST R2 K0 - 0x4C0C0000, // 0001 LDNIL R3 - 0x200C0203, // 0002 NE R3 R1 R3 - 0x740E0002, // 0003 JMPT R3 #0007 - 0x540E0013, // 0004 LDINT R3 20 - 0x1C0C0003, // 0005 EQ R3 R0 R3 - 0x780E0004, // 0006 JMPF R3 #000C - 0x5C0C0400, // 0007 MOVE R3 R2 - 0x7C0C0000, // 0008 CALL R3 0 - 0x900E0200, // 0009 SETMBR R3 K1 R0 - 0x900E0401, // 000A SETMBR R3 K2 R1 - 0x80040600, // 000B RET 1 R3 - 0x80000000, // 000C RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: to_TLV -********************************************************************/ -be_local_closure(Matter_TLV_item_to_TLV, /* 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(to_TLV), - &be_const_str_solidified, - ( &(const binstruction[ 1]) { /* code */ - 0x80040000, // 0000 RET 1 R0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** 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_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: reset -********************************************************************/ -be_local_closure(Matter_TLV_item_reset, /* 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[ 8]) { /* constants */ - /* K0 */ be_nested_str_weak(parent), - /* K1 */ be_nested_str_weak(next_idx), - /* K2 */ be_nested_str_weak(tag_vendor), - /* K3 */ be_nested_str_weak(tag_profile), - /* K4 */ be_nested_str_weak(tag_number), - /* K5 */ be_nested_str_weak(tag_sub), - /* K6 */ be_nested_str_weak(typ), - /* K7 */ be_nested_str_weak(val), - }), - be_str_weak(reset), - &be_const_str_solidified, - ( &(const binstruction[10]) { /* code */ - 0x4C080000, // 0000 LDNIL R2 - 0x90020001, // 0001 SETMBR R0 K0 R1 - 0x90020202, // 0002 SETMBR R0 K1 R2 - 0x90020402, // 0003 SETMBR R0 K2 R2 - 0x90020602, // 0004 SETMBR R0 K3 R2 - 0x90020802, // 0005 SETMBR R0 K4 R2 - 0x90020A02, // 0006 SETMBR R0 K5 R2 - 0x90020C02, // 0007 SETMBR R0 K6 R2 - 0x90020E02, // 0008 SETMBR R0 K7 R2 - 0x80000000, // 0009 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** 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_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: 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: tostring -********************************************************************/ -be_local_closure(Matter_TLV_item_tostring, /* 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[34]) { /* constants */ - /* K0 */ be_nested_str_weak(), - /* K1 */ be_nested_str_weak(tag_profile), - /* K2 */ be_nested_str_weak(Matter_X3A_X3A), - /* K3 */ be_nested_str_weak(tag_number), - /* K4 */ be_nested_str_weak(0x_X2508X_X20), - /* K5 */ be_nested_str_weak(tag_vendor), - /* K6 */ be_nested_str_weak(0x_X2504X_X3A_X3A), - /* K7 */ be_nested_str_weak(0x_X2504X_X3A), - /* K8 */ be_nested_str_weak(tag_sub), - /* K9 */ be_nested_str_weak(_X25i_X20), - /* K10 */ be_const_int(0), - /* K11 */ be_nested_str_weak(_X3D_X20), - /* K12 */ be_nested_str_weak(val), - /* K13 */ be_nested_str_weak(int), - /* K14 */ be_nested_str_weak(_X25i), - /* K15 */ be_nested_str_weak(typ), - /* K16 */ be_nested_str_weak(TLV), - /* K17 */ be_nested_str_weak(U1), - /* K18 */ be_nested_str_weak(U8), - /* K19 */ be_nested_str_weak(U), - /* K20 */ be_nested_str_weak(bool), - /* K21 */ be_nested_str_weak(true), - /* K22 */ be_nested_str_weak(false), - /* K23 */ be_nested_str_weak(null), - /* K24 */ be_nested_str_weak(real), - /* K25 */ be_nested_str_weak(_X25g), - /* K26 */ be_nested_str_weak(string), - /* K27 */ be_nested_str_weak(_X22_X25s_X22), - /* K28 */ be_nested_str_weak(int64), - /* K29 */ be_nested_str_weak(tostring), - /* K30 */ be_nested_str_weak(instance), - /* K31 */ be_nested_str_weak(_X25s), - /* K32 */ be_nested_str_weak(tohex), - /* K33 */ be_nested_str_weak(_X20), - }), - be_str_weak(tostring), - &be_const_str_solidified, - ( &(const binstruction[167]) { /* code */ - 0x58080000, // 0000 LDCONST R2 K0 - 0xA802009C, // 0001 EXBLK 0 #009F - 0x500C0200, // 0002 LDBOOL R3 1 0 - 0x200C0203, // 0003 NE R3 R1 R3 - 0x780E0038, // 0004 JMPF R3 #003E - 0x880C0101, // 0005 GETMBR R3 R0 K1 - 0x5411FFFE, // 0006 LDINT R4 -1 - 0x1C0C0604, // 0007 EQ R3 R3 R4 - 0x780E000A, // 0008 JMPF R3 #0014 - 0x00080502, // 0009 ADD R2 R2 K2 - 0x880C0103, // 000A GETMBR R3 R0 K3 - 0x4C100000, // 000B LDNIL R4 - 0x200C0604, // 000C NE R3 R3 R4 - 0x780E0004, // 000D JMPF R3 #0013 - 0x600C0018, // 000E GETGBL R3 G24 - 0x58100004, // 000F LDCONST R4 K4 - 0x88140103, // 0010 GETMBR R5 R0 K3 - 0x7C0C0400, // 0011 CALL R3 2 - 0x00080403, // 0012 ADD R2 R2 R3 - 0x70020023, // 0013 JMP #0038 - 0x880C0105, // 0014 GETMBR R3 R0 K5 - 0x4C100000, // 0015 LDNIL R4 - 0x200C0604, // 0016 NE R3 R3 R4 - 0x780E0004, // 0017 JMPF R3 #001D - 0x600C0018, // 0018 GETGBL R3 G24 - 0x58100006, // 0019 LDCONST R4 K6 - 0x88140105, // 001A GETMBR R5 R0 K5 - 0x7C0C0400, // 001B CALL R3 2 - 0x00080403, // 001C ADD R2 R2 R3 - 0x880C0101, // 001D GETMBR R3 R0 K1 - 0x4C100000, // 001E LDNIL R4 - 0x200C0604, // 001F NE R3 R3 R4 - 0x780E0004, // 0020 JMPF R3 #0026 - 0x600C0018, // 0021 GETGBL R3 G24 - 0x58100007, // 0022 LDCONST R4 K7 - 0x88140101, // 0023 GETMBR R5 R0 K1 - 0x7C0C0400, // 0024 CALL R3 2 - 0x00080403, // 0025 ADD R2 R2 R3 - 0x880C0103, // 0026 GETMBR R3 R0 K3 - 0x4C100000, // 0027 LDNIL R4 - 0x200C0604, // 0028 NE R3 R3 R4 - 0x780E0004, // 0029 JMPF R3 #002F - 0x600C0018, // 002A GETGBL R3 G24 - 0x58100004, // 002B LDCONST R4 K4 - 0x88140103, // 002C GETMBR R5 R0 K3 - 0x7C0C0400, // 002D CALL R3 2 - 0x00080403, // 002E ADD R2 R2 R3 - 0x880C0108, // 002F GETMBR R3 R0 K8 - 0x4C100000, // 0030 LDNIL R4 - 0x200C0604, // 0031 NE R3 R3 R4 - 0x780E0004, // 0032 JMPF R3 #0038 - 0x600C0018, // 0033 GETGBL R3 G24 - 0x58100009, // 0034 LDCONST R4 K9 - 0x88140108, // 0035 GETMBR R5 R0 K8 - 0x7C0C0400, // 0036 CALL R3 2 - 0x00080403, // 0037 ADD R2 R2 R3 - 0x600C000C, // 0038 GETGBL R3 G12 - 0x5C100400, // 0039 MOVE R4 R2 - 0x7C0C0200, // 003A CALL R3 1 - 0x240C070A, // 003B GT R3 R3 K10 - 0x780E0000, // 003C JMPF R3 #003E - 0x0008050B, // 003D ADD R2 R2 K11 - 0x600C0004, // 003E GETGBL R3 G4 - 0x8810010C, // 003F GETMBR R4 R0 K12 - 0x7C0C0200, // 0040 CALL R3 1 - 0x1C0C070D, // 0041 EQ R3 R3 K13 - 0x780E0010, // 0042 JMPF R3 #0054 - 0x600C0018, // 0043 GETGBL R3 G24 - 0x5810000E, // 0044 LDCONST R4 K14 - 0x8814010C, // 0045 GETMBR R5 R0 K12 - 0x7C0C0400, // 0046 CALL R3 2 - 0x00080403, // 0047 ADD R2 R2 R3 - 0x880C010F, // 0048 GETMBR R3 R0 K15 - 0x88100110, // 0049 GETMBR R4 R0 K16 - 0x88100911, // 004A GETMBR R4 R4 K17 - 0x280C0604, // 004B GE R3 R3 R4 - 0x780E0005, // 004C JMPF R3 #0053 - 0x880C010F, // 004D GETMBR R3 R0 K15 - 0x88100110, // 004E GETMBR R4 R0 K16 - 0x88100912, // 004F GETMBR R4 R4 K18 - 0x180C0604, // 0050 LE R3 R3 R4 - 0x780E0000, // 0051 JMPF R3 #0053 - 0x00080513, // 0052 ADD R2 R2 K19 - 0x70020048, // 0053 JMP #009D - 0x600C0004, // 0054 GETGBL R3 G4 - 0x8810010C, // 0055 GETMBR R4 R0 K12 - 0x7C0C0200, // 0056 CALL R3 1 - 0x1C0C0714, // 0057 EQ R3 R3 K20 - 0x780E0006, // 0058 JMPF R3 #0060 - 0x880C010C, // 0059 GETMBR R3 R0 K12 - 0x780E0001, // 005A JMPF R3 #005D - 0x580C0015, // 005B LDCONST R3 K21 - 0x70020000, // 005C JMP #005E - 0x580C0016, // 005D LDCONST R3 K22 - 0x00080403, // 005E ADD R2 R2 R3 - 0x7002003C, // 005F JMP #009D - 0x880C010C, // 0060 GETMBR R3 R0 K12 - 0x4C100000, // 0061 LDNIL R4 - 0x1C0C0604, // 0062 EQ R3 R3 R4 - 0x780E0001, // 0063 JMPF R3 #0066 - 0x00080517, // 0064 ADD R2 R2 K23 - 0x70020036, // 0065 JMP #009D - 0x600C0004, // 0066 GETGBL R3 G4 - 0x8810010C, // 0067 GETMBR R4 R0 K12 - 0x7C0C0200, // 0068 CALL R3 1 - 0x1C0C0718, // 0069 EQ R3 R3 K24 - 0x780E0005, // 006A JMPF R3 #0071 - 0x600C0018, // 006B GETGBL R3 G24 - 0x58100019, // 006C LDCONST R4 K25 - 0x8814010C, // 006D GETMBR R5 R0 K12 - 0x7C0C0400, // 006E CALL R3 2 - 0x00080403, // 006F ADD R2 R2 R3 - 0x7002002B, // 0070 JMP #009D - 0x600C0004, // 0071 GETGBL R3 G4 - 0x8810010C, // 0072 GETMBR R4 R0 K12 - 0x7C0C0200, // 0073 CALL R3 1 - 0x1C0C071A, // 0074 EQ R3 R3 K26 - 0x780E0005, // 0075 JMPF R3 #007C - 0x600C0018, // 0076 GETGBL R3 G24 - 0x5810001B, // 0077 LDCONST R4 K27 - 0x8814010C, // 0078 GETMBR R5 R0 K12 - 0x7C0C0400, // 0079 CALL R3 2 - 0x00080403, // 007A ADD R2 R2 R3 - 0x70020020, // 007B JMP #009D - 0x600C000F, // 007C GETGBL R3 G15 - 0x8810010C, // 007D GETMBR R4 R0 K12 - 0xB8163800, // 007E GETNGBL R5 K28 - 0x7C0C0400, // 007F CALL R3 2 - 0x780E000F, // 0080 JMPF R3 #0091 - 0x880C010C, // 0081 GETMBR R3 R0 K12 - 0x8C0C071D, // 0082 GETMET R3 R3 K29 - 0x7C0C0200, // 0083 CALL R3 1 - 0x00080403, // 0084 ADD R2 R2 R3 - 0x880C010F, // 0085 GETMBR R3 R0 K15 - 0x88100110, // 0086 GETMBR R4 R0 K16 - 0x88100911, // 0087 GETMBR R4 R4 K17 - 0x280C0604, // 0088 GE R3 R3 R4 - 0x780E0005, // 0089 JMPF R3 #0090 - 0x880C010F, // 008A GETMBR R3 R0 K15 - 0x88100110, // 008B GETMBR R4 R0 K16 - 0x88100912, // 008C GETMBR R4 R4 K18 - 0x180C0604, // 008D LE R3 R3 R4 - 0x780E0000, // 008E JMPF R3 #0090 - 0x00080513, // 008F ADD R2 R2 K19 - 0x7002000B, // 0090 JMP #009D - 0x600C0004, // 0091 GETGBL R3 G4 - 0x8810010C, // 0092 GETMBR R4 R0 K12 - 0x7C0C0200, // 0093 CALL R3 1 - 0x1C0C071E, // 0094 EQ R3 R3 K30 - 0x780E0006, // 0095 JMPF R3 #009D - 0x600C0018, // 0096 GETGBL R3 G24 - 0x5810001F, // 0097 LDCONST R4 K31 - 0x8814010C, // 0098 GETMBR R5 R0 K12 - 0x8C140B20, // 0099 GETMET R5 R5 K32 - 0x7C140200, // 009A CALL R5 1 - 0x7C0C0400, // 009B CALL R3 2 - 0x00080403, // 009C ADD R2 R2 R3 - 0xA8040001, // 009D EXBLK 1 1 - 0x70020006, // 009E JMP #00A6 - 0xAC0C0002, // 009F CATCH R3 0 2 - 0x70020003, // 00A0 JMP #00A5 - 0x00140721, // 00A1 ADD R5 R3 K33 - 0x00140A04, // 00A2 ADD R5 R5 R4 - 0x80040A00, // 00A3 RET 1 R5 - 0x70020000, // 00A4 JMP #00A6 - 0xB0080000, // 00A5 RAISE 2 R0 R0 - 0x80040400, // 00A6 RET 1 R2 + 0x000E3E03, // 00FF ADD R3 K31 R3 + 0xB0063803, // 0100 RAISE 1 K28 R3 + 0x80040400, // 0101 RET 1 R2 }) ) ); @@ -1377,11 +648,247 @@ be_local_closure(Matter_TLV_item_tostring, /* name */ /******************************************************************** -** Solidified function: set_anonymoustag +** Solidified function: reset ********************************************************************/ -be_local_closure(Matter_TLV_item_set_anonymoustag, /* name */ +be_local_closure(Matter_TLV_item_reset, /* 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[ 8]) { /* constants */ + /* K0 */ be_nested_str_weak(parent), + /* K1 */ be_nested_str_weak(next_idx), + /* K2 */ be_nested_str_weak(tag_vendor), + /* K3 */ be_nested_str_weak(tag_profile), + /* K4 */ be_nested_str_weak(tag_number), + /* K5 */ be_nested_str_weak(tag_sub), + /* K6 */ be_nested_str_weak(typ), + /* K7 */ be_nested_str_weak(val), + }), + be_str_weak(reset), + &be_const_str_solidified, + ( &(const binstruction[10]) { /* code */ + 0x4C080000, // 0000 LDNIL R2 + 0x90020001, // 0001 SETMBR R0 K0 R1 + 0x90020202, // 0002 SETMBR R0 K1 R2 + 0x90020402, // 0003 SETMBR R0 K2 R2 + 0x90020602, // 0004 SETMBR R0 K3 R2 + 0x90020802, // 0005 SETMBR R0 K4 R2 + 0x90020A02, // 0006 SETMBR R0 K5 R2 + 0x90020C02, // 0007 SETMBR R0 K6 R2 + 0x90020E02, // 0008 SETMBR R0 K7 R2 + 0x80000000, // 0009 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[13]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0x4C0C0000, // 0001 LDNIL R3 + 0x200C0203, // 0002 NE R3 R1 R3 + 0x740E0002, // 0003 JMPT R3 #0007 + 0x540E0013, // 0004 LDINT R3 20 + 0x1C0C0003, // 0005 EQ R3 R0 R3 + 0x780E0004, // 0006 JMPF R3 #000C + 0x5C0C0400, // 0007 MOVE R3 R2 + 0x7C0C0000, // 0008 CALL R3 0 + 0x900E0200, // 0009 SETMBR R3 K1 R0 + 0x900E0401, // 000A SETMBR R3 K2 R1 + 0x80040600, // 000B RET 1 R3 + 0x80000000, // 000C RET 0 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** Solidified function: parse +********************************************************************/ +be_local_closure(Matter_TLV_item_parse, /* 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[25]) { /* constants */ + /* K0 */ be_nested_str_weak(typ), + /* K1 */ be_nested_str_weak(TLV), + /* K2 */ be_nested_str_weak(_len), + /* K3 */ be_nested_str_weak(val), + /* K4 */ be_nested_str_weak(int64), + /* K5 */ be_nested_str_weak(frombytes), + /* K6 */ be_nested_str_weak(BFALSE), + /* K7 */ be_nested_str_weak(BTRUE), + /* K8 */ be_nested_str_weak(U8), + /* K9 */ be_nested_str_weak(I8), + /* K10 */ be_nested_str_weak(geti), + /* K11 */ be_nested_str_weak(get), + /* K12 */ be_nested_str_weak(FLOAT), + /* K13 */ be_nested_str_weak(getfloat), + /* K14 */ be_const_int(1), + /* K15 */ be_nested_str_weak(UTF8), + /* K16 */ be_nested_str_weak(asstring), + /* K17 */ be_nested_str_weak(NULL), + /* K18 */ be_nested_str_weak(EOC), + /* K19 */ be_nested_str_weak(tasmota), + /* K20 */ be_nested_str_weak(log), + /* K21 */ be_nested_str_weak(MTR_X3A_X20unexpected_X20eoc), + /* K22 */ be_const_int(3), + /* K23 */ be_nested_str_weak(MTR_X3A_X20unexpected_X20type_X3A_X20), + /* K24 */ be_nested_str_weak(next_idx), + }), + be_str_weak(parse), + &be_const_str_solidified, + ( &(const binstruction[105]) { /* code */ + 0x880C0100, // 0000 GETMBR R3 R0 K0 + 0x88100101, // 0001 GETMBR R4 R0 K1 + 0x88140902, // 0002 GETMBR R5 R4 K2 + 0x94140A03, // 0003 GETIDX R5 R5 R3 + 0x541A0007, // 0004 LDINT R6 8 + 0x1C180A06, // 0005 EQ R6 R5 R6 + 0x781A000A, // 0006 JMPF R6 #0012 + 0xB81A0800, // 0007 GETNGBL R6 K4 + 0x7C180000, // 0008 CALL R6 0 + 0x90020606, // 0009 SETMBR R0 K3 R6 + 0x88180103, // 000A GETMBR R6 R0 K3 + 0x8C180D05, // 000B GETMET R6 R6 K5 + 0x5C200200, // 000C MOVE R8 R1 + 0x5C240400, // 000D MOVE R9 R2 + 0x7C180600, // 000E CALL R6 3 + 0x541A0007, // 000F LDINT R6 8 + 0x00080406, // 0010 ADD R2 R2 R6 + 0x70020054, // 0011 JMP #0067 + 0x88180906, // 0012 GETMBR R6 R4 K6 + 0x1C180606, // 0013 EQ R6 R3 R6 + 0x741A0002, // 0014 JMPT R6 #0018 + 0x88180907, // 0015 GETMBR R6 R4 K7 + 0x1C180606, // 0016 EQ R6 R3 R6 + 0x781A0003, // 0017 JMPF R6 #001C + 0x88180907, // 0018 GETMBR R6 R4 K7 + 0x1C180606, // 0019 EQ R6 R3 R6 + 0x90020606, // 001A SETMBR R0 K3 R6 + 0x7002004A, // 001B JMP #0067 + 0x88180908, // 001C GETMBR R6 R4 K8 + 0x14180606, // 001D LT R6 R3 R6 + 0x781A000E, // 001E JMPF R6 #002E + 0x88180909, // 001F GETMBR R6 R4 K9 + 0x18180606, // 0020 LE R6 R3 R6 + 0x781A0004, // 0021 JMPF R6 #0027 + 0x8C18030A, // 0022 GETMET R6 R1 K10 + 0x5C200400, // 0023 MOVE R8 R2 + 0x5C240A00, // 0024 MOVE R9 R5 + 0x7C180600, // 0025 CALL R6 3 + 0x70020003, // 0026 JMP #002B + 0x8C18030B, // 0027 GETMET R6 R1 K11 + 0x5C200400, // 0028 MOVE R8 R2 + 0x5C240A00, // 0029 MOVE R9 R5 + 0x7C180600, // 002A CALL R6 3 + 0x90020606, // 002B SETMBR R0 K3 R6 + 0x00080405, // 002C ADD R2 R2 R5 + 0x70020038, // 002D JMP #0067 + 0x8818090C, // 002E GETMBR R6 R4 K12 + 0x1C180606, // 002F EQ R6 R3 R6 + 0x781A0006, // 0030 JMPF R6 #0038 + 0x8C18030D, // 0031 GETMET R6 R1 K13 + 0x5C200400, // 0032 MOVE R8 R2 + 0x7C180400, // 0033 CALL R6 2 + 0x90020606, // 0034 SETMBR R0 K3 R6 + 0x541A0003, // 0035 LDINT R6 4 + 0x00080406, // 0036 ADD R2 R2 R6 + 0x7002002E, // 0037 JMP #0067 + 0x5419FFF7, // 0038 LDINT R6 -8 + 0x28180A06, // 0039 GE R6 R5 R6 + 0x781A0016, // 003A JMPF R6 #0052 + 0x5419FFFE, // 003B LDINT R6 -1 + 0x18180A06, // 003C LE R6 R5 R6 + 0x781A0013, // 003D JMPF R6 #0052 + 0x8C18030B, // 003E GETMET R6 R1 K11 + 0x5C200400, // 003F MOVE R8 R2 + 0x44240A00, // 0040 NEG R9 R5 + 0x7C180600, // 0041 CALL R6 3 + 0x441C0A00, // 0042 NEG R7 R5 + 0x00080407, // 0043 ADD R2 R2 R7 + 0x001C0406, // 0044 ADD R7 R2 R6 + 0x041C0F0E, // 0045 SUB R7 R7 K14 + 0x401C0407, // 0046 CONNECT R7 R2 R7 + 0x941C0207, // 0047 GETIDX R7 R1 R7 + 0x90020607, // 0048 SETMBR R0 K3 R7 + 0x00080406, // 0049 ADD R2 R2 R6 + 0x881C090F, // 004A GETMBR R7 R4 K15 + 0x181C0607, // 004B LE R7 R3 R7 + 0x781E0003, // 004C JMPF R7 #0051 + 0x881C0103, // 004D GETMBR R7 R0 K3 + 0x8C1C0F10, // 004E GETMET R7 R7 K16 + 0x7C1C0200, // 004F CALL R7 1 + 0x90020607, // 0050 SETMBR R0 K3 R7 + 0x70020014, // 0051 JMP #0067 + 0x88180911, // 0052 GETMBR R6 R4 K17 + 0x1C180606, // 0053 EQ R6 R3 R6 + 0x781A0000, // 0054 JMPF R6 #0056 + 0x70020010, // 0055 JMP #0067 + 0x88180912, // 0056 GETMBR R6 R4 K18 + 0x1C180606, // 0057 EQ R6 R3 R6 + 0x781A0005, // 0058 JMPF R6 #005F + 0xB81A2600, // 0059 GETNGBL R6 K19 + 0x8C180D14, // 005A GETMET R6 R6 K20 + 0x58200015, // 005B LDCONST R8 K21 + 0x58240016, // 005C LDCONST R9 K22 + 0x7C180600, // 005D CALL R6 3 + 0x70020007, // 005E JMP #0067 + 0xB81A2600, // 005F GETNGBL R6 K19 + 0x8C180D14, // 0060 GETMET R6 R6 K20 + 0x60200008, // 0061 GETGBL R8 G8 + 0x5C240600, // 0062 MOVE R9 R3 + 0x7C200200, // 0063 CALL R8 1 + 0x00222E08, // 0064 ADD R8 K23 R8 + 0x58240016, // 0065 LDCONST R9 K22 + 0x7C180600, // 0066 CALL R6 3 + 0x90023002, // 0067 SETMBR R0 K24 R2 + 0x80040400, // 0068 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + +/******************************************************************** +** 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 */ @@ -1389,15 +896,73 @@ be_local_closure(Matter_TLV_item_set_anonymoustag, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 1]) { /* constants */ - /* K0 */ be_nested_str_weak(set_fulltag), + ( &(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(set_anonymoustag), + be_str_weak(_encode_tag_len), &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ - 0x8C040100, // 0000 GETMET R1 R0 K0 - 0x7C040200, // 0001 CALL R1 1 - 0x80000000, // 0002 RET 0 + ( &(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 }) ) ); @@ -1405,26 +970,38 @@ be_local_closure(Matter_TLV_item_set_anonymoustag, /* name */ /******************************************************************** -** Solidified function: init +** Solidified function: set ********************************************************************/ -be_local_closure(Matter_TLV_item_init, /* name */ +be_local_closure(Matter_TLV_item_set, /* name */ be_nested_proto( - 2, /* nstack */ - 2, /* argc */ + 5, /* nstack */ + 3, /* 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), + ( &(const bvalue[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(reset), + /* K1 */ be_nested_str_weak(typ), + /* K2 */ be_nested_str_weak(val), }), - be_str_weak(init), + be_str_weak(set), &be_const_str_solidified, - ( &(const binstruction[ 2]) { /* code */ - 0x90020001, // 0000 SETMBR R0 K0 R1 - 0x80000000, // 0001 RET 0 + ( &(const binstruction[12]) { /* code */ + 0x8C0C0100, // 0000 GETMET R3 R0 K0 + 0x7C0C0200, // 0001 CALL R3 1 + 0x4C0C0000, // 0002 LDNIL R3 + 0x200C0403, // 0003 NE R3 R2 R3 + 0x740E0002, // 0004 JMPT R3 #0008 + 0x540E0013, // 0005 LDINT R3 20 + 0x1C0C0203, // 0006 EQ R3 R1 R3 + 0x780E0002, // 0007 JMPF R3 #000B + 0x90020201, // 0008 SETMBR R0 K1 R1 + 0x90020402, // 0009 SETMBR R0 K2 R2 + 0x80040000, // 000A RET 1 R0 + 0x80000000, // 000B RET 0 }) ) ); @@ -1866,85 +1443,520 @@ be_local_closure(Matter_TLV_item_tlv2raw, /* name */ /******************************************************************** -** Solidified function: _encode_tag_len +** 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: _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: _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: tostring ********************************************************************/ -be_local_closure(Matter_TLV_item__encode_tag_len, /* name */ +be_local_closure(Matter_TLV_item_tostring, /* name */ be_nested_proto( - 6, /* nstack */ - 1, /* argc */ + 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[ 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), + ( &(const bvalue[34]) { /* constants */ + /* K0 */ be_nested_str_weak(), + /* K1 */ be_nested_str_weak(tag_profile), + /* K2 */ be_nested_str_weak(Matter_X3A_X3A), + /* K3 */ be_nested_str_weak(tag_number), + /* K4 */ be_nested_str_weak(0x_X2508X_X20), + /* K5 */ be_nested_str_weak(tag_vendor), + /* K6 */ be_nested_str_weak(0x_X2504X_X3A_X3A), + /* K7 */ be_nested_str_weak(0x_X2504X_X3A), + /* K8 */ be_nested_str_weak(tag_sub), + /* K9 */ be_nested_str_weak(_X25i_X20), + /* K10 */ be_const_int(0), + /* K11 */ be_nested_str_weak(_X3D_X20), + /* K12 */ be_nested_str_weak(val), + /* K13 */ be_nested_str_weak(int), + /* K14 */ be_nested_str_weak(_X25i), + /* K15 */ be_nested_str_weak(typ), + /* K16 */ be_nested_str_weak(TLV), + /* K17 */ be_nested_str_weak(U1), + /* K18 */ be_nested_str_weak(U8), + /* K19 */ be_nested_str_weak(U), + /* K20 */ be_nested_str_weak(bool), + /* K21 */ be_nested_str_weak(true), + /* K22 */ be_nested_str_weak(false), + /* K23 */ be_nested_str_weak(null), + /* K24 */ be_nested_str_weak(real), + /* K25 */ be_nested_str_weak(_X25g), + /* K26 */ be_nested_str_weak(string), + /* K27 */ be_nested_str_weak(_X22_X25s_X22), + /* K28 */ be_nested_str_weak(int64), + /* K29 */ be_nested_str_weak(tostring), + /* K30 */ be_nested_str_weak(instance), + /* K31 */ be_nested_str_weak(_X25s), + /* K32 */ be_nested_str_weak(tohex), + /* K33 */ be_nested_str_weak(_X20), }), - be_str_weak(_encode_tag_len), + be_str_weak(tostring), &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 + ( &(const binstruction[167]) { /* code */ + 0x58080000, // 0000 LDCONST R2 K0 + 0xA802009C, // 0001 EXBLK 0 #009F + 0x500C0200, // 0002 LDBOOL R3 1 0 + 0x200C0203, // 0003 NE R3 R1 R3 + 0x780E0038, // 0004 JMPF R3 #003E + 0x880C0101, // 0005 GETMBR R3 R0 K1 + 0x5411FFFE, // 0006 LDINT R4 -1 + 0x1C0C0604, // 0007 EQ R3 R3 R4 + 0x780E000A, // 0008 JMPF R3 #0014 + 0x00080502, // 0009 ADD R2 R2 K2 + 0x880C0103, // 000A GETMBR R3 R0 K3 + 0x4C100000, // 000B LDNIL R4 + 0x200C0604, // 000C NE R3 R3 R4 + 0x780E0004, // 000D JMPF R3 #0013 + 0x600C0018, // 000E GETGBL R3 G24 + 0x58100004, // 000F LDCONST R4 K4 + 0x88140103, // 0010 GETMBR R5 R0 K3 + 0x7C0C0400, // 0011 CALL R3 2 + 0x00080403, // 0012 ADD R2 R2 R3 + 0x70020023, // 0013 JMP #0038 + 0x880C0105, // 0014 GETMBR R3 R0 K5 + 0x4C100000, // 0015 LDNIL R4 + 0x200C0604, // 0016 NE R3 R3 R4 + 0x780E0004, // 0017 JMPF R3 #001D + 0x600C0018, // 0018 GETGBL R3 G24 + 0x58100006, // 0019 LDCONST R4 K6 + 0x88140105, // 001A GETMBR R5 R0 K5 + 0x7C0C0400, // 001B CALL R3 2 + 0x00080403, // 001C ADD R2 R2 R3 + 0x880C0101, // 001D GETMBR R3 R0 K1 + 0x4C100000, // 001E LDNIL R4 + 0x200C0604, // 001F NE R3 R3 R4 + 0x780E0004, // 0020 JMPF R3 #0026 + 0x600C0018, // 0021 GETGBL R3 G24 + 0x58100007, // 0022 LDCONST R4 K7 + 0x88140101, // 0023 GETMBR R5 R0 K1 + 0x7C0C0400, // 0024 CALL R3 2 + 0x00080403, // 0025 ADD R2 R2 R3 + 0x880C0103, // 0026 GETMBR R3 R0 K3 + 0x4C100000, // 0027 LDNIL R4 + 0x200C0604, // 0028 NE R3 R3 R4 + 0x780E0004, // 0029 JMPF R3 #002F + 0x600C0018, // 002A GETGBL R3 G24 + 0x58100004, // 002B LDCONST R4 K4 + 0x88140103, // 002C GETMBR R5 R0 K3 + 0x7C0C0400, // 002D CALL R3 2 + 0x00080403, // 002E ADD R2 R2 R3 + 0x880C0108, // 002F GETMBR R3 R0 K8 + 0x4C100000, // 0030 LDNIL R4 + 0x200C0604, // 0031 NE R3 R3 R4 + 0x780E0004, // 0032 JMPF R3 #0038 + 0x600C0018, // 0033 GETGBL R3 G24 + 0x58100009, // 0034 LDCONST R4 K9 + 0x88140108, // 0035 GETMBR R5 R0 K8 + 0x7C0C0400, // 0036 CALL R3 2 + 0x00080403, // 0037 ADD R2 R2 R3 + 0x600C000C, // 0038 GETGBL R3 G12 + 0x5C100400, // 0039 MOVE R4 R2 + 0x7C0C0200, // 003A CALL R3 1 + 0x240C070A, // 003B GT R3 R3 K10 + 0x780E0000, // 003C JMPF R3 #003E + 0x0008050B, // 003D ADD R2 R2 K11 + 0x600C0004, // 003E GETGBL R3 G4 + 0x8810010C, // 003F GETMBR R4 R0 K12 + 0x7C0C0200, // 0040 CALL R3 1 + 0x1C0C070D, // 0041 EQ R3 R3 K13 + 0x780E0010, // 0042 JMPF R3 #0054 + 0x600C0018, // 0043 GETGBL R3 G24 + 0x5810000E, // 0044 LDCONST R4 K14 + 0x8814010C, // 0045 GETMBR R5 R0 K12 + 0x7C0C0400, // 0046 CALL R3 2 + 0x00080403, // 0047 ADD R2 R2 R3 + 0x880C010F, // 0048 GETMBR R3 R0 K15 + 0x88100110, // 0049 GETMBR R4 R0 K16 + 0x88100911, // 004A GETMBR R4 R4 K17 + 0x280C0604, // 004B GE R3 R3 R4 + 0x780E0005, // 004C JMPF R3 #0053 + 0x880C010F, // 004D GETMBR R3 R0 K15 + 0x88100110, // 004E GETMBR R4 R0 K16 + 0x88100912, // 004F GETMBR R4 R4 K18 + 0x180C0604, // 0050 LE R3 R3 R4 + 0x780E0000, // 0051 JMPF R3 #0053 + 0x00080513, // 0052 ADD R2 R2 K19 + 0x70020048, // 0053 JMP #009D + 0x600C0004, // 0054 GETGBL R3 G4 + 0x8810010C, // 0055 GETMBR R4 R0 K12 + 0x7C0C0200, // 0056 CALL R3 1 + 0x1C0C0714, // 0057 EQ R3 R3 K20 + 0x780E0006, // 0058 JMPF R3 #0060 + 0x880C010C, // 0059 GETMBR R3 R0 K12 + 0x780E0001, // 005A JMPF R3 #005D + 0x580C0015, // 005B LDCONST R3 K21 + 0x70020000, // 005C JMP #005E + 0x580C0016, // 005D LDCONST R3 K22 + 0x00080403, // 005E ADD R2 R2 R3 + 0x7002003C, // 005F JMP #009D + 0x880C010C, // 0060 GETMBR R3 R0 K12 + 0x4C100000, // 0061 LDNIL R4 + 0x1C0C0604, // 0062 EQ R3 R3 R4 + 0x780E0001, // 0063 JMPF R3 #0066 + 0x00080517, // 0064 ADD R2 R2 K23 + 0x70020036, // 0065 JMP #009D + 0x600C0004, // 0066 GETGBL R3 G4 + 0x8810010C, // 0067 GETMBR R4 R0 K12 + 0x7C0C0200, // 0068 CALL R3 1 + 0x1C0C0718, // 0069 EQ R3 R3 K24 + 0x780E0005, // 006A JMPF R3 #0071 + 0x600C0018, // 006B GETGBL R3 G24 + 0x58100019, // 006C LDCONST R4 K25 + 0x8814010C, // 006D GETMBR R5 R0 K12 + 0x7C0C0400, // 006E CALL R3 2 + 0x00080403, // 006F ADD R2 R2 R3 + 0x7002002B, // 0070 JMP #009D + 0x600C0004, // 0071 GETGBL R3 G4 + 0x8810010C, // 0072 GETMBR R4 R0 K12 + 0x7C0C0200, // 0073 CALL R3 1 + 0x1C0C071A, // 0074 EQ R3 R3 K26 + 0x780E0005, // 0075 JMPF R3 #007C + 0x600C0018, // 0076 GETGBL R3 G24 + 0x5810001B, // 0077 LDCONST R4 K27 + 0x8814010C, // 0078 GETMBR R5 R0 K12 + 0x7C0C0400, // 0079 CALL R3 2 + 0x00080403, // 007A ADD R2 R2 R3 + 0x70020020, // 007B JMP #009D + 0x600C000F, // 007C GETGBL R3 G15 + 0x8810010C, // 007D GETMBR R4 R0 K12 + 0xB8163800, // 007E GETNGBL R5 K28 + 0x7C0C0400, // 007F CALL R3 2 + 0x780E000F, // 0080 JMPF R3 #0091 + 0x880C010C, // 0081 GETMBR R3 R0 K12 + 0x8C0C071D, // 0082 GETMET R3 R3 K29 + 0x7C0C0200, // 0083 CALL R3 1 + 0x00080403, // 0084 ADD R2 R2 R3 + 0x880C010F, // 0085 GETMBR R3 R0 K15 + 0x88100110, // 0086 GETMBR R4 R0 K16 + 0x88100911, // 0087 GETMBR R4 R4 K17 + 0x280C0604, // 0088 GE R3 R3 R4 + 0x780E0005, // 0089 JMPF R3 #0090 + 0x880C010F, // 008A GETMBR R3 R0 K15 + 0x88100110, // 008B GETMBR R4 R0 K16 + 0x88100912, // 008C GETMBR R4 R4 K18 + 0x180C0604, // 008D LE R3 R3 R4 + 0x780E0000, // 008E JMPF R3 #0090 + 0x00080513, // 008F ADD R2 R2 K19 + 0x7002000B, // 0090 JMP #009D + 0x600C0004, // 0091 GETGBL R3 G4 + 0x8810010C, // 0092 GETMBR R4 R0 K12 + 0x7C0C0200, // 0093 CALL R3 1 + 0x1C0C071E, // 0094 EQ R3 R3 K30 + 0x780E0006, // 0095 JMPF R3 #009D + 0x600C0018, // 0096 GETGBL R3 G24 + 0x5810001F, // 0097 LDCONST R4 K31 + 0x8814010C, // 0098 GETMBR R5 R0 K12 + 0x8C140B20, // 0099 GETMET R5 R5 K32 + 0x7C140200, // 009A CALL R5 1 + 0x7C0C0400, // 009B CALL R3 2 + 0x00080403, // 009C ADD R2 R2 R3 + 0xA8040001, // 009D EXBLK 1 1 + 0x70020006, // 009E JMP #00A6 + 0xAC0C0002, // 009F CATCH R3 0 2 + 0x70020003, // 00A0 JMP #00A5 + 0x00140721, // 00A1 ADD R5 R3 K33 + 0x00140A04, // 00A2 ADD R5 R5 R4 + 0x80040A00, // 00A3 RET 1 R5 + 0x70020000, // 00A4 JMP #00A6 + 0xB0080000, // 00A5 RAISE 2 R0 R0 + 0x80040400, // 00A6 RET 1 R2 }) ) ); @@ -1983,38 +1995,26 @@ be_local_closure(Matter_TLV_item_set_commonprofile, /* name */ /******************************************************************** -** Solidified function: set +** Solidified function: init ********************************************************************/ -be_local_closure(Matter_TLV_item_set, /* name */ +be_local_closure(Matter_TLV_item_init, /* name */ be_nested_proto( - 5, /* nstack */ - 3, /* argc */ + 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[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(reset), - /* K1 */ be_nested_str_weak(typ), - /* K2 */ be_nested_str_weak(val), + ( &(const bvalue[ 1]) { /* constants */ + /* K0 */ be_nested_str_weak(parent), }), - be_str_weak(set), + be_str_weak(init), &be_const_str_solidified, - ( &(const binstruction[12]) { /* code */ - 0x8C0C0100, // 0000 GETMET R3 R0 K0 - 0x7C0C0200, // 0001 CALL R3 1 - 0x4C0C0000, // 0002 LDNIL R3 - 0x200C0403, // 0003 NE R3 R2 R3 - 0x740E0002, // 0004 JMPT R3 #0008 - 0x540E0013, // 0005 LDINT R3 20 - 0x1C0C0203, // 0006 EQ R3 R1 R3 - 0x780E0002, // 0007 JMPF R3 #000B - 0x90020201, // 0008 SETMBR R0 K1 R1 - 0x90020402, // 0009 SETMBR R0 K2 R2 - 0x80040000, // 000A RET 1 R0 - 0x80000000, // 000B RET 0 + ( &(const binstruction[ 2]) { /* code */ + 0x90020001, // 0000 SETMBR R0 K0 R1 + 0x80000000, // 0001 RET 0 }) ) ); @@ -2027,36 +2027,39 @@ be_local_closure(Matter_TLV_item_set, /* name */ be_local_class(Matter_TLV_item, 8, NULL, - be_nested_map(28, + be_nested_map(31, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(parent, -1), be_const_var(0) }, - { be_const_key_weak(TLV, 0), be_const_class(be_class_Matter_TLV) }, - { be_const_key_weak(tag_sub, -1), be_const_var(5) }, - { be_const_key_weak(encode_len, -1), be_const_closure(Matter_TLV_item_encode_len_closure) }, - { be_const_key_weak(val, 5), be_const_var(7) }, - { be_const_key_weak(_cmp_gt, -1), be_const_closure(Matter_TLV_item__cmp_gt_closure) }, - { be_const_key_weak(create_TLV, -1), be_const_static_closure(Matter_TLV_item_create_TLV_closure) }, - { be_const_key_weak(reset, -1), be_const_closure(Matter_TLV_item_reset_closure) }, - { be_const_key_weak(to_str_val, 6), be_const_closure(Matter_TLV_item_to_str_val_closure) }, - { be_const_key_weak(to_TLV, -1), be_const_closure(Matter_TLV_item_to_TLV_closure) }, - { be_const_key_weak(_encode_tag_len, -1), be_const_closure(Matter_TLV_item__encode_tag_len_closure) }, - { be_const_key_weak(set_contextspecific, -1), be_const_closure(Matter_TLV_item_set_contextspecific_closure) }, - { be_const_key_weak(parse, 7), be_const_closure(Matter_TLV_item_parse_closure) }, - { be_const_key_weak(set_anonymoustag, -1), be_const_closure(Matter_TLV_item_set_anonymoustag_closure) }, - { be_const_key_weak(tlv2raw, -1), be_const_closure(Matter_TLV_item_tlv2raw_closure) }, - { be_const_key_weak(set_fulltag, 10), be_const_closure(Matter_TLV_item_set_fulltag_closure) }, + { be_const_key_weak(is_array, 17), be_const_bool(0) }, + { be_const_key_weak(init, -1), be_const_closure(Matter_TLV_item_init_closure) }, { be_const_key_weak(set_parent, -1), be_const_closure(Matter_TLV_item_set_parent_closure) }, - { be_const_key_weak(tag_profile, 23), be_const_var(3) }, + { be_const_key_weak(set_fulltag, -1), be_const_closure(Matter_TLV_item_set_fulltag_closure) }, { be_const_key_weak(typ, -1), be_const_var(6) }, - { be_const_key_weak(_encode_tag, 20), be_const_closure(Matter_TLV_item__encode_tag_closure) }, - { be_const_key_weak(init, 13), be_const_closure(Matter_TLV_item_init_closure) }, - { be_const_key_weak(sort, 14), be_const_static_closure(Matter_TLV_item_sort_closure) }, + { be_const_key_weak(parse, 30), be_const_closure(Matter_TLV_item_parse_closure) }, + { be_const_key_weak(parent, 22), be_const_var(0) }, + { be_const_key_weak(to_str_val, -1), be_const_closure(Matter_TLV_item_to_str_val_closure) }, + { be_const_key_weak(encode_len, 4), be_const_closure(Matter_TLV_item_encode_len_closure) }, + { be_const_key_weak(TLV, 20), be_const_class(be_class_Matter_TLV) }, + { be_const_key_weak(reset, 0), be_const_closure(Matter_TLV_item_reset_closure) }, + { be_const_key_weak(tag_profile, -1), be_const_var(3) }, + { be_const_key_weak(create_TLV, -1), be_const_static_closure(Matter_TLV_item_create_TLV_closure) }, + { be_const_key_weak(tag_sub, -1), be_const_var(5) }, { 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(next_idx, -1), be_const_var(1) }, - { be_const_key_weak(tag_number, -1), be_const_var(4) }, - { be_const_key_weak(set_commonprofile, -1), be_const_closure(Matter_TLV_item_set_commonprofile_closure) }, + { be_const_key_weak(val, 5), be_const_var(7) }, + { be_const_key_weak(_encode_tag, -1), be_const_closure(Matter_TLV_item__encode_tag_closure) }, + { be_const_key_weak(_cmp_gt, -1), be_const_closure(Matter_TLV_item__cmp_gt_closure) }, + { be_const_key_weak(_encode_tag_len, 25), be_const_closure(Matter_TLV_item__encode_tag_len_closure) }, + { be_const_key_weak(is_struct, -1), be_const_bool(0) }, + { be_const_key_weak(tlv2raw, -1), be_const_closure(Matter_TLV_item_tlv2raw_closure) }, + { be_const_key_weak(sort, -1), be_const_static_closure(Matter_TLV_item_sort_closure) }, + { be_const_key_weak(is_list, -1), be_const_bool(0) }, + { be_const_key_weak(to_TLV, 18), be_const_closure(Matter_TLV_item_to_TLV_closure) }, { be_const_key_weak(set, -1), be_const_closure(Matter_TLV_item_set_closure) }, + { be_const_key_weak(set_anonymoustag, 15), be_const_closure(Matter_TLV_item_set_anonymoustag_closure) }, + { be_const_key_weak(set_commonprofile, -1), be_const_closure(Matter_TLV_item_set_commonprofile_closure) }, + { be_const_key_weak(tag_number, -1), be_const_var(4) }, + { be_const_key_weak(next_idx, 1), be_const_var(1) }, + { be_const_key_weak(set_contextspecific, -1), be_const_closure(Matter_TLV_item_set_contextspecific_closure) }, })), be_str_weak(Matter_TLV_item) ); @@ -2491,61 +2494,12 @@ be_local_closure(Matter_TLV_list_item, /* name */ ( &(const bvalue[ 1]) { /* constants */ /* K0 */ be_nested_str_weak(val), }), - be_str_weak(item), - &be_const_str_solidified, - ( &(const binstruction[ 3]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x94080401, // 0001 GETIDX R2 R2 R1 - 0x80040400, // 0002 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: add_obj -********************************************************************/ -be_local_closure(Matter_TLV_list_add_obj, /* name */ - be_nested_proto( - 7, /* 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(val), - /* K1 */ be_nested_str_weak(push), - /* K2 */ be_nested_str_weak(to_TLV), - /* K3 */ be_nested_str_weak(tag_sub), - }), - be_str_weak(add_obj), - &be_const_str_solidified, - ( &(const binstruction[21]) { /* code */ - 0x4C0C0000, // 0000 LDNIL R3 - 0x200C0403, // 0001 NE R3 R2 R3 - 0x780E0010, // 0002 JMPF R3 #0014 - 0x600C000F, // 0003 GETGBL R3 G15 - 0x5C100400, // 0004 MOVE R4 R2 - 0x60140015, // 0005 GETGBL R5 G21 - 0x7C0C0400, // 0006 CALL R3 2 - 0x780E0004, // 0007 JMPF R3 #000D - 0x880C0100, // 0008 GETMBR R3 R0 K0 - 0x8C0C0701, // 0009 GETMET R3 R3 K1 - 0x5C140400, // 000A MOVE R5 R2 - 0x7C0C0400, // 000B CALL R3 2 - 0x70020006, // 000C JMP #0014 - 0x8C0C0502, // 000D GETMET R3 R2 K2 - 0x7C0C0200, // 000E CALL R3 1 - 0x900E0601, // 000F SETMBR R3 K3 R1 - 0x88100100, // 0010 GETMBR R4 R0 K0 - 0x8C100901, // 0011 GETMET R4 R4 K1 - 0x5C180600, // 0012 MOVE R6 R3 - 0x7C100400, // 0013 CALL R4 2 - 0x80040000, // 0014 RET 1 R0 + be_str_weak(item), + &be_const_str_solidified, + ( &(const binstruction[ 3]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x94080401, // 0001 GETIDX R2 R2 R1 + 0x80040400, // 0002 RET 1 R2 }) ) ); @@ -2619,11 +2573,11 @@ be_local_closure(Matter_TLV_list_getsub, /* name */ /******************************************************************** -** Solidified function: findsub +** Solidified function: add_obj ********************************************************************/ -be_local_closure(Matter_TLV_list_findsub, /* name */ +be_local_closure(Matter_TLV_list_add_obj, /* name */ be_nested_proto( - 6, /* nstack */ + 7, /* nstack */ 3, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -2631,30 +2585,36 @@ be_local_closure(Matter_TLV_list_findsub, /* name */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 3]) { /* constants */ + ( &(const bvalue[ 4]) { /* constants */ /* K0 */ be_nested_str_weak(val), - /* K1 */ be_nested_str_weak(tag_sub), - /* K2 */ be_nested_str_weak(stop_iteration), + /* K1 */ be_nested_str_weak(push), + /* K2 */ be_nested_str_weak(to_TLV), + /* K3 */ be_nested_str_weak(tag_sub), }), - be_str_weak(findsub), + be_str_weak(add_obj), &be_const_str_solidified, - ( &(const binstruction[16]) { /* code */ - 0x600C0010, // 0000 GETGBL R3 G16 - 0x88100100, // 0001 GETMBR R4 R0 K0 - 0x7C0C0200, // 0002 CALL R3 1 - 0xA8020007, // 0003 EXBLK 0 #000C - 0x5C100600, // 0004 MOVE R4 R3 - 0x7C100000, // 0005 CALL R4 0 - 0x88140901, // 0006 GETMBR R5 R4 K1 - 0x1C140A01, // 0007 EQ R5 R5 R1 - 0x78160001, // 0008 JMPF R5 #000B - 0xA8040001, // 0009 EXBLK 1 1 - 0x80040800, // 000A RET 1 R4 - 0x7001FFF7, // 000B JMP #0004 - 0x580C0002, // 000C LDCONST R3 K2 - 0xAC0C0200, // 000D CATCH R3 1 0 - 0xB0080000, // 000E RAISE 2 R0 R0 - 0x80040400, // 000F RET 1 R2 + ( &(const binstruction[21]) { /* code */ + 0x4C0C0000, // 0000 LDNIL R3 + 0x200C0403, // 0001 NE R3 R2 R3 + 0x780E0010, // 0002 JMPF R3 #0014 + 0x600C000F, // 0003 GETGBL R3 G15 + 0x5C100400, // 0004 MOVE R4 R2 + 0x60140015, // 0005 GETGBL R5 G21 + 0x7C0C0400, // 0006 CALL R3 2 + 0x780E0004, // 0007 JMPF R3 #000D + 0x880C0100, // 0008 GETMBR R3 R0 K0 + 0x8C0C0701, // 0009 GETMET R3 R3 K1 + 0x5C140400, // 000A MOVE R5 R2 + 0x7C0C0400, // 000B CALL R3 2 + 0x70020006, // 000C JMP #0014 + 0x8C0C0502, // 000D GETMET R3 R2 K2 + 0x7C0C0200, // 000E CALL R3 1 + 0x900E0601, // 000F SETMBR R3 K3 R1 + 0x88100100, // 0010 GETMBR R4 R0 K0 + 0x8C100901, // 0011 GETMET R4 R4 K1 + 0x5C180600, // 0012 MOVE R6 R3 + 0x7C100400, // 0013 CALL R4 2 + 0x80040000, // 0014 RET 1 R0 }) ) ); @@ -2753,30 +2713,42 @@ be_local_closure(Matter_TLV_list_add_array, /* name */ /******************************************************************** -** Solidified function: push +** Solidified function: findsub ********************************************************************/ -be_local_closure(Matter_TLV_list_push, /* name */ +be_local_closure(Matter_TLV_list_findsub, /* name */ be_nested_proto( - 5, /* nstack */ - 2, /* argc */ + 6, /* nstack */ + 3, /* argc */ 2, /* varg */ 0, /* has upvals */ NULL, /* no upvals */ 0, /* has sup protos */ NULL, /* no sub protos */ 1, /* has constants */ - ( &(const bvalue[ 2]) { /* constants */ + ( &(const bvalue[ 3]) { /* constants */ /* K0 */ be_nested_str_weak(val), - /* K1 */ be_nested_str_weak(push), + /* K1 */ be_nested_str_weak(tag_sub), + /* K2 */ be_nested_str_weak(stop_iteration), }), - be_str_weak(push), + be_str_weak(findsub), &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x5C100200, // 0002 MOVE R4 R1 - 0x7C080400, // 0003 CALL R2 2 - 0x80000000, // 0004 RET 0 + ( &(const binstruction[16]) { /* code */ + 0x600C0010, // 0000 GETGBL R3 G16 + 0x88100100, // 0001 GETMBR R4 R0 K0 + 0x7C0C0200, // 0002 CALL R3 1 + 0xA8020007, // 0003 EXBLK 0 #000C + 0x5C100600, // 0004 MOVE R4 R3 + 0x7C100000, // 0005 CALL R4 0 + 0x88140901, // 0006 GETMBR R5 R4 K1 + 0x1C140A01, // 0007 EQ R5 R5 R1 + 0x78160001, // 0008 JMPF R5 #000B + 0xA8040001, // 0009 EXBLK 1 1 + 0x80040800, // 000A RET 1 R4 + 0x7001FFF7, // 000B JMP #0004 + 0x580C0002, // 000C LDCONST R3 K2 + 0xAC0C0200, // 000D CATCH R3 1 0 + 0xB0080000, // 000E RAISE 2 R0 R0 + 0x80040400, // 000F RET 1 R2 }) ) ); @@ -2910,6 +2882,37 @@ be_local_closure(Matter_TLV_list_tostring_inner, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified function: push +********************************************************************/ +be_local_closure(Matter_TLV_list_push, /* 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[ 2]) { /* constants */ + /* K0 */ be_nested_str_weak(val), + /* K1 */ be_nested_str_weak(push), + }), + be_str_weak(push), + &be_const_str_solidified, + ( &(const binstruction[ 5]) { /* code */ + 0x88080100, // 0000 GETMBR R2 R0 K0 + 0x8C080501, // 0001 GETMET R2 R2 K1 + 0x5C100200, // 0002 MOVE R4 R1 + 0x7C080400, // 0003 CALL R2 2 + 0x80000000, // 0004 RET 0 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: findsubtyp ********************************************************************/ @@ -3001,27 +3004,27 @@ be_local_class(Matter_TLV_list, &be_class_Matter_TLV_item, be_nested_map(22, ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(encode_len, 14), be_const_closure(Matter_TLV_list_encode_len_closure) }, + { be_const_key_weak(encode_len, 7), be_const_closure(Matter_TLV_list_encode_len_closure) }, { be_const_key_weak(tlv2raw, -1), be_const_closure(Matter_TLV_list_tlv2raw_closure) }, - { be_const_key_weak(to_str_val, 19), be_const_closure(Matter_TLV_list_to_str_val_closure) }, - { be_const_key_weak(findsubval, 7), be_const_closure(Matter_TLV_list_findsubval_closure) }, + { be_const_key_weak(to_str_val, 14), be_const_closure(Matter_TLV_list_to_str_val_closure) }, + { be_const_key_weak(findsubval, 5), be_const_closure(Matter_TLV_list_findsubval_closure) }, { be_const_key_weak(size, -1), be_const_closure(Matter_TLV_list_size_closure) }, - { be_const_key_weak(is_struct, -1), be_const_bool(0) }, - { be_const_key_weak(add_struct, 20), be_const_closure(Matter_TLV_list_add_struct_closure) }, { be_const_key_weak(findsubtyp, 21), be_const_closure(Matter_TLV_list_findsubtyp_closure) }, + { be_const_key_weak(add_struct, 19), be_const_closure(Matter_TLV_list_add_struct_closure) }, + { be_const_key_weak(push, -1), be_const_closure(Matter_TLV_list_push_closure) }, { be_const_key_weak(parse, -1), be_const_closure(Matter_TLV_list_parse_closure) }, { be_const_key_weak(init, 0), be_const_closure(Matter_TLV_list_init_closure) }, { be_const_key_weak(item, -1), be_const_closure(Matter_TLV_list_item_closure) }, { be_const_key_weak(tostring_inner, -1), be_const_closure(Matter_TLV_list_tostring_inner_closure) }, - { be_const_key_weak(getsubval, -1), be_const_closure(Matter_TLV_list_getsubval_closure) }, - { be_const_key_weak(getsub, 5), be_const_closure(Matter_TLV_list_getsub_closure) }, - { be_const_key_weak(push, -1), be_const_closure(Matter_TLV_list_push_closure) }, + { be_const_key_weak(getsubval, 20), be_const_closure(Matter_TLV_list_getsubval_closure) }, + { be_const_key_weak(getsub, -1), be_const_closure(Matter_TLV_list_getsub_closure) }, + { be_const_key_weak(findsub, -1), be_const_closure(Matter_TLV_list_findsub_closure) }, { be_const_key_weak(add_list, 17), be_const_closure(Matter_TLV_list_add_list_closure) }, { be_const_key_weak(add_array, -1), be_const_closure(Matter_TLV_list_add_array_closure) }, { be_const_key_weak(add_TLV, -1), be_const_closure(Matter_TLV_list_add_TLV_closure) }, { be_const_key_weak(setitem, 11), be_const_closure(Matter_TLV_list_setitem_closure) }, - { be_const_key_weak(findsub, -1), be_const_closure(Matter_TLV_list_findsub_closure) }, { be_const_key_weak(add_obj, -1), be_const_closure(Matter_TLV_list_add_obj_closure) }, + { be_const_key_weak(is_list, -1), be_const_bool(1) }, { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_list_tostring_closure) }, })), be_str_weak(Matter_TLV_list) @@ -3036,6 +3039,40 @@ void be_load_Matter_TLV_list_class(bvm *vm) { extern const bclass be_class_Matter_TLV_struct; +/******************************************************************** +** Solidified function: tostring +********************************************************************/ +be_local_closure(Matter_TLV_struct_tostring, /* 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[ 3]) { /* constants */ + /* K0 */ be_nested_str_weak(tostring_inner), + /* K1 */ be_nested_str_weak(_X7B), + /* K2 */ be_nested_str_weak(_X7D), + }), + be_str_weak(tostring), + &be_const_str_solidified, + ( &(const binstruction[ 7]) { /* code */ + 0x8C080100, // 0000 GETMET R2 R0 K0 + 0x50100200, // 0001 LDBOOL R4 1 0 + 0x58140001, // 0002 LDCONST R5 K1 + 0x58180002, // 0003 LDCONST R6 K2 + 0x5C1C0200, // 0004 MOVE R7 R1 + 0x7C080A00, // 0005 CALL R2 5 + 0x80040400, // 0006 RET 1 R2 + }) + ) +); +/*******************************************************************/ + + /******************************************************************** ** Solidified function: init ********************************************************************/ @@ -3078,10 +3115,36 @@ be_local_closure(Matter_TLV_struct_init, /* name */ /*******************************************************************/ +/******************************************************************** +** Solidified class: Matter_TLV_struct +********************************************************************/ +extern const bclass be_class_Matter_TLV_list; +be_local_class(Matter_TLV_struct, + 0, + &be_class_Matter_TLV_list, + be_nested_map(4, + ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(init, -1), be_const_closure(Matter_TLV_struct_init_closure) }, + { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_struct_tostring_closure) }, + { be_const_key_weak(is_list, -1), be_const_bool(0) }, + { be_const_key_weak(is_struct, 0), be_const_bool(1) }, + })), + be_str_weak(Matter_TLV_struct) +); +/*******************************************************************/ + +void be_load_Matter_TLV_struct_class(bvm *vm) { + be_pushntvclass(vm, &be_class_Matter_TLV_struct); + be_setglobal(vm, "Matter_TLV_struct"); + be_pop(vm, 1); +} + +extern const bclass be_class_Matter_TLV_array; + /******************************************************************** ** Solidified function: tostring ********************************************************************/ -be_local_closure(Matter_TLV_struct_tostring, /* name */ +be_local_closure(Matter_TLV_array_tostring, /* name */ be_nested_proto( 8, /* nstack */ 2, /* argc */ @@ -3093,14 +3156,14 @@ be_local_closure(Matter_TLV_struct_tostring, /* name */ 1, /* has constants */ ( &(const bvalue[ 3]) { /* constants */ /* K0 */ be_nested_str_weak(tostring_inner), - /* K1 */ be_nested_str_weak(_X7B), - /* K2 */ be_nested_str_weak(_X7D), + /* K1 */ be_nested_str_weak(_X5B), + /* K2 */ be_nested_str_weak(_X5D), }), be_str_weak(tostring), &be_const_str_solidified, ( &(const binstruction[ 7]) { /* code */ 0x8C080100, // 0000 GETMET R2 R0 K0 - 0x50100200, // 0001 LDBOOL R4 1 0 + 0x50100000, // 0001 LDBOOL R4 0 0 0x58140001, // 0002 LDCONST R5 K1 0x58180002, // 0003 LDCONST R6 K2 0x5C1C0200, // 0004 MOVE R7 R1 @@ -3112,31 +3175,6 @@ be_local_closure(Matter_TLV_struct_tostring, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified class: Matter_TLV_struct -********************************************************************/ -extern const bclass be_class_Matter_TLV_list; -be_local_class(Matter_TLV_struct, - 0, - &be_class_Matter_TLV_list, - be_nested_map(3, - ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(init, -1), be_const_closure(Matter_TLV_struct_init_closure) }, - { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_struct_tostring_closure) }, - { be_const_key_weak(is_struct, -1), be_const_bool(1) }, - })), - be_str_weak(Matter_TLV_struct) -); -/*******************************************************************/ - -void be_load_Matter_TLV_struct_class(bvm *vm) { - be_pushntvclass(vm, &be_class_Matter_TLV_struct); - be_setglobal(vm, "Matter_TLV_struct"); - be_pop(vm, 1); -} - -extern const bclass be_class_Matter_TLV_array; - /******************************************************************** ** Solidified function: init ********************************************************************/ @@ -3242,40 +3280,6 @@ be_local_closure(Matter_TLV_array_parse, /* name */ /*******************************************************************/ -/******************************************************************** -** Solidified function: tostring -********************************************************************/ -be_local_closure(Matter_TLV_array_tostring, /* 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[ 3]) { /* constants */ - /* K0 */ be_nested_str_weak(tostring_inner), - /* K1 */ be_nested_str_weak(_X5B), - /* K2 */ be_nested_str_weak(_X5D), - }), - be_str_weak(tostring), - &be_const_str_solidified, - ( &(const binstruction[ 7]) { /* code */ - 0x8C080100, // 0000 GETMET R2 R0 K0 - 0x50100000, // 0001 LDBOOL R4 0 0 - 0x58140001, // 0002 LDCONST R5 K1 - 0x58180002, // 0003 LDCONST R6 K2 - 0x5C1C0200, // 0004 MOVE R7 R1 - 0x7C080A00, // 0005 CALL R2 5 - 0x80040400, // 0006 RET 1 R2 - }) - ) -); -/*******************************************************************/ - - /******************************************************************** ** Solidified class: Matter_TLV_array ********************************************************************/ @@ -3283,11 +3287,13 @@ extern const bclass be_class_Matter_TLV_list; be_local_class(Matter_TLV_array, 0, &be_class_Matter_TLV_list, - be_nested_map(3, + be_nested_map(5, ( (struct bmapnode*) &(const bmapnode[]) { + { be_const_key_weak(tostring, 1), be_const_closure(Matter_TLV_array_tostring_closure) }, { be_const_key_weak(init, -1), be_const_closure(Matter_TLV_array_init_closure) }, - { be_const_key_weak(parse, 2), be_const_closure(Matter_TLV_array_parse_closure) }, - { be_const_key_weak(tostring, -1), be_const_closure(Matter_TLV_array_tostring_closure) }, + { be_const_key_weak(parse, 3), be_const_closure(Matter_TLV_array_parse_closure) }, + { be_const_key_weak(is_list, -1), be_const_bool(0) }, + { be_const_key_weak(is_array, -1), be_const_bool(1) }, })), be_str_weak(Matter_TLV_array) ); diff --git a/lib/libesp32/berry_tasmota/include/be_ctypes.h b/lib/libesp32/berry_tasmota/include/be_ctypes.h index 5e029100b7e4..abaffa8c31ff 100644 --- a/lib/libesp32/berry_tasmota/include/be_ctypes.h +++ b/lib/libesp32/berry_tasmota/include/be_ctypes.h @@ -60,7 +60,13 @@ typedef struct be_ctypes_classes_t { const be_ctypes_class_t * classes; } be_ctypes_classes_t; -BE_EXPORT_VARIABLE const bclass be_class_ctypes_bytes; +#ifdef __cplusplus +extern "C" { +#endif + extern const bclass be_class_ctypes_bytes; +#ifdef __cplusplus +} +#endif static void ctypes_register_class(bvm *vm, const bclass * ctypes_class) { be_pushntvclass(vm, ctypes_class); diff --git a/lib/libesp32/berry_tasmota/src/embedded/zigbee_zcl_attribute.be b/lib/libesp32/berry_tasmota/src/embedded/zigbee_zcl_attribute.be index 0d557728d1b7..f960f8e74796 100644 --- a/lib/libesp32/berry_tasmota/src/embedded/zigbee_zcl_attribute.be +++ b/lib/libesp32/berry_tasmota/src/embedded/zigbee_zcl_attribute.be @@ -202,14 +202,15 @@ class zcl_attribute_list : zcl_attribute_list_ntv var items = [] # {"Device":"0x246D","Name":"Plug","EnergyTotal":"0x000000000000","Endpoint":1,"LinkQuality":229} + var v # shortaddr - if self.shortaddr != nil - items.push(format('"Device":"0x%04X"', self.shortaddr)) + if (v := self.shortaddr) != nil + items.push(f'"Device":"0x{v:04X}"') end # groupaddr - if self.groupaddr != nil - items.push(format('"Group":"0x%04X"', self.groupaddr)) + if (v := self.groupaddr) != nil + items.push(f'"Group":"0x{v:04X}"') end # attributes @@ -222,13 +223,13 @@ class zcl_attribute_list : zcl_attribute_list_ntv end # Endpoint - if self.src_ep != nil - items.push(format('"Endpoint":%i', self.src_ep)) + if (v := self.src_ep) != nil + items.push(f'"Endpoint":{v}') end # LQI - if self.lqi != nil - items.push(format('"LinkQuality":%i', self.lqi)) + if (v := self.lqi) != nil + items.push(f'"LinkQuality":{v}') end var s = "{" + items.concat(",") + "}" @@ -238,68 +239,6 @@ class zcl_attribute_list : zcl_attribute_list_ntv end end -#@ solidify:zcl_attributes,weak -class zcl_attributes - var shortaddr - var groupaddr - var lqi - var src_ep - var attr_list - - def init(shortaddr, groupaddr, lqi, src_ep, attr_list) - self.shortaddr = shortaddr - self.groupaddr = groupaddr - self.lqi = lqi - self.src_ep = src_ep - if isinstance(self.attr_list, list) - self.attr_list = attr_list - else - self.attr_list = [] - end - end - - def push(attr) - self.attr_list.push(attr) - end - - def tostring() - import json - - var items = [] - # {"Device":"0x246D","Name":"Plug","EnergyTotal":"0x000000000000","Endpoint":1,"LinkQuality":229} - - # shortaddr - if self.shortaddr != nil - items.push(format('"Device":"0x%04X"', self.shortaddr)) - end - # groupaddr - if self.shortaddr != nil - items.push(format('"Group":"0x%04X"', self.groupaddr)) - end - - # attributes - for e: self.attr_list - items.push(e.tostring()) - end - - # Endpoint - if self.src_ep != nil - items.push(format('"Endpoint":%i', self.src_ep)) - end - - # Endpoint - if self.lqi != nil - items.push(format('"LinkQuality":%i', self.lqi)) - end - - var s = "{" + items.concat(",") + "}" - return s - - # return format("shortaddr:0x%04X groupaddr:0x%04X %s", self.shortaddr, self.groupaddr, str(self.attr_list)) - end - -end - #- # Unit tests diff --git a/lib/libesp32/berry_tasmota/src/solidify/solidified_zigbee_zcl_attribute.h b/lib/libesp32/berry_tasmota/src/solidify/solidified_zigbee_zcl_attribute.h index 01c75933f915..bbf637b6b584 100644 --- a/lib/libesp32/berry_tasmota/src/solidify/solidified_zigbee_zcl_attribute.h +++ b/lib/libesp32/berry_tasmota/src/solidify/solidified_zigbee_zcl_attribute.h @@ -785,7 +785,7 @@ be_local_closure(zcl_attribute_list_deinit, /* name */ ********************************************************************/ be_local_closure(zcl_attribute_list_tostring, /* name */ be_nested_proto( - 10, /* nstack */ + 11, /* nstack */ 1, /* argc */ 2, /* varg */ 0, /* has upvals */ @@ -805,9 +805,9 @@ be_local_closure(zcl_attribute_list_tostring, /* name */ /* K8 */ be_nested_str_weak(tostring), /* K9 */ be_const_int(1), /* K10 */ be_nested_str_weak(src_ep), - /* K11 */ be_nested_str_weak(_X22Endpoint_X22_X3A_X25i), + /* K11 */ be_nested_str_weak(_X22Endpoint_X22_X3A_X25s), /* K12 */ be_nested_str_weak(lqi), - /* K13 */ be_nested_str_weak(_X22LinkQuality_X22_X3A_X25i), + /* K13 */ be_nested_str_weak(_X22LinkQuality_X22_X3A_X25s), /* K14 */ be_nested_str_weak(_X7B), /* K15 */ be_nested_str_weak(concat), /* K16 */ be_nested_str_weak(_X2C), @@ -815,68 +815,69 @@ be_local_closure(zcl_attribute_list_tostring, /* name */ }), be_str_weak(tostring), &be_const_str_solidified, - ( &(const binstruction[61]) { /* code */ + ( &(const binstruction[62]) { /* code */ 0xA4060000, // 0000 IMPORT R1 K0 0x60080012, // 0001 GETGBL R2 G18 0x7C080000, // 0002 CALL R2 0 - 0x880C0101, // 0003 GETMBR R3 R0 K1 - 0x4C100000, // 0004 LDNIL R4 - 0x200C0604, // 0005 NE R3 R3 R4 - 0x780E0005, // 0006 JMPF R3 #000D - 0x8C0C0502, // 0007 GETMET R3 R2 K2 - 0x60140018, // 0008 GETGBL R5 G24 - 0x58180003, // 0009 LDCONST R6 K3 - 0x881C0101, // 000A GETMBR R7 R0 K1 - 0x7C140400, // 000B CALL R5 2 - 0x7C0C0400, // 000C CALL R3 2 - 0x880C0104, // 000D GETMBR R3 R0 K4 - 0x4C100000, // 000E LDNIL R4 - 0x200C0604, // 000F NE R3 R3 R4 - 0x780E0005, // 0010 JMPF R3 #0017 - 0x8C0C0502, // 0011 GETMET R3 R2 K2 - 0x60140018, // 0012 GETGBL R5 G24 - 0x58180005, // 0013 LDCONST R6 K5 - 0x881C0104, // 0014 GETMBR R7 R0 K4 - 0x7C140400, // 0015 CALL R5 2 - 0x7C0C0400, // 0016 CALL R3 2 - 0x580C0006, // 0017 LDCONST R3 K6 - 0x8C100107, // 0018 GETMET R4 R0 K7 - 0x7C100200, // 0019 CALL R4 1 - 0x14140604, // 001A LT R5 R3 R4 - 0x78160006, // 001B JMPF R5 #0023 - 0x8C140502, // 001C GETMET R5 R2 K2 - 0x941C0003, // 001D GETIDX R7 R0 R3 - 0x8C1C0F08, // 001E GETMET R7 R7 K8 - 0x7C1C0200, // 001F CALL R7 1 - 0x7C140400, // 0020 CALL R5 2 - 0x000C0709, // 0021 ADD R3 R3 K9 - 0x7001FFF6, // 0022 JMP #001A - 0x8814010A, // 0023 GETMBR R5 R0 K10 - 0x4C180000, // 0024 LDNIL R6 - 0x20140A06, // 0025 NE R5 R5 R6 - 0x78160005, // 0026 JMPF R5 #002D - 0x8C140502, // 0027 GETMET R5 R2 K2 - 0x601C0018, // 0028 GETGBL R7 G24 - 0x5820000B, // 0029 LDCONST R8 K11 - 0x8824010A, // 002A GETMBR R9 R0 K10 - 0x7C1C0400, // 002B CALL R7 2 - 0x7C140400, // 002C CALL R5 2 - 0x8814010C, // 002D GETMBR R5 R0 K12 - 0x4C180000, // 002E LDNIL R6 - 0x20140A06, // 002F NE R5 R5 R6 - 0x78160005, // 0030 JMPF R5 #0037 - 0x8C140502, // 0031 GETMET R5 R2 K2 - 0x601C0018, // 0032 GETGBL R7 G24 - 0x5820000D, // 0033 LDCONST R8 K13 - 0x8824010C, // 0034 GETMBR R9 R0 K12 - 0x7C1C0400, // 0035 CALL R7 2 - 0x7C140400, // 0036 CALL R5 2 - 0x8C14050F, // 0037 GETMET R5 R2 K15 - 0x581C0010, // 0038 LDCONST R7 K16 - 0x7C140400, // 0039 CALL R5 2 - 0x00161C05, // 003A ADD R5 K14 R5 - 0x00140B11, // 003B ADD R5 R5 K17 - 0x80040A00, // 003C RET 1 R5 + 0x4C0C0000, // 0003 LDNIL R3 + 0x880C0101, // 0004 GETMBR R3 R0 K1 + 0x4C100000, // 0005 LDNIL R4 + 0x200C0604, // 0006 NE R3 R3 R4 + 0x780E0005, // 0007 JMPF R3 #000E + 0x8C0C0502, // 0008 GETMET R3 R2 K2 + 0x60140018, // 0009 GETGBL R5 G24 + 0x58180003, // 000A LDCONST R6 K3 + 0x5C1C0600, // 000B MOVE R7 R3 + 0x7C140400, // 000C CALL R5 2 + 0x7C0C0400, // 000D CALL R3 2 + 0x880C0104, // 000E GETMBR R3 R0 K4 + 0x4C100000, // 000F LDNIL R4 + 0x200C0604, // 0010 NE R3 R3 R4 + 0x780E0005, // 0011 JMPF R3 #0018 + 0x8C0C0502, // 0012 GETMET R3 R2 K2 + 0x60140018, // 0013 GETGBL R5 G24 + 0x58180005, // 0014 LDCONST R6 K5 + 0x5C1C0600, // 0015 MOVE R7 R3 + 0x7C140400, // 0016 CALL R5 2 + 0x7C0C0400, // 0017 CALL R3 2 + 0x58100006, // 0018 LDCONST R4 K6 + 0x8C140107, // 0019 GETMET R5 R0 K7 + 0x7C140200, // 001A CALL R5 1 + 0x14180805, // 001B LT R6 R4 R5 + 0x781A0006, // 001C JMPF R6 #0024 + 0x8C180502, // 001D GETMET R6 R2 K2 + 0x94200004, // 001E GETIDX R8 R0 R4 + 0x8C201108, // 001F GETMET R8 R8 K8 + 0x7C200200, // 0020 CALL R8 1 + 0x7C180400, // 0021 CALL R6 2 + 0x00100909, // 0022 ADD R4 R4 K9 + 0x7001FFF6, // 0023 JMP #001B + 0x880C010A, // 0024 GETMBR R3 R0 K10 + 0x4C180000, // 0025 LDNIL R6 + 0x200C0606, // 0026 NE R3 R3 R6 + 0x780E0005, // 0027 JMPF R3 #002E + 0x8C180502, // 0028 GETMET R6 R2 K2 + 0x60200018, // 0029 GETGBL R8 G24 + 0x5824000B, // 002A LDCONST R9 K11 + 0x5C280600, // 002B MOVE R10 R3 + 0x7C200400, // 002C CALL R8 2 + 0x7C180400, // 002D CALL R6 2 + 0x880C010C, // 002E GETMBR R3 R0 K12 + 0x4C180000, // 002F LDNIL R6 + 0x200C0606, // 0030 NE R3 R3 R6 + 0x780E0005, // 0031 JMPF R3 #0038 + 0x8C180502, // 0032 GETMET R6 R2 K2 + 0x60200018, // 0033 GETGBL R8 G24 + 0x5824000D, // 0034 LDCONST R9 K13 + 0x5C280600, // 0035 MOVE R10 R3 + 0x7C200400, // 0036 CALL R8 2 + 0x7C180400, // 0037 CALL R6 2 + 0x8C18050F, // 0038 GETMET R6 R2 K15 + 0x58200010, // 0039 LDCONST R8 K16 + 0x7C180400, // 003A CALL R6 2 + 0x001A1C06, // 003B ADD R6 K14 R6 + 0x00180D11, // 003C ADD R6 R6 K17 + 0x80040C00, // 003D RET 1 R6 }) ) ); @@ -908,213 +909,5 @@ void be_load_zcl_attribute_list_class(bvm *vm) { be_setglobal(vm, "zcl_attribute_list"); be_pop(vm, 1); } - -extern const bclass be_class_zcl_attributes; - -/******************************************************************** -** Solidified function: init -********************************************************************/ -be_local_closure(zcl_attributes_init, /* name */ - be_nested_proto( - 9, /* nstack */ - 6, /* 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(shortaddr), - /* K1 */ be_nested_str_weak(groupaddr), - /* K2 */ be_nested_str_weak(lqi), - /* K3 */ be_nested_str_weak(src_ep), - /* K4 */ be_nested_str_weak(attr_list), - }), - be_str_weak(init), - &be_const_str_solidified, - ( &(const binstruction[15]) { /* 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 - 0x6018000F, // 0004 GETGBL R6 G15 - 0x881C0104, // 0005 GETMBR R7 R0 K4 - 0x60200012, // 0006 GETGBL R8 G18 - 0x7C180400, // 0007 CALL R6 2 - 0x781A0001, // 0008 JMPF R6 #000B - 0x90020805, // 0009 SETMBR R0 K4 R5 - 0x70020002, // 000A JMP #000E - 0x60180012, // 000B GETGBL R6 G18 - 0x7C180000, // 000C CALL R6 0 - 0x90020806, // 000D SETMBR R0 K4 R6 - 0x80000000, // 000E RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: tostring -********************************************************************/ -be_local_closure(zcl_attributes_tostring, /* 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[17]) { /* constants */ - /* K0 */ be_nested_str_weak(json), - /* K1 */ be_nested_str_weak(shortaddr), - /* K2 */ be_nested_str_weak(push), - /* K3 */ be_nested_str_weak(_X22Device_X22_X3A_X220x_X2504X_X22), - /* K4 */ be_nested_str_weak(_X22Group_X22_X3A_X220x_X2504X_X22), - /* K5 */ be_nested_str_weak(groupaddr), - /* K6 */ be_nested_str_weak(attr_list), - /* K7 */ be_nested_str_weak(tostring), - /* K8 */ be_nested_str_weak(stop_iteration), - /* K9 */ be_nested_str_weak(src_ep), - /* K10 */ be_nested_str_weak(_X22Endpoint_X22_X3A_X25i), - /* K11 */ be_nested_str_weak(lqi), - /* K12 */ be_nested_str_weak(_X22LinkQuality_X22_X3A_X25i), - /* K13 */ be_nested_str_weak(_X7B), - /* K14 */ be_nested_str_weak(concat), - /* K15 */ be_nested_str_weak(_X2C), - /* K16 */ be_nested_str_weak(_X7D), - }), - be_str_weak(tostring), - &be_const_str_solidified, - ( &(const binstruction[63]) { /* code */ - 0xA4060000, // 0000 IMPORT R1 K0 - 0x60080012, // 0001 GETGBL R2 G18 - 0x7C080000, // 0002 CALL R2 0 - 0x880C0101, // 0003 GETMBR R3 R0 K1 - 0x4C100000, // 0004 LDNIL R4 - 0x200C0604, // 0005 NE R3 R3 R4 - 0x780E0005, // 0006 JMPF R3 #000D - 0x8C0C0502, // 0007 GETMET R3 R2 K2 - 0x60140018, // 0008 GETGBL R5 G24 - 0x58180003, // 0009 LDCONST R6 K3 - 0x881C0101, // 000A GETMBR R7 R0 K1 - 0x7C140400, // 000B CALL R5 2 - 0x7C0C0400, // 000C CALL R3 2 - 0x880C0101, // 000D GETMBR R3 R0 K1 - 0x4C100000, // 000E LDNIL R4 - 0x200C0604, // 000F NE R3 R3 R4 - 0x780E0005, // 0010 JMPF R3 #0017 - 0x8C0C0502, // 0011 GETMET R3 R2 K2 - 0x60140018, // 0012 GETGBL R5 G24 - 0x58180004, // 0013 LDCONST R6 K4 - 0x881C0105, // 0014 GETMBR R7 R0 K5 - 0x7C140400, // 0015 CALL R5 2 - 0x7C0C0400, // 0016 CALL R3 2 - 0x600C0010, // 0017 GETGBL R3 G16 - 0x88100106, // 0018 GETMBR R4 R0 K6 - 0x7C0C0200, // 0019 CALL R3 1 - 0xA8020006, // 001A EXBLK 0 #0022 - 0x5C100600, // 001B MOVE R4 R3 - 0x7C100000, // 001C CALL R4 0 - 0x8C140502, // 001D GETMET R5 R2 K2 - 0x8C1C0907, // 001E GETMET R7 R4 K7 - 0x7C1C0200, // 001F CALL R7 1 - 0x7C140400, // 0020 CALL R5 2 - 0x7001FFF8, // 0021 JMP #001B - 0x580C0008, // 0022 LDCONST R3 K8 - 0xAC0C0200, // 0023 CATCH R3 1 0 - 0xB0080000, // 0024 RAISE 2 R0 R0 - 0x880C0109, // 0025 GETMBR R3 R0 K9 - 0x4C100000, // 0026 LDNIL R4 - 0x200C0604, // 0027 NE R3 R3 R4 - 0x780E0005, // 0028 JMPF R3 #002F - 0x8C0C0502, // 0029 GETMET R3 R2 K2 - 0x60140018, // 002A GETGBL R5 G24 - 0x5818000A, // 002B LDCONST R6 K10 - 0x881C0109, // 002C GETMBR R7 R0 K9 - 0x7C140400, // 002D CALL R5 2 - 0x7C0C0400, // 002E CALL R3 2 - 0x880C010B, // 002F GETMBR R3 R0 K11 - 0x4C100000, // 0030 LDNIL R4 - 0x200C0604, // 0031 NE R3 R3 R4 - 0x780E0005, // 0032 JMPF R3 #0039 - 0x8C0C0502, // 0033 GETMET R3 R2 K2 - 0x60140018, // 0034 GETGBL R5 G24 - 0x5818000C, // 0035 LDCONST R6 K12 - 0x881C010B, // 0036 GETMBR R7 R0 K11 - 0x7C140400, // 0037 CALL R5 2 - 0x7C0C0400, // 0038 CALL R3 2 - 0x8C0C050E, // 0039 GETMET R3 R2 K14 - 0x5814000F, // 003A LDCONST R5 K15 - 0x7C0C0400, // 003B CALL R3 2 - 0x000E1A03, // 003C ADD R3 K13 R3 - 0x000C0710, // 003D ADD R3 R3 K16 - 0x80040600, // 003E RET 1 R3 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified function: push -********************************************************************/ -be_local_closure(zcl_attributes_push, /* 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[ 2]) { /* constants */ - /* K0 */ be_nested_str_weak(attr_list), - /* K1 */ be_nested_str_weak(push), - }), - be_str_weak(push), - &be_const_str_solidified, - ( &(const binstruction[ 5]) { /* code */ - 0x88080100, // 0000 GETMBR R2 R0 K0 - 0x8C080501, // 0001 GETMET R2 R2 K1 - 0x5C100200, // 0002 MOVE R4 R1 - 0x7C080400, // 0003 CALL R2 2 - 0x80000000, // 0004 RET 0 - }) - ) -); -/*******************************************************************/ - - -/******************************************************************** -** Solidified class: zcl_attributes -********************************************************************/ -be_local_class(zcl_attributes, - 5, - NULL, - be_nested_map(8, - ( (struct bmapnode*) &(const bmapnode[]) { - { be_const_key_weak(groupaddr, 6), be_const_var(1) }, - { be_const_key_weak(push, 4), be_const_closure(zcl_attributes_push_closure) }, - { be_const_key_weak(shortaddr, -1), be_const_var(0) }, - { be_const_key_weak(init, -1), be_const_closure(zcl_attributes_init_closure) }, - { be_const_key_weak(tostring, -1), be_const_closure(zcl_attributes_tostring_closure) }, - { be_const_key_weak(lqi, 1), be_const_var(2) }, - { be_const_key_weak(attr_list, -1), be_const_var(4) }, - { be_const_key_weak(src_ep, 0), be_const_var(3) }, - })), - be_str_weak(zcl_attributes) -); -/*******************************************************************/ - -void be_load_zcl_attributes_class(bvm *vm) { - be_pushntvclass(vm, &be_class_zcl_attributes); - be_setglobal(vm, "zcl_attributes"); - be_pop(vm, 1); -} /********************************************************************/ /* End of solidification */ diff --git a/pio-tools/get_flash_size.py b/pio-tools/get_flash_size.py new file mode 100644 index 000000000000..c0480d854fd4 --- /dev/null +++ b/pio-tools/get_flash_size.py @@ -0,0 +1,45 @@ +from os.path import join +import subprocess +from SCons.Script import COMMAND_LINE_TARGETS + +Import("env") +env = DefaultEnvironment() +platform = env.PioPlatform() + +if "upload" in COMMAND_LINE_TARGETS: + + def esp32_detect_flashsize(): + esptoolpy = join(platform.get_package_dir("tool-esptoolpy") or "", "esptool.py") + esptoolpy_flags = ["flash_id"] + esptoolpy_cmd = [env["PYTHONEXE"], esptoolpy] + esptoolpy_flags + try: + output = subprocess.run(esptoolpy_cmd, capture_output=True).stdout.splitlines() + for l in output: + if l.decode().startswith("Detected flash size: "): + size = (l.decode().split(": ")[1]) + print("Did get flash size:",size) + return size, True + return "4MB",False + except subprocess.CalledProcessError as exc: + print("Did get chip info failed with " + str(exc)) + return "4MB",False + + size, overridden = esp32_detect_flashsize() + old_flash_size = env.BoardConfig().get("upload.flash_size") + old_maximum_size = env.BoardConfig().get("upload.maximum_size") + new_maximum_size = int(size.split("MB")[0]) * 0x100000 + + if new_maximum_size > old_maximum_size: + + extra_flags = env.BoardConfig().get("build.extra_flags").split(" ") + new_flags = "" + for flag in extra_flags: + if flag.startswith("-DESP32"): + flag = f"-DESP32_{size}" + new_flags += flag + " " + env.BoardConfig().update("build.extra_flags",new_flags) + env.BoardConfig().update("upload.flash_size",size) + + env.BoardConfig().update("upload.maximum_size", new_maximum_size) + + env.Replace(TASMOTA_flash_size=size) \ No newline at end of file diff --git a/pio-tools/post_esp32.py b/pio-tools/post_esp32.py index 9f8a2f637483..facff33e7e87 100644 --- a/pio-tools/post_esp32.py +++ b/pio-tools/post_esp32.py @@ -1,6 +1,8 @@ # From: https://github.com/letscontrolit/ESPEasy/blob/mega/tools/pio/post_esp32.py # Thanks TD-er :) +# Thanks @staars for safeboot and auto resizing LittleFS code and enhancements + # Combines separate bin files with their respective offsets into a single file # This single file must then be flashed to an ESP32 node with 0 offset. # @@ -29,6 +31,8 @@ import requests import shutil import subprocess +import codecs +from SCons.Script import COMMAND_LINE_TARGETS sys.path.append(join(platform.get_package_dir("tool-esptoolpy"))) import esptool @@ -52,6 +56,30 @@ variants_dir = join(FRAMEWORK_DIR, "variants", "tasmota") +def patch_partitions_bin(size_string): + partition_bin_path = join(env.subst("$BUILD_DIR"),"partitions.bin") + with open(partition_bin_path, 'r+b') as file: + binary_data = file.read(0xb0) + import hashlib + bin_list = list(binary_data) + size = codecs.decode(size_string[2:], 'hex_codec') # 0xc50000 -> [c5,00,00] + bin_list[0x8a] = size[0] + bin_list[0x8b] = size[1] + result = hashlib.md5(bytes(bin_list[0:0xa0])) + partition_data = bytes(bin_list) + result.digest() + file.seek(0) + file.write(partition_data) + print("New partition hash:",result.digest().hex()) + +def esp32_detect_flashsize(): + if not "upload" in COMMAND_LINE_TARGETS: + return "4MB",False + size = env.get("TASMOTA_flash_size") + if size == None: + return "4MB",False + else: + return size,True + def esp32_create_chip_string(chip): tasmota_platform = env.subst("$BUILD_DIR").split(os.path.sep)[-1] tasmota_platform = tasmota_platform.split('-')[0] @@ -120,6 +148,8 @@ def esp32_create_combined_bin(source, target, env): # factory_offset = -1 # error code value - currently unused app_offset = 0x10000 # default value for "old" scheme fs_offset = -1 # error code value + flash_size_from_esp, flash_size_was_overridden = esp32_detect_flashsize() + with open(env.BoardConfig().get("build.partitions")) as csv_file: print("Read partitions from ",env.BoardConfig().get("build.partitions")) csv_reader = csv.reader(csv_file, delimiter=',') @@ -136,7 +166,13 @@ def esp32_create_combined_bin(source, target, env): # elif(row[0] == 'factory'): # factory_offset = int(row[3],base=16) elif(row[0] == 'spiffs'): - if esp32_build_filesystem(row[4]): + partition_size = row[4] + if flash_size_was_overridden: + print(f"Will override fixed FS partition size from {env.BoardConfig().get('build.partitions')}: {partition_size} ...") + partition_size = hex(int(flash_size_from_esp.split("MB")[0]) * 0x100000 - int(row[3],base=16)) + print(f"... with computed maximum size from connected {env.get('BOARD_MCU')}: {partition_size}") + patch_partitions_bin(partition_size) + if esp32_build_filesystem(partition_size): fs_offset = int(row[3],base=16) @@ -147,16 +183,19 @@ def esp32_create_combined_bin(source, target, env): tasmota_platform = esp32_create_chip_string(chip) if "-DUSE_USB_CDC_CONSOLE" in env.BoardConfig().get("build.extra_flags") and "cdc" not in tasmota_platform: - tasmota_platform += "cdc" + tasmota_platform += "cdc" print("WARNING: board definition uses CDC configuration, but environment name does not -> changing tasmota safeboot binary to:", tasmota_platform + "-safeboot.bin") - + if not os.path.exists(variants_dir): os.makedirs(variants_dir) if("safeboot" in firmware_name): esp32_copy_new_safeboot_bin(tasmota_platform,firmware_name) else: esp32_fetch_safeboot_bin(tasmota_platform) + flash_size = env.BoardConfig().get("upload.flash_size", "4MB") + if flash_size_was_overridden: + flash_size = flash_size_from_esp flash_freq = env.BoardConfig().get("build.f_flash", "40000000L") flash_freq = str(flash_freq).replace("L", "") flash_freq = str(int(int(flash_freq) / 1000000)) + "m" @@ -225,4 +264,4 @@ def esp32_create_combined_bin(source, target, env): esptool.main(cmd) -env.AddPostAction("$BUILD_DIR/${PROGNAME}.bin", esp32_create_combined_bin) +env.AddPostAction("$BUILD_DIR/${PROGNAME}.bin", esp32_create_combined_bin) \ No newline at end of file diff --git a/platformio_tasmota32.ini b/platformio_tasmota32.ini index d537a0c42276..1cd5fcd6e579 100644 --- a/platformio_tasmota32.ini +++ b/platformio_tasmota32.ini @@ -11,11 +11,11 @@ build_unflags = ${esp_defaults.build_unflags} -Wpointer-arith build_flags = ${esp_defaults.build_flags} ; comment next line to disable IPv6 support - -DUSE_IPV6 + ;-DUSE_IPV6 -Wno-switch-unreachable -Wno-stringop-overflow -fno-exceptions - -flto + -flto=auto -DBUFFER_LENGTH=128 -DHTTP_UPLOAD_BUFLEN=2048 -DMQTT_MAX_PACKET_SIZE=1200 @@ -37,6 +37,7 @@ build_flags = ${esp_defaults.build_flags} -Wl,--wrap=_Z11analogWritehi ; `analogWrite(unsigned char, int)` use the Tasmota version of analogWrite for deeper integration and phase control -Wl,--wrap=ledcReadFreq ; `uint32_t ledcReadFreq(uint8_t chan)` extra_scripts = pre:pio-tools/add_c_flags.py + pre:pio-tools/get_flash_size.py pre:pio-tools/gen-berry-structures.py post:pio-tools/post_esp32.py ${esp_defaults.extra_scripts} diff --git a/platformio_tasmota_cenv_sample.ini b/platformio_tasmota_cenv_sample.ini index 2f987d809f6b..ed427a6edfb3 100644 --- a/platformio_tasmota_cenv_sample.ini +++ b/platformio_tasmota_cenv_sample.ini @@ -22,13 +22,6 @@ board_build.f_flash = 80000000L build_flags = ${env:tasmota32_base.build_flags} -DFIRMWARE_TASMOTA32 -DOTA_URL='"http://ota.tasmota.com/tasmota32/release/tasmota32s3.bin"' -; !!! Real flash size needed, avoid autoresize since it is formating FS !!! -board_upload.flash_size = 8MB -board_upload.maximum_size = 8388608 -; Without autoresize a partition scheme is needed which does fit to flash size -board_build.partitions = partitions/esp32_partition_app2944k_fs2M.csv -; Dont use safeboot, not used in this partition scheme -> an empty entry needed to overwrite the default setting -board_upload.arduino.flash_extra_images = ; Example for custom file upload in Tasmota Filesystem custom_files_upload = ${env:tasmota32_base.custom_files_upload} tasmota/berry/modules/Partition_Wizard.tapp diff --git a/platformio_tasmota_env32.ini b/platformio_tasmota_env32.ini index 546b66d5de9a..3c09ecdd8b33 100644 --- a/platformio_tasmota_env32.ini +++ b/platformio_tasmota_env32.ini @@ -42,14 +42,23 @@ custom_files_upload = no_files [env:tasmota32-arduino30] extends = env:tasmota32_base +board = esp32 build_flags = ${env:tasmota32_base.build_flags} - -DFIRMWARE_SAFEBOOT -DOTA_URL='""' +; *** Do not use safe boot scheme +board_build.partitions = partitions/esp32_partition_app1856k_fs320k.csv +; Safeboot not used in this partition scheme -> an empty entry needed to overwrite the default setting +board_upload.arduino.flash_extra_images = lib_extra_dirs = lib/lib_ssl, lib/libesp32 lib_ignore = - Micro-RTSP ESP Mail Client - DHT sensor library + IRremoteESP8266 + NeoPixelBus + OneWire + MFRC522 + universal display Library + ESP8266Audio + ESP8266SAM [env:tasmota32c6-safeboot] extends = env:tasmota32_base @@ -59,9 +68,14 @@ build_flags = ${env:tasmota32_base.build_flags} -DOTA_URL='""' lib_extra_dirs = lib/lib_ssl, lib/libesp32 lib_ignore = - Micro-RTSP ESP Mail Client - DHT sensor library + IRremoteESP8266 + NeoPixelBus + OneWire + MFRC522 + universal display Library + ESP8266Audio + ESP8266SAM [env:tasmota32-safeboot] extends = env:tasmota32_base diff --git a/tasmota/include/tasmota_version.h b/tasmota/include/tasmota_version.h index acb8a752a324..14d021c89016 100644 --- a/tasmota/include/tasmota_version.h +++ b/tasmota/include/tasmota_version.h @@ -20,6 +20,6 @@ #ifndef _TASMOTA_VERSION_H_ #define _TASMOTA_VERSION_H_ -const uint32_t VERSION = 0x0D000003; // 13.0.0.3 +const uint32_t VERSION = 0x0D000004; // 13.0.0.4 #endif // _TASMOTA_VERSION_H_ diff --git a/tasmota/language/ru_RU.h b/tasmota/language/ru_RU.h index 60d61d492c21..0b2d556a9bfc 100644 --- a/tasmota/language/ru_RU.h +++ b/tasmota/language/ru_RU.h @@ -2,6 +2,7 @@ ru-RU.h - localization for Russian - Russia for Tasmota Copyright (C) 2021 Roman-vn + Copyright (C) 2023 usr44 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 @@ -28,7 +29,7 @@ * Use online command StateText to translate ON, OFF, HOLD and TOGGLE. * Use online command Prefix to translate cmnd, stat and tele. * - * Updated until v9.3.1.1 + * Updated until v13.0.0.3 \*********************************************************************/ //#define LANGUAGE_MODULE_NAME // Enable to display "Module Generic" (ie Spanish), Disable to display "Generic Module" (ie English) @@ -63,7 +64,7 @@ #define D_BLINKOFF "Не Мигать" #define D_BOOT_COUNT "Количество загрузок" #define D_BRIGHTLIGHT "Яркость" -#define D_BSSID "BSSId" +#define D_BSSID "BSSID" #define D_BUTTON "Кнопка" #define D_BY "by" // Written by me #define D_BYTES "Байт" @@ -74,7 +75,7 @@ #define D_COLDLIGHT "Холодный" #define D_COMMAND "Команда" #define D_CONNECTED "Соединен" -#define D_CORS_DOMAIN "CORS Domain" +#define D_CORS_DOMAIN "Домен CORS" #define D_COUNT "Подсчет" #define D_COUNTER "Счетчик" #define D_CT_POWER "CT Power" @@ -88,7 +89,7 @@ #define D_MOVING_DISTANCE "Moving Distance" #define D_STATIC_DISTANCE "Static Distance" #define D_DETECT_DISTANCE "Detect Distance" -#define D_DISTANCE "Distance" +#define D_DISTANCE "Расстояние" #define D_DNS_SERVER "DNS Сервер" #define D_DO "Disolved Oxygen" #define D_DONE "Выполнено" @@ -105,33 +106,33 @@ #define D_FALLBACK_TOPIC "Топик обратной связи" #define D_FALSE "Ложно" #define D_FILE "Файл" -#define D_FILE_SYSTEM_SIZE "File System Size" -#define D_FLOW_RATE "Flow rate" -#define D_FRAGMENTATION "frag." // Lower case abbreviated version of fragmentation used in "memory fragmentation" -#define D_FRAME_RATE "Frame rate" +#define D_FILE_SYSTEM_SIZE "Размер файловой системы" +#define D_FLOW_RATE "Скорость потока" +#define D_FRAGMENTATION "фраг." // Lower case abbreviated version of fragmentation used in "memory fragmentation" +#define D_FRAME_RATE "Частота кадров" #define D_FREE_MEMORY "Свободная память" -#define D_PSR_MAX_MEMORY "PS-RAM Memory" -#define D_PSR_FREE_MEMORY "PS-RAM free Memory" -#define D_FREQUENCY "Frequency" +#define D_PSR_MAX_MEMORY "Память PS-RAM" +#define D_PSR_FREE_MEMORY "Свободная память PS-RAM" +#define D_FREQUENCY "Частота" #define D_GAS "Газ" #define D_GATEWAY "Шлюз" #define D_GROUP "Группа" #define D_HOST "Хост" #define D_HALL_EFFECT "Hall Effect" -#define D_HOSTNAME "Имя Хоста" +#define D_HOSTNAME "Имя хоста" #define D_HUMIDITY "Влажность" #define D_ILLUMINANCE "Освещенность" #define D_IMMEDIATE "немедленно" // Button immediate #define D_INDEX "Индекс" #define D_INFO "Инфо" -#define D_INFRARED "Infrared" +#define D_INFRARED "Инфракрасный" #define D_INITIALIZED "Инициализировано" #define D_IP_ADDRESS "IP Адрес" #define D_LIGHT "Свет" #define D_LWT "LWT" #define D_LQI "LQI" // Zigbee Link Quality Index #define D_MODULE "Модуль" -#define D_MOISTURE "Moisture" +#define D_MOISTURE "Влага" #define D_MQTT "MQTT" #define D_MULTI_PRESS "многократное нажатие" #define D_NOISE "Шум" @@ -139,15 +140,15 @@ #define D_NOX "NOx" #define D_O2 "Oxygen" #define D_OFF "Выкл" -#define D_OFFLINE "Офф-лайн" +#define D_OFFLINE "Офлайн" #define D_OK "Ок" #define D_ON "Вкл" -#define D_ONLINE "Он-лайн" +#define D_ONLINE "Онлайн" #define D_ORP "ORP" #define D_PASSWORD "Пароль" #define D_PH "pH" #define D_MQ "MQ" -#define D_PARTITION "Partition" // As in flash and firmware partition +#define D_PARTITION "Раздел" // As in flash and firmware partition #define D_PORT "Порт" #define D_POWER_FACTOR "Коэффициент мощности" #define D_POWERUSAGE "Мощность" @@ -159,27 +160,27 @@ #define D_PROGRAM_FLASH_SIZE "Размер Flash для программ" #define D_PROGRAM_SIZE "Размер программы " #define D_PROJECT "Проект" -#define D_RAIN "Rain" -#define D_RANGE "Range" +#define D_RAIN "Дождь" +#define D_RANGE "Диапазон" #define D_RECEIVED "Получено" -#define D_RESTART "Перезапуск" -#define D_RESTARTING "Перезапуск" +#define D_RESTART "Перезагрузка" +#define D_RESTARTING "Перезагрузка" #define D_RESTART_REASON "Причина перезагрузки" #define D_RESTORE "восстановление" #define D_RETAINED "нераспред." -#define D_RULE "Rule" +#define D_RULE "Правило" #define D_SAVE "Сохранить" #define D_SENSOR "Датчик" -#define D_SSID "SSId" +#define D_SSID "SSID" #define D_START "Старт" #define D_STD_TIME "STD" #define D_STOP "Стоп" -#define D_SUBNET_MASK "Маска Подсети" +#define D_SUBNET_MASK "Маска подсети" #define D_SUBSCRIBE_TO "Подписаться на" -#define D_UNSUBSCRIBE_FROM "Unsubscribe from" +#define D_UNSUBSCRIBE_FROM "Отписатся от" #define D_SUCCESSFUL "Успешно" -#define D_SUNRISE "Sunrise" -#define D_SUNSET "Sunset" +#define D_SUNRISE "Восход" +#define D_SUNSET "Закат" #define D_TEMPERATURE "Температура" #define D_TO "до" #define D_TOGGLE "Переключить" @@ -190,27 +191,27 @@ #define D_TVOC "TVOC" #define D_UPGRADE "обновление" #define D_UPLOAD "Загрузить" -#define D_UPTIME "Uptime" -#define D_USED "used" +#define D_UPTIME "Аптайм" +#define D_USED "использовано" #define D_USER "Пользователь" #define D_UTC_TIME "UTC" -#define D_UV_INDEX "UV Index" -#define D_UV_INDEX_1 "Low" -#define D_UV_INDEX_2 "Mid" -#define D_UV_INDEX_3 "High" -#define D_UV_INDEX_4 "Danger" +#define D_UV_INDEX "УФ Индекс" +#define D_UV_INDEX_1 "Низ" +#define D_UV_INDEX_2 "Сред" +#define D_UV_INDEX_3 "Выс" +#define D_UV_INDEX_4 "Опасный" #define D_UV_INDEX_5 "BurnL1/2" #define D_UV_INDEX_6 "BurnL3" #define D_UV_INDEX_7 "OoR" -#define D_UV_LEVEL "УФ уровень" -#define D_UV_POWER "UV Power" +#define D_UV_LEVEL "УФ Уровень" +#define D_UV_POWER "УФ Мощность" #define D_VERSION "Версия" #define D_VOC "VOC" #define D_VOLTAGE "Напряжение" -#define D_VOLUME "Volume" -#define D_WEIGHT "Weight" -#define D_WARMLIGHT "Тепло" -#define D_WEB_SERVER "Web сервер" +#define D_VOLUME "Громкость" +#define D_WEIGHT "Вес" +#define D_WARMLIGHT "Тёплый" +#define D_WEB_SERVER "Веб-сервер" #define D_SOC "State of Charge" #define D_SOH "State of Health" @@ -218,17 +219,17 @@ #define D_WARNING_MINIMAL_VERSION "ПРЕДУПРЕЖДЕНИЕ Эта версия не поддерживает персистентные настройки" #define D_LEVEL_10 "уровень 1-0" #define D_LEVEL_01 "уровень 0-1" -#define D_SERIAL_LOGGING_DISABLED "Serial logging отключен" -#define D_SYSLOG_LOGGING_REENABLED "Syslog logging включен" +#define D_SERIAL_LOGGING_DISABLED "Serial логирование выключено" +#define D_SYSLOG_LOGGING_REENABLED "Syslog логирование включено" #define D_SET_BAUDRATE_TO "Установить скорость передачи (Baudrate)" -#define D_RECEIVED_TOPIC "Полученный Топик" +#define D_RECEIVED_TOPIC "Полученный топик" #define D_DATA_SIZE "Размер данных" #define D_ANALOG_INPUT "Аналоговый вход" // support.ino #define D_OSWATCH "osWatch" -#define D_BLOCKED_LOOP "Блокирующий цикл" +#define D_BLOCKED_LOOP "Заблокированный цикл" #define D_WPS_FAILED_WITH_STATUS "WPS конфигурация НЕУДАЧНА со статусом" #define D_ACTIVE_FOR_3_MINUTES "активен в течение 3 минут" #define D_FAILED_TO_START "не удалось запустить" @@ -242,9 +243,9 @@ #define D_ATTEMPTING_CONNECTION "Попытка подключения..." #define D_CHECKING_CONNECTION "Проверка соединения..." #define D_QUERY_DONE "Запрос выполнен. Обнаружены службы MQTT" -#define D_MQTT_SERVICE_FOUND "MQTT сервис service найдено" +#define D_MQTT_SERVICE_FOUND "MQTT сервис найден" #define D_FOUND_AT "найдено в" -#define D_SYSLOG_HOST_NOT_FOUND "System лог хост не найден" +#define D_SYSLOG_HOST_NOT_FOUND "Syslog хост не найден" // settings.ino #define D_SAVED_TO_FLASH_AT "Сохранено во флэш-память" @@ -253,42 +254,42 @@ #define D_ERASED_SECTOR "Стереть сектор" // xdrv_02_webserver.ino -#define D_NOSCRIPT "To use Tasmota, please enable JavaScript" +#define D_NOSCRIPT "Чтобы использовать Tasmota, пожалуйста включите JavaScript" #define D_SAFEBOOT "SAFEBOOT" #define D_MINIMAL_FIRMWARE_PLEASE_UPGRADE "Прошивка MINIMAL
пожалуйста обновите" #define D_WEBSERVER_ACTIVE_ON "Веб-сервер активен" #define D_WITH_IP_ADDRESS "с IP-адресом" #define D_WEBSERVER_STOPPED "Веб-сервер остановлен" #define D_FILE_NOT_FOUND "Файл не найден" -#define D_REDIRECTED "Перенаправлено на адаптивный портал" -#define D_WIFIMANAGER_SET_ACCESSPOINT_AND_STATION "Wifi менеджер устанавливает Точку Доступа и сохраняет станцию" -#define D_WIFIMANAGER_SET_ACCESSPOINT "Wifi менеджер установил Точку Доступа" +#define D_REDIRECTED "Перенаправлено на captive portal" +#define D_WIFIMANAGER_SET_ACCESSPOINT_AND_STATION "Wi-Fi менеджер устанавливает Точку Доступа и сохраняет станцию" +#define D_WIFIMANAGER_SET_ACCESSPOINT "Wi-Fi менеджер установить Точку Доступа" #define D_TRYING_TO_CONNECT "Попытка подключения устройства к сети" -#define D_RESTART_IN "Перезапуск" +#define D_RESTART_IN "Перезагрзука" #define D_SECONDS "секунд" -#define D_DEVICE_WILL_RESTART "Устройство будет перезапущено через несколько секунд" +#define D_DEVICE_WILL_RESTART "Устройство будет перезагружено через несколько секунд" #define D_BUTTON_TOGGLE "Переключить" -#define D_CONFIGURATION "Конфигурация" +#define D_CONFIGURATION "Настройки" #define D_INFORMATION "Информация" #define D_FIRMWARE_UPGRADE "Обновление прошивки" -#define D_MANAGEMENT "Consoles" +#define D_MANAGEMENT "Управление" #define D_CONSOLE "Консоль" -#define D_CONFIRM_RESTART "Подтвердить перезагрузку" - -#define D_CONFIGURE_MODULE "Конфигурация Модуля" -#define D_CONFIGURE_WIFI "Конфигурация WiFi" -#define D_CONFIGURE_MQTT "Конфигурация MQTT" -#define D_CONFIGURE_DOMOTICZ "Конфигурация Domoticz" -#define D_CONFIGURE_LOGGING "Конфигурация Logging" -#define D_CONFIGURE_OTHER "Конфигурация прочее" -#define D_CONFIRM_RESET_CONFIGURATION "Подтвердить Сброс Конфигурации" -#define D_RESET_CONFIGURATION "Сброс Конфигурации" -#define D_BACKUP_CONFIGURATION "Резервное копирование Конфигурации" -#define D_RESTORE_CONFIGURATION "Восстановление Конфигурации" -#define D_MAIN_MENU "Главное Меню" - -#define D_MODULE_PARAMETERS "Параметры модуля" +#define D_CONFIRM_RESTART "Перезагрузить устройство?" + +#define D_CONFIGURE_MODULE "Настройки модуля" +#define D_CONFIGURE_WIFI "Настройки Wi-Fi" +#define D_CONFIGURE_MQTT "Настройки MQTT" +#define D_CONFIGURE_DOMOTICZ "Настройки Domoticz" +#define D_CONFIGURE_LOGGING "Настройки логирования" +#define D_CONFIGURE_OTHER "Прочие настрйки" +#define D_CONFIRM_RESET_CONFIGURATION "Выполнить cброс настроек?" +#define D_RESET_CONFIGURATION "Сброс настроек" +#define D_BACKUP_CONFIGURATION "Резервное копирование настроек" +#define D_RESTORE_CONFIGURATION "Восстановление настроек" +#define D_MAIN_MENU "Главное меню" + +#define D_MODULE_PARAMETERS "Настройки модуля" #define D_MODULE_TYPE "Тип модуля" #define D_PULLUP_ENABLE "No Button/Switch pull-up" #define D_ADC "ADC" @@ -296,8 +297,8 @@ #define D_SERIAL_IN "Serial вход" #define D_SERIAL_OUT "Serial выход" -#define D_WIFI_PARAMETERS "Параметры Wifi" -#define D_SCAN_FOR_WIFI_NETWORKS "Сканирование беспроводных сетей Wifi" +#define D_WIFI_PARAMETERS "Настройки Wi-Fi" +#define D_SCAN_FOR_WIFI_NETWORKS "Сканирование сетей Wi-Fi" #define D_SCAN_DONE "Сканирование завершено" #define D_NO_NETWORKS_FOUND "Не найдено сетей" #define D_REFRESH_TO_SCAN_AGAIN "Обновить для повторного сканирования" @@ -307,62 +308,62 @@ #define D_WEP "WEP" #define D_WPA_PSK "WPA PSK" #define D_WPA2_PSK "WPA2 PSK" -#define D_AP1_SSID "WiFi Network" -#define D_AP1_SSID_HELP "Type or Select your WiFi Network" -#define D_AP2_SSID "WiFi Network 2" -#define D_AP2_SSID_HELP "Type your Alternative WiFi Network" -#define D_AP_PASSWORD "WiFi Пароль" -#define D_AP_PASSWORD_HELP "Enter your WiFi Password" -#define D_SELECT_YOUR_WIFI_NETWORK "Select your WiFi Network" -#define D_SHOW_MORE_WIFI_NETWORKS "Scan for all WiFi Networks" -#define D_SHOW_MORE_OPTIONS "More Options" -#define D_CHECK_CREDENTIALS "Please, check your credentials" -#define D_SUCCESSFUL_WIFI_CONNECTION "Successful WiFi Connection" -#define D_NOW_YOU_CAN_CLOSE_THIS_WINDOW "Now you can close this window" -#define D_REDIRECTING_TO_NEW_IP "Redirecting to new device's IP address" - -#define D_MQTT_PARAMETERS "Параметры MQTT" +#define D_AP1_SSID "Wi-Fi Сеть" +#define D_AP1_SSID_HELP "Введите или выберите вашу Wi-Fi сеть" +#define D_AP2_SSID "Wi-Fi Сеть 2" +#define D_AP2_SSID_HELP "Введите дополнительную Wi-Fi сеть" +#define D_AP_PASSWORD "Пароль" +#define D_AP_PASSWORD_HELP "Введите пароль от сети Wi-Fi" +#define D_SELECT_YOUR_WIFI_NETWORK "Выберите вашу Wi-Fi сеть" +#define D_SHOW_MORE_WIFI_NETWORKS "Сканировать все сети Wi-Fi" +#define D_SHOW_MORE_OPTIONS "Больше настроек" +#define D_CHECK_CREDENTIALS "Пожалуйста, проверьте ваши учетные данные" +#define D_SUCCESSFUL_WIFI_CONNECTION "Успешное подключение к Wi-Fi" +#define D_NOW_YOU_CAN_CLOSE_THIS_WINDOW "Теперь вы можете закрыть это окно" +#define D_REDIRECTING_TO_NEW_IP "Переадресация на новый IP адрес устройства" + +#define D_MQTT_PARAMETERS "Настройки MQTT" #define D_CLIENT "Клиент" -#define D_FULL_TOPIC "Полный Топик" +#define D_FULL_TOPIC "Полный топик" -#define D_LOGGING_PARAMETERS "Параметры Logging" -#define D_SERIAL_LOG_LEVEL "Serial лог уровень" -#define D_MQTT_LOG_LEVEL "Mqtt log level" -#define D_WEB_LOG_LEVEL "Web лог уровень" -#define D_SYS_LOG_LEVEL "System лог уровень" +#define D_LOGGING_PARAMETERS "Настройки логирования" +#define D_SERIAL_LOG_LEVEL "Уровень логирования Serial" +#define D_MQTT_LOG_LEVEL "Уровень логирования MQTT" +#define D_WEB_LOG_LEVEL "Уровень логирования Web" +#define D_SYS_LOG_LEVEL "Уровень логирования Syslog" #define D_MORE_DEBUG "Дополнительная информация для отладки" -#define D_SYSLOG_HOST "System лог хост" -#define D_SYSLOG_PORT "System лог порт" -#define D_TELEMETRY_PERIOD "Период телеметрии" - -#define D_OTHER_PARAMETERS "Параметры Прочие" -#define D_TEMPLATE "Template" -#define D_ACTIVATE "Activate" -#define D_DEVICE_NAME "Device Name" -#define D_WEB_ADMIN_PASSWORD "Пароль Web администратора" -#define D_MQTT_ENABLE "MQTT активен" +#define D_SYSLOG_HOST "Порт Syslog" +#define D_SYSLOG_PORT "Хост Syslog" +#define D_TELEMETRY_PERIOD "Период отправки телеметрии" + +#define D_OTHER_PARAMETERS "Настройки Прочие" +#define D_TEMPLATE "Шаблон" +#define D_ACTIVATE "Активировать" +#define D_DEVICE_NAME "Имя устройства" +#define D_WEB_ADMIN_PASSWORD "Пароль веб-интерфейса" +#define D_MQTT_ENABLE "Включить MQTT" #define D_MQTT_TLS_ENABLE "MQTT TLS" #define D_HTTP_API "HTTP API" -#define D_HTTP_API_ENABLE "HTTP API активен" -#define D_FRIENDLY_NAME "Дружественное Имя" +#define D_HTTP_API_ENABLE "Включить HTTP API" +#define D_FRIENDLY_NAME "Понятное имя устройства" #define D_BELKIN_WEMO "Belkin WeMo" #define D_HUE_BRIDGE "Hue Bridge" #define D_SINGLE_DEVICE "одиночное" #define D_MULTI_DEVICE "мульти" -#define D_CONFIGURE_TEMPLATE "Конфигурация Template" -#define D_TEMPLATE_PARAMETERS "Параметры Template" -#define D_TEMPLATE_NAME "Name" -#define D_BASE_TYPE "Based on" -#define D_TEMPLATE_FLAGS "Options" +#define D_CONFIGURE_TEMPLATE "Настройки шаблона" +#define D_TEMPLATE_PARAMETERS "Настройки шаблона" +#define D_TEMPLATE_NAME "Имя" +#define D_BASE_TYPE "На основе" +#define D_TEMPLATE_FLAGS "Настройки" -#define D_SAVE_CONFIGURATION "Сохранить конфигурацию" -#define D_CONFIGURATION_SAVED "Конфигурация сохранена " -#define D_CONFIGURATION_RESET "Конфигурация сброшена" +#define D_SAVE_CONFIGURATION "Сохранить настройки" +#define D_CONFIGURATION_SAVED "Настройки сохранены " +#define D_CONFIGURATION_RESET "Настройки сброшены" #define D_PROGRAM_VERSION "Версия программы" -#define D_BUILD_DATE_AND_TIME "Дата & Время сборки" -#define D_CORE_AND_SDK_VERSION "Версия Core/SDK" +#define D_BUILD_DATE_AND_TIME "Дата и время сборки" +#define D_CORE_AND_SDK_VERSION "Версия ядра/SDK" #define D_FLASH_WRITE_COUNT "Кол-во записей Flash" #define D_MAC_ADDRESS "MAC Адрес" #define D_MQTT_HOST "MQTT Хост" @@ -380,47 +381,47 @@ #define D_FLASH_CHIP_SIZE "Размер Flash памяти" #define D_FREE_PROGRAM_SPACE "Свободное пространство программ" -#define D_UPGRADE_BY_WEBSERVER "Обновление через Веб-сервер" -#define D_OTA_URL "OTA Url" +#define D_UPGRADE_BY_WEBSERVER "Обновление через веб-сервер" +#define D_OTA_URL "Ссылка OTA" #define D_START_UPGRADE "Начать обновление" -#define D_UPGRADE_BY_FILE_UPLOAD "Обновление путем загрузки файлов" -#define D_UPLOAD_FACTORY "Switching to safeboot partition" +#define D_UPGRADE_BY_FILE_UPLOAD "Обновление путем загрузки файлa" +#define D_UPLOAD_FACTORY "Переключение на раздел safeboot" #define D_UPLOAD_STARTED "Загрузка началась" #define D_UPGRADE_STARTED "Обновление началось" #define D_UPLOAD_DONE "Загрузка завершена" #define D_UPLOAD_TRANSFER "Upload transfer" -#define D_TRANSFER_STARTED "Transfer started" +#define D_TRANSFER_STARTED "Передача началась" #define D_UPLOAD_ERR_1 "Файл не выбран" #define D_UPLOAD_ERR_2 "Недостаточно места" -#define D_UPLOAD_ERR_3 "Invalid file signature" +#define D_UPLOAD_ERR_3 "Неверная подпись файла" #define D_UPLOAD_ERR_4 "Размер прошивки больше, чем реальный размер флеш памяти" #define D_UPLOAD_ERR_5 "Ошибка загрузки буфера" #define D_UPLOAD_ERR_6 "Ошибка загрузки. Включено лог уровня 3" #define D_UPLOAD_ERR_7 "Загрузка прервана" #define D_UPLOAD_ERR_8 "Файл неверный" #define D_UPLOAD_ERR_9 "Слишком большой файл" -#define D_UPLOAD_ERR_10 "Failed to init RF chip" -#define D_UPLOAD_ERR_11 "Failed to erase RF chip" -#define D_UPLOAD_ERR_12 "Failed to write to RF chip" -#define D_UPLOAD_ERR_13 "Failed to decode RF firmware" -#define D_UPLOAD_ERR_14 "Not compatible" +#define D_UPLOAD_ERR_10 "Не удалось инициализировать RF чип" +#define D_UPLOAD_ERR_11 "Не удалось стереть RF чип" +#define D_UPLOAD_ERR_12 "Не удалось записать в RF чип" +#define D_UPLOAD_ERR_13 "Не удалось декодировать прошивку RF чипа" +#define D_UPLOAD_ERR_14 "Не совместимо" #define D_UPLOAD_ERROR_CODE "Код ошибки загрузки" #define D_ENTER_COMMAND "Введите команду" -#define D_ENABLE_WEBLOG_FOR_RESPONSE "Включить Веб лог уровня 2 если ожидается ответ" +#define D_ENABLE_WEBLOG_FOR_RESPONSE "Включите веб лог уровня 2 если ожидается ответ" #define D_NEED_USER_AND_PASSWORD "Ожидается user=&password=" // xdrv_01_mqtt.ino -#define D_FINGERPRINT "Проверка TLS Fingerprint..." -#define D_TLS_CONNECT_FAILED_TO "Сбой подключения TLS к" +#define D_FINGERPRINT "Проверка отпечатка TLS..." +#define D_TLS_CONNECT_FAILED_TO "Сбой TLS подключения к" #define D_RETRY_IN "Повторить" -#define D_VERIFIED "Проверено Fingerprint" -#define D_INSECURE "Небезопасное соединение, недействительный Fingerprint" +#define D_VERIFIED "Отпечаток проверен" +#define D_INSECURE "Соединение небезопасно, неверный отпечаток" #define D_CONNECT_FAILED_TO "Ошибка подключения к" // xplg_wemohue.ino #define D_MULTICAST_DISABLED "Multicast отключен" -#define D_MULTICAST_REJOINED "Multicast (ре)соединился" +#define D_MULTICAST_REJOINED "Multicast (пере)подключился" #define D_MULTICAST_JOIN_FAILED "Multicast ошибка соединения" #define D_FAILED_TO_SEND_RESPONSE "Не удалось отправить ответ" @@ -428,18 +429,18 @@ #define D_WEMO_BASIC_EVENT "WeMo основное событие" #define D_WEMO_EVENT_SERVICE "WeMo служба событий" #define D_WEMO_META_SERVICE "WeMo мета-сервис" -#define D_WEMO_SETUP "WeMo настройка" +#define D_WEMO_SETUP "Найстрока WeMo" #define D_RESPONSE_SENT "Ответ отправлен" #define D_HUE "Hue" -#define D_HUE_BRIDGE_SETUP "Hue настройка" +#define D_HUE_BRIDGE_SETUP "Настройки Hue" #define D_HUE_API_NOT_IMPLEMENTED "Hue API не реализовано" #define D_HUE_API "Hue API" -#define D_HUE_POST_ARGS "Hue POST args" +#define D_HUE_POST_ARGS "Hue POST арг." #define D_3_RESPONSE_PACKETS_SENT "3 ответных пакета получено" // xdrv_07_domoticz.ino -#define D_DOMOTICZ_PARAMETERS "Параметры Domoticz" +#define D_DOMOTICZ_PARAMETERS "Настройки Domoticz" #define D_DOMOTICZ_IDX "Idx" #define D_DOMOTICZ_KEY_IDX "Key idx" #define D_DOMOTICZ_SWITCH_IDX "Switch idx" @@ -457,35 +458,35 @@ #define D_DOMOTICZ_UPDATE_TIMER "Update timer" // xdrv_09_timers.ino -#define D_CONFIGURE_TIMER "Конфигурация Timer" -#define D_TIMER_PARAMETERS "Параметры Timer" -#define D_TIMER_ENABLE "Enable Timers" -#define D_TIMER_ARM "Arm" -#define D_TIMER_TIME "Time" -#define D_TIMER_DAYS "Days" -#define D_TIMER_REPEAT "Repeat" -#define D_TIMER_OUTPUT "Output" -#define D_TIMER_ACTION "Action" +#define D_CONFIGURE_TIMER "Настройки таймера" +#define D_TIMER_PARAMETERS "Настройки таймера" +#define D_TIMER_ENABLE "Включить таймеры" +#define D_TIMER_ARM "Включить" +#define D_TIMER_TIME "Время" +#define D_TIMER_DAYS "Дни" +#define D_TIMER_REPEAT "Повторять" +#define D_TIMER_OUTPUT "Выход" +#define D_TIMER_ACTION "Действие" // xdrv_10_knx.ino -#define D_CONFIGURE_KNX "Конфигурация KNX" -#define D_KNX_PARAMETERS "Параметры KNX" +#define D_CONFIGURE_KNX "Настройки KNX" +#define D_KNX_PARAMETERS "Настройки KNX" #define D_KNX_GENERAL_CONFIG "General" -#define D_KNX_PHYSICAL_ADDRESS "Physical Address" -#define D_KNX_PHYSICAL_ADDRESS_NOTE "( Must be unique on the KNX network )" -#define D_KNX_ENABLE "Enable KNX" -#define D_KNX_GROUP_ADDRESS_TO_WRITE "Data to Send to Group Addresses" -#define D_ADD "Add" -#define D_DELETE "Delete" -#define D_REPLY "Reply" -#define D_KNX_GROUP_ADDRESS_TO_READ "Group Addresses to Receive Data from" -#define D_RECEIVED_FROM "Received from" -#define D_KNX_COMMAND_WRITE "Write" -#define D_KNX_COMMAND_READ "Read" -#define D_KNX_COMMAND_OTHER "Other" -#define D_SENT_TO "sent to" -#define D_KNX_WARNING "The group address ( 0 / 0 / 0 ) is reserved and can not be used." -#define D_KNX_ENHANCEMENT "Communication Enhancement" +#define D_KNX_PHYSICAL_ADDRESS "Физический адрес" +#define D_KNX_PHYSICAL_ADDRESS_NOTE "( Должен быть уникальным в сети KNX )" +#define D_KNX_ENABLE "Включить KNX" +#define D_KNX_GROUP_ADDRESS_TO_WRITE "Данные для отправки на групповые адреса" +#define D_ADD "Добавить" +#define D_DELETE "Удалить" +#define D_REPLY "Ответ" +#define D_KNX_GROUP_ADDRESS_TO_READ "Групповые адреса для получения данных" +#define D_RECEIVED_FROM "Получено от" +#define D_KNX_COMMAND_WRITE "Запись" +#define D_KNX_COMMAND_READ "Чтение" +#define D_KNX_COMMAND_OTHER "Другая" +#define D_SENT_TO "отправить" +#define D_KNX_WARNING "Групповой адрес ( 0 / 0 / 0 ) является зарезервированым и не может быть использован." +#define D_KNX_ENHANCEMENT "Улучшение связи" #define D_KNX_TX_SLOT "KNX TX" #define D_KNX_RX_SLOT "KNX RX" #define D_KNX_TX_SCENE "KNX SCENE TX" @@ -522,25 +523,25 @@ // xdrv_89_dali.ino #define D_SENSOR_DALI_RX "Dali RX" #define D_SENSOR_DALI_TX "Dali TX" -#define D_CONFIGURE_DALI "Конфигурация DALI" +#define D_CONFIGURE_DALI "Настройки DALI" // xdrv_03_energy.ino -#define D_ENERGY_TODAY "Энергия Сегодня" -#define D_ENERGY_YESTERDAY "Энергия Вчера" -#define D_ENERGY_TOTAL "Энергия Всего" +#define D_ENERGY_TODAY "Энергия сегодня" +#define D_ENERGY_YESTERDAY "Энергия вчера" +#define D_ENERGY_TOTAL "Энергия всего" // xdrv_27_shutter.ino -#define D_OPEN "Open" -#define D_CLOSE "Close" -#define D_DOMOTICZ_SHUTTER "Shutter" +#define D_OPEN "Отрыть" +#define D_CLOSE "Закрыть" +#define D_DOMOTICZ_SHUTTER "Жалюзи" // xdrv_28_pcf8574.ino -#define D_CONFIGURE_PCF8574 "Configure PCF8574" -#define D_PCF8574_PARAMETERS "PCF8574 parameters" -#define D_INVERT_PORTS "Invert Ports" -#define D_DEVICE "Device" -#define D_DEVICE_INPUT "Input" -#define D_DEVICE_OUTPUT "Output" +#define D_CONFIGURE_PCF8574 "Настройки PCF8574" +#define D_PCF8574_PARAMETERS "Настройки PCF8574" +#define D_INVERT_PORTS "Инвертировать порты" +#define D_DEVICE "Устройство" +#define D_DEVICE_INPUT "Вход" +#define D_DEVICE_OUTPUT "Выход" // xsns_05_ds18b20.ino #define D_SENSOR_BUSY "Датчик DS18x20 занят" @@ -548,7 +549,7 @@ #define D_SENSORS_FOUND "Датчик DS18x20 найден" // xsns_06_dht.ino -#define D_TIMEOUT_WAITING_FOR "Тайм-аут, в ожидании" +#define D_TIMEOUT_WAITING_FOR "Превышено время ожидания" #define D_START_SIGNAL_LOW "сигнал старт низкий" #define D_START_SIGNAL_HIGH "сигнал старт высокий" #define D_PULSE "пульс" @@ -561,10 +562,10 @@ // xsns_18_pms5003.ino #define D_STANDARD_CONCENTRATION "CF-1 PM" // Standard Particle CF-1 Particle Matter #define D_ENVIRONMENTAL_CONCENTRATION "PM" // Environmetal Particle Matter -#define D_PARTICALS_BEYOND "Particals" +#define D_PARTICALS_BEYOND "Частицы" // xsns_27_apds9960.ino -#define D_GESTURE "Gesture" +#define D_GESTURE "Жест" #define D_COLOR_RED "Red" #define D_COLOR_GREEN "Green" #define D_COLOR_BLUE "Blue" @@ -572,12 +573,12 @@ #define D_PROXIMITY "Proximity" // xsns_32_mpu6050.ino -#define D_AX_AXIS "Accel. X-Axis" -#define D_AY_AXIS "Accel. Y-Axis" -#define D_AZ_AXIS "Accel. Z-Axis" -#define D_GX_AXIS "Gyro X-Axis" -#define D_GY_AXIS "Gyro Y-Axis" -#define D_GZ_AXIS "Gyro Z-Axis" +#define D_AX_AXIS "Ускор. ось X" +#define D_AY_AXIS "Ускор. ось Y" +#define D_AZ_AXIS "Ускор. ось Z" +#define D_GX_AXIS "Гироскоп ось X" +#define D_GY_AXIS "Гироскоп ось Y" +#define D_GZ_AXIS "Гироскоп ось Z" // xsns_33_QMC5883L.ino #define D_MX "Induction X-Axis" @@ -588,25 +589,25 @@ // xsns_34_hx711.ino #define D_HX_CAL_REMOVE "Remove weight" #define D_HX_CAL_REFERENCE "Load reference weight" -#define D_HX_CAL_DONE "Calibrated" -#define D_HX_CAL_FAIL "Calibration failed" -#define D_RESET_HX711 "Reset Scale" -#define D_CONFIGURE_HX711 "Configure Scale" -#define D_HX711_PARAMETERS "Scale parameters" -#define D_ITEM_WEIGHT "Item weight" -#define D_REFERENCE_WEIGHT "Reference weight" -#define D_CALIBRATE "Calibrate" -#define D_CALIBRATION "Calibration" +#define D_HX_CAL_DONE "Откалибровано" +#define D_HX_CAL_FAIL "Ошибка калибровки" +#define D_RESET_HX711 "Сбросить весы" +#define D_CONFIGURE_HX711 "Настроить весы" +#define D_HX711_PARAMETERS "Параметры весов" +#define D_ITEM_WEIGHT "Вес предмета" +#define D_REFERENCE_WEIGHT "Калибровочный вес" +#define D_CALIBRATE "Калибровать" +#define D_CALIBRATION "Калибровка" //xsns_35_tx20.ino -#define D_TX20_WIND_DIRECTION "Wind Direction" -#define D_TX20_WIND_SPEED "Wind Speed" -#define D_TX20_WIND_SPEED_MIN "Wind Speed Min" -#define D_TX20_WIND_SPEED_MAX "Wind Speed Max" -#define D_TX20_NORTH "N" -#define D_TX20_EAST "E" -#define D_TX20_SOUTH "S" -#define D_TX20_WEST "W" +#define D_TX20_WIND_DIRECTION "Направление ветра" +#define D_TX20_WIND_SPEED "Скорость ветра" +#define D_TX20_WIND_SPEED_MIN "Мин. скорость ветра" +#define D_TX20_WIND_SPEED_MAX "Макс. скорость ветра" +#define D_TX20_NORTH "С" +#define D_TX20_EAST "В" +#define D_TX20_SOUTH "Ю" +#define D_TX20_WEST "З" // xsns_53_sml.ino #define D_TPWRIN "Energy Total-In" @@ -631,8 +632,8 @@ #define D_SpL1L2L3 "Voltage L1+L2+L3/3" // xsns_86_tfminiplus.ino -#define D_SIGNALSTRENGTH "Signal Strength" -#define D_CHIPTEMPERATURE "Chip Temperature" +#define D_SIGNALSTRENGTH "Сила сигнала" +#define D_CHIPTEMPERATURE "Температура чипа" // tasmota_template.h - keep them as short as possible to be able to fit them in GUI drop down box #define D_SENSOR_NONE "-нет-" @@ -656,15 +657,15 @@ #define D_SENSOR_DFR562 "MP3 Player" #define D_SENSOR_DFR562_BUSY "MP3 Busy" #define D_SENSOR_IRSEND "IRsend" -#define D_SENSOR_SWITCH "Свич" // Suffix "1" +#define D_SENSOR_SWITCH "Переключ." // Suffix "1" #define D_SENSOR_BUTTON "Кнопка" // Suffix "1" #define D_SENSOR_RELAY "Реле" // Suffix "1i" #define D_SENSOR_LED "Led" // Suffix "1i" #define D_SENSOR_LED_LINK "LedLink" // Suffix "i" -#define D_SENSOR_PWM "PWM" // Suffix "1" +#define D_SENSOR_PWM "ШИМ" // Suffix "1" #define D_SENSOR_COUNTER "Счетчик" // Suffix "1" -#define D_SENSOR_INTERRUPT "Interrupt" -#define D_SENSOR_INPUT "Input" +#define D_SENSOR_INTERRUPT "Прерывание" +#define D_SENSOR_INPUT "Вход" #define D_SENSOR_IRRECV "IRrecv" #define D_SENSOR_MHZ_RX "MHZ Rx" #define D_SENSOR_MHZ_TX "MHZ Tx" @@ -685,7 +686,7 @@ #define D_SENSOR_SDIO_D1 "SDIO D1" #define D_SENSOR_SDIO_D2 "SDIO D2" #define D_SENSOR_SDIO_D3 "SDIO D3" -#define D_SENSOR_BACKLIGHT "Backlight" +#define D_SENSOR_BACKLIGHT "Подсветка" #define D_SENSOR_PMS5003_TX "PMS5003 Tx" #define D_SENSOR_PMS5003_RX "PMS5003 Rx" #define D_SENSOR_SDS0X1_RX "SDS0X1 Rx" @@ -784,7 +785,7 @@ #define D_SENSOR_ADE7953_IRQ "ADE7953 IRQ" #define D_SENSOR_ADE7953_RST "ADE7953 RST" #define D_SENSOR_ADE7953_CS "ADE7953 CS" -#define D_SENSOR_BUZZER "Buzzer" +#define D_SENSOR_BUZZER "Зуммер" #define D_SENSOR_DISP_RESET "Display Rst" #define D_SENSOR_ZIGBEE_TXD "Zigbee Tx" #define D_SENSOR_ZIGBEE_RXD "Zigbee Rx" @@ -840,11 +841,11 @@ #define D_SENSOR_TELEINFO_RX "TInfo Rx" #define D_SENSOR_TELEINFO_ENABLE "TInfo EN" #define D_SENSOR_LMT01_PULSE "LMT01 Pulse" -#define D_SENSOR_ADC_INPUT "ADC Input" -#define D_SENSOR_ADC_TEMP "ADC Temp" -#define D_SENSOR_ADC_LIGHT "ADC Light" -#define D_SENSOR_ADC_BUTTON "ADC Button" -#define D_SENSOR_ADC_RANGE "ADC Range" +#define D_SENSOR_ADC_INPUT "ADC Вход" +#define D_SENSOR_ADC_TEMP "ADC Темп." +#define D_SENSOR_ADC_LIGHT "ADC Свет" +#define D_SENSOR_ADC_BUTTON "ADC Кнопка" +#define D_SENSOR_ADC_RANGE "ADC Диапазон" #define D_SENSOR_ADC_CT_POWER "ADC CT Power" #define D_SENSOR_ADC_JOYSTICK "ADC Joystick" #define D_SENSOR_ADC_PH "ADC pH" @@ -912,7 +913,7 @@ #define D_SENSOR_BL6523_TX "BL6523 Tx" #define D_SENSOR_BL6523_RX "BL6523 Rx" #define D_SENSOR_HEARTBEAT "Heartbeat" -#define D_SENSOR_RESET "Reset" +#define D_SENSOR_RESET "Сброс" #define D_GPIO_SHIFT595_SRCLK "74x595 SRCLK" #define D_GPIO_SHIFT595_RCLK "74x595 RCLK" #define D_GPIO_SHIFT595_OE "74x595 OE" @@ -1007,54 +1008,54 @@ #define D_RESETTABLE_TOTAL_ACTIVE "Total Active (RST)" //SOLAXX1 -#define D_PV1_VOLTAGE "PV1 Voltage" -#define D_PV1_CURRENT "PV1 Current" -#define D_PV1_POWER "PV1 Power" -#define D_PV2_VOLTAGE "PV2 Voltage" -#define D_PV2_CURRENT "PV2 Current" -#define D_PV2_POWER "PV2 Power" -#define D_SOLAR_POWER "Solar Power" -#define D_INVERTER_POWER "Inverter Power" -#define D_STATUS "Status" -#define D_SOLAX_MODE_0 "Waiting" -#define D_SOLAX_MODE_1 "Checking" -#define D_SOLAX_MODE_2 "Working" -#define D_SOLAX_MODE_3 "Failure" -#define D_SOLAX_MODE_4 "Permanent Failure" // to be translated -#define D_SOLAX_MODE_5 "Software Update" // to be translated -#define D_SOLAX_MODE_6 "Selftest" // to be translated -#define D_SOLAX_ERROR_0 "No Error Code" -#define D_SOLAX_ERROR_1 "Grid Lost Fault" -#define D_SOLAX_ERROR_2 "Grid Voltage Fault" -#define D_SOLAX_ERROR_3 "Grid Frequency Fault" -#define D_SOLAX_ERROR_4 "Pv Voltage Fault" -#define D_SOLAX_ERROR_5 "Isolation Fault" -#define D_SOLAX_ERROR_6 "Over Temperature Fault" -#define D_SOLAX_ERROR_7 "Fan Fault" -#define D_SOLAX_ERROR_8 "Other Device Fault" +#define D_PV1_VOLTAGE "Напряжение PV1" +#define D_PV1_CURRENT "Ток PV1" +#define D_PV1_POWER "Мощность PV1" +#define D_PV2_VOLTAGE "Напряжение PV2" +#define D_PV2_CURRENT "Напряжение PV2" +#define D_PV2_POWER "Мощность PV2" +#define D_SOLAR_POWER "Мощность солнца" +#define D_INVERTER_POWER "Мощность инвертора" +#define D_STATUS "Статус" +#define D_SOLAX_MODE_0 "Ожидание" +#define D_SOLAX_MODE_1 "Проверка" +#define D_SOLAX_MODE_2 "Работает" +#define D_SOLAX_MODE_3 "Сбой" +#define D_SOLAX_MODE_4 "Постоянный сбой" +#define D_SOLAX_MODE_5 "Обновление ПО" +#define D_SOLAX_MODE_6 "Самопроверка" +#define D_SOLAX_ERROR_0 "Нет кода ошибки" +#define D_SOLAX_ERROR_1 "Ошибка: потеря сети" +#define D_SOLAX_ERROR_2 "Ошибка: напряжение сети" +#define D_SOLAX_ERROR_3 "Ошибка: частота сети" +#define D_SOLAX_ERROR_4 "Ошибка: напряжение Pv" +#define D_SOLAX_ERROR_5 "Ошибка: изоляция" +#define D_SOLAX_ERROR_6 "Ошибка: перегрев" +#define D_SOLAX_ERROR_7 "Сбой ветилятора" +#define D_SOLAX_ERROR_8 "Другой сбой устройства" //xdrv_10_scripter.ino -#define D_CONFIGURE_SCRIPT "Edit script" -#define D_SCRIPT "edit script" -#define D_SDCARD_UPLOAD "file upload" -#define D_UFSDIR "ufs directory" -#define D_UPL_DONE "Done" -#define D_SCRIPT_CHARS_LEFT "chars left" -#define D_SCRIPT_CHARS_NO_MORE "no more chars" -#define D_SCRIPT_DOWNLOAD "Download" -#define D_SCRIPT_ENABLE "script enable" -#define D_SCRIPT_UPLOAD "Upload" -#define D_SCRIPT_UPLOAD_FILES "Upload files" +#define D_CONFIGURE_SCRIPT "Редактировать скрипт" +#define D_SCRIPT "редактировать скрипт" +#define D_SDCARD_UPLOAD "загрузка файлов" +#define D_UFSDIR "директория ufs" +#define D_UPL_DONE "Готово" +#define D_SCRIPT_CHARS_LEFT "символов осталось" +#define D_SCRIPT_CHARS_NO_MORE "больше нет символов" +#define D_SCRIPT_DOWNLOAD "Скачать" +#define D_SCRIPT_ENABLE "скрипт включен" +#define D_SCRIPT_UPLOAD "Загрузить" +#define D_SCRIPT_UPLOAD_FILES "Загрузить файлы" //xdrv_50_filesystem.ino -#define D_MANAGE_FILE_SYSTEM "Manage File system" -#define D_FS_SIZE "Size" -#define D_FS_FREE "Free" +#define D_MANAGE_FILE_SYSTEM "Управление файловой системой" +#define D_FS_SIZE "Размер" +#define D_FS_FREE "Свободно" #define D_NEW_FILE "newfile.txt" -#define D_CREATE_NEW_FILE "Create and edit new file" -#define D_EDIT_FILE "Edit File" -#define D_CONFIRM_FILE_DEL "Confirm file deletion" -#define D_SHOW_HIDDEN_FILES "Show hidden files" +#define D_CREATE_NEW_FILE "Создать и редактировать новый файл" +#define D_EDIT_FILE "Редактировать файл" +#define D_CONFIRM_FILE_DEL "Подтвердите удаление файла" +#define D_SHOW_HIDDEN_FILES "Показывать скрытые файлы" //xsns_67_as3935.ino #define D_AS3935_GAIN "gain:" diff --git a/tasmota/tasmota.ino b/tasmota/tasmota.ino index 67a149347fe1..a74efb45f4bf 100644 --- a/tasmota/tasmota.ino +++ b/tasmota/tasmota.ino @@ -406,6 +406,7 @@ void setup(void) { #ifdef CONFIG_IDF_TARGET_ESP32 // restore GPIO16/17 if no PSRAM is found + #if ESP_IDF_VERSION_MAJOR < 5 // TODO for esp-idf 5 if (!FoundPSRAM()) { // test if the CPU is not pico uint32_t chip_ver = REG_GET_FIELD(EFUSE_BLK0_RDATA3_REG, EFUSE_RD_CHIP_VER_PKG); @@ -415,6 +416,7 @@ void setup(void) { gpio_reset_pin(GPIO_NUM_17); } } + #endif #endif // CONFIG_IDF_TARGET_ESP32 #endif // ESP32 diff --git a/tasmota/tasmota_support/settings.ino b/tasmota/tasmota_support/settings.ino index 4459408652d0..e6ac6e6b8af8 100644 --- a/tasmota/tasmota_support/settings.ino +++ b/tasmota/tasmota_support/settings.ino @@ -189,6 +189,9 @@ bool RtcRebootValid(void) { extern "C" { #include "spi_flash.h" +#if ESP_IDF_VERSION_MAJOR >= 5 + #include "spi_flash_mmap.h" +#endif } #ifdef ESP8266 diff --git a/tasmota/tasmota_support/support_command.ino b/tasmota/tasmota_support/support_command.ino index 5233762969f5..40be1cf49122 100644 --- a/tasmota/tasmota_support/support_command.ino +++ b/tasmota/tasmota_support/support_command.ino @@ -200,13 +200,15 @@ void CmndWifiTest(void) if (0 == XdrvMailbox.index) { Wifi.wifi_Test_Restart = true; } // If WifiTest is successful, save data on SSID1 and restart if (2 == XdrvMailbox.index) { Wifi.wifi_Test_Save_SSID2 = true; } // If WifiTest is successful, save data on SSID2 - SettingsUpdateText(Wifi.wifi_Test_Save_SSID2 ? SET_STASSID2 : SET_STASSID1, ssid_test); - SettingsUpdateText(Wifi.wifi_Test_Save_SSID2 ? SET_STAPWD2 : SET_STAPWD1, pswd_test); + if (3 != XdrvMailbox.index) { // WifiTest3 never ever makes anything persistent, thus works without webserver + SettingsUpdateText(Wifi.wifi_Test_Save_SSID2 ? SET_STASSID2 : SET_STASSID1, ssid_test); + SettingsUpdateText(Wifi.wifi_Test_Save_SSID2 ? SET_STAPWD2 : SET_STAPWD1, pswd_test); + } AddLog(LOG_LEVEL_INFO, PSTR(D_LOG_WIFI D_CONNECTING_TO_AP " %s " D_AS " %s ..."), - SettingsText(Wifi.wifi_Test_Save_SSID2 ? SET_STASSID2 : SET_STASSID1), TasmotaGlobal.hostname); + ssid_test, TasmotaGlobal.hostname); - WiFi.begin(SettingsText(Wifi.wifi_Test_Save_SSID2 ? SET_STASSID2 : SET_STASSID1), SettingsText(Wifi.wifi_Test_Save_SSID2 ? SET_STAPWD2 : SET_STAPWD1)); + WiFi.begin(ssid_test,pswd_test); } } else { ResponseCmndChar(D_JSON_BUSY); @@ -2746,4 +2748,4 @@ void CmndTouchThres(void) { } #endif // ESP32 SOC_TOUCH_VERSION_1 or SOC_TOUCH_VERSION_2 -#endif // ESP32 +#endif // ESP32 \ No newline at end of file diff --git a/tasmota/tasmota_support/support_crash_recorder.ino b/tasmota/tasmota_support/support_crash_recorder.ino index c3d6f63a9671..bf55869cdcb8 100644 --- a/tasmota/tasmota_support/support_crash_recorder.ino +++ b/tasmota/tasmota_support/support_crash_recorder.ino @@ -30,7 +30,7 @@ void CmndWDT(void) { volatile uint32_t dummy = 0; while (1) { - dummy++; + dummy = dummy + 1; } } @@ -160,7 +160,10 @@ void CrashDumpClear(void) // esp_err_t IRAM_ATTR esp_backtrace_print(int depth) #include "freertos/xtensa_api.h" -#if ESP_IDF_VERSION_MAJOR >= 4 +#if ESP_IDF_VERSION_MAJOR >= 5 + #include "esp_debug_helpers.h" + #include "esp_cpu_utils.h" +#elif ESP_IDF_VERSION_MAJOR >= 4 #include "esp_debug_helpers.h" #else // IDF 3.x #include "esp_panic.h" diff --git a/tasmota/tasmota_support/support_esp.ino b/tasmota/tasmota_support/support_esp.ino index 4315ee5d493c..c7d284ae7010 100644 --- a/tasmota/tasmota_support/support_esp.ino +++ b/tasmota/tasmota_support/support_esp.ino @@ -214,7 +214,6 @@ String GetCodeCores(void) { #ifdef ESP32 -#include "bootloader_flash.h" #include "soc/soc.h" #include "soc/spi_reg.h" // ESP32_ARCH contains the name of the architecture (used by autoconf) @@ -240,6 +239,7 @@ String GetCodeCores(void) { // See libraries\ESP32\examples\ResetReason.ino #if ESP_IDF_VERSION_MAJOR > 3 // IDF 4+ + #include "esp_chip_info.h" #if CONFIG_IDF_TARGET_ESP32 // ESP32/PICO-D4 #include "esp32/rom/rtc.h" #elif CONFIG_IDF_TARGET_ESP32S2 // ESP32-S2 @@ -255,6 +255,10 @@ String GetCodeCores(void) { #include "rom/rtc.h" #endif +#if ESP_IDF_VERSION_MAJOR >= 5 + #include "esp_chip_info.h" +#endif + // Set the Stacksize for Arduino core. Default is 8192, some builds may need a bigger one size_t getArduinoLoopTaskStackSize(void) { return SET_ESP32_STACK_SIZE; @@ -393,7 +397,12 @@ void NvsInfo(void) { // See Esp.cpp #include "Esp.h" -#include "esp_spi_flash.h" +#if ESP_IDF_VERSION_MAJOR >= 5 + // esp_spi_flash.h is deprecated, please use spi_flash_mmap.h instead + #include "spi_flash_mmap.h" +#else + #include "esp_spi_flash.h" +#endif #include #include #include @@ -423,6 +432,9 @@ extern "C" { #include "rom/spi_flash.h" #define ESP_FLASH_IMAGE_BASE 0x1000 #endif +#if ESP_IDF_VERSION_MAJOR >= 5 + #include "bootloader_common.h" +#endif uint32_t EspProgramSize(const char *label) { const esp_partition_t *part = esp_partition_find_first(ESP_PARTITION_TYPE_APP, ESP_PARTITION_SUBTYPE_ANY, label); @@ -715,7 +727,12 @@ uint8_t* FlashDirectAccess(void) { } extern "C" { - bool esp_spiram_is_initialized(void); + #if ESP_IDF_VERSION_MAJOR >= 5 + // bool IRAM_ATTR __attribute__((pure)) esp_psram_is_initialized(void) + bool esp_psram_is_initialized(void); + #else + bool esp_spiram_is_initialized(void); + #endif } // this function is a replacement for `psramFound()`. @@ -725,7 +742,11 @@ bool FoundPSRAM(void) { #if CONFIG_IDF_TARGET_ESP32C3 return psramFound(); #else - return psramFound() && esp_spiram_is_initialized(); + #if ESP_IDF_VERSION_MAJOR >= 5 + return psramFound() && esp_psram_is_initialized(); + #else + return psramFound() && esp_spiram_is_initialized(); + #endif #endif } @@ -874,8 +895,12 @@ typedef struct { pkg_version += ((word3 >> 2) & 0x1) << 3 return pkg_version */ +#if (ESP_IDF_VERSION_MAJOR >= 5) + uint32_t pkg_version = bootloader_common_get_chip_ver_pkg(); +#else uint32_t chip_ver = REG_GET_FIELD(EFUSE_BLK0_RDATA3_REG, EFUSE_RD_CHIP_VER_PKG); uint32_t pkg_version = chip_ver & 0x7; +#endif // AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("HDW: ESP32 Model %d, Revision %d, Core %d, Package %d"), chip_info.model, chip_revision, chip_info.cores, chip_ver); diff --git a/tasmota/tasmota_support/support_tasmota.ino b/tasmota/tasmota_support/support_tasmota.ino index 4daeb4571a0d..feb98c8a052c 100644 --- a/tasmota/tasmota_support/support_tasmota.ino +++ b/tasmota/tasmota_support/support_tasmota.ino @@ -1921,6 +1921,8 @@ void TasConsoleInput(void) { // // This patched version of pinMode forces a full GPIO reset before setting new mode // +#include "driver/gpio.h" + extern "C" void ARDUINO_ISR_ATTR __pinMode(uint8_t pin, uint8_t mode); extern "C" void ARDUINO_ISR_ATTR pinMode(uint8_t pin, uint8_t mode) { diff --git a/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino b/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino index 0b6db6671c5d..54c477c7bdfc 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino @@ -30,6 +30,8 @@ // Enable below demo feature only if defines USE_UNISHOX_COMPRESSION and USE_SCRIPT_WEB_DISPLAY are disabled //#define USE_WEB_SSE +#define USE_CONSOLE_CSS_FLEX + #ifndef WIFI_SOFT_AP_CHANNEL #define WIFI_SOFT_AP_CHANNEL 1 // Soft Access Point Channel number between 1 and 11 as used by WifiManager web GUI #endif @@ -371,12 +373,29 @@ const char HTTP_FORM_RST_UPG_FCT[] PROGMEM = "" ""; +#ifdef USE_CONSOLE_CSS_FLEX +const char HTTP_CMND_STYLE[] PROGMEM = // Overrule CSS for flex console + "html,body{height:99%%;}" + "body{display:flex;flex-flow:column;}" + "textarea{resize:none;flex:auto;min-height:99px}"; + +const char HTTP_FORM_CMND[] PROGMEM = + "" // Close HTTP_HEAD_STYLE3
+ "" + "
" + "
" //
here fixes Firefox layout + "" + // "
" + "
" + "
"; // Add dummy
replacing HTTP_HEAD_STYLE3 closed
+#else const char HTTP_FORM_CMND[] PROGMEM = "


" "
" "
" // "
" "
"; +#endif // USE_CONSOLE_CSS_FLEX const char HTTP_TABLE100[] PROGMEM = ""; @@ -3117,7 +3136,11 @@ void HandleConsole(void) WSContentStart_P(PSTR(D_CONSOLE)); WSContentSend_P(HTTP_SCRIPT_CONSOL, Settings->web_refresh); +#ifdef USE_CONSOLE_CSS_FLEX + WSContentSendStyle_P(HTTP_CMND_STYLE); +#else WSContentSendStyle(); +#endif // USE_CONSOLE_CSS_FLEX WSContentSend_P(HTTP_FORM_CMND); WSContentSpaceButton((WebUseManagementSubmenu()) ? BUTTON_MANAGEMENT : BUTTON_MAIN); WSContentStop(); diff --git a/tasmota/tasmota_xdrv_driver/xdrv_04_light.ino b/tasmota/tasmota_xdrv_driver/xdrv_04_light.ino index f4b27dd101c3..6599fde21d2e 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_04_light.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_04_light.ino @@ -2080,7 +2080,7 @@ bool LightApplyFade(void) { // did the value chanegd and needs to be applied Light.fade_duration = LightGetSpeedSetting() * 500; Light.speed_once_enabled = false; // The once off speed value has been read, reset it if (!Settings->flag5.fade_fixed_duration) { - Light.fade_duration = (distance * Light.fade_duration) / 1023; // time is proportional to distance, except with SO117 + Light.fade_duration = (distance * Light.fade_duration) / 1023 + 1 /* make sure value is not zero */; // time is proportional to distance, except with SO117 } if (Settings->save_data) { // Also postpone the save_data for the duration of the Fade (in seconds) diff --git a/tasmota/tasmota_xdrv_driver/xdrv_10_scripter.ino b/tasmota/tasmota_xdrv_driver/xdrv_10_scripter.ino index 54922adf9695..a91c48b0fa46 100755 --- a/tasmota/tasmota_xdrv_driver/xdrv_10_scripter.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_10_scripter.ino @@ -5379,10 +5379,10 @@ extern char *SML_GetSVal(uint32_t index); glob_script_mem.spi.settings = SPISettings(fvar, MSBFIRST, SPI_MODE0); if (TasmotaGlobal.spi_enabled) { -#ifdef EPS8266 +#ifdef ESP8266 SPI.begin(); glob_script_mem.spi.spip = &SPI; -#endif // EPS8266 +#endif // ESP8266 #ifdef ESP32 if (glob_script_mem.spi.sclk == -1) { diff --git a/tasmota/tasmota_xdrv_driver/xdrv_23_zigbee_5_2_converters.ino b/tasmota/tasmota_xdrv_driver/xdrv_23_zigbee_5_2_converters.ino index 6c682450c1e4..67929f7582e9 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_23_zigbee_5_2_converters.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_23_zigbee_5_2_converters.ino @@ -1214,6 +1214,8 @@ void ZCLFrame::syntheticAqaraSensor(Z_attribute_list &attr_list, class Z_attribu attr_list.addAttribute(0x0001, 0x0020).setFloat(batteryvoltage); uint8_t batterypercentage = toPercentageCR2032(uval32); attr_list.addAttribute(0x0001, 0x0021).setUInt(batterypercentage * 2); + } else if (0x03 == attrid) { + attr_list.addAttributePMEM("AqaraTemperature").copyVal(attr); // Temperature } else if ((nullptr != modelId) && ((0 == getManufCode()) || (0x115F == getManufCode()))) { translated = true; if (modelId.startsWith(F("lumi.sensor_magnet"))) { // door / window sensor diff --git a/tasmota/tasmota_xdrv_driver/xdrv_27_esp32_shutter.ino b/tasmota/tasmota_xdrv_driver/xdrv_27_esp32_shutter.ino index f09370ed69cf..538e11fe492f 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_27_esp32_shutter.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_27_esp32_shutter.ino @@ -460,8 +460,6 @@ void ShutterRtc50mS(void) int32_t ShutterPercentToRealPosition(int16_t percent, uint32_t index) { - // if inverted recalculate the percentposition - percent = (ShutterSettings.shutter_options[index] & 1) ? 100 - percent : percent; if (ShutterSettings.shutter_set50percent[index] != 50) { return (percent <= 5) ? ShutterSettings.shuttercoeff[2][index] * percent*10 : (ShutterSettings.shuttercoeff[1][index] * percent + (ShutterSettings.shuttercoeff[0][index]*10))*10; } else { @@ -523,9 +521,8 @@ uint8_t ShutterRealToPercentPosition(int32_t realpos, uint32_t index) } } } - realpercent = realpercent < 0 ? 0 : realpercent; - // if inverted recalculate the percentposition - return (ShutterSettings.shutter_options[index] & 1) ? 100 - realpercent : realpercent; + realpercent = realpercent < 0 ? 0 : realpercent; + return realpercent; } void ShutterInit(void) @@ -1268,7 +1265,8 @@ bool ShutterButtonHandler(void) // handle on button release: start shutter on shortpress and stop running shutter after longpress. if (NOT_PRESSED == button && Shutter[shutter_index].direction != 0 // only act on shutters activly moving - && Button.hold_timer[button_index] > 0) // kick in on first release of botton. do not check for multipress + && Button.hold_timer[button_index] > 0 // kick in on first release of botton. do not check for multipress + && !ShutterSettings.shutter_button[button_index].position[3].mqtt_broadcast ) // do not stop on hold release if broadcast { XdrvMailbox.index = shutter_index +1; XdrvMailbox.payload = -99; // reset any payload to invalid @@ -1321,7 +1319,7 @@ void ShutterToggle(bool dir) void ShutterShow(){ for (uint32_t i = 0; i < TasmotaGlobal.shutters_present; i++) { - WSContentSend_P(HTTP_MSG_SLIDER_SHUTTER, (ShutterSettings.shutter_options[i] & 1) ? D_OPEN : D_CLOSE,(ShutterSettings.shutter_options[i] & 1) ? D_CLOSE : D_OPEN, ShutterRealToPercentPosition(-9999, i), i+1); + WSContentSend_P(HTTP_MSG_SLIDER_SHUTTER, (Settings->shutter_options[i] & 1) ? D_OPEN : D_CLOSE,(Settings->shutter_options[i] & 1) ? D_CLOSE : D_OPEN, (Settings->shutter_options[i] & 1) ? (100 - ShutterRealToPercentPosition(-9999, i)) : ShutterRealToPercentPosition(-9999, i), i+1); } } /*********************************************************************************************\ @@ -1516,8 +1514,11 @@ void CmndShutterPosition(void) } int8_t target_pos_percent = (XdrvMailbox.payload < 0) ? (XdrvMailbox.payload == -99 ? ShutterRealToPercentPosition(Shutter[index].real_position, index) : 0) : ((XdrvMailbox.payload > 100) ? 100 : XdrvMailbox.payload); - // webgui still send also on inverted shutter the native position. - target_pos_percent = ((ShutterSettings.shutter_options[index] & 1) && (SRC_WEBGUI == TasmotaGlobal.last_source)) ? 100 - target_pos_percent : target_pos_percent; + target_pos_percent = ((Settings->shutter_options[index] & 1) && ((SRC_MQTT != TasmotaGlobal.last_source) + || (SRC_SERIAL != TasmotaGlobal.last_source) + || (SRC_WEBCOMMAND != TasmotaGlobal.last_source) + )) ? 100 - target_pos_percent : target_pos_percent; + if (XdrvMailbox.payload != -99) { Shutter[index].target_position = ShutterPercentToRealPosition(target_pos_percent, index); //Shutter[i].accelerator[index] = ShutterGlobal.open_velocity_max / ((Shutter[i].motordelay[index] > 0) ? Shutter[i].motordelay[index] : 1); diff --git a/tasmota/tasmota_xdrv_driver/xdrv_27_shutter.ino b/tasmota/tasmota_xdrv_driver/xdrv_27_shutter.ino index f6fe28a40807..c5255c5637fd 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_27_shutter.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_27_shutter.ino @@ -252,8 +252,6 @@ void ShutterRtc50mS(void) int32_t ShutterPercentToRealPosition(int16_t percent, uint32_t index) { - // if inverted recalculate the percentposition - percent = (Settings->shutter_options[index] & 1) ? 100 - percent : percent; if (Settings->shutter_set50percent[index] != 50) { return (percent <= 5) ? Settings->shuttercoeff[2][index] * percent*10 : (Settings->shuttercoeff[1][index] * percent + (Settings->shuttercoeff[0][index]*10))*10; } else { @@ -315,9 +313,8 @@ uint8_t ShutterRealToPercentPosition(int32_t realpos, uint32_t index) } } } - realpercent = realpercent < 0 ? 0 : realpercent; - // if inverted recalculate the percentposition - return (Settings->shutter_options[index] & 1) ? 100 - realpercent : realpercent; + realpercent = realpercent < 0 ? 0 : realpercent; + return realpercent; } void ShutterInit(void) @@ -950,7 +947,11 @@ bool ShutterButtonHandler(void) if (NOT_PRESSED == button) { //AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("SHT: Shtr%d, Button %d, hold %d, dir %d, index %d, payload %d"), shutter_index+1, button_index+1, Button.hold_timer[button_index],Shutter[shutter_index].direction,XdrvMailbox.index,XdrvMailbox.payload); - if (Shutter[shutter_index].direction && (Button.hold_timer[button_index] > 0 && (!Settings->flag.button_single || Button.hold_timer[button_index] > 20))) { + if (Shutter[shutter_index].direction + && (Button.hold_timer[button_index] > 0 + && (!Settings->flag.button_single + || Button.hold_timer[button_index] > 20)) + && !(Settings->shutter_button[button_index] & (0x01<<29))) { XdrvMailbox.index = shutter_index +1; XdrvMailbox.payload = XdrvMailbox.index; //AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("SHT: Shtr%d, Button %d, hold %d, dir %d, index %d, payload %d"), shutter_index+1, button_index+1, Button.hold_timer[button_index],Shutter[shutter_index].direction,XdrvMailbox.index,XdrvMailbox.payload); @@ -1144,7 +1145,7 @@ void ShutterToggle(bool dir) void ShutterShow(){ for (uint32_t i = 0; i < TasmotaGlobal.shutters_present; i++) { - WSContentSend_P(HTTP_MSG_SLIDER_SHUTTER, (Settings->shutter_options[i] & 1) ? D_OPEN : D_CLOSE,(Settings->shutter_options[i] & 1) ? D_CLOSE : D_OPEN, ShutterRealToPercentPosition(-9999, i), i+1); + WSContentSend_P(HTTP_MSG_SLIDER_SHUTTER, (Settings->shutter_options[i] & 1) ? D_OPEN : D_CLOSE,(Settings->shutter_options[i] & 1) ? D_CLOSE : D_OPEN, (Settings->shutter_options[i] & 1) ? (100 - ShutterRealToPercentPosition(-9999, i)) : ShutterRealToPercentPosition(-9999, i), i+1); } } @@ -1338,8 +1339,10 @@ void CmndShutterPosition(void) } int8_t target_pos_percent = (XdrvMailbox.payload < 0) ? (XdrvMailbox.payload == -99 ? ShutterRealToPercentPosition(Shutter[index].real_position, index) : 0) : ((XdrvMailbox.payload > 100) ? 100 : XdrvMailbox.payload); - // webgui still send also on inverted shutter the native position. - target_pos_percent = ((Settings->shutter_options[index] & 1) && (SRC_WEBGUI != TasmotaGlobal.last_source)) ? 100 - target_pos_percent : target_pos_percent; + target_pos_percent = ((Settings->shutter_options[index] & 1) && ((SRC_MQTT != TasmotaGlobal.last_source) + || (SRC_SERIAL != TasmotaGlobal.last_source) + || (SRC_WEBCOMMAND != TasmotaGlobal.last_source) + )) ? 100 - target_pos_percent : target_pos_percent; if (XdrvMailbox.payload != -99) { //target_pos_percent = (Settings->shutter_options[index] & 1) ? 100 - target_pos_percent : target_pos_percent; Shutter[index].target_position = ShutterPercentToRealPosition(target_pos_percent, index); diff --git a/tasmota/tasmota_xdrv_driver/xdrv_50_filesystem.ino b/tasmota/tasmota_xdrv_driver/xdrv_50_filesystem.ino index ee99a4f801ff..dfc54172e0de 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_50_filesystem.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_50_filesystem.ino @@ -183,9 +183,9 @@ void UfsCheckSDCardInit(void) { if (TasmotaGlobal.spi_enabled && PinUsed(GPIO_SDCARD_CS)) { int8_t cs = Pin(GPIO_SDCARD_CS); -#ifdef EPS8266 +#ifdef ESP8266 SPI.begin(); -#endif // EPS8266 +#endif // ESP8266 #ifdef ESP32 SPI.begin(Pin(GPIO_SPI_CLK), Pin(GPIO_SPI_MISO), Pin(GPIO_SPI_MOSI), -1); #endif // ESP32 diff --git a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_flash.ino b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_flash.ino index ca0af5319606..6609ca082966 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_flash.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_flash.ino @@ -21,9 +21,17 @@ #ifdef USE_BERRY #include -#include "esp_spi_flash.h" + +#include "esp_idf_version.h" +#if ESP_IDF_VERSION_MAJOR >= 5 + // esp_spi_flash.h is deprecated, please use spi_flash_mmap.h instead + #include "spi_flash_mmap.h" +#else + #include "esp_spi_flash.h" +#endif size_t FlashWriteSubSector(uint32_t address_start, const uint8_t *data, size_t size) { +#if ESP_IDF_VERSION_MAJOR < 5 uint32_t addr = address_start; size_t size_left = size; size_t current_offset = 0; @@ -59,6 +67,9 @@ size_t FlashWriteSubSector(uint32_t address_start, const uint8_t *data, size_t s } return current_offset; +#else + // TODO ESPIDF 5 +#endif } /*********************************************************************************************\ @@ -73,6 +84,7 @@ extern "C" { // If length is not specified, it is full block 4KB int32_t p_flash_read(struct bvm *vm); int32_t p_flash_read(struct bvm *vm) { +#if ESP_IDF_VERSION_MAJOR < 5 int32_t argc = be_top(vm); // Get the number of arguments if (argc >= 1 && be_isint(vm, 1) && (argc < 2 || be_isint(vm, 2)) ) { // optional second argument must be int @@ -91,6 +103,7 @@ extern "C" { be_pushbytes(vm, buf.get(), length); be_return(vm); } +#endif be_raise(vm, kTypeError, nullptr); } @@ -98,6 +111,7 @@ extern "C" { // if `no_erase` is true, just call spi_flash_write int32_t p_flash_write(struct bvm *vm); int32_t p_flash_write(struct bvm *vm) { +#if ESP_IDF_VERSION_MAJOR < 5 int32_t argc = be_top(vm); // Get the number of arguments if (argc >= 2 && be_isint(vm, 1) && be_isinstance(vm, 2)) { be_getglobal(vm, "bytes"); /* get the bytes class */ /* TODO eventually replace with be_getbuiltin */ @@ -126,6 +140,7 @@ extern "C" { } } } +#endif be_raise(vm, kTypeError, nullptr); } @@ -134,6 +149,7 @@ extern "C" { // Address and length must be 4KB aligned int32_t p_flash_erase(struct bvm *vm); int32_t p_flash_erase(struct bvm *vm) { +#if ESP_IDF_VERSION_MAJOR < 5 int32_t argc = be_top(vm); // Get the number of arguments if (argc >= 2 && be_isint(vm, 1) && be_isint(vm, 2)) { int32_t address = be_toint(vm, 1); @@ -147,6 +163,7 @@ extern "C" { esp_err_t ret = spi_flash_erase_range(address, length); be_return_nil(vm); } +#endif be_raise(vm, kTypeError, nullptr); } diff --git a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_tcpclientasync.ino b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_tcpclientasync.ino index 8c6fa9841c69..ba574920b240 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_tcpclientasync.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_tcpclientasync.ino @@ -68,6 +68,7 @@ public: state = AsyncTCPState::INPROGRESS; // reset state } +#ifdef USE_IPV6 if (ip.type() == IPv6) { struct sockaddr_in6 *tmpaddr = (struct sockaddr_in6 *)&serveraddr; sockfd = socket(AF_INET6, SOCK_STREAM, 0); @@ -75,12 +76,15 @@ public: memcpy(tmpaddr->sin6_addr.un.u8_addr, &ip[0], 16); tmpaddr->sin6_port = htons(port); } else { +#endif struct sockaddr_in *tmpaddr = (struct sockaddr_in *)&serveraddr; sockfd = socket(AF_INET, SOCK_STREAM, 0); tmpaddr->sin_family = AF_INET; tmpaddr->sin_addr.s_addr = ip; tmpaddr->sin_port = htons(port); +#ifdef USE_IPV6 } +#endif if (sockfd < 0) { AddLog(LOG_LEVEL_DEBUG, "BRY: Error: socket: %d", errno); return 0; @@ -312,7 +316,7 @@ public: local_addr = IPAddress((uint32_t)(s->sin_addr.s_addr)); // return IPAddress((uint32_t)(s->sin_addr.s_addr)); } - +#ifdef USE_IPV6 // IPv6, but it might be IPv4 mapped address if (((struct sockaddr*)&local_address)->sa_family == AF_INET6) { struct sockaddr_in6 *saddr6 = (struct sockaddr_in6 *)&local_address; @@ -325,6 +329,7 @@ public: // return IPAddress(IPv6, (uint8_t*)(saddr6->sin6_addr.s6_addr)); } } +#endif // USE_IPV6 } } diff --git a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_webclient.ino b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_webclient.ino index 9dcf44ccbf3c..eb5b7feb4284 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_webclient.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_webclient.ino @@ -582,6 +582,7 @@ public: size_t write(const uint8_t *buffer, size_t size) override { // AddLog(LOG_LEVEL_INFO, "FLASH: addr=%p hex=%*_H size=%i", addr_start + offset, 32, buffer, size); if (size > 0) { +#if ESP_IDF_VERSION_MAJOR < 5 // TODO later esp_err_t ret = spi_flash_write(addr_start + offset, buffer, size); if (ret != ESP_OK) { return 0; } // error offset += size; @@ -590,6 +591,7 @@ public: if (((offset - size) / STREAM_FLASH_PROGRESS_THRESHOLD) != (offset / STREAM_FLASH_PROGRESS_THRESHOLD)) { AddLog(LOG_LEVEL_DEBUG, D_LOG_UPLOAD "Progress %d kB", offset / 1024); } +#endif } return size; } @@ -611,6 +613,7 @@ protected: extern "C" { int32_t wc_writeflash(struct bvm *vm); int32_t wc_writeflash(struct bvm *vm) { +#if ESP_IDF_VERSION_MAJOR < 5 int32_t argc = be_top(vm); if (argc >= 2 && be_isint(vm, 2)) { HTTPClientLight * cl = wc_getclient(vm); @@ -650,6 +653,7 @@ extern "C" { be_pushint(vm, written); be_return(vm); /* return code */ } +#endif be_raise(vm, kTypeError, nullptr); } } diff --git a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino index 1fca11afe67f..fee50f5f71a6 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_52_3_berry_zigbee.ino @@ -257,16 +257,17 @@ extern "C" { sizeof(Z_attribute), /* size in bytes */ 11, /* number of elements */ nullptr, - (const be_ctypes_structure_item_t[11]) { + (const be_ctypes_structure_item_t[12]) { { "_attr_id", offsetof(Z_attribute, attr_id), 0, 0, ctypes_u16, 0 }, { "_cluster", offsetof(Z_attribute, cluster), 0, 0, ctypes_u16, 0 }, { "_cmd", offsetof(Z_attribute, attr_id), 0, 0, ctypes_u8, 0 }, // low 8 bits of attr_id { "_cmd_general", offsetof(Z_attribute, attr_id) + 1, 1, 1, ctypes_u8, 0 }, // bit #1 of byte+1 { "_direction", offsetof(Z_attribute, attr_id) + 1, 0, 1, ctypes_u8, 0 }, // bit #0 of byte+1 { "_iscmd", offsetof(Z_attribute, key_is_cmd), 0, 0, ctypes_u8, 0 }, - { "attr_multiplier", offsetof(Z_attribute, attr_multiplier), 0, 0, ctypes_u32, 0 }, + { "attr_base", offsetof(Z_attribute, attr_base), 0, 0, ctypes_u32, 0 }, { "attr_divider", offsetof(Z_attribute, attr_divider), 0, 0, ctypes_u32, 0 }, - { "attr_type", offsetof(Z_attribute, attr_type), 0, 0, ctypes_i32, 0 }, + { "attr_multiplier", offsetof(Z_attribute, attr_multiplier), 0, 0, ctypes_u32, 0 }, + { "attr_type", offsetof(Z_attribute, attr_type), 0, 0, ctypes_u8, 0 }, // { "key", offsetof(Z_attribute, key), 0, 0, ctypes_ptr32, 0 }, // { "key_is_pmem", offsetof(Z_attribute, key_is_pmem), 0, 0, ctypes_u8, 0 }, // { "key_is_str", offsetof(Z_attribute, key_is_str), 0, 0, ctypes_u8, 0 }, diff --git a/tasmota/tasmota_xdrv_driver/xdrv_52_9_berry.ino b/tasmota/tasmota_xdrv_driver/xdrv_52_9_berry.ino index 49255b436619..d63e8728c042 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_52_9_berry.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_52_9_berry.ino @@ -64,10 +64,10 @@ void checkBeTop(void) { * Use PSRAM if available \*********************************************************************************************/ extern "C" { - void *berry_malloc(uint32_t size); + void *berry_malloc(size_t size); void *berry_realloc(void *ptr, size_t size); #ifdef USE_BERRY_PSRAM - void *berry_malloc(uint32_t size) { + void *berry_malloc(size_t size) { return special_malloc(size); } void *berry_realloc(void *ptr, size_t size) { @@ -77,7 +77,7 @@ extern "C" { return special_calloc(num, size); } #else - void *berry_malloc(uint32_t size) { + void *berry_malloc(size_t size) { return malloc(size); } void *berry_realloc(void *ptr, size_t size) { @@ -89,7 +89,7 @@ extern "C" { #endif // USE_BERRY_PSRAM - void *berry_malloc32(uint32_t size) { + void *berry_malloc32(size_t size) { #ifdef USE_BERRY_IRAM return special_malloc32(size); #else diff --git a/tasmota/tasmota_xdrv_driver/xdrv_68_zerocrossDimmer.ino b/tasmota/tasmota_xdrv_driver/xdrv_68_zerocrossDimmer.ino index f0199b78360e..e1856b5e3b4c 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_68_zerocrossDimmer.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_68_zerocrossDimmer.ino @@ -24,6 +24,9 @@ #define XDRV_68 68 + +#if !defined(ESP32) || (ESP_IDF_VERSION_MAJOR < 5) // temporarily disable for IDF 5.0 + static const uint8_t TRIGGER_PERIOD = 75; #define ZCDIMMERSET_SHOW 1 @@ -139,21 +142,21 @@ void IRAM_ATTR ACDimmerTimer_intr() { for (uint8_t i = 0 ; i < MAX_PWMS; i++ ) { if (Pin(GPIO_PWM1, i) == -1) continue; - if (time_since_zc + TRIGGER_PERIOD >= ac_zero_cross_dimmer.enable_time_us[i]){ + if (time_since_zc + TRIGGER_PERIOD + 30 >= ac_zero_cross_dimmer.enable_time_us[i]){ // Very close to the fire event. Loop the last µseconds to wait. #ifdef ESP8266 - // on ESP8266 we can change dynamically the trigger interval - ac_zero_cross_dimmer.actual_tigger_Period = tmin(ac_zero_cross_dimmer.actual_tigger_Period,tmax(5,ac_zero_cross_dimmer.enable_time_us[i] - time_since_zc)); + // on ESP8266 we can change dynamically the trigger interval. + ac_zero_cross_dimmer.actual_tigger_Period = tmin(ac_zero_cross_dimmer.actual_tigger_Period*2,ac_zero_cross_dimmer.enable_time_us[i] - time_since_zc); #endif #ifdef ESP32 while (time_since_zc < ac_zero_cross_dimmer.enable_time_us[i]) { time_since_zc = micros() - ac_zero_cross_dimmer.crossed_zero_at; } #endif - if (time_since_zc >= ac_zero_cross_dimmer.enable_time_us[i] && !ac_zero_cross_dimmer.triggered[i] ) { + if (time_since_zc+5 >= ac_zero_cross_dimmer.enable_time_us[i] && !ac_zero_cross_dimmer.triggered[i] ) { digitalWrite(Pin(GPIO_PWM1, i), HIGH ^ ac_zero_cross_dimmer.fallingEdgeDimmer ); ac_zero_cross_dimmer.triggered[i] = true; - ac_zero_cross_dimmer.accurracy[i] = tmax(ac_zero_cross_dimmer.accurracy[i],time_since_zc-ac_zero_cross_dimmer.enable_time_us[i]); + ac_zero_cross_dimmer.accurracy[i] = time_since_zc-ac_zero_cross_dimmer.enable_time_us[i]; } if (time_since_zc >= ac_zero_cross_dimmer.disable_time_us[i]) { digitalWrite(Pin(GPIO_PWM1, i), LOW ^ ac_zero_cross_dimmer.fallingEdgeDimmer ); @@ -214,12 +217,13 @@ void ACDimmerLogging(void) ); for (uint8_t i = 0; i < MAX_PWMS; i++){ if (Pin(GPIO_PWM1, i) == -1) continue; - if (ac_zero_cross_dimmer.accurracy[i]) ac_zero_cross_dimmer.accurracy[i]--; + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("ZCD: PWM[%d] en: %ld µs, dis: %ld µs, fade: %d, cur: %d, end: %d, lastlight: %d, acc: %ld"), i+1, ac_zero_cross_dimmer.enable_time_us[i], ac_zero_cross_dimmer.disable_time_us[i], Light.fade_cur_10[i], Light.fade_start_10[i], Light.fade_end_10[i], ac_zero_cross_dimmer.lastlight[i], ac_zero_cross_dimmer.accurracy[i] ); + if (ac_zero_cross_dimmer.accurracy[i]) ac_zero_cross_dimmer.accurracy[i]=0; } } @@ -297,4 +301,7 @@ bool Xdrv68(uint32_t function) } return result; } + +#endif // !enabled(ESP32) || (ESP_IDF_VERSION_MAJOR < 5) + #endif // USE_AC_ZERO_CROSS_DIMMER diff --git a/tasmota/tasmota_xnrg_energy/xnrg_15_teleinfo.ino b/tasmota/tasmota_xnrg_energy/xnrg_15_teleinfo.ino index bc40715b4fac..34c3993bd9c2 100644 --- a/tasmota/tasmota_xnrg_energy/xnrg_15_teleinfo.ino +++ b/tasmota/tasmota_xnrg_energy/xnrg_15_teleinfo.ino @@ -406,7 +406,7 @@ void DataCallback(struct _ValueList * me, uint8_t flags) AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: HC:%ld HP:%ld Total:%ld"), hc, hp, total_wh); } - AddLog (LOG_LEVEL_INFO, PSTR ("TIC: Total counter updated to %ld Wh"), total_wh); + AddLog (LOG_LEVEL_DEBUG_MORE, PSTR ("TIC: Total counter updated to %ld Wh"), total_wh); if (total_wh>0) { Energy->total[0] = (float) total_wh / 1000.0f; Energy->import_active[0] = Energy->total[0]; @@ -422,17 +422,17 @@ void DataCallback(struct _ValueList * me, uint8_t flags) total_wh = atol(me->value); Energy->total[0] = (float) total_wh / 1000.0f; Energy->import_active[0] = Energy->total[0]; - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: Total:%ldWh"), total_wh); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: Total:%ldWh"), total_wh); } // Wh indexes (standard) else if ( ilabel == LABEL_EASF01) { - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: HC:%ld"), atol(me->value)); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: HC:%ld"), atol(me->value)); } else if ( ilabel == LABEL_EASF02) { - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: HP:%ld"), atol(me->value)); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: HP:%ld"), atol(me->value)); } // Contract subscribed (legacy) @@ -468,7 +468,7 @@ void DataCallback(struct _ValueList * me, uint8_t flags) else if (ilabel == LABEL_ISOUSC) { isousc = atoi( me->value); - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: ISousc set to %d"), isousc); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: ISousc set to %d"), isousc); } // Contract subscribed (Power in KVA) @@ -477,20 +477,20 @@ void DataCallback(struct _ValueList * me, uint8_t flags) // Convert KVA to A isousc = atoi( me->value) * 5 ; - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: ISousc set to %d"), isousc); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: ISousc set to %d"), isousc); } // Serial Number of device else if (ilabel == LABEL_ADCO || ilabel == LABEL_ADSC) { strcpy(serialNumber, me->value); - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: %s set to %s"), me->name, serialNumber); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: %s set to %s"), me->name, serialNumber); } // Status else if (ilabel == LABEL_STGE) { status_register = strtol(me->value, nullptr, 16); - AddLog(LOG_LEVEL_DEBUG, PSTR("Status Resister : %s set to %08X"), me->name, status_register); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("Status Resister : %s set to %08X"), me->name, status_register); } } @@ -786,7 +786,7 @@ bool TInfoCmd(void) { // At least "EnergyConfig" if (CMND_ENERGYCONFIG == Energy->command_code) { - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: len %d, data '%s'"), XdrvMailbox.data_len, XdrvMailbox.data ? XdrvMailbox.data : "null" ); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: len %d, data '%s'"), XdrvMailbox.data_len, XdrvMailbox.data ? XdrvMailbox.data : "null" ); // Just "EnergyConfig" no more parameter // Show Teleinfo configuration @@ -838,7 +838,7 @@ bool TInfoCmd(void) { int command_code = GetCommandCode(command, sizeof(command), pParam, kTInfo_Commands); - AddLog(LOG_LEVEL_DEBUG, PSTR("TIC: param '%s' cmnd %d"), pParam, command_code); + AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("TIC: param '%s' cmnd %d"), pParam, command_code); switch (command_code) { case CMND_TELEINFO_STANDARD: @@ -1002,7 +1002,7 @@ void TInfoProcess(void) // if needed, update energy total every hour if (tick_update++ > 3600 * 4) { EnergyUpdateTotal(); - AddLog (LOG_LEVEL_INFO, PSTR ("TIC: Total counter updated to %lu Wh"), total_wh); + AddLog (LOG_LEVEL_DEBUG, PSTR ("TIC: Total counter updated to %lu Wh"), total_wh); tick_update = 0; } diff --git a/tasmota/tasmota_xsns_sensor/xsns_02_analog.ino b/tasmota/tasmota_xsns_sensor/xsns_02_analog.ino index 59c469d12fc0..0be99724e9bc 100644 --- a/tasmota/tasmota_xsns_sensor/xsns_02_analog.ino +++ b/tasmota/tasmota_xsns_sensor/xsns_02_analog.ino @@ -24,6 +24,12 @@ #define XSNS_02 2 +#ifdef ESP32 + #if ESP_IDF_VERSION_MAJOR >= 5 + #include "esp32-hal-adc.h" + #endif +#endif + #ifdef ESP8266 #define ANALOG_RESOLUTION 10 // 12 = 4095, 11 = 2047, 10 = 1023 #define ANALOG_RANGE 1023 // 4095 = 12, 2047 = 11, 1023 = 10 @@ -176,6 +182,11 @@ bool adcAttachPin(uint8_t pin) { return (ADC0_PIN == pin); } #endif +#if defined(ESP32) && (ESP_IDF_VERSION_MAJOR >= 5) + bool adcAttachPin(uint8_t pin) { + return true; // TODO - no more needed? + } +#endif void AdcSaveSettings(uint32_t idx) { char parameters[32]; @@ -297,7 +308,9 @@ void AdcInit(void) { if (Adcs.present) { #ifdef ESP32 +#if ESP_IDF_VERSION_MAJOR < 5 analogSetClockDiv(1); // Default 1 +#endif #if CONFIG_IDF_TARGET_ESP32 analogSetWidth(ANALOG_RESOLUTION); // Default 12 bits (0 - 4095) #endif // CONFIG_IDF_TARGET_ESP32 diff --git a/tasmota/tasmota_xsns_sensor/xsns_110_max17043.ino b/tasmota/tasmota_xsns_sensor/xsns_110_max17043.ino index 4a90f0b13fc6..7c97be17e0e3 100644 --- a/tasmota/tasmota_xsns_sensor/xsns_110_max17043.ino +++ b/tasmota/tasmota_xsns_sensor/xsns_110_max17043.ino @@ -27,10 +27,6 @@ * The alert flag and alert threshold are not required for MQTT, the alert pin is not used * by this sensor driver. * - * Wiring and other information: - * - * \lib\lib_i2c\DFRobot_MAX17043\resources - * * Tested module(s): * * https://www.dfrobot.com/product-1734.html @@ -45,16 +41,6 @@ #define XI2C_83 83 // See I2CDEVICES.md #define MAX17043_ADDRESS 0x36 - -//#define MAX17043_USE_LIB - -#ifdef MAX17043_USE_LIB - -#include "DFRobot_MAX17043.h" -DFRobot_MAX17043 max17043_gauge; // Class to read from MAX17043 - -#else - #define MAX17043_VCELL 0x02 #define MAX17043_SOC 0x04 #define MAX17043_MODE 0x06 @@ -62,30 +48,18 @@ DFRobot_MAX17043 max17043_gauge; // Class to read from MAX17043 #define MAX17043_CONFIG 0x0c #define MAX17043_COMMAND 0xfe -#endif // MAX17043_USE_LIB - bool max17043 = false; /*********************************************************************************************/ void Max17043Init(void) { if (I2cSetDevice(MAX17043_ADDRESS)) { - -#ifdef MAX17043_USE_LIB - - if (max17043_gauge.begin() == 0) { - -#else - I2cWrite16(MAX17043_ADDRESS, MAX17043_COMMAND, 0x5400); // Power on reset delay(10); if (I2cRead16(MAX17043_ADDRESS, MAX17043_CONFIG) == 0x971c) { // Default 0x971c I2cWrite16(MAX17043_ADDRESS, MAX17043_MODE, 0x4000); // Quick start I2cWrite16(MAX17043_ADDRESS, MAX17043_CONFIG, 0x9700); delay(10); - -#endif // MAX17043_USE_LIB - max17043 = true; I2cSetActiveFound(MAX17043_ADDRESS, "MAX17043"); } @@ -93,20 +67,10 @@ void Max17043Init(void) { } void Max17043Show(bool json) { - -#ifdef MAX17043_USE_LIB - - float voltage = max17043_gauge.readVoltage() / 1000.0; // Battery voltage in Volt - float percentage = max17043_gauge.readPercentage(); // Battery remaining charge in percent - -#else - float voltage = (1.25f * (float)(I2cRead16(MAX17043_ADDRESS, MAX17043_VCELL) >> 4)) / 1000.0; // Battery voltage in Volt uint16_t per = I2cRead16(MAX17043_ADDRESS, MAX17043_SOC); float percentage = (float)((per >> 8) + 0.003906f * (per & 0x00ff)); // Battery remaining charge in percent -#endif // MAX17043_USE_LIB - // During charging the percentage might be (slightly) above 100%. To avoid strange numbers // in the statistics the percentage provided by this driver will not go above 100% if (percentage > 100.0) { percentage = 100.0; } diff --git a/tasmota/tasmota_xsns_sensor/xsns_127_esp32_sensors.ino b/tasmota/tasmota_xsns_sensor/xsns_127_esp32_sensors.ino index c50d9a82d24b..53b643557425 100644 --- a/tasmota/tasmota_xsns_sensor/xsns_127_esp32_sensors.ino +++ b/tasmota/tasmota_xsns_sensor/xsns_127_esp32_sensors.ino @@ -33,7 +33,7 @@ #define XSNS_127 127 -#if CONFIG_IDF_TARGET_ESP32 +#if CONFIG_IDF_TARGET_ESP32 && (ESP_IDF_VERSION_MAJOR < 5) // Hall sensor is no more supported in esp-idf 5 #define HALLEFFECT_SAMPLE_COUNT 32 // 32 takes about 12 mS at 80MHz CPU frequency @@ -51,7 +51,7 @@ void Esp32SensorInit(void) { } } -#endif // CONFIG_IDF_TARGET_ESP32 +#endif // CONFIG_IDF_TARGET_ESP32 && (ESP_IDF_VERSION_MAJOR < 5) void Esp32SensorShow(bool json) { bool json_end = false; @@ -84,7 +84,7 @@ void Esp32SensorShow(bool json) { } } -#if CONFIG_IDF_TARGET_ESP32 +#if CONFIG_IDF_TARGET_ESP32 && (ESP_IDF_VERSION_MAJOR < 5) // Hall sensor is no more supported in esp-idf 5 if (HEData.present) { int value = 0; for (uint32_t i = 0; i < HALLEFFECT_SAMPLE_COUNT; i++) { @@ -115,7 +115,7 @@ void Esp32SensorShow(bool json) { #endif // USE_WEBSERVER } } -#endif // CONFIG_IDF_TARGET_ESP32 +#endif // CONFIG_IDF_TARGET_ESP32 && (ESP_IDF_VERSION_MAJOR < 5) if (json_end) { ResponseJsonEnd(); @@ -138,11 +138,11 @@ bool Xsns127(uint32_t function) { Esp32SensorShow(0); break; #endif // USE_WEBSERVER -#if CONFIG_IDF_TARGET_ESP32 +#if CONFIG_IDF_TARGET_ESP32 && (ESP_IDF_VERSION_MAJOR < 5) // Hall sensor is no more supported in esp-idf 5 case FUNC_INIT: Esp32SensorInit(); break; -#endif // CONFIG_IDF_TARGET_ESP32 +#endif // CONFIG_IDF_TARGET_ESP32 && (ESP_IDF_VERSION_MAJOR < 5) } return result; } diff --git a/tasmota/tasmota_xsns_sensor/xsns_80_mfrc522.ino b/tasmota/tasmota_xsns_sensor/xsns_80_mfrc522.ino index 037ded6da257..7ceeed9aed4b 100644 --- a/tasmota/tasmota_xsns_sensor/xsns_80_mfrc522.ino +++ b/tasmota/tasmota_xsns_sensor/xsns_80_mfrc522.ino @@ -100,9 +100,9 @@ void RC522ScanForTag(void) { void RC522Init(void) { if (PinUsed(GPIO_RC522_CS) && PinUsed(GPIO_RC522_RST) && (SPI_MOSI_MISO == TasmotaGlobal.spi_enabled)) { Mfrc522 = new MFRC522(Pin(GPIO_RC522_CS), Pin(GPIO_RC522_RST)); -#ifdef EPS8266 +#ifdef ESP8266 SPI.begin(); -#endif // EPS8266 +#endif // ESP8266 #ifdef ESP32 SPI.begin(Pin(GPIO_SPI_CLK), Pin(GPIO_SPI_MISO), Pin(GPIO_SPI_MOSI), -1); #endif // ESP32