EE 308 -- LAB 10
Synchronous Serial Communications on the 68HC11

In this lab, one HC11 board (the master) will be used to query another HC11 board (the slave) about its status. The master HC11 will send a byte to the slave HC11. The slave HC11 will return to the master the value in its corresponding register -- e.g., if the master sends the slave the number 0x2B, the slave will return the value of its BAUD register 0x102B. In this manner, the master can find out the value of any register inside the slave. We will use the Motorola SPI interface for communications between the two boards.

  1. Connect two HC11 EVBU boards together as shown below. The switch going to the TIC1 line on the Master HC11 should be one of the debounced switches on your protoboard.

      
    Figure 1: Connection of two HC11 EVBU boards for serial communication.

  2. Program the master HC11 board as follows:

  3. Program the slave HC11 board as follows:

  4. Verify that the system works properly. For example, have the master determine the value of the slave's BAUD register, and verify that it is 9600.

  5. Connect your logic analyzer to the master's MOSI, MISO, SCLK, IRQ, tt PIA Port B Bit 0, Port D Bit 5 and E Clock lines. Trigger your logic analyzer of the falling edge of the master's TIC1 line. Measure the following times, and compare (where appropriate) to the values specified on the MC6821 data sheet:

    1. The time from the falling edge on TIC1 to data being sent over the SPI. This is how long it takes the master to get into the TIC1 interrupt service routine, read Port E, and send the data.

    2. The SPI clock frequency.

    3. Verify that the data on the SPI is valid on the falling edge of SCLK, and the the data is sent with the most significant bit first.



Bill Rison, <rison@ee.nmt.edu >
Fri Mar 29 1996
© 1996, New Mexico Tech