drv_gpio.h 774 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /*
  2. * Copyright (c) 2006-2021, RT-Thread Development Team
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2021-07-29 KyleChan first version
  9. */
  10. #ifndef __DRV_GPIO_H__
  11. #define __DRV_GPIO_H__
  12. #include <board.h>
  13. #include <rthw.h>
  14. #include <rtdbg.h>
  15. #include <rtthread.h>
  16. #include <rtdevice.h>
  17. #include <drv_common.h>
  18. #include <hal_data.h>
  19. #ifdef __cplusplus
  20. extern "C" {
  21. #endif
  22. #define RA_MIN_PIN_VALUE BSP_IO_PORT_00_PIN_00
  23. #define RA_MAX_PIN_VALUE BSP_IO_PORT_11_PIN_15
  24. #ifdef R_ICU_H
  25. struct ra_pin_irq_map
  26. {
  27. const icu_instance_ctrl_t *irq_ctrl;
  28. const external_irq_cfg_t *irq_cfg;
  29. };
  30. #endif
  31. int rt_hw_pin_init(void);
  32. #ifdef __cplusplus
  33. }
  34. #endif
  35. #endif /* __DRV_GPIO_H__ */