0% found this document useful (0 votes)
16 views

Automatic Zebra Crossing Using Raspberry PI

The Automatic Zebra Crossing project enhances pedestrian safety and convenience at zebra crossings using an Atmega8 microcontroller board, a time display, and Progisp software. The project features a pair of automatic gates positioned at both ends of the zebra crossing, closing whenever the traffic signal turns red to stop vehicles. This closure effectively restricts pedestrian movement beyond the zebra crossing area, ensuring enhanced safety.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

Automatic Zebra Crossing Using Raspberry PI

The Automatic Zebra Crossing project enhances pedestrian safety and convenience at zebra crossings using an Atmega8 microcontroller board, a time display, and Progisp software. The project features a pair of automatic gates positioned at both ends of the zebra crossing, closing whenever the traffic signal turns red to stop vehicles. This closure effectively restricts pedestrian movement beyond the zebra crossing area, ensuring enhanced safety.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology

ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

Automatic Zebra Crossing Using Raspberry PI


Kaumudi Tanajirao Patil1 Dhanashree Anandrao Salunkhe2
U.G, Student U.G, Student
Department of Electronics &Telecommunication Department of Electronics& Telecommunication
Engineering College, NMCOE, Peth, India Engineering College, NMCOE, Peth, India

S. T. Chaus3
Associate Professor
Department of Telecommunication
Engineering College, NMCOE, Peth, India

Abstract:- The Automatic Zebra Crossing project I. INTRODUCTION


enhances pedestrian safety and convenience at zebra
crossings using an Atmega8 microcontroller board, a time The "Automatic Zebra Crossing Project" utilizes the
display, and Progisp software. The project features a pair Raspberry PIand Raspberry PI software to enhance pedestrian
of automatic gates positioned at both ends of the zebra safety at busy intersections and zebra crossings. The project
crossing, closing whenever the traffic signal turns red to implements an automatic zebra crossing system with
stop vehicles. This closure effectively restricts pedestrian automated gates and a time display to provide valuable
movement beyond the zebra crossing area, ensuring information to pedestrians.
enhanced safety. The system works like an automatic
stairway, with the gates being opened or closed depending The project comprises the Raspberry PI microcontroller
on the condition of the traffic signal. As the central control and automated gates on both sides of the zebra crossing. The
device, the Atmega8 microcontroller board processes Raspberry PI serves as the central control unit, processing
inputs from the traffic signal and generates control signals inputs from traffic signals and pedestrian presence sensors to
to open and close the gates. The time display tells coordinate the system's functionality.
pedestrians how much time is left until they can cross in
real time. The Atmega8 microcontroller is programmed When the traffic signal turns red, the system activates
using the Progisp software, allowing the construction of the automated gates on both sides of the zebra crossing, acting
the control logic and synchronization with the traffic as physical barriers to prevent pedestrians from crossing
signal. The software enables the microcontroller to work during the red-light phase. This encourages pedestrians to
seamlessly with the gate motors and the time display. The wait safely on the zebra crossing.
Automatic Zebra Crossing system dramatically improves
pedestrian safety by keeping people inside the crossing The project integrates a time display module that reveals
area when the light is red. This system uses gates for the remaining time until the traffic light turns green. This aids
straying, lowering accident rates, and optimizing traffic pedestrians in making informed decisions about when to cross
flow. The project documentation outlines the software
implementation with Progisp and explains the hardware Inspired by an automatic staircase, the system uses a
setup. This setup involves an Atmega8 microcontroller motion detection mechanism for smooth pedestrian
board, gate motors, and a time display. The code movement. As the traffic signal turns green, the gates open
integrates a control logic for synchronization. automatically, ensuring a safe road crossing for pedestrians.

 Hardware Requirement: The Raspberry PI software is crucial for programming


the Raspberry PI, ensuring efficient and reliable operation. By
 Raspberry Pi- Pico leveraging the Raspberry PI platform, the project provides a
 Mobile Wi-fi Module cost-effective solution to improve pedestrian safety.
 Power Supply Unit
 Motor Unit The project documentation encompasses the hardware
 Relay Unit setup, including the Atmega8 microcontroller board, gate
motors, and time display, along with the software
 Software Requirement: implementation using Progisp. The code includes the control
logic for synchronizing the gate operation with the traffic
 Python signal. Additionally, the documentation provides guidelines
for system calibration, testing procedures, and potential
 PC
future enhancement
 Web page

IJISRT24JUN240 www.ijisrt.com 729


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

II. RELATED WORKS islands at pedestrian crossings. Post-implementation results


reveal these measures significantly reduce pedestrian-related
A. Literature Survey accidents. Thus, advanced safety measures like vehicle and
In 1930, the United Kingdom installed the first zebra infrastructure modifications, protective systems, training, and
crossing on Slough High Street, which feature white stripes behavioural knowledge enhancement prove to be key in
resembling a zebra's coat and offered pedestrian priority over decreasing the occurrence and severity of accidents involving
vehicular traffic as per the Road Traffic Act of 1934, Section vulnerable road users (Mako and Szakonyi, 2016).
18. To address the declining effectiveness of Belisha beacons
due to increasing car traffic and low usage by drivers and B. Hardware Setup
pedestrians, the Ministry of Transport experimented with The component selection analysis is based on specific
various designs to improve visibility and utilization. This led parts required for the smart crossing zebra project:
to the well-known black and white stripes being implemented
across 1,000 test locations in the UK, with credit given to  Servo Motor
George Charlesworth, a traffic engineer, and physicist, for
creating the zebra markings.

 Time Display Systems:


Time display systems play a crucial role in the automatic
zebra crossing project, providing pedestrians with
information about the remaining time for crossing.

 "Design and Implementation of a Countdown Timer for


Pedestrian Crossings" by Smith et al. (2016): This study
presents the design and implementation of a countdown
timer system for pedestrian crossings. The system utilizes
LED displays to inform pedestrians about the remaining
time to cross the road safely.
 "Evaluation of Different Time Display Systems for Fig 1. Servo Motor
Pedestrian Crossings" by Johnson et al. (2018): The
authors evaluate different time display systems, including The servo motor produces torque and speed based on the
digital displays, audio signals, and tactile indicators, to applied current and voltage. It operates as a closed-loop
determine their effectiveness in assisting pedestrians system, receiving commands from a servo controller and
during the crossing. delivering precise torque and velocity through a feedback
mechanism. Servo motors are electronic actuators that control
Pfortmueller (2014) conducted a retrospective study to angular or linear position, as well as velocity and
analyse the severity and mortality of injuries sustained by acceleration. For this project, a micro servo motor was chosen
adult pedestrians based on their use of zebra crosswalks. The due to its suitability within the project's scope.
study found that accidents on zebra crosswalks were more
prevalent compared to non-zebra crosswalk accidents.  Jump Wire
However, the severity of injuries in non-zebra crosswalk
accidents was significantly higher than in zebra crosswalk
accidents. Accidents involving large vehicles were also
associated with a higher risk of severe injury. The study
highlights the need for further prospective research, including
a detailed assessment of motor vehicle types and speed. It is
crucial to address these findings to reduce the number of road
traffic injuries and fatalities worldwide.

The increasing number of pedestrian accidents requires


urgent attention. Careless crossing is a primary reason behind
these accidents, which can result from inadequate time to Fig 2 Jump Wire
cross safely, crossing at excessive speeds, or encountering
unexpected factors. To address this issue effectively, one A jump wire, also known as a jumper or DuPont wire, is
alternative is to incorporate zebra crossing speed into an electrical wire with connectors or pins at each end. It is
roadway design and operation. used to interconnect components in a breadboard or test
circuit without the need for soldering. These wires are
Road traffic crashes often stem from a mix of factors inserted into slots on a breadboard or circuit board to establish
including road design, vehicle conditions, and the behaviour connections. Although jumper wires come in various colors,
of road users. We've investigated the primary causes of the colors do not hold specific meanings. However, they can
pedestrian fatalities and examined the safety impact of road be used advantageously to differentiate between types of
measures such as traffic lights, roundabouts, and refuge connections, such as ground or power.

IJISRT24JUN240 www.ijisrt.com 730


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

 LED (Light-Emitting Diode)  Raspberry PI

Fig 3 LED (Light-Emitting Diode) Fig 5 Raspberry PI

LEDs, or light-emitting diodes, are semiconductor light The Raspberry PI Raspberry Pi (/paɪ/) is a series of
sources that shine when current flows through them. They small single-board computers (SBCs) developed in
hold numerous advantages over traditional incandescent light the United Kingdom by the Raspberry Pi Foundation in
sources: they consume less power, last longer, are more association with Broadcom. A Raspberry Pi Zero with
durable, smaller in size, and switch faster. In this project, we smaller size and reduced input/output (I/O) and general-
employ LEDs as traffic signals for drivers and pedestrians purpose input/output (GPIO) capabilities was released in
alike. Red LEDs command a stop, while green LED. The November 2015 for $5 USD.
emitted light color depends on the energy electrons need to
traverse the semiconductor's band gap. To create white light,  LCD
we can use multiple semiconductors or a phosphor layer on
the semiconductor device.

 BO Motor

Fig 6 LCD Display

LCD (Liquid Crystal Display) is a flat panel display that


utilizes liquid crystals in its primary operation. It finds a case
for consumers and businesses, commonly appearing in
Fig 4 BO Motor smartphones, televisions, computer monitors, and instrument
panels. LCDs represented a significant technological leap
The BO motor is a lightweight DC-geared motor that over the technologies they replaced, such as light-emitting
provides good torque and RPM at lower voltages. It can run diode (LED) and gas-plasma displays. They enabled much
at approximately 200 RPM when powered by a single Li-Ion thinner displays of cathode ray tube (CRT) technology and
cell, making it perfect for battery-operated lightweight robots. consumed far less power as they operated by blocking light
The motor requires minimum or no lubrication due to its rather than emitting it. While LEDs emit light, LCDs use a
inherent lubricity, making it easy to maintain. It is an ideal backlight to produce images through liquid crystals. Liquid
choice for DIY enthusiasts and can be easily installed in crystal display, or LCD, derives its name from a combination
mobile robot cars, especially in 2WD platforms. of two states of matter: solid and liquid. It employs liquid
crystals to generate a visible image. These super-thin
technology display screens find widespread use in laptop
computer screens, TVs, cell phones, and portable video
games, offering a much slimmer profile than cathode ray tube
(CRT) technology.

IJISRT24JUN240 www.ijisrt.com 731


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

 Motor Diver III. PROPOSED WORK

A. Methodology
Creating an automatic zebra crossing project using
Raspberry PIand time display involves building a system that
detects traffic signals, controls the opening and closing of
gates, and implements an automatic mechanism to guide
pedestrians safely across the road. Below is a general
methodology to get you started:

 Components Needed :-

 Raspberry PI board
 Traffic signal module (to detect the red light)
 Servo motors (to control the gates)
Fig 7 Motor Diver  LED display module (for time display)
 Breadboard and jumper wires
Motor drivers serve a vital function in many motor-  Power supply (battery or adapter)
related projects. They amplify control and power, ensuring  Step-by-Step Methodology:
effective motor movement control. Acting as a bridge
between the microcontroller or control system and the motor,  Setup Hardware:
they transform low-power signals into high-power outputs. Connect the Raspberry PI to your computer and install
Motor drivers come with speed and direction control, current the Raspberry software. Assemble the hardware components
sensing, and protection features such as overcurrent and on the breadboard and connect them to the Raspberry PI
overtemperature. They vary in type, including brushed DC, according to their specifications and pin configurations.
brushless DC, and stepper motor drivers, each crafted for
specific motor needs. Robotics, automation, and automotive  Traffic Signal Detection:
industries rely on motor drivers for their high precision in Interface the traffic signal module with the Raspberry PI
motor control and energy efficiency, which are essential for to detect the red light. Use digital inputs to read the state of
the success of their projects. the traffic signal (e.g., red light).
 Adapter 12 V  Control Gates with Servo Motors:
Connect servo motors to the gates on both sides of the
zebra crossing. Write code to control the servo motors to open
and close the gates.

 Implementing Time Display:


Connect an LED display module to the Raspberry PI
board to display the time countdown for pedestrian crossing.
You can use either a 7-segment display or a dot matrix display
to show the time remaining for pedestrians to cross the road
safely.

 Coding the Raspberry:


Write the Raspberry PI to integrate all the components.
Use the inputs from the traffic signal and ultrasonic sensors
to determine the appropriate times for the gates to open and
close. Implement a timer to display the time remaining for
pedestrians to cross the road.

 Testing and Debugging:


Fig 8 Adapter 12 V Upload the code to the Raspberry PIand test the system.
Debug and make necessary adjustments to ensure smooth
The 12V adapter transforms wall outlet AC power into functionality.
12-volt DC power, offering a low-voltage DC supply for
electronics like routers, modems, speakers, and other small  Safety Considerations:
appliances. Its compact, cylindrical design features a plug for Pay attention to safety measures and ensure the gates do
device power input. Some adapters come with switchable tips not close while pedestrians are still crossing. Implement
for different devices. It's crucial to match the adapter's voltage failsafe mechanisms to prevent accidents.
and polarity with the device's

IJISRT24JUN240 www.ijisrt.com 732


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

 Documentation:  If the red light is detected, proceed to the next step.


Document the project, including circuit diagrams, code Otherwise, continue looping.
explanations, and any modifications made.
 Step 7: Close the Gates
B. Algorithm
 Activate the servo motors connected to the gates to close
 Step 1: Set up the Hardware them, preventing pedestrians from crossing.
 Set the positions of the servo motors to close the gates.
 Connect two servo motors to the Raspberry PI. These will
control the gates.  Step 8: Wait for Pedestrian Presence
 Connect sensors to detect the traffic signal status and
presence of pedestrians on the zebra crossing. Make sure  Continuously monitor the input from the pedestrian
all the connections are properly wired and secure. presence sensor.
 If a pedestrian is detected, proceed to the next step.
 Step 2: Define Pin Assignments Otherwise, continue looping.

 Assign Pins for the Servo Motors and Sensors. For  Step 9: Open the Gates
example:
 Deactivate the servo motors to open the gates and allow
 Gate 1 servo: Pin 2 pedestrians to cross.
 Gate 2 servo: Pin 3  Set the positions of the servo motors to open the gates.
 Traffic signal sensor: Pin 4
 Pedestrian presence sensor: Pin 5  Step 10: Wait for Pedestrian Clearance

 Step 3: Initialize Libraries  Continue monitoring the input from the pedestrian
Include the necessary libraries for servo motor control presence sensor.
and sensor input/output.  If no pedestrians are detected, proceed to the next step.
Otherwise, continue looping.
 Step 4: Set Up the Initial Configuration
 Step 11: Close the Gates Again
 Set the initial positions of the servo motors to keep the
gates open.  Activate the servo motors to close the gates and prevent
 Configure the sensor inputs and outputs. more pedestrians from crossing.
 Set the positions of the servo motors to close the gates.
 Step 5: Implement the Loop
In the main loop of your Raspberry PI code,  Step 12: Repeat the Process
continuously check the status of the traffic signal and the
presence of pedestrians.
 Return to Step 6 and continue the loop to monitor the
traffic signal and pedestrian presence.
 Step 6: Check Traffic Signal Status
 Block Diagram
 Read the input from the traffic signal sensor.

Fig 9 Project Block Diagram

IJISRT24JUN240 www.ijisrt.com 733


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

 Flowchart The system's input and output components included two


HC-SR04 Ultrasonic Sensors, one SG90 Micro Servo, several
LED lights, male-female jumper wires, and a standard
breadboard. The Raspberry PI board, with 32KB of flash
memory, was selected due to its easy trackability and
compatibility with the open-source IDE used for
implementing software instructions onto its SRAM. The IDE
can be conveniently downloaded from the Raspberry PI.cc
website, making manipulation of the system more accessible
when using Raspberry PI as the computational device.

The Raspberry PI board features 14 advanced


input/output pins (with 6 of them usable as PWM outputs), 6
simple inputs, a USB connection, an energy jack, and a reset
button. These components provide all the necessary elements
to develop a simple system. Powering the Raspberry PI can
be achieved through a USB link connected to a PC or laptop,
or by using an AC-to-DC connector to plug it into a battery.

 Future Enhancement

 The system incorporates advanced sensors, such as


infrared or ultrasonic sensors, to detect pedestrians
waiting to cross, thereby improving efficiency and
preventing unnecessary gate closures.
 The project integrates with the traffic light system to
ensure better synchronization between the gates and the
traffic signals, resulting in smoother traffic flow and
minimized waiting time for pedestrians.
 A mechanism is implemented to adjust the gate's opening
and closing speed, accommodating different pedestrian
flow rates and providing a more comfortable and user-
friendly experience.
 An emergency stop button or switch is included, allowing
pedestrians to halt the gate operation if needed, especially
in situations compromising pedestrian safety or in case of
malfunctions.
 A smart control system is developed, which analyses real-
time traffic conditions, such as vehicle and pedestrian
density, to optimize gate operation using machine
learning algorithms or external data sources.
 Audio/visual signals, such as warning lights or sound
alerts, are integrated to provide additional cues for
pedestrians and drivers, enhancing safety and awareness
of the gate operation.
 Accessibility features are incorporated to cater to
individuals with disabilities, ensuring that the zebra
Fig 10 Project Flowchart. crossing is accessible to a wider range of pedestrians.
These features may include audible signals or tactile
IV. IMPLEMENTATION AND TESTING feedback systems.
 The system implements a data logging system to record
 Implementation the number of crossings, gate usage patterns, and
The proposed system needed proper scaling before pedestrian waiting times. This data can be used for
implementation in a real-life scenario to ensure perfect output analysis and optimization of the system's performance.
in a controlled environment. For showcasing the capabilities  A mobile application is developed, enabling pedestrians
and potential of the system, a prototype model was developed to request gate operation or provide feedback on the
using a miniature version. The computational device chosen system, enhancing user engagement and facilitating
for the prototype was Raspberry PI, which offers open-source communication and updates.
hardware with various easy-to-implement functionalities.

IJISRT24JUN240 www.ijisrt.com 734


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

 Output Below are the Final Results.

Fig 11 LCD Indicating Time to Stop Pedestrian Fig 14 LCD show Time Remaining for
Pedestrian to Cross Road.

Fig 12 Signal is Red for Pedestrian.


Fig 15 Now the Gate is Open for Road Cross

V. CONCLUSION

The Raspberry PI-based automatic zebra crossing


project demonstrates an innovative approach to enhance by
leveraging technology for a safer urban environment. It is part
of a larger city initiative, showcasing the potential of
integrating mechatronic systems with IoT technology to
create a Smart Zebra Crossing. The prototype consists of
three subsystems: manual, automated, and Blynk App-
controlled, providing flexibility and usability in different
scenarios.

The system seamlessly integrates the instrumentation


system, the actuation system, and the human-machine
interface. Intensive programming efforts have optimized the
prototype's performance, ensuring it effectively responds to
real-world scenarios.

Fig 13 Signal is Green for Pedestrian

IJISRT24JUN240 www.ijisrt.com 735


Volume 9, Issue 6, June – 2024 International Journal of Innovative Science and Research Technology
ISSN No:-2456-2165 https://doi.org/10.38124/ijisrt/IJISRT24JUN240

The microcontroller chosen for the project is NodeMCU


ESP8266, which offers cost-effective and energy-efficient
solutions while providing seamless Wi-Fi and Bluetooth
connectivity. The project implementation draws heavily from
mechatronics principles, and the developer has conducted
significant online research to devise effective prototype
design and mechanics. Programming complexity has honed
the developer's coding skills, contributing to valuable hands-
on experience.

By integrating IoT and mechatronics concepts, the


project showcases the synergy between hardware and
software, providing valuable insights into smart city
infrastructure. The primary concern of the automatic zebra
crossing is pedestrian safety, aiming to create safer and more
efficient road-crossing experiences for pedestrians. The
project highlights the potential of combining emerging
technologies to tackle urban challenges and improve the
quality of life.

Implementing a mechatronic-based automated system is


a promising step toward building cities with innovative and
adaptive infrastructure. We expect continuous improvements
and refinements in the prototype design, reflecting the
iterative nature of modern technology projects. The
Raspberry PI-based solution is scalable and adaptable for
various pedestrian crossings in urban environments.

REFERENCES

[1]. R. Methorst, R. Eenink, J. Cardoso, K. Machata and J.


Malasek, "Single unprotected road user crashes:
Europe we have a problem!", Transp. Res. Procedia,
vol. 14, pp. 2297-2305, Jan. 2016.
[2]. D. R. Green, J. Ward and N. Wyper, "Solar-powered
wireless crosswalk warning system", Jan. 2008.
[3]. Road Traffic Injuries, 2020, [online]
Available: https://www.who.int/news-room/fact-
sheets/detail/road-traffic-injuries.
[4]. A. H. Ariffin, Z. Mohd Jawi, M. Md Isa, K. Abu
Kassim and S. Wong, "Pedestrian casualties in road
accidents-Malaysia perspective", Proc. MIROS Road
Saf. Conf., pp. 280-289, 2010.
[5]. C. Bastien, R. Wellings and B. Burnett, "An evidence
based method to calculate pedestrian crossing speeds
in vehicle collisions (PCSC)", Accident Anal.
Prevention, vol. 118, pp. 66-76, Sep. 2018.
[6]. B. Hoe Goh, K. Subramaniam, Y. Tuck Wai and A.
Ali Mohamed, "Pedestrian crossing speed: The case of
Malaysia", Int. J. Traffic Transp. Eng., vol. 2, pp. 323-
332, Dec. 2012.
[7]. D. Muley, W. Alhajyaseen, M. Kharbeche and M. Al-
Salem, "Pedestrians’ speed analysis at signalized
crosswalks", Procedia Comput. Sci., vol. 130, pp.
567-574, Jan. 2018.
[8]. S. Movahed, S. P. Azad and H. Zakeri, "A safe
pedestrian walkway; creation a safe public space
based on pedestrian safety", Procedia Social Behav.
Sci., vol. 35, pp. 572-585, Jan. 2012.

IJISRT24JUN240 www.ijisrt.com 736

You might also like