Summary (Microcontrollers)

7.7
This topic covered the techniques you need to handle integer and floating point arithmetic in a microcontroller. We discussed the conversion of integers between any two bases and then discussed signed and unsigned multiple precision arithmetic operations that had not been discussed in earlier examples. Floating-point representations of numbers with a fractional part, and the algorithms used to add and multiply floating point numbers, were discussed together with the problems of rounding and conversion. The IEEE standard floating-point format was used throughout these discussions. We ended with the use of the stack for holding the arguments for arithmetic subroutines and showed how you can write a sequence of subroutine calls to evaluate any formula.
You should now be able to write subroutines for signed and unsigned arithmetic operations, and you should be able to write and use such subroutines that save results on the stack. You should be able to convert integers from one representation to another and write subroutines to do this conversion. You should be able to write numbers in the IEEE floating-point representation, and you should understand how these numbers are added or multiplied and how errors can accumulate.

Do You Know These Terms?

See the end of topic J for instructions.
long data float data state biasing m-digit base-b
representation Polish notation parsing tree fixed-point
representation significand exponential part floating-point hidden bit single precision
floating-point
floating-point
numbers bias
normalized
number denormalized
number unnormalization renormalized overflow underflow rounding toward
plus infinity rounding toward
minus infinity truncation
rounding toward zero
rounding to nearest
flushing to zero
rounding
guard bit
round bit
sticky bit
decimal floatingpoint number
linguistic variable
value
membership
function rule
fuzzy inference
kernel knowledge base antecedent fuzzy AND consequent fuzzy OR fuzzy negate singleton
The Motorola M68HC12A4EVB board can implement all the experiments including thosf of topic 10. The wire-wrap area shows a shift-register that implements the device diagrammed in Figure 10.6.
tmp7-81_thumb[1]


Next post:

Previous post: