System information
5 Device Emulation
ARM-USB-Controller Communication
The software running on the USB controller is called Mass Storage Bulk Only (MSBO)
firmware. The program processing the high level protocol is named MSBO daemon. The
MSBO daemon runs on the ARM CPU. By the reason of the unidirectional connection
between the AHB bus and the USB Controller, the MSBO Firmware cannot contact the
ARM CPU. Instead, the MSBO daemon asks periodically the MSBO firmware for new
commands. To synchronize the communication between the daemon and the firmware, a
message based protocol is implemented. Table 5.3 lists the ports of the protocol.
Name Address
MESSAGE_COMMAND_PORT 0x3FC0
MESSAGE_DATA_POINTER_PORT 0x3FD0
REQUEST_MESSAGE 0x3FD4
MESSAGE_INTERRUPT_PORT 0x3FE0
MESSAGE_SIZE_PORT 0x3FE4
MESSAGE_ACK_PORT 0x3FE8
Table 5.3: I/O Ports of the ARM-EZ-Host message protocol.
The ports are address locations inside the internal SRAM of the USB controller. The right
hand of the table displays the address of the message ports. A message contains a command
word, a pointer to a data location and a size information field. The size of the information
specifies the size of the data addressed by the data pointer. Following commands exist:
MESSAGE_CMD_DEBUG_MSG The message contains a debug message. Due to the
uncomfortable serial interface of the USB controller, debugging of the USB firmware is
difficult. With the aid of the Debug Message Command, the debug output is available on
the ARM CPU.
MESSAGE_CMD_SCSI_CMD If the USB Controller receives an SCSI command, then the
command is forwarded to the MSBO daemon. The daemon gets a pointer to the received
SCSI command. More information about the SCSI command processing can be found next
in this section.
MESSAGE_CMD_ERROR_MSG The firmware sends error messages with this command.
MESSAGE_CMD_CONFIGURATION_MSG The firmware sends information about its
internal configuration. This is the size and location of the transfer buffer. The transfer
buffer is discussed at the end of this section.
Handshaking
Every message is initiated by the MSBO firmware. The firmware informs the MSBO daemon
about a new message by activating the interrupt port MESSAGE_INTERRUPT_PORT.
72