summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author R. Belmont <rb6502@users.noreply.github.com>2014-03-03 03:06:41 +0000
committer R. Belmont <rb6502@users.noreply.github.com>2014-03-03 03:06:41 +0000
commit2dff1e75b0b635fe571578ada03c919787fbb481 (patch)
tree7768d496b9ae370d10333c623dd5a4838e701362 /src
parent91e2c229629bbd79ec1a4217859f379281aac889 (diff)
(MESS) apollo: More cleanup, devlegcy.h now gone. [R. Belmont]
Diffstat (limited to 'src')
-rw-r--r--src/mess/machine/apollo.c45
1 files changed, 14 insertions, 31 deletions
diff --git a/src/mess/machine/apollo.c b/src/mess/machine/apollo.c
index fd8c0b41ce0..15ed6de946b 100644
--- a/src/mess/machine/apollo.c
+++ b/src/mess/machine/apollo.c
@@ -29,18 +29,9 @@
*/
#include "includes/apollo.h"
-
#include "machine/pc_fdc.h"
#include "formats/apollo_dsk.h"
-#include "emuopts.h"
-#include "devlegcy.h"
-
-#if defined(APOLLO_FOR_LINUX)
-#include <fcntl.h>
-#include <unistd.h>
-#endif
-
#define APOLLO_IRQ_VECTOR 0xa0
#define APOLLO_IRQ_PTM 0
#define APOLLO_IRQ_SIO1 1
@@ -784,27 +775,6 @@ static const ptm6840_interface apollo_ptm_config = {
DN3000/DN3500 Realtime Calendar MC146818 at 0x8900/0x10900
***************************************************************************/
-static DEVICE_RESET( apollo_rtc )
-{
- address_space &space = device->machine().device(MAINCPU)->memory().space(AS_PROGRAM);
- apollo_state *state = device->machine().driver_data<apollo_state>();
- UINT8 year = state->apollo_rtc_r(space, 9);
-
- // change year according to configuration settings
- if (year < 20 && apollo_config(APOLLO_CONF_DATE_1990))
- {
- year+=80;
- state->apollo_rtc_w(space, 9, year);
- }
- else if (year >= 80 && !apollo_config(APOLLO_CONF_DATE_1990))
- {
- year -=80;
- state->apollo_rtc_w(space, 9, year);
- }
-
- //SLOG1(("reset apollo_rtc year=%d", year));
-}
-
WRITE8_MEMBER(apollo_state::apollo_rtc_w)
{
m_rtc->write(space, 0, offset);
@@ -1064,12 +1034,25 @@ MACHINE_START_MEMBER(apollo_state,apollo)
MACHINE_RESET_MEMBER(apollo_state,apollo)
{
+ address_space &space = m_maincpu->space(AS_PROGRAM);
+ UINT8 year = apollo_rtc_r(space, 9);
+
//MLOG1(("machine_reset_apollo"));
// set configuration
apollo_csr_set_servicemode(apollo_config(APOLLO_CONF_SERVICE_MODE));
- device_reset_apollo_rtc(machine().device(APOLLO_RTC_TAG));
+ // change year according to configuration settings
+ if (year < 20 && apollo_config(APOLLO_CONF_DATE_1990))
+ {
+ year+=80;
+ apollo_rtc_w(space, 9, year);
+ }
+ else if (year >= 80 && !apollo_config(APOLLO_CONF_DATE_1990))
+ {
+ year -=80;
+ apollo_rtc_w(space, 9, year);
+ }
ptm_counter = 0;
sio_output_data = 0xff;