Can't ping over PPP on EC25 Pi Base HAT with Twilio SIM

I purchased the Raspberry Pi 3G/4G&LTE Base HAT and attached it to my Raspberry Pi 3 Model B.
It came with a Twilio SIM with $15 of data on it and I configured it for data and activated it.
I have tried QMI and PPP and can’t seem to get either to work (can’t ping www.google.com).

This is my first post on this forum. I have a log file, but I don’t appear to be able to attach it. Therefore, I’ll just paste the results in here. It shows the steps I went through to attempt to get a ping to work via PPP. At the end, I re-enable WiFi (wlan0) on my Pi and show that I can get a ping to work via that interface.

ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
link/ether b8:27:eb:88:6b:75 brd ff:ff:ff:ff:ff:ff
3: wwan0: <BROADCAST,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 1000
link/ether c6:f1:46:57:da:d4 brd ff:ff:ff:ff:ff:ff
inet 169.254.209.147/16 brd 169.254.255.255 scope global noprefixroute wwan0
valid_lft forever preferred_lft forever
inet6 fe80::f053:f24f:bbca:e80c/64 scope link
valid_lft forever preferred_lft forever
4: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
link/ether b8:27:eb:dd:3e:20 brd ff:ff:ff:ff:ff:ff
inet 10.0.0.30/24 brd 10.0.0.255 scope global dynamic noprefixroute wlan0
valid_lft 85239sec preferred_lft 74439sec
inet6 2600:1700:720:9038:7d4:696b:4ce2:6b7d/64 scope global dynamic mngtmpaddr noprefixroute
valid_lft 2439362sec preferred_lft 452162sec
inet6 fe80::bb82:9711:e130:bf26/64 scope link
valid_lft forever preferred_lft forever

sudo ip link set wwan0 down

sudo ip link set wlan0 down

ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
link/ether b8:27:eb:88:6b:75 brd ff:ff:ff:ff:ff:ff
3: wwan0: <BROADCAST,MULTICAST,NOARP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
link/ether c6:f1:46:57:da:d4 brd ff:ff:ff:ff:ff:ff
4: wlan0: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
link/ether b8:27:eb:dd:3e:20 brd ff:ff:ff:ff:ff:ff

sudo pon
pppd options in effect:
debug # (from /etc/ppp/peers/provider)
updetach # (from /etc/ppp/peers/provider)
dump # (from /etc/ppp/peers/provider)
noauth # (from /etc/ppp/peers/provider)
remotename 3gppp # (from /etc/ppp/peers/provider)
/dev/ttyUSB3 # (from /etc/ppp/peers/provider)
115200 # (from /etc/ppp/peers/provider)
lock # (from /etc/ppp/peers/provider)
connect chat -s -v -f /etc/chatscripts/chat-connect -T wireless.twilio.com # (from /etc/ppp/peers/provider)
disconnect chat -s -v -f /etc/chatscripts/chat-disconnect # (from /etc/ppp/peers/provider)
nocrtscts # (from /etc/ppp/peers/provider)
modem # (from /etc/ppp/peers/provider)
asyncmap 0 # (from /etc/ppp/options)
lcp-echo-failure 4 # (from /etc/ppp/options)
lcp-echo-interval 30 # (from /etc/ppp/options)
hide-password # (from /etc/ppp/peers/provider)
novj # (from /etc/ppp/peers/provider)
novjccomp # (from /etc/ppp/peers/provider)
ipcp-accept-local # (from /etc/ppp/peers/provider)
ipcp-accept-remote # (from /etc/ppp/peers/provider)
ipparam 3gppp # (from /etc/ppp/peers/provider)
noipdefault # (from /etc/ppp/peers/provider)
ipcp-max-failure 30 # (from /etc/ppp/peers/provider)
defaultroute # (from /etc/ppp/peers/provider)
usepeerdns # (from /etc/ppp/peers/provider)
noccp # (from /etc/ppp/peers/provider)
noipx # (from /etc/ppp/options)
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;+COPS?;+CGREG?;&D2^M)
expect (OK)
^M
^M
Quectel^M
EC25^M
Revision: EC25AFAR05A04M4G^M
^M
SubEdition: V06^M
^M
+CSQ: 18,99^M
^M
+COPS: 0,0,“Twilio”,7^M
^M
+CGREG: 0,1^M
^M
OK
– got it

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

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

Script chat -s -v -f /etc/chatscripts/chat-connect -T wireless.twilio.com finished (pid 1000), status = 0x0
Serial connection established.
using channel 1
Using interface ppp0
Connect: ppp0 <–> /dev/ttyUSB3
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x8b23cdbf> ]
rcvd [LCP ConfReq id=0xf <asyncmap 0x0> <magic 0x47482eef> ]
No auth is possible
sent [LCP ConfRej id=0xf ]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x8b23cdbf> ]
rcvd [LCP ConfReq id=0x10 <asyncmap 0x0> <magic 0x47482eef> ]
sent [LCP ConfAck id=0x10 <asyncmap 0x0> <magic 0x47482eef> ]
sent [LCP EchoReq id=0x0 magic=0x8b23cdbf]
sent [IPCP ConfReq id=0x1 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns2 0.0.0.0>]
rcvd [LCP DiscReq id=0x11 magic=0x47482eef]
rcvd [LCP EchoRep id=0x0 magic=0x47482eef 8b 23 cd bf]
rcvd [IPCP ConfReq id=0xa]
sent [IPCP ConfNak id=0xa <addr 0.0.0.0>]
rcvd [IPCP ConfNak id=0x1 <addr 25.181.22.254> <ms-dns1 10.177.0.34> <ms-dns2 10.177.0.210>]
sent [IPCP ConfReq id=0x2 <addr 25.181.22.254> <ms-dns1 10.177.0.34> <ms-dns2 10.177.0.210>]
rcvd [IPCP ConfReq id=0xb]
sent [IPCP ConfAck id=0xb]
rcvd [IPCP ConfAck id=0x2 <addr 25.181.22.254> <ms-dns1 10.177.0.34> <ms-dns2 10.177.0.210>]
Could not determine remote IP address: defaulting to 10.64.64.64
local IP address 25.181.22.254
remote IP address 10.64.64.64
primary DNS address 10.177.0.34
secondary DNS address 10.177.0.210

cat /etc/resolv.conf

Generated by resolvconf

nameserver 10.177.0.34
nameserver 10.177.0.210

ping -I ppp0 -c 2 www.google.com
ping: www.google.com: Temporary failure in name resolution

route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 0.0.0.0 0.0.0.0 U 0 0 0 ppp0
10.64.64.64 0.0.0.0 255.255.255.255 UH 0 0 0 ppp0

sudo route add default gw 25.181.22.254

route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 25.181.22.254 0.0.0.0 UG 0 0 0 ppp0
0.0.0.0 0.0.0.0 0.0.0.0 U 0 0 0 ppp0
10.64.64.64 0.0.0.0 255.255.255.255 UH 0 0 0 ppp0

ping -I ppp0 -c 2 www.google.com
ping: www.google.com: Temporary failure in name resolution

sudo ip link set wlan0 up

ping -I wlan0 -c 2 www.google.com
PING www.google.com(2607:f8b0:4002:c02::6a (2607:f8b0:4002:c02::6a)) from 2600:1700:720:9038:7d4:696b:4ce2:6b7d wlan0: 56 data bytes
64 bytes from 2607:f8b0:4002:c02::6a (2607:f8b0:4002:c02::6a): icmp_seq=1 ttl=100 time=50.9 ms
64 bytes from 2607:f8b0:4002:c02::6a (2607:f8b0:4002:c02::6a): icmp_seq=2 ttl=100 time=40.8 ms

www.google.com ping statistics —
2 packets transmitted, 2 received, 0% packet loss, time 115ms
rtt min/avg/max/mdev = 40.836/45.858/50.880/5.022 ms

Dear David,
Thanks for your sharing here.
You can go on your testing, if you any technical issue, you can create topic here. Thanks!

I do not see any problem related to the modem here, your log shows that your modem just works.
Test this SIM card somewhere else to see if Internet access is available right away or if there is any redirection.
Try to ping provider’s DNS servers by IP, find the IP address of operator’s web site and ping it by IP as well.

Thanks jfrog. I just tried another SIM and it’s working. I’ve contacted Twilio about the SIM they gave me. I actually saw it work at one time and then it stopped after I tried installing RaspAP and using the Pi as an AP through the SIM. Something stopped working during that process.

Hi! I’m also experiencing issues for ICMP pings when using my BG95 device as modem. HTTP Traffic is passing by smoothly, but when I ping from cmd to google, the ping reply is not being received.

Any clue? May device being consuming this ping reply instead of forward it to my PC?

Thanks!