Author Topic: linux-gpib and python - Keithley2015 & HP3457A 10v logging  (Read 7623 times)

0 Members and 1 Guest are viewing this topic.

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
linux-gpib and python - Keithley2015 & HP3457A 10v logging
« on: January 10, 2014, 07:50:58 am »
Guyzz

I have just played a bit with the python bindings on linux-gpib.
I'm a total beginner with python , so it might not be "neat" ... But it works

I'm logging my Geller SVR (K2015) and SVR-T (3457A) , and also logging temperatures via a homebuild USB-AVR 4xDS18B20 logger , using pyserial.

I have attached a few examples , and my dm-temp.py program , if anyone wants to have a look.
Python seems to be a nice program for doing these tasks.

The .csv  Collumns are : Date ; Time ; HP Temp ; HP Volt;Keithley Temp; keithley Volt

/Bingo
 

Offline AlfBaz

  • Super Contributor
  • ***
  • Posts: 2184
  • Country: au
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #1 on: January 10, 2014, 08:32:00 am »
Good stuff Bingo :-+

Beware... trending can be addivtive ;)
 

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #2 on: January 10, 2014, 12:50:36 pm »
@AB

I know ....

I just got more 4 DIY Geller SVR's ....
Time to put the 3457A scanner at work

/Bingo
 

Offline Andreas

  • Super Contributor
  • ***
  • Posts: 3238
  • Country: de
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #3 on: January 10, 2014, 09:48:11 pm »
Hello,

it seems that on the Keithley there is also a resolution of <10uV in the 10V range as on the HP34401A.
But the values look rather noisy.
Did you use any filtering?
Which integration time? (measurement rate?)


With best regards

Andreas
 

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #4 on: January 10, 2014, 10:10:48 pm »
@Andreas

How do you make those graphs from a .csv ... Teach me please  :)
Is it gnuplot ?
Can i get the "script/commands" ?




On the 3457 i used 100NPLC (Max)

On the K2015 i used 10NPLC (Max) , the K2015 has filtering enabled (i think default is 10 measurement moving average)

The temperatures are "bad" , as i had another linux program also accesing my USB-AVR temp logger (/dev/TTYACM0) , at first
t thought it was cool that 2 programs could acces the temp sensors. But then i discovered that they both send temp sensor commands , and the readings then got mixed up. I'ts actually funny that you can read/write from two tasks to one serialport .

I have stopped the 2'nd task , and attached another csv file.

My SVR on the Keithley , and SVR-T on the 3457A are lying in free air unencapsulated on the table.
And i'm an bit surprised that there can be 0.8C difference from the two boards that are maybe 15 cm apart.

Edit:
Ohh and remember both meters are 6.5 digits , even though the gpib returns more digits.
I haven't utilized the extra digit on the 3457A yet ....

Edit2: 11-jan - Uploaded a newer zipdile with more measurements in it
/Bingo
 
« Last Edit: January 11, 2014, 06:51:00 am by bingo600 »
 

Offline Andreas

  • Super Contributor
  • ***
  • Posts: 3238
  • Country: de
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #5 on: January 11, 2014, 08:05:13 am »
@Andreas

How do you make those graphs from a .csv ... Teach me please
Is it gnuplot ?


Hello,

it's a simple spreadsheet. I use usually a very old version of MS-Works which came with my first XP-System which is still doing my measurements.
But any other spreadsheet should do the job.
Eventually you will have to adapt the country specifics because of the decimal point.

0.8 degrees difference is not a lot. Within a room you can have several degrees of temperature difference depending on air circulation. And even the references AD587 have a self heating of around 3 degrees Celsius against environment.

With best regards

Andreas


 

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #6 on: January 11, 2014, 09:03:39 am »
@Andreas

Regarding filtering:

Would you recommend i use the meters in "Raw mode" , and do ie. a 12 point averaging filter in python
12 because i read every 5 sec , and log to file on every 12'th measurement (1/min).

Should i use a greater number ?


Or should i use the meter ?
Ie. the Keithley can do moving average in the HW , 10..100 measurements

I have to read up on the E3457A to see if it can do the same (moving average)

I'll see if i can get the extra digit out of the 3457A  - RMATH & SMATH on HIRES REG 14

/Bingo
 

Offline Andreas

  • Super Contributor
  • ***
  • Posts: 3238
  • Country: de
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #7 on: January 11, 2014, 10:48:05 am »
Would you recommend i use the meters in "Raw mode"

That depends on many factors:

With how much precision is the meter calculating  (single / double precision or 5 byte "reals")
What is the real resolution of the adc?
With which precision is phyton calculating?
The goal should be to get the lowest artifact (rounding) errors by averaging.

But with 5 seconds reading intervals it might be better to do some pre-Filtering over 5 seconds
(e.g. moving average of 25 values with 200 ms integration time).
You can do some statistic evaluations to find out whats best in your case.

With best regards

Andreas
 

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #8 on: January 11, 2014, 12:09:35 pm »
Would you recommend i use the meters in "Raw mode"

That depends on many factors:

With how much precision is the meter calculating  (single / double precision or 5 byte "reals")
What is the real resolution of the adc?
With which precision is phyton calculating?
The goal should be to get the lowest artifact (rounding) errors by averaging.

But with 5 seconds reading intervals it might be better to do some pre-Filtering over 5 seconds
(e.g. moving average of 25 values with 200 ms integration time).
You can do some statistic evaluations to find out whats best in your case.

With best regards

Andreas

Hmmm ....

I was "absent" the day they taught serious statistics in school  :scared:
I'll need some guidance

Quote
Almost all platforms map Python floats to IEEE 754 double precision.
http://floating-point-gui.de/languages/python/


I added a new version , that adds the HP 3457A HIGHRES register to the measurements , making it a ~7.5 digit meter

New .csv layout
Collums : Date;Time;HP-Temp;HP-Volt;HP-Highres;HP-7.5digit;K2015-Temp;K2015-Volt;


/Bingo

Added a new datafile with more readings
New .csv layout
Collums : Date;Time;HP-Temp;HP-Volt;HP-Highres;HP-7.5digit;K2015-Temp;K2015-Volt;
« Last Edit: January 12, 2014, 09:39:25 am by bingo600 »
 

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #9 on: January 13, 2014, 10:40:08 am »
I have been toying with gnuplot for the first time ever ....

And as Dave would have said : Ta..Daaaaaaa




The funny "retrace" is because data started at 10:00 , and the "graph" apparently "wraps" at 00:00.
This is 00:00 wrap creates the "retrace line"

/Bingo
« Last Edit: January 13, 2014, 10:42:47 am by bingo600 »
 

Offline Andreas

  • Super Contributor
  • ***
  • Posts: 3238
  • Country: de
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #10 on: January 13, 2014, 07:43:29 pm »
Hello,

you can correct this behaviour by adding the date to the x-axis.

With best regards

Andreas
 

Offline bingo600Topic starter

  • Super Contributor
  • ***
  • Posts: 1987
  • Country: dk
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #11 on: January 15, 2014, 06:52:50 pm »
Whoaaa .....

GnuPlot is extremely powerfull

I think i have made same graph as Andreas  :) :)
Andreas thanx for the inspiration



I have "Low heat in my lab, and usually the door closed" , one can see that the "Cold" has hit Denmark
I came home at 14 , and opened the door to the lab.

Now there isn't much doubt that the units are temp sensitive.

/Bingo

Edit: This page is a great gnuplot ref... Check out the "Not So FAQ"
http://www.ualberta.ca/~xz10/gnuplot/index-e.html
« Last Edit: January 15, 2014, 07:15:27 pm by bingo600 »
 

Offline Andreas

  • Super Contributor
  • ***
  • Posts: 3238
  • Country: de
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #12 on: January 15, 2014, 09:12:07 pm »
Gratulations,

the plot looks good to me.

The question is: is the instrument really temperature dependant or more temperature gradient dependant.
On some devices I have different results depending on temperature slope.

With best regards

Andreas
 

Offline AlfBaz

  • Super Contributor
  • ***
  • Posts: 2184
  • Country: au
Re: linux-gpib and python - Keithley2015 & HP3457A 10v logging
« Reply #13 on: January 15, 2014, 10:28:59 pm »
The question is: is the instrument really temperature dependant or more temperature gradient dependant.
On some devices I have different results depending on temperature slope.

Interesting, so whilst the temperature is changing the differing thermal masses on the ref board can cause thermoelectric offsets and once the boards temperature has stabilised you should see a stable output. I have acquired a small Peltier cooler/warmer that I intend installing some control on with these sorts of tests in mind
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf