03-04-2016 02:49 AM
Hi,
I am trying to make a VI for programming a motor to use on a robot. The thought behind this VI is to make the motor turn with x degrees, and then wait for a new degrees signal. It works fine for degrees greater than 0 (positive). But when I try to go to negative values or zero it just oscillates around the desired degree.
This VI uses some VI's for the motor drive, so it may be difficult to understand perfectly.
Vegard
03-04-2016 07:37 AM
@Vegard123 wrote:
This VI uses some VI's for the motor drive, so it may be difficult to understand perfectly.
Vegard
Even harder to understand when these vis are not attached. From the rest of the code what I can see if that if you set degrees to -1 and speed to 70 the value of s?t:f (what does this represent? You should give significative names to indicators) will be negative. Is it a negative feedback value that causes instability? Have you tried setting a speed value of less than 64 to get a positive feedback value?
Ben64
03-07-2016 02:14 AM
Hi,
I think the solution to this problem were to set a desired deviation, ie 3% instead of taking percentages of the desired degree value. When the degrees come closer to zero, the accepted offset in degrees are a lot smaller than it is at larger degrees.