您好,Xingwen:
我现在正在做Android 系统ppp的拨号程序,可是我搞了很久一点思路都没有,我想请您帮我一下可以吗?
谢谢您!
Tinary
On Dec 9, 11:15 am, Xingwen Huang <[email protected]> wrote:
> Hi,all
> this is my pppd log. It seems that, radio call the service pppd, but radio
> could not create file in /etc. How can i solve this problem? chmod, chown?
> Failed to create pid file, it will cause "Couldn't attach to PPP", will it?
> D/pppd ( 163): using channel 1
> I/pppd ( 163): Using interface ppp0
> E/pppd ( 163): Failed to create pid file /etc/ppp/ppp0.pid: m
> I/pppd ( 163): Connect: ppp0 <--> /dev/pts/1
> W/pppd ( 163): Warning - secret file /etc/ppp/pap-secrets has world
> and/or group access
>
> D/pppd ( 208): using channel 1
> E/pppd ( 208): Couldn't attach to PPP unit 1: m
> I/pppd ( 163): Modem hangup
> I/pppd ( 163): Connection terminated.
>
> On Wed, Nov 25, 2009 at 11:51 PM, hikeit <[email protected]> wrote:
> > Unfortunately this isn't something I've dealt with personally...
> > But... this thread is dealing with it specifically... are you already
> > on that thread?
>
> >http://groups.google.com/group/android-porting/browse_thread/thread/f...
>
> > -Jesse
>
> > On Nov 24, 10:29 pm, Xingwen Huang <[email protected]> wrote:
> > > Hi, Jesse
> > > Now, i use ttyS1 to make the phonecall, and send sms. It's ok.
> > > another issue, gprs
> > > init.rc
> > > 296 service pppd_gprs /etc/init.gprs-pppd
> > > 297 user root
> > > 298 group radio cache inet misc
> > > 299 disabled
> > > init.gprs-pppd
> > > # so that the exit code of pppd may be retrieved
> > > # this is a workaround for issue #651747
> > > #trap "/system/bin/sleep 1;exit 0" TERM
> > > PPPD_PID=
> > > /system/bin/setprop "net.gprs.ppp-exit" ""
> > > /system/bin/log -t pppd "Starting pppd"
> > > #/system/xbin/pppd $*
> > > /system/xbin/pppd /dev/ttyS1 115200 \
> > > nocrtscts \
> > > modem \
> > > noauth \
> > > debug \
> > > dump \
> > > nodetach \
> > > usepeerdns \
> > > noipdefault \
> > > defaultroute \
> > > user "cmnet" \
> > > 0.0.0.0:0.0.0.0
> > > PPPD_EXIT=$?
> > > PPPD_PID=$!
> > > /system/bin/log -t pppd "pppd exited with $PPPD_EXIT"
> > > /system/bin/setprop "net.gprs.ppp-exit" "$PPPD_EXIT"
>
> > > log:
> > > 876 D/AT ( 42): AT> ATD*99***1#
> > > 877 D/AT ( 42): AT< CONNECT
> > > 878 D/RILJ ( 98): [0038]< SETUP_DEFAULT_PDP {1, /dev/ppp0}
> > > 879 D/GSM ( 98): [PdpConnection] PDP connecting to dataLink in
> > > PdpConnection
> > > 880 I/GSM ( 98): connect PppLink
> > > 881 I/GSM ( 98): set property_pppd_exit_code
> > > 882 I/GSM ( 98): start service pppd_gprs
> > > 883 D/GSM ( 98): [PdpConnection] PDP setup on cid = 1
> > > 884 I/pppd ( 154): Starting pppd
> > > 885 D/vold ( 40): Accepted connection from framework
> > > 886 D/vold ( 40): dispatch_cmd(send_ums_status):
> > > 946 D/AT ( 42): AT< ~ÿ}#À!}!}!} }2}"}&} }*}
> > }}#}$À#}'}"}(}"U<83>~~ÿ}#À!}!}!} }2}"}&} }*} }
> > > }#}$À#}'}"}(}"U<83>~~ÿ}#À!}!}!} }2}"}&} }*} }
> > > }#}$À#}'}"}(}"U<83>~~ÿ}#À!}!}!} }2}"}&} }*} }
> > > }#}$À#}'}"}(}"U<83>~~ÿ}#À!}!}!} }2}"}&} }*} } }#}$À#}'}"}
>
> > > 947 D/AT ( 42): AT< NO CARRIER
>
> > > it seems that the init.gprs-pppd starts, but it gets nothing. Maybe it
> > uses
> > > the same port, though set ttyS1 in init.gprs-pppd, and set ppp0 in
> > > SETUP_DEFAULT_PDP. It's not the proper way!
>
> > > how to implement multiplexer in the kernel??
> > > and what about add a system("/bin/pppd /dev/ttyS1"), or the like in my
> > ril.
>
> > > Thanks & best regards for you
>
> > > On Fri, Nov 20, 2009 at 2:31 AM, hikeit <[email protected]> wrote:
> > > > On our devices the multiplexer was implemented in the kernel...
> > > > Do you intend to you your hardware for making telephone calls (ie is
> > > > it a phone)? If not, you could simply set up dialling and everything
> > > > within pppd scripts.
>
> > > > As for getting the script to run, it might be helpful to learn that
> > > > after cupcake, support for the gprs_pppd service goes away, so you may
> > > > decide to add a system("/bin/pppd /dev/ttyS1"); or the like in your
> > > > RIL (this is what we've done for donut & cupcake support, as some
> > > > releases of cupcake didn't support the gprs_pppd service properly
> > > > either)
>
> > > > -Jesse
>
> > > > On Nov 19, 4:59 am, Xingwen Huang <[email protected]> wrote:
> > > > > Thank you very much! Your advice is helpful.
> > > > > Today, I have worked on linux(ubuntu) to implement gprs with pppd.
> > > > > I have been aware of the process.
> > > > > The problem is that there is no at+cmux in my modem.
> > > > > any idea?
>
> > > > > On Wed, Nov 18, 2009 at 11:45 PM, hikeit <[email protected]> wrote:
> > > > > > I'm seeing two problems here.
> > > > > > First is that it can't start pppd:
> > > > > > -Possibly because you don't have /etc/init.gprs_pppd executable, as
> > > > > > kkw mentioned... grab the script from some other cupcake build and
> > > > > > modify it to point to the correct serial channel
> > > > > > -Also you do need to configure all the scripts and settings in
> > /etc/
> > > > > > ppp (options.<serport>, pap-secrets, chap-secrets, ip-up, ip-down)
>
> > > > > > The second issue is separate. It looks like the PPP traffic is
> > landing
> > > > > > in the current serial session, which will not work at all.
> > > > > > -There should be an AT command when setting up the connection to
> > > > > > redirect it to the modem's secondary serial channel... you'll need
> > to
> > > > > > look at the GPRS spec for your modem to figure out the right
> > command.
> > > > > > -The other possibility is that you haven't implemented the
> > multiplexer
> > > > > > properly yet.
>
> > > > > > -Jesse
>
> > > > > > On Nov 17, 10:33 pm, simon <[email protected]> wrote:
> > > > > > > Hi, all
> > > > > > > I want to start pppd in my system. So, I follow the advice in
> > the
> > > > > > > maillist, but it still doesn't work. It said that Unable to start
> > > > > > > service ctl [pppd_gprs] uid: 1001.
> > > > > > > I found my problem was in the list too, but hadn't soloved.
> > > > > > > What i have done:
> > > > > > > init.rc
> > > > > > > setprop ro.radio.use-ppp yes (it works)
>
> > > > > > > service pppd_gprs /etc/init.gprs_pppd
> > > > > > > user root
> > > > > > > group radio cache inet misc
> > > > > > > disabled
> > > > > > > /system/core/init/property_service.c
> > > > > > > struct {
> > > > > > > const char *service;
> > > > > > > unsigned int uid;
> > > > > > > } control_perms[] = {
> > > > > > > {"pppd_gprs", AID_RADIO },
> > > > > > > {NULL, 0 }
> > > > > > > };
> > > > > > > But it also happend :<3>init: sys_prop: Unable to start service
> > ctl
> > > > > > > [pppd_gprs] uid: 1001 pid:97
>
> > > > > > > any idea please!
>
> > > > > > > log:
> > > > > > > D/AT ( 42): AT> AT+CGQREQ=1
> > > > > > > D/AT ( 42): AT< OK
> > > > > > > D/AT ( 42): AT> AT+CGQMIN=1
> > > > > > > D/AT ( 42): AT< OK
> > > > > > > D/AT ( 42): AT> AT+CGEREP=1,0
> > > > > > > D/AT ( 42): AT< OK
> > > > > > > D/AT ( 42): AT> AT+CGACT=1,1
> > > > > > > D/AT ( 42): AT< OK
> > > > > > > D/AT ( 42): AT> ATD*99***1#
> > > > > > > <3>init: sys_prop: Unable to start service ctl [pppd_gprs] uid:
> > 1001
> > > > > > > pid:97
> > > > > > > D/AT ( 42): AT< CONNECT
> > > > > > > D/RILJ ( 97): [0038]< SETUP_DEFAULT_PDP {1, ppp0}
> > > > > > > D/GSM ( 97): [PdpConnection] PDP setup on cid = 1
> > > > > > > D/AT ( 42): AT< ~ }# !}!}!} }2}"}&} }*} } }#}$ #}'}"}(}"U
> > ~~ }
> > > > > > > # !}!}!} }2}"}&} }*} } }#}$ #}'}"}(}"U ~~ }# !}!}!} }2}"}&} }*}
> > }"}
> > > > > > > (}"U ~~ }# !}!}!} }2}"}&} }*} } }#}$ #}'}"}(}"U ~~ }# !}!}!}
> > }2}"}&}
> > > > }
> > > > > > > *} } }#}$ #}'}"}(}"U ~~ }# !}!}!} }2}"}&} }*} } }#}$ #}'}"!}!}!}
> > > > }2}"}
> > > > > > > &} }*} } }#}$ #}'}"}
> > > > > > > D/AT ( 42): AT< NO CARRIER
>
> > > > > > > Thanks & best regards
>
> > > > > > --
> > > > > > unsubscribe:
> > > > > > [email protected]<android-porting%[email protected]>
> > <android-porting%[email protected]<android-porting%[email protected]>
>
> > > > <android-porting%[email protected]<android-porting%[email protected]>
> > <android-porting%[email protected]<android-porting%[email protected]>
>
> > > > > > website:http://groups.google.com/group/android-porting
>
> > > > --
> > > > unsubscribe:
> > > > [email protected]<android-porting%[email protected]>
> > <android-porting%[email protected]<android-porting%[email protected]>
>
> > > > website:http://groups.google.com/group/android-porting
>
> > --
> > unsubscribe:
> > [email protected]<android-porting%[email protected]>
> > website:http://groups.google.com/group/android-porting
--
unsubscribe: [email protected]
website: http://groups.google.com/group/android-porting