Transmission with relative record timing means the records are scheduled one after another based on the delta time tag set.
The option MXF_TXAPERIODIC_FLAG_USE_RECORD_RELATIVE_TIME
is used to perform this function.
For instance, for an array of n records to transmit, the records' transmit timing is as follows:
Time record 1 = record 1 time tag (offset from current time)
Time record 2 = Time record 1 + (record 2 time tag - record 1 time tag)
Time record 3 = Time record 2 + (record 3 time tag - record 2 time tag)
......
Time record n = Time record n-1 + (record n time tag - record n-1 time tag)
Each time tag becomes relative to the previous record sent.
#define MAX_TX_SUBFRAMES_TO_TRANSMIT 4
uint32 rc;
HMXF_SERVER server;
HMXF_DEVICE device;
HMXF_CHANNEL txChannel;
size_t txBufferSize;
HMXF_BUFFER txBuffer;
uint64 data;
uint64 word, subframeSize=VMXF_A717_SUBFRAME_SIZE_128;
...
if (!rc)
if(!rc)
{
if(!rc)
{
if(!txHostBuffer)
rc = MAXT_ERROR_MEM;
}
}
if(!rc)
{
rec = txHostBuffer;
for(data=0; data<MAX_TX_SUBFRAMES_TO_TRANSMIT; data++)
{
rec->
dataSize = 2 * (uint32)subframeSize;
for(word=0; word < subframeSize; word++)
{
if (word == 0)
{
switch (data%4)
{
case 0:
break;
case 1:
break;
case 2:
break;
case 3:
break;
default:
break;
}
}
else
rec->
data[word] = (uint16)(0x11*word);
}
}
}
if(!rc)
{
printf("Transmitting ...\n");
rc =
mxfA717TxAperiodicWrite(txBuffer, MXF_TXAPERIODIC_FLAG_USE_RECORD_RELATIVE_TIME, 0, MAX_TX_SUBFRAMES_TO_TRANSMIT, txHostBuffer);
}
...