Search Unity

  1. Are you interested in providing feedback directly to Unity teams? Sign up to become a member of Unity Pulse, our new product feedback and research community.
    Dismiss Notice

Help Wanted Physical steering with gyroscope

Discussion in 'Android' started by FeboGamedeveloper, May 14, 2021.

  1. FeboGamedeveloper

    FeboGamedeveloper

    Joined:
    Feb 2, 2014
    Posts:
    45
    Hi, I have a gyro problem.

    I have physical steering to which a mobile phone with a gyroscope is connected. When you turn the steering wheel, your mobile also turns. Obviously, the steering always does the same type of movement so the mobile phone also does the same type of movement (symmetrical with respect to the center of the steering). I need to find through the gyroscope a function that in the game gives me a number between -45 (the steering is turned completely to the left) and 45 (the steering is turned completely to the right) that tells me the rotation of the steering.
     
  2. vagelis199

    vagelis199

    Joined:
    Jul 27, 2012
    Posts:
    102
    Normalize the values to 45 degrees
     
unityunity