drv_spi.h 553 B

123456789101112131415161718192021
  1. /*
  2. * Copyright (c) 2006-2018, RT-Thread Development Team
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. *
  7. * Change Logs:
  8. * Date Author Notes
  9. * 2017-10-20 ZYH the first version
  10. */
  11. #ifndef __STM32_SPI_H_
  12. #define __STM32_SPI_H_
  13. #include <rtthread.h>
  14. #include <rthw.h>
  15. #include <rtdevice.h>
  16. extern int stm32_spi_register_bus(SPI_TypeDef *SPIx, const char *name);
  17. extern rt_err_t stm32_spi_bus_attach_device(rt_uint32_t pin, const char *bus_name, const char *device_name);
  18. extern int stm32_hw_spi_init(void);
  19. #endif