2014-10-12 09:12 PM
Dear all,
I started to work on a STM32L152D-EVAL board. While I started to play around, I tried the demonstration firmware from the following link: http://www.st.com/web/en/catalog/tools/PF257910 I am using the IAR Compiler with I-Jet debugger. I am able to flash the board with new firmware, however nothing is showing up on the lcd, neither something happens when i press the joy stick as demonstrated.I thought the demonstration firmware should run out of the box. Am I missing something here?In particular I need examples related to the SPI interface for this board. Can someone please point me to the right samples for SPI on this board, which may work out of the box, so that I can then further customize the samples based on my needs? Thanks a lot. Regards, Pradeep #stm32l152d-eval-demonstratio-spi
2014-10-15 05:22 AM
As I indicated I don't have this board, so I'm only doing limited analysis.
The Master SPI should not be dependent on any Slave attachment. You might want to focus on the chip select mechanism, and if that is blocking clocks/signals.2014-10-15 07:38 AM
2014-10-15 08:13 AM
After some analysis, I can say that chip select is not blocking signals.
Yeah, I'm not so sure, I think you need to decide if it's a GPIO or AF pin, and then how it's state is handled by the peripheral.2014-10-16 04:10 AM
GPIO_InitStructure.GPIO_Mode of the NSS to GPIO_Mode_Out
and not as AF Pin, I could get the Chip Select signal on scope and then I could also see SCLK , MOSI. Thanks for your feedback. However according to datasheet, SP1_NSS is available as Alternate function on the PA4. See below. Or is my understanding wrong about the table below: Regards.2014-10-16 10:22 AM
By setting the GPIO_InitStructure.GPIO_Mode of the NSS to GPIO_Mode_Out and not as AF Pin, I could get the Chip Select signal on scope and then I could also see SCLK , MOSI. Thanks for your feedback.
However according to datasheet, SP1_NSS is available as Alternate function on the PA4. See below. Or is my understanding wrong about the table below:
The misunderstanding probably relates to the SPI peripherals configuration with respect to SPI_InitStructure.SPI_NSS, ie hard, soft, mushy, etc. and what than means related to GPIO/AF