Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Berry/Zigbee add web hook per device for customized status display #20542

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Expand Up @@ -16,6 +16,7 @@ All notable changes to this project will be documented in this file.
- Command ``TimedPower<index> <milliseconds>[,ON|OFF|TOGGLE|BLINK]`` executes ``Power<index> [ON|OFF|TOGGLE|BLINK] `` and after <millisecond> executes ``Power<index> [OFF|ON|TOGGLE|BLINK_OFF]``
- Berry solidification of strings longer than 255 bytes (#20529)
- Berry syntax coloring for Notepad++ (by FransO)
- Berry/Zigbee add web hook per device for customized status display

### Breaking Changed

Expand Down
5 changes: 5 additions & 0 deletions tasmota/tasmota_xdrv_driver/xdrv_23_zigbee_A_impl.ino
Expand Up @@ -2211,6 +2211,7 @@ void ZigbeeShow(bool json)

uint32_t now = Rtc.utc_time;

// iterate through devices by alphabetical order
for (uint32_t i = 0; i < zigbee_num; i++) {
const Z_Device &device = zigbee_devices.devicesAt(sorted_idx[i]);
uint16_t shortaddr = device.shortaddr;
Expand Down Expand Up @@ -2365,6 +2366,10 @@ void ZigbeeShow(bool json)
}
WSContentSend_P(PSTR("{e}"));
}
#ifdef USE_BERRY
// Berry hook to display additional customized information
callBerryZigbeeDispatcher("web_device_status", nullptr, nullptr, shortaddr);
#endif // USE_BERRY
}

WSContentSend_P(msg[ZB_WEB_LINE_END]); // Terminate current multi column table and open new table
Expand Down