Go to Post Do you guys mind if we postpone kick-off to around January 26 or so? We can still keep the ship date on February 20, if that isn't a problem. - dlavery [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 01-02-2011, 01:19
2733Programming 2733Programming is offline
Registered User
FRC #2733 (Pigmice)
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2008
Location: Portland, OR
Posts: 6
2733Programming is an unknown quantity at this point
Odd error when trying to use camera: No content-length token found in packet

We've recently been trying to get the camera to work with Java. We're using the standard KoP camera plugged into port #2 on the cRIO with all of the correct settings as stated in the setting up your camera PDF. Based on what we read in this section of the forums, only a single line of code was actually required to make the camera send back an image to the stock dashboard (which is all we are trying to do). We added that line:

Code:
AxisCamera camera = AxisCamera.getInstance();
to the main class's constructor and everything compiled fine, but once we begin running teleop on the robot, we get this odd error:

"AxisCamera: No content-length token found in packet: S_errno_ECONNREFUSED"

It comes up every few seconds in the netbeans output window, and no video is displayed on the dashboard.

Anyone know why this is happening or what we can do to fix it? We've looked around, but haven't seen anyone posting about this problem anywhere else. Your help would be much appreciated! Thanks.
Reply With Quote
  #2   Spotlight this post!  
Unread 02-02-2011, 17:55
buildmaster5000 buildmaster5000 is offline
Trying to program the swerve drive
AKA: Alex
FRC #2421 (Rolling Thunder Robotics)
Team Role: Alumni
 
Join Date: May 2009
Rookie Year: 2009
Location: Northern Virginia
Posts: 207
buildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud of
Re: Odd error when trying to use camera: No content-length token found in packet

I had a similar problem. I got the same error in netbeans, using the code below:

Code:
//in constructor:
AxisCamera cam=AxisCamera.getInstance();
//in teleopPeriodic
try{
                ColorImage currentImage=cam.getImage();
                cam.writeResolution(AxisCamera.ResolutionT.k320x240);
                currentImage.luminanceEqualize();
                currentImage.free();
            }catch(AxisCameraException c){}
            catch(NIVisionException i){}
__________________
-Alex



2010 Washington DC Regional: Engineering Excellence Award
Reply With Quote
  #3   Spotlight this post!  
Unread 02-02-2011, 19:52
flriley flriley is offline
Registered User
FRC #0086
 
Join Date: Feb 2011
Location: Jacksonville, FL
Posts: 5
flriley is an unknown quantity at this point
Re: Odd error when trying to use camera: No content-length token found in packet

We had the same issue for a while but we read up on it and were able to figure out that it's an issue due to the user info. In the FRC document "How to Configure your Camera" it gives working usernames and passwords that seem to eliminate this issue.

"How to Configure Your Camera
The camera comes with a network address of 192.168.0.90 and a root password of “pass”. The IP address is kept but the password for root must be updated to “admin” to work with the camera access software.

Manual Configuration of the Camera
The username/password combinations that work with the default code are shown in the table below. As long as at least one of these users is configured, the camera initialization software will work.
User name FRC
Password FRC
root pass (Axis default, must be changed)
root admin
FRC FRC"

Using the username "FRC" and password "FRC" has worked for us so far.
Reply With Quote
  #4   Spotlight this post!  
Unread 02-02-2011, 22:16
buildmaster5000 buildmaster5000 is offline
Trying to program the swerve drive
AKA: Alex
FRC #2421 (Rolling Thunder Robotics)
Team Role: Alumni
 
Join Date: May 2009
Rookie Year: 2009
Location: Northern Virginia
Posts: 207
buildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud ofbuildmaster5000 has much to be proud of
Re: Odd error when trying to use camera: No content-length token found in packet

Thank you. I will try that tomorrow at the next build meeting.
__________________
-Alex



2010 Washington DC Regional: Engineering Excellence Award
Reply With Quote
Reply


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 11:19.

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