Data Acquisition (DAQ) and Control from Microstar Laboratories

Knowledge Base: Applications

Q10104 Communication pipe failure after upgrading DAPtools software

Tags: Help, communication pipe, com pipe, buffer size

Applies to: all versions of DAPcell 6 and DAPtools 5, DAP840, DAP4000a, DAP5000a, DAP5216a, DAP5016a, DAP5200a, DAP5216a

After upgrading from DAPtools version 4.3 to DAPtools version 5.1, my application fails to start correctly. I discovered that the DAPL system runs out of memory before it finishes setting up the communication pipes. Do I need to do something different for setting up communication pipes?

Buffer memory is reserved for a communication pipe created by an application using the DLL function DapComPipeCreate, or using the Data Acquisition Processor application in the Control Panel. The default settings of DAPcell 6.x services, from DAPtools package 5.xx, attempt to optimize performance of Windows Vista, Windows 7, and Windows 8 systems by reserving 8M storage elements. Sometimes this demands too much buffer memory, particularly for DAP board models having less than 128MB of physical memory. To correct this problem, use the maxsize option to establish a smaller buffer memory size on the DAP side of the commmunication pipe. Shown below are some examples of how to apply this adjustment. The examples assume communication pipes of type long because the 32-bit elements are more likely to cause problems, but the same solutions apply for pipes transferring other data types (byte, word, float, double, text).

  • \\<server>\<dap>\Cp2Out [maxsize=4096 type=long] - both PC side and DAP side have 4096 buffered elements

  • \\<server>\<dap>\Cp2Out [type=long | maxsize=4096] - the DAP-side buffering is limited to 4096 elements, while the PC side uses the default 8M elements

The DAPcell software on the DAPtools 6.00 release and later uses different rules for setting communication pipe default sizes on the DAP side, based on the buffer memory available on the DAP board, so ordinarily you should not need to make these same adjustments. Boards with 128MB or more of buffer memory will continue to use the large communications buffers for maximum compatibility with Windows 7 and Windows 8. If your application uses several communications pipes, it remains possible to run short of buffer memory, and you might need similar reductions in the maxsize properties of your communication pipes.


More information about properties of communication pipes is available in the DAPIO32 Reference Manual