Quantcast
Channel: Instrument Control (GPIB, Serial, VISA, IVI) topics
Viewing all 5662 articles
Browse latest View live

RS232 Keithley 2420 labview error

$
0
0

Hello,

 

I was hoping someone might be able to help me interface a Keithley 2420 with labview 2013 via RS232.

 

I have installed the driver details through labview, and they were successfully installed. However, when I try to run one of the examples provided (ReadSingle for example), the operation time-out and I am presented with the error message attached. This happens even if I extend the timeout period. I have checked that the Baud rate etc match on both sides.

 

In addition to this the Keithley occassionally flashes the error code -101, invalid character, which may or may not be related to the problem.

 

Has anyone else had a similar problem, and found a solution?

 

 

 

 


Error 1073807339 from Sartorius CP225D Labview control program

$
0
0

I'm trying to use RS232-to-USB to read from Sartorius analytic balance CP225D. I built a program using the Sartorius-SBI drivers from NI. 

However, whenever I run the program, it always gives the error 1073807339. Sometimes, I can obtain several correct measurement data and then it suddenly outputs error. 

 

Alternatively, we have been using the software called Winwedge (http://www.taltech.com/winwedge) to read data from the balance and it has actually been working. I'm working on the Labview program because I need to synchronize multiple instruments and Winwedge is not going to help with that. That said, I believe the program is not in the balance, and I've matched baud rate, parity, data bits and stop bits in each program. But it still doesn't work. 

 

Can anyone suggest what could be wrong?

 

Controlling Valco Universal Actuator (USB to USB Interface)

$
0
0

Hello, 

 

I apologize in advance for my lack of computer/LabVIEW experience.  Hopefully my problem has a straightforward solution that I'm just missing.

 

I'm trying to connect a Valco multiposition universal actuator to a computer to be controlled via LabVIEW.  The model I have has a USB port and I'm connecting it to my computer via a USB to USB cable.  Before I plugged in my device, I installed this USB driver from Valco's website:  http://www.vici.com/support/download.php

 

My device shows up in both device manager and in MAX as "Com 8."  It says in device manager that it is working properly.  However, when I go to Instrument I/O in LabVIEW, there is no driver for my universal actuator and it says there are "no connected devices."  I searched for Valco drivers on the LabVIEW website and could not find any.  

 

Another odd thing I noticed is that when I look at the properties of my device in device manager, two device functions show up:  USB Serial Converter and USB Serial Port (COM 8).  Not sure if that's normal or not but I just thought I'd mention it.  

 

Here is the manual for the product:  http://www.vici.com/support/tn/tn415.pdf

 

Sorry if this description isn't detailed enough.  I guess if anyone could point me in the right direction as far as establishing communication with my device and getting LabVIEW to recognize it, that would be great.

 

Thanks so much in advance!

 

Laura 

PCII, PCIIA, or AT-GPIB

$
0
0

I have some old calibration software (Tektronix) that was used in the mid 1990s. It gives me two choices for the GPIB card to use for talking to the scope:

PCII

PCIIA

 

This particular PC is running XP, and I have a PCI-GPIB card installed.

 

I also have an old ISA card, AT-GPIB 181060-01 Rev. C2 on the shelf. (I don't even know if this PC has an ISA slot).

 

 

The cal software will not work with the installed PCI-GPIB, as configured.

 

Can anyone tell me if either the PCI-GPIB or the AT-GPIB card should work if the cal software is looking for a PCII or PCIIA?

 

Thanks -

Dan

xbox controller recognition

$
0
0

I have an Xbox 360 controller operating a downloaded sample .vi with great success in windows xp and Labview 2010. Moving to Win 8.1and Labview 2012 or 2014, the program does not recognize the controller. What may have changed???

 

Thanks

Control Consort EV232 power supply via RS-232

$
0
0

Hello there,

 

I'm completely new to the world of Labview. I've started an internship yesterday in a protein engineering lab and my first duty is to create a Labview interface that enables us to control a power supply (namely Consort EV232) for an electrophoresis application. The power supply is connected to a MOXA multiport serial board via RS-232, which is in turn connected to the PC.

 

Like I said, I'm completely new to Labview, having only done some really basic programming in class. I've never had the occasion to touch any hardware and am completely at a loss at how to tell the PC or Labview to connect to the power supply and I haven't found any driver that fits the power supply. I'm aware that this is a really basic question, please bear in mind that I really don't know where to start.

 

Have a nice day.

Eurotherm 2404 RS232

$
0
0

Hello all,

Another day, another problem with my serial connections!

I am trying to log the reading from a Eurotherm 2404 using the driver linked through the NI website (NI Driver). The baud rate, data bits, parity, and stop bits are set at 9600, 7, even, 1, as specified by the instrument I am using. However I cannot get the VIs to work properly, and have traced the error to the VISA read serial. When I try to query the device through MAX, I just get a time out error again.

I have tried both null modem and straight through cables. Does anyone have any other suggesitons for things to try?

How to add a save button on front panel for saved waveform data

$
0
0

Hi, I am kind of new to LabVIEW and I have been working on a code for an agilent oscilloscope to communicate via GPIB and so far this runs smoothly on gathering both analog channels one by one, "Not simoultaneously" but it does the trick (vpp,vrms, frequency...etc.).  I added feature to add waveform data to a .csv file (Problem: a dialog box opens before user gathers all data. Solution:  I want the user to save the .CSV file whenever he wants to for future reference on front panel). I added another feature to get a snapshot of the waveform graph (Problem: a dialog box opens. Solution: I want the user to save the JPEG file whenever he wants to take a snapshot ("take snapshot" button on front panel)).  I am working with hp54645d agilent driver. I have attached my code, if someone can please tell me how I need to do this (maybe wiring and structures are solutions don't know). Thank You in Advance.


download NIDAQmx.lib

$
0
0

I have re-installed NIDAQ multiple times, making sure ANSI-C support was included.  NIDAQmx.h is installed, but NIDAQmx.lib is not!  Can I just download the .lib?  I am running version 14.0 f1.

where can i find ni4882.h for gcc compiler?

$
0
0
I have c code compiled on MS visual Studio 2010. Now I need to recompile same code with gcc. But I think ni4882.h is not being linked correctly. Where can I find ni4882.h for gcc compiler? I am using MingW on my windows 8 PC.

Reading from sensor to LabView via rs232 or subVI problem

$
0
0

I'm quite new to LabView and not too experienced with instrument control so I was wondering if someone could help me solve my problem?

 

Currently, I'm using 2011 LabView and am trying to read pressures from Pfeiffer's DualGauge pressure sensor (TPG 262) and display the two pressure readings on LabView.  However, when I run my program, the pressure readings are not displayed-- all that is displayed are the default 0.00mBar pressure reading even though the DualGauge sensor's screen displays a reading.  To connect the sensor, I'm using a RS232 cable and have been successful in finding the device on my Device Manager, so I don't think the connection is the problem (I've also seen the port show up in Device Manager when I connected the sensor via RS232 and USB into my computer).  I'm also using Pfeiffer's subVI's in my code, and I suspect that the problem may be in there. 

 

 

Attached is my code and here are the links to the DualGauge manual and LabView software driver from Pfeiffer

 

Dual Gauge Manual-- Pg. 23 and 68 are probably the only things related to the RS232 connection. 

http://www.idealvac.com/files/brochures/Pfeiffer_TPG262_Operating_Instructions.pdf

 

Pfeiffer's DualGauge LabView driver-- Software Dual Gauge LabView Driver 2009

http://www.pfeiffer-vacuum.com/products/measurement/activeline/measurement-equipment/onlinecatalog.action?detailPdoId=3357#product-downloads

 

 

Any help is great appreciated!

-Candice

VISA Serial Write Binary File aborted

$
0
0

I have built a VI to communicate with a UUT (unit under test) over a serial port. The read and write are working properly, but I am having problems with using this port to transfer a binary file. I am attempting to automate an existing procedure performed with hyperterminal which uses the "send file" function with the "ymodem"' protocol setting.

 

There is no error when attempting to use "VISA write from file", and I have verified that the file size & bytes transferred are both 21862 bytes (from "Get file size" and "VISA write from file"). However, the UUT replies with a message that the operation was aborted by the user. I have also attempted to use "VISA Write", but I get the same results (Big or Little Endian).

 

Questions:

1) What changes do I need to make for this to work like Hyperterminal in "ymodem" protocol?

2) Do I need to modify the file before sending?

3) Do I need to send the file 1024 bytes at a time, appending the last message with null bits to make it come out to an even 1024 bytes?

4) Do I need to precede the file with a special header?

 

I have attached 2 pictures of example VIs to represent how I have attempted to use "VISA Write from File" and "VISA Write". The actual VI is built as an event handler driven producer-consumer.

 

======================

Example UUT Response:

======================

 

Erasing 450560 bytes at SPI Flash address 0x180000
Waiting for the file to be sent ... (press 'a' to abort)
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC

Aborted by user.

OK

err[20:49:37] RCVR: No Updates - Restart

 

======================

 

 

Best Regards,

 

Sam Broyles

 

 

control NCD relay via USB

$
0
0

Hi,I need to use Labview to control National Control Device (NCD) ProXR relays via USB ComPort. NCD doesn't support the instrument driver now. Did anyone ever successfully control the 8 relays ? Can you share your VI source code? Thank you for your kind help.

 

Infinity 1-1c camera control with labview

$
0
0

Hi Everyone,

 
Recently, I try use labview to control my camera (Infinity 1-1C). I installed 2010 labview plug-in for camera, and my labview and vision was 2013 at that time. When I tried ran the Snapshot example VI, the warning said the data types are different, please see attachments. Then
I installed labview 2010 version instead of 2013 version, the problem is solved, the run arrow not broken again. 
What's the difference between labview 2010 and labview 2013, why the 2010 version is compatible with 2010 plug-in for camera, 2013 version isn't compatible? 
 
Anothering thing is the technician told me NI company wrote this plug in. so I have a detail question about the snapshot example in this plug in. When I ran this example in labview 2010 with grayscale image format setting, the programming works, and I got image. But when I set the image format as 32 RGB since Infinity 1-1C can get colorful image with 32 RGB, the programming gave a error. The error said: 5100 occurred at LvLuConvImg.vi. So I opened LvLuConvImg.vi, and changed the Bayer setting, but it still not works. 
 
Would you please give me some suggestions about these questions in detail? That's would be very helpful.
 
Thank you very much, and I really appreciated it.

Programming Keysight N5245A to Freq & Pwr Sweep and save S-parameters in mdif file

$
0
0

Good evening, I am looking for a little direction here. I am attempting to use LabView to frequency & power sweep an amplifier and save the resulting data as a mdif file.

I wiould like to the device to perform a frequency sweep at a power level and then step up to the next power level and sweep in frequency again. I would like to sweep from 6-10GHz and from -30 to -10dBm.

Attached is what I have come up with so far. I believe I am not on the right track. Is there anyone out there who can provide direction on the correct way to go about doing this?

 

Thank You,

Jemal

 


acquire data from oscilloscope DPO2024

$
0
0

I am trying to acquire data from oscilloscope DPO2024 using labview. I am able to do so, but my vi file works only for channel 1. Other than channel 1, it do not work and instead, it changes the setting of oscilloscope as well. Find the vi files attached.

 

Any help is much appreciated.

Control de un equipo via puerto USB

$
0
0

Hola!

 

Estoy tratando de controlar una fuente de corriente la cual está conectada via un puerto USB, la idea es controlar las rampas y la corriente inicial y final de la misma. En este momento estoy explorando algo simple lo cual es solamente leer el valor de campo, hice un par de programas sencillos pero ninguno funcionó (adjuntos y están en LabVIEW 8.5). Si alguien puede darme una mano con eso les quedo agradecido.

 

Saludos!!!

FTDI FT233h MPSEE SPI Interface

$
0
0
Hello,
I am fairly new to labview and FTDI chips. I bought ftdi UM232H module and i am trying to use SPI interface using MPSSE to control SPI device. Since i am very new to labview i decided to write simple code that could write a data in the EEPROM chip. i have downloaded the sample labview code provided in ftd website and connect them all to write a simple code so i could see the signals in the Tektronix MSO 2024 oscilliscope. I have installed correct drivers and my code compiles well. The pin configuration for ftdi UM232H to oscilliscope is (pin 7 - clock, pin 8- MOSI, pin10 - chip select and pin 6 - ground). The code can see the ftdi chip but i can't see any signals in the oscilliscope. I have attached my code in the attachment. I was wondering if someone could look at my code and say what i am doing wrong. i have attached all my codes below
 
Thank You

pyvisa RS232 to DS345 function generator

$
0
0

Hello,

 

I am attempting to control a DS345 function generator over a RS232 serial connection with PyVISA (version 1.6).  I am attempting to make an arbitrary waveform with the function generator.  All SCPI commands appear to be working, but when I try to send the raw data for the waveform, the device gives a checksum error.

 

This is especially odd as it works perfectly when I send the message over GPIB.

 

I was wondering if anybody had any experience with this sort of issue.

 

Here my code 

 

import visa
from struct import pack
from struct import unpack
import time
import array


def charge_inject():

    ADDRESS = "GPIB0::19::INSTR"
    __AMP__ = 0.1
    __OFFSET__ = 0.1
    __BURST_COUNT__ = 25
    __DATA__ = [0, 0, 100, 0, 101, -2047, 2101, 0]

    rm = visa.ResourceManager()
    ds345 = rm.open_resource('ASRL1::INSTR')

    ds345.write("*CLS") # clears registers
    ds345.write("*SRE 16") # enables "message available bit"

    ds345.write("AMPL " + str(__AMP__) + "VP") # sets amplitude
    ds345.write("OFFS %f" % __AMP__) # sets offset


    ok = ds345.query("LDWF? 1,%i" % (len(__DATA__) / 2)) # tells machine that 'len(__DATA__) / 2' vector vertices will be sent
    if str.rstrip(str(ok)) != "1": # quit if there's an error loading the waveform
        print "NOT Ready to send waveform"
        quit()
    else :
        print "Ready to send waveform"

    # creates binary data to send to the generator, including the checksum
    chksum = 0
    input = pack('h', 0)
    for i in range (1, len(__DATA__)):
        input += pack('h', __DATA__[i])
        chksum += __DATA__[i]
        print __DATA__[i]

    print chksum
    input += pack('h', chksum)
    print input
    #print chr(input)
    # write_raw is needed rather than just write, since write will try
    # to treat input as python's unicode type, which may only take
    # 8 bit values
    ds345.write_raw(input)

    #ds345.write_binary_values('', __DATA__, datatype='h')

    ds345.write("FUNC5\n") # sets to arbitrary waveform to produce output
    ds345.write("BCNT %i" % __BURST_COUNT__) # sets burst count
    ds345.write("TSRC 0") # sets trigger source to single (triggers as many as burst count)
    ds345.write("MTYP 5") # sets the type of modulation to burst modulation
    ds345.write("MENA 1") # enables modulation
    ds345.write("*TRG") # triggers burst'''

charge_inject()

 

 

Thank you

pyvisa RS232 to DS345 function generator

$
0
0

Hello,

 

I am attempting to control a DS345 function generator over a RS232 serial connection with PyVISA (version 1.6).  I am attempting to make an arbitrary waveform with the function generator.  All SCPI commands appear to be working, but when I try to send the raw data for the waveform, the device gives a checksum error.

 

This is especially odd as it works perfectly when I send the message over GPIB.

 

I was wondering if anybody had any experience with this sort of issue.

 

Here my code 

 

import visa
from struct import pack
from struct import unpack
import time
import array


def charge_inject():

    ADDRESS = "GPIB0::19::INSTR"
    __AMP__ = 0.1
    __OFFSET__ = 0.1
    __BURST_COUNT__ = 25
    __DATA__ = [0, 0, 100, 0, 101, -2047, 2101, 0]

    rm = visa.ResourceManager()
    ds345 = rm.open_resource('ASRL1::INSTR')

    ds345.write("*CLS") # clears registers
    ds345.write("*SRE 16") # enables "message available bit"

    ds345.write("AMPL " + str(__AMP__) + "VP") # sets amplitude
    ds345.write("OFFS %f" % __AMP__) # sets offset


    ok = ds345.query("LDWF? 1,%i" % (len(__DATA__) / 2)) # tells machine that 'len(__DATA__) / 2' vector vertices will be sent
    if str.rstrip(str(ok)) != "1": # quit if there's an error loading the waveform
        print "NOT Ready to send waveform"
        quit()
    else :
        print "Ready to send waveform"

    # creates binary data to send to the generator, including the checksum
    chksum = 0
    input = pack('h', 0)
    for i in range (1, len(__DATA__)):
        input += pack('h', __DATA__[i])
        chksum += __DATA__[i]
        print __DATA__[i]

    print chksum
    input += pack('h', chksum)
    print input
    #print chr(input)
    # write_raw is needed rather than just write, since write will try
    # to treat input as python's unicode type, which may only take
    # 8 bit values
    ds345.write_raw(input)

    #ds345.write_binary_values('', __DATA__, datatype='h')

    ds345.write("FUNC5\n") # sets to arbitrary waveform to produce output
    ds345.write("BCNT %i" % __BURST_COUNT__) # sets burst count
    ds345.write("TSRC 0") # sets trigger source to single (triggers as many as burst count)
    ds345.write("MTYP 5") # sets the type of modulation to burst modulation
    ds345.write("MENA 1") # enables modulation
    ds345.write("*TRG") # triggers burst'''

charge_inject()

 

 

Thank you

Viewing all 5662 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>