Spectrum Digital XDS510 USB, USB PLUS, C2000 XDS510LC, XDS560 v2 STM emulator Tech Note
Below you will find brief information for emulator XDS510 USB, emulator XDS510 USB PLUS, emulator XDS560v2 STM. This document provides basic validation and trouble shooting for SD XDS510USB and SD XDS560V2 STM emulators installed as part of CCS v5.
PDF
Download
Document
Advertisement
Advertisement
Spectrum Digital Document Revision 0.03 Emulation Tech Note 11 Validating Spectrum Digital Emulation Drivers on Linux Document Revision 0.03 October 15, 2010 Page 1 of 8 Spectrum Digital Document Revision 0.03 1 OVERVIEW This document provides basic validation and trouble shooting for SD XDS510USB and SD XDS560V2 STM emulators installed as part of CCS v5. Several Linux platforms and versions have been validated and each has it own set of installation caveats which have been detailed in section 7 troubleshooting. 2 OS VERSIONS SUPPORTED UBUNTU - 8.04 LTS, 9.04, 9.10, 10.04 LTS, 10.10 REDHAT - 5 STABLE LINUX VERSION – UBUNTU 10.04 LTS (Recommended Linux version) PROBLEMATIC VERSION – UBUNTU 9.10 (USB 2.0 is generally known to be problematic) Validation has shown Ubuntu 10.04 to be the most stable version of Ubuntu. 3 SPECTRUM DIGITAL EMULATORS SUPPORTED XDS510 USB XDS510 USB PLUS C2000 XDS510LC XDS560v2 STM 4 CCS INSTALLATION PATH CCS_BASE_DIR - <CCS_INSTALL_PATH>/ccsv5/ccs_base_5.x.x.xxxxx 5 VALIDATING XDS510USB CLASS EMULATORS 5.1 SPECTRUM DIGITAL USB JTAG UTILITY SdConfig GUI based utility is replaced with Sdjtag command line utility used to test connection between SD XDS510USB class emulators, Linux PC and target JTAG scan chain. It is located under <CCS_BASE_DIR>/emulation/drivers directory. It currently supports four commands – portsavailable, scantest, reset and clean. SDJTAG – portsavailable. This command is used to validate connection between emulator and PC to test if USB rules for SD emulators are set correctly. A sample output is as shown below. <CCS_BASE_DIR>/emulation/drivers$./sdjtag -X portsavailable SpectrumDigital USB Jtag Utility ** Checking for available USB devices on valid ports. $$ XDS510USB PLUS connected on: $$ EmuPortAddr=0x510 $$ EmuSerialNumber=S330612043022426 SDJTAG – reset The reset command verifies the connection between emulator and the target which resets the emulator to a known good state. A sample output is shown below. <CCS_BASE_DIR>/emulation/drivers$./sdjtag -p 0x510 -X scantest SpectrumDigital USB Jtag Utility Page 2 of 8 Spectrum Digital Document Revision 0.03 ** Resetting Emulator -- Emulator is Reset SDJTAG – scantest The scantest command also verifies the connection between emulator and the target which measures the length of JTAG IR and DR registers. A sample output is shown below. <CCS_BASE_DIR>/emulation/drivers$./sdjtag -p 0x510 -X scantest SpectrumDigital USB Jtag Utility ** Emulator Scan Test -- Found JTAG IR Length of 38 -- Found 1 device(s) in the scan chain SDJTAG – clean The sdjtag clean command cleans XDS510USB open resources when CCS crashes. 5.2 SPECTRUM DIGITAL XDS510USB CONFIGURATION FILE The Spectrum Digital configuration file sdopts.cfg is located under <CCS_BASE_DIR>/emulation/drivers directory. This file is identical to the Windows version and is where Spectrum Digital stores its emulator configuration options. Sdopts.cfg can be edited using a basic gedit text editor. Detailed documentation of the options can be found in the file itself. 5.3 BASIC VALIDATION INSTRUCTIONS 1. 2. Install CCSv5. SD emulation drivers are installed as apart of CCS install. Test emulator connection with the Linux PC. a. Check to see if emulator is recognized on the USB port by running the following command. Make sure it is connected to a USB 2.0 port. $ lsusb Bus 001 Device 005: ID 0c55:2000 Spectrum Digital, Inc. - XDS510LC USB Emulators. Bus 001 Device 004: ID 0c55:0510 Spectrum Digital, Inc. Spectrum Digital XDS510 JTAG Debugger - XDS510 USB Emulators Bus 001 Device 003: ID 0c55:0540 Spectrum Digital, Inc. SPI540 - XDS510 USB PLUS Emulators. Bus 001 Device 002: ID 050d:0234 Belkin Components F5U234 USB 2.0 4-Port Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub b. Check to see if low level USB rules for SD emulators are set correctly. i. Run sdjtag from the command line as shown below. <CCS_BASE_DIR>/emulation/drivers$./sdjtag -X portsavailable SpectrumDigital USB Jtag Utility ** Checking for available USB devices on valid ports. $$ XDS510USB PLUS connected on: $$ EmuPortAddr=0x510 $$ EmuSerialNumber=S330612043022426 ii. The output shown above indicates that spectrum digital low level USB rules are set correctly. If the output to sdjtag is as shown below, go to troubleshooting section for detailed instructions. <CCS_BASE_DIR>/emulation/drivers$./sdjtag -X portsavailable SpectrumDigital USB Jtag Utility ** Checking for available USB devices on valid ports. >> USB Rules not installed >> Goto linux troubleshooting page for detailed instructions on installing USB Rules. 3. Test emulator connection with the target. Page 3 of 8 Spectrum Digital a. Document Revision 0.03 Run sdjtag from the command line with the scantest command as shown below. <CCS_INSTALL_DIR>/ccsv4/emulation/drivers$./sdjtag -p 0x510 -X scantest SpectrumDigital USB Jtag Utility ** Emulator Scan Test -- Found JTAG IR Length of 38 -- Found 1 device(s) in the scan chain 5.4 CLEANING SHARED RESOURCES When CCS crashes or is not shutdown properly, xds510usb’s shared resources are cleaned up by running sdjtag with clean option. $ cd <CCS_BASE_DIR >/emulation/drivers $./sdjtag -X clean SpectrumDigital USB Jtag Utility !!!CAUTION!!! -- Make sure XDS510USB class emulators are not in use. -- Press 'Enter' to continue: ... -- Cleaned opened resources successfully 6 VALIDATING XDS560V2 STM EMULATOR 6.1 Spectrum Digital XDS560v2 Configuration Utility Spectrum Digital XDS560v2 Configuration utility (Sd560v2Config) is a convenient utility used to scan, test or setup a Spectrum Digital XDS560v2 STM emulator connected on to an USB port or an Ethernet port. This is a GUI based application. Detailed documentation on Sd560v2Config utility can be found under <CCS_BASE_DIR>/common/uscif/Sd560v2Config_Readme.pdf. In order for Sd560v2Config utility to be resizable on Linux, one should turn off compiz visual effects as shown in figure 1 below. This is a jdk 1.5 issue, and is fixed under jdk 1.6. FIGURE 1: Turn off visual effects Page 4 of 8 Spectrum Digital Document Revision 0.03 6.2 Spectrum Digital XDS560v2 STM Configuration file The Spectrum Digital configuration file sd560v2opts.cfg is located under <CCS_BASE_DIR>/common/uscif directory. This file is identical to the Windows version and is where Spectrum Digital stores its emulator configuration options. Sd560v2opts.cfg can be edited using a basic gedit text editor. Detailed documentation of the options can be found in the file itself. 6.3 BASIC VALIDATION INSTRUCTIONS 1. 2. a. Install CCSv5. SD emulation drivers are installed as a part of CCS install. Test emulator connection with the Linux PC. Check to see if emulator is recognized on the USB port by running the following command. Make sure it is connected to a USB 2.0 port. $ lsusb Bus 001 Device 004: ID 0c55:0562 Spectrum Digital, Inc. Bus 001 Device 003: ID 050d:0234 Belkin Components F5U234 USB 2.0 4-Port Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub b. Check to see if low level USB rules for SD emulators are set correctly. i. Launch Sd560v2Config utility from the desktop. If the icon is not populated on your desktop, launch it from the command line , $ cd <CCS_BASE_DIR>/common/uscif $ ../../../eclipse/jre/bin/java -jar sd560v2config.jar From the USB Tab select on Find all Connected XDS560V2 USB emulators and click on start button. The output is as shown in figure 1 below. Go to troubleshooting section 7, for unexpected results. FIGURE 2: Sd560v2Config to test USB connection. Page 5 of 8 Spectrum Digital c. Document Revision 0.03 Test emulator connection with the target. i. Launch Sd560v2Config utility from the desktop. If the icon is not available on your desktop, launch it from the command line , $ cd <CCS_BASE_DIR>/common/uscif $ ../../../eclipse/jre/bin/java -jar sd560v2config.jar From the Dbgjtag Tab, select the adapter to sd560v2u, address to 0, check on pathlength and click on start button. The output is as shown in figure 2 below. Go to troubleshooting section 7, for unexpected results. FIGURE 3: Sd560v2Config to test pathlength. 6.4 CLEANING SHARED RESOURCES Spectrum Digital XDS560v2 STM emulation drivers requires the user to clean shared resources that are left open on certain use cases as listed below. • CCS crashes or is not shutdown properly. • Sd560v2Config utility crashes. • When CCS is run over XDS560V2 STM USB port in one user mode, before using CCS over XDS560V2 STM USB port in another user mode. The procedure for cleaning shared resources is as shown: $ cd <CCS_BASE_DIR>/common/uscif $./sd560v2u_linux_cleanup.sh !!!CAUTION!!! Make sure XDS560 STM EMULATOR is not in use on the USB port Do you want to continue with the cleanup [Y]? y --Cleaned opened resources successfully Page 6 of 8 Spectrum Digital Document Revision 0.03 7 TROUBLESHOOTING 7.1 EMULATOR CONNECTION TO THE PC CCS can be installed in Linux as a user or root and each method of installation has some minor caveats and is also Linux platform and version dependent. 1. 2. The table matrix shown below depicts the possible installation/validation permission options. CCS SD EMULATOR SD EMULATOR USB RULES INSTALLATION VALIDATION PERMISSION PERMISSION ROOT ROOT USER ROOT USER ROOT SET AUTOMATICALLY SET AUTOMATICALLY NOT SET. INSTALL MANUALLY USER USER NOT SET. INSTALL MANUALLY Based on the table shown above, if SD emulator usb rules are not set, install the rules manually from the command prompt using the steps shown below. Unplug SD emulator from the PC’s USB port. Run setup_sd.sh as a root located under <CCS_BASE_DIR>/emulation/drivers directory. $ cd <CCS_BASE_DIR >/emulation/drivers $ sudo ./setup_sd.sh 3. 4. Revalidate the SD emulator connection by following the validation sequence in section 4.3 for XDS510USB class emulators and section 5.3 for XDS560V2 STM emulator Even after following all the instructions doesn’t install SD emulators USB rules correctly, then For Ubuntu 8.04 and 9.04, Modify /etc/udev/rules.d/40-basic-permissions.rules as a root at line number 9 which says SUBSYSTEM==”usb”, ENV{DEVTYPE}==”usb_device, MODE=”0664” to SUBSYSTEM==”usb”, ENV{DEVTYPE}==”usb_device, MODE=”0666” Unplug SD emulator from the USB port. Restart udev deamon using the following command as a root $ /etc/init.d/udev restart For Ubuntu 9.10 and 10.04, Modify /lib/udev/rules.d/50-udev-default.rules as a root at line number 62 which says #libusb device nodes SUBSYSTEM==”usb”, ENV{DEVTYPE}==”usb_device, MODE=”0664” to #libusb device nodes SUBSYSTEM==”usb”, ENV{DEVTYPE}==”usb_device, MODE=”0666” Unplug SD emulator from the USB port. Restart udev deamon using the following command as a root $ restart udev For redhat 5 Modify /etc/udev/rules.d/50-udev.rules as a root at line number 321 which says ACTION=="add", SUBSYSTEM=="usb_device", \ PROGRAM="/bin/sh -c 'K=%k; K=$${K#usbdev}; printf bus/usb/%%03i/%%03i $${K%%%%.*} $${K#*.}'", \ NAME="%c", MODE="0644" ACTION=="add", SUBSYSTEM=="usb_device", \ Page 7 of 8 Spectrum Digital Document Revision 0.03 PROGRAM="/bin/sh -c 'K=%k; K=$${K#usbdev}; printf bus/usb/%%03i/%%03i $${K%%%%.*} $${K#*.}'", \ NAME="%c", MODE="0666" Unplug SD emulator from the USB port. Restart udev deamon using the following command as a root $ /sbin/start_udev If CCS still fails to communicate with the emulator, retry after cleaning shared resources as mentioned in section 5.4 for XDS510USB class emulators and section 6.4 for XDS560V2 STM emulator. 5. 7.2 INSTALLING EMULATION DRIVERS The correct method of installing spectrum digital emulation drivers on the top of existing CCSv5 installation is to run with /remove option. This ensures that the install package uninstalls the previous install package before installing the new package. $ ./sd_emupack_setup.x.x.x.x /remove Page 8 of 8 ">

Public link updated
The public link to your chat has been updated.
Advertisement
Key features
- Validating Spectrum Digital Emulation Drivers on Linux
- Basic validation and trouble shooting
- SD XDS510USB and SD XDS560V2 STM emulators
- CCS v5
- Several Linux platforms and versions
- Installation caveats
Frequently asked questions
This document provides basic validation and trouble shooting for SD XDS510USB and SD XDS560V2 STM emulators installed as part of CCS v5. It also details the installation caveats for each platform.
The document lists the supported platforms, including Ubuntu releases and RedHat 5. It also mentions the recommended and problematic versions based on validation results.
The document details the supported emulators, including the XDS510 USB, XDS510 USB PLUS, C2000 XDS510LC, and XDS560v2 STM.