|
Victor::Set not working
I am sure this is operator error somehow but I don't see it. I initialize a new Victor instance like this:
...
#define CARD_HELICALRAMP 4
#define PWM_HELICALRAMP 3
...
pMotor = new Victor(CARD_HELICALRAMP, PWM_HELICALRAMP);
...
and use it like this:
...
pMotor->Set(fMotor);
...
The pMotor member pMotor is *Victor type and fMotor is a float. The physical output is not updating. No error messages appear on the console. Am I doing something wrong? I know the function is getting called and I know the fMotor value is in the correct range (I put a printf just before the line above).
The Set call is from a different task but that should not matter (I think). This is the only PWM I have declared at this point (no RobotDrive or anything else). Does that matter? I have only one sidecar hooked up to the DIO in slot 4. This is wired to PWM 3. Do I have to start at PWM 0 for some undocumented reason?
Any advice or help is much appreciated!
|