sensor

sensor is a command for Claude Code from HermeticOrmus/LibreEmbed-Claude-Code. It costs 22 tokens per session (1,008 once invoked), scanned A, original, MIT.

A command for generating embedded sensor code from a datasheet or requested processing method. It supports driver creation, calibration, digital filters and motion-sensor fusion.

In plain words
What is it for?
Use it to generate I2C or SPI drivers, calibration routines, moving-average, median, Butterworth or Kalman filters, and accelerometer-gyroscope-magnetometer fusion.
Why use it?
It gives a direct way to request common sensor-integration tasks without describing the implementation from scratch. The supplied information does not state how the generated code is tested.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Part of the sensor-integration plugin — 1 skill, 1 command, 1 agent shipped together

Good fit Use it to generate I2C or SPI drivers, calibration routines, moving-average, median, Butterworth or Kalman filters, and accelerometer-gyroscope-magnetometer fusion.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/hermeticormus/libreembed-claude-code/sensor
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/HermeticOrmus/LibreEmbed-Claude-Code

Made for: Claude Code.

Or install sensor-integration, the plugin that ships this one along with the rest of its 1 skill, 1 command, 1 agent.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for sensor

README.md
[![agentmods](https://agentmods.dev/badge/commands/hermeticormus/libreembed-claude-code/sensor/github.svg)](https://agentmods.dev/commands/hermeticormus/libreembed-claude-code/sensor)
Your own site
<a href="https://agentmods.dev/commands/hermeticormus/libreembed-claude-code/sensor"><img src="https://agentmods.dev/badge/commands/hermeticormus/libreembed-claude-code/sensor/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for sensor

Your own site · 80×15
<a href="https://agentmods.dev/commands/hermeticormus/libreembed-claude-code/sensor"><img src="https://agentmods.dev/badge/commands/hermeticormus/libreembed-claude-code/sensor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 22 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,008 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00022 $0.01008
Opus 5.5 $0.00009 $0.00403
Sonnet 5.5 $0.00004 $0.00202
Haiku 4.5 $0.00002 $0.00101

Measured 15d ago against content hash 739c3ca24b07, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

sensor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 15d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/sensor-integration/commands/sensor.md · 117 lines

How it starts

The opening of the file, as written. The whole thing — 117 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/sensor

Sensor integration command: driver generation, calibration, filtering, fusion.

Trigger

/sensor <action> [options]

Actions

driver

Generate a sensor driver from a datasheet description.

/sensor driver --part bme280 --bus i2c --addr 0x76
/sensor driver --part icm42688 --bus spi --mode 0
/sensor driver --part ads1115 --bus i2c --channels 4

calibrate

Generate calibration code for a sensor.

/sensor calibrate --method 2-point --units celsius --range "-40,85"
/sensor calibrate --method multipoint --points 5 --nvm-address 0x08080000
/sensor calibrate --method temperature-compensation --coeff 0.05

filter

Generate a digital filter for sensor data.

/sensor filter --type moving-average --window 8 --dtype int32
/sensor filter --type kalman-1d --q 1 --r 10
/sensor filter --type median --window 5
/sensor filter --type butterworth --order 2 --cutoff 10Hz --sample 100Hz

fuse

Generate IMU sensor fusion code.

/sensor fuse --sensors accel+gyro --filter complementary --dt 0.01
/sensor fuse --sensors accel+gyro+mag --filter madgwick --beta 0.1

Process

  1. Read sensor datasheet: WHO_AM_I register, output registers, compensation formula.
  2. Implement init: verify WHO_AM_I, read calibration NVM, configure oversampling and ODR.
  3. Implement read: burst read raw output registers, apply compensation formula.
  4. Add calibration: two-point at minimum, store in NVM.
  5. Add filter: select based on noise characteristics and acceptable latency.

Output Examples

Sensor driver test sequence

/* Acceptance test for a new sensor driver */
void sensor_driver_test(void)
{
    bme280_t dev;

    /* 1. Init */
    int rc = bme280_init(&dev, &i2c1_ops, BME280_ADDR);
    TEST_ASSERT_EQUAL_INT(0, rc);

    /* 2. Read and sanity-check (room temperature expected 15-35°C) */
    int32_t temp_hundredths;
    bme280_read_temperature(&dev, &temp_hundredths);
    TEST_ASSERT_INT_WITHIN(2000, 2500, temp_hundredths);  /* 5-45°C */

    /* 3. Verify no I2C errors after 100 consecutive reads */
    for (int i = 0; i < 100; i++) {
        TEST_ASSERT_EQUAL_INT(0, bme280_read_temperature(&dev, &temp_hundredths));
    }
}

Read the full file on GitHub · 117 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 15d ago First seen · 117 lines · 22 tokens per session scan A 739c3ca24b07

Subscribe to this mod's changes

sensor is a command published in the GitHub repository HermeticOrmus/LibreEmbed-Claude-Code (50 stars, last pushed 6d ago), licensed MIT. It adds 22 tokens to every session and 1,008 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-01.