You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2018/09/07 11:16:44 UTC

[GitHub] 5frank opened a new issue #1389: SPI never initialized and no errors (stm32)

5frank opened a new issue #1389: SPI never initialized and no errors (stm32)
URL: https://github.com/apache/mynewt-core/issues/1389
 
 
   
   Trying to use SPI_2 on stm32_e407 devboard but the issue might apply to other bsp:s/mcu:s as well.
   
   In app/myapp/syscfg.yml SPI 2 is enabled:
   ```
   syscfg.vals:
       SPI_2_MASTER: 1
   ```
   The problem is that SPI_2_MASTER is used in mcu layer but not in the bsp layer which result in that SPI 2 is never initialize. (no `hal_spi_init(2, ...)` call).
   
   I guess this issue could either be seen as a problem in the bsp layer (i.e. in hw/bsp/olimex_stm32-e407_devboard/src/hal_bsp.c) as it do not to throw a compile time error. i.e. it could have something like:
   ```
   #ifdef SPI_2_MASTER
   #error "SPI_2 support not (yet) implemented"
   #endif
   ```
   ... or a problem in the mcu layer (in hw/mcu/stm/stm32_common/src/hal_spi.c) as there is no check that hal_spi_init() have been called and give no other error.
   
   Perhaps it is better to fix in in the mcu layer, but not sure how to do that at compile time?
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services