Emu28 Changelog

What's new in Emu28 1.37

May 23, 2023
  • DISPLAY.C
  • Changed function CreateLcdBitmap(), call function
  • CreateAnnunBitmapFromMain() to create a pure B&W annunciator bitmap
  • Added new function CreateAnnunBitmapFromMain(), create a B&W
  • annunciator bitmap from background bitmap
  • DISRPL.C
  • Changed function PutSn(), BINx(), DoSemiStream(),
  • RplDecodeObject() and RplCreateObjView(), added error handling for
  • memory allocation failed
  • EMU28.C
  • Changed function WinMain(), added disable of TIMER_RESOLUTION
  • throttling for Windows 11 and added a more flexible CPU binding
  • for the Saturn core emulation thread on Windows Vista and later
  • with function GetCurrentProcessorNumber()
  • EMU28.DSP
  • Added pngcrc.c sources
  • Added "LODEPNG_NO_COMPILE_CRC" to lodepng.c definitions
  • EMU28.H
  • Extern declaration of global function
  • EMU28.RC
  • Changed version and copyright
  • FILES.C
  • Renamed pbySignature[] to bySignature[] and defined signature as
  • constant
  • Added function UnpackRom(), subroutine for unpacking ROM image
  • Changed function MapRom() and MapRomBmp(), speed optimization
  • unpacking ROM image using UnpackRom()
  • Changed function NewDocument(), SaveBackup(), RestoreBackup() and
  • CreateRgnFromBitmap(), added error handling for memory allocation
  • failed
  • Changed function OpenDocument(), simplified file signature check
  • Changed function SaveDocument(), adjusted to bySignature[]
  • KML.C
  • Made pAnnunciator variable public
  • Changed function AddToLog(), optimized implementation
  • Changed function DestroyKmlList(), minor optimization
  • Changed function CreateKmlList(), added error handling for memory
  • allocation failed
  • Changed function ParseString(), optimized memory allocation and
  • added error handling for memory allocation failed
  • Changed function ParseLine(), ParseLines() and ParseBlock(),
  • added error handling for memory allocation failed
  • KML.H
  • Added extern declaration of variable pAnnunciator
  • LODEPNG.C
  • Changed implementation file to LodePNG version 20230410 with
  • unmarked typecast patches for x64 compatibility, Copyright (c)
  • 2005-2023 Lode Vandevenne
  • LODEPNG.H
  • Changed header file to LodePNG version 20230410
  • PCH.H
  • Added definitions, emum and struct for calling function
  • SetProcessInformation()
  • PNGCRC.C
  • New module for generating the PNG CRC32 replacing the CRC
  • generation in LODEPNG.C
  • UDP.C
  • Replaced static IN_ADDR by SOCKADDR_IN structure
  • Changed function ResetUdp(), invalidate IP address inside
  • SOCKADDR_IN structure
  • Changed function SendByteUdp(), replaced local SOCKADDR_IN
  • by the global static SOCKADDR_IN structure

New in Emu28 1.36 (Mar 23, 2022)

  • DISPNUM.C:
  • new module for decoding text in the LCD, non displayable
  • characters are shown as MIDDLE DOT U+00B7 now
  • EMU28.C:
  • changed function SaveChanges(), added document name to MRU list
  • changed function OnFileMruOpen(), modified implementation taking
  • care of the SaveChanges() modification adding a filename to the
  • MRU list after saving a document
  • changed function OnViewCopy(), get display text now
  • EMU28.DSP:
  • added dispnum.c sources
  • EMU28.H:
  • changed function prototype
  • extern declaration of global functions
  • EMU28.RC:
  • changed version and copyright
  • FILES.C:
  • changed function DibNumColors(), CreateBIPalette() and
  • DecodeBmp(), marked BITMAPINFOHEADER pointer as unaligned
  • changed function CreateBIPalette() and DecodeBmp(), minor
  • optimization at input data check
  • changed function DecodePng(), simplified destination row pointer
  • calculation in main loop and removed dead code in function
  • cleanup
  • LODEPNG.C:
  • changed implementation file to LodePNG version 20220109 with
  • unmarked typecast patches for x64 compatibility, Copyright (c)
  • 2005-2022 Lode Vandevenne
  • LODEPNG.H:
  • changed header file to LodePNG version 20220109
  • MRU.C:
  • added some remarks
  • added function MruID(), return ID of the given entry
  • changed function MruFilename(), changed function interface writing
  • found filename into a buffer instead of returning a pointer to the
  • filename
  • PCH.H:
  • added CLL macro
  • added __unaligned definition for MSVC6.0 SDK and earlier
  • STEGANO.C:
  • added support for 3 bit/byte encode/decode
  • added function CodingLength(), calculate the number of necessary
  • pixel channels to encode the input data with a given bit/byte
  • setting
  • bugfix in function SteganoDecodeDib(), bitmap size check was
  • incomplete, so a buffer overrun was possible
  • STEGANO.H:
  • added config for disabling 3bit/byte encoding

New in Emu28 1.35 (Aug 25, 2021)

  • DEBUGGER.C:
  • Bugfix in function EnterBreakpoint(), returned an uninitialized address value on empty breakpoint edit control
  • Bugfix in function OnDrawBreakWnd(), modified implementation and fixed background color of highlighted selection
  • DISASM.C:
  • Bugfix in function disasm_1() and disasm_8(), fixed decoding of r=ss, ss=r and rssEX with ss = 5, 6, 7, D, E or F register select
  • EMU28.C:
  • Changed function OnContextMenu(), when the context menu was generated from the keyboard it opened at a fix position, now when the mouse cursor position is inside the client window, at the mouse cursor position
  • EMU28.RC:
  • Changed version and copyright
  • ENGINE.C:
  • Changed function InitAdjustSpeed(), added critical section for writing reference CPU cycles and reference time
  • Bugfix in function AdjKeySpeed() and SetSpeed(), removed critical section handling for initializing CPU slow down, because this section is locked when the CPU emulation thread already slow down the CPU speed
  • FETCH.C:
  • Bugfix in table o81Af2_, o81Af1_ and o81Af0_, replaced o_invalid6 function pointers by their corresponding opcode function
  • Bugfix in table o12_, o11_ and o10_, replaced o_invalid3 function pointers by their corresponding opcode function
  • LODEPNG.C:
  • Changed implementation file to LodePNG version 20210627 with unmarked typecast patches for x64 compatibility, Copyright (c) 2005-2021 Lode Vandevenne
  • LODEPNG.H:
  • Changed header file to LodePNG version 20210627
  • MOPS.C:
  • Bugfix in function ReadTAcc(), moved critical section because InitAdjustSpeed() part is already protected
  • SOUND.C:
  • Bugfix in function SoundOut(), removed critical section handling because InitAdjustSpeed() is already protected

New in Emu28 1.34 (Jul 28, 2020)

  • DISPLAY.C
  • Changed function UpdateContrast() and StartDisplay(), changed call
  • of function UpdateAnnunciators() updating all annunciators
  • Changed function UpdateAnnunciators(), changed function prototype
  • with an additional argument to get information which annunciators
  • have changed, so only the annunciators which have changed are
  • redrawn now
  • EMU28.C
  • Changed function OnPaint(), changed call of function
  • UpdateAnnunciators() updating all annunciators
  • EMU28.DSP
  • Added stegano.c and stegano.h sources
  • Added "LODEPNG_NO_COMPILE_ALLOCATORS" to lodepng.c definitions
  • Removed external.c sources
  • EMU28.H
  • Changed function prototype
  • Extern declaration of global function
  • Removed extern declaration of global function
  • EMU28.RC
  • Changed version and copyright
  • ENGINE.C
  • Changed function WorkerThread(), changed call of function
  • UpdateAnnunciators() updating all annunciators
  • EXTERNAL.C
  • File deleted
  • FETCH.C
  • Changed table o81B_, removed 1LK7 changes because table has no
  • 1LK7 related opcodes any more
  • Changed table o81_, replaced beep patch opcode o81B_ by
  • o_invalid3, so table o81B_ isn't used any more
  • FILES.C
  • Added lodepng allocator functions lodepng_malloc(),
  • lodepng_realloc() and lodepng_free()
  • Added function MapRomBmp(), loading a ROM image from stenographic
  • bitmaps with uncompressing
  • Changed function OpenDocument(), when KML script file name is
  • longer than the file buffer, skip the name heading until the name
  • remainder fits into the buffer, this cause a KML script error with
  • the selection of a new KML script instead of a general document
  • file read error before
  • Changed function GetOpenFilename() and GetSaveAsFilename(),
  • expanded HP28C file extension select with *.e28c and use this file
  • extension as default for saving now
  • KML.C
  • Bugfix in function ParseLines() and ParseBlocks(), if loading of
  • an include file failed the KML script line number at the error
  • message was wrong
  • Changed function InitGlobal(), added possibility of ROM image
  • loading from stenographic bitmaps in TOK_ROM and TOK_BITMAP block
  • Changed function KillKML(), added preset of global variable
  • Changed function InitKML(), changed warning to error at ROM beep
  • patch detection
  • LODEPNG.C
  • Changed implementation file to LodePNG version 20200306 with
  • unmarked typecast patches for x64 compatibility, Copyright (c)
  • 2005-2020 Lode Vandevenne
  • LODEPNG.H
  • Changed header file to LodePNG version 20200306
  • MOPS.C
  • Changed function WriteSlaveIO(), the annunciator access variable
  • now contain bit coded the annunciators which have changed and is
  • the argument for the modified UpdateAnnunciators() function
  • OPCODES.C
  • Removed function o81B1() as part of the beep patch
  • OPCODES.H
  • Removed extern declaration of function o81B1()
  • PCH.H
  • Added definitions to disable stegano disk interface and stegano
  • encoder
  • STEGANO.C
  • STEGANO.H
  • New modules to encode/decode data in bitmap images
  • TYPES.H
  • Changed structure CHIPSET, moved variable bShutdnWake behind
  • variable cycles so that cycles has a QWORD alignment necessary for
  • _USRDLL definition set else the definition destroy the state file
  • structure

New in Emu28 1.33 (Aug 27, 2019)

  • DEBUGGER:
  • added enum type, static variables and static function prototypes
  • for trace implementation
  • removed all occurrences of UNREFERENCED_PARAMETER(wParam);
  • changed function NotifyDebugger(), added flush trace buffer
  • changed function Debugger(), added trace implementation in case
  • WM_INITDIALOG, WM_DESTROY and WM_COMMAND
  • added functions StartTrace(), StopTrace(), FlushTrace(),
  • PrintTrace(), OutTrace(), OnBrowseTraceSettings(),
  • TraceSettings(), OnTraceSettings() and OnTraceEnable() for trace
  • implementation
  • DISPLAY.C:
  • changed function CreateMainBitmap(), changed LoadBitmapFile()
  • function call loading a bitmap with realizing a palette
  • changed function CreateAnnunBitmap(), changed LoadBitmapFile()
  • function call loading a bitmap without realizing a palette
  • added function SetAnnunBitmap(), setting a created annunciator
  • bitmap
  • EMU28.C:
  • added variable bMouseButton saving if mouse button was pressed
  • when mouse cursor was inside a virtual button hit area
  • removed function OnNcHitTest(), replaced by additional
  • OnLButtonDown() implementation
  • changed function OnLButtonDown(), added part for windows movement
  • when having no title bar prior done over the WM_NCHITTEST message
  • handler which caused side effects
  • changed function OnLButtonUp() and OnKeyDown(), added reset of
  • variable bMouseButton
  • changed function MainWndProc(), added WM_ENDSESSION handler for
  • document saving, WM_CONTEXTMENU calls the context menu only when
  • the right mouse button was not pressed over a virtual button hit
  • area before, removed the WM_NCRBUTTONUP case and removed the
  • WM_NCHITTEST message handler
  • EMU28.DSP:
  • added definition for lodepng.c
  • EMU28.H:
  • changed function prototype
  • extern declaration of global functions
  • EMU28.RC:
  • added dialog IDD_TRACE
  • changed menu IDR_DEBUG, added ID_TRACE_SETTINGS and
  • ID_TRACE_ENABLE menu items
  • changed version and copyright
  • ENGINE.C:
  • changed function Debugger(), added function fnOutTrace() call
  • FILES.C:
  • added function CheckForBeepPatch() looking for ROM beep patches at
  • known positions
  • bugfix in function NewDocument(), initialize the ROM fingerprint
  • after loading the KML script
  • changed function DecodeBmp(), DecodeGif(), DecodePng() and
  • LoadBitmapFile(), changed function prototype by adding an argument
  • if a palette should realized
  • KML.C:
  • changed function ResizeMainBitmap(), added annunciator resize
  • handling for annunciator definitions inside main bitmap
  • changed function InitKML(), added warning for ROM beep patches
  • LODEPNG.C:
  • changed implementation file to LodePNG version 20190824 with
  • unmarked typecast patches for x64 compatibility, Copyright (c)
  • 2005-2019 Lode Vandevenne
  • LODEPNG.H:
  • changed header file to LodePNG version 20190824
  • RESOURCE.H:
  • added definitions

New in Emu28 1.32 (Jul 18, 2018)

  • DISRPL.C:
  • Changed function DoHexStream() and DoHxs(), removed trailing space if data length is zero
  • Bugfix in function DoIntStream(), =DOINT stream with zero data length crashed decoder
  • EMU28.C:
  • Bugfix in function OnViewCopy(), fixed unsynchronized GDI operation
  • EMU28.DSP:
  • Added lodepng.h and lodepng.c sources
  • EMU28.RC:
  • Changed version and copyright
  • FILES.C:
  • Changed function GetSaveObjectFilename(), changed function behavior with file extensions; the old implementation added the default extension always when the file had no extension or the given extension wasn't in the file filter list, the actual implementation adds the default extension for the case of no extension only
  • Added function DecodePng() as wrapper for decoding PNG image files
  • Changed function LoadBitmapFile(), added PNG image file support
  • Added function EncodeColorBits() returning bitfield position encoded color bits
  • Bugfix in function CreateRgnFromBitmap(), removed GetObject() call for getting the image properties, they are get over a GetDIBits() query now, removed creating a memory DC because it's unused and added bitfield decoding which is important for the 16 bit (5:6:5) color setting
  • KML.C:
  • Changed function AdjustPixel(), changed function prototype using a buffer position instead of device context pixel coordinate to locate the adjustable pixel
  • Changed function TransparentCircle(), complete new implementation with changed function prototype; the prior implementation used the GetPixel()/SetPixel() method to adjust the pixel color of a single pixel, this method was extremely slow on some PC configurations, the current method is creating a byte copy of the complete target area, does the pixel adjustments on byte level and finally copy the result back to the target device context
  • Changed function DrawButton(), adjusted implementation to new prototype of function TransparentCircle()
  • Bugfix in function DrawAnnunciator(), used wrong device context on external annunciator bitmap for getting background pixel color (buggy implementation only worked with external bitmaps having a white background color)
  • LODEPNG.C:
  • New module for decoding PNG files LodePNG version 20180611 with unmarked typecast patches for x64 compatibility, Copyright (c) 2005-2018 Lode Vandevenne
  • LODEPNG.H:
  • Header file for decoding PNG files LodePNG version 20180611, Copyright (c) 2005-2018 Lode Vandevenne

New in Emu28 1.31 (Sep 20, 2017)

  • DEBUGGER.C:
  • Changed function UpdateStackWnd(), OnStackPush() and OnStackPop(), fixed signed/unsigned mismatch
  • Changed function UpdateProfileWnd(), fixed signed/unsigned mismatch and optimized ENG unit search break
  • DISPLAY.C:
  • Added function CreateAnnunBitmap() and DestroyAnnunBitmap(), handle a separate annunciator bitmap
  • Changed function WritePixelDWORD(), WritePixelWORD() and WritePixelBYTE(), changed order of operands to enable constant folding of compiler
  • Bugfix in function ResizeWindow(), added Critical Section for GDI access
  • EMU28.H:
  • Changed window style for disabled title bar, added system menu with minimize in task bar
  • Extern declaration of global variable and functions
  • EMU28.RC:
  • Changed IDD_CHOOSEKML, enlarged width of dialog to get an enlarged "Current KML Script" combo box
  • Changed IDD_KMLLOG, enlarged width of "Title of the Script", "by" and "The Author" text boxes
  • Changed version and copyright
  • FILES.C:
  • Changed function NewDocument(), removed SetWindowLocation() call in restore case because on a valid document the window position was already restored in function RestoreBackup()
  • Added function LoadIconFromFile(), load icon file and activate the icons
  • Added function LoadIconDefault(), activate the window class default icons
  • KML.C:
  • Added keyword "Opaque", "Scale" and "Icon" to pLexToken[] table
  • Changed function InitGlobal(), added implementation of keyword "Scale" and "Icon"
  • Changed function InitLcd(), added implementation of keyword "Bitmap"
  • Changed function InitAnnunciator(), added implementation of keyword "Opaque"
  • Changed function KillKML(), added LoadIconDefault() to disable custom icons, added DestroyAnnunBitmap() and preset of some global variables
  • Changed function DrawAnnunciator(), added alternative annunciator bitmap and opaque bitmap drawing
  • Added function ResizeMainBitmap(), resize main bitmap and main bitmap dependend variables like size, offset, ...
  • Changed function InitKML(), added scaling main bitmap
  • KML.H:
  • Added TOK_OPAQUE, TOK_SCALE and TOK_ICON definition
  • Added bOpaque in KmlAnnunciator structure
  • MOPS.C:
  • Bugfix in function MapNCE() and MapEXT(), map only free memory pages
  • Changed function MapROM(), masking the ROM size with 0xFFFFF is not necessary
  • Changed function Map(), changed mapping order because of mapping free memory pages only now
  • Changed function NreadEx(), removed conditional jump for speed optimization

New in Emu28 1.29 (May 28, 2015)

  • DEBUGGER.C
  • bugfix in function OnContextMenu(), when the context menu was generated from the keyboard it was opened at the wrong position
  • bugfix in function Debugger(), use critical section for secure deletion of the last instruction buffer
  • DISPLAY.C
  • changed function CreateMainBitmap(), removed unreferenced variable in release mode
  • changed function ResizeWindow(), optimized implementation now works independent from window style and menu bar setting
  • EMU28.C
  • added global variable dwTColor and dwTColorTol for the background transparency color matching
  • added global variable hRgn to hold a region resource handle for a transparent background bitmap
  • added global variables bTitleBar, bShowTitle, bShowMenu and bClientWinMove
  • added Critical Section initialization
  • added function UpdateWindowBars(), helper function to update state of title and menu bar
  • changed function SettingsProc(), added "Show Title" and "Show Menu" checkbox handling
  • changed function OnPaint(), added UpdateWindowBars() call
  • changed function OnInitMenu(), added MRU list update
  • added function OnContextMenu(), context menu implementation
  • added function OnNcHitTest(), when no title bar check if mouse position is in client not over a button area
  • changed function MainWndProc(), minor change in WM_PALETTECHANGED implementation and added WM_CONTEXTMENU, WM_NCRBUTTONUP and WM_NCHITTEST message handler
  • changed function WinMain(), changed method of memory leak detection by adding _CrtSetDbgFlag() at begin and removing _CrtDumpMemoryLeaks() at end of program
  • EMU28.H:
  • added window styles definition
  • changed function prototypes
  • extern declaration of global variables and function
  • EMU28.RC:
  • changed IDD_SETTINGS, added "Show Title" and "Show Menu" checkbox
  • added menu IDM_MENU
  • changed version and copyright
  • ENGINE.C:
  • bugfix in function SaveInstrAddr(), added critical section to be sure that last instruction buffer is still available
  • FILES.C:
  • defined abs() and labs() as intrinsic
  • changed function DecodeGif(), changed function prototype by adding an argument overwritten by the transparent color if found
  • changed function LoadBitmapFile(), adjusted to new prototype of function DecodeGif()
  • added function AbsColorCmp() and LabColorCmp(), compare colors with tolerance
  • added function CreateRgnFromBitmap(), create opaque bitmap region
  • KML.C:
  • added keyword "SysItem" to pLexToken[] table
  • changed function InitGlobal(), added implementation of keyword "Color"
  • changed function RunLine(), added implementation of keyword "SysItem"
  • changed function KillKML(), added reset of variables hRgn, dwTColor and dwTColorTol
  • added function MouseIsButton() to check if mouse over button area
  • changed function MouseMovesTo(), changed _ASSERT implementation to make sure that class cursor is NULL and use function MouseIsButton() to select cursor type now
  • KML.H:
  • added TOK_SYSITEM definition
  • changed structure KmlToken, replaced TCHAR array szName[20] with LPCTSTR szName pointer
  • added MouseIsButton() function prototype
  • MRU.C:
  • changed all function argument types from INT to UINT
  • removed global variables hMruMenu and nMruPos
  • removed all update menu calls in this module and made functions robust against non initialized MRU list and ID index out of range
  • changed function GetMenuPosForId(), changed function prototype so the resulting menu handle and menu position aren't global variables any more
  • changed function MruInit(), changed return value from FALSE to TRUE for success and changed implementation like used in the PPC emulator variants
  • changed function MruUpdateMenu(), changed function prototype by adding the HMENU argument for updating the selected menu and added initialization prior done in function MruInit()
  • changed function MruWriteList(), if there are no entries don't write the "FileCount" setting any more
  • PCH.H:
  • added _WINSOCK_DEPRECATED_NO_WARNINGS definition
  • added GCLP_HCURSOR, SetClassLongPtr, GetClassLongPtr and ULONG_PTR definitions for MSVC6.0 SDK and earlier
  • RESOURCE.H:
  • added definitions
  • SETTINGS.C:
  • changed function ReadSettings() and WriteSettings(), added item "ShowTitle", "ShowMenu" and "ClientWinMove" in section [Emulator] in the INI-File
  • SOUND.C:
  • bugfix in function DestroyWaveThread(), the WM_QUIT message may failed and so the sound message thread wasn't shut down
  • changed function SoundOpen(), added additional check if the sound device support the necessary audio format
  • SYMBFILE.C:
  • changed function RplLoadTable(), made optimizations and added integrity checks

New in Emu28 1.28 (Mar 20, 2014)

  • DEBUGGER.C
  • removed INSTRSIZE definition
  • changed function GetAddr(), made function more general by adding address range check and the ability of decoding a symbolic entry into an address
  • bugfix in function OnSetCursor(), on "Activation follows mouse" enabled child dialogs lost focus when cursor moved over parent debugger dialog
  • changed function Debugger(), removed initialization of global variable wInstrSize
  • changed function EnterAddr(), changed parameter storage from static variable to window user data and replaced address decoder code by GetAddr() function call
  • changed function EnterBreakpoint(), replaced address decoder code by GetAddr() function call and so added decoding a symbolic entry into an address
  • bugfix in function LoadMemData(), forgot to check if file content fit into Saturn address range, loading now stops also after last Saturn address written
  • changed function SaveMemData(), added assertion for Saturn address verification
  • bugfix in function DebugMemLoad() and DebugMemSave(), adjusted to new prototype of function GetAddr() and so added checking if the given addresses are in the Saturn address range because Saturn read/write functions don't do the range check; this also cause a change in behavior, on empty address fields the operation fails and the dialog still remains open
  • DISPLAY.C
  • changed function UpdateContrast(), replaced BitBlt() by PatBlt() function call
  • changed function CreateLcdBitmap(), added implementation to select the pixel drawing routine over function pointer, Zoom factors 1-4 still using the old implementation, greater Zoom factors are using a more generic approach
  • changed DestroyLcdBitmap(), added reset of variables x-zoom factor and function pointer WritePixel
  • replaced function WritePixelQuad() by the new functions WritePixelZoom4(), WritePixelZoom3(), WritePixelZoom2() and WritePixelZoom1() and WritePixelDWORD(), WritePixelWORD() and WritePixelBYTE() with new implementation to support nLcdZoom values > 4
  • added function WriteDisplayCol() for writing a display column
  • changed function UpdateMainDisplay(), removed zoom factor assertion and simplified writing of display area
  • changed function UpdateAnnunciators(), changed to a more efficient bitcount implementation and other minor optimizations
  • bugfix in function StopDisplay(), restoring the LCD background wasn't locked against GUI thread GDI access
  • EMU28.C
  • changed function SetSoundDeviceList(), replaced "Standard Audio" device ID from constant to definition
  • bugfix in function SettingsProc(), restart the sound engine by calling the clean up and initialization functions now and on "Activation follows mouse" enabled debugger dialog maybe got focus even if it's not the last active one
  • changed function OnFileNew(), removed call of function SaveBackup() which is already a part of function NewDocument()
  • changed function OnFileNew(), OnFileOpen(), OnFileMruOpen(), OnFileSave(), OnFileSaveAs() and OnFileClose(), switched detection of document is available from variable pbyRom (ROM image loaded) to variable bDocumentAvail
  • changed function OnViewCopy(), removed nLcdZoom assertion and MONOCHROME source code part
  • changed function WinMain(), added sound engine initialization and clean up
  • EMU28.RC
  • changed version and copyright
  • ENGINE.C
  • initialized variable wInstrSize with size of last instruction array (the circular buffer can hold (wInstrSize-1) instructions)
  • bugfix in function WorkerThread(), moved sound engine initialization and clean up from SM_RUN state to main function, this prevents a non responding Saturn CPU emulation when changing from SM_SLEEP to SM_RUN state during sound engine initialization
  • FETCH.C
  • made typedef of jump table struct constant, so the const keyword was removed from all references of JMPTAB
  • changed function EvalOpcode(), minor code optimization
  • FILES.C
  • bugfix in function PatchRom(), removed limitation that patch file must have 6 characters minimum, fixed a buffer overflow when end of patch file consists of white space characters, recalculate checksums only on address patch written and return failture on syntax errors now
  • KML.C
  • changed function InitLcd(), removed Zoom factor 4 limitation
  • PCH.H
  • added GWLP_USERDATA, SetWindowLongPtr, GetWindowLongPtr and LONG_PTR definitions for MSVC6.0 SDK and earlier
  • REDEYE.C
  • changed function IrPrinter(), changed to a more efficient bitcount implementation for missed bits
  • SETTINGS.C
  • changed function ReadSettings() and WriteSettings(), added item "LastInstrBufSize" in section [Debugger] in the INI-File
  • SOUND.C
  • changed function GetSoundBuf() and SoundOpen(), eliminate GCC warning
  • STACK.C
  • added function Trim(), create a trimmed copy of the input string
  • added function SetBcd(), contain implementation of prior function RPL_SetBcd()
  • changed function RPL_SetBcd(), wrapper for function SetBcd() to trim data before decoding
  • changed function RPL_SetComplex(), create a trimmed working copy before decoding the outline brackets and because of the changed function RPL_SetBcd() the real number arguments are accepted with white spaces around now
  • UDP.C
  • changed function SendByteUdp(), replaced malloc() by _alloca() call for UNICODE wchar to char string translation to get rid of freeing the allocated memory manually

New in Emu28 1.27 (May 2, 2013)

  • DDESERV.C
  • prepared for C++ compiling
  • DEBUGGER.C
  • prepared for C++ compiling
  • added new function OnCodeFindPCO(), search for a PCO object in the
  • code window
  • changed function Debugger(), added context menu commands handler
  • in the WM_COMMAND section
  • changed function OnFindOK(), added downwards search direction
  • changed function Find(), added and changed message handler for the
  • "Previous" and "Next" buttons
  • changed function UpdateProfileWnd(), changed CPU frequency from
  • 640000 constant to calculated one from T2CYCLES
  • DISPLAY.C
  • prepared for C++ compiling
  • EMU28.C
  • prepared for C++ compiling
  • replaced global variable ThreadId with local variable dwThreadId
  • added global variable with the identifier for the waveform-audio
  • output device
  • added function SetSoundDeviceList(), helper function for filling
  • sound device combo box with waveform-audio output devices
  • changed function SettingsProc(), removed sound radio button
  • handlers and added implementation of sound device combo box
  • bugfix in function OnViewScript(), ROM image change wasn't handled
  • bugfix in function OnCopyData(), state file loading is only
  • allowed when the current instance has already a document available
  • EMU28.DSP
  • added sound.c sources
  • EMU28.H
  • prepared for C++ compiling
  • extern declaration of global variables and functions
  • removed extern declaration of global variable
  • EMU28.RC
  • changed IDD_FIND, added a "Previous" button for previous search,
  • shorten the text of the "Find Next" button to "Next" and changed
  • the ID of the next search button
  • changed IDD_SETTINGS, removed "Speaker" and "Wave" radio buttons
  • and added "Device" combo box in the sound section
  • added "Previous PCO" and "Next PCO" menu entries in debugger
  • "Code" context menu
  • changed version and copyright
  • ENGINE.C
  • added global variable bEnableSlow for global disabling slowing
  • down the CPU
  • added global variable bSoundSlow slowing down the CPU core at
  • sound output
  • bugfix default setting of variable dwSaturnCycles, the real CPU is
  • running with a nominal strobe frequency of ~640 kHz
  • 640000 / 16384 = 39
  • changed function AdjustSpeed() and InitAdjustSpeed, added sound
  • slow down implementation
  • changed function WorkerThread(), added sound engine control
  • EXTERNAL.C
  • removed global variable bWaveBeep
  • moved global variable dwWaveVol to module sound.c
  • removed functions BeepWave() and BeepWin9x()
  • changed function External(), removed PC speaker support and used
  • function SoundBeep() instead of BeepWave() for beep output over
  • sound card, changed CPU cycles estimation from 1MHz to 640kHz CPU
  • strobe frequency
  • FETCH.C
  • prepared for C++ compiling
  • FILES.C
  • prepared for C++ compiling
  • changed function MapRom(), modified minimum file size detection
  • and replaced VirtualAlloc() with malloc() memory request
  • changed function UnmapRom(), adjusted memory deallocation
  • changed function SaveBackup(), improved document available
  • detection
  • KML.C
  • prepared for C++ compiling
  • added global variable wKeybLocId to hold the keyboard layout input
  • locale at begin of KML loading
  • changed function ParseBlocks(), use variable wKeybLocId instead
  • of input locale reading
  • bugfix in function KillKML(), key mapping state table wasn't
  • cleared at the end and added reset of variable wKeybLocId
  • bugfix in function InitKML(), changed implementation by reading
  • the current keyboard layout and convert the layout data to the
  • input locale setting
  • MRU.C
  • prepared for C++ compiling
  • OPCODES.C
  • changed function o801(), call beeper handler function on beeper
  • port change
  • PCH.H
  • added include malloc.h
  • RESOURCE.H
  • added definitions
  • removed IDC_SOUND_SPEAKER and IDC_SOUND_WAVE
  • RPL.C
  • prepared for C++ compiling
  • SETTINGS.C
  • bugfix in function GetRegistryString(), ignored target buffer size
  • when copying the default to the target string buffer
  • changed function ReadSettings() and WriteSettings(), added item
  • "WaveDeviceId" and "WaveTime" and deleted item "WaveBeep" in
  • section [Emulator] in the INI-File
  • SOUND.C
  • new module for native beeper emulation over wave output device
  • STACK.C
  • prepared for C++ compiling
  • SYMBFILE.C
  • prepared for C++ compiling

New in Emu28 1.26 (Jan 24, 2013)

  • DEBUGGER.C
  • removed variables pbyMapData and dwMapDataSize, the implementation
  • behind moved to module DISMEM.C
  • bugfix in function SetMappingMenu(), disable RPL object viewer if
  • the memory browser isn't in mapped memory mode
  • changed function SetMappingMenu(), ViewMemWnd() and OnFindOK(),
  • changed to DISMEM.C implementation
  • changed function GetMemCurAddr(), OnMemGoAdr(), OnKeyUpDown() and
  • OnKeyPlusMinus(), variable dwMapDataSize isn't global any more,
  • use function GetMemDataMask() instead
  • changed function ViewCodeWnd(), set disassembler to memory mapped
  • mode
  • bugfix in function OnDblClick(), fixed buffer overflow when
  • converting a 2 byte hexadecimal string to a byte and added an
  • update of code window
  • changed function Debugger(), added initialization of RPL object
  • viewer get nibble function in WM_INITDIALOG message
  • bugfix in function UpdateRplObjViewWnd(), show entry point names
  • only in mapped mode and end address for RPL object viewer depend
  • on the actual memory mapping mode and with the design change to
  • the DISMEM.C implementation in all debugger and disassembler
  • related parts, the RPL object viewer also works in all memory
  • mapping modes properly now
  • DISASM.C
  • changed function read_nibble(), call function GetMemNib() from the
  • new module DISMEM.C for mapping mode memory access and made
  • function static
  • DISMEM.C
  • new module for accessing memory data for debug view purpose
  • DISRPL.C
  • the get nibble function is not hard referenced as read_nibble()
  • call any more, it's now called over RplReadNibble() function
  • pointer
  • changed function PrintTail(), expanded to handle 6 digit addresses
  • DISRPL.H
  • added extern declaration of RplReadNibble() function pointer
  • EMU28.C
  • changed function Disasm(), changed to DISMEM.C implementation
  • added function OnCopyData() as WM_COPYDATA message handler
  • implementation for changing the state file to the given state file
  • name
  • changed function MainWndProc(), added WM_COPYDATA message handler
  • changed function WinMain(), expanded single instance case by
  • transmitting the given state file name to the already opened
  • program instance and added more flexible CPU binding for the
  • Saturn core emulation thread on Windows NT4.0 and later
  • EMU28.DSP
  • added dismem.c sources
  • EMU28.H
  • added WM_COPYDATA identifier definition
  • added enum MEM_MAPPING
  • extern declaration of global functions
  • removed extern declaration of global variable
  • EMU28.RC
  • changed version
  • KML.C
  • added global variable bLocaleInc for checking if locale block
  • content already included
  • added keyword "Locale" to pLexToken[] and token TOK_LOCALE to
  • eIsGlobalBlock[] table
  • changed function ParseLine() and ParseBlock(), preset szLexString
  • variable with NULL after freeing
  • changed function IncludeLines() and IncludeBlocks(), changed
  • function prototype by adding a boolean argument for selecting the
  • text message "Including" or "Parsing" in the log file
  • bugfix in function ParseLines(), return a TOK_NONE line for an
  • empty block instead of a NULL pointer which regular stands for a
  • syntax error
  • bugfix in function ParseLines() and ParseBlocks(), changed
  • function prototype by adding a boolean argument for selecting the
  • mode "include" or "parse" for the next lines or blocks and
  • verifying the "Include" argument was incomplete and may caused
  • memory leaks at error condition
  • bugfix in function ParseBlock(), verifying the block commmand
  • argument was incomplete and may caused a memory leak at error
  • condition
  • changed function ParseBlocks(), changed function prototype by
  • adding a boolean argument if an "End" token is also valid and
  • added implementation of block "Locale"
  • changed function KillKML(), added reset of variable bLocaleInc
  • bugfix in function ReloadButtons(), ON key button wasn't handled
  • changed function ReleaseButton(), for speed optimization skip
  • function if button is already released
  • bugfix in function LoadKMLGlobal(), fixed a memory leak caused by
  • the error condition that expected block command is a string
  • changed function InitKML(), added current keyboard input locale
  • setting log file text
  • KML.H
  • added TOK_LOCALE definition
  • TIMER.C
  • changed function SetHPTime(), time calculation now work properly
  • for host system dates before 1970/01/01 and after 2106/02/07

New in Emu28 1.25 (Jan 24, 2013)

  • DISPLAY.C
  • changed function UpdateContrast(), new brush is only necessary for
  • an initialized KML contrast palette entry
  • changed function CreateLcdBitmap(), preset KML contrast palette
  • with black on background for the case of a complete uninitialized
  • KML contrast palette
  • bugfix in function UpdateMainDisplay(), don't draw display pattern
  • on uninitialized KML foreground contrast palette entry;
  • bug/behavior was introduced in v1.24 to get display output also
  • for the case of no KML contrast palette entries defined
  • changed function UpdateMainDisplay(), exchanged StretchBlt() back
  • to BitBlt() because the bug in the WineHQ BitBlt() implementation
  • was fixed in Wine 1.4
  • bugfix in function UpdateAnnunciators(), don't draw annunciators
  • on uninitialized KML foreground contrast palette entry;
  • bug/behavior was introduced in v1.24 to get display output also
  • for the case of no KML contrast palette entries defined
  • EMU28.C
  • changed function OnPaint(), exchanged StretchBlt() back to
  • BitBlt() in display redraw part because the bug in the WineHQ
  • BitBlt() implementation was fixed in Wine 1.4
  • EMU28.RC
  • changed version

New in Emu28 1.24 (Jan 24, 2013)

  • DEBUGGER.C
  • changed function ViewMemWnd(), removed initialized but unused
  • variable
  • DISPLAY.C
  • initialize hBrush variable
  • bugfix in function UpdateContrast(), delete only brush if exists,
  • fixed possible use of uninitialized KML contrast palette for
  • display pattern -> use black brush for this case and added
  • GdiFlush() before the end of the GDI critical section to eval all
  • pending GDI operations to avoid GDI problems on a different task
  • bugfix in function CreateLcdBitmap(), display pattern brush
  • initialization may failed because of an uninitialized KML contrast
  • palette -> brush now created in function UpdateContrast()
  • changed function DestroyLcdBitmap(), reset hBrush after deleting
  • bugfix in function UpdateMainDisplay(), display pattern drawing is
  • independent from initialization state of KML contrast palette
  • bugfix in function UpdateAnnunciators(), annunciators hadn't
  • worked in the case of uninitialized KML contrast palette for
  • display pattern
  • DISRPL.C
  • changed function RplCreateObjView(), defined end pointer also as
  • constant
  • EMU28.C
  • changed function SettingsProc(), added "Single Instance" checkbox
  • handling
  • bugfix in function OnDropFiles(), changed function prototype to
  • the correct structure type of dropped file names and initialized
  • the bSuccess variable for the case the wNumFiles variable is 0
  • changed function MainWndProc(), made correct type cast to argument
  • of function OnDropFiles()
  • changed function WinMain(), replaced multiple class name usage
  • with atom variable, moved read settings before window creation,
  • and added check for setting "SingleInstance" to switch to an
  • already running program instance instead of creating a new one
  • EMU28.H
  • extern declaration of global variable
  • EMU28.RC
  • added item "Single Instance" in settings dialog
  • changed version and copyright
  • FILES.C
  • bugfix in function DecodeBmp() and DecodeGif(), a 2nd bitmap load
  • allocated and bound a 2nd palette to the main window, now only the
  • 1st bitmap (mostly the KML background bitmap) bound his palette to
  • the main window
  • KML.C
  • changed table pLexToken[], defined table as constant and changed
  • last token id table preset from constant number to member of token
  • id enumerator
  • bugfix in function ParseString(), decoding the \" sequence as
  • quotation mark inside a string was incomplete, so every single '\'
  • character was also removed
  • MRU.C
  • changed function MruUpdateMenu(), changed variable type of
  • variable hMenu
  • changed function MruReadList(), removed initialized but unused
  • variable
  • RESOURCE.H
  • added definition
  • SETTINGS.C
  • changed function ReadSettings(), moved CPU speed setting to
  • MainWndProc()
  • changed function ReadSettings() and WriteSettings(), added item
  • "SingleInstance" in section [Emulator] in the INI-File
  • UDP.C
  • added function ResetUdp(), reset UDP address
  • bugfix in function SendByteUdp(), fixed memory leak at error
  • condition and optimized IP address decoding

New in Emu28 1.23 (Jan 24, 2013)

  • EMU28.C
  • changed function SettingsProc(), added infrared printer settings
  • changed function SaveChanges(), detect if document is available
  • now over the variable bDocumentAvail and not over the variable
  • pbyRom any more; in the case of an illegal KML script there maybe
  • a document loaded, but no ROM image, so pbyRom will be NULL in
  • this case
  • bugfix function OnViewScript(), when quitted the dialog "Choose
  • Your KML Script" with the Cancel button when chosen an invalid
  • script the function returned without the possibility of saving the
  • current document; now the function try to reload the primarily KML
  • script and if this also fails then the current document is saved
  • EMU28.H
  • extern declaration of global variables and functions
  • EMU28.DSP
  • added redeye.c and udp.c sources
  • added library Ws2_32.lib
  • EMU28.RC
  • added "Infrared Printer" group in Settings dialog
  • changed version
  • ENGINE.C
  • added global variable nOpcSlow to hold the number of CPU opcodes
  • slowing down the CPU core
  • changed function AdjustSpeed(), added CPU opcode slow down
  • implementation
  • added function InitAdjustSpeed(), initialize CPU slow down part
  • if necessary
  • changed function AdjKeySpeed() and SetSpeed(), use function
  • InitAdjustSpeed() to initialize the CPU slow down variables
  • FILES.C
  • changed function CrcRom(), if no ROM available return without
  • modifying the checksum
  • changed function ResetDocument(), NewDocument(), OpenDocument()
  • and RestoreBackup(), added state variable if document is available
  • KEYMACRO.C
  • changed function EventThread(), added minimum key hold time for
  • keyboard macro playing and subtract minimum key hold time from
  • saved waiting time, this is more accurate when the user has
  • selected a different minimum key hold time than the default one
  • changed function KeyMacroRecord(), now saving the complete waiting
  • time including the key state holding time, the key state holding
  • time is now subtract in the player function thread EventThread()
  • changed function OnToolMacroNew(), removed adding the key state
  • holding time to the reference time, this is not necessary any more
  • MOPS.C
  • added function ReadTAcc(), reading timer value with checking for
  • CPU speed measurement behaviour
  • changed function ReadIO() and ReadSlaveIO(), the timer register
  • content is now read by function ReadTAcc() to analyze the read
  • access scheme
  • bugfix in function WriteIO(), added implementation of the STL bit
  • in the LEDOUT (0x30D) register
  • PCH.H
  • added include winsock2.h
  • REDEYE.C
  • new module for decoding the redeye data stream for a HP82240B
  • printer
  • RESOURCE.H
  • added some definitions
  • SETTINGS.C
  • changed function ReadSettings() and WriteSettings(), added item
  • "KeyMinDelay" in section [Macro] and the items "Address" and
  • "Port" in section [IrPrinter] in the INI-File
  • UDP.C
  • new module for sending a byte over UDP