NOTICE: The Processors Wiki will End-of-Life on January 15, 2021. It is recommended to download any files or other content you may need that are hosted on processors.wiki.ti.com. The site is now set to read only.
DA8xx SPI Flash writer for DSP only device
Return to Overview of DA8xx SDK Getting Started Guide
DSP-based SPI writer (SPIwriter.out) [edit]
- Locate the pa_bdk_da8xx_yymmdd.zip package in the unzipped "DA8xx SDK YYMMDD".
- Unzip the pa_bdk_da8xx_yymmdd.zip package. This will create a "bdk" directory, which contains both a pre-built executable and the source code of the 'SPI writer for DSP only devices'. You can either:
- Build the SPI-writer executable from source code: In CCSv4, build the project in the bdk\spiflash\spiwriter folder to create SPIwriter.out
- Or, use the pre-built executable: bdk\spiflash\spiwriter\SPIwriter.out
There's no real compelling reason to build SPIwriter.out - just use the prebuilt.
Receipe to use spiwriter.out[edit]
- If the DSKDA830 is powered-up, power it down.
- If the UI board is connected to the DSKDA830, make sure that the UI board's SW1 "BOOT DEVICE" switch is set to [0 0 0 0] for numbers [1 2 3 4] respectively (i.e., all 'OFF').
Pin # | 1 | 2 | 3 | 4 |
---|---|---|---|---|
Position | 0 | 0 | 0 | 0 |
- Set SW2 ("BOOT") on the DSKDA830 (i.e., the main board) to boot the DA830 'from XDS':
ON-ON-ON-ON-OFF-OFF
- If you not already have a flashable image file (for example, pa-ais.bin), create one from the DSP executable (pa.out) using the AISgen tool (instructions here).
- Copy your image file (assumed to be named 'pa-ais.bin' hereafter) to some directory on your C: drive
- Create a plain text file called “spiwriter.dat” in the root directory of your C: drive (C:\spiwriter.dat). The location and name of spiwriter.dat is critical to the execution of the spiwriter application (SPIwriter.out looks for apiwriter.dat only in C:\, and gives up if it's not found).
- Edit the contents of spiwriter.dat to be simply the complete path/filename of the flashable image file (e.g., c:\myImage\pa-ais.bin) followed by <space> followed by "0". For example:
C:\work\ais\pa-ais.bin 0
- Save the file 'C:\spiwriter.dat'
- Power-up the DSKDA830
- Open CCS4, launch the TI debugger, and connect to the c674x DSP.
- Load the spiwriter.out file to the DSP and run.
- The spiwriter application takes several minutes to complete. Messages indicating operation will be displayed in the CCS console. Note that the 'Reading file' step takes quite a long time, on the order of minutes. Following is a sample of the messages displayed:
C:\work\ais\pa-ais.bin 0x0
Input file name = C:\work\ais\pa-ais.bin, offset = 0
Reading file C:\work\ais\pa-ais.bin
Reading Block 0 from file...
Writing Block 0 to flash...
Reading Block 1 from file...
Writing Block 1 to flash...
.......(omitted)..........
SPIFlash is written correctly :-)
- After successful completion, the console will display the message "SPIFlash is written correctly :-)".
- Select “Terminate All” from the “Target” menu and wait for the CCS4 debugger session to completely terminate
- Power-down the DA830 EVM.
- Set the BOOT-SW2 switch on the DSKDA830 to boot from the SPI flash:
OFF-ON-OFF-ON-OFF-OFF
- Power-up the DA830. It should boot from your newly-flashed image.