[arm-allstar] 3G Dongle with Hamvoip on PI

Lawrence Roney roney at chiarappa.com
Fri Jul 19 12:46:01 EDT 2019


Hi Rachid, 

If I understand correctly, you want to use a cellular dongle (USB modem) that plugs into the Pi, vs. an external cellular/Wi-Fi hotspot.  I've had good success with a Huawei E397u-53 dongle for this purpose.  It is self-contained, powered directly from the Pi, and does not require the use of Wi-Fi from a separate hotspot device.

In the USA, I have it activated on a T-Mobile LTE, unlimited $10 per month plan (2GB high speed, then rate limited, but the limited speed is more than adequate for Allstar VoIP traffic)

To set it up:
You need to install the USB Modeswitch utility to force the dongle into modem mode.  They usually start out in CD ROM emulation mode to load their Windows drivers, etc.   This is done with:  pacman -S usb_modeswitch

Then, install a PPP stack on the Pi with:  pacman -S ppp   (this may already be included in the recent HamVoIP distribution)

You will need to create an /etc/chatscripts/carrier_name configuration file  (where "carrier_name" is the name of your cell provider, ex. Verizon, T-Mobile etc.)  This file sends the connection setup, "AT" commands to the modem's dialer and looks for the expected responses.  This file also contains the carrier specific access point name (APN) information that tells the modem what to "dial" to join the carrier's mobile data network.  For example, my T-Mobile chatscript file has the line:  OK AT+CGDCONT=1,"IP","fast.t-mobile.com"   YOU WILL NEED TO RESEARCH YOUR CARRIER'S SPECIFIC APN AND THE ZTE MODEM COMMANDS

You will need to create an /etc/ppp/peers/carrier_name file.  This file contains the configuration settings for the PPP session.

Archlinux will create a new ppp0 interface for the modem.  (Note: Make sure the eth0 interface is set to DHCP and is unplugged, otherwise the default route will not change to ppp0)

To connect, at the Linux prompt start the PPP session by typing: pon carrier_name   (where "carrier_name" is the filename of the chatscript and peers files created in the previous steps)

To disconnect, at the Linix prompt, type: poff

On my Pi, I added automatic startup configurations in /etc/rc.local and on-demand DTMF macro sequences in /etc/asterisk/rpt.conf  to bring up/down the PPP connection.

Hope this helps to get you started.  Email me directly if you would like specific notes and chatscript file examples for how I setup the Huawei E397u-53 (available on Amazon) for use on the US T-Mobile LTE network.

73,
Lawrence - N6YFN





More information about the ARM-allstar mailing list