DSPRelated.com
Forums

how to embed assembly

Started by liang mar March 1, 2004
Hi:
I give my thanks to you at first.I did as your guides :Enable or Disable the
interrupt using the assembly statement in C enviornment on the " CCS DSK C5000
1.22 " in the following :
#include <board.h>
#include <flash1.h>
void main (void)
{ asm("SSBX INTM");
.
.
.
asm("RSBX INTM");
.
.
.
}
but the bit "INTM" always could not be changed(through the register window) and
there is a error information when invoke the assembler (version 3.50) ---"
ERROR! at line 123: [E0002] Invalid mnemonic specification RSBX INTM". Why ?
perhaps the environment is disturbed ? If the version is too low to work
well,could I get free the high version ?

The following is the Version for each tools on the DSK:
TMS320C54x ANSI C Compiler Version 3.50
TMS320C54x ANSI C Codegen Version 3.50
C Source Interlister Version 1.20
TMS320C54x COFF Assembler Version 3.50
TMS320C54x COFF Linker Version 3.50

Please give me a answer as soon as possible ? Thanks a lot ! ---------------------------------




liang,

ther *must* be atleast one spoce after the first qoute in these statements
asm ("<space>nop<spcae>" );
i think it will work
derk -----Oorspronkelijk bericht-----
Van: liang mar [mailto:]
Verzonden: maandag 1 maart 2004 3:57
Aan:
Onderwerp: [c54x] how to embed assembly Hi:
I give my thanks to you at first.I did as your guides :Enable or Disable
the interrupt using the assembly statement in C enviornment on the " CCS DSK
C5000 1.22 " in the following :
#include <board.h>
#include <flash1.h>
void main (void)
{ asm("SSBX INTM");
.
.
.
asm("RSBX INTM");
.
.
.
}
but the bit "INTM" always could not be changed(through the register window)
and there is a error information when invoke the assembler (version
3.50) ---" ERROR! at line 123: [E0002] Invalid mnemonic specification
RSBX INTM". Why ? perhaps the environment is disturbed ? If the version is
too low to work well,could I get free the high version ?

The following is the Version for each tools on the DSK:
TMS320C54x ANSI C Compiler Version 3.50
TMS320C54x ANSI C Codegen Version 3.50
C Source Interlister Version 1.20
TMS320C54x COFF Assembler Version 3.50
TMS320C54x COFF Linker Version 3.50

Please give me a answer as soon as possible ? Thanks a lot ! --------------------------------- _____________________________________
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: Send an email to

To Post: Send an email to

To Leave: Send an email to

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

Other Groups: http://www.dsprelated.com

Yahoo! Groups Links


Liang-

> ther *must* be atleast one spoce after the first qoute in these statements
> asm ("<space>nop<spcae>" );
> i think it will work

Yes Derk is correct. Otherwise, the assembler will think that SSBX is a label:

SSBX: INTM
.
.

For the assembler, any non-comment text in column one is a label.

-Jeff

> -----Oorspronkelijk bericht-----
> Van: liang mar [mailto:]
> Verzonden: maandag 1 maart 2004 3:57
> Aan:
> Onderwerp: [c54x] how to embed assembly
>
> Hi:
> I give my thanks to you at first.I did as your guides :Enable or Disable
> the interrupt using the assembly statement in C enviornment on the " CCS DSK
> C5000 1.22 " in the following :
> #include <board.h>
> #include <flash1.h>
> void main (void)
> { asm("SSBX INTM");
> .
> .
> .
> asm("RSBX INTM");
> .
> .
> .
> }
> but the bit "INTM" always could not be changed(through the register window)
> and there is a error information when invoke the assembler (version
> 3.50) ---" ERROR! at line 123: [E0002] Invalid mnemonic specification
> RSBX INTM". Why ? perhaps the environment is disturbed ? If the version is
> too low to work well,could I get free the high version ?
>
> The following is the Version for each tools on the DSK:
> TMS320C54x ANSI C Compiler Version 3.50
> TMS320C54x ANSI C Codegen Version 3.50
> C Source Interlister Version 1.20
> TMS320C54x COFF Assembler Version 3.50
> TMS320C54x COFF Linker Version 3.50
>
> Please give me a answer as soon as possible ? Thanks a lot !



Dear Liang,
I think you must put a space before a assembly instruction. Only the labels in
DSP assembly can be written with no space in left. The assembly instruction must
be as the following format:
asm("<SPACE><Assembly Instruction>");

Best regards,
Morteza Alizadeh

liang mar <> wrote:
Hi:
I give my thanks to you at first.I did as your guides :Enable or Disable the
interrupt using the assembly statement in C enviornment on the " CCS DSK C5000
1.22 " in the following :
#include
#include
void main (void)
{ asm("SSBX INTM");
.
.
.
asm("RSBX INTM");
.
.
.
}
but the bit "INTM" always could not be changed(through the register window) and
there is a error information when invoke the assembler (version 3.50) ---"
ERROR! at line 123: [E0002] Invalid mnemonic specification RSBX INTM". Why ?
perhaps the environment is disturbed ? If the version is too low to work
well,could I get free the high version ?

The following is the Version for each tools on the DSK:
TMS320C54x ANSI C Compiler Version 3.50
TMS320C54x ANSI C Codegen Version 3.50
C Source Interlister Version 1.20
TMS320C54x COFF Assembler Version 3.50
TMS320C54x COFF Linker Version 3.50

Please give me a answer as soon as possible ? Thanks a lot ! --------------------------------- _____________________________________
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: Send an email to

To Post: Send an email to

To Leave: Send an email to

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

Other Groups: http://www.dsprelated.com

Yahoo! Groups Links
---------------------------------