Gapped and Crossed Line Following with LEGO Mindstorms. Part 1. Challenge. Use of State Machines

We start a course for following a line with crosses and gaps. This is a challenge that one of the users at FLLCasts.com was trying to accomplish and asked us for advice. We present the whole challenge to you step-by-step. But first, let's also see the whole run of the line following algorithm. With this course, we also do an introduction of using State Machine as a programming pattern.

  • #204
  • 06 Jan 2016
  • 2:45

The gaps are 0.1 meters in length. The robot doesn't know where the gaps are, where the turns are. It should come from the start to the end. We show the complete line following run so that you have an idea of how the whole program behaves and what the result is at the end. 

The only way to properly learn how to follow lines is to actually do the programming at each step. Try to program the robot, and then share the results with us of how successful it was. 

While programming we implement a pattern. This pattern is called "State Machine". A state machine has a number of states and transitions between these states. We sometimes call these transitions "behaviours". 

Full course available at

Gaped and Crossed Line Following with LEGO Mindstorms

EV3 Competition Robot with 3 color sensors

Modification of the EV3 Competition Robot Full with light sensors attached to the front

English

For this video we got a request for more advanced line following algorithm for a robot that can follow a the line as shown on this field. This is a field from one of the users at fllcasts.com and we desided to build an algorithm that can follow this line. As you can see it's pretty complex, it has turns, it has gaps and it also has cross sections. It's a very interesting line and we decided to build this in the next few video, in this course we'll describe how do you program the robot to follow such a line. Now let's see an example and what is the final result from our work.

As you saw the robot was successful. Now let's look at the program and learn how do you build such a line following algorithm.

Courses and lessons with this Tutorial

This Tutorial is used in the following courses and lessons

Image for The power of State Machines. Gapped and Crossed Line Following with LEGO Mindstorms EV3
  • 12
  • 92:11
  • 0
Image for Challenge
  • 1
  • 0
  • 0
  • 3d_rotation 1