SlideShare a Scribd company logo
1 of 74
Download to read offline
MINISTRY OF EDUCATION AND TRAINING
HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY AND EDUCATION
FACULTY FOR HIGH QUALITY TRAINING
GRADUATION THESIS
ELECTRONICS AND TELECOMMUNICATION
ENGINEERING TECHNOLOGY
RESEARCH, DESIGN AND IMPLEMENTATION OF
AN AUTOMATIC CAR PARKING SYSTEM
TRAN NHAT HUY
TRAN DUY KHANH
SKL 0 1 1 1 5 8
Ho Chi Minh City, August, 2023
LECTURER: Ph.D. TRAN VI DO
STUDENT: VO HUY HOANG
HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY AND EDUCATION
FACULTY FOR HIGH QUALITY TRAINING
GRADUATION PROJECT
RESEARCH, DESIGN AND IMPLEMENTATION OF AN
AUTOMATIC CAR PARKING SYSTEM
VO HUY HOANG
Student ID : 18146020
TRAN NHAT HUY
Student ID : 18146024
TRAN DUY KHANH
Student ID : 18146033
Major: MECHATRONICS ENGINEERING
Advisor: Dr. Tran Vi Do
Ho Chi Minh City, 7th
of August 2023
Disclaimer
The contents of this report reflect the views of the authors, who are solely responsible for
the facts and the accuracy of the material and information presented here. This report is not
a standard, specification or regulation.
Acknowledgements
We are over helmed in all humbleness and gratefulness to acknowledge our depth to all
those who have helped us to put these ideas, well above the level of simplicity and into
something concrete.
I would like to express my special thanks of gratitude to my teacher Tran Vi Do as well as
our principal who gave me the excellent opportunity to do this wonderful project on this
interesting topic, which also helped us in doing a lot of research and we came to know
about so many new things. We are thankful to them.
Any attempt at any level cannot be satisfactorily completed without the support and
guidance of our teacher and friends.
We would like to thank my wonderful friends who helped us a lot in gathering different
information, collecting data and guiding us from time to time in making this project, despite
of their busy schedules, they gave me different ideas in making this project unique.
Table of Contents
ABSTRACT..................................................................................................................................................1
CHAPTER 1: INTRODUCTION .................................................................................................................2
1.1. Motivation of the research ...........................................................................................................2
1.2. The scientific and practical significance of the topic ....................................................................2
1.3. Objective of research ....................................................................................................................2
1.4. Target and research area ..............................................................................................................2
1.5. Methodological basic ....................................................................................................................2
1.6. Benefit of project ..........................................................................................................................2
CHAPTER 2: LITERATURE REVIEW ......................................................................................................3
2.1. The introduction of automatic car parking systems .....................................................................3
2.2. Overview of traffic station in Vietnam..........................................................................................3
2.2.1. Demand for parking lot in Vietnam recently ................................................................................5
2.2.3. Misidentification of automatic parking lot ...................................................................................6
2.3. General process.............................................................................................................................7
2.4. Some of car parking systems.........................................................................................................8
2.4.1. Tower Parking System...................................................................................................................8
2.4.2. Silo Parking System.......................................................................................................................9
2.4.3. Rotary Parking System ..................................................................................................................9
2.5. Comparison .................................................................................................................................10
2.5.1. Automatic Car Parking System....................................................................................................10
2.5.2. Traditional Spontaneous Parking................................................................................................11
2.6. Install Process..............................................................................................................................12
2.9. Stepper Motor.............................................................................................................................14
2.9.1. Construction and Working Principle...........................................................................................14
2.9.2. Types of Stepper Motor..............................................................................................................15
2.10. Belt Transmission........................................................................................................................16
2.11. Lead Screw ..................................................................................................................................16
2.12. Electrical Components ................................................................................................................18
CHAPTER 3: DESIGN AND IMPLEMENTATION............................................................................23
3.1. Block Diagram..............................................................................................................................23
3.1.1. Block Listing ................................................................................................................................23
3.1.2. Block Diagram .............................................................................................................................24
3.2. Operational Description..............................................................................................................24
3.3. Mechanical Design ......................................................................................................................24
3.3.1. Calculation and equipment choosing ..........................................................................................24
3.3.2. Solidworks drawing......................................................................................................................30
3.3.3. Some Of Detailed Drawings ................................................................................................32
3.4. Electrical Design..................................................................................................................37
3.4.1. Components........................................................................................................................37
3.4.2. Block Diagram......................................................................................................................37
3.4.3 Control Design.....................................................................................................................38
CHAPTER 4: EXPERIMENT AND RESULT ......................................................................................40
4.1. Experiment..........................................................................................................................40
4.2. Result..................................................................................................................................45
4.3. Overall.................................................................................................................................45
CHAPTER 5: CONCLUSION AND IMPROVEMENT.......................................................................47
5.1. Conclusion..........................................................................................................................47
5.2. Improvement ......................................................................................................................47
References..................................................................................................................................................48
Appendix....................................................................................................................................................49
List of Figures
Figure of Chapter 2
Figure 2. 1: Traffic congestion in metropolises on peak hours [1]................................................................4
Figure 2. 2: The vacant lands become temporary parking, affecting urban beauty [2]................................5
Figure 2. 3: Car parked on the pavement [3]................................................................................................6
Figure 2. 4: GeneralProcessDiagram ...............................................................................................................7
Figure 2. 5: Tower Parking System [4]...........................................................................................................8
Figure 2. 6: Silo Parking System [5].............................................................................................................9
Figure 2. 7: Rotary Parking System [6].......................................................................................................10
Figure 2. 8: Automatic Car Parking System Principle..................................................................................10
Figure 2. 9: Traditional Spontaneous Parking .............................................................................................11
Figure 2. 10: Install Process Diagram ..........................................................................................................12
Figure 2. 11: Stepper Motor [7] ..................................................................................................................14
Figure 2. 12: Stepper Motor Construction [8].............................................................................................15
Figure 2. 13: Square Thread [9]...................................................................................................................17
Figure 2. 14: Acme Thread [9].....................................................................................................................17
Figure 2. 15: Buttress Thread [9].................................................................................................................18
Figure 2. 16: Power Source .........................................................................................................................18
Figure 2. 17: Arduino Mega 2560 R3 [10] ...................................................................................................19
Figure 2. 18: LCD 1602 [11].........................................................................................................................19
Figure 2. 19: RFID RC522 [12]......................................................................................................................21
Figure 2. 20: Proximity Sensor ....................................................................................................................21
Figure of Chapter 3
Figure 3. 2: Block Listing .............................................................................................................................23
Figure 3. 3: Block Diagram...........................................................................................................................24
Figure 3. 4: Several types of Shaped Aluminums........................................................................................26
Figure 3. 5: V-Slot Shaped Aluminum..........................................................................................................26
Figure 3. 6: Shaped Aluminum 20x20 .........................................................................................................26
Figure 3. 7: Electric motor and speed reduction machine..........................................................................28
Figure 3. 8: The front-side view of prototype .............................................................................................30
Figure 3. 9: The left-side view of prototype................................................................................................30
Figure 3. 10: The back-side view of machine ..............................................................................................31
Figure 3. 11: The complete prototype ........................................................................................................31
Figure 3. 12: Total Assembly Prototype ......................................................................................................32
Figure 3. 13: 3D Assembly Prototype..........................................................................................................32
Figure 3. 14: Parking Car Frame ..................................................................................................................33
Figure 3. 15: Assembly Table.......................................................................................................................33
Figure 3. 16: Lifting Pad...............................................................................................................................34
Figure 3. 17: Part cb4 ..................................................................................................................................34
Figure 3. 18: Part cb5 ..................................................................................................................................35
Figure 3. 19: Plate Z.....................................................................................................................................35
Figure 3. 20: Nut Screw ..............................................................................................................................36
Figure 3. 21: Fixed Frame...........................................................................................................................36
Figure 3. 22: Electrical block diagram .........................................................................................................37
Figure 3. 23: Electric circuit.........................................................................................................................38
Figure 3. 24: Operational flowchart............................................................................................................38
Figure 3. 25: Control flow chart ..................................................................................................................39
Figure of Chapter 4
Figure 4. 1: Small car model......................................................................................................................40
Figure 4. 2: RFID card .................................................................................................................................41
Figure 4. 3: Control board ..........................................................................................................................41
Figure 4. 4: Car in standby position.............................................................................................................42
Figure 4. 5: Infrared sensor to detect car.....................................................................................................42
Figure 4. 6: Successfully Parking .................................................................................................................43
Figure 4. 7: Parking out mode.....................................................................................................................43
Figure 4. 8: Testing with the blocking standby position.............................................................................44
Figure 4. 9 : Sucessfully Parking Out .........................................................................................................44
LIST OF TABLES
Table 3. 1: Electrical Components...............................................................................................................37
1
ABSTRACT
The growing number of vehicles in metropolitan areas has resulted in an increase in the
demand for parking places. Traditional parking systems are becoming obsolete, inefficient,
and time-consuming. Automatic car parking systems have developed as a viable answer
to this problem. This abstract presents an overview of autonomous car parking systems,
including their essential components and advantages. To automate the parking procedure,
automatic car parking systems employ advanced technology such as sensors, cameras, and
computer algorithms. These technologies do not require human interaction, allowing for
more efficient utilization of available parking space. Vehicles are steered and positioned
inside the parking lot using a combination of sensor data and clever algorithms, ensuring
that the available space is used optimally. Finally, the system is almost complete when it is
possible to identify and analyze the number of license plates, count the remaining space
up to 90%
Keywords: Automatic car parking systems, human interaction, combination of sensor data,
clever algorithms , license plates.
2
CHAPTER 1: INTRODUCTION
1.1. Motivation of the research
In recent years, there has been a growing interest in the development and implementation
of automatic car parking systems. These systems utilize advanced technologies and
algorithms to efficiently park vehicles without human intervention. The motivation behind
the research and development of automatic car parking systems stems from several key
factors, including the increasing global urbanization, limited parking space availability,
environmental concerns, and the potential for improved efficiency and convenience.
1.2. The scientific and practical significance of the topic
- Design the Automatic Car Parking System with the best product to serve the customer’s
demand.
- Improve more about the quality of product, structure of machine than the other type of
traditional way.
1.3. Objective of research
The major is to research about the problem of current car parking system, thereby offering
many various solution. One of the best solution that our team find out that is to build an
fully automatic car parking system which make it more convenient for people to park their
cars without worrying about safety, security, saving time and easy to operate.
1.4. Target and research area
- Research about the technology of an Automatic Car Parking System.
- Design and assemble structure of machine.
- Calculate the transmission structure design.
- Research the electrical and control design.
1.5. Methodological basic
Investigate and analysis the advantages and disadvantages of the Automatic Car Parking
System to have several improvements in the future.
1.6. Benefit of project
Overall, automatic automobile parking systems offer a variety of advantages, including
greater parking capacity, time and cost savings, convenience, safety, environmental
sustainability, and integration with smart city projects. These benefits make them an
appealing solution for addressing parking issues in highly populated locations.
3
CHAPTER 2: LITERATURE REVIEW
2.1. The introduction of automatic car parking systems
In recent years, cities around the world have encountered several issues when it comes to
properly and successfully parking vehicles. Population development, along with
insufficient parking spots, has resulted in increased congestion, traffic difficulties, and
driver discontent. Advanced technologies have been developed to address these
difficulties, paving the path for the adoption of automatic car parking systems.
Automatic automobile parking systems are cutting-edge technologies that maximize
parking space use and ease the parking process. These technologies are intended to reduce
the time and effort required for vehicles to locate parking spaces while increasing parking
facility capacity overall. Automatic automobile parking systems provide a seamless and
convenient experience for both drivers and parking attendants by integrating numerous
components such as sensors, cameras, computer algorithms, and robotic mechanics.
The technology that powers automatic parking systems is based on a network of sensors
strategically placed throughout the parking complex. These sensors continuously monitor
parking space availability and communicate real-time data to a central control system. The
control system analyzes the data and finds the best parking place for an arriving vehicle
using clever algorithms. Once a parking space is given, the system directs the driver via
clear signage or even autonomous driving mechanisms, offering a hassle-free parking
experience.
Furthermore, automated parking systems can be linked to modern payment mechanisms
and smartphone apps. This allows for smooth payment processing and allows vehicles to
secure parking places ahead of time, giving them convenience and peace of mind. These
systems can also help parking operators manage their facilities more efficiently, analyze
parking patterns, and generate important insights for future planning and improvement.
Finally, the emergence of automatic car parking systems constitutes a huge improvement
in parking technology. These systems transform the way vehicles are parked by utilizing
cutting-edge technologies to optimize space use, improve security, and simplify the
parking procedure.
These technologies, with their potential to automate parking activities, present a viable
solution to the issues that urban regions have in managing parking spaces efficiently. As
technology advances, we may anticipate even more developments in autonomous
automobile parking systems, resulting in even more fluid and intelligent parking
experiences for drivers globally.
2.2. Overview of traffic station in Vietnam
4
The large population of metropolises means that people's transportation needs increase,
which directly increases the number of individual vehicles. City managers should address
traffic flow issues to reduce peak-hour traffic congestion by constructing additional
infrastructure such as highways, undergrounds, expanding additional routes to meet vehicle
density, and developing many parking lots to meet resident demand.
For example, in certain large cities in our country today, such as Ho Chi Minh City,
obtaining a parking lot in the city center is quite difficult, because daily car traffic in the
city is always far more than the number of built-in parking lots.
Figure 2. 1: Traffic congestion in metropolises on peak hours [1]
Furthermore, the city's lack of measures to develop static traffic has slowed the
development of developing additional parking lots. Furthermore, initiatives to address the
lack of parking lots have yet to be effective because investors have not recognized their
potential. Currently, the state of parking lots in major cities is becoming an issue.
As usual, our country is celebrating Tet. Meanwhile, there are many unofficial parking lots
that exist to profit off people's car deposits but do not provide security, quality
management, or make ticket rates prohibitively exorbitant, leaving many people
disappointed. As a result, there is currently a high demand for smart and secure parking for
the driver, help to reduce the problem of over traffic in the urban area.
5
Figure 2. 2: The vacant lands become temporary parking, affecting urban beauty [2]
2.2.1. Demand for parking lot in Vietnam recently
Recognizing the truth of many flaws in parking in Ho Chi Minh City. Our group has
developed an automatic parking lot system. As a result, the device is highly valued for its
user safety while reducing time and personnel costs.
According to Ho Chi Minh City Police statistics, the average in the city occurred 50-100%
of motorbike losses, with hospitals, supermarkets, commercial areas, markets, and so on
accounting for 30%. The primary reason is that the thief used a fraudulent ticket, the
number plate, or the automobile holder misplaced the ticket. The parking system arose as
a result of this.
Our team decided to use this model as the theme for our research because of its security.
We will show genuine facts to persuade investors, potential partners, or readers that your
business will attract a large number of clients in a booming industry and can guarantee
sales that outperform the competition.
This is one of the best and most specific components of the company plan, which includes
taking into account the present market size and market development patterns. Many of the
following sections of the business plan, such as production, marketing, and the total capital
required, will be predicated on the sales prediction given in this section. Here are the
components that we wish to highlight in our product market analysis.
6
Figure 2. 3: Car parked on the pavement [3]
2.2.2. Current difficulties
The traffic jam is usually a popular topic, and there are numerous channels that show this
problem to the society such as radio, and television that post about it, as well as a channel
that specializes in delivering information on traffic spots in the area. The city is full of the
car flow on the streets is so large and complicated that the capacity of the current roadways
is limited.
However, due to the massive number of vehicles, the current parking points is not enough
for the needs of customers. So the major reason are:
1. Car senders' attitudes sometimes become sensitive, as well as their professional levels.
2. The security of most parking park is not following the standard.
3. Customers spend a long time to go to a nearby parking lot and they do not know about
the state of the parking park which they are heading to.
4. Customers find it uncomfortable to wait a long period for their turn during vehicle
sending times.
2.2.3. Misidentification of automatic parking lot
Many people argue that the Automatic parking lot technology does not provide sufficient
assurance of safety. Specifically, in order to operate this system, it is evident that human
resources must be decreased, leading people to believe that there is a shortage of
7
individuals who look after their property. Despite the reduction in human resources, we
believe the Automatic Parking System still assures the ability to protect users' property.
Smart technology allows gadgets to communicate with one another and provide data to a
website, allowing the supervisor to control the parking lot from afar. Furthermore, using
both real cards and license plates will save money.
Another problem is that many businesses are still hesitant to replace traditional parking lots
with smart parking lots because they believe that even if they cut labor, they will still incur
significant costs in maintaining the Automatic parking lot. This is not incorrect, but if we
look at our country's parking demands, we will see that.
The Automatic parking lot system's potential. Indeed, the Automatic parking lot system
will eliminate the majority of traditional car park difficulties while enhancing performance
and being convenient and comfortable for customers every time they visit. Aim of project
In this project, we want to build an Automatic parking lot system prototype with all of the
necessary functionalities without spending too much money in order to demonstrate that a
Automatic parking lot is a viable parking solution for cities. To beat the challenges that
traditional parking lots have while also improving the consumer experience when using
this service. Customers may thus follow the status of parking lots from anywhere in order
to make informed judgments.
2.3. General process
Figure 2. 4: General Process Diagram
1. Entrance: The entry point of the parking park.
2. Vehicle Detection: Sensors will detect the appearance of a vehicle.
8
3. Parking Space Selection: The system selects an appropriate parking space based on many
factors.
4. Vehicle Guidance: The system provides instructions to the driver on how to navigate to
the selected parking space.
5. Parking Space: The physical parking space where the vehicle will be parked.
6. Vehicle Position Control: The system controls the vehicle's movement and positioning
within the parking space.
7. Parking Completion: Confirmation that the vehicle has been successfully parked.
8. Exit: The exit point of the parking facility.
2.4. Some of car parking systems
2.4.1. Tower Parking System
An elevator that transfers vehicles to a parking area surrounding the elevator shaft makes
up the tower parking system. The parking tower's additional storeys were added using this
format. The central lift unit in the tower parking system can only move vertically and must
park on both sides. The system's primary benefit is that it can be integrated into an existing
structure without affecting the main structure's vibration or sound levels and uses much
less space than a conventional parking lot.
Figure 2. 5: Tower Parking System [4]
9
2.4.2. Silo Parking System
The vehicle parking and retrieval is handled by a single central positioning mechanism on
the cylinder-shaped silo systems. the outer perimeter of the center was filled with parked
cars. A lift/rotation mechanism that completes vehicle positioning occupies the core and
often only allows one vehicle to be driven at once.
The silo's mechanics, on the other hand, permit simultaneous up/down and axial
positioning, which can move cars swiftly. The silo parking system can be constructed
above ground or underground and is best suited for locations with very poor soil conditions.
The silo system can be utilized with one or more parking modules, but typically only one
car can be parked or retrieved at a time.
Figure 2. 6: Silo Parking System [5]
2.4.3. Rotary Parking System
The rotary parking system was created specifically to fit more than two cars in the
horizontal area. The building can fit six carriages in a place meant for two, and depending
on user needs, it can be modified to fit bigger numbers. It can also be utilized successfully
in several zones. restricted area in terms of size. Cars access the parking lot on the ground
floor under this system. When an empty compartment reaches the ground floor, all the
carriages are then turned clockwise. To unload an automobile, all the vehicles are turned
10
clockwise until the chosen vehicle is on the ground. In order for the next car to be loaded
or for another vehicle to be unloaded, the driver now exits the system.
Figure 2. 7: Rotary Parking System [6]
2.5. Comparison
Both modern method (Automatic Car Parking System ) and traditional spontaneous
parking have their competitive advantages.
2.5.1. Automatic Car Parking System
Figure 2. 8: Automatic Car Parking System Principle
Outstanding Feature
11
Automated Operation: Automated car parking systems automate the entire parking
operation by utilizing advanced technology and machinery. Robotic systems typically park
vehicles in specific zones, removing the need for human interaction.
Faster and More Efficient: Automatic car parking systems can significantly reduce the time
required for parking and retrieving vehicles. The process is streamlined and automated,
resulting in quicker turnaround times and reduced congestion.
Enhanced Safety: With automated parking systems, the risk of human error is significantly
reduced. The robotic mechanisms are designed to park vehicles precisely and safely,
minimizing the chances of collisions or damage to vehicles.
2.5.2. Traditional Spontaneous Parking
Figure 2. 9: Traditional Spontaneous Parking
Outstanding Features
Traditional parking systems have been in use for a long time, and most people are familiar
with how they work. Users understand how to obtain a ticket, locate a parking space, and
pay at a central payment station or machine.
When compared to more modern automated systems, implementing a traditional parking
system can be quite inexpensive. It does not necessitate sophisticated technology or
12
substantial infrastructure, making it a cost-effective solution, particularly for smaller
parking facilities or temporary parking arrangements.
Traditional parking systems are versatile in terms of the types of vehicles they can
accommodate
Traditional parking systems are versatile in terms of the types of vehicles they can
accommodate. They may be customized to handle a variety of vehicle sizes, including
motorbikes, bicycles, and big vehicles, without requiring considerable modifications.
Also, security is one of the major problem that affecting to the driver when they are not
sure that their car will be in the perfect state while leaving for a period of time.
2.6. Install Process
Figure 2. 10: Install Process Diagram
First step: Research the customer’s demand
Second step: Design the overall system architecture.
Third step: Construct the frame of machine.
Fourth step: Install various sensors, such as ultrasonic or infrared sensors, at appropriate
locations to detect the presence of vehicles.
Fifth step: Develop a control system to manage the overall operation of the parking system.
Sixth step: Install mechanical components such as conveyors, lifts, and platforms for
vehicle movement. Integrate motors, gears, and pulley systems to enable automated vehicle
transportation within the parking system.
Research
driver’s
demands
System Design
Assemble the
frame
Install various
sensors
Establish a
communication
network
Install
mechanical
components
Design an
interface
Ensure safety
features are in
place
Testing and
Commissioning
Deployment
and
Maintenance
13
Seventh step: Design and develop a user-friendly interface for drivers to interact with the
parking system , provide benefit solution to help the user or driver to interact more efficient
and controllable.
Eighth step: Implement security measures like surveillance cameras and access control
systems (RFID technique) . Ensure safety features are in place, such as emergency stop
buttons and obstacle detection mechanisms.
Ninth step: Conduct extensive testing to verify the functionality and performance of the
automatic car parking system.
Tenth step: Establish a regular maintenance schedule to ensure proper functioning.
2.7. RFID Technique
RFID stands for Radio Frequency Identification (radio frequency recognition). It is a
remote radio recognition technique, allowing data on a chip to be read "do not expose"
through the radio wave path at a distance from 50 cm to 10 meters, depending on the type
of RFID label card.
A magnetic card will be issued to service users. To identify and track radio waves, this sort
of card comprises ICs with identity information about a product, animal, or person.
The magnetic cards will be connected to the automobile providing information in the
parking lot, which means your information will be better controlled. Magnetic cards,
similar to ID cards for automobile owners and cars. This card's information is unique. The
frequency range of each RFID card will be different.
It acts as a signal reader/scanner. When a card passes through the electromagnetic area due
to the antenna generated, the information on the card will be read and decoded.
2.8. UART Protocol
UART (Universal Asynchronous Receiver-Transmitter) asynchronous serial data
transmission, this is one of the most popular device-to-device communication protocols.
UART communication is widely used in applications to communicate with modules such
as: Bluetooth, Wifi, RFID card reader module with Raspberry Pi, Arduino or another
microcontroller. This is also a common and popular communication standard in the
industry.
In UART communication, two UARTs communicate with each other directly. The
communication A UART translates parallel data from a control device, such as a CPU, into
14
serial data, sends it serially to a receiving UART, and then converts the serial data back
into parallel data for the receiving device.
2.9. Stepper Motor
An electromechanical device known as a stepper motor transforms electrical power into
mechanical power. Additionally, it is a synchronous, brushless electric motor that has a
large number of steps per entire rotation.
As long as the motor is carefully sized for the application, the position of the motor can
be regulated precisely without the use of a feedback device. When an electrical pulse is
applied, the stepper motor turns the motor shaft a specific amount using the theory of
operation for magnets.
2.9.1. Construction and Working Principle
 Construction:
The construction of a stepper motor is fairly related to a DC motor. It includes a permanent
magnet like Rotor which is in the middle & it will turn once force acts on it. This rotor is
enclosed through a no. of the stator which is wound through a magnetic coil all over it. The
stator is arranged near to rotor so that magnetic fields within the stators can control the
movement of the rotor. [7]
Figure 2. 11: Stepper Motor [7]
The stepper motor can be controlled by energizing every stator one by one. Therefore, the
stator will magnetize & works like an electromagnetic pole which uses repulsive energy
on the rotor to move forward.
The stator’s alternative magnetizing as well as demagnetizing will shift the rotor gradually
&allows it to turn through great control.
15
Figure 2. 12: Stepper Motor Construction [8]
2.9.2. Types of Stepper Motor
There are three main types of stepper motors, they are:
+ Permanent magnet stepper
+ Hybrid synchronous stepper
+ Variable reluctance stepper
 Permanent Magnet Stepper Motor
Permanent magnet motors use a permanent magnet (PM) in the rotor and operate on the
attraction or repulsion between the rotor PM and the stator electromagnets. This motor
includes permanent magnets in the construction of the motor. This kind of motor is also
known as tin-can/can-stack motor. The main benefit of this stepper motor is less
manufacturing cost. [7]
 Variable Reluctance Stepper Motor
Variable reluctance (VR) motors have a plain iron rotor and operate based on the principle
that minimum reluctance occurs with minimum gap, hence the rotor points are attracted
toward the stator magnet poles. The stepper motor like variable reluctance is the basic type
of motor and it is used for the past many years. As the name suggests, the rotor’s angular
position depends on the magnetic circuit’s reluctance that can be formed among the teeth
of the stator as well as a rotor. [7]
 Hybrid synchronous Stepper Motor
16
Hybrid stepper motors are named because they use a combination of permanent magnet
(PM) and variable reluctance (VR) techniques to achieve maximum power in small
package sizes.
The most popular type of motor is the hybrid stepper motor because it gives a good
performance as compared with a permanent magnet rotor in terms of speed, step resolution,
and holding torque. But this type of stepper motor is expensive as compared with
permanent magnet stepper motors. This motor combines the features of both the permanent
magnet and variable reluctance stepper motors. These motors are used where less stepping
angle is required like 1.5, 1.8 & 2.5 degrees. [7]
2.10. Belt Transmission
 Advantages of belt transmission:
+The key benefits of belt and pulley transmission systems include their affordability,
lubrication-free operation, and silent operation. These are the reasons why they are utilized
in household appliances. Slip can be helpful in some situations.
+ The driving belt may slip, for instance, if a machine like a pillar drill becomes stuck. This
could shield the user from harm and safeguard the drive motor from deterioration.
 Disadvantages of belt and pulley transmission:
+ The biggest drawback is that slips can happen. Therefore, they should only be utilized in
situations where slip won't interfere with machine operation.
2.11. Lead Screw
A mechanical linear actuator known as a lead screw transforms rotational motion into linear
motion. Its functionality depends on the screw shaft and nut threads gliding past one
another without using ball bearings. Because the screw shaft and the nut come in direct
touch with one another and have a wide surface area, friction losses are larger. Lead screw
threads have changed over time to reduce friction.
Types of Lead Screw Threads
 Square Thread:
The square thread has its flanks at right angles to the axis of the screw. No radial or bursting
pressure is acting on the nut since square threads have a 00-thread angle. Square threads
have less resistance to motion and less friction.
Square threads are typically used in power transmission [9]. Typical applications of square
threads are in lathe machines and jackscrews. However, they are difficult and costly to
17
manufacture. They are manufactured by using a single point cutting tool. Their load
capacity is also the lowest since the areas of the tooth at the crest and root are similar.
Figure 2. 13: Square Thread [9]
 Acme Thread:
The acme thread has a 290-thread angle. This modification of square threads was
developed in the mid-1800s. Acme threads have a higher load capacity than square threads
because the tooth has a wider base. Another advantage of this type is their low number of
threads per inch, which increases the lead. The wear of the threads can be compensated.
However, they are less efficient than square threads due to friction introduced by the thread
angle. [9]
Figure 2. 14: Acme Thread [9]
 Buttress Thread:
The buttress thread is designed to handle high axial loads and transmit power in one
direction; the direction depends on the orientation of the weight-bearing and trailing flanks.
The weight-bearing flank of a standard buttress thread makes a seventy slant while its
trailing flank makes a 450-angle slant. The tooth of the buttress thread has a wider base,
which gives the screw about twice the shear strength of the square thread. The efficiency
is almost equal to the square thread due to its low frictional losses. [9]
18
Figure 2. 15: Buttress Thread [9]
2.12. Electrical Components
a) Main Power Source:
The power source is the main energy supply for the system, so it is required to have stable
in voltage and current supply over time. Then we choose Power Supply 12V 20A.
Figure 2. 16: Power Source
b) Microcontroller:
At first time, we decided to use the Arduino board due to the common and popular in
making 3D printer, but we have already changed our mind that will be present later.
Arduino Mega 2560 is extremely popular, easy to find, easy to understand programming
language, hardware easy to connect.
The Arduino mega 2560 board is a microprocessor board designed to be built applications
that interact with each other or with a more conducive environment.
The circuit board is built on the Arduino mega 2560 8bit microprocessor platform.[10]
19
Figure 2. 17: Arduino Mega 2560 R3 [10]
The Arduino IDE software makes it simple to program and flash code onto the
microcontroller. can program in the C/C++ computer language. Overall, the language set
is straightforward and simple enough for even non-micro specialized control to understand.
Arduino IDE software is used to flash the code for the Arduino Mega 2560 board. The
software's user interface is simple and intuitive. It is convenient for the procedure because
the Arduino Mega library and source code are relatively vast.
c) LCD Screen
LCD 1602 is a liquid crystal display. his element resembles a dot matrix module. It is used
to display characters, numbers, and other symbols. It is made up of 5x7 or 5x11 dot matrix
positions, and each one can display a single character that is entered.
A dot pitch between two characters and a space between lines can be used by the LCD
1602 to distinguish characters and lines. The LCD's meaning number may display two
rows, each with 16 characters.
In this project , the LCD is also the screen to display the status of the system.
Figure 2. 18: LCD 1602 [11]
20
Specifications :
1. Operating Voltage is 4.7V to 5.3V.
2. Current consumption is 1mA without backlight.
3. Alphanumeric LCD display module, meaning can display alphabets
and numbers.
4. Consists of two rows and each row can print 16 characters.
5. Each character is built by a 5×8-pixel box.
6. Can work on both 8-bit and 4-bit mode.
7. It can also display any custom generated characters.
8. Available in Green and Blue Backlight.
Applications:
At present, LCDs are used frequently in CD/DVD players, digital watches, computers, etc.
It is also used in many electronic projects and devices to display messages. In screen
industries, LCDs have replaced the CRTs (Cathode Ray Tubes) because these displays use
more power as compared to LCD, heavier & larger.
In this project, we use LCD 16x02 for the purpose of displaying available space in the
parking lot, and also showing "Full Slot" when the parking lot has no space available.
d) Module RFID RC522
RFID RF522 module is a reader by using MFRC522 chip, which accepts the ID code from
the RFID card. It is usually accompanied by an RFID tag in a credit card format and an
RFID tag in a keychain format. The cards can have 1K or 4K memory divided into sectors
and blocks. [12]
The RFID reader module RC522 is also used to write RFID tags. To read the information
encoded on a tag, it is placed in close proximity to the Reader (does not need to be within
direct line-of-sight of the reader). A Reader generates an electromagnetic field which
causes electrons to move through the tag’s antenna and subsequently power the chip.
Applications :
1. Frequency range: 13,56 MHz
2. Interface: SPI/I2C/UART
21
3. Supply Voltage: 2,5V to 3,3V
4. Max. current: 13-26 mA
5. Min. current: 10 uA
6. Logic levels: 5V y 3V3
7. Reach: 5 cm
Figure 2. 19: RFID RC522 [12]
e) Proximity Sensor
When an object enters the field of a proximity sensor, which does not require touch, the
sensor recognizes the presence of the object, which is frequently referred to as the
"target". Depending on the type of proximity sensor, the sensor may detect a target via
sound, light, infrared radiation (IR), or electromagnetic fields. Phones, recycling
facilities, self-driving cars, anti-aircraft systems, and production lines all use proximity
sensors.
There are numerous varieties of proximity sensors, and they all detect targets
differently. The inductive proximity sensor and the capacitive proximity sensor are the
two types of proximity sensors that are most frequently utilized.
Figure 2. 20: Proximity Sensor
22
Advantages:
The thing to be detected won't be damaged or worn because it might be picked up even
without being touched.
The life-extension employs a semiconductor output since the non-contact output method is
used, which has no impact on the contact point's life (apart from the magnetic type).
In contrast to the optical detection method, it is suitable for use in environments like water
and oil and is unaffected by the stains, oil, and water of the detection item. Also included
are items with Teflon casings and great chemical resistance.
In contrast to touch sensors, it will be affected by the ambient temperature, nearby objects,
and sensors of the same type, such as inductive and electrostatic capacitance sensors. As a
result, considerations for mutual interference must be made while positioning the sensors.
Additionally, the inductive type must handle the impact of nearby metal, whilst the
electrostatic capacitance type must take into account the impact of nearby items.
23
CHAPTER 3: DESIGN AND IMPLEMENTATION
3.1. Block Diagram
3.1.1. Block Listing
: To provide the energy for all circuit.
: To transfer and receive the control signal.
: To scan and identify the user tag.
: To show the process and information.
: To provide motion of lifting mechanism of 2 axis
: To keep and drop the vehicle into the cell parking.
: To move the Z-axis of lifting system.
: To move the Y-axis of lifting system.
D : To control the airflow.
: To provide air for system.
: To detect car and movement of system.
Figure 3. 1: Block Listing
Power
Controller
RFID Scanner
Stepper Motor
Cylinder
LCD
Lead Screw
Pulley & Belt
Solenoid
Air Compressor
Infrared Sensor
24
3.1.2. Block Diagram
Figure 3. 2: Block Diagram
3.2. Operational Description
First, the car will be put in the standby-position waiting for transportation , scan the RFID
card by RFID scanner , on each RFID card will have a number from 1 to 9 including ID
that help us easy to identify which puzzle that the car will be parked in. The controller
receive the signal from scanner , show on the LCD that position the car will be parked.
Then , the controller send signal to stepper motor Y-axis and Z-axis to move to the right
position. The air compressor will prove air flow to the solenoid and cylinder which is an
arm of the lifting system to lift the car out of the standby-position then take it into the right
puzzle position.
The operation of parking car out process is the same , switch on the other mode , using the
RFID card to scan, the system will take the car from the puzzle frame to the standby-
position.
3.3. Mechanical Design
3.3.1. Calculation and equipment choosing
a) Frame Design
At first, we decided to choose shaped aluminum to build the frame because most of the
DIY (do it yourself) 3D printer in the world is made by this material and aluminum is the
most quantified metal used in building, after steel.
25
Then we researched about the advantages and disadvantages of this material to decide that
we should choose shaped aluminum to build the frame or not.
-Advantages:
+ The first advantage of aluminum is its recyclable characteristic. Aluminum is a
sustainable material. A key feature is that it can be recycled while still retaining its initial
properties. This is a huge advantage and is not only cost-effective but also beneficial for
the environment.
+ The second advantage of aluminum is Corrosion Resistant. Aluminum develops a thin
layer of aluminum oxide on its surface when exposed to air. This layer protects the
aluminum from corrosion when exposed.
+ The third advantage of aluminum is Versatile and Flexible. Due to the characteristics of
aluminum being durable, strong and light, it is an ideal material for the construction
industry.
-Disadvantages:
+ The first disadvantage of Aluminum is about its price. If you are working on a large
building project, you will want to save money where possible. Unfortunately, aluminum is
more expensive when compared to some alternative materials, such as steel.
Additionally, because it cannot take the same stress as steel, more of it is required to ensure
the structure’s strength is viable, meaning utilizing it in some designs may cost more
overall.
+The second disadvantage of Aluminum is about the overall strength. While being praised
for its malleable qualities, this particular property of aluminum can also act as a
disadvantage. It can be more easily dented and scratched in comparison to steel. Steel is
strong and less likely to warp, deform or bend under any weight, force or heat.
Nevertheless, the strength of steel’s trade-off is that steel is much heavier and denser than
aluminum.
From the advantages and disadvantages mentioned above, our group decide to choose
aluminum, especially V-slot Shaped Aluminum, to build the frame of the machine because
we need a light frame, but it must be strong enough to load the weight of the table.
Moreover, the price of Shaped Aluminum is suitable for us to handle. There are several
types of shaped aluminums with varied sizes, but we believe that 20x20 is a suitable size
for our machine.
26
Figure 3. 3: Several types of Shaped Aluminums
Figure 3. 4: V-Slot Shaped Aluminum
Figure 3. 5: Shaped Aluminum 20x20
We also use the aluminum for other parts of the frame such as Screws, Machining Details,
Sliding T-nut, etc.
27
b) Motion in Z-Axis (Base on prototype)
The weight of lifting arm is not too heavy then we decided to choose Lead Screws instead
of Ball Screws in our design. Lead Screws are used for low-cost requirements, positioning
applications.
 Z-Axis Lead Screw
For Z-Axis, our group use an old Z-Axis kit from an CNC machine. The lead of screw of
this Lead Screw is 8mm then we could calculate the step per millimeter.
Step with lead screw:
B = 360/(α*λ*m) = 360/ {1.8*8*(1/16)} = 400 (steps/mm)
m =1/16 (maximum micro step)
α = 1.80 (the step angle of the motor)
λ = 8mm (diameter of lead screw)
To calculate how many step of lead screw to move each millimeter , we can solve
Linear distance = 400 / λ = 400 / 8 = 50 (steps/mm)
c) Motion in Y – Axis (Base on prototype)
To control the lifting mechanism in the Y – axis , we need to use the pulley and belt
Belt Step = (360 degrees / α) * (λ / (m * R))
With the all variable shown :
α (step angle of the motor) = 1.80 degre
λ (belt pitch) = 2 mm
m (micro step) = 1/16
R (teeth of pulley) = 20 teeth
Belt Step = (360 / 1.80) * (2 / (0.0625 * 20)) ≈ 400 (steps/mm)
Then to calculate the linear distance the belt and gear can travel based on the steps
Linear distance = 400 / (λ * R) = 400 / (2*20) = 10 (steps/mm)
d) Determine and calculate according to the actual need
28
In reality, instead of using a stepper motor to drive the shafts and lifting mechanism with
a lead screw base on the prototype we built , we decide to use the electric motor and drive
sprocket for lifting mechanism.
For example , we have some basic parameter of the structure.
- Pallet weight: G = 200kg = 2000N
- Weight of lifting object: Q = 2500 kg = 25000 N ( SUV Q2)
Height: H = 8 meters
First , we have to choose the electric motor and speed reduction machine.
Figure 3. 6: Electric motor and speed reduction machine
The capacity calculated when lifting the object is equal to the tonnage determined by
the formula:
N =
.
. .
=
.
. . .
= 8.5 Kw
With η = ηp . η0 = 0.96 . 0.92 = 0.88 structural performance
ηp chain transmission efficiency = 0.96
η0 transmission and coupling performance = 0.92
* Select chain type
The tooth chain should only be used when the transmission speed is over 10m/s and there
is a requirement to work quietly and without noise.
For the chain transmission of the lift, choose a roller chain of the TOCT10947-64 range.
Then we will calculate the maximum chain tension.
Chain max tension :
S max = (Q+G) / 4 = 27000 / 4 = 6750 (N)
With:
29
Q :Lift load
Chain breaking force: Sd >= Smax * nx
In there:
Sd: Chain breaking force, N;
Smax: Chain maximum tension (N)
Nx = 8:10 - safety factor of chain
Sd >= 6750 * 8 = 54000 (N)
* Select the size of drive sprocket
Teeth of drive sprocket : Z =19
Ring diameter :
= 230 mm
Determine the forces acting on the shaft:
Ring force: P = Pchain = Smax = 6750 (N)
Pr = P* tga = 6750 * tg20 = 2456.79 (N)
With:
Pr: centripetal force
*Pallet parameter
Puzzle Parking is a simple designed automatic parking system that works in place of
conventional concrete parking floors.
Each parking floor has a maximum height of 2100mm for SUVs and 1600 for SEDAN.
With this technology, the driver only needs to park the car on the pallet on the 1st floor of
each parking block, then the system will automatically move the car pallet to the parking
position with the lifting and sliding mechanism.
System capacity:
Total parking spaces in the whole parking lot: (depending on each project).
30
Vehicle dimensions excluding parking mirror on automatic parking system: (depending on
the project)
SEDAN vehicle: 5000x1850x1550mm
SUV: 5000x1850x1900mm
Vehicle load: over 2,000kg
Notice of vacant seats at each block (distinguishable from SEDAN - SUV)
Each block will be equipped with additional space indicator lights, and the driver actively
approaches the vacant parking block.
3.3.2. Solidworks drawing
a) Front-side
Figure 3. 7: The front-side view of prototype
b) Left-side
Figure 3. 8: The left-side view of prototype
31
c) The back-side
Figure 3. 9: The back-side view of machine
d) The fully-workout machine
Figure 3. 10: The complete prototype
32
3.3.3. Some Of Detailed Drawings
Figure 3. 11: Total Assembly Prototype
Figure 3. 12: 3D Assembly Prototype
33
Figure 3. 13: Parking Car Frame
Figure 3. 14: Assembly Table
34
Figure 3. 15: Lifting Pad
Figure 3. 16: Part cb4
35
Figure 3. 17: Part cb5
Figure 3. 18: Plate Z
36
Figure 3. 19: Nut Screw
Figure 3. 20: Fixed Frame
37
3.4. Electrical Design
In this section, we would like to show you our electrical design such as wiring diagrams
and schematics.
3.4.1. Components
Number Name Quantity
1 Stepper Motor 42 & 57 2
2 LCD 1
3 RFID Scanner 1
4 Arduino Mega 2560 R3 1
5 Driver DM542 2
6 Proximity Sensor 12
Table 3. 1: Electrical Components
We need 2 stepper motors. 1 stepper motors for Y and for Z-Axis.1 RFID to scan ID for
each cell of parking area. Proximity sensors will be used to recognize the position of
vehicles in the parking area, and to know the position of the lift system which is the most
important part of process.
3.4.2. Block Diagram
Figure 3. 21: Electrical block diagram
38
Figure 3. 22: Electric circuit
3.4.3 Control Design
Figure 3. 23: Operational flowchart
39
Description : When the power is in , the default state of system is parking in mode , then
using the RFID card to scan , if the system recognize the UID , it will automatically park
the car into the right position , if the system can not recognize the UID , we have to repeat
the scanning process or reset the system. To use the parking out mode , we have to switch
by the button and do exactly the step of the parking in mode.
Figure 3. 24: Control flow chart
Description : When the system is online , first we have to set/define the mode, then it will
initialize on LCD and start the UART function. When the sensor IN detected , it is required
RFID data to get information , so we need to use the RFID card for scanning. If the card is
accepted , it will send to controller for log in verification, then the controller will analyze
if this ID valid or not. If this ID is valid , it will display status to LCD and accept to park
the vehicle, otherwise we have to repeat the procedure from the RFID scanning.
This process is also the same with the parking out mode.
40
CHAPTER 4: EXPERIMENT AND RESULT
4.1. Experiment
We make the experiments with the automatic car parking system in 2 cases
First , we will look around the prototype and see each part to know how to control the
system correctly.
In this project , we decide to use a small car model to present the real car in reality , with
this ratio , we are able to witness how the system work more clearly and easy to operate
without any problem.
The weight of each car model is only about 50 gram but it has different type of car , for
example truck , SUV and so on.
Figure 4. 1: Small car model
Because our system can operate in 2 mode so , we need to separate in 2 case to explain
how it work.
Case 1: To park the car into the cell of frame.
First, put the car into standby- position , using random RFID card for scanning , because
we build the frame of parking car with 9 cells so we will have 9 RFID cards. Each RFID
card will contain an unique ID to identify.
If losing the RFID card , we are not able to scan and have to wait for a new RFID card due
to the unique ID of it.
41
Figure 4. 2: RFID card
Figure 4. 3: Control board
Take out any RFID card from number 1 to 9 , we put it in the RFID scanner for the system
to read the ID , also help to identify the cell which the car will be park in.
The status will be shown on the LCD , it will give the information if there is a car in the
stand-by position or not. If there is a car in the standby position, the system will receive
the signal detected by the infrared sensor and give feedback to the controller (CPU).
When the RFID card is recognized, the lifting mechanism starts to move to the standby
position to pick up the car. The stepper motor of Y-axis will start to move first from the
initial state , then then by using the lead screw mechanism, the car is able to transport and
put in the right parking position without no issue.
42
Figure 4. 4: Car in standby position
After finishing the process, the lifting mechanism will automatically return to the standby
position, waiting for the new instruction.
In this case, if we try to park the another car at the same position with the first car , the
notification on the LCD will be displayed “ Can not park “.
Figure 4. 5: Infrared sensor to detect car
The infrared sensor on each cell will detect the presence of the car and send signal to the
controller.
43
Figure 4. 6: Successfully Parking
Case 2 : Take out the car
As we know that to take the car out , we have to use the RFID card that qualified with the
same number on it , in this case the car is in the cell number 4.
First, we have to change to the parking out mode by switching the button on the control
and electrical board.
If we do not do this step, it is not possible to take the car out of the parking frame.
Figure 4. 7: Parking out mode
44
In this case, we put a car into the standby position to see if the program can recognized
or not.
Figure 4. 8: Testing with the blocking standby position
No doubt, the program can easily find that there is another car inside the standby position
with the helping of algorithm and proximity sensor.
It show us a warning message in the LCD that showed “These is a car in the standby-
position”.
After removing the blocking car out of the standby- position , the system can work again
and it able to transport the car down fast and precisely without any problems.
Figure 4. 9 : Sucessfully Parking Out
45
Not only to transfer the car in or out , the system are able to identify of many cases and
show on the LCD for the user or driver to know the status of parking frame , even for the
supervisor to control easily.
These are : Announcement of car and no car
Case 1 : Parking in
No car in stand-by position and no car in cell : Show on LCD ( There is no car need to be
parked)
A car in stand-by position and a car in cell : Show on LCD (There is a car in cell , can not
park in)
No car in stand-by position and a car in cell : Show on LCD ( There is a car in cell)
Case 2 : Parking out
A car in stand-by position and a car in cell : Show on LCD ( There is a car in stand-by
position , can not park out)
A car in stand-by position and no car in cell : Show on LCD ( There is no car in cell –
There is a car in standby-position.
No car in stand-by position and no car in cell : Show on LCD ( There is no car in cell)
4.2. Result
1. Accuracy of positioning: The experiment show that how precisely the system can
identify the position of the vehicle within the parking space. High accuracy combines
with the smooth movement and no lag.
2. Time of parking: The measurement of the time taken by the system , the expected result
is efficient and timely parking about 30 seconds for each car , reduce the overall time
required compared to manual parking.
3. Safety: By using RFID card , the result show that it is really safe for the users , not only
to reduce the collision compared to the traditional parking , but also help to protect this
expensive property from stealing , broking and so on.
4. User experience: The user experience of the automatic parking system should also be
taken into account, including any additional features or comforts provided, ease of use,
clear instructions or feedback. The experiment's participants' feedback can be used to
gauge how user-friendly the system is.
4.3. Overall
By conducting this experiment, we are able to gain a lot knowledge and experiences , also
we can assess the performance , efficiency and reliability of the automatic car parking
46
system. This will help to improve our machine become better by applying more new
technology such as facial recognition, image processing to improve the security and so on.
Due to the limitation of technology , this prototype is quiet hard to apply in this real life ,
instead of using stepper motor and lead screw for lifting mechanism , we can replace by
electric motor , driver sprocket and chain to make it more efficient.
Finally, we can make sure that the demand of the automatic car parking system will be
increased in the near future.
In other hand , we feel that our project is only applying for the simulation so we will try to
regenerate the system to another way for making more realistic.
47
CHAPTER 5: CONCLUSION AND IMPROVEMENT
5.1. Conclusion.
Since there are currently a lot of people driving automobiles and motorbikes, the parking
system needs to be improved. In conventional parking lots, there is a lot of congestion for
a variety of reasons.
The best method to lower labor expenses, improve accuracy, and speed up vehicle entrance
and exit is a automatic parking system. Therefore, the parking lot design must be
appropriate for the parking lot size, working hours, parking capacity, and emergency
situations.
As a result, the system will function best if it is correctly installed in the appropriate
environment. If we have better hardware, we can optimize the speed of the lifting
mechanism, make it faster and more precise.
Establishing an effective method where auxiliary devices may communicate and share
data.
Discover and contrast with currently available smart parking lots in the market.
Integrating RFID and image processing into parking lot management will improve the
security and dependability of the lot.
5.2. Improvement
Looking ahead , we are able to see a great potential for improvement and expansion of the
automatic car parking system. Real time analysis and AI base algorithm to predict parking
demand and optimize parking space. Moreover , face recognition can be added for more
safety and security.
We can see that , this project will be a key to represent a significant achievement in the
world of smart transportation solution, it will improve the overall quality life for resident.
With this successful implementation, we are happy to contribute to the on going
development of smart cities and pave the way more sustainable and efficient future.
48
References
[1] “Vietnam Traffic – The Reality of Traffic in Vietnam & Essential Guides”
https://www.elprocus.com/stepper-motor-types-advantages-applications/(accessed
June.20, 2023)
[2] “ HCMC faces tremendous pressure on parking spaces “
https://vietnamnet.vn/en/hcmc-faces-tremendous-pressure-on-parking-spaces-
2077838.html (accessed June.20,2023)
[3] “ Finding parking a battle in major cities”
https://e.vnexpress.net/news/trend/finding-parking-a-battle-in-major-cities-4590923.html
(accessed June.20,2023)
[4] “What is Automated car parking system? “
https://www.mutrade.com/news/what-is-automated-car-parking-system-what-you-didnt-
know-about-the-tower ((accessed June.20,2023)
[5] “Different types of automated parking system “
https://constrofacilitator.com/different-types-of-automated-parking-system/(accessed
June.20,2023)
[6] “ Rotary parking system “
https://www.pinterest.ca/pin/524387950346838268/ (accessed June.20,2023)
[7] “What is a Stepper Motor: Types & Its Working”
https://www.elprocus.com/stepper-motor-types-advantages-applications/ (accessed
June.20,2023)
[8] “Stepper motor : working, construction, types and driving methods”
https://www.gadgetronicx.com/stepper-motor-working-construction-types-drive/
[9] “Lead Screw”
https://www.iqsdirectory.com/articles/ball-screw/lead-screws.html(accessed
June.25,2023)
[10] “Mega 2560 Rev3”
https://docs.arduino.cc/hardware/mega-2560 (accessed June.25,2023)
[11] “LCD 1602”
https://circuitdigest.com/article/16x2-lcd-display-module-pinout-datasheet(accessed
June.25,2023)
[12] “RC552 RFID Module”
https://components101.com/wireless/rc522-rfid-module (accessed June.25,2023)
49
Appendix
//Khai báo chân động cơ
//Trục z
#define Pz 10
#define Dz 11
//Trục y
#define Py 12
#define Dy 13
//khai bao cảm biến X-Y-Z
#define CBx 7
#define CBy 8
#define CBz 9
#define xilanh 18
//Khai báo cảm biến hồng ngoại
#define CB1 23
#define CB2 25
#define CB3 27
#define CB4 29
#define CB5 31
#define CB6 33
#define CB7 35
#define CB8 37
#define CB9 39
#define CB10 41
//Khai báo biến
int x=0, y=0, z=0;
String bien;
//khai báo RFID
#include<SPI.h>
#include<MFRC522.h>
50
#define RST_PIN 48
#define SS_PIN 53
MFRC522 mfrc522(SS_PIN,RST_PIN);
//khai báo lcd
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x27, 20, 4);
//Khai báo chế độ lấy- gửi xe
#define Lay 4
#define Gui 6
void setup() {
Serial.begin(9600);
lcd.init();
lcd.backlight();
Serial.begin(9600);
SPI.begin();
mfrc522.PCD_Init();
Serial.println("vui long quet the");
Serial.println();
pinMode(Lay,INPUT_PULLUP);
digitalWrite(Lay,0);
pinMode(Gui,INPUT_PULLUP);
digitalWrite(Gui,0);
pinMode(Py,OUTPUT);
pinMode(Dy,OUTPUT);
pinMode(Pz,OUTPUT);
51
pinMode(Dz,OUTPUT);
pinMode(CB1, INPUT_PULLUP);
pinMode(CB2, INPUT_PULLUP);
pinMode(CB3, INPUT_PULLUP);
pinMode(CB4, INPUT_PULLUP);
pinMode(CB5, INPUT_PULLUP);
pinMode(CB6, INPUT_PULLUP);
pinMode(CB7, INPUT_PULLUP);
pinMode(CB8, INPUT_PULLUP);
pinMode(CB9, INPUT_PULLUP);
pinMode(CB10, INPUT_PULLUP);
digitalWrite(CB10,1);
pinMode(CBx, INPUT);
digitalWrite(CBx,0);
pinMode(CBy, INPUT);
digitalWrite(CBy,1);
pinMode(CBz, INPUT);
digitalWrite(CBz,1);
pinMode(xilanh,OUTPUT);
digitalWrite(xilanh,1);
}
void loop() {
//Gọi chương trình về home
vehome();
//Chọn chế độ lấy hay gửi xe
if((digitalRead(Lay)==1)&&(digitalRead(Gui)==0)){
lcd.setCursor(3,1);
52
lcd.print("CHE DO LAY XE");
}
if((digitalRead(Lay)==0)&&(digitalRead(Gui)==1)){
lcd.setCursor(3,1);
lcd.print("CHE DO GUI XE");
}
if((x==1)&&(y==1)&&(z==1)){
lcd.setCursor(1,0);
lcd.print("VUI LONG QUET THE!");
}
////Chương trình quẹt thẻ RFID
if(!mfrc522.PICC_IsNewCardPresent())
{return;}
if(!mfrc522.PICC_ReadCardSerial())
{return;}
String content="";
for(byte i=0;i<mfrc522.uid.size;i++)
{content.concat(String(mfrc522.uid.uidByte[i]<0x10?" 0":" "));
content.concat(String(mfrc522.uid.uidByte[i],HEX));
}
content.toUpperCase();
bien = content.substring(1);
Serial.print("Ma: ");
Serial.println(bien);
// lcd.setCursor(0,2);
// lcd.print(bien);
delay(500);
//////Gọi chương trình gủi xe vào các ô////
////Gửi xe vào ô số 1
53
if((digitalRead(CB10)==0)&&(bien=="35 2D 9A
8A")&&(digitalRead(CB1)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 1");
Gui1();
}
////Gửi xe vào ô số 2
if((digitalRead(CB10)==0)&&(bien=="54 B0 99
8A")&&(digitalRead(CB2)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 2");
Gui2();
}
////Gửi xe vào ô số 3
if((digitalRead(CB10)==0)&&(bien=="5F 04 9A
8A")&&(digitalRead(CB3)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 3");
Gui3();
}
////Gửi xe vào ô số 4
if((digitalRead(CB10)==0)&&(bien=="F0 A7 99
8A")&&(digitalRead(CB4)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 4");
Gui4();
}
54
////Gửi xe vào ô số 5
if((digitalRead(CB10)==0)&&(bien=="71 1F 9A
8A")&&(digitalRead(CB5)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 5");
Gui5();
}
////Gửi xe vào ô số 6
if((digitalRead(CB10)==0)&&(bien=="EF D9 99
8A")&&(digitalRead(CB6)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 6");
Gui6();
}
////Gửi xe vào ô số 7
if((digitalRead(CB10)==0)&&(bien=="E3 DB 99
8A")&&(digitalRead(CB7)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 7");
Gui7();
}
////Gửi xe vào ô số 8
if((digitalRead(CB10)==0)&&(bien=="28 B4 99
8A")&&(digitalRead(CB8)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 8");
Gui8();
55
}
////Gửi xe vào ô số 9
if((digitalRead(CB10)==0)&&(bien=="D3 51 FC
AC")&&(digitalRead(CB9)==1)&&(digitalRead(Gui)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("GUI VAO O SO 9");
Gui9();
}
//////Gọi chương trình lấy xe ở các ô////
////Lấy xe ở ô số 1
if((digitalRead(CB10)==1)&&(bien=="35 2D 9A
8A")&&(digitalRead(CB1)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 1");
Lay1();
}
////Lấy xe ở ô số 2
if((digitalRead(CB10)==1)&&(bien=="54 B0 99
8A")&&(digitalRead(CB2)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 2");
Lay2();
}
////Lấy xe ở ô số 3
if((digitalRead(CB10)==1)&&(bien=="5F 04 9A
8A")&&(digitalRead(CB3)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
56
lcd.print("LAY XE O SO 3");
Lay3();
}
////Lấy xe ở ô số 4
if((digitalRead(CB10)==1)&&(bien=="F0 A7 99
8A")&&(digitalRead(CB4)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 4");
Lay4();
}
////Lấy xe ở ô số 5
if((digitalRead(CB10)==1)&&(bien=="71 1F 9A
8A")&&(digitalRead(CB5)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 5");
Lay5();
}
////Lấy xe ở ô số 6
if((digitalRead(CB10)==1)&&(bien=="EF D9 99
8A")&&(digitalRead(CB6)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 6");
Lay6();
}
////Lấy xe ở ô số 7
if((digitalRead(CB10)==1)&&(bien=="E3 DB 99
8A")&&(digitalRead(CB7)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
57
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 7");
Lay7();
}
////Lấy xe ở ô số 8
if((digitalRead(CB10)==1)&&(bien=="28 B4 99
8A")&&(digitalRead(CB8)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 8");
Lay8();
}
////Lấy xe ở ô số 9
if((digitalRead(CB10)==1)&&(bien=="D3 51 FC
AC")&&(digitalRead(CB9)==0)&&(digitalRead(Lay)==1)){
lcd.clear();
lcd.setCursor(3,0);
lcd.print("LAY XE O SO 9");
Lay9();
}
//////////////////////////Thông báo có hay không có xe/////////
////gửi
if (((bien=="35 2D 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB1)==1))||((bien=="54 B0 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB2)==1))||((bien=="5F 04 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB3)==1))||
((bien=="F0 A7 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB4)==1))||((bien=="71 1F 9A
58
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB5)==1))||((bien=="EF D9 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB6)==1))||((bien=="E3 DB 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB7)==1))||((bien=="28 B4 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB8)==1))||((bien=="D3 51 FC
AC")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB9)==1))){
lcd.setCursor(2,3);
lcd.print("KHONG CO XE GUI!");
delay(1000);
lcd.clear();
}
/////
if(((bien=="35 2D 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB1)==0))||
((bien=="54 B0 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB2)==0))||
((bien=="5F 04 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB3)==0))||
((bien=="F0 A7 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB4)==0))||
((bien=="71 1F 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB5)==0))||
((bien=="EF D9 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB6)==0))||
((bien=="E3 DB 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB7)==0))||
((bien=="28 B4 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB8)==0))||
((bien=="D3 51 FC
AC")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB9)==0)))
{
lcd.setCursor(1,3);
lcd.print("O GUI DANG CO XE!");
59
delay(1000);
lcd.clear();
}
if (((bien=="35 2D 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB1)==0))||((bien=="54 B0 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB2)==0))||((bien=="5F 04 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB3)==0))||
((bien=="F0 A7 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB4)==0))||((bien=="71 1F 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB5)==0))||((bien=="EF D9 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB6)==0))||((bien=="E3 DB 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB7)==0))||((bien=="28 B4 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB8)==0))||((bien=="D3 51 FC
AC")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)&
&(digitalRead(CB9)==0))){
lcd.setCursor(1,2);
lcd.print("O GUI DANG CO XE!");
lcd.setCursor(2,3);
lcd.print("KHONG CO XE GUI!");
delay(2000);
lcd.clear();
}
/////lấy
if(((bien=="35 2D 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB1)==0)&
&(digitalRead(CBy)==0))||((bien=="54 B0 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB2)==0)&
&(digitalRead(CBy)==0))||((bien=="5F 04 9A
60
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB3)==0)&
&(digitalRead(CBy)==0))||
((bien=="F0 A7 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB4)==0)&
&(digitalRead(CBy)==0))||((bien=="71 1F 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB5)==0)&
&(digitalRead(CBy)==0))||((bien=="EF D9 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB6)==0)&
&(digitalRead(CBy)==0))||((bien=="E3 DB 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB7)==0)&
&(digitalRead(CBy)==0))||((bien=="28 B4 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB8)==0)&
&(digitalRead(CBy)==0))||((bien=="D3 51 FC
AC")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB9)==0)
&&(digitalRead(CBy)==0))){
lcd.setCursor(2,3);
lcd.print("BAI DANG CO XE!");
delay(1000);
lcd.clear();
}
if(((bien=="35 2D 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB1)==1)&
&(digitalRead(CBy)==0))||((bien=="54 B0 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB2)==1)&
&(digitalRead(CBy)==0))||((bien=="5F 04 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB3)==1)&
&(digitalRead(CBy)==0))||
((bien=="F0 A7 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB4)==1)&
&(digitalRead(CBy)==0))||((bien=="71 1F 9A
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB5)==1)&
&(digitalRead(CBy)==0))||((bien=="EF D9 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB6)==1)&
&(digitalRead(CBy)==0))||((bien=="E3 DB 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB7)==1)&
&(digitalRead(CBy)==0))||((bien=="28 B4 99
8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB8)==1)&
&(digitalRead(CBy)==0))||((bien=="D3 51 FC
61
AC")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB9)==1)
&&(digitalRead(CBy)==0))){
lcd.setCursor(1,2);
lcd.print("O LAY KHONG CO XE!");
lcd.setCursor(2,3);
lcd.print("BAI DANG CO XE!");
delay(2000);
lcd.clear();
}
if(((bien=="35 2D 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB1)==1))||
((bien=="54 B0 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB2)==1))||
((bien=="5F 04 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB3)==1))||
((bien=="F0 A7 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB4)==1))||
((bien=="71 1F 9A
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB5)==1))||
((bien=="EF D9 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB6)==1))||
((bien=="E3 DB 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB7)==1))||
((bien=="28 B4 99
8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB8)==1))||
((bien=="D3 51 FC
AC")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB9)==1)))
{
lcd.setCursor(1,3);
lcd.print("O LAY KHONG CO XE!");
delay(1000);
lcd.clear();
}
}
//Chương Trình auto home
62
void vehome(){
//ve home x
while((digitalRead(CBx)==0)&&(x==0)){
digitalWrite(xilanh,0);
delay(500); }
if(digitalRead(CBx)==1){
digitalWrite(xilanh,1);
x=1;
Serial.print("x:");
Serial.println(x);
}
//ve home z
while((digitalRead(CBz)==1)&&(x==1)&&(z==0)){
digitalWrite(Dz,HIGH);
digitalWrite(Pz,HIGH);
delayMicroseconds(300);
digitalWrite(Pz,LOW);
delayMicroseconds(300);}
if(digitalRead(CBz)==LOW){
z=1;
Serial.print("z:");
Serial.println(z);
}
//ve home y
while((digitalRead(CBy)==1)&&(x==1)&&(z==1)&&(y==0)){
digitalWrite(Dy,LOW);
digitalWrite(Py,HIGH);
delayMicroseconds(800);
digitalWrite(Py,LOW);
delayMicroseconds(800);}
63
if(digitalRead(CBy)==0){
y=1;
Serial.print("y:");
Serial.println(y);
}
}
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////CHƯƠNG TRÌNH GỬI XE VÀO CÁC
Ô///////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////Chương trình lấy xe ở bãi
void Layxebai(){
//phuong x
digitalWrite(xilanh,0);
delay(1500);
//phuong z
for(int i=0;i<=600;i++){
digitalWrite(Dz,LOW);
digitalWrite(Pz,HIGH);
delayMicroseconds(300);
digitalWrite(Pz,LOW);
delayMicroseconds(300);}
//phuong x1
digitalWrite(xilanh,1);
delay(3500);
}
64
//chương trình hạ xe vào ô
void Haxeo(){
//phương x đâm vô
digitalWrite(xilanh,0);
delay(1500);
//phuong z hạ xuống
for(int i=0;i<=600;i++){
digitalWrite(Dz,HIGH);
digitalWrite(Pz,HIGH);
delayMicroseconds(300);
digitalWrite(Pz,LOW);
delayMicroseconds(300);}
//phương x rút ra
digitalWrite(xilanh,1);
delay(3000);
}
////chương trình con gửi xe vào các ô
void Gui1(){
for(int i=0;i<=810;i++){
digitalWrite(Dy,HIGH);
digitalWrite(Py,HIGH);
delayMicroseconds(500);
digitalWrite(Py,LOW);
delayMicroseconds(500);
}
Layxebai();
//phương y
for(int i=0;i<=2380;i++){
digitalWrite(Dy,HIGH);
digitalWrite(Py,HIGH);
65
delayMicroseconds(500);
digitalWrite(Py,LOW);
delayMicroseconds(500);
}
Haxeo();
x=0;
y=0;
z=0;
}
void Gui2(){
for(int i=0;i<=810;i++){
digitalWrite(Dy,HIGH);
digitalWrite(Py,HIGH);
delayMicroseconds(500);
digitalWrite(Py,LOW);
delayMicroseconds(500);
}
Layxebai();
//phương y
for(int i=0;i<=1590;i++){
digitalWrite(Dy,HIGH);
digitalWrite(Py,HIGH);
delayMicroseconds(500);
digitalWrite(Py,LOW);
delayMicroseconds(500);
}
Haxeo();
x=0;
y=0;
S K L 0 0 2 1 5 4

More Related Content

Similar to Research, design and implementation of an automatic car parking system.pdf

Arthur Pantelides Dissertation Without Appendix
Arthur Pantelides  Dissertation Without AppendixArthur Pantelides  Dissertation Without Appendix
Arthur Pantelides Dissertation Without Appendix
Arthur Pantelides, PhD
 
CS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFT
CS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFTCS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFT
CS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFT
Josephat Julius
 
HORIZON-2020-handbook-for-ukrainian-researchers
HORIZON-2020-handbook-for-ukrainian-researchersHORIZON-2020-handbook-for-ukrainian-researchers
HORIZON-2020-handbook-for-ukrainian-researchers
Rostyslav LUKACH
 
PharmaLedger – Dissemination and In-Project Exploitation Plan
PharmaLedger – Dissemination and In-Project Exploitation PlanPharmaLedger – Dissemination and In-Project Exploitation Plan
PharmaLedger – Dissemination and In-Project Exploitation Plan
PharmaLedger
 
Digital Trade Integration in Central Asia
Digital Trade Integration in Central AsiaDigital Trade Integration in Central Asia
Digital Trade Integration in Central Asia
Sustainable Development Policy Institute
 

Similar to Research, design and implementation of an automatic car parking system.pdf (20)

Technical efficiency of Vietnam rice farms a stochastic frontier production a...
Technical efficiency of Vietnam rice farms a stochastic frontier production a...Technical efficiency of Vietnam rice farms a stochastic frontier production a...
Technical efficiency of Vietnam rice farms a stochastic frontier production a...
 
GViz - Project Report
GViz - Project ReportGViz - Project Report
GViz - Project Report
 
Luận Văn The Impact Of Social Network To Student’s Choice An Education Consul...
Luận Văn The Impact Of Social Network To Student’s Choice An Education Consul...Luận Văn The Impact Of Social Network To Student’s Choice An Education Consul...
Luận Văn The Impact Of Social Network To Student’s Choice An Education Consul...
 
Nanotechnology synthesis study_research
Nanotechnology synthesis study_researchNanotechnology synthesis study_research
Nanotechnology synthesis study_research
 
Final Dissertation
Final DissertationFinal Dissertation
Final Dissertation
 
Credit risk management and loan performance in microfinance....pdf
Credit risk management and loan performance in microfinance....pdfCredit risk management and loan performance in microfinance....pdf
Credit risk management and loan performance in microfinance....pdf
 
POLICY AND LEGAL FRAMEWORK ON DIGITAL ECONOMY IN SOME COUNTRIES AND LESSONS F...
POLICY AND LEGAL FRAMEWORK ON DIGITAL ECONOMY IN SOME COUNTRIES AND LESSONS F...POLICY AND LEGAL FRAMEWORK ON DIGITAL ECONOMY IN SOME COUNTRIES AND LESSONS F...
POLICY AND LEGAL FRAMEWORK ON DIGITAL ECONOMY IN SOME COUNTRIES AND LESSONS F...
 
Arthur Pantelides Dissertation Without Appendix
Arthur Pantelides  Dissertation Without AppendixArthur Pantelides  Dissertation Without Appendix
Arthur Pantelides Dissertation Without Appendix
 
“Bank Finance in Real Estate – Significance and Impact” (India)
“Bank Finance in Real Estate – Significance and  Impact” (India)“Bank Finance in Real Estate – Significance and  Impact” (India)
“Bank Finance in Real Estate – Significance and Impact” (India)
 
Supporting Collaboration and Harnessing of OER Within the Policy Framework of...
Supporting Collaboration and Harnessing of OER Within the Policy Framework of...Supporting Collaboration and Harnessing of OER Within the Policy Framework of...
Supporting Collaboration and Harnessing of OER Within the Policy Framework of...
 
Health OER Inter-Institutional Project Formative Evaluation of Health OER Des...
Health OER Inter-Institutional Project Formative Evaluation of Health OER Des...Health OER Inter-Institutional Project Formative Evaluation of Health OER Des...
Health OER Inter-Institutional Project Formative Evaluation of Health OER Des...
 
La01.005 a study on the impact of foreign direct investment on economic devel...
La01.005 a study on the impact of foreign direct investment on economic devel...La01.005 a study on the impact of foreign direct investment on economic devel...
La01.005 a study on the impact of foreign direct investment on economic devel...
 
CS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFT
CS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFTCS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFT
CS499_JULIUS_J_FINAL_YEAR_PROJETCT_L_DRAFT
 
HORIZON-2020-handbook-for-ukrainian-researchers
HORIZON-2020-handbook-for-ukrainian-researchersHORIZON-2020-handbook-for-ukrainian-researchers
HORIZON-2020-handbook-for-ukrainian-researchers
 
PharmaLedger – Dissemination and In-Project Exploitation Plan
PharmaLedger – Dissemination and In-Project Exploitation PlanPharmaLedger – Dissemination and In-Project Exploitation Plan
PharmaLedger – Dissemination and In-Project Exploitation Plan
 
457180206(1)
457180206(1)457180206(1)
457180206(1)
 
457180206(2)
457180206(2)457180206(2)
457180206(2)
 
457180206
457180206457180206
457180206
 
TS010.docx
TS010.docxTS010.docx
TS010.docx
 
Digital Trade Integration in Central Asia
Digital Trade Integration in Central AsiaDigital Trade Integration in Central Asia
Digital Trade Integration in Central Asia
 

More from Man_Ebook

More from Man_Ebook (20)

BÀI GIẢNG MÔN HỌC CƠ SỞ NGÔN NGỮ, Dùng cho hệ Cao đẳng chuyên nghiệp.pdf
BÀI GIẢNG MÔN HỌC CƠ SỞ NGÔN NGỮ, Dùng cho hệ Cao đẳng chuyên nghiệp.pdfBÀI GIẢNG MÔN HỌC CƠ SỞ NGÔN NGỮ, Dùng cho hệ Cao đẳng chuyên nghiệp.pdf
BÀI GIẢNG MÔN HỌC CƠ SỞ NGÔN NGỮ, Dùng cho hệ Cao đẳng chuyên nghiệp.pdf
 
TL Báo cáo Thực tập tại Nissan Đà Nẵng.doc
TL Báo cáo Thực tập tại Nissan Đà Nẵng.docTL Báo cáo Thực tập tại Nissan Đà Nẵng.doc
TL Báo cáo Thực tập tại Nissan Đà Nẵng.doc
 
Giáo trình thực vật học 2 - Trường ĐH Cần Thơ.pdf
Giáo trình thực vật học 2 - Trường ĐH Cần Thơ.pdfGiáo trình thực vật học 2 - Trường ĐH Cần Thơ.pdf
Giáo trình thực vật học 2 - Trường ĐH Cần Thơ.pdf
 
Giáo trình mô động vật - Trường ĐH Cần Thơ.pdf
Giáo trình mô động vật - Trường ĐH Cần Thơ.pdfGiáo trình mô động vật - Trường ĐH Cần Thơ.pdf
Giáo trình mô động vật - Trường ĐH Cần Thơ.pdf
 
Giáo trình ngôn ngữ hệ thống A - Trường ĐH Cần Thơ.pdf
Giáo trình ngôn ngữ hệ thống A - Trường ĐH Cần Thơ.pdfGiáo trình ngôn ngữ hệ thống A - Trường ĐH Cần Thơ.pdf
Giáo trình ngôn ngữ hệ thống A - Trường ĐH Cần Thơ.pdf
 
Giáo trình ngôn ngữ mô hình hóa UML - Trường ĐH Cần Thơ.pdf
Giáo trình ngôn ngữ mô hình hóa UML - Trường ĐH Cần Thơ.pdfGiáo trình ngôn ngữ mô hình hóa UML - Trường ĐH Cần Thơ.pdf
Giáo trình ngôn ngữ mô hình hóa UML - Trường ĐH Cần Thơ.pdf
 
Giáo trình nguyên lý máy học - Trường ĐH Cần Thơ.pdf
Giáo trình nguyên lý máy học - Trường ĐH Cần Thơ.pdfGiáo trình nguyên lý máy học - Trường ĐH Cần Thơ.pdf
Giáo trình nguyên lý máy học - Trường ĐH Cần Thơ.pdf
 
Giáo trình mô hình hóa quyết định - Trường ĐH Cần Thơ.pdf
Giáo trình mô hình hóa quyết định - Trường ĐH Cần Thơ.pdfGiáo trình mô hình hóa quyết định - Trường ĐH Cần Thơ.pdf
Giáo trình mô hình hóa quyết định - Trường ĐH Cần Thơ.pdf
 
Giáo trình Linux và phần mềm nguồn mở.pdf
Giáo trình Linux và phần mềm nguồn mở.pdfGiáo trình Linux và phần mềm nguồn mở.pdf
Giáo trình Linux và phần mềm nguồn mở.pdf
 
Giáo trình logic học đại cương - Trường ĐH Cần Thơ.pdf
Giáo trình logic học đại cương - Trường ĐH Cần Thơ.pdfGiáo trình logic học đại cương - Trường ĐH Cần Thơ.pdf
Giáo trình logic học đại cương - Trường ĐH Cần Thơ.pdf
 
Giáo trình lý thuyết điều khiển tự động.pdf
Giáo trình lý thuyết điều khiển tự động.pdfGiáo trình lý thuyết điều khiển tự động.pdf
Giáo trình lý thuyết điều khiển tự động.pdf
 
Giáo trình mạng máy tính - Trường ĐH Cần Thơ.pdf
Giáo trình mạng máy tính - Trường ĐH Cần Thơ.pdfGiáo trình mạng máy tính - Trường ĐH Cần Thơ.pdf
Giáo trình mạng máy tính - Trường ĐH Cần Thơ.pdf
 
Giáo trình lý thuyết xếp hàng và ứng dụng đánh giá hệ thống.pdf
Giáo trình lý thuyết xếp hàng và ứng dụng đánh giá hệ thống.pdfGiáo trình lý thuyết xếp hàng và ứng dụng đánh giá hệ thống.pdf
Giáo trình lý thuyết xếp hàng và ứng dụng đánh giá hệ thống.pdf
 
Giáo trình lập trình cho thiết bị di động.pdf
Giáo trình lập trình cho thiết bị di động.pdfGiáo trình lập trình cho thiết bị di động.pdf
Giáo trình lập trình cho thiết bị di động.pdf
 
Giáo trình lập trình web - Trường ĐH Cần Thơ.pdf
Giáo trình lập trình web  - Trường ĐH Cần Thơ.pdfGiáo trình lập trình web  - Trường ĐH Cần Thơ.pdf
Giáo trình lập trình web - Trường ĐH Cần Thơ.pdf
 
Giáo trình lập trình .Net - Trường ĐH Cần Thơ.pdf
Giáo trình lập trình .Net  - Trường ĐH Cần Thơ.pdfGiáo trình lập trình .Net  - Trường ĐH Cần Thơ.pdf
Giáo trình lập trình .Net - Trường ĐH Cần Thơ.pdf
 
Giáo trình lập trình song song - Trường ĐH Cần Thơ.pdf
Giáo trình lập trình song song  - Trường ĐH Cần Thơ.pdfGiáo trình lập trình song song  - Trường ĐH Cần Thơ.pdf
Giáo trình lập trình song song - Trường ĐH Cần Thơ.pdf
 
Giáo trình lập trình hướng đối tượng.pdf
Giáo trình lập trình hướng đối tượng.pdfGiáo trình lập trình hướng đối tượng.pdf
Giáo trình lập trình hướng đối tượng.pdf
 
Giáo trình lập trình hướng đối tượng Java.pdf
Giáo trình lập trình hướng đối tượng Java.pdfGiáo trình lập trình hướng đối tượng Java.pdf
Giáo trình lập trình hướng đối tượng Java.pdf
 
Giáo trình kỹ thuật phản ứng - Trường ĐH Cần Thơ.pdf
Giáo trình kỹ thuật phản ứng  - Trường ĐH Cần Thơ.pdfGiáo trình kỹ thuật phản ứng  - Trường ĐH Cần Thơ.pdf
Giáo trình kỹ thuật phản ứng - Trường ĐH Cần Thơ.pdf
 

Recently uploaded

Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...
Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...
Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...
EADTU
 
Orientation Canvas Course Presentation.pdf
Orientation Canvas Course Presentation.pdfOrientation Canvas Course Presentation.pdf
Orientation Canvas Course Presentation.pdf
Elizabeth Walsh
 
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonQUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
httgc7rh9c
 
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPSSpellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
AnaAcapella
 
SPLICE Working Group: Reusable Code Examples
SPLICE Working Group:Reusable Code ExamplesSPLICE Working Group:Reusable Code Examples
SPLICE Working Group: Reusable Code Examples
Peter Brusilovsky
 

Recently uploaded (20)

PANDITA RAMABAI- Indian political thought GENDER.pptx
PANDITA RAMABAI- Indian political thought GENDER.pptxPANDITA RAMABAI- Indian political thought GENDER.pptx
PANDITA RAMABAI- Indian political thought GENDER.pptx
 
How to Add New Custom Addons Path in Odoo 17
How to Add New Custom Addons Path in Odoo 17How to Add New Custom Addons Path in Odoo 17
How to Add New Custom Addons Path in Odoo 17
 
Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...
Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...
Transparency, Recognition and the role of eSealing - Ildiko Mazar and Koen No...
 
AIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.pptAIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.ppt
 
diagnosting testing bsc 2nd sem.pptx....
diagnosting testing bsc 2nd sem.pptx....diagnosting testing bsc 2nd sem.pptx....
diagnosting testing bsc 2nd sem.pptx....
 
Orientation Canvas Course Presentation.pdf
Orientation Canvas Course Presentation.pdfOrientation Canvas Course Presentation.pdf
Orientation Canvas Course Presentation.pdf
 
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
 
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonQUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
 
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024
 
Including Mental Health Support in Project Delivery, 14 May.pdf
Including Mental Health Support in Project Delivery, 14 May.pdfIncluding Mental Health Support in Project Delivery, 14 May.pdf
Including Mental Health Support in Project Delivery, 14 May.pdf
 
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPSSpellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
 
Michaelis Menten Equation and Estimation Of Vmax and Tmax.pptx
Michaelis Menten Equation and Estimation Of Vmax and Tmax.pptxMichaelis Menten Equation and Estimation Of Vmax and Tmax.pptx
Michaelis Menten Equation and Estimation Of Vmax and Tmax.pptx
 
SPLICE Working Group: Reusable Code Examples
SPLICE Working Group:Reusable Code ExamplesSPLICE Working Group:Reusable Code Examples
SPLICE Working Group: Reusable Code Examples
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
When Quality Assurance Meets Innovation in Higher Education - Report launch w...
When Quality Assurance Meets Innovation in Higher Education - Report launch w...When Quality Assurance Meets Innovation in Higher Education - Report launch w...
When Quality Assurance Meets Innovation in Higher Education - Report launch w...
 
Play hard learn harder: The Serious Business of Play
Play hard learn harder:  The Serious Business of PlayPlay hard learn harder:  The Serious Business of Play
Play hard learn harder: The Serious Business of Play
 
How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17
 
Simple, Complex, and Compound Sentences Exercises.pdf
Simple, Complex, and Compound Sentences Exercises.pdfSimple, Complex, and Compound Sentences Exercises.pdf
Simple, Complex, and Compound Sentences Exercises.pdf
 

Research, design and implementation of an automatic car parking system.pdf

  • 1. MINISTRY OF EDUCATION AND TRAINING HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY AND EDUCATION FACULTY FOR HIGH QUALITY TRAINING GRADUATION THESIS ELECTRONICS AND TELECOMMUNICATION ENGINEERING TECHNOLOGY RESEARCH, DESIGN AND IMPLEMENTATION OF AN AUTOMATIC CAR PARKING SYSTEM TRAN NHAT HUY TRAN DUY KHANH SKL 0 1 1 1 5 8 Ho Chi Minh City, August, 2023 LECTURER: Ph.D. TRAN VI DO STUDENT: VO HUY HOANG
  • 2. HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY AND EDUCATION FACULTY FOR HIGH QUALITY TRAINING GRADUATION PROJECT RESEARCH, DESIGN AND IMPLEMENTATION OF AN AUTOMATIC CAR PARKING SYSTEM VO HUY HOANG Student ID : 18146020 TRAN NHAT HUY Student ID : 18146024 TRAN DUY KHANH Student ID : 18146033 Major: MECHATRONICS ENGINEERING Advisor: Dr. Tran Vi Do Ho Chi Minh City, 7th of August 2023
  • 3. Disclaimer The contents of this report reflect the views of the authors, who are solely responsible for the facts and the accuracy of the material and information presented here. This report is not a standard, specification or regulation.
  • 4. Acknowledgements We are over helmed in all humbleness and gratefulness to acknowledge our depth to all those who have helped us to put these ideas, well above the level of simplicity and into something concrete. I would like to express my special thanks of gratitude to my teacher Tran Vi Do as well as our principal who gave me the excellent opportunity to do this wonderful project on this interesting topic, which also helped us in doing a lot of research and we came to know about so many new things. We are thankful to them. Any attempt at any level cannot be satisfactorily completed without the support and guidance of our teacher and friends. We would like to thank my wonderful friends who helped us a lot in gathering different information, collecting data and guiding us from time to time in making this project, despite of their busy schedules, they gave me different ideas in making this project unique.
  • 5. Table of Contents ABSTRACT..................................................................................................................................................1 CHAPTER 1: INTRODUCTION .................................................................................................................2 1.1. Motivation of the research ...........................................................................................................2 1.2. The scientific and practical significance of the topic ....................................................................2 1.3. Objective of research ....................................................................................................................2 1.4. Target and research area ..............................................................................................................2 1.5. Methodological basic ....................................................................................................................2 1.6. Benefit of project ..........................................................................................................................2 CHAPTER 2: LITERATURE REVIEW ......................................................................................................3 2.1. The introduction of automatic car parking systems .....................................................................3 2.2. Overview of traffic station in Vietnam..........................................................................................3 2.2.1. Demand for parking lot in Vietnam recently ................................................................................5 2.2.3. Misidentification of automatic parking lot ...................................................................................6 2.3. General process.............................................................................................................................7 2.4. Some of car parking systems.........................................................................................................8 2.4.1. Tower Parking System...................................................................................................................8 2.4.2. Silo Parking System.......................................................................................................................9 2.4.3. Rotary Parking System ..................................................................................................................9 2.5. Comparison .................................................................................................................................10 2.5.1. Automatic Car Parking System....................................................................................................10 2.5.2. Traditional Spontaneous Parking................................................................................................11 2.6. Install Process..............................................................................................................................12 2.9. Stepper Motor.............................................................................................................................14 2.9.1. Construction and Working Principle...........................................................................................14 2.9.2. Types of Stepper Motor..............................................................................................................15 2.10. Belt Transmission........................................................................................................................16 2.11. Lead Screw ..................................................................................................................................16 2.12. Electrical Components ................................................................................................................18 CHAPTER 3: DESIGN AND IMPLEMENTATION............................................................................23 3.1. Block Diagram..............................................................................................................................23 3.1.1. Block Listing ................................................................................................................................23 3.1.2. Block Diagram .............................................................................................................................24 3.2. Operational Description..............................................................................................................24 3.3. Mechanical Design ......................................................................................................................24 3.3.1. Calculation and equipment choosing ..........................................................................................24 3.3.2. Solidworks drawing......................................................................................................................30
  • 6. 3.3.3. Some Of Detailed Drawings ................................................................................................32 3.4. Electrical Design..................................................................................................................37 3.4.1. Components........................................................................................................................37 3.4.2. Block Diagram......................................................................................................................37 3.4.3 Control Design.....................................................................................................................38 CHAPTER 4: EXPERIMENT AND RESULT ......................................................................................40 4.1. Experiment..........................................................................................................................40 4.2. Result..................................................................................................................................45 4.3. Overall.................................................................................................................................45 CHAPTER 5: CONCLUSION AND IMPROVEMENT.......................................................................47 5.1. Conclusion..........................................................................................................................47 5.2. Improvement ......................................................................................................................47 References..................................................................................................................................................48 Appendix....................................................................................................................................................49
  • 7. List of Figures Figure of Chapter 2 Figure 2. 1: Traffic congestion in metropolises on peak hours [1]................................................................4 Figure 2. 2: The vacant lands become temporary parking, affecting urban beauty [2]................................5 Figure 2. 3: Car parked on the pavement [3]................................................................................................6 Figure 2. 4: GeneralProcessDiagram ...............................................................................................................7 Figure 2. 5: Tower Parking System [4]...........................................................................................................8 Figure 2. 6: Silo Parking System [5].............................................................................................................9 Figure 2. 7: Rotary Parking System [6].......................................................................................................10 Figure 2. 8: Automatic Car Parking System Principle..................................................................................10 Figure 2. 9: Traditional Spontaneous Parking .............................................................................................11 Figure 2. 10: Install Process Diagram ..........................................................................................................12 Figure 2. 11: Stepper Motor [7] ..................................................................................................................14 Figure 2. 12: Stepper Motor Construction [8].............................................................................................15 Figure 2. 13: Square Thread [9]...................................................................................................................17 Figure 2. 14: Acme Thread [9].....................................................................................................................17 Figure 2. 15: Buttress Thread [9].................................................................................................................18 Figure 2. 16: Power Source .........................................................................................................................18 Figure 2. 17: Arduino Mega 2560 R3 [10] ...................................................................................................19 Figure 2. 18: LCD 1602 [11].........................................................................................................................19 Figure 2. 19: RFID RC522 [12]......................................................................................................................21 Figure 2. 20: Proximity Sensor ....................................................................................................................21 Figure of Chapter 3 Figure 3. 2: Block Listing .............................................................................................................................23 Figure 3. 3: Block Diagram...........................................................................................................................24 Figure 3. 4: Several types of Shaped Aluminums........................................................................................26 Figure 3. 5: V-Slot Shaped Aluminum..........................................................................................................26 Figure 3. 6: Shaped Aluminum 20x20 .........................................................................................................26 Figure 3. 7: Electric motor and speed reduction machine..........................................................................28 Figure 3. 8: The front-side view of prototype .............................................................................................30 Figure 3. 9: The left-side view of prototype................................................................................................30 Figure 3. 10: The back-side view of machine ..............................................................................................31 Figure 3. 11: The complete prototype ........................................................................................................31
  • 8. Figure 3. 12: Total Assembly Prototype ......................................................................................................32 Figure 3. 13: 3D Assembly Prototype..........................................................................................................32 Figure 3. 14: Parking Car Frame ..................................................................................................................33 Figure 3. 15: Assembly Table.......................................................................................................................33 Figure 3. 16: Lifting Pad...............................................................................................................................34 Figure 3. 17: Part cb4 ..................................................................................................................................34 Figure 3. 18: Part cb5 ..................................................................................................................................35 Figure 3. 19: Plate Z.....................................................................................................................................35 Figure 3. 20: Nut Screw ..............................................................................................................................36 Figure 3. 21: Fixed Frame...........................................................................................................................36 Figure 3. 22: Electrical block diagram .........................................................................................................37 Figure 3. 23: Electric circuit.........................................................................................................................38 Figure 3. 24: Operational flowchart............................................................................................................38 Figure 3. 25: Control flow chart ..................................................................................................................39 Figure of Chapter 4 Figure 4. 1: Small car model......................................................................................................................40 Figure 4. 2: RFID card .................................................................................................................................41 Figure 4. 3: Control board ..........................................................................................................................41 Figure 4. 4: Car in standby position.............................................................................................................42 Figure 4. 5: Infrared sensor to detect car.....................................................................................................42 Figure 4. 6: Successfully Parking .................................................................................................................43 Figure 4. 7: Parking out mode.....................................................................................................................43 Figure 4. 8: Testing with the blocking standby position.............................................................................44 Figure 4. 9 : Sucessfully Parking Out .........................................................................................................44 LIST OF TABLES Table 3. 1: Electrical Components...............................................................................................................37
  • 9. 1 ABSTRACT The growing number of vehicles in metropolitan areas has resulted in an increase in the demand for parking places. Traditional parking systems are becoming obsolete, inefficient, and time-consuming. Automatic car parking systems have developed as a viable answer to this problem. This abstract presents an overview of autonomous car parking systems, including their essential components and advantages. To automate the parking procedure, automatic car parking systems employ advanced technology such as sensors, cameras, and computer algorithms. These technologies do not require human interaction, allowing for more efficient utilization of available parking space. Vehicles are steered and positioned inside the parking lot using a combination of sensor data and clever algorithms, ensuring that the available space is used optimally. Finally, the system is almost complete when it is possible to identify and analyze the number of license plates, count the remaining space up to 90% Keywords: Automatic car parking systems, human interaction, combination of sensor data, clever algorithms , license plates.
  • 10. 2 CHAPTER 1: INTRODUCTION 1.1. Motivation of the research In recent years, there has been a growing interest in the development and implementation of automatic car parking systems. These systems utilize advanced technologies and algorithms to efficiently park vehicles without human intervention. The motivation behind the research and development of automatic car parking systems stems from several key factors, including the increasing global urbanization, limited parking space availability, environmental concerns, and the potential for improved efficiency and convenience. 1.2. The scientific and practical significance of the topic - Design the Automatic Car Parking System with the best product to serve the customer’s demand. - Improve more about the quality of product, structure of machine than the other type of traditional way. 1.3. Objective of research The major is to research about the problem of current car parking system, thereby offering many various solution. One of the best solution that our team find out that is to build an fully automatic car parking system which make it more convenient for people to park their cars without worrying about safety, security, saving time and easy to operate. 1.4. Target and research area - Research about the technology of an Automatic Car Parking System. - Design and assemble structure of machine. - Calculate the transmission structure design. - Research the electrical and control design. 1.5. Methodological basic Investigate and analysis the advantages and disadvantages of the Automatic Car Parking System to have several improvements in the future. 1.6. Benefit of project Overall, automatic automobile parking systems offer a variety of advantages, including greater parking capacity, time and cost savings, convenience, safety, environmental sustainability, and integration with smart city projects. These benefits make them an appealing solution for addressing parking issues in highly populated locations.
  • 11. 3 CHAPTER 2: LITERATURE REVIEW 2.1. The introduction of automatic car parking systems In recent years, cities around the world have encountered several issues when it comes to properly and successfully parking vehicles. Population development, along with insufficient parking spots, has resulted in increased congestion, traffic difficulties, and driver discontent. Advanced technologies have been developed to address these difficulties, paving the path for the adoption of automatic car parking systems. Automatic automobile parking systems are cutting-edge technologies that maximize parking space use and ease the parking process. These technologies are intended to reduce the time and effort required for vehicles to locate parking spaces while increasing parking facility capacity overall. Automatic automobile parking systems provide a seamless and convenient experience for both drivers and parking attendants by integrating numerous components such as sensors, cameras, computer algorithms, and robotic mechanics. The technology that powers automatic parking systems is based on a network of sensors strategically placed throughout the parking complex. These sensors continuously monitor parking space availability and communicate real-time data to a central control system. The control system analyzes the data and finds the best parking place for an arriving vehicle using clever algorithms. Once a parking space is given, the system directs the driver via clear signage or even autonomous driving mechanisms, offering a hassle-free parking experience. Furthermore, automated parking systems can be linked to modern payment mechanisms and smartphone apps. This allows for smooth payment processing and allows vehicles to secure parking places ahead of time, giving them convenience and peace of mind. These systems can also help parking operators manage their facilities more efficiently, analyze parking patterns, and generate important insights for future planning and improvement. Finally, the emergence of automatic car parking systems constitutes a huge improvement in parking technology. These systems transform the way vehicles are parked by utilizing cutting-edge technologies to optimize space use, improve security, and simplify the parking procedure. These technologies, with their potential to automate parking activities, present a viable solution to the issues that urban regions have in managing parking spaces efficiently. As technology advances, we may anticipate even more developments in autonomous automobile parking systems, resulting in even more fluid and intelligent parking experiences for drivers globally. 2.2. Overview of traffic station in Vietnam
  • 12. 4 The large population of metropolises means that people's transportation needs increase, which directly increases the number of individual vehicles. City managers should address traffic flow issues to reduce peak-hour traffic congestion by constructing additional infrastructure such as highways, undergrounds, expanding additional routes to meet vehicle density, and developing many parking lots to meet resident demand. For example, in certain large cities in our country today, such as Ho Chi Minh City, obtaining a parking lot in the city center is quite difficult, because daily car traffic in the city is always far more than the number of built-in parking lots. Figure 2. 1: Traffic congestion in metropolises on peak hours [1] Furthermore, the city's lack of measures to develop static traffic has slowed the development of developing additional parking lots. Furthermore, initiatives to address the lack of parking lots have yet to be effective because investors have not recognized their potential. Currently, the state of parking lots in major cities is becoming an issue. As usual, our country is celebrating Tet. Meanwhile, there are many unofficial parking lots that exist to profit off people's car deposits but do not provide security, quality management, or make ticket rates prohibitively exorbitant, leaving many people disappointed. As a result, there is currently a high demand for smart and secure parking for the driver, help to reduce the problem of over traffic in the urban area.
  • 13. 5 Figure 2. 2: The vacant lands become temporary parking, affecting urban beauty [2] 2.2.1. Demand for parking lot in Vietnam recently Recognizing the truth of many flaws in parking in Ho Chi Minh City. Our group has developed an automatic parking lot system. As a result, the device is highly valued for its user safety while reducing time and personnel costs. According to Ho Chi Minh City Police statistics, the average in the city occurred 50-100% of motorbike losses, with hospitals, supermarkets, commercial areas, markets, and so on accounting for 30%. The primary reason is that the thief used a fraudulent ticket, the number plate, or the automobile holder misplaced the ticket. The parking system arose as a result of this. Our team decided to use this model as the theme for our research because of its security. We will show genuine facts to persuade investors, potential partners, or readers that your business will attract a large number of clients in a booming industry and can guarantee sales that outperform the competition. This is one of the best and most specific components of the company plan, which includes taking into account the present market size and market development patterns. Many of the following sections of the business plan, such as production, marketing, and the total capital required, will be predicated on the sales prediction given in this section. Here are the components that we wish to highlight in our product market analysis.
  • 14. 6 Figure 2. 3: Car parked on the pavement [3] 2.2.2. Current difficulties The traffic jam is usually a popular topic, and there are numerous channels that show this problem to the society such as radio, and television that post about it, as well as a channel that specializes in delivering information on traffic spots in the area. The city is full of the car flow on the streets is so large and complicated that the capacity of the current roadways is limited. However, due to the massive number of vehicles, the current parking points is not enough for the needs of customers. So the major reason are: 1. Car senders' attitudes sometimes become sensitive, as well as their professional levels. 2. The security of most parking park is not following the standard. 3. Customers spend a long time to go to a nearby parking lot and they do not know about the state of the parking park which they are heading to. 4. Customers find it uncomfortable to wait a long period for their turn during vehicle sending times. 2.2.3. Misidentification of automatic parking lot Many people argue that the Automatic parking lot technology does not provide sufficient assurance of safety. Specifically, in order to operate this system, it is evident that human resources must be decreased, leading people to believe that there is a shortage of
  • 15. 7 individuals who look after their property. Despite the reduction in human resources, we believe the Automatic Parking System still assures the ability to protect users' property. Smart technology allows gadgets to communicate with one another and provide data to a website, allowing the supervisor to control the parking lot from afar. Furthermore, using both real cards and license plates will save money. Another problem is that many businesses are still hesitant to replace traditional parking lots with smart parking lots because they believe that even if they cut labor, they will still incur significant costs in maintaining the Automatic parking lot. This is not incorrect, but if we look at our country's parking demands, we will see that. The Automatic parking lot system's potential. Indeed, the Automatic parking lot system will eliminate the majority of traditional car park difficulties while enhancing performance and being convenient and comfortable for customers every time they visit. Aim of project In this project, we want to build an Automatic parking lot system prototype with all of the necessary functionalities without spending too much money in order to demonstrate that a Automatic parking lot is a viable parking solution for cities. To beat the challenges that traditional parking lots have while also improving the consumer experience when using this service. Customers may thus follow the status of parking lots from anywhere in order to make informed judgments. 2.3. General process Figure 2. 4: General Process Diagram 1. Entrance: The entry point of the parking park. 2. Vehicle Detection: Sensors will detect the appearance of a vehicle.
  • 16. 8 3. Parking Space Selection: The system selects an appropriate parking space based on many factors. 4. Vehicle Guidance: The system provides instructions to the driver on how to navigate to the selected parking space. 5. Parking Space: The physical parking space where the vehicle will be parked. 6. Vehicle Position Control: The system controls the vehicle's movement and positioning within the parking space. 7. Parking Completion: Confirmation that the vehicle has been successfully parked. 8. Exit: The exit point of the parking facility. 2.4. Some of car parking systems 2.4.1. Tower Parking System An elevator that transfers vehicles to a parking area surrounding the elevator shaft makes up the tower parking system. The parking tower's additional storeys were added using this format. The central lift unit in the tower parking system can only move vertically and must park on both sides. The system's primary benefit is that it can be integrated into an existing structure without affecting the main structure's vibration or sound levels and uses much less space than a conventional parking lot. Figure 2. 5: Tower Parking System [4]
  • 17. 9 2.4.2. Silo Parking System The vehicle parking and retrieval is handled by a single central positioning mechanism on the cylinder-shaped silo systems. the outer perimeter of the center was filled with parked cars. A lift/rotation mechanism that completes vehicle positioning occupies the core and often only allows one vehicle to be driven at once. The silo's mechanics, on the other hand, permit simultaneous up/down and axial positioning, which can move cars swiftly. The silo parking system can be constructed above ground or underground and is best suited for locations with very poor soil conditions. The silo system can be utilized with one or more parking modules, but typically only one car can be parked or retrieved at a time. Figure 2. 6: Silo Parking System [5] 2.4.3. Rotary Parking System The rotary parking system was created specifically to fit more than two cars in the horizontal area. The building can fit six carriages in a place meant for two, and depending on user needs, it can be modified to fit bigger numbers. It can also be utilized successfully in several zones. restricted area in terms of size. Cars access the parking lot on the ground floor under this system. When an empty compartment reaches the ground floor, all the carriages are then turned clockwise. To unload an automobile, all the vehicles are turned
  • 18. 10 clockwise until the chosen vehicle is on the ground. In order for the next car to be loaded or for another vehicle to be unloaded, the driver now exits the system. Figure 2. 7: Rotary Parking System [6] 2.5. Comparison Both modern method (Automatic Car Parking System ) and traditional spontaneous parking have their competitive advantages. 2.5.1. Automatic Car Parking System Figure 2. 8: Automatic Car Parking System Principle Outstanding Feature
  • 19. 11 Automated Operation: Automated car parking systems automate the entire parking operation by utilizing advanced technology and machinery. Robotic systems typically park vehicles in specific zones, removing the need for human interaction. Faster and More Efficient: Automatic car parking systems can significantly reduce the time required for parking and retrieving vehicles. The process is streamlined and automated, resulting in quicker turnaround times and reduced congestion. Enhanced Safety: With automated parking systems, the risk of human error is significantly reduced. The robotic mechanisms are designed to park vehicles precisely and safely, minimizing the chances of collisions or damage to vehicles. 2.5.2. Traditional Spontaneous Parking Figure 2. 9: Traditional Spontaneous Parking Outstanding Features Traditional parking systems have been in use for a long time, and most people are familiar with how they work. Users understand how to obtain a ticket, locate a parking space, and pay at a central payment station or machine. When compared to more modern automated systems, implementing a traditional parking system can be quite inexpensive. It does not necessitate sophisticated technology or
  • 20. 12 substantial infrastructure, making it a cost-effective solution, particularly for smaller parking facilities or temporary parking arrangements. Traditional parking systems are versatile in terms of the types of vehicles they can accommodate Traditional parking systems are versatile in terms of the types of vehicles they can accommodate. They may be customized to handle a variety of vehicle sizes, including motorbikes, bicycles, and big vehicles, without requiring considerable modifications. Also, security is one of the major problem that affecting to the driver when they are not sure that their car will be in the perfect state while leaving for a period of time. 2.6. Install Process Figure 2. 10: Install Process Diagram First step: Research the customer’s demand Second step: Design the overall system architecture. Third step: Construct the frame of machine. Fourth step: Install various sensors, such as ultrasonic or infrared sensors, at appropriate locations to detect the presence of vehicles. Fifth step: Develop a control system to manage the overall operation of the parking system. Sixth step: Install mechanical components such as conveyors, lifts, and platforms for vehicle movement. Integrate motors, gears, and pulley systems to enable automated vehicle transportation within the parking system. Research driver’s demands System Design Assemble the frame Install various sensors Establish a communication network Install mechanical components Design an interface Ensure safety features are in place Testing and Commissioning Deployment and Maintenance
  • 21. 13 Seventh step: Design and develop a user-friendly interface for drivers to interact with the parking system , provide benefit solution to help the user or driver to interact more efficient and controllable. Eighth step: Implement security measures like surveillance cameras and access control systems (RFID technique) . Ensure safety features are in place, such as emergency stop buttons and obstacle detection mechanisms. Ninth step: Conduct extensive testing to verify the functionality and performance of the automatic car parking system. Tenth step: Establish a regular maintenance schedule to ensure proper functioning. 2.7. RFID Technique RFID stands for Radio Frequency Identification (radio frequency recognition). It is a remote radio recognition technique, allowing data on a chip to be read "do not expose" through the radio wave path at a distance from 50 cm to 10 meters, depending on the type of RFID label card. A magnetic card will be issued to service users. To identify and track radio waves, this sort of card comprises ICs with identity information about a product, animal, or person. The magnetic cards will be connected to the automobile providing information in the parking lot, which means your information will be better controlled. Magnetic cards, similar to ID cards for automobile owners and cars. This card's information is unique. The frequency range of each RFID card will be different. It acts as a signal reader/scanner. When a card passes through the electromagnetic area due to the antenna generated, the information on the card will be read and decoded. 2.8. UART Protocol UART (Universal Asynchronous Receiver-Transmitter) asynchronous serial data transmission, this is one of the most popular device-to-device communication protocols. UART communication is widely used in applications to communicate with modules such as: Bluetooth, Wifi, RFID card reader module with Raspberry Pi, Arduino or another microcontroller. This is also a common and popular communication standard in the industry. In UART communication, two UARTs communicate with each other directly. The communication A UART translates parallel data from a control device, such as a CPU, into
  • 22. 14 serial data, sends it serially to a receiving UART, and then converts the serial data back into parallel data for the receiving device. 2.9. Stepper Motor An electromechanical device known as a stepper motor transforms electrical power into mechanical power. Additionally, it is a synchronous, brushless electric motor that has a large number of steps per entire rotation. As long as the motor is carefully sized for the application, the position of the motor can be regulated precisely without the use of a feedback device. When an electrical pulse is applied, the stepper motor turns the motor shaft a specific amount using the theory of operation for magnets. 2.9.1. Construction and Working Principle  Construction: The construction of a stepper motor is fairly related to a DC motor. It includes a permanent magnet like Rotor which is in the middle & it will turn once force acts on it. This rotor is enclosed through a no. of the stator which is wound through a magnetic coil all over it. The stator is arranged near to rotor so that magnetic fields within the stators can control the movement of the rotor. [7] Figure 2. 11: Stepper Motor [7] The stepper motor can be controlled by energizing every stator one by one. Therefore, the stator will magnetize & works like an electromagnetic pole which uses repulsive energy on the rotor to move forward. The stator’s alternative magnetizing as well as demagnetizing will shift the rotor gradually &allows it to turn through great control.
  • 23. 15 Figure 2. 12: Stepper Motor Construction [8] 2.9.2. Types of Stepper Motor There are three main types of stepper motors, they are: + Permanent magnet stepper + Hybrid synchronous stepper + Variable reluctance stepper  Permanent Magnet Stepper Motor Permanent magnet motors use a permanent magnet (PM) in the rotor and operate on the attraction or repulsion between the rotor PM and the stator electromagnets. This motor includes permanent magnets in the construction of the motor. This kind of motor is also known as tin-can/can-stack motor. The main benefit of this stepper motor is less manufacturing cost. [7]  Variable Reluctance Stepper Motor Variable reluctance (VR) motors have a plain iron rotor and operate based on the principle that minimum reluctance occurs with minimum gap, hence the rotor points are attracted toward the stator magnet poles. The stepper motor like variable reluctance is the basic type of motor and it is used for the past many years. As the name suggests, the rotor’s angular position depends on the magnetic circuit’s reluctance that can be formed among the teeth of the stator as well as a rotor. [7]  Hybrid synchronous Stepper Motor
  • 24. 16 Hybrid stepper motors are named because they use a combination of permanent magnet (PM) and variable reluctance (VR) techniques to achieve maximum power in small package sizes. The most popular type of motor is the hybrid stepper motor because it gives a good performance as compared with a permanent magnet rotor in terms of speed, step resolution, and holding torque. But this type of stepper motor is expensive as compared with permanent magnet stepper motors. This motor combines the features of both the permanent magnet and variable reluctance stepper motors. These motors are used where less stepping angle is required like 1.5, 1.8 & 2.5 degrees. [7] 2.10. Belt Transmission  Advantages of belt transmission: +The key benefits of belt and pulley transmission systems include their affordability, lubrication-free operation, and silent operation. These are the reasons why they are utilized in household appliances. Slip can be helpful in some situations. + The driving belt may slip, for instance, if a machine like a pillar drill becomes stuck. This could shield the user from harm and safeguard the drive motor from deterioration.  Disadvantages of belt and pulley transmission: + The biggest drawback is that slips can happen. Therefore, they should only be utilized in situations where slip won't interfere with machine operation. 2.11. Lead Screw A mechanical linear actuator known as a lead screw transforms rotational motion into linear motion. Its functionality depends on the screw shaft and nut threads gliding past one another without using ball bearings. Because the screw shaft and the nut come in direct touch with one another and have a wide surface area, friction losses are larger. Lead screw threads have changed over time to reduce friction. Types of Lead Screw Threads  Square Thread: The square thread has its flanks at right angles to the axis of the screw. No radial or bursting pressure is acting on the nut since square threads have a 00-thread angle. Square threads have less resistance to motion and less friction. Square threads are typically used in power transmission [9]. Typical applications of square threads are in lathe machines and jackscrews. However, they are difficult and costly to
  • 25. 17 manufacture. They are manufactured by using a single point cutting tool. Their load capacity is also the lowest since the areas of the tooth at the crest and root are similar. Figure 2. 13: Square Thread [9]  Acme Thread: The acme thread has a 290-thread angle. This modification of square threads was developed in the mid-1800s. Acme threads have a higher load capacity than square threads because the tooth has a wider base. Another advantage of this type is their low number of threads per inch, which increases the lead. The wear of the threads can be compensated. However, they are less efficient than square threads due to friction introduced by the thread angle. [9] Figure 2. 14: Acme Thread [9]  Buttress Thread: The buttress thread is designed to handle high axial loads and transmit power in one direction; the direction depends on the orientation of the weight-bearing and trailing flanks. The weight-bearing flank of a standard buttress thread makes a seventy slant while its trailing flank makes a 450-angle slant. The tooth of the buttress thread has a wider base, which gives the screw about twice the shear strength of the square thread. The efficiency is almost equal to the square thread due to its low frictional losses. [9]
  • 26. 18 Figure 2. 15: Buttress Thread [9] 2.12. Electrical Components a) Main Power Source: The power source is the main energy supply for the system, so it is required to have stable in voltage and current supply over time. Then we choose Power Supply 12V 20A. Figure 2. 16: Power Source b) Microcontroller: At first time, we decided to use the Arduino board due to the common and popular in making 3D printer, but we have already changed our mind that will be present later. Arduino Mega 2560 is extremely popular, easy to find, easy to understand programming language, hardware easy to connect. The Arduino mega 2560 board is a microprocessor board designed to be built applications that interact with each other or with a more conducive environment. The circuit board is built on the Arduino mega 2560 8bit microprocessor platform.[10]
  • 27. 19 Figure 2. 17: Arduino Mega 2560 R3 [10] The Arduino IDE software makes it simple to program and flash code onto the microcontroller. can program in the C/C++ computer language. Overall, the language set is straightforward and simple enough for even non-micro specialized control to understand. Arduino IDE software is used to flash the code for the Arduino Mega 2560 board. The software's user interface is simple and intuitive. It is convenient for the procedure because the Arduino Mega library and source code are relatively vast. c) LCD Screen LCD 1602 is a liquid crystal display. his element resembles a dot matrix module. It is used to display characters, numbers, and other symbols. It is made up of 5x7 or 5x11 dot matrix positions, and each one can display a single character that is entered. A dot pitch between two characters and a space between lines can be used by the LCD 1602 to distinguish characters and lines. The LCD's meaning number may display two rows, each with 16 characters. In this project , the LCD is also the screen to display the status of the system. Figure 2. 18: LCD 1602 [11]
  • 28. 20 Specifications : 1. Operating Voltage is 4.7V to 5.3V. 2. Current consumption is 1mA without backlight. 3. Alphanumeric LCD display module, meaning can display alphabets and numbers. 4. Consists of two rows and each row can print 16 characters. 5. Each character is built by a 5×8-pixel box. 6. Can work on both 8-bit and 4-bit mode. 7. It can also display any custom generated characters. 8. Available in Green and Blue Backlight. Applications: At present, LCDs are used frequently in CD/DVD players, digital watches, computers, etc. It is also used in many electronic projects and devices to display messages. In screen industries, LCDs have replaced the CRTs (Cathode Ray Tubes) because these displays use more power as compared to LCD, heavier & larger. In this project, we use LCD 16x02 for the purpose of displaying available space in the parking lot, and also showing "Full Slot" when the parking lot has no space available. d) Module RFID RC522 RFID RF522 module is a reader by using MFRC522 chip, which accepts the ID code from the RFID card. It is usually accompanied by an RFID tag in a credit card format and an RFID tag in a keychain format. The cards can have 1K or 4K memory divided into sectors and blocks. [12] The RFID reader module RC522 is also used to write RFID tags. To read the information encoded on a tag, it is placed in close proximity to the Reader (does not need to be within direct line-of-sight of the reader). A Reader generates an electromagnetic field which causes electrons to move through the tag’s antenna and subsequently power the chip. Applications : 1. Frequency range: 13,56 MHz 2. Interface: SPI/I2C/UART
  • 29. 21 3. Supply Voltage: 2,5V to 3,3V 4. Max. current: 13-26 mA 5. Min. current: 10 uA 6. Logic levels: 5V y 3V3 7. Reach: 5 cm Figure 2. 19: RFID RC522 [12] e) Proximity Sensor When an object enters the field of a proximity sensor, which does not require touch, the sensor recognizes the presence of the object, which is frequently referred to as the "target". Depending on the type of proximity sensor, the sensor may detect a target via sound, light, infrared radiation (IR), or electromagnetic fields. Phones, recycling facilities, self-driving cars, anti-aircraft systems, and production lines all use proximity sensors. There are numerous varieties of proximity sensors, and they all detect targets differently. The inductive proximity sensor and the capacitive proximity sensor are the two types of proximity sensors that are most frequently utilized. Figure 2. 20: Proximity Sensor
  • 30. 22 Advantages: The thing to be detected won't be damaged or worn because it might be picked up even without being touched. The life-extension employs a semiconductor output since the non-contact output method is used, which has no impact on the contact point's life (apart from the magnetic type). In contrast to the optical detection method, it is suitable for use in environments like water and oil and is unaffected by the stains, oil, and water of the detection item. Also included are items with Teflon casings and great chemical resistance. In contrast to touch sensors, it will be affected by the ambient temperature, nearby objects, and sensors of the same type, such as inductive and electrostatic capacitance sensors. As a result, considerations for mutual interference must be made while positioning the sensors. Additionally, the inductive type must handle the impact of nearby metal, whilst the electrostatic capacitance type must take into account the impact of nearby items.
  • 31. 23 CHAPTER 3: DESIGN AND IMPLEMENTATION 3.1. Block Diagram 3.1.1. Block Listing : To provide the energy for all circuit. : To transfer and receive the control signal. : To scan and identify the user tag. : To show the process and information. : To provide motion of lifting mechanism of 2 axis : To keep and drop the vehicle into the cell parking. : To move the Z-axis of lifting system. : To move the Y-axis of lifting system. D : To control the airflow. : To provide air for system. : To detect car and movement of system. Figure 3. 1: Block Listing Power Controller RFID Scanner Stepper Motor Cylinder LCD Lead Screw Pulley & Belt Solenoid Air Compressor Infrared Sensor
  • 32. 24 3.1.2. Block Diagram Figure 3. 2: Block Diagram 3.2. Operational Description First, the car will be put in the standby-position waiting for transportation , scan the RFID card by RFID scanner , on each RFID card will have a number from 1 to 9 including ID that help us easy to identify which puzzle that the car will be parked in. The controller receive the signal from scanner , show on the LCD that position the car will be parked. Then , the controller send signal to stepper motor Y-axis and Z-axis to move to the right position. The air compressor will prove air flow to the solenoid and cylinder which is an arm of the lifting system to lift the car out of the standby-position then take it into the right puzzle position. The operation of parking car out process is the same , switch on the other mode , using the RFID card to scan, the system will take the car from the puzzle frame to the standby- position. 3.3. Mechanical Design 3.3.1. Calculation and equipment choosing a) Frame Design At first, we decided to choose shaped aluminum to build the frame because most of the DIY (do it yourself) 3D printer in the world is made by this material and aluminum is the most quantified metal used in building, after steel.
  • 33. 25 Then we researched about the advantages and disadvantages of this material to decide that we should choose shaped aluminum to build the frame or not. -Advantages: + The first advantage of aluminum is its recyclable characteristic. Aluminum is a sustainable material. A key feature is that it can be recycled while still retaining its initial properties. This is a huge advantage and is not only cost-effective but also beneficial for the environment. + The second advantage of aluminum is Corrosion Resistant. Aluminum develops a thin layer of aluminum oxide on its surface when exposed to air. This layer protects the aluminum from corrosion when exposed. + The third advantage of aluminum is Versatile and Flexible. Due to the characteristics of aluminum being durable, strong and light, it is an ideal material for the construction industry. -Disadvantages: + The first disadvantage of Aluminum is about its price. If you are working on a large building project, you will want to save money where possible. Unfortunately, aluminum is more expensive when compared to some alternative materials, such as steel. Additionally, because it cannot take the same stress as steel, more of it is required to ensure the structure’s strength is viable, meaning utilizing it in some designs may cost more overall. +The second disadvantage of Aluminum is about the overall strength. While being praised for its malleable qualities, this particular property of aluminum can also act as a disadvantage. It can be more easily dented and scratched in comparison to steel. Steel is strong and less likely to warp, deform or bend under any weight, force or heat. Nevertheless, the strength of steel’s trade-off is that steel is much heavier and denser than aluminum. From the advantages and disadvantages mentioned above, our group decide to choose aluminum, especially V-slot Shaped Aluminum, to build the frame of the machine because we need a light frame, but it must be strong enough to load the weight of the table. Moreover, the price of Shaped Aluminum is suitable for us to handle. There are several types of shaped aluminums with varied sizes, but we believe that 20x20 is a suitable size for our machine.
  • 34. 26 Figure 3. 3: Several types of Shaped Aluminums Figure 3. 4: V-Slot Shaped Aluminum Figure 3. 5: Shaped Aluminum 20x20 We also use the aluminum for other parts of the frame such as Screws, Machining Details, Sliding T-nut, etc.
  • 35. 27 b) Motion in Z-Axis (Base on prototype) The weight of lifting arm is not too heavy then we decided to choose Lead Screws instead of Ball Screws in our design. Lead Screws are used for low-cost requirements, positioning applications.  Z-Axis Lead Screw For Z-Axis, our group use an old Z-Axis kit from an CNC machine. The lead of screw of this Lead Screw is 8mm then we could calculate the step per millimeter. Step with lead screw: B = 360/(α*λ*m) = 360/ {1.8*8*(1/16)} = 400 (steps/mm) m =1/16 (maximum micro step) α = 1.80 (the step angle of the motor) λ = 8mm (diameter of lead screw) To calculate how many step of lead screw to move each millimeter , we can solve Linear distance = 400 / λ = 400 / 8 = 50 (steps/mm) c) Motion in Y – Axis (Base on prototype) To control the lifting mechanism in the Y – axis , we need to use the pulley and belt Belt Step = (360 degrees / α) * (λ / (m * R)) With the all variable shown : α (step angle of the motor) = 1.80 degre λ (belt pitch) = 2 mm m (micro step) = 1/16 R (teeth of pulley) = 20 teeth Belt Step = (360 / 1.80) * (2 / (0.0625 * 20)) ≈ 400 (steps/mm) Then to calculate the linear distance the belt and gear can travel based on the steps Linear distance = 400 / (λ * R) = 400 / (2*20) = 10 (steps/mm) d) Determine and calculate according to the actual need
  • 36. 28 In reality, instead of using a stepper motor to drive the shafts and lifting mechanism with a lead screw base on the prototype we built , we decide to use the electric motor and drive sprocket for lifting mechanism. For example , we have some basic parameter of the structure. - Pallet weight: G = 200kg = 2000N - Weight of lifting object: Q = 2500 kg = 25000 N ( SUV Q2) Height: H = 8 meters First , we have to choose the electric motor and speed reduction machine. Figure 3. 6: Electric motor and speed reduction machine The capacity calculated when lifting the object is equal to the tonnage determined by the formula: N = . . . = . . . . = 8.5 Kw With η = ηp . η0 = 0.96 . 0.92 = 0.88 structural performance ηp chain transmission efficiency = 0.96 η0 transmission and coupling performance = 0.92 * Select chain type The tooth chain should only be used when the transmission speed is over 10m/s and there is a requirement to work quietly and without noise. For the chain transmission of the lift, choose a roller chain of the TOCT10947-64 range. Then we will calculate the maximum chain tension. Chain max tension : S max = (Q+G) / 4 = 27000 / 4 = 6750 (N) With:
  • 37. 29 Q :Lift load Chain breaking force: Sd >= Smax * nx In there: Sd: Chain breaking force, N; Smax: Chain maximum tension (N) Nx = 8:10 - safety factor of chain Sd >= 6750 * 8 = 54000 (N) * Select the size of drive sprocket Teeth of drive sprocket : Z =19 Ring diameter : = 230 mm Determine the forces acting on the shaft: Ring force: P = Pchain = Smax = 6750 (N) Pr = P* tga = 6750 * tg20 = 2456.79 (N) With: Pr: centripetal force *Pallet parameter Puzzle Parking is a simple designed automatic parking system that works in place of conventional concrete parking floors. Each parking floor has a maximum height of 2100mm for SUVs and 1600 for SEDAN. With this technology, the driver only needs to park the car on the pallet on the 1st floor of each parking block, then the system will automatically move the car pallet to the parking position with the lifting and sliding mechanism. System capacity: Total parking spaces in the whole parking lot: (depending on each project).
  • 38. 30 Vehicle dimensions excluding parking mirror on automatic parking system: (depending on the project) SEDAN vehicle: 5000x1850x1550mm SUV: 5000x1850x1900mm Vehicle load: over 2,000kg Notice of vacant seats at each block (distinguishable from SEDAN - SUV) Each block will be equipped with additional space indicator lights, and the driver actively approaches the vacant parking block. 3.3.2. Solidworks drawing a) Front-side Figure 3. 7: The front-side view of prototype b) Left-side Figure 3. 8: The left-side view of prototype
  • 39. 31 c) The back-side Figure 3. 9: The back-side view of machine d) The fully-workout machine Figure 3. 10: The complete prototype
  • 40. 32 3.3.3. Some Of Detailed Drawings Figure 3. 11: Total Assembly Prototype Figure 3. 12: 3D Assembly Prototype
  • 41. 33 Figure 3. 13: Parking Car Frame Figure 3. 14: Assembly Table
  • 42. 34 Figure 3. 15: Lifting Pad Figure 3. 16: Part cb4
  • 43. 35 Figure 3. 17: Part cb5 Figure 3. 18: Plate Z
  • 44. 36 Figure 3. 19: Nut Screw Figure 3. 20: Fixed Frame
  • 45. 37 3.4. Electrical Design In this section, we would like to show you our electrical design such as wiring diagrams and schematics. 3.4.1. Components Number Name Quantity 1 Stepper Motor 42 & 57 2 2 LCD 1 3 RFID Scanner 1 4 Arduino Mega 2560 R3 1 5 Driver DM542 2 6 Proximity Sensor 12 Table 3. 1: Electrical Components We need 2 stepper motors. 1 stepper motors for Y and for Z-Axis.1 RFID to scan ID for each cell of parking area. Proximity sensors will be used to recognize the position of vehicles in the parking area, and to know the position of the lift system which is the most important part of process. 3.4.2. Block Diagram Figure 3. 21: Electrical block diagram
  • 46. 38 Figure 3. 22: Electric circuit 3.4.3 Control Design Figure 3. 23: Operational flowchart
  • 47. 39 Description : When the power is in , the default state of system is parking in mode , then using the RFID card to scan , if the system recognize the UID , it will automatically park the car into the right position , if the system can not recognize the UID , we have to repeat the scanning process or reset the system. To use the parking out mode , we have to switch by the button and do exactly the step of the parking in mode. Figure 3. 24: Control flow chart Description : When the system is online , first we have to set/define the mode, then it will initialize on LCD and start the UART function. When the sensor IN detected , it is required RFID data to get information , so we need to use the RFID card for scanning. If the card is accepted , it will send to controller for log in verification, then the controller will analyze if this ID valid or not. If this ID is valid , it will display status to LCD and accept to park the vehicle, otherwise we have to repeat the procedure from the RFID scanning. This process is also the same with the parking out mode.
  • 48. 40 CHAPTER 4: EXPERIMENT AND RESULT 4.1. Experiment We make the experiments with the automatic car parking system in 2 cases First , we will look around the prototype and see each part to know how to control the system correctly. In this project , we decide to use a small car model to present the real car in reality , with this ratio , we are able to witness how the system work more clearly and easy to operate without any problem. The weight of each car model is only about 50 gram but it has different type of car , for example truck , SUV and so on. Figure 4. 1: Small car model Because our system can operate in 2 mode so , we need to separate in 2 case to explain how it work. Case 1: To park the car into the cell of frame. First, put the car into standby- position , using random RFID card for scanning , because we build the frame of parking car with 9 cells so we will have 9 RFID cards. Each RFID card will contain an unique ID to identify. If losing the RFID card , we are not able to scan and have to wait for a new RFID card due to the unique ID of it.
  • 49. 41 Figure 4. 2: RFID card Figure 4. 3: Control board Take out any RFID card from number 1 to 9 , we put it in the RFID scanner for the system to read the ID , also help to identify the cell which the car will be park in. The status will be shown on the LCD , it will give the information if there is a car in the stand-by position or not. If there is a car in the standby position, the system will receive the signal detected by the infrared sensor and give feedback to the controller (CPU). When the RFID card is recognized, the lifting mechanism starts to move to the standby position to pick up the car. The stepper motor of Y-axis will start to move first from the initial state , then then by using the lead screw mechanism, the car is able to transport and put in the right parking position without no issue.
  • 50. 42 Figure 4. 4: Car in standby position After finishing the process, the lifting mechanism will automatically return to the standby position, waiting for the new instruction. In this case, if we try to park the another car at the same position with the first car , the notification on the LCD will be displayed “ Can not park “. Figure 4. 5: Infrared sensor to detect car The infrared sensor on each cell will detect the presence of the car and send signal to the controller.
  • 51. 43 Figure 4. 6: Successfully Parking Case 2 : Take out the car As we know that to take the car out , we have to use the RFID card that qualified with the same number on it , in this case the car is in the cell number 4. First, we have to change to the parking out mode by switching the button on the control and electrical board. If we do not do this step, it is not possible to take the car out of the parking frame. Figure 4. 7: Parking out mode
  • 52. 44 In this case, we put a car into the standby position to see if the program can recognized or not. Figure 4. 8: Testing with the blocking standby position No doubt, the program can easily find that there is another car inside the standby position with the helping of algorithm and proximity sensor. It show us a warning message in the LCD that showed “These is a car in the standby- position”. After removing the blocking car out of the standby- position , the system can work again and it able to transport the car down fast and precisely without any problems. Figure 4. 9 : Sucessfully Parking Out
  • 53. 45 Not only to transfer the car in or out , the system are able to identify of many cases and show on the LCD for the user or driver to know the status of parking frame , even for the supervisor to control easily. These are : Announcement of car and no car Case 1 : Parking in No car in stand-by position and no car in cell : Show on LCD ( There is no car need to be parked) A car in stand-by position and a car in cell : Show on LCD (There is a car in cell , can not park in) No car in stand-by position and a car in cell : Show on LCD ( There is a car in cell) Case 2 : Parking out A car in stand-by position and a car in cell : Show on LCD ( There is a car in stand-by position , can not park out) A car in stand-by position and no car in cell : Show on LCD ( There is no car in cell – There is a car in standby-position. No car in stand-by position and no car in cell : Show on LCD ( There is no car in cell) 4.2. Result 1. Accuracy of positioning: The experiment show that how precisely the system can identify the position of the vehicle within the parking space. High accuracy combines with the smooth movement and no lag. 2. Time of parking: The measurement of the time taken by the system , the expected result is efficient and timely parking about 30 seconds for each car , reduce the overall time required compared to manual parking. 3. Safety: By using RFID card , the result show that it is really safe for the users , not only to reduce the collision compared to the traditional parking , but also help to protect this expensive property from stealing , broking and so on. 4. User experience: The user experience of the automatic parking system should also be taken into account, including any additional features or comforts provided, ease of use, clear instructions or feedback. The experiment's participants' feedback can be used to gauge how user-friendly the system is. 4.3. Overall By conducting this experiment, we are able to gain a lot knowledge and experiences , also we can assess the performance , efficiency and reliability of the automatic car parking
  • 54. 46 system. This will help to improve our machine become better by applying more new technology such as facial recognition, image processing to improve the security and so on. Due to the limitation of technology , this prototype is quiet hard to apply in this real life , instead of using stepper motor and lead screw for lifting mechanism , we can replace by electric motor , driver sprocket and chain to make it more efficient. Finally, we can make sure that the demand of the automatic car parking system will be increased in the near future. In other hand , we feel that our project is only applying for the simulation so we will try to regenerate the system to another way for making more realistic.
  • 55. 47 CHAPTER 5: CONCLUSION AND IMPROVEMENT 5.1. Conclusion. Since there are currently a lot of people driving automobiles and motorbikes, the parking system needs to be improved. In conventional parking lots, there is a lot of congestion for a variety of reasons. The best method to lower labor expenses, improve accuracy, and speed up vehicle entrance and exit is a automatic parking system. Therefore, the parking lot design must be appropriate for the parking lot size, working hours, parking capacity, and emergency situations. As a result, the system will function best if it is correctly installed in the appropriate environment. If we have better hardware, we can optimize the speed of the lifting mechanism, make it faster and more precise. Establishing an effective method where auxiliary devices may communicate and share data. Discover and contrast with currently available smart parking lots in the market. Integrating RFID and image processing into parking lot management will improve the security and dependability of the lot. 5.2. Improvement Looking ahead , we are able to see a great potential for improvement and expansion of the automatic car parking system. Real time analysis and AI base algorithm to predict parking demand and optimize parking space. Moreover , face recognition can be added for more safety and security. We can see that , this project will be a key to represent a significant achievement in the world of smart transportation solution, it will improve the overall quality life for resident. With this successful implementation, we are happy to contribute to the on going development of smart cities and pave the way more sustainable and efficient future.
  • 56. 48 References [1] “Vietnam Traffic – The Reality of Traffic in Vietnam & Essential Guides” https://www.elprocus.com/stepper-motor-types-advantages-applications/(accessed June.20, 2023) [2] “ HCMC faces tremendous pressure on parking spaces “ https://vietnamnet.vn/en/hcmc-faces-tremendous-pressure-on-parking-spaces- 2077838.html (accessed June.20,2023) [3] “ Finding parking a battle in major cities” https://e.vnexpress.net/news/trend/finding-parking-a-battle-in-major-cities-4590923.html (accessed June.20,2023) [4] “What is Automated car parking system? “ https://www.mutrade.com/news/what-is-automated-car-parking-system-what-you-didnt- know-about-the-tower ((accessed June.20,2023) [5] “Different types of automated parking system “ https://constrofacilitator.com/different-types-of-automated-parking-system/(accessed June.20,2023) [6] “ Rotary parking system “ https://www.pinterest.ca/pin/524387950346838268/ (accessed June.20,2023) [7] “What is a Stepper Motor: Types & Its Working” https://www.elprocus.com/stepper-motor-types-advantages-applications/ (accessed June.20,2023) [8] “Stepper motor : working, construction, types and driving methods” https://www.gadgetronicx.com/stepper-motor-working-construction-types-drive/ [9] “Lead Screw” https://www.iqsdirectory.com/articles/ball-screw/lead-screws.html(accessed June.25,2023) [10] “Mega 2560 Rev3” https://docs.arduino.cc/hardware/mega-2560 (accessed June.25,2023) [11] “LCD 1602” https://circuitdigest.com/article/16x2-lcd-display-module-pinout-datasheet(accessed June.25,2023) [12] “RC552 RFID Module” https://components101.com/wireless/rc522-rfid-module (accessed June.25,2023)
  • 57. 49 Appendix //Khai báo chân động cơ //Trục z #define Pz 10 #define Dz 11 //Trục y #define Py 12 #define Dy 13 //khai bao cảm biến X-Y-Z #define CBx 7 #define CBy 8 #define CBz 9 #define xilanh 18 //Khai báo cảm biến hồng ngoại #define CB1 23 #define CB2 25 #define CB3 27 #define CB4 29 #define CB5 31 #define CB6 33 #define CB7 35 #define CB8 37 #define CB9 39 #define CB10 41 //Khai báo biến int x=0, y=0, z=0; String bien; //khai báo RFID #include<SPI.h> #include<MFRC522.h>
  • 58. 50 #define RST_PIN 48 #define SS_PIN 53 MFRC522 mfrc522(SS_PIN,RST_PIN); //khai báo lcd #include <Wire.h> #include <LiquidCrystal_I2C.h> LiquidCrystal_I2C lcd(0x27, 20, 4); //Khai báo chế độ lấy- gửi xe #define Lay 4 #define Gui 6 void setup() { Serial.begin(9600); lcd.init(); lcd.backlight(); Serial.begin(9600); SPI.begin(); mfrc522.PCD_Init(); Serial.println("vui long quet the"); Serial.println(); pinMode(Lay,INPUT_PULLUP); digitalWrite(Lay,0); pinMode(Gui,INPUT_PULLUP); digitalWrite(Gui,0); pinMode(Py,OUTPUT); pinMode(Dy,OUTPUT); pinMode(Pz,OUTPUT);
  • 59. 51 pinMode(Dz,OUTPUT); pinMode(CB1, INPUT_PULLUP); pinMode(CB2, INPUT_PULLUP); pinMode(CB3, INPUT_PULLUP); pinMode(CB4, INPUT_PULLUP); pinMode(CB5, INPUT_PULLUP); pinMode(CB6, INPUT_PULLUP); pinMode(CB7, INPUT_PULLUP); pinMode(CB8, INPUT_PULLUP); pinMode(CB9, INPUT_PULLUP); pinMode(CB10, INPUT_PULLUP); digitalWrite(CB10,1); pinMode(CBx, INPUT); digitalWrite(CBx,0); pinMode(CBy, INPUT); digitalWrite(CBy,1); pinMode(CBz, INPUT); digitalWrite(CBz,1); pinMode(xilanh,OUTPUT); digitalWrite(xilanh,1); } void loop() { //Gọi chương trình về home vehome(); //Chọn chế độ lấy hay gửi xe if((digitalRead(Lay)==1)&&(digitalRead(Gui)==0)){ lcd.setCursor(3,1);
  • 60. 52 lcd.print("CHE DO LAY XE"); } if((digitalRead(Lay)==0)&&(digitalRead(Gui)==1)){ lcd.setCursor(3,1); lcd.print("CHE DO GUI XE"); } if((x==1)&&(y==1)&&(z==1)){ lcd.setCursor(1,0); lcd.print("VUI LONG QUET THE!"); } ////Chương trình quẹt thẻ RFID if(!mfrc522.PICC_IsNewCardPresent()) {return;} if(!mfrc522.PICC_ReadCardSerial()) {return;} String content=""; for(byte i=0;i<mfrc522.uid.size;i++) {content.concat(String(mfrc522.uid.uidByte[i]<0x10?" 0":" ")); content.concat(String(mfrc522.uid.uidByte[i],HEX)); } content.toUpperCase(); bien = content.substring(1); Serial.print("Ma: "); Serial.println(bien); // lcd.setCursor(0,2); // lcd.print(bien); delay(500); //////Gọi chương trình gủi xe vào các ô//// ////Gửi xe vào ô số 1
  • 61. 53 if((digitalRead(CB10)==0)&&(bien=="35 2D 9A 8A")&&(digitalRead(CB1)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 1"); Gui1(); } ////Gửi xe vào ô số 2 if((digitalRead(CB10)==0)&&(bien=="54 B0 99 8A")&&(digitalRead(CB2)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 2"); Gui2(); } ////Gửi xe vào ô số 3 if((digitalRead(CB10)==0)&&(bien=="5F 04 9A 8A")&&(digitalRead(CB3)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 3"); Gui3(); } ////Gửi xe vào ô số 4 if((digitalRead(CB10)==0)&&(bien=="F0 A7 99 8A")&&(digitalRead(CB4)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 4"); Gui4(); }
  • 62. 54 ////Gửi xe vào ô số 5 if((digitalRead(CB10)==0)&&(bien=="71 1F 9A 8A")&&(digitalRead(CB5)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 5"); Gui5(); } ////Gửi xe vào ô số 6 if((digitalRead(CB10)==0)&&(bien=="EF D9 99 8A")&&(digitalRead(CB6)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 6"); Gui6(); } ////Gửi xe vào ô số 7 if((digitalRead(CB10)==0)&&(bien=="E3 DB 99 8A")&&(digitalRead(CB7)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 7"); Gui7(); } ////Gửi xe vào ô số 8 if((digitalRead(CB10)==0)&&(bien=="28 B4 99 8A")&&(digitalRead(CB8)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 8"); Gui8();
  • 63. 55 } ////Gửi xe vào ô số 9 if((digitalRead(CB10)==0)&&(bien=="D3 51 FC AC")&&(digitalRead(CB9)==1)&&(digitalRead(Gui)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("GUI VAO O SO 9"); Gui9(); } //////Gọi chương trình lấy xe ở các ô//// ////Lấy xe ở ô số 1 if((digitalRead(CB10)==1)&&(bien=="35 2D 9A 8A")&&(digitalRead(CB1)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 1"); Lay1(); } ////Lấy xe ở ô số 2 if((digitalRead(CB10)==1)&&(bien=="54 B0 99 8A")&&(digitalRead(CB2)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 2"); Lay2(); } ////Lấy xe ở ô số 3 if((digitalRead(CB10)==1)&&(bien=="5F 04 9A 8A")&&(digitalRead(CB3)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0);
  • 64. 56 lcd.print("LAY XE O SO 3"); Lay3(); } ////Lấy xe ở ô số 4 if((digitalRead(CB10)==1)&&(bien=="F0 A7 99 8A")&&(digitalRead(CB4)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 4"); Lay4(); } ////Lấy xe ở ô số 5 if((digitalRead(CB10)==1)&&(bien=="71 1F 9A 8A")&&(digitalRead(CB5)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 5"); Lay5(); } ////Lấy xe ở ô số 6 if((digitalRead(CB10)==1)&&(bien=="EF D9 99 8A")&&(digitalRead(CB6)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 6"); Lay6(); } ////Lấy xe ở ô số 7 if((digitalRead(CB10)==1)&&(bien=="E3 DB 99 8A")&&(digitalRead(CB7)==0)&&(digitalRead(Lay)==1)){ lcd.clear();
  • 65. 57 lcd.setCursor(3,0); lcd.print("LAY XE O SO 7"); Lay7(); } ////Lấy xe ở ô số 8 if((digitalRead(CB10)==1)&&(bien=="28 B4 99 8A")&&(digitalRead(CB8)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 8"); Lay8(); } ////Lấy xe ở ô số 9 if((digitalRead(CB10)==1)&&(bien=="D3 51 FC AC")&&(digitalRead(CB9)==0)&&(digitalRead(Lay)==1)){ lcd.clear(); lcd.setCursor(3,0); lcd.print("LAY XE O SO 9"); Lay9(); } //////////////////////////Thông báo có hay không có xe///////// ////gửi if (((bien=="35 2D 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB1)==1))||((bien=="54 B0 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB2)==1))||((bien=="5F 04 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB3)==1))|| ((bien=="F0 A7 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB4)==1))||((bien=="71 1F 9A
  • 66. 58 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB5)==1))||((bien=="EF D9 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB6)==1))||((bien=="E3 DB 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB7)==1))||((bien=="28 B4 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB8)==1))||((bien=="D3 51 FC AC")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB9)==1))){ lcd.setCursor(2,3); lcd.print("KHONG CO XE GUI!"); delay(1000); lcd.clear(); } ///// if(((bien=="35 2D 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB1)==0))|| ((bien=="54 B0 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB2)==0))|| ((bien=="5F 04 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB3)==0))|| ((bien=="F0 A7 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB4)==0))|| ((bien=="71 1F 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB5)==0))|| ((bien=="EF D9 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB6)==0))|| ((bien=="E3 DB 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB7)==0))|| ((bien=="28 B4 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB8)==0))|| ((bien=="D3 51 FC AC")&&(digitalRead(CB10)==0)&&(digitalRead(Gui)==1)&&(digitalRead(CB9)==0))) { lcd.setCursor(1,3); lcd.print("O GUI DANG CO XE!");
  • 67. 59 delay(1000); lcd.clear(); } if (((bien=="35 2D 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB1)==0))||((bien=="54 B0 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB2)==0))||((bien=="5F 04 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB3)==0))|| ((bien=="F0 A7 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB4)==0))||((bien=="71 1F 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB5)==0))||((bien=="EF D9 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB6)==0))||((bien=="E3 DB 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB7)==0))||((bien=="28 B4 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB8)==0))||((bien=="D3 51 FC AC")&&(digitalRead(CB10)==1)&&(digitalRead(Gui)==1)&&(digitalRead(CBy)==0)& &(digitalRead(CB9)==0))){ lcd.setCursor(1,2); lcd.print("O GUI DANG CO XE!"); lcd.setCursor(2,3); lcd.print("KHONG CO XE GUI!"); delay(2000); lcd.clear(); } /////lấy if(((bien=="35 2D 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB1)==0)& &(digitalRead(CBy)==0))||((bien=="54 B0 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB2)==0)& &(digitalRead(CBy)==0))||((bien=="5F 04 9A
  • 68. 60 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB3)==0)& &(digitalRead(CBy)==0))|| ((bien=="F0 A7 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB4)==0)& &(digitalRead(CBy)==0))||((bien=="71 1F 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB5)==0)& &(digitalRead(CBy)==0))||((bien=="EF D9 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB6)==0)& &(digitalRead(CBy)==0))||((bien=="E3 DB 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB7)==0)& &(digitalRead(CBy)==0))||((bien=="28 B4 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB8)==0)& &(digitalRead(CBy)==0))||((bien=="D3 51 FC AC")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB9)==0) &&(digitalRead(CBy)==0))){ lcd.setCursor(2,3); lcd.print("BAI DANG CO XE!"); delay(1000); lcd.clear(); } if(((bien=="35 2D 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB1)==1)& &(digitalRead(CBy)==0))||((bien=="54 B0 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB2)==1)& &(digitalRead(CBy)==0))||((bien=="5F 04 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB3)==1)& &(digitalRead(CBy)==0))|| ((bien=="F0 A7 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB4)==1)& &(digitalRead(CBy)==0))||((bien=="71 1F 9A 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB5)==1)& &(digitalRead(CBy)==0))||((bien=="EF D9 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB6)==1)& &(digitalRead(CBy)==0))||((bien=="E3 DB 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB7)==1)& &(digitalRead(CBy)==0))||((bien=="28 B4 99 8A")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB8)==1)& &(digitalRead(CBy)==0))||((bien=="D3 51 FC
  • 69. 61 AC")&&(digitalRead(CB10)==0)&&(digitalRead(Lay)==1)&&(digitalRead(CB9)==1) &&(digitalRead(CBy)==0))){ lcd.setCursor(1,2); lcd.print("O LAY KHONG CO XE!"); lcd.setCursor(2,3); lcd.print("BAI DANG CO XE!"); delay(2000); lcd.clear(); } if(((bien=="35 2D 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB1)==1))|| ((bien=="54 B0 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB2)==1))|| ((bien=="5F 04 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB3)==1))|| ((bien=="F0 A7 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB4)==1))|| ((bien=="71 1F 9A 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB5)==1))|| ((bien=="EF D9 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB6)==1))|| ((bien=="E3 DB 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB7)==1))|| ((bien=="28 B4 99 8A")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB8)==1))|| ((bien=="D3 51 FC AC")&&(digitalRead(CB10)==1)&&(digitalRead(Lay)==1)&&(digitalRead(CB9)==1))) { lcd.setCursor(1,3); lcd.print("O LAY KHONG CO XE!"); delay(1000); lcd.clear(); } } //Chương Trình auto home
  • 70. 62 void vehome(){ //ve home x while((digitalRead(CBx)==0)&&(x==0)){ digitalWrite(xilanh,0); delay(500); } if(digitalRead(CBx)==1){ digitalWrite(xilanh,1); x=1; Serial.print("x:"); Serial.println(x); } //ve home z while((digitalRead(CBz)==1)&&(x==1)&&(z==0)){ digitalWrite(Dz,HIGH); digitalWrite(Pz,HIGH); delayMicroseconds(300); digitalWrite(Pz,LOW); delayMicroseconds(300);} if(digitalRead(CBz)==LOW){ z=1; Serial.print("z:"); Serial.println(z); } //ve home y while((digitalRead(CBy)==1)&&(x==1)&&(z==1)&&(y==0)){ digitalWrite(Dy,LOW); digitalWrite(Py,HIGH); delayMicroseconds(800); digitalWrite(Py,LOW); delayMicroseconds(800);}
  • 71. 63 if(digitalRead(CBy)==0){ y=1; Serial.print("y:"); Serial.println(y); } } ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////CHƯƠNG TRÌNH GỬI XE VÀO CÁC Ô/////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////// /////Chương trình lấy xe ở bãi void Layxebai(){ //phuong x digitalWrite(xilanh,0); delay(1500); //phuong z for(int i=0;i<=600;i++){ digitalWrite(Dz,LOW); digitalWrite(Pz,HIGH); delayMicroseconds(300); digitalWrite(Pz,LOW); delayMicroseconds(300);} //phuong x1 digitalWrite(xilanh,1); delay(3500); }
  • 72. 64 //chương trình hạ xe vào ô void Haxeo(){ //phương x đâm vô digitalWrite(xilanh,0); delay(1500); //phuong z hạ xuống for(int i=0;i<=600;i++){ digitalWrite(Dz,HIGH); digitalWrite(Pz,HIGH); delayMicroseconds(300); digitalWrite(Pz,LOW); delayMicroseconds(300);} //phương x rút ra digitalWrite(xilanh,1); delay(3000); } ////chương trình con gửi xe vào các ô void Gui1(){ for(int i=0;i<=810;i++){ digitalWrite(Dy,HIGH); digitalWrite(Py,HIGH); delayMicroseconds(500); digitalWrite(Py,LOW); delayMicroseconds(500); } Layxebai(); //phương y for(int i=0;i<=2380;i++){ digitalWrite(Dy,HIGH); digitalWrite(Py,HIGH);
  • 74. S K L 0 0 2 1 5 4