picofuse

memory.h
Go to the documentation of this file.
1 
12 #pragma once
13 #include <stdbool.h>
14 #include <stddef.h>
15 
16 #ifdef __cplusplus
17 extern "C" {
18 #endif
19 
21 // TYPES
22 
32 typedef struct hw_memory_usage_t {
33  size_t ram_total_bytes;
34  size_t ram_free_bytes;
35  size_t heap_used_bytes;
43  size_t
46 
48 // PUBLIC METHODS
49 
75 
76 #ifdef __cplusplus
77 }
78 #endif
size_t flash_used_bytes
Exact linked program image size in flash.
Definition: memory.h:41
size_t flash_reserved_bytes
Flash reserved by active block devices.
Definition: memory.h:42
Snapshot of active memory use.
Definition: memory.h:32
size_t stack_total_bytes
Current core&#39;s reserved stack capacity.
Definition: memory.h:37
size_t ram_free_bytes
Primary SRAM available for heap growth.
Definition: memory.h:34
size_t flash_total_bytes
Physical flash capacity.
Definition: memory.h:40
bool hw_memory_get_usage(hw_memory_usage_t *usage)
Obtain a memory usage snapshot for the current platform.
size_t stack_used_bytes
Current core&#39;s active stack bytes.
Definition: memory.h:38
size_t ram_total_bytes
Total primary SRAM capacity.
Definition: memory.h:33
size_t psram_used_bytes
Active PSRAM allocation bytes.
Definition: memory.h:36
size_t heap_used_bytes
C allocator high-water usage in primary SRAM.
Definition: memory.h:35
size_t flash_free_bytes
Sector-usable flash after image and reservations.
Definition: memory.h:44
size_t stack_free_bytes
Current core&#39;s remaining stack capacity.
Definition: memory.h:39
struct hw_memory_usage_t hw_memory_usage_t
Snapshot of active memory use.