📄 readme.txt
字号:
/*************************************************************************************************************************************************/
This code configures the primary SPI of the ADSP-21369 SHARC processor in master mode. The SPI is configured as transmitter or receiver based on the
macro settings in SPI.h file. When configured as receiver after the DMA is completed the data received is compared with the known data.
In case of failure only one LED is toggled and for the passing case 3 LEDs on the ADSP-21369 EZ-KIT Lite board are toggled.
The following are the files available in the project:
1. SPI.h file which has the macros for configuring the system and SPI.
a. The SET_CPHASE, SET_CLKPL and SET_CPHASE_CLKPL macros are used for selecting Clock Phase and Polarity for the SPI transfers.
b. Using the MS_TRANSMITTER macro the SPI can be configured as transmitter in DMA mode otherwise the SPI is used as receiver in DMA mode.
c.The core clock for the ADSP-21369 processor also can be defined using the PLL_XXX_MHZ macros. These macros allow the processor to run in the
configured core clock. The PMCTL register is configured as per the macro value selected.
d. The SPI frequency can also be configured using the SPI_FREQ macro. Based on the value selected the SPIBAUD register value will be calculated and
programmed by the application.
2. Configdai.asm which has the SRU routings for the SPI. The SPI signals are routed as follows:
a. DPI 6 - SPI_CLK
b. DPI 7 - SPI_MOSI
c. DPI 8 - SPI_FLG0
d. DPI 13 - SPI_MISO
3. InitPLL.asm - Configures the PLL as per the Core clock frequency selected.
4. SPI_Master_DMA.asm - Configures the SPI control registers for master mode DMA operation. And the SPIBAUD rate is calculated automatically
based on the SPI_FREQ macro and core clock selected.
/*************************************************************************************************************************************************/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -