comparison packages/hal/arm/pid/current/misc/Notes @ 50:a0774359f013 ecos-sw-1999-11-02

Merge from eCos master repository on 1999-11-02-17:02:15-GMT
author jlarmour
date Tue, 02 Nov 1999 20:57:07 +0000
parents 443894e2e912
children c38311975d4f
comparison
equal deleted inserted replaced
49:698ff3191b93 50:a0774359f013
20 ------------------------------------------- 20 -------------------------------------------
21 21
22 ####COPYRIGHTEND#### 22 ####COPYRIGHTEND####
23 =========================================================================== 23 ===========================================================================
24 24
25 15 Jan 1999 25 27 Oct 1999
26 26
27 How to build and install the GDB module on the PID 27 How to build and install the GDB module on the PID
28 28
29 1. Configure a minimal eCos system with all packages except 'infra' disabled. 29 Make GDB module
30 2. Edit <hal/hal.h> to enable GDB: 30 ~~~~~~~~~~~~~~~
31 1. Configure a minimal eCos system with all packages except 'infra' disabled.
32 2. Edit <hal/hal.h> to enable GDB:
31 #define CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS 33 #define CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
32 #undef CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT 34 #undef CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
33 #undef CYGDBG_HAL_DEBUG_GDB_THREAD_SUPPORT 35 #undef CYGDBG_HAL_DEBUG_GDB_THREAD_SUPPORT
34 3. make;make -C hal/arm/pid/current/misc 36 3. make;make -C hal/arm/pid/<version>/misc
35 4. Download the image onto the PID board: 37
36 arm-elf-gdb -nw hal/arm/pid/current/misc/gdb_module.img 38 Alternatively run hal/arm/pid/<version>/misc/STUBS_config.
37 You can connect to the board using either existing GDB stubs or Angel. 39
40
41 GDB image is in the file hal/arm/pid/<version>/misc/gdb_module.img
42
43
44 Make FLASH tool
45 ~~~~~~~~~~~~~~~
46 1. Configure a separate eCos system with all packages enabled.
47 2. Change diag chanel to port B (in file pkgconf/hal_arm_pid.h):
48 #define CYGHWR_HAL_ARM_PID_DIAG_PORT 1
49 2. make misc
50
51 FLASH tool is in the file hal/arm/pid/<version>/misc/prog_flash
52
53
54 Prepare board for eCos
55 ~~~~~~~~~~~~~~~~~~~~~~
56 1. Set jumper 7-8 on LK6 [using the Angle code in the 16 bit EPROM]
57 2. Set jumper 5-6 on LK6 [select 8bit ROM mode]
58 3. Set jumper LK18 [ROM remap - this is also required for eCos]
59 4. Set S1 to 0-0-1-1 [20MHz operation]
60
61
62 Program FLASH
63 ~~~~~~~~~~~~~
64 1. Download the image onto the PID board:
65 arm-elf-gdb -nw hal/arm/pid/<version>/misc/gdb_module.img
66
67 (gdb) target rdi s=<serial device>
68 (gdb) load
69 [...]
70 (gdb) quit
71
38 This will download the stubs onto the board at 0x60000..0x64000 72 This will download the stubs onto the board at 0x60000..0x64000
39 5. Configure a separate eCos system with all packages enabled.
40 6. make misc
41 7. Now download the FLASH programmer tool
42 arm-elf-gdb -nw hal/arm/pid/current/misc/prog_flash
43 8. Run the tool. The GDB stubs will now be programmed into the FLASH.
44 73
45 eCos GDB stubs should now be installed and set up as the default monitor when you 74 2. Now download the FLASH programmer tool
46 run from FLASH. 75 arm-elf-gdb -nw hal/arm/pid/<version>/misc/prog_flash
76
77 (gdb) target rdi s=<serial device>
78 (gdb) load
79 [...]
80 (gdb) cont
81
82 3. The FLASH tool will output some text on the board serial port B at
83 38400 baud:
84
85 ARM eCos
86 FLASH here!
87 manuf: 8, device: 40
88 Error: Wrong Manufaturer: 08
89 ... Please change FLASH jumper
90
91 4. This text is repeated until you remove the jumper 7-8 on LK6. Then
92 the output should be:
93
94 manuf: 1F, device: A4
95 AT29C040A recognised
96 About to program FLASH using data at 60000..64000
97 *** Press RESET now to abort!
98
99 5. You have about 10 seconds to abort the operation by pressing
100 reset. After this timeout, the FLASH programming happens:
101
102 ...Programming FLASH
103 All done!
104
105 6. Quit/kill the GDB process which will hang.
106
107 7. Next time you reset the board, the stub will be in control, communicating
108 on serial port A at 38400 baud. See documentation for further details
109 on how to connect with GDB.
110
111
112
113 Big-Endian operation
114 ~~~~~~~~~~~~~~~~~~~~
115
116 1) If the board is to be used in big-endian mode, the stub should be
117 configured for platform 'pidbe' instead of 'pid'. 'pidbe' can also
118 be used as a second argument to the STUBS_config script.
119
120 2a) If a big-endian rom controller is installed on the board, the
121 programming of a new stub into flash is covered in the ARM PID
122 manual.
123
124 2b) If a big-endian rom controller is _not_ used, this is what you
125 must do:
126
127 1) Follow the above instructions (including jumper settings) ,
128 but instead of using the 'prog_flash' FLASH tool, use the
129 'prog_flash_BE_image_LE_system' FLASH tool.
130
131 2) Instead of resetting the board after the FLASH has been
132 programmed, switch off the power and enable jumper LK4.
133
134 If you have to re-program the FLASH later, you can follow the
135 steps above again, but also disable jumper LK4 when changing the
136 other jumpers.
137