-
Notifications
You must be signed in to change notification settings - Fork 24
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
[BK7231N][CB3S] Reading 0x00... failed with serial.BytesToRead 4056 #5
Comments
Thanks, will you be able to recheck if I give you updated flasher binary? |
Yes, i can check this. First afternoon 😉 |
The wb3s device also has a reading problem. The recording goes smoothly. Flasher mode: BK7231T |
Assembled layout on WB3S ready to help with testing |
Also having a problem flashing a WB3S Starting read backup and flash new! |
Does the problem happen only in "Backup and write" modes or in a separate modes as well? I will try to prepare a build with increased time for read operation and we will see what happens. |
In my case both during backup and write. Also the write and read test in the advanced options do not allow to communicate properly with the MCU. |
same on backup (read) only test read/write |
It works for me... I increased a delay in UART read for slower computers... |
1.0.2 doesn't give the countdown to do the reset Starting read backup and flash new! |
No @itsj4y , it's not the version thing. You won't get countdown to RESET if you do erase flash memory of BK but do not write. This is because in this case BK has no application and reboots constantly. The same will happen in bkWriter or anything, as long as you do erase without write on BK. Still... thanks for testing. I hoped that increasing the delay from 5 to 10 seconds will help, but it seems that issue is somewhere else. Flash respond command is the following: so your buffer content looks like it has a start of flash read command, but for some reasons it's cut in place? Can you try different baud rate, like 128000 and 256000 ? You can enter those numbers into the field (copy paste them, they are not on the list). Extra question: can you show a photo of your USB to uart converter and/or give me a specific model name of it? |
Ok so it worked after firmware write (no backup) |
When i do Backup:
But when flashing already without a backup, the process goes forward.
Surprisingly, there is no CRC matches error, which in HID occurred Test writing pattern:
Test read/write:
[BK7231GUIFlashTool v1.0.2](1de86ee) As I set baud to 256000 I got this result(for 128000 as above):
|
I have added a larger buffer, it was not needed for my machine, but maybe... |
This was successfully done. You made it :) baud rate 921600:
baud rate 1500000!
And test read/write as well:
Do backup and flash new:
And It has stability problems from time to time:
|
Thank you @Rafik89 for testing. It's a good news. I am still super surprised that it worked for me with 4096 buffer, it's very strange. |
I checked WB3S reading, everything works. I will try to restore the original firmware of the device. I will help you test |
Do not try to restore the original firmware without me adding an option for that first! You may break your bootloader. |
OK got it |
Hello, I have problem flashing CB2S. Getting bus success! |
@veivari which version? |
@openshwprojects 1.0.3 |
Hi @openshwprojects, Edit: |
#I also get the same problem:
I'm using this USB to UART device: Edit: But after a few seconds the reading failed. Edit 2: |
@dawosch isn't it a battery-powered device where MCU turns off the wifi module? Can you show device photo? |
@Rafik89 On the other side there is the battery mount. |
Sorry but your problem is not related to the flasher. Basically, this device has TuyaMCU and TuyaMCU might interfere with flashing. You can either cut the rx/tx tracks or desolder the MCU temporarily. |
Ok, thanks for the info. Would it be possible to increase the baud rate a little bit more to write the firmware complete? Thanks |
If you are asking in relation to TuyaMCU devices, then it's not practical. The correct approach is just to power the device correctly (avoid MCU interruption) and, if required, remove temporarily the MCU or cut traces. |
Hello, I also had this random write error. I increased the TimeOut (0.25f instead of 0.05f) at line 387 of the BK7231Flasher.cs file (from V1.06) and the write was successful. |
Hello, iam having an problem with an BK7231N on an aliexpress relay board. Firmware read was a success at first, the write is the problem (thats the reason why i dont do a backup in this try) TTL chip/board used is an cp2102*
|
Hi Dexruus, did you try to modify the timeout as I said in my previous message ? |
Hi, This is more an FYI that this is still an issue for at least some users. I'd love to see it working, since the GUI is much nicer and easier to use than the python implementation. |
I don't know what is wrong. It seems to work reliable for me. @thinksilicon how did you compile it on linux? Btw, I have a major update coming for this tool. It will be possible to extract Tuya config very easily and also it will be possible to configure OBK in place, from the flasher access. It will be released in few days. |
Hey,
|
Hey, just wanted to say that I was having a similar issue on linux but it worked fine on windows. As you said, it probably has to do with the interaction with serial ports over Mono. Hopefully they can find a fix! |
Great! Thanks for this hint! =) |
Thanks, this helped. No issues on my Windows 10 laptop. But on my Ubuntu 22.04 workstation (Ryzen 5700G) I faced the same issue. By changing two of the topmost UART timings from 1s to 5s everything started working. |
Thank you for testing. Now 5s delays in those two fields are default values. |
with a separated CB2S module, I got the sequence
on a Debian "testing" system on a Ryzen 5 4650G with version 1.1.1 (so with the two defaults of 5, I checked them). No problem on a Windows laptop with the same hardware. May be the higher timeout wasn't the reason it worked but only increased the chances. |
Might relates to #19
|
Hello,
BK7231N (CB3S) chip I can't do flasch or backup. Whichever I do.
In the HID Download itself goes without the slightest problem.
The text was updated successfully, but these errors were encountered: