Firmware for ESP32-S2 / ESP32-S3 that uses a USB CDC 4G modem only for receiving SMS, then forwards incoming messages over Wi-Fi (e.g. Bark push notifications).
- USB CDC host communication
- Receive SMS (AT URC notification)
- Forward SMS over Wi-Fi (optional Bark push)
- Periodic keepalive SMS (optional, to keep SIM active)
- One-shot test SMS on boot (optional)
- Status LED indicator
Supported ESP SoC:
- ESP32-S2
- ESP32-S3
-
Install ESP-IDF (project requires
>= 4.4.1, seemain/idf_component.yml). -
Export ESP-IDF environment.
-
Set build target:
idf.py set-target esp32s2 # or: idf.py set-target esp32s3 -
Configure in
menuconfig:- Wi-Fi STA credentials used by the firmware:
CONFIG_MODEM_WIFI_SSID/CONFIG_MODEM_WIFI_PASSWORD - SMS forwarding to Bark (optional):
EXAMPLE_BARK_ENABLE/EXAMPLE_BARK_KEY/EXAMPLE_BARK_GROUP - Keepalive SMS (optional):
EXAMPLE_KEEPALIVE_ENABLE/EXAMPLE_KEEPALIVE_TARGET/EXAMPLE_KEEPALIVE_DAYS - One-shot test SMS (optional):
EXAMPLE_TEST_SMS_ON_BOOT
- Wi-Fi STA credentials used by the firmware:
-
Build/flash/monitor:
idf.py build flash monitor
- Do not publish personal credentials in
sdkconfig. This repo usessdkconfig.defaultsas a safe baseline. - SMS sending (keepalive / one-shot test SMS) may incur charges. They are disabled by default.
When EXAMPLE_KEEPALIVE_ENABLE is enabled, the firmware will:
- Sync time via NTP (
CONFIG_NTP_SERVER, defaultntp.aliyun.com) - Store last keepalive timestamp in NVS
- Check every hour (
KEEPALIVE_CHECK_INTERVAL_MS) and send an SMS toEXAMPLE_KEEPALIVE_TARGETonce the interval (EXAMPLE_KEEPALIVE_DAYS) is due
Apache-2.0. See LICENSE, NOTICE, and THIRD_PARTY_NOTICES.md.