bigbigmdm / IMSProg

IMSProg - software for CH341A-based programmers to work with I2C, SPI and MicroWire EEPROM/Flash chips
https://antenna-dvb-t2.ru/IMSProg.php
GNU General Public License v3.0
215 stars 38 forks source link

Issue with FairChild 93C56 #24

Closed Calosha closed 8 months ago

Calosha commented 8 months ago

Hi @bigbigmdm! First of all thank you for the software. I read content of 93C56 and bits are misplaced. I got: 4a31 4634 3446 5338 5958 324c 3036 3333 3135.... instead of: 314a 3446 4634 3853 5859 4c32 3630 3333 3531....

Any ideas what could cause incorrect reading?

Here is data spec for the eeprom. Image of the chip: image

Chip connection: CH341A 93C56 pin name 93C56 pin
CLK sk 2
CS cs 1
MOSI di 3
MIOS do 4
GND gnd 5
3.3V pe 6
5V pre, Vcc 7,8
Calosha commented 8 months ago

I think the issue is endianness (Little Endian/Big Endian). Is there a setting for it in the software?

bigbigmdm commented 8 months ago

There is a lot of confusion with the 93Cxx chips in some programmes. These are 16-bit chips. The high byte is read first, then the low byte. And in the 8-bit dump - vice versa. And the dump of the IMSProg programme is 8-bit. In the source code of SNANDer, which I took as a basis, there is just confusion with the byte order. I rearranged them in the correct order, just like in the EZP2019 programme. You are just showing me a 16-bit dump and in it the bytes should be rearranged compared to the 8-bit dump. The data will be written to the disc in a different order.

16 bit DUMP                       8 bit DUMP
4a31 4634 3446 5338 5958 = 31 4a 34 46 46 34 38 53 58 59

Am I making myself very unclear?

Calosha commented 8 months ago

Спасибо Михаил. Тогда можно попросить фичу что-бы editor мог переключаться с 8 на 16 и обратно?

bigbigmdm commented 8 months ago

К сожалению, быстро это не сделать, поскольку я использую для отображения дампа готовый компонент QHexEdit2, а у него нет 16-битного режима. Буду думать в этом направлении, поскольку это правильно.

bigbigmdm commented 8 months ago

Пока не реализовал, но помню о Вас.

Calosha commented 8 months ago

Спасибо! С праздниками Вас!