Ethernet initialisation issues in AVTP project

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Ethernet initialisation issues in AVTP project

955 Views
ssattva1
Contributor III

I am working on AVTP implementation using AVB stack provided by NXP

ssattva1_0-1754643186207.png

I am specifically working on s32k358_baremetal_acf_example project and I am facing issues after flashing the elf. I did not face any issues with building the project (make sure RTD version is 4.0 , not 5.0). My ethernet module initialisation is not getting done after flashing.

Issues:

  • Program goes to HW fault immediately after flashing , reason being " MemManage: The processor attempted an instruction fetch from a location that does not permit execution. HardFault: A fault has been escalated to a hard fault." After clicking reset button in the debug window then it enters into main.c

ssattva1_1-1754643620648.png

  • In the function EMACLLD_ClockInit_HwSwitch() , the clock switch is not happening and upon observing the registers  I come to know that the clock switch request fails and FIRC is the source instead of EMAC_EXTERNAL_TX_RMII. "010b - Switch after the request failed because of an inactive target clock and the current clock is FIRC."

ssattva1_0-1754643881076.png

 

  • Upon further digging , I decide to compare it with LWIP baremetal project . The above registers show success after Clock_Ip_Init () in device_init(), not so the case with AVTP project.  I am using the same board and PHY , yet I dont know why it shows target clock inactive when it comes to AVTP project.
  • Even if I comment out the EMACLLD_ClockInit_HwSwitch() function and make appropriate clock configs in the peripheral tool , it again gets stuck at DMA init

ssattva1_1-1754644217547.png

 

  • Please help me resolve this blocker.
    HW USED: S32K358 eval board
    PHY : ADTJA1101-RMII
Tags (3)
0 Kudos
Reply
3 Replies

948 Views
PavelL
NXP Employee
NXP Employee

Hello @ssattva1 ,

I have successfully run RGMII with the TJA1103-SDBR on the S32K3X8EVB-Q289.

However, RMII requires some hardware modifications to the board. For details, please refer to section 13.2 of the S32K3X8EVB-Q289 Hardware User Manual (S32K3X8EVB-Q289HWUM.pdf).

Best regards,

Pavel

0 Kudos
Reply

920 Views
ssattva1
Contributor III
Hi @PavelL , Lwip example works without making those changes in HW for RMII.
I found this thing recently, when I probe into resistor 65 in ADTJA1101, which is the resistor along REFCLK, the voltage level is around 2V for LWIP project , but it drops down to 1V as soon as I run AVTP project. Could you help me with this?
0 Kudos
Reply

873 Views
PavelL
NXP Employee
NXP Employee

Hello @ssattva1 ,

I apologize for the delayed response — I was on vacation.

It's great to hear that the LWIP example works for you.

Regarding the voltage drop on REFCLK, this seems like a hardware conflict. Please verify that the RMII pin configuration matches between the LWIP example and your AVTP project. Specifically, the emac_mii_rmii_tx_clk pin should be configured as input.

In other words, since one example works, I recommend comparing its configuration with the other project to identify any discrepancies.

Best regards,

Pavel

0 Kudos
Reply