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/PROCESSOR-SDK-AM437X: Porting PRP HSR application

Part Number: PROCESSOR-SDK-AM437X

Tool/software: TI-RTOS

Hi,

Can someone explain purpose of PWMSS in prp_app?

I'm working on example port to custom board and I don't understand what for is used....
Thanks!

Regards, Mare

  • The RTOS team have been notified. They will respond here.
  • Mare,

    PWMSS in prp_app is used mainly due to PWMSS's eCAP module for time sync of PTP support, see protocols\timeSync\drivers\icss_timeSync_ecap_edma.c:

    /* configure the eCAP0 timer in
    1. sync packet received => deltaT calculation => write 0x0451 /0x0651 in a specific memory location
    2. calculate period for ECAP(i.e. update period) => write ecap period and start ecap
    3. ecap will periocally generate interrupt => EDMA is triggered => writes 451/651 in IEP register and clear ecap bits
    repeate step 1 to 3*/

    void TimeSync_initEcap(TimeSync_ParamsHandle_t timeSyncHandle)
    {
    /* Putting ECAP in APWM mode, stop TSCTR if running */

    Regards,
    Garrett
  • Thanks for info Garrett!

    I have another issue.
    On custom board I have strange behavior!


    Some times it port on ICSS become unreachable after start. Now I looking for reason...

    1.) From link processors.wiki.ti.com/.../ICSS_EMAC_LLD_debug_guide I try to check statistic:
    hostStatPtr = (hostStatistics_t*)((((ICSSEMAC_Object*)emachandle->object)->hostStat));
    pruStatPtr = (pruStatistics_t*)((((ICSSEMAC_Object*)emachandle->object)->pruStat));
    pruStatPtr members are always 0 (when port running & when is broken).
    hostStatPtr has members with numbers...
    Why?

    2.)
    When is broken, app hit RED_ERR in RedTxPacketEnqueue(). (/* Check if queue is full and there is an wrap around */ and /* Check if the Queue is already full */) That mean PRU firmware not runing?

    3.) We dont use "Collision/Carrier Sense" pins so I check in main.c lines...:
    switchEmacCfg->halfDuplexEnable = 0;
    That is OK, right?

    4.)Is possible that pru stuck because want control some pin which is not pinmuxed?

    Any suggestion what/where to check?

    Thank you Garrett for all your effort!
    Regards, Mare

  • Mare,

    1) the prusStat memory is allocated but not updated, wheras the hostStat is updated in ICSS_EmacUpdateRxStats() at hsrPrp_red.c and ICSS_EmacUpdateTxStats( ) at hsrPrp_red_tx.c. To get pruStat, you need call ICSS_EmacReadStats() which is in icss_emac library. This is explained in the wiki as well: processors.wiki.ti.com/.../ICSS_EMAC_LLD_developers_guide

    2) you can find out from above pruStat

    3) yes

    4) pinmux is always the 1st item you need to check to ensure icss_emac pins are properly multiplexed.

    Regards,
    Garrett
  • Thanks Garrrett!

    It seem it was HW problem. Should I close thread or lived open until porting of my custom board is finish?

    Regards, Mare
  • Or maybe was not just an HW issue.

    I Figure out that ICSS_EmacUpdatePhyStatus() is not called when link is broken / ping doesn't work. So app did not check link status....
    What should be reason? what should I check?

    Regards, Mare
  • Hi Garrett,

    I'm not familiar enough in knowledge of TI RTOS. I see that Link is blocked by semaphore.
    Issue remands, but I don't understand yet what is going on...
    I'll report when I figure out what issue is..

    Thanks for now. 

    Regards, Mare
     

  • Mare,

    ICSS_EmacUpdatePhyStatus( ) is called in the LinkTask - ICSS_EMacOsLinkTaskFnc() which is from icss_emac PDK driver. It seems that you don't have PHY setup properly on your custom board...btw, please open another ticket for the PHY/Link issue. The thread has been marked as 'resolved' and closed, thanks!

    Regards,
    Garrett