-
Notifications
You must be signed in to change notification settings - Fork 225
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
TY0201 (_TZ3000_bjawzodf) wrong custom firmware submitted #620
Comments
@KipK I'm sorry to bother you.. This is a sample of index.json. Is there any information to know which device and firmware can match? For example, such as the 'ModelID' attribute, it seems that there is a way that only certain device models can use this firmware. Certainly, there seems to be a procedure to parse the "fileName" attribute to find out the firmware magic code...
|
Ota updates are matched by devices using manufacturer That said, I think it's better to disable OTA for those device, than automatically push a wrong fw. , |
Thank you for your kind reply. @KipK Actually, I was just a user until I upgraded the wrong firmware today. Based on the many clues you mentioned, i read the source code and made the following guess. The A new firmware has been registered in Unfortunately, due to the incorrectly updated firmware, my
This problem occurred because the identifier of the
As you say, Tuya-based devices often have the problem of overlapping unique identifiers, as many of them are randomly made by many small and medium-sized companies. Therefore, when describing metadata in If this is correct under your review, I would like to describe additional metadata for the problem item of I think the problem can be avoided by describing I found the basis in the following source code.
|
Not your fault, Zigbee Ota has been enabled for TS0201 on latest z2m release, and so it pushed you the wrong firmware.
ManufactuerName can be the same but modelID is probably different yes. |
I removed the firmware for the time being (removing ota functionality of TS0201 requires a z2m update leading to users having bricked devices until then). @KipK could you re-submit it with the modelId included? |
@Koenkk , I'm not sure this fw should be kept. It could be a transition ota file from ofw to custom fw. ( pvvx ? ) Manufacturer field says Custom Device (DIY) Installing custom fw should only be made manually. Updating them is not a problem. @jehos, can you post the state tab content for your bricked device, I want to see the "device": {} content. |
@KipK Sorry, Actually after hanging on for over 12 hours yesterday, I deleted the bricked device registered in Z2m. Now there is no way to re-register... However, since I have screenshots and log files that I kept for my issue management, I will give you some information to refer to.
And this issues started here. Submmiter's original intention was to just update the
I was simply a user, so I never imagined that the community would run with the efforts of so many people. In particular, I would like to thank you very much as a maintainer of Z2M. (@Koenkk) And i know @KipK also active in the HA community and helping. The people who develop custom firmware are valuable to the community. As a career system engineer, I believe no one does anything wrong on purpose. (But in security, I don't trust anyone.. :-) This won't happen often, but once it happens, it has a huge impact, so I hope it will be improvement in the OTA's contribution procedure and firmware update procedure more explicit. As we all agree, people are not perfect and always make mistakes, so we can learn from mistake and improvement the system. People who participate in each stage are bound to make mistakes, so there is a need for a way to review or prevent problems that may arise at each stage. If the sieve is tighter, the system will be stable even with a lot of participation. This discussion is beyond the scope of this issue, so I would like to create an issue and discuss it separately. “Talk is cheap. Show me the code.” I appreciate your hard work |
Ok so the firmware is actually @pvvx custom fw. |
Most Tuya devices have the same IDs:
It is not worth publishing firmware with the specified identifiers, since many Tuya devices respond to them. Similarly, with the name of the model and manufacturer of Tuya devices. Several completely different Zigbee devices have already been found on sale under the Tuya brand, but with the same model name and manufacturer. Also, under the same IDs, but with different "File Version" Tuya devices have different functionality.
Currently, Tuya devices have already started using other identifiers from other brands, which makes the situation even more confusing. Favorite hobby: making fakes. |
There is a text string in the "*.zigbee" file format for OTA. It can be used to specify the device model for the user. |
ID numbers of alternative firmware.
All ZigBeeTLc:
Last year I came to an agreement with all known Russian-speaking creators of alternative firmware regarding the distribution of Zigbee OTA identifiers. Since then we have been using different "manufacturer codes". |
@lukas1760 - There are more than a dozen different Tuya devices with the name "TS0201". |
@pvvx here it is. Zigbee Model |
The names provided do not identify the model of the Tuya device. Determine the Tuya device model by the following criteria:
|
Unfortunately, I did not have such a thermometer and I do not have its original firmware to restore. |
That is sad. Is there any way/method to get the firmware from a working device to a PC? |
Yes. |
@lukas1760 |
If it can help, I've made an ota file from @pvxx previous post , with higher version than the one that was installed by mistake. Just in case z2m refuse to downgrade. After install it will use the correct version, it's just to trick ota. |
Many thanks. But i have no sucess with ota update propably because of changed device properties. I don't know how to force update. |
After searching a bit, it seems to be this firmware that has been installed , not from @pvvx It should work they have same manufacturer code and image type. Could be OTA is broken too. You can then try to flash it using links posted above: https://github.com/pvvx/TlsrComSwireWriter |
All these data are not involved in the Zigbee OTA process. They are information data for automating the creation of Zigbee OTA header in Telink applications... According to the encoding from the Telink SDK 1141-0203-10013001, they indicate:
Such IDs are installed in the Telink SDK by default (in "version_cfg.h") and the Tuya firmware writer did not change anything. Another version of the SDK from Telink contains the following imageType::
This is what all the identifiers look like in the firmware from Tuya - no one changes anything there that is written in the Telink SDK. |
Yes I had checked ota headers on booth files and manufacturer code + image type are the same. So this should work. I guess installing the wrong firmware broke OTA then. But I haven't tested myself, I don't have this device anyway. |
@KipK if you tell me what to check, I will do it. But I don't have com flasher possibility yet. |
@pvxx, reading the python script you've posted , I think I get why. OTA header has 0x1141 manufacturer code, but bin file has 0xDB15 , ( from bytes 16-17 little indian ) So it seems once the wrong firmware has been installed, it changed the manufacturer code to 0xDB15. try this one first: if it doesn't work then this one: |
@KipK many thanks for help. DB15-0203-1001FFFF-TY0201_TZ3000_bjawzodf.zigbee |
Hi! I have the same situation with my TY0201, unfortunately. I managed to get the point of getting new firmware to upload (but failed at the end), so I will keep an eye on this thread, appreciate your efforts :) |
Why don't you look at what IDs the firmware installed on the device has? These are standard Zigbee commands. Guessing the ID without having the device is stupid. Next, take any script that replaces the IDs in the OTA file header for Zigbee and set the required IDs, replacing the "File Version" number with a larger one. File from message #620 (comment) do not use! Flashing the pvvx/ZigbeeTLc#107 (comment) provided by @diggit into the ZTU module showed that the file does not work! |
Is there an alternate firmware for _TZ3000_bjawzodf that increases polling frequency and doesn't brick the device? I'm unable to see let alone pair this device with this: https://pvvx.github.io/ATC_MiThermometer/TelinkMiFlasher.html Currently working with factory firmware: |
wrong custom firmware submitted with
index.json
at a02dbd5This causes firmware update notifications on device that have the same ID, but are actually different.
SEE:
The text was updated successfully, but these errors were encountered: