Am having difficulty getting hello_world to run on my TMDXEVM8148 development board. I can connect with the board, but if I try to download hello_world, I get the following error message. Can someone who successfully programs the C674 on the DM8148 part send me their setup? Or perhaps help me debug mine?
I see what could be a similar problem here:
http://e2e.ti.com/support/development_tools/code_composer_studio/f/81/p/140477/509678.aspx#509678
and have tried to setup my project similarly.
Here are what I believe to be relevant files: (renamed ccxml -> txt)8422.DM8148.txt 1462.DM8148.txt
And the file it refers to explicitly.
8662.DM8148_EVM.gel
Thanks very much for any help you can provide. I'm pretty stuck in the weeds until I can get hello world working correctly.
O..
Have you try to load the gel file, then connect to A8, connect to DSP before you try to download the hello world?
Hi Viet Dinh,
Thanks so much for responding. I appreciate it very much.
So I think there's something very fundamental I'm missing. I have the gel file specified in the target configuration, but before I can run it (if I'm running the debug process) the connection fails. Is there another way to load gel files? Perhaps through the scripting console or some such?
Also, can you confirm the proper gel file to load first?
Sorry for the noob questions. All the documentation on gel files I can find refer to CCS 4.2 and below. If there's newer documentation, please point me to it and I promise I won't bother you (as much :) ).
Thanks,
Orion,
Could you visit this page to see if it solve your problem?
http://processors.wiki.ti.com/index.php/Connecting_to_DSP_on_C6A8168,_DM8168,_C6A8148,_DM8148
BR,
Viet
Hi Viet,
I have previously visited that page. Here is where I have the problem.
Snipped from page
Procedure to connect to the DSP on C6A8168/DM8148/C6A8148/DM8148 is described below:
1. After starting CCSv4 or CCSv5, create new target configuration. Select XDS510USB/XDS560USB emulator and device as TI816X/TI4X based on what is applicable.
Note:
2. Launch debug session with this configuration. Once you see the emulator connection. You can connect to the cortex-A8.
/SNIP
When trying to do these 2 steps, I run into two problems.
The first, which I think is minor, is that the JTAG which ships with the EVM is a XDS100v2, so I select that option instead
The second, which I think is major is, In CCS5.1 I can't figure out how to connect without using a debug session. When I debug, before I can run any gel scripts, it errors out saying "device is in reset..." and terminates the debug session.
So I got the idea to try and build an arm hello world project first since it seems the arm sits on top of the DSP. I figure if I can make a connection there, then I can run the gel scripts and be on my way. So I create a new CCS project, Can't find the DM148 or DM14x partnumber under ARM, so I select a generic A8 device. It builds its own "hello_world" fine. It also connects and downloads fine, but verifies incorrectly. I imagine that's because there's no appropriate address-map setup for this device as I just used a generic A8 device.
So two ways I can see to proceed are.
1) please tell me how I can connect to the ARM without needing to use a debug-session for it
2) please tell me where I can get proper A8 device support for the DM8148 part.
3) Tell me why I've completely missed the boat here. :)
Let back up. First of all, have you create a New target config file? If not, from CCS, go to File->New->Target Config File. Choose file, dir then click on Ok. Once you done that, the <config>.ccxml should be open. Choose your Jtag connection from the pulldown, type in ti814x in Board or Device option and click on save. Once you done that, go to Run->Debug Configuration and select the .ccxml file you just created and click on apply and then debug.
After that, you should see all the processors in the device. You now can connect to processor, load the gel file and run.
Hope it helps,
HI Viet,
Ok, we're making progress. Thanks for your help and your patience.
I have done as you suggested. Then I select the Cortex A8 and right-click -> connect.
Then I select Tools/Gel Files and get the Gel File View. I right-click in the Gel file View and select "open".
Now the question is which gel file to use.
The most obvious choices are
.../Baseboard/src/CCS_Test_code/Base_Board/Integrated_Baseboard_Tests/GEL/DM814X_1_0.gel
and
../Baseboard/src/CCS_Test_code/Base_Board/Integrated_Baseboard_Tests/GEL/DM814X_2_x.gel
2_x.gel
DM814X_1_0.gel running DM814X System Initialization/DM814X_System_Initialisation_GP_device ends up in an infinite loop around the PLLs
The last line from the console is
CortexA8: Output: DM814X USB_PLL Init is in Progress, Please wait .....
In reading the gel file there are a bunch of while (xxx) != yyy;
I imagine it's stuck in one of those loops. Perhaps a timeout would help here.
If I reset the whole system and try DM814X_2_x.gel, I get to:
CortexA8: Output: **** DM814X ALL ADPLL INIT IS COMPLETE ******* CortexA8: Trouble Writing Memory Block at 0x48100100 on Page 0 of Length 0x4: (Error -1065 @ 0x3D5A) Unable to access device memory. Verify that the memory address is in valid memory. If error persists, confirm configuration, power-cycle board, and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 5.0.569.0) DM814X_System_Initialisation_GP_device() cannot be evaluated.target access failed at *((unsigned int *) 0x48100100)=(unsigned int) 0x01031FFF [DM814X_2_x.gel:712] at PLL_CLOCKS_Config() [DM814X_2_x.gel:885] at DM814X_System_Initialisation_GP_device()
Relevant part of the gel file is here:
GEL_TextOut("\t **** DM814X ALL ADPLL INIT IS COMPLETE ******* \n","Output",1,1,1); WR_MEM_32(0x48100100, 0x01031FFF); WR_MEM_32(0x48100114, 0xC010E); WR_MEM_32(0x48100118, 0xF);
Thanks in advance for any advice you might have.
Please try to use the Gel file from here: http://e2e.ti.com/support/embedded/bios/f/355/t/153410.aspx#555839.
Also see this link for more info: http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/716/p/170156/623945.aspx#623945
Almost there :) Looks like it connects correctly (Yay!!!)
CortexA8: GEL Output: Connecting Target...CortexA8: Output: **** DM8148 ALL ADPLL INIT IS In Progress ......... CortexA8: GEL Output: A8 ADPLLJ CLKOUT value is = 600 CortexA8: GEL Output: L3 ADPLLJ CLKOUT value is = 200 CortexA8: GEL Output: DSP ADPLLJ CLKOUT value is = 500 CortexA8: GEL Output: DSS ADPLLJ CLKOUT value is = 200 CortexA8: GEL Output: HDVICP ADPLLJ CLKOUT value is = 266 CortexA8: GEL Output: SGX ADPLLJ CLKOUT value is = 200 CortexA8: GEL Output: USB ADPLLJ CLKOUT value is = 192 CortexA8: GEL Output: VIDEO-0 ADPLLJ CLKOUT value is = 54 CortexA8: GEL Output: VIDEO-1 ADPLLJ CLKOUT value is = 148 CortexA8: GEL Output: VIDEO-2/HDMI ADPLLJ CLKOUT value is = 148 CortexA8: GEL Output: AUDIO ADPLLJ CLKOUT value is = 200 CortexA8: Output: **** DM8148 ALL ADPLL INIT IS Done ************** CortexA8: Output: PRCM for C674x is in Progress, Please wait..... CortexA8: GEL Output: CP0...Done CortexA8: GEL Output: CP1...Done CortexA8: GEL Output: CP2...Done CortexA8: GEL Output: CP3...Done CortexA8: GEL Output: CP4...Done CortexA8: GEL Output: CP5...Done CortexA8: GEL Output: CP6...Done CortexA8: Output: User Can Connect to C674x CortexA8: Output: PRCM for C674x is DONE ****** CortexA8: Output: PRCM for Control Module in Progress CortexA8: Output: PRCM for Control Module Done CortexA8: Output: PRCM for OCMCRAM0/1 Initialization in Progress CortexA8: Output: PRCM for OCMCRAM0 Initialization Done CortexA8: GEL Output: ***** Configuring ethernet Clk and Mux....***** CortexA8: GEL Output: ***** GMII pin mux and Clk initialized....***** CortexA8: Output: PRCM for SPI-0 CS-0 is in Progress, Please wait..... CortexA8: GEL Output: ***** SPI-0 CS-0 is initialized....***** CortexA8: Output: PRCM for SD/MMC0 are in Progress, Please wait..... CortexA8: GEL Output: ***** MMC0/SD is initialized....***** CortexA8: GEL Output: **** Configuring DDR PLL to 533 MHz......... CortexA8: GEL Output: DDR ADPLLJ CLKOUT value is = 533 CortexA8: Output: **** DM8148 DDR3 EVM EMIF0 and EMIF1 configuration in progress......... CortexA8: Output: Busy reading back DMM registers Please wait ...CortexA8: Output: DMM register read successfully CortexA8: Output: **** DM8148 DDR3 EVM EMIF0 and EMIF1 configuration is DONE **** CortexA8: GEL Output: Connecting Target... Done.
This just happened automatically upon connecting to the ARM. It must have run OnTargetConnect. I didn't do anything else at this point.
Then I try to download hello_world and get 2 pop up errors which say
An error has occurred. See error log for more details.The function "getGelFiles" returned an error condition (0x80780001)
AND
Load Failed
which seems to be related to the console error:
C674X_0: Trouble Writing Memory Block at 0x20 on Page 0 of Length 0x5a00: (Error -1190 @ 0x20) Unable to access device memory. Verify that the memory address is in valid memory. If error persists, confirm configuration, power-cycle board, and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 5.0.569.0)
C674X_0: GEL: File: C:\Users\Orion\Dropbox\BRE\TICode\hello_world_on_board_2\Debug\hello_world_on_board_2.out: Load failed.
This seems similar to the other page you referenced. However I think it's different because this write error occurs on the C674X whereas the other example failed on the Coretex.
Instead, I think I may have setup my project incorrectly. The only Device I've selected is TI8148, but I don't see where it specifies in the project where to write/execute code.
Ok, now I'm a bit farther. I got the simple sys/bios example to execute on the target, but it instantly runs to its abort() routine at 0x80009a00" .
One thing worthy of note is that if I select a device of DM8148, then the RTSC page won't let me specify the platform, but if I select "Generic C674 device" Then it lets me select a platform of
ti.platforms.evmDM8148
and a target of
ti.targets.C674
However, if I choose a device of
DM8148
Then no targets or platforms are displayed in the RTSC page.
Could I have a corrupt DM8148.xml file?
Thanks for your help,
Glad you got alot closer. :)
Have you try to connect the DSP before you try to download the file?
The program is running on the board, its just not getting very far before it gets stuck in the weeds. i.e. before main can run.
I've been poking at the board a bit more and have come to the realization that sysmin is being written too before abort() is called.
sysmin buffer contains:
{module#43}: line 1041: error {id:0xc2c0000, args:[0x8000, 0x19e6d2f]}
xdc.runtime.Error.raise: terminating execution
I can't find any references to this while searching the forum.
Thanks for any advice.