|
Re: Inputs for the Encoder
The example was using C and the C libs, have not tried with C++. The digital inputs were defined in the function call.
if these are defined as 8 & 9 then everthing works,
static const UINT32 ENC_A = 10;
static const UINT32 ENC_B = 11;
In the Initialize function..
StartEncoder(ENC_A, ENC_B);
then in the OperatorControl function is
enc = GetEncoder(ENC_A, ENC_B);
GetEncoder() only returns a 0 or 1 for inputs 10&11 but if the inputs are moved to 8&9 and the code changed to reflect the input change all works.
I think there still might be some issues that need to worked out either in the WPIlibs (C) or in the hardware.
Will try with C++ and see is using inputs 10&11 still have issues
jee7s, Thanks for the above reply,
-pete
|