paper: Modified Bilbo bang-bang .vi

Thread created automatically to discuss a document in CD-Media.

Modified Bilbo bang-bang .vi
by: Tom Line

A modified version of Bilbo’s bang-bang .vi for labview

A modified version of Bilbo’s bang-bang .vi for labview

Bang Bang (SubVI).vi (18.5 KB)


Care to explain what the modification is and if it is an improvement. I have looked at the subvi, and if your vi is to be placed in the same timed structure, I don’t see a major difference. I see you are going backwards, from the original .vi but not sure what else changed, or improved.

I’m not that strong in labview, so be easy on me if I am missing something obvious.


Hello Scott,
I think I can explain his modifications quite easily.
I messed up in the feedback loop for the Slew Rate Limiter portion. He is sampling it in the correct location.
Additionally, his modifications are set up for a 0 to -1 range for the shooter drive command. Personally, I would have done that modification a different way, but his works, and I don’t argue with success.

Now, I have posted a few different versions, each with different goals.

Are you using the Bang-Bang control? I would love to hear how it is working for you and help you modify it for optimum performance on your robot.

We actually used the built in labview PID control. We only used the PI terms, so it was a PI control. We had 3 closed loop shot selections, 1500 RPM for the fender, 2500 for front of key and 2800 for rear of key. While tuning we couldn’t get one set of gains to work at all 3 set point rpms, so we had to employ a “gain shifter” based on the RPM requested. We also limited the output range between motor values that were expected. This also gave it some “Feed forward” as the PID was limited to a range that was expected. We tried a couple of other methods, but this method gave us the best response. We did not try the bang-bang method, but looking at trying it, as it would eliminate some different pid code between autonomous and teleop.

We are planning on doing some off season events, so looking to try this method and see how it performs.

I always thought the pid was overkill, but at the 1500 rpm we saw deviations in the +_50 rpm range. From what I read, it sounded like the bang-bang gave tighter control than what we saw with pid.

So Tom, did you get it working well, I take it?

According to this post, they got it working but felt they had better control with their PID version.