LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem using two ports in parallell on cFP?

This could be VISA related, or something that should be posted in the Fieldpoint section, but anyway:

It seems VISA has some problems handling communication on two ports at the same time on a compact Fieldpoint 2020 module. Quite often I get write errors; VISA reports that it could not write to the port. Unfortunately I do not have the error code right here (will post it later), but VISA gets a timeout on accessing the port.

One port (port 1) is busy responding to modbus polls at 9600 baud, the other one (port 2) is used to upload large chuncks of data at 38400 baud every now and then. (Parallell running VIs, both have normal priority etc.). All the code is fine and is used without any problems in numerous applications running on PCs, however there are some major differenses: First of all the code was previously based on the serpdrv based serial VIs, these VIs have been replaced with the VISA based compatability VIs from LV 7.1.1. I have not gotten around to testing whether this causes a problem on a PC as well. Secondly the code is now run on a cFP 2020. The modbus related port checks the number of bytes continously and processes incoming messages if a certain halt in the data occurs. As long as there is no modbus commands coming in the second port has no problems...

Does this sound familar to anyone? It seems to me that VISA is having problems writing to two ports at the same time, or perhaps there is some other serial related task that affects the writing on the second port. Using the compatability VIs is probably not the best thing to do, but could it cause this type of problem?

I would normally investigate this a bit more before posting anything here, however I'm in a bit of a rush and hope that someone in a different time zone might give me some clues before I wake up tomorrow morning...:-)
0 Kudos
Message 1 of 3
(2,712 Views)
The error code by the way is -1073807339.
0 Kudos
Message 2 of 3
(2,702 Views)
FYI the errors disappeared when running the code as a built application.

Running in the development environment probably puts an extra load on the system that makes VISA operations fail sometimes.

Developing for the cFP was otherwise a pleasant experience, might replace the use of PCs in some of our systems.
0 Kudos
Message 3 of 3
(2,685 Views)