Xtium-CLHS PX8 User's Manual
Installing Xtium-CLHS PX8
•
21
•
Provide 64 bytes per frame buffer for metadata. Memory for this data is reserved in chunks
of 64kB blocks.
•
Provide 48 bytes per frame buffer for buffer management. Memory for this data is reserved
in chunks of 64kB blocks.
•
For each frame buffer DMA table, allocate 24 bytes + 8 bytes for each 4kB of buffer. For
example, for a 120x50x8 image: 120x50 = 6000 = 1.46 4kB blocks -> roundup to 2 4kB
blocks. Therefore 24 bytes + (2 * 8 bytes) = 40 bytes for DMA tables per frame buffer.
Memory for this data is reserved in chunks of 64kB blocks. If vertical flipping is enabled, one
must add 16 bytes per line per buffer. For example, for an image 4080x3072 image: 16
bytes * 3072 = 49152 bytes.
•
Note that Sapera LT reserves the 1
st
5MB for its own resources, which includes the 200
bytes per frame buffer mentioned above.
•
Test for any memory error when allocating host buffers. Simply use the Buffer menu of the
Sapera Grab demo program (see Grab Demo Overview) to allocate the number of host
buffers required for your acquisition source. Feel free to test the maximum limit of host
buffers possible on your host system – the Sapera Grab demo will not crash when the
requested number of host frame buffers is not allocated.
•
The following calculation is an example of the amount of contiguous memory to reserve
beyond 5MB with 80,000 buffers of 2048x1024x8:
a) (80000 * 64 bytes)
b) (80000 * 48 bytes)
c) (80000 * (24 + (((2048*1024)/4kB) * 8))) = 323MB
d) Total = a (rounded up to nearest 64kB) + b (rounded up to nearest 64kB) + c (rounded
up to nearest 64kB).
Host Computer Frame Buffer Memory Limitations
When planning a Sapera application and its host frame buffers used, plus other Sapera memory
resources, do not forget the Windows operating system memory needs.
A Sapera application using the preferred scatter gather buffers could consume most of the
remaining system memory, with a large allocation of frame buffers. If using frame buffers allocated
as a single contiguous memory block, Windows will limit the allocation dependent on the installed
system memory. Use the Buffer menu of the Sapera Grab demo program to allocate host buffer
memory until an error message signals the limit allowed by the operating system used.
Contiguous Memory for Sapera Messaging
The current value for Sapera messaging determines the total amount of contiguous memory
reserved at boot time for messages allocation. This memory space stores arguments when a
Sapera function is called. Increase this value if you are using functions with large arguments, such
as arrays and experience any memory errors.