Skip to main content
This guide walks through the creation and deployment of your first configuration with Miru. If this is your first time using Miru, you’re in the right place!

Create an Account

To create an account, navigate to the sign up page and follow the instructions.

Terminology

Before we begin, let’s define some key configuration terminology to differentiate between configuration schemas, instances, and types.

Config Instances

A config instance is a set of parameters used to alter the behavior of code. Config instances are typically stored as JSON or YAML files (or potentially in a database somewhere), which applications parse into a structured format for consumption. The following YAML file defines a config instance for controlling a robot’s motion.
max_linear_speed_mps: 1.2
max_angular_speed_radps: 1.0
obstacle_avoidance_enabled: true
navigation_mode: balanced
telemetry:
  upload_interval_sec: 60
  heartbeat_interval_sec: 10

Config Schemas

A config schema defines the constraints for a config instance. Miru uses JSON Schema, a popular open-source configuration language, for defining the valid fields, types, and values in a config instance. Below is an example JSON Schema.
$schema: "https://json-schema.org/draft/2020-12/schema"
title: Mobility
type: object
properties:
  max_linear_speed_mps:
    type: number
    minimum: 0.1
    maximum: 5.0
    default: 1.2
  max_angular_speed_radps:
    type: number
    minimum: 0.1
    maximum: 3.0
    default: 1.0
  obstacle_avoidance_enabled:
    type: boolean
    default: true
  navigation_mode:
    type: string
    enum: [conservative, balanced, aggressive]
    default: balanced
  telemetry:
    type: object
    properties:
      upload_interval_sec:
        type: integer
        minimum: 10
        maximum: 300
        default: 60
      heartbeat_interval_sec:
        type: integer
        minimum: 1
        maximum: 60
        default: 10
    required:
      - upload_interval_sec
      - heartbeat_interval_sec
required:
  - max_linear_speed_mps
  - max_angular_speed_radps
  - obstacle_avoidance_enabled
  - navigation_mode
  - telemetry
While Miru only supports JSON Schema at the moment, other configuration languages are coming soon. Here are some popular ones:
While config schemas are recommended, they are not required to begin using Miru.

Config Types

A config type represents the parameters that configure an aspect of a robot’s software, regardless of the version of that software. For instance, a robot may have a Mobility config type that configures its motion. The Mobility config type goes through many iterations—parameters are added or deprecated (creating new config schemas) and given different values (creating new config instances). The Mobility config type is not a particular config instance nor a particular config schema. It simply refers to the motion-related parameters for the robot in general.

Clone the Repository

To make things easy, we’ve created a starter repository with some sample schemas and instances. Clone the getting-started repository.
git clone https://github.com/miruml/getting-started.git
You’ll find the following directories in the repository:

Mobility Config Type

For the remainder of this guide, the Mobility config type is used as an example. The /schemas/mobility.schema.yaml defines the config schema for the Mobility config type. It includes key parameters such as:
  • Maximum linear and angular speeds
  • Obstacle avoidance settings
  • Navigation mode selection
  • Telemetry intervals
mobility.schema.yaml
$miru_config_type_slug: "mobility"
$schema: "https://json-schema.org/draft/2020-12/schema"
title: Mobility
type: object
properties:
  max_linear_speed_mps:
    type: number
    minimum: 0.1
    maximum: 5.0
    default: 1.2
  max_angular_speed_radps:
    type: number
    minimum: 0.1
    maximum: 3.0
    default: 1.0
  obstacle_avoidance_enabled:
    type: boolean
    default: true
  navigation_mode:
    type: string
    enum: [conservative, balanced, aggressive]
    default: balanced
  telemetry:
    type: object
    properties:
      upload_interval_sec:
        type: integer
        minimum: 10
        maximum: 300
        default: 60
      heartbeat_interval_sec:
        type: integer
        minimum: 1
        maximum: 60
        default: 10
    required:
      - upload_interval_sec
      - heartbeat_interval_sec
required:
  - max_linear_speed_mps
  - max_angular_speed_radps
  - obstacle_avoidance_enabled
  - navigation_mode
  - telemetry
The /instances/mobility.instance.yaml defines a config instance adhering to the Mobility config schema.
mobility.instance.yaml
max_linear_speed_mps: 1.2
max_angular_speed_radps: 1.0
obstacle_avoidance_enabled: true
navigation_mode: balanced
telemetry:
  upload_interval_sec: 60
  heartbeat_interval_sec: 10

Starting Schemaless

While this guide uses a well-defined schema for the mobility config type, you may find it simpler to begin using Miru without a schema. To do this, follow along with the /schemas/empty-mobility.schema.yaml file instead of /schemas/mobility.schema.yaml. This file defines an empty schema that regards all config instances as valid.
empty-mobility.schema.yaml
$miru_config_type_slug: "mobility"
$schema: "http://json-schema.org/draft/2020-12/schema"
title: Empty Mobility
I