Firmware: removed CPU_EMBEDDED #define as obsolete

Change-Id: I18f593d2abdc44d1d7dd48c5ef0e4bc19a9a0b88
This commit is contained in:
David Banks 2019-11-02 19:37:15 +00:00
parent 3b0286f692
commit fc651b7135
6 changed files with 4 additions and 29 deletions

View File

@ -39,7 +39,6 @@ char *cmdStrings[] = {
"continue", "continue",
"next", "next",
"step", "step",
#if defined(CPU_EMBEDDED)
"regs", "regs",
"dis", "dis",
"fill", "fill",
@ -55,7 +54,6 @@ char *cmdStrings[] = {
"test", "test",
"srec", "srec",
"special", "special",
#endif
"reset", "reset",
"trace", "trace",
"blist", "blist",
@ -81,7 +79,6 @@ void (*cmdFuncs[])(char *params) = {
doCmdContinue, doCmdContinue,
doCmdNext, doCmdNext,
doCmdStep, doCmdStep,
#if defined(CPU_EMBEDDED)
doCmdRegs, doCmdRegs,
doCmdDis, doCmdDis,
doCmdFill, doCmdFill,
@ -97,7 +94,6 @@ void (*cmdFuncs[])(char *params) = {
doCmdTest, doCmdTest,
doCmdSRec, doCmdSRec,
doCmdSpecial, doCmdSpecial,
#endif
doCmdReset, doCmdReset,
doCmdTrace, doCmdTrace,
doCmdList, doCmdList,
@ -508,7 +504,6 @@ void log_addr_data(int a, int d) {
log_char(d); log_char(d);
} }
#if defined(CPU_EMBEDDED)
void loadData(unsigned int data) { void loadData(unsigned int data) {
int i; int i;
for (i = 0; i <= 7; i++) { for (i = 0; i <= 7; i++) {
@ -628,8 +623,6 @@ void genericRead(char *params, unsigned int (*readFunc)()) {
memAddr++; memAddr++;
} }
#endif
/******************************************************** /********************************************************
* Logging Helpers * Logging Helpers
********************************************************/ ********************************************************/
@ -689,13 +682,11 @@ int logDetails() {
log_addr_data(b_addr, b_data); log_addr_data(b_addr, b_data);
} }
log0("\n"); log0("\n");
#if defined(CPU_EMBEDDED)
if (mode & B_RDWR_MASK) { if (mode & B_RDWR_MASK) {
// It's only safe to do this for brkpts, as it makes memory accesses // It's only safe to do this for brkpts, as it makes memory accesses
logCycleCount(OFFSET_BW_CNTL, OFFSET_BW_CNTH); logCycleCount(OFFSET_BW_CNTL, OFFSET_BW_CNTH);
disMem(i_addr); disMem(i_addr);
} }
#endif
return watch; return watch;
} }
@ -703,21 +694,13 @@ void logAddr() {
memAddr = hwRead16(OFFSET_IAL); memAddr = hwRead16(OFFSET_IAL);
// Update the serial console // Update the serial console
logCycleCount(OFFSET_CNTL, OFFSET_CNTH); logCycleCount(OFFSET_CNTL, OFFSET_CNTH);
#if defined(CPU_EMBEDDED)
//log0("%04X\n", i_addr); //log0("%04X\n", i_addr);
nextAddr = disMem(memAddr); nextAddr = disMem(memAddr);
#else
log0("%04X\n", memAddr);
#endif
return; return;
} }
void version() { void version() {
#if defined(CPU_EMBEDDED)
log0("%s In-Circuit Emulator version %s\n", NAME, VERSION); log0("%s In-Circuit Emulator version %s\n", NAME, VERSION);
#else
log0("%s Bus Monitor version %s\n", NAME, VERSION);
#endif
log0("Compiled at %s on %s\n",__TIME__,__DATE__); log0("Compiled at %s on %s\n",__TIME__,__DATE__);
log0("%d watches/breakpoints implemented\n",MAXBKPTS); log0("%d watches/breakpoints implemented\n",MAXBKPTS);
} }
@ -871,7 +854,6 @@ void genericBreakpoint(char *params, unsigned int mode) {
* Test Helpers * Test Helpers
********************************************************/ ********************************************************/
#if defined(CPU_EMBEDDED)
char *testNames[6] = { char *testNames[6] = {
"Fixed", "Fixed",
"Checkerboard", "Checkerboard",
@ -944,7 +926,6 @@ void test(unsigned int start, unsigned int end, int data) {
log0(": passed\n"); log0(": passed\n");
} }
} }
#endif // CPU_EMBEDDED
int pollForEvents() { int pollForEvents() {
int cont = 1; int cont = 1;
@ -1029,8 +1010,6 @@ void doCmdReset(char *params) {
logAddr(); logAddr();
} }
#if defined(CPU_EMBEDDED)
// doCmdRegs is now in regs<cpu>.c // doCmdRegs is now in regs<cpu>.c
void doCmdDis(char *params) { void doCmdDis(char *params) {
@ -1245,8 +1224,6 @@ void doCmdSpecial(char *params) {
logSpecial("IRQ", CTRL_PORT & (1 << SPECIAL_0)); logSpecial("IRQ", CTRL_PORT & (1 << SPECIAL_0));
} }
#endif // CPU_EMBEDDED
void doCmdTrace(char *params) { void doCmdTrace(char *params) {
long i; long i;
sscanf(params, "%ld", &i); sscanf(params, "%ld", &i);

View File

@ -20,7 +20,6 @@
unsigned int hwRead8(unsigned int offset); unsigned int hwRead8(unsigned int offset);
unsigned int hwRead16(unsigned int offset); unsigned int hwRead16(unsigned int offset);
#if defined(CPU_EMBEDDED)
unsigned int disMem(unsigned int addr); unsigned int disMem(unsigned int addr);
void loadData(unsigned int data); void loadData(unsigned int data);
void loadAddr(unsigned int addr); void loadAddr(unsigned int addr);
@ -29,7 +28,6 @@ unsigned int readMemByteInc();
void writeMemByte(); void writeMemByte();
void writeMemByteInc(); void writeMemByteInc();
unsigned int disMem(unsigned int addr); unsigned int disMem(unsigned int addr);
#endif
void doCmdBreak(char *params, unsigned int mode); void doCmdBreak(char *params, unsigned int mode);
void doCmdBreakI(char *params); void doCmdBreakI(char *params);

View File

@ -1,5 +1,5 @@
# CPU specfic build flags # CPU specfic build flags
CPU_CFLAGS = -DCPU_6502 -DCPU_EMBEDDED CPU_CFLAGS = -DCPU_6502
# CPU specfic object files # CPU specfic object files
CPU_OBJECTS = dis6502.o regs6502.o CPU_OBJECTS = dis6502.o regs6502.o

View File

@ -1,5 +1,5 @@
# CPU specfic build flags # CPU specfic build flags
CPU_CFLAGS = -DCPU_65C02 -DCPU_EMBEDDED CPU_CFLAGS = -DCPU_65C02
# CPU specfic object files # CPU specfic object files
CPU_OBJECTS = dis65c02.o regs6502.o CPU_OBJECTS = dis65c02.o regs6502.o

View File

@ -1,5 +1,5 @@
# CPU specfic build flags # CPU specfic build flags
CPU_CFLAGS = -DCPU_6809 -DCPU_EMBEDDED CPU_CFLAGS = -DCPU_6809
# CPU specfic object files # CPU specfic object files
CPU_OBJECTS = dis6809.o regs6809.o CPU_OBJECTS = dis6809.o regs6809.o

View File

@ -1,5 +1,5 @@
# CPU specfic build flags # CPU specfic build flags
CPU_CFLAGS = -DCPU_Z80 -DCPU_EMBEDDED CPU_CFLAGS = -DCPU_Z80
# CPU specfic object files # CPU specfic object files
CPU_OBJECTS = disz80.o regsz80.o CPU_OBJECTS = disz80.o regsz80.o