Skip to main content

Software OTA

The Cogniteam Cloud Platform supports over-the-air (OTA) updates of its edge agents using Docker containers. This provides a scalable and reliable mechanism to roll out updates across fleets of robots or IoT devices with minimal manual intervention.

Overview

Each edge agent is capable of provisioning Docker containers. The update process involves periodically checking and pulling updated images from a container registry.

This mechanism enables:

  • Controlled version upgrades
  • Rollback to previous stable versions

Update Flow

  1. Start-Up Version Check Upon startup, the agent compares its current configuration version to the latest available version.

  2. Image Pull & Deployment If an update is needed:

    • The updated Docker image is pulled
    • The running container is stopped
    • A new container is launched with the updated image

Configuration

Configuration is a composition of components. Configuration and Components are versioned in the system.

Example: component.json

This section provides a sample JSON file to configure and deploy a component using the Cogniteam Cloud system.

What is a JSON File?

JSON (JavaScript Object Notation) is a lightweight, human-readable data format commonly used for configuration and data exchange. It consists of attribute–value pairs and supports arrays and nested structures.

Creating a Component JSON File

Once your component is containerized and available in a Docker registry, you can define a JSON configuration file that instructs the Nimbus system how to run it.

Sample Configuration:

{
"name": "nimbus/hector",
"type": "COMPONENT_TYPE_COMPONENT",
"className": "Ros1Component",
"description": "2D laser scan mapping using Hector mapping algorithm",
"environment": {
"dockerInfo": {
"image": "hector1:latest",
"commands": [
"roslaunch",
"hector_mapping",
"hector_mapping.launch",
"map_resolution:=${map_resolution}",
"map_size:=${map_size}",
"base_frame:=${base_frame}"
]
}
},
"parameters": {
"parameters": [
{
"name": "map_resolution",
"limits": {
"min": 0.001,
"max": 2,
"step": 0.01
},
"doubleValue": 0.1
},
{
"name": "map_string",
"limits": {
"min": 0,
"max": 8,
"step": 1
},
"stringValue": "string-value"
},
{
"name": "base_frame",
"limits": {
"min": 0,
"max": 8,
"step": 1
},
"stringValue": "base_link"
}
]
},
"streams": {
"inputStreams": [
{
"name": "scan",
"type": "",
"cloud": {
"id": "123",
"download_policy": {
"min_download_interval": "10000"
}
},
"ros_topic": {
"topic": "/scan",
"type": "Messages.sensor_msgs.LaserScan"
}
}
],
"outputStreams": [
{
"name": "map",
"type": "",
"ros_topic": {
"topic": "/map",
"type": "Messages.nav_msgs.OccupancyGrid"
}
},
{
"name": "pose_stamped",
"type": "",
"ros_topic": {
"topic": "/slam_out_pose",
"type": "Messages.geometry_msgs.PoseStamped"
}
}
]
},
"ros": {
"base_frame": "base_link",
"rate": 10.0,
"publishTfDevices": true
}
}

Explanation of Key Sections

  • name: Component identifier
  • type: Component classification (e.g., software component)
  • className: Class type used by the Cogniteam Cloud system
  • environment.dockerInfo.image: Docker image tag
  • commands: Startup command and arguments passed to the container
  • parameters: Tunable settings with type, range, and default values
  • streams: Input and output ROS topics and their Nimbus equivalents
  • ros: TF settings, including base frame and publish rate

Advanced Docker Configuration

"dockerInfo": {
"image": "cognimbus/hamster_driver",
"commands": [],
"privileged": true,
"gpu": true
}

Device Access Configuration

"requiredDevices": [
{
"name": "laser",
"info": {
"type": "USB_PORT_TYPE_SERIAL",
"productId": "ea60",
"vendorId": "10c4"
},
"mountAs": "/dev/ttyUSB0"
}
]

Uploading the JSON File

You can register your component using the Cogniteam Cloud Web Interface

  • Navigate to: Components > Add Component
  • Enter a component name
  • Upload the JSON file
  • Then you will be able to use this new component inside a configuration

Local ROS Component (Non-Docker)

The Agent can also run ROS components directly on the host without Docker, provided ROS is installed.

Example JSON for Local Component

"environment": {
"rosLocalInfo": {
"PackageName": "hector_mapping",
"launchFile": "mapping_default.launch",
"workspaceSetup": "/opt/ros/melodic/setup.bash",
"arguments": {
"map_resolution": "${map_resolution}",
"map_resolution2": "${map_resolution2}"
}
}
}