PanuWorld's Emu48 utilities

Improve the daily user experience of your HP emulator

Those who have worked with HP's calculators e.g. during university studies, have serious problems in using traditional Windows calculator later when working on their computers at work or at home. The solution for this problem is to install the great HP48 (other models can be run, too) emulator on the PC, which allows using the efficient RPN logic when entering calculations. An quick launch shortcut for the emulator allows it to replace all other calculator programs in daily work.

Emu48 HP emulator official web site and download
Emu48 is heavily configurable, so please read carefully the installation instructions. Note especially that you will need a ROM file containing the internal code of the calculator you want to use. Read the documentation of Emu48 for details.

panuWorld's "Single-instance" launch script

A big problem in use of the Emu48 HP emulator as a general-purpose calculator is it's inability to reuse the emulator window, i.e. keep only one instance of the emulator running: Every time you double-click your shortcut to show your calculator, a new instance of Emu48 is started, and this new instance of the emulator cannot load your calculator state file because it is locked by the previous instance. This happens often when the calculator is hidden behind other windows during daily work — the shortcut always tries to start a new emulator instead of simply activating the existing calculator.

This file is missing or already loaded in another instance of Emu48.After accidentally trying to start a new instance of Emu48, the message This file is missing or already loaded in another instance of Emu48. is displayed. To get out from this situation, you need to click three times (OK—Cancel—Close) to close the new instance and then find the another calculator window somewhere.

To overcome this shortcoming of Emu48, I have written a short VBS script that automatically activates an existing instance of Emu48 instead of starting a new one. Of course, if no Emu48 is running, a new one is started.

Emu48 Single Instance Launcher
Copy the EMU48.vbs file to the installation directory of Emu48. Then change your calculator shortcuts to use this script instead of EMU48.EXE directly. The shortcut command line shall be: <path to Emu48 directory>\Emu48.vbs <calculator state file.E48>. Note that the name of the calculator state file is obligatory when using this script to launch the calculator.

McAfee VirusScan 8.0 users: If the script works slowly, disable the ScriptScan function or update your virus scanner.

The true solution would be adding a System topic in the Emu48's DDE interface that allows controlling the emulator with WM_DDE_EXECUTE: Then E48 files may be associated to force an existing Emu48 to load a new E48 file without starting a new Emu48 instance. Naturally such DDE command should also activate (and restore if minimized) the Emu48 window. Sending a DDE command to reload the currently open state file (that is, double-clicking a shortcut to an E48 file second time) should only bring the Emu48 window to foreground. This would be a nice new feature for Emu48, which still does not prevent multiple instances of the emulator when they are really needed.

PanuWorld's keyboard mapping for Hp48

The default keyboard mapping of Emu48 is not intuitive for all users. It tries to map the PC keyboard key combinations to the corresponding characters on the HP calculator. My approach is easier for heavy HP48 users: map the PC keys key-by-key to HP48 keys. For the numeric keypad and letter keys there is an evident association. The right-shift, left-shift, and alpha keys can be mapped to Ctrl, Shift and Tab keys on the left side of the PC key board, in the familiar order. ESC, Space, Delete, and Backspace can do the rest.

PanuWorld's HP48 keyboard mapping file for Emu48
Copy the KEYB-FI.KMI file to the installation directory of Emu48. To activate this keyboard map, replace the reference to the standard KEYBOARD.KMI by KEYB-FI.KMI in the KML file you are using. You may also copy the JEMAC-FI.KML script (which is the JEMAC.KML included in Emu48 distribution with reference to KEYB-FI.KMI instead of KEYBOARD.KMI) to the directory and activate it using the Change KML script... function of Emu48.
PanuWorld's primary key-to-key mappings (all HP48 keys, 49 pcs)
PC key HP48 key Note
0...9, +, –, Enter  0...9, +, –, ENTER  Both on the PC main and numeric keypad
×, ÷ ×, ÷ On the PC numeric keypad only
, . Comma on the PC numeric keypad
Space bar SPC
A...Z A...Z
Delete DEL
Backspace Backspace
Esc ON A.k.a. Cancel
Tab α Keep pressed or press once/twice like on the real calculator
Shift Keep pressed or press once like on the real calculator
Ctrl Keep pressed or press once like on the real calculator
 

Extra keyboard shortcuts (most of the remaining Finnish/Swedish PC keys)
PC key HP48 key Note
↑, ←, ↓, → K, P, Q, R PC arrow keys are same as K, P, Q, R
Menu L Windows context menu key
' ×
Use apostrophe key for × if no numeric keypad
§
÷
Use section key for ÷ if no numeric keypad
. . Full stop on the PC main keyboard
, ┐+. (,) Comma on the PC main keyboard
Å A, ┌+9 α-mode must be on; Shift+Å works also
Ä A, ┐+9 α-mode must be on; Shift+Ä works also
Ö O, ┐+9 α-mode must be on; Shift+Ö works also
< ┐+2 α-mode must be on
> (Shift+<) ┌+2 (LIBRARY) α-mode must be on
| (AltGr+<) ┌+J (MEMORY) α-mode must be on
¨ (accent key) ┐+9 The base letter must be typed first and α-mode must be on
^ (Shift+¨) ┐+8 The base letter must be typed first and α-mode must be on
~ (AltGr+¨) ┌+8 (PLOT) The base letter must be typed first and α-mode must be on
´ (accent key) ┌+7 (SOLVE) The base letter must be typed first and α-mode must be on
` (Shift+´) ┐+7 The base letter must be typed first and α-mode must be on
Home ┌+K (STACK) First line in HP48 menus
End ┌+Q Last line in HP48 menus
Page Up ┐+K Previous page in HP48 menus
Page Down ┐+Q (VIEW) Next page in HP48 menus
Insert ┌+α (ENTRY) Toggles insert/overwrite
 

Keyboard shortcuts for emulator functions
PC key Emu48 function Note
Ctrl+Insert Copy Stack MS-DOS keyboard shortcut for Copy
Shift+Insert Paste Stack MS-DOS keyboard shortcut for Paste
F1 About Emu48...
F12 Save Object...

This keyboard mapping file works also with other PC keyboards than Finnish/Swedish. However, there will be some irrationalities, especially at the punctuation keys. This is because Emu48 processes the PC keys by the positions on the keyboard, ignoring the characters printed on the keys (which vary depending on the keyboard language).

You may edit the mapping script to match better your non-Finnish keyboard. The script contains examples how to generate the HP48 key combinations and key sequences based on PC key combinations (compare script code to the table above). Some of them needed rather tricky KML scripting.
 
To see PanuWorld's finest appearance, update your web browser!