Practice the ROS2 REST in Pieces coding problem in Integration. Browser-based execution with automated grading — no local ROS install required. 0% of engineers pass this challenge.
A fleet management dashboard polls a REST API every 2 seconds to display robot positions. The robot publishes its position over ROS2 at 10 Hz. A ROS2→REST bridge is supposed to forward these positions to the dashboard, but operators report the dashboard always shows data that is 8–12 seconds old.
The bug: a synchronous HTTP POST is made inside the subscriber callback. Each POST takes ~200 ms to complete. At 10 Hz subscriptions the callbacks pile up 2× faster than they drain — by the time a position is forwarded to REST it's already 7–8 positions stale.
Fix the bridge using a cache-and-timer pattern:
self.latest_pose = msg (non-blocking, O(1)).create_timer fires at 2 Hz and performs the HTTP POST with the cached pose.This decouples ROS2 message ingestion from network I/O entirely.
It is a hands-on Integration challenge on SimuCode where you implement and run ROS2 code in the browser with runtime-verified tests.
Open this page, sign in, and solve the problem in the built-in IDE. Your solution is graded against real ROS2 execution checks.
This Hard problem focuses on http, subscriber, blocking-io skills used in robotics interviews and production systems.