Previous 15994 Revisions Next

r14679 Friday 2nd March, 2012 at 01:48:28 UTC by R. Belmont
Apollo: start actually resetting devices on "reset" opcode (nw)
[src/mess/drivers]apollo.c
[src/mess/includes]apollo.h
[src/mess/machine]sc499.c sc499.h

src/mess/machine/sc499.c
r14678r14679
917917            m_status |= SC499_STAT_IRQ;
918918         }
919919         break;
920      }
920      }                                                   
921921   }
922922}
923923
src/mess/machine/sc499.h
r14678r14679
7777   // static pointer to myself (nasty: used for logging and dma ...)
7878   static sc499_device *m_device;
7979
80   virtual void device_reset();
81
8082private:
8183   // device-level overrides
8284   virtual void device_start();
83   virtual void device_reset();
8485
8586   const char *cpu_context();
8687
src/mess/includes/apollo.h
r14678r14679
1616
1717#include "emu.h"
1818
19#include "cpu/m68000/m68000.h"
20#include "machine/terminal.h"
21#include "machine/ram.h"
22#include "machine/omti8621.h"
23#include "machine/sc499.h"
24#include "machine/3c505.h"
25#include "machine/68681.h"
26
1927#ifndef VERBOSE
2028#define VERBOSE 0
2129#endif
r14678r14679
93101//      : driver_device(machine, config) { }
94102
95103   apollo_state(const machine_config &mconfig, device_type type, const char *tag)
96         : driver_device(mconfig, type, tag) { }
104         : driver_device(mconfig, type, tag),
105            m_ctape(*this, APOLLO_CTAPE_TAG)
106            { }
97107
108    required_device<sc499_device> m_ctape;
109
98110   device_t *dma8237_1;
99111   device_t *dma8237_2;
100112   device_t *pic8259_master;
101113   device_t *pic8259_slave;
114   
102115};
103116
104117MACHINE_CONFIG_EXTERN( apollo );
src/mess/drivers/apollo.c
r14678r14679
2929
3030#include "includes/apollo.h"
3131#include "machine/apollo_kbd.h"
32#include "machine/omti8621.h"
33#include "machine/sc499.h"
34#include "machine/3c505.h"
35#include "machine/68681.h"
3632
3733#include "debugger.h"
3834
39#include "cpu/m68000/m68000.h"
4035#include "cpu/m68000/m68kcpu.h"
4136
42#include "machine/terminal.h"
43#include "machine/ram.h"
44
4537#include "sound/beep.h"
4638
4739#include "apollo_dsp.lh"
r14678r14679
10501042
10511043static void apollo_reset_instr_callback(device_t *device)
10521044{
1045   apollo_state *apollo = device->machine().driver_data<apollo_state>();
1046
10531047   DLOG1(("apollo_reset_instr_callback"));
1054   // FIXME: this will reset the CPU too
1055//  device->machine().schedule_soft_reset();    // needs to call reset on the devices other than the CPU
1048
1049    // reset non-CPU devices here
1050    apollo->m_ctape->device_reset();
10561051}
10571052
10581053/***************************************************************************

Previous 15994 Revisions Next


© 1998-2018 The MESS Team