Skip to main content

AN-1093 Collision Avoidance Controller

Contents

References

For related documents and software, please visit:

https://www.dialog-semiconductor.com/products/greenpak

Download our free GreenPAK Designer software [1] to open the .gp file [2] and use the GreenPAK development tools [3] to freeze the design into your own customized IC in a matter of minutes.

Dialog Semiconductor provides a complete library of application notes [4] featuring design examples as well as explanations of features and blocks within the Dialog IC.

  1. GreenPAK Designer Software, Software Download, and User Guide, Dialog Semiconductor
  2. AN-1093 Collision Avoidance Controller.gp, GreenPAK Design File, Dialog Semiconductor
  3. GreenPAK Development Tools, GreenPAK Development Tools Webpage, Dialog Semiconductor
  4. GreenPAK Application Notes, GreenPAK Application Notes Webpage, Dialog Semiconductor
  5. SLG46620 Datasheet, Dialog Semiconductor

Authors: Oleg Gorodechny and Serhiy Prykhodko

Introduction

We will demonstrate how to make a vehicle collision avoidance system using a single SLG46620V GreenPAK IC. This IC provides processing of the ultrasonic sensor and RC transmitter, and assists in control of the vehicle. The basic idea of how to implement this is shown in Fig. 1.

Figure 1. Basic implementation

The principle of operation is as follows: the higher the rate - the greater the distance at which the automatic brake will engage before an obstacle (only when the throttle is engaged). Schematic, and illustration of PCB are shown in Fig. 2, and Fig. 3.

Figure 2. Collision Avoidance Controller schematic example
Figure 3. Collision Avoidance Controller PCB illustration

Collision Avoidance Controller circuit design

As shown in Fig. 4 and 5 the system can be implemented using the following cell blocks: two INVs (INV0, INV1), seven 2-bit LUTs (LUT1, LUT2, LUT3, LUT4, LUT5, LUT6 and LUT7), thirteen 3-bit LUTs (LUT0, LUT1, LUT2, LUT3, LUT4, LUT5, LUT8, LUT9, LUT10, LUT11, LUT12, LUT13 and LUT15), one 4-bit LUT1, eleven DFFs (DFF/LATCH0, DFF/LATCH2, DFF/LATCH3, DFF/LATCH4, DFF/LATCH5, DFF/LATCH6, DFF/LATCH7, DFF/LATCH8, DFF/LATCH9, DFF/LATCH10 and DFF/LATCH11), DCMP0/PWM0, nine CNTs/DLYs (CNT0/DLY0, CNT1/DLY1, CNT2/DLY2/FSM0, CNT3/DLY3, CNT4/DLY4/FSM1, CNT5/DLY5, CNT6/DLY6, CNT8/DLY8 and CNT9/DLY9), two P DLYs (P DLY0, P DLY1), OSC and two Pipe Delays (Pipe Delay0, Pipe Delay1).

Figure 4. Collision Avoidance Controller circuit design (Matrix 0)
Figure 5. Collision Evasion Controller circuit design (Matrix 1)

Collision Avoidance Controller circuit analysis

The implementation of this project is shown on the block diagram (see Fig. 6). This project is based on the comparison of two values: THROTTLE_IN (position of throttle stick) and ECHO (distance to the obstacle). Comparison block is implemented using DCMP0/PWM0 and two FSMs blocks (CNT2/DLY2/FSM0 and CNT4/DLY4/FSM1). In both FSMs blocks, the default counter data value is 240. This value corresponds to the number of steps to detect the difference of the input signals. Their counter data goes down to 0 when the input signal is switched HIGH. Input signals previously are processed before the comparison because their frequencies are different (as shown in Fig. 7).

This function (input signal processing) is implemented on the combination of group blocks that do the following functions: clock divider (ECHO CLK and THROTTLE CLK), Ready state (ECHO ready system and THROTTLE ready system) and a block that stores the data for comparison (Comparison). For THROTTLE_IN signal, these are: CNT8/DLY8, CNT1/DLY1, CNT2/DLY2/FSM0, P DLY0, 3-bit LUT0, DFF0 and 2-bit LUT2 blocks. For the ECHO signal, these are: CNT3/DLY3, CNT4/DLY4/FSM1, LATCH10, LATCH11, 2-bit LUT4 3-bit LUT9, DFF6 and 2-bit LUT5 blocks. Then, both data are ready for comparison – output result of DCMP0/PWM0 is written into the Pipe Delay1. It is implemented using 3-bit LUT13 and 8, 2-bit LUT6, P DLY1 and INV1. If OUT0 Pipe Delay1 is LOW, it’s the STOP state (obstacle detected), see Fig. 8, Fig. 9 and Fig. 10.

If OUT0 Pipe Delay1 is HIGH, the device is in the normal state (motion of the car continues), see Fig. 11 and Fig. 12. RESET block is implemented using the combination of the following blocks: 2-bit LUTs 3 and 7, 3-bit LUTs 2, 3, 5, 10, 11, 12, 15 and DFFs 2, 4, 7 and 9. 4-bit LUT1 is a MUX to control the THROTTLE_IN and Internal STOP (combination of the blocks: CNT9/DLY9 and 2-bit LUT1). The function of the automatic STOP can be switched on/off with the remote control and it is implemented in the Function control block (CNT6/DLY6, LATCH5, 3-bit LUT4, DFF3 and MUX based on 4-bit LUT1).

Figure 6. Block Diagram

If the automatic STOP turns on, it indicates this via LEDs (front LEDs shine at full intensity and rear LEDs shine dimly). If internal STOP is activated - rear LEDs shine at the full intensity (this function is the same as stop signal in real car). Rear LEDs control is implemented using PWM & Control block (Pipe Delay0 and 3-bit LUT1). To get the result from the ultrasonic sensor, a 10us pulse has to be generated and fed into the input trigger, and repeated every 60ms. Such function is implemented using the Pulse generator block (CNT0/DLY0, INV0 and CNT5/DLY5).

Figure 7. Collision Avoidance Controller ECHO and THROTTLE_IN signals
Figure 8. Automatic STOP function operation
Figure 9. The car has stopped
Figure 10. THROTTLE_OUT operation when the car has stopped
Figure 12. THROTTLE_OUT operation when the car is moving
Figure 11. The car is moving

Conclusion

Using only one SLG46620V IC, we can create the system that controls an RC car providing protection from collision with an obstacle, and LED visual effects control. This design can be extended to other applications such as robotic vacuums, toys, handicapped early warning systems, industrial automation.