Assignment 11, due Nov 14

Part of the homework for 22C:60, Fall 2008
by Douglas W. Jones
THE UNIVERSITY OF IOWA Department of Computer Science

Remember to write your name on what you turn in! Homework must be turned in on paper and in class!

Homework

  1. Background: The classic IBM PC parallel port has 25 pins. Pins 1 to 17 are signal pins (either data or control pins) while pins 18 to 25 are ground pins. Consider the following extremely simplistic Hawk parallel port interface:

    To send data to the parallel port, the program should wait for the printer to be not busy (an input, pin 11 equal to zero) and then send out the 8 data bits (outputs, pins 2 to 9). Then, the program should send out a strobe pulse (output, pin 1, normally one, set to zero for the duration of the pulse). The strobe pulse should end when the device indicates that it is busy (pin 11 equal to one), acknowledging that it is starting to read the data, and the device will remain busy until it is ready to process another character.

    a) Write a Hawk subroutine PPINIT to set up the parallel port in an appropriate idle state with the pins configured appropriately for use of the above communications protocol. (0.6 points)

    b) Give a timing diagram for the relationship between the busy, strobe and data pins as two consecutive bytes are output. You need only show one data pin, where that pin is zero in the first output byte and one in the second. (0.6 points)

    c) Write a Hawk subroutine PPPUT to send one byte (the low 8 bits) from R3 to the parallel port. (0.6 points)

  2. mux-based circuit with feedback
    Background: Consider the circuit for a type D latch shown to the right:

    Problem: Construct a type-D positive edged triggered flipflop from two of these circuits. For maximum credit, your solution must eliminate one of the two inverters in this circuit. (0.6 points)

  3. A problem: Give a logic diagram for a one-bit slice of the parallel port data and control registers, showing the connection to the internal Hawk data bus, the connection to the pin of the parallel port, and the control signals. It will have to respond to read and write signals on the control and data addresses. (0.6 points)