View Single Post
  #3   Spotlight this post!  
Unread 09-05-2013, 03:20
Azrathud's Avatar
Azrathud Azrathud is offline
Computer Nerd
AKA: Bryce Guinta
FRC #2945 (BANG)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2010
Location: Colorado
Posts: 24
Azrathud is on a distinguished road
Re: Here's Some Sensor Test Code for the Gyro & PID, Accelerometer, and Magnetic Enco

Quote:
Originally Posted by joelg236 View Post
From what I saw, it looks like these basically just log the values. Any reason you use a separate project just for logging a sensor's value instead of just putting it in your normal code?
All of them are basically logging values, except for the Gyro rotation one; just logging values may seem easy, but actually knowing what classes and methods to use is kind of time consuming to figure out without examples. WPILIB doesn't do a very job describing the behaviour of classes and its methods, and I needed to know if the . Basically I needed to see what the output was to get.

Just using these classes with my actual robot code would have been be next to impossible this year if I didn't write some(very basic) test to code to verify that the device was indeed correctly wired, and to see what the output looked like.
Reply With Quote