|
|
View previous topic :: View next topic |
Author |
Message |
Glazer. R Guest
|
OT: IAR compiler forum |
Posted: Tue May 24, 2005 12:56 am |
|
|
Dear all,
I am now using IAR benchmark compiler 3.30A for MSP430 series. I hardly found any technical forum for this compiler. If anyone happens to use this compiler before and know the sources, please recommend a few places i can turn to.
The problem i am facing is how to increment a 32 bit long variable using its assembly instruction. INC.
By using INC instuction, I can increase the 16bit time counter. But come to 32bit, it seems to have problem. Is it because INC instuction is only cater for up to 16 bit operand?
Sample code:
Code: |
EXTERN time_counter ;if define as 16 bit, working fine
TB0_INT ; when timeB 0 interrupts, increase time counter
INC &time_counter
RETI
|
|
|
|
future
Joined: 14 May 2004 Posts: 330
|
|
Posted: Tue May 24, 2005 1:16 am |
|
|
You will need to do like we do with the 8 bit micros.
Increment the variable, test for carry and increment the high byte if necessary.
I dont know asm for the msp...
IAR has a forum, almost empty, but still a forum. |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|