1
0

drv_flash.h 635 B

123456789101112131415161718192021222324252627282930
  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-02-09 shelton the first version
  9. */
  10. #ifndef __DRV_FLASH_H__
  11. #define __DRV_FLASH_H__
  12. #include <rtthread.h>
  13. #include "rtdevice.h"
  14. #include <rthw.h>
  15. #ifdef __cplusplus
  16. extern "C" {
  17. #endif
  18. int at32_flash_read(rt_uint32_t addr, rt_uint8_t *buf, rt_uint32_t size);
  19. int at32_flash_write(rt_uint32_t addr, const rt_uint8_t *buf, rt_uint32_t size);
  20. int at32_flash_erase(rt_uint32_t addr, rt_uint32_t size);
  21. #ifdef __cplusplus
  22. }
  23. #endif
  24. #endif /* __DRV_FLASH_H__ */