EECS 373 Lab 6: Serial Bus Interfacing - Answer Sheet

Name and Unique Names




Staff Signature for Demo




In-Lab Assignment

Interrupt Driven UART Communication

How does the application initialize the UART connection? What is the UART speed and configuration? How is this different from earlier uses when you output data using printf?




Change the application such that it reacts immediate on key presses and changing the output mode of the OLED accordingly. Instead of using a polled character read function, you will have to use interrupts. Look at the UART driver in drivers/mms_uart to find out how to subscribe to interrupt events, and how to configure the driver for interrupt driven communication. In addition, you will have to change the switch block for the new behavior. Instead of busy looping and delaying code execution, you should check for a new display mode every now and then in order to react to key presses. Note that you don't have to check for a change of state after every operation. Human reaction time is around 100 ms. Thus, if you react to a key press within that time, we can't really differentiate if it was immediate or not.

Serial Protocol Analysis

Identify the peripheral to which each signal belongs.

Signal NamePin NumberBreakout NamePeripheral Name

Serial Analyzers

Using the different logic analyzer capabilities answer the following questions for the different serial protocols. Make sure you measure average transfer rates over a significant amount of time, not just over one transfer (e.g. 100ms to 1 second).

  1. What is the frequency of the clock SCK?
  2. What is the polarity of the clock SCK (low or high when inactive)? Note, you will have to figure this out in order for the SPI Analyzer block to work correctly.
  3. What's the throughput in bytes/second? How and why is it different from the clock speed?
  4. What is the data we transmit? Hint: convert the bytes to ASCII.
  1. What is the frequency of the clock SCL?
  2. What's the average transmit (master to slave write) data rate in bytes/second?
  3. What's the average receive (master to slave read) data rate in bytes/second?
  4. What are the slave addresses the master tries to contact?
  5. Are the messages getting acknowledged? If yes, by whom? If not, how does it work? Who guarantees that the line stays high, even though all the devices put their SDA line on high-z (floating) status? Hint: look at the wiring diagram of the FPGA Cores and the individual Core configurations.

The UART uses 8 bit data. Answer the following questions using the logic analyzer.

  1. What is the baud rate of the UART signal?
  2. What is the configuration (Even/Odd Parity)?
  3. What is the average transfer rate in bytes/sec?
  4. What does the UART data say in ASCII?
  5. Are there any other optional signals UART could use? If so, name them.

Give at least two potential improvements in order to speed up transfer on all the serial protocols.





You may work with a partner for this assignment.

During the next lab, show that your radio transmits messages. We will have a receiver station connected to one of the stations which will log all the source addresses. In order to not have the same source address as another group, choose a random uint16_t number and set it in your main.c as the SRC_ADDRESS define. This will allow you to identify and differentiate your messages from other groups.

Submit a compressed file for each of your SoftConsole workbenches for the Interrupt Driven UART Communication (name it oledSoftware_uniquename1_uniquename2.{rar,zip,7z,bz}) and the CoreSPI driver for the radio (name it cc2520_uniquename1_uniquename2.{rar,zip,7z,bz}). The workbenches should be fully configured with build targets and your code should compile. Send both compressed files to with the subject f10-lab6:uniquename1,uniquename2. Hand in your answers from the questions asked during the lab. You can use the following Answer Sheet. Before handing your solution in, show your application to a lab staff and get a signature on your title page.