embedded_platform/
time.rs1#[repr(transparent)]
2#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
3pub struct Hertz(u32);
4
5pub trait U32Ext {
6 fn hz(self) -> Hertz;
7}
8
9impl U32Ext for u32 {
10 fn hz(self) -> Hertz {
11 Hertz(self)
12 }
13}