Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   Need help converting 2009 code to 2010 (http://www.chiefdelphi.com/forums/showthread.php?t=87398)

dani692 04-11-2010 19:43

Need help converting 2009 code to 2010
 
Hey,

My team keeps old robots around for presentations and such, and since we have some downtime now we need to make sure we can download code to our 2009 robot in case something happens. Problem is, that labview expired in January and there are some big changes in 2010. Is there a way to get around the library issues or do we have to redo the code? Thanks!

kamocat 04-11-2010 21:43

Re: Need help converting 2009 code to 2010
 
Library issues? Could you be more specific?
The code should reference the new libraries automatically.

j.cole 05-11-2010 15:15

Re: Need help converting 2009 code to 2010
 
To be honest with you it might be easier/faster to just rewrite the entire code. Especialy if you have a new programmer that needs to learn LabView. If you REALLY want to use the old code I don't know what to tell you.

Alan Anderson 05-11-2010 15:43

Re: Need help converting 2009 code to 2010
 
You're mostly concerned about being able to restore the existing program to the cRIO in case of emergency, right? If you won't be trying to modify the code, there's a reasonably simple solution. Just use ftp to copy the contents of the cRIO's filesystem, and stash it somewhere safe so you can put it back if necessary.

Joe Ross 05-11-2010 15:59

Re: Need help converting 2009 code to 2010
 
While there were some changes for the libraries from 2009 to 2010, They weren't huge. I recall only having to make a few minor changes to our code. In any case, it should be much faster to change the code then to re-implement. However, reimplementing the code is often a valuable experience, because you can always use your experience to make your code better and simpler.

Details about what exactly you are seeing would be helpful

Mark McLeod 05-11-2010 16:14

Re: Need help converting 2009 code to 2010
 
I only remember DashboardEnable.ctl going missing from 2009, but it's been awhile.

dani692 05-11-2010 18:43

Re: Need help converting 2009 code to 2010
 
Yeah, the only one that isn't in the 2010 library is "driverstation.lvlib:dashboardenable.ctl". Is there any way to download that? Or something along those lines?

Mark McLeod 05-11-2010 18:48

Re: Need help converting 2009 code to 2010
 
You can just create a duplicate.
The structure is referenced in the BuildDashboard... vi

or replace the dashboard code with the 2010 version

or eliminate it altogether...

Joe Ross 05-11-2010 19:33

Re: Need help converting 2009 code to 2010
 
Here's NI's response: http://decibel.ni.com/content/message/11956#11956

dani692 05-11-2010 19:42

Re: Need help converting 2009 code to 2010
 
OK, we copied the vi from the 2010 code and pasted it into the old code, and were able to build it successfully.

We then turned on our robot with the new code and the Driver Station said "System: WatchDog" instead of "System: Enabled." How can we fix this?

Mark McLeod 05-11-2010 21:39

Re: Need help converting 2009 code to 2010
 
It sounds like the Watchdog isn't being fed in Teleop.vi
Are you familiar with how the Watchdog code works?

dani692 11-11-2010 17:45

Re: Need help converting 2009 code to 2010
 
1 Attachment(s)
This is what the watchdog looks like in teleop. The case loop with motor controls and what not is to the right. It's opened in begin.vi and killed in finish.vi. We looked at the 2010 code and it's the same. Does using the 2009 driver station instead of the classmate make a difference?

Greg McKaskle 11-11-2010 19:48

Re: Need help converting 2009 code to 2010
 
No. The type of DS will not matter. The code to the left that may be taking a long time to execute is the first thing I'd look at.

Greg McKaskle


All times are GMT -5. The time now is 10:16.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi