02-26-2020 07:20 AM
I’ve placed code in Test.vi but whatever I place in there and try to control stutters.
The biggest example is my solenoid. After a few seconds of having test enabled the solenoid clicks as it goes on and off.
Also both motors stutter as they seem to get set to my Winch Power value but then get set to zero then back to being fed back a value.
Not sure what is happening.
The "Winch 1" and "Winch 2" are Talon SRX and operate normally in Teleop.
The Solenoid is a single solenoid.
All are opened in Begin and I have disabled the Safety on all of them (thinking that might be the issue).
They are not referenced at all in Periodic Tasks.
Thing is I took out all of my motor and solenoid control from periodic tasks earlier this season as I saw this same behavior happening in PT.
02-26-2020 10:33 AM
Have you tried interactive execution (click the run arrow in the Robot Main.vi) and using the LabVIEW debugging tools to see what values you are sending to the outputs in that VI?
02-26-2020 10:51 AM
I can try that but the focus here is on the solenoid. All that should be happening is that an "ON" signal should be being sent to the solenoid constantly. There are not variables involved or other logic.
Yet the behavior of the robot is that the solenoid clicks as it is cycling on and off rapidly.
The only other code that should be executing while Test is enabled is Periodic Tasks and no solenoids are even references in my Periodic Tasks so I cant think of any other code that would be fighting Test Enabled code.
02-26-2020 11:00 AM
Create a new project from the LabVIEW roboRIO template; open your solenoid in Begin.vi; add your loop in Test.vi; put the Solenoid "On" in said loop. Run the code. Do you still see the same behavior?
If yes, my next step would be to try with the example that ships with LabVIEW in Help > Find Examples..
If no, I suspect there is another place in your code where the solenoid is being called.
Regards,