Linux实现ppp拨号4G模块联网全球APN之越南(Vietnam)

Linux实现ppp拨号4G模块联网全球APN之越南(Vietnam)

有需要其他国家的APN,请留言,我会在评论区回复你们!

越南拥有四个网络运营商:
Viettel
Vinaphone
Mobifone
Vietnamobile

chat脚本配置

chat脚本主要用来通过AT命令完成4G模块的拨号过程
chat还有个常用的关键词为ABORT,这个关键词用于判断何时终止脚本,在AT交互过程中,模块发生错误,并且输出一些错误信息时,ABORT可根据设定的词,停止当前脚本。

以下脚本命名为“gprs-connect-chat”
修改gprs-connect-chat脚本
vi /etc/ppp/peers/gprs-chat-connect

网络运营商APN

Viettel 3G

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","v-internet",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

或者

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","e-connect",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

Viettel 4G

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","e-connect",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

或者

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","v-connect",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

Vinaphone

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","m3-world",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

Mobifone

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","m3-world",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

或者

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","m-wap",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 

Vietnamobile

ABORT "BUSY"
ABORT "NO CARRIER"
ABORT "NO DIALTONE"
ABORT "ERROR"
ABORT "NO ANSWER"
TIMEOUT 120
"" AT
OK \rATZ
# Connection to the network
OK  \rAT+CGDCONT=1,"IP","internet",,0,0
# Dial the number
OK-AT-OK ATDT*99#
CONNECT \d\c 
  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值