openaliro
Aliro reader: UWB/CCC core and ESP32-S3/C5/C6 port
Loading...
Searching...
No Matches
woz_alloc.h
1
// Memory allocation and timing facade: qmalloc, qcalloc, qfree wrap the platform heap;
2
// qrtc_get_us returns monotonic microseconds since boot.
3
/*
4
* Copyright (c) 2026 asxeem
5
* SPDX-License-Identifier: ISC
6
* woz_alloc.h - thin heap + monotonic-clock wrappers over woz_port.h.
7
*/
8
#ifndef WOZ_ALLOC_H
9
#define WOZ_ALLOC_H
10
11
#include <stddef.h>
12
#include <stdint.h>
13
14
#include "
woz_port.h
"
15
21
static
inline
void
*qmalloc(
size_t
size)
22
{
23
return
woz_malloc(size);
24
}
25
32
static
inline
void
*qcalloc(
size_t
nb_items,
size_t
item_size)
33
{
34
return
woz_calloc(nb_items, item_size);
35
}
36
41
static
inline
void
qfree(
void
*ptr)
42
{
43
woz_free(ptr);
44
}
45
50
static
inline
int64_t qrtc_get_us(
void
)
51
{
52
return
woz_uptime_us();
53
}
54
55
#endif
/* WOZ_ALLOC_H */
woz_port.h
Portable platform shim: allocates memory, measures uptime and cycle counts, provides sleep stubs for ...
modules
woz_uwb
src
facade
woz_alloc.h
Generated by
1.9.8