Go to Post At one of the registration days at the beginning of the year I actually made a sign saying: "I'm not smart isn't an excuse". - Mr. Pockets [more]
Home
Go Back   Chief Delphi > Technical > Technical Discussion
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 16-02-2012, 12:46
gaurav.agashe gaurav.agashe is offline
Registered User
FRC #0886
 
Join Date: Jan 2012
Location: Toronto, ON
Posts: 5
gaurav.agashe is an unknown quantity at this point
Exclamation Vision runs only once!

When I click on "Enable Vision" in Robot Main.vi, the cRIO processes the camera image and outputs a 2D array in VisionProcessing.vi that gives me the co-ordinates (in pixels) of the rectangle. I then shut off the "Enable Vision" button.

When I move the robot closer to the net and click on "Enable Vision" again, nothing changes! The image viewer block I have wired to the Img Out does not change, and the values in the measurements-array to not change either!

It's as if our vision runs only once, and thats it. Please view attached screenshot of VI. Any help is much appreciated!! Thanks!

http://www.chiefdelphi.com/forums/at...4&d=1329243121
  #2   Spotlight this post!  
Unread 16-02-2012, 20:56
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,752
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: Vision runs only once!

How often are you leaving the camera off? I filed a bug tracker awhile back that may relate to this. When the camera is disabled, it stops reading from the stream. At some point, perhaps ten or fifteen seconds later, the camera seems to close the connection, and the MJPEG code doesn't handle this error 66.

Please let me know if there seems to be another way to provoke this.

Greg McKaskle
  #3   Spotlight this post!  
Unread 16-02-2012, 23:26
Peter Randall Peter Randall is offline
Director of Technology
FRC #1218 (Vulcan Robotics)
Team Role: Teacher
 
Join Date: Jan 2003
Rookie Year: 2003
Location: Philadelphia
Posts: 37
Peter Randall will become famous soon enoughPeter Randall will become famous soon enough
Re: Vision runs only once!

I ran into this as well tonight. I wanted to turn off vision processing when I didn't need it. If I turn it back on immediately, it picks up fine. But if I leave it off for a while, 15+ seconds, it won't restart. Seems buggy to me.

__________________
Peter Randall
Chairman, Department of Engineering & Robotics
Springside Chestnut Hill Academy
TEAM 1218
  #4   Spotlight this post!  
Unread 17-02-2012, 09:46
gaurav.agashe gaurav.agashe is offline
Registered User
FRC #0886
 
Join Date: Jan 2012
Location: Toronto, ON
Posts: 5
gaurav.agashe is an unknown quantity at this point
Re: Vision runs only once!

Quote:
Originally Posted by Peter Randall View Post
I ran into this as well tonight. I wanted to turn off vision processing when I didn't need it. If I turn it back on immediately, it picks up fine. But if I leave it off for a while, 15+ seconds, it won't restart. Seems buggy to me.

This is exactly what is happening to us! Our current logic is in the attached screenshot: Vision_noArea.JPG


Also, the area-particle-filter block makes the cRIO crash as soon as i Enable Vision. I have removed the filtering block for the time being. The VI I was using that was causing this is in the attachment Vision_withArea.JPG. Is my syntax/layout of the IMAQ particle filter horribly wrong to cause this crash?
Attached Thumbnails
Click image for larger version

Name:	vision_noArea.JPG
Views:	24
Size:	110.7 KB
ID:	11943  Click image for larger version

Name:	vision_withArea.JPG
Views:	42
Size:	39.7 KB
ID:	11944  
  #5   Spotlight this post!  
Unread 17-02-2012, 15:03
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,752
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: Vision runs only once!

What controller are you running the vision code on? 8 or 4?

For the bug fix, I'm not in a situation where I can fully test the attached VI, but it should deal with the error when the camera shuts down the stream. Rename the file shown below and put the attached file one in its place.

Program Files\National Instruments\LabVIEW 2011\vi.lib\Rock Robotics\WPI\Camera\WPI_CameraRead MJPGString.vi

Please let me know if this corrects the issue and we will get this on the NI site.
Greg McKaskle
Attached Files
File Type: vi WPI_CameraRead MJPGString.vi (31.5 KB, 21 views)
  #6   Spotlight this post!  
Unread 18-02-2012, 21:46
TheSochenOne TheSochenOne is offline
Programmer
AKA: Yoav Sochen
FRC #3316 (D-Bug)
Team Role: Programmer
 
Join Date: Feb 2012
Rookie Year: 2010
Location: Tel Aviv
Posts: 1
TheSochenOne is an unknown quantity at this point
Re: Vision runs only once!

the exact same thing happened to me yesterday. we are using an almost identical vision processing algorithm.
I tried the fix you suggested and it doesn't seem to fix the problem
  #7   Spotlight this post!  
Unread 18-02-2012, 22:10
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,752
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: Vision runs only once!

Can you describe exactly what you are doing, the symptoms, and what you've tried to fix it.

Greg McKaskle
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 22:10.

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