J-Link Gdb Server; J-Link Commander - Segger J-Link User Manual

Hide thumbs Also See for J-Link:
Table of Contents

Advertisement

Save the settings file and restart the debug session. Open the J-Link Control Panel
and verify that the "MemMap" tab shows the new settings for CFI flash and work RAM
area.
6.5.2

J-Link GDB Server

The configuration for the J-Link GDB Server is done by the .gdbinit file. The follow-
ing commands have to be added to the .gdbinit file to enable the flash download
feature:
monitor WorkRAM = <SAddr>-<EAddr>
monitor flash CFI = <SAddr>-<EAddr>
For more information about the GDB monitor commands please refer to J-Link GDB
Server on page 66.
6.5.3

J-Link commander

J-Link Commander supports downloading bin files into external CFI flash memory. In
the following, it is explained which steps are necessary to prepare J-Link Commander
for download into external CFI flash memory based on a sample sequence for a ST
STM32F103ZE device:
r
speed 1000
exec setcfiflash 0x64000000 - 0x64FFFFFF
exec setworkram 0x20000000 - 0x2000FFFF
w4 0x40021014, 0x00000114 // RCC_AHBENR, FSMC clock enable
w4 0x40021018, 0x000001FD // GPIOD~G clock enable
w4 0x40011400, 0xB4BB44BB // GPIOD low config, NOE, NWE => Output, NWAIT => Input
w4 0x40011404, 0xBBBBBBBB // GPIOD high config, A16-A18
w4 0x40011800, 0xBBBBBBBB // GPIOE low config, A19-A23
w4 0x40011804, 0xBBBBBBBB // GPIOE high config, D5-D12
w4 0x40011C00, 0x44BBBBBB // GPIOF low config, A0-A5
w4 0x40011C04, 0xBBBB4444 // GPIOF high config, A6-A9
w4 0x40012000, 0x44BBBBBB // GPIOG low config, A10-A15
w4 0x40012004, 0x444B4BB4 // GPIOG high config, NE2 => output
w4 0xA0000008, 0x00001059 // CS control reg 2, 16-bit, write enable, Type: NOR flash
w4 0xA000000C, 0x10000505 // CS2 timing reg (read access)
w4 0xA000010C, 0x10000505 // CS2 timing reg (write access)
speed 4000
mem 0x64000000,100
loadbin C:\STMB672_STM32F103ZE_TestBlinky.bin,0x64000000
mem 0x64000000,100
6.5.3.1 Converting non-bin files
As previously mentioned, J-Link Commander supports programming of bin files into
flash memory. If the data file to be programmed is in non-bin format (.hex, .mot,
.srec), the file needs to be converted into binary first. There are various free soft-
J-Link / J-Trace (UM08001)
© 2004-2013 SEGGER Microcontroller GmbH & Co. KG
195

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the J-Link and is the answer not in the manual?

This manual is also suitable for:

J-trace

Table of Contents

Save PDF