Function fromNumber

  • Converts a number to an U16 value

    Parameters

    • value: number

      The number to convert

    Returns U16_t

    The U16 representation of the number

    Throws

    if the value is not a safe integer, negative or too large for U16