Send three resets when connecting, not just one#689
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #689 +/- ##
=======================================
Coverage 99.51% 99.52%
=======================================
Files 58 58
Lines 3958 3960 +2
=======================================
+ Hits 3939 3941 +2
Misses 19 19 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Do we know why this is apparently specific to ZBT-2? Just the ESP32 USB/serial bridge being a bit slower upon startup? |
TheJulianJES
left a comment
There was a problem hiding this comment.
In before resetting during the start of a reset breaks some coordinators with ancient firmware versions 😄
Should be good
|
I've tested all of the adapters I have, including a few newer dual protocol sticks and the old HUSBZB-1, both with the 115200 and the 57600 firmwares. The triple reset works on every stick. Some other adapters that required two attempts with the old behavior now work on the first try so I think this is about as well-tested as I can manage 😄. |
Some devices, like the ZBT-2, send a single NAK if you connect to them immediately after the firmware starts. Sending more than one reset frame seems to flush enough buffers to "break through" and properly reset the device on the first try.