Rs232 read and write from pressure transducer with command.

New to LabVIEW and have my first task. I have connected to a Setra pressure transducer via rs232 in Com port 4. I'm trying to track and log pressure over a given period of time. A command of "P" must be sent to the transducer for it to return a pressure reading. By searching, so far I have VISA open, close, read and write on my block diagram. I tried to create a constant from the VISA read resource name and connect it to COM4, but that did not work. Not sure how to accomplish my goal or how to wire everything up correctly. Any help for a beginner is appreciated.

That error is due to some process already having exclusive rights to the port.  Do you have Hyperterminal or something else the could be using the COM port open?  Did you not close out the VISA reference during previous runs?
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines

Similar Messages

  • ITunes Library on an Airport Disk?  Read and write from multiple Macs?

    OK, I've scoured the forums for an answer to this, but haven't found anything definitive. Apologies if I've missed the answer, but here's what I want to know:
    I have an iMac as a primary computer, plus a Mac Mini hooked up to my entertainment system, and my girlfriend's powerbook in the house too. There seem to be two main iTunes options: either constantly try to keep all three iTunes libraries synchronised by running around importing files, etc.; or just keep one library, and share it over the network.
    Right now, I am keeping my iTunes library on my iMac and sharing it with the Mac Mini and the powerbook. If anyone wants to add music (or other content) to the library, it has to be through the iMac. Obviously the iMac has to be on for any other computer to access the shared library.
    I want to try to make things simpler by having a single "network" iTunes library that all computers to be able to share (read AND write). I envisage having this "iTunes Server" on an external HD connected to my Airport Extreme as an Airport Disk. If I move the entire contents of ~/music/iTunes (including artwork, library files, etc) to this central location, will the three Macs be able to deal with this, ie can multiple computers share an iTunes library database on an airdisk? Will I be able to stream content from this library to all three computers? Will I be able to import new music into the library from any one of the three computers?

    I am having a very similar problem. I have all of my music saved on a large external disk connected to my airport. I would like to be able to just play what i want from this disk, but i don't like having to download every track i want to listen to. I still want to be able to bring my laptop with me and have some music so i don't want to make this external disk my library folder. Is there a way to play it on my computer similar to a shared library on another computer? Am i asking to much out of apple?

  • Read and write from access

    I am arun, a beginner in the field of LabVIEW. Now I am trying to read and write data from MS Access with out database connection toolset. How this possible. How I can use activex in Labview for doing this. Please give me some reference materials.

    Hi Arun,
    The following discussion forum talks about the same issue, and provides a good explanation and references for the different options. Also, which version of LabVIEW are you using?
    How to read/write from Access database
    Thanks,
    Lesley Y.

  • How do I make Read and Write 10 Gold work with Firefox? I have the latest Firefox 10.0.1 but it keeps saying "Please upgrade your version of Mozilla Firefox. The minimum version supported by Read&Write is version 3.0."

    I just loaded Moxilla Firefox on my Windows 7 PC today and tried to use my Read and Write 10 Gold text help software but it just does not seem to work with this browser (works fine on Internet Explorer) as it keeps saying "Please upgrade your version of Mozilla Firefox.
    The minimum version supported by Read&Write is version 3.0." but this versions is higher than 3.0!

    We have a solution available for anyone needing to run Firefox 10 with Read&Write v10 Gold, please email us directly for this temporary resolution- [email protected]

  • How can i format an external drive so as to read and write from both windows and mac side

    i recently bought a macbook pro and used bootcamp so as to be able to run win7 and mac. I now wish to have an external drive so as to backup and tranfer files between the two os's. Specifically to read and write form either windows or mac. How can I do this?              

    Format it as FAT.

  • Read and write from and to text file

     Hi All,
    I am trying to read some portion of a text file and make measurement and calculation with those numbers and write back to the same text file and also to a excel file. I need to create a 2 D  array of 20 by 20 from the text file values and write to front panel table and to text file. but I am having problem with it, obviously I am new to this. Please help me.  thanks much
    ~ Johnny

    Hi Lynn,
    the requirement is to move C1 and C2 to each position that is given in the text file in steps and percentage value.
    for example C1 has to go to first step (5%) and C2 has to go thru all steps, 5% to 95% , in 5 percent increment. 
    each 100 steps translates to 1 percent increment in the capacitor value.
    at the end, I need to enter the measured data (values of C1 for each step, vesus all values of C2 for all steps) and enter them at the bottom of the text file's table where it starts at : "IMPEDANCE_REAL in Ohmone line per C1 position, containing all values for the different C2 positions" and do the same for where it says "IMPEDANCE_IMAGINARY in Ohmone line per C1 position, containing all values for the different C2 positions"
    the reason I read the file twice, is that if it read it once, I couldn't connect it to spreadsheet string to array vi.
    as you can see, I also like to use the write to measurement file and build table express vi's to display the table on the front panel and save the data to ni data file format so later I convert it to excel  too.
    any thoughts?
    thanks for your help
    ~ Johnny
    Attachments:
    read from text2.vi ‏82 KB

  • How to read and write from XL file

    HI ,
    I wanted to read a data from XL file and write a data in XL file by generating a report .Can any body help me out.Many examples are available on discussion forums but when I try to save and run those Vi .I am not able to run Showing error .Please tell what is going wrong as I m having latest labview 8.6 .
    Regards
    Sharmila.karale

    Hi Adnan,
    Here are the examples of Vi which I have downloaded from the forum for my reference
    Regards
    Sharmila.Krale
    Attachments:
    SAVE TO EXCEL.llb ‏128 KB
    excel.llb ‏1618 KB

  • Need easy fix to make my external HD read and write from PC to Mac user

    Ok. So I got a MacBook pro. Changing from PC. I have 2500 songs on my iTunes file which is on an external hard drive. This is where I keep it. It was a sinch directing iTunes to where my music files and playlists were but needing to add more songs in the playlists from this hard drive that has all my other music is apparently impossible. Mac only reads this ext HD and can't write because it's NTSC. OK, I googled to try and find a fix. Macfuse nor NTSC3g worked. I don't want to buy another thing for this after spending $1200. Nor do I want to take the time to reformat 20,000 songs in an external HD from NTSC to FAT. is there a better way? I specifically asked the clerk in the apple store if this was going to be a problem. He said no of course. But apparently it is a problem. Anyone got any ideas before I take this laptop back?

    Here are all the NTFS mounting, read and writing utilities available for the Mac.
    http://www.macupdate.com/find/mac/ntfs
    Read the reviews, download the demos, try them out.
    Can I ask how big your external HD is? Why not buy another external drive and copy your music files from the NTFS formatted PC drive to a Mac formatted drive.
    You will need another external drive for backuping up your MacBook, anyway.
    You do have a backup plan for your MacBook?

  • Read and Write from Remote Shared directory

    Hello everyone,
    I'm working on an enterprise portal. One of the things i was asked to do is access a remote directory (like "\\machine\share\") and be able to, at least, list the files, download to the portal user any of them, and be able to upload some as well. Also my goal is to create dinamycally a directory inside the shared one for every record I insert into a database for, for example, creating a course (each course has an attachment of files with the schedules, curriculum, etc. in pdf or doc files).
    Can anyone point me in the right direction on how to star this? are there any API's, packages or something like that that i can use?
    Thank you in advance.

    I have allready done that type of Project
    I use FTP to Connect remote server. there is api call
    com.enterprisedt.net.ftp you can download it free
    also you can get the document of that API.
    there is som sample code
    import com.enterprisedt.net.ftp.*;
    class remote
    private String localPath,remotePath;
    private FTPClient ftpClient;
    public remote()
    try
    localPath="localpath to download";
    remotePath="remote path from server";
    ftpClient = new FTPClient();
    FTPMessageCollector listener = new FTPMessageCollector();
    ftpClient.setMessageListener(listener);
    ftpClient.setRemoteHost(ip of the remote host);
    ftpClient.setTimeout(10 * 60 * 1000);
    System.out.println("connecting to the Remote Server....");
    ftpClient.connect();
    System.out.println("connected to the Remote Server ");
    ftpClient.login(username,password);
    ftpClient.setConnectMode(FTPConnectMode.PASV);
    ftpClient.setType(FTPTransferType.ASCII);
    downloadFiles();
    catch(FTPException ftpe)
    System.out.println(ftpe.toString());
    catch(Exception e)
    System.out.println(e.toString());
    public void downloadFiles()
    try
    String [] remoteFileList;
    String localFileName;
    remoteFileList=ftpClient.dir(remotePath + "/");//get the Remote
    //file list
    for(int j=0;j<remoteFileList.length;j++)
    ( localFileName =localfile //filter only fileneme from remotFileList[J])
    ftpClient.get(localPath + localFileName, remoteFileList[j]);
    System.out.println("Successfuly Downloaded " +
    ftpClient.quit();
    catch(Exception e)
    System.out.println(e.toString());
    from Jinath
    Message was edited by:
    JBN

  • How to read and write from the serial port using java

    can anyone tel me how to capture data from a serial port and display on the screen and also store it in a database.

    Java Comm API, JDBC

  • Can't stop synchronized threads with I/O read and write

    I have two synchronized threads which doing read and write from and into a file.
    One thread called "reader" which does reading, encoding, etc from a source file and puts its output in a pre-defined variable. Another called "writer" which puts the reader's output into a file ( not the source file ). Both thread will notify each other when they've finished each of their part. It's similiar to CubyHole example of Java Tutorial example from Sun.
    But somehow it seems like the threads keep spawning and won't die. Even if the source file has been all read and the data has been fully written, calling interrupt(), return, etc has no effect. The threads will keep running untill System.exit() called.
    Is it because the threads were blocked for I/O operation and the only way to kill them is to close the I/O ?
    To be honest, it's not only stop the threads that I want to, I also want to somehow pause the threads manually in the middle of the process.
    Is it possible ?
    Cheers.!!!

    The example code for the problem using 4 classes called :
    - libReadWrite ( class holding methods for aplication operations )
    - reader ( thread class responsible for reading data )
    - writer ( thread class responsible for writing data )
    - myGUI ( user interface class )
    All of them written in different file.
    // libReadWrite
    pubic class libReadWrite {
    private boolean dataReady;
    private String theData;
    //read data
    public synchronized void read(String inputFile) {
    while (dataReady == true) {
    try {
    wait();
    } catch (InterruptedException ex) {}
    RandomAccessFile raf = new RandomAccessFile(inputFile, "r"); // I'm using raf here because there are a lot of seek operations
    theData = "whatever"; // final data after several unlist processes
    dataReady = true;
    notifyAll();
    public synchronized void write(String outputFile) {
    while (dataReady == false) {
    try {
    wait();
    } catch (InterruptedException ex) {}
    DataOutputStream output = new DataOutputStream(new FileOutputStream(outputFile, true));
    output.writeBytes(theData);
    dataReady = false;
    notifyAll();
    //Reader
    public class reader extends Thread {
    private libReadWrite myLib;
    private String inputFile;
    public reader (libReadWrite myLib, String inputFile) {
    this.myLib = myLib;
    this.inputFile = inputFile;
    public void run() {
    while (!isInterrupted()) {
    myLib.read(inputFile); <-- this code running within a loop
    return;
    public class writer extends Thread {
    private libReadWrite myLib;
    private String outputFile;
    public writer (libReadWrite myLib, String outputFile) {
    this.myLib = myLib;
    this.outputFile = outputFile;
    public void run() {
    while (!isInterrupted()) {
    myLib.write(outputFile); <-- this code running within a loop
    try {
    sleep(int)(Math.random() + 100);
    } catch (InterruptedException ex) {}
    return;
    //myGUI
    public class myGUI extends JFrame {
    private libReadWrite lib;
    private reader readerRunner;
    private writer writerRunner;
    //Those private variables initialized when the JFrame open (windowOpened)
    libReadWrite lib = new libReadWrite();
    reader readerRunner = new reader("inputfile.txt");
    writer writerRunner = new writer("outputfile.txt");
    //A lot of gui stuffs here but the thing is below. The code is executed from a button actionPerformed
    if (button.getText().equals("Run me")) {
    readerRunner.start();
    writerRunner.start();
    button.setText("Stop me");
    } else {
    readerRunner.interrupt();
    writerRunner.interrupt();
    }

  • Fast way to read and write console

    hi guys
    what's the fastest way to read and write from console?
    For writing I'm using (I think thats the fastest way)
    System.out.println(foo)and I have to read the following - all numbers are ints (that means m + n + 1 lines):
    1 * "<n> <m>"
    n * "<a> <b> <c>"
    m * "<a> <b>"Actual I'm reading (the second line for example) with
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String[] items = br.readLine().split("[^\\-\\.0-9]+");
    Target mainTarget = new Target(Integer.parseInt(items[0]), Integer.parseInt(items[1]), Integer.parseInt(items[2]));
    for (int i = 1; i < m; i++) {
        items = br.readLine().split("[^\\-\\.0-9]+");
        mainTarget.addTarget(Integer.parseInt(items[0]), Integer.parseInt(items[1]), Integer.parseInt(items[2]));
    } But that isn't really fast...
    have you any idea?
    grz faetzminator

    faetzminator wrote:
    right, I have 1 + 1 + 1 =3 up to 10^6-1 + 10^6-1 + 1 =2*10^6-1 input lines with max 4999997 integers (and I have to store 2999999 of them)
    ok, if that is the fastest way... (maybe the reading of the input file is so slow; I run eg "java Foo < input > output")All those br.readLine calls where you never check if the return is null are dangerous.
    I really don't understand what you are doing. You mentioned System.in at first and now reading from files.
    I also am pretty sure that you are in fact running out of memory.

  • HELP!: How to read and write to External hard drives? What file system to use?

    hey all, this has been really frustrating for me today. i want to be able to write to an external HDD that's formatted in NTFS. today i find out it isn't possible to write to this file system on a Mac and that on FAT32 it is possible. however, FAT32 can't address files larger than 4GB so this hurts me a lot. are there any other file systems that'll allow me to read and write from a Mac? my goal was to use freeNAS to build a NAS with an old tower and connect my external hard drives to it, but if i can't write to them this may not be possible.
    thanks guys, i'd appreciate any help!

    Read this, you don't need to install any software unless you have no choice.
    https://discussions.apple.com/docs/DOC-3044
    https://discussions.apple.com/community/notebooks/macbook_pro?view=documents

  • Fast, small-byte reads and writes.

    I am trying to communicate with a third-party counter using a 1 byte "start" command followed by reading a 4 byte number.  I would like to perform this read/write pair as fast as possible as I will be using count-times on the order of microseconds repeated millions of times.  Our first attempt used USB but the latency in the bus was way too slow at 1ms.  We spent more time waiting than counting. We are currently considering GPIB since the latency should be only 30 microseconds but we're concerned that the overhead from labview will prevent us from reading and writing that fast.  Another idea we had was to use digital I/O channels to create our own parallel port to by-pass the USB bus.  Can anyone comment on a good solution for low-latency small-byte reads and writes from labview? What type of hardware is recommended and can labview support programmatic reads-writes on the order of microseconds? Thanks!

    Theoretically GPIB is capable of very good latencies, as you say on the order of usec.  But in the real world using real PCs running real operating systems and connected to real instruments, the latencies seem to cluster around 2-5msec, in my experience.  The issue isn't LabVIEW so much as all the stuff through which instrumentation interactions must filter, including background processes, screen updates and all the rest of the activities which consume the processor's bandwidth.  Some instruments allow you to buffer and interpret the next command while the current one is underway, then trigger it, which saves latency.  Also keep in mind that your GPIB network will only be as responsive as the least-well-behaved instrument on the bus.

  • Using the Borland Database Engine to read AND write SHARED Paradox Database Tables

    I need to read and write Paradox database tables with a C# AT THE SAME TIME AS people using the Paradox tables with legacy Paradox programs interactively.
    I think the only way to do that reliably without corrupting the tables is to use the BDE Borland Database Engine.
    Does anyone know how to do that? I found this c++ program... But I don't know how to integrate this into c#
    http://www.codeproject.com/KB/database/bdedatabase.aspx
    Is there another way to do this? Again, most important, I don't want to corrupt the paradox database.
    I can read the paradox records all day long, that is no problem, it is updating at the same time as the legacy program users..
    I also know that the whole thing needs to be updated, but that can not be done overnight.
    Thanks in advance
    Dave

    Being pretty new to programming, I am trying just to read info from Paradox tables with C#. Info is actively being updated from another program at the same time. The program I am trying to write only needs to read data. The other program does use the BDE,
    so it is already present running on the computer.
    I've been looking at code but just haven't found quite the right combination.
    Thanks. Any help is greatly appreciated.

Maybe you are looking for