Get Latest Electronics / Electrical Projects directly to your Email ID

Line Following Robot With Real–time Viterbi Track–before–detect Algorithm (Electronics Project)


Line following robots are applied in numerous application areas. High reliability of the line estimation could be obtained by the application of Track–Before–Detect algorithms, like Viterbi algorithm. The hardware and software of the robot are shown in the paper.

Real–time constraint are discussed in this paper, related to the constructed robot. The obtained results shows the possibilities of tracking the single line using Raspberry Piv.2 and Linux operating system.


This algorithm uses window approach and the image is analyzed from bottom located window. After each processing step this moving window moves toward top part of image and the process is repeated until end of the image is achieved.

Local Paths of Trellis Example.

Local Paths of Trellis Example.


The mobile robot (Fig. 2) consist of solid wooden construction, four wheels, power supply and DC motors. It is testing platform for different hardware devices, with a specific constraints. Such flexibility allows the testing autonomous robot with on-board image processing and  computation, as well as remote control using specific wireless link. It could be equipped with different type cameras, like RBG, IR, Depth working together or alone. Multiple cameras could be mounted depending on test demands.


The Raspberry Pi v.2 board has four processor core 700MHz each. Previous version of Raspberry  Pi contains only single core, so hardware supported parallel processing is not possible in this board.

Single core board requires sequential processing (Fig. 4) so real–time processing is harder to achieve.  It is important that Linux is not real–time system and the non–critical application requires availability of computation power reserve. Four cores processor allows the parallel processing, so different tasks could be assigned to appropriate cores.

Two different Main Control System Processing Flows

Two different Main Control System Processing Flows.


The robot follows the line and estimate line very well. Low contrast line could be estimated but line should be dark for considered test. Dark obstacles may disturb estimation. Message exchange adds some delays but non–blocking mode is used. The processing speed could estimated using achieved frame per seconds (fps) value. Mean value for 0. 5 hour period is measured.


The most important problem (real–time image process-ing) was solved, by the selection of proper hardware and soft-ware implementation. This robot supports image processing with variable frame rate. Fixed frame rate is achieved after the reduction of image size and by the selection of optimization. The most important is not a selection of resolution and optimization flag, but proper design of Viterbi algorithm.

This algorithm requires a lot of computation, and some processor design (especially DSP) supports Viterbi processing in hardware. The optimization of Viterbi algorithm using different software approaches will be considered in further work. The application of Viterbi algorithm gives superior performance of line estimation, so it is accepted for particular hardware. Low power design requires FPGA implementation.

Source: West–Pomeranian University of Technology
Authors: Grzegorz MATCZAK | Przemysław MAZUREK

Download Project

Subscribe for Electronics / Electrical Project Downloads (Free):

Enter your email address:  

Discuss this Project:

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>