Quectel EC25 PPP connect Failure

Hello,
Scripts for your reference:-

root@xxx:/etc/ppp/peers# cat quectel-chat-connect
ABORT “BUSY”
ABORT “NO CARRIER”
ABORT “NO DIALTONE”
ABORT “ERROR”
ABORT “NO ANSWER”
TIMEOUT 30
‘’ AT
OK ATE0
OK ATI;+CSUB;+CSQ;+CPIN?;+COPS?;+CGREG?;&D2
OK AT+CGDCONT=1,“IP”,“airtelgprs.com
OK ATD*99#
CONNECT ‘’
root@xxx:/etc/ppp/peers#

root@xxx:/etc/ppp/peers# cat quectel-chat-disconnect
ABORT “ERROR”
ABORT “NO DIALTONE”
SAY "
Sending break to the modem
"
“” +++
“” +++
“” +++
SAY "
Goodbay
"
root@xxx:/etc/ppp/peers#

root@xxx:/etc/ppp/peers# cat quectel-ppp
/dev/ttyS8
115200
user “abc”
password “123”
connect ‘/usr/sbin/chat -s -v -f /etc/ppp/peers/quectel-chat-connect’
disconnect ‘/usr/sbin/chat -s -v -f /etc/ppp/peers/quectel-chat-disconnect’
hide-password
noauth
debug
defaultroute
noipdefault
root@xxx:/etc/ppp/peers#

Dear Mahesh,
Just as you have said that if you do not send ATD command and just call the PPP script, it can dial up successful and can get the IP address as the following(ppp0). It is normal. After you get the IP address, you can access the internet.
image

After that you issue is can not kill pppd process ? Whether my understanding is right?
you can try to use the following command to kill pppd process. Thanks!
image

Hello Kyson,

I am stuck at running the pppd call command for the script.
Attaching the logs:-

root@iSense-V4:/etc/ppp/peers# pppd call quectel-ppp
abort on (BUSY)
abort on (NO CARRIER)
abort on (NO DIALTONE)
abort on (ERROR)
abort on (NO ANSWER)
timeout set to 30 seconds
send (AT^M)
expect (OK)
^M
OK
– got it

send (ATE0^M)
expect (OK)
^M
^M
OK
– got it

send (ATI;+CSUB;+CSQ;+CPIN?;+COPS?;+CGREG?;&D2^M)
expect (OK)
^M
^M
Quectel^M
EC25^M
Revision: EC25EFAR06A02M4G^M
^M
SubEdition: V06^M
^M
+CSQ: 28,99^M
^M
+CPIN: READY^M
^M
+COPS: 0,0,“IND airtel airtel”,7^M
^M
+CGREG: 0,1^M
^M
OK
– got it

send (AT+CGDCONT=1,“IP”,“airtelgprs.com”^M)
expect (OK)
^M
^M
OK
– got it

send (ATD*99#^M)
expect (CONNECT)
^M
^M
CONNECT
– got it

send (^M)
Script /usr/sbin/chat -s -v -f /etc/ppp/peers/quectel-chat-connect finished (pid 530), status = 0x0
Serial connection established.
using channel 7
Using interface ppp0
Connect: ppp0 <–> /dev/ttyS8
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0xfd072a29> ]
rcvd [LCP ConfReq id=0x0 <asyncmap 0x0> <magic 0x5ab0cdbc> ]
sent [LCP ConfAck id=0x0 <asyncmap 0x0> <magic 0x5ab0cdbc> ]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0xfd072a29> ]
rcvd [LCP DiscReq id=0x1 magic=0x5ab0cdbc]
rcvd [CHAP Challenge id=0x1 , name = “UMTS_CHAP_SRVR”]
sent [CHAP Response id=0x1 <1a468b8053042e4c47c91e5f415d5007>, name = “abc”]
rcvd [CHAP Success id=0x1 “”]
CHAP authentication succeeded
CHAP authentication succeeded
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0>]
rcvd [LCP ProtRej id=0x2 80 fd 01 01 00 0f 1a 04 78 00 18 04 78 00 15 03 2f]
Protocol-Reject for ‘Compression Control Protocol’ (0x80fd) received
rcvd [IPCP ConfReq id=0x0]
sent [IPCP ConfNak id=0x0 <addr 0.0.0.0>]
rcvd [IPCP ConfRej id=0x1 <compress VJ 0f 01>]
sent [IPCP ConfReq id=0x2 <addr 0.0.0.0>]
rcvd [IPCP ConfReq id=0x1]
sent [IPCP ConfAck id=0x1]
rcvd [IPCP ConfNak id=0x2 <addr 100.76.53.234>]
sent [IPCP ConfReq id=0x3 <addr 100.76.53.234>]
rcvd [IPCP ConfAck id=0x3 <addr 100.76.53.234>]
Could not determine remote IP address: defaulting to 10.64.64.64
not replacing default route to eth0 [10.1.1.1]
local IP address 100.76.53.234
remote IP address 10.64.64.64
Script /etc/ppp/ip-up started (pid 533)
Script /etc/ppp/ip-up finished (pid 533), status = 0x0
rcvd [LCP TermReq id=0x3]
LCP terminated by peer
Connect time 29.3 minutes.
Sent 0 bytes, received 0 bytes.
Script /etc/ppp/ip-down started (pid 537)
sent [LCP TermAck id=0x3]
Script /etc/ppp/ip-down finished (pid 537), status = 0x0
Connection terminated.
abort on (ERROR)
abort on (NO DIALTONE)
send (+++^M)k to the modem
send (+++^M)
send (+++^M)
Script /usr/sbin/chat -s -v -f /etc/ppp/peers/quectel-chat-disconnect finished (pid 542), status = 0x0
Serial link disconnected.
Modem hangup
root@iSense-V4:/etc/ppp/peers#

You can see from the log that it was connected for 29 min. And it got disconnected automatically.
During that 29 min, even though ppp0 was available in ifconfig, the Internet was not accessible.

Dear Mahesh,
Please confirm whether it is must disconnect after a certain amount of time, like you said 29 minutes. If it is, it is better to confirm whether there have any limit of the SIM card or the network.
And you can try to access the internet all the time to confirm whether there still have such issue, and also can try whether it can restore by itself or you must kill the pppD process then call again. Thanks!
By the way, you also can forbiden eth0 to have a try. Thanks!

Dear Kyson,
All I am trying to do is to Connect the Modem using the serial port to the Internet using pppd, which is not happening even with following all the given documents.

pppd and chat script are not running for a long time. I have already shared with you the logs.
I am sharing it here again. Please go through it and help me out to fix this.

root@iSense-V4:/etc/ppp/peers# pppd call quectel-ppp
abort on (BUSY)
abort on (NO CARRIER)
abort on (NO DIALTONE)
abort on (ERROR)
abort on (NO ANSWER)
timeout set to 30 seconds
send (AT^M)
expect (OK)
^M
OK
– got it

send (ATE0^M)
expect (OK)
^M
^M
OK
– got it

send (ATI;+CSUB;+CSQ;+CPIN?;+COPS?;+CGREG?;&D2^M)
expect (OK)
^M
^M
Quectel^M
EC25^M
Revision: EC25EFAR06A02M4G^M
^M
SubEdition: V06^M
^M
+CSQ: 28,99^M
^M
+CPIN: READY^M
^M
+COPS: 0,0,“IND airtel airtel”,7^M
^M
+CGREG: 0,1^M
^M
OK
– got it

send (AT+CGDCONT=1,“IP”,“airtelgprs.com”^M)
expect (OK)
^M
^M
OK
– got it

send (ATD*99#^M)
expect (CONNECT)
^M
^M
CONNECT
– got it

send (^M)
Script /usr/sbin/chat -s -v -f /etc/ppp/peers/quectel-chat-connect finished (pid 530), status = 0x0
Serial connection established.
using channel 7
Using interface ppp0
Connect: ppp0 <–> /dev/ttyS8
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0xfd072a29> ]
rcvd [LCP ConfReq id=0x0 <asyncmap 0x0> <magic 0x5ab0cdbc> ]
sent [LCP ConfAck id=0x0 <asyncmap 0x0> <magic 0x5ab0cdbc> ]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0xfd072a29> ]
rcvd [LCP DiscReq id=0x1 magic=0x5ab0cdbc]
rcvd [CHAP Challenge id=0x1 , name = “UMTS_CHAP_SRVR”]
sent [CHAP Response id=0x1 <1a468b8053042e4c47c91e5f415d5007>, name = “abc”]
rcvd [CHAP Success id=0x1 “”]
CHAP authentication succeeded
CHAP authentication succeeded
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0>]
rcvd [LCP ProtRej id=0x2 80 fd 01 01 00 0f 1a 04 78 00 18 04 78 00 15 03 2f]
Protocol-Reject for ‘Compression Control Protocol’ (0x80fd) received
rcvd [IPCP ConfReq id=0x0]
sent [IPCP ConfNak id=0x0 <addr 0.0.0.0>]
rcvd [IPCP ConfRej id=0x1 <compress VJ 0f 01>]
sent [IPCP ConfReq id=0x2 <addr 0.0.0.0>]
rcvd [IPCP ConfReq id=0x1]
sent [IPCP ConfAck id=0x1]
rcvd [IPCP ConfNak id=0x2 <addr 100.76.53.234>]
sent [IPCP ConfReq id=0x3 <addr 100.76.53.234>]
rcvd [IPCP ConfAck id=0x3 <addr 100.76.53.234>]
Could not determine remote IP address: defaulting to 10.64.64.64
not replacing default route to eth0 [10.1.1.1]
local IP address 100.76.53.234
remote IP address 10.64.64.64
Script /etc/ppp/ip-up started (pid 533)
Script /etc/ppp/ip-up finished (pid 533), status = 0x0
rcvd [LCP TermReq id=0x3]
LCP terminated by peer
Connect time 29.3 minutes.
Sent 0 bytes, received 0 bytes.
Script /etc/ppp/ip-down started (pid 537)
sent [LCP TermAck id=0x3]
Script /etc/ppp/ip-down finished (pid 537), status = 0x0
Connection terminated.
abort on (ERROR)
abort on (NO DIALTONE)
send (+++^M)k to the modem
send (+++^M)
send (+++^M)
Script /usr/sbin/chat -s -v -f /etc/ppp/peers/quectel-chat-disconnect finished (pid 542), status = 0x0
Serial link disconnected.
Modem hangup
root@iSense-V4:/etc/ppp/peers#

Dear Kyson,
The company I am working in is going to use this Modem in its Products, which will be more than 1000 Modem Requirements from you guys.
So, can you Please help me out here to make this Modem work?

Dear Mahesh,
From the log you provide, we just can judge that the module have not dial up successful, because, it have not get the DNS address. So please help to double check the following information:
1.Use the following command to save the ppp log:
tail -f /var/log/syslog
2. Check the IP:
ifconfig
3. check the route, if PPP0 is not defalut route, you should add it, do not forget to ifconfig down eth0
route
4.Modify DNS setting file:
/etc /resolv.conf
Examples:
/system/etc/ppp # vi /etc/resolv.conf
nameserver 8.8.8.8
nameserver 8.8.4.4

If all the above confirmation still cannot solve your issue, it is better to send email to support@quectel.com to get local support. You know if you want to order our module, you still need to contact our local FAE or sales. Thanks

Hello Kyson,
Thank you for the information.
I made the PPP0 as default route, Modem got connected to the Network and was able to ping to the URLs with resolv.conf file just the way by given by you.

Is there any way to make the resolv.conf file to get updated automatically by detecting the network , without making the changes to the file Manually?

Dear Mahesh,
Thanks for your update, i am glad to hear the good news.
Normally, it is no need to modify the resolv.conf file manually, it should have automatically. But some system may need have such issue, you may just need to modify one time, no need to modify again even restart your system. Please note it is the system issue, we just can solve it with such method. Thanks!

Hello Kyson,

  1. Are the DNS server IPs dependent on the Country region?
  2. Are the DNS server IPs dependent on the SIM Networks which we are using?

Or is it Universal in both the conditions?

Dear Mahesh,
1.it is the network software configuration, normally it depends on the network supplier.
2.as you know, there are two kinds of DNS server, one is common DNS server, the other one is provid by the operator. So, it is hard to say it is dependent on the SIM network or not. Thanks!

Dear Kyson,
pppd part I have completed and thanks for your support on that.

Now I am working on the SMS part.
Can you please explain the difference between the below:-

“SM” - (U)SIM message storage
“ME” - Mobile equipment message storage
“MT” - Same as “ME” storage

And what is the Maximum Size for One Message? as the Number of messages can be stored is given as 255 in the below.

AT+CPMS?
+CPMS: “ME”,0,255,“ME”,0,255,“ME”,0,255

and also what are mem1, mem2 and mem3 related to SIM SMS Memory??

Dear Mahesh,
If it is different question, it is better to raise a new topic.
For your question, please know that SM means that the SMS message can store at USIM memory, and ME or MT means that the SMS message can be store at module or your system memory except USM memory.
And the max size of one SMS message is 160 character in GSM coding, and 140 character in 8bit coding, and 70 character in UCS2 coding. Thanks!
About AT+CPMS? command,please check the following explanation. Thanks!

Hey Kyson,
Thank you for your response and details.
If I have any other questions, I will create a new topic according to it.

Thank You.

Hey Kyson,
Is there any way to shift to command mode while the pppd is running in the background without stopping the pppd?
What I Want to know is, is it possible to send any AT commands or Send/Receive SMS while the pppd is running in the background?

Dear Sir,
You can try to add “&” when dial up, which can run PPP in background without stop pppd.
Please note that AT command is via USB AT port or UART port, PPP is via USB modem port. If they use different port, of course can send any “AT commands or Send/Receive SMS” while the pppd is running in the background.Thanks!

Dear Kyson,
We are using, only UART Port for running both PPPd and AT commands, the USB port is not used for anything.
Once I make the PPPD run in the background by using ‘&’, after that what ever AT Commands I send via the Same UART Port, I am not getting any response for them.

Dear Sir,
If you just use UART port in Linux system, for your application, you’d better to use CMUX function. Please check the following link and document about CMUX. Thanks!
Quectel_AndroidLinux_CMUX_Driver_User_Guide_V1.0.pdf (444.7 KB)

https://cnquectel-my.sharepoint.com/:u:/g/personal/asean-fae_quectel_com/EeU1Bkc7rupGo9EQFqR7kkoByac16t4aNVUAsucPilXnPQ?e=ZM3KKP

Hello Kyson,
I am going through the Source code which you have provided.

Can I edit the source according to my requirement or the same what you have provided is enough?