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.

Communicating EMAC Port 0s

Hi,,

I have a problem with communicating 2 6678EVMs over AMC connecition by using their EMAC port 0 interfaces.

As you know EMAC port 0 is connected to  the backplane connection at the AMC Chassis. It is not connected to the RJ45 connector through PHY. I tried to modify PA_exampleProject to communicate these by using EMAC port0. To achieve this, I make the following changes:

1. cpswEvm7788=1

2. cpswLpbkMode=CPSW_LOOPBACK_EXTERNAL

3. comment out the raw  CSL_SGMMI_EnableLoopBack(macport) in Init_SGMII function to aviod loopback.

When I run this configuration, both sides cannot receive any packet.

I will be happy if somebody can make any suggestion.. 

Thank You,

Alpaslan



  • Alpaslan,

    I will take a look at the example code and get back with you soon.

  • Alpaslan,

    You actually want to setup cpswLpbkMode=CPSW_LOOPBACK_NONE, because you are actually not using loopback--you are communicating with another device.

    Since you are using the AMC connection, you are not going through the RJ45 and PHY, so you are doing a direct SGMII to SGMII connection using autonegotiation. The procedure for this is listed in the GbE Switch Subsystem user guide in section 2.4.3.3. You will want to set up one EVM as the master and one EVM as the slave. This gets a little more complicated because the user guide uses register layer code while the example project uses functional layer code.

    I have modified the cpsw_mgmt.c file so the the SGMIIs should be able to autonegotiate with this mode. You will need to build 2 versions of the test. One for the master (set SGMII_MASTER=0 in the attached file), and one for the slave (set SGMII_MASTER=1 in the attached file).

    This should resolve issues with the SGMII configuration. If you run into problems, you may also need to update the MAC addresses of the packet so that the packets are unique (currently, each EVM will be sending packets with the same MAC address which doesn't quite make sense in a real scenario). If you need to do this, you will want to modify the MAC address in the CPSW ALE, the PA look up table (through the input to the addMac API), and in the packet itself.

    Please let me know if you have any more questions.6378.cpsw_mgmt_sgmii_to_sgmii_autoneg.zip

  • Derek,

    At last I can communicate 2 6678 evms over SGMII interface. I set cpswLpbkMode = CPSW_LOOPBACK_INTERNAL, comment out CSL_SGMII_enableLoopback (macPortNum) line, and I use SGMII to SGMII with Forced Link Configuration scheme. When  cpswLpbkMode = CPSW_LOOPBACK_NONE is set also need to change Init_Switch() in cpsw_mgmt.c. I also call CSL_CPSW_3GF_enableAleBypass() for cpswLpbkMode = CPSW_LOOPBACK_NONE. And as a final change, I exchange the src mac address and dst mac address values for pktMatch[] in cppi_qmss_mgmt.c.

    Now I try to understand the functionality of ALE and how I configure it.

    Thank you for your support.

  • hello,I also work with this project with the same feature as yours,but i haved tried two weeks without anything successed ,can you explan more detail about the " i exchange the src mac address and dst mac address values for pktMatch[] in cppi_qmss_mgmt.c" in  both the DSPA and DSPB. thank you very much .if you can send your project to me  is best.my email is xd_yxd@163.com.