mirror of
https://github.com/pvvx/RTL00MP3.git
synced 2025-07-31 12:41:06 +00:00
add examples
This commit is contained in:
parent
265d41b6a3
commit
4128624f93
112 changed files with 158017 additions and 0 deletions
23
RTL00_SDKV35a/example_sources/spi/readme.txt
Normal file
23
RTL00_SDKV35a/example_sources/spi/readme.txt
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
Example Description
|
||||
|
||||
This example describes how to use SPI read/write by mbed api.
|
||||
|
||||
|
||||
The SPI Interface provides a "Serial Peripheral Interface" Master.
|
||||
|
||||
This interface can be used for communication with SPI slave devices,
|
||||
such as FLASH memory, LCD screens and other modules or integrated circuits.
|
||||
|
||||
In this example, it use 2 sets of SPI. One is master, the other is slave.
|
||||
By default it use SPI0 as slave, and use SPI2 as master.
|
||||
So we connect them as below:
|
||||
Connect SPI0_MOSI (PC_2) to SPI2_MOSI (PA_1)
|
||||
Connect SPI0_MISO (PC_3) to SPI2_MISO (PA_0)
|
||||
Connect SPI0_SCLK (PC_1) to SPI2_SCLK (PA_2)
|
||||
Connect SPI0_CS (PC_0) to SPI2_CS (PA_4)
|
||||
|
||||
Because some GPIOA are used as SDIO purpose which has higher priority.
|
||||
So we need pull high PA_7 when device boot up.
|
||||
Connect PA_7 to 3V3
|
||||
|
||||
After boot up, the master will send data to slave and shows result on LOG_OUT.
|
||||
Loading…
Add table
Add a link
Reference in a new issue