Function rp_hal::rom_data::double_to_fix[][src]

pub fn double_to_fix() -> extern "C" fn(v: f64, n: i32) -> i32

Convert a double to an unsigned fixed point integer representation where n specifies the position of the binary point in the resulting fixed point representation, e.g. _double2ufix(0.5f, 16) == 0x8000. This method rounds towards -Infinity, and clamps the resulting integer to lie within the range 0x00000000 to 0xFFFFFFFF