Matt Heck wrote: >>> - very poorly suited to developing floating-point functions, >>> especially untested ones >> >> The XCASM assembler supports floating point. So does the associated >> XCSIM simulator. > > > Sweet-- I'll have to look into it. Do you happen to know if this > thing's IEEE compliant? Converting values between two floating-point > packages to test things is an extra headache I'd like to avoid. > > Thank you, Sergio! > > --Matt Yep. IEEE 754 32 bit single format stored little endien order. The assembler uses .df .dsf and .pic_df directives to initialise memory and associate labels with floating point quantities (association allows the simulator to display, monitor and edit multibyte quantities such as floats, longs and words according to their type). The .pic_df directive generates retlw statements suitable for PIC table lookup. The floating point library supports IEEE 754 single format quite NaNs (including +/- Infinity) and rounding is by simple truncation. The assembler allows statements of the form: fred .dsf 0 jack .dsf 0 bert .dsf 0 .let fred = bert / jack Here the assembler will generate all the code necessary to invoke the floating point divide function with parameters bert and jack, and then store the result to fred. The assembler also allows embedded user functions e.g. .let fred = SIN(theta) * bert where SIN is a user defined function Regards Sergio Masci -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics