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.

Need second Ethernet (usb-Ethernet adapter) on 1808EVM

Other Parts Discussed in Thread: AM1808

Hi,

I need a second Ethernet on the AM1808 EVM.  I have the trendnet TU2-ET100 that is popular with the BeagleBoard but the Kernel that came with our EVM doesn't appear to have USB-to-Ethernet support built in.

 

I build the kernel in the PSP DaVinci-PSP-SDK-03.20.00.12 tarball and added in USB Ethernet support but when I plug up the trendnet adapter all I see on dmesg is:

usb 2-1: new full speed USB device using ohci and address 3
usb 2-1: not running at top speed; connect to a high speed hub

Not sure how close I am to getting this to work ... I also tried to add OTG support in the kernel of the above PSP and it wouldn't even build.  Got at error like:

CC      drivers/usb/gadget/r8a66597-udc.o
drivers/usb/gadget/r8a66597-udc.c: In function 'r8a66597_probe':
drivers/usb/gadget/r8a66597-udc.c:1585: error: implicit declaration of function 'IS_ERR'
drivers/usb/gadget/r8a66597-udc.c:1588: error: implicit declaration of function 'PTR_ERR'

Any advice?  I've asked to join Logic's Knowledge base but have yet to have my account "activated".

Is there a community kernel for this board in the TI git?  I didn't see anything in git ... all I've been able to find so far is the kernel included in the PSP tarballs like the one I mentioned above.

 

Regards,

 

Brian

 

  • It looks like you probably haven't built the driver. Can you go to your Linux kernel source and do

    make menuconfig

    Select Device Drivers, Network device support, USB Network adapters, and select ASIX AX88xxx Based USB 2.0 Ethernet Adapters. That driver supports the Trendnet device you have.

    Steve K.

  • Tried that (and a bunch of other things) before I even posted. I'd post the .config if I could figure how.

    Regards,

     

    Brian

     

     

     

     

  • Here are some of the settings of USB adapters in my .config:

     

    #
    # USB Network Adapters
    #
    CONFIG_USB_CATC=y
    CONFIG_USB_KAWETH=y
    CONFIG_USB_PEGASUS=y
    CONFIG_USB_RTL8150=y
    CONFIG_USB_USBNET=y
    CONFIG_USB_NET_AX8817X=y
    CONFIG_USB_NET_CDCETHER=y
    CONFIG_USB_NET_CDC_EEM=y
    CONFIG_USB_NET_DM9601=y
    CONFIG_USB_NET_SMSC95XX=y
    CONFIG_USB_NET_GL620A=y
    CONFIG_USB_NET_NET1080=y
    CONFIG_USB_NET_PLUSB=y
    CONFIG_USB_NET_MCS7830=y
    CONFIG_USB_NET_RNDIS_HOST=y
    CONFIG_USB_NET_CDC_SUBSET=y
    CONFIG_USB_ALI_M5632=y
    CONFIG_USB_AN2720=y
    CONFIG_USB_BELKIN=y
    CONFIG_USB_ARMLINUX=y
    # CONFIG_USB_EPSON2888 is not set
    # CONFIG_USB_KC2190 is not set
    CONFIG_USB_NET_ZAURUS=y
    # CONFIG_USB_NET_INT51X1 is not set
    # CONFIG_WAN is not set
    # CONFIG_PPP is not set
    # CONFIG_SLIP is not set
    CONFIG_NETCONSOLE=y
    # CONFIG_NETCONSOLE_DYNAMIC is not set

    CONFIG_USB_SUPPORT=y
    CONFIG_USB_ARCH_HAS_HCD=y
    CONFIG_USB_ARCH_HAS_OHCI=y
    # CONFIG_USB_ARCH_HAS_EHCI is not set
    CONFIG_USB=y
    CONFIG_USB_DEBUG=y
    CONFIG_USB_ANNOUNCE_NEW_DEVICES=y

    # Miscellaneous USB options
    #
    # CONFIG_USB_DEVICEFS is not set
    # CONFIG_USB_DEVICE_CLASS is not set
    CONFIG_USB_DYNAMIC_MINORS=y
    CONFIG_USB_SUSPEND=y
    # CONFIG_USB_OTG is not set
    # CONFIG_USB_OTG_WHITELIST is not set
    # CONFIG_USB_OTG_BLACKLIST_HUB is not set
    # CONFIG_USB_MON is not set
    # CONFIG_USB_WUSB is not set
    # CONFIG_USB_WUSB_CBAF is not set

    # USB Host Controller Drivers
    #
    CONFIG_USB_C67X00_HCD=y
    CONFIG_USB_OXU210HP_HCD=y
    CONFIG_USB_ISP116X_HCD=y
    CONFIG_USB_ISP1760_HCD=y
    # CONFIG_USB_ISP1362_HCD is not set
    CONFIG_USB_OHCI_HCD=y
    # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set
    # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set
    CONFIG_USB_OHCI_LITTLE_ENDIAN=y
    CONFIG_USB_SL811_HCD=y
    CONFIG_USB_R8A66597_HCD=y
    # CONFIG_USB_HWA_HCD is not set
    CONFIG_USB_MUSB_HDRC=y
    CONFIG_USB_MUSB_SOC=y
    CONFIG_USB_MUSB_HOST=y
    # CONFIG_USB_MUSB_PERIPHERAL is not set
    # CONFIG_USB_MUSB_DUAL_ROLE is not set
    # CONFIG_USB_MUSB_OTG is not set
    CONFIG_USB_MUSB_HDRC_HCD=y
    # CONFIG_MUSB_PIO_ONLY is not set
    # CONFIG_USB_INVENTRA_DMA is not set
    # CONFIG_USB_TI_CPPI_DMA is not set
    CONFIG_USB_TI_CPPI41_DMA=y
    CONFIG_USB_MUSB_DEBUG=y

     

     

     

  • Hate it when this happens!  It is a lick on me!  Sorry for the noise.

    I copied the uImage to my tftpboot dir but forgot that I made u-boot tftp something other than "uImage"!  It helps to specify the "right" file before you look stupid in front of everyone. I did a uname -a and was horrified that it wasn't the time/datestamp of what I just built and I had a "here's your sign" moment.

     

    eth1 is now showing up in dmesg for the trendnet adapter on my 1808.

     

    Again, sorry for the noise!

     

    Now if I can just get the beagleboard to mount rootfs via NFS with the trendnet I'd be happy.  ;)

     

    Brian

     

  • I still have issue with getting the kernel OTG support to build with the PSP mentioned in the first post.  The Trendnet as a 2nd nic is working fine now on the USB port.

     

    Regards,

     

    Brian

  • I have a few findings.  Out of the box, the kernel flashed on the board supports the OTG port only in host mode. To use it in host mode I connected one of those 5-in-1 cables where the ends are changeable. One end has Mini USB A while the other end has USB A Female. I was able to connect a USB memory stick and it was recognized.

    I then re-compiled the kernel to support OTG mode. Type in make menuconfig, select Device Drivers, scroll down to and select USB Support. Select Inventra Highspeed Dual Role Controller. Then for Driver Mode select Both Host and Peripheral: Non-OTG Device. If you don't need Host mode you could select USB Peripheral (gadget stack). Then back on the USB Support page, scroll down to USB Gadget Support and select it. In the USB Peripheral Controller window make sure you have Inventra HDRC USB Peripheral selected. Then select the Gadget driver you want built. I built the Ether Gadget driver with RNDIS support. After building and booting the kernel I was able to connect the OTG port to my laptop with a standard USB cable. I had usb0 network devices on my laptop and on the board.

    I hope this helps.

  • Steve,

     

    Ah, that does help.  I'll have to try that.  Can I do the same kind of stuff with the 1808 OTG that you can do on the Beableboard like Ethernet over the USB cable for NFS, usbtty console  etc.?

     

    On a different topic, I was able to get NFS going on my beagleboard using the trendnet.  I did a git pull of u-boot & kernel and that did the trickk so it must have been something with the version I was trying to use. 

     

    Regards,

     

    Brian

  • Hi Brian,

    While I haven't tested it thoroughly on AM1808 but you should be able to do the same things with OTG as Beagle. The Ethernet Gadget driver works the same way so I don't see why the rest shouldn't.

    Steve K.

  • After going back an looking at my .config I pretty much had what you said.

    In Device Drivers->USB support-> Inventra Highspeed Dual Role Controller  I selected:

    (X) Both host and peripheral:  USB OTG (On The Go) Device

    I changed that to:

    (X) USB Peripheral (gadget stack)

    and it still results in:

     CC      drivers/usb/gadget/r8a66597-udc.o
    drivers/usb/gadget/r8a66597-udc.c: In function 'r8a66597_probe':
    drivers/usb/gadget/r8a66597-udc.c:1585: error: implicit declaration of function 'IS_ERR'
    drivers/usb/gadget/r8a66597-udc.c:1588: error: implicit declaration of function 'PTR_ERR'
    make[2]: *** [drivers/usb/gadget/r8a66597-udc.o] Error 1
    make[1]: *** [drivers/usb/gadget] Error 2
    make: *** [drivers] Error 2

    This is with kernel in:
    DaVinci-PSP-SDK-03.20.00.12/src/kernel/linux-03.20.00.12 built with CSL 2009q1-203

    Which version of the kernel/PSP are you using?

    Regards,

    Brian

  • I'm still on 03.20.00.11, but I see your problem.  It looks like under the USB Gadget Support you have the incorrect core setting.  Go to Device Drivers -> USB Support -> USB Gadget Support -> USB Peripheral Controller. Make sure you have the Intentra HDRC USB Peripheral Controller selected:

         │ │        ( ) Renesas R8A66597 USB Peripheral Controller          │ │
         │ │        (X) Inventra HDRC USB Peripheral (TI, ADI, ...)         │ │
         │ │        ( ) Renesas M66592 USB Peripheral Controller            │ │
         │ │        ( ) Dummy HCD (DEVELOPMENT)                             │ │

    From your compilation error, it looks like you have the R8A66597 selected.

    Steve K.

  • In 3.20.00.12 under USB Gadget Support the Inventra option isn't there.  I think where the Renesas enters the picture is Gadget support defaults to:

    (2)   Maximum VBUS Power usage (2-500 mA)                        │ │ 
      │ │          USB Peripheral Controller (Renesas R8A66597 USB Peripheral

     

    I didn't catch that I could change "USB Peripheral Controller".  Wasn't obvious there was menu selection behind that selection in make menuconfig ... but when I discovered it I saw the menu as you stated in your last post and selected Inventra HDRC .... so now my build fails at:

    [hutch@localhost linux-03.20.00.12]$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- uImage
      CHK     include/linux/version.h
      CHK     include/generated/utsrelease.h
    make[1]: `include/generated/mach-types.h' is up to date.
      CALL    scripts/checksyscalls.sh
      CHK     include/generated/compile.h
      CC      drivers/usb/musb/musb_core.o
    drivers/usb/musb/musb_core.c: In function 'musb_init_controller':
    drivers/usb/musb/musb_core.c:1948: error: label 'bad_config' used but not defined
    make[2]: *** [drivers/usb/musb/musb_core.o] Error 1
    make[1]: *** [drivers/usb/musb] Error 2
    make: *** [drivers] Error 2

  • Clarification.  I should have edited my post when I said "In 3.20.00.12 under USB Gadget Support the Inventra option isn't there."  I said this wrong .. what I meant to say it isn't obvous that this choice is there the way make menuconfig presents it.  Maybe it was my terminal width but it wasn't obvious to me there was a menu behind the option I mentioned in my last post.

    Hope I don't cause confusion for anyone else following this.