Handsfree Omnidirectional VR Motorcycle Simulation

A prototype handsfree SteamVR simulation created in Unity for testing weight distribution and wearability of custom VR helmet(s). The user controls the speed and direction of a virtual motorcycle using the gyroscopic sensor in a Vive VR headset or cell phone via RiftCat. Developed for and in collaboration with Cyreana Foulk and Chris Foulk.

Leap Motion (Ultraleap) – Unity Hands

Testing Leap Motion controller for hand tracking and hand physics inside the Unity editor (play mode). Deploying to HoloLens 2 takes a few minutes each time and a specific process to prevent errors. Less deployments is better, especially if you just want to tweak something small.

Rocco – 2019 Update

Still working on this guy… sorry no video at this time. He was assembled enough to execute some motion presets that I added to the code, but there are some interference issues and possibly one or two servos that don’t work quite right. I took him back apart to work on shielding but got pulled off the project for a while. So close to getting back to the code.

Partially Assembled

Circuit Diagram v8 (WIP)

Alive! Well, the light is on…

Mostly Assembled

Servo Hook-Up Board – Bottom

Servo Hook-Up Board – Top

Servo Hook-Up Board – Side

PC Power Supply with Voltage Regulator (Arduino wants 7-12V, I gave it 9V)

Rocco – Controls and Connection


The videos below are demonstrations of the potentiometer and a few other commands.  The potentiometer controls the interval value when turned left or right (as does “i##”).  You can also see some examples of the other commands that Rocco accepts as input in the first video.  I am pasting a sequence of motion pre-sets while using the potentiometer to change his movement speed.

“[” or “]”   |   Increase/decrease servo speed – Rocco continues executing a motion every “servo_speed” milliseconds until motion is complete

“s###”   |   Set a three digit servo speed (default is 25ms, maximum 999ms)

Hardware potentiometer   |   Increase/decrease servo_interval – Rocco moves each servo “servo_interval” number of degrees until executed motion is complete

“i##”   |   Set a two digit servo interval (default is 32 which is the maximum value)

“p”   |   Toggle usage of potentiometer for reading the servo interval (potentiometer is used by default)

“j##”   |   Select a servo using a two digit servo number

“,” (the “<” key)   |   Select previous servo

“.” (the “>” key)   |   Select next servo

“k”   |   “Knock” selected servo (move +5 degrees then -5 degrees just to see which servo is selected)

“a###”   |   Set the angle of current servo, requires three digit angle (add leading zeros if necessary)

“g”   |   Get angle of selected servo

“m##” (00-08 currently)   |   Execute pre-coded motion

“+”   |   Selected servo plus 5 degrees

“-”   |   Selected servo minus 5 degrees

“d”   |   Disconnect selected servo (reset required to reconnect)

“r”   |   Reset


I am using an HC-06 Bluetooth serial module for wireless control.  It accepts 3.6 – 6V and I’m using 5V from the Arduino.


The transmit/receive pins should be wired as follows:

Arduino “TX0” -> HC-06 “RXD”
Arduino “RX0” -> HC-06 “TXD”

Other markings on the module:  JY-MCU, BT_BOARD V1.06

The HC-06 is a slave device only and cannot start communication on its own (it cannot be paired with other Bluetooth modules, only “masters” like a computer or smart phone)

I am using the Real-Term application to connect to the module, which can be downloaded here:

Real-Term is also referenced on the page below, which is a good source of information on serial communication in general:

Below is an example of how to connect to the HC-06 module using Real-Term:

Baud: 9600 (this value should match what is coded in the Arduino)
Port: “6 = \BthModem0” (you can find which COM port HC-06 is using in Windows 7 by “Devices and Printers”, “HC-06”, “Hardware”)
Parity: None
Data Bits: 8
Stop Bits: 1
Hardware Flow Control: None
Press “Change” to connect

I am also able to connect to the Bluetooth module using my Nook tablet and the “Bluetooth Terminal” application.  Any Android tablet will work, but iPads and iPhones will not as they don’t support this kind of connection.

Additional links:
(if the link breaks just search for “a child’s guide to basic two way bluetooth” – that is how the document is titled)

Rocco – Circuit and Arduino

Servo Power Supply

I had a left over power supply with a molex connector on the end that can put out 5V @ 2A or 12V @ 2A.  I am using it at 5V to independently power the servos collectively.  I also re-purposed a female molex to 2-pin adapter to get the power to the breadboard.

I am not sure yet how much current these servos draw.  I only know that 2A is enough because, well, I tried it.  I tried to measure this with my multimeter but could not get a valid reading.  I later discovered most multimeters can’t read servo current.

Below are two possible explanations (they may be the same) and a discussion about idle and stalled current draw:

I will find a way to measure before adding more servos or planning a battery system.


I ordered a SunFounder breadboard kit with jumper wires and some other components for testing.

SunFounder Kit:

I haven’t made a schematic yet for how I have the board and servos wired up.  I would like to make one in Fritzing but for now, here are some photos:

I’m using the potentiometer from the SunFounder kit to increase/decrease an interval value in the code.  I’m also using a switch from the kit to enable/disable an HC-06 Bluetooth module.

Bluetooth serial module:

Fritzing circuit design tool:

Lastly, I am using some servo extension cables to give myself some room to work.

Futaba / JR Style Servo Extension Leads:


I chose an Arduino Mega 2560 R3 for the main board.  I’ve never used an Arduino before so this is exciting.  There are dedicated products for controlling servos and pre-programming motions, but I’m currently putting an emphasis on coding as much of this project as possible.  The Mega has enough pins to control (but not power) all 18 servos.  I’ve read there may be problems with interrupts or “bandwidth” when trying to control all 18, but I’m still going to try.  If it doesn’t work out I’ll look at adding hardware to the project.

I like this board:

This one I feel is cheating:

The Arduino can be powered with a wide range of supplies, but I am using a generic 9V DC 650mA supply from Amazon.

Arduino Safety

Knowing nothing specific about Arduino boards or dev boards in general, I looked up what kinds of things can break it (so that I don’t do those things).

10 Ways to Destroy an Arduino:

Rocco – Frame and Parts

Rocco was designed in Tinkercad.  The model can be found here:  https://tinkercad.com/things/i91TkKbNDc9

It should not be printed to a 3D printer currently because the holes don’t line up quite right.  When I started assembling the first leg I had to widen most of the holes and even move some of them.  This is possibly because the servo dimensions aren’t exact.  I will try to fix the model when I build the rest of the legs.

Below is a description of all the materials and components currently used to make the robot.

Drill Bits

Any drill bits meant for plexiglass will work, but these are the bits I’ve used:

R&H 3/16″ Plexiglass Acrylic & Lexan Drill Bit

1/8″ Drill Bit for Plastic

5/64″ Carbide Small-Diameter Drill Bit
(M2’s actual outer diameter is 1.9mm = .0748in = use 5/64)

3/32″ Carbide Small-Diameter Drill Bit
(M2.5’s actual outer diameter is 2.4mm = .0945in = use 3/32)


You can order acrylic sheets anywhere, but I have a lot left over from prior projects.  I have previously ordered them from U.S. Plastics.  You can cut plexiglass by scoring it repeatedly with a box cutter along a heavy straight edge.

Acrylic Sheet 24″ x 24″ x 1/16″ (.060) Thick

Plexiglass Cuts

18 @ 20mm x 100mm – mid-leg and outer leg lengths (shared size)
6 @ 10mm x 132mm – longest leg pieces
12 @ 10mm x 42mm – knee servo side mounts
18 @ 10mm x 32mm – knee servo top and bottom mounts
12 @ 35mm x 35mm – hip top and bottom plates
6 @ 12mm x 35mm – hip mid-panel
2 @ ? – hexagonal body top and bottom (no exact dimensions currently)
Other – there may be other plexiglass cuts added later

Wood Block

I needed some spacing material to fill an area in my design and provide support.  I also needed to be able to cut it by hand, so I just got a stick of wood from the hardware store.

6 @ ~27mm x ~22mm x ~11mm (length, width, height)

The wood is then cut to an “L” shape.  I’ve only made one so I’m not sure how much I cut out.  Let’s just call it “some”.

Frame Hardware

I designed the mounting hardware solution around getting as many of the components as I could from one place.

I was able to do this such that I got everything from McMaster-Carr.  Most of the components are shown to the right:

According to the link below, the “spline screw” that fits in the center of the servos I’m using (TowerPro MG90s) is an M2.5 size.  I needed longer screws than the ones that were supplied so that I could put plexiglass between the screw heads and the servos.


I also needed some threaded rod that I could cut to specific lengths using a dremmel.  The threaded rod and the the metal hex nuts for it are the heaviest parts of the mounting hardware but it is necessary to keep the hip/shoulder “square” and keep it from flexing.  To keep the weight down, almost all the mounting hardware is nylon.

Metric Pan Head Phillips Machine Screw
Black-Oxide 18-8 Stainless Steel, M2.5 Size, 8mm Length,.45mm Pitch

Type 316 Stainless Steel Fully Threaded Rod
M2 Thread, 0.4mm Pitch, 1 Meter Long

Type 18-8 Stainless Steel Thin Hex Nut – DIN 439B
M2x0.4 Thread Size, 4mm Wide, 1.2mm High

Metric Nylon Pan Head Phillips Machine Screw
Black, M2 Size, 16 mm Length, 0.4 mm Pitch

Nylon 6/6 Hex Nut
M2x0.4 Thread Size, 4.2mm Wide, 1.5mm High

Nylon Flat Washer
M2 Screw Size, 2.2mm ID, 5.0mm OD

Rocco – Servos

At first I thought I was going to get full size servos for this project, but the lowest price I saw for those was around $10 per servo, which would have added $180 to the project before it even got started.  I did not want to make that kind of commitment never having worked with these components before.  I did a lot of research and have tried to summarize it below.

Here is a look at the current outcome of having chosen metal geared MG90s micro servos:


Cost/Quality – Servos are another type of purchase where you get what you pay for.  I feel like the choice was sort of “expensive” vs. “disposable”.  There are also robotics grade servos, but those were definitely out of the question.

Gear Type – I wanted the more expensive metal geared servos instead of plastic so that the gears don’t strip/slip under the weight of the robot. I’ve heard these can get hot but I can’t test that yet.

Brands and Models – I’ve heard Hitec and Futaba are the better brands.  Many people have strong negative and positive opinions about brands and models of servos.  This is in part due to the fact that the market contains a lot of knock-off products and a lot of servos with really bad quality control.  Many arrive faulty or fail quickly.  On top of that, I found most of the discussion about servos seems to center around keeping expensive RC planes and helicopters in the air.  As I understand it, there are also a lot of issues with online hobby shops holding people’s money hostage while they obtain their stock from overseas.  Lastly, using servos to carry the weight of a robot is an inherent abuse of their design.

Physical Size – Standard size servos with metal gears cost too much to be “disposable”, and I didn’t want to spend enough to get a quality brand/model at that size.  I chose the micro size instead.  The micro servos are lighter and use less power too.

Voltage and Torque – For testing I was able to power one servo using the Arduino, but it definitely can’t power 18 of them.  I don’t know how many it can power safely, but I think the answer is very few.  The more voltage you supply to a servo (within its specified range), the greater its torque (strength).  Torque is one of the more important factors for walking robots since they need immediate and constantly available support for their weight.  Running servos at their maximum voltage will wear them out quicker though, so I chose to run mine at 5V which is in between their minimum and maximum values.

Accuracy – I’m actually minimally concerned with this, as I want my robot to have a little personality anyway.  I plan to accommodate for any detrimental imprecision with code wherever possible.

Practicality – I wondered was it even practical to use micro servos?  They’re not famous for doing heavy lifting.  It turns out yes!  There aren’t as many examples of these in use, but some of my favorite robots are using them.  Sometimes they are a little shaky in certain positions, but I will try to design and code around that as well.


Pretty much my favorite robot:

Amazingly fast and very smooth:

I think this one is a kit:

Nylon geared:


Given the quality issues, I assume I will be replacing servos periodically, so being able to return them and get new ones quickly and cheaply is my main concern.  With hobby shops and eBay ruled out, I ignored a lot of negative comments about the TowerPro MG90s and ordered it anyway because it was the only servo that met the requirements AND could be ordered via Amazon Prime for $5 per servo.

TowerPro MG90s Micro Servo Specs:

Dimensions: 22.8 x 12.2 x 28.5mm

Operating Speed (4.8V no load): 0.1sec / 60 degrees
Operating Speed (6V no load): 0.08sec / 60 degrees

Stall Torque (4.8V): 1.8 kg / cm
(also seen listed as 2.2 kg / cm)

Stall Torque (6V):   2.2 kg / cm
(also seen listed as 2.5 kg / cm)

Temperature Range: -30 to +60 Degree C

Dead Band Width: 5usec
(also seen listed as 2usec)

Operating Voltage: 4.8 – 6.0 Volts

Weight: 13.4g
(also seen listed as 13g)


Types of Servos and How They Work

Tips for reducing servo failure: