поискавой системы для электроныых деталей
  Russian  ▼
ALLDATASHEETRU.COM

X  

RM0312 датащи(PDF) 209 Page - STMicroelectronics

номер детали RM0312
подробное описание детали  STM8TL5xxx microcontroller family
PDF  275 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
производитель  STMICROELECTRONICS [STMicroelectronics]
домашняя страница  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

RM0312 датащи(HTML) 209 Page - STMicroelectronics

Back Button RM0312 Datasheet HTML 205Page - STMicroelectronics RM0312 Datasheet HTML 206Page - STMicroelectronics RM0312 Datasheet HTML 207Page - STMicroelectronics RM0312 Datasheet HTML 208Page - STMicroelectronics RM0312 Datasheet HTML 209Page - STMicroelectronics RM0312 Datasheet HTML 210Page - STMicroelectronics RM0312 Datasheet HTML 211Page - STMicroelectronics RM0312 Datasheet HTML 212Page - STMicroelectronics RM0312 Datasheet HTML 213Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 209 / 275 page
background image
DocID022352 Rev 3
209/275
RM0312
Serial peripheral interface (SPI)
223
Handling data transmission and reception
The TXE flag (Tx buffer empty) is set when the data is transferred from the Tx buffer to the
shift register. It indicates that the internal Tx buffer is ready to be loaded with the next data.
An interrupt can be generated if TXIE bit in the SPI_ICR register is set.
Note:
The software must ensure that TXE flag is set to 1 before attempting to write into the Tx
buffer. Otherwise, it will overwrite the data which was previously written in the Tx buffer.
The RXNE flag (Rx buffer not empty) is set on the last sampling clock edge, when the data
is transferred from the shift register to the Rx buffer. It indicates that a data is ready to be
read from the SPI_DR register. An interrupt can be generated if RXIE bit in the SPI_ICR
register is set. Clearing the RXNE bit is performed by reading the SPI_DR register.
In some configurations, the BSY flag can be used during the last data transfer to wait until
the completion of the transfer.
Full Duplex Transmit and receive procedure in master or slave mode
(BDM=0 and RXONLY = 0)
1.
Enable the SPI by setting the SPE bit
2.
Write the first data to be transmitted in the SPI_DR register (this clears the TXE flag).
3.
Wait until TXE = 1 and write the second data to be transmitted. Then wait until RXNE =
1 and read the SPI_DR to get the first received data (this clears the RXNE bit). Repeat
this operation for each data to be transmitted/received until the n-1 received data.
4.
Wait until RXNE = 1 and read the last received data.
5.
Wait until TXE = 1 and then wait until BSY = 0 before disabling the SPI.
This procedure can also be implemented using dedicated interrupt subroutines launched at
each rising edge of RXNE or TXE flags.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


датащи скачать

Go To PDF Page


ссылки URL



Вашему бизинису помогли Аллдатащит?  [ DONATE ] 

Что такое Аллдатащит   |   реклама   |   контакт   |   Конфиденциальность   |   Ссылка на техническое описание    |   обмен ссыками   |   поиск по производителю
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com