Skip to content
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

TLSR8251 can't read #2

Open
bearpawmaxim opened this issue Jun 25, 2022 · 6 comments
Open

TLSR8251 can't read #2

bearpawmaxim opened this issue Jun 25, 2022 · 6 comments

Comments

@bearpawmaxim
Copy link

bearpawmaxim commented Jun 25, 2022

Hi! I'm unsuccessfully trying to dump the stock firmware from Xiaomi SJWS01LM water leak sensor that has a tslr8251 chip.
(I 'm going to write a custom firmware because I don't like how the stock one behaves)
(I'm a newbie to TSLR* chips)

Trying to dump the firmware with the USB-uart converter.
TX wire connected through 1k resistor to SWS/PA<7> (pin 4 on 24-pin package) and RX wire connected to the same SWS pin directly.
RST pin is not connected (because my uart converter doesn't have one)..

The error I'm getting is
Error[102] Read PGM Version and Config!
What am I doing wrong? Thanks for help!

@bearpawmaxim
Copy link
Author

Okay, the error means that we're receiving less bytes than expected - will check RX.

@bearpawmaxim
Copy link
Author

bearpawmaxim commented Jun 26, 2022

Added logging to command function and got

Open COM4, 230400 bit/s... ok
Read bytes count less than expected! (6 < 19) bytes: 00 00 00 00 00 24!
Error[102] Read PGM Version and Config!```

@pvvx
Copy link
Owner

pvvx commented Jun 30, 2022

Not all types of USB-UART chips work with Telink Swire emulation.
Only Chinese USB-UARTs. Not FTDI - FTDI filters invalid UART characters...
The RX input of the USB-UART adapter must not have a resistor with an LED.

@bearpawmaxim
Copy link
Author

I'm finished with using the stm32f103vet6 at the hardware side and tsltools825x at software side. But even with this sometimes I cannot connect to the MCU (because it is falling asleep?). I think I definitely need to solder the rst pin to be able to use the activation procedure...

@pvvx
Copy link
Owner

pvvx commented Jun 30, 2022

This repository is dedicated to Telink-SWire hardware programmer based on TLSR8269/825x chips... And I don't quite understand your question... Is it about a different type of programmer?

A reset or power-up signal is required to wake the chip from sleep mode.

@bearpawmaxim
Copy link
Author

bearpawmaxim commented Jul 3, 2022

Upd: connected the reset line, but even with this still getting an error Error[102] Read PGM Version and Config!

And I don't quite understand your question...

The question is whether the described in the first post wiring is correct and the reason why I'm getting an error.

P.S.: with ch340g and an stm32-based adapters the result is same - error mentioned above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants