Skip to content

SNMP_Embedded v3.3.3 — Initial Release

Choose a tag to compare

@syntax1269 syntax1269 released this 06 Sep 01:15
· 13 commits to main since this release

SNMP_Embedded is a memory-safe SNMPv2c agent library for Arduino on ESP32 and ESP8266, built for long-term unattended operation on small MCUs. This is the initial baseline release.

Highlights

  • Deterministic memory, zero runtime heap. All packet memory lives in a fixed-slot ASN.1 pool that is allocated once at boot — no malloc on the request path, no fragmentation, no transient spikes.
  • Derived sizing, not magic numbers. The varbind cap and pool size are computed at compile time from the packet budget (default 1400 B packets → 8-varbind cap, 142 slots × 312 B); static_assert guards fail the build if any container outgrows its slot.
  • Loud, RFC-correct failure modes. Over-cap GETBULK and over-budget responses answer tooBig instead of silently truncating; double-release and pool exhaustion are detected and logged, never swallowed.
  • Hardware-proven. Flood soaks on a 1 MB ESP8266 board (200 ms between operations, 30+ minutes sustained) finished with zero crashes and zero pool alarms; heap stays flat by construction.
  • CI-enforced. Every push runs arduino-lint, a 175-assertion host test suite, and an ESP8266 + ESP32 example compile matrix.

What's included

  • SNMPv2c agent: GET, GETNEXT, GETBULK, SET, traps, and informs
  • RFC1213 system group plus user-defined custom OID handlers
  • Two examples (ESP32_SNMP, SNMP_Sensor) that compile out of the box
  • Full API and memory-model documentation in the README

Measured footprint (examples as shipped)

Target Example Result
ESP32 ESP32_SNMP 70% program / 15% RAM
ESP8266 (d1_mini) both examples compile clean

Install

  • Arduino IDE (Library Manager): Tools → Manage Libraries… → search SNMP_Embedded → Install (indexed as of the acceptance of registry PR arduino/library-registry#9032).
  • Manual: Code → Download ZIP, then Sketch → Include Library → Add .ZIP Library…
  • PlatformIO: add to lib_deps:
    lib_deps =
        https://github.com/syntax1269/SNMP_Embedded.git#v3.3.3
    Pin the tag (#v3.3.3) for reproducible builds; use the bare URL to track main (not recommended for production).

Verify your build

git clone https://github.com/syntax1269/SNMP_Embedded
cd SNMP_Embedded/tests && make ci-test

The suite prints a color-coded summary in a terminal (green pass / yellow warnings / red failures); piped or CI output stays plain text for clean logs and diffs.

Version numbering

v3.3.3 continues the version lineage of the codebase this library was derived from; it is the first SNMP_Embedded release.

Provenance

Begins as a fork of Arduino_SNMP v2.1.0 by Aidan Cyr (MIT). The majority of the engine has since been rewritten — pool allocator, derived sizing, trap/inform lifecycle, and the entire verification infrastructure. Attribution is retained in the LICENSE per the MIT license.