Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   C/C++ (http://www.chiefdelphi.com/forums/forumdisplay.php?f=183)
-   -   Name of camera task (http://www.chiefdelphi.com/forums/showthread.php?t=83718)

SuperBK 28-02-2010 20:10

Name of camera task
 
Hi. Got the camera to the dashboard to work this weekend. Woohoo!

It has around a 2.5 second lag, is this normal, good or bad. I set it to 160 x 120 and tried setting max frames per second to 15. Setting FPS didn't seem to change the lag.

I noticed that if you kill the robot code, the camera still appears on the dashboard because there is a separte camera task for it. What is this task called? It seems that when a new program is run (in memory for fast debugging) and the camera task is already running, then it won't reinitialize the camera, plus it sometimes dies with a kernal exemption. Is there a way to stop the camera task from code?

Thanks,
Brian

byteit101 01-03-2010 06:35

Re: Name of camera task
 
At the moment, no. You will need to modify WPIlib: (From AxisCamera.cpp)
Code:

// TODO: Keep track of this so it can be shut down!
new PCVideoServer();

But to answer your question, FRC_cameraTask and FRC_PCVideoServer

2.5 seconds is bad, did you update the driverstation to 1.1, cRIO to v20 and WPILib to 4.3?

Zme 01-03-2010 08:30

Re: Name of camera task
 
I believe there is something to the effect of a DeleteInstance() function in wpi lib i'm not completely sure of its effects though. I do know that stoping cameras with it didn't seem to work out too well, and without source infront of me i can't say much else on it.

as for lag, try decreasing color depth or setting a moderate amount of compression (we use 50).

are you running any image processing? it can slow things down quite a bit.

let us know how it goes

byteit101 01-03-2010 14:51

Re: Name of camera task
 
Quote:

Originally Posted by Zme (Post 929948)
I believe there is something to the effect of a DeleteInstance() function in wpi lib i'm not completely sure of its effects though. I do know that stoping cameras with it didn't seem to work out too well, and without source infront of me i can't say much else on it.

as for lag, try decreasing color depth or setting a moderate amount of compression (we use 50).

are you running any image processing? it can slow things down quite a bit.

let us know how it goes

DeleteInstance is for Java, and won't delete the images to the dashboard, as my previous post says

Zme 02-03-2010 08:35

Re: Name of camera task
 
Quote:

Originally Posted by byteit101 (Post 930071)
DeleteInstance is for Java, and won't delete the images to the dashboard, as my previous post says

ah, that explains a lot. Thanks for the clarification.


All times are GMT -5. The time now is 13:46.

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