I’m continuing working with Juan Brito and Danny Macancela from the blog Desafio Ecuador, developing new boards to bring near the technology and programming languages. Our last work is a board to use with the Raspberry Pi and focused to learn Python. The board has the basic elements to start with this language. Also, with the develop of the PCB we remove the wiring, avoiding troubles with connections, inversion polarity…So with this board you only focused in the software develop, because the hardware side will work!
Mário Ribeiro writes:
Have you been using float or double variables to perform mathematical operations on embedded systems without a Floating-Point Unit (FPU)? You are doing it wrong! That’s incredibly inefficient.
An FPU is an hardware block specially designed to carry on arithmetic operations on floating point numbers. Even though the C/C++ code may work without an FPU, it’s always much faster to use hardware designed for a specific purpose, like this one, instead of relying on a software implementation, something that the compiler will do for you, knowing the hardware restrictions you have but not in an efficient manner. Essentially, it will generate a lot of assembly code, greatly increasing the size of your program and the amount of time required to complete the operation. Thus, if you don’t have an FPU available and you still want to perform those arithmetic operations efficiently you’ll have to convert those numbers to fixed-point representation. Integers! But how? By scaling them. Let’s see how that scaling value may be determined.
The Art of Representing Floating-Point Numbers as Integers – [Link]