Jump to content

Simultaneous Image Acquisition Errors in CVS


Recommended Posts

Dear all,

My application involves an inspection system using a CVS-1456 and two cameras DFK41BF02 from Imaging Source. The specs of the cameras are 1280 x 960 pixel, 15 fps max, 1/2" CCD. I'm using LabVIEW 8.6.1 for the program.

Initially, in MAX, I've set the video mode for both cameras to be 1280x960 (Mono 8) 3.75fps and the speed of transfer to be 200Mbps for each camera. The program, which was using high-level imaqdx functions, worked fine. Later, I find out that I need both cameras to grab simultaneously at a speed of 7.5fps and thus, changed the settings in MAX accordingly (increased the video mode to 7.5fps). When I tried to rerun the program, I can only capture from one of the camera while the second camera gives me Error -50150 (as can be seen attached).

I've checked whether there's enough bandwidth to run both cameras at 7.5fps simultaneously with the program that I found here:

http://digital.ni.com/public.nsf/allkb/F7F4DA6482C401278625732D0066EF4E

It says that I am only using 52% (26% for each camera) of the bandwidth. So, there should be no problem with the bandwidth. What I did further was to use the low-level imaqdx functions and set the buffer to be 30. I still get the same error. I tried using a smaller buffer and when I reduced it to 2 for both cameras, I received a different error (still error, though) -1074360320.

Please explain why and how do I solve this headache.

post-9485-126399739303_thumb.jpg

post-9485-126399739606_thumb.jpg

Link to comment

I don't think you have a bandwidth problem at all - it's a memory issue. Can you upload your code so we can look at it?

Hi Crelf,

Thanks for your reply. Attached is the basic code, which I use that get those errors. Ultimately, the code will have APIs for machine vision inspection, which I am developing under the simulated environments - from image files. Thank you in advance!

Shazlan

Basic Forum.vi

Link to comment

The code seems okay - where are you getting the error? Do you get the error when only one of the loops is enabled (ie: put a disable structure around one of them)?

When I am running only one loop (ie. one camera), the application runs perfectly at any frame rate (up to 15 fps). If I run the application with both loops enabled at 3.75 fps, there seems to be no problem. I got the error when I am running both loops at 7.5 fps.

Link to comment

I'm using NI's CVS. So, there shouldn't be any driver or imaqdx compatibility issues.

I've posted the same question at NI's forum and here are some of the replies I got:

http://forums.ni.com/ni/board/message?board.id=200&message.id=26520&jump=true#M26520

What do you guys think? Unfortunately, I don't have the system with me right now - it's at the site, and am planning to make a visit there to correct the issues next Sunday. I hope to have the answers before leaving there. Lastly, I really appreciate it if somebody here can advice on the concerns that I have. For convenience's sake, the issues are copied and pasted below:

1. I think I can get away with 3.75 fps but I need to read and monitor every frame that the camera captures. I personally haven't done this but it can be done by changing the imaqdx buffer mode to 'buffer number' (as oppose to 'Last') and wire the number of buffer frame that I want to acquire. This buffer frame number will increase +1 at a time and once it has reached the max, I will need to reset it back to zero (0). Am i right? Also, am I right to say that when the camera has filled up the buffer, it will overwrite the first image in the buffer?

2. What worries me is I have encountered ceiling memory limitation even before any processing has taken place. In my application, there will be three to four rejection criterias that I need to detect. The way I am planning to do this is by creating an image (using IMAQ create) for each process and destroy it once the processing is done and I got the results. In order to save processing time, I was planning to run all 3 or 4 processes at the same time in parallel. Now, with such limited memory, should I change my plan to processing one criteria at a time (IMAQ Create for criteria 1 - Process 1 - Destroy - IMAQ Create for criteria 2 - Process 2 - Destroy - ...). Can someone advice the best programming structure to do this?

3. Lastly, is there a way for me to estimate the amount of RAM I require to run my program? CVS-1456 has 128MB of RAM. How much 'extra' do I need to leave unused for the machine to operate efficiently without errors?

Thank you.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.