Unreadable Device Acceleration/Rotation/Gravity

As the title suggests, getting a mobile device’s acceleration, rotation and gravity is not possible.

UserInputService’s properties AccelerometerEnabled and GyroscopeEnabled return false. Using GetDeviceAcceleration or the other functions return an InputObject with its Position and Delta as 0, 0, 0.


Confirmed on two different phones:

  1. OnePlus 3 running Resurrection Remix based on Android 7.1.1
  2. Samsung Galaxy Note 4 running Android 6.0.1

Here’s a place for you to test your device’s accelerometer: https://www.roblox.com/games/604256335/mobile-test


edit: Everything seemed to work fine before the servers had issues.
edit2: might be stupid, we’ll see in a few minutes
edit3: Okay, suddenly everything started working again.
edit4: no
edit5: Ehm, okay. The getter functions started to work once I created a separate TextLabel and a LocalScript with this running this:

local UIS = game:GetService("UserInputService")
UIS.DeviceAccelerationChanged:connect(function(Acc)
	script.Parent.Text = tostring(Acc.Position)
end)
1 Like

I can also confirm this on Samsung Galaxy S7, however it works fine on my iPad (forgot its number). It seems to be an Android problem.

I was wondering why the steering in my racing game just didn’t work for my Android, I noticed this about 3 weeks ago? but thought maybe it was something with my code but didn’t really look into it as I had stopped working on the game a long time ago.

Seems same issue as here (in July):

It works when you connect to the event because:

In the same thread it’s mentioned a fix would go out for it though, but maybe that hasn’t happened.

cc @darthskrill, could you shine some light on the matter :slight_smile:

Quoting also gives a notification btw :smile:

1 Like