A89: Re: Exit routine


[Prev][Next][Index][Thread]

A89: Re: Exit routine




> HI
> I canīt exit my programme with RTS, I have to use Doors Esc+On to get back
> to doors!! What should I do ??? Is it because I have so many JSR and BRA
> that I donīt return to doors??
> Thanks asm people
> Javier

Check to make sure that the stack pointer (a7/sp) is the same as when you first
enterered the program at _main.
Most likely you've forgotten to restore it properly after a library call - the
ones that take arguments pushed onto the stack. They don't restore the stack
themselves.

 / Niklas Brunlid
Check out Prosit for the TI-89 / TI-92 Plus at http://c625.sparta.lu.se
Random PQF Quote follows:

"Have another drink, not-Corporal Nobby?" said Sergeant Colon unsteadily.
"I do not mind if I do, not-Sgt Colon," said Nobby.
        -- The joys of working undercover
           (Terry Pratchett, Guards! Guards!)




References: