03-11-2010 09:24 AM
Hello everybody,
I'm working in a program which controls the PHD 2000 infuse/withdraw pump, a Data acquisition board (National Instruments USB-6251) and a flow meter (Sensirion SLG1430) using Labview. The infuse rate of the pump depends on the Data acq. board's measurements. So, it changes continously in time.
The program is almost finished, the pump and the data acq. board work fine together. My problem is integrating the flow meter with the pump and the board. When I start the program, the data acq. board and the flow meter take measurements . But when I connect the pump, flow meter readings become disordered (I'm reading hexadecimal strings which have to be in certain order, if they don't follow a patron then, they are incorrect).
In addition, the pump and the flow meter can work fine in 2 different programs at the same time!!!!!!!!!!. But, because I need the actual infusion rate of the pump and also the measurements the flow meter takes to do calculations in real time, I need only one program to control everything...
The serial configuration is:
Pump:
baud rate: 19200
8 bits
parity and flow control: none
2 bits stop
Flow meter:
baud rate: 19200
8 bits
parity and flow control: none
1 bit stop
ah! I've checked that the IRQ's of each one of the COM ports are different... also, as I said, my problem is that the flow meter can't work with the pump in the same program...Suggestions are welcome.
Thanks,
Daniela.
03-11-2010 10:31 AM
03-12-2010 03:10 PM
Hi,
I have one VISA reference for each one of the COM ports.
Well, this is part of mi code. The rest of it is about doing the feedback control and has nothing to do with the ports. I marked in green the COM port control and the function that opens VISA (for the pump). At the botton is the part which controls the flow meter, as you can see, it's "isolated" from the rest of the program...that's why I don't understand the disordered data.
Thanks,
Daniela.
03-12-2010 03:28 PM