This program makes sequential measurements and saves the results to a semi-colon delimited text file (*.csv) which can be directly loaded into MS Excel and used to produce a nice graph of the measurements.
Communication is through GPIB. It's very flexible and rate, time, instrument, query command, conditional commands, parameters to be added to the file etc. are fully selectable. All settings could be saved and
are loaded when the program is started. An Excel macro file and a sample printout could be downloaded at the bottom of this page.
Dec 25, 2018 - New version 2.0
Changes from 1.5 to 2.0:
Run Time Error if Path Button is clicked and the path didn't exist.
Clearing Device ID didn't clear ID Response.
Loading a saved setting with a second GPIB address that didn't exists didn't turn off Cond Commands.
File and Tools menus were not disabled during a running sequence.
Hitting Enter in timing boxes to select Apply possible even when Apply Button was disabled.
Entering Total Minutes as 0:seconds e.g. 0:30 gave incorret total time.
In Conditional Command number of selectable "Consecutive Conditions Met" increased to 30.
In Conditional Command number of selectable percent settings changed to 30.
Entering Total Time changed to Hours:Minutes rather than Minutes:Seconds. Number only is hours.
Code for input boxes changed to accept only valid characters, Timing boxes will translate period and comma to colon.
Text in Sequence Frame Text boxes changed when a sequence was manually stopped and color changed to red of the first box.
The word Aborted in the Sequence in Progress Text box changed to Terminated.
The word Done in the Sequence in Progress Text box changed to Completed.
Label Current Measurement changed to Latest Measurement.
Color of Conditional Commands label text on Sequence frame changed to blue from red.
Some message boxes slightly changed in text and graphic symbol.
In Conditional Command now possible to have both one of < , > , = and "Less than Max Value" conditions active at the same time.
In Conditional Command > and < expressions now also use expression plus or minus percents rather than only exact value . For exact value use 0%.
In Conditional Command "Less than Max Value" now includes target values in percent of max rather than just less. For exact value use 0%
In Conditional Command "Less than Max Value" now also have an option to select Less Than Max Value minus an absolute value.
Added Menu items to save five more settings than just last one i.e. Startup plus five other settings.
Added Menu items to recall five saved settings plus Startup and Default settings.
Added a message box to show Conditional Command data e.g. Conditional type, reason for aborted sequence, target values and last measurement in case of an terminated sequence.
Shows up at a terminated sequence but can also be opened from the Tools menu.
Added Menu item under About to show Conditional Command settings, enabled all the time when Conditional Command is active.
Added button "Create New Folder" on "Select Path" window.
Added Query to add a prefix to a log-file or replace it in case it already exists.
Added option on Test window to convert measurements in Scientific notation to Decimal notation.
Added a popup menu to the File Name Text box to open the current file in Excel.
Most Text boxes now cleared by double click.
DeviceID and Measurement Query Text boxes now change text in lower case to upper case.
Added Tool Tips on Time labels to show valid time formats.
Change background color of Latest Measurement text box whenever a condition is met.
Note: Saved Conditional Command settings from an earlier versions will not be correctly recalled with this version.
Changes from 1.41 to 1.5:
Actual Number of consecutive measurements needed to stop the sequence was one less than indicated on the Conditional Commands window.
The Target Value text box on Conditional Commands window now only accept plus, minus, comma, period and numbers.
The text of the Sequence In Progress textbox on the main window changed to red for message "Aborted" after a condition was met and the sequence was stopped.
GPIB Communicator (on Tools Menu) changed to the latest version (1.91).
URL to check for updates changed to the actual page rather than an index page.
Added Conditional Commands setting to abort a sequence if the measured value is less than the accumulated Max value.
Changes from 1.40 to 1.41:
The File Name box is now prevented from containing path. Should be filename only.
Selecting another drive in the Path box a second time could cause a false error.
Now possible to view the About window with a command line switch /?. A command file doing this is now included in the setup.
Changes from 1.32 to 1.40:
The value of the manually selected GPIB address was not saved and the list defaulted to the lowest found address on the bus. Now it is saved.
Should the saved address not be available on the bus the list shows "None".
The dialog box to set Excel path always started with "c:\". Now it starts with the currently set path.
The Log File path box now changes according to the path of the selected Log File name when the Log File name is changed via the dialog box.
Path cannot be entered in the Log File box.
Settings now stored in Registry rather than in an ini-file
Set Log File Name added to File Menu
Changes from 1.31 to 1.32:
Couldn't load the log file with MS Excel from the program if the path contained spaces e.g. c:\Documents and Settings\User\My Documents
Newer version (v1.83) of GPIBcomm.
Changes from 1.3 to 1.31:
Incorrect time display in the Sequence frame, Elapsed Time, Remaining Time and Time From Start in Log file when minutes was selected fixed.
Only displayed time was wrong, the actual sequence was OK.
Misspelled keyword in the log file corrected. This will result in an incorrect Command when starting with an ini-file from previous version - just correct and resave.
An error message added if Time Interval is in seconds and time is entered with a colon e.g. 1:30.
Sequence frame caption color changed to Red when Conditional Command is ON.
Sequence frame caption now also says Conditional Command OFF (in black) when Conditional Command is OFF.
Button for Conditional Command added to main window in addition to the Menu item.
The way the dropdown lists on Conditional Command window are initiated changed. This will result in wrong settings when starting with an ini-file from previous version - just correct and resave.
New warning message if Conditional Command is selected and not all parameters are defined.
The help message in the Test Measurement Query window altered to make it more understandable.
Changes from 1.2.2 to 1.3:
Connect button now isn't enabled when no saved settings are available (i.e. ini-file missing).
Newer version (v1.8) of GPIBcomm.
Function to send a GPIB command to a second device at certain conditions (see below).
Changes from 1.2.1 to 1.2.2:
Two minor bugs fixed:
Some devices could have timing problems at Connect causing Read Error,
DeviceID, used to identify at Connect, was case sensitive.
Changes from 1.2.0 to 1.2.1:
Changing between Sec and Min now doesn't clear Time Interval (introduced with v1.1),
All Frames except Sequence now disabled during a running sequence,
Time is now displayed correctly, also hours,
Stop sequence now stops the sequence immediately rather than waiting for the current sequence to finish,
Enabling/disabling of several buttons and boxes corrected,
Timing Frame now doesn't show 0 seconds if there are no seconds in the sequence (i.e. 1 hour 1 minute 0 seconds to 1 hour 1 minute),
Path to Excel-file now loads correctly at start,
No Save question now at quit if nothing changed.
Time from start in log file now in format hh:mm:ss instead of seconds,
Info button on Test window renamed to Help.
Changes from 1.1.0 to 1.2.0:
Yes, there are few and I'm working on it. Hopefully a new version will be available soon.
GPIB address could now be selected manually (for instruments not responding to ID? or *IDN?,
Another GPIB device can now be connected without having to restart the program,
Wildcards can now be used to exclude characters of the query response string and an Info button added,
Space(s) in the beginning of Exclude strings now permitted.
Changes from 1.0.0 to 1.1.0:
A total redesign of the main window,
Changing between Sec and Min for Time Interval now clears Time Interval box,
Latest Measurement label changed to Current Measurement,
Stop Sequence now clears progress bar,
Pressing Enter at any box inside Timing frame triggers Apply,
The way the Log File path was defined changed, the path has been split into Path and File Name.
Mini button added,
Total Minutes didn't clear Number of Sequences if beginning with a 0 (zero),
Start Sequence button became enabled after first sequence, now stays disabled until finished,
Seconds and minutes in Time Interval didn't have the same result in sequences i.e. 5 secs vs 0:05 min,
GPIB Communicator added as part of the program for easy testing of commands,
Open current log file with Excel from a menu,
Show Remaining Sequences,
Show Elapsed Time,
Show Remaining Time.
Here is a screen shot of a measurement sequence, every 2 seconds during 1 minute.
Number of Sequences (= measurements) says 31 because the first one is always done at time = 0.
Operation is not all obvious so some explanation may be needed:
Time Interval: The time between measurements in seconds or minutes.
Format for Minutes is as minutes:seconds or minutes only
Comma or period will be translated to colon and Enter = Apply.
Number of Sequences or Total Time: Only one could be entered. Click Apply when done.
Format for Total Time is hours:minutes, hours or :minutes
Comma or period will be translated to colon and Enter = Apply.
Log File: The path and name of the file where the data is stored.
Path: Click Find to open another window and select a folder.
File Name: Either click Find or enter manually in the text box.
Some countries use a comma for decimal separator so for Excel to understand the data select the right one for you.
ID String: The ID query command the program sends to identify an instrument.
Most of Tek's newer instruments are backwards compatible so they understand both but many others don't.
Manual GPIB Address: Select this to manually connect to an available GPIB address in the drop down list which will appear.
This is to be used when an instrument won't respond to either ID? or *IDN?.
Device ID: The expected reply from the selected instrument. It could be partial.
ID response: The actual ID response from the instrument.
Measurement Query: The command query used to force the instrument to send a measurement value.
This could also be defined on the Test window.
Conditional Command: Click this button to open the Conditional Commands window. Same as Tools/Conditional Command, see below.
This screen will show the actual measurement response.
Translation from Scientific Notation measurement response to Decimal Notation is selected here.
If you want mask away part of the measurement response, make a selection in the Query Response text box.
Then click Add
The selection is copied to the Exclude text box and will be removed from the response.
To recheck click Refresh.
The Exclude boxes can also be manually entered/edited.
The excluded text is the actual string shown in the Exclude text boxes and not absolute positions in the original string.
Some wildcards can be used, click Help for rules.
When done click OK to save the data and return to the main screen .
Connect: Click this button and if the instrument is found on the bus it's full ID response is shown in the ID Response text box.
If more than one instrument could reply to the query only the one with the lowest address will.
Start Sequence: Click this button to initiate the sequence.
Tools/GPIB Comm: Can be used to communicate with the instrument to explore commands and queries.
Tools/Conditional Command (New in v1.3): Lets you define a command, a device and conditions to be met for a
command to be sent to a second device. Very convenient if, for example, you want to record a discharge curve of
a battery and you don't want it to be too deep discharged. Hook up the load via a relay driven by a programmable
power supply and turn off the supply when the voltage has dropped to your preset level.. New in v1.5 is the
"Less than last Max Value" option which means that the target value is updated for each setting if it is higher than the
previous target value. With this you can record a rising value and stop the recording if it starts to drop. Useful
for charging batteries.
This example was done on a 1.5 kHz signal every 2 seconds during 40 seconds using a Tek DC5010 Frequency Counter.
To enter the measurement data into MS Excel select "Open Current Log File with Excel" in the File Menu.
To do that the correct path to the MS Excel exe file must have been defined.
When loaded into MS Excel (2003) it could look like something this after only these few manual steps:
Select Columns A thru D.
Select all data in Columns C and D. Selecting A or B instead of C will change the scale of the X-axis.
Insert/Chart/XY (Scatter)/Chart #3/Finish
You must have a NI GPIB card with the proper drivers installed. Find and download National Instruments GPIB card drivers here.
It is expected to work on any PC/win OS (not 3.1) with a correctly installed and working NI card.
Download Measurement Logging here
NOTE ! Be sure to uninstall any older version before installing this version.
The ini-file from v1.0 is not be compatible with other versions below 1.40 so you'd have to delete it too. v1.40 and up doesn't use the ini-file.
v1.1 and higher are OK but some saved entries on Conditional Commands window may have to be corrected.
Some Conditional Commands settings from earlier versions may not be correct when v1.5 or 2.0 has been installed.
Download an Excel file with macros to load data, create chart, save data and print a chart only.
Download a sample printout of a discharge sequence of an 18650 LiIon battery.
Email me with comments /Håkan
Home / Go back