Skip to content
UPEEC

Fixed-Point Arithmetic

Represent fractions with integers scaled by a power of two — fast on MCUs without an FPU.

Intermediate
Comments 0

Q15 format: value =n/215= n / 2^{15}. Multiply then shift: (int32_t)a * b >> 15. CMSIS-DSP provides Q15/Q31 functions.

Spotted a mistake or want to add detail? Suggest an improvement — Content Contributors' edits are reviewed by editors before they go live.

Discussion (0)

Sign in or join free to ask questions and discuss this topic.