Float Typecast
Typecast a floating-point type to an unsigned integer or vice versa
- Library:
HDL Coder / HDL Floating Point Operations
Description
The block casts the underlying bits of the input to the corresponding fixed-point or floating point representation. The input and output of the block contain the same number of bits.
Input Data Type | Output Data Type |
---|---|
half | uint16 |
single | uint32 |
double | uint64 |
uint32 | single |
uint64 | double |
uint16 | half |
This figure shows how the block mask, behavior, and output data type changes dynamically depending on the input data type that you specify.