mirror of https://github.com/stella-emu/stella.git
More debugger work for 2K/4K ROMs.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2681 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
263e8e6240
commit
05a39cb1e0
|
@ -0,0 +1,31 @@
|
|||
//============================================================================
|
||||
//
|
||||
// SSSS tt lll lll
|
||||
// SS SS tt ll ll
|
||||
// SS tttttt eeee ll ll aaaa
|
||||
// SSSS tt ee ee ll ll aa
|
||||
// SS tt eeeeee ll ll aaaaa -- "An Atari 2600 VCS Emulator"
|
||||
// SS SS tt ee ll ll aa aa
|
||||
// SSSS ttt eeeee llll llll aaaaa
|
||||
//
|
||||
// Copyright (c) 1995-2013 by Bradford W. Mott, Stephen Anthony
|
||||
// and the Stella Team
|
||||
//
|
||||
// See the file "License.txt" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id$
|
||||
//============================================================================
|
||||
|
||||
#include "Cart2K.hxx"
|
||||
#include "Cart2KWidget.hxx"
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Cartridge2KWidget::Cartridge2KWidget(
|
||||
GuiObject* boss, const GUI::Font& font,
|
||||
int x, int y, int w, int h, Cartridge2K& cart)
|
||||
: CartDebugWidget(boss, font, x, y, w, h)
|
||||
{
|
||||
addBaseInformation(2048, "Atari", "Standard 2K cartridge, non-bankswitched\n"
|
||||
"Accessible @ $1000 - $1FFF");
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
//============================================================================
|
||||
//
|
||||
// SSSS tt lll lll
|
||||
// SS SS tt ll ll
|
||||
// SS tttttt eeee ll ll aaaa
|
||||
// SSSS tt ee ee ll ll aa
|
||||
// SS tt eeeeee ll ll aaaaa -- "An Atari 2600 VCS Emulator"
|
||||
// SS SS tt ee ll ll aa aa
|
||||
// SSSS ttt eeeee llll llll aaaaa
|
||||
//
|
||||
// Copyright (c) 1995-2013 by Bradford W. Mott, Stephen Anthony
|
||||
// and the Stella Team
|
||||
//
|
||||
// See the file "License.txt" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id$
|
||||
//============================================================================
|
||||
|
||||
#ifndef CARTRIDGE2K_WIDGET_HXX
|
||||
#define CARTRIDGE2K_WIDGET_HXX
|
||||
|
||||
class Cartridge2K;
|
||||
#include "CartDebugWidget.hxx"
|
||||
|
||||
class Cartridge2KWidget : public CartDebugWidget
|
||||
{
|
||||
public:
|
||||
Cartridge2KWidget(GuiObject* boss, const GUI::Font& font,
|
||||
int x, int y, int w, int h,
|
||||
Cartridge2K& cart);
|
||||
virtual ~Cartridge2KWidget() { }
|
||||
|
||||
// No implementation for non-bankswitched ROMs
|
||||
void loadConfig() { }
|
||||
void handleCommand(CommandSender* sender, int cmd, int data, int id) { }
|
||||
};
|
||||
|
||||
#endif
|
|
@ -0,0 +1,32 @@
|
|||
//============================================================================
|
||||
//
|
||||
// SSSS tt lll lll
|
||||
// SS SS tt ll ll
|
||||
// SS tttttt eeee ll ll aaaa
|
||||
// SSSS tt ee ee ll ll aa
|
||||
// SS tt eeeeee ll ll aaaaa -- "An Atari 2600 VCS Emulator"
|
||||
// SS SS tt ee ll ll aa aa
|
||||
// SSSS ttt eeeee llll llll aaaaa
|
||||
//
|
||||
// Copyright (c) 1995-2013 by Bradford W. Mott, Stephen Anthony
|
||||
// and the Stella Team
|
||||
//
|
||||
// See the file "License.txt" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id$
|
||||
//============================================================================
|
||||
|
||||
#include "Cart4K.hxx"
|
||||
#include "Cart4KWidget.hxx"
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Cartridge4KWidget::Cartridge4KWidget(
|
||||
GuiObject* boss, const GUI::Font& font,
|
||||
int x, int y, int w, int h, Cartridge4K& cart)
|
||||
: CartDebugWidget(boss, font, x, y, w, h)
|
||||
{
|
||||
uInt16 offset = (cart.myImage[0xFFD] << 8) | cart.myImage[0xFFC];
|
||||
addBaseInformation(4096, "Atari", "Standard 4K cartridge, non-bankswitched\n"
|
||||
"Accessible @ $1000 - $1FFF");
|
||||
}
|
|
@ -21,7 +21,6 @@
|
|||
#define CARTRIDGE4K_WIDGET_HXX
|
||||
|
||||
class Cartridge4K;
|
||||
|
||||
#include "CartDebugWidget.hxx"
|
||||
|
||||
class Cartridge4KWidget : public CartDebugWidget
|
||||
|
@ -29,13 +28,7 @@ class Cartridge4KWidget : public CartDebugWidget
|
|||
public:
|
||||
Cartridge4KWidget(GuiObject* boss, const GUI::Font& font,
|
||||
int x, int y, int w, int h,
|
||||
Cartridge4K& cart)
|
||||
: CartDebugWidget(boss, font, x, y, w, h)
|
||||
{
|
||||
addBaseInformation(4096, "Atari", "Standard 4K cartridge, non-bankswitched\n"
|
||||
"Accessible @ $1000 - $1FFF");
|
||||
}
|
||||
|
||||
Cartridge4K& cart);
|
||||
virtual ~Cartridge4KWidget() { }
|
||||
|
||||
// No implementation for non-bankswitched ROMs
|
||||
|
|
|
@ -19,6 +19,8 @@ MODULE_OBJS := \
|
|||
src/debugger/gui/ToggleBitWidget.o \
|
||||
src/debugger/gui/TogglePixelWidget.o \
|
||||
src/debugger/gui/ToggleWidget.o \
|
||||
src/debugger/gui/Cart2KWidget.o \
|
||||
src/debugger/gui/Cart4KWidget.o \
|
||||
src/debugger/gui/JoystickWidget.o \
|
||||
src/debugger/gui/PaddleWidget.o \
|
||||
src/debugger/gui/BoosterWidget.o \
|
||||
|
|
|
@ -24,6 +24,9 @@ class System;
|
|||
|
||||
#include "bspf.hxx"
|
||||
#include "Cart.hxx"
|
||||
#ifdef DEBUGGER_SUPPORT
|
||||
#include "Cart2KWidget.hxx"
|
||||
#endif
|
||||
|
||||
/**
|
||||
This is the standard Atari 2K cartridge. These cartridges
|
||||
|
@ -35,6 +38,8 @@ class System;
|
|||
*/
|
||||
class Cartridge2K : public Cartridge
|
||||
{
|
||||
friend class Cart2KWidget;
|
||||
|
||||
public:
|
||||
/**
|
||||
Create a new cartridge using the specified image
|
||||
|
@ -121,6 +126,18 @@ class Cartridge2K : public Cartridge
|
|||
*/
|
||||
string name() const { return "Cartridge2K"; }
|
||||
|
||||
#ifdef DEBUGGER_SUPPORT
|
||||
/**
|
||||
Get debugger widget responsible for accessing the inner workings
|
||||
of the cart.
|
||||
*/
|
||||
CartDebugWidget* debugWidget(GuiObject* boss,
|
||||
const GUI::Font& font, int x, int y, int w, int h)
|
||||
{
|
||||
return new Cartridge2KWidget(boss, font, x, y, w, h, *this);
|
||||
}
|
||||
#endif
|
||||
|
||||
public:
|
||||
/**
|
||||
Get the byte at the specified address
|
||||
|
|
|
@ -37,6 +37,8 @@ class System;
|
|||
*/
|
||||
class Cartridge4K : public Cartridge
|
||||
{
|
||||
friend class Cartridge4KWidget;
|
||||
|
||||
public:
|
||||
/**
|
||||
Create a new cartridge using the specified image
|
||||
|
|
Loading…
Reference in New Issue