Announcement

Collapse

Technology Forum Has Moved!

The FIRST Tech Challenge Technology forum has moved to a new location! Please take a look at our forum blog for links and instructions on how to access the new forum.

The official blog of the FIRST Tech Challenge - a STEM robotics programs for students grades 7-12.


Note that volunteers (except for FTA/WTA/CSA will still access their role specific forum through this site. The blog also outlines how to access the volunteer forums.
See more
See less

Issues Turning Using IMU

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Thanks GearTicks abd KernelPanic for the help! Using some of the code we had and combining it with bits and pieces of what you suggested we have a robot that is now accurately turning using the IMU. Thanks again for all of the help!

    Comment


    • #17
      Originally posted by GearTicks View Post

      You can definitely make these calculations smaller and simpler. The remainder and sign operations are very handy.
      Code:
      [FONT=courier new]    double delta = (tarH - currH + 540) % 360 - 180; //gets delta in the range -180 to 180[/FONT]
      Nice! Will play around with that. Thanks!
      Mentor, teams 8578 & 11959

      Comment

      Working...
      X