# -*- Mode:Org; Coding:utf-8; fill-column:158 org-confirm-babel-evaluate:nil -*- # ######################################################################################################################################################.H.S.## # FILE: tool-info.org #+TITLE: Test Equipment #+SUBTITLE: Hardware, Usage, & Automation Notes #+AUTHOR: Mitch Richling #+EMAIL: http://www.mitchr.me/ #+DATE: 2025-11-20 #+DESCRIPTION: Test Automation Tools & Notes #+KEYWORDS: gpib ethernet lxi scpi dmm oscilloscope multimeter awg power supply signal generator measure instruments bench electronics #+LANGUAGE: en #+OPTIONS: num:t toc:nil \n:nil @:t ::t |:t ^:nil -:t f:t *:t <:t skip:nil d:nil todo:t pri:nil H:5 p:t author:t html-scripts:nil broken-links:t #+SEQ_TODO: TODO:NEW(t) TODO:WORK(w) TODO:HOLD(h) | TODO:FUTURE(f) TODO:DONE(d) TODO:CANCELED(c) #+PROPERTY: header-args :eval never-export #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_HEAD: #+HTML_LINK_HOME: https://www.mitchr.me/ #+HTML_LINK_UP: https://github.com/richmit/TestEquipmentNotes # ######################################################################################################################################################.H.E.## #+ATTR_HTML: :border 2 solid #ccc :frame hsides :align center | | | | *Author:* | /{{{author}}}/ | | *Generated:* | /{{{time(%Y-%m-%d %H:%M:%S)}}}/ | | *Updated:* | /{{{modification-time(%Y-%m-%d %H:%M:%S)}}}/ | #+ATTR_HTML: :align center Copyright {{{time(%Y)}}} Mitch Richling. All rights reserved. #+MACRO: MRSCPI [[https://richmit.github.io/mrSCPI/][=mrSCPI=]] This document originally started as a place to keep operational notes about my test equipment. The sort of stuff I found myself looking up while at the bench like DMM resister test current or the IP address I used for my counter. Later I added web links to product information & downloads. After discovering Zotero, I added documentation links to my local laptop's Zotero repository. When I developed {{{MRSCPI}}} I started adding little bits of executable code to the notes for various equipment configurations and measurements. I decided to publish these notes as a response to requests for {{{MRSCPI}}} examples -- the {{{MRSCPI}}} blocks below being ready-made examples! I expect most of the remaining content here isn't very useful to anyone other than myself. * Links For Emacs :noexport: |----------------------------------------+----------------------| | Device | Link | |----------------------------------------+----------------------| | R&S HMC8043 Power Supply | [[#MSIDhmc8043]] | | Rigol DG2052 AWG | [[#MSIDdg2052]] | | Agilent 33210A AWG | [[#MSID33210a]] | | Keysight 34401A Bench DMM | [[#MSID34401a]] | | HP 53131A Universal Counter | [[#MSID53131a]] | | Keithly DMM6500 Bench DMM | [[#MSIDdmm6500]] | | Rigol DHO4204 Oscilloscope | [[#MSIDdho4204]] | | Siglent SDS2504X+ Oscilloscope | [[#MSIDsds2504xp]] | | Tektronix TDS2024 Oscilloscope | [[#MSIDtds2024]] | | Tektronix TDS3052B Oscilloscope | [[#MSIDtds3052b]] | | HIOKI 3030 Analog VOM | [[#MSIDHIOKI3030]] | | SANWA EM7000 FET Analog VOM | [[#MSIDSANWAEM7000]] | | Gossen-Metrawatt METRAmax 2 Multimeter | [[#MSIDGMMETRAM2]] | | Keysight U1233A DMM | [[#MSIDU1233A]] | | Thurlby Thandar WA301 HF Amplifier | [[#MSIDTTWA301]] | | Fluke 107 Pocket DMM | [[#MSIDF107]] | |----------------------------------------+----------------------| | Bus Pirate 2 | [[#MSIDbuspirate5]] | | i2c Driver | [[#MSIDi2cd]] | | SPI Driver | [[#MSIDspid]] | | Analog/Digital Discovery 2 | [[#MSIDdadddd]] | |----------------------------------------+----------------------| The links in the above table are to sections of this document I frequently use inside Emacs. This section is not exported to HTML. * Table of Contents :PROPERTIES: :ID: 64f32d6b-fb85-4b5a-bf20-7f2142cb964d :END: [[#DTOC][Detailed TOC]] #+TOC: headlines 2 * Instrument Connection Data Table :noexport: :PROPERTIES: :CUSTOM_ID: data-and-code :END: ** Main Table #+TBLNAME:connect-data |------------+-----------+----------------+-----------+----------+----------------+-----------------------------+-----------------+------------+-----------+--------+-------| | Instrument | Model | Type | Mfg | Protocal | SSH Local Port | Instrument IP | Instrument Port | cname | dnam | snam | sanam | |------------+-----------+----------------+-----------+----------+----------------+-----------------------------+-----------------+------------+-----------+--------+-------| | | SDS2504X+ | Oscilloscope | Siglent | vnc | 5900 | oscope-sig.home.mitchr.me | 5900 | | | | | | 33210a | 33210A | AWG | Agilent | raw | 9001 | awg-agilent.home.mitchr.me | 5025 | 33210ae | 33210a | aawge | aawg | | 33210a | 33210A | AWG | Agilent | https | 9002 | awg-agilent.home.mitchr.me | 443 | 33210aw | | aawgw | | | 34401a | 34401A | DMM | Keysight | plgx | 9003 | gpib-rover.home.mitchr.me | 1234 | 34401ap | | dmmp | | | 34401a | 34401A | DMM | Keysight | soip | 9004 | serial.home.mitchr.me | 10001 | 34401as | 34401a | dmms | dmm | | 53131a | 53131A | Counter | HP | plgx | 9005 | gpib-rover.home.mitchr.me | 1234 | 53131ap | 53131a | countp | count | | dg2052 | DG2052 | AWG | Rigol | raw | 9006 | awg-rigol.home.mitchr.me | 5555 | dg2052e | dg2052 | dg2ke | dg2k | | dg2052 | DG2052 | AWG | Rigol | http | 9007 | awg-rigol.home.mitchr.me | 80 | dg2052w | | dg2kw | | | dho4204 | DHO4204 | Oscilloscope | Rigol | raw | 9008 | oscope-rigol.home.mitchr.me | 5555 | dho4204e | dho4204 | dho4ke | dho4k | | dho4204 | DHO4204 | Oscilloscope | Rigol | http | 9009 | oscope-rigol.home.mitchr.me | 80 | dho4204w | | dho4kw | | | dmm6500 | DMM6500 | DMM | Keithley | raw | 9010 | dmm-keithley.home.mitchr.me | 5025 | dmm6500e | dmm6500 | 6500e | 6500 | | dmm6500 | DMM6500 | DMM | Keithley | http | 9011 | dmm-keithley.home.mitchr.me | 80 | dmm6500w | | 6500w | | | hmc8043 | HMC8043 | Power Supply | R&S | raw | 9012 | ps-rns.home.mitchr.me | 5025 | hmc8043e | hmc8043 | pse | ps | | hmc8043 | HMC8043 | Power Supply | R&S | http | 9013 | ps-rns.home.mitchr.me | 80 | hmc8043w | | psw | | | sds2504xp | SDS2504X+ | Oscilloscope | Siglent | raw | 9014 | oscope-sig.home.mitchr.me | 5025 | sds2504xpe | sds2504xp | sig2ke | sig2k | | sds2504xp | SDS2504X+ | Oscilloscope | Siglent | http | 9015 | oscope-sig.home.mitchr.me | 80 | sds2504xpw | | sig2kw | | | serial | serial | Serial Console | Lantronix | http | 9016 | serial.home.mitchr.me | 80 | serialw | | serial | | | tds2024 | TDS2024 | Oscilloscope | Tektronix | soip | 9017 | serial.home.mitchr.me | 10002 | tds2024s | | tek2ks | tek2k | | tds3052b | TDS3052B | Oscilloscope | Tektronix | t3k | 9018 | oscope-tek.home.mitchr.me | 80 | tds3052bh | tds3052b | tek3kh | tek3k | | tds3052b | TDS3052B | Oscilloscope | Tektronix | plgx | 9019 | gpib-rover.home.mitchr.me | 1234 | tds3052bp | | tek3kp | | | tds3052b | TDS3052B | Oscilloscope | Tektronix | soip | 9020 | serial.home.mitchr.me | 10003 | tds3052bs | | tek3ks | | | tds3052b | TDS3052B | Oscilloscope | Tektronix | http | 9021 | oscope-tek.home.mitchr.me | 80 | tds3052bw | | tek3kw | | |------------+-----------+----------------+-----------+----------+----------------+-----------------------------+-----------------+------------+-----------+--------+-------| ** Ethernet Ports | Device IP | Switch Port | Cable ID | |--------------+-------------+----------------| | oscope-tek | G05 | white/grey | | oscope-sig | G06 | red/grey | | oscope-rigol | G07 | black/grey | | gpib-rover | G10 | sleeved yellow | | awg-agilent | G12 | red/black | | awg-rigol | G13 | black/black | | dmm-keithley | G14 | green/black | | ps-rns | G15 | blue/black | | serial | G16 | short grey | ** Serial Ports On Lantronix Console | cname | Serial port | cable marker | |-----------+-------------+--------------| | 34401as | 1 | pink | | tds2024s | 2 | blue | | tds3052bs | 3 | orange | | NC | 4 | NC | ** Instrument Information | Instrument | Model | Type | Mfg | Description | |-------------+-----------+--------------+-----------+-------------------------------------------------------------------| | 33210a | 33210A | AWG | Agilent | 1 channel, 10MHz, 14-bit, 50 MSa/s, 8Kpt, isolated | | 34401a | 34401A | DMM | Keysight | 6.5 Digit | | 53131a | 53131A | Counter | HP | 2 channels, 10 digits/s, 0-225MHz, 500ps, 5Vac+dc | | 53131a-c | 53131A | Counter(RF) | HP | 1 channel, 10 digits/s, 100MHz-3GHz, 500ps, 5Vac+dc | | dg2052 | DG2052 | AWG | Rigol | 2 channel, 15-50MHz, 16-bit, 250 MSa/s, 16 Mpts/channal, grounded | | dg2052-c | DG2052 | Counter | Rigol | 1 channel, 7 digits/s, 1μHz-240MHz, 4ns-1Ms, 2.5 Vac+dc | | dho4204 | DHO4204 | Oscilloscope | Rigol | DPO, 12-bit, 800MHz, 4 analog channels, 1-4GS/s | | dho4204 | DHO4204 | Counter | Rigol | 1 channels, 3-6 digits/s, 500MHz | | dmm6500 | DMM6500 | DMM | Keithley | 6.5 Digit | | hmc8043 | HMC8043 | Power Supply | R&S | 3 channel | | sds2504xp | SDS2504X+ | Oscilloscope | Siglent | DPO/MSO, 8-bit, 400MHz, 4 analog channels, 1-2GS/s, 16digital | | sds2504xp-a | SDS2504X+ | AWG | Siglent | 1 channel, 10-50MHz, 14-bit, 150 MSa/s, 16 Kpts/channal, grounded | | sds2504xp-c | SDS2504X+ | Counter | Siglent | 1 channel, 7 digits/s | | tds2024 | TDS2024 | Oscilloscope | Tektronix | DSO, 8-bit, 200MHz, 4 analog channels, 2GS/s | | tds3052b | TDS3052B | Oscilloscope | Tektronix | DPO, 9-bit, 500MHz, 2 analog channels, 5GS/s | ** Unicode Chars :PROPERTIES: :CUSTOM_ID: uchars :END: Ω μ ± ≤ ** Macros #+MACRO: cn2con (eval (TEQD-cname2con $1)) #+MACRO: cn2dns (eval (format "=%s=" (or (TEQD-cname2dns $1) "N/A"))) ** Code #+begin_src elisp :exports none :results value :var condat=connect-data :lexical yes (defun TEQD-getelt (title-or-number row) ;; title can be a string (title) or number (column number) or a list of strings and/or numbers. (if (listp title-or-number) (mapcar (lambda (x) (TEQD-getelt x row)) title-or-number) (if (stringp title-or-number) (nth (seq-position (car condat) title-or-number) row) (nth title-or-number row)))) (defun TEQD-getcol (title-or-number) "Pull a column or list of columns. Columns given by string (title) or index (integer)." (let ((cn (if (stringp title-or-number) (seq-position (car condat) title-or-number) title-or-number))) (mapcar (lambda (x) (elt x cn)) condat))) (defun TEQD-cname2con (cname) "Find instrument with cname and return string with connection data" (let ((mp (seq-position condat cname (lambda (a b) (string-equal (TEQD-getelt "cname" a) b))))) (if mp (cl-destructuring-bind (iproto lport rip rport) (TEQD-getelt '("Protocal" "SSH Local Port" "Instrument IP" "Instrument Port") (nth mp condat)) (format "%s://%s:%s (DIRECT) or %s://%s:%s (SSH)" iproto rip rport iproto "127.0.0.1" lport)) "N/A"))) (defun TEQD-cname2dns (cname) "Find instrument with cname and return string with DNS name" (let ((mp (seq-position condat cname (lambda (a b) (string-equal (TEQD-getelt "cname" a) b))))) (if mp (TEQD-getelt "Instrument IP" (nth mp condat))))) (defun TEQD-cname2ip (cname) "Find instrument with cname and return IP address from DNS" (let ((dnsn (TEQD-cname2dns cname))) (if dnsn (dns-query dnsn)))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;(TEQD-getelt "cname" (nth 3 condat)) ;(TEQD-getelt 0 (nth 3 condat)) ;(TEQD-getelt '(0 1 2) (nth 3 condat)) ;(TEQD-getelt '("cname" "Protocal") (nth 3 condat)) ;(TEQD-getcol "cname") ;(TEQD-getcol 6) ;(TEQD-cname2con "tds3052bw") ;(TEQD-cname2dns "tds3052bw") ;(TEQD-cname2ip "tds3052bw") #+end_src #+RESULTS: #+begin_example TEQD-cname2ip #+end_example * SCPI Connected Instruments :PROPERTIES: :CUSTOM_ID: scpi-inst :END: ** Rohde & Schwarz HMC8043 Power Supply :PROPERTIES: :CUSTOM_ID: MSIDhmc8043 :END: *** Links :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-link :END: - Product Page: https://www.rohde-schwarz.com/us/products/test-and-measurement/dc-power-supplies/rs-hmc804x-dc-power-supply-series_63493-61542.html - Documentation: https://www.rohde-schwarz.com/manual/hmc804x/ - Firmware: https://www.rohde-schwarz.com/firmware/hmc804x/ *** Documentation (These links only work on my personal laptop) :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-doc :END: #+BEGIN_EXPORT html #+END_EXPORT *** Local LAN Settings & Addresses (These links only work on my home network) :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-lan :END: - Host name: {{{cn2dns(hmc8043w)}}} - Device Web Server: {{{cn2con(hmc8043w)}}} *** Notes :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-notes :END: **** Back Ports :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-notes-backIO :END: #+ATTR_HTML: :width 90% :align center [[file:MSIDhmc8043-BP.png][file:MSIDhmc8043-BP.png]] - Bottom (Right To Left) - 2x8 Rectangular Connector -- Wago 713-1108 (non-latching), 713-1108/037-000 (latching), 713-1108/037-9037/033-000 (latching + strain relief plate) - 10/100 Base-T Ethernet - USB Type B 2.0 Device - Center: IEC C14/C13: AC Power Connector The pinout of the rectangular connector, as viewed from the back: #+ATTR_HTML: :rules all solid #ccc :frame all :align center | CH3+ | CH3 SENSE+ | CH2+ | CH2 SENSE+ | CH1+ | CH1 SENSE+ | U+ interface / Trigger | I+ interface | | CH3- | CH3 SENSE- | CH2- | CH2 SENSE- | CH1- | CH1 SENSE- | U- interface | I- interface | **** Remote control notes :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-notes-remote :END: This instrument has a very robust SCPI stack. It has never crashed on me from poor network communication or invalid SCPI commands. Results are always terminated by a single newline character. If a SCPI command line with multiple, semicolon separated commands has a result, then it is returned as a single line with the individual results separated by semicolons. *** Remote Control :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote :END: **** *IDN? :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote-idn :END: #+NAME: btn-hmc8043-idn #+begin_src mrscpi :output verbatum :exports both :wrap "src text :eval never :tangle no" :url @hmc8043 :cmd *IDN? #+end_src #+RESULTS: btn-hmc8043-idn #+begin_src text :eval never :tangle no >>*IDN?>> Rohde&Schwarz,HMC8043,042973185,HW42000000,SW01.400 #+end_src **** Default Setup :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote-rst :END: #+NAME: btn-hmc8043-default-setup #+begin_src mrscpi :output verbatum :exports code :url @hmc8043 :result_type nil :echo false :delay_after_complete 50 :cmd *RST #+end_src #+RESULTS: btn-hmc8043-default-setup **** Set voltage & current for each channel :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote-setmeasv :END: #+NAME: btn-hmc8043-set-10-10-5 #+begin_src mrscpi :output verbatum :exports both :wrap "src text :eval never :tangle no" :var avol=15.0 dvol=5.0 acur=150.0e-3 dcur=70.0e-3 :url @hmc8043 :result_type nil :delay_after_complete 200 :cmd :OUTPut:MASTer:STATe OFF :cmd :INSTrument:NSELect 1; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude ${avol}; :SOURce:CURRent:LEVel:IMMediate:AMPLitude ${acur}; :OUTPut:CHANnel:STATe ON :cmd :INSTrument:NSELect 2; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude ${avol}; :SOURce:CURRent:LEVel:IMMediate:AMPLitude ${acur}; :OUTPut:CHANnel:STATe ON :cmd :INSTrument:NSELect 3; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude ${dvol}; :SOURce:CURRent:LEVel:IMMediate:AMPLitude ${dcur}; :OUTPut:CHANnel:STATe ON :result_type :string :delay_after_complete 10 :cmd :INSTrument:NSELect 1; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude?; :SOURce:CURRent:LEVel:IMMediate:AMPLitude? :cmd :INSTrument:NSELect 2; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude?; :SOURce:CURRent:LEVel:IMMediate:AMPLitude? :cmd :INSTrument:NSELect 3; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude?; :SOURce:CURRent:LEVel:IMMediate:AMPLitude? #+end_src #+RESULTS: btn-hmc8043-set-10-10-5 #+begin_src text :eval never :tangle no >>:OUTPut:MASTer:STATe OFF>> >>:INSTrument:NSELect 1; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude 15.0; :SOURce:CURRent:LEVel:IMMediate:AMPLitude 0.15; :OUTPut:CHANnel:STATe ON>> >>:INSTrument:NSELect 2; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude 15.0; :SOURce:CURRent:LEVel:IMMediate:AMPLitude 0.15; :OUTPut:CHANnel:STATe ON>> >>:INSTrument:NSELect 3; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude 5.0; :SOURce:CURRent:LEVel:IMMediate:AMPLitude 0.07; :OUTPut:CHANnel:STATe ON>> >>:INSTrument:NSELect 1; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude?; :SOURce:CURRent:LEVel:IMMediate:AMPLitude?>> 1.5000E+01;1.5000E-01 >>:INSTrument:NSELect 2; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude?; :SOURce:CURRent:LEVel:IMMediate:AMPLitude?>> 1.5000E+01;1.5000E-01 >>:INSTrument:NSELect 3; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude?; :SOURce:CURRent:LEVel:IMMediate:AMPLitude?>> 5.000E+00;7.0000E-02 #+end_src **** Turn on master output :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote-masterout :END: Check the values above to make sure the settings are correct, and then activate the supply output like this: #+NAME: btn-hmc8043-master-on #+begin_src mrscpi :output verbatum :exports both :wrap "src text :eval never :tangle no" :url @hmc8043 :result_type nil :delay_after_complete 50 :cmd :OUTPut:MASTer:STATe ON :result_type string :delay_after_complete 10 :cmd :OUTPut:MASTer:STATe? #+end_src #+RESULTS: btn-hmc8043-master-on #+begin_src text :eval never :tangle no >>":OUTPut:MASTer:STATe ON\n">> >>":OUTPut:MASTer:STATe?\n">> 1 #+end_src **** Check voltage and current :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote-readv :END: We can check the current voltage and current like so: #+NAME: btn-hmc8043-measure-VA #+begin_src mrscpi :output verbatum :exports both :wrap "src text :eval never :tangle no" :url @hmc8043 :delay_after_complete 10 :read_timeout_next_byte 20 :result_type nil :cmd :INSTrument:NSELect 1 :result_split :ssv # Note: R&S devices return semicolon seporated values from compound SCPI statements :result_type :float :cmd :MEASure:SCALar:VOLTage:DC?; :MEASure:SCALar:CURRent:DC? :result_type nil # Note: We don't have to turn off split because a nil type means we don't even try and read a result :cmd :INSTrument:NSELect 2 :result_type :float :cmd :MEASure:SCALar:VOLTage:DC?; :MEASure:SCALar:CURRent:DC? :result_type nil :cmd :INSTrument:NSELect 3 :result_type :float :cmd :MEASure:SCALar:VOLTage:DC?; :MEASure:SCALar:CURRent:DC? #+end_src #+RESULTS: btn-hmc8043-measure-VA #+begin_src text :eval never :tangle no >>:INSTrument:NSELect 1>> >>:MEASure:SCALar:VOLTage:DC?; :MEASure:SCALar:CURRent:DC?>> [0.0, 0.0] >>:INSTrument:NSELect 2>> >>:MEASure:SCALar:VOLTage:DC?; :MEASure:SCALar:CURRent:DC?>> [0.0, 0.0] >>:INSTrument:NSELect 3>> >>:MEASure:SCALar:VOLTage:DC?; :MEASure:SCALar:CURRent:DC?>> [0.0, 0.0] #+end_src **** Sequenceing :PROPERTIES: :CUSTOM_ID: MSIDhmc8043-remote-seq :END: Here we sequence the thrid channel to come on 90ms after the first two. #+NAME: btn-hmc8043-set-10-10-5-seq #+begin_src mrscpi :output verbatum :exports code :var avol=15.0 dvol=5.0 acur=150.0e-3 dcur=70.0e-3 del1=10.0 del2=100.0 :url @hmc8043 :echo false :result_type nil :delay_after_complete 200 :cmd :OUTPut:MASTer:STATe OFF # Set 9V & 08mA on Ch1 & Ch2. Set 5V @ 60mA on Ch1. :cmd :INSTrument:NSELect 1; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude ${avol}; :SOURce:CURRent:LEVel:IMMediate:AMPLitude ${acur}; :cmd :INSTrument:NSELect 2; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude ${avol}; :SOURce:CURRent:LEVel:IMMediate:AMPLitude ${acur}; :cmd :INSTrument:NSELect 3; :SOURce:VOLTage:LEVel:IMMediate:AMPLitude ${dvol}; :SOURce:CURRent:LEVel:IMMediate:AMPLitude ${dcur}; # Set Ch1 & Ch2 to start first, and then Ch3 90ms later. :cmd :SEQuence:STATe OFF :cmd :INSTrument:NSELect 1; :SEQuence:CHANnel:STATe ON; :SEQuence:DELay ${del1}; :SEQuence:TRIGgered OFF :cmd :INSTrument:NSELect 2; :SEQuence:CHANnel:STATe ON; :SEQuence:DELay ${del1}; :SEQuence:TRIGgered OFF :cmd :INSTrument:NSELect 3; :SEQuence:CHANnel:STATe ON; :SEQuence:DELay ${del2}; :SEQuence:TRIGgered OFF :cmd :SEQuence:STATe ON # Activate all the channels :cmd :INSTrument:NSELect 1; :OUTPut:CHANnel:STATe ON :cmd :INSTrument:NSELect 2; :OUTPut:CHANnel:STATe ON :cmd :INSTrument:NSELect 3; :OUTPut:CHANnel:STATe ON # At this point, the master enable needs to be pressed. #+end_src #+RESULTS: btn-hmc8043-set-10-10-5-seq #+begin_src text :eval never :tangle no #+end_src ** Agilent 33210A Arbitrary Waveform Generator :PROPERTIES: :CUSTOM_ID: MSID33210a :END: *** Links :PROPERTIES: :CUSTOM_ID: MSID33210a-link :END: - Product Page: https://www.keysight.com/us/en/product/33210A/33210a-waveform-and-function-generator.html - Firmware & Documentation: https://www.keysight.com/us/en/support/33210A/33210a-waveform-and-function-generator.html *** Documentation (These links only work on my personal laptop) :PROPERTIES: :CUSTOM_ID: MSID33210a-doc :END: #+BEGIN_EXPORT html #+END_EXPORT *** Local LAN Settings & Addresses (These links only work on my home network) :PROPERTIES: :CUSTOM_ID: MSID33210a-lan :END: - Host name: {{{cn2dns(33210aw)}}} - Device Web Server: {{{cn2con(33210aw)}}} *** Notes :PROPERTIES: :CUSTOM_ID: MSID33210a-notes :END: **** Performance & Operational Facts :PROPERTIES: :CUSTOM_ID: MSID33210a-notes-perf :END: - Primary Output - 50 Ω typical - Isolation 42 Vp maximum to earth - Short-circuit protected. Overload disables main output. - Typical Current - 10 Vpp sine wave at 1 kHz into a 0.5 Ω load: 135 mArms - 1 Vpp sine wave at 1 kHz into a 0.5 Ω load: 13 mArms - Current is a linear function of V between 1 Vpp and 10 Vpp - 10 MHz Reference Clock (input/output) - Input - Lock range: 10 MHz ± 500 Hz; - Level: 100 mVpp to 5 Vpp - Impedance: 1 kΩ - Output - Frequency: 10 MHz - Level: 632 mVpp - Impedance: 50 Ω AC coupled - Arb Spec - Frequency: 1 mHz to 3 MHz - Points: 2 pts to 8 kPts - Resolution: 14 bits - Sample rate: 50 MSa/s - Minimum rise/fall time: 70 ns (vs 20 ns for square & pulse waveforms) **** Back Ports :PROPERTIES: :CUSTOM_ID: MSID33210a-notes-backIO :END: #+ATTR_HTML: :width 90% :align center [[file:MSID33210a-BP.png][file:MSID33210a-BP.png]] - Right Side Top (4 ports arranged in a square) - Top Right: BNC External 10 MHz Reference Input (Option 001) - Top Left: BNC External 10 MHz Reference Output (Option 001) - Bottom Right: BNC External Modulation Input Terminal - Bottom Left: BNC External Trigger Input, Burst Gate Input, or rigger Output - Bottom Center Right To Left - USB 2.0 Device - 10/100 Base-T Ethernet - GPIB Interface - Left Side Top: IEC C14/C13: AC Power Connector *** Remote Control :PROPERTIES: :CUSTOM_ID: MSID33210a-remote :END: **** *IDN? :PROPERTIES: :CUSTOM_ID: MSID33210a-remote-idn :END: #+NAME: btn-33210a-idn #+begin_src mrscpi :output verbatum :exports both :wrap "src text :eval never :tangle no" :url @33210a :cmd *IDN? #+end_src #+RESULTS: btn-33210a-idn #+begin_src text :eval never :tangle no >>"*IDN?\n">> Agilent Technologies,33210A,MY48001014,1.04-1.02-22-2 #+end_src **** Standard Waveforms :PROPERTIES: :CUSTOM_ID: MSID33210a-remote-stdwav :END: =APPLy= arguments are frequency, amplitude, and offset: #+begin_src mrscpi :output verbatum :exports code :url @33210a :echo false :result_type nil :cmd :APPLy:SINusoid 5 KHZ, 3.0 VPP, -1.0V #+END_SRC #+RESULTS: **** ARB :PROPERTIES: :CUSTOM_ID: MSID33210a-remote-arb :END: We use the command =DATA= for floating point values in the range [-1.0, 1.0]. #+begin_src mrscpi :output verbatum :exports code :url @33210a :echo false :result_type nil # Turn off the output :cmd :OUTPut OFF # upload 4 floating point values for the waveform to VOLATILE memory :cmd :DATA VOLATILE,-1.0,1.0,0.0 # Select the waveform in VOLATILE memory :cmd :FUNCtion:USER VOLATILE # Set waveform properties :cmd :FREQuency 5 kHz :cmd :VOLTage 3.0 VPP :cmd :VOLTage:OFFS 0 # Turn on the output :cmd :OUTPut ON #+END_SRC #+RESULTS: We use the command =DATA:DAC= for integer values in the range [-8191, 8191]. #+begin_src mrscpi :output verbatum :exports both :wrap "src text :eval never :tangle no" :url @33210a :result_type nil # Turn off the output :cmd :OUTPut OFF # upload 4 (up to 8k supported) integer values for the waveform :cmd :DATA:DAC VOLATILE,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,8191 # Move the VOLATILE waveform into non-VOLATILE storage. The system can store 4 non-VOLATILE waveforms. Names for waveforms may be up to 12 characters. :cmd :DATA:COPY AN_ARB_NAME :result_type :string # List non-VOLATILE waveforms stored. :cmd :DATA:NVOLatile:CATalog? :result_type nil # Select the waveform we just saved :cmd :FUNCtion:USER AN_ARB_NAME # Set waveform properties :cmd :FREQuency 5 kHz :cmd :VOLTage 3.0 VPP :cmd :VOLTage:OFFS 0 # Turn on the output :cmd :OUTPut ON #+END_SRC #+RESULTS: #+begin_src text :eval never :tangle no >>":OUTPut OFF\n">> >>":DATA:DAC VOLATILE,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,-8191,8191\n">> >>":DATA:COPY AN_ARB_NAME\n">> >>":DATA:NVOLatile:CATalog?\n">> "AN_ARB_NAME" >>":FUNCtion:USER AN_ARB_NAME\n">> >>":FREQuency 5 kHz\n">> >>":VOLTage 3.0 VPP\n">> >>":VOLTage:OFFS 0\n">> >>":OUTPut ON\n">> #+end_src ** Keysight 34401A Bench Digital Multimeter :PROPERTIES: :CUSTOM_ID: MSID34401a :END: *** Links :PROPERTIES: :CUSTOM_ID: MSID34401a-link :END: - Product Page: https://www.keysight.com/us/en/product/34401A/digital-multimeter-6-digit.html - Documentation: https://www.keysight.com/us/en/support/34401A/digital-multimeter-6-digit.html *** Documentation (These links only work on my personal laptop) :PROPERTIES: :CUSTOM_ID: MSID34401a-doc :END: #+BEGIN_EXPORT html #+END_EXPORT *** Local LAN Settings & Addresses (These links only work on my home network) :PROPERTIES: :CUSTOM_ID: MSID34401a-lan :END: - Serial over IP access: {{{cn2con(34401as)}}} *** Serial Settings (Lantronix console server) :PROPERTIES: :CUSTOM_ID: MSID34401a-serial :END: #+ATTR_HTML: :align center :cellpadding 2px | Parameter | Setting | | | | |--------------+------------------------| | Cable | crossover (null modem) | | Line | 1 | | TCP/IP Port | 10001 | | Serial | RS232 | | Baud | 9600 | | Parity | Even | | Data Bits | 7 | | Stop Bits | 2 | | Flow Control | SOFT | | Xon | ^Q | | Xof | ^S | *** Notes :PROPERTIES: :CUSTOM_ID: MSID34401a-notes :END: **** Performance & Operational Facts :PROPERTIES: :CUSTOM_ID: MSID34401a-notes-perf :END: - Voltage Measurement Input Impedance - With =INPut:IMPedance:AUTO= set to =OFF= (startup default), 10MΩ for all ranges - With =INPut:IMPedance:AUTO= set to =ON=, 10 Gohm for 100 mVdc, 1 Vdc, and 10 Vdc ranges and 10MΩ for the rest. - Front Panel Digits Buttons (Resolution) for DC measurements #+ATTR_HTML: :align center :rules all :cellpadding 2px | Digits | Description | Integration Time | | | | | |--------+--------------+------------------| | 4 | Slow 4 Digit | 1 PLC | | 5 | Slow 5 Digit | 10 PLC | | 6 | Fast 6 Digit | 10 PLC | - Digits/Resolution for AC measurements - Fixed at 6.5 digits - Fixed at 5.5 digits for continuity and diode tests - AC Current Shunt Resistance: 0.1Ωfor 1A& 3 A. 5Ωfor 10mA and 100mA. - AC Bandwidth: 300kHz - Resistance Test Current #+ATTR_HTML: :align center :rules all :cellpadding 2px | Range | Current | | | | |-------+---------| | 100Ω | 1mA | | 1kΩ | 1mA | | 10kΩ | 100μA | | 100kΩ | 10μA | | 1MΩ | 5μA | | 10MΩ | 500nA | | 100MΩ | 500nA | - Continuity & Diode Test Current: 1mA - VM Complete Output: 5V TTL normally high. 2 μs low pulse after the completion of each measurement. - External Trigger Terminal: 5V TTL normally high. Trigger measurement via a low pulse with a width greater than 1 μs. This low pulse may be created by shorting the input to ground. **** Back Ports :PROPERTIES: :CUSTOM_ID: MSID34401a-notes-backIO :END: #+ATTR_HTML: :width 90% :align center [[file:MSID34401a-BP.png][file:MSID34401a-BP.png]] - Right Side (6 ports arranged 3x2 grid mirroring the front banana inputs) - Top Right: Banana HI Sense (4W Ω) - Top Left: Banana HI Input (V Ω Diode) - Middle Right: Banana Sense LO - Middle Left: Banana Input LO - Bottom Right: Current Fuse - Bottom Left: Banana 3A input - Bottom Center (Right To Left) - BNC VM Complete Output - BNC External Trigger - Bottom Left (Right To Left) - GPIB Interface - DB9 Serial Interface - Center: Chassis Ground Screw - Top (Left of center): IEC C14/C13: AC Power Connector **** Remote control notes :PROPERTIES: :CUSTOM_ID: MSID34401a-note-remote :END: Results read from this instrument use MS-DOS line ending conventions -- i.e. they end with a carriage return and newline (\r\n). For this reason I generally set =:result_chomp= to =true= in {{{MRSCPI}}} scripts. For reliable results over the serial interface, the instrument must be set to "remote" mode before any other commands are issued. When finished, the instrument should be released to "local" mode. Simple, single SCPI command sessions may sometimes be preformed without this mode switching -- for example, sending a simple =*IDN?= command generally works. See: [[#MSID34401a-serialrc-notes][Serial Remote Control Best Practice]]. I have tested the Prologix Ethernet adapter with this meter's GPIB interface and it works perfectly. That said, I normally use the serial interface. **** Undocumented :PROPERTIES: :CUSTOM_ID: MSID34401a-note-undoc :END: ***** PEEK & POKE :PROPERTIES: :CUSTOM_ID: MSID34401a-note-undoc-peek :END: | SCPI Command | Function | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:POKE 25,0,<1/0>~ | Enable/Disable 10mA AC range | | ~DIAG:POKE 27,0,<1/0>~ | Enable/Disable 10kHz AC filter | | ~DIAG:POKE 28,0,<1191/0>~ | Enable/Disable standard deviation and peak-to-peak | | ~DIAG:POKE 30,0,<1191/0>~ | Enable/Disable internal and external temperature sensors | | ~DIAG:POKE 31,0,<1191/0>~ | Enable/Disable scale calculations | | ~DIAG:POKE 32,0,<1191/0>~ | Enable/Disable custom conversion apertures | | ~DIAG:POKE 33,0,<1191/0>~ | Enable/Disable state storage and power-on auto-recall | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:POKE 29,0,1~ | Display original measured values in temperature measurement mode | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:PEEK? -10,1,0~ | Check feature: Standard deviation and peak-to-peak | | ~DIAG:PEEK? -10,2,0~ | Check feature: Internal temperature and external temperature sensors | | ~DIAG:PEEK? -10,3,0~ | Check feature: Scale calculation | | ~DIAG:PEEK? -10,4,0~ | Check feature: Custom conversion aperture | | ~DIAG:PEEK? -10,5,0~ | Check feature: state store | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:PEEK? 0,,0~ | Read RAM byte | | ~DIAG:PEEK? 1,,0~ | Read RAM word | | ~DIAG:PEEK? 2,,0~ | Read RAM double word | | ~DIAG:PEEK? 3,,0~ | Read RAM floating-point | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:PEEK? -1,,0~ | reads the EEPROM low zone (set) word and returns it in decimal | | ~DIAG:PEEK? -2,,0~ | reads the EEPROM high zone (calibration) word and returns it in a specific format | | ~DIAG:PEEK? -3,,0~ | ROM ref values for specified block | | ~DIAG:PEEK? -4,0,0~ | reads power line frequency 1=50/400Hz | | ~DIAG:PEEK? -5,0,0~ | Whether there is a waiting interrupt | | ~DIAG:PEEK? -6,0,0~ | Read the stack dump from the previous interrupt | | ~DIAG:PEEK? -7,0,0~ | reads ADC raw data | | ~DIAG:PEEK? -8,0,0~ | *DANGEROUS:* [unsecured] enable: ZERO DCV | | ~DIAG:PEEK? -9,0,0~ | Number of rows in the block table | | ~DIAG:PEEK? -11,0,0~ | lookup NVRAM data by block using the index to stored address | | ~DIAG:PEEK? -12,0,0~ | lookup block table in ROM data using index to stored address | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:POKE 34,0,0~ | *DANGEROUS:* reset CPU | | ~DIAG:POKE 23,0,0~ | *DANGEROUS:* resets calibration count | | ~DIAG:POKE 0,0,0~ | *DANGEROUS:* increases the calibration count | | ~DIAG:POKE -2,,~ | *DANGEROUS:* Write RAM bytes | | ~DIAG:POKE -3,,~ | *DANGEROUS:* Write RAM words | | ~DIAG:POKE -4,,~ | *DANGEROUS:* Write RAM floating-point | |------------------------------+-----------------------------------------------------------------------------------| | ~DIAG:PEEK? -2,,0~ | Obtain 34401 calibration data | The range numbers for "~DIAG:PEEK? -2~" are: | Func | RANGE values | |------+--------------| | DCV | 75-79 | | DCI | 82-85 | | OHM | 87-92 | | OHM4 | 94-99 | | ACV | 104-108 | The returned value for "~DIAG:PEEK? -2~" is: "~,,<0>,,~". NVRAM storage is split into numbered blocks. The low part is for safe changes. The high part is for calibration data and can only be written when unsecured. Example blocks: | BLOCK | Description | |-------+--------------------------------------------------------------------------------------------------| | 70 | Count gain between T2 ticks and residual on 80C196 AD | | 71 | Non-linear correction coeff1 (quadratic) | | 73 | Non-linear correction coeff2 (cubic) | | 76 | Transform params for DC 1V range (multiplier, shift, NA, offset, ?) must be scaled for line/NPLC | ***** Features :PROPERTIES: :CUSTOM_ID: MSID34401a-note-undoc-feat :END: - Standard deviation and peak-to-peak (~DIAG:POKE 28~) :: - New SCPI Commands: - ~CALCulate:AVERage:SDEViation?~ :: - ~CALCulate:AVERage:PTPeak?~ :: - New Menu: - ~math menu -> min-max: sdev, pp~ :: - Internal and external temperature sensors (~DIAG:POKE 30~) :: - New SCPI Commands: - ~CONF:TEMPerature?~ :: - ~CONF:TEMPerature {TCouple|RTD|FRTD|THERmistor|DEFault},{TC type, or (F)RTD alpha, or Thermistor type},{|MIN|MAX|DEF},{|MIN|MAX|DEF}~ :: Temperature measurement mode/transducer/subtype. \\ No query possible. \\ Transducer value of ~DEFault~ means "last used" \\ Range is ignored \\ - ~CONF?~ :: With temperature enabled, this also returns transducer type and subtype in addition to range/resolution (range fixed as "1") - ~UNIT:TEMPerature?~ :: - ~UNIT:TEMPerature {Cel|Far|K}~ :: - ~SENSe:TEMPerature:TRANsducer:TYPE?~ :: - ~SENSe:TEMPerature:TRANsducer:TYPE {TCouple|RTD|FRTD|THERmistor|DEFault}~ :: FRTD is 4W RTD \\ RTD is 2W \\ DEFault = TC -- WARNING: this behaviour is diffrent from CONF:TEMP - ~SENSe:TEMPerature:NPLCycles?~ :: - ~SENSe:TEMPerature:NPLCycles {0.02|0.2|1|10|100|MINimum|MAXimum}~ :: - ~SENSe:TEMPerature:TRANsducer:TCouple:TYPE?~ :: - ~SENSe:TEMPerature:TRANsducer:TCouple:TYPE {B|E|J|K|N|R|S|T}~ :: - ~SENSe:TEMPerature:TRANsducer:TCouple:RJUNction?~ :: - ~SENSe:TEMPerature:TRANsducer:TCouple:RJUNction {MIN|MAX}~ :: - ~[SENSe]:TEMPerature:TRANsducer:TCouple:RJUNction?~ :: - ~[SENSe]:TEMPerature:TRANsducer:TCouple:RJUNction {|MIN|MAX}~ :: Reference junction temperature for TC, -1 to 55C range - ~SENSe:TEMPerature:TRANsducer:RTD:TYPE?~ :: - ~SENSe:TEMPerature:TRANsducer:RTD:TYPE {85|91}~ :: RTD alpha value, 0.00385 or 0.00391 - ~SENSe:TEMPerature:TRANsducer:RTD:RESistance:REFerence?~ :: - ~SENSe:TEMPerature:TRANsducer:RTD:RESistance:REFerence {R0 resistance>|MIN|MAX}~ :: RTD reference (25C) resistance, 4.9 - 2100 ohm range - ~SENSe:TEMPerature:TRANsducer:THERMistor:TYPE?~ :: - ~SENSe:TEMPerature:TRANsducer:THERMistor:TYPE {2200,5000,10000}~ :: Thermistor type (in ohms) \\ The first two are B=3975. The last is B=3695 - ~DIAGnostic:TEMPerature?~ :: Read internal on-chip temperature sensor. \\ This causes relay(s) to activate regardless of selected function. - New Menu: - ~temp menu~ - Scale calculations (~DIAG:POKE 31~) :: - New SCPI Commands: - ~CALCulate:FUNCtion SCALe?~ :: - ~CALCulate:FUNCtion SCALe~ :: Only one math operation is available at a time. For example min/max can't be used at the same time as SCALE. - ~CALCulate:SCALe:GAIN?~ :: - ~CALCulate:SCALe:GAIN~ :: - ~CALCulate:SCALe:OFFSet?~ :: - ~CALCulate:SCALe:OFFSet~ :: - New Menu: - ~menu -> scale~ - Custom conversion apertures (~DIAG:POKE 32~) :: - New SCPI Commands: - ~:APERture?~ :: - ~:APERture {