Skip to content

Nibroc00/UrgentStop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Urgent Stop

Project Overview

The goal of this project is to construct an algorithm which is capable of stopping an autonomous vehicle. The algorithm should be capable of stopping the vehicle in an optimal manner; for example, it should come to a smooth stop when able or come to a quick stop in an emergency. Here is the zombi robot for which this will be developed:

zombi

Ideally, we would like this work to be generally applicable, not just to zombi.

Unity

To remove the need for the physical vehicle, we will simulate stopping the vehicle within Unity. To get started with Unity, download Unity Hub.

To manage the massive files that inevitably come alongside Unity, we will be managing collaboration on the project through USU Box.

Resources

User Manual

1. Necessary Software Installation

1.1 Download Unity

Go to https://unity.com/download which is the Unity downloads page. Scroll down slightly to the title that says Create with Unity in three steps. Then in the section labeled, 1. Download the Unity Hub, click on the blue text that says Download for Windows.

Download for Windows

When the download is complete, select it from the downloads menu at the bottom of your screen.

Select executable from downloads

You will then see a pop-up that asks if you want to allow this app to make changes to your device. Select yes.

You will then see a pop-up with a licensing agreement. Select I Agree.

Agree to terms of service

You can then select the location for the installation. If you desire, you can change the location. Otherwise, select install.

Click Install

You will see your final pop-up. Make sure that the Run Unity Hub box is checked. Then press Finish.

Click Finish

A pop up will then appear. Click Skip Installation in the bottom right corner.

Skip installation

Select installs from the menu on the left.

Click Installs

Then click the blue button that says Install Editor.

Click Install Editor

Select the Archive tab.

Click Archive

Click on the blue text that says download archive.

Click Download Archive

You will be taken to the Unity downloads archive. Scroll down and select the tab for Unity 2020.x.

Click Unity 2020.x

Then scroll down to Unity 2020.3.29f1. Click the corresponding green button that says Unity Hub.

Click the appropriate Unity Hub button

The installation will then begin and when it is complete you will see a popup that asks if you want to allow this app to make changes to your device. Select yes.

1.2 Connect to the USU VPN

If you are not connected to the USU network, you will need to connect to the USU VPN. Go to https://usu.service-now.com/aggies?id=kb_article_view&sysparm_article=KB0011477&sys_kb_id=fb3eb5d2b8834100bd5c10e091b7dbf3&spa=1 and follow the installation instructions for the VPN.

1.3 Install Git LFS

Git lfs uses a separate server for easier managing of large files. Visit https://git-lfs.github.io/ to download. On Linux, you likely just need to install the git-lfs package from your distro's repository.

Download Git LFS

In the windows search bar, search for the command prompt. Click on the Command Prompt app to open it.

Open a Command Prompt

Type in git lfs install and press enter.

Git LFS Initialized

You know this is installed properly if you type in git lfs version then press enter and are shown the version rather than an error message.

See LFS version number

2. Accessing The Project

2.1 Cloning the Repository

Make sure you are connected to the USU VPN.

Open the command prompt. To clone the project on your desktop type in cd Desktop and press enter, otherwise, navigate to the location where you would like to clone the project. Then type git clone mater@129.123.24.8:urgentstop.git UrgentStopSimulation and press enter. Wait for the cloning process to finish.

Clone the project

You will then be prompted to give a password. Type in spot and then press enter.

2.2 Opening The Project In Unity

Return to the Unity hub and select the Projects tab from the lefthand menu.

Click Projects

Click the arrow next to the open button. Then click on the option Add Project From Disk.

Click the dropdown on Open

Click Add project from disk

Navigate to the directory where you cloned the project. If you followed the steps shown in previous steps, the directory is on the desktop and is named UrgentStopSimulation. Select the folder and then press the Add Project button.

Select your Urgent Stop project folder

Double click on the project in the Unity hub to open it in the Unity editor. It will take some time to load, but the project will then open in Unity.

Click your project from the projects list

3. Running The Simulation In Unity

Opening the Scene

In the Unity Editor there is a list of assets in the bottom left corner, select Scenes.

Select scenes

Double click on Scene.

Double click Scene

Then click the play button arrow at the top of the screen to start the simulation.

Click the play button

3.2 Changing The Simulation Variables And Running The Simulation

Select the parameters for the simulation:

  • Car mass: The mass of the vehicle (USU's Zombi)
  • Terrain: The type of ground desired to test stopping
  • Stopping Distance: The distance in meters the obstacle will be from the vehicle

Then press the Start Simulation button.

Click Start Simulation

Initially, the zombi will be getting up to top speed. Note that the obstacle will not appear in the simulation until the vehicle has reached top speed (about 4.5 m/s). The HUD displays the zombi current speed, the mass of the vehicle, the terrain friction, and the stopping distance to the obstacle.

Grass Terrain

Once top speed is reached, the distance to obstacle countdown will begin.

Count Down Started

And the zombi will come to a stop.

Zombi Stopped

4. Executable

4.1 Accessing The Executable

Navigate to where you cloned the project on your computer.

Unzip the contents of the zipped urgentstop build folder.

If needed, in the newly unzipped folder, open the directory named urgentstop build.

Double click the executable file UrgentStop.

4.2 Running The Executable

Select the parameters for the simulation:

  • Car mass: The mass of the vehicle (USU's Zombi)
  • Terrain: The type of ground desired to test stopping
  • Stopping Distance: The distance in meters the obstacle will be from the vehicle

Press the Start Simulation button to run the simulation.

Initially, the zombi will be getting up to top speed. Note that the obstacle will not appear in the simulation until the vehicle has reached top speed (about 4.5 m/s). The HUD displays the zombi current speed, the mass of the vehicle, the terrain friction, and the stopping distance to the obstacle.

Once top speed is reached, the distance to obstacle countdown will begin, and zombi will slow down until it stops.

From here, you can either press the restart button in the HUD to reset the simulation or press the escape key on your keyboard to exit the application.

About

To remove the need for the physical vehicle, we will simulate stopping the vehicle within Unity. The goal of this project is to construct an algorithm which is capable of stopping an autonomous vehicle. The algorithm should be capable of stopping the vehicle in an optimal manner; for example, it should come to a smooth stop when able or come to …

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors