40
Flanders’ MECHATRONICS Technology Centre www.fmtc.be Orocos Introduction Open Robot Control Software Peter Soetens Flanders’ Mechatronics Technology Centre Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46 Email: [email protected] FMTC 2006

Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Flanders’MECHATRONICSTechnology Centrewww.fmtc.be

Orocos IntroductionOpen Robot Control Software

Peter Soetens

Flanders’ Mechatronics Technology CentreLeuven

1 October 2007FMTC, Leuven

FMTC Celestijnenlaan 300 D B-3001 Leuven BelgiumTel: +32-16-32.25.90 Fax: +32-16-32.27.46 Email: [email protected] FMTC 2006

Page 2: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Outline

1 Introduction

2 Approach

3 Example Application

Page 3: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Section Outline

1 IntroductionExamples

2 ApproachThe Component ModelCommunication Categories

3 Example Application

Page 4: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Orocos in one-liners

The Real-Time Toolkit (RTT):Open Robot Control Software⇒ Open Source ’robot’ control and interfacingReal-time Software Toolkits in C++⇒ Developer’s toolTool for developing components for control⇒ Real-time, thread-safe, interactiveOffers common component implementations⇒ Optional

Freely available on:http://www.orocos.org

Page 5: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Outline

1 IntroductionExamples

2 ApproachThe Component ModelCommunication Categories

3 Example Application

Page 6: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication and Behaviour

Continuous control: tracking a light source.

Page 7: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication and Behaviour

Continuous and discrete control: Placing a car window

Page 8: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Introduction

In these examples, Orocos was used todo the real-time communicationsdefine the real-time behaviour of machines in response tocommunicationaccess the hardware devicescreate components which do all this.

Page 9: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Introduction

In these examples, Orocos was used todo the real-time communicationsdefine the real-time behaviour of machines in response tocommunicationaccess the hardware devicescreate components which do all this.

Page 10: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Introduction

In these examples, Orocos was used todo the real-time communicationsdefine the real-time behaviour of machines in response tocommunicationaccess the hardware devicescreate components which do all this.

Page 11: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Introduction

In these examples, Orocos was used todo the real-time communicationsdefine the real-time behaviour of machines in response tocommunicationaccess the hardware devicescreate components which do all this.

Page 12: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Section Outline

1 IntroductionExamples

2 ApproachThe Component ModelCommunication Categories

3 Example Application

Page 13: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Outline

1 IntroductionExamples

2 ApproachThe Component ModelCommunication Categories

3 Example Application

Page 14: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

A Component Model for Control

ApproachCreate a software component for each ‘task’ within themachine

Page 15: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component Definition

CommunicationDefined by thecomponent interface

BehaviourDefined by real-timestate machines

Page 16: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component Definition

CommunicationDefined by thecomponent interface

BehaviourDefined by real-timestate machines

Page 17: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Work-flow

Component ModelReal-Time Toolkit tobuild components

ComponentsRe-usable part of anapplication

Applications‘Deployments’ selectand connectComponents

Page 18: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Work-flow

Component ModelReal-Time Toolkit tobuild components

ComponentsRe-usable part of anapplication

Applications‘Deployments’ selectand connectComponents

Page 19: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Work-flow

Component ModelReal-Time Toolkit tobuild components

ComponentsRe-usable part of anapplication

Applications‘Deployments’ selectand connectComponents

Page 20: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Outline

1 IntroductionExamples

2 ApproachThe Component ModelCommunication Categories

3 Example Application

Page 21: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component CommunicationPatterns

In which ways can components communicate?

Configuration of parametersExchange dataCooperate to achieve a task

Page 22: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component CommunicationPatterns

Page 23: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component Interface

Page 24: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component Interface

Page 25: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component Implementation

Page 26: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

State Machine Example

Page 27: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Section Outline

1 IntroductionExamples

2 ApproachThe Component ModelCommunication Categories

3 Example Application

Page 28: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Example Application

How are these communication primitives used ?

Page 29: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Example Application

Page 30: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Deployment Configuration

Page 31: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Component Interface

Page 32: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Configuration

Configuration Flow : Properties

Page 33: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Data

Data Flow : Ports and Connectors

Page 34: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Data

Data Flow : Ports and Connectors

Page 35: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Execution

Execution Flow

Page 36: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Execution

Execution Flow: Methods

Page 37: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Execution

Execution Flow: Commands

Page 38: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Execution

Execution Flow: Events

Page 39: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Communication: Complete Picture

Page 40: Open Robot Control Software Peter Soetens - Orocos · Leuven 1 October 2007 FMTC, Leuven FMTC Celestijnenlaan 300 D B-3001 Leuven Belgium Tel: +32-16-32.25.90 Fax: +32-16-32.27.46

Example Application Summary

The following steps lead to a control application design:identification of the ‘control tasks’→ componentsdefining each component’s interfacesetting up components connectionsdefining component or application behaviours