avrora.sim.mcu
Class USART.SerialPrinter

java.lang.Object
  extended byavrora.sim.mcu.USART.SerialPrinter
All Implemented Interfaces:
USART.USARTDevice
Enclosing class:
USART

protected class USART.SerialPrinter
extends java.lang.Object
implements USART.USARTDevice

A simple implementation of the USARTDevice interface that connects to a USART on the processor. It simply prints out a representation of each frame it receives.


Method Summary
 void receiveFrame(USART.Frame frame)
          Receive a frame.
 USART.Frame transmitFrame()
          Transmit a frame from this device.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

transmitFrame

public USART.Frame transmitFrame()
Description copied from interface: USART.USARTDevice
Transmit a frame from this device.

Specified by:
transmitFrame in interface USART.USARTDevice
Returns:
the frame for transmission

receiveFrame

public void receiveFrame(USART.Frame frame)
Description copied from interface: USART.USARTDevice
Receive a frame.

Specified by:
receiveFrame in interface USART.USARTDevice
Parameters:
frame - the frame to be received