광고
광고
CF.book Page 169 Friday, July 8, 2005 8:59 AM
12
Using Hardware Tools
This chapter explains the CodeWarrior IDE hardware tools, which you can use board bring-up, test, and analysis.
This chapter consists of these sections:
Flash Programmer
Use the CodeWarrior flash programmer to program target-board flash memory with code from any CodeWarrior IDE project, or with code from any individual executable files. The
CodeWarrior debugger provides some flash-programming features, such as view/ modify
, memory/register, and save memory content to a file. The
CodeWarrior flash programmer does not duplicate this functionality.
The flash programmer runs as a CodeWarrior plug-in, using the CodeWarrior debugger protocol API to communicate with the target boards. The CodeWarrior flash programmer lets you use the same IDE to program the flash of any of the embedded target boards.
NOTE
For Special-Edition software, the CodeWarrior flash programmer is limited to
128 kilobytes. There is no such limitation for Standard-Edition or Professional-
Edition software.
Each software edition also comes with an optional ColdFire flash programmer, available in subdirectory
\bin\Pugins\Support\Flash_Programmer
of the CodeWarrior installation directory.
Follow these steps:
1. Make sure to build the application you want to program into flash memory.
2. From the IDE main menu bar, select Tools > Flash Programmer — the Flash
Programmer window (Figure 12.1) appears.
ColdFire Architectures v6.0 - Targeting Manual 169
CF.book Page 170 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Flash Programmer
Figure 12.1 Flash Programmer Window: Target Configuration Panel
170
3. If the Target Configuration panel is not visible, select if from the list at the left — the panel moves to the front of the Flash Programmer window.
4. Verify Target Configuration settings.
a. If the Default Project field specifies your project, skip ahead to substep c.
b. Otherwise, from the main menu bar, select Project > Set as default project to specify your project.
c. If the Default Target field specifies the correct Flash target, skip ahead to substep d.
d. Otherwise, from the main menu bar, select Project > Set as default target to specify the correct Flash target.
e. Make sure that the Use Custom Settings checkbox is clear.
f. Click the Load Settings button — the system updates other settings for the default project and target.
ColdFire Architectures v6.0 - Targeting Manual
CF.book Page 171 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Flash Programmer
5. Configure the flash device.
a. From the pane list at the left of the Flash Programmer window, select Flash
Configuration — the Flash Configuration panel moves to the front of the window,
Figure 12.2 Flash Programmer Window: Flash Device Configuration Panel
b. Make sure that the Device list box specifies your target processor.
c. Make sure that the Flash Memory Base Address text box specifies the appropriate base address.
d. The Organization and Sector Address Map boxes display appropriate additional information.
ColdFire Architectures v6.0 - Targeting Manual 171
CF.book Page 172 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Flash Programmer
6. Erase the destination flash-memory sectors.
a. From the pane list at the left of the Flash Programmer window, select Erase/
Blank Check — the Erase/Blank Check panel moves to the front of the window,
Figure 12.3 Flash Programmer Window: Erase/Blank Check Flash Panel
172 b. In the panel’s list box, select the sectors you want to erase. (To select them all, check the All Sectors checkbox.) c. Click the Erase button — the flash programmer erases the sectors.
d. (Optional) To confirm erasure, select the same sectors, then click the Blank Check button — a message reports the status of the sectors.
ColdFire Architectures v6.0 - Targeting Manual
CF.book Page 173 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Flash Programmer
7. Flash your application.
a. From the pane list at the left of the Flash Programmer window, select Program/
Verify — the Program/Verify Flash panel moves to the front of the window, as
Figure 12.4 Flash Programmer Window: Program/Verify Flash Panel
b. Make sure that the Use Selected File checkbox is clear.
c. Click the Program button — the flash programmer programs your application into the target sectors of flash memory.
d. (Optional) To confirm programming, click the Verify button — the flash programmer compares the data now in flash sectors to the image file on disk.
ColdFire Architectures v6.0 - Targeting Manual 173
CF.book Page 174 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Hardware Diagnostics
8. (Optional) For an additional test of programmed flash sectors, run a checksum.
a. From the pane list at the left of the Flash Programmer window, select Checksum
— the Checksum panel moves to the front of the window, as Figure 12.5 shows.
Figure 12.5 Flash Programmer Window: Checksum Panel
b. In the Compute Checksum Over area, select the appropriate option button: File on
Target, File on Host, Memory Range on Target, or Entire Flash.
c. If this selection activates the Address Range text boxes, enter the appropriate Start and Size values.
d. Click the Calculate Checksum button — the flash programmer runs the checksum calculation; a message tells you the result.
9. This completes flash programming.
Hardware Diagnostics
Use the CodeWarrior hardware diagnostics tool to obtain several kinds of information about the target board.
Select Tools > Hardware Diagnostics from the IDE main menu bar — the Hardware
Diagnostics window (Figure 12.6) appears.
174 ColdFire Architectures v6.0 - Targeting Manual
CF.book Page 175 Friday, July 8, 2005 8:59 AM
Figure 12.6 Hardware Diagnostics window: Configuration Panel
Using Hardware Tools
Hardware Diagnostics
Figure 12.6 shows the Configuration panel. Click any name in the list pane to bring the
corresponding panel to the front of the window:
• Memory Read/Write Test — which Figure 12.7 shows.
• Scope Loop Test — which Figure 12.8 shows.
• Memory Tests — which Figure 12.9 shows.
ColdFire Architectures v6.0 - Targeting Manual 175
CF.book Page 176 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Hardware Diagnostics
Figure 12.7 Hardware Diagnostics window: Memory Read/Write Test Panel
Figure 12.8 Hardware Diagnostics window: Scope Loop Test Panel
176 ColdFire Architectures v6.0 - Targeting Manual
CF.book Page 177 Friday, July 8, 2005 8:59 AM
Figure 12.9 Hardware Diagnostics window: Memory Tests Panel
Using Hardware Tools
Hardware Diagnostics
The Hardware Diagnostics window lists global options for the hardware diagnostic tools; these preferences apply to every open project file. For more information about each hardware-diagnostics panel, see the IDE User’s Guide .
ColdFire Architectures v6.0 - Targeting Manual 177
CF.book Page 178 Friday, July 8, 2005 8:59 AM
Using Hardware Tools
Hardware Diagnostics
178 ColdFire Architectures v6.0 - Targeting Manual
다운로드
광고