Microcontrollers (MCU)

Design Support

Getting Started

Selection Tool

Training & Events

Developer Network

University

 

Without a hardware multiplier, multiplication and division require many instruction cycles, especially in C code. This report describes a method to perform multiplication and division with only shift and add instructions without a hardware multiplier. The method is based on Horner's method. The MSP430 microcontroller (MCU) can perform a register shift or add in one instruction cycle. This allows fast execution of multiplications and divisions using Horner's method. This method not only produces accurate results but also provides a very good dynamic range, because it does not depend on finite word length effects like some of the conventional methods. This document also describes the Canonical Signed Digit (CSD) representation of numbers, which further reduces the computational load when used with this method for multiplication and division. Note that Horner's method requires the multiplier or the divisor to be known in advance to function.