Microprocessors and Microcontrollers

There is no strict border between microprocessors and microcontrollers because certain chips can access external code and/or data memory (microprocessor mode) and are equipped with particular peripheral components. Some microcontrollers have an internal RC oscillator and do not need an external component. However, an external quartz or ceramic resonator or RC network is frequently connected to the built-in, active element of the clock generator. Clock frequency varies from 32 kHz (extra low power) up to 75 MHz. Another auxiliary circuit generates the reset signal for an appropriate period after a supply is turned on. Watchdog circuits generate chip reset when a periodic retriggering signal does not come in time due to a program problem.

There are several modes of consumption reduction activated by program instructions. Complexity and structure of the interrupt system (total number of sources and their priority level selection), settings of level/edge sensitivity of external sources and events in internal (i.e., peripheral) sources, and handling of simultaneous interrupt events appear as some of the most important criteria of microcontroller taxonomy. Although 16- and 32-bit microcontrollers are engaged in special, demanding applications (servo-unit control), most applications employ 8-bit chips. Some microcontrollers can internally operate with a 16-bit or even 32-bit data only in fixed-point range-microcontrollers are not provided with floating point unit (FPU). New microcontroller families are built on RISC (Reduced Instruction Set) core executing due to pipelining one instruction per few clock cycles or even per each cycle. One can find further differences in addressing modes, number of direct accessible registers, and type of code memory (ranging from 1 to 128 KB) that are important from the view of firmware development. Flash memory enables quick and even in-system programming (ISP) using 3-5 wires, whereas classical EPROM makes chips more expensive due to windowed ceramic packaging. Some microcontrollers have built-in boot and debug capability to load code from a PC into the flash memory using UART (Universal Asynchronous Receiver/Transmitter) and RS-232C serial line. OTP (One Time Programmable) EPROM or ROM appear effective for large production series. Data EEPROM (from 64 B to 4 KB) for calibration constants, parameter tables, status storage, and passwords that can be written by firmware stand beside the standard SRAM (from 32 B to 4 KB).

The range of peripheral components is very wide. Every chip has bidirectional I/O (input/output) pins associated in 8-bit ports, but they often have an alternate function. Certain chips can set an input decision level (TTL, MOS, or Schmitt trigger) and pull-up or pull-down current sources. Output drivers vary in open collector or tri-state circuitry and maximal currents. At least one 8-bit timer/counter (usually provided with a prescaler) counts either external events.

(optional pulses from an incremental position sensor) or internal clocks, to measure time intervals, and periodically generates an interrupt or variable baud rate for serial communication. General purpose 16-bit counters and appropriate registers form either capture units to store the time of input transients or compare units that generate output transients as a stepper motor drive status or PWM (pulse width modulation) signal. A real-time counter (RTC) represents a special kind of counter that runs even in sleep mode. One or two asynchronous and optionally synchronous serial interfaces (UART/USART) communicate with a master computer while other serial interfaces like SPI, CAN, and I2C control other specific chips employed in the device or system. Almost every microcontroller family has members that are provided with an A/D converter and a multiplexer of single-ended inputs. Input range is usually unipolar and equal to supply voltage or rarely to the on-chip voltage reference. The conversion time is given by the successive approximation principle of ADC, and the effective number of bits (ENOB) usually does not reach the nominal resolution 8, 10, or 12 bits.

There are other special interface circuits, such as field programmable gate array (FPGA), that can be configured as an arbitrary digital circuit. Microcontroller firmware is usually programmed in an assembly language or in C language. Many software tools, including chip simulators, are available on websites of chip manufacturers or third-party companies free of charge. A professional integrated development environment and debugging hardware (in-circuit emulator) is more expensive (thousands of dollars). However, smart use of an inexpensive ROM simulator in a microprocessor system or a step-by-step development cycle using an ISP programmer of flash microcontroller can develop fairly complex applications.

Airport on Time

Get Me to the Airport on Time

I was off to the airport on another trip. I started out early, arrived at the airport on time, but when I arrived the plane had canceled and I had to apply for another plane. The next plane headed for my destination was about two hours away. This would, in fact, make me miss my connecting flight.

I suppose I ought to be grateful that I was able to catch a later flight. It gave me some time to sit in the airport with nothing to do but think. Talk about a boring afternoon!

One of the things I thought about was never flying again. But, necessity is the mother of inconvenience, or something like that.

While I was thinking in the airport, I thought of a wise old man who, waxing philosophical, once said, “Time waits for no man.” I know he was wise because he did not include women in his observation. Although time will wait for no man, it has a different approach to women.

Usually speaking, a man welcomes the passing of time. Proudly he displays those wrinkles and calluses as marks of manhood. Until recently, gray hair was a crown of authority. Even Solomon, the wisest man said, “The hoary [gray] head is a crown of glory, if it be found in the way of righteousness” (Proverbs 16:31 KJV).

The grayer the head, the wiser the man. Although, I must confess I have seen my share of intelligence-challenged gray-headed men.

A woman, however, has an altogether different philosophy when it comes to time. As a man with gray hair, I do not fully understand their philosophy.

I suppose there are some men who would like to be 25 again. Most men, however, are happy to be as old as they are. Women are different. They live upon the concept of ageless beauty. Who am I, as a man, to counter that philosophy?

I discovered this many years ago. A woman casually asked me how old I thought she was. I have long since discovered that this is no casual question and she is not looking for exact information. I, at the time, took it as a challenge and tried to guess her age.


I have since learned that the correct response to this question is, “Why, you don’t look a day over 25.” I do not know exactly what that means, but I have often gotten smiles from this response. No matter how old the woman is, in her mind she is still 25.

The man has a different idea.

“I’m 60,” he will boast to whoever will listen, “and I can still do a whole day’s work.” Then he will go out and throw his back out just to prove it.

Time has a different effect upon a man as it does upon a woman.

There is nothing wrong with trying to look younger. I suppose it is an easier task to do if you are a woman than if you are a man.

Every morning before I leave the house I try to make myself as non-scary to the public as I possibly can. I will scrape my face, pat down my hair, and douse myself with aftershave and in 10 minutes, I am done and ready for the world.

I have noticed that the Gracious Mistress of the Parsonage takes a lot longer than 10 minutes to get ready to face the world. I must admit she does a very good job of it, but I also must admit it takes a long time and it seems each year it gets longer.

I do not want to call attention to myself. I just want to get through the day and back home again. I know I am not as young as I used to be but I take consolation in the fact that I am older than I used to be. And hand in hand with good old Father Time, I have walked down the wonderful timeline.

For me personally, I like to celebrate each birthday as a once-in-a-lifetime celebration. My goal in life is to get as old as I possibly can and with the good help of Father Time, I am well on my way. Time has not stood still for me, for which I am most thankful.

Just like getting to the airport on time for my flight, I want to be on time for everything happening in my life. I do not want to miss a thing. Too often people look backward, stumble over today, find themselves in tomorrow and do not know how they got there. I want to enjoy the time I have in real time.

There is no time like the present to enjoy. Memories are wonderful. Aspirations are delightful. But, nothing can take the place of right now.

Nano Machines

Nano Machines

Nanomachines are devices that range in size from the smallest of MEMS devices down to devices assembled from individual molecules. This section briefly introduces energy sources, structural hierarchy, and the projected future of the assembly of nanomachines. Built from molecular components performing individual mechanical functions, the candidates for energy sources to actuate nanomachines are limited to those that act on a molecular scale. Regarding manufacture, the assembly of nanomachines is by nature a one-molecule-at-a-time operation. Although microscopy techniques are currently used for the assembly of nanostructures, self-assembly is seen as a viable means of mass production. In a molecular device a discrete number of molecular components are combined into a supramolecular structure where each discrete molecular component performs a single function.

The combined action of these individual molecules causes the device to operate and perform its various functions. Molecular devices require an energy source to operate. This energy must ultimately be used to activate the component molecules in the device, and so the energy must be chemical in nature. The chemical energy can be obtained by adding hydrogen ions, oxidants, etc., by inducing chemical reactions by the impingement of light, or by the actions of electrical current. The latter two means of energy activation, photochemical and electrochemical energy sources, are preferred since they not only provide energy for the operation of the device, but they can also be used to locate and control the device.

Additionally, such energy transduction can be used to transmit data to report on the performance and status of the device. Another reason for the preference for photochemical- and electrochemical-based molecular devices is that, as these devices are required to operate in a cyclic manner, the chemical reactions that drive the system must be reversible. Since photochemical and electrochemical processes do not lead to the accumulation of products of reaction, they readily lend themselves to application in nanodevices. Molecular devices have recently been designed that are capable of motion and control by photochemical methods. One device is a molecular plug and socket system, and another is a piston-cylinder system. The construction of such supramolecular devices belongs to the realm of the chemist who is adept at manipulating molecules. As one proceeds upwards in size to the next level of nanomachines, one arrives at devices assembled from (or with) single-walled carbon nanotubes (SWNTs) and/or multi-walled carbon nanotubes (MWNTs) that are a few nanometers in diameter. We will restrict our discussion to carbon nanotubes (CNTs) even though there is an expanding database on nanotubes made from other materials, especially bismuth.

The strength and versatility of CNTs make them superior tools for the nanomachine design engineer. They have high electrical conductivity with current carrying capacity of a billion amperes per square centimeter. They are excellent field emitters at low operating voltages. Moreover, CNTs emit light coherently and this provides for an entire new area of holographic applications. The elastic modulus of CNTs is the highest of all materials known today. These electrical properties and extremely high mechanical strength make MWNTs the ultimate atomic force microscope probe tips. CNTs have the potential to be used as efficient molecular assembly devices for manufacturing nanomachines one atom at a time

Failure Analysis

Failure Analysis of Mechatronic Systems

The failure modes of a mechatronic system include failure modes of mechanical, electrical, computer, and control subsystems, which could be classified as hardware and software failures. The failure analysis of mechatronic systems consists of hardware and software fault detection, identification (diagnosis), isolation, and recovery (immediate or graceful recovery), which requires intelligent control. The hardware fault detection could be facilitated by redundant information on the system and/or by monitoring the performance of the system for a given/prescribed task. Information redundancy requires sensory system fusion and could provide information on the status of the system and its components, on the assigned task of the system, and the successful completion of the task in case of operator error or any unexpected change in the environment or for dynamic environment. The simplest monitoring method identifies two conditions (normal and abnormal) using sensor information/signal: if the sensor signal is less than a threshold value, the condition is normal, otherwise it is abnormal. In most practical applications, this signal is sensitive to changes in the system/process working conditions and noise disturbances, and more effective decision-making methods are required.

Generally, monitoring methods can be divided into two categories: model-based methods and featurebased methods. In model-based methods, monitoring is conducted on the basis of system modeling and model evaluation. Linear, time-invariant systems are well understood and can be described by a number

of models such as state space model, input-output transfer function model, autoregressive model, and autoregressive moving average (ARMA) model. When a model is found, monitoring can be performed by detecting the changes of the model parameters (e.g., damping and natural frequency) and/or the

changes of expected system response (e.g., prediction error). Model-based monitoring methods are also referred to as failure detection methods.

Model-based systems suffer from two significant limitations. First, many systems/processes are nonlinear, time-variant systems. Second, sensor signals are very often dependent on working conditions. Thus, it is difficult to identify whether a change in sensor signal is due either to the change of working

conditions or to the deterioration of the process. Feature-based monitoring methods use suitable features of the sensor signals to identify the operation

conditions. The features of the sensor signal (often called the monitoring indices) could be time and/or frequency domain features of the sensor signal such as mean, variance, skewness, kurtosis, crest factor, or power in a specified frequency band. Choosing appropriate monitoring indices is crucial. Ideally the

monitoring indices should be: (I) sensitive to the system/process health conditions, (ii) insensitive to the working conditions, and (iii) cost effective. Once a monitoring index is obtained, the monitoring function is accomplished by comparing the value obtained during system operation to a previously determined threshold, or baseline, value. In practice, this comparison process can be quite involved. There are a

number of feature-based monitoring methods including pattern recognition, fuzzy systems, decision trees, expert systems, and neural networks. Fault detection and identification (FDI) process in dynamic systems could be achieved by analytical methods such as detection filters, generalized likelihood ratio (which uses Kalman filter to sense discrepancies in system response), and multiple mode method (which requires dynamic model of the system and could be an issue due to uncertainty in the dynamic model) (Chow and Willsky, 1984). As mentioned above, the system failures could be detected and identified by investigating the difference between various functions of the observed sensor information and the expected values of these functions. In case of failure, there will be a difference between the observed and the expected behavior of the system, otherwise they will be in agreement within a defined threshold. The threshold test could be performed on the instantaneous readings of sensors, or on the moving average of the readings to reduce noise. In a sensor voting system, the difference of the outputs of several sensors and each component (sensor or actuator) is included in at least one algebraic relation. When a component fails, the relations including that component will not hold and the relations that exclude that component will hold. For a voting system to be fail-safe and detect the presence of a failure, at least two components are required. For a voting system to be fail-operational and identify the failure, at least three components are required, e.g., three sensors to measure the same quantity (directly or indirectly).