[erlang-questions] Float to binary
Tue Mar 22 02:24:14 CET 2011
On 22/03/2011, at 11:27 AM, Bob Cowdery wrote:
> Its part of a binary that gets sent to a device. Its not actually a
> scaling factor its simply a conversion from MHZ to Hz. 1 MHz =
Er, that _is_ a scaling factor.
> The frequency internally is a float but needs to be a 32 bit
> big-endian number in Hz to send to the device.
So will Hz = round(1000000 * MHz) do?
More information about the erlang-questions