This is the build version of AV4EV Simulator for Linux and should run without installing other dependencies. This simulator is based on SODA.Sim and integrated by Po-Jen Wang (pojen.wang@autoware.org) and Alexander Kalmykov (alex.kalm.dev@gmail.com).
The go-kart mechatronics system is designed as a modular system, consisting of several subsystems responsible for different tasks. There are seven major subsystems:
- Power Distribution (PD)
- Main Control (MC)
- User Interface (UI)
- Throttle-by-Wire (TBW)
- Brake-by-Wire (BBW)
- Steer-by-Wire (SBW)
- Rear-Shelf Design (RSD)
In our go-kart drive-by-wire design, all subsystems except the PD and the RSD use an STM32 Nucleo development board on a standalone PCB as the electronic control unit (ECU). Communication is achieved using the controller area network (CAN) to allow efficient information exchange between nodes. These modular control systems are integrated with the original go-kart chassis in a non-intrusive manner and are easy to understand, build, and modify.
-
Download
AV4EV_Sim.zip
from this link. -
If the machine has previously installed Autoware, edit the
.bashrc
file (under home, andctrl+h
to un-hide the hidden files) and comment out the following line toward the bottom:RMW_IMPLEMENTATION=rmw_cyclonedds_cpp
-
Save and reboot. Autoware should run normally without this line. However, this line would need to be enabled before running AWSIM.
-
Extract the
AV4EV_Sim
folder from the compressed zip file. -
Navigate to the directory:
cd AV4EV_Sim/Linux/AV4EV/Binaries/Linux
-
Run the simulator:
./AV4EV
- Hit
F11
to switch between window and full-screen modes.
- On the top left corner, select
Free
and thenEditor Mode
. - Select the drop-down menu to the right (cube with green plus sign). Under
SODA Vehicles
, select and dragKart Full
into the scene where you’d like to place the vehicle. - You may hit
X
(top right corner) to close the Editor Mode window after placing the go-kart to show the full UI. Editor Mode is used to edit component properties. - Hit the green triangle
Run
button to start the simulation. - Hit
X
(keyboard) to pose the vehicle (third-person mode) and enable UI, you’d be able to drive the go-kart with the keyboard’sW
,S
,A
, andD
keys,X
will stop the vehicle immediately.
The vehicle currently has the following topics set up for sensor and control ROS2 interface:
- Camera:
/kart/camera
- Lidar:
/kart/lidar
- GNSS:
/kart/gnss
- IMU:
/kart/imu
- Odom:
/kart/odom
- Control:
/kart/ackermann_cmd
After the ackermann_msg
is being published by your planner, Hit M
to toggle between the keyboard manual control and autonomous mode (ROS2 ackermann_cmd
).
AD Allowed on the right will be enabled when the go-kart is controlled via ROS2.
You may use rviz2
and rqt
to test sensor output through ROS2 interface.
Similar to spawning the go-kart, you can spawn boxes in the environment under Tools -> Boxes
to test obstacle avoidance. Under the editor mode window, rotate the boxes along the z-axis (blue) by 33° to face the race track.
- Hit
Enter
to exit the 3rd-person mode and go back to Spectator mode. - Hit
ctrl
and use the mouse scroll to zoom in/out of the camera view.
You can change the map to Pennovation and have a sneak peek of the Pennovation environment we built:
- Select the first icon (three horizontal lines) on the top left corner -> Open Level -> select Pennovation map.
- The default camera position is off so you need to fly around with the keyboard and go above ground level before placing the go-kart on the ground.
- Note: This is still under development and there are some collision errors so the go-kart may not run correctly on all of the surfaces.
To use the source code of the plugin, you need to have an Unreal Engine project with SODA.Sim and SODA.Sim ROS2 plugins installed. You can find more information and download the plugins from the following repositories: