Using Mimic Joint for Gearbox Simulation

I’m trying to use the mimic joint constraint to simulate the effect of motor reflected inertia (apparent inertia of motor rotor as seen through a gearbox). But this seems to be very unstable, only working at very low ratios (<2). Is the mimic joint constraint suitable for this type of usage? Are there examples I can follow to see what I’m doing wrong?

This github link has my code “smallest unit test” of the behavior I’m trying to simulate, along with the ConstraintSolver errors I get when trying to run it.

Thanks,