Skip to content

JeppeSchildt/f1tenth

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 

Repository files navigation

README

This README will walk the reader through the steps to setup the ROS workspace for this project and how to Launch the Car. This tutorial is intended for unix-based terminals.

It is assumed that ROS-melodic is installed on the Jetson.

SSH into the Jetson or connect keyboard, mouse and monitor to the Jetson and open a terminal in the the Linux GUI and follow these steps:

ROS Workspace Setup

  1. Clone this repository into a folder on the Jetson
$ cd ~/sandbox (or whatever folder you want to work in)
$ git clone https://github.com/jepp5220/f1tenth.git
  1. Create workspace
$ mkdir -p f1tenth_ws/src
$ cp -r f1tenth_system f1tenth_ws/src/
  1. Install additional ROS packages
$ sudo apt-get update
$ sudo apt-get install ros-melodic-driver-base
  1. Make Python scripts executeable
$ cd f1tenth_ws
$ find . -name “*.py” -exec chmod +x {} \;
  1. Move to workspace folder and compile the code
$ catkin_make
  1. Source directory
$ source devel/setup.bash

Now we are ready to launch the car.

Launching the Car

  1. Start roscore
$ roscore
  1. In another terminal, move to workspace folder and source the bash file as such:
$ source devel/setup.bash
  1. To launch the car, use the following command:
$ roslaunch racecar drive.launch

Now we can activate the different kinds of control.

For external control, run these three Python scripts in seperate terminals:

$ python3 f1tenthv2/f1tenth_ws/src/f1tenth_system/racecar/racecar/
    scripts/lidarMQ.py

$ python3 f1tenthv2/f1tenth_ws/src/f1tenth_system/racecar/racecar/
    scripts/odomMQ.py

$ python3 f1tenthv2/f1tenth_ws/src/f1tenth_system/racecar/racecar/
    scripts/recieveinputMQ.py

Here it is noted that the external controller also needs to comsume and send input to actually activate the external control.

For Manual control, run this Python script in a seperate terminal:

$ python3 f1tenthv2/f1tenth_ws/src/f1tenth_system/racecar/racecar/
    scripts/manual_controller.py

For Pure Pursuit control, run this Python script in a seperate terminal:

$ python3 f1tenthv2/f1tenth_ws/src/f1tenth_system/racecar/racecar/
    scripts/purepursuit.py

About

Software for the F1Tenth car - BSc project

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors