File tree Expand file tree Collapse file tree
ports/atmel-samd/supervisor Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2424 * THE SOFTWARE.
2525 */
2626
27+ #include "supervisor/internal_flash.h"
28+
2729#include <stdint.h>
2830#include <string.h>
2931
Original file line number Diff line number Diff line change 3232
3333#include "sam.h"
3434
35- #define FLASH_ROOT_POINTERS
36-
3735#ifdef SAMD51
3836#define TOTAL_INTERNAL_FLASH_SIZE (FLASH_SIZE / 2)
3937#endif
4947#define INTERNAL_FLASH_SYSTICK_MASK (0x1ff) // 512ms
5048#define INTERNAL_FLASH_IDLE_TICK (tick ) (((tick) & INTERNAL_FLASH_SYSTICK_MASK) == 2)
5149
52- void internal_flash_init (void );
53- uint32_t internal_flash_get_block_size (void );
54- uint32_t internal_flash_get_block_count (void );
55- void internal_flash_irq_handler (void );
56- void internal_flash_flush (void );
57- bool internal_flash_read_block (uint8_t * dest , uint32_t block );
58- bool internal_flash_write_block (const uint8_t * src , uint32_t block );
59-
60- // these return 0 on success, non-zero on error
61- mp_uint_t internal_flash_read_blocks (uint8_t * dest , uint32_t block_num , uint32_t num_blocks );
62- mp_uint_t internal_flash_write_blocks (const uint8_t * src , uint32_t block_num , uint32_t num_blocks );
63-
64- extern const struct _mp_obj_type_t internal_flash_type ;
65-
66- struct _fs_user_mount_t ;
67- void flash_init_vfs (struct _fs_user_mount_t * vfs );
68-
6950#endif // MICROPY_INCLUDED_ATMEL_SAMD_INTERNAL_FLASH_H
You can’t perform that action at this time.
0 commit comments