Skip to content
/ BBB4G Public

Beagle Bone Black interfacing with 4G Module

License

Notifications You must be signed in to change notification settings

2AB5/BBB4G

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 

Repository files navigation

BBB4G

The aim of this repo is to help people interface their BBB with any1 4G modules available in the market.

You can connect your 4g Module with your BBB via UART or via an USB interface but for both the process is same you should only change a line of code to switch between them.

1. Check your device connection

Use the following command to list peripherals connected via serial or USB ports:

sudo dmesg | grep tty

For USB-connected modules, on modern kernels, the output typically resembles:

[   55.066972] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB0
[   55.082450] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB1
[   55.111827] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB2

here,
/dev/ttyUSB0 is for diag port.
/dev/ttyUSB1 is AT ports you can use it with screen/dev/ttyUSB1 or minicom to test with AT Commands.
/dev/ttyUSB2 is Modem port for ppp-dial.
/dev/ttyUSB3 appears for module with GSM/GNSS connectivity

if you are using UART make sure to configure your UART pins accordingly,

config-pin p9.11 uart
config-pin p9.13 uart 

2. PPP dialup connection setup

in the sub-folder /etc-ppp-peers there are three different files

cd /etc/ppp/peers
nano connect

navigate to the sub-directory and use the nano command to create the files and copy the contents of them there, the naming doesnt matter as long as you have renamed them in the simcom-pppd file.

3. Connect

pppd call simcom-pppd &

once the connection is setup successfully you can use

ifconfig ppp0  

returns ip-info

cat/etc/resolv.conf 

returns DNS server information

route -n 

info about route table

ping google.com 

check connection

4. Notes

The first time I tried this with UART, I forgot to configure the 4G module's RESET pin. As a result, when I tried to reconnect, it never worked. It was such a small detail that slipped by, so be sure to take care of that.

5. Auto-connect upon reboot

To make things even simpler you can use crontab to automate the connection with 4G module whenever your BBB boots up, to do this you need to setup a cron job.

  1. Install crontab if you dont have it
 sudo apt-get install crontab
  1. Create a scrpit file (eg. connect.sh)
nano /path/to/your/connect.sh
#!/bin/bash
pppd call simcom-pppd &

if you are connecting it via UART make sure to add your config-pin command aswell.
3. Make it executable

chmod +x /path/to/your/connect.sh
  1. Edit the cron tab file : add this job.
crontab -e
@reboot /path/to/your/connect.sh

6. References

SIMCom Wireless Solutions, SIMCom A7600 Linux USB User Guide, Version 1.01.03, 2020. [Online]. Available: https://www.cika.com/soporte/Information/GSMmodules/A76xx/SIMCOM_A7600_Linux_USB_User_Guide_V1.01.03.pdf

Footnotes

  1. So far I have tested this with 4 different simcom 4g modules; SIM A7672S - Parry tech, SIMA7670C - Adiy, SIM A7672S - Ktron, SIM7600EI.

About

Beagle Bone Black interfacing with 4G Module

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published