VR Mech’s Missing Link: The Phone in Your Pocket

In the process of making a homemade Mech Combat game that features robot-like piloted tanks capable of turning the cockpit independent of the direction of movement, [Florian] realized that while the concept was intuitive to humans, implementing it in a VR game had challenges. In short, when the body perceives movement but doesn’t feel the expected acceleration and momentum, motion sickness can result. A cockpit view that changes independently of forward motion exacerbates the issue.

To address this, [Florian] wanted to use a swivel chair to represent turning the Mech’s “hips”. This would control direction of travel and help provide important physical feedback. He was considering a hardware encoder for the chair when he realized he already had one in his pocket: his iPhone.

By making an HTML page that accesses the smartphone’s Orientation API, no app install was needed to send the phone’s orientation to his game via a WebSocket in Unity. He physically swivels his chair to steer and is free to look around using the VR headset, separate from the direction of travel. Want to try it for yourself? Get it from [Florian]’s GitHub repository.

A video is embedded below, but if you’re interested in details be sure to also check out [Florian]’s summary of insights and methods for avoiding motion sickness in a VR Mech cockpit.

This project incorporates a physical element into the VR environment, but there’s neat work being done in the other direction as well; how about spicing up your stationary bike with a VR headset and Google street view data?

10 thoughts on “VR Mech’s Missing Link: The Phone in Your Pocket

  1. I use my Galaxy S6 with VR goggles to fly my quad copter (Phantom 3 Pro) in VR or First Person Video FPV.

    That setup with the Litchi app allows my goggles with the S6 control the quad’s camera.

  2. this is a stroke of genius, we have perfectly capable sensors in our phones, why not use them.
    i am a bit worried about the latency but that would probably be very phone and software dependant.

      1. granted, but i do think there is at least some standardisation, even if accidental or through context, i doubt there is a different accelerometer in every phone, they probably have their goto parts just as any other industry.

  3. I woulda probably glued onto the chair the two Wii nunchuks I won at a thrift shop for $1 apiece and hooked up via ATmega328P to be a 10-axis HID joystick, and then derived rotation from the differential motion. But hey, as long as your phone’s in your pocket then that’s def. clever enough.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s