Table 39-6. SPI Master (CPHA=0) Configuration (continued)
Register
Value
Comments
SHIFTCTL(n+1)
0x0000_0101
Configure receive using Timer 0 on
posedge of clock with input data on Pin
1.
TIMCMPn
0x0000_3F01
Configure 32-bit transfer with baud rate
of divide by 4 of the FlexIO clock. Set
TIMCMP[15:8] = (number of bits x 2) - 1.
Set TIMCMP[7:0] = (baud rate divider /
2) - 1.
TIMCFGn
0x0100_2222
Configure start bit, stop bit, enable on
trigger high and disable on compare,
initial clock state is logic 0. Set PINPOL
to invert the output shift clock.
TIMCTLn
0x01C3_0201
Configure dual 8-bit counter using Pin 2
output (shift clock), with Shifter 0 flag as
the inverted trigger.
TIMCMP(n+1)
0x0000_FFFF
Never compare.
TIMCFG(n+1)
0x0000_1100
Enable when Timer 0 is enabled and
disable when Timer 0 is disabled.
TIMCTL(n+1)
0x0003_0383
Configure 16-bit counter (never
compare) using inverted Pin 3 output (as
slave select).
SHIFTBUFn
Data to transmit
Transmit data can be written to
SHIFTBUF, use the Shifter Status Flag
to indicate when data can be written
using interrupt or DMA request. Can
support MSB first transfer by writing to
SHIFTBUFBBS register instead.
SHIFTBUF(n+1)
Data to receive
Received data can be read from
SHIFTBUFBYS, use the Shifter Status
Flag to indicate when data can be read
using interrupt or DMA request. Can
support MSB first transfer by reading
from SHIFTBUFBIS register instead.
Table 39-7. SPI Master (CPHA=1) Configuration
Register
Value
Comments
SHIFTCFGn
0x0000_0021
Start bit loads data on first shift.
SHIFTCTLn
0x0003_0002
Configure transmit using Timer 0 on
posedge of clock with output data on Pin
0.
SHIFTCFG(n+1)
0x0000_0000
Start and stop bit disabled.
SHIFTCTL(n+1)
0x0080_0101
Configure receive using Timer 0 on
negedge of clock with input data on Pin
1.
TIMCMPn
0x0000_3F01
Configure 32-bit transfer with baud rate
of divide by 4 of the FlexIO clock. Set
TIMCMP[15:8] = (number of bits x 2) - 1.
Table continues on the next page...
Application Information
KL27 Sub-Family Reference Manual , Rev. 5, 01/2016
776
Freescale Semiconductor, Inc.
Содержание MKL27Z128VFM4
Страница 2: ...KL27 Sub Family Reference Manual Rev 5 01 2016 2 Freescale Semiconductor Inc...
Страница 54: ...AWIC introduction KL27 Sub Family Reference Manual Rev 5 01 2016 54 Freescale Semiconductor Inc...
Страница 100: ...Module operation in low power modes KL27 Sub Family Reference Manual Rev 5 01 2016 100 Freescale Semiconductor Inc...
Страница 142: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 142 Freescale Semiconductor Inc...
Страница 248: ...Memory map and register descriptions KL27 Sub Family Reference Manual Rev 5 01 2016 248 Freescale Semiconductor Inc...
Страница 256: ...Memory map register descriptions KL27 Sub Family Reference Manual Rev 5 01 2016 256 Freescale Semiconductor Inc...
Страница 262: ...Initialization application information KL27 Sub Family Reference Manual Rev 5 01 2016 262 Freescale Semiconductor Inc...
Страница 292: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 292 Freescale Semiconductor Inc...
Страница 324: ...Functional Description KL27 Sub Family Reference Manual Rev 5 01 2016 324 Freescale Semiconductor Inc...
Страница 390: ...Application information KL27 Sub Family Reference Manual Rev 5 01 2016 390 Freescale Semiconductor Inc...
Страница 422: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 422 Freescale Semiconductor Inc...
Страница 432: ...Initialization Application Information KL27 Sub Family Reference Manual Rev 5 01 2016 432 Freescale Semiconductor Inc...
Страница 442: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 442 Freescale Semiconductor Inc...
Страница 512: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 512 Freescale Semiconductor Inc...
Страница 610: ...Initialization application information KL27 Sub Family Reference Manual Rev 5 01 2016 610 Freescale Semiconductor Inc...
Страница 646: ...Initialization application information KL27 Sub Family Reference Manual Rev 5 01 2016 646 Freescale Semiconductor Inc...
Страница 744: ...Application information KL27 Sub Family Reference Manual Rev 5 01 2016 744 Freescale Semiconductor Inc...
Страница 784: ...Application Information KL27 Sub Family Reference Manual Rev 5 01 2016 784 Freescale Semiconductor Inc...
Страница 830: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 830 Freescale Semiconductor Inc...
Страница 850: ...Application information KL27 Sub Family Reference Manual Rev 5 01 2016 850 Freescale Semiconductor Inc...
Страница 886: ...Functional description KL27 Sub Family Reference Manual Rev 5 01 2016 886 Freescale Semiconductor Inc...