Skip to main content

encode_mjd_bcd_utc

Function encode_mjd_bcd_utc 

Source
pub fn encode_mjd_bcd_utc(dt: DateTime<Utc>) -> Option<[u8; 5]>
Available on crate feature chrono only.
Expand description

Encode a chrono::DateTime<chrono::Utc> to a 5-byte DVB UTC time (16-bit MJD + 24-bit BCD HHMMSS).

Sub-second precision is truncated. Returns None if the date is not representable in a 16-bit MJD.