Global Sources
EE Times-Asia
Stay in touch with EE Times Asia
EE Times-Asia > Amplifiers/Converters

Moving to 12-bit embedded control

Posted: 01 Aug 2000 ?? ?Print Version ?Bookmark and Share

Keywords:embedded? microcontroller? 12 bit? 8 bit? analog devices?

Stephan Ohr ponders the increasing integration of microcontrollers and ADCs, and its application in embedded control.

At the Embedded Systems Conference in 1998, Tremont Mao of Analog Devices was demonstrating his own version of the Rube Goldberg machine. For those of you unfamiliar with Rube Goldberg, he was an American cartoonist who envisioned every operation?even the simple flip of a switch?as an elaborate chain of events involving bizarre situations such as falling objects and barking dogs. Tremont Miao's machine was the world's most entertaining chewing gum dispenser. It would pick up a colored ball of gum with a set of metallic claws, and drop it into an elaborate wire mesh chute. From there a series of pulleys, elevators, and conveyors would transport it to a trap door through which it would emerge, only to be consumed by visitors on the trade show floor.

The entire mechanical chain was controlled by something Miao called the "microverter"?an 80C51 with an on-chip ADC. "Is this an 80C51 microcontroller with a really good analog front end?" I asked at that time. "Or was this a 12-bit ADC so sophisticated that a microcontroller was part of its feature set?"

It's not surprising that microcontrollers are considered as analog and mixed-signal devices. Back then in mid-1998, I wrote in one of my articles that embedded microcontroller parts resembled analog circuits that mandated "hands-on" design skills to make these things work. "If you sit with an applications developer, you see wires going in all directions," I wrote. "Instead of a scope, you see a logic analyzer."

In those days I was fresh out of an engineering position in Signetics (which became part of Philips Semiconductors). My team worked on data converters?mostly motor controllers and servos?that included 8048s (the forerunner to the 8051). Back then, it was an analog applications engineer who designed the motor control servo?a linear position finder?after teaching himself enough control code to get the 8048 servo to slide into various positions.

While the 80C51 series chips?along with National Semiconductor's COPS and Microchip's PIC controllers?now come equipped with on-chip ADCs, there is also a trend toward increasing the bit resolution of these front-end devices (from 8 bits to 12 bits).

Miao's microverter was one of the first microcontrollers to include an on-chip 12-bit ADC. And Microchip introduced a 12-bit device for its PIC series controllers in mid-1999. As 12-bit successive approximation ADCs become easier to implement without laser trimming, I believe microcontrollers with 12-bit front ends will become more and more common.

Even though higher bit resolution is getting cheaper, it is still something you pay for. So make sure you carefully consider the real need?in embedded systems applications?of putting a 12-bit controller on the front of an 8-bit microcontroller. You have to latch the data into the controller in two complete cycles. This means that first, you have to take in the 8 most significant bits (MSBs) in one clock cycle of the controller, and then the next 4 LSBs in the next clock cycle of the processor. It's what is known as a "folded data" structure. What are the applications where it makes sense to handle this complexity?

Need for folded data

The answer, if you think about it, points to applications where the microprocessor?indeed the entire data acquisition system?no matter how slow it ticks (say, 20MHz) is still outrunning the system it is measuring. In operation, the embedded controller?a miniature data acquisition system?reads the analog signal and converts it to a digital number. The microcontroller takes the number and compares it with a number stored in a look-up table (LUT). If it finds the reading is fine, it probably does nothing. If it doesn't like the reading, it issues some kind of instruction, an 8- or 12-bit number, which a DAC (or pulse width modulator) converts back to analog voltage. This enables some kind of cue to tell the system what to do next.

The primary users of 12-bit ADCs with 8-bit microcontrollers are X-Y plotters and machine tool equipment. Remember, with data converters, the bit resolution maps a ratio (which is a measure of precision) between the MSB and the LSB in the sequence of measurements. With an 8-bit converter, the resolution is only 256. That is 2 to the nth power, where n is the number of bits. Thus, with a 12-bit ADC?by adding just four bits?the precision with which you can sample real world signals becomes four orders of magnitude greater (212 or 4,096).

If you examine the kind of embedded control applications in which an 8-bit controller measures data with 12-bit resolution, it wouldn't be the consumer electronics space. You don't need 12-bit precision (say) to determine and display the frequency you've tuned into on your FM radio. After all, there are only about 190 choices if you divide up the FM radio spectrum into 100-kHz slices. The 12-bit resolution is used increasingly for flatbed scanners, but then you require a CCD or CMOS imager on the front end. You will also need a correlated double sampler in addition to the controller to make sure your pixels are appropriately ordered before you feed them to the host processor.

Rather, the 12-bit ADC with 8-bit microcontroller combination is used for embedded industrial control, particularly in motorized position finders. In fact, as far back as 20 years ago, Cincinnati Milacron used 12-bit ADCs and DACs with 8-bit micros to control the rotational position of each elbow (each axis) on a 6-axis industrial robot (the kind used to assemble cars in older production lines). The 360 position of the rotating robot arm was measured by an optical encoder, converted to a digital number by the ADC, and compared with a number in the LUT of the controller. If there was any difference between measured position and the ideal position recorded in the LUT, the microcontroller would issue a "re-position" command and the DAC at the output of the system would translate that into driving voltages for the elbow's motor. A 12-bit converter, here, would offer a rotational precision down to nine-hundredths of one degree. Now how many angular minutes of precision is that?

At that time, Milacron's engineers told me it was useless to harness a higher resolution, since the motor could not resolve that fine a degree. However, they did acknowledge that a 14-bit device would help them correct for some of the wobble (or "table jitter," as they called it) in the motor bearings. But the cost outweighed the benefits. Now, more than ever, you too need to strike a balance when it comes to precision in embedded control.

Article Comments - Moving to 12-bit embedded control
*? You can enter [0] more charecters.
*Verify code:


Visit Asia Webinars to learn about the latest in technology and get practical design tips.

Back to Top