Post Go back to editing

ADXRS453 with STM32

Hello,

I am beginner and I would really use some help from experienced users.

My goal is to use ADXRS453 with help of no-os library and Nucleo with STM32F103RB.

Short question is - how do you do that?

I found Guide and I use provided adxrs453 drivers and provided stm32 drivers for SPI and GPIO. I define param structures and empty device pointer as instruced. I define spi funtions as stm32_spi functions and pass the arguments. Still, proccessor calls back HardFault_Handler as spi_init does not return success.

Could anyone provide some template, or roadmap how to implement stm32 drivers and device drivers? If needed, I can show my code. Any help would be highly appreciated!



tag added
[edited by: gregorylakewood at 2:57 PM (GMT -5) on 31 Jan 2022]
Parents
  • Hi  ,

    I suggest you start with the iio_demo project, try to build it using the no-OS build system and run it on your stm32f103rb board.

    https://github.com/analogdevicesinc/no-OS/tree/master/projects/iio_demo

    We currently support auto-generating the STM32CubeIde project from Linux (are you using Windows or Linux as your host machine?), you can follow the build guide here:

    https://wiki.analog.com/resources/no-os/build

    So the flow would be:

    - install the stm32 environment/prerequisites

    - generate an .ioc file for your board where you configure minimal stuff like internal clocking and UART for the iio_demo to work

    - use this .ioc and our build system to generate the STM32CubeIDE project

    - make develop / make run / make debug to run/debug the code

    Once this is working, you can proceed to creating your own project under projects/ folder with its own Makefile, src.mk and .c files. And of course, your own full-featured .ioc file with spi/gpio etc.

    The instructions above have been superseeded by the proper way to build for stm32, see my other comment.

Reply
  • Hi  ,

    I suggest you start with the iio_demo project, try to build it using the no-OS build system and run it on your stm32f103rb board.

    https://github.com/analogdevicesinc/no-OS/tree/master/projects/iio_demo

    We currently support auto-generating the STM32CubeIde project from Linux (are you using Windows or Linux as your host machine?), you can follow the build guide here:

    https://wiki.analog.com/resources/no-os/build

    So the flow would be:

    - install the stm32 environment/prerequisites

    - generate an .ioc file for your board where you configure minimal stuff like internal clocking and UART for the iio_demo to work

    - use this .ioc and our build system to generate the STM32CubeIDE project

    - make develop / make run / make debug to run/debug the code

    Once this is working, you can proceed to creating your own project under projects/ folder with its own Makefile, src.mk and .c files. And of course, your own full-featured .ioc file with spi/gpio etc.

    The instructions above have been superseeded by the proper way to build for stm32, see my other comment.

Children
No Data