A7670E Cat-1/GNSS HAT
| ||
Features
- Standard Raspberry Pi 40PIN GPIO extension header, supports Raspberry Pi series boards.
- Supports protocols including TCP/IP, HTTP(s), MQTT(s), FTP(s), and SSL.
- Supports dial-up, telephone calls, and SMS.
- Supports LBS base station positioning, it can get the approximate position info via the mobile network.
- Support GNSS positioning, it can obtain the position via the satellite signal.
- TTS (Text To Speech) feature, texts in Chinese/English can be converted into spoken words.
- Onboard USB interface, for testing AT Commands, network communication, and so on.
- Onboard audio jack can be connected to the headset for sound recording, making telephone calls, listening to the TTS resulting speech, etc.
- Breakout commonly used control pins of the A7670E module, make it easy to connect with host boards like Arduino/STM32.
- SIM card slot, supports 1.8V/3V SIM card.
- 2 x LED indicators, easy to monitor the operating status.
- Comes with online development resources and manual (examples for Raspberry Pi/Jetson Nano/Arduino/ESP32).
Hardware Test
Connection
- Before using the module, you need to prepare the following things except Type C USB cable, GNSS antenna and LTE antenna:
a 4G SIM card (GPRS is available) a headphone cable with microphone (optional)
- In case of power failure, insert the activated 4G SIM card, plug in the headphone cable with microphone (optional), and connect the USB cable to the computer.
- Connect one end of the Type C USB cable to the PC's USB port and the other end to the USB port of the A7670E Cat-1/GNSS HAT. The PWR light will illuminate, and wait approximately 3 to 5 seconds for the module to start. The NET light will remain steady, indicating successful module startup. Wait for the module to automatically search for the network; the NET light will begin to flash.
- Open the device manager; for first-time use, install the Windows driver. Refer to the following image for installation instructions:
Dial-up networking
Dial-up Internet access using LTE Cat-1 network on Windows
After connecting the module to Windows using the Type-C to USB-A cable, use the serial port debugging assistant to open AT COM and send the following command to enable RNDIS internet access:
AT+DIALMODE=0 AT$MYCONFIG="usbnetmode",0
- To test the internet speed, open the speed testing website: www.speedtest.net. Click on the mouse to start the speed test. The following image is an actual screenshot of the speed test:
Note:
Theoretical Upstream and Downstream Speeds for A7670E Module on Cat-1/2G Networks:
Network Format | Uplink | Downlink |
---|---|---|
LTE Cat-1 | 5Mbps | 10Mbps |
EDGE | 236.8Kbps | 236.8Kbps |
GPRS | 85.6Kbps | 85.6Kbps |
However, actual speed tests can be influenced by various factors such as network coverage, congestion, and the status of the base station. Thus, speed test data can vary across different times and locations.
Serial Port Assistant Debug
Refer to the box below for software settings:
Common AT Command Description
Command | Description | Return |
---|---|---|
AT | AT Test Command | OK |
ATE | ATE1 Set Up Echo ATE0 Turn off Echo |
OK |
AT+SIMCOMATI | Query Module Information | OK |
AT+IPREX | Setting the module hardware serial port baud rate | +IPREX: OK |
AT+CRESET | Reset Module | OK |
AT+CSQ | Network signal quality check, returning signal strength value | +CSQ: 25,99 OK |
AT+CPIN? | Check SIM card status, returning 'READY,' indicating the SIM card is recognized and functioning properly | +CPIN: READY |
AT+COPS? | Query the current network operator; upon successful connection, it will return information about the network operator | +COPS: OK |
AT+CREG? | Query network registration status | +CREG: OK |
AT+CPSI? | Query UE (User Equipment) system information. | |
AT+CNMP | Network mode selection command: 2: Automatic 13: GSM only 14: WCDMA only 38: LTE only |
OK |
- For more detailed AT commands, please refer to: A76XX_Series_AT_Command_Manual_V1.01.pdf
TCP/UDP Serial Port Data Transparent Transmission
Command | Description | Return |
---|---|---|
AT+NETOPEN | Open network access mode | OK +NETOPEN: 0 |
AT+CIPRXGET=1 | Buffer access mode | OK |
AT+CIPOPEN=0,"TCP","39.99.166.146",2317 | Set up TCP/IP and Port | +CIPOPEN: 0,0 OK |
AT+CIPSEND=0,9 | Send the data | > |
waveshare | Data content | OK +CIPSEND: 0,9,9 |
AT+CIPCLOSE=0 | Disconnect TCP | +CSQ: 25,99 OK |
AT+NETCLOSE | Close network access mode | OK +NETCLOSE: 0 |
TTS (Text-to-Speech)
The commonly used commands for TTS (Text-to-Speech) are as follows:
AT+CTTSPARAM=? // View the range of adjustable parameters AT+CTTSPARAM=1,3,0,1,1 // Set parameters AT+CTTSPARAM? // Read the current TTS settings AT+CTTS=1,"6B228FCE4F7F75288BED97F3540862107CFB7EDF" // Synthesize and play UCS2 text AT+CTTS=2,"1234567890" // Synthesize and play text
LBS
The common commands for LBS (Location-Based Service) functionality are as follows:
AT+CLBS=? // View the range of parameters that can be set AT+SIMEI=xxxxx // If there is no IMEI, set the IMEI first; xxxxx must correspond to the IMEI code on the module sticker AT+CLBS=2 // Retrieve detailed address AT+CLBS=1 // Retrieve current latitude and longitude
HTTP Request
The common commands of HTTP function as shown below:
AT+HTTPINIT // Enable HTTP AT+HTTPPARA="URL",https://www.waveshare.cloud/api/sample-test/ // Set target URL information AT+HTTPACTION=0 // HTTP Get request AT+HTTPREAD=0,500 // Output HTTP return value AT+HTTPDATA=5,1000 // Set HTTP parameter
MQTT Request
The common commands for GNSS (Global Navigation Satellite System) positioning function are as follows:
AT+CMQTTSTART // Enable MQTT AT+CMQTTACCQ=0,"Waveshare-7670X",0 // Set up ClientID AT+CMQTTCONNECT=0,"tcp://mqtt.easyiothings.com",20,1 // Connect to MQTT server AT+CMQTTTOPIC=0,8 // Set up publishing topic. AT+CMQTTPAYLOAD=0,9 // Set message content AT+CMQTTPUB=0,0,60 // Post a message AT+CMQTTSUB=0,8,1 //Subscribe to topics
GNSS Satellite Positioning
The common commands for GNSS satellite positioning functionality are as follows:
AT+CGNSSPWR=1 // Activate GNSS AT+CGNSSTST=1 // Enable information output AT+CGNSSPORTSWITCH=0,1 // Switch NMEA data output port AT+CGPSINFO // Retrieve satellite latitude and longitude data
Phone Call
Phone call command as shown below:
ATD<phone_number>; //Such as dialing 10000: ATD10000; AT+CHUP //hang up the phone
If the output volume is too small, you can use the following commands to adjust:
AT+COUTGAIN=? //Adjust volume level, (0-7) AT+COUTGAIN=7 //Set volume to 7, return OK
Send and Receive SMS Messages
Send English Messages
1. Set the local SMS message center: AT+CSCA="+8613800755500" + Enter; return OK. <br> 2. AT+CMGF=1: Set the SMS mode as TEXT;<br> 3. AT+CMGS="phone number" <Enter> , set the receiver phone number, and then return: ">"; Send the required message, such as "Send message test!", and Enter is not needed at the end. After editing the message, send it in hexadecimal format with the key value of 1A for sending (1A represents "CTRL+Z" and is used to indicate the module to execute the send operation, alternatively 1B (1B represents "ESC") can be sent to cancel the operation). After successful transmission, the module returns "+CMGS: 15" to confirm successful sending, as shown in the figure below.<br>
Receive English Messages
1. Send a message "This is a receive test for SIM7600X!" on your phone to the test module.
2. When receiving a message, the serial port will automatically report the information. For example, "SM", 20, indicates that there are 20 messages in the Short Message (SM) storage. The message just sent is the 20th message.
3. Read the message: AT+CMGR=20 reads the 20th message (AT+CMGL="ALL" is for reading all messages).
4. Delete the message: AT+CMGD=20 as shown below:
5. Convert the displayed message to text through the code converter.
Raspberry Pi User Guide
Hardware Preparation & Connection
- A Raspberry Pi 4B/Raspberry Pi 5
- A A7670E Cat-1/GNSS HAT
- A 4G communication card
- A LTE antenna
- A GPS ceramic antenna
Connect all of the above hardware as shown below:
UART Configuration
Since the Raspberry Pi's serial port is by default used for terminal debugging, modifying the Raspberry Pi settings is necessary to use the serial port.
- Execute the following command to access the Raspberry Pi configuration:
sudo raspi-config
- Choose Interfacing Options -> Serial -> no -> yes to disable the serial port debugging function.
Sample Demo
- Raspberry Pi code
- Open the Raspberry Pi to run:
mkdir A7670E_Raspberry&&cd A7670E_Raspberry python -m venv env source env/bin/activate pip install pynmea2 pyserial paho-mqtt wget https://files.waveshare.com/wiki/A7670E-Cat-1-GNSS-HAT/A7670E-Cat-1_GNSS_HAT_Demo_Code.zip unzip A7670E-Cat-1_GNSS_HAT_Demo_Code.zip cd Raspberry
GNSS
This demo uses the Pynmea library to parse NMEA 0183 formatted satellite data into latitude and longitude.
cd GNSS python GNSS_example.py
After execution, there is a wait for GPS information retrieval, which can be slower due to reasons like hardware boot-up, weather conditions, or weak satellite signals.
HTTP
This demo is for testing the HTTP interface:
cd HTTP python HTTP_example.py
MQTT
This demo combines Waveshare Cloud platform and uploads the Raspberry Pi running status to the cloud through MQTT.
1. Register and log in to Waveshare Cloud, through the Devices|Attributes interface, select the Raspberry Pi device, and enter the device name through One-Click Add.
2. Obtain MQTT-related parameters of this device from the device list.
3. Fill parameter data into the code.
4. Execute the code on the cloud device.
python MQTT_example.py
5. View specific device dashboard information through the dashboard.
Jetson Nano User Guide
Hardware Preparation & Connection
- A Jetson Nano
- A A7670E Cat-1/GNSS HAT
- A 4G communication card
- A LTE antenna
- A GPS ceramic antenna
Connect all of the above hardware as shown below:
Sample Demo
- Jetson Nano sample demo
- Enter the Raspberry Pi to execute:
mkdir A7670E_jetsonNano&&cd A7670E_jetsonNano python -m venv env source env/bin/activate pip install pynmea2 pyserial paho-mqtt wget https://files.waveshare.com/wiki/A7670E-Cat-1-GNSS-HAT/A7670E-Cat-1_GNSS_HAT_Demo_Code.zip unzip A7670E-Cat-1_GNSS_HAT_Demo_Code.zip cd JestonNano
GNSS
This demo uses the Pynmea library to parse NMEA 0183 formatted satellite data into latitude and longitude.
cd GNSS sudo bash -c 'source ../env/bin/activate && python GNSS_example.py'
HTTP
This demo is for testing the HTTP interface.
cd HTTP sudo bash -c 'source ../env/bin/activate && python HTTP_example.py'
MQTT
This demo combines Waveshare Cloud platform and uploads the Raspberry Pi running status to the cloud through MQTT.
1. Register and log in to Waveshare Cloud. Add the device through the Device|Attributes interface.
2. Retrieve the MQTT-related parameters of this device from the device list.
3. Fill parameter data into the code.
4. Execute the code on the cloud device.
sudo bash -c 'source ../env/bin/activate && python MQTT_example.py'
Arduino/ESP32 User Guide
Hardware Preparation & Connection
- A Jetson Nano
- A LTE antenna
- A GPS ceramic antenna
- A A7670E Cat-1/GNSS HAT
- A 4G communication card
Hardware connection as shown below:
A7670E Cat-1/GNSS HAT |
Arduino |
5V |
5V |
GND |
GND |
RX |
11 |
TX |
10 |
GNSS
This demo uses the TinyGPS++ library to parse NMEA 0183 formatted satellite data into latitude and longitude.
- 1. Enter Arduino IDE, and search TinyGPSPlus in "LIBRARY MANAGER".
- 2. Program the demo to view the serial port debugger content.
Resource
Document
Demo
Tools & Driver
Related Example
Application Note
A7600 & A7670 AT commands reference:
- A76XX_Series_AT_Command_Manual
- A7600_Series_TCPIP_Application Note
- A7600_Series_MQTT(S)_Application Note
- A7600_Series_HTTP(S)_Application Note
- A7600_Series_LBS_Application Note
- A7600_Series_Audio_Application Note
- A76XX_Series_GNSS_Application_Note
- A7600_Series_SSL_Application Note
- A7600_Series_FTP(S)_Application Note
- A7670X_Series_Hardware_Design_V1.03
FAQ
Taking the connection of A7670E Cat-1/GNSS HAT to Raspberry Pi as an example, after parsing the latitude and longitude information of satellite signals through the GNSS_example.py code, you can simply input the latitude and longitude data into a map that supports the NMEA 0183 coordinate system.
Here, we will demonstrate using the map service provided by Waveshare Cloud:
1. Create any type of device on the device attribute page and obtain the MQTT connection data.
2. Input the parameters to the "Raspberry/GPSMaps/A7670E_GNSS_Python.py" demo.
3. Connect the A7670E Cat-1/GNSS HAT to the Raspberry Pi and run the example demo located at Raspberry/GPSMaps/A7670E_GNSS_Python.py. Wait for the satellite signal to be parsed successfully, and you can then view the location information on the map.
{{{5}}}
- Yes, the A7670E suffix E refers to Europe, targeting the European market, and the Asian frequency bands are similar to those in Europe, so it can be used in Asia.
- The US band is different, plus some limitations, so it can't be used.
{{{5}}}
Support
Technical Support
If you need technical support or have any feedback/review, please click the Submit Now button to submit a ticket, Our support team will check and reply to you within 1 to 2 working days. Please be patient as we make every effort to help you to resolve the issue.
Working Time: 9 AM - 6 PM GMT+8 (Monday to Friday)