RTC Website

chapter 6 companion and outline

This page contains companion resources and an outline for chapter 6 of the book An Introduction to Real-Time Computing for Mechanical Engineers, and it therefore lacks most of chapter 6’s contents. While some sections of the book are fully available on this site, many are not. Please consider purchasing a copy from the MIT Press.

Digital realization of dynamic systems

An important aspect of real-time computing is the interaction between the computer and its physical environment. A computer may measure external variables, perform computations based on those measurements, and effect changes in other external variables.

Usually, physical variables have two characteristics. First, they are continuous-valued: variables can take on an unlimited number of values over a finite range, and they do not change by finite amounts instantaneously. In addition, physical variables are continuous-time: they are time-varying (dynamic) and can take on new values at every instant of time. Examples include position, force, pressure, temperature, and voltage.

However, within the computer, these continuous variables must be represented (i.e., approximated) by a finite number of numerical quantities, each with finite precision. shows the input and output conversion between physical variables and digital quantities. For the input direction, a physical variable acts on a sensor, which in turn produces an appropriate signal for one of the computer’s interfaces. In the output direction, a digital value is transformed into a signal appropriate for an actuator to change a physical variable.

 Figure 6.1
Figure 6.1: Measurement and control of external physical variables.

We have already made use of these types of conversions. Lab 4 made successive measurements of the motor position (the physical variable) with an encoder (the sensor). The encoder produced a pair of discrete-valued signals that were interpreted by the counter (the interface) as an integer number. In addition, an output interface was used to convert digital values to a pulse-modulated signal applied to an amplifier/motor (the actuator) that altered the motor torque (the physical variable).

Generally, the interface signals are either discrete-valued or analog signals. Discrete-valued signals are transferred by serial or parallel interfaces. An analog signal is any continuous-valued signal, usually a voltage, representing some physical quantity. Analog signals are transferred by analog-to-digital or digital-to-analog conversion.

Conversion of a physical variable to numerical representation may be thought of as the combination of two processes:

  • Sampling: The evaluation of a continuous signal at discrete points in time.
  • Quantization: The assignment of the value of a continuous signal to one of a finite set of discrete states.

Questions immediately arise with regard to accurate and efficient conversion: With what accuracy must the value be quantized? At what points in time must a dynamic signal be sampled?

This chapter examines the characteristics and limitations of sampling, quantization, and processing of dynamic variables external to a computer. In lab 6, we will integrate all of these ideas, along with interrupt-based timing, to explore real-time signal processing of the type used in filtering or control.

Analog signals

ADC and DAC hardware

Sampling

Discrete-Time Systems

Analog Input/Output of the myRIO

TX

Timer interrupts and their programming

TX

Summary

Problems

Realizing a discrete dynamic system

TX

Online resources for Chapter 6

No online resources.