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.

RTOS/am3359: EtherCAT issue

Part Number: AM3359
Other Parts Discussed in Thread: SYSBIOS

Tool/software: TI-RTOS

Hello David,

This is a new post but it concerns my previous post RTOS/AM3359- EtherCAT issue : I thought it was resolved but there's a new issue.

I've a little big problem while updating the try PRU-ICSS-ETHERCAT-SLAVE  01_00_05_00 !!!

Before doing that I had also updated to pdk pdk_am335x_1_0_9 and I have rebuilded of the libraries for all components.

Then I've generated both project from PRU: ethercat_slave_full_AM335x_arm (patched with Beckoff stack 5.12) and ethercat_slave_demo_AM335x_arm.

I thied to compile these 2 projects and: IMPOSSIBLE !!!

I have the same error while compiling: a problem of undefined type in osal library (in my previous post, I had included a picture of the log but I list it, sorry...)

I tried to investigate and find the error.

In the file am335x_app_pa8fg.c found in the folder AM335x_release\ConfigPkg\cfg I can find the indirection :

/* Module__startupDoneFxn__C */
__FAR__ const CT__ti_osal_Settings_Module__startupDoneFxn ti_osal_Settings_Module__startupDoneFxn__C = ((CT__ti_osal_Settings_Module__startupDoneFxn)0);
But, if I search for the type CT__ti_osal_Settings_Module__startupDoneFxn There's no definition for this type.

For example, in the previous command:

/* Module__loggerFxn8__C */
__FAR__ const CT__ti_osal_Settings_Module__loggerFxn8 ti_osal_Settings_Module__loggerFxn8__C = ((CT__ti_osal_Settings_Module__loggerFxn8)0);
If I search for the type CT__ti_osal_Settings_Module__loggerFxn8 I can find its definition il the file C:\ti\pdk_am335x_1_0_9\packages\ti\osal\Settings.h:

/* Module__loggerFxn8 */
typedef xdc_runtime_Types_LoggerFxn8 CT__ti_osal_Settings_Module__loggerFxn8;
__extern __FAR__ const CT__ti_osal_Settings_Module__loggerFxn8 ti_osal_Settings_Module__loggerFxn8__C;
#ifdef ti_osal_Settings_Module__loggerFxn8__CR
#define ti_osal_Settings_Module__loggerFxn8__C (*((CT__ti_osal_Settings_Module__loggerFxn8*)(xdcRomConstPtr + ti_osal_Settings_Module__loggerFxn8__C_offset)))
#else
#define ti_osal_Settings_Module__loggerFxn8 (ti_osal_Settings_Module__loggerFxn8__C)
#end

And tis is the same for all types defined !!!!

There's only a mistake on Module__startupDoneFxn__C.

Of course, I tried to put a same definition in the file Settings.h:

/* Module__startupDoneFxn__C */
typedef xdc_runtime_Types_startupDoneFxn CT__ti_osal_Settings_Module__startupDoneFxn;
__extern __FAR__ const CT__ti_osal_Settings_Module__startupDoneFxn ti_osal_Settings_Module__startupDoneFxn__C;
#ifdef ti_osal_Settings_Module__startupDoneFxn__CR
#define ti_osal_Settings_Module__startupDoneFxn__C (*((CT__ti_osal_Settings_Module__startupDoneFxn*)(xdcRomConstPtr + ti_osal_Settings_Module__startupDoneFxn__C_offset)))
#else
#define ti_osal_Settings_Module__startupDoneFxn (ti_osal_Settings_Module__startupDoneFxn_C)
#endif

But of course it doesn't work and I have an error while compiling the osal library:

In file included from /ti/PDK_AM~2/packages/ti/binary/pruss_app_sorte_slave/obj/icev2AM335x/a8host/release/pruss_app_sorte_slave_configuro/package/cfg/sorte_icev2am335x_app_pa8fg.c:43:0:
/ti/PDK_AM~2/packages/ti/osal/Settings.h:191:9: error: unknown type name 'xdc_runtime_Types_startupDoneFxn'
 typedef xdc_runtime_Types_startupDoneFxn CT__ti_osal_Settings_Module__startupDoneFxn;

Did you ever make the compilation for these projects ?

Did it succeeded ?

Can you tell me why it doen't work and help me to fix the problem ?

Thanks a lot for your help.

 

Laurence

  • The error while compiling is:

    'CT__ti_osal_Settings_Module__startupDoneFxn' undeclared here (not in a function) am335x_app_pa8fg.c /ethercat_slave_full_AM335x_arm/AM335x_debug/configPkg/package/cfg line 6888 C/C++ Problem
  • The RTOS team have been notified. They will respond here.
  • Hello Lawrence

    I was able to build install and run the latest version. I do see a issue with your installation.

    PRU-ICSS EtherCAT 1.0.5 requires Processor SDK 4.1.0 . This is described in the component version section of the PRU-ICSS EtherCAT User Guide http://processors.wiki.ti.com/index.php/PRU_ICSS_EtherCAT#Component_Version .  Using another version of the processor SDK is not guaranteed to work.

    This is not the latest version of the Processor SDK which is 4.2.0.

    A link to a previous version of the Processor SDK is found by going  to the previous release section in the current processor SDK download page. For the RTOS on windows this would be found near the bottom of this page  http://software-dl.ti.com/processor-sdk-rtos/esd/AM335X/latest/index_FDS.html

    For RTOS on windows this will take you to http://software-dl.ti.com/processor-sdk-rtos/esd/AM335X/04_01_00_06/index_FDS.html 

    Please note that Processor SDK 4.1.0 requires CCS 7.2.0.00013.  A link for an online download of this version of CCS is included on the same page. I typically prefer an offline download for CCS. This can be found at http://processors.wiki.ti.com/index.php/Download_CCS

    The installation instructions for what CCS features to is in the Processor SDK getting started guide in the Download and install software section http://processors.wiki.ti.com/index.php/Processor_SDK_RTOS_Getting_Started_Guide#Download_and_install_software

    One thing to watch for after installing CCS. is that CCS will offer to perform updates. This is good however there can be an update that we wish to avoid. One of the updates can be to go from the current version for example CCS 7.2 to CCS 7.3. It is important uncheck that box and not perform that update!

    To avoid issues - I always start a pru-icss-ethercat and Processor SDK installation in an empty ti directory.  If I wish to maintain a previous version I was working on,  I first uninstall CCS and then rename the existing ti directory to a another name, like ti_ver5_save.

     Once CCS, Processor SDK, and PRU--ICSS EtherCAT have been installed, it is necessary to start CCS up so that it can detect what has been installed wait a few minutes for CCS to complete it's scan and then close CCS. 

    Nothing needs to be built  in the Processor SDK to support the PRU-ICSS EtherCAT examples if you are using a TI AM335x ICEv2 or any of the EVMs listed as supported in http://processors.wiki.ti.com/index.php?title=PRU_ICSS_EtherCAT&oldid=230968#Supported_Devices  .

    To create the project files follow the steps in http://processors.wiki.ti.com/index.php?title=PRU_ICSS_EtherCAT&oldid=230968#Generating_Project_files  

    David

  • Hello David,

    So last news...

    I managed to compile my project with pdk_am335x_1_0_8 (provided by Processor SDK 4.1.0) and PRU-ICSS-EtherCAT_Slave_01.00.05.00.

    Everything works but I have a new issue...

    In order to link my project, I use several libairies:

    • ti.drv.gpmc.aa8fg
    • ti.drv.spi.aa8fg
    • ti.board.aa8fg
    • .....

    These libairies are provided in the file am335x_app.cfg in the following settences:

    • var Gpmc = xdc.loadPackage('ti.drv.gpmc');

    • var Spi = xdc.loadPackage('ti.drv.spi');
    • var Board = xdc.loadPackage('ti.board');

    In fact, the complete path to the location of these libairies are:

    • "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\gpmc\lib\am335x\a8\release\ti.drv.gpmc.aa8fg
    • C:\ti\pdk_am335x_1_0_8\packages\ti\drv\spi\lib\am335x\a8\release\ti.drv.spi.aa8fg
    • C:\ti\pdk_am335x_1_0_8\packages\ti\board\lib\lectraAxis\a8\release\ti.board.aa8fg
    • ......

    For versioning resaon, I would like to save all these libairies in an other place where I put all my own projects

    But I don't find how to change the path where to find the libairies.

    In fact, the path are mentioned in the file linker.cmd in the folder .....AM335x_release\configPkg

    But this file is generated by the script linkcmd_bm_v7a.xdt  in the folder C:\ti\bios_6_46_05_55\packages\gnu\targets\arm

    The commands in this file are the following:

    %if ($args.length > 0) {
    INPUT(
        %for (var i = 0; i < $args.length; i++) {
        "`$args[i]`"
        %}
    )
    %}

    and the result is:

    INPUT(
        "D:\Users\l.cazaban\Projets\Pilotage\6_Products\CNumDsp2015\src\ethercat_slave_full_lectra_pdk8_pru5\AM335x_release\configPkg\package\cfg\am335x_app_pa8fg.oa8fg"
        "D:\Users\l.cazaban\Projets\Pilotage\6_Products\CNumDsp2015\src\ethercat_slave_full_lectra_pdk8_pru5\src\sysbios\sysbios.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\gpmc\lib\am335x\a8\release\ti.drv.gpmc.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\spi\lib\am335x\a8\release\ti.drv.spi.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\board\lib\lectraAxis\a8\release\ti.board.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\csl\lib\am335x\a8\release\ti.csl.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\gpio\lib\a8\release\ti.drv.gpio.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\pruss\lib\a8\release\ti.drv.pruss.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\i2c\lib\a8\release\ti.drv.i2c.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\drv\uart\lib\a8\release\ti.drv.uart.aa8fg"
        "C:\ti\pdk_am335x_1_0_8\packages\ti\osal\lib\tirtos\am335x\a8\release\ti.osal.aa8fg"
        "C:\ti\bios_6_46_05_55\packages\gnu\targets\arm\rtsv7A\lib\gnu.targets.arm.rtsv7A.aa8fg"
        "C:\ti\bios_6_46_05_55\packages\gnu\targets\arm\rtsv7A\lib\boot.aa8fg"
        "C:\ti\bios_6_46_05_55\packages\gnu\targets\arm\rtsv7A\lib\syscalls.aa8fg"

    So my problem is where to find and change the array args described as:

     $args[]     - array of zero or more libraries that should be linked  with (in the order they appear in the argument list)

    Can you help me another time on this point ?

    Thanks a lot

     

    Laurence

  • Yes I found it !!!
    It is sepcified in the project propertries: Tab XDCTools/Package Repository !
    Thanks

    Laurence