GtDio6xMultiSiteWriteSystemMemoryToBoard

Applies To

GX5296

Purpose

Copies the specified number of vectors from the system memory to the DIO memory.

Syntax

GtDio6xMultiSiteWriteSystemMemoryToBoard (nHandle, lSystemMemoryStart, lBoardVectorStart, lVectorSize, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Session identifier:
Board handle is used when communicating with the hardware. The Board handle session identifier is returned by calling GtDio6xInitialize or GtDio6xSetupInitialization.
lSystemMemoryStart
LONG
Specifies the System memory start address, usually should be 0.
lBoardVectorStart
LONG
Specifies the GX5296 DIO board starting memory address to write to from o the system memory.
lVectorSize   
LONG
Specifies how many vectors to copy from the system memory to DIO memory.
pnStatus
PSHORT
Returned status: 0 on success, negative value on failure.

Comments

The function Copies the specified number of vectors from the system memory to the DIO memory. The user once finished to edit and write his vectors using the GtDio6xMultiSiteWriteVectorMemoryToSystemMemory() API, calls this function to transfer the data form the system memory to the board’s memory.

Note: The GtDio6xMultiSiteXXX() APIs provides the functionality required for efficient multi-site testing. By enabling parallel testing of multiple Devices Under Test (DUTs) simultaneously.

Example

The following example writes 15 elements of vector data starting at address 0 for channels 0, 1, 2 to the system memory, then write the system memory to the DIO board:

Note: see GtDio6xMultiSiteGetRealTimeCompareFailures() API for a complete example.

 

LONG    alChannelList[3];

CHAR    acVector[15*3];

LONG    alSitelList[1];

SHORT nStatus;

 

// Clear any previous site lists

GtDio6xMultiSiteDeleteAllSites(nHandle, &nStatus);

CheckStatus(nStatus);

 

// Fill Site #0 Channels Array: CH0-CH2

for (l = 0; l < 3; l++)

    alSiteChannels[l] = l;

// Set Site0 Channels list

GtDio6xMultiSiteSetChannelList(nHandle, 0, 4, alSiteChannels, &nStatus);

CheckStatus(nStatus);

 

for (l = 0; l < 15; l++)

{

    acVector [l * 3 + 0] = GTDIO6X_OPCODE_DRIVE_LOW_EXPECT_LOW;

    acVector [l * 3 + 1] = GTDIO6X_OPCODE_DRIVE_HIGH_EXPECT_HIGH;

    acVector [l * 3 + 2] = GTDIO6X_OPCODE_DRIVE_LOW_EXPECT_LOW;

}

GtDio6xMultiSiteWriteVectorMemoryToSystemMemory(nHandle, lSiteCount, alSitelList, 0, 15*3, acVector, -1,-1, 0, &nStatus);

// Write the System Memory to the DIO board

GtDio6xMultiSiteWriteSystemMemoryToBoard(nHandle, 0, 0, lVectorLength, &nStatus);

 

See Also

GtDio6xMultiSiteDeleteAllSites, GtDio6xMultiSiteGetChannelList, GtDio6xMultiSiteGetRealTimeCompareFailures, GtDio6xMultiSiteGetSiteChannelCount , GtDio6xMultiSiteGetSiteList, GtDio6xMultiSiteGetSiteCount, GtDio6xMultiSiteSetChannelList, GtDio6xMultiSiteSetSiteArray, GtDio6xMultiSiteWriteVectorMemoryToSystemMemory, GtDio6xGetErrorString