SPI Slave Problem:
For STM32L151, If SPI2 is configured as SPI Slave, what is the expected frequency from SPI Master for which STM32L151 can transmit data without any issues?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2018-12-06 10:47 PM
STM32L151's AHB is at 32Mhz and APB runs at 16MHz.
Given in the datasheet that SPI Slave clock can be APB clock/2 max.
I have tried to transmit 7 bytes of data from STM32L151. I am able to receive data properly if my SPI master clock is configured to 2.5Mhz. At any higher frequencies, i am seeing data repetition.
For Instance, If I try to send data as 0xA0,0xA1,0xA2,0xA3,0xA4,0xA5,0xA6. I am receiving data as 0xA0,0xA0,0xA0,0xA1,0xA2,0xA2,0xA3 and the transfer is incomplete.
I have tried using polling as well as DMA Mode. Still i face this issue at higher frequency.
I am suspecting that TXE is not set properly during the transaction at high frequency.
Labels:
- Labels:
-
SPI
-
STM32L1 Series
This discussion is locked. Please start a new topic to ask your question.
0 REPLIES 0
