This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

LED Blink Demo not working for c6678LE EVM

I'm new to code composer, embedded programming and DSP. I have a C6678EVM with an XDS560v2 USB mezzanine emulation board attached and I cannot get the LED blink demo to work (or any demo to work for that matter... except for Hello World). I'm running CCSv6.1.3


I have poured through all the documentation, forums and read all the tips on what libraries to include, how to compile, what packages you need installed, etc... and I'm very stuck. I've have tried 3 different blink LED demos:

1) from the TI-RTOS workshop series (lab 4). I haven't managed to get this to compile

2 & 3) from the PDK_c667x_2_0_1 package where I have installed the example projects. This creates two LED demos. One called GPIO_LedBlink_C6678_EVM_c66xTestProject and the other called GPIO_LedBlink_C6678_EVM_c66xExampleProject (what is the difference between them?). I have gotten both of these to compile (without errors or warnings), but when they run, nothing happens. When I pause execution and step through the code they seem to be going through an Idle loop.


Which LED the on the EVM is supposed to blink?

How many cores do the demos run on? Should all cores be connected to the target? (I have tried connecting all 8 cores, running the .out file on just one core, and more or less every permutation of having the cores connected, running, paused, disconnected).


I'd appreciate any tips and help that can be provided.



  • Welcome to the TI E2E forum. I hope you will find many good answers here and in the TI.com documents and in the TI Wiki Pages (for processor issues). Be sure to search those for helpful information and to browse for the questions others may have asked on similar topics (e2e.ti.com). Please read all the links below my signature.

    We will get back to you on the above query shortly. Thank you for your patience.

    Note: We strongly recommend you to create new e2e thread for your queries instead of following up on an old/closed e2e thread, new threads gets more attention than old threads and can provide link of old threads or information on the new post for clarity and faster response.

  • No need to connect all the cores, just connect core0 which will call the gel file and initialize the peripherals.
    Will try to reproduce the issue.
    D1,D2,D3 and D4 LEDs should blink.

    What are other examples are not working ?
    Can you please try other example projects ?
    I hope that other than LED example, all examples are working fine.
  • Hi Amanda,

    You are right. The LED doesnot blink for the following examples. These are known software bugs and it is filed as a bug.

    GPIO_LedBlink_C6678_EVM_c66xExampleProject
    GPIO_LedBlink_C6678_EVM_c66xTestProject

    We will let you know once the bug is fixced.

    I have tested other few examples below, which works fine.

    SPI_BasicExample_K2H_c66xTestProject
    rmSharedK2HC66BiosTestProject
    rmMemK2HC66BiosTestProject
    UART_BasicExample_K2H_c66xTestProject
  • Thanks for your response. I'll give those other examples a try (for the C6678). Can you tell me the difference between the "TestProject" and the "ExampleProject"? Is there a bug report for these that you can refer me to? Is there a workaround to get the LEDs to blink? (or does the user have no control whatsoever on these LEDs?) As a beginner, it is the simplest system I look at to figure out how this environment works.

  • Oh! All 4 LEDs should blink! Good to know! Thank you! Do the other cores need to have a GEL initialization file, or is it for one of the cores enough? I did try one of the image processing examples, but I was having DCHP issues... I'll give that another shot
  • Amada,

    The gel initialisation is enough for one of the cores. As of now, we do not have any workaround for LED examples.

    We recommend you to create new thread for different issues. Thank you.
  • If you don't have DHCP server setup then you can run the demo example with static IP configuration, for that, you have to connect EVM board to PC using ethernet cable.
  • I did some more digging into this and came across this note on the wiki that there are no user LEDs on C6678 and C6657 EVM connected to GPIO pins.
    processors.wiki.ti.com/.../Processor_SDK_RTOS_GPIO


    I looked at the schematics and it appears the GPIO pins are either muxed with the BOOTMODE Pins or connected to the FPGA so I don`t think the C66x core can toggle the LED. The FPGA is connected to a GPIO that is connected to a user LED and the C66x can send a command to FPGA and toggle the LED but this is not done over the LED interface.

    Regards,
    Rahul
  • Hi Rahul,

    Yes, I read that too. The C6678 DSP can communicate with the FPGA configuration registers using the SPI interface (at register 0x20BF0000). There are GPIO status registers available at an offset of 07h which correspond to available GPIOs on the DSP but these are read only. Then at an offset of 08h there are the DEBUG_LED1-4 bits that can be toggled on and off. I'm trying to figure out how to toggle these pins. If the GPIOs here are read only, then what is the point of using them to toggle the LED bits? Couldn't you just toggle them directly?

    (all this from the document at: http://wfcache.advantech.com/www/support/TI-EVM/download/TMDXEVM6678L_Technical_Reference_Manual_1V00.pdf)

    Then there are the GPIO registers at 0x0232000 for the C6678 and these are shared with bootmode pins. I don't know what relevance those have to the SPI GPIO registers... Does this mean I have to configure the GEL file to boot via SPI instead of I2C?

    I'm currently looking into how to use SPI to toggle the GPIO pins so that the LEDs can blink. Except that those bits are read only??? Do the SPI GPIO pins read the DSP GPIO pins and then those control the LED bits? I have no idea... (meanwhile I don't know how to really set any of these bits because I can't run through the most basic of demos that blink an LED... and how do you use SPI?)  My brain is getting twisted into knots. From going through the forum, it seems like others have gotten the LEDs to blink no problem. It's possible...

  • There is a platfrom library function called platform_led that can be used to communicate with the FPGA to toggle the LED.

    I am attaching an example project that I had created some time back that demonstrates this functionality.

    4834.led_play.zip

    You can import this project into CCS and change the PDK_INSTALL_DIR in the CCS environment to point to your PDK path and build the project.

    Hope this helps

    Regards,

    Rahul

  • Thank you very much! I am accustomed to creating RTSC projects where I can select the libraries I want to include. How to I get a library to be included in the "Includes" directory in the project for a standard CCS project?
  • Right click on the Project and go to Build properties. In the Properties go to CCS build -> C6000 Linker -> File Search Path
    In that configuration window, you can add path where the library is installed and the libraries to link to.

    Regards,
    Rahul
  • Thanks Rahul. Those are the steps that I've been taking, but it is not working. I assumed I was doing something wrong. In the Includes directory, it's looking for C:\Users\amanda\workspace_v6_1_3\led_play\Debug\$(PDK_INSTALL_DIR)\packages), which doesn't exist. I followed your steps to add the PDK directory and it is not being added to the Includes list. Any thoughts?
  • Try inserting the directory path from Windows , directly into the search path instead of using Macros to define paths to see if that resolves your issues.

    Typically, you can go to the Build Properties, under CCS build in environment tab change the PDK_INSTALL_PATH and then apply and refresh your project to apply this change to the entire project.

    Regards,
    Rahul
  • As an update: I was able to get the code to compile by copying the code from the LED_play example you gave me into my own project, rather than importing it. That fixed all the library errors. The LEDs blink now! Thank you *very* much for your advice Rahul!
  • Wow, six month and two PDK versions later and this problem still persists. That is very disappointing.

    I wasted about a whole day to find out, that the example blink LED is not supposed to work with the c6678LE EVM.

    Thanks anyway for the platform example.

    Regards

    Daniel