LibJuno 1.0.1
LibJuno is a lightweight C11 library designed specifically for embedded systems.
Loading...
Searching...
No Matches
minimal_memory_example.c File Reference
#include "juno/macros.h"
#include "juno/memory/memory_api.h"
#include "juno/memory/memory_block.h"
#include "juno/status.h"
#include <stdio.h>
#include <stdalign.h>
Include dependency graph for minimal_memory_example.c:

Data Structures

struct  USER_DATA_T
 

Typedefs

typedef struct USER_DATA_T USER_DATA_T
 

Functions

static JUNO_STATUS_T UserDataCopy (JUNO_POINTER_T tDest, JUNO_POINTER_T tSrc)
 
static JUNO_STATUS_T UserDataReset (JUNO_POINTER_T tPointer)
 Reset the memory at the pointer. This could mean zero-initialization.
 
 JUNO_MEMORY_BLOCK (gUserDataMemory, USER_DATA_T, 5)
 
 JUNO_MEMORY_BLOCK_METADATA (gUserDataMetadata, 5)
 
void ErrorHandler (JUNO_STATUS_T tStatus, const char *pcMsg, JUNO_USER_DATA_T *pvUserData)
 
int main (void)
 

Variables

const JUNO_POINTER_API_T gtUserDataPointerApi
 

Typedef Documentation

◆ USER_DATA_T

typedef struct USER_DATA_T USER_DATA_T

Function Documentation

◆ ErrorHandler()

void ErrorHandler ( JUNO_STATUS_T  tStatus,
const char *  pcMsg,
JUNO_USER_DATA_T pvUserData 
)

◆ JUNO_MEMORY_BLOCK()

JUNO_MEMORY_BLOCK ( gUserDataMemory  ,
USER_DATA_T  ,
 
)

◆ JUNO_MEMORY_BLOCK_METADATA()

JUNO_MEMORY_BLOCK_METADATA ( gUserDataMetadata  ,
 
)

◆ main()

int main ( void  )

◆ UserDataCopy()

static JUNO_STATUS_T UserDataCopy ( JUNO_POINTER_T  tDest,
JUNO_POINTER_T  tSrc 
)
static

◆ UserDataReset()

static JUNO_STATUS_T UserDataReset ( JUNO_POINTER_T  tPointer)
static

Reset the memory at the pointer. This could mean zero-initialization.

Variable Documentation

◆ gtUserDataPointerApi

const JUNO_POINTER_API_T gtUserDataPointerApi
Initial value:
= {
}
static JUNO_STATUS_T UserDataCopy(JUNO_POINTER_T tDest, JUNO_POINTER_T tSrc)
Definition minimal_memory_example.c:40
static JUNO_STATUS_T UserDataReset(JUNO_POINTER_T tPointer)
Reset the memory at the pointer. This could mean zero-initialization.
Definition minimal_memory_example.c:53