Wire2Wire.org logo

Buttonbar
By viewing or using information on this site you agree to the disclaimer click here to viewHomeContact mereport a dead linkdonatego back to from where you came


Cen-Tech caliper converter

News 1*24 protocol  1*24 to RS232 converter  1*24 to 2*24(yadro) converter


This page is dedicated to the development of a converter of the data port on a Cen-Tech caliper / scale to a more supported format.

In the process of adding a DRO to my 44142 combo lathe / drill machine I found the YADRO project (http://www.yadro.de/). I really liked the idea of this software DRO due to it's low cost and flexibility. I proceeded to build up a set of hardware and ordered a set of Cen-Tech calipers to convert to scales from harbor freight (http://www.harborfreight.com/6-inch-digital-caliper-47257.html). The nice thing about the calipers was they were inexpensive ($20 normal $10 or less if you wait for a sale) and they had a few sizes in stock that would cover my mill needs. BUT, when I finally hooked up the scales they did not work. Looking at the images at the YADRO site and my scales they are identical on the outside. But, unfortunately the guts must be different. The protocol the Cen-Tech uses is not the same as the 2*24 (sylvac) or 7BCD supported by YADRO. My goal is to make a adapter to convert from Cen-Tech (1*24) to 2*24 for use with YADRO and many other devices out there.


News
4JUL10 !!!!!!!!!!!!! READ THIS FIRST !!!!!!!!!!!!!!!!!!!!!
Today I picked up a new 8" Cen-tech caliper for the Y axis of my mill (finaly got around to taking the carage off to make the alters needed to mount it). When I went to test it out it did not work with my adapter. After a little investigation I found out it uses the true 2*24 protocall and works directly with the normal YADRO interface card!
Easy way to check which scale you have is to check the clock pin frequency if it is around 65kHz it may be 2*24 if it is around 4kHz more than likely it is the 1*24 format. The outward dimentions and pin out are identical between the 2 scales. Inside there is a extra set of pads for a watch crystal. (one of my new ones had it install the other did not.)
27JUN10 I have finished the quadrature firmware. (click here for more info)
In the process of debuging this I found a error in the raw card preventing it from being used for quadrature encoders. I have updated the raw card and firmware for the cen-tech adapter so one raw card can be used for both. Not I have not build any of the new raw cards so far.
21MAR10 Another update from John on Measumax scales.

It turns out that the datasheet which came with the Measumax scale was wrong -  they had the data and V+ lines swapped! There must be reverse polarity protection diode in series with the USB connector to the outside world. I only got the scale to work when using the internal battery and the "pull-up" resistor. It is a bit hard to describe in words (and probably not very interesting for you!) but the upshot is that when I swap the V+ and data wires to the YADRO-Centech, it works perfectly - well, almost. remember the reverse polarity protection diode? It means that the 1.6V which the YADRO-Centech card passes to the scale isn't enough to power the scale. To fix it, I put a 2.7V zener in series with the 5V line, and a pull-down to Gnd (to get the zener current up to around 5mA. I feed the resulting 2.3V to the "Centech", which "sees" 1.65V after the reverse polarity protection diode, and everything is absolutely perfect! I made a couple of mods to the board, using the Q5 holes for the zener, and the R10 holes for the zener's resistor, cut a couple of tracks and used the component leads to form a couple of new tracks. It is quite neat - and no new holes needed to be drilled.
14MAR10 John sent this in:
I had two minor changes to make in order to get it to work with the intended scale (a "Measumax" brand):
  • It needed a pull-up on the data line. The clock line was OK - but the data line appears to be an open collector output, so a 10k pullup worked a treat. Actually, I'll modify the board slightly, to use R4 as the pullup - I'll cut the 5V feed which is supplied to the calliper, and connect the top of R4 to the 1.5V feed instead.
  • I had to omit Q5, and put a link between C & E, since the Vce drop of the transistor prevented the scale from working properly.
So it sounds like with minor changes Measumax brand scale work under YADRO via this adapter as well. (Thanks John)
05DEC09 Adapter built up and verifed good!!
fully built adapter
If anyone needs a raw card or programed micro just drop me a email!
Also I have 1 extra Yadro raw card available (minimum order was 2)  asking $40 + shipping. Email me if interested.
21NOV09 Raw cards arrived! Will start assembling the first one when I get back after thanksgiving.
adapter raw card
14NOV09 Scale to Yadro adapter finished and uploaded. First batch of raw cards on order now.
I have also made a achive copy of www.yadro.de in case it disapears from the internet. (Last update was in 2006 and no responce fromt he listed email address) If you need a copy just send me a email and I can send it out.
16AUG09 Scale to RS232 adapter finished and uploaded
19SEP08  Created new page  to cover the progress of the converter.



1*24 protocol  / Cen-Tech info
The protocol used by the Cen-Tech devices I have named 1*24 since it  is one packet of 24 bits that repeats.
  • LSB is sent first
  • Bits 0 - 19 are the reading (no decimal) in binary.  Inch/mm mode DOES affect this reading.
  • The last 4 bits look to be status.
  • Bit 20 = negative sign. (high = negative)
  • Bit 21, 22 = unknown never got them to flip.
  • Bit 23 = inch/mm. (low = mm)
  • The clock rate is apx 3.57kHz with a 70/30 duty cycle (low/high).
  • Data is clocked on the high edge.
  • Every 4th bit the high is stretched so the cycle takes 540us but the data IS valid over the entire high.
  • The data is sent from the caliper apx every 100ms.
Far as I can tell there is NO remote control on this scale.

It automatically falls asleep every so often but wakes up as soon as the scale moves. When the scale wakes up it keeps the last unit setting and 0 location. (ie location is not lost). During sleep the LCD and data port are shut down.

After a power cycle both the location and units are reset. 0 is placed at the current location and units are set to mm.

Like many other scales the + side of the battery is connected to the frame of the scale.



Cen-Tech to RS232 adapter
I have finished a hardware dongle based off a PIC16F628 that converts the Cen-Tech protocal into RS232. Also included in the zip file is a windows perl script that will read the dongle connected to a serial port and report back the readings.

Code is here caliper_rs232.zip
Make sure to read the README.txt included.


Cen-Tech to Yadro adapter
I have finished a hardware dongle based off a PIC16F628 that converts the Cen-Tech protocal into 2*24 protocal. Also included in the readme is how to setup Yadro to work properly with the adapter. 

Code, bill of materials, raw card data, build instructions, and usage instructions are here cen-tech_quadrature_yadro.zip
Make sure to read the README.txt included.
(old V1 raw card build date is here not recomented for new adapters.)
cen-tech to yadro adapter logic
(right click and select "view image" to see larger version)

(click on slideshow to bring up web album with image comments)