Crate riot_wrappers
source ·Expand description
Safe and idiomatic Rust wrappers for RIOT-OS
See RIOT’s documentation on using Rust for a general introduction to Rust on RIOT, this crate’s README file on general concepts (such as the interaction between modules here, RIOT modules and features), and the individual modules’ documentation entries for details.
Re-exports
pub use riot_sys;
pub use cstr;
Modules
- Tools for declaring a function that is run during initialization
- Bluetil tools for BLE Advertising Data (AD)
- Common error handling components for the RIOT operating system
- Experimental area for GNRC utility functions
- Access to RIOT’s GPIO pins
- Controlling the I²C bus
- Interaction with interrupts
- Wrappers for the
LEDn_{ON,OFF,TOGGLE}
macros - Tools for providing a RIOT main function
- Access to messages by explicit type indication
- Data-carrying mutex built using RIOT’s mutex module
- Registration and use of SAUL, the Sensor Actuator Uber Layer
- Tools for running RIOT’s built-in shell
- An implementation of the embedded_nal (Network Abstradtion Layer) UDP traits based on RIOT sockets
- An implementation of the embedded_nal (Network Abstradtion Layer) TCP traits based on RIOT sockets
- Wrappers for the stdio
- Create, inspect or modify RIOT processes (“threads”)
- Access to the Virtual File System (VFS) layer
Macros
- Run the function
$func
during auto initialization, with the priority giving the position in the initialization sequence. - interruptDeprecatedWrap a Rust interrupt handler in an extern “C” wrapper that does the post-return cleaups.
- To have a nice Rust main function, run the
riot_main!
macro with the name of your main function an item (ie. top level in a module) in your crate. The function identified by it must return something that implements the Termination trait. - riot_main_with_tokensDeprecated
- Make a function whose signature is
fn(&mut
Stdio
,
Args
<'b>) -> impl
Termination
available through XFA in any RIOT shell, even when called throuch C. (The function’s signature may be more generic, eg. accepting animpl
Write
and animpl
IntoIterator
<&str>
).
Functions
- Name of the RIOT board that is being used