LabVIEW Programming Real-time Control of KEITHLEY 6517A Electrometer

Publisher:chunxingLatest update time:2011-11-30 Keywords:LabVIEW Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

LabVIEW Programming Real-time Control of KEITHLEY 6517A Electrometer

Based on the GPIB interface bus, the simplest button commands in 6517A are used to realize real-time control of 6517A panel operations and synchronous display of information on the LabVIEW5.1 platform.
Keywords: LabVIEW programming; computer simulation; 6517A electrometer

Hefei 230029, China)
LabVIEW provides a way for any program to call another LabVIEW program, that is, to use the latter as a subroutine (i.e., subVI). Therefore, in the main data acquisition program of the experimental station, the simulated 6517A is embedded as a subVI called by the main program (of course, this subroutine can run independently without relying on the main program). According to the requirements of the main program, the subVI of 6517A has the following characteristics:
concise code and high execution efficiency; it can fully realize the functions of each button on the real panel, and can basically display the various information displayed by 6517A synchronously; independent window, does not visually interfere with the main program window, so as to facilitate user use.
For complex uncompiled LabVIEW programs, the code is required to be as concise as possible, which is beneficial to improve the running speed. In addition, considering that the adjustment of 6517A parameters is only a small part of the data acquisition and control of the experimental station, we did not use the LabVIEW subroutine provided by KEITHLEY with the instrument. For 6517A, there are three ways to realize the functions of the panel buttons: one is to use the function selection commands in its SCPI commands, such as using various commands in the SENSe command group to select the measurement content (voltage, current, resistance and charge) and various parameters related to the measurement of these quantities [1]. This method is comprehensive and can directly realize a certain function with a sufficiently long command, which may require pressing multiple keys to realize, and the user does not need to know the display information of the 6517A front panel (the LabVIEW subroutine provided by KEITHLEY is written in this way). The disadvantage is that the code command is long and complicated to write, and all SCPI commands must be very familiar. Another way is to use the SYSTem:KEY〈NRf〉 command in the SYSTem command group. Each function key on the 6517A function panel corresponds to a number. For example, executing: SYSTem:KEY 15 is equivalent to manually pressing the V (voltage) key once. Using this method basically "copies" the buttons on the front panel on the computer monitor. Although setting a parameter requires multiple button presses and the selection menu needs to be displayed synchronously on the computer, the code is concise and the interface function provided by LabVIEW can be used to completely simulate the front panel of 6517A in appearance. It is a good method. The third method is to use DDC language, which has a concise syntax, but is difficult to remember, difficult to maintain, and not powerful. We did not consider it when writing. ?
The entire 6517A subroutine is a large whileloop. Within the loop are the commands and display subroutines corresponding to all the buttons on the front panel. The condition for the loop to end is that the Boolean button "RETURN" = false. This structure has two functions. Since the execution of the LabVIEW program is parallel, it can accept commands from any virtual button at any time. The other is that the display on the computer screen is basically synchronized with the display of the electrometer. The subroutine is set to "open when called and close after completion", which does not visually affect the use of the main program. That is, after pressing RETURN, the subroutine window is closed.
2.2 Buttons
Figure 1 is the interface of the 6517A subVI. The character "Ω" in the figure has been replaced by "Ohm". It tries to imitate the front panel of the actual instrument, except that the POWER switch of the 6517A is replaced by the RETURN button. The mechanical action of each button is set to "Latch when Released", so that every time the button in the figure is pressed, the program sends a corresponding command to the 6517A through the GPIB interface to complete the manual key press action. Then the button floats up and will not cause malfunction. The program corresponding to the button is a "true?false" case structure. Write the command in True CASE: SYSTem: KEY 〈NRf〉 (Figure 2), and leave it blank in False CASE. When you click the button with the mouse, 6517A will complete the corresponding key action according to the command. As shown in the command in the figure, the GPIB write control sends: SYST: KEY 15 to 6517A, and it is completed by pressing the "V" key once.

?
In order to better display the unit of the measured value, the 6517A display line has some special symbols, such as the temperature symbol ℃ on the secondary display line, the resistance unit Ω (ohm) on the main display line, and the magnitude unit μ (i.e., 10-6). However, actual tests show that the signal received by the computer from the 6517A can only correctly display the numbers 0 to 9, letters A to B and a to b in the standard ASCII code. Therefore, using only the above command will display garbled characters and cannot correctly reflect all the display information of the 6517A. After analysis, the author obtained the corresponding encoding of non-ASCII codes after passing through the GPIB interface as follows (Table 1).
?

The RETURN key is the logical quantity that controls the entire subroutine. However, this also brings a problem. When the program is running, it is found that after the first parameter setting is completed and the subroutine is exited, RETURN may still remain in the false state. Then, when the subroutine is called for the second time, it will not be able to enter the loop (or will only loop once) because RETURN=false. For this reason, the parallel processing feature of LabVIEW is used. When RETURN is set to false, two actions will be completed. First, the logical constant True is assigned to RETURN (using local variable, which will not interfere with its function of interrupting the loop), and then the loop is exited, thus ensuring the next call.
Keywords:LabVIEW Reference address:LabVIEW Programming Real-time Control of KEITHLEY 6517A Electrometer

Previous article:Implementation methods of two check codes of Modbus protocol based on LabVIEW
Next article:Research on On-line Intermittent Turbidimeter

Recommended ReadingLatest update time:2024-11-16 19:55

Research on Data Flow Control Method in LabVIEW
0 Preface    LabVIEW (Laboratory Virtual Instrument Engineering Workbench) is the originator of the concept of virtual instruments and is the world's best virtual instrument software development platform . It uses a graphical data flow programming language. This emerging programming method has brought new difficulti
[Test Measurement]
Research on Data Flow Control Method in LabVIEW
Calculus of Expressions in LabVIEW 8.2
  The calculus operation node of the expression in LabVIEW 8.2 is located in the "Mathematics → Scripts and Formulas → Calculus" of the function palette as shown in the figure.     Calculus sub-selection panel   The Calculus palette performs calculus sweeps and calculates values ​​based on given formula expr
[Test Measurement]
Calculus of Expressions in LabVIEW 8.2
Developing a Solar-Powered Milk Refrigeration System Using LabVIEW and NI Single-Board RIO
Challenge: Develop a milk refrigeration system for rural areas in India where electricity supply is not guaranteed. Solution: A refrigeration system that uses solar energy in combination with available grid electricity by converting and storing thermal energy and releasing it when freezing the milk.    Figure 1
[Test Measurement]
Developing a Solar-Powered Milk Refrigeration System Using LabVIEW and NI Single-Board RIO
A New Method of Hybrid Processing of GHz High-Frequency Signals Using LabVIEW and MATLAB
With the continuous improvement of technological strength, the frequency of the processed signals is getting higher and higher. For example, the signal of a mobile phone is an ultra-high frequency signal of GHz. In the process of collecting such ultra-high frequency signals, the system is easily interfered by various
[Test Measurement]
A New Method of Hybrid Processing of GHz High-Frequency Signals Using LabVIEW and MATLAB
Pointer wiggling problem in Labview
      I'm learning Labview recently and I'm going to make a host computer to display the data sent by the microcontroller with an instrument in Labview. However, although the instrument responds, the pointer data keeps jumping and keeps returning to zero. It only points to the data size at the moment the data is sent,
[Test Measurement]
Pointer wiggling problem in Labview
Design and implementation of communication between industrial computer and inverter based on labview
  1 Introduction   The gearbox in a wind turbine is an important mechanical component, and the performance of the bearing plays a vital role in the performance of the gearbox. According to user requirements, the gearbox bearings must be tested on a test machine that simulates actual working conditions before leaving t
[Test Measurement]
Design and implementation of communication between industrial computer and inverter based on labview
Virtual Oscilloscope Based on LABVIEW
This program comes from the " Virtual Oscilloscope 2003" program released by an unknown predecessor. I modified its driver part so that it can be used for our USB data acquisition card (12-bit, MSP-010501). The effect after modification is quite good. I admire the predecessor who wrote this progr
[Test Measurement]
Virtual Oscilloscope Based on LABVIEW
Radar Moving Target Simulation Based on Labview
The targets detected by radar are usually moving objects, such as airplanes and missiles in the air, ships at sea, and vehicles on the ground. However, there are often various backgrounds around the targets, such as various landforms, clouds and rain, waves, and metal wire interference released by the enemy. These b
[Industrial Control]
Radar Moving Target Simulation Based on Labview
Latest Analog Electronics Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号