For several years, LabWindows CVI 2019 would not allow me to deploy a dll to a real time PXI target if a dll already existed. At some point, all of my systems stopped starting the dll automatically on power up...sometimes. Around this time, LabWindows decided to have no problems deploying dlls to targets that already had dlls on them. I seem to have corrupted something across 12 systems for them to all behave the same way. When the program starts, one of the firsts things it does is open a serial port and send a message to a terminal. This is how I know it starts and is ready to go.
It will eventually start the program after 2-5 restarts. Right now I am dealing with a system that I have restarted about 8 times and it will won't start. I even redeployed the dll.
This is the beginning of the program, and I can't even get the opening message:
{NOTE: I have snipped code after the call to InitCVIRTE();
void CVIFUNC_C RTmain (void)
{
ssize_t size;
int ASAP3Success = 0;
int DebugFlag = 0;
char DebugMessage[100] = {'\0'};
Terminal_Port_Open();
if (InitCVIRTE (0, 0, 0) == 0)
{
Terminal_Writeline("Problem with CVI Run Time Engine - Closing DDRT");
return; /* out of memory */
}
int Terminal_Port_Open(void)
{
char ** addresses = NULL;
int numAddresses;
int index;
char TerminalMessage[100] = {'\0'};
GetAllTCPHostAddresses (&addresses, &numAddresses);
/* Use the address strings... */
for (index = 0; index < numAddresses; index++)
{
/* Free address string */
if (strstr(addresses[index], "202"))
{
terminalComPort = 9;
break;
}
TCPFreeMemory (addresses[index]);
}
/* Free addresses array */
TCPFreeMemory (addresses);
if (OpenComConfig (terminalComPort, NULL, 115200, 0, 8, 1, 512, -1) < 0)
return -1;
ComWrt (1, "\r\n", 2);
sprintf(TerminalMessage, "DDRT started. Version: %s", VERSION);
Terminal_Writeline(TerminalMessage);
return 0;
}
Any ideas?
Programming Data Acquisition and Control in Measurement Studio and Labwindows/CVI