Nizam Moidu 4a2ae013ed
HLW8112 Driver for energy measurments (#1810)
* initial test driver for hlw8112

Signed-off-by: Nizam <code@maxters.net>

* restrict build to BK7231N
will stub other platforms later

Signed-off-by: Nizam <code@maxters.net>

* fix newer gcc build

Signed-off-by: Nizam <code@maxters.net>

* fix channel b stat restore
after all i still doesnt get pointer arithmetic

Signed-off-by: Nizam <code@maxters.net>

* clean up flashvar bk7231 still use emetering struct to store data

Signed-off-by: Nizam <code@maxters.net>

* fix OpenBK7231N_ALT build fail

Signed-off-by: Nizam <code@maxters.net>

* disable incomplete spi device raw access commands and ui

Signed-off-by: Nizam <code@maxters.net>

* remove mqtt hack for commands. leverage existing tasmota command framework

Signed-off-by: Nizam <code@maxters.net>

* missed flashvar restore

Signed-off-by: Nizam <code@maxters.net>

* disable hlw812 driver for upstream pr

Signed-off-by: Nizam <code@maxters.net>

---------

Signed-off-by: Nizam <code@maxters.net>
2025-09-30 15:04:15 +02:00
..
2024-10-10 13:30:21 +02:00
2023-08-20 13:39:12 +02:00
2025-03-30 20:37:37 +02:00
2025-06-17 18:01:35 +02:00
2025-06-17 18:01:35 +02:00
2025-06-17 18:01:35 +02:00
2025-06-17 18:01:35 +02:00
2025-06-17 18:01:35 +02:00
2024-01-12 13:14:38 +01:00
2025-08-10 08:46:49 +02:00
2023-12-05 16:47:15 +01:00
2025-06-17 18:01:35 +02:00
2024-01-11 15:13:46 +01:00
2023-12-05 16:47:15 +01:00
2025-09-29 11:43:47 +02:00
2025-06-17 18:01:35 +02:00
2025-06-17 18:01:35 +02:00
2023-08-20 13:39:12 +02:00

Documentation

Here is the latest, up to date documentation. This file was autogenerated by running 'node scripts/getcommands.js' in the repository. The descriptions were taken from code and from the JSON files, and then converted to MarkDown. Do not add anything here, as it will overwritten with next rebuild.

Basic doc pages

Doc tables

Section Comment
IO/Pin Roles (82 total) You can set pin roles in 'Configure Module' section or use one of predefined templates in Web App. For each pin, you also set corresponding channel value. This is needed for modules with multiple relays. If you have 3 relays and 3 buttons, you need to use channel values like 1, 2, and 3. Just enter '1' in the text field, etc.
Flags (52 total) Flags are global and allows you to alter behaviour of the device.
Drivers (67 total) Drivers allows you to control certain peripherals or enable certain features that are off by default.
Script constants (42 total) Every console command that takes an integer argument supports certain constant expansion.
Channel Types (62 total) Channel types are often not required and don't have to be configured, but in some cases they are required for better device control from OpenBeken web panel. Channel types describes the kind of value stored in channel, for example, if you have a Tuya Fan Controller with 3 speeds control, you can set the channel type to LowMidHigh and it will display the correct UI radiobutton on OpenBeken panel.
Some channels have '_div10' or '_div100' suffixes. This is for TuyaMCU. This is needed because TuyaMCU sends values as integers, so it sends, for example, 215 for 21.5C temperature, and we store it internally as 215 and only convert to float for display.
FAQ (31 total) Here is a detailed list of questions you may ask. Some information from docs is repeated here.
Console/Script commands (362 total) There are multiple console commands that allow you to automate your devices. Commands can be entered manually in command line, can be send by HTTP (just like in Tasmota), can be send by MQTT and also can be scripted.
Command Examples (10 total) Here you can find some examples of console commands usage
Autoexec.bat examples (configs) (37 total) Here you can find examples of autoexec.bat configs. The autoexec.bat file can be created in Web Application, under LittleFS tab, and is run every time device reboots (unless device enters safe mode/AP mode). The autoexec.bat file allows you to create more advanced configs, setup TuyaMCU mappings, etc
MQTT Topics (25 total) MQTT topic names and content for incoming and outgoing OBK MQTT publishes
Script examples (6 total) Scripts can be put in autoexec.bat and then they will start automatically on reboot, you can also put script in other LittleFS file and use startScript [fileName] [Label] command to run them. From the firmware point of view, scripts and autoexecs are basically the same thing. There is, however, a little bit more advanced system of execution for scripts which can be written in a form of scripts threads that run over time, can have delays within then, conditional checks and jumps.
Console/Script commands [Extended Edition] (362 total) More details on commands.