MotoHawk Slave SPI Definition

This MotoHawk™ block allows the Slave side of a full duplex Serial Peripheral Interface (SPI) link to be specified in order to perform inter CPU communication.

Block ID

Slave Definition

Library

motohawk_SPI_lib

Description

This MotoHawk™ block allows the Slave side of a full duplex Serial Peripheral Interface (SPI) link to be specified in order to perform inter CPU communication. SPI communication is peer to peer, where one peer is designated as the Master and the other is designated as the Slave. The Master initiates communication, which the Slave responds to. Communication is full duplex, meaning that when the Master initiates a transfer the Slave will also initiate a transfer. Thus the response to a particular transfer is pre-loaded by the Slave before the transfer has been initiated by the Master.

The slave configures what data it will transmit via the Slave SPI Reload block. However this is a load action since the data is only sent out onto the wire when the Master initiates a transaction (typically a completely different application model). The transfer is full duplex so the Slave SPI Reload needs to execute before the Master begins the transfer (because the data loaded by this block will begin to be sent out on the wire as the transfer progresses). The Slave SPI Trigger block can be used to control execution flow. Each instance of Slave SPI Reload can have a trigger associated with it that will fire when the referenced reload was last executed and the Master then initiates a transfer. Executing a Slave SPI Read from within a Slave SPI Trigger would allow the application to recover the data transmitted by the Master.

An application may contain multiple SPI slave definitions, provided that each SPI slave definition block has a unique name and is assigned an exclusive SPI resource chosen from the block drop down resource list.

Block Parameters

Parameter Field Values Comments/Description
Name Unique, C-legal, single quote enclosed alphanumeric Name for this Slave SPI Definition that will be referenced by other blocks like the Slave SPI Reload block.
Resource Drop-down list SPI resource to use with this Slave definition. The behavior is unsupported by the module if (None) is the only resource.
Frame Size Drop-down list Specifies the number of bits in one frame of data. All communication will need to be compatible with this definition.
Task Name Single quote enclosed alphanumeric Specifies the task that will execute any Slave SPI Triggers that have been associated to Slave SPI Reload that are using this Slave Definition. The task may be shared with other activity.