Pin 1 on the 20 pin connector is labelled VTref. The idea here is that you connect the Vcc of the target system to this pin, and it "tells" the Segger what logic level your target is running at. Pin 19 on the Segger is available to supply power to the target. A real Segger provides 5 volts (software switchable), and the following article describes a hack to get 3.3 volts instead. My clone supplies 3.3 volts (switchable by a jumper).
This guys aricle is all about setting up the Segger to deliver 3.3 volt power to the target system. Mine would do that anyway, but I am removing the jumper to disable it. The article has points of interest regardless, in particular the photos of the insides of a real Segger J-link (from this era), which apparently was based on an STM32F205 chip rather than the Atmel device in my clone.There is a 3.3 volt regulator, and a jumper that can pass 3.3 volts to pin 2 on the JTAG cable to power a target.
There are two NXP ALVC164245 chips. These are 16 bit level shifters. The datasheet from TI says that can shift from 5.0 to 3.3 or from 3.3 to 2.5. Two of them gives us 32 bits, and it is a bit perplexing to understand why we need 32 bits when we have only a handful of signals on the JTAG cable. It may have to do with the way direction switching is handled. The datasheet says one side of the chip is rated for 1.5 to 5.5 volts, while the other is 1.5 to 3.6. My bet is that the 1.5 to 3.6 side is connected to 3.3 volt logic from the Atmel chip and the other side (the 1.5 to 5.5) is connected to the cable. This would allow the JTAG system to run at 1.8, 2.5, 3.3, and maybe even 5.0 volts.
My device has grounds on all the even pins (except pin 2) as shown. Pin 2 could deliver 3.3 volts to the target, except that I have disabled this by removing a jumper on the PCB. This leaves the 10 odd pins:
Apr 29 17:59:47 trona kernel: usb 1-1: new full-speed USB device number 2 using xhci_hcd Apr 29 17:59:47 trona kernel: usb 1-1: New USB device found, idVendor=1366, idProduct=0101, bcdDevice= 1.00 Apr 29 17:59:47 trona kernel: usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3 Apr 29 17:59:47 trona kernel: usb 1-1: Product: J-Link Apr 29 17:59:47 trona kernel: usb 1-1: Manufacturer: SEGGER Apr 29 17:59:47 trona kernel: usb 1-1: SerialNumber: 001631096578This command gets the ball rolling:
openocd -f /usr/share/openocd/scripts/interface/jlink.cfg -c "transport select jtag"We get this:
Warn : An adapter speed is not selected in the init scripts. OpenOCD will try to run the adapter at the low speed (100 kHz) Warn : To remove this warnings and achieve reasonable communication speed with the target, set "adapter speed" or "jtag_rclk" in the init scripts. Info : J-Link ARM V8 compiled Nov 28 2014 13:44:46 Info : Hardware version: 8.00 Info : VTarget = 3.338 V Info : clock speed 100 kHz Warn : There are no enabled taps. AUTO PROBING MIGHT NOT WORK!! Info : JTAG tap: auto0.tap tap/device found: 0x13722093 (mfg: 0x049 (Xilinx), part: 0x3722, ver: 0x1) Info : JTAG tap: auto1.tap tap/device found: 0x4ba00477 (mfg: 0x23b (ARM Ltd), part: 0xba00, ver: 0x4) Warn : AUTO auto0.tap - use "jtag newtap auto0 tap -irlen 2 -expected-id 0x13722093" Warn : AUTO auto1.tap - use "jtag newtap auto1 tap -irlen 2 -expected-id 0x4ba00477"
Tom's Computer Info / [email protected]