Back to projects
Robotics Simulation Platform

Virtual Robotics Simulator

Virtual Robotics Simulator preview

A C++ robotics simulator built in Unreal Engine with 50+ procedurally generated maps and 15+ realistically flawed sensors (gyro drift, laser noise, motor imprecision), originally created to keep our RoboCup team building software during the pandemic — even without access to the physical robot.

C++Unreal EnginePythonJavaEmbedded Systems
View on GitHub

About

This simulator wasn’t born from curiosity. It was born from a problem.

We were preparing for RoboCup Junior — specifically the rescue maze challenge — when the pandemic made it impossible to meet in person. No lab. No robot. No hardware access. Waiting wasn’t an option.

So instead of pausing development, we built the robot virtually.

The Virtual Robotics Simulator is a high-fidelity Unreal Engine environment written in C++ that allowed us to continue developing autonomous logic without touching the physical platform. It became our hardware substitute — not a toy demo, but a serious engineering tool.

The system generates 50+ procedural maze maps to simulate competition-style environments. If your navigation algorithm only works in a clean, predictable layout, it fails here quickly. That was intentional.

Realism was critical. Over 15 simulated sensors replicate real-world imperfections. Gyroscopes accumulate drift. Laser rangefinders introduce noise. Motors behave like actual mechanical systems — meaning they’re not perfectly precise. The idea wasn’t visual realism alone, but behavioral realism. Code that survives here has a much better chance of surviving competition.

The key architectural decision was the cross-platform abstraction layer. STM32 firmware runs unchanged both inside the simulator and on real hardware. That meant we could develop embedded logic at home, test it aggressively, and later deploy it directly onto the robot once we had access again. No rewrites. No “simulation-only” hacks.

C++ powers the simulation core inside Unreal Engine. Python scripts automated test scenarios and stress runs. Java handled specific sensor interface modules where appropriate. Every component had a purpose.

What started as a workaround during lockdown became a robust development platform — and a demonstration that constraints often produce better engineering decisions than comfort.

Key Features

  • 50+ procedurally generated competition-style maze environments
  • 15+ simulated sensors with physics-based error models
  • STM32 firmware compatibility via abstraction layer
  • Real-time sensor simulation including drift and noise
  • Cross-platform architecture supporting simulation and hardware
  • Python scripting for automated test scenarios

Challenges & Solutions

  • Recreating RoboCup-style maze behavior without physical hardware
  • Designing sensor error models that are realistic but computationally manageable
  • Maintaining real-time performance inside Unreal Engine with complex simulations
  • Building an abstraction layer clean enough to avoid firmware rewrites