I’ve been hanging out in the NVIDIA Omniverse community on Discord and ran into a post that inspired me to dig my heels into a challenge that someone had been working on for days, which was to simulate linear motion from a rotational drive.
This seemed like it should be a simple simulation, but clearly it wasn’t easy to pull off! The fact that we couldn’t find any tutorials for simulating a simple threaded nut and bolt motivated me to fill that gap. So, that’s what we’ll be doing in this article!
We’re going to use two different approaches! I started this project using a Rack-and-Pinion joint to manage linear motion of the nut based on the rotational drive of the bolt. Later, someone asked how to keep the bolt still and only rotate the nut, which we’ll also do using a Mimic joint.
You can access the project files on GitHub, which we’ll go over in detail.
If you’d prefer video walk-throughs of this project, you can watch the Rack-and_Pinion approach here:
I’m currently working on the Mimic joint video and will publish that soon!
Hello World Digital Twin
I’ve seen complex digital twin projects that include a mechanical screw drive—A threaded drive shaft that causes an object to travel along its length as it rotates. A bench vice is a perfect example!
The simplest representation of this type of movement is a nut and bolt, so I’m calling this a “hello world” digital twin.
Sadly, the original poster’s project requirements weren’t as simple, but this still seemed like a great way to strengthen fundamental skills in NVIDIA Omniverse. Even if my simulation isn’t 100% mechanically accurate, which is just a matter of getting the math right to meet your project’s needs.
Let’s review the key joint components we’ll be using to create this simulation.
Rack and Pinion Joint
The rack-and-pinion joint in NVIDIA’s Isaac Sim requires you to setup a revolute joint and a prismatic joint, which will be controlled based on a ratio you provide. The ratio determines the conversion factor between the angular displacement (in radians) of the pinion and the linear displacement (in meters) of the rack.
Revolute Joint
The revolute joint revolves around an axis.
Prismatic Joint
Prismatic joints slides along an axis.
Mimic Joint
The mimic joint uses more of a “follow the leader” approach and can leverage any combination of joint types. In this project, we’ll apply the mimic joint to the revolute joint that rotates the nut, which will also follow a nut guide that we’ll tie to a prismatic joint.
Reviewing an AI Generated Rack-and-Pinion Example
The original poster had Claude create a decent representation of this type of joint and shared the Python script on Discord. I ran that in Isaac Sim and found it extremely valuable for understanding how the scene needed to be setup to pull this off.
Let’s take a quick look at that.
You can check out the screw.py file and the claude_scripted.usda file directly on GitHub. If you load the USD file in Isaac Sim, you can compare how the Python script generates the USD, which allows you to control everything directly in the Isaac Sim user interface:

This is an excellent way to learn how Python can be used to generate USD scenes, while also understanding how USD feeds Omniverse user interfaces. That’s exactly how I improved my understanding of how this project needed to be setup, allowing me to create the same simulation using only the UI.
I used Devin AI to help me understand how to build the static bolt version, which I saved as a .usda file so I could study the data to understand the difference.
Setting up the mimic joint version was a bit more challenging to grasp in the Isaac Sim UI, but I kept practicing until I could replicate it consistently and understood how the parameters effect the simulation.
Let’s Build Our Digital Twins
Let’s walk through the steps of how to set up both of our simulations in Isaac Sim.
CAD-to-USD
Before we jump into Isaac Sim, we’ll start by exporting the CAD files from OnShape in the JT format, which we’ll use to convert the separate parts into USD. I’ve already done that and provided those files in the hex_bolt folder of the project repo to make this easier for you.

I ran into issues converting the JT files to USD using Isaac Sim, so I spun up Omniverse USD Composer to handle this process. You can see how I did this in the video walkthrough.
Isaac Sim Project Set Up: Rotating Bolt using Rack-and-Pinion
Start Isaac Sim with an empty scene and set the lights to Default.

Create a ground plane by going to Create > Physics > Ground Plane.
Add a physics scene to set our gravity by going to Create > Physics > Physics Scene.
Adding Parts with Physics
Go to the Stage tab and right-click to create a new Xform and rename that to “Bolt”. Now, you can right-click that Bolt Xform and add a Reference to the Bolt.usd in the hex_bolt folder. With the Bolt selected, you can hit the “F” key to bring it into focus in the preview window.
Next, you can follow that same process to create an Xform for the Nut, and add a reference to the Nut.usd file. Drag the Nut up so it’s just above the bolt hex.
We need to add physics to both our Nut and Bolt, so right-click each one and apply Add > Physics > Rigid Body with Collision Preset, so they can be moved by the joints that we’ll add next.
Adding Joints
Now that we have our parts in place, we can add our joints.
Right-click the Bolt and go to Create > Physics > Joint > Revolute Joint, which will add the rotation joint we’ll use to spin the bolt. Go to the properties and change the axis to Z.
Scroll back up to the top of the properties and click the + button to add Physics > Angular Drive to allow our bolt to rotate. Here’s a screenshot of our Bot’s revolute joint settings:

Follow the previous steps and add a Prismatic Joint to the Nut with these settings:

The prismatic joint does not need a drive added in this case.
Next, right-click World in the stage tab and create a Rack and Pinion joint, which also does not need a drive. Adjust the Body0 parameter to point to our Bolt and Body1 value to point to the Nut, as shown below:

The last step is to add the appropriate Hinge and Prismatic targets, along with the proper Ratio value, to our Rack and Pinion joint:

The Ratio value will vary based on your specific project, since it’s what determines how fast the nut moves compared to the spin of the drive.
If you haven’t already, be sure to save your project!
Run The Simulation
Now, you can hit the play button to run the simulation and watch the bolt spin as the nut moves up to the top. If you wait for the simulation to play out, you’ll find the nut stops at the top, which is due to the the Target Velocity parameter we added to our revolute joint. If you adjust that value to 900, you’ll find the Nut keeps going beyond the height of the bolt.
Isaac Sim Project Set Up: Static Bolt using Mimic Joint
Start Isaac Sim with an empty scene and set the lights to Default.

Create a ground plane by going to Create > Physics > Ground Plane.
Add a physics scene to set our gravity by going to Create > Physics > Physics Scene.
Adding Parts with Physics
Go to the Stage tab and right-click to create an XForm and call it NutAssembly. Nesting our nut and bolt under this is a key difference in this build!
Right-click the NutAssembly and apply Add > Physics > Articulation Root. This is another key difference to ensure our mimic joint can work properly.
Now you can right-click the NutAssembly to create a new child Xform and rename that to “Bolt”. Right-click that Bolt Xform and add a Reference to the Bolt.usd in the hex_bolt folder. With the Bolt selected, you can hit the “F” key to bring it into focus in the preview window.
Next, you can follow that same process to create another NutAssembly child Xform for the Nut, and add a reference to the Nut.usd file. Drag the Nut up so it’s just above the bolt hex, which should be 0.005 on the Z axis.
We need one more child Xform, which we’ll call NutSlide. This is what the nut will follow. You’ll want to set the Z axis on this one to 0.005, as well.
Now, add a cube shape child to this Xform. You may need to reduce the scale down to 0.001 for it to match the rest of our CAD imported prims.
We need to add physics to all of the child Xforms, so right-click each one and apply Add > Physics > Rigid Body with Collision Preset, so they can be moved by the joints that we’ll add next. We also need to ensure each one has mass, so right-click each one again and apply Add > Physics > Mass and be sure to set the Mass parameter under each Xform to 1.0 so they all have some weight.
Now that we have our parts in place, we can add our joints.
🚧 This section is still under construction as I update it with new info! 🚧
Right-click the Bolt and go to Create > Physics > Joint > Fixed Joint, which will make sure our bolt does not rotate.
Right-click the Nut and go to Create > Physics > Joint > Revolute Joint, which will allow our nut to rotate. In the properties, set the axis to Z. Also, set the Lower Limit to -100000 and the Upper Limit to 100000. These are required for our mimic joint to work, which we’ll create soon.
Right-click the NutSlide and go to Create > Physics > Joint > Prismatic Joint, which is what our nut’s revolute joint will follow.
Next, we need to set this prismatic joint’s Body 0 parameter to /World/NutAssembly/Bolt.
Update the Axis to Z and set the Lower Limit to 0.0 with an Upper Limit of 0.025, which ensures out nut stops at the top of our bolt.
Now, we add a linear drive to the prismatic joint so our slide moves up and our nut can follow it. Right-click the joint and Add > Physics > Linear Drive.
Under the drive’s parameters, set the Target Velocity to 0.06 and the Damping to 100000.
The last piece of this puzzle is to go back to our nut’s revolute joint’s properties and set Body 0 to /World/NutBoltAssembly/NutSlide
Then, we click the +Add button and select Physics > Mimic Joint. Set the Reference Joint to our Prismatic Joint and
Customizing Settings For Your Project
Any of these joint parameters can be adjusted to meet your specific project’s needs. Exactly how you adjust them varies enough that I couldn’t begin to cover all the details here. The goal would be to mimic real-world scenarios as close as possible. One example would be if you have motor specs you can replicate or if you have the ability to do the math to define the appropriate ratio to match the drive rotation and linear speed you’re looking to replicate in your digital twin.
Conclusion
I personally found this useful enough to help me understand the rack and pinion joint, and how it can be used to create this seemingly simple simulation, that I had to share what I learned in case anyone else found it useful.
It all started with me being willing to try something new to see what I’d learn. It also helped to see an AI generated example, which was the key to helping close the gap in my understanding of the joint relationships and in figuring out the math that was a bit over my head.
I highly recommend joining the NVIDIA Omniverse community to see what you can learn there and to ask for help on projects you get stuck on. If you’re already a pro, you can help others who might be stuck!
If you’re interested in learning more about joints in Isaac Sim, check out this video I made where I reverse engineer some examples, which was a helpful foundation for this specific project!
