?? functaumg369xb_init.html
字號:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<link rel="stylesheet" href="htmlhelp.css" type="text/css">
<title>aumg369xb_init</title>
</head>
<body>
<h1>aumg369xb_init</h1>
<p class="syntax">
ViStatus aumg369xb_init (ViRsrc resourceName, ViBoolean IDQuery,
ViBoolean resetDevice, ViPSession instrumentHandle);
</p>
<h2 class="purpose">Purpose</h2>
<p class="body">
This function performs the following initialization actions:
<br/>
- Opens a session to the Default Resource Manager resource and a session to the specified device using the interface and address specified in the Resource_Name control.
<br/>
- Performs an identification query on the Instrument.
<br/>
- Resets the instrument to a known state.
<br/>
- Sends initialization commands to the instrument that set any necessary programmatic variables such as Headers Off, Short Command form, and Data Transfer Binary to the state necessary for the operation of the instrument driver.
<br/>
- Returns an Instrument Handle which is used to differentiate between different sessions of this instrument driver.
<br/>
- Each time this function is invoked an Unique Session is opened. It is possible to have more than one session open for the same resource.
<br/>
Notes:
<br/>
(1) If this instrument does not support an ID Query, and the ID Query control is set to "Do Query" then this function should return the Warning Code 0x3FFC0101 - VI_WARN_NSUP_ID_QUERY.
<br/>
(2) If this instrument does not support a Reset, and the Reset control is set to "Reset Device" then this function should return the Warning Code 0x3FFC0102 - VI_WARN_NSUP_RESET.
</p>
<h2>Parameters</h2>
<table class="borderless" summary="Parameter help">
<tr>
<td valign="top"><em class="label">Input</em></td>
</tr>
<tr>
<td class="tablehead">Name</td>
<td class="tablehead">Type</td>
<td class="tablehead">Description</td>
</tr>
<tr>
<td class="paramName">resourceName</td>
<td class="paramDataType">ViRsrc</td>
<td>
<p class="body">
This control specifies the interface and address of the device that is to be initialized (Instrument Descriptor). The exact grammar to be used in this control is shown in the note below.
<br/>
Default Value: "GPIB0::5::INSTR"
<br/>
Notes:
<br/>
(1) Based on the Instrument Descriptor, this operation establishes a communication session with a device. The grammar for the Instrument Descriptor is shown below. Optional parameters are shown in square brackets ([]).
<br/>
Interface Grammar
<br/>
------------------------------------------------------
<br/>
GPIB GPIB[board]::primary address[::secondary address]
<br/>
[::INSTR]
<br/>
The GPIB keyword is used with GPIB instruments.
<br/>
The default value for optional parameters are shown below.
<br/>
Optional Parameter Default Value
<br/>
-----------------------------------------
<br/>
board 0
<br/>
secondary address none - 31
</p>
</td>
</tr>
<tr>
<td class="paramName">IDQuery</td>
<td class="paramDataType">ViBoolean</td>
<td>
<p class="body">
This control specifies if an ID Query is sent to the instrument during the initialization procedure.
<br/>
Valid Values:
<br/>
VI_FALSE (0) - Skip Query
<br/>
VI_TRUE (1) - Do Query (Default Value)
<br/>
Notes:
<br/>
(1) Under normal circumstances the ID Query ensures that the instrument initialized is the type supported by this driver. However circumstances may arise where it is undesirable to send an ID Query to the instrument. In those cases; set this control to "Skip Query" and this function will initialize the selected interface, without doing an ID Query.
</p>
</td>
</tr>
<tr>
<td class="paramName">resetDevice</td>
<td class="paramDataType">ViBoolean</td>
<td>
<p class="body">
This control specifies if the instrument is to be reset to its power-on settings during the initialization procedure.
<br/>
Valid Values:
<br/>
VI_FALSE (0) - Don't Reset
<br/>
VI_TRUE (1) - Reset Device (Default Value)
<br/>
Notes:
<br/>
(1) If you do not want the instrument reset. Set this control to "Don't Reset" while initializing the instrument.
</p>
</td>
</tr>
<tr>
<td valign="top"><em class="label">Output</em></td>
</tr>
<tr>
<td class="tablehead">Name</td>
<td class="tablehead">Type</td>
<td class="tablehead">Description</td>
</tr>
<tr>
<td class="paramName">instrumentHandle</td>
<td class="paramDataType">ViSession (passed by reference)</td>
<td>
<p class="body">
This control returns an Instrument Handle that is used in all subsequent function calls to differentiate between different sessions of this instrument driver.
<br/>
Notes:
<br/>
(1) Each time this function is invoked a Unique Session is opened. It is possible to have more than one session open for the same resource.
</p>
</td>
</tr>
</table>
<h2>Return Value</h2>
<table class="borderless" summary="Return value help">
<tr>
<td class="tablehead">Name</td>
<td class="tablehead">Type</td>
<td class="tablehead">Description</td>
</tr>
<tr>
<td class="paramName">status</td>
<td class="paramDataType">ViStatus</td>
<td>
<p class="body">
This control contains the status code returned by the function call.
<br/>
Status Codes:
<br/>
Status Description
<br/>
-------------------------------------------------
<br/>
0 No error (the call was successful).
<br/>
3FFC0101 ID Query not supported - VI_WARN_NSUP_ID_QUERY
<br/>
3FFC0102 Reset not supported - VI_WARN_NSUP_RESET
<br/>
3FFC0103 Self Test not supported - VI_WARN_NSUP_SELF_TEST
<br/>
3FFC0104 Error Query not supported - VI_WARN_NSUP_ERROR_QUERY
<br/>
3FFC0105 Revision Query not supported - VI_WARN_NSUP_REV_QUERY
<br/>
3FFF0005 The specified termination character was read.
<br/>
3FFF0006 The specified number of bytes was read.
<br/>
BFFC0001 Parameter 1 out of range.
<br/>
BFFC0002 Parameter 2 out of range.
<br/>
BFFC0003 Parameter 3 out of range.
<br/>
BFFC0004 Parameter 4 out of range.
<br/>
BFFC0005 Parameter 5 out of range.
<br/>
BFFC0006 Parameter 6 out of range.
<br/>
BFFC0007 Parameter 7 out of range.
<br/>
BFFC0008 Parameter 8 out of range.
<br/>
BFFC0011 Instrument returned invalid response to ID Query
<br/>
BFFF0000 Miscellaneous or system error occurred.
<br/>
BFFF000E Invalid session handle.
<br/>
BFFF0015 Timeout occurred before operation could complete.
<br/>
BFFF0034 Violation of raw write protocol occurred.
<br/>
BFFF0035 Violation of raw read protocol occurred.
<br/>
BFFF0036 Device reported an output protocol error.
<br/>
BFFF0037 Device reported an input protocol error.
<br/>
BFFF0038 Bus error occurred during transfer.
<br/>
BFFF003A Invalid setup (attributes are not consistent).
<br/>
BFFF005F No listeners condition was detected.
<br/>
BFFF0060 This interface is not the controller in charge.
<br/>
BFFF0067 Operation is not supported on this session.
<br/>
Notes:
<br/>
(1) Parameter Error Codes for parameters 1 through 8 are defined in the vpptype.h header file the range is BFFC0001 - BFFC0008;
</p>
</td>
</tr>
</table>
<h2>References</h2>
<p class="body">
<a href="Anritsu%20MG369XB%20Synthesizer.html">Anritsu MG369XB Synthesizer</a><br/>
<a href="Alphabetical%20Function%20Index.html">Alphabetical Function Index</a><br/>
<a href="Hierarchical%20Function%20Index.html">Hierarchical Function Index</a><br/>
</p>
</body>
</html>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -