Code Monkey home page Code Monkey logo

carla_sim_digital_mirrors's Introduction

carla_sim_digital_mirrors - A Carla Simulator Client with Digital Mirrors

Xbox One controller, Fanatec DD1 wheels, adjustable rear view mirrors, share memory model between process routines.

screenshot

Introduction

This code demonstrates how to share carla data between different python processes via a shared memory dictionary.

Features

  • Supports xbox one controller
  • Supports Fanatec DD1 base & Wheels
  • Mirror sensor camera images are processed and stored in a shared memory object
  • Main simulation thread uses pygame window.
  • Share memory is accessed by the mirror view routines and displayed using opencv

Prerequisites

Setup and Execute

  • poetry install - setup the environment
  • Ensure the Carla Simulator is running on localhost and listening to port 2000
    • .\CarlaUE4.exe -windowed -ResX=1024 -ResY=786 -carla-rpc-port=2000 -quality-level=High
  • Set simulation parameters in config.yaml
  • poetry run python sim_main.py - main simulation thread
  • poetry run python mirror_views.py - dual mirror views
  • poetry run python right_mirror_view.py - rigth mirror only
  • poetry run python left_mirror_view.py - left mirror only

NOTE: So far only testing on Windows 10.

Utilities

  • poetry run python util_get_joystick_values.py - Display joystick values untility tool

Controls

Xbox One Controller

  • Left Stick - Steering
  • Right Trigger - Accelerate
  • Left Trigger - Brake
  • A - Toggle Reverse
  • B - Hand Brake

Fanatec DD1 Wheel Controller

  • Wheel - Steering
  • Accelerator Pedal - Accelerate
  • Brake Pedal - Brake
  • A - Toggle Reverse
  • B - Hand Brake

Mirror Adjustment Keys

Left Mirror Controls

  • W - Left Mirror Rotate Up
  • X - Left Mirror Rotate Down
  • A - Left Mirror Rotate away from car
  • B - Left Mirror Rotate towards car

Right Mirror Controls

  • T - Right Mirror Rotate Up
  • B - Right Mirror Rotate Down
  • H - Right Mirror Rotate away from car
  • F - Right Mirror Rotate towards car

Screenshot

screenshot

carla_sim_digital_mirrors's People

Contributors

doddsy2018 avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

chillimeat

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.