diff options
| author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2023-04-16 12:05:20 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-16 12:05:20 +0000 |
| commit | 56bf829931cd3f8267ad435f6ff8f3ae200418b4 (patch) | |
| tree | 41afd65c26f8e77b02845476cbc15fce672119b3 /rtic-monotonics/src/lib.rs | |
| parent | ef8046b060a375fd5e6b23d62c3a9a303bbd6e11 (diff) | |
| parent | cb83309462b1ed6d20ef498d7c2aaa86184c16fc (diff) | |
Merge #732
732: Docs 1 r=korken89 a=datdenkikniet
Going over all of the subprojects and trying to find stuff that may need docs
Co-authored-by: datdenkikniet <jcdra1@gmail.com>
Diffstat (limited to 'rtic-monotonics/src/lib.rs')
| -rw-r--r-- | rtic-monotonics/src/lib.rs | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/rtic-monotonics/src/lib.rs b/rtic-monotonics/src/lib.rs index 04ce4e2..507ee64 100644 --- a/rtic-monotonics/src/lib.rs +++ b/rtic-monotonics/src/lib.rs @@ -1,10 +1,31 @@ -//! Crate +//! In-tree implementations of the [`rtic_time::Monotonic`] (reexported) trait for +//! timers & clocks found on commonly used microcontrollers. +//! +//! To enable the implementations, you must enable a feature for the specific MCU you're targeting. +//! +//! # Cortex-M Systick +//! The [`systick`] monotonic works on all cortex-M parts, and requires that the feature `cortex-m-systick` is enabled. +//! +//! # RP2040 +//! The RP2040 monotonics require that the `rp2040` feature is enabled. +//! +//! # nRF +//! nRF monotonics require that one of the available `nrf52*` features is enabled. +//! +//! All implementations of timers for the nRF52 family are documented here. Monotonics that +//! are not available on all parts in this family will have an `Available on crate features X only` +//! tag, describing what parts _do_ support that monotonic. Monotonics without an +//! `Available on crate features X only` tag are available on any `nrf52*` feature. +//! +// To build these docs correctly: +// RUSTFLAGS="--cfg docsrs" cargo doc --featuers cortex-m-systick,rp2040,nrf52840 #![no_std] #![deny(missing_docs)] //deny_warnings_placeholder_for_ci #![allow(incomplete_features)] #![feature(async_fn_in_trait)] +#![cfg_attr(docsrs, feature(doc_cfg))] pub use rtic_time::{Monotonic, TimeoutError, TimerQueue}; |
