pub unsafe extern "C" fn infrared_decode(
handler: *mut InfraredDecoderHandler,
level: bool,
duration: u32,
) -> *const InfraredMessageExpand description
Provide to decoder next timing.
§Arguments
handler(direction in) - - handler to INFRARED decoders. Should be acquired withinfrared_alloc_decoder().level(direction in) - - high(true) or low(false) level of input signal to analyze. it should alternate every call, otherwise it is an error case, and decoder resets its state and start decoding from the start.duration(direction in) - - duration of steady high/low input signal.
§Returns
if message is ready, returns pointer to decoded message, returns NULL. Note: ownership of returned ptr belongs to handler. So pointer is valid up to next infrared_free_decoder(), infrared_reset_decoder(), infrared_decode(), infrared_check_decoder_ready() calls.