Author Topic: Free HP3478A multimeter control program.  (Read 20548 times)

0 Members and 1 Guest are viewing this topic.

Offline Ringmodulator

  • Regular Contributor
  • *
  • Posts: 124
  • Country: de
Re: Free HP3478A multimeter control program.
« Reply #25 on: September 14, 2019, 03:45:57 pm »
Hi lmester,

thank you for this programm.

It works with a Emanuele Girlando Arduino GPIB adapter.
My first contact with a Arduino board.

Could backup the cal data of my two HP 3478a.

One question: What is the "X-Ohm" measurement function?

Chris
 

Offline Miti

  • Super Contributor
  • ***
  • Posts: 1331
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #26 on: November 24, 2019, 01:59:28 pm »
I just wanted to update here that I've released what I call version 6 of the firmware for the Galvant GPIBUSB adapter. This firmware is highly compatible with the Prologix command set. You can find it here: https://github.com/steve1515/gpibusb-firmware

This firmware allows the Galvant adapter to work with the regular version of lmester's HP 3478A control program. Binary read/write works as well, so the meter calibration can be read and written.
  :)

Hi Steve,

Thanks for the new firmware!
I can confirm that it works with the regular version for reading of the calibration constants but not for writing. Can you post the interface settings and the .cfg file that works for you?

Thanks,
Miti
Fear does not stop death, it stops life.
 

Offline steve1515

  • Regular Contributor
  • *
  • Posts: 86
  • Country: us
Re: Free HP3478A multimeter control program.
« Reply #27 on: November 25, 2019, 04:18:26 am »
Hi Miti.

Below you will find what I'm using for settings.

When writing the updated firmware, I also created a program that reads/writes and displays detailed calibration information. My program is compatible with lmester's calibration files as well. Can you try out my program and see if writes are working when you use the updated firmware? lmester's program and mine should be using the same commands over GPIB. I'm interested to hear if my program works for you or also fails.

My Program: https://github.com/steve1515/hp3478a-calibration
Download: https://github.com/steve1515/hp3478a-calibration/releases

Here is what I used for settings:


Here are the contents of my config file:
Code: [Select]
5
F1
R0
N5
Z1
T1
HP3478A
log
log
0
1
1
1000
0
23
I
M
M
D1
0
D:\Downloads\HP3478A\log\
64
GPIB
460800
1
10000000
0
Unused value
Unused value
Unused value
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #28 on: November 25, 2019, 01:11:40 pm »
I've been notified that my program is not working with the current release of the ar488 Arduino firmware (0.47.53). It is working with the 0.46.03 version. Until this problem is resolved you should use the 0.46.03 ar488 firmware.
 

Offline steve1515

  • Regular Contributor
  • *
  • Posts: 86
  • Country: us
Re: Free HP3478A multimeter control program.
« Reply #29 on: November 27, 2019, 02:51:26 am »
I believe Miti is using my customized Galvant GPIB-USB firmware version 6 and not the Arduino. I just want to clear this up in case there is any confusion.
 

Offline Miti

  • Super Contributor
  • ***
  • Posts: 1331
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #30 on: November 27, 2019, 04:10:26 am »
I believe Miti is using my customized Galvant GPIB-USB firmware version 6 and not the Arduino. I just want to clear this up in case there is any confusion.

Yes, I'm using your "v6" firmware but I think lmester's comment was in general, it wasn't addressed to me. I will give your program a try in the next couple of days.
Fear does not stop death, it stops life.
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #31 on: November 27, 2019, 02:49:31 pm »
I believe Miti is using my customized Galvant GPIB-USB firmware version 6 and not the Arduino. I just want to clear this up in case there is any confusion.

Yes, I'm using your "v6" firmware but I think lmester's comment was in general, it wasn't addressed to me. I will give your program a try in the next couple of days.

Sorry for the confusion. Miti is correct. This was a general comment only for users of the Arduino with ar488 firmware. I'm working with the ar488 author to solve this problem. First will be some comparisons of the responses of my real Prologix adapter and the Arduino Prologix clone.
 

Offline Miti

  • Super Contributor
  • ***
  • Posts: 1331
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #32 on: November 28, 2019, 12:48:20 am »
Hi Steve,

I tested your program. Reading seems ok, writing is unstable. could be the interface? These are the messages that I've got:

ERROR: Failed while writing calibration data to instrument.
Extended Error Information:
Failed while verifying calibration data in instrument SRAM.

Operation completed successfully.

ERROR: Failed while writing calibration data to instrument.

Extended Error Information:
Failed while verifying calibration data in instrument SRAM.

ERROR: Failed while writing calibration data to instrument.

Extended Error Information:
Invalid GPIB adapter version string.

ERROR: Failed while writing calibration data to instrument.

Extended Error Information:
Invalid GPIB adapter version string.


ERROR: Failed while writing calibration data to instrument.

Extended Error Information:
Could not communicate with instrument.

Writing calibration data to instrument...
Operation completed successfully.

I added it to my collection of utilities anyway.
Thanks!!
Fear does not stop death, it stops life.
 

Offline steve1515

  • Regular Contributor
  • *
  • Posts: 86
  • Country: us
Re: Free HP3478A multimeter control program.
« Reply #33 on: November 28, 2019, 02:32:10 am »
Miti,

When it writes it reads back to verify. I believe it's this step that's failing. Do you have the switch on the front panel turned to cal mode? If this switch isn't turned it should cause this.

Although, if you read and then write back the exact same data, then it should succeed even if cal mode is not turned on since the verify would pass since the data is the same.

Does the data read look kind of ok? I wonder if there's an issue with your SRAM.

I wonder if anyone else would be able to try out my firmware with the Galvant just to make sure there aren't any issues. Hmm...   :-BROKE

EDIT: Just noticed that you also are getting errors getting the version string. I if you open a terminal window can you issue "++ver" and see if that works? The GPIB-USB should return a version string.

--Steve
« Last Edit: November 28, 2019, 02:35:14 am by steve1515 »
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #34 on: November 28, 2019, 03:48:42 am »
Steve,

I decided to try your software. You may be interested to know that it works good with a real Prologix adapter!

No luck with the Arduino. I had to add a delay in my code to get it to connect to the Arduino. The Arduino starts it's boot loader whenever the COM port is opened. It takes about two seconds from opening the port until the Arduino bails out of the boot loader and starts running application code.  Do you have any delay after opening the COM port?

Also, I like the way you show the cal gain and offset. If you don't mind, i'd like to use some of your code to add that feature to mine.

Code: [Select]
--- save cal using Prologix ---

D:\Junk\cal>hp3478acalibration.exe -f file.cal -r 6
Reading calibration data from instrument...
Instrument contains valid calibration data.
Writing calibration data to file...
Operation complete.

    Calibration     Raw              Raw
#   Entry           Offset  Offset   Gain   Gain      Checksum
--  --------------  ------  -------  -----  --------  --------
01        30 mV DC  000310      310  2CCCE  1.015558  C7
02       300 mV DC  000031       31  2CC3F  1.015629  CF
03          3 V DC  000004        4  2CCF5  1.015595  CD
04         30 V DC  999994       -6  1521F  1.015209  B6
05        300 V DC  000000        0  152DE  1.015168  DC
06      <not used>  000000        0  00000  1.000000  FF
07            AC V  999502     -498  14F45  1.013945  C0
08    30 Ohm 2W/4W  999904      -96  050DE  1.004968  B7
09   300 Ohm 2W/4W  999991       -9  054EE  1.005378  AC
10    3 kOhm 2W/4W  999999       -1  05344  1.005344  B9
11   30 kOhm 2W/4W  999999       -1  0512C  1.005116  B5
12  300 kOhm 2W/4W  999999       -1  0522F  1.005219  B1
13    3 MOhm 2W/4W  999999       -1  052D1  1.005171  B4
14   30 MOhm 2W/4W  999999       -1  0524F  1.005239  AF
15       300 mA DC  000260      260  3EF50  1.027950  D2
16           3A DC  000025       25  3E00D  1.027997  DA
17      <not used>  000000        0  00000  1.000000  FF
18    300 mA/3A AC  999502     -498  3C3F2  1.026292  BA
19      <not used>  000000        0  00000  1.000000  FF

--- save cal using ar488 ---
--- Note that AR488 does return the substring "GPIB" for ++ver ---



D:\Junk\cal>hp3478acalibration.exe -f file.cal -r 6
Reading calibration data from instrument...
ERROR: Failed while reading calibration data from instrument.

Extended Error Information:
Invalid GPIB adapter version string.

D:\Junk\cal>

--- program settings ---

<?xml version="1.0" encoding="utf-8" ?>

<Settings>
 
  <!--Serial Port Settings-->
  <SerialPort>
    <PortName>COM11</PortName>
    <BaudRate>460800</BaudRate>
    <DataBits>8</DataBits>
    <Parity>None</Parity> <!--Parity = None, Odd, Even, Mark, Space-->
    <StopBits>One</StopBits> <!--StopBits = One, OnePointFive, Two-->
    <FlowControl>None</FlowControl> <!--FlowControl = None, RequestToSend, RequestToSendXOnXOff, XOnXOff-->
  </SerialPort>
 
  <!--GPIB Adapter Settings-->
  <GPIBAdapter>
    <Timeout>1000</Timeout> <!--Serial/GPIB Timeout (mSec)-->
    <VersionString>GPIB</VersionString> <!--Command '++ver' return value must contain this string.-->
  </GPIBAdapter>
 
</Settings>



 

Offline Miti

  • Super Contributor
  • ***
  • Posts: 1331
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #35 on: November 28, 2019, 11:24:28 am »
Also, I like the way you show the cal gain and offset. If you don't mind, i'd like to use some of your code to add that feature to mine.

Hi lmester,

If you do that, can you also add edit function to the program? This way one can adjust the offset or gain of a particular function in decimal, the program then calculates the hex and checksum and saves to a new calibration file.
« Last Edit: November 28, 2019, 11:26:06 am by Miti »
Fear does not stop death, it stops life.
 

Offline steve1515

  • Regular Contributor
  • *
  • Posts: 86
  • Country: us
Re: Free HP3478A multimeter control program.
« Reply #36 on: November 28, 2019, 09:22:22 pm »
Hi lmester,

There is maybe a 200 mSec delay when starting up, but once you connect to the COM port at the correct baud rate it should work.

Feel free to use the code, but please add attribution. Thanks! :)
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #37 on: November 29, 2019, 04:52:06 am »
Miti,

That's a great idea! It'd be really great to be able to tweak up the gain and/or offset without going through a full calibration.  With it's input shorted my meter shows a small negative reading on some resistance ranges. It could use some offset adjustment. And, now that we can easily save the cal data, you could revert back to an earlier cal if you mess things up by tweaking the cal entries.
« Last Edit: December 05, 2019, 02:50:35 pm by lmester »
 

Offline Miti

  • Super Contributor
  • ***
  • Posts: 1331
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #38 on: November 29, 2019, 11:12:02 am »
With it's input shorted my meter shows a small negative reading on some resistance ranges. It could use some offset adjustment.

Does it show that negative reading in both, 2W and 4W? Keep in mind that this meter can only be calibrated in one mode, which seems stupid to me.
Fear does not stop death, it stops life.
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #39 on: December 05, 2019, 03:16:12 pm »
!!! update !!!  12/7/2019

Unfortunately I've found some more problems with my program and  the new AR488 firmware.

Use the 0.46.03  AR488 firmware until I solve all of the problems.

Sorry about this :-(

--------- old post ------

A problem with my software and the AR488 arduino firmware has been solved.

If you're having problems connecting to your meter using the AR488 firmware you can correct the problem by downloading the 0.47.59 version: https://github.com/Twilight-Logic/AR488



« Last Edit: December 07, 2019, 08:38:03 am by lmester »
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #40 on: December 25, 2019, 06:28:47 am »
A new version is available with the ability to adjust an instrument calibration entry.

You can now adjust the gain and offset values for a calibration entry. You can use this to adjust the calibration without going through the full calibration procedure for the instrument.

This is from a request from Miti.

This code was made much easier thanks to code from Steve Matos (Steve1515).  He provided code that converted the compressed instrument cal data into a gain and offset value. I only had to reverse his algorithm to compress the gain and offset back into the cal data storage format.

When you click the "Update cal." button the new cal data will be written to the instrument.

Make sure that the cal enable switch is turned on or the cal write will fail.

Warning! Be careful with this. It gives you a quick and easy way to trash the instrument calibration.



« Last Edit: December 25, 2019, 07:01:24 am by lmester »
 
The following users thanked this post: steve1515, coromonadalix, Photoman, Ringmodulator

Online coromonadalix

  • Super Contributor
  • ***
  • Posts: 5977
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #41 on: December 25, 2019, 03:04:34 pm »
Maybe  just maybe,  force the user to do a backup  before using this cal data interface ???

Surely  someone will do this mistake and learn from it ??
 

Offline Ground_Loop

  • Frequent Contributor
  • **
  • Posts: 649
  • Country: us
Re: Free HP3478A multimeter control program.
« Reply #42 on: December 26, 2019, 01:43:21 am »
Will your application also work with  3457?  I have mine at the cal lab right now and would like to back it up right out of the shop.
There's no point getting old if you don't have stories.
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #43 on: December 26, 2019, 05:47:46 am »
Maybe  just maybe,  force the user to do a backup  before using this cal data interface ???

Surely  someone will do this mistake and learn from it ??

coromonadalix,

I'd thought of doing some type of auto cal backup. I'd need a way to do it that would work without being a nuisance for someone that's adjusting their instrument's cal. you could enter the edit cal window many times while adjusting the cal data. A dialog to save a backup cal file each time would get old very quickly.

One possibility would be to automatically save a copy of the current instrument cal into the program cfg folder whenever edit cal was selected. This would be easy to code since the edit cal window already reads the current calibration data when it's opened. To make this automatic, I'd need to add a date/time stamp to the cal file name. A minor problem with this is that the cfg folder could have a lot of cal update log files in it. Not a big problem since the files are small. Also, if the user has multiple instruments, they'd need to determine which instrument the cal update logs came from.

There is some protection already available with my program and with the instrument.

First, you need to turn on the front panel cal enable switch.

Next, you get a final warning from my program before new cal data is written.

Any suggestions on how to make the edit cal feature safer but still easy to use would be welcome.


 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #44 on: December 26, 2019, 05:56:42 am »
Will your application also work with  3457?  I have mine at the cal lab right now and would like to back it up right out of the shop.

I did a quick look through the 3457 docs.  It's unlikely that my program would work. Calibration requires that the user enters a PIN code to enable calibration. This may not even be possible through the GPIB interface. Much different than the hardware cal enable switch on the HP3478A.
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #45 on: December 27, 2019, 09:07:57 am »
The user Miti has informed me that there is a problem with my instrument calibration update function. If you enter a gain value above 1.055555 my program will write an incorrect gain value into the instrument. Until I resolve this bug, you should only enter gain values below 1.055555. Also, you should verify the new gain value by exiting and then re-enter the cal update window.  Verify that the current cal gain data read from the instrument matches the value that you saved.

I'm sorry about this problem.

Once I determine what's wrong I'll release an updated version.
 

Online coromonadalix

  • Super Contributor
  • ***
  • Posts: 5977
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #46 on: December 27, 2019, 09:40:54 am »
@ lmester   a warning popup  should be fine to warn user of the possibility to smash the instrument calibration.

For the backups, i dont know if you can poke an serial number thru the gpib port via some commands  ??
and create a file   snxxxxxx-date xxxxxx-time xxxxxx   and manage all this ?? 

I think the simplest solution  would be per use basis,  one software use / one instrument, if a person has 2x, 3x 3478 meters in a chain and does a mistake .......   sure the cal switch is a good protection.

I dont know if the meter can operate under "calibration" at on position ??  sadly i dont own these meters


You know  when we say dont do this and that loll  someone will do it  loll

And thks for the time put in this great piece of software
« Last Edit: December 27, 2019, 09:43:09 am by coromonadalix »
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #47 on: December 28, 2019, 07:54:11 am »
@ lmester   a warning popup  should be fine to warn user of the possibility to smash the instrument calibration.

For the backups, i dont know if you can poke an serial number thru the gpib port via some commands  ??
and create a file   snxxxxxx-date xxxxxx-time xxxxxx   and manage all this ?? 

I think the simplest solution  would be per use basis,  one software use / one instrument, if a person has 2x, 3x 3478 meters in a chain and does a mistake .......   sure the cal switch is a good protection.

I dont know if the meter can operate under "calibration" at on position ??  sadly i dont own these meters


You know  when we say dont do this and that loll  someone will do it  loll

And thks for the time put in this great piece of software

First, the instrument will operate when in "calibration" mode.  It just shows a "C" appended to the reading. Also, the instrument has no way to read it's serial number through GPIB. It'd be great to be able to automatically add a serial number to the cal data file. It's just not possible with this instrument. The best solution is probably just to dump a time/date stamped file to the user's hard drive before each cal edit.

Right now I'm working on the more important problem of why my program is limited in the range of cal gain values that can be properly sent to the instrument. This may just be a problem with my program range checks. I may be allowing the user to input invalid cal data. More work and talk with the original author of the calibration decode algorithm is needed.





How much protection do you need to have for operator errors? I remember a quote from many decades ago:

"You can try to goof-proof a system. Unfortunately the goof can allways be bigger than the proof!"

 

Online coromonadalix

  • Super Contributor
  • ***
  • Posts: 5977
  • Country: ca
Re: Free HP3478A multimeter control program.
« Reply #48 on: December 28, 2019, 02:32:45 pm »
Well said  lmester

I hope you find the little buggar in the software   
 

Offline lmesterTopic starter

  • Regular Contributor
  • *
  • Posts: 143
  • Country: us
    • My page
Re: Free HP3478A multimeter control program.
« Reply #49 on: January 19, 2020, 05:08:02 am »
I've released an updated version of the software.

This version should work without problems with the current version of the AR488 Arduino firmware. If you use an Arduino based GPIB adapter and have any problems please let me know!

Updates to the edit calibration feature:
It seems that I was allowing invalid data to be entered for the gain entry.
The range check for gain now allows a value from 1 to 1.055555.
The allowed offset range is -100000 to 899999.

I added an automatic backup of the calibration data.
When you write calibration data, a file with the previous data will be saved in the cfg (config) folder.
The date and time are appended to the filename. Here is an example filename.
CALBackup_2020_01_01_02_53_14.cal
The file uses the normal .cal file format and can be sent to the instrument using the "Write calibration" function.

Fixed bug with reading instrument settings on program start:

When you start the program you have two options for instrument settings:
You can use the current settings or write the settings saved in the program config file to the instrument.
The program was not properly reading the current settings.
This has now been corrected.

Minor GUI layout problems with Windows 10:
I recently upgraded from Windows 7 to Windows 10. With Win 10 I noticed that some of the radio button controls were overlapping and not displayed properly. This version corrects the problem.



 
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf