- Module 16
Navigation through Traffic
Programming – Road Behaviour & Automation
Module Identity
TitleNavigation through TrafficSubject AreasComputer Science TechnologyFormatExperiential and inquiry-based learning with FOSSBot; Visual programming; Collaborative teamwork (groups of 3-5); Gamification elements (interactive projects).Preparation RequirementsPre-synchronization of FOSSBot with Wi-Fi; Familiarity with the programming interface; Setup of classroom "maze" using chairs/boxes.Estimated Duration45 minutes (30 min lesson + 15 min assessment)Age Range13-16 years old (Lower/Upper Secondary)KeywordsAutomation, Robotic Systems, Ultrasonic Sensor, Obstacle Avoidance, Traffic Navigation, Logic Structures, Visual Programming.Summary"Navigation through Traffic" introduces students to the fundamentals of automation and physical computing by connecting code to the real world. Through hands-on experimentation with the FOSSBot robot, learners progress from basic movement commands to sophisticated sensor-based navigation. The module focuses on the ultrasonic sensor, enabling the robot to "see" and avoid obstacles, simulating real-world smart traffic systems. By solving maze challenges and programming obstacle avoidance logic, students develop critical problem-solving skills, adaptability, and collaborative efficiency in a creative, gamified environment.
Introduction
Connecting computers to the physical world is a cornerstone of modern robotics. This lesson guides students through the process of programming an autonomous vehicle capable of navigating a complex environment. Starting with basic directional commands (forward, reverse, rotate), students quickly advance to integrating sensory feedback.
The core of the lesson revolves around the ultrasonic sensor, which allows the FOSSBot to detect obstacles and make decisions—a fundamental concept in autonomous driving technology. Students apply this knowledge by creating a "traffic navigation" program, where the robot must successfully traverse a classroom maze, utilizing LED signals and movement logic to avoid collisions and reach an exit.Prerequisite Knowledge
- • Familiarity with a visual programming environment
- • Ability to create and debug programs
- • Understanding of loops and conditional statements
Learning Outcomes
By the end of this module, students will be able to:
Conceptual Understanding
- ✓ Explain how Ultrasonic sensors work and calibrate them
- ✓ Recognize the role of technology in smart object avoidance systems
- ✓ Identify basic functions and use of sensors
Programming & Implementation
- ✓ Program automation systems using logical structures (if, else, and)
- ✓ Operate the FOSSBot interface (connection, project input, editing)
- ✓ Record and interpret sensor values in real environmental conditions
Engineering & Problem-Solving
- ✓ Create and improve an “obstacle avoidance” system based on environmental data
- ✓ Design and program robotic systems to conduct experiments or creative learning projects
- ✓ Collaborate in groups to optimize robot function design
📐 Key Logic & Control Concepts
Obstacle Avoidance Logic:
REPEAT UNTIL (Distance < 5)
DO [Move Forward]The robot continues moving until the ultrasonic sensor detects an object closer than 5 cm.
Traffic Navigation Sequence:
1. Move Forward (Green Light)
2. Detect Obstacle -> Stop -> Red Light
3. Rotate 90° -> Move ForwardThis logic mimics real-world autonomous vehicle behavior, combining sensors, visual signals (LEDs), and movement.


