Author Topic: 3458a logging via Windows app.....revisited  (Read 19291 times)

0 Members and 1 Guest are viewing this topic.

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #200 on: July 25, 2019, 04:14:10 pm »
Hi,

Small update to the EXE (see version 1.47 in post #1), somebody asked to be able to set sample rates in fractions of seconds i.e. X.Xsecs.
Minimum is now 0.1 secs.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline Wintel

  • Contributor
  • Posts: 12
  • Country: us
Re: 3458a logging via Windows app.....revisited
« Reply #201 on: September 30, 2019, 11:45:52 pm »
Good program, very helpful.
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #202 on: October 27, 2019, 08:17:43 am »
Hello,

I purchased some time ago a used HP34401 DVM, and this software seem to do exactly
what i would. So the question is does it work on 34401 with only serial interface (with USB adapter) on Win7 (or win 10) ?
I first looked on BenchVue, but that really overpriced for what i need to do !
Best regards, and many thanks to all contributor of this tool.

Frex
 

Offline imo

  • Super Contributor
  • ***
  • Posts: 1963
  • Country: 00
Re: 3458a logging via Windows app.....revisited
« Reply #203 on: October 27, 2019, 08:32:19 am »
Nope, the 34401A cannot work with a ttl/cmos USB dongle on its RS232.

Mind its rx/tx/dtr/dsr signals have got the rs232 levels (around +/- 9V, log1=-9V).

You need to convert the rs232 levels to ttl/cmos levels (ie. MAX232, or 2 transistors, etc).

Another issue to solve could be the handshaking. I've been using the serial, while I force the 34401's DTR input to +5V (a pullup 4k7 resistor) telling to the 34401 my side is always ready. Otherwise you most probably have to elaborate the DTR/DSR signals as well.

I was using the Agilent DMM Utility under Win7 and it worked till 10NPLC "reliably" (sometimes it had problem with initiation of the measurement, but the measurement itself was runnung for days fine). The lower NPLCs do not work reliably without handshaking. Today I use my own stm32 as an interface, fusing the 34401A data with two 16bit adcs (temperature) and an RTC, sending the data via Bluetooth to my PCs.
« Last Edit: October 27, 2019, 08:51:30 am by imo »
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #204 on: October 27, 2019, 08:49:44 am »
Hello,

Thanks for the answer.
So, even with the right level interface, it couldn't work fine, is that ?
What others solutions exist to record data with 34401 on modern PC ?
Does you own solution is available ?
Regards

Frex
 

Offline imo

  • Super Contributor
  • ***
  • Posts: 1963
  • Country: 00
Re: 3458a logging via Windows app.....revisited
« Reply #205 on: October 27, 2019, 08:55:08 am »
With right interface and handshaking it works fine under Win7.
The 34401A rs232 interface speed is limited to 9600baud  >:( therefore you cannot expect it will work with all sampling rates.

Other way to get the data off the 34401A is the GPIB interface - it is fast enough for any sampling rates 34401A supports..
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #206 on: October 27, 2019, 09:27:17 am »
Hello,

Ok fine.
You would recommend to  get a GPIB-USB adapter and that's it ?
It will work out of the box with the software ?
Do you know a "low cost" model that work fine and you would recommend ?
Thanks again.

Frex
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #207 on: October 27, 2019, 02:18:14 pm »
Hello,

Ok fine.
You would recommend to  get a GPIB-USB adapter and that's it ?
It will work out of the box with the software ?
Do you know a "low cost" model that work fine and you would recommend ?
Thanks again.

Frex

82357B via Ebay (knock off version) is probably what you are looking for. I have one and it works fine with my 3458A & Win10.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #208 on: October 27, 2019, 07:27:40 pm »
Hello,

Ok, i ordered one 82357B on Aliexpress here  https://fr.aliexpress.com/item/32905508446.html?spm=a2g0s.9042311.0.0.1ecd6c373NtPPK .
I hope that will do the job. I will post my experience as soon received.
Thank !

Frex
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #209 on: November 08, 2019, 04:51:28 pm »
Hi,

Small update to the EXE (see version 1.48 in post #1), I have been playing with the PPM/DegC option in the Playback chart.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #210 on: November 09, 2019, 12:40:18 pm »
Hi,

Small update to the EXE (see version 1.49 in post #1), I have added a REFRESH CHART button in the Playback chart......much easier/quicker to refresh the graph if you make any changes to the graph settings etc.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #211 on: November 11, 2019, 02:38:48 pm »
Hello,

I received the 82357A adapter these days.
After spending some time to understanding what  need to be installed, i finally  get it working.
I tried first the BenchVue  multimeter software (DMM), but i won't pay for that...
So i installed your IODeviceapp software and i must say that's a great job !
Thank you for sharing your job with us.

I use it with my HP34401 DMM, and it is connected to my Win7-64 computer.
I don't know if you already had this issue, but data graph display doesn't work.
Anyway, data logging work ok.
(When i enable data display, the error box message say that autoscale can't work
with negative data, but they are only positive ! There is the same issue when
 using post-process data display utility).

I would also have one question (i'm noob on SCPI commands) about data to be logged :
Does it is possible to record two differents measurements with the same device when data logging ?
For example, i would like to record with the DMM, the frequency of the incoming signal,
and  then record the AC RMS values. (Maybe by using alternate SCPI commands
for each measurements ?) Does it is possible ?
 Thank you for your help.

Best regards,

Frex
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #212 on: November 11, 2019, 06:53:19 pm »
Hello,

I received the 82357A adapter these days.
After spending some time to understanding what  need to be installed, i finally  get it working.
I tried first the BenchVue  multimeter software (DMM), but i won't pay for that...
So i installed your IODeviceapp software and i must say that's a great job !
Thank you for sharing your job with us.

I use it with my HP34401 DMM, and it is connected to my Win7-64 computer.
I don't know if you already had this issue, but data graph display doesn't work.
Anyway, data logging work ok.
(When i enable data display, the error box message say that autoscale can't work
with negative data, but they are only positive ! There is the same issue when
 using post-process data display utility).

I would also have one question (i'm noob on SCPI commands) about data to be logged :
Does it is possible to record two differents measurements with the same device when data logging ?
For example, i would like to record with the DMM, the frequency of the incoming signal,
and  then record the AC RMS values. (Maybe by using alternate SCPI commands
for each measurements ?) Does it is possible ?
 Thank you for your help.

Best regards,

Frex

I think logging from the same device would depend on the commands you want to use.......I just did a quick test and set up both channels to log from my 3458A and it appears to be doing so just fine.
You could run into problems if ch.1 sends a command that is due to take some time to respond and in the meantime ch.2 has sent it's command to the same device. You could find you get a queue of commands building up (the small pop up will show you queued commands).

Could you post your CSV log file here and maybe a screenshot of the app so I can see your setup and I will take a look at it. I seem to remember a similar issue during development but thought it was all fixed.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline pwlps

  • Regular Contributor
  • *
  • Posts: 165
  • Country: fr
Re: 3458a logging via Windows app.....revisited
« Reply #213 on: November 12, 2019, 01:02:25 pm »

I think logging from the same device would depend on the commands you want to use.......I just did a quick test and set up both channels to log from my 3458A and it appears to be doing so just fine.
You could run into problems if ch.1 sends a command that is due to take some time to respond and in the meantime ch.2 has sent it's command to the same device. You could find you get a queue of commands building up (the small pop up will show you queued commands).


Yes, the commands can mix up if both devices point to the same physical address. Using only blocking commands might work but then you loose some of the advantages of asynchronous commands.  But there is one very simple solution to this. Add, on the device2 upper panel, a new button "set device2 same as device1" as an alternative to the "create device 2" button. The code of this button would be the same except for the first line:
dev2 = CreateDevice(... etc.
should be replaced by
dev2=dev1

This is quite different from setting the same address for both: as there is only one object - i.e. a single queue and a single device lock  -  commands cannot mix up.
I did not try but I don't see any reason this wouldn't work.
« Last Edit: November 12, 2019, 01:04:01 pm by pwlps »
 
The following users thanked this post: Theboel

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #214 on: November 13, 2019, 05:10:25 pm »
Hello,

Thank you for your answer.

First, below a screen-shoot of the error message that appear when data plot
is enabled and as soon the first value is recorded.
(value is indicated in error message as out of plot range axis, maybe an issue with decimal separator ?).
Note that there is same issue when opening a recorded csv files with playback plot viewer.
Anyway, the data log work fine and so i can show data plot results in others apps (Calc/Excel).



I tried to set both device channel with my 34401A, but i think the reading  are in collision (send at same time)
and so there is only the first value that is read.
I want to measure the RMS voltage first (command  is    :Measure:Voltage:AC? DEF,DEF) and then
i want to measure the input signal frequency (command is  :Measure:FREQency? DEF,DEF  ).

I understand that the second measurement must be delayed, but i must admit that i don't know how.
You can show my setup on the screenshoot below, only the first measure is received...
Can you help me to fix this ?





Regards.

Frex





 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #215 on: November 13, 2019, 10:56:59 pm »
A first quick look at your screenshots......the app is crashing because your language uses commas for decimal points instead of full stops and its conflicting with the comma separated values.
Try selecting the semi-colon option instead, save settings, and clear your csv file and start again.

I would suggest get everything working with just one device first before trying two.

Ian.
« Last Edit: November 13, 2019, 11:00:18 pm by IanJ »
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #216 on: November 14, 2019, 05:24:32 am »
Hello,

Ok, i will try  to change the language setting for the graph plot.

Note that i of course tried separate devices settings and if i select only one at once,
i got the correct measurement on the channel (frequency or AC value).
If i try to use both at same time there is probably a conflict and there is only one value read.
I don't know how to set the command (and where) avoiding to be send at same time (at sampling frequency) ?

Regards.

Frex
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #217 on: November 14, 2019, 06:06:07 am »
Hi,

There is no place in my app to separate the timing of the requests.
I will look more into this by mimicking your setup later and see what happens.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline pwlps

  • Regular Contributor
  • *
  • Posts: 165
  • Country: fr
Re: 3458a logging via Windows app.....revisited
« Reply #218 on: November 14, 2019, 09:21:13 am »
There is no place in my app to separate the timing of the requests.

Hi Ian and Frex,

Maybe you missed my previous post where I suggested a small add-on addressing the collision problem (and precisely, this would automatically separate the timings), it shouldn't take more than 10 minutes to add it in the code. And I think this is the only way to do it reliably. Of course it has to be tested for possible side effects - for example both devices will now have the same "name" fields (dev2.name same as dev1.name), but I did not look if this field is used in your latest code.

Edit
Another approach, without modyfying the code, would consist of using the blocking mode ("send blocking" checkbox checked) for one of the devices and async mode for the other. Then the command-responses sequences cannot mix up either.  However it will allow to mix the preceding configuration commands, if any such are added in "At Run": so it will only work if there is a single "At Run" command. If you need to add other commands to reconfigure the meter between the measurements (the case here),  the configuration commands should be sent in the same command string (in SCPI they are separated by a semicolon).
 Incidentally, I just saw that the settings on the screenshot are not correct: the commands "Measure.FREQ?" and "Measure.Volts?" should be repeated before each measurement, so these are "At run" commands and not "Pre run" commands.



Pawel
« Last Edit: November 14, 2019, 10:29:43 am by pwlps »
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #219 on: November 14, 2019, 02:51:40 pm »
Pawel,

I have been thinking about this and not sure I want to modify the code......its already a pretty complicated app due to my layout and cramming a lot of functionality in......I think it is good that ch.1 and ch.2 are separated completely and the essence of the app is to drive two different devices. I'd like to avoid confusion.

Not to mention the testing etc required.....

Hmmmm!

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 

Offline pwlps

  • Regular Contributor
  • *
  • Posts: 165
  • Country: fr
Re: 3458a logging via Windows app.....revisited
« Reply #220 on: November 14, 2019, 03:08:44 pm »
As I suggested it would only be an option, activated with a separate button. But I agree there are a lot of them already...

Pawel
 

Offline Frex

  • Contributor
  • Posts: 26
Re: 3458a logging via Windows app.....revisited
« Reply #221 on: November 15, 2019, 05:59:00 pm »
Hello,

After tweaking some region setting in the OS, I finally get graph display working,
even if sometime i have some weird behavior.
(Maybe the Win7 OS is not as good supported as Win 10  too ?).
Anyway,  display is only for convenience. So that's fine as is. ;)

About making two interlaced measurements with the same devices,
i think this would be a (for me at least) great feature, but i understand it require some work.
Too bad for me. :P
So the good point would be to found a tips to become this work with your actual software,
but I'm for now a beginner in scpi commands.

If you Ian or Pawel can gave me an example of commands i can use to try,
 that would help me a lot. (With the 34401, i want to log frequency and AC rms amplitude each 10s ).
I must admit that I'm little confused about the all options fields to complete on the GUI. :-\
Thank you.
Regards.


Frex
 

Offline IanJ

  • Supporter
  • ****
  • Posts: 1015
  • Country: scotland
  • Pro EE guy many years ago, now a hobby/home biz.
    • IanJohnston.com
Re: 3458a logging via Windows app.....revisited
« Reply #222 on: November 15, 2019, 08:29:18 pm »
Hello,

After tweaking some region setting in the OS, I finally get graph display working,
even if sometime i have some weird behavior.
(Maybe the Win7 OS is not as good supported as Win 10  too ?).
Anyway,  display is only for convenience. So that's fine as is. ;)

About making two interlaced measurements with the same devices,
i think this would be a (for me at least) great feature, but i understand it require some work.
Too bad for me. :P
So the good point would be to found a tips to become this work with your actual software,
but I'm for now a beginner in scpi commands.

If you Ian or Pawel can gave me an example of commands i can use to try,
 that would help me a lot. (With the 34401, i want to log frequency and AC rms amplitude each 10s ).
I must admit that I'm little confused about the all options fields to complete on the GUI. :-\
Thank you.
Regards.


Frex

If you press the NOTEPAD button in the app it is loaded with some example commands for some instruments.

Ian.
Ian Johnston
www.ianjohnston.com
Manufacturer of the PDVS2 & PDVS2mini
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf