Join our technical discussions about Freescale Microcontrollers: M68HC12. (Freescale Semiconductor is a Subsidiary of Motorola).
Floating-Point Assembler Code - ga5941 - Jan 22 16:42:34 2009
I'm a hobbyist writting assembler code for a MC9S12A256 using AN974,
the MC68HC11 Floating-Point Package written by Gordon Doughman. I'm
getting some strange results and wonder if anyone else is experiencing
problems using this package. The application is controlling a dob
telescope with stepper motors.
------------------------------------

(You need to be a member of 68hc12 -- send a blank email to 68hc12-subscribe@yahoogroups.com )
Re: Floating-Point Assembler Code - David Armstrong - Jan 22 16:51:28 2009
I think there are some bugs in that code. I'll attach a floating point
package that worked for me. It was provided to me from someone else on the
list here.
Dave
On Thu, Jan 22, 2009 at 2:42 PM, ga5941
wrote:
> I'm a hobbyist writting assembler code for a MC9S12A256 using AN974,
> the MC68HC11 Floating-Point Package written by Gordon Doughman. I'm
> getting some strange results and wonder if anyone else is experiencing
> problems using this package. The application is controlling a dob
> telescope with stepper motors.
>
>
>
[Non-text portions of this message have been removed]
------------------------------------

(You need to be a member of 68hc12 -- send a blank email to 68hc12-subscribe@yahoogroups.com )RE: Floating-Point Assembler Code - "Redd, Emmett R" - Jan 24 9:56:45 2009
The below is from memory.
I have never used the HC11 Floating-Point Package. But, there is one subtle difference
between the HC11 and HC12 that could cause some strange things to happen on calling any
routines where parameters are passed via the stack. The HC11 stack pointer points to the
next available position on the stack; the HC12 stack pointer points to the last used
position on the stack.
HTH
Emmett Redd Ph.D. mailto:E...@missouristate.edu
Professor (417)836-5221
Department of Physics, Astronomy, and Materials Science
Missouri State University Fax (417)836-6226
901 SOUTH NATIONAL Dept (417)836-5131
SPRINGFIELD, MO 65897 USA
Physicists always practice energy conservation.
________________________________
From: 6...@yahoogroups.com on behalf of ga5941
Sent: Thu 1/22/2009 3:42 PM
To: 6...@yahoogroups.com
Subject: [68HC12] Floating-Point Assembler Code
I'm a hobbyist writting assembler code for a MC9S12A256 using AN974,
the MC68HC11 Floating-Point Package written by Gordon Doughman. I'm
getting some strange results and wonder if anyone else is experiencing
problems using this package. The application is controlling a dob
telescope with stepper motors.
------------------------------------

(You need to be a member of 68hc12 -- send a blank email to 68hc12-subscribe@yahoogroups.com )
Re: Floating-Point Assembler Code - Edward Karpicz - Jan 24 11:25:29 2009
Redd, Emmett R wrote:
> I have never used the HC11 Floating-Point Package. But, there is one
> subtle difference between the HC11 and HC12 that could cause some strange
> things to happen on calling any routines where parameters are passed via
> the stack. The HC11 stack pointer points to the next available position
> on the stack; the HC12 stack pointer points to the last used position on
> the stack.
>
Yes, but to access stack space on HC11, one had to transfer SP to X or Y
index register. On HC11 TSX and TSY transfer SP+1 to X and Y, and on HC12
TSX and TSY transfer SP+0 to X and Y. So I don't know how hardware
independent HC11 code could fail on HC12.
HC11FP +-*/ operations have some flaws and math functions have not very good
accuracy.
Regards
Edward
------------------------------------

(You need to be a member of 68hc12 -- send a blank email to 68hc12-subscribe@yahoogroups.com )