LogoLogo
  • Welcome
  • Vehicle Operation
    • Getting started
    • Auterion Suite
      • Dashboard
      • Fleet Management
        • Vehicles
          • Cloud Features
          • Groups
        • Flights
        • Compliance
      • Manufacturer
        • Service Bulletins
      • Administration
      • User Management
      • Simulations
    • Auterion Mission Control
      • Installation
      • First steps
      • UI Breakdown
        • Navigating between the views
        • Fly View
          • Fly View UI Overview
          • Vehicle status indicator
          • Flight mode selector
          • Quick actions sidebar
          • Connection manager
          • Vehicle Dashboard
          • Flight Map
          • Camera View
          • Monitoring the Flight
          • Flying Manually (RC/Joystick)
          • Flying a Mission
        • Plan View
          • Plan UI Overview
          • Plan tools
            • Mission Menu
            • Waypoint Missions
            • Survey Patterns
              • Area Survey
              • Corridor Scan
          • Mission Summary
          • Mission Editor Tab
            • Start Section
            • Mission Section
            • End Section
            • Extras
          • Terrain visualization
          • GeoFence
          • Rally Points
        • Quick Vehicle Menu
          • Pre-Flight Checklist
          • Connectivity
        • Photo Gallery
        • Settings
        • Pilot Login
      • Useful resources
        • Mission Planning
          • Mission Cloud Sync
          • Terrain Following
          • Import Geo-Awareness data or KML overlays
        • Maps and Custom Overlays
          • Using Offline Maps
          • Importing GeoPDF overlays
        • Track GCS as Smart Asset in Suite
        • Live PX4 Log Streaming
        • Monitor Local Flights with ADS-B
        • GPS Denied Workflow
        • Windows Crash Logs Analysis
        • Screen Recordings
    • Remote Controllers
      • Skynav Remote Controller
        • Installing Mission Control
        • Joystick and Button Mapping
        • Using LTE for Online Maps in the Field
        • Advanced Radio Settings
        • Drop Guards and Chest Strap
        • Unit Serial Number
    • Settings & Maintenance
      • Vehicle Setup
      • WiFi Setup
      • Compass Calibration
      • Safety Setup
      • Joystick Setup
      • Vehicle Web UI
      • Software Update
      • Remote ID
        • How Remote ID works
        • Remote ID indicators in AMC
        • Frequently Asked Questions
    • Precise Flight
  • App development
    • Getting Started
      • Development environment Setup
      • Connecting to a device
      • Application Development
    • App Framework
      • Building your First App
      • Apps API
      • Sensor Data
      • Video Streams
      • Photos
      • Hardware Peripherals
      • Persistent Storage
      • MAVLink
      • Native Docker Compose
      • App Parameters
      • Log App Data to Auterion Suite
        • How to log Time Series Data
        • How to log basic Text Output
      • How to store an App's Binary Data on Skynode
      • User Web Interfaces
      • Build Arguments
      • Debugging apps with SSH
      • Debugging Apps with gdb
      • PX4 Messages in ROS 2
      • DDS / ROS2 Configuration
      • Structuring Applications with Multiple Services
    • Auterion SDK
      • Installation
      • Write Your First App
      • SDK API
      • Flight Mode API
        • Flight Mode API
        • Dynamics in Body Frame
        • Dynamics in Local Frame
        • Go-To in Local Frame
      • System State API
      • Peripheral Actuator Control API
      • Camera API
      • Navigation Input API
        • Global Navigation
        • Local Navigation
      • Visual Tracking API
    • Simulation
      • Virtual Skynode
        • Simulation-Gazebo Reference
        • Simulation-AirSim Reference
        • Connecting from other Computers
        • Resetting Virtual Skynode
        • Multiple Virtual Skynodes on single machine
      • Physical Skynode
    • Resources
      • Cross Compilation - Faster Builds
      • Auterion CLI Reference
      • Troubleshooting
      • App Tutorial
      • Skynode Vision Kit S
        • Set up the Vision Kit
        • Install and test a simple vision app
    • Legacy app workflow
      • App Development
      • MAVLink
      • Using the App Template
      • Example Applications
        • Autopilot Telemetry (C++)
        • Autopilot Telemetry (Python)
        • Photo Gallery
  • Hardware Integration
    • Getting started
      • Required Sensors
      • Wiring Skynode to the Vehicle
      • Actuators Setup
      • Sensors Setup
        • Set Orientations
        • Compass Calibration
        • Gyroscope calibration
        • Accelerometer calibration
        • Level horizon calibration
        • Airspeed calibration
      • Bench Test
      • Tuning
      • Creating Airframe Configurations for APX4
    • Skynode
      • Skynode X
      • Skynode ENT/GOV
      • Skynode X Integration and Development Kit
        • Get Skynode ready
        • Power Skynode
        • Register Skynode
        • Connect Skynode to AMC
        • Sensors and Peripherals
        • Next steps
      • Payloads
        • Generic USB Webcams (UVC)
        • Workswell Wiris Pro
        • Trillium HD40-LV
        • NextVision Gimbals (with TRIP2)
        • Sony Alpha a7R IV
        • Phase One iXM-100
        • Gremsy Gimbals
      • Connectivity
        • USB-C Network Connection
        • WiFi
        • LTE Setup
        • SIYI MK15
        • Microhard Data Link
        • Data Link Wiring
        • Silvus Data Link
        • Doodle Labs Data Link
        • Custom Data Link
        • Ethernet Interface Configuration
      • Skynode LED Meanings
      • Troubleshooting
      • Legacy DSM/DSMX Support
      • Peripherals
        • Power Module
        • 12S Power Module
        • Pixhawk Adapter Board
        • Pixhawk Payload Bus
        • Data Link Module
        • PX4 F9P GPS
        • Freefly RTK GPS
        • Airspeed Sensor
        • LIDAR
        • USB camera
        • See3CAM_24CUG
    • Skynode S
      • Datasheet
      • Interfaces
      • Basic Vehicle Integration
      • Add LTE to Skynode S
      • Skynode S LED status indicator
      • Skynode S flight logs
    • AI Node
      • Datasheet
      • Evaluation Kit
        • Power AI Node
        • Wiring AI Node to Skynode
        • Internet sharing with Skynode
        • Activate AI Node on Suite
      • Dimensions and CAD model
      • Interfaces
      • Connectivity
        • USB Network Connection
        • Serial Debug Connection
        • AI Node as Network Bridge
        • Standalone Internet Access
      • Updating AuterionOS
    • Advanced Airframe Integration
      • Custom power setup
      • Wiring without Breakout Boards
      • Gripper Integration
        • Setting up Payload Delivery with Gripper
      • ESC Calibration
      • Camera Calibration
        • Camera Calibration on a Computer
        • Camera Calibration on Skynode
      • Serial Port Configuration
    • Flight controller customization
      • AMC's Advanced Mode
      • Flight Controller Shell
      • Micro XRCE-DDS
    • AuterionOS Customization
      • OEM Tools Installation
      • Adding SSH keys
      • Changing the Root Password
      • Modifying Environment Variables
      • Pre-install Applications
      • Suite Manufacturer Tools
    • AuterionOS System Guide
      • Introduction
      • Flashing PX4 Binary and Vehicle Config
      • Building and Flashing PX4 Firmware
      • SSH Access
      • Filesystem and partitions
      • Environment Variables Reference
      • Types of AuterionOS Images
      • Mavlink Routing and Endpoints
      • Packaging AuterionOS Image
    • Additional Resources
      • Remote ID
        • How Remote ID works
        • Vehicle Serial Number
        • Communication Diagram
        • Remote ID configuration
        • How Auterion tested
      • Auto-Tuning
  • Release Notes
    • APX4
      • APX4 3.2
        • APX4 3.2.1
      • APX4 3.1
        • APX4 3.1.1
        • APX4 3.1.0
      • APX4 3.0
        • APX4 3.0.8
        • APX4 3.0.5
      • APX4 2.7
        • APX4 2.7.37
        • APX4 2.7.25
        • APX4 2.7.20
        • APX4 2.7.12
        • APX4 2.7.7
        • APX4 2.7.6
      • APX4 2.6
        • APX4 2.6.1
      • APX4 2.5
        • APX4 2.5.14
        • APX4 2.5.13
        • APX4 2.5.8
        • APX4 2.5.7
        • APX4 2.5.5
        • APX4 2.5.4
        • APX4 2.5.0
      • APX4 2.4
        • APX4 2.4.2
        • APX4 2.4.1
      • APX4 2.3
        • APX4 2.3.0
      • APX4 2.2
        • APX4 2.2.2
        • APX4 2.2.0
      • APX4 2.1
        • APX4 2.1.1
        • APX4 2.1.0
      • APX4 2.0
        • APX4 2.0.2
        • APX4 2.0.0
    • AuterionOS
      • AOS for AI Node
        • AI Node AOS 1.1.0
        • AI Node AOS 1.0.2
        • AI Node AOS 1.0.0
        • AI Node AOS 0.7.0
        • AI Node AOS 0.6.1
        • AI Node AOS 0.6.0
        • AI Node AOS 0.5.0
        • AI Node AOS 0.4.0
      • AOS for Skynode
        • AOS 3.7
          • AOS 3.7.14
          • AOS 3.7.9
        • AOS 3.6
          • AOS 3.6.14
        • AOS 3.5
          • AOS 3.5.13
        • AOS 3.3
          • AOS 3.3.9
        • AOS 3.2
          • AOS 3.2.9
        • AOS 2.19
          • AOS 2.19.14
        • AOS 2.15
          • AOS 2.15.10
          • AOS 2.15.7
        • AOS 2.12
          • AOS 2.12.8
        • AOS 2.10
          • AOS 2.10.2
        • AOS 2.8
          • AOS 2.8.1
        • AOS 2.7
          • AOS 2.7.15
        • AOS 2.6
          • AOS 2.6.1
        • AOS 2.5
          • AOS 2.5.14
          • AOS 2.5.13
          • AOS 2.5.8
          • AOS 2.5.7
          • AOS 2.5.5
          • AOS 2.5.4
          • AOS 2.5.0
        • AOS 2.4
          • AOS 2.4.1
        • AOS 2.3
          • AOS 2.3.0
        • AOS 2.2
          • AOS 2.2.2
          • AOS 2.2.0
        • AOS 2.1
          • AOS 2.1.1
          • AOS 2.1.0
        • AOS 2.0
          • AOS 2.0.2
          • AOS 2.0.0
    • Auterion Mission Control
      • AMC 1.34
        • AMC 1.34.19
        • AMC 1.34.14
      • AMC 1.33
        • AMC 1.33.13
      • AMC 1.32
        • AMC 1.32.7
      • AMC 1.30
        • AMC 1.30.17
      • AMC 1.29
        • AMC 1.29.7
      • AMC 1.26
        • AMC 1.26.8
      • AMC 1.22
        • AMC 1.22.3
      • AMC 1.19
        • AMC 1.19.5
      • AMC 1.18
        • AMC 1.18.3-1
        • AMC 1.18.3
      • AMC 1.17
        • AMC 1.17.10
        • AMC 1.17.9
      • AMC 1.15
        • AMC 1.15.0
      • AMC 1.14
        • AMC 1.14.6
        • AMC 1.14.0
      • AMC 1.13
      • AMC 1.12
      • AMC 1.11
      • AMC 1.10
        • AMC 1.10.1
        • AMC 1.10.0
      • AMC 1.9
        • AMC 1.9.1
        • AMC 1.9.0
      • AMC 1.8
    • Hardware
      • Skynode Rev 11 (Jan 2022)
Powered by GitBook
On this page
  • Introduction
  • Build your own application
  • App.yml
  • The "src" folder
  • Makefile
  • Tools
  • Packaging Apps into AuterionOS
  • Example Applications
  • Troubleshooting
  • Packaging artifacts fails
  • Packaging artifacts requires sudo
  1. App development
  2. Legacy app workflow

Using the App Template

PreviousMAVLinkNextExample Applications

Last updated 1 year ago

These instructions only apply to AuterionOS version 2.5 and earlier. Developers targeting AOS 2.7 and newer should use the new app workflow instead: Getting Started

Introduction

This documentation explains how to develop an application for AuterionOS. An application is a set of Docker containers that can interact together and with Auterion software. Tools are provided in order for you to build, deploy and run your application on top of AuterionOS for development, and then package it into an update archive to deploy it to Skynode-powered vehicles. Attached to this documentation there are four example applications written in C++ and Python that use mavlink (MavSDK) to get flight controller telemetry or interact with Auterion Payload Manager. At the end of the documentation you will find a section listing the most important commands to know in order to interact with an application installed on your device.

Have a look at the Examples if you like to see code first

You can also first develop and prototype by just using ssh to connect to Skynode. See the section on for further details.

Build your own application

An application is composed of:

  • app.yml: A YAML file that describes your application

  • src: A folder that contains application source code and Dockerfile

  • Makefile: One makefile that contains build and install instructions

  • tools: A folder that contains tools needed in order to build and deploy your application

App.yml

The app.yml is the file that describes and configures your application. This file follows the Compose file format and should define every service that composes your application. A minimal app.yml should contain at least:

version: '3.7'
services:
  service1:
    image: service1
    container_name: service1
    restart: unless-stopped
    network_mode: host
    volumes:
      - '/data/app/myapp/data:/data'

Where service1 is the name of your docker container and myapp is the name of your application.

For a multiple containers application, app.yml should contain at least:

version: '3.7'
services:
  service1:
    image: service1
    container_name: service1
    restart: unless-stopped
    network_mode: host
    volumes:
      - '/data/app/myapp/data:/data'
  service2:
    image: service2
    container_name: service2
    restart: unless-stopped
    network_mode: host
    volumes:
      - '/data/app/myapp/data:/data'

Where service1 is the name of your first docker container, service2 is the name of your second docker container and myapp is the name of your application.

Network

By adding network_mode: host to your service definition in app.yml you will be able to expose your service to the network.

Volumes

By adding - '/persistent/shared_container_dir:/shared_container_dir' to the list of volumes of your service definition in app.yml, you will be able to access to the WiFi and LTE configuration files.

By adding the following volumes to the list of volumes of your service definition in app.yml, you will be able to access pictures taken by Auterion Payload Manager:

- '/data/shared_photos:/shared_photos'
- '/data/photos:/data/photos'
- '/dev/media:/dev/media'

The "src" folder

You are actually free to architecture your application as you want. One way to architecture your src folder is:

/src
    /service1
        /Dockerfile
        /src
    /service2
        /Dockerfile
        /src

You can learn more about Dockerfile on docs.docker.com

Makefile

In order to drive the build and deployment processes you can define a Makefile with the following rules:

appName ?= myapp
toolsPath = ./tools

ifneq ($(artifactPath),)
artifactPath=$(artifactPath)
else
artifactPath=./output/$(appName).auterionos
endif

build-myapp-service1:
	docker build ./src/service1 -t service1

build-myapp-service2:
	docker build ./src/service2 -t service2

build: build-myapp-service1 build-myapp-service2
	mkdir -p output
	docker save service1 service2 | gzip > output/$(appName).image
	$(toolsPath)/package_app.sh --app=$(appName)

install:
	$(toolsPath)/update.py --artifact $(artifactPath)

Where service1 is the name of your first docker container, service2 is the name of your second docker container and myapp is the name of your application.

The build target will build every service and generate the application artifact in output/<myapp>.auterionos. The install target will upload and install the artifact on your device (via USB-C).

Tools

The tools folder is important because it contains the scripts you will need to package an application and to deploy it to your device. You will need to copy the following scripts from tools and copy them to the root of your application workspace:

  • tools/package_app.sh

  • tools/mender-artifact

Packaging Apps into AuterionOS

Example Applications

A good way to start developing applications for AuterionOS is to experiment with the example applications provided by Auterion.

Troubleshooting

In case your deployment fails you can find useful information in the following logs:

  • /var/log/apache2/error.log

  • /data/<APP_NAME>.log

Packaging artifacts fails

In case you cannot package an artifact or build an application, you can execute the script ./setup/sanity_check.sh in order to verify that your setup is configured correctly. This script will give you additional information in order to fix your setup issue.

Packaging artifacts requires sudo

Depending on which Linux distribution the development environment is installed, the make command may need to be executed with sudo. The package script uses mounts in order to copy files in the artifact, which may require elevated privileges.

Manufactuers refer to for a guide on how to package your app into an AuterionOS base image. The process can be used to include Apps directly in AuterionOS images.

USB-C Networking on Skynode
Pre-install Apps