AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified Apache-2.0 Self-run

Kernel Services

skill-beriberikix-zephyr-agent-skills-kernel-services · by beriberikix

Advanced Zephyr RTOS kernel services. Covers inter-thread communication using Zbus (pub/sub), behavioral management with the State Machine Framework (SMF), background processing via work queues, and persistent configuration with the Settings subsystem. Trigger when building modular application architectures, complex state-driven logic, or requiring persistent data storage.

No reviews yet
0 installs
27 views
0.0% view→install

Install

$ agentstack add skill-beriberikix-zephyr-agent-skills-kernel-services

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-beriberikix-zephyr-agent-skills-kernel-services)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
4mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Kernel Services? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Zephyr Kernel Services

Move beyond basic threading and logging to build modular, event-driven, and robust Zephyr applications.

Core Workflows

1. Event-Driven Communication (Zbus)

Decouple your modules using a lightweight publish-and-subscribe bus.

  • Reference: [zbus.md](references/zbus.md)
  • Key Tools: ZBUS_CHAN_DEFINE, ZBUS_SUBSCRIBER_DEFINE, zbus_chan_pub.

2. Behavioral Logic (SMF)

Manage complex system states and transitions using the State Machine Framework.

  • Reference: [smf.md](references/smf.md)
  • Key Tools: smf_set_state, SMF_CREATE_STATE, Hierarchical states.

3. Background Processing (Work Queues)

Defer long-running or non-critical tasks to prevent blocking interrupts or high-priority threads.

  • Reference: [settingsworkqueue.md](references/settingsworkqueue.md)
  • Key Tools: k_work_submit, k_work_delayable, Custom work queues.

4. Persistence (Settings)

Save and restore configuration data and state across reboots.

  • Reference: [settingsworkqueue.md](references/settingsworkqueue.md#settings-subsystem)
  • Key Tools: settings_load, settings_save_one, NVS backends.

Quick Start (Zbus)

// Define a channel for sensor data
ZBUS_CHAN_DEFINE(sensor_data_chan, struct sensor_msg, NULL, NULL, ZBUS_OBSERVERS_EMPTY, ZBUS_CHAN_DEFAULTS);

// Publish from a thread
zbus_chan_pub(&sensor_data_chan, &msg, K_NO_WAIT);

Professional Patterns (Asset Tracker Style)

  • Modularity: Use Zbus as the backbone for inter-module communication.
  • Predictability: Use SMF to define clear lifecycle states for each module (e.g., Uninitialized -> Ready -> Active -> Error).
  • Responsiveness: Use custom work queues for sensor data ingestion to keep the main thread responsive for cloud communication.
  • Sensor Integration: For sensor data ingestion patterns, see the [hardware-io](../hardware-io/SKILL.md) skill.

Automation Tools

  • [zbuschannellint.py](scripts/zbuschannellint.py): Detect duplicate ZBUS_CHAN_DEFINE names across source files.

Examples & Templates

  • [smfstatetabletemplate.c](assets/smfstatetabletemplate.c): Starter SMF state table and lifecycle wiring.

Validation Checklist

  • [ ] Zbus publishers and subscribers exchange messages without deadlock or missed updates.
  • [ ] SMF transitions follow expected state graph under normal and error conditions.
  • [ ] Deferred work executes on intended queue context with bounded execution time.
  • [ ] Settings values persist across reboot and reload successfully at startup.

Resources

  • [References](references/):
  • zbus.md: Publish/Subscribe patterns and subscriber types.
  • smf.md: Finite and Hierarchical state machine implementation.
  • settings_workqueue.md: Background work and persistent storage.
  • [Scripts](scripts/):
  • zbus_channel_lint.py: Zbus channel name collision checker.
  • [Assets](assets/):
  • smf_state_table_template.c: State-machine template.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.