parasite85 / tuya_tygwzw1_hack

20 stars 6 forks source link

"Wired mode" - how to & how to verify it works? #5

Open kitor opened 4 months ago

kitor commented 4 months ago

I have one of those tygwzw1 that arrived kinda broken - WiFi part was working but was unable to communicate with ZigBee module. Not sure about the reason (RTL side shows constant retry with different UART speeds, on TX/RX pins it is visible it tries to communicate but with no response.

I successfully flashed ZigBee module via ST-Link v2, but I still don't see any activity on that UART (except char which RTL sends trying to communicate). I assumed 115200N1.

I noticed Tuya docs for TYZS3 says module requires flow control via RTS/CTS signals in Zigbee mode, same is written in UART-EZSP Gateway Protocol Reference. In fact I see those pins are connected to Realtek module...

Have you tested running Zigbee module standalone? Do I need to desolder or erase Realtek module not to interfere? Are flow control pins really needed? (most adapters expose only TX/RX). Is there any [printable] output I should expect on UART when module is powered ON (or there's any input I can do to get any response)?

In ideal world I'd like to repurpose just the module and put it inside my OpenWRT WiFi AP that happens to have 2nd UART port exposed... assuming module indeed works and flow control part is not needed.

codeandsolder commented 3 months ago

Default has RTS/CTS enabled, try this: https://github.com/codeandsolder/tuya_tygwzw1_hack/blob/nocts/flash_tyzs/mp-ncp-uart-hw-nocts.bin