Homework 7

22C:116, Spring 1997

Due Friday Mar. 21, 1997, in class

Douglas W. Jones
  1. Background Consider the possibility of using standard asynchronous serial ports to connect to a CSMA-CD (Ethernet) style bus. That is, conventional bidirectional UART interfaces are connected to a bus as follows:
      -------------o-------------------o--------o--- bus
      __________   |   __________    __|__      |
     | Transmit |->o->| Receiver |  | UART|    ...
     |          |_____|          |  |_____|
     |            UART           |  __|||__
     |___________________________| |  Host |
             __|||||||||__         |_______|
            |     Host    |
            |   Computer  |
    From the point of view of the host computers, the UART offers the usual serial device interface. Assume that the bus is arranged so that the start bit is a 1 and the bus passively or's together all of the outputs from all of the UARTS to compute the value all UARTS will receive. Assume all UARTS use the same data rate

    Aside: From a software perspective, the Apple Localtalk bus works roughly like this. At a lower level, however, the Localtalk bus uses inductive coupling between the local UART and the bus, and a synchronous protocol is used instead of an asynchronous protocol.

    The Problem: Outline the interrupt service routine(s) and low level software needed to implement the CSMA-CD (Ethernet) protocol on this hardware. Assume that each machine has a unique 8-bit address, and that the interface to higher level software is through send_packet( d, a ), which sends the fixed size packet of data d, to user a, and receive_packet( d, a ), which awaits a packet from any user and returns the packet in d and the address of the sender a. The constant packet_size is given in bytes.

  2. Background: In the early 1970's, Parnas defined the transparency of an interface layer in a hierarchically structured system as the degree to which that layer exposes the state of the underlying system. A transparent layer is one which allows the user (at a higher level) to enter and observe all of the lower level system states, while an opaque layer is one that hides lower level details, preventing the user from observing or manipulating certain elements of the lower level system state. He used the example of a cart with a steering mechanism to illustrate this. If the user interface to the steering mechanism allows the front wheels to turn independently (as the low level mounting of the wheels permits), the cart may be steered through a remarkable range of trajectories, but many dangerous configurations are possible. A more opaque user interface would couple the two steerable wheels, limiting the manuverability of the cart but providing considerable safety.

    The Problem: Tannenbaum uses a different definition of transparency in Section 9.4.1, without ever giving a general definition of the term, although he gives many examples in the distributed system context. Write a page or so that a) Gives a general definition of transparency as the term is used by Tannenbaum, b) contrasts this with Parnas's use of the term, and c) attempts to find the relationship between these two usages. Here, items a) b) and c) are not sub-parts of the problem, but issues you must address, not necessarily in that order.

  3. Background: In early networks, the speed of data communications was generally very slow relative to the speed of computation. For example, in 1970, you could buy mature computing technology to run at 1 MIPS, but most long haul networks used only 9600 baud links, and a few ran at 56 kilobaud. Today, we have computers running at 100 MIPS, but we consider a 1 megabaud link to be slow (10baseT uses 10 megabaud, and 100baseT, which is becoming available, uses 100 megabaud). As a result, the number of computing cycles available per bit transmitted is declining.

    The Problem: Discuss the impact of this on the whole idea of protocol hierarchies outlined in section 10.1 of the text.