The CIN on the block diagram is orange if you have not set the node to be thread safe. A thread safe node is yellow. Complete the following steps to make LabVIEW recognize a CIN node as thread safe.
- Add the CINProperties function to your CIN code in the prototypes section of your .c source file, as shown in the following example code:
CIN MgErr CINProperties(int32 prop, void *data);
- Add the following function statement to the functions section of your .c source file:
CIN MgErr CINProperties(int32 prop, void *data)
{
switch (prop) {
case kCINIsReentrant:
*(Bool32 *)data = TRUE;
return noErr;
}
return mgNotSupported;
}