Download Print this page

UNI-T UTG1000X Series Programming Manual

Function/arbitrary waveform generator
Hide thumbs Also See for UTG1000X Series:

Advertisement

Quick Links

Programming Manual
UTG1000X Series Function/Arbitrary Waveform Generator

Advertisement

loading

Summary of Contents for UNI-T UTG1000X Series

  • Page 1 Programming Manual UTG1000X Series Function/Arbitrary Waveform Generator...
  • Page 2: Product Certification

    The information provided in this manual is subject to change without notice.  UNI-T shall not be liable for any errors that may be contained in this manual. For any incidental or  consequential damages arising out of the use or the information and deductive functions provided in this manual.
  • Page 3: Instruction Format

    SCPI SCPI (Standard Commands for Programmable Instruments) is a standardized instrument programming language that builds on existing standards IEEE 488.1 and IEEE 488.2 and follows the floating point rules of IEEE 754 standard, ISO 646 message exchange 7-bit encoding notation (equivalent to ASCII programming) and many other standards. This section introduces the format, symbols, parameters, and abbreviations of the SCPI command.
  • Page 4 Programming Manual UTG1000X Series Boolean  The available values for the parameter is “ON” ( 1)or “OFF” ( 0) . For example, :SYSTem:LOCK {{1 | ON} | {0 | OFF}}. Integer  Unless otherwise specified, the parameter can be any integer within the effective value range.
  • Page 5 Query for manufacture name, product model, product serial number and software version number. Return Format  The query returns manufacture name, product model, and product serial number. The software version is separated by dot mark. For Example  UNI-T Technologies, UTG1000X, 000000001, 00.00.01 *RST Syntax  *RST Description ...
  • Page 6 Programming Manual UTG1000X Series :SYSTem:PHASe:MODe Syntax  :SYSTem:PHASe:MODe {INDependent | SYNChronization} :SYSTem:PHASe:MODe? Description  The phase mode of the interchannel. If the mode is sync, it represents start phase of the two channels keeps synchronized. Otherwise, the phase mode is independent.
  • Page 7 Programming Manual UTG1000X Series Description  A separator of number forma for the system. Return Format  The query returns separator in system number format. For Example  :SYSTem:NUMBer:FORMat NONe Set the number format of the system to NONe. :SYSTem:NUMBer:FORMat? The query returns NONe.
  • Page 8 Programming Manual UTG1000X Series :SYSTem:CYMometer? The query returns 1. :SYSTem:CYMometer:FREQuency? Syntax  :SYSTem:CYMometer:FREQuency? Description  Acquiring the currently measured frequency of the frequency meter. Return Format  The query returns the currently measured frequency of the frequency meter in scientific notation. The unit is Hz.
  • Page 9 Programming Manual UTG1000X Series CHANnel Command It used to set the channel function of the signal source. :CHANnel<n>:MODE Syntax  :CHANnel<n>:MODE {CONTinue|MODulation|SWEep|BURSt } :CHANnel<n>:MODE? Description  Set the signal mode for the specified channel, which is CONTinue, MODulation, SWEep or BURSt.
  • Page 10 Programming Manual UTG1000X Series :CHANnel2:PA:OUTPut? The query returns 1. :CHANnel<n>:INVersion Syntax  :CHANnel<n>:INVersion {{1 |ON}|{0|OFF}} :CHANnel<n>:INVersion? Description  Turn on/off the inversion of the specified channel. <n>: Channel number, n takes value 1, 2. Return Format  The query returns the inversion status of the specified channel. 0 represents OFF, 1 represents ON.
  • Page 11 Programming Manual UTG1000X Series :CHANnel<n>:LIMit:LOWer Syntax  :CHANnel<n>:LIMit:LOWer {<voltage>} :CHANnel<n>:LIMit:LOWer? Description  Set the lower limit of amplitude for the specified channel. <voltage> represents voltage, the unit is the specified unit of the current channel. <n>: Channel number, n takes value 1, 2.
  • Page 12 Programming Manual UTG1000X Series :CHANnel<n>:LOAD Syntax  :CHANnel<n>:LOAD {<resistance>} :CHANnel<n>:LOAD? Description  Set the output load for the specified channel. <resistance> represents load resistance value, the unit isΩ. <n>: Channel number, n takes value 1, 2. Notice: The range of resistance value is 1~10000, 10000 is corresponding to high resistance.
  • Page 13 Programming Manual UTG1000X Series Continuous :CHANnel<n>:BASE:WAVe Syntax  :CHANnel<n>:BASE:WAVe { SINe | SQUare | PULSe | RAMP | ARB | NOISe | DC } :CHANnel<n>:BASE:WAVe? Description  Set the basic wave for the specified channel, which is sine wave, square wave, impulse wave, triangle wave, arbitrary wave, noise wave and DC.
  • Page 14 Programming Manual UTG1000X Series <n>: Channel number, n takes value 1, 2. Return Format  The query returns the upper limit of amplitude of the specified channel in scientific notation. For Example  :CHANnel1:BASE:PERiod 0.002 Set the output period of CH1 to 2ms.
  • Page 15 Programming Manual UTG1000X Series :CHANnel<n>:BASE:OFFSet {<voltage>} :CHANnel<n>:BASE:OFFSet? Description  Set the output DC offset for the specified channel. <voltage> represents voltage, the unit is V. The range is from 0 to the maximum DC under the current load. The maximum DC under the current load = the current load *10/ (50+ the current load) – the minimum value under the current load.
  • Page 16 Programming Manual UTG1000X Series :CHANnel<n>:BASE:DUTY Syntax  :CHANnel<n>:BASE:DUTY {<duty>} :CHANnel<n>:BASE:DUTY? Description  Set the output duty cycle for the specified channel. <duty> represents duty cycle, the unit is %. The range is 0-100. <n>: Channel number, n takes value 1, 2.
  • Page 17 Programming Manual UTG1000X Series :CHANnel<n>: RISe PULSe: Syntax  :CHANnel<n>:PULSe:RISe {<width>} :CHANnel<n>:PULSe:RISe? Description  Set the rising edge pulse width of impulse wave for the specified channel. <width> represents pulse width, the unit is S. <n>: Channel number, n takes value 1, 2.
  • Page 18 Programming Manual UTG1000X Series Modulation :CHANnel<n>:MODulate:TYPe Syntax  :CHANnel<n>:MODulate:TYPe <type> :CHANnel<n>:MODulate:TYPe? Description  Set the modulation type for the specified channel. <type>: AM|FM|PM|ASK|FSK|PSK|PWM }, which is AM, FM, PM, ASK, FSK, PSK and PWM. <n>: Channel number, n takes value 1, 2.
  • Page 19 Programming Manual UTG1000X Series For Example  :CHANnel1:MODulate:SOURce INTernal Set the modulation source of CH1 to INTernal. :CHANnel1:MODulate:SOURce? The query returns INTernal. :CHANnel<n>:MODulate:FREQuency Syntax  :CHANnel<n>:MODulate:FREQuency {<freq>} :CHANnel<n>:MODulate:FREQuency? Description  Set the modulation frequency for the specified channel’s signal. <freq> represents frequency, the unit is Hz.
  • Page 20 Programming Manual UTG1000X Series ~ 120%. <n>: Channel number, n takes value 1, 2. Return Format  The query returns the modulation depth of the specified channel in scientific notation. For Example  :CHANnel1:MODulate:DEPTh 50 Set the modulation depth for CH1 to 50%.
  • Page 21 Programming Manual UTG1000X Series :CHANnel<n>:PM:PHASe:DEV Syntax  :CHANnel<n>:PM:PHASe:DEV { <phase>} :CHANnel<n>:PM:PHASe:DEV? Description  Set the phase deviation for the specified channel output. <phase> represents phase deviation, the unit is°, the range is 0~360. <n>: Channel number, n takes value 1, 2.
  • Page 22: Frequency Sweep

    Programming Manual UTG1000X Series :CHANnel1:FSK:FREQ 2000 Set the hopping frequency of CH1 to 2KHz. :CHANnel1:FSK:FREQ? The query returns 2e+3. :CHANnel<n>:PSK:PHASe Syntax  :CHANnel<n>:PSK:PHASe { < phase >} :CHANnel<n>:PSK:PHASe? Description  Set the phase value of PSK for the specified channel. The modulation mode must be specified in advance for this command to take effect.
  • Page 23 Programming Manual UTG1000X Series < freq > represents frequency, the unit is Hz. <n>: Channel number, n takes value 1, 2. Return Format  The query returns the start frequency for the frequency sweep of the specified channel in scientific notation.
  • Page 24 Programming Manual UTG1000X Series Burst :CHANnel<n>:BURSt:TYPe Syntax  :CHANnel<n>:BURSt:TYPe {NCYC|GATe|INFinit} :CHANnel<n>:BURSt:TYPe? Description  Set the burst mode for the specified channel. There are N cycle, gating, infinite. <n>: Channel number, n takes value 1, 2. Return Format  The query returns the burst mode of the specified channel.
  • Page 25 Programming Manual UTG1000X Series For Example  :CHANnel1:BURSt:PHASe 18 Set phase of burst for CH1 to 18°. :CHANnel1:BURSt:PHASe? The query returns 1.8e+1. :CHANnel<n>:BURSt:CYCLes Syntax  :CHANnel<n>:BURSt:CYCLes <cycles> :CHANnel<n>:BURSt:CYCLes? Description  Set cycle of burst for the specified channel. < cycles >represents cycle numbers, it is integer data.
  • Page 26 Programming Manual UTG1000X Series The query returns trigger source of the specified channel. For Example  :CHANnel1:TRIGger:SOURce INTernal Set trigger source of CH1 to INTernal. :CHANnel1:TRIGger:SOURce? The query returns INTernal. :CHANnel<n>:BURSt:TRGEdge Syntax  :CHANnel<n>:BURSt:TRGEdge {RISe|FALL} :CHANnel<n>:BURSt: TRGEdge? Description  Set the trigger edge of burst mode for the specified channel. This instruction is only valid for external trigger of burst function.
  • Page 27: Setup Communication

    Programming Manual UTG1000X Series For Example  "GateVibar.bsv" :WARB1: CARRier Write basic arbitrary wave file for CH1. DISPlay Command It is used to acquire the information of signal source. :DISPlay? Syntax  :DISPlay? Description  To query the currently image data on the screen of signal source.
  • Page 28 Programming Manual UTG1000X Series c. Click to confirm to pop-out the dialogue, d. Click Unzip to decompressing files, after the decompression is completed, the installation program will execute automatically. If your computer needs to install .NET Framework4, it will installed automatically during the installation.
  • Page 29 Programming Manual UTG1000X Series f. To set the installation path, the default path is “C:\Program Files (x86)\National Instruments\”, or you can click Next to change the installation path, as shown in the following figure, g. Double click Next in the license agreement dialogue and to select“I accept the above 2 License Agreement(s).”...
  • Page 30: Connecting Device

    Programming Manual UTG1000X Series h. Click Next to start the installation. j. Restart the computer after the installation is completed. 2.Connecting Device Take USB method as an example to introduce the connection. a. Turn on the spectrum analyzer; b. Use USB wire to connect the USB Device port of the spectrum analyzer with USB Host port of the computer, as shown in the following figure, Instruments.uni-trend.com...
  • Page 31 Programming Manual UTG1000X Series c. Turn on NI MAX on the computer. The dialogue as shown in the following figure, d. Turn on the device and scroll down the options to select the spectrum analyzer’s drive, as shown in the following figure, e.
  • Page 32 Programming Manual UTG1000X Series f. Use mouse to click the option Input/Output, as shown in the following figure, g. Use mouse to click Query to query IDN of the spectrum analyzer, the query result will display at the red area, as shown in the following figure, h.
  • Page 33 Programming Manual UTG1000X Series VISA Programming Example There are some examples in this section. Through these examples, user can know how to use VISA, and it can combine with the command of programming manual to realize the control of the instrument.
  • Page 34 Programming Manual UTG1000X Series Foundation\VISA\WinNT\include), as shown in the following figure. Select "Linker-General" in attribute dialog on the left side, set the value of "Additional Library Directories" to visa32.lib, as shown in the following figure. Add file visa.h in projectname.cpp file #include <visa.h>...
  • Page 35 Programming Manual UTG1000X Series int usbtmc_test() { /** This code demonstrates sending synchronous read & write commands * to an USB Test & Measurement Class (USBTMC) instrument using NI-VISA * The example writes the "*IDN?\n" string to all the USBTMC * devices connected to the system and attempts to read back * results using the write and read functions.
  • Page 36 Programming Manual UTG1000X Series parameters in this function are reserved for future functionality. These two parameters are given the value VI_NULL. */ for (i = 0; i < int(numInstrs); i++) if (i > 0) viFindNext(findList, instrResourceString); status = viOpen(defaultRM, instrResourceString, VI_NULL, VI_NULL, &instr);...
  • Page 37 Programming Manual UTG1000X Series fflush(stdin); getchar(); return 0; int _tmain(int argc, _TCHAR* argv[]) usbtmc_test(); return 0; TCP/IP Example int tcp_ip_test(char *pIP) char outputBuffer[VI_FIND_BUFLEN]; ViSession defaultRM, instr; ViStatus status; /* First we will need to open the default resource manager. */ status = viOpenDefaultRM(&defaultRM);...
  • Page 38 Programming Manual UTG1000X Series status = viClose(instr); status = viClose(defaultRM); printf("Press Enter to exit."); fflush(stdin); getchar(); return 0; int _tmain(int argc, _TCHAR* argv[]) printf("Please input IP address:"); char ip[256]; fflush(stdin); gets(ip); tcp_ip_test(ip); return 0; C# Example Environment: Window system, Visual Studio ...
  • Page 39 Programming Manual UTG1000X Series catch (Exception ex) System.Console.WriteLine(ex.Message); void Main(string[] args) usbtmc_test(); TCP/IP Example class Program void tcp_ip_test(string ip) using (var rmSession = new ResourceManager()) var resource = string.Format("TCPIP0::{0}::inst0::INSTR", ip); var mbSession = (MessageBasedSession)rmSession.Open(resource); mbSession.RawIO.Write("*IDN?\n"); System.Console.WriteLine(mbSession.RawIO.ReadString()); catch (Exception ex) System.Console.WriteLine(ex.Message);...
  • Page 40 Programming Manual UTG1000X Series VB Example Environment: Window system, Microsoft Visual Basic 6.0.  Description: Access the instrument via USBTMC and TCP/IP, and send "*IDN?" command on  NI-VISA to query the device information. Steps:  Open Visual Basic software and create a new standard application program project.
  • Page 41 Programming Manual UTG1000X Series Dim retCount AsLong Dim status AsLong Dim instrResourceString AsString *VI_FIND_BUFLEN Dim Buffer AsString * MAX_CNT Dim i AsInteger ' First we must call viOpenDefaultRM to get the manager ' handle. We will store this handle in defaultRM.
  • Page 42 Programming Manual UTG1000X Series ' At this point we now have a session open to the USB TMC instrument. ' We will now use the viWrite function to send the device the string "*IDN?", ' asking for the device's identification.
  • Page 43 Programming Manual UTG1000X Series EndIf ' Now we will open a session via TCP/IP device status = viOpen(defaultRM, "TCPIP0::" + ip + "::inst0::INSTR", VI_LOAD_CONFIG, VI_NULL, instrsesn) If (status < VI_SUCCESS) Then resultTxt.Text = "An error occurred opening the session" viClose(defaultRM)
  • Page 44 Programming Manual UTG1000X Series Communication with the device via TCP/IP is similar with USBTMC, it need to set VISA write and read function to synchronous I/O, set LabVIEW to asynchronous IO by default. Right click on the node and select "Synchronous I/O Mode>>Synchronous" from shortcut menu to enable synchronous writing or reading of data, as shown in the following figure.
  • Page 45 Programming Manual UTG1000X Series function usbtmc_test() % This code demonstrates sending synchronous read & write commands % to an USB Test & Measurement Class (USBTMC) instrument using % NI-VISA %Create a VISA-USB object connected to a USB instrument vu = visa('ni','USB0::0x5345::0x1234::SN20220718::INSTR');...
  • Page 46 Programming Manual UTG1000X Series %Close the VISA object fclose(vt); delete(vt); clear vt; Python Example Environment: Window system, Python3.8, PyVISA 1.11.0.  Description: Access the instrument via USBTMC and TCP/IP, send "*IDN?" command on NI-VISA to  query the device information.
  • Page 47 Programming Manual UTG1000X Series Programming Application Example Configuring Sine Wave This section is to introduce how to configure the sine wave function. Explanation A sine wave has an amplitude, an offset, and a phase relative to a synchronous pulse. It can use high voltage value and low voltage value to set its amplitude and deviation.
  • Page 48 Programming Manual UTG1000X Series The following wave can set by SCPI command. The following command can generate the square wave as shown above. :CHANnel1:MODe CONTinue :CHANnel1:BASE:WAVe SQUare :CHANnel1:BASE:FREQuency 40000 :CHANnel1:BASE:AMPLitude 2 :CHANnel1:BASE:OFFSet 0 :CHANnel1:BASE:PHAse 90 :CHANnel1:BASE:DUTY 20 :CHANnel1:OUTPut ON Configuring Sawtooth Wave This section is to introduce how to configure the sawtooth wave.
  • Page 49 Programming Manual UTG1000X Series The following command can generate the sawtooth wave as shown above. :CHANnel1:MODe CONTinue :CHANnel1:BASE:WAVe RAMP :CHANnel1:BASE:FREQuency 30000 :CHANnel1:BASE:HIGH 2 :CHANnel1:BASE:LOW 0 :CHANnel1:BASE:PHAse 90 :CHANnel1:RAMP:SYMMetry 20 :CHANnel1:OUTPut ON Configuring Impulse Wave This section is to introduce how to configure the impulse wave.
  • Page 50 Programming Manual UTG1000X Series The following command can generate the impulse wave as shown above. :CHANnel1:MODe CONTinue :CHANnel1:BASE:WAVe PULSe :CHANnel1:BASE:FREQuency 100000 :CHANnel1:BASE:HIGH 2 :CHANnel1:BASE:LOW 0 :CHANnel1:BASE:PHAse 270 :CHANnel1:BASE:DUTY 20 :CHANnel1:PULSe:RISe 0.0000002 :CHANnel1:PULSe:FALL 0.0000002 :CHANnel1:OUTPut ON Configuring Arbitrary Wave This section is to introduce how to configure the arbitrary wave.
  • Page 51: Appendix 1:Key List

    Programming Manual UTG1000X Series Appendix 1:Key List Function Description Wave Wave mode Mode Output mode √ Utility System Symbol Digit key symbol Digit key decimal point NUM0 Digit key 0 NUM1 Digit key 1 NUM2 Digit key 2 NUM3 Digit key 3...