close-circle
Close
0%
0%

Screen Capture Utility for Tektronix THS720 Scopes

A screen capture tool for Tektronix THS720 Oscilloscopes

Similar projects worth following
close
This is a screen capture tool for THS720 (and probably 710, 730) Oscilloscopes. It connects through the serial port on the scope, and stores a .bmp file of the current screen display. Distributed as source code, it is licensed with a BSD2.0 license.

The THS720 is a nice little battery powered 100MHz, two channel digital scope from the late 1990's. Tektronix still has the Programmers manual for this scope (shows the 710, 720, and 730 as being the same command set) on their web site. They also have some Visual Basic example code for screen captures and simple control. As a Linux/Unix user, Visual Basic is not terribly useful, so I wrote this tool in ANSII C. This project was developed under Fedora 24, talking to a THS720P scope so it should work with most dists. Later, MS support was added.

For MS users, an executable file is included. For Linux users, you will have to compile it via Make. To use this utility, download and unzip the source code in a directory. Type:

make

to compile it.

The path to the serial port defaults to /dev/ttyUSB0. You can modify the default in the file ths_dump.c, line 49 if you are using a different serial port. You can also set the path to the serial port from the command line. I tested this with a few of the "no name" usb to serial cables in my lab, and one had issues with dropping bytes, but the motherboard serial port was reliable. The real FTDI cable worked correctly also.

Set the scope up to use 9600 Baud, N81 communications with "Hard Flagging" enabled (hardware handshake) and connect the serial port to the PC.

Run the program as:

ths_dump foo.bmp

to store the current screen image to the file foo.bmp.

If you want to see what command line options this program supports, type:

ths_dump ?

and it will list

-D device_path (the serial port you are using)

-S baud_rate (the com speed, only tested at 9600)

-L image_size_over-ride (lets you pick an arbitrary image file size for testing)

-C (shows the BSD license text and exits)

If you don't provide an output file name, the program will complain and exit.

ths_dump_for_windows.zip

Ported to run in a windows command line environment. Built with MINGW/Msys. Source code and an executable file.

Zip Archive - 43.37 kB - 08/27/2017 at 19:09

download-circle
Download

ths_dump_08_18_2017.zip

Source code and Makefile for program. Added the forgotton standard_constants.h file.

Zip Archive - 13.50 kB - 08/19/2017 at 00:43

download-circle
Download

  • Ported to Windows Command line

    Bharbour08/27/2017 at 19:26 0 comments

    I was using my scope at a contract gig, and needed to store some screen shots. There were no Linux boxes to be had, so next weekend at home, I ported the code to be built in a MINGW/Msys tool chain. The code has been tested and works on a Windows 7 box and a Windows 8 box.

    One thing to note, the Windows 7 box was assigning crazy high COMx: numbers like COM17: and COM18: to my USB to serial converter. The MSYS file open function would not tolerate com ports that high and errored out. I found a com port number 2 that had not been assigned already, and edited the COM port name in the Device Mangler. The problem went away. I don't know what the top com port that the MSYS will tolerate, but it is definitely less than 17. I suspect it is 4, but that is untested.

    If you are using a com port other than COM1: (the default), add the command line option   -d COMx:   where x is the com port number for your serial port device.

    The source code is here for the windows version, and since it is not customary to offer Windows programs as source code, I included the .exe file.

View project log

Enjoy this project?

Share

Discussions

Bharbour wrote 06/26/2017 at 14:47 point

As a follow on to this project, I developed enough control functions to extract individual channel data and settings to plot the data externally with correct dimensions on both axes. It would be a big project to fully implement all of the controls on this scope, and it is a relatively simple scope.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates