Skip to content

C_LIB_DOCUM

Pavel A edited this page Sep 4, 2016 · 3 revisions

C library

TODO

Please see libdevmem.h

Implemented by mapping /dev/mem, exactly like in the devmem utility but physical addresses are relative by default.

The base address for relative offsets is defined in an environment variable. The name of the variable can be #defined at compile time.

The library is just one .c file that should be compiled with the user program. It can be built as a real static or shared library, if wanted.

See also: the config helper script libdevmem-config.

Example

See files ex1.c, ex1.mk in the source.

Clone this wiki locally