Embedding a kinematic controller in an omnidirectional mobile robot - Embedded.com

Embedding a kinematic controller in an omnidirectional mobile robot


Mobile robot embedded software, in order to allow successful performance of the robot, must cope with various kinds of activities, such as control of the robot actuators, processing of sensor readings and communication.

These activities are time-critical and should be performed ideally at the same time. But due to computational limitations, this perfect parallelism is almost never achieved in real world applications. The control of the robot’s movement should, thus, be developed with these computational restrictions in mind.

This work deals with the implementation of a kinematic controller for an omnidirectional robot, which must also perform sensor readings concurrently. The robot has several sensors from which it has to acquire data, and then a real-time operational system was used to accomplish concurrency requirements.

The robot hardware has a microcontrollers network, but only one of the nodes is used for the purposes of this paper: the PSoC 5LP, based on an ARM Cortex-M3 processor. The kinematic controller described in this work was embedded in the omnidirectional robot AxeBot. It consists of three swedish wheels whose axes are physically displaced 120 degrees from each other. A network consisting of three microcontrollers composes the computational nucleus of the Axe- Bot. The three microcontrollers are:

1) the DIL/NetPC 2486, from SSV Embedded Systems, with a Vortex86SX 300MHz processor and 64MB SDRAM;

2) the Mbed, based on the microcontroller NXP LPC1768 which, in turn, is based on an ARM Cortex-M3 processor; and

3) the Cypress Semiconductors’ PSoC 5LP, also based on an ARM Cortex-M3 core.

The network is heterogenous in the sense that it uses two different communication protocols be- tween its nodes: a CAN (Controller Area Net- work) network connects mbed and PSoC, and an Ethernet network connects mbed and DNP 2486.

In this context, multitasking is an indispensable requirement, and a Real-Time Operating Sys- tem (RTOS) may fulfill it, since it is capable of managing multiple tasks through a synchroniza- tion mechanism involving task prioritization and scheduling, providing an abstraction layer in the software design.

The RTOS used in this work was the FreeRTOS which can be ported to the PSoC 5LP. An advantage of this OS is that it is written in the C programming language, the same used by PSoC Creator, the IDE for PSoC 5LP development.

In the FreeRTOS the tasks may be in one of four states: running, in which it is executing; blocked, in which it is not able to run until some event occurs; ready, in which it is not executing, but is able to; and suspended, in which it is not running and it is not able to run.

All tasks are created in the ready state, and the task scheduler decides whether or not it can be in the running state based on its priority: if some higher priority task is already running, the task in the ready state waits until it gets blocked or suspended; if the running task has a lower priority than the task in the ready state, then the former is preempted by the last.

The sensors required processor time to be read, and then the implemented software made use of the prioritizing and semaphores mechanisms from the RTOS to allow for a synchronized processor time use, without compromise any of the tasks that the robot should perform.

The tests results of the kinematic controller were satisfactory, in the sense that the errors were small, and the robot was still able to perform sensing activities.

To read this external content in full, download the complete paper from the author archives at the Federal University of Bahia. 

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.