HCS08 and lauterbach debugger

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

HCS08 and lauterbach debugger

2,700件の閲覧回数
cris2pher
Contributor I
I'm a newbie in the use of both the lauterbach debugger and the HCS08 microprocessor.
Although I was able to connect the debugger to the HCS08 microprocessor, it is not operating properly.
When I do a step by step operation on the debugger, and a function call is performed, after processing the content of the function and an  RTS command is reached, the cursor of the debugger must return to the place where the function is called when the RTS command is processed. But this is not what happened. After processing the RTS command, the cursor goes to the address 0xFFFE which is the RESET interrupt vector. I already disabled the COP and the LVD. There is nothing connected on the RESET pin except the debugger. What do you think causes the cursor to go to the RESET interrupt? Please help me fix this. Thanks in advance. 
ラベル(1)
0 件の賞賛
返信
3 返答(返信)

816件の閲覧回数
Luigi
Contributor III
Also, be sure you are not "calling" an interrupt service routine (ISR), which returns with an RTI instead of an RTS.  Or, if your function is an ISR, be sure it is declared as an interrupt routine so the return will be correct.
0 件の賞賛
返信

816件の閲覧回数
rocco
Senior Contributor II
Hi, Christopher:

After the reset occurs, you can check the reset status register (SRS on the GBxx) to see the cause of the reset.

If the stack was corrupted, and it sent your code to never-never-land, the ILOP (illegal opcode) bit may be set.

HTH

Message Edited by rocco on 2007-04-2301:05 PM

0 件の賞賛
返信

816件の閲覧回数
tonyp
Senior Contributor II
>What do you think causes the cursor to go to the RESET interrupt?

Check your stack contents right before executing the RTS instruction.  Chances are you have corrupted your stack (or have unbalanced PUSH and PULL instuctions) and the return address pulled is garbage.
0 件の賞賛
返信