infineon4engineers Facebook

infineon@google+ Google+

infineon@linkedin linkedin

infineon4engi@twitter twitter

infineon@youtube youtube

+ Reply to Thread
Results 1 to 3 of 3

Thread: Ethernet

  1. #1

    Ethernet

    Hi,

    I just bought a brand new TriCore Starter Kit (Infineon TriCore TC275TF). I am interested in Ethernet, is there any example code for Ethernet to begin with or Ethernet loopback? Thank you

  2. #2
    Infinity is on a distinguished road
    Join Date
    Nov 2014
    Posts
    1
    Points
    12.5
    Hi,

    I also work with the Ethernet communication on a Application Kit with the TC275 Microcontroller. I'm trying currently to configure the interface as follows. But it does not really work. I can only receive messages but can not send messages . Does anyone see the bug in the configuration?

    Thanks in Advance!


    //Port configuration
    portConfiguration();

    ETH_CLC.B.DISR = 0;

    ETH_GPCTL.B.EPR = 1;

    ETH_BUS_MODE.B.SWR = 1;
    while(ETH_BUS_MODE.B.SWR == 1);

    /* ETH_BUS_MODE */
    ETH_BUS_MODE.B.PBL = 0x2;
    ETH_BUS_MODE.B.DSL = 0x2;

    /* ETH_MAC_CONFIGURATION */
    ETH_MAC_CONFIGURATION.B.PRELEN = 0x2;
    ETH_MAC_CONFIGURATION.B.FES = 1;
    ETH_MAC_CONFIGURATION.B.WD = 0;
    ETH_MAC_CONFIGURATION.B.JD = 0;
    ETH_MAC_CONFIGURATION.B.BE = 1;
    ETH_MAC_CONFIGURATION.B.DO = 0;
    ETH_MAC_CONFIGURATION.B.LM = 0;
    ETH_MAC_CONFIGURATION.B.DM = 1;
    ETH_MAC_CONFIGURATION.B.DR = 0;
    ETH_MAC_CONFIGURATION.B.ACS = 0;
    ETH_MAC_CONFIGURATION.B.BL = 0;
    ETH_MAC_CONFIGURATION.B.DC = 0;
    ETH_MAC_CONFIGURATION.B.TE = 1;
    ETH_MAC_CONFIGURATION.B.RE = 1;

    /* ETH_FRAME_FILTER */
    ETH_MAC_FRAME_FILTER.B.RA = 1;

    /* ETH_FLOW_CONTROL */
    ETH_FLOW_CONTROL.B.TFE = 1;
    ETH_FLOW_CONTROL.B.RFE = 1;

    ETH_GMII_ADDRESS.B.CR = 0x01;

    /* Initialize DMA Descriptors */
    initDmaDesc();

    /* ETH_INTERRUPT_ENABLE */
    ETH_INTERRUPT_ENABLE.B.TIE = 1;
    ETH_INTERRUPT_ENABLE.B.RIE = 1;
    ETH_INTERRUPT_ENABLE.B.NIE = 1;

    /* ETH_Operation_Mode */
    ETH_OPERATION_MODE.B.TSF = 1;
    ETH_OPERATION_MODE.B.RSF = 1;
    ETH_OPERATION_MODE.B.ST = 1;
    ETH_OPERATION_MODE.B.SR = 1;

  3. #3
    New Member New Member vivekrsingh20 is on a distinguished road
    Join Date
    Jan 2019
    Posts
    16
    Points
    160
    Quote Originally Posted by Infinity View Post
    Hi,

    I also work with the Ethernet communication on a Application Kit with the TC275 Microcontroller. I'm trying currently to configure the interface as follows. But it does not really work. I can only receive messages but can not send messages . Does anyone see the bug in the configuration?

    Thanks in Advance!


    //Port configuration
    portConfiguration();

    ETH_CLC.B.DISR = 0;

    ETH_GPCTL.B.EPR = 1;

    ETH_BUS_MODE.B.SWR = 1;
    while(ETH_BUS_MODE.B.SWR == 1);

    /* ETH_BUS_MODE */
    ETH_BUS_MODE.B.PBL = 0x2;
    ETH_BUS_MODE.B.DSL = 0x2;

    /* ETH_MAC_CONFIGURATION */
    ETH_MAC_CONFIGURATION.B.PRELEN = 0x2;
    ETH_MAC_CONFIGURATION.B.FES = 1;
    ETH_MAC_CONFIGURATION.B.WD = 0;
    ETH_MAC_CONFIGURATION.B.JD = 0;
    ETH_MAC_CONFIGURATION.B.BE = 1;
    ETH_MAC_CONFIGURATION.B.DO = 0;
    ETH_MAC_CONFIGURATION.B.LM = 0;
    ETH_MAC_CONFIGURATION.B.DM = 1;
    ETH_MAC_CONFIGURATION.B.DR = 0;
    ETH_MAC_CONFIGURATION.B.ACS = 0;
    ETH_MAC_CONFIGURATION.B.BL = 0;
    ETH_MAC_CONFIGURATION.B.DC = 0;
    ETH_MAC_CONFIGURATION.B.TE = 1;
    ETH_MAC_CONFIGURATION.B.RE = 1;

    /* ETH_FRAME_FILTER */
    ETH_MAC_FRAME_FILTER.B.RA = 1;

    /* ETH_FLOW_CONTROL */
    ETH_FLOW_CONTROL.B.TFE = 1;
    ETH_FLOW_CONTROL.B.RFE = 1;

    ETH_GMII_ADDRESS.B.CR = 0x01;

    /* Initialize DMA Descriptors */
    initDmaDesc();

    /* ETH_INTERRUPT_ENABLE */
    ETH_INTERRUPT_ENABLE.B.TIE = 1;
    ETH_INTERRUPT_ENABLE.B.RIE = 1;
    ETH_INTERRUPT_ENABLE.B.NIE = 1;

    /* ETH_Operation_Mode */
    ETH_OPERATION_MODE.B.TSF = 1;
    ETH_OPERATION_MODE.B.RSF = 1;
    ETH_OPERATION_MODE.B.ST = 1;
    ETH_OPERATION_MODE.B.SR = 1;


    good to here that you had success with ethernet on AURIX, but can you please help me out, i cannot run the demo code of ethernet from iLLD, it gets stuck in
    Code:
    /** Insert DEBUG instruction
     */
    IFX_INLINE void __debug(void)
    {
        __asm__ volatile ("debug" : : : "memory");
    }
    before just this the ethernet demo code was in

    Code:
    void IfxEth_enableModule(void)
    {
        {
            uint16 l_TempVar = IfxScuWdt_getCpuWatchdogPassword();
            IfxScuWdt_clearCpuEndinit(l_TempVar);
            ETH_CLC.U = 0;
            IfxScuWdt_setCpuEndinit(l_TempVar);
        }
    }
    then it went in " __asm__ volatile ("debug" : : : "memory");" and got stuck

+ Reply to Thread

Tags for this Thread

Disclaimer

All content and materials on this site are provided “as is“. Infineon makes no warranties or representations with regard to this content and these materials of any kind, whether express or implied, including without limitation, warranties or representations of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. No license, whether express or implied, is granted by Infineon. Use of the information on this site may require a license from a third party, or a license from Infineon.


Infineon accepts no liability for the content and materials on this site being accurate, complete or up- to-date or for the contents of external links. Infineon distances itself expressly from the contents of the linked pages, over the structure of which Infineon has no control.


Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Usage Terms of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Usage Terms of this site. Infineon reserves the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.