mwdg-ffi 0.3.0

C FFI bindings for the mwdg micro-watchdog library
Documentation
  • Coverage
  • 100%
    9 out of 9 items documented0 out of 8 items with examples
  • Size
  • Source code size: 50.76 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 203.98 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 12s Average build duration of successful builds.
  • all releases: 12s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • vpetrigo/mwdg
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • vpetrigo

docs.rs

mwdg-ffi

C FFI bindings for the mwdg micro-watchdog library.

This crate provides C-compatible bindings for the mwdg library, enabling the use of the multi-watchdog system in C/C++ embedded projects.

Overview

The library allows C applications to register software watchdogs, track liveness, and detect timeouts centrally. It requires the user to provide platform-specific callbacks for time tracking and critical section management.

Integration

Include the generated include/mwdg.h header in your C code.

Build static library

To use in C/C++ projects, you need to build the static library:

# Build for target (e.g., ARMv7-M FP)
cargo build -p mwdg-ffi --target <target-triple> --release

The target/<target-triple>/release directory will contain libmwdg_ffi.a. You can link this file along with the header mwdg.h (generated in the build process under the OUT_DIR directory) in your C/C++ project.

License