Author Topic: Program that can log from many multimeters.  (Read 584288 times)

KungFuJosh and 7 Guests are viewing this topic.

Offline ali_asadzadeh

  • Super Contributor
  • ***
  • Posts: 1914
  • Country: ca
Re: Program that can log from many multimeters.
« Reply #3575 on: July 04, 2024, 10:43:34 am »
Quote
The Hantek HDM3065(B) works fine with TestController using RS232 or LAN. As there's no specific definition for these devices yet, you can just select the Keysight 34461A on the device list in TC and then change the SCPI command set on your DMM to "Agilent".  ([Shift]+Utility -> I/O Config -> SCPI).

I have its SCPI programming guide in English and I'm trying to write the definition file for TC but I didn't have the time to finish it yet.
I have changed the HDM3065(B) SCPI commands to Agilent, But TC would not recognize it either socket or LXI
ASiDesigner, Stands for Application specific intelligent devices
I'm a Digital Expert from 8-bits to 64-bits
 

Offline HKJTopic starter

  • Super Contributor
  • ***
  • Posts: 2975
  • Country: dk
    • Tests
Re: Program that can log from many multimeters.
« Reply #3576 on: July 04, 2024, 10:50:27 am »
Quote
The Hantek HDM3065(B) works fine with TestController using RS232 or LAN. As there's no specific definition for these devices yet, you can just select the Keysight 34461A on the device list in TC and then change the SCPI command set on your DMM to "Agilent".  ([Shift]+Utility -> I/O Config -> SCPI).

I have its SCPI programming guide in English and I'm trying to write the definition file for TC but I didn't have the time to finish it yet.
I have changed the HDM3065(B) SCPI commands to Agilent, But TC would not recognize it either socket or LXI

Sockets uses port numbers and they must match. It would be logical that it uses the Agilent port number when simulating it, but maybe it do not!
 

Offline Microcheap

  • Frequent Contributor
  • **
  • Posts: 256
  • Country: 00
Re: Program that can log from many multimeters.
« Reply #3577 on: July 05, 2024, 05:45:33 am »
I have changed the HDM3065(B) SCPI commands to Agilent, But TC would not recognize it either socket or LXI

In fact, when selected the Agilent SCPI commands, the multimeter is identified as the 34401A. The definition file for the 34401A includes support only for serial and GPIB. To connect the HDM3065 to TC using LAN you need to edit the definition file.

In the file AgilentHP34401A.txt located in the Devices folder, just change the line "#port com gpib" to "#port 5025 socket com"

I was just now making a definition file specifically for the HDM3000. I expect to finish it during the weekend.



 

Offline gby

  • Regular Contributor
  • *
  • Posts: 248
  • Country: us
Re: Program that can log from many multimeters.
« Reply #3578 on: July 18, 2024, 03:16:40 pm »
Hi HKJ,

Does TC scripting support multi-dimensional array variables? 

I see the array with =var MyVar[1] type syntax for a single dimension/single index array.  But can you have two indexes?  For example 10000 by 6?  I tired a few variations of possible syntax but none of them worked.
 

Offline HKJTopic starter

  • Super Contributor
  • ***
  • Posts: 2975
  • Country: dk
    • Tests
Re: Program that can log from many multimeters.
« Reply #3579 on: July 18, 2024, 03:55:05 pm »
Hi HKJ,

Does TC scripting support multi-dimensional array variables? 

I see the array with =var MyVar[1] type syntax for a single dimension/single index array.  But can you have two indexes?  For example 10000 by 6?  I tired a few variations of possible syntax but none of them worked.

A array is a normal variable and each entry in a array is also a normal variable, i.e. you can have any dimension you want.
You use the array() function to create a array variable:
=var a=array(array(1,2,3),array(4,5,6),array(7,8,9))
=a
;; {{=1, =2, =3}, {=4, =5, =6}, {=7, =8, =9}}

 It is not as such a multidimensional array, because each element do not need to be an array, but can be anything:
=var d=array(array(1,2,3),"Hello world",array(7,8,array(10,11,12))  )
=d
;; {{=1, =2, =3}, ="Hello world", {=7, =8, {=10, =11, =12}}}


You can also use this function to show contents of variables:
=displayVar(d)



Also note that a 10000 x 6 will be rather heavy on memory usage. I do also have vector and matrix types that are much more economic on memory, but I have not documented them very much, because I am not finished with them and they are not something I expect people will use in TC.
« Last Edit: July 18, 2024, 04:00:50 pm by HKJ »
 

Offline gby

  • Regular Contributor
  • *
  • Posts: 248
  • Country: us
Re: Program that can log from many multimeters.
« Reply #3580 on: July 18, 2024, 06:14:35 pm »
HKJ,

Thanks for the quick reply.  This 2-d array question is around extracting the locally recorded data in my device.  It records up to 10000 points with up to 6 channels.

Having an element in an array as an array itself does not do what I am trying to do....or my brain is not flexible enough.  Say I do:
   =var Data = array(1,2,3,4,5,6)
   =var RecData = array(0,Data)
This would allow me to record the 6 data points indexed by point number.  But, how do I access a specific value?  RecData[n] would give me the nth set of 6 values.  To get the third data channel at the nth sample point I would need to do it in two steps.  For example:
   = Data = RecData[n]
   = Data[3]
I had hoped that something like RecData[n,3] could get me the data in one step.  Since there are multiple ways to do what I need to do in one or two steps instead of one step, then I am good to go.

Thanks for providing a great tool and good support.
 

Offline HKJTopic starter

  • Super Contributor
  • ***
  • Posts: 2975
  • Country: dk
    • Tests
Re: Program that can log from many multimeters.
« Reply #3581 on: July 18, 2024, 06:36:34 pm »
HKJ,

Thanks for the quick reply.  This 2-d array question is around extracting the locally recorded data in my device.  It records up to 10000 points with up to 6 channels.

Having an element in an array as an array itself does not do what I am trying to do....or my brain is not flexible enough.  Say I do:
   =var Data = array(1,2,3,4,5,6)
   =var RecData = array(0,Data)
This would allow me to record the 6 data points indexed by point number.  But, how do I access a specific value?  RecData[n] would give me the nth set of 6 values.  To get the third data channel at the nth sample point I would need to do it in two steps.  For example:
   = Data = RecData[n]
   = Data[3]
I had hoped that something like RecData[n,3] could get me the data in one step.  Since there are multiple ways to do what I need to do in one or two steps instead of one step, then I am good to go.

You can do: =d[2][2][1]
A little trick: When assigning to an array, it will automatic expand as needed, to avoid expansion each time a element is added assign the last needed element a dummy value first, i.e: =var a[0];a[10000]=0; and you have a 10001 element array. Any non-assigned element will contain a special empty value (same as when declaring a var without assigning a value).

You can also store data directly in the TC table, there are functions to handle that:

You can see the bottom of KeysightU1461A.txt  for examples, documentation: https://lygte-info.dk/project/TestControllerFunctions%20UK.html#tableInitHeader_&&_tableAddRow

You might also be able to do something with this function: https://lygte-info.dk/project/TestControllerFunctions%20UK.html#tableAddCSVText

 

Offline Pukker

  • Regular Contributor
  • *
  • Posts: 153
  • Country: nl
Re: Program that can log from many multimeters.
« Reply #3582 on: July 23, 2024, 08:02:09 am »
Made some changes to my Powersupply-test and Battery-test scripts.
Some small adjustments and made it possible to save the graph, the csv file and
the Commandwindow log in a test file.
So I can start the test and let it run and leave it.
After completing the test all  is saved with the name
of the test given at start.

Note: Measurements attached are made an powersupply with an 0.5 Ohm resister in series.
Battery-test also simulated with powersupply.

Question at HKJ: Can I make an testblock in the graph with the most
important values, so the graph tell everyting over the test,

For example:
;; Test is Completed.
;; Tested Powersupply is: PowerSupply Ri is 05 ohm
;; Voltage deviation 'No-Load Voltage' to 'Specified Voltage' = 1.781 Volt
;; Voltage drop from 'No-Load Voltage' to 'Voltage at Maximum Current' = -1.611 Volt
;; Maximum Current = 3.0 Ampere
;; Maximum Power = 36.49 Watt
;; Internal Resistance = 528mOhm
;; Burn-InTest Succesfull (1.0 Minutes at 1.0 Ampere)
« Last Edit: July 23, 2024, 08:13:44 am by Pukker »
 

Offline HKJTopic starter

  • Super Contributor
  • ***
  • Posts: 2975
  • Country: dk
    • Tests
Re: Program that can log from many multimeters.
« Reply #3583 on: July 23, 2024, 05:25:59 pm »
Question at HKJ: Can I make an testblock in the graph with the most
important values, so the graph tell everyting over the test,

You can use the annotations: http://lygte-info.dk/project/TestControllerPopupChartLayoutUK.html#Annotations
You can make some text with the menu and then use the right click menu in the log screen and generate a script with "Generate Scripts, Chart layout" to generate a example script. You will have to edit the script commands to fir your purpose.
 

Online flash2b

  • Regular Contributor
  • *
  • Posts: 119
  • Country: nl
Re: Program that can log from many multimeters.
« Reply #3584 on: Today at 07:13:44 pm »
I encountered a problem while using the device driver for the Keithley 199 written by "Gertjan".

The problem manifests itself when using the "reconnect device" option in TestController (i have used the latest version). The Keithley 199 (K199) is nicely found after startup of TestController (TC) but can no longer be identified after "reconnect device" I did contact the author of the driver who suggested to run TC in debug mode which showed different behavior towards the K199 from start-up to re-connect.

Start-up:
;; COM6: Tx: <++addr 26.> 2B 2B 61 64 64 72 20 32 36 0A
;; COM6: Tx: <G0U0X.> 47 30 55 30 58 0A
;; COM6: Tx: <++read_tmo_ms 950.> 2B 2B 72 65 61 64 5F 74 6D 6F 5F 6D 73 20 39 35 30 0A
;; COM6: Tx: <++read eoi.> 2B 2B 72 65 61 64 20 65 6F 69 0A
;; COM6: Rx: <1991000000000010000000100000000001> 31 39 39 31 30 30 30 30 30 30 30 30 30 30 31 30 30 30 30 30 30 30 31 30 30 30 30 30 30 30 30 30 30 31

Re-connect:
;; COM6: Tx: <G0U0X.> 47 30 55 30 58 0A
;; COM6: Tx: <++read eoi.> 2B 2B 72 65 61 64 20 65 6F 69 0A
;; COM6: Rx: timeout
;; AR488 A:26: **Device do not match** <nul>
;; AR488 A:26 Device "Keithley,199" do not match answer: "**Device do not match** <nul>"


I am using an ProMicro powered AR488 on COM6. The K199 is on GPIB A:26.

What I also noticed in the log-trace is that the <reset> and <goLocal> are not transmitted to the K199 since TC already closed COM6 before that.

;; K199: Rx <0>
;; COM6: Close
;; K199: Tx <reset>
;; K199: Delay: 1000ms
;; K199: Tx <goLocal>
;; K199: Delay: 1000ms

I have attached the log-file which recorded just starting up, no measurement and then re-connect.

I hope HKJ can help me to solve the problem, its annoying to re-start TC multiple times.
 
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf