Go to Post A stack of hearing aid batteries can also read 13v, but they won't run a robot. - Alan Anderson [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #16   Spotlight this post!  
Unread 03-02-2014, 14:10
carrud carrud is offline
Registered User
AKA: Clark Rudder
FRC #2637
Team Role: Mentor
 
Join Date: Feb 2014
Rookie Year: 2014
Location: Los Angeles Area
Posts: 20
carrud is an unknown quantity at this point
Re: URGENT: Code not working for various reasons

Unfortunately my previous post was not entirely correct. Although that was a problem we encountered it was not actually the first problem related to the symptom first reported by the OP. The initial problem was that clicking "deploy" resulted in nothing happening. The code was not getting sent to crio. This problem still happens. Although we have messed about and can sometimes circumvent the problem we have not yet figured exactly why it happens.

When we click deploy, the deploy window appears very, very briefly. This is clearly different than when we have a successful deployment where the window appears and shows the progress bar during the activity. Netconsole shows nothing during this time (though I don't know if it is supposed to show anything).
  #17   Spotlight this post!  
Unread 03-02-2014, 14:31
wireties's Avatar
wireties wireties is offline
Principal Engineer
AKA: Keith Buchanan
FRC #1296 (Full Metal Jackets)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Rockwall, TX
Posts: 1,170
wireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond repute
Send a message via AIM to wireties
Re: URGENT: Code not working for various reasons

Quote:
Originally Posted by carrud View Post
Unfortunately my previous post was not entirely correct. Although that was a problem we encountered it was not actually the first problem related to the symptom first reported by the OP. The initial problem was that clicking "deploy" resulted in nothing happening.
Try turning off the Windoze firewall or create a rule that allows access to a FTP server (which is what really happens when you download code). We have to do this in order to download code.

HTH
__________________
Fast, cheap or working - pick any two!
  #18   Spotlight this post!  
Unread 03-02-2014, 14:47
wireties's Avatar
wireties wireties is offline
Principal Engineer
AKA: Keith Buchanan
FRC #1296 (Full Metal Jackets)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Rockwall, TX
Posts: 1,170
wireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond repute
Send a message via AIM to wireties
Re: URGENT: Code not working for various reasons

Quote:
Originally Posted by carrud View Post
This being a "single-mode OS" seems to be the underlying force behind this happening. At least in some cases.
There is a fundamental misunderstanding in this thread about what "deploying" really means. The transfer is from an FTP client (Windoze) to an FTP server (the robot). The file you are transferring is NOT a fully linked executable. It is code to be dynamically linked and loaded to the VxWorks/FIRST/WPI infrastructure on the robot. So every unknown symbol in the deployed .out file must be satisfied in the text and data segments of the VxWorks/FIRST/WPI/NI code already on the robot (put there when we image the cRIO). This dynamic linking loader is a single pass algorithm, not a dual pass linker like the one we use when combining multiple objects on our development station (where the WindRiver 3.3 is running).

So how does one make sure their code will load and run (2 distinctly different issues)? Most FIRST programmers simply deploy and debug using print/log/smartconsole output. But without using the debugging interface to the robot, you will miss messages about the unresolved symbols and/or tasks getting suspended for various violations (memory access, divide by zero etc). Instead create a target server and load and run your code using the debugging tools and you will see these errors and fix them. FIRST has a tutorial that covers this procedure. NetConsole MIGHT catch them depending on how badly the errors cripple the OS on the robot.

http://wpilib.screenstepslive.com/s/...-robot-program

Many of you might think this is a lame setup. But I remind you this exactly how adding code to the Linux kernel (and many other operating systems) works. WindRiver and VxWorks are not unusual in this respect.

HTH
__________________
Fast, cheap or working - pick any two!

Last edited by wireties : 03-02-2014 at 14:58. Reason: added link to debugging tutorial
  #19   Spotlight this post!  
Unread 03-02-2014, 14:49
steinra's Avatar
steinra steinra is offline
(KG7KEO)
AKA: Randy Steiner
FRC #5461 (V.E.R.N.)
Team Role: Coach
 
Join Date: Nov 2008
Rookie Year: 2007
Location: Meridian, Idaho
Posts: 56
steinra is on a distinguished road
Re: URGENT: Code not working for various reasons

I noted in the list of posts here that the cRio may not have been updated to this years image yet? Is that correct?

We had issues with is running by on the format and update image that it had the rebooting crio and did not take any time on the other steps. I know we had struggles with it and had to do the following.

Make sure all network interfaces were disabled, then only use the wired net connection and plug into the bridge/AP. Make sure the firewall is off.

Make sure you can ping the cRio.

open the imaging tool.

See that the cRio is found.

On the 8 slot crio change the switch to safe mode
On the 4 slot do it on the imaging tool.

Make a minor update (change name, change language, add the can) for instance, do not choose format cRio.

Safe mode will prompt to image cRio. Say yes. This should take a little while and not jump right to rebooting crio message.

After it is done turn off the safe mode switch and then in the imaging tool choose to format the cRio with the new image.

Then the code will need to be deployed.

This was the only way we were able to get both cRio's we have to the current software revision.

If you are still having issues with the C++ code deploy then maybe try jumping over to a labview of java code set and see if that will work for something as simple as reading the joystick value. If you can get that to work, then maybe something is incorrect in the WindRiver setup.

Hope this may help.

Randy
__________________
Randy Steiner
2014-2015 FIRST Team 5461 - Coach
2011-2014 FIRST Team 4106 - Head Mentor
2007-2011 FIRST Team 1891 - Mentor
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 03:14.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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