{"action":"closed","issue":{"url":"https://api.github.com/repos/SwerveRobotics/ftc_app/issues/19","labels_url":"https://api.github.com/repos/SwerveRobotics/ftc_app/issues/19/labels{/name}","comments_url":"https://api.github.com/repos/SwerveRobotics/ftc_app/issues/19/comments","events_url":"https://api.github.com/repos/SwerveRobotics/ftc_app/issues/19/events","html_url":"https://github.com/SwerveRobotics/ftc_app/issues/19","id":108423210,"number":19,"title":"Discontinuities in IMU heading","user":{"login":"IronReignRobotics","id":6445257,"avatar_url":"https://avatars.githubusercontent.com/u/6445257?v=3","gravatar_id":"","url":"https://api.github.com/users/IronReignRobotics","html_url":"https://github.com/IronReignRobotics","followers_url":"https://api.github.com/users/IronReignRobotics/followers","following_url":"https://api.github.com/users/IronReignRobotics/following{/other_user}","gists_url":"https://api.github.com/users/IronReignRobotics/gists{/gist_id}","starred_url":"https://api.github.com/users/IronReignRobotics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IronReignRobotics/subscriptions","organizations_url":"https://api.github.com/users/IronReignRobotics/orgs","repos_url":"https://api.github.com/users/IronReignRobotics/repos","events_url":"https://api.github.com/users/IronReignRobotics/events{/privacy}","received_events_url":"https://api.github.com/users/IronReignRobotics/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-09-25T23:26:46Z","updated_at":"2015-09-27T03:27:55Z","closed_at":"2015-09-27T03:27:55Z","body":"First thanks for sharing your whole codebase and approach to extending ftc_app.  We tried it out a few weeks ago, but since the imu code was broken we set it aside for a while.  Now we are trying your recent updates and getting actual heading values.  But we are seeing discontinuities in the Euler angle outputs.  I'm not talking about gimbal lock.\r\n\r\nFor example, if the heading is nearing 320 degrees (normalization turned off) as we are rotating counter clockwise, the instant we go below 320 degrees we start getting small negative angles for the next 8 degrees of rotation.  So at 316 degrees of rotation it will actually be reporting -4 degrees and at 313 degrees, -7.  It returns to the absolute range when we cross over to 312 degrees.\r\n\r\nThere are multiple such discontinuities, in fact the pattern seems to be that for every multiple n of 16 degrees, the highest 8 degrees in the range are reported as x = n*16 - actual heading, while you get the actual heading in the lower half of the range.\r\n\r\nHave you seen this?  Or is this more likely evidence of a faulty sensor?  \r\n\r\nAlso looking forward to your next version integrating the national teams latest changes.  I see you've made headway on the merge in your mentors branch.\r\n\r\nThanks."}}