Parking aid

11,678

Parking aid
Parking aid

This circuit is based around the PIC 16C84 (or PIC 16F84) microcontroller. This chip is a compact computer integrated into a single chip, which includes RAM memory, EEPROM, I/O ports, and a CPU. When purchased, this chip is unprogrammed and requires the user to compile source code and upload the resulting machine code using a PC and a small programmer connected to the parallel port. The circuit functions as a parking aid featuring two infrared sensors (or at least one) that continuously measure the distance between the rear of a vehicle and nearby obstacles, such as another car. Feedback is provided to the driver through sound from a speaker, with six distinct alert levels. The first level emits short low-frequency beeps with long pauses when an obstacle is more than approximately 1.4 meters away. The second level produces long low-frequency beeps when the distance is between 1 meter and 1.4 meters. The third, fourth, and fifth levels increase the frequency and shorten the beep duration as the vehicle approaches the obstacle at distances of less than 1 meter, 75 cm, and 50 cm, respectively. At distances closer than 25 cm, level six is triggered, producing rapid dual-tone sounds to indicate an imminent collision. When no obstacle is detected, a soft ticking sound is heard to signify that the processor is functioning correctly. Upon activation (ideally through a switch or in conjunction with the vehicle's reverse lights), a short dual-tone sound confirms that the device is operational. The circuit utilizes the Sharp IR distance sensor GP2D02, which operates on triangular measurement principles and is designed to measure distances between 10 cm and 80 cm; however, with effective interpretation of the digital output, a practical measurement range exceeding 140 cm can be achieved. If only one sensor is to be used, the line "#define TWO_SENSORS" in the source code should be replaced with "#define ONE_SENSOR" to prevent software issues due to the absence of a second sensor. The complete system comprises three units: two outdoor units (one containing the microprocessor, power supply, first sensor, and additional components, while the other contains the second sensor) and one indoor unit, which functions as an audio amplifier with a speaker and power supply. The outdoor unit at the rear of the vehicle connects to the indoor unit near the driver using only three wires; if two sensors are employed, four wires are necessary to connect the second sensor to the first. When two sensors are utilized, the software selects the highest value from the two for sound signal conversion, representing the shortest distance. The LCD output in the source code is intended for use with the 'LCD Experimental board using PIC16F84' and is not applicable to this circuit; instead, the output value from the sensor (or the highest output from the two sensors) would be displayed continuously on the LCD. It is important to ensure that the two (or one) outdoor units are fully waterproof. A plastic housing with a glass cover for the sensor is recommended. Optimal results are achieved when the sensors are mounted vertically, with the infrared light-emitting diode oriented upwards. It is advisable to use shielded cable between the two outdoor units, not exceeding 1.4 meters in length. Encasing the sensor in aluminum foil and grounding it has been found to enhance performance significantly. When the sensor is directed towards open air, it should provide a reading of 1. Without the foil, readings may fluctuate randomly between 1 and 40; thus, using the foil allows for earlier beeping activation at a lower value, improving the effective range.

The circuit utilizes a microcontroller as the central processing unit, which executes the programmed logic for distance measurement and sound signal generation. The infrared sensors detect reflected light from nearby obstacles, converting this information into a digital signal that the microcontroller processes. The microcontroller's firmware includes algorithms for interpreting the sensor data, determining the distance to the nearest obstacle, and adjusting the sound output accordingly.

The audio feedback system is designed to provide clear and distinct alerts to the driver, ensuring that the user is aware of their proximity to potential hazards. The use of varying frequencies and beep lengths serves to communicate different levels of urgency effectively. The design also incorporates safety features, such as the soft ticking sound when no obstacles are detected, which indicates that the system is operational and ready for use.

The choice of the Sharp IR distance sensor GP2D02 is critical for the functionality of the circuit, as it offers a reliable means of measuring distances within the specified range. The sensor's triangular measurement principle allows for accurate readings, and the additional signal processing enhances the effective range of the system.

In terms of construction, attention to waterproofing and proper sensor orientation is essential to ensure consistent performance in various environmental conditions. The integration of aluminum foil as a grounding shield is a noteworthy enhancement that mitigates interference and improves the accuracy of the readings. The overall design emphasizes simplicity in wiring and installation, making it accessible for users looking to implement a parking aid system in their vehicles.This circuit is based around the PIC 16C84 (or PIC 16F84) microcontroller. This chip is actually a small computer contained in a single chip, including RAM memory, EEPROM, I/O ports, CPU and so on. When you buy this chip, it comes empty with no program on it. You have to compile the source code and download the resulting machine code into it, usin g a PC and a small programmer attached to the parallel port of the PC and the chip. To get yourself familiar with this stuff, I suggest you first read this link: Getting started with microcontrollers. This circuit is a parking aid. Two infrared sensors (or at least one) are continuously sensing the distance between the back of your car and an obstacle (i.

e. the other car). Feedback to the driver is given via sound through a speaker. There are six levels: the first level (starting level) sounds short low frequency beeps and long pauses to indicate that there is an obstacle further than about 1m40. The second level sounds long low frequency beeps when you are between 1m and 1m40 of the obstacle. The third, fourth and fifth level will get you higher in frequency (and shorter beeps) when you are nearing the other vehicle at resp.

less than 1m, 75 cm and 50 cm. When you are closer than 25 cm, you are in level 6 where quick dual-tone sounds can be heared, indicating that you are about to crash. When there is no obstacle, no sound is heard except some soft ticking, indicating that the processor is running OK.

When the device is put on (preferably through a switch or operated together with the back driving lights) a short dual tone is heard to confirm that the device is up and running. The circuit makes use of the Sharp IR distance sensor GP2D02. This sensor is based on triangular measuring principles, and is designed to measures distances between 10 cm and 80 cm, but using some smart interpreting of the digital output value, we can get in practice a range of more than 140 cm.

If you want to use only one sensor, you should replace the line "#define TWO_SENSORS" with "#define ONE_SENSOR" in the source code. Otherwise the software would hang because it can`t find the second sensor. The complete device consists of three units: two outdoor units (one of which contains the microprocessor, power supply, first sensor and some other components, the other one contains only the second sensor) and one indoor unit, which is basically just an audio amplifier with speaker and power supply.

There are only three wires necessary to connect the outdoor unit at the back of the car to the indoor unit close to the driver. If you use two sensors, you need four wires from the second sensor to the first sensor. When using two sensors, the software will allways take the highest value of the two sensors for conversion to sound signals (this is the shortest distance).

The LCD output in the source code is only used if you run this software on the `LCD Experimental board using PIC16F84` shown elsewhere on this site, not for this circuit. In this case, the output value of the sensor (or the highest output value of the two sensors) will be shown constantly on the LCD display.

The two (or one) outdoor units should be build completely waterproof. I used a plastic housing with a hole, where I mounted a piece of glass to put the sensor behind. You get the best results when you mount the sensors vertically, with the IR light emitting diode upwards. It is advisable that you use shielded cable between the two outdoor units not longer than 1. 4 meter. I experienced that winding a peace of aluminium folio around the sensor and connecting this folio to ground, gave much better results.

When the sensor is pointing to open air, it should give a reading of 1. Without the folio, the reading will vary randomly between 1 and 40. So when using the folio, we can start beeping at a much lower value, giving a higher range. 🔗 External reference