I am using TCP-IP to transfert, in a loop, the result of data acquisition from a target using LabVIEW-RT to a host system.
As the size of the buffer is very important for the performance of the TCP-IP transfer, I have choiced to use a fixed size for the buffer (1024 bytes). For this reason, my buffer includes at least 3 parts : the header, the data and the padding.
At this time, I am using the "cast" function to convert the data following by the "concatenate string" function to build the TCP-IP string. But I refer to some documents about the memory management, this sequence induces memory allocation and copy in my loop.
Do you have ideas to avoid the memory allocation and copy in the loop ? If I know how I can do with an array (using the "replace arr
ay subset" with a preallocated array), I don't know how I can do with a string.
Thanks,
Hubert