(A) Add Packages
[kamikaze]$ ./scripts/feeds install huaweiaktbbo
[kamikaze]$ ./scripts/feeds install comgt
[kamikaze]$ ./scripts/feeds chat
(B)make menuconfig
a. [kamikaze]$ make menuconfig
b. select following
network --> ppp --> chat
Libraries --> libusb
kernel modules --> USB Support --> kmod-usb-serial -->kmod-usb-serial-option
Utilities --> "comgt" and " huaweiaktbbo"
(C) make kernel and root file system
[kamikaze]$ make V=99
(D) Get the new Linux and load it to ZNAS board
get the new linux from ~/kamikaze/bin/openwrt-rdc-jffs2-64k-znas.img
(E) Configure for 3G mobile card
1.modify the file --> /etc/modules.d/60-usb-serial as following
usbserial vendor=0x12d1 product=0x1003 maxSize=4096
2. add this file --> /etc/hotplug.d/usb/20-usb-e220 content as following
case "$ACTION" in
add)
[ ${PRODUCT} == "12d1/1003/0" ] && {
echo ${PRODUCT}
/usr/bin/huaweiAktBbo
ifup wan
}
;;
remove)
[ ${PRODUCT} == "12d1/1003/0" ] && {
echo ${PRODUCT}
ifdown wan
}
;;
esac
3.modify the file --> /lib/network/3g.sh as following for disable(without) PINCODE
- PINCODE="$pincode" gcom -d "$device" -s /etc/gcom/setpin.gcom || {
- echo "$cfg(3g): Failed to set the PIN code."
- set_3g_led 0 0 0
- return 1
+ test -z "$pincode" || {
+ PINCODE="$pincode" gcom -d "$device" -s /etc/gcom/setpin.gcom || {
+ echo "$cfg(3g): Failed to set the PIN code."
+ set_3g_led 0 0 0
+ return 1
+ }
4. chmod 777 /lib/network/3g.sh
5.modify the file --> /etc/config/network ,add WAN item as following
config interface wan
option device "/dev/ttyUSB0"
option ifname "ppp0"
option proto "3g"
option apn "internet"
(F) Reboot(Press the reset key or run reboot) and wait the linux start up.
after all plug in the 3G mobile USB Card.
沒有留言:
張貼留言