Go to Post I'm very excited for this year, because robots. - pyrtle [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
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 21-01-2013, 21:24
13liud 13liud is offline
Registered User
FRC #2202
 
Join Date: Jan 2013
Location: Wisconsin
Posts: 1
13liud is an unknown quantity at this point
How to display image (RGB, Binary, HSV, etc.) on driver station screen

We are trying to implement vision, but we can't move forward until we can actually see the images we're working with. Is there some way to, once we have an image (RGB, Binary, HSV, etc.) stored as a C++ variable, to display it or see it, preferably as a live feed? How exactly could I do this?

If that's not possible, I need any means of viewing an image file created on the cRIO for testing purposes.
Reply With Quote
  #2   Spotlight this post!  
Unread 23-01-2013, 08:42
rbmj rbmj is offline
Registered User
FRC #0612 (Chantilly Robotics)
Team Role: Alumni
 
Join Date: Apr 2011
Rookie Year: 2011
Location: DC Area/Fairfax County
Posts: 192
rbmj is a jewel in the roughrbmj is a jewel in the roughrbmj is a jewel in the rough
Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen

You can write the image to a file and then look at it on your computer by FTP-ing to the cRIO.
Reply With Quote
  #3   Spotlight this post!  
Unread 23-01-2013, 13:10
mikets's Avatar
mikets mikets is offline
Software Engineer
FRC #0492 (Titan Robotics)
Team Role: Mentor
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Bellevue, WA
Posts: 667
mikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of light
Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen

Quote:
Originally Posted by 13liud View Post
We are trying to implement vision, but we can't move forward until we can actually see the images we're working with. Is there some way to, once we have an image (RGB, Binary, HSV, etc.) stored as a C++ variable, to display it or see it, preferably as a live feed? How exactly could I do this?

If that's not possible, I need any means of viewing an image file created on the cRIO for testing purposes.
As long as your camera is on the standard IP address, you should be able to see the live feed of the camera on your dashboard.
__________________
Reply With Quote
  #4   Spotlight this post!  
Unread 26-01-2013, 20:09
Toa Circuit's Avatar
Toa Circuit Toa Circuit is offline
Thaddeus Maximus
AKA: Thad Hughes
FRC #4213 (MetalCow Robotics)
Team Role: Leadership
 
Join Date: Nov 2012
Rookie Year: 2012
Location: Shirley, IL
Posts: 131
Toa Circuit is an unknown quantity at this point
Re: How to display image (RGB, Binary, HSV, etc.) on driver station screen

If you look at the image processing example... there is the following lines:
Code:
BinaryImage *thresholdImage=image->ThresholdHSV(threshold); // get just the green target pixels
//thresholdImage->Write("/threshold.png");
BinaryImage *convexHullImage=thresholdImage->ConvexHull(false); // fill in partial and full rectangles
//convexHullImage->Write("/ConvexHull.png");
BinaryImage *filteredImage=convexHullImage->ParticleFilter(criteria, 1); //Remove small particles
//filteredImage->Write("Filtered.png");
Uncomment the commented out lines and the files will be saved to the cRIO. Just then get them off with FTPing to the cRIO (At 10.xx.yy.2) with a program like FileZilla.
The documentation reccommends you comment out the loop before writing to the cRIO flash though to keep it from deteriorating. How important this is, Im not sure of. I did it though, and it worked just fine for our purposes, if not better (Cause we could just enable and grab processed pictures, then reenable again and such.)
__________________

2012 Head of Programming and Electrical
2013-14 Overall Team Captain and Programming Head
2012-14 Mentor of FLL Team Power Surge
2014 Dean's List Finalist
2014 CIR Xerox Creativity Award
Webpage
Reply With Quote
  #5   Spotlight this post!  
Unread 27-01-2013, 08:52
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,748
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: How to display image (RGB, Binary, HSV, etc.) on driver station screen

The cRIO is sold industrially for machine monitoring. The filesystem does wear-leveling and the flash is capable of many many rewrites. It is fine to use the flash for debugging, that is one of the reasons it is there.

Greg McKaskle
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 13:30.

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