
29-01-2006, 18:47
|
 |
Programming User
 FRC #1317 (Digital Fusion)
Team Role: Programmer
|
|
Join Date: Jan 2004
Rookie Year: 2004
Location: Ohio
Posts: 1,508
|
|
|
Re: Pwm and pot
Quote:
|
Originally Posted by steven114
Actually, you'd have to do something more like:
Code:
pwm01 = Get_Analog_Value(rc_ana_in01) >> 2;
The controller doesn't sample the analog inputs until you call Get_Analog_Value, and the shift is to convert the 10-bit analog input to the 8-bit PWM output.
|
Yep... my mistake.
__________________
|