Skip to content
If this is your first visit, please click here to learn about shipping and delivery.
If this is your first visit, please touch here to learn about shipping and delivery.
SIM7000 cellular HAT with its modem and antenna connectors

Troubleshoot a Cellular HAT on Raspberry Pi: Serial Ports, AT Responses and Linux Logs

A cellular HAT that does not answer a command has a different problem from one that registers on a network but cannot reach a server. Treating both as “no internet” encourages random changes: a new APN, another library, a reboot and perhaps a different antenna. A more productive approach is to identify the last layer that worked.

This guide develops a repeatable diagnostic process for a Raspberry Pi host. PMD Way's cellular HAT collection includes the SIM7000 NB-IoT/eMTC/EDGE/GPRS/GNSS HAT, which provides USB and UART control options. Check the fitted modem variant, board revision and firmware before applying instructions written for another SIM7000 board.

Make a diagnostic record first

Record the Pi model, operating-system version, board revision, modem identification, firmware, chosen interface and power arrangement. Add the SIM provider and the radio technology intended for the deployment. Keep private identifiers out of any version you share publicly.

Confirm that the operator supports the exact modem technology, bands and SIM service at the installation location. A region named in a product description is not a service guarantee, and legacy GSM capability is not a fallback unless a compatible network actually exists. Resolve that prerequisite before interpreting repeated registration failures as a wiring fault.

Separate host access from radio operation

Useful boundaries in a cellular fault report
Layer Evidence of progress What it does not establish
Linux interface The expected port exists and can be opened The modem is responding correctly
AT interface A recognised command receives a valid response The SIM or network is ready
Registration The relevant registration status is accepted A data session or server connection exists
Data connection The selected data service is active DNS, authentication or the application works
Application The intended service acknowledges the operation The system will recover after a fault

Write each result beside its timestamp. “Port opens, AT replies, SIM ready, registration unsuccessful” is a useful starting point for support. “The example does not work” leaves every layer uncertain.

Choose one interface for the first test

Use the board's documented USB path or its documented GPIO UART path, keeping the initial arrangement simple. The Waveshare board manual describes the interfaces and a default 3.3 V UART level translator. Check the actual board configuration before connecting it; a modified 5 V interface setting is inappropriate for a Pi GPIO UART.

The store lists a 5 V board supply. This is separate from UART signalling voltage and from the supply requirements of the bare modem. Follow the schematic for the correct board revision when arranging USB and header power, avoiding unverified combinations of power sources.

For USB, observe which devices appear when the modem is connected. A modem may expose several ports with different purposes. Identify the AT port through the board documentation and system information rather than assuming that the lowest numbered serial device is correct.

For GPIO UART, use the official Raspberry Pi serial configuration documentation. The UART must be enabled and a serial login console must not compete for the same port. Device mappings vary between Pi models: notably, the primary serial alias on a Pi 5 can refer to its debug UART, so an old example using /dev/serial0 does not by itself identify the GPIO-header connection.

Give the command port one owner

A terminal, a Python script, a PPP process and a modem-management service should not independently send commands through the same control channel. Otherwise one program can consume another's reply, leaving a valid modem response looking like a timeout.

Determine which service owns the modem before opening a terminal. If a management service is intentionally controlling the connection, use its supported diagnostics. For a temporary manual test, pause only the relevant service through its documented process and restore it afterwards. Avoid permanently disabling unrelated network services simply to make a test command succeed.

ModemManager's port-detection documentation explains how it discovers and groups ports using Linux device events. Reconnection and re-enumeration therefore matter: a hard-coded device name should not be treated as a permanent identity.

Begin with observation commands

The SIMCom SIM7000 AT command manual documents model and firmware queries and SIM readiness checks. Use the manual matching the installed firmware; the linked revision is a reference, not proof that every firmware behaves identically.

Small initial command set
Command Purpose
AT Check basic command-response communication
AT+CGMM Read model identification
AT+CGMR Read firmware identification
AT+CPIN? Read the SIM password/readiness state

A ready SIM is not proof of registration. Check the registration command appropriate to the active radio service, then the data-session state. Do not copy an old GPRS demonstration's APN, server address or radio-mode settings into an unrelated NB-IoT deployment.

Capture complete responses in software

A useful diagnostic script records transmitted commands and received lines separately. Handle unsolicited modem messages as events rather than assuming every incoming line belongs to the most recent command. Allow the documented operation timeout and distinguish a final error response from silence.

For example, a test log might record a command at 10:02:00, a status event at 10:02:01 and its final response at 10:02:03. A script that reads one line immediately after transmitting can mistake the status event for the answer. Preserve the full sequence while investigating, then build explicit parsing around the modem's response format.

Use logs to choose the next experiment

If the device disappears during transmission, investigate the power path and USB connection before changing application credentials. If the port remains stable and registration works, focus on data configuration, name resolution and the actual endpoint. Change one variable and repeat the same test.

ModemManager's debugging guide distinguishes modem logs from connection-management logs and warns that logs can include sensitive material. Remove SIM identifiers, PINs, credentials and private payloads before sharing a fault report, while retaining timestamps and error codes.

Finally, repeat the successful test after a cold start and a controlled reconnect. Save the working configuration and a short fault-recovery record. That evidence turns a one-off connection into a maintainable Raspberry Pi cellular installation.

Previous article Battery Power for Arduino Projects: Voltage Range, Runtime and Regulator Heat