]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/ppp-gprs/files/ppp-gprs.patch
ppp-gprs scripts which uses /dev/ttyS1.
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / ppp-gprs / files / ppp-gprs.patch
1 diff -Naur ppp_gprs_old/etc/ppp/chap-secrets ppp_gprs/etc/ppp/chap-secrets
2 --- ppp_gprs_old/etc/ppp/chap-secrets   1970-01-01 02:00:00.000000000 +0200
3 +++ ppp_gprs/etc/ppp/chap-secrets       2006-10-20 15:08:59.000000000 +0300
4 @@ -0,0 +1,2 @@
5 +# Secrets for authentication using CHAP
6 +# client       server  secret                  IP addresses
7 diff -Naur ppp_gprs_old/etc/ppp/chatscripts/gprs-connect-chat ppp_gprs/etc/ppp/chatscripts/gprs-connect-chat
8 --- ppp_gprs_old/etc/ppp/chatscripts/gprs-connect-chat  1970-01-01 02:00:00.000000000 +0200
9 +++ ppp_gprs/etc/ppp/chatscripts/gprs-connect-chat      2006-10-20 15:08:22.000000000 +0300
10 @@ -0,0 +1,37 @@
11 +# Boilerplate
12 +#
13 +        ABORT           'BUSY'
14 +        ABORT           'NO ANSWER'
15 +        ABORT           'NO CARRIER'
16 +        ABORT           'NO DIALTONE'
17 +        ABORT           '\nRINGING\r\n\r\nRINGING\r'
18 +        SAY             "GPRS modem init: press <ctrl>-C to disconnect"
19 +
20 +# Wake up the modem
21 +#
22 +        TIMEOUT         5
23 +        ''              'AT'
24 +        OK-ATQ0V1&C1-OK 'ATE1'
25 +        ABORT           'ERROR'
26 +        TIMEOUT         12
27 +
28 +# Reset to the factory defaults
29 +# Also, use '+CME ERROR' codes for ME errors, 'ERROR' for syntax errors
30 +#
31 +        OK              'AT&F'
32 +        OK              'AT+CGDCONT=1,"IP","Your-GPRS-APN","0.0.0.0",0,0'
33 +        SAY             "\n + defining PDP context"
34 +
35 +# Attach to the GPRS service.  Strictly, we don't need this step,
36 +# as AT+CGDATA will do it for us, but doing it explicitly makes it
37 +# a little easier to debug.
38 +#
39 +        TIMEOUT         45
40 +        OK              'AT+CGATT=1'
41 +        SAY             "\n + attaching to GPRS"
42 +
43 +# Enter data state
44 +        OK              'ATD*99#'
45 +        SAY             "\n + requesting data connection"
46 +        CONNECT         ''
47 +        SAY             "\n + connected"
48 diff -Naur ppp_gprs_old/etc/ppp/chatscripts/gprs-disconnect-chat ppp_gprs/etc/ppp/chatscripts/gprs-disconnect-chat
49 --- ppp_gprs_old/etc/ppp/chatscripts/gprs-disconnect-chat       1970-01-01 02:00:00.000000000 +0200
50 +++ ppp_gprs/etc/ppp/chatscripts/gprs-disconnect-chat   2006-10-20 15:08:22.000000000 +0300
51 @@ -0,0 +1,10 @@
52 +# Boilerplate
53 +#
54 +        ABORT           BUSY
55 +        ABORT           ERROR
56 +        ABORT           'NO DIALTONE'
57 +        TIMEOUT         30
58 +
59 +# Get some attention
60 +        ''              '+++\c'
61 +        SAY             " + sending break"
62 diff -Naur ppp_gprs_old/etc/ppp/gprs-options ppp_gprs/etc/ppp/gprs-options
63 --- ppp_gprs_old/etc/ppp/gprs-options   1970-01-01 02:00:00.000000000 +0200
64 +++ ppp_gprs/etc/ppp/gprs-options       2006-10-24 02:18:51.000000000 +0300
65 @@ -0,0 +1,13 @@
66 +defaultroute            
67 +nodetach                # Comment out to run in the background
68 +mtu 1400
69 +crtscts
70 +noipdefault
71 +ipcp-accept-local
72 +ipcp-accept-remote
73 +novj
74 +novjccomp
75 +debug                   # Comment out for no debugging info
76 +lock
77 +replacedefaultroute     # update routing table information
78 +usepeerdns              # find out and update the nameservers
79 diff -Naur ppp_gprs_old/etc/ppp/peers/gprs ppp_gprs/etc/ppp/peers/gprs
80 --- ppp_gprs_old/etc/ppp/peers/gprs     1970-01-01 02:00:00.000000000 +0200
81 +++ ppp_gprs/etc/ppp/peers/gprs 2006-10-20 15:07:31.000000000 +0300
82 @@ -0,0 +1,15 @@
83 +#name Your-GPRS-Username # If you dont have a username and password, comment this out
84 +noauth # If you commented out the line above, uncomment this
85 +/dev/ttyS1
86 +
87 +115200                  # Serial port line speed and options
88 +
89 +asyncmap 20A0000
90 +escape FF
91 +
92 +# Generic GPRS options
93 +file /etc/ppp/gprs-options
94 +
95 +# Chat scripts
96 +connect "/usr/sbin/chat -f /etc/ppp/chatscripts/gprs-connect-chat"
97 +disconnect "/usr/sbin/chat -f /etc/ppp/chatscripts/gprs-disconnect-chat"