Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
01/06/07 22:46
Read: times


 
#130409 - mov SP,STACK
Responding to: ???'s previous message
iseg isn't recognized by the keil evaluation assembler that comes with the SiLabs eval board.

Which version of A51.exe?
V7.04a included in SiLabs eval correctly recognizes 'ISEG' directive.

I suppose the error is not in ISEG, but in this line.
mov SP, STACK

As the 'STACK' is a label, '#' is required to represent its address, instead of its contents. And stack pointer is set to less value by one than actual stack area address, because PUSH instruction increments SP before storing the operand.

PUSH operation:
(SP) <- (SP) + 1
((SP)) <- (direct)

So, try this.
    iseg AT 80h 
STACK: ds 64 
. 
. 
. 
    mov SP, #STACK-1


Tsuneo

List of 8 messages in thread
TopicAuthorDate
iseg?/upper 128 bytes of RAM            01/01/70 00:00      
   examine startup.A51            01/01/70 00:00      
      In Response to Tsuneo            01/01/70 00:00      
         mov SP,STACK            01/01/70 00:00      
            In Response to Tsuneo            01/01/70 00:00      
               Surely, SiLabs assembly.ini is incorrect            01/01/70 00:00      
   using upper 128 bytes for stack            01/01/70 00:00      
      In Response to D.c. Van Warendorp            01/01/70 00:00      

Back to Subject List