AlphaSim.cpp File Reference


Detailed Description

Defines the entry point for the application.

Id
AlphaSim.cpp,v 1.48 2008/04/10 12:32:24 iamcamiel Exp

X-1.48 Martin Borgman 10-APR-2008 Handle SDL support on OS X through OS_X/SDLMain.m.

X-1.47 Camiel Vanderhoeven 04-APR-2008 Take version number from config.h

X-1.46 Camiel Vanderhoeven 26-MAR-2008 Fix compiler warnings.

X-1.45 Camiel Vanderhoeven 17-MAR-2008 Always set volatile DPR rom contents.

X-1.44 Camiel Vanderhoeven 14-MAR-2008 Formatting.

X-1.43 Camiel Vanderhoeven 14-MAR-2008 1. More meaningful exceptions replace throwing (int) 1. 2. U64 macro replaces X64 macro.

X-1.42 Camiel Vanderhoeven 04-MAR-2008 Version updated to 0.18.

X-1.41 Brian Wheeler 26-FEB-2008 a) Catch SIGUSR1 to trigger the backtracer if es40 seems to have hung. b) Use _exit() to really really quit when a SIGSEGV is caught.

X-1.40 Brian Wheeler 07-FEB-2008 On GNU systems, display a backtrace when a segmentation fault occurs, and DEBUG_BACKTRACE has been defined.

X-1.39 Brian Wheeler 05-FEB-2008 Display a message when system initialization has failed.

X-1.38 Camiel Vanderhoeven 26-JAN-2008 Lifted hardcoded file-size limit of 10,000 bytes for config file.

X-1.37 Camiel Vanderhoeven 02-JAN-2008 Version updated to 0.17.

X-1.35 Camiel Vanderhoeven 28-DEC-2007 Throw exceptions rather than just exiting when errors occur.

X-1.34 Camiel Vanderhoeven 28-DEC-2007 Keep the compiler happy.

X-1.33 Camiel Vanderhoeven 10-DEC-2007 Use configurator to read config-file and set up devices.

X-1.32 Camiel Vanderhoeven 7-DEC-2007 Moved SDL_Init to gui implementation.

X-1.31 Camiel Vanderhoeven/Brian Wheeler 6-DEC-2007 Use Boch's SDL gui plugin (with thanks to the Bochs project!!)

X-1.30 Camiel Vanderhoeven 2-DEC-2007 Added support for code profiling.

X-1.29 Brian Wheeler 1-DEC-2007 Added console support if USE_CONSOLE is defined.

X-1.28 Brian Wheeler 22-NOV-2007 Added nic0.disabled configuration option.

X-1.27 Camiel Vanderhoeven 17-NOV-2007 Use FAILURE.

X-1.26 Camiel Vanderhoeven 17-NOV-2007 Version updated to 0.16. Made it possible to disable the network by defining NO_NETWORK.

X-1.25 Camiel Vanderhoeven 14-NOV-2007 Added network.

X-1.24 Camiel Vanderhoeven 08-NOV-2007 Version updated to 0.15.

X-1.23 Camiel Vanderhoeven 02-NOV-2007 Version updated to 0.14.

X-1.22 Camiel Vanderhoeven 10-APR-2007 Replaced LoadROM(...) and SelectROM() calls with a single LoadROM() call. (See System.cpp, X-1.23).

X-1.21 Camiel Vanderhoeven 10-APR-2007 Calls to LoadROM and SelectROM changed to fit X-1.22 of System.cpp.

X-1.20 Camiel Vanderhoeven 31-MAR-2007 Added old changelog comments.

X-1.19 Camiel Vanderhoeven 28-FEB-2007 Call lockstep_init() if needed.

X-1.18 Camiel Vanderhoeven 16-FEB-2007 No longer load CSV files, this can be done with the LOAD CSV command in the Interactive De-Bugger.

X-1.17 Camiel Vanderhoeven 16-FEB-2007 a) Removed most of the code from this file. The main function no longer controls every clocktick, but rather transfers control directly to CSystem::Run(), or to the Interactive Debugger. b) In the IDB-version, the name of a script to execute can be specified on the command line (es40_idb ).

X-1.16 Camiel Vanderhoeven 13-FEB-2007 The define DISASM_START can be set to the number of processor cycles after which the disassembly will start.

X-1.15 Camiel Vanderhoeven 13-FEB-2007 The define DO_SETPC can be set to the address of the first instruction to be executed.

X-1.14 Camiel Vanderhoeven 12-FEB-2007 Use methods provided by CCPU rather than directly accessing its member variables.

X-1.13 Camiel Vanderhoeven 12-FEB-2007 Added comments.

X-1.12 Camiel Vanderhoeven 9-FEB-2007 Removed an obscure hack.

X-1.11 Camiel Vanderhoeven 9-FEB-2007 If DO_DISASM is set, disassembly will be output.

X-1.10 Brian Wheeler 7-FEB-2007 Configuration file may be specified on the command line.

X-1.9 Camiel Vanderhoeven 7-FEB-2007 Add instantiation of trace engine.

X-1.8 Camiel Vanderhoeven 3-FEB-2007 RUN_LT can be set to provide a breakpoint (end if pc < defined value)

X-1.7 Brian Wheeler 3-FEB-2007 Formatting.

X-1.6 Brian Wheeler 3-FEB-2007 Support for execution speed timing on Linux

X-1.5 Brian Wheeler 3-FEB-2007 Support for configuration file.

X-1.4 Brian Wheeler 3-FEB-2007 Made execution speed timing dependent on _WIN32 (since this code uses a lot of Windows-specific features, and won't compile on Linux.

X-1.3 Brian Wheeler 3-FEB-2007 Scanf calls made compatible with Linux/GCC/glibc.

X-1.2 Brian Wheeler 3-FEB-2007 Includes are now case-correct (necessary on Linux)

X-1.1 Camiel Vanderhoeven 19-JAN-2007 Initial version in CVS.

Author:
Camiel Vanderhoeven (camiel@camicom.com / http://www.camicom.com)

Definition in file AlphaSim.cpp.

#include "StdAfx.h"
#include "System.h"
#include "Flash.h"
#include "DPR.h"
#include "lockstep.h"
#include "SDL.h"

Go to the source code of this file.

Functions

int main (int argc, char *argv[])
 Entry point for the application.

Variables

const char * path []
 "standard" locations for a configuration file. This will be port specific.


Function Documentation

int main ( int  argc,
char *  argv[] 
)

Entry point for the application.

Does the following:

  • Try to find the configuration file.
  • Reads the configuration file, and uses the configurator to instantiate all system components.
  • Creates the trace-engine if in debug mode.
  • Runs the emulator.
  • Cleans up.

Definition at line 269 of file AlphaSim.cpp.

References Poco::Exception::displayText(), FAILURE, LL, CSystem::LoadROM(), lockstep_init(), path, CSystem::Run(), CTraceEngine::run_script(), CDPR::SaveStateF(), CFlash::SaveStateF(), CSystem::stop_threads(), theDPR, theSROM, theSystem, trc, and VERSION.


Variable Documentation

const char* path[]

Initial value:

{

  ".\\es40.cfg",
  "c:\\es40.cfg",
  "c:\\windows\\es40.cfg",








  0
}
"standard" locations for a configuration file. This will be port specific.

Definition at line 202 of file AlphaSim.cpp.

Referenced by main(), and SDLMain::openGame:.


SourceForge.net Logo
Project space on SourceForge.net