FieldPoint Family

cancel
Showing results for 
Search instead for 
Did you mean: 

Accessing multiple serial ports hangs cFP-2010?

Either port by itself is fine, both together crash application.  RT 7.1, same effect compiled or just downloaded.

Three parallel loops in application, one communicates via ethernet, the other two via the serial ports.  Port 1 loop does approximately 100 bytes in and out every other second, port 2 loop does about 50 bytes both ways every 5 seconds.  Both serial loops initialize the port outside of the loop then manipulate (via visa) the handshaking lines, send and receive within the loop.  Global stops end the loops.

When both loops are running the whole application crashes in 5 to 10 minutes, including the ethernet loop.  Either serial loop by itself plus the ethernet loop will run indefinitely.  If the serial loops handshake/send/receive sections are gated by a common semaphore so that only one can run at a time, the application runs indefinitely.

All data manipulation within the serial loops is done with array element replacement; no append or build array.  Memory usage is constant in all cases.

Has anybody seen something similar?  The semaphore work around is acceptable in this application but I can imagine cases where it would be a problem.  Thanks.

Matt
0 Kudos
Message 1 of 3
(3,359 Views)
Matt,
 
I have not seen hangs, but I did see a problem where the VISA Read would return a timeout error on the serial ports (no flow control and small amounts of data). The problem disappeared after upgrading the embedded serial version to 2.4.5 (LabVIEW 7.1 ships with NI-Serial 2.4.3 embedded). You should try getting the update from the NI site and see if it helps.
 
Regards,
Aaron
LabVIEW Champion, CLA, CPI
Message 2 of 3
(3,355 Views)
Thanks Aaron.  That resolved it.  For the record I updated as follows:

NI-Serial 2.5.3 -> 2.5.5
NI-Visa 3.1 -> 3.3
NI-Watchdog 2.1.0 -> 2.1.3

I appreciate your help.

Matt
0 Kudos
Message 3 of 3
(3,339 Views)