Using the info I got here: What does a 'Can't shmget: Invalid argument ....
I ran through the calculations for shared memory and I think I am either way off or I need to get much more RAM.
I'm building up 16 cameras and would prefer to run them at 640x480 with 10fps and 24bit color. It seems 40 frames is the default image buffer, but 100 frames seems to be the recommended.
I've got 8gb RAM currently and a decent Core2 Quad processor along with a pair of striped 1tb hard drives along with a pair of 8 channel PV-981 cards (PV-150 equiv with PCI-E). The machine had been planed for 8 cameras but after it was ordered the instructions came down that I needed to plan for more overlapping coverage.
307200 = 640X480 pixels
7372800 = * 24 bit color
737280000 = * 100 frame ring buffer (image buffer)
11796480000 = * 16 cameras
11520000 = / 1024 for kilobytes Convert
11250 = / 1024 for megabytes convert
Is my math completely wrong in stating I need over 11 gigs of RAM? If so, what settings should I be looking at? Also how should I best tweak the settings to get the most out of the system?
Shared Memory - 16 Cameras
OK, I'm a putz. I was doing the conversion to Kb and Mb, but I had not done bits to bytes.
Also, does the shmall and shmmax need to be the same as the the first example in the wiki shows? Or should the two be different as shown a bit below that? If so, what should the ratio be?
If I ./configure with the --enable-mmap=yes command does that just bypass the need fore the shared memory now?
Code: Select all
(Width*Height*Depth*Buffer*Cameras+(1*overhead))/bytes/kilobytes/megabytes
(640 *480 *24 *80 *16 +(1*.10) )/8 /1024 /1024 = 1,125 Mb RAM
If I ./configure with the --enable-mmap=yes command does that just bypass the need fore the shared memory now?