annotate loadtools/loadtool.help @ 700:db9a8e88e63f

target-utils lunadrv program written, compiles
author Mychaela Falconia <falcon@freecalypso.org>
date Thu, 07 May 2020 02:19:51 +0000
parents 8b1e86dcc3ac
children e78c7ab3b0e6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 This is the help file for fc-loadtool. See lthelp.c for the code
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 that parses and displays it. The parsing code is the only
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 documentation for the format of this help file - if you are going to
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 edit this help text, read the parsing code first.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 === main
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 This utility allows you to perform the following operations
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 on your Calypso GSM device:
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 * Peek and poke registers
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 * Dump any part of memory
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 * Read and program flash
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 See the following help topics for more information:
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 help peekpoke Register peek and poke commands
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 help flash Flash operation commands
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 help all List of all implemented commands
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 help exit Controlling the cleanup on exit
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 === all
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 abbr Read an ABB register
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 abbw Write an ABB register
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 baud Switch the serial comm with loadagent to a different baud rate
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 crc32 Get CRC-32 of a memory area on the target
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 dieid Read the Calypso die ID
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 dump Dump a target memory region in hex and ASCII
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 dump2bin Dump a target memory region to a file in binary format
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 dump2srec Dump a target memory region to a file in S-record format
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 exec Execute a command script
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 exit Exit from loadtool and clean up the target device state
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 flash Flash operations
410
e3d976e1f814 loadtools/loadtool.help: update for FC devices having flash2
Mychaela Falconia <falcon@freecalypso.org>
parents: 228
diff changeset
33 flash2 Operations on the 2nd flash bank (FC and Pirelli devices only)
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 quit Alias for exit
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 r8 Read an 8-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 r16 Read a 16-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 r32 Read a 32-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 w8 Write an 8-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 w16 Write a 16-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 w32 Write a 32-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 To get help on any command, type help and the command keyword.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 === abbr
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 === abbw
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 abbr pg reg Read ABB register <reg> on page <pg>
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 abbw pg reg val Write <val> into register <reg> on page <pg>
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 The <pg> and <reg> arguments default to decimal unless prefixed with 0x;
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 the <val> argument to abbw is always hexadecimal.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 === baud
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 baud Display the current baud rate
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 baud <rate> Switch the baud rate to <rate> (number in bps)
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 The supported baud rates are:
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58 Standard: 19200, 38400, 57600, 115200
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 Calypso special: 203125, 406250, 812500
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 The baud command coordinates the necessary simultaneous switching of the
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 baud rate on both the host and the target (loadagent). Loadagent always
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 supports all of the listed rates and will switch happily, but in the case
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 of the higher non-standard baud rates fc-loadtool has no way of knowing
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 ahead of time whether or not the requested baud rate is supported by your
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 usb2serial adapter or whatever other serial port hardware and driver
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 you are using. If the baud rate switch fails, the communication link with
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 the target will be broken and fc-loadtool will exit ungracefully.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70 === crc32
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 crc32 hex-start hex-len
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 The first argument is the starting target memory address in hex; the second
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 argument is the length of the area to CRC, also in hex. The command will be
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75 sent to loadagent; CRC-32 of the requested range will be computed on the target
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 and displayed in hex.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78 === dieid
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 dieid Display the Calypso die ID
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80 dieid <filename> Display the Calypso die ID, and also save it in the
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 named file
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83 The Calypso die ID resides in 4 16-bit registers at target addresses
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 0xFFFEF010 through 0xFFFEF016. It is displayed on the terminal and optionally
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85 saved to a file in this simple form:
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87 FFFEF010: xxxx
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 FFFEF012: xxxx
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89 FFFEF014: xxxx
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 FFFEF016: xxxx
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 === dump
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93 dump hex-start hex-len
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95 The first argument is the starting target memory address in hex; the second
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96 argument is the length of the area to dump, also in hex. The dump will be
621
f44770a652eb loadtool.help: additional details documented for dump commands
Mychaela Falconia <falcon@freecalypso.org>
parents: 576
diff changeset
97 displayed on the terminal in hex and ASCII. As an implementation limit, both
f44770a652eb loadtool.help: additional details documented for dump commands
Mychaela Falconia <falcon@freecalypso.org>
parents: 576
diff changeset
98 the starting target memory address and the length of the area to dump need to
f44770a652eb loadtool.help: additional details documented for dump commands
Mychaela Falconia <falcon@freecalypso.org>
parents: 576
diff changeset
99 be aligned to 16 bytes.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101 === dump2bin
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 === dump2srec
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103 dump2bin hex-start hex-len outfile
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104 dump2srec hex-start hex-len outfile
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 The first argument is the starting target memory address in hex; the second
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107 argument is the length of the area to dump, also in hex; the third argument
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108 is the name of the output file to be created/written. The dump will be saved
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 in binary or S-records as per the chosen command, always in the native byte
643
cd031e2501fa loadtool.help: dump2bin and dump2srec improvements
Mychaela Falconia <falcon@freecalypso.org>
parents: 632
diff changeset
110 order of the Calypso ARM7 target (little-endian).
621
f44770a652eb loadtool.help: additional details documented for dump commands
Mychaela Falconia <falcon@freecalypso.org>
parents: 576
diff changeset
111
643
cd031e2501fa loadtool.help: dump2bin and dump2srec improvements
Mychaela Falconia <falcon@freecalypso.org>
parents: 632
diff changeset
112 The 128 byte alignment requirement of previous versions has been lifted; you
cd031e2501fa loadtool.help: dump2bin and dump2srec improvements
Mychaela Falconia <falcon@freecalypso.org>
parents: 632
diff changeset
113 can now dump as little as one byte without any alignment restrictions. In the
cd031e2501fa loadtool.help: dump2bin and dump2srec improvements
Mychaela Falconia <falcon@freecalypso.org>
parents: 632
diff changeset
114 case of dump2srec the output file will be written with 32 bytes of payload per
cd031e2501fa loadtool.help: dump2bin and dump2srec improvements
Mychaela Falconia <falcon@freecalypso.org>
parents: 632
diff changeset
115 S3 record, with the last record carrying from 1 to 32 bytes of payload as
cd031e2501fa loadtool.help: dump2bin and dump2srec improvements
Mychaela Falconia <falcon@freecalypso.org>
parents: 632
diff changeset
116 needed.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 === exec
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 exec <script-file>
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120
228
ccf5edab9d5f loadtool.help: exec command description updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 54
diff changeset
121 Read and execute commands from the named file. If the execution of a script
ccf5edab9d5f loadtool.help: exec command description updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 54
diff changeset
122 command encounters an error, the following commands are not executed, i.e.,
ccf5edab9d5f loadtool.help: exec command description updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 54
diff changeset
123 stop on first error.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125 === exit
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 === quit
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 exit Clean up the target in the default manner and exit
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128 exit bare Exit loadtool without doing anything to the target
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129 exit iota-off Exit loadtool and command an ABB power-off on the target
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 exit jump0 Exit loadtool and command the target to reboot via jump to 0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
131
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
132 The default method of cleaning up the target device state upon exit is set
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133 in the hardware parameters file selected with the -h or -H command line
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
134 option; it is the exit-mode setting. On most targets the default exit mode is
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
135 iota-off.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
136
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
137 If you do an exit bare without powering the target device off in some other
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
138 way, the device will still be running loadagent, which is probably not what you
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
139 want. However, it is the proper exit mode if you have powered off or reset the
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
140 target device by brute force (yanking the battery).
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
141
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
142 === flash
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
143 === flash2
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
144 The primary end use of fc-loadtool is for reading and writing the NOR flash
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
145 memories of the supported GSM devices. Most Calypso phones and modems have
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
146 only one flash bank (as in chip select), and are manipulated with the flash
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
147 command. FreeCalypso development boards and the Pirelli DP-L10 phone have two
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
148 flash banks (as in chip selects) of 8 MiB each; they are manipulated with the
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
149 flash and flash2 commands.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
150
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
151 The following flash operations are available:
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
152
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
153 flash blankchk Blank-check a region of flash
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
154 flash dump2bin Dump flash content to a file in binary format
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
155 flash dump2srec Dump flash content to a file in S-record format
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
156 flash erase Erase a region of flash
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
157 flash geom Display geometry details of detected flash chip
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
158 flash id Perform flash chip autodetection sequence
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
159 flash info Display flash configuration info
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
160 flash program-bin Program flash with a binary file
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
161 flash program-m0 Program flash with an image in TI's *.m0 format
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
162 flash program-srec Program flash with an image in standard S-record format
675
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
163 flash e-program-bin Combined erase and program-bin
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
164 flash e-program-m0 Combined erase and program-m0
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
165 flash e-program-srec Combined erase and program-srec
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
166 flash quickprog Program a few flash words from the command line
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
167 flash reset Reset flash chip to read array mode
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
168 flash sectors Display the list of flash sector addresses and sizes
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
169 flash status Intel-style flash only: read Status Register
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
170 flash unlock Intel-style flash only: unlock flash sectors
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
171
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
172 Additional operation for Compal targets only:
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
173
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
174 flash erase-program-boot Erase and reprogram the boot sector
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
175
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
176 Substitute flash2 instead of flash when operating on the 2nd flash chip select
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
177 of Pirelli-style flash memory configurations. Prepend help before a command to
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
178 get usage information, e.g., help flash program-bin.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
179
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
180 === flash:blankchk
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
181 flash[2] blankchk hex-start-offset hex-length
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
182
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
183 Blank-checks an area of flash starting at the specified hex offset (from the
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
184 base address of the flash bank) and extending for the specified hex length.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
185 Reports whether the checked region is blank or not. Flash must be blank (FF in
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
186 all bytes) before it can be programmed.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
187
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
188 === flash:dump2bin
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
189 flash[2] dump2bin outfile [offset [length]]
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
190
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
191 Read device flash content and save it to a file. If only a filename is
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
192 specified, the full flash bank is dumped; one can optionally specify a starting
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
193 offset and an explicit length, both in hex.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
194
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
195 This command was originally nothing more than a user-friendly front-end to the
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
196 plain dump2bin command (see help dump2bin), but in the current version it first
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
197 performs the flash chip autodetection operation if it hasn't been done already
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
198 (needed in order to determine the size of the flash bank) and resets the flash
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
199 to read array mode.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
200
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
201 === flash:dump2srec
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
202 flash[2] dump2srec outfile [offset [length]]
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
203
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
204 Read device flash content and save it to a file. If only a filename is
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
205 specified, the full flash bank is dumped; one can optionally specify a starting
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
206 offset and an explicit length, both in hex.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
207
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
208 This command was originally nothing more than a user-friendly front-end to the
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
209 plain dump2srec command (see help dump2srec), but in the current version it
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
210 first performs the flash chip autodetection operation if it hasn't been done
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
211 already (needed in order to determine the size of the flash bank) and resets
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
212 the flash to read array mode.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
213
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
214 === flash:erase
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
215 flash[2] erase hex-start-offset hex-length
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
216
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
217 Erases an area of flash starting at the specified hex offset (from the base
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
218 address of the flash bank) and extending for the specified hex length.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
219
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
220 Flash memory can only be erased (turning 0 bits back to 1s) in units of
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
221 sectors, as set in stone by the design of the flash chip in use. Loadtool will
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
222 autodetect the flash chip in use and will only operate on those flash chip types
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
223 which it knows about; if a known chip is found, loadtool knows its sector layout
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
224 and enforces that both arguments to the flash[2] erase command lie on sector
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
225 boundaries.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
226
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
227 === flash:erase-program-boot
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
228 flash erase-program-boot binfile [length]
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
229
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
230 This operation is applicable to Compal targets only. This command erases and
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
231 reprograms flash sector 0 (the boot sector) with minimized vulnerability to
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
232 bricking by loading the new boot code into a scratchpad RAM area on the target,
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
233 then commanding loadagent (running on the target) to erase and reprogram the
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
234 dangerous flash sector without requiring further interaction with loadtool.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
235 (In contrast, loadtool's "regular" flash erase and program operations are
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
236 driven primarily by loadtool, with loadagent providing only low-level
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
237 functions.)
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
238
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
239 The new bits to be programmed are taken from the specified binary file. Byte 0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
240 of the file goes into byte 0 of the flash and so on, for the specified length.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
241 If no length argument is given, it defaults to the length of the file, which
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
242 must not exceed the length of flash sector 0: 64 KiB on the "basic" Compal
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
243 phones or 8 KiB on C155/156.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
244
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
245 === flash:geom
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
246 This command displays information about the detected flash chip: device name,
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
247 geometry details and the command set style (AMD or Intel). The displayed
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
248 geometry details include the total size of the flash bank, the total number of
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
249 sectors, the number of regions with different sector sizes and the sector size
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
250 and the number of sectors in each region.
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
251
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
252 === flash:id
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
253 This command explicitly invokes the same flash chip autodetection operation
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
254 that is performed the first time each flash bank is accessed with any flash or
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
255 flash2 command.
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
256
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
257 === flash:info
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
258 This command displays the global flash configuration settings that have been
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
259 selected at fc-loadtool invokation time (hardware parameters associated with
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
260 the target set via -h or -H): the global single-4M, single-8M or dual-8M
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
261 setting and flash bank base addresses.
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
262
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
263 In previous versions this command performed flash ID checks and displayed
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
264 geometry information; these functions have been moved to the new flash id and
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
265 flash geom commands.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
266
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
267 === flash:program-bin
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
268 flash[2] program-bin flash-offset binfile [file-offset [length]]
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
269
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
270 This command programs flash, using a binary file as the data source. One must
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
271 always specify the starting flash offset (from the base address of the flash
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
272 bank), but the starting file offset and length are optional, defaulting to the
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
273 whole file.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
274
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
275 The binary file must be in the native byte order of the Calypso ARM7 processor,
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
276 which is little-endian. Images produced by flash[2] dump2bin are suitable.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
277
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
278 === flash:program-m0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
279 flash[2] program-m0 image.m0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
280
632
ae4330d86029 loadtool.help: description of program-m0 updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 621
diff changeset
281 Calypso firmware images built with TI's TMS470 toolchain in TI's canonical
ae4330d86029 loadtool.help: description of program-m0 updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 621
diff changeset
282 manner come out in a hex format that is a variant of Motorola's SREC, in files
ae4330d86029 loadtool.help: description of program-m0 updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 621
diff changeset
283 ending with the .m0 suffix. We have nicknamed this format "moko-style m0"
ae4330d86029 loadtool.help: description of program-m0 updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 621
diff changeset
284 after its most famous user; this command programs the flash with an image in
ae4330d86029 loadtool.help: description of program-m0 updated
Mychaela Falconia <falcon@freecalypso.org>
parents: 621
diff changeset
285 this moko-style m0 format.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
286
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
287 Because each S-record contains an address, no addresses or offsets need to be
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
288 specified in the flash[2] program-m0 command, only the image file.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
289
675
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
290 This command does NOT include a built-in flash erase step - see
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
291 help flash e-program-m0 for the more complete version.
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
292
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
293 === flash:program-srec
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
294 flash[2] program-srec image.srec
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
295
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
296 This command programs the flash with an image in the standard S-record format,
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
297 in the native little-endian byte order of the Calypso ARM7 processor. It is
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
298 the opposite byte order from that used by TI's *.m0 files -
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
299 see help flash program-m0. Images produced by flash[2] dump2srec are suitable
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
300 for flash[2] program-srec.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
301
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
302 Because each S-record contains an address, no addresses or offsets need to be
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
303 specified in the flash[2] program-srec command, only the image file.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
304
675
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
305 === flash:e-program-bin
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
306 flash[2] e-program-bin flash-offset binfile [file-offset [length]]
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
307
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
308 This command is an extension of flash[2] program-bin: it first erases the range
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
309 of sectors that contains the range of flash words to be programmed, then
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
310 executes the program-bin operation. All arguments are exactly the same as for
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
311 flash[2] program-bin - see help flash program-bin. The range of sectors that
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
312 will be erased will be the minimal set that contains the area of flash to be
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
313 programmed. This command is intended for automated (no thinking required)
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
314 flashing of firmware release images that are delivered in binary format; only
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
315 flash-offset and binfile arguments will be given in this case.
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
316
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
317 === flash:e-program-m0
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
318 flash[2] e-program-m0 image.m0
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
319
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
320 This command reads in the specified S-record image in moko-style m0 format,
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
321 builds a map of potentially discontiguous flash regions into which the image
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
322 deposits bits, erases the set of flash sectors which need to be erased before
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
323 programming these regions, then programs the new image bits into flash. This
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
324 command is intended for automated (no thinking required) flashing of firmware
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
325 release images that are delivered in moko-style m0 format.
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
326
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
327 === flash:e-program-srec
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
328 flash[2] e-program-srec image.srec
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
329
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
330 This command works like flash[2] e-program-m0, but takes in an S-record image
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
331 in little-endian byte order, which is the opposite byte order from that used by
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
332 TI's *.m0 files. This command is provided only for the sake of symmetry - no
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
333 practical use case is envisioned.
8b1e86dcc3ac loadtool.help: new flash e-program-* commands documented
Mychaela Falconia <falcon@freecalypso.org>
parents: 643
diff changeset
334
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
335 === flash:quickprog
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
336 flash[2] quickprog hex-offset hex-data-string
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
337
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
338 This command is intended only for developers; it provides raw access to
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
339 loadagent's basic flash write primitive. Read the source code for more
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
340 information.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
341
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
342 === flash:reset
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
343 Intel-style flash memory chips have two "stable" or "quiescent" states: reading
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
344 array data and reading the status register (SR). After an erase or program
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
345 operation the flash chip is "parked" in the Read SR state; the flash reset
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
346 command switches it back to reading array data.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
347
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
348 This command works for AMD-style flash as well, but it is normally not needed,
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
349 as AMD-style flash chips automatically return to the read-array-data state
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
350 after every erase or program operation.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
351
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
352 === flash:sectors
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
353 This command displays the list of sector offsets and sizes for the detected
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
354 flash chip. This command is deprecated except for debugging of loadtool
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
355 internals; the new flash geom command displays the same information in a much
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
356 more compact form.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
357
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
358 === flash:status
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
359 This command is only applicable to Intel-style flash chips. It reads the flash
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
360 chip's Status Register, which can be used to diagnose errors incurred by
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
361 previous erase or program operations.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
362
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
363 === flash:unlock
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
364 flash unlock hex-start-offset hex-length
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
365
518
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
366 This command is only applicable to Intel-style flash chips. These flash chips
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
367 power up with each sector (erase block) in the "locked" state; each sector
372757bb62e4 loadtools/loadtool.help updated for new flash handling architecture
Mychaela Falconia <falcon@freecalypso.org>
parents: 410
diff changeset
368 needs to be unlocked before it can be erased or programmed.
0
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
369
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
370 This command is normally not needed, as the flash erase command unlocks each
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
371 sector before erasing it. However, if you are going to perform program
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
372 operations in some sectors without erasing them, you will need to unlock them
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
373 explicitly first.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
374
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
375 This command operates only on sector boundaries just like flash erase.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
376
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
377 === r8
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
378 === r16
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
379 === r32
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
380 === w8
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
381 === w16
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
382 === w32
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
383 === peekpoke
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
384 The register peek and poke commands are:
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
385
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
386 r8 addr Read an 8-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
387 r16 addr Read a 16-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
388 r32 addr Read a 32-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
389 w8 addr data Write an 8-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
390 w16 addr data Write a 16-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
391 w32 addr data Write a 32-bit register or memory location
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
392
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
393 All addresses and data values are in hex.
e7502631a0f9 initial import from freecalypso-sw rev 1033:5ab737ac3ad7
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
394