Buscar

emu50

Esta é uma pré-visualização de arquivo. Entre para ver o arquivo original

EMU48.EXE
EMU48.TXT
	Emu48 - A freeware HP38/39/40/48/49 Emulator
	 for Windows 9x, ME, NT, 2000 and XP
	********************
	* OPERATING SYSTEM *
	********************
This version of Emu48 should work with all Intel Win32 platforms. You may
recompile the sources to run Emu48 with Windows NT on a DEC Alpha.
	****************
	* INSTALLATION *
	****************
Emu48 is distributed in 1 archive:
- Emu48-1_35.zip		All files and sources
To install Emu48, just unzip Emu48-1_35.zip into an empty directory. When you
first run Emu48, it will detect the directory in which you installed it, and
will write its configuration to a file named Emu48.ini in your Windows
directory. If you move the Emu48 directory to another place you have to change
the directory path inside the Emu48.ini file manually or have to delete the
Emu48.ini file.
You can also update your current version with the Unofficial Service Packs:
- E48BP3x.ZIP			New EXE-File
- E48SP3x.ZIP			Sources of the Service Pack
Replace the original EXE file please.
	************************
	* YOU NEED A ROM IMAGE *
	************************
Emu48 needs an image of a calculator ROM to be able to run. Since fall 2000 the
emulator ROM's for the HP38, 39, 40, 48 and 49 are freely available on different
internet sites. Because there's no license for the distribution of the ROM
images, they aren't included in the Emu48 package. You can still use the classic
way extracting them from your own calculator. But in mostly all cases you have
to convert the ROM files into the Emu48 ROM format.
- HP38:
To upload the ROM of your HP38G, you will need a special aplet called "ROM
UPLOAD", available at http://www.epita.fr/~avenar_j/hp. Once you've uploaded the
ROM, you have to convert it using the Convert utility.
To do that, start a Command Prompt while running Windows, and type:
	Convert <rom-file> ROM.38G
Where <rom-file> is the path to your ROM image. This will create a file named
ROM.38G. This tool will also check its validity.
- HP39/40:
To upload the ROM of your HP39G/HP40G, you will need a special aplet called "ROM
UPLOAD", available at http://privat.swol.de/ChristophGiesselink/emu48.htm. Once
you've uploaded the ROM, you have to convert it using the Rom2emu utility.
To do that, start a Command Prompt while running Windows, and type:
	Rom2emu <rom-file> ROM.39G
There's also a HP39G/HP40G beta ROM for emulators at
http://www.epita.fr/~avenar_j/hp/39.htm for download.
- HP48:
If you have already used another HP48 emulator, you can convert the ROM using
the Convert utility.
To do that, start a Command Prompt while running Windows, and type:
	Convert <rom-file> ROM.48G
or	Convert <rom-file> ROM.48S
Where <rom-file> is the path to your old ROM image. This will create a file
named ROM.48G or ROM.48S, depending on the version you own. This tool should be
able to read any style of ROM image, and will also check its validity. Note that
if you run it with only one parameter, no file will be written, but it will
still check the validity of the ROM.
If you have never used an HP48 emulator, and don't have a ROM dump, you can
either use Jean-Yves Avenard's ROMUPL.BIN or the ROMDump Wizard V1.x, which will
almost automatically get the ROM from your HP48. After the download you may have
to convert your dump with the CONVERT utility into the Emu48 format.
You can find the latest version of the ROM dump programs on:
ROMUPL.BIN	http://www.epita.fr/~avenar_j/hp/calcen.html
ROMDump Wizard	http://privat.swol.de/ChristophGiesselink/index.htm
- HP49:
There's no ROM download program available so far. But you can find a HP49G ROM
for emulators in the YorkeM emulator package or in the HP49G SDK on
http://www.hpcalc.org in the HP49 section.
	****************
	* HOW TO START *
	****************
When Emu48 is installed and you have put the ROM image(s), which must be in the
Emu48 ROM format, into the Emu48 directory, you can start Emu48. You'll see a
"Choose Your KML Script" box.
KML Scripts in fact define the visual aspect of Emu48, the behavior of the
buttons, of the keyboard, ... It's a GREAT way to customize your copy of Emu48.
Check that the path in the "Emu48 Directory" text area is correct. Modify it if
the directory in which you installed Emu48 is not the directory displayed. Click
the refresh button ("V") after modifying it to update the list box or use the
("...") button to start the directory browser.
Choose a KML script in the list box for your calculator ROM you put into Emu48's
directory.
Several HP48 scripts are included in the Emu48 archive:
 * Emu48's Default Faceplate for HP48G/GX
 * Emu48's Default Faceplate for HP48S/SX
	These two are simple scripts, good for 800x600 display resolution.
 * Casey's Gx with Toolbar and Touch Screen
 * Casey's Sx with Toolbar and Touch Screen
	These script uses many advanced features, and is a good demonstration of
	the power of Emu48's scripting language KML. Try it, it is really great!
 * Floating buttons
	This one looks really great.
 * Small but realistic HP48 Gx
	This one has been designed for small resolutions such as 640x480.
	Note: some things in this script have to be fixed.
If you want other great scripts, visit Rechlin's great HP archive
	http://www.hpcalc.org/
And if you are interested in writing new scripts, get the KML 2.0 documentation
from Christoph's page at http://privat.swol.de/ChristophGiesselink/emu48.htm
Once you have selected a script, press OK to start the emulator. In most cases,
when Emu48 crash after pressing the OK button, you forgot to convert the ROM
image into the emulator format. While it's running, you can use the View/Change
KML Script... command to change the visual aspect of Emu48.
	***************
	* KML SCRIPTS *
	***************
Don't use TRUELCD.KMI for emulating display contrast in your scripts. It's not
fully correct. The hardware contrast values are in the area from 0 to 31. But
the ROMs bounds them to useful values. The HP48 S(X) ROM use only display
contrast values between 3 and 19 and the HP48 G(X) ROM values between 9 and 24.
Maybe you have to adjust the "Rom" filename in the "Global" section. This mostly
happen with the HP49G ROM name. Some KML files use the name ROM.E49, that's the
name of the emulator ROM file published by HP. But Emu48 state files for the
HP49G have the same file extension, so the use of ROM.49G is preferred now.
	****************
	* COMMAND LINE *
	****************
The command line syntax is "Emu48 [E48file [Port2file]]". The first parameter
sets the filename for the emulation data, the second parameter the Port2 file.
You're not able to set a Port 2 file without setting the emulation data file.
The arguments are optional.
	*******************
	* LOAD/SAVE FILES *
	*******************
There are two ways to transfer files from or to the emulator. The one way is to
use the serial port to transfer the data directly from your HP to the emulator.
The second way is to load data, saved on your PC, into the stack of the
emulator. You can do this by using the Edit/Load Object... command or with the
file Drag and Drop feature. But there's one important restriction, the data must
a HP binary file (begin with HPHP48- or HPHP49-, this depends on your emulated
calculator)! If not, the data is load as string. The Edit/Save Object... command
will save the data in stack level 1 on the PC (always binary mode). Be sure,
when you use the second way for data transfer, that no program is running on the
emulator. The second way doesn't work on a HP38, because he has no stack. So you
can load aplets only from the serial port.
	*****************
	* DRAG AND DROP *
	*****************
Dropping HP objects over the emulator window will load program files (like the
command "Load object...") on the stack. Be sure that the emulator isn't
busy
before doing this.
	*******************
	* SHARED RAM CARD *
	*******************
You can add a SHARED (explained below) RAM card of up to 4MB to a HP48. By
default, no such card will be created when you start Emu48. The MkShared.exe
utility will allow you to create it.
To create a Port 2 RAM Card, call the program, select the RAM Card size, enter
the card file name and press the 'Create' button. That's it. Please remember,
this program replace the destination file without any request!
If you use RAM cards greater than 128 KB in a HP48SX, you can only see the first
128 KB of the card. Please remember, the firmware of all HP48GX versions has a
bug when using a 4MB RAM card. You always get the message "Warning: Invalid Card
Data" at startup and Port 33 is unaccessible. This is not a bug of the emulator!
When you have created this file, run Emu48, and use the Close menu item to close
the calculator state. Now select File/Settings. In the "Port 2" text area, type
the name of the file you created (if you don't include a path, it will be
searched for in Emu48's directory).
You can also tick the check box "Port 2 Is Shared". When the box is cleared,
only the first instance of Emu48 will allow you to use the RAM card in Port 2.
When this box is checked, the first instance of Emu48 will give you both read
and write access to this RAM card. If you start Emu48 in another instance, the
RAM card in Port 2 will be write-protected. Thus you can transfer files very
easily between two calculators. This RAM card is used by both S/SX and G/GX
types.
	***********************
	* FLASH ROM EMULATION *
	***********************
The HP49G save the operation system in a reprogramable memory, a so called flash
memory. The flash memory is divided into two parts, into the Operating System
and into a User Data area. The User Data area is viewed as Port 2 in the HP49G.
Emu48 saves the Port 2 data in the ROM file (normally ROM.49G). As default
setting the ROM file is writeable in the first instance of Emu48. When you open
another instance of a HP49G emulation the Port 2 area is READ ONLY, that mean
all changes in Port 2 are lost when you exit this instance. If you don't want to
save data in Port 2 and want to protect the operating systems from overwriting,
you're able protect the ROM file. To do this, close all Emu48 instances and set
the variable 'Writeable' defined in the Emu48.ini file, section [ROM] to zero.
	***********************
	* COPY / PASTE STRING *
	***********************
With the menu items "Copy String" and "Paste String" in the "Edit" menu you're
able to copy HP string objects from the stack to the PC clipboard and vice
versa.
	**********
	* BACKUP *
	**********
Emu48 includes a backup feature (in the Edit menu). It save the complete state
of the calculator (excepting the ROM and Port 2 content) in the computer's
memory. You might want to use it before doing something risky, and if you don't
want to save to the disk. It provides some kind of Undo feature. It is also used
by Emu48 when you want to save or load a new document, to restore its old state
if you cancel the operation or of something goes wrong.
	************
	* KEYBOARD *
	************
To enter a character to the emulator use the PC keyboard (key translation
depends on the used KML script) or the mouse. If you press the left mouse
button, the emulator key is pressed as long as you press the mouse button or
leaving the area of the emulator button. Sometimes you need to press more then
one key (contrast setting, warmstart, ...). To do this, press the right mouse
button. All "locked" buttons are released after enter a key with the left mouse
button.
	*********
	* CLOCK *
	*********
The emulator time is synchronized with the PC time at startup of the emulator.
This may cause problems with other non original operating systems running on the
HP. On HP48 S(X) calculators the address area #00052-#00070, on all other
emulated calculators the address area #00058-#00076 in System RAM are rewritten
with the actual time information.
	*************
	* EMU48.INI *
	*************
The section [Timers] in the Emu48.ini file isn't used any more. The variable
values are replaced by useful constants. You may delete this section if you
want. Starting an old version of Emu48 (V1.07 and earlier) will add this section
again. If you move the Emu48 directory to another place, you have to adjust the
variable 'Emu48Directory' in the [Files] section.
	************************
	* REAL SPEED EMULATION *
	************************
As you recognized the speed of the emulated HP is much faster than an original
one. The reason is, the assembler commands are emulated faster than the original
CPU can execute them. On one side this is a big advantage (faster execution of
programs) on the other side this cause many trouble. In Emu48 only the timers
work with the original speed. In result all commands like User-RPL WAIT wait
more or less the correct time. But many programs like shells or editors use an
own key handler to realize an autorepeat implementation. Normally these programs
use the execution time of each assembler command for waiting. On Emu48 this time
is much shorter, so the time between each key read is shorter as well and you
get a very fast key repetition. The editor ED from the JAZZ package hasn't this
problem, because the key input is synchronized with one of the timers. To solve
this problem Emu48 generally slow down emulation if a key is pressed. To solve
some other speed depending problems you are able to slow down the whole
emulation speed. There are two variables 'SXCycles=82' and 'GXCycles=123'
defined in the Emu48.ini file, section [Emulator] which control the "real" speed
and key repetition slow down for each calculator type. Each numeric value is
representing the allowed CPU cycles in a 16384Hz time frame. Because the used
cycle statements (from SASM.DOC) in Emu48 doesn't correspond to the real values
of the CPU, the saved values are estimated by comparing the execution time of a
program to the real calculator. Increasing the value fitting to your ROM will
make the "real speed" HP faster and vice versa. No warranty to the functionality
of Emu48 when you go below the default values.
	*************************
	* SERIAL PORT EMULATION *
	*************************
The serial ports are emulated as well now. You may choose the same serial port
for wire and IR. Remember that the IR port only work with 2400 Baud. If you want
to change the serial port settings, but they are disabled, close the serial port
with the command CLOSEIO or power cycle the HP first.
Now it's possible to make transfers between the real calculator and Emu48. If
you have problems with the connection please try the following. There's a simple
way to check if your serial port is used by another program. First disable the
serial settings in both combo boxes and very important close the settings
dialog. Reopen the settings dialog and choose the COM port in the wire combo box
to the port the HP is connected with. When you open this combo box you only see
valid (unused) serial ports. Don't use the IR combo box, it only works with 2400
Baud. The next important thing are the serial settings of the real calculator
and Emu48, they must be equal. If this doesn't work then mostly there's a
hardware or a resource problem of the serial port. Check this with connecting
the HP with a transfer program you like on the same serial port.
	****************
	* DISASSEMBLER *
	****************
With the internal disassembler you're able to disassemble the Saturn chip
address area. With the default Map setting the disassembler always see the
mapped memory address. If for example you configured the RAM at #00000 you will
see the RAM and not the ROM at this address. With the other module settings you
specify a special module for
disassembly. Each module use a linear address mode,
beginning at address #00000 and will not overlapped by other modules. So, for
example, you can access the second port of a HP48 RAM card greater than 128KB at
address #40000 (128 * 1024 * 2). The "Copy Data" button copies the selected
disassembler lines to the PC clipboard.
	**************
	* DDE SERVER *
	**************
I implemented a DDE server in Emu48 to transmit data from and to the HP stack
with DDE. You have the same restrictions like with the commands "Load object..."
and "Save Object...", that a running program may corrupt memory. Take care to
transmit data only after the acknowledge of the last DDE transaction.
Technical data:
Servername: Emu48
Topicname: Stack
Item: - (ignored, must be a nonzero string)
Clipboardformat: "CF_HPOBJ" (user defined)
The DDE commands CONNECT, POKE and REQUEST are supported.
The structure of the clipboard format "CF_HPOBJ":
+--------+------------------------------------+
| 4 Byte | HP object |
+--------+------------------------------------+
 \ \
 \ +--- normal HP object
 +----------- length of object (LSB first)
	********************
	* TROUBLE SHOOTING *
	********************
Visit the Emu48 FAQ site at http://privat.swol.de/ChristophGiesselink/index.htm
to get more information please.
	***********
	* SUPPORT *
	***********
We cannot provide any individual support for Emu48. All informations about Emu48
will be on the Emu48 Official Homepage on the Web:
	http://www.epita.fr/~sebc/Emu48/index.html
or on the Emu48 FAQ at
	http://privat.swol.de/ChristophGiesselink/index.htm
	***************
	* LEGAL STUFF *
	***************
Emu48 - An HP38/39/40/48/49 Emulator
Copyright (C) 2005 Sebastien Carlier & Christoph Gießelink
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation; either version 2 of the License, or (at your option) any later
version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc., 59 Temple
Place, Suite 330, Boston, MA 02111-1307 USA
	***************
	* The Authors *
	***************
Paper Mail:
	Sebastien Carlier
	10 Allee des bergeronnettes
	35340 LIFFRE
	FRANCE
E-Mail:
	sebc@epita.fr
Homepage:
	http://www.epita.fr/~sebc/Emu48/index.html
Paper Mail:
	Christoph Giesselink
	GERMANY
E-Mail:
	c dot giesselink at gmx dot de
Homepage:
	http://privat.swol.de/ChristophGiesselink/index.htm
EMU48PLUS.TXT
Emu48 1.42+
Emu48+ is a modified version of Emu48 to add support for the ARM-based 
calculators. It does not emulate the ARM CPU, but it enhances the 
Saturn emulation to more closely match the emulation provided by the 
Saturn emulator on the ARM-based calculators.
Emu48+ adds support for many of the Saturn+ instructions, including 
some of the BUSCC instructions, and it also adds support for the 80-line 
display used on the 49G+ and 50G.
At present, the additional calculators supported in Emu48+ are the 
49G+, 48GII (hardware revision 1), 50G, and 39G+.
To create KML scripts for the additional calculator models, use the 
following model codes:
39G+: Model "P"
49G+: Model "Q"
48GII: Model "2"
50G: Model "Q"
 Class 50
Most of the code that was changed in Emu48+ over Emu48 was provided by
Cyrille de Brebisson of Hewlett-Packard.
PROBLEMS.TXT
Known bugs and restrictions of Emu48 V1.42
------------------------------------------
- the following I/O bits aren't emulated (incomplete)
 DTEST (0x102) [VDIG LID TRIM]
 DSPCTL (0x103) [LRT LRTD LRTC BIN]
 LPD (0x108) [LB2 LB1 LB0 VLBI]
 LPE (0x109) [ELBI EVLBI GRST RST]
 CMODE (0x10A) Mode register
 IOC (0x110) [ERBZ]
 RCS (0x111) [RX RER RBZ]
 SRQ1 (0x118) [ISQR VSRQ]
 SRQ2 (0x119) [LSRQ]
 IRC (0x11A) [IRI EIRU EIRI IRE]
 LCR (0x11C) [LED ELBE LBZ LBF]
 LBR (0x11D) [LBO]
- the baudrates 1920, 3840, 7680 and 15360 aren't emulated on most
 operating systems
 Windows 95a 1920, 3840, 7680 work, 15360 fail
 Windows 98, NT4.0, 2000, XP all baudrates fail
- problems when receiving a break signal on the serial port
 Windows 98, NT4.0 SP4 no retrigger on port open
 Windows 98 timing problems setting the RER bit
 Windows 2000 SP2 no known problems
- System-RPL commands VERYVERYSLOW, VERYSLOW and SLOW depends on PC
 speed (are realized as simple down counter in ROM)
- display updating differs from the real machine
- screen VBL counter values may skip after large display operations
 like turning on or updating the whole display
- executing an opcode over a MMU boundary will fail
- read on an unconfigured address (open data bus) will not show the
 same value like a real calculator
- the Yorke hardware signals BEN and DA19 aren't fully supported,
 because the emulator don't use a multiplexed AR18 / NCE3 data line
 -> all programs that run on a real calculator will run as well,
 programs with incorrect DA19 / BEN handling may run on the
 emulator but will crash on a real calculator
- incomplete reset logic of the bank switcher FF, on real
 calculators a reset happen after about 4s in deep sleep, in the
 emulator this happens immediately
- no MP interrupt on card control circuit or timer restart
- no beeper support with OUT command -> all programs that aren't
 use the "=makebeep" subroutine, like alarm wake up, have no sound
- beeper emulation, ATTN key doesn't work
- no infrared printer support
- Shell OS: clock isn't synchronized with real time
- HP49G: the flash memory is emulated now with some restrictions
 - no flash programming times, the flash state machine returns
 immediately the ready signal
 - only one write buffer, second not needed because of prior reason
 - not fully tested, especially the status byte may return
 incorrect values (error bits)
 - quitting the emulator while programming the flash isn't allowed,
 because the content of flash state machine isn't saved so far
08/22/06 (c) by Christoph Gießelink, c dot giesselink at gmx dot de
real50g.bmp
real50g.kml
ROM.50G
DEBUGGER.TXT
Debugger in Emu48/Tools/Debugger...
-----------------------------------
This is a short description of the internal assembly debugger of Emu48.
The debugger was designed to help customers inspecting assembler code objects, a part that cannot be handled satisfactorily by the JAZZ package. Thanks to Mika Heiskanen and all the others supporting this great program.
After starting the debugger the emulation will stop at the current program counter position. The emulation will continue after closing the debugger window. Please remember that the clock now shows the wrong time.
1.) Menu Debug
- Run F5
Continue calculator emulation under debugger control. The emulation will stop at a breakpoint. Please remember that the emulation speed is slower than without debugger control.
- Run to Cursor F6
Execute program until address at cursor position is reached. Breakpoints are still active and may stop execution before.
- Step Into F7
Execute one code instruction.
- Step Over F8
Execute a GOSUB, GOSUBL or GOSBVL as one instruction. Normally the instruction cursor will set to the position behind the GOSUB instruction.
But this makes trouble in the following code part:
 GOSUB +
 NIBASC /Hello world/
+ C=RSTK
The program counter will never
reach the address behind the GOSUB instruction. The debugger solve this problem by breaking the emulation when the stack has the same level before the GOSUB instruction. In this example the single step execution will continue after the C=RSTK instruction.
- Step Out F9
Continue the program until a RTI, RTN, RTNC, RTNCC, RTNNC, RTNSC, RTNSXN, RTNYES instruction is found above the current stack level.
At some code constructions (mostly used to save space on the hardware stack) like
 C=RSTK
 PC=C
and
 C=RSTK
 RSTK=C
 RTN
the stop address will be wrong. The problem in both code fragments is the C=RSTK opcode. In the first example there is no RTN instruction to stop. In the second one the C=RSTK instruction purge the original return address and then the RSTK=C instruction is interpreted as a GOSUB instruction.
In opposite the following code will work fine:
 RSTK=C
 ..
 code <- F9 was pressed here
 ..
 GOSUB -
 C=RSTK
 RTN <- emulation will stop after this instruction
- RTN
So be careful using the F9 key.
- Break F11
Stops the emulation at the current program counter position.
2.) Menu Breakpoints
- Set Breakpoint F2
Toggle a code breakpoint at the cursor position in the Code window.
- Edit Breakpoints...
You get a sorted list of all current breakpoints. When the breakpoint is checked it's enabled otherwise it's disabled. With "Add" you can add a new or enable an existing breakpoint, with "Delete" you can delete the selected ones. Addresses greater than #FFFFF are cut after the fifths nibble. When adding a new breakpoint, you must select if this is a "Code", "RPL", "Memory Access", "Memory Read" or "Memory Write" breakpoint.
 - "Code" stop before opcode execution on this address
 - "RPL" stop on the first opcode of the selected RPL address
 - "Memory Access" stop before reading or writing to the selected address
 - "Memory Read" stop before reading the selected address
 - "Memory Write" stop before writing to the selected address
With a left mouse button double click on a breakpoint you can toggle the check box inside. When you use the space key instead, on all selected breakpoints the check box is toggled.
- Clear All Breakpoints
Clear all address specific breakpoints.
- NOP3 Code Breakpoints
What are NOP3 code breakpoints? As you know user programs are loaded somewhere in memory and can be moved after a garbage collection. So it's very difficult to break a user program at a hard set breakpoint with F2. To solve this problem the debugger will stop emulation at a NOP3 opcode. So you can easily add a NOP3 command into your sources to force a break condition. To enable this you have to check this item.
NOP3 and NOP3, what's the difference? The Saturn CPU has no NOP command, so NOP3 is an opcode that is three nibbles long and doesn't change a register. In the HP SASM.DOC document two different opcodes are defined for NOP3:
 Opcode 820 for HST=0 0
and
 Opcode 420 for GOC + (next line)
In the assembler of the HPTOOLS 3.x package NOP3 is defined as opcode 820. The advantage of the opcode is that the execution time is always the same, independent from the carry flag. This code is used in the HP48 ROM as well. So I decided to use the GOC opcode for a code breakpoint condition.
A short example how to use a NOP3 Code breakpoint:
ASSEMBLE
 NIBASC /HPHP48-E/
BREAK MACRO
 CON(3) #024 NOP3
 ENDM
RPL
CODE
 BREAK code breakpoint
 GOSBVL =SAVPTR save register
 GOSUB + problem for step over
 NIBASC /Hello world/
+ C=RSTK
 GOVLNG =GETPTRLOOP
ENDCODE
- CODE Object Breakpoints
If this item is checked, the debugger stops program execution at the first instruction of every DOCODE object which isn't located in ROM. For inspecting DOCODE objects in ROM use address CODE breakpoints instead please.
- RPL Breakpoints
If this item is checked, the debugger stops program execution on every instruction called after a PC=(A) or PC=(C) opcode. This is normally the begin of a new RPL command. RPL breakpoints use a "-R" marker instead of the assembler "->" PC position marker.
3.) Menu Interrupts
- Step Over Interrupts
If this item is checked, interrupt handler code will be skipped. This option is useful when you don't want to debug the interrupt handler. But be careful, when you disable the interrupts all code until interrupt enable belong to the interrupt handler code and couldn't executed in single step any more. Enabled breakpoints are still active.
You can also use this option if you want to quit the interrupt handler. Just check this option, press F7 for "Step Into" for stopping the debugger behind the RTI instruction, and uncheck this option again.
4.) Menu Info
- Last Instructions...
This is a short viewer for the last 255 executed CPU addresses. The disassembled opcode maybe wrong, because only the CPU address of each command was saved and memory mapping may have changed meanwhile. In the "Last Instructions" dialog you can copy selected lines to the clipboard or clear this list.
- Profiler...
This opens a small toolbox window which shows the number of CPU cycles and the corresponding execution time of the instruction sequence between the last two breakpoints. The CPU cycles are only approximate values, the real cycles are depending mostly on the used ROM to Saturn CPU core interface.
- Write Only Registers...
Some of the display registers have a different meaning on reading and writing. This dialog shows the data written to the write only I/O registers.
5.) Code window
This windows shows you the disassembled code. The line with the current PC is marked with a "->" or "-R" between the address and the disassembly.
You can use the UP, PAGE UP, DOWN and PAGE DOWN keys to scroll the window content. There is one strange behavior, when you move to higher addresses the debugger is able to disassemble the next line correctly, but when you move to cursor to lower addresses the debugger does not know if this address is at the begin or inside of an opcode. In result you get wrong disassembled lines.
Context menu pressing the right mouse button:
- Go to address... G
Moves the cursor to the specified code address.
- Go to PC
Sets the cursor to the actual position of the PC.
- Set breakpoint F2
Toggle a code breakpoint at the cursor position in the Code window.
- Set PC to selection
Set the PC to the cursor position. Be careful with this command, you change the execution order of the commands!
6.) Register window
Here you can see the actual contents of the CPU registers. The values are only updated at a program execution stop. All changed CPU registers are highlighted.
With the left mouse button you change the content of the register. On bit registers, like CY and Mode, the state change immediately without any request.
7.) Memory window
This windows shows the memory content in the selected context.
You can use the arrow, PAGE UP and PAGE DOWN keys to move the cursor to a memory position. With a double click on the left mouse button (only in Map mode) you can change the content of the two addresses. When the memory position is read only (ROM or write protected RAM) the content wouldn't change.
Context menu pressing the right mouse button:
- Go to address... G
Moves the cursor to the specified memory address.
- Go to PC
Sets the cursor to the actual position of the PC.
- Go to D0
Sets the cursor to the actual position of the D0 register.
- Go to D1
Sets the cursor to the actual position of the D1 register.
- Go to Stack
Sets the cursor to the return address placed in the top level of the stack.
- Follow
Follow is a Pop-up menu to change the
address behavior of the memory window. Normally the address of the memory window is static and only change by entering a new address. With Follow the memory window view follow the content of a selected address or register. In follow mode the memory window is only updated after an emulation step.
- Follow none
This is the default mode. The address of the memory window is static.
- Follow Address Content
This is a special mode of indirect addressing. You can specify an address which content will we interpreted as memory pointer. The memory window follow this memory pointer.
- Follow Register PC/D0/D1
The memory window follow the content of the selected register.
- Find... F
Calls the "Find" dialog box, allowing you to search for a data sequence in hexadecimal or ASCII mode. The search area is selected by the memory view Mapping mode described in the following section. When you close the "Find" dialog box, you will loose all saved strings in the data combo box.
- Mapping
Mapping is a Pop-up menu to select the memory view of the Memory window. Normally the CPU see only 512KB of the total memory, the rest is banked or covered by other modules. The following menu entries select the memory chip connected with the chosen Chip Select signal of the MMU. The connections are calculator model dependent.
- Mapping Map
This is the default mode. Here the Memory window shows what the CPU see. In this mode you can also change the memory content of writeable memory.
- Mapping NCE1/NCE2/CE1/CE2/NCE3
Here the Memory window shows the content of the selected Chip Select signal. The content is showed in a linear address model and it's content can't be changed in this mode.
Here's a comparison of the mapping of the emulated calculator models:
Abbreviations: ROM = Read Only Memory
 RAM = Random Access Memory
 Flash = electrical reprogramming ROM
 Slt = Memory Card Slot
 BS = Bank Switcher (no memory)
 nc. = not connected
 | HP38G | HP39/40G | HP48S/SX | HP48G/G+/GX | HP49G
-----------------------------------------------------------------------------
NCE1 | ROM 512KB | ROM 1024KB | ROM 256KB | ROM 512KB | Flash 2048KB
NCE2 | RAM 32KB | RAM 128KB | RAM 32KB | RAM 32/128KB | RAM 256KB
CE1 | nc. | BS | Slt1 32/128KB | BS | BS
CE2 | nc. | nc. | Slt2 32/128KB | Slt1 32/128KB | RAM 128KB
NCE3 | nc. | RAM 128KB | nc. | Slt2 32KB-4MB | RAM 128KB
8.) Stack window
The content of the hardware stack is viewed here. In "1:" is the current return address. A double click on an item shows the address content in the Code window.
Context menu pressing the right mouse button:
- Push
Push a new element before the current selection onto the stack.
- Pop
Pop the selected element from the stack.
- Modify
Modifies the stack content of the current selection.
9.) MMU window
The configuration of the memory controllers is viewed here. The viewed addresses are the first address of each module area and may differ from the given address in the CONFIG command.
This example
 LC(5) #C0000 128KB size
 CONFIG
 LC(5) #98765 start address of module
 CONFIG
will config a 128KB module at address #80000 and not at the given address. So the MMU viewer will show you the address #80000.
10.) Miscellaneous window
The Miscellaneous window show you the internal state of the interrupt flag, the 1ms keyboard handler and the contents of the Bank Switcher latch. The Bank Switcher item is only enabled on calculators with a latch inside. You see the loaded value of the address lines A6-A0. You have to ignore the last bit (A0), because it isn't wired to the six bit latch.
You can change the values by pressing the left mouse button over the old content.
02/24/06 (c) by Christoph Gießelink

Teste o Premium para desbloquear

Aproveite todos os benefícios por 3 dias sem pagar! 😉
Já tem cadastro?

Outros materiais