DSPRelated.com
Forums

DSP56807 MACSU instruction operation

Started by wjschint May 23, 2003
I am executing the following instruction on the DSP56807:

MACSU Y0,X0,B

Where, before execution:
Y0 = 0xFFF9
X0 = 0x041E
B = 0

After:
B = B2:B1:B0 = 0x00 083B C65C (it is treating Y0 as unsigned)

Why doesn't this instruction treat Y0 as a two's-compliment signed
number? (ie. Y0 = -6), in which case the result would be:

B = 0xFF FFFF CE98

There has to be a simple explanation - someone please set me
straight...
Thank you - Bill Schintler



RE: [motoroladsp] DSP56807 MACSU instruction operation

Dear Bill,

The combination                 MACSU Y0,X0,B   is invalid
the correct form is     MACSU X0,Y0,B

also be carefull when using the code warrior assembler, because
in this case Code Warrior changed the order without telling you.
Allways select the mix code option to verify that the code
was assembled in the correct form.


Jose Torrico
Commodity Systems
www.commodity.com.br
Sao Paulo-Brazil


-----Original Message-----
From: wjschint [mailto:w...@mchsi.com]
Sent: Friday, May 23, 2003 12:52 AM
To: m...@yahoogroups.com
Subject: [motoroladsp] DSP56807 MACSU instruction operation


I am executing the following instruction on the DSP56807:

MACSU Y0,X0,B

Where, before execution:
Y0 = 0xFFF9
X0 = 0x041E
B = 0

After:
B = B2:B1:B0 = 0x00 083B C65C  (it is treating Y0 as unsigned)

Why doesn't this instruction treat Y0 as a two's-compliment signed
number? (ie. Y0 = -6), in which case the result would be:

B = 0xFF FFFF CE98

There has to be a simple explanation - someone please set me
straight...
Thank you - Bill Schintler


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get A Free Psychic Reading! Your Online Answer To Life's Important Questions.
http://us.click.yahoo.com/Lj3uPC/Me7FAA/uetFAA/PNArlB/TM
---------------------------------~->

_____________________________________
Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer.  You need to do a "reply all" if you want your answer to be distributed to the entire group.

_____________________________________
About this discussion group:

To Join:  m...@yahoogroups.com

To Post:  m...@yahoogroups.com

To Leave: m...@yahoogroups.com

Archives: http://www.yahoogroups.com/group/motoroladsp

More Groups: http://www.dsprelated.com/groups.php3
 

">http://docs.yahoo.com/info/terms/