Buying a phone, which one has best tracking? Nexus 5 or M8?

Official forum for open source FreePIE discussion and development.
Post Reply
Elwood
One Eyed Hopeful
Posts: 22
Joined: Mon May 12, 2014 7:51 am

Buying a phone, which one has best tracking? Nexus 5 or M8?

Post by Elwood »

From what I've read in this forum, Nexus 5 has almost perfect sensor readouts - is that correct?

Is the HTC M8, (which I believe Cybervillain has), as good as the Nexus 5?

And has anyone tried the LG G2 with Freepie?

Thank you!
CyberVillain
Petrif-Eyed
Posts: 2166
Joined: Mon Jun 22, 2009 8:36 am
Location: Stockholm, Sweden

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by CyberVillain »

I must admit that I havent used my M8 that much with actual gaming. Funny you should ask though because I just started testing it yesterday because I want to play Alien Isolation in a more VR like way. I have only created the script so havent tried it more than just getting the script to work (No actual gameplay), with raw data and sensor fusion in FreePIE it works very bad, if the phone is not flat relative to the horizon the YAW readout is totaly wrong. The onboard google sensor fusion seems ok, will try to actual play with that more tonight and can report back.

I use a rubberband to attach the phone to a USB gamepad (Together they act as crude weapon/body tracking device), so I do not use the M8 for headtracking, the difference is the orientation of the phone. In other words I do not know how the phone responds if you try to use it like a HMD

My script

Code: Select all

def update():          
    x = filters.deadband(filters.delta(math.degrees(filters.continousRotation(android[0].googleYaw))), deadband)
    y = filters.deadband(filters.delta(math.degrees(android[0].googlePitch)), deadband)
    
    if enabled:     
        mouse.deltaX = x * multiply
        mouse.deltaY = -y * multiply
        
if starting: 
    deadband = 0.01
    multiply = 12
    android[0].update += update
    enabled = True
    axisDeadband = 200        


enabled = not joystick[0].getDown(3) #Used to disable mouse so that you can correct for drift(Not much with M8 and google fusion)
mouse.leftButton = joystick[0].getDown(7) #Fire
mouse.rightButton = joystick[0].getDown(2) #Aim down sights
keyboard.setKey(Key.Space, joystick[0].getDown(5)) #Motion tracker
keyboard.setKey(Key.F, joystick[0].getDown(1)) #Crouch

keyboard.setKey(Key.Y, joystick[0].zRotation < -axisDeadband) #Forward
keyboard.setKey(Key.H, joystick[0].zRotation > axisDeadband) "Backward

keyboard.setKey(Key.G, joystick[0].z < -axisDeadband) #Left
keyboard.setKey(Key.J, joystick[0].z > axisDeadband) #Right
Elwood
One Eyed Hopeful
Posts: 22
Joined: Mon May 12, 2014 7:51 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by Elwood »

Thank you for the answer, looking forward to your further tests!

I wonder if it is a software or hardware issue that causes the tracking to be off on so many phones. My S3 was a disaster.
konstantin_lozev
Cross Eyed!
Posts: 192
Joined: Fri Jul 04, 2014 1:43 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by konstantin_lozev »

Hi, I have been experimenting somewhat and the best and easiest way to try if your phone's IMU is OK hardwarewise, is to try some of the official Durovis Dive demos.
Elwood
One Eyed Hopeful
Posts: 22
Joined: Mon May 12, 2014 7:51 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by Elwood »

Indeed the Dive apps were showing plenty of drift with my S3.

But I don't think that I will be able to install any apps at the shop :)

So, I'm asking about other people's experiences.

@Cybervillain: did you get the chance to test the HTC M8? How did that go?
CyberVillain
Petrif-Eyed
Posts: 2166
Joined: Mon Jun 22, 2009 8:36 am
Location: Stockholm, Sweden

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by CyberVillain »

I would say its decent you need to correct for drift now and then (I have added a button that disables mouse emylation so that you can move the device to the position in game and then resume tracking). But I think mouse controlled games are pretty shitty for this type of controllers.

I will will play around with Arma if I get time with two phones, problem is torso/body and weapon are not seperate controls even in arma.

Games should have 3 controls, one for body/torso one for weapon and one for head
NoxWings
One Eyed Hopeful
Posts: 44
Joined: Thu May 15, 2014 8:04 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by NoxWings »

CyberVillain wrote:Games should have 3 controls, one for body/torso one for weapon and one for head
I completely agree ^^.

Independent Walking-Looking-Aiming(hand based) thats the VR key. Even if you are not going to use them all separately because the game could be played with a gamepad too, you can still fake them to be fixed like in a regular game.
Elwood
One Eyed Hopeful
Posts: 22
Joined: Mon May 12, 2014 7:51 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by Elwood »

I finally decided to go for a LG G3 due to the screen resolution, because I like tinkering with VR and reading comics ;). The screen is really great, and still looks kinda like a screen even thru the 7x 35mm lens i put in my Dive. On the S3 (Amoled 720p) I could literally count the R G B cells;).

I think that the market Occulus version will have to be equipped with

As for the tracking, it's kind of mixed... it does not track the most important axis -horizontal turning angle- good enough (in the HMD position), there is plenty of noise and it likes to bounce back a lot after fast movements. That is most unfortunate, since the other readouts -vertical angle and roll- are much better. So in the end I had to filter the input a lot, just like with the old S3... so all the subtle movements are out of the question.

I guess I'll have to stick that Wiimote on top of my head after all (and look really, really stupid) ;)
konstantin_lozev
Cross Eyed!
Posts: 192
Joined: Fri Jul 04, 2014 1:43 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by konstantin_lozev »

Elwood wrote:I finally decided to go for a LG G3 due to the screen resolution, because I like tinkering with VR and reading comics ;). The screen is really great, and still looks kinda like a screen even thru the 7x 35mm lens i put in my Dive. On the S3 (Amoled 720p) I could literally count the R G B cells;).

I think that the market Occulus version will have to be equipped with

As for the tracking, it's kind of mixed... it does not track the most important axis -horizontal turning angle- good enough (in the HMD position), there is plenty of noise and it likes to bounce back a lot after fast movements. That is most unfortunate, since the other readouts -vertical angle and roll- are much better. So in the end I had to filter the input a lot, just like with the old S3... so all the subtle movements are out of the question.

I guess I'll have to stick that Wiimote on top of my head after all (and look really, really stupid) ;)
Hi, Elwood, I think what you describe looks like IMU data from the accelerometer, rather than the gyro. With accelerometers, they measure confidently pitch and roll, since they measure the force of gravity which is transferred from one axis to the other. This does not hold for yaw and there you get the noise and all bouncing back problems.
Maybe it's the phone's fusion...
Elwood
One Eyed Hopeful
Posts: 22
Joined: Mon May 12, 2014 7:51 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by Elwood »

I use the "android[0].googleYaw" etc method. Will try later with the "non-google" commands but if I remember correctly, they were even worse on my S3 than the "google" stuff, so I'm not expecting much improvement here.
konstantin_lozev
Cross Eyed!
Posts: 192
Joined: Fri Jul 04, 2014 1:43 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by konstantin_lozev »

Elwood wrote:I use the "android[0].googleYaw" etc method. Will try later with the "non-google" commands but if I remember correctly, they were even worse on my S3 than the "google" stuff, so I'm not expecting much improvement here.
Do you get the same behavior with the Dive demos?
Elwood
One Eyed Hopeful
Posts: 22
Joined: Mon May 12, 2014 7:51 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by Elwood »

I've recently found out that I have been using a faulty script all along. Due to bad indentation, it was - let's say - resetting itself on every loop.

With that out of the picture, the LG G3 can be called a "decent" tracker, and the S3 is still just as bad as it was before. So to anyone considering buying a G3 and use it with Freepie, it's OK-ish. Far from perfect, there is some drift, but I suppose it's just what an average android phone is going to give you.
CyberVillain
Petrif-Eyed
Posts: 2166
Joined: Mon Jun 22, 2009 8:36 am
Location: Stockholm, Sweden

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by CyberVillain »

Yeah, that is dangerous, we could check that a subscriber only add it self one time, but it will hog some perforamnce etc
konstantin_lozev
Cross Eyed!
Posts: 192
Joined: Fri Jul 04, 2014 1:43 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by konstantin_lozev »

IMO pitch drift should not be present in any IMU that has gyros and accelerometers. The accelerometer gives you a comstant reference frame of the earth's gravity, so no drift allowed.
CyberVillain
Petrif-Eyed
Posts: 2166
Joined: Mon Jun 22, 2009 8:36 am
Location: Stockholm, Sweden

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by CyberVillain »

Thats not even true for military grade sensors, its far from true with consumer sensors. If the signal from the accelerometers was perfect we could use the integrated value for position tracking
konstantin_lozev
Cross Eyed!
Posts: 192
Joined: Fri Jul 04, 2014 1:43 am

Re: Buying a phone, which one has best tracking? Nexus 5 or

Post by konstantin_lozev »

Maybe I did not explain myself correctly, sorry for that. The accelerometers have a flaw which is noise, gyros have a flaw which is drift. Accelerometers do not drift, so they can be used to correct the pitch drift over time. Therefore, excessive pitch drift beyond the accelerometer noise is not acceptable with a good fusion algorithm.
The thing is, the accelerometer readings do not even need integration (unlike gyros). With a wiimote, you can derive the pitch for a limited scenario (with a few assumptions) simply from aSin(wiimote.gz) and I guarantee that will not drift over time, but it will twitch now and then by around 0.02 rad (which is the noise).
Post Reply

Return to “FreePIE”