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.

Rebuild NSP omapl138 driver for EVMOMAPL137 device

Other Parts Discussed in Thread: OMAPL138

Hi,

I have EVMOMAPL137 board and try to run the ndk_evm6748_bios5_cfgdemo example on this board (this example is simplest for lan w/o dhcp).

Thus, I created new copy of omapl138 ndk driver folder and rebuilt it for omapl137 platform.

i.e. renamed all occurrences of the string "omapl138" on the "omapl137" and changed the variable macsel=RMII in the csl_mdio.c, after configure the config.bld, the ethernet driver was succesfully rebuilt.

After this, I linking my ethernet driver in to the ndk_evm6748_bios5_cfgdemo project and changed bios5 configuration file for evmomapl137 platform. This project  also successfully built w/o warnings and errors.

But this project not working correctly on the board. Thus, in the debugger console I have:

 

TCP/IP Stack Client Configuration Demo

192 bytes required for save

Using default MAC address

Using MAC Address: 00-08-ee-03-14-99

MAC Address = 00-08-ee-03-14-99

Next, I added static ARP in workhost

> arp    -s    192.168.8.140     00-08-ee-03-14-99

but ping  to  192.168.8.140  is failed.

Help me please to resolve this problem. I think that need to fix the pinmux defines in the emacHooks.c, but  I do not know how :)

Thanks!

 

  • Please state what version of the NDK you are using, and in addition whether you have installed any NDK patch releases.

    Dave

  • Hi Nikolay Kokorin,

    The NDK version 2.0 shipped with Ethernet drivers for the 6747.  You can look at the driver implementation in this release to compare the settings and make changes as necessary.

    http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/ndk/index.html

    see the directory:

    ndk_2_0_0\packages\ti\ndk\src\hal\evmomapl137\eth_omapl137

    Steve

  • Hi all,

    David, I have installed ndk_2_20_04_26 and nsp_1_00_00_09 (bios5, ccv4 etc. is latest versions).

    Steven, this is first what I did :) Thus, only csl_emac.c and csl_mdio.c files should be fixed.

    Files csl_emac.c from ndk_2_0_0 and nsp_1_00 are different but fully compatible.

    File csl_mdio.c from ndk_2_0_0 has only once difference - variable macsel = RMII

    other files are hardware-independ (or I'm wrong?)

    Thus, I'm copied all files from omapl138 driver and change only csl_mdio.c.

    Do I need to make changes to the emacHooks.c file (or any other) in the ndk_evm6748_bios5_cfgdemo example?

    Thanks!

  • Hi all again :)

    If I use the ethdriver.c from ndk_2_0_0 then linking of example project fails (undefined   symbol   _EMAC_startSwitch).

    This function are contained in the ndk_2_0_0\packages\ti\ndk\example\tools\evmomapl137\evminit.c but also contained new undefined symbol _EVMOMAPL137_I2C_write.

  • Nikolay,

    After looking at this post again, I don't think it makes sense to rebuild the driver.  The NDK 2.0.0 ships with the driver library for the OMAPL137, you should just link it into your program.

    It should be located here:

    ndk_2_0_0\packages\ti\ndk\lib\hal\evmomapl137\hal_eth_omapl137.lib

    Steve

  • Hi Steven,

    >other files are hardware-independ (or I'm wrong?)

    It's wrong. I fixed also the ethdriver.c and rebuilt driver. Now it's work fine!

    The next problem was posted because I did not linked the evmomapl137bsl.lib into my project.

    Thanks!

    But I have a question: I trying rewrite the EVMOMAPL137_I2C_write function from evmomapl137bsl.lib using CSLR (from pspdrivers_01_30_01\packages\ti\pspiom\). Unfortunately, I do not know why but it does not work correctly. Can you check the attached file to find my mistake?

    Very thanks

    7142.i2c.zip

  • Nikolay,

    The file you are referring to is part of the PSP drivers, which I do not work on.  I have requested that someone from the PSP drivers team help you with this.

    Thanks,

    Steve

  • Hi Steven,

    Thanks, I resolved the problem.

    After the cycle of  transmitting data was necessary generate a stop for i2c

    i2cRegs->ICMDR |= CSL_FMKT(I2C_ICMDR_STP,SET);

    Thanks for your support