2020-03-10 14:38:40 -06:00
openpilot in simulator
2020-03-01 11:50:03 -07:00
=====================
2020-02-04 20:46:57 -07:00
2020-09-10 04:14:49 -06:00
## Running the simulator
2020-11-18 14:10:37 -07:00
2020-09-10 04:14:49 -06:00
First, start the CARLA server.
2020-03-01 11:50:03 -07:00
```
2020-09-10 04:14:49 -06:00
./start_carla.sh
2020-03-01 11:50:03 -07:00
```
2020-09-10 04:14:49 -06:00
2020-09-11 09:42:12 -06:00
Then start bridge and openpilot.
```
2020-09-11 09:42:31 -06:00
./start_openpilot_docker.sh
2020-11-05 15:11:41 -07:00
```
2020-09-10 04:14:49 -06:00
2020-11-05 15:11:41 -07:00
To engage openpilot press 1 a few times while focused on bridge.py to increase the cruise speed.
2020-11-18 14:10:37 -07:00
2020-06-03 13:54:49 -06:00
## Controls
2020-09-10 04:14:49 -06:00
2020-09-11 09:42:12 -06:00
You can control openpilot driving in the simulation with the following keys
2020-06-17 18:53:17 -06:00
| key | functionality |
| :---: | :---------------: |
| 1 | Cruise up 5 mph |
| 2 | Cruise down 5 mph |
| 3 | Cruise cancel |
| q | Exit all |
2020-03-01 11:50:03 -07:00
2020-09-29 15:00:03 -06:00
To see the options for changing the environment, such as the town, spawn point or precipitation, you can run `./start_openpilot_docker.sh --help` .
This will print the help output inside the docker container. You need to exit the docker container before running `./start_openpilot_docker.sh` again.
2020-11-15 13:13:12 -07:00
2021-03-11 16:28:37 -07:00
## Performance
openpilot doesn't have any extreme hardware requirements, however CARLA is very resource-intensive and may not run smoothly on your system. For this case, we have a low quality mode you can activate by running:
```
./start_openpilot_docker.sh --low_quality
```
You can also check out the [CARLA python documentation ](https://carla.readthedocs.io/en/latest/python_api/ ) to find more parameters to tune that might increase performance on your system
2020-11-15 13:13:12 -07:00
## Further Reading
The following resources contain more details and troubleshooting tips.
* [CARLA on the openpilot wiki ](https://github.com/commaai/openpilot/wiki/CARLA )