硬件平台:瑞泰DM365开发板
开发板内核:Linux 2.6.18
DVSDK版本:2_10_00_17
//
问题2:
Cannot open /dev/ttyUSB0: Device or resource busy
Cannot open /dev/ttyUSB1: Device or resource busy
Cannot open /dev/ttyUSB2: Device or resource busy
……
*********************************华丽的分割线****************************************
继上一篇《 DM365+EC122调试(一)》,这篇继续在DM365板子上调试EC122。现在开发板加载的是NandFlash上的文件系统。
第一步,运行 usb_modeswitch -W
Target device description data
-------------------------
Manufacturer: HUAWEI TECHNOLOGIES
Product: HUAWEI Mobile
Serial No.:
-------------------------
Found correct target device
Mode switch succeeded. Bye.
Oh, Shit ! 竟然出现上面这些信息,而且还没有引起OOM Killer。于是reboot,再次usb_modeswitch -W,仍然没有引起OOM Killer。太好了,似乎感觉马上就能调好3G模块了。在 /dev/tts/ 目录下多了 USB0、USB1、 USB2、 USB3这么四个节点。
恩,试试 wvdial 吧。于是运行 wvdialconf /etc/wvdial.conf ,新问题又来了,就是上面的那个“问题2 ”。我的天啊,不要这么折磨我好吗,我好想赶紧写论文啊!
坚持不懈的搜索网上的解决办法,终于看到这么个标题《 [SOLVED] HSDPA Huawei E220 and wvdial: Device or resource busy》。此时,看到那个 [SOLVED]是多么的让我欣喜啊!引用其中的关键内容:
*********************************华丽的分割线****************************************
Hey, I just recently went through this and it nearly drove me nuts, had the 'device busy' problem even for root. After many, many days and several aneurysms I finally found my problem, maybe this will help you too.
It turned out that wvdial tries to create a lock file for the usb device in '/var/lock', but for some reason when I looked in '/var' I had no 'lock' directory. I checked my other Arch machine and it has a '/var/lock' directory, so I'm not sure where this one disappeared to.
Soon as I created ' /var/lock ' wvdial worked perfectly. Hope this helps you out.
Cheers,
Wittfella
Last edited by Wittfella (2009-06-16 15:45:48)
----From https://bbs.archlinux.org/viewtopic.php?id=74163
*********************************华丽的分割线****************************************
赶紧的查看自己的文件系统,哦,的确没有找到' /var/lock ',果断创建吧。并且,手动的在 /dev 目录下建立了 ttyUSB0 ttyUSB1 ttyUSB2 ttyUSB3这四个符号链接,分别对用 /dev/tts/ 目录下的 USB0 USB1 USB2 USB3。重新运行 wvdialconf /etc/wvdial.conf 正确找到了 ttyUSB0 ,然后就是运行 wvdial ,一切OK, 拨号成功!
*********************************华丽的分割线****************************************
--> WvDial: Internet dialer version 1.61
--> Warning: section [Dialer [08]conf] does not exist in wvdial.conf.
--> Warning: section [Dialer /etc/wvdial.conf] does not exist in wvdial.conf.
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
OK
--> Modem initialized.
--> Sending: ATDT#777
--> Waiting for carrier.
ATDT#777
CONNECT 3100000
--> Carrier detected. Starting PPP immediately.
--> Starting pppd at Thu Jan 1 00:17:15 1970
--> Pid of pppd: 833
--> Using interface ppp0
--> pppd: [08]x[03]
--> pppd: [08]x[03]
--> pppd: [08]x[03]
--> pppd: [08]x[03]
--> pppd: [08]x[03]
--> pppd: [08]x[03]
--> local IP address 49.92.62.141
--> pppd: [08]x[03]
--> remote IP address 172.25.8.25
--> pppd: [08]x[03]
--> primary DNS address 218.2.135.1
--> pppd: [08]x[03]
--> secondary DNS address 61.177.7.1
--> pppd: [08]x[03]
Caught signal 2: Attempting to exit gracefully...
--> Terminating on signal 15
--> pppd: [08]x[03]
--> Connect time 0.5 minutes.
--> pppd: [08]x[03]
--> pppd: [08]x[03]
--> Disconnecting at Thu Jan 1 00:17:45 1970
#
*********************************华丽的分割线****************************************
痛苦的调试过程终于有了一些令人稍稍满意的结果了。
好了,本文结束了,今后还会有其他调试记录!
2012-05-04