FPGA JTAG Debug Guide
Description:
ü If the device pin JTAG debug port welding is completed, you can skip to the second step, installing Quartus II and Nios II software.
ü And you have installed Quartus II and Nios II software, you can skip to the third step is to install the JTAG driver.
ü If the JTAG driver has been installed, you can jump to the fourth step, directly connected JTAG debug tool chain equipment.
Step 1: Welding JTAG interface
Please welding 2*5 pin header in the picture-position.
Step 2: Install Quartus II and Nios II
Download: 91sp2_quartus_windows.exe, 91sp2_nios2_windows.exe
Website: ftp://ftp.altera.com/outgoing/release/
u Install Quartus II 9.1
- Decompressing files 91sp2_quartus_windows.exe to the current directory to the 91sp2_quartus_windows folder.
- Open 91sp2_quartus_windows folder, dblclick setup.exe file start the installation program of Quartus II 9.1.
- Click Next, until appear License Agreement Window, then select “I accept the terms of the license agreement” and click Next.
- In the Customer Information interface, fill in the User Name and Company Name.
- Choose the install path. Here you can choose the default C:\Altera\91 as installation path, also set new installation path in yourself. If you set new installation path, you must notice: Installation path can't appear Spaces and Chinese characters. Here we choose default installation C:\Altera\91.
- Click Next, choose Complete in the Setup Type window. Click on Next installation procedures. The process is slow to wait inside.
- After the completion of the will pop up a Dialog box of "Create Quartus II 9.1 shortcut on desktop?”.Prompts you to create desktop shortcut icons, choose "Yes".
- Pop-up dialog box again, the default settings, click "OK".
- Click Finish, to complete the installation of the Quartus II 9.1.
u Install Nios II 9.1
- Run 91sp2_nios2eds_windows.exe file, click Next, click Yes.
- Choose installation path, this path the same to your install Quartus II 9.1.
- Click Next, installation.
- Click on Finish, complete installation.
Step 3: Install JTAG Driver
u Connection the USB-Blaster
u Wait for “find new hardware”
If no the “Find new hardware” message, try to change one USB interface.
u Specifies the driver path(three methods)
- In Quartus II environment, specify the driver path can be installed directly. If your Quartus II 9.1 installed in C:\altera\91 directory, in C:\altera\91\quartus\drivers\usb-blaster\x32 directory to find “usbblst.inf”, point in the file selection can be installed.
u After the installation restart the computer.
Step 4: Connect JTAG debug equipment to run Command Shell
Note: Only you complete the first three steps, you will be able to work for the next.
u Run Command Shell, StartàProgramàAlteraà Nios II EDS 9.1àNios II 9.1 Command Shell.
u Enter the nios2-terminal –-persistent >> log.txt command in the Command Shell interface and press the Enter Key. The log from the IP board is recoded into the file log.txt. The log.txt is in C:\altera\91\nios2eds\examples.
The log.txt file:
Set up tx channel info block for cha
nios2-terminal: exiting due to ^C on host
nios2-terminal: connected to hardware target using JTAG UART on cable
nios2-terminal: "USB-Blaster [USB-0]", device 1, instance 0
nios2-terminal: (Use the IDE stop button or Ctrl-C to terminate)
--------------------------------------------------------------------------------------------------
Design configuration:
-- Cyclone version
-- Encapsulator enabled, De-encapsulator enabled, RTP enabled
-- 6 demux ports
-- 1 input ports, 0 output ports
-- 3 pointers (maximum)
-- MAC address set to 0013d4fcebda
-- IP address set to 010.010.200.198
-- IP subnet mask set to 255.255.255.0
--------------------------------------------------------------------------------------------------
init mac registers.
init mac registers.
reset phy.
Init phy chip
PHY reg 0 = 1000.
PHY id1 = 2000.
PHY id2 = 5c90.
Init phy2 chip
PHY reg 0 = 1000.
PHY id1 = 2000.
PHY id2 = 5c90.
Initialize buffer freelist
-- Freelist level now 2
disable channel .
disable PAT replace.
set 7 packets per frame.
Set up tx channel info block for channel 0 : TX Host channel
-- No encapsulation
Set up tx channel info block for channel 0 : ASI TX channel
-- RTP/UDP/IP encapsulation with...
MAC DA : 01005e000065
IP DA : 225.000.000.101
UDP src : 2000
UDP dest : 04d2
Enable input port 0 and assign to channel 1
get type 2 from arm7.
-- MAC address set to 000e26ff5dd5
-- IP address set to 010.010.080.010
-- IP subnet mask set to 255.255.255.000
-- Gateway set to 010.010.010.001
-- Gateway MAC address set to ffffffffffff
get type 40 from arm7
get ch 0:5
ena=1,pat=1
Set up tx channel info block for channel 0:1 : ASI TX channel
Dst IP:238.001.001.001
Dst MAC:01:00:5e:01:01:01
Dst port:1234
-- UDP/IP encapsulation with...
MAC DA : 01005e010101
IP DA : 238.001.001.001
UDP src : 07d0
UDP dest : 04d2
get type 41 from arm7
get ch 1:5
ena=3,pat=3
Set up tx channel info block for channel 1:1 : ASI TX channel
Dst IP:238.001.001.002
Dst MAC:01:00:5e:01:01:02
Dst port:1234
-- UDP/IP encapsulation with...
MAC DA : 01005e010102
IP DA : 238.001.001.002
UDP src : 07d1
UDP dest : 04d2
get type 42 from arm7
get ch 2:5
ena=7,pat=7
Set up tx channel info block for channel 2:1 : ASI TX channel
Dst IP:238.001.001.003
Dst MAC:01:00:5e:01:01:03
Dst port:1234
-- UDP/IP encapsulation with...
MAC DA : 01005e010103
IP DA : 238.001.001.003
UDP src : 07d2
UDP dest : 04d2
get type 43 from arm7
get ch 3:5
ena=f,pat=f
Set up tx channel info block for channel 3:1 : ASI TX channel
Dst IP:238.001.001.004
Dst MAC:01:00:5e:01:01:04
Dst port:1234
-- UDP/IP encapsulation with...
MAC DA : 01005e010104
IP DA : 238.001.001.004
UDP src : 07d3
UDP dest : 04d2
get type 44 from arm7
get ch 4:4
ena=f,pat=1f
get type 45 from arm7
get ch 5:4
ena=f,pat=3f
get type 80 from arm7.PAT table
get type 81 from arm7.PAT table
get type 82 from arm7.PAT table
get type 83 from arm7.PAT table
get type 1 from arm7,set all pid table.
0.
100.
200.
300.
400.
500.
600.
700.
800.
900.
a00.
b00.
c00.
d00.
e00.
f00.
1000.
1100.
1200.
1300.
1400.
1500.
1600.
1700.
1800.
1900.
1a00.
1b00.
1c00.
1d00.
1e00.
1f00.
get type 2 from arm7.
-- MAC address set to 000e26ff5dd5
-- IP address set to 010.010.080.010
-- IP subnet mask set to 255.255.255.000
-- Gateway set to 010.010.010.001
-- Gateway MAC address set to ffffffffffff
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.
set ready.