Ben’s Status Reports

Week of 8

Progress: Obstacle Avoidance

Obstacle avoidance is convincingly working! This video shows it functioning consistently in techspark

Some improvements that improved it from last week:
> Variable path length execution

> Global transform of obstacles using odometry delta

> Rejection of small obstacles

> Improved residual policy

> Compute utilization improvements

Progress: Return to Commander

Return to commander is also working, with path replay! This video shows:

1. obstacle avoidance run to reach the goal

2. turn around

3. use odometry to track the forward path in reverse to the starting point

The path following is implemented as pure pursuit. The lookahead distance is scaled by forward velocity, and respects hardware limits of what radius curvature is feasible.

Week of Nov 1

Progress: Depth Inference

I compared the various runtime / compilation strategies for the ZipDepth model on Pi5. Two threads LiteRT (tensorflow format converted) INT8 quantization proved fastest by a mile.

The GPU is basically useless because it only has shader cores.

Progress: Absolute Depth

The ZipDepth model (integrated last week) is only trained to output relative depth, but we need absolute depth for dynamic window approach to function. I went through a few different calibration approaches, increasing in complexity but also performance.

1. Idea 1: set up boxes at measured locations, interpolate relative fit

> this doesnt work because relative depth can jump a lot, perceived depths can be at vastly different GT locations

2. Use charuco board to gather large amount of data, fit a curve to this

> improved things but not good enough

3. mix charuco + synthetic training data (small amt of low quality data right now) to train residual network to convert to absolute depth on top of baseline correction.

this video shows the learned residual model (~75k FP32 params) output vs ground truth

> this approach is scalable and effective! we just need more synthetic and real data. ideally on a variety of real objects but thats not possible without a motion capture cage

Progress: Obstacle Avoidance

Using the absolute depth output, dynamic window approach is run to:
1. sample candidate paths for the robot to drive on (everything modeled as arcs of variable radius)
2. collision check using robot dimensions along paths (1.5s in the future)
3. for non-collision paths, rank based on some heuristic (naive for now) and select one to execute

This runs realtime, with odometry and all other major load, at ~3-4hz. Video below shows early runs.

In the section below I discuss why this isnt working well yet (i think).

Progress: Control Improvements and ToDos

[BIG BUG] there is a mismatch between the lowest rpm and and configured feedforward duty cycle at that rpm

ff(RPM) = 0.28 + 0.0016 × RPM
ff(75) = 0.28 + 0.0016 x 75 = 0.4
40% duty cycle is producing ~90 RPM baseline from the data i have collected. therefore, we need to recalibrate the feedforward at the hardware measure 40% duty cycle minimum.
this is a major bug for the obstacle avoidance because it implies that our modeled path of the robot is not being realized. if we command: [LEFT=75, RIGHT=90], we are realizing: LEFT=90, RIGHT=90].
[CALIBRATION IDEA] run sweep of arcs on target surface to tune on, measure ground truth odometry arc as sys-id step to match path planning. I tried this quickly, but will need to redo because of the bug above. incidentally proved to be a cool odometry demo. video below

Week of Oct 25

This video summarizes progress of both major milestones

* running in realtime on the crawler, rendered offline. no special setup other than what is documented below

Progress: Odometry

Odometry is working! We use a custom version of the MINS estimation model. MINS allows native fusion of multiple sensor sources; we configure it to use: wheel encoders, IMU, camera, (optionally) GPS. Because we provide the MINS model with approximate clock offsets between sensor sources (see last week’s progress on calibrating these values), our pub/sub system must reliably deliver messages on time. I made some improvements to our pub/sub stack to allow this:

  • native multi-threading via sidestepping the GIL (>= python3.13)
  • zero-copy of images via shared mem pool
  • best effort delivery where tolerable
  • UART missed packet is acceptable

Our MINS fork also makes the following changes to the core estimator to make the solve more robust:

  • (big assumption) our crawler always resides on a gravity aligned, perfectly flat XY plane
    • reduces solve from 6 dof to 3 dof (x, y, yaw)
  • turning occurs around the rear wheels (due to weight distribution)
    • original impl estimates it around the middle

And we perform the following calibration routine:

  1. static period: acquire IMU baseline, clock sync
  2. dynamic hand guided period: acquire visual lock
  3. static period: settle

Important frequencies:

[INPUT] IMU:               111hz (hardware poll rate)

[INPUT] ENCODER: 20hz (hardware poll rate)

[INPUT] CAMERA:   30hz (downsampled from 60fps native rate)

[OUTPUT] POSE:     20hz

Progress: Depth

We run the ZipDepth model (6.1M params) at 3Hz on the RPi5. I exported the model to ONNX  to quantize it to INT8. Inference runs about 100ms faster at INT8 instead of FP32 (train quantization), without any severe quality degradation.

The next step (to try) will be to use this depth map to run autonomous goal-free heuristic-based exploration. I plan to use the Dynamic Window Approach (paper from the goat Dieter Fox 1997) to generate candidate path arcs.

Please see the video at the top of this weeks report.

Week of Oct 18

Progress: Build

To parallelize work, I built the first V0 (after prototype) crawler. This one powers the pi5 off the drive battery, and has the updates listed below. All major subsystems are integrated and wired.

Progress: CAD

After the prototype build, I made some minor adjustments:

  • added mounting points for buck converter
  • solenoid mounting
  • usbc debug port to rpi5
  • more room for wiring
  • updated camera mount to OV9281
  • added repeater

Progress: Calibration

I added four calibration routines:

[REQUIRED] camera intrinsics

  • uses checkerboard to solve camera intrinsics
  • camera intrinsics fed into optical flow model
  • rectified image fetchable

Below photos show unrectified and rectified images.

[REQUIRED] camera, IMU extrinsics and time offset

This is a bit more advanced. It uses the same checkerboard to solve for:

  • time delay between camera frames and IMU sensor readings
  • extrinsic mapping from imu frame to camera frame

It does this by keeping the board static, and moving the crawler. It captures frames and IMU data, and solves a fit over the unknowns. This data is critical for the odometry.

[REQUIRED] IMU white noise model

Here I use the Kalibr IMU noise model to find the IMU steady state noise. This test is conducted with a static crawler over a long period (multiple hours).

[OPTIONAL] empirical wheel diameter

Although we know the pulses per rotation of the motor and the wheel diameter, the effective wheel diameter may be different (due to printer tolerances, etc). Using a known measured distance, we can calibrate the effective wheel diameter.

Skipped for now.

Week of Oct 12

The design report and presentation really killed my time this week, so not much was accomplished.

Progress: CAD

I finished the first crawler build, with wiring. The belts also arrived, and the tension looks good there. Ethan is investigating the compute power issues we have. Luckily, we always have the option of powering the pi5 off of the drive battery instead of the dedicated compute battery.

Next steps:

  • Update CAD for buck converter spot
  • Teleop build out
  • Camera integration
  • VIO + obstacle avoidance

Ethics: Part C

Our project is directly motivated by consideration of changing environmental factors. Global warming directly causes more severe natural disaster conditions. Our project will build technology to help humans perform search and rescue in both disaster-afflicted places and remote nature preserves without existing network infrastructure.

Another side of the consideration is what resources does the manufacturing of our robots require, and how does the use of these robots impact the environment. The robots are designed to be cheap and mass produced, so they will potentially litter the environment after use. Given all robots are equipped with GPS, we should be able to recover a large amount of these after use, aiming to leave little trace on the environment.

Week of Sep 27

I am writing this progress report a bit early, as I am out of town and offline Fri Oct 2 – Sun Oct 4.

Progress: CAD

I printed the first crawler frame, and did a mock assembly (waiting for heat set inserts, etc to arrive) to test the fit of various components.

I made the following adjustments after checking fit:

  • update all heat set insert dims
  • update motor clearance
    • nub clearance: updated depth 1.5mm -> 2,5mm
    • shaft clearance: updated ID 8.5mm -> 10mm
  • increase z clearance for frame
    • updated 37mm -> 39mm (1mm z clearance)
  • add debug port for pi5
  • check csi connector clearance
    • updated 14mm -> 16.5mm
  • check bearing fit with calipers
    • 0.24 layer height: 0.4mm undersize
    • avoid variable layer height
    • updated bearing holes +0.4mm oversize
extra changes:
  • updated boost converter mounting dims
  • updated drive shaft pressfit: 8mm -> 8.1mm
  • reworked tbeam mounting
    • full disassembly, full screw down
  • moved antenna mounting point up

Also, after checking the drive LiPo specs, the max rated temp is 60C, which we could easily hit. I added 20mm intake/outtake fans, and a Pi5 cooling fan. The case cans will be tied directly to the 12v rail.

The final V0 cad looks like this:

Finally, I made a wiring diagram for the V0 build:

Remaining work:

1. Print 1x v0 crawler

2. Assemble 1x v0 crawler

3. Test v0 crawler

4. Add router drop mechanism (electromagnet, solenoid)

Week of Sep 20

Progress: GPS

Continuing work from last week, I validated the GPS on both boards, with LoRa link saturated. This was the final acceptance test for the GPS firmware modifications.

I also added UART support (instead of serial-over-USB) to the modified RNode firmware and tested that with the RPi 0_2. USB for robotics is a personal no-go for me (for reliability purposes), so this is a great change. To test the UART support, I saturated the LoRa air between two nodes, polled the IMU at max frequency, and polled the GPS at max frequency. Over 100s period, UART drop counter was at 0. To achieve the 0 frame drop number, I bumped the baud rate in firmware up to 230400, up from 115200. I first increased it to 460800, but sometimes got UART overrun flag on Pi, so I dropped to non-standard 230400.

I also validated the freshness of IMU readings. Over a 100s period, I polled the hardware at 100hz, and observed source timestamps of 9.996–10.004 ms. This is super consistent.

Remaining work:

1. Characterize if IMU readings are reasonably accurate

Progress: Power

The BLDC motors arrived, and because the documentation was limited, I wasn’t sure about the pinout. I tested and validated the pinout to be:
RED: 12V, BLK: gnd, BLUE: pwm, WHITE: dir of rot, YLW: tach square wave

I made a mistake when reading the tach output, and pulled too much current through, which damaged the encoder. I confirmed this on the scope, thge encoder just reads noise now instead of the square pulses. Good to know this mistake now, but a bit of a setback.

I also validated the motors can be powered off the 3S 2.2Ah battery.

Remaining work:

1. Map pulses / gearbox rot

2. Add velocity control to driver

3. Push driver code to main

Progress: SLAM

I rendered some more diverse scenes, there are 7 scenes. Full playlist here:
https://youtube.com/playlist?list=PLF-3LrHYO10c&si=75cfseLHm1imou-5

Scene names:

1. Pine ridge: outdoors, forested, incline

2. Parking garage: indoors, low lighting

3. Warehouse: indoors, mixed lighting

4. Abandoned city: large space, dense urban

5. Forest field: sparse outdoors

6. Classroom: dense indoors, small space

7. Hidden alley: dense urban

In addition, I instrumented all but forest field for online testing. By online testing, I mean running odometery and path planning in the loop (as opposed to the static paths I worked with last week). This does not mean realtime, as rendering a frame is on the order of 5-10s, but I did test the realtime performance of any models/algorithms on the pi5.

Here, I am running ZipDepth at 2 Hz. The depth map is fed into an implementation of Dieter Fox’s Dynamic Window Approach for classical obstacle avoidance. The video shows strong results in this dense visual scene, for both odometry robustness and obstacle avoidance. The odometry algorithm is OpenVINS which runs a mixture of SLAM and optical flow, which are fed with IMU fixes into an EKF.

This setup allows to:

1. Test odometry algorithms on dynamically generated paths, various scenes

2. Test obstacle avoidance algorithms on realistic scenes

Week of Sep 13

Progress: GPS

I modified the RNode firmware , which is an open source ESP32 firmware that drives various LoRa radio hardware. This is the firmware I previously had flashed onto our TBeam Supreme radios.

The new firmware fork supports the following additions:

1. GPS fixes @ 1Hz

2. IMU fixes @ 100Hz

3. UART to host linux device (instead of only serial-over-USB)

I then tested this firmware, using my phone as a ‘ground truth’ GPS device. I moved in a unique pattern, at approx 2m/s continuously on Gesling stadium. Here, the pattern is ‘BEN’ (N gets cut off part way through). TBeam GPS fixes are in red, phone fixes are in blue. I also disabled cellular on the phone to give a more apples-apples comparison.

I also tried the GPS in a more occluded urban area (behind techspark, severe occlusion from Scaife, Hamerschlag, Ansys). And found high GPS drift (up to 20m). I compared the GPS satellite count, and the Gesling setting both established the minimum lock faster (>8 satellites in under 5s), and a higher steady state satellite count (~14 satellites). This indicates that even in outdoor settings, we may not be able to fully rely on GPS for localization. We should fuse with SLAM and IMU to generate more robust localization.

Remaining work:

1. Flash other board with GPS firmware

2. Test GPS firmware under LoRa saturated, to ensure the serial link has sufficient bandwidth

3. Characterize if IMU readings are reasonably accurate

Progress: Power

I soldered the headers onto both the RPi Zero 2 W and the TBeam Supreme. The Tbeam Supreme has a built in slot for 18650 3.7V battery. I used a DC voltage booster to boost VBAT to 5V, and that 5V rail powers the Pi.

Remaining work:

1. Test this for Pi5 under load

2. Test battery life

Progress: SLAM

I generated some synthetic videos to help us iterate on SLAM faster, without needing hardware. These videos are rendered in Blender, on 8×2080 over 12 hours. Rendered videos:

These videos are rendered at 60fps, 120s length. They contain traversal, rotation, and pauses. There is also mocked vibration and terrain change. The output of the rendering step is both the video, and the ground truth robot pose. Camera parameters were aligned to our target camera which is 120deg, grayscale, global shutter, 1280×800 or 640×400 at ~140fps. Source asset packs:

https://download.blender.org/demo/test/classroom.zip
https://dl.polyhaven.org/file/ph-assets/Scenes/hidden_alley.zip
https://dl.polyhaven.org/file/ph-assets/Scenes/the_shed.zip
https://www.blendkit.com/asset-gallery-detail/665e2d80-6e77-403f-a84d-704934de982d/

Then, I used these videos to run realtime vSLAM (no synthetic IMU data), using the OV2SLAM and ORB3-SLAM monocular vSLAM libraries. This ran on a Radxa Rock5C, 8GB memory cap, pinned to only 4 cores as a proxy for Pi5 performance. I swept a variety of parameters, including but not limited to:

1. source framerate: 15, 30, 60fps

2. source resolution: 640×400, 1280×800

3. scene: forrest field, hidden alley, classroom

4. native knobs for each library

Results are detailed, so I won’t enumerate them here. Still thinking on the takeaways and iterating. For the compute side, it fits easily on 4 cores, with a peak memory usage of < 1GB. As the map grows, the memory usage might increase, but with > 4GB we have tons of headroom.

Remaining work:

1. Render more diverse scenes

2. Render scenes with limited loop closure, higher velocites

3. Test more parameters and libraries. Explore gauss splat or learned visual odometry strategies

4. Transfer to real hardware and run in-domain testing

Progress: Crawler CAD

CAD is mostly drafted, as well as the associated BOM. The Crawler uses two BLDC motors, a 3S 2200mAh drive battery, and a 18650 compute battery. It is a skid-steer setup, with a unibody frame.

Remaining work:

1. Finish up top plate to enclose wires

2. General CAD finish-up

3. Print and assemble first Crawler

4. Test crawler