Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Get code from cRIO (http://www.chiefdelphi.com/forums/showthread.php?t=97442)

bobl 19-09-2011 11:45

Get code from cRIO
 
Our team has misplaced the laptop that we use for programming and along with it a flash drive with the backups. Is there any way to read the existing code from the cRIO so we don't have to start from scratch? We program in Java.

anthonyttu 19-09-2011 12:10

Re: Get code from cRIO
 
Sorry there is no way to remove code from a RIO.

bobl 19-09-2011 12:13

Re: Get code from cRIO
 
That is what I thought but was hopeful I was wrong. Thanks for the quick response.,

Andrew Schreiber 19-09-2011 14:21

Re: Get code from cRIO
 
This post seems to come up every year... I strongly suggest throwing your code into a git repository (even LV code)and putting it on a free account at github or any of the other hosted SCM sites. Revision tracking AND backup all in one and it is free.

AdamHeard 19-09-2011 14:29

Re: Get code from cRIO
 
Quote:

Originally Posted by Andrew Schreiber (Post 1077643)
This post seems to come up every year... I strongly suggest throwing your code into a git repository (even LV code)and putting it on a free account at github or any of the other hosted SCM sites. Revision tracking AND backup all in one and it is free.

Highly recommend the same. It's amazing how many programmers don't apreciate the importance of version control.

Off topic, but if you use the two interpreted languages available, Python and Lua, you could ftp the code off ;)

Andrew Schreiber 19-09-2011 15:37

Re: Get code from cRIO
 
Quote:

Originally Posted by AdamHeard (Post 1077644)
Highly recommend the same. It's amazing how many programmers don't apreciate the importance of version control.

Off topic, but if you use the two interpreted languages available, Python and Lua, you could ftp the code off ;)


True, we are operating off the assumption that the OP did not use either of those languages. If it is incorrect and you DID use one of those the process Adam described above would work.


As for more details on SCM... the thread http://www.chiefdelphi.com/forums/sh....php?p=1073528 has a small discussion on it.

I can tell you when I start a project the first command I type is "git init" depending on what I'm doing I do I then push to a remote server (github usually). Works great for hw assignments too.

WizenedEE 19-09-2011 19:56

Re: Get code from cRIO
 
Well, if you just want to upload new code to try it out and then put the old code back on, you can just grab startup.rtexe off of it (I don't know if startup.alias is needed.)

mesamb1 19-09-2011 23:16

Re: Get code from cRIO
 
Creating a zip file of the folder of your code and uploading it to a folder on your teams website is another easy way to back up your code.
bobl, though I feel for your loss having done the same thing my self, this is a great opportunity to review coding in Java before the season starts. Not that saves you any time, but it is an awesome learning experience

~Cory~ 20-09-2011 00:08

Re: Get code from cRIO
 
Slow your horses people. If you really really really want your code (and provided its in c++ or another one of the mentioned languages) You can "Somewhat" get the code from the cRIO. You can ftp and fecth the FRC_UserProgram.out file from the /ni-rt/system/ directory. This code can be be then decompiled using a tool such as ollydebug. This technique should be reserved for times when the amount of work to recreate what ever the old coder made is greater than about 10000000000000000 hours:)

Ether 20-09-2011 10:13

Re: Get code from cRIO
 
Quote:

Originally Posted by ~Cory~ (Post 1077716)
This code can be be then decompiled using a tool such as ollydebug.

Ollydbg contains a disassembler, not a "decompiler". You can't get your original C++ code back.



Joe Ross 20-09-2011 10:42

Re: Get code from cRIO
 
Quote:

Originally Posted by Ether (Post 1077766)
Ollydbg contains a disassembler, not a "decompiler". You can't get your original C++ code back.

It also appears to be x86 only, which won't help you with the cRIO's ppc target.

Quote:

Originally Posted by mesamb1 (Post 1077703)
Creating a zip file of the folder of your code and uploading it to a folder on your teams website is another easy way to back up your code.

Another option would be to use ftp to upload it to your robot.

WizenedEE 20-09-2011 17:47

Re: Get code from cRIO
 
Quote:

Originally Posted by Joe Ross (Post 1077768)
Another option would be to use ftp to upload it to your robot.

Great idea! Also, let's put a compiler and an AI on it so it'll write its own code.


All times are GMT -5. The time now is 23:40.

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