NUTINY-SDK-M0516 Nuvoton Technology Corporation of America, NUTINY-SDK-M0516 Datasheet - Page 244

no-image

NUTINY-SDK-M0516

Manufacturer Part Number
NUTINY-SDK-M0516
Description
BOARD EVAL NUMICRO M051 SERIES
Manufacturer
Nuvoton Technology Corporation of America
Series
NuMicro M051™r
Type
MCUr
Datasheets

Specifications of NUTINY-SDK-M0516

Contents
Board, Cable
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
For Use With/related Products
M051™ Series, M052/M054/M058/M0516
2) Write the related settings into the SPI_CNTRL register to control this SPI slave actions
3)
4)
5)
6)
7)
Select high level and level trigger for the input of slave select signal by setting the Slave
Select Active Level bit SS_LVL (SPI_SSR[2] = 1) and the Slave Select Level Trigger bit
SS_LTRIG (SPI_SSR[4] = 1).
1.
2.
3.
4.
5.
6.
7.
If this SPI slave will transmits (be read) one byte data to the off-chip master device, write the
byte data that will be transmitted into the TX0 [7:0] (SPI_TX0[7:0]) register.
If this SPI slave just only receives (be written) one byte data from the off-chip master device,
you don’t care what data will be transmitted and just write 0xFF into the SPI_TX0[7:0]
register.
Enable the GO_BUSY bit (SPI_CNTRL[0] = 1) to wait for the slave select trigger input and
serial clock input from the off-chip master device to start the data transfer at the SPI
interface.
Waiting for SPI interrupt occurred (if the Interrupt Enable IE bit is set) or just polling the
GO_BUSY bit till it be cleared to 0 by hardware automatically.
Read out the received one byte data from RX[7:0] (SPI_RX0[7:0]) register
Go to 3) to continue another data transfer or disable the GO_BUSY bit to stop data transfer.
Set this SPI controller as slave device in SLAVE bit (SPI_CNTRL[18] = 1)
Select the serial clock idle state at high in CLKP bit (SPI_CNTRL[11] = 1)
Select data transmitted at negative edge of serial clock in TX_NEG bit (SPI_CNTRL[2] =
1)
Select data latched at positive edge of serial clock in RX_NEG bit (SPI_CNTRL[1] = 0)
Set the bit length of word transfer as 8 bits in TX_BIT_LEN bit field (SPI_CNTRL[7:3] =
0x08)
Set only one time of word transfer in TX_NUM (SPI_CNTRL[9:8] = 0x0)
Set LSB transfer first in LSB bit (SPI_CNTRL[10] = 1), and don’t care the SP_CYCLE bit
field (SPI_CNTRL[15:12]) due to not burst mode in this case.
NuMicro M051
Series Technical Reference Manual
- 244 -
Publication Release Date: Sep 14, 2010
Revision V1.2

Related parts for NUTINY-SDK-M0516