View Single Post
  #12   Spotlight this post!  
Unread 21-02-2010, 09:27
byteit101's Avatar
byteit101 byteit101 is offline
WPILib maintainer (WPI)
AKA: Patrick Plenefisch
no team (The Cat Attack (Formerly))
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2009
Location: Worcester
Posts: 699
byteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of light
Re: potentiometer/ analog inputs

Quote:
Originally Posted by whatabouteve View Post
this could be i will try to fix this.
would printing

printf(" =angletop");
printf("%d",angletop);

would this work in the correct format assuming it prints on line 1 and the %d writes over it?
no, this will output something like this:
Code:
         =angletop23         =angletop85         =angletop712         =angletop465         =angletop84         =angletop6         =angletop4586         =angletop589         =angletop486
i would recommend one printf a loop (if possible): printf("angletop=%d\r\n",angletop);
__________________
Bubble Wrap: programmers rewards
Watchdog.Kill();
printf("Watchdog is Dead, Celebrate!");
How to make a self aware robot: while (∞) cout<<(sqrt(-∞)/-0);
Previously FRC 451 (The Cat Attack)
Now part of the class of 2016 at WPI & helping on WPILib
Reply With Quote