Sugarcoat Developer Docs#

Sugarcoat is the orchestration layer of the EMOS ecosystem. It provides the foundational abstractions (components, events, actions, and the launcher) that power EmbodiedAgents and Kompass.

This site contains developer documentation for contributors and package authors building on top of Sugarcoat.

Looking for usage documentation?

Tutorials, installation guides, and usage documentation are on the EMOS Documentation site.


Understand the Framework#

Architecture

Core module structure, component lifecycle, Monitor orchestration, Launcher process graph, and I/O system.

Architecture Overview
Event System

Condition trees, event patterns, action dispatch, fallback hierarchy, and Monitor evaluation loop.

Event-Driven Architecture

Extend & Integrate#

Custom Components

Subclass BaseComponent with lifecycle hooks, run types, I/O validation, and custom actions.

Creating a New BaseComponent
Custom Types

Add new SupportedType wrappers and callbacks, register custom ROS messages, and opt into API streaming modes and the shared-memory fast path.

Extending the Type System
Processing Pipelines

Inject post-processors on callbacks and pre-processors on publishers for data transformation.

Adding Processing Pipelines to I/O
Robot Plugins

Adapt recipes to specific hardware: transports, feedback and command mapping, actions and events, driver processes, sensor mounts and mapping.

Creating a Plugin
UI Elements

Register custom input forms and output visualizations in the web UI, and understand what the JSON/WebSocket API serves for new data types.

Adding UI Elements
Testing

Running the suite, and testing components, events, fallbacks, plugins and recipes with pytest and launch_testing.

Testing Guide

Reference#

Built-in Services

Live reconfiguration services: topic replacement, parameter updates, and file-based configuration.

Default Services In Sugarcoat Components
Systemd Deployment

Convert Sugarcoat recipes into systemd services for production deployment.

Converting a Sugarcoat Recipe into a systemd Service