Renesas TM V.3.20A Especificaciones Pagina 676

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 762
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 675
Renesas Technology, Tools FAQs
Last Updated: October 19, 2001
Document Number: 01100502_e
Q.
When I try to execute the instruction that sets the stack pointer with a step program, while using M38000TL2-FPD and M37531RSS
in combination, the emulator begins to malfunction, as shown below. Is there a work-around for this?
[Example]
------------------------------------------------------
C000 LDX #3Fh
C002 TXS ; Stack pointer setting
C003 LDM #C4,3Bh ; CPU mode register setting
C006 NOP
------------------------------------------------------
A.
In the emulator system, the user's stack pointer uses 3 bytes for step execution or user program execution/stop.
In the example program above, when the TXS instruction in line 2 is executed, the stack pointer temporarily indicates the SFR area
of M37531 (not the internal RAM area). Therefore, the emulator system cannot access the stack correctly and, as a result,
malfunctions.
To avoid this problem, set a break point at the location where the stack pointer setting is completed, and then execute the program
from that point. In the above example, the break point should be set at address C006, and then the program should be executed from
there. Once you have done this, there should be no problem in executing the step program.
In the actual MCU, this problem will not occur, as the stack will not be used when executing these instructions.
The following restrictions apply to the stack area in the emulator system. Please keep these in mind when debugging your program.
In this emulator, up to 3 bytes of the user stack is used as a work area.
If there is not enough user stack area available, areas that cannot be used for stack (SFR areas, RAM or ROM areas which are
storing data) will be used as the work area, which may cause problems in the user program or loss of emulator functions.
Therefore, always reserve the users stack area with 3 bytes more than the maximum amount used by the user program.
After reset, the emulator will use the addresses stored in the MCU file as the beginning of the stack area.
Top of Page | Back to Previous Page
Terms of Use Privacy Policy
(C)2004 Renesas Technology Corp., All Rights Reserved.
Vista de pagina 675
1 2 ... 671 672 673 674 675 676 677 678 679 680 681 ... 761 762

Comentarios a estos manuales

Sin comentarios