riot_coap_handler_demos::led

Function single_led

Source
pub fn single_led<const I: u8>(led: LED<I>) -> impl Handler + Reporting
Available on crate feature riot-wrappers only.
Expand description

Handler for a single LED.

The handler accepts PUTs of CBOR booleans true or false. It also accepts POSTs, which for simplicity of the implementation right now require a CBOR null value in the payload.