是德科技
直播中

陈蕾

7年用户 248经验值
私信 关注
[问答]

N5182B上的GPIB连接错误

嗨我有一个关于在PC和MXG N5182之间建立GPIB连接的问题我正在考虑将多个波形文件上传到MXG。
我只是检查API参考,解释了在MXG和PC之间打开GPIB端口的方法(我使用的是VB.NET)我只是按照API示例例如,Dim Bin1Wav As New CCWAPI.AgtPBProject Bin1Wav.SignalGenerator.SetConnectionGPIB(0,19,
0)但是,我得到连接错误,它说“AgtPulseBuilding.Engine.Exception.InvalidSGException:没有检测到信号发生器连接:..”我不确定为什么会发生这种情况是因为当我执行代码时,MXG进入远程
模式。
这意味着VB.NET代码和SetConnectionGPIB函数正在MXG和Desktop之间建立GPIB连接。
我附上了错误的屏幕截图有人知道如何解决这个问题吗?
谢谢

以上来自于谷歌翻译


     以下为原文

  Hi  

I have a question about establishing GPIB connection between PC and MXG N5182

I am thinking to uploading multiple wave form files to MXG.

I just check API references which explain the way to open GPIB port between MXG and  PC( I am using VB.NET)
  
I simply follow API example

For example,  

  Dim Bin1Wav As New CCWAPI.AgtPBProject
  Bin1Wav.SignalGenerator.SetConnectionGPIB(0, 19, 0)

However, I am getting connection error
it says " AgtPulseBuilding.Engine.Exception.InvalidSGException: No Signal Generator Connection Detected:.."


I am not really sure why this happen this is because when I execute code, MXG is getting into remote mode. Which means that VB.NET code and SetConnectionGPIB function is establishing GPIB connection between MXG and Desktop.

I have attached screenshot of error  

Do anybody know how to fix this issue ?

thanks   
附件

回帖(1)

杨梅

2018-10-29 16:14:54
VB.net,我通常会开始这样的程序,我假设您安装了Agilent I / O库?
www.agilent.com/find/iosuite'''''''''''''''''''''''''''
“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”“”
''''''''''''''''''''''''''Imp Imp Imp Imp Imp In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In In
:INSTR“Dim oRm As New ResourceManagerClass()Dim FGEN As New FormattedIO488Class()'打开仪器的会话。
FGEN.IO = oRm.Open(instAddress,AccessMode.NO_LOCK,10000,“”)FGEN.IO.Timeout = 10000'查询Idendity字符串和报告。
FGEN.WriteString(“* IDN?”,True)Dim strResult As String = FGEN.ReadString()Console.WriteLine(“Instrument Identity String:”+ strResult)'清除并重置仪器FGEN.WriteString(“* CLS; * RST
; * OPC?“,True)FGEN.ReadString()

以上来自于谷歌翻译


     以下为原文

  VB.net,  I usually start out my programs like this, I assume you have Agilent I/O libraries installed?  www.agilent.com/find/iosuite

''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

Imports System.Text
Imports Ivi.Visa.Interop

Dim instAddress As String = "GPIB0::22::INSTR"
        Dim oRm As New ResourceManagerClass()
        Dim FGEN As New FormattedIO488Class()

        'Open session for instrument.
        FGEN.IO = oRm.Open(instAddress, AccessMode.NO_LOCK, 10000, "")
        FGEN.IO.Timeout = 10000

        'Query Idendity string and report.
        FGEN.WriteString("*IDN?", True)
        Dim strResult As String = FGEN.ReadString()

        Console.WriteLine("Instrument Identity String: " + strResult)

        'Clear and reset instrument
        FGEN.WriteString("*CLS;*RST;*OPC?", True)
        FGEN.ReadString()
举报

更多回帖

发帖
×
20
完善资料,
赚取积分