agentsclimarketplace

Embedded timing libs

Skill easyzoom/aix-skills/skills/embedded-timing-libs

Use when integrating, porting, configuring, or debugging embedded software timer libraries such as MultiTimer, timeout schedulers, or tick-based callback timersFrom its SKILL.md

Install
npx -y skills add easyzoom/aix-skills --skill embedded-timing-libs

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 24 stars24 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

2.6 KB, 499 tokens by cl100k_base, as published. Nobody here has run it

Embedded Timing Libs

Overview

Use this skill for lightweight software timer libraries such as MultiTimer. The agent should confirm tick source, callback context, time units, wraparound behavior, and scheduler frequency before relying on timer callbacks.

When To Use

Use this skill when:

  • The user wants to add or debug MultiTimer, software timers, timeout lists, periodic callbacks, or one-shot timers.
  • Timers drift, fire too early/late, stop firing, fire repeatedly, or break across tick overflow.

Do not use this skill for hardware PWM/timer peripheral bring-up. Use embedded-peripheral-bringup for register-level timer issues.

First Questions

Ask for:

  • Timer library and target runtime.
  • Tick source and frequency.
  • Callback context: main loop, RTOS task, ISR, or scheduler hook.
  • Time units used by the library and application.
  • Number of timers and longest expected uptime.
  • Whether callbacks may start/stop other timers.

Integration Checklist

  1. Confirm tick monotonicity. Timer logic needs a stable increasing timebase or explicit wraparound handling.

  2. Match units. Milliseconds, ticks, microseconds, and RTOS ticks must not be mixed silently.

  3. Define callback context. Timer callbacks must not block if they run in ISR or scheduler critical context.

  4. Test one-shot and periodic behavior. Verify start, stop, restart, and callback ordering.

  5. Test wraparound. Use simulated ticks or shortened counters to prove overflow behavior.

Common Failures

  • Tick function returns seconds while timer expects milliseconds.
  • Callback blocks in interrupt context.
  • Timer list is modified while iterating without protection.
  • Drift accumulates because periodic timers restart from callback time instead of scheduled time.
  • Wraparound breaks after long uptime.

Verification

Before claiming timer integration works:

  • State tick source, frequency, unit, callback context, and protection strategy.
  • Confirm one-shot, periodic, cancel, restart, and wraparound behavior.
  • Confirm callback execution time is acceptable.
  • Confirm timer operations are safe from ISR/task contexts in use.

Example

User:

MultiTimer 定时回调偶尔不准。

Agent:

  1. Asks for tick source, units, callback context, and scheduling frequency.
  2. Checks unit conversion and whether callbacks block.
  3. Tests periodic drift and tick wraparound with a small counter.

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.