Talking Digital Calipers for Engineering Accessibility
A few months after we published our Digital Calipers DRO video tutorial we received an email asking if it would be possible to adapt the project to make talking calipers that read the value out loud over a set of speakers for a blind mechanical engineering student to use. Using the same technique we used in our Huffman Coded Audio Halloween video to store and playback audio from the chip we were able to build talking calipers for Terry to use in his job and his mechanical engineering studies. The video includes a section where Terry talks about his passion for engineering and a demo of him using the talking calipers, so make sure to check it out!
Click any photo to enlarge:
Here are a few photos of the NerdKits Talking Calipers in action:
The first version of the circuit, which Terry demonstrates in the video, is a self-contained, battery-powered unit, and talks to calipers with the "fast" communication protocol:
The second version of the circuit, which Mike demonstrates in the video, has a power supply connector and handles a caliper with the "slow" communication protocol:
Digital Caliper Interface
There are at least two common types of digital caliper interfaces, and we built one version of this circuit for each. (It would certainly be possible to build one that would detect and handle either.) In our Digital Calipers DRO video, the calipers transmitted 2 sets of 24 bits in quick succession, with a bit period of only about 12µs ("fast"). However, in the code published here, we were working with calipers of the other type, which transmit 6 sets of 4 bits, with a bit period of roughly 400µs ("slow"). The "slow" protocol also transmits information about whether the calipers are set to inch or millimeter mode, while in the "fast" protocol, only the absolute measurement is transmitted.
Sound Storage and Playback
The only difference between how we stored and played sound for our Halloween Huffman-Coded Audio project and this one is that here, we stored the second difference of the sound signal instead of the first difference, as for speech data this yielded better compression.
One version of this circuit used the BJT-based power supply that we demonstrated in the Digital Calipers DRO video. The other used a simple resistor plus LED as a nearly-constant voltage source, since the voltage drop across the LED is quite similar to the voltage needed by the calipers.
The following schematic summarizes the caliper interface, audio output, and power supply components around the microcontroller. Click to enlarge.
In addition to one USB NerdKit, the following extra parts are needed to complete this project:
You can download a ZIP file containing the source code (including both the microcontroller C code as well as the Python scripts involved in performing the Huffman encoding of the audio) here.
More Videos and Projects!
Take a look at more videos and microcontroller projects!