Agilent E3631A issues

VISA; TCP/IP, CAN and similar protocols
Ответить
Chess
interested
interested
Сообщения: 6
Зарегистрирован: 01 ноя 2012, 18:45
Версия LabVIEW: 2011
Контактная информация:

Agilent E3631A issues

Сообщение Chess »

Hello to all, I am the new one :)

I am also relatively new to labview and trying to control my Agilent E3631A Power Supply via USB, but am having some issues at the moment.

Here is what I did: (just in order to make sure I didn't miss any important steps..)

I got myself a serial-usb-adapter and installed the drivers for it.
Then I downloaded the labview driver for my power supply
( http://sine.ni.com/apps/utf8/niid_web_d ... 03BA7CCD71 )
In unzipped the folder, which contained the tree and some example VIs.

When I plug my power supply into the USB it appears in MAX as COM8
So I opened the example VI for simple DC power output, selected COM8 from the dropdown menu and hit run.
About 30 seconds later I get the error: "VISA: (Hex 0xBFFF000E) The given session or object reference is invalid."

If you know why this happens or have an idea what I could try please answer, I really need to get this running...

Regards and thank you very much in advance,
Chess
Аватара пользователя
Eugen Graf

Activity Professionalism Silver Black
guru
guru
Сообщения: 6502
Зарегистрирован: 13 ноя 2007, 02:20
Награды: 4
Версия LabVIEW: 2009
Откуда: Saarbrücken
Контактная информация:

Re: Agilent E3631A issues

Сообщение Eugen Graf »

Hi Chess!

You can try the low debug mode (the yellow lamp in the Block Diagramm top menue) to look where and why the error happens.
Chess
interested
interested
Сообщения: 6
Зарегистрирован: 01 ноя 2012, 18:45
Версия LabVIEW: 2011
Контактная информация:

Re: Agilent E3631A issues

Сообщение Chess »

Hi Eugen,

I tried that before, but it did not really enlighten me..
At first I have a green arrow over the initialize sub VI, and then all the other Sub VIs show errors.

Does that help?

Thank you very much,
Chess
Аватара пользователя
Eugen Graf

Activity Professionalism Silver Black
guru
guru
Сообщения: 6502
Зарегистрирован: 13 ноя 2007, 02:20
Награды: 4
Версия LabVIEW: 2009
Откуда: Saarbrücken
Контактная информация:

Re: Agilent E3631A issues

Сообщение Eugen Graf »

Ok, it fails on the initialisation. That means:

device is not connected
device is not switched on
no connection to device
wrong settings, such the baud rate or parity or hardware handshake and so on.
If you have a test software delivered with the device, try to run it nad establish communication without :labview:

Regards, Eugen
Chess
interested
interested
Сообщения: 6
Зарегистрирован: 01 ноя 2012, 18:45
Версия LabVIEW: 2011
Контактная информация:

Re: Agilent E3631A issues

Сообщение Chess »

Hello Eugen,

thanks for the response!

The device is connected and it is switched on. I have tried enabling or disabling the output, but that did not change anything.

I have checked the settings I could find in MAX (which were Baud Rate, Data bits, Parity , Stop Bits and Flow control.) and they match the requirements I found in the manual of my power supply.
(I could however not find where to find the start bits in MAX (The manual says I need 1 start bit and 2 stop bits...)
When I click validate it says that all the parameters are valid, and that it successfully opened a VISA session to "ASRL8::INSTR"

Which other settings could be wrong? (I did not find the setting "hardware handshake" anywhere..)

Unfortunately I do not have any additional software for the device. If there was additional software, it has been lost long ago, and I didn't find any testing software on the Agilent website.
I tried however accessing it via HyperTerminal, but I was not able to open a connection to the device.
(I did not find HyperTerminal on my PC, so I downloaded the Hyper Terminal Private Edition Trial)

I also tried to access it through the MAX VISA test panel by sending clicking *IDN?\n and I get the following response:

The big window says:

1: Write Operation (*IDN?\n)
Return Count: 6 bytes

and "Return Data" says:

Write Operation (*IDN?\n)
No Error

If everything else fails, could I write my own VISA driver? I have never done this, nor have I any experience with VISA at all, but I really need to get this running..

Regards, Chess
Аватара пользователя
mzu2006

Professionalism Tutorials Black
doctor
doctor
Сообщения: 2456
Зарегистрирован: 16 авг 2008, 02:12
Награды: 3
Версия LabVIEW: 7.1 10 11 12
Откуда: St-Petersburg (RU), Phila, Boston, Washington DC
Контактная информация:

Re: Agilent E3631A issues

Сообщение mzu2006 »

[quote="Chess"]When I plug my power supply into the USB it appears in MAX as COM8{/quote]
Did you mean "When I plug my USB-to-serial"?

The device comes equipped with GPIB and RS-232. p48 of the manual says "The GPIB interface is selected when the power supply is shipped
from the factory". Did you switch it to RS-232 as directed on p.48-52?
jg69

Professionalism
developer
developer
Сообщения: 265
Зарегистрирован: 14 окт 2008, 00:09
Награды: 1
Версия LabVIEW: 8.x, 20x

Re: Agilent E3631A issues

Сообщение jg69 »

Chess
interested
interested
Сообщения: 6
Зарегистрирован: 01 ноя 2012, 18:45
Версия LabVIEW: 2011
Контактная информация:

Re: Agilent E3631A issues

Сообщение Chess »

Hello to everyone,

I am very sorry, I did not know that crossposting was a fauxpas. *embarrassed
But I did not mean to play someone off against someone else at all. And as soon as the problem is solved, I will post it everywhere I asked for help, so that no one tries to help me with a solved problem.
I am very grateful that you try helping me with this problem and I am really sorry for the crossposting!


Fortunately I have two power supplies of the same model, which react just the same, so I don't think it is a hardware problem with the power supply. At the moment I have connected one via RS - 232 and one via the USB adapter to see how they behave..

I have solved one problem by now. (Thanks to mzu2006 :) Thanks Mzu!) I really did not realize that the supplies factory setting was HPIB / 488 (I am a bit embarrassed..) As soon as I had changed this in the settings of the device, I was able to get it's ID via *IDN? in MAX.

However the device I am controlling via USB is still uncooperative... I have not yet been able to make it respond..

One of my approaches was it, that the interconnected adapter disturbs the IDN - transmission, or even brings in it's own IDN. So I tried switching off the ID query in the initialize Sub VI. This seemed to work, but the next error appeared when it tried to reset.

So I began taking a closer look at the driver in Highlight Execution mode and started decoupling all the stuffs which made problems:

Setting the ID Query? to NO
Setting Reset? to NO
And then I had to remove the error query (even if I feel kind of bad about just removing the error query..)
That made the initialize sub VI run.

After that I had to remove the error queries from the Configure Output and the Configure Current Limit as well, which made these work too.

I don't know whether this strategy would have been successful, because at the moment I am having trouble with the Read Output VI, where "VISA Read" gives me an error. I really don't know how to solve this, and am pretty sure that a simple decoupling would not be a good idea.. ;)

Does anybody have an idea why I am not able to get the IDN via MAX, or whether there is any use in rebuilding the driver at all?

Thank you all, and sorry for the crossposting again.,
Chess

Crossposts:
http://forums.ni.com/t5/LabVIEW/Agilent-...ue#M705080
http://www.labviewforum.de/Thread-Agile ... er-Labview
Аватара пользователя
mzu2006

Professionalism Tutorials Black
doctor
doctor
Сообщения: 2456
Зарегистрирован: 16 авг 2008, 02:12
Награды: 3
Версия LabVIEW: 7.1 10 11 12
Откуда: St-Petersburg (RU), Phila, Boston, Washington DC
Контактная информация:

Re: Agilent E3631A issues

Сообщение mzu2006 »

Removing the error query will not get you far. I see troubleshooting by elimination sequence as follows:

1. Is the driver for usb-to-rs232 properly installed (device manager)
2. Assuming you can communicate with some power supply using RS232. Connect this very power supply to USB-to-rs232 (without powering it off). Can you communicate?
3. If no, When you reconnect this very power supply to real RS232, can you communicate as you used to be able to? (Safety check)
4. If yes, try to connect USB-2-RS232 to something else presumably working (old COM port mouse or old modem would do). Check communication
5. if no luck, then USB-RS232 is malfunctioning
6. otherwise, power supply is incompatible with this particlular USB-to-RS232


PS.
Chess, crossposting itself does not constitute a fauxpas, but next time, please, as a matter of common courtesy, provide links to the x-posted topics on other forums.(like you already did). We are all volunteers here, so it helps us to make better usage of our time without having to reinvent the wheel.
Chess
interested
interested
Сообщения: 6
Зарегистрирован: 01 ноя 2012, 18:45
Версия LabVIEW: 2011
Контактная информация:

Re: Agilent E3631A issues

Сообщение Chess »

Hello Mzu,

The device pops up as Prolific USB-to-Serial Comm Port, so I assume the drivers work correctly.

I tried communicating with it via RS 232, which worked properly. It did however not work via USB and the adapter.. Reconnected via RS232 it worked again.

I do not have an old RS 232 device at the moment, but I will come up with something..

However, I have made the mistake by connecting just with a gender changer. Do you think I might need a NULL-modem?

Thanks for your help,
Chess
Аватара пользователя
mzu2006

Professionalism Tutorials Black
doctor
doctor
Сообщения: 2456
Зарегистрирован: 16 авг 2008, 02:12
Награды: 3
Версия LabVIEW: 7.1 10 11 12
Откуда: St-Petersburg (RU), Phila, Boston, Washington DC
Контактная информация:

Re: Agilent E3631A issues

Сообщение mzu2006 »

Chess писал(а):I have made the mistake by connecting just with a gender changer. Do you think I might need a NULL-modem?
Use whatever cable you used when connecting it to regular RS-232
Chess
interested
interested
Сообщения: 6
Зарегистрирован: 01 ноя 2012, 18:45
Версия LabVIEW: 2011
Контактная информация:

Re: Agilent E3631A issues

Сообщение Chess »

Hello mzu,

that solved the problem!

Obviously the RS323 to RS232 Wire I was using to control the power supply contains a NULL modem
(which I would never have suspected, because it is not written on it or sth. like that.. )

So my first fault were the front panel settings, and my second one was a missing NULL modem. I am a bit embarassed again..

Thank you so much for your help!!

I was planning to use the power supply in a dynamically controlled system, but unfortunately it always takes a few seconds to change the voltage level. I fear this might not be fast enough for my system. Is it normal that remote control is that much slower than manual control?

Thanks again,
Chess
Ответить

Вернуться в «Communcation with devices»