To debug the user application you will require following software and hardware:
• Cross/Straight Network cable
• JTAG cable
• Eclipse IDE for C/C++ developers. You can download Eclipse IDE from
the
http://www.eclipse.org/downloads/download.php?file=/technology/epp/do
wnloads/release/20071103/eclipse-cpp-europa-fall2-linux-gtk.tar.gz
7.1 Debugging uClinux kernel using nios2-elf-insight over
JTAG
To debug the uClinux kernel using nios2-elf-insight over JTAG, first build the
zImage by using the following steps:
Before debugging, configure the kernel as explained below:
#make menuconfig
The menu configuration window opens:
System Level Solutions 39
Kernel hacking ---->
[*] Kernel debugging
[*] Compile the kernel with debug info
Save, exit and build the zImage.
Following are the steps to debug uClinux kernel using JTAG.
1. Download the .sof file to your board using command:
#nios2-configure-sof/home/uClinux/System-files/
sls_neek_bsp_hw.sof
2. Go to home/uClinux/uClinux-dist/linux 2.6.x .You will find vmlinux.
Copy it and paste it in same dir with name vmlinux.elf.
3. Now there will be debug script called nios2-debug in NIOS II IDE. The
script is located at <altera_tools_installation_path>/nios2eds/bin.
4. Modify the script to make it compatible with uClinux kernel. Save a copy
of this script before modifying it and change line no 70 in nios2-debug
from :