Interfaces


Nearly all measuring devices used for dendrochronology are based on optical encoders. These devices transform a movement into an electrical signal. This signal must be measured and transformed to data that can be understood by a personal computer.

Our USBParSer and ParSer  interfaces are equipped with industry strength electronics to perform this task. The devices are used on our TimeTable and VideoTimeTable measuring series but are also available separately to update older measuring hardware for the use with SCIEM software.

RS232 ParSer

The ParSer interface connects a TimeTable, VideoTimeTable or any other measuring device that is equipped with a HEDS optical encoder to the serial RS232 interface of a PC. A built in Microprocessor keeps track of the current position.

The ParSer interface can be used to connect different measuring devices such as the Lintab series to a PC and use these measuring devices with PAST32/PAST4/PASTLite and Windows.

System requirements:

Hewlett Packard/Agilent optical encoder equipped measuring device, 1 free RS232 interface, PAST32, PAST4 or PASTLite data acquisition software.

The ParSer comes complete with 220V power supply, custom made RS232 cable, a 2 m encoder cable and a Trigger mouse. Manual and plugin drivers for PAST32 on 3 1/2" Floppy disk.


A comment on optical encoders

The problem:



A HEDS encoder disk

Optical encoders have been used in length measurement systems for quite some time. For example every inkjet printer has built in an encoder to position the printer head. Briefly explaned an encoder transforms rotational or linear movements into electrical signals with rectangular waveforms. The encoder disk consists of mylar and holds a number of lines, depending on the required resolution. The disk on the left has 400 lines resulting in a resolution of 400 cpr (counts per revolution).

 The problem with optical encoders is, that the attached computer has to be very careful to count all(!) the electrical impulses the encoder sends. If for example the above disk is turned once per second (1 rpm) this results in a impulse frequency of 1.600 Hz or 1.600 impulses per second. Cheap interface products connect the encoder directly to a PC, in most cases the parallel (aka Centronics or printer) port.

 Since even a simple PC with a monotask operating system like DOS has to do several other things than only waiting for data to arrive on the parallel port, interrupt techniques have to be used. This means, that whenever the electrical state of one of the lines of the parallel port changes, an interrupt is triggered (the same is happening if you press a key on your keyboard or push a mouse button). The computer stops its actual work, gets the data from the port and continues.

 

Diagram © Hewlett/Packard

This is ok as long as the frequency of the incoming interrupt requests is significant smaller than the time the computer needs to digest the data. Unfortunately this is only true for low frequencies up to several hundred impulses/second. As an additional problem the interrupts that can be generated by the parallel port have a low priority in a standard PC environment, which means that the computer seldom handles these interrupts in real time.

These problems result in the fact, that not all impulses that were generated by turning the encoder disk reach the belly of the computer. Data is lost and your measurements are shorter than the actual length. If you have a standard length measuring device based on an optical encoder (such as the Lintab 1 series) you can stress your system by turning the movement knob fast into one direction and then back slowly. In most cases you won´t get back to were you started. It needs no mentioning that such behaviour is most inaccurate for precise length measurements.

Another problem arises that under a modern operating system such as Windows it is not possible to use the parallel port in the described manner (at least not without several tricks). The parallel port in fact was not designed to be used as data aquisition port. Its main purpose is sending data out, namely to a printer.

The solution:

Optical encoders were not designed to be interfaced by computers directly. In an industrial environment taking too short a length measurement can have fatal consequences (think of a turning lathe or a modern CAM device that positions the cutting tools inaccurate). Therefore the manufacturers of optical encoders developed special integrated circuits to build a buffer between the encoder and a computer. These interface chips are clocked at high speeds (up to 20MHz) and have nothing else to do but count the incoming impulses. The processing computer can decide by itself when it is capable of handling new data. It then sends a message to the interface chip and gets the actual position. Our ParSer device consists of a Motorola microprocessor (µP) and an interface chip. The device starts controlling the encoder as soon as it is powered. Of course the above named problems arise here, too - but since the µP and the interface chip are fast it would take a very fast hand to flood the interface with incoming impulses (in fact with the standard TimeTable devices problems will occur when the sample holder is moved with a speed higher than 12.5m/second which should be sufficient for hand movement;-)

© 2003 by SCIEM
05.11.2003 DI Bernhard Knibbe