FIRST Robotics Competition Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Programming question

We are getting set to travel to

our first Regional and are furiously trying to make our kicker work.  We are going with a mechanical solution which involves setting up a fifth CIM to run the kicker.  The problem is that in the begin.vi, there is no place in the merge errors.vi to attach the error out wire for the motor.  I opened it up and added a fourth error in in the front panel and it is reflected in the block diagam.  However, when I return to the begin.vi to hopefully wire out the error wire, it doesn't exist.

Would someone enlighten me?  I am just about ready to put my head under a drill press and lobotimize myself......

0 Kudos
Message 1 of 3
(4,591 Views)

Hi fhobart,

The reason you can't find the additional input that you've created for the Merge Errors VI is because you didn't create a terminal for it. I've included instructions on how to create the additional terminal below if you're interested. However, unless you've already done this, I would like to point out that you'll need to adjust the code in the block diagram to handle this additional error input. The easier thing to do would be to expand the Build Array VI in the Begin VI to include an extra input and wire the error wire from your motor to it.

To add an additional terminal to a connector pane:

- From the front panel of the Merge Errors VI right click on its icon in the top right corner and select Show Connector.

- This should now show you the available terminals that you can add your extra terminal to.

- Select an empty terminal and then click on the additional input/output. The terminal that you have selected should now be the same color as the datatype of the control/indicator.

- Save the VI and in the Begin VI, right click the Merge Errors VI and select Relink To SubVI

0 Kudos
Message 2 of 3
(2,655 Views)

Just note that later if you update the LabVIEW your modifications to the Merge Errors vi most likely will be over written and set back to the original.

It is not advisable to modify the built in functions.

I would not modify the Merge Errors.vi.

1. What you could do is use more than one Merge Errors.vi (3) and chain outputs together narrowing the output down to a single Error data line.

or

2. Feed all the error out of your vis into a Build Array node and then feed the Error Array into the "error array in" of the Merge Errors.vi (low left input).

Omar
0 Kudos
Message 3 of 3
(2,655 Views)