Trying to use USB-to-RS232 (FTDI) with Mofi 3500

You have power but no data then. I think the RT305X chips need some sort of "OTG" driver in addition to or instead of kmod-usb2.

You can also try other USB devices like a mouse or flash drive. They should all cause the "new XXX speed USB device" message.

I'm not sure what you mean by chip model or how to get anything about the chip except USB ID (when hooked up to regular PC, or in the stock-mofi-firmware lsusb in my OP).

As for brand and model of cable, I actually have 5 of these, 4 appear the same (one of which is the one I've been using up to now), about 6" long with no distinguishing marks, just a "Q.C. OK" + bar code + serial number sticker, and one is different, about 24" long, with sticker saying:

USB-RS-232 Converter
Model: USA-FTDI-A36
Data Communications
(bar code)
(serial number)

All 5 of them show exactly the same in lsusb when connected to a regular PC.

Is it relevant from my OP then that (with stock-mofi-firmware) something about dwc_otc came up in dmesg when I connected the device?

Appreciate all the suggestions everyone...

The FTDI chip the cable uses has a model # which denotes what driver it will then need, as FTDI makes a range of chips for serial communitcation.

It appears you have all the correct FTDI/serial packages installed, except for libftdi or libftdi1, unless either was installed as a dependency and not listed in your output... please post the output of:
opkg list-installed | grep ftdi

As the USB core is not even enumerating devices when they are plugged in, the choice of a high level driver is irrelevant.

The 305X chip's USB module contains "On the Go" logic so it can operate as either a host or a device. This is common on smartphones so the user can either connect the phone to a PC as a device, or use it as a host to access a memory card, etc with the phone OS.

Only host mode is possible the way that routers are wired.

1 Like

@mk24 I didn't see your prior post until after I posted =]

@mucm Whenever you do get the USB portion fixed, here's theOpenWrt driver from FTDI's site (CC'd for MIPS)

Okay thanks. So noting in my OP that (with the OEM provided firmware) the message when USB devices were connected was:

[  429.090000] usb 1-1: new full-speed USB device number 2 using dwc_otg

and googling there does seem to be an older (12.09 timeframe) openwrt package kmod-usb-rt305x-dwc_otg (no longer supported? as its not in the current releases or downloads folder) but this prodded me to list available packages mentioning "otg" (which found none), and "dwc" which found kmod-usb-dwc2 and kmod-usb-dwc3.

root@OpenWrt:/# opkg update
...
root@OpenWrt:/# opkg install kmod-usb-dwc2
Installing kmod-usb-dwc2 (4.14.63-1) to root...
Downloading http://downloads.openwrt.org/releases/18.06.1/targets/ramips/rt305x/packages/kmod-usb-dwc2_4.14.63-1_mipsel_24kc.ipk
Configuring kmod-usb-dwc2.
[  241.945264] kmodloader: loading kernel modules from /etc/modules.d/*
[  241.968572] dwc2 101c0000.otg: Configuration mismatch. dr_mode forced to host
[  242.018950] dwc2 101c0000.otg: DWC OTG Controller
[  242.028572] dwc2 101c0000.otg: new USB bus registered, assigned bus number 1
[  242.042887] dwc2 101c0000.otg: irq 26, io mem 0x101c0000
[  242.057925] hub 1-0:1.0: USB hub found
[  242.076870] hub 1-0:1.0: 1 port detected
[  242.104031] kmodloader: done loading kernel modules from /etc/modules.d/*
root@OpenWrt:/# ls -latr /dev/ |tail -n 5
crw-------    1 root     root      108,   0 Dec  5 19:23 ppp
srw-rw-rw-    1 root     root             0 Dec  5 19:23 log
drwxr-xr-x    3 root     root            60 Dec  6 15:13 bus
drwxr-xr-x    4 root     root          1200 Dec  6 15:13 .
crw-------    1 root     root        4,  64 Dec  6 15:14 ttyS0

(connected USB-RS232 adapter here)

root@OpenWrt:/# [  270.286555] usb 1-1: new full-speed USB device number 2 using dwc2
[  270.557682] ftdi_sio 1-1:1.0: FTDI USB Serial Device converter detected
[  270.571403] usb 1-1: Detected FT232RL
[  270.603772] usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB0
ls -latr /dev/ |tail -n 5
srw-rw-rw-    1 root     root             0 Dec  5 19:23 log
drwxr-xr-x    3 root     root            60 Dec  6 15:13 bus
crw-------    1 root     root      188,   0 Dec  6 15:14 ttyUSB0
drwxr-xr-x    4 root     root          1220 Dec  6 15:14 .
crw-------    1 root     root        4,  64 Dec  6 15:14 ttyS0

(note the chip model actually appears to be a FT232RL from the message above)

Hot diggity, thank you everyone who suggested things here.

1 Like

So, marking this thread solved but I'm not fully done with this router : - (
WAN function moves to LAN1

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.