The figure below illustrates the structure of a device driver built with the universal device driver. The principal function, however, applies to 'hard coded' drivers, too.

To other software components (primarily to the user interface) the device driver interfaces by a list of variable definitions. On the other hand, a list of procedures does the 'real work', translating the abstract parameter values to physical command sequences. In between a function here called variable -- procedure linkage defines which procedure is run to set or read a certain parameter.
With the universal device driver, all this is setup (compiled) during the program initialization from a text file which describes the device driver in special, but quite simple programming language. The following pages describe how variables , procedures and the protocol encapsulation work together.