07-06-2009 11:07 AM
I have a genie plus syringe pump (manual attached) and i need to be able to control the flow rate from the pump in real time from the computer, using a dial to up or lower the rate as i see fit. I have used the basic serial write/read vi from the examples that another posting mentioned and it communicated with the device just fine using the commands found in the manual. my question is how can i modify this or what do i have to do make the program i need? I am barely a beginner yet at labview but am told that it can be a very useful program for this and other future applications i will encounter. any advice is much appreciated, thanks!
Solved! Go to Solution.
07-06-2009 01:23 PM
07-06-2009 01:33 PM
I would want this to work like this:
I have a visual of the flow on video on the computer as it comes out of the pump and enters the channel. while monitoring this if i need to raise or lower the speed i can do that from the computer (turning the dial as i see fit). so really i need a continous control of the pump from the program.
in the example u gave can u tell me how to change the two text indicators u gave? serial initialization and pump control. also what do i type here so that it controls it continuously? from the genie manual i know that i can set the rate to a specific value (RAT[etc,etc]) but how do i make it dynamic with the dial?
07-06-2009 01:37 PM
I have experience with syringe pump VI's... since they operate only via simple serial commands, you'll definitely need an event structure and a while-loop. Essentially, within your while loop, you need to first query the rate, and subsequently change the rate if it differs from the current setpoint in the VI.
Did your pump come with any LabVIEW toolboxes? As in, pre-built "subVI" boxes that will perform simple steps such as set/get rate? Since you're new to LabVIEW, I think if you can share your current simple solution, I'd be better able to help you add to it from there, rather than sharing my rather complex syringe pump VI (it's for two pumps and involves feedback control) and having you try to decipher it.
07-06-2009 01:40 PM
Ah, OK. You're that much of a beginner. You don't change the text indicators to do anything. Those are labels. The code is already set up to run continuously.
I would strongly recommend doing some of the LabVIEW tutorials and to look over the material in the NI Developer Zone's Learning Center which provides links to other materials and other tutorials. You can also take the online courses for free.
07-06-2009 01:44 PM
the pump did not come with any labview software, etc... as of right now i have no solution yet, i am trying the pump example that the previous poster provided soon.
as for the tutorials in lab view i did all of them but they werent that helpful outside of creating the program the tutorial set out to make i felt (probably go back over them tomorrow).
07-06-2009 01:59 PM
07-06-2009 02:17 PM - edited 07-06-2009 02:20 PM
Here's a simple version I threw together since my first post here. If you did the basic VISA tutorial, and had it communicating with your pump, this should make sense to you.
From left to right:
- set up VISA
- send "START" command (w/VISA write)
- send query command
- read buffer coming back (v/VISA read)
- compare the digit in the read buffer (your format will vary, may have to chop up the string that comes back)
- if buffer is not equal to the "dial" then the true case will send a new rate to the pump
- outside the loop, stop, and close the VISA comms
* For my example (going by the pumps I've worked with), the syntax is "pump address" "command" "value", so "0RAT" simply queries the rate of pump 0, and "0RAT100" sets the rate to 100.
07-06-2009 02:25 PM
07-06-2009 02:30 PM