O'Reilly logo

Making Embedded Systems by Elecia White

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 9. Math

When we looked at trading resources in the last chapter, you had to choose between RAM, code space, and processing cycles. Trading resources goes only so far. Sometimes you need to make your code go faster. Not knowing what you’ll need for your system, I can still guess that you’ll need to implement some math (because that is where processors excel).

The less your system does, the fewer resources it needs to do them. Sometimes we confuse accuracy, which is important, with precision, which can go too far (see ). If you can quantify the range of data you expect and your error budget, there are some useful methods to reduce unnecessary precision for all sorts of algorithms, thereby saving RAM and processing cycles.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required