Go to Post Build a student a robot and it will keep him/her busy for a few days in the spring. Teach a student how to build(design, wire, program) a robot and they will stay away from home, use some really strange language and wear funny clothes the whole year long. - Al Skierkiewicz [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
  #1   Spotlight this post!  
Unread 17-01-2010, 15:52
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Camera not sending image to Classmate?

Right now we have compiled the Circle Tracker Demo to the CRio. We have the crossover cable connected from the camera to port 2 on the CRio, and another crossover cable connected from port 1 on the CRio to the classmate.

There is no image coming up at all either and we are very confused. Any help?
  #2   Spotlight this post!  
Unread 17-01-2010, 16:03
byteit101's Avatar
byteit101 byteit101 is offline
WPILib maintainer (WPI)
AKA: Patrick Plenefisch
no team (The Cat Attack (Formerly))
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2009
Location: Worcester
Posts: 699
byteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of lightbyteit101 is a glorious beacon of light
Re: Camera not sending image to Classmate?

you don't need a crossover to connect the cRIO to the Classmate.
what Language?
__________________
Bubble Wrap: programmers rewards
Watchdog.Kill();
printf("Watchdog is Dead, Celebrate!");
How to make a self aware robot: while (∞) cout<<(sqrt(-∞)/-0);
Previously FRC 451 (The Cat Attack)
Now part of the class of 2016 at WPI & helping on WPILib
  #3   Spotlight this post!  
Unread 17-01-2010, 17:59
frcchile's Avatar
frcchile frcchile is offline
Registered User
FRC #2576
 
Join Date: Jan 2008
Location: santiago, chile
Posts: 79
frcchile will become famous soon enough
Re: Camera not sending image to Classmate?

Quote:
Originally Posted by byteit101 View Post
you don't need a crossover to connect the cRIO to the Classmate.
what Language?
Brother you need unistall and install again FRCLabVIEWUpdate2.0for2010 and FRCLabVIEWUpdate1.0for2010 I had the same problem and it worked


Good luck
  #4   Spotlight this post!  
Unread 17-01-2010, 21:05
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

Yea, we just fixed the Dashboard, which wasn't updating. We didn't have a chance to check to see if the camera will send any, but we will tomorrow. I will update tomorrow as well. Oh, and we're coding in Java.
  #5   Spotlight this post!  
Unread 18-01-2010, 12:15
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

I updated the dashboard, but the camera is still not sending images. However, I am not getting an error message saying Timeout in Communications, so I have no clue what is exactly happening.
  #6   Spotlight this post!  
Unread 18-01-2010, 18:21
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Camera not sending image to Classmate?

You do have the video display on-off switch turned on, right? It's the little control at the bottom of the dashboard video window. It'll show a bright green highlight when you set it to the "on" state.
  #7   Spotlight this post!  
Unread 18-01-2010, 18:51
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

Yea, we do. We got the dashboard to say "camera running e", but still no camera images. Any ideas?
  #8   Spotlight this post!  
Unread 18-01-2010, 23:26
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,753
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Camera not sending image to Classmate?

I don't think I saw mention of configuring the camera. There is a utility to create an FRC user and FRC password on the camera. Without those, the camera will simply return errors, and it may be that the WPI camera libs hide the errors -- not sure.

Connect the camera to the PC, set the PC IP to 192.168.1.1, and run the camera setup utility. Alternately, you can browse to 192.168.1.90 and do the configuration by hand. You can also do this to verify the camera works correctly. Once you log into the camera, you can view images, change settings, etc.

Greg McKaskle
  #9   Spotlight this post!  
Unread 20-01-2010, 20:46
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

We did configure the camera and tried setting the username and password to FRC, but that still did not fix it.
__________________


2011 Pit Crew:
2011 CT Xerox Creativity Award

HYPER Alumni
  #10   Spotlight this post!  
Unread 20-01-2010, 20:51
Eugene Fang's Avatar
Eugene Fang Eugene Fang is offline
The Blue Alliance
no team
Team Role: Alumni
 
Join Date: Jan 2007
Rookie Year: 2000
Location: Bay Area, CA -> Pittsburgh, PA
Posts: 772
Eugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond repute
Re: Camera not sending image to Classmate?

Run the Driver Station update to uninstall the old Driver Station, then run it again to reinstall it. Just updating it (without the uninstall) sometimes doesn't work.
__________________
Eugene Fang
2010 Silicon Valley Regional Dean's List Finalist

Various FLL Teams - Student (2000-2006), Mentor (2007-2010)
FRC Team 604 - Student (2007-2010), Mentor/Remote Advisor (2011-2015)
FRC Team 1323 - Mentor/Remote Advisor (2011-2014)

The Blue Alliance | TBA GameDay | TBA Android App
  #11   Spotlight this post!  
Unread 20-01-2010, 21:14
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

We did uninstall the old Driver Station. Sorry to be very unhelpful to my situation. Is there anything else I can add that would make this easier?
__________________


2011 Pit Crew:
2011 CT Xerox Creativity Award

HYPER Alumni
  #12   Spotlight this post!  
Unread 20-01-2010, 21:31
Geek 2.0 Geek 2.0 is offline
Registered User
FRC #0107
Team Role: Programmer
 
Join Date: Sep 2009
Rookie Year: 2008
Location: Holland, MI
Posts: 120
Geek 2.0 will become famous soon enough
Re: Camera not sending image to Classmate?

Could you post your code that the cRIO is running?
  #13   Spotlight this post!  
Unread 20-01-2010, 21:39
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

Ok, well, I'm not at robotics now, so I'll post it tomorrow. Thanks guys!
__________________


2011 Pit Crew:
2011 CT Xerox Creativity Award

HYPER Alumni
  #14   Spotlight this post!  
Unread 21-01-2010, 14:37
mswalker mswalker is offline
Mentor
FRC #2583 (Westwood Robotics)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 26
mswalker is on a distinguished road
Re: Camera not sending image to Classmate?

This post may help. I haven't tried it yet but it appears to describe the problem we are having:

http://www.chiefdelphi.com/forums/sh...13&postcount=3
  #15   Spotlight this post!  
Unread 22-01-2010, 17:05
TPNigl TPNigl is offline
Registered User
FRC #0069 (Team HYPER)
Team Role: Programmer
 
Join Date: Jan 2009
Rookie Year: 2007
Location: Quincy, MA
Posts: 94
TPNigl is an unknown quantity at this point
Re: Camera not sending image to Classmate?

We did fix that and we have that update complete.

Here's our code

Code:
import edu.wpi.first.wpilibj.GenericHID.Hand;
import edu.wpi.first.wpilibj.Gyro;
import edu.wpi.first.wpilibj.IterativeRobot;
import edu.wpi.first.wpilibj.Jaguar;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.PIDController;
import edu.wpi.first.wpilibj.PIDOutput;
import edu.wpi.first.wpilibj.RobotDrive;
import edu.wpi.first.wpilibj.SpeedController;
import edu.wpi.first.wpilibj.Timer;
import edu.wpi.first.wpilibj.camera.AxisCamera;
import edu.wpi.first.wpilibj.camera.AxisCameraException;
import edu.wpi.first.wpilibj.image.ColorImage;
import edu.wpi.first.wpilibj.image.NIVisionException;
import edu.wpi.first.wpilibj.DriverStationLCD;
//   import edu.wpi.first.wpilibj.samples.CircleTrackerDemo.TrackerDashboard;

/**
 * The VM is configured to automatically run this class, and to call the
 * functions corresponding to each mode, as described in the IterativeRobot
 * documentation. If you change the name of this class or the package after
 * creating this project, you must also update the manifest file in the resource
 * directory.
 */
public class CircleTrackerDemo extends IterativeRobot {

    double kScoreThreshold = .01;
    AxisCamera cam;
  
    TrackerDashboard trackerDashboard = new TrackerDashboard();
    /**
     * This function is run when the robot is first started up and should be
     * used for any initialization code.
     */
    public void robotInit() {
        Timer.delay(10.0);
        cam = AxisCamera.getInstance();
        cam.writeResolution(AxisCamera.ResolutionT.k320x240);
        cam.writeBrightness(0);
      }

    /**
     * This function is called periodically during autonomous
     */
    public void autonomousPeriodic() {
    }

    /**
     * This function is called while the robot is disabled.
     */
    public void disabledPeriodic() {
    }

    /**
     * This function is called at the beginning of teleop
     */
    public void teleopInit() {
    boolean lastTrigger = false;
    DriverStationLCD.getInstance().println(DriverStationLCD.Line.kUser2, 1, "Starting Camera Code");
    DriverStationLCD.getInstance().updateLCD();
    Timer.delay(1.0); //Wait one second so user can see starting message

    }

    /**
     * This function is called periodically during operator control
     */
    public void teleopPeriodic() {
            try {
                DriverStationLCD.getInstance().println(DriverStationLCD.Line.kUser2, 1, "Camera Running     ");
                DriverStationLCD.getInstance().updateLCD();
                if (cam.freshImage()) {// && turnController.onTarget()) {
                    ColorImage image = cam.getImage();
                    Thread.yield();
                    Target[] targets = Target.findCircularTargets(image);
                    Thread.yield();
                    image.free();
                    if (targets.length == 0 || targets[0].m_score < kScoreThreshold) {
                        System.out.println("No target found");
                        DriverStationLCD.getInstance().println(DriverStationLCD.Line.kUser2, 1, "Not Found              " );
                        Target[] newTargets = new Target[targets.length + 1];
                        newTargets[0] = new Target();
                        newTargets[0].m_majorRadius = 0;
                        newTargets[0].m_minorRadius = 0;
                        newTargets[0].m_score = 0;
                        for (int i = 0; i < targets.length; i++) {
                            newTargets[i + 1] = targets[i];
                        }
                  } else {
                        DriverStationLCD.getInstance().println(DriverStationLCD.Line.kUser3, 1, "Pos X: " + targets[0].m_xPos );
                        DriverStationLCD.getInstance().println(DriverStationLCD.Line.kUser4, 1, "Pos Y: " + targets[0].m_yPos );
                        DriverStationLCD.getInstance().updateLCD();
                        System.out.println(targets[0]);
                        System.out.println("Target Angle: " + targets[0].getHorizontalAngle());
                    }
                }
            } catch (NIVisionException ex) {
                ex.printStackTrace();
            } catch (AxisCameraException ex) {
                ex.printStackTrace();
            }


        }
    }
It's just the basic default code for the CircleTrackerDemo
__________________


2011 Pit Crew:
2011 CT Xerox Creativity Award

HYPER Alumni
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting Camera Footage on the Classmate CRASH999 FRC Control System 6 23-01-2010 12:29
Dashboard not appearing on classmate railerobotics Programming 2 20-01-2010 15:42
Java Camera Video on ClassMate Thomas4019 Java 8 16-01-2010 00:18
Classmate not loading Dashbaord on bootup gokul Control System 2 13-01-2010 10:34
[not-FIRST] Camera Image Processing Greg Marra Programming 11 11-03-2008 21:10


All times are GMT -5. The time now is 21:29.

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