Giter VIP home page Giter VIP logo

zaytuna's Introduction

Calligraphy



3D Self-Driving Car Simulator with ROS ๐ŸŒณ

Zaytuna is a very simple, lightweight 3D self-driving car simulator that is programmable with ROS.
The simulator is meant to be used for educational purposes only!

โ— Note: Not suitable for virtual machine. You'll not be able to run it in Virtualbox or on a guest operating system. And if you've ever got it to run on a guest OS, the scene won't render properly, and therefore will not be suitable to drive with vision. For a simulator you usually need an actual graphic card, and not emulated one.

For any bug reports or suggestions, please use the above Issues/Discussions dialogs.

Requirements: ROS. "No support for ROS2 yet!"
If you haven't yet, you need to install a ROS version that is supported on your operating system. And make sure that ROS environment variables are setup properly.

Building the package: If you know how to build a ROS package, you probably don't need to read the rest. Otherwise, it's more convenient to go through these tutorials first.
To build the package open a terminal and navigate to src folder in your catkin workspace, assuming your catkin workspace is named catkin_ws, then run the following commands:

  • :~/catkin_ws/src$ git clone https://github.com/ChevronOne/zaytuna.git
  • :~/catkin_ws/src$ cd ..
  • :~/catkin_ws$ catkin_make or :~/catkin_ws$ catkin build depending on which command you've used when you first build your catkin workspace

If the build was successful, open a second terminal and run the command roscore, and in the current terminal run the command rosrun zaytuna zay_simu. And there you have it!

By default, there should be a model vehicle with some obstacles. However, you can delete or add up to 10 model vehicles and up to 5000 obstacles as needed.

To see the topics of the simulated model vehicle, open a third terminal and run the command rostopic list. Currently there is no documentation or tutorials of how to use them, but if you're familiar with ROS, then most of them should be self-explanatory.
To navigate in the scene use W, S, A, D, Up, Down, Right and Left keys. And for orientation use mouse pointer. If a model vehicle is connected to control panel with Key-Controller chosen, you can move it with T, G, F and H keys, but then you'll need to detach it manually from control panel in order to make it listen to ROS-topics again.

The simulator provides simulations for almost all basic sensors that are needed for a self-driving car to be programmed. The only topic that's missing is LiDAR/Laser Scanner, but a model vehicle still can be fully driven with vision.
The subscribers of speed and steering each takes a value within a range of [-1,1]. For steering value 1.0 simulates 25 degrees right-turn of front wheels, and -1.0 the same for left turn. And for speed 1.0 simulates full speed in forward direction and -1.0 the same for backward direction.

Depending on how much it could be used, there might be a consideration to work on a lidar-simulation as well. However the aim is to keep it simple and lightweight as possible, and avoid using any heavy dependencies or physic libraries.


Screenshots:

Zaytuna-Simulator

The View from Vehicle's Camera

Vehicle's Camera from ROS Visualizer App (rviz)



Note: The word Zaytuna means 'an olive tree' ๐ŸŒฑ

zaytuna's People

Contributors

chevronone avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.