Functional Description
11-20
ADSP-BF537 Blackfin Processor Hardware Reference
Functional Description
The following sections describe the functional operation of the TWI.
General Setup
General setup refers to register writes that are required for both slave
mode operation and master mode operation. General setup should be per-
formed before either the master or slave enable bits are set.
• Program the
TWI_CONTROL
register to enable the TWI controller
and set the prescale value. Program the prescale value to the binary
representation of
f
SCLK
/ 10MHz
All values should be rounded up to the next whole number. The
TWI_ENA
bit enable must be set. Note once the TWI controller is enabled a bus
busy condition may be detected. This condition should clear after t
BUF
has expired assuming no additional bus activity has been detected.
Slave Mode
When enabled, slave mode operation supports both receive and transmit
data transfers. It is not possible to enable only one data transfer direction
and not acknowledge (NAK) the other. This is reflected in the following
setup.
1. Program
TWI_SLAVE_ADDR
. The appropriate 7 bits are used in deter-
mining a match during the address phase of the transfer.
2. Program
TWI_XMT_DATA8
or
TWI_XMT_DATA16
. These are the initial
data values to be transmitted in the event the slave is addressed and
a transmit is required. This is an optional step. If no data is written
and the slave is addressed and a transmit is required, the serial
clock (
SCL
) is stretched and an interrupt is generated until data is
written to the transmit FIFO.
Summary of Contents for Blackfin ADSP-BF537
Page 42: ...Contents xlii ADSP BF537 Blackfin Processor Hardware Reference ...
Page 90: ...Development Tools 1 32 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 138: ...Programming Examples 4 26 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 340: ...SDC Programming Examples 6 84 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 606: ...Programming Examples 9 94 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 660: ...Programming Examples 10 54 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 720: ...Electrical Specifications 11 60 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 840: ...Programming Examples 13 42 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 876: ...Programming Examples 14 36 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 938: ...Programming Examples 15 62 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 958: ...Programming Examples 17 12 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 986: ...Programming Examples 18 28 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 1162: ...G 26 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 1218: ...Index I 56 ADSP BF537 Blackfin Processor Hardware Reference ...