Anybody here have ever used a CH341A with a MX25L6405D?
(my English is not very good, it may sound a little weird)
I'm having problems because it can't find the MX25L6405D.
I know that the programmer works, since I was able to make goods dumps of a MX25L8006 that was on a old router, but I was not able to detect a MX25L6405D that was on my Thinkpad X200 (it could not even find a chip). I know it is not a problem with the SOIC16 clip that I used since I was able to use it on a rayer_spi device.
I not really sure if this is correct but, I saw that could be a bug on the code of the program that the CH341A port was based on: https://blog.danman.eu/ch341a-usb-serial-eeprom-reader-under-linux/
I still didn't tried this version of the ch341prog because right now i don't have the time, but I will do eventually.
I used the 0.9.9 of flashrom.
Sorry if I caused any problems, Potato
Hi Potato,
On 07.06.2016 18:59, potato wrote:
I know that the programmer works, since I was able to make goods dumps of a MX25L8006 that was on a old router, but I was not able to detect a MX25L6405D that was on my Thinkpad X200 (it could not even find a chip). I know it is not a problem with the SOIC16 clip that I used since I was able to use it on a rayer_spi device.
The problem is not the flash chip itself but the circuitry surrounding it. Every device that you flash by ISP is a different story, especially when the device is not meant to be flashed by ISP. The X200 is one of those and particularly hard to flash. Presumably because of some capa- city on the CS line. So you need a programmer that can drive CS pretty strong, or work around by using a very low SPI clock or hack flashrom to assert CS earlier (that works for me using a FT2232H based program- mer). I've seen a Raspberry Pi 2 programming an X200 oob, supposedly it drives CS strong enough.
Here's a clumsy patch for flashrom that might help: http://paste.flashrom.org/view.php?id=2802 It adds dummy reads that might kind of pre-charge CS.
Urja, do you know a way to assert CS earlier on a CH341A?
Sorry if I caused any problems, Potato
No problems.
Nico
On Fri, Jun 10, 2016 at 8:57 PM, Nico Huber nico.h@gmx.de wrote:
Hi Potato,
On 07.06.2016 18:59, potato wrote:
I know that the programmer works, since I was able to make goods dumps of a MX25L8006 that was on a old router, but I was not able to detect a MX25L6405D that was on my Thinkpad X200 (it could not even find a chip). I know it is not a problem with the SOIC16 clip that I used since I was able to use it on a rayer_spi device.
The problem is not the flash chip itself but the circuitry surrounding it. Every device that you flash by ISP is a different story, especially when the device is not meant to be flashed by ISP. The X200 is one of those and particularly hard to flash. Presumably because of some capa- city on the CS line. So you need a programmer that can drive CS pretty strong, or work around by using a very low SPI clock or hack flashrom to assert CS earlier (that works for me using a FT2232H based program- mer). I've seen a Raspberry Pi 2 programming an X200 oob, supposedly it drives CS strong enough.
Here's a clumsy patch for flashrom that might help: http://paste.flashrom.org/view.php?id=2802 It adds dummy reads that might kind of pre-charge CS.
Urja, do you know a way to assert CS earlier on a CH341A?
Depends on for how long, but yes... https://github.com/flashrom/flashrom/blob/staging/ch341a_spi.c#L334 repeat that line for a delay of 750ns / line after the assertion, but reduce the limit in lines 343 and 344 for the amount usable for delay generation, since that packet is max 32 bytes (the comment there is pretty good).
For a longer delay than that about 20us, it'd need more complex mechanisms, but yeah doable.
Sorry if I caused any problems, Potato
No problems.
Nico
Thanks for the help, the patch did work (the chip was detected), unfortunately the system was not really reliable. The dumps were note matching and the chip was only detected on the first run of flashrom, after that it was needed to remove the USB device and insert-it again, otherwise the chip would not be find. Since there is no way to set the speed of the CH341A on flashrom right now, I will see if there is any way to "boost" the signal (or something like that) from the CH341A (and look on some other SPI programmers).
Potato
On 10-06-2016 14:57, Nico Huber wrote:
Hi Potato,
On 07.06.2016 18:59, potato wrote:
I know that the programmer works, since I was able to make goods dumps of a MX25L8006 that was on a old router, but I was not able to detect a MX25L6405D that was on my Thinkpad X200 (it could not even find a chip). I know it is not a problem with the SOIC16 clip that I used since I was able to use it on a rayer_spi device.
The problem is not the flash chip itself but the circuitry surrounding it. Every device that you flash by ISP is a different story, especially when the device is not meant to be flashed by ISP. The X200 is one of those and particularly hard to flash. Presumably because of some capa- city on the CS line. So you need a programmer that can drive CS pretty strong, or work around by using a very low SPI clock or hack flashrom to assert CS earlier (that works for me using a FT2232H based program- mer). I've seen a Raspberry Pi 2 programming an X200 oob, supposedly it drives CS strong enough.
Here's a clumsy patch for flashrom that might help: http://paste.flashrom.org/view.php?id=2802 It adds dummy reads that might kind of pre-charge CS.
Urja, do you know a way to assert CS earlier on a CH341A?
Sorry if I caused any problems, Potato
No problems.
Nico