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.

Ethercat example on TMDXICE3359

Other Parts Discussed in Thread: SYSBIOS

Dear all:

 According to the SDK manual s and wiki: "Configuring TwinCAT for AM335x", I can run the EtherCAT example successful, but I can't find LED shown on TwinCAT app so I can't use TwinCAT to control TMDXICE's LED:

1.  I use TMDXICE3359 1.0.0.3 FW, boot app from SD card.

2. After running the EtherCAT example, I can see LED in circular bit shift pattern, D6~D9 toggles.

3. After running TwinCAT (v2.11.0 build 2214, 30 days evaluation) on window XP SP3 (32 bits), and according step by step of wiki, I can see TI Boxn (ti-esc) shown on TwinCAT tree view.

4. If I set free run by TwinCAT, I can see TMDXICE goes running mode ( LED circular shift stopped, D6 keeps lite on, implies running mode).

The question is:

My TwinCAT application shows different TIBoxn compared with wiki's last step:

My TwinCAT shows following tree view:

Box 1 (TIESC-001)

-> TXPDO

-> RxPDO

->WcState

->InfoData

However the wiki pictures shows with:

TI Box 1 (ti-esc)

-> DI Inputs

->Motor AllInputs

->DO Outputs (we can control LED from herel)

->WcState

->InfoData

Is there anything I miss or  wrong when going these steps? Or there is any example, TI_ESC.xml or TwinCAT version mismatch?

Note as mentioned by user manual, TI_ESC.xml is located at sdk\examples\ethercat\esi, wiki said it located at sdk\protocols\ethercat\docs\esi, however I can only found one located at sdk\protocol\ethercat\ecat_app\esi\, can someone help to check  the xml is right version or not?

  • Hello,

    We are in the process of updating the wiki page to incorporate the latest changes. Meanwhile, we have posted the latest Quick Start Guide for ICE at

    http://processors.wiki.ti.com/index.php/AM335xICEQSG

    This has updated information that might help you.

    Thanks,

    Ranjith

  • Calvin,

    the confusion comes from the fact that we actually have two different examples of using EtherCAT...

    The example in the examples folder as well as the pre-build binaries only have 32bit in/out PDO config (according to c:\ti\am335x_sysbios_ind_sdk_1.0.0.3\sdk\examples\ethercat\esi\TiEtherCATLib.xml). The lower 8 bits are connected to LED/switches on the board.

    If you have access to the Beckhoff SSC code you can also generate the EtherCAT application in c:\ti\am335x_sysbios_ind_sdk_1.0.0.3\sdk\protocols\ethercat\ecat_appl\

    This is using the XML c:\ti\am335x_sysbios_ind_sdk_1.0.0.3\sdk\protocols\ethercat\ecat_appl\esi\TI_ESC.xml. It has a bit more application like PDO data with LEDs/switches and so on. For details please see the sources.

    Obviously we are only providing a building block for EtherCAT slave devices and there are millions of options what to do with it. Only an application plus a matching XML definition  can be used in real test against an EtherCAT master. Carefully controlling the test system and configuration is therefore required. It is quite easy to get confused if you try multiple examples and configs. Always make sure that the device definition used by the master is the same as the one read from the device.

    Regards.

  • Dear Ranjith:

    According the new starting guide, I copy the "TiEtherCATLib.xml" to c:\TwinCAT\IO\EtherCAT, but it seems confused the board or TwinCAT. After a few trying, my board is dead now.

    The board behavior now is:

    1. It can run app for several seconds and then program hangs, for example, i2c_LED app will toggle after power on reset, but after 4~5 sec, all LEDs will off except D3 is keeping on (D3 is connected to 5V_0D). For EtherCAT example, the similar condition happens: init bit shift pattern goes for several seconds then all LEDs off except D3 is on.

    2. The behavior is the same no matter which boot mode : "SPI bootloader + SPI app", "SPI bootloader + SD app" or "NOR bootloader + SD app", the three boot methods are proved to work fine last week.

    3. The reset button have no function once program hangs. If pressing reset button before program hangs (after power on reset, program can run for 3 ~ 4 seconds, pressing the reset button during this time interval), the reset function is fine, board will reset, but it will hang after several seconds.

    4. Once board hangs, it will auto-reset after a few minutes. For example in i2c_LED app, it will toggle LEDs, but after several seconds, it hangs again, after a few minute, it resets and toggle LEDs again, then hangs again, the behavior repeats again and again, it seems the program will run to uncertain address and finally go back to the reset address or WDT reset happens.


    5. USB JTAG have no functions, I can't use CCS5 to connect the board. So no way to load program via CCS,  no UART device shown on PC, I can't see boot loading information dumped via terminal (tera-term).  (See below for error message when connecting)

    6. Remove power and let it rest for 10 minutes is of no use, short the power has no use.


    It seems some configuration is broken, either in SPI flash, E2PROM, or any other place. Is there any thing I can check or do to rescue the board?

    Note: When connect to TMDXICE3359 via JTAG, it will show:

    Error connecting to the target:
    (Error -151 @ 0x0)
    One of the FTDI driver functions used during
    the connect returned bad status or an error.
    The cause may one or more of: invalid emulator serial number,
    blank emulator EEPROM, missing FTDI drivers, faulty USB cable.
    Use the xds100serial command-line utility in the 'common/uscif'
    folder to verify the emulator can be located.
    (Emulation package 5.0.569.0)

    The Console information is:

    IcePick_D_0: Error connecting to the target: (Error -151 @ 0x0) One of the FTDI driver functions used during the connect returned bad status or an error. The cause may one or more of: invalid emulator serial number, blank emulator EEPROM, missing FTDI drivers, faulty USB cable. Use the xds100serial command-line utility in the 'common/uscif' folder to verify the emulator can be located. (Emulation package 5.0.569.0)

    If program is not hanging, I can use xds100serial.exe to get the XDS100 emulators with:

    VID/PID Type Serial # Description

    0403/a6d0 xds100v1/v2 ICE

    If program hangs, it will show:

    No XDS100 emulators were found on the system.