FIRST Robotics Competition Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Build Error - vi with bad block diagram

My team is having an error whenever we build a project/application before we send it to the cRIO. It runs through the process and when it gets to the end, it gives back an error message saying that the build was unsucessful. The error code is something like 2015, maybe (I'll find out later and update this)? It says it can't use a broken VI with a missing block diagram. The place the error occurs at is long and odd, but there is something like CloseReference.vi in it.

For this reason I deleted all the Close VIs in our program that were left over from the default project (we don't use them anywhere else). This did not solve the problem, though.

One thing to note is that this is a project that was copied over from another one. We wanted to change our test code into our final robot code, so we made a new project with the correct name, copied the telop and begin VIs (overwriting the default ones) and re-directing them to the new ones when LabVIEW tried to open them. However, our old test code now has this same problem, so it's probably something universal. We will try a blank project next.

Another interesting thing is that it will temporarily deploy (running it with the Run button).

I've posted this on Chief Delphi too.

Thanks for any of your replies!

0 Kudos
Message 1 of 7
(9,235 Views)

Hi,

When you deleted the close reference VI's did you get the same error message about a broken VI with a missing block diagram or did you get a different message?

Can you post a screenshot of the error message(s)?

Do have any problems building the default robot code?

~Olivia

0 Kudos
Message 2 of 7
(3,213 Views)

Sorry it took so long to reply, I never got to it.

Fortunately the problem has seemed to solve itself. The one large thing that we did was to image the cRIO, but that's not really related to the code on the computer so I don't think that was it. I did try a blank project and that worked, and since then has worked everywhere else too. Maybe building an unmodified project made LabVIEW realize that the VI didn't have a bad block diagram.

Should I still post the error? I have it copied down...

0 Kudos
Message 3 of 7
(3,213 Views)

Hi,

I'm glad you're able to build your code now. I have to admit that it does seem odd that it happened in the first place and that reimaging seemed to help.

You can post the error if you like. We welcome any feedback and it could help anyone else that might have seen the same thing.

0 Kudos
Message 4 of 7
(3,213 Views)

When you copied the project and manually overwrote some of the VI's I believe you created issues where your were still using code from the old project. I would be very careful removing all of the Close Ref.vi calls from your system. These are used to clean up resources. By not using them you will most likely encounter a resource issue since your system is never cleaning up unused references and resources.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 5 of 7
(3,213 Views)

Alright, here is the error.

I know it's not exactly right, but I delete all the close VIs because they never get used anyway. There's never a finish VI or something like that, the robot will always just get turned off. Correct me if I'm wrong, but that's my view.

Error Received When Building Project:

An error occurred while saving the following file:

C:\Users\CHS Robotics\Documents\All My Documents\Programming Code\2010 Programming Code\2010 Robot Code\Teleop.vi

Invoke Node in AB_Source_VI.lvclass:Close_Reference.vi->AB_Build.lvclass:Copy_Files.vi->AB_Application.lvclass:Copy_Files.vi->AB_Build.lvclass:Build.vi->AB_RTEXE.lvclass:Build.vi->AB_Engine_Build.vi->AB_Build_Invoke.vi->AB_Build_Invoke.vi.ProxyCaller

<APPEND>

Method Name: <b>Save:Target Instrument</b>

Details:

Visit the Request Support page at ni.com/ask to learn more about resolving this problem. Use the following information as a reference:

Error 1502 occurred at AB_Source_VI.lvclass:Close_Reference.vi -> AB_Build.lvclass:Copy_Files.vi -> AB_Application.lvclass:Copy_Files.vi -> AB_Build.lvclass:Build.vi -> AB_RTEXE.lvclass:Build.vi -> AB_Engine_Build.vi -> AB_Build_Invoke.vi -> AB_Build_Invoke.vi.ProxyCaller

Possible reason(s):

LabVIEW:  Cannot save a bad VI without its block diagram.

0 Kudos
Message 6 of 7
(3,213 Views)

Sorry that the error message is so full of gibberish. The last sentence is all you need to know, though it needs a bit of elaboration. The error is saying that one of the VIs, probably the Teleop VI is bad, broken, containing a syntax error that needs to be corrected before an application can be built for download.

Open the Robot Main, click on the run array, which should be broken, and correct the issue. Then see if you can deploy and set as startup.

Greg McKaskle

0 Kudos
Message 7 of 7
(3,213 Views)