Connection Retry and Fallback Behaviors
Notecard includes a robust retry and fallback system designed to preserve battery life and maintain connectivity across multiple radio access technologies (RATs). When its primary transport cannot establish or sustain a connection, Notecard automatically retries its connection or falls back to alternative transports based on its capabilities and configuration. Understanding how Notecard defines connection attempts, tracks failures, and chooses subsequent transports can help you predict behavior in remote deployments.
This guide explains how Notecard manages connection retries across cellular, Wi-Fi, LoRa, and satellite/NTN, and fallback behaviors as defined in the card.transport API:
cell-ntn: Cellular with satellite fallback.wifi-cell: Wi-Fi with cellular fallback.wifi-cell-ntn: Wi-Fi primary, cellular secondary, and satellite fallback.wifi-ntn: Wi-Fi with satellite fallback.
Each Notecard radio type (e.g. Wi-Fi, cellular, LoRa, and satellite/NTN) has its own definition of a connection attempt. These attempts determine when failure thresholds are met and when a radio fallback is triggered (if available).
Cellular
Establishing a cellular connection using any cellular-enabled Notecard involves:
- Powering on the modem.
- Registering with the cellular network (which depends on the SIM in use, defaulting to the onboard eSIM).
- Acquiring an IP address.
If any step fails, the entire attempt is considered a failure. What happens next depends on the type of Notecard in use:
- If using Notecard Cellular, after four consecutive failures it will be placed in a network registration penalty box.
- If using Notecard Cellular or Notecard Cell+WiFi with a paired Starnote and two consecutive failures occur, it will proceed to attempt a satellite/NTN connection.
Wi-Fi
A Wi-Fi connection attempt using either Notecard Cell+WiFi or Notecard WiFi involves:
- Scanning for available Wi-Fi access points (APs).
- Joining the configured AP.
- Acquiring an IP address from the AP.
If any step fails, the entire attempt is considered a failure. Notecard will automatically retry its Wi-Fi connection or fallback depending on the Notecard in use:
- If using a Notecard WiFi only, after four consecutive failures it will be placed in a Wi-Fi penalty box for 60 minutes to prevent unnecessary battery drain (reduced to 5 minutes if USB-powered).
- If using a Notecard Cell+WiFi and it is configured to fallback to cellular (the default behavior), it will proceed to attempt a cellular connection after one failure.
- If using a Notecard WiFi with a paired Starnote, after two consecutive failures it will proceed to attempt a satellite connection.
LoRa
A Notecard for LoRa connection attempt involves connecting to a compatible LoRaWAN gateway, pending any applicable duty cycle restrictions. If no gateway is available, the connection is considered a failure.
After ten consecutive failed attempts to join a LoRaWAN gateway, the device will enter a penalty box and automatically attempt to rejoin 60 minutes later to prevent unnecessary battery drain.
There are no supported radio fallback capabilities for Notecard for LoRa.
Satellite
Satellite/NTN connectivity operates differently from traditional networks. Rather than establishing persistent connections, NTN uses a packet-based policy model which involves:
- Powering on the satellite modem.
- Waiting for satellite visibility and lock (this can take multiple minutes, depending upon satellite visibility).
- Sending data packets when a satellite is available.
If Starnote is unable to establish a satellite connection, Notecard will automatically retry Wi-Fi and/or cellular after the penalty box period has expired. The length of time Notecard waits to retry Wi-Fi or cellular is 60 minutes, unless overridden with the card.transport seconds argument.
A successful NTN connection will automatically clear a cellular network registration penalty box, and Notecard will reattempt a cellular connection at the next sync opportunity.
Fallback Summary and Monitoring Tips
The following table summarizes how each transport fallback configuration functions, depending on the Notecard and Starnote in use.
| Transport | Attempts Before Fallback | Previous RAT Retry Behavior |
|---|---|---|
| cell-ntn | 2 cellular failures | Cellular retried after it clears penalty box or a successful NTN connection |
| wifi-cell | 1 Wi-Fi failure | Wi-Fi retried after 60 minutes |
| wifi-cell-ntn | 1 Wi-Fi + 2 cellular failures | Wi-Fi and cellular retried after they clear respective penalty boxes or a successful NTN connection |
| wifi-ntn | 2 Wi-Fi failures | Wi-Fi retried after 60 minutes |
You can use the following Notecard APIs to monitor the health of the transport currently in use:
- Use the card.wireless API to get the last known signal strength and connection status.
- Use the card.wireless.penalty API to view the current penalty box state.
- Use the hub.status API to monitor the status of the Notecard's connection to Notehub.
- Use the hub.sync.status API to check the status of the most recent sync with Notehub.