Closed djorr5 closed 3 months ago
@djorr5 ,
Yes, the esp_gateway_control_light_on_off()
function runs on the Rainmaker task, so it's necessary to add a lock to ensure thread safety. The Zigbee API is also not thread-safe, so if you intend to repurpose it, you'll need to add a lock for that as well.
Thanks @xieqinan just wanted to confirm. You might want to get the Rainmaker side to update the code to avoid confusion.
@djorr5,
You might want to get the Rainmaker side to update the code to avoid confusion.
No problem, I will do it later.
Question
Hi, I am just playing around with the Rainmaker Zigbee gateway example. I noticed that in the
esp_gateway_control_light_on_off
function there is noesp_zb_lock_acquire
when controlling the zigbee ED. Is this just because it has not been updated? Wondering if I need to apply this if I repurpose the gateway code in regards to Rainmaker.Additional context.
https://github.com/espressif/esp-rainmaker/blob/master/examples/zigbee_gateway/main/esp_gateway_control.c