SEGGER - Jobs
emWin upgrade     Trade-In program     Web shop

J-Flash SPI

 

J-Flash SPI is a PC software running on Microsoft Windows (backward compatible down to Windows 2000) systems, Linux or Mac OS X, which allows direct programming of SPI flashes via J-Link or Flasher. The flash is programmed directly via J-Link using the SPI protocol, no CPU / MCU in between.

Most common SPI flashes are automatically recognized by their respective ID and can easily be programmed with no further setup / configuration of J-Flash SPI needed to be done by the user.

Features

  • Direct programming of SPI flash via J-Link (no CPU / MCU in between).
  • Since J-Link communicates directly with the flash, even flashes connected to CPUs not supported by J-Link can be programmed
  • Cross-platform (command line version for Linux and Mac OS X available)
  • Auto-detection of popular SPI flashes
  • Any SPI flash can be supported. All flash parameters can be manually configured/overriden, if required.
  • Can be controlled via command-line.
  • Part of the J-Link software and documentation package.

J-Link manual (UM08001)          Software and Documentation download
 

Licensing

In order to use J-Flash SPI, either a higher-end J-Link model (J-Link PLUS or higher, click here for a model overview) or a Flasher Production Programmer (click here for a model overview) is needed.

Connection of SPI flash

20-pin connection:

The following table lists the pinout for the SPI interface on J-Link / Flasher.

Pin Signal Type Description
1 VTref Input This is the target reference voltage. It is used to check if the target has power, to create the  logic-level reference for the input comparators and to control the output logic levels to the target. It is normally fed from Vdd of the target board and must not have a series resistor.
2 Not connected NC Leave open on target side.
3 Not connected NC Leave open on target side.
5 DI Output Data-input of target SPI. Output of J-Link, used to transmit data to the target SPI.
7 nCS Output Chip-select of target SPI (active LOW).
9 CLK Output SPI clock signal.
11 Not connected NC Leave open on target side.
13 DO Input Data-out of target SPI. Input of J-Link, used to receive data from the target SPI.
15 nRESET Output Target CPU reset signal (active LOW). Typically connected to the reset pin of the target CPU, which is typically called "nRST", "nRESET" or "RESET".
17 Not connected NC Leave open on target side.
19 5V-Supply Output This pin can be used to supply power to the target hardware. Older J-Links may not be able to supply power on this pin.

 

*On later J-Link products like the J-link ULTRA, these pins are reserved for firmware extension purposes. They can be left open or connected to GND.

Pins 4, 6, 8, 10, 12 are GND pins connected to GND in J-Link. They should also be connected to GND in the target system.

 

J-Link 10-pin Needle Adapter connection:

The following table lists the pinout for the SPI interface on J-Link / Flasher when using the J-Link 10-pin Needle Adapter (model 8.06.04).

Pin Signal Type Description
1 VTref Input This is the target reference voltage. It is used to check if the target has power, to create the  logic-level reference for the input comparators and to control the output logic levels to the target. It is normally fed from Vdd of the target board and must not have a series resistor.
2 nCS Output Chip-select of target SPI (active LOW).
4 CLK Output SPI clock signal.
5 5V-Supply Output This pin can be used to supply power to the target hardware. Older J-Links may not be able to supply power on this pin.
6 DO Input Data-out of target SPI. Input of J-Link, used to receive data from the target SPI.
7 Not connected NC Leave open on target side.
8 DI Output Data-input of target SPI. Output of J-Link, used to transmit data to the target SPI.
9 Not connected NC Leave open on target side.
10 nRESET Output Target CPU reset signal. Typically connected to the RESET pin of the target CPU, which is typically called "nRST", "nRESET" or "RESET".

Pin 3 is GND pin connected to GND in J-Link. It should also be connected to GND in the target system.

 

 

 

Notes regarding nRESET:  If there is another device / peripheral that also controls the SPI flash (e.g. a CPU the flash is connected to), nRESET of J-Link should be connected to the reset of the target system or the reset pin of the CPU to make sure that J-Link can keep the CPU in reset while programming the SPI flash.

Which SPI flash devices are supported?

J-Flash SPI is able to auto-detect common SPI flashes automatically, via their respective ID. Anyhow, since all flash parameters (size, commands etc.) can also be manually configured by the user, any SPI flash device can be supported.

For a list of flash devices that are supported by the flash auto-detection of J-Flash SPI, please refer to here: List of supported SPI flashes

Atmel / Adesto DataFlash

Atmel DataFlash is not supported by J-Flash SPI as its instruction set and handling in general is significantly different from any other SPI flash. Moreover, it's page/sector size is not a power of 2, making is incompatible to existing concepts.

Command line version

For Linux and Mac a command line version of J-Flash SPI is available. This command line version is also available under Windows, for users who prefer a command line version over the GUI version (which can also be controlled from commandline). The command line version is also part of the J-Link software and documentation package.

Flash programming speed

Due to the high performance and the efficient protocol of J-Link/Flasher, programming speeds up to the max. flash programming specified by the flash vendor, can be achieved.

Flash device Programming speed1
ISSI IS25LP128 500 KB/s
ISSI IS25LD040 100 KB/s
ISSI IS25LQ080 340 KB/s
ISSI IS25CD010 100 KB/s
ISSI IS25CQ032 190 KB/s
Macronix MX25L3235E 285 KB/s
Macronix MX66L1G45G 430 KB/s
Macronix MX66L51235F 315 KB/s
Micron N25Q128A 270 KB/s
Micron M25P10 160 KB/s
Micron M25PX16 230 KB/s
Micron M45PE10 230 KB/s
Micron M25PE4 215 KB/s
Spansion S25FL128 410 KB/s
Spansion S25FL116K 265 KB/s
Winbond W25Q128FV 340 KB/s

1 Max. flash programming speed that can be achieved depends on flash device. Flash programming is done in pages and page size as well as page programming time varies from device to device. For more information about the page programming time for a specific flash device, please refer to the appropriate datasheet.