I built this programmator, soldered to the appropriate pins on the
flash (you need to unsolder these pins from board for programming),
and programmed it easy.
See log:
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
------------------
F:\Temp\str8132\spipgm>SPIPGMW.EXE
SPI FlashROM Programmer 1.6 (C) 2008-2009 by Martin Rehak;
ra...@seznam.cz
Compiled by GCC 3.4.5 (mingw-vista special r3) at 22:49:21, Jan 21
2009
(Win9x/NT/2K/XP compatability)
SYNTAX: spipgm /i|r|d|e|p [filename] [address] [size] [/l=iobase] [/
d=delay]
/i - identify SPI FlashROM
/r address size - read & display data block (0x prefix = hexa
number)
/d filename - dump entire FlashROM to file
/p filename - program entire FlashROM from file (without
erase)
/e - erase entire FlashROM
/u - unlock write protection bits (may depend on WP# level)
/l= LPT port I/O base address (default is 378h - LPT1)
/d= additional delay for SPI clock pulse width [usec] (default
is 0)
LPT to SPI pin assignment (based on BSD AVR programmer):
pin 7 = D5 -> CS#
pin 8 = D6 -> SCK (CLK)
pin 9 = D7 -> MOSI (DIO)
pin 10 = ACK -> MISO (DO)
pin 18 = GND -> GND
|
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
|
F:\Temp\str8132\spipgm>SPIPGMW.EXE /i
SPI FlashROM Programmer 1.6 (C) 2008-2009 by Martin Rehak;
ra...@seznam.cz
Compiled by GCC 3.4.5 (mingw-vista special r3) at 22:49:21, Jan 21
2009
(Win9x/NT/2K/XP compatability)
SPI connected to LPT port at I/O base address: 378h, SCK pulse width: t
+0us
FlashROM JEDEC ID, type: 202017h
ST Microelectronic M25P64 (8MB)
Status = 00h (SRP, RES, TB , BP2, BP1, BP0, WEL, BSY)
0 0 0 0 0 0 0 0
|
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
|
F:\Temp\str8132\spipgm>SPIPGMW.EXE /u
SPI FlashROM Programmer 1.6 (C) 2008-2009 by Martin Rehak;
ra...@seznam.cz
Compiled by GCC 3.4.5 (mingw-vista special r3) at 22:49:21, Jan 21
2009
(Win9x/NT/2K/XP compatability)
SPI connected to LPT port at I/O base address: 378h, SCK pulse width: t
+0us
FlashROM JEDEC ID, type: 202017h
ST Microelectronic M25P64 (8MB)
Status = 02h, WE bit is enabled
Unlocking...
Status = 00h, device is unlocked now.
|
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
|
F:\Temp\str8132\spipgm>SPIPGMW.EXE /e
SPI FlashROM Programmer 1.6 (C) 2008-2009 by Martin Rehak;
ra...@seznam.cz
Compiled by GCC 3.4.5 (mingw-vista special r3) at 22:49:21, Jan 21
2009
(Win9x/NT/2K/XP compatability)
SPI connected to LPT port at I/O base address: 378h, SCK pulse width: t
+0us
FlashROM JEDEC ID, type: 202017h
ST Microelectronic M25P64 (8MB)
Status = 02h, WE bit is enabled
Please wait... done.
|
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
|
F:\Temp\str8132\spipgm>SPIPGMW.EXE /p age-v01r03.bin
SPI FlashROM Programmer 1.6 (C) 2008-2009 by Martin Rehak;
ra...@seznam.cz
Compiled by GCC 3.4.5 (mingw-vista special r3) at 22:49:21, Jan 21
2009
(Win9x/NT/2K/XP compatability)
SPI connected to LPT port at I/O base address: 378h, SCK pulse width: t
+0us
FlashROM JEDEC ID, type: 202017h
ST Microelectronic M25P64 (8MB)
Programming page at: 007FFF00h (100%)
------------------
|
But,
something wrong with u-boot now.
It works, but gives crc error on every boot.
See log:
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
-----------------------
U-Boot 1.1.4 (Nov 27 2007 - 09:29:18)
U-Boot code: 00000000 -> 0001AF80 BSS: -> 0001FEF4
IRQ Stack: 00e6ff7c
FIQ Stack: 00e6ef7c
RAM Configuration:
Bank #0: 00000000 32 MB
Flash Manufacturer: ST
Flash: 8 MB
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
PLL clock at 250MHz
CPU clock at 250MHz
AHB clock at 125MHz
APB clock at 62MHz
Check Link Status .Up
T T T T T T T T T T
Retry count exceeded; starting again
-----------------------
|
It tryes to get some file on tftp, I see.
I can boot it with reset button pressed and load firmware (without
first 256k) into RAM:
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
-----------------------
U-Boot 1.1.4 (Nov 27 2007 - 09:29:18)
U-Boot code: 00000000 -> 0001AF80 BSS: -> 0001FEF4
IRQ Stack: 00e6ff7c
FIQ Stack: 00e6ef7c
RAM Configuration:
Bank #0: 00000000 32 MB
Flash Manufacturer: ST
Flash: 8 MB
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
PLL clock at 250MHz
CPU clock at 250MHz
AHB clock at 125MHz
APB clock at 62MHz
Star Equuleus # tftpboot 0x1020000 age2.bin
Check Link Status ...Up
TFTP from server 192.168.10.3; our IP address is 192.168.10.2
Filename 'age2.bin'.
Load address: 0x1020000
Loading:
#################################################################
#################################################################
#################################################################
...
#################################################################
#################################################################
############################
done
Bytes transferred = 8126464 (7c0000 hex)
Star Equuleus # go 0x1020000
## Starting application at 0x01020000 ...
Uncompressing
Linux.............................................................
...................................................... done, booting
the kernel.
-----------------------
|
Then, I can log in to web-interface and try to reflash original
firmware through it. Device is going to reboot after flashing, and
goes to the same state (with crc error on boot).
Any ideas, what to do?
I think that I'm erased something wrong in flash. I have old bricked
dump of flash...