summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author ajrhacker <ariedlmayer@massenergylab.com>2016-07-05 11:52:30 -0400
committer Angelo Salese <angelosa@users.noreply.github.com>2016-07-05 17:52:30 +0200
commit71053ad9dd8fe41f568de68c44e60337252f3c06 (patch)
treeb2aeb221413e16273c04fb61c8729b46d46da84c
parent20724e105cd5ddd93e56d0319cb1e4370c0fd50f (diff)
feversoc: Hook up EEPROM; remap buttons (#1028)
feversoc.cpp: Hook up EEPROM; remap buttons, hook up lamps and serial RTC [AJR]; rtc4543.cpp: More complete implementation with better logging features. Added JRC6355E variant used by feversoc. [AJR]
-rw-r--r--src/devices/machine/rtc4543.cpp255
-rw-r--r--src/devices/machine/rtc4543.h33
-rw-r--r--src/emu/output.cpp7
-rw-r--r--src/mame/drivers/feversoc.cpp64
4 files changed, 282 insertions, 77 deletions
diff --git a/src/devices/machine/rtc4543.cpp b/src/devices/machine/rtc4543.cpp
index ac1eba33e79..1351651550d 100644
--- a/src/devices/machine/rtc4543.cpp
+++ b/src/devices/machine/rtc4543.cpp
@@ -5,7 +5,8 @@
rtc4543.c - Epson R4543 real-time clock chip emulation
by R. Belmont
- TODO: writing (not done by System 12 or 23 so no test case)
+ JRC 6355E / NJU6355E is basically similar, but order of registers
+ is reversed and readouts happen on falling CLK edge.
**********************************************************************/
@@ -15,10 +16,22 @@
// MACROS / CONSTANTS
//**************************************************************************
-#define VERBOSE 0
+#define VERBOSE 1
+
+const char *rtc4543_device::s_reg_names[7] =
+{
+ "second",
+ "minute",
+ "hour",
+ "day of the week",
+ "day",
+ "month",
+ "year"
+};
+
//**************************************************************************
-// LIVE DEVICE
+// RTC4543 DEVICE
//**************************************************************************
// device type definition
@@ -32,7 +45,14 @@ const device_type RTC4543 = &device_creator<rtc4543_device>;
rtc4543_device::rtc4543_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: device_t(mconfig, RTC4543, "R4543 RTC", tag, owner, clock, "rtc4543", __FILE__),
device_rtc_interface(mconfig, *this),
- data_cb(*this), m_ce(0), m_clk(0), m_wr(0), m_data(0), m_shiftreg(0), m_curreg(0), m_curbit(0), m_clock_timer(nullptr)
+ data_cb(*this), m_ce(0), m_clk(0), m_wr(0), m_data(0), m_curbit(0), m_clock_timer(nullptr)
+{
+}
+
+rtc4543_device::rtc4543_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *filename)
+ : device_t(mconfig, type, name, tag, owner, clock, shortname, filename),
+ device_rtc_interface(mconfig, *this),
+ data_cb(*this), m_ce(0), m_clk(0), m_wr(0), m_data(0), m_curbit(0), m_clock_timer(nullptr)
{
}
@@ -54,9 +74,8 @@ void rtc4543_device::device_start()
save_item(NAME(m_clk));
save_item(NAME(m_wr));
save_item(NAME(m_data));
- save_item(NAME(m_shiftreg));
save_item(NAME(m_regs));
- save_item(NAME(m_curreg));
+ save_item(NAME(m_curbit));
}
@@ -72,8 +91,6 @@ void rtc4543_device::device_reset()
m_wr = 0;
m_clk = 0;
m_data = 0;
- m_shiftreg = 0;
- m_curreg = 0;
m_curbit = 0;
}
@@ -88,11 +105,6 @@ void rtc4543_device::device_timer(emu_timer &timer, device_timer_id id, int para
}
-static inline UINT8 make_bcd(UINT8 data)
-{
- return ((data / 10) << 4) | (data % 10);
-}
-
//-------------------------------------------------
// rtc_clock_updated -
//-------------------------------------------------
@@ -101,16 +113,13 @@ void rtc4543_device::rtc_clock_updated(int year, int month, int day, int day_of_
{
static const int weekday[7] = { 7, 1, 2, 3, 4, 5, 6 };
- m_regs[0] = make_bcd(second); // seconds (BCD, 0-59) in bits 0-6, bit 7 = battery low
- m_regs[1] = make_bcd(minute); // minutes (BCD, 0-59)
- m_regs[2] = make_bcd(hour); // hour (BCD, 0-23)
- m_regs[3] = make_bcd(weekday[day_of_week - 1]); // low nibble = day of the week
- m_regs[3] |= (make_bcd(day) & 0x0f) << 4; // high nibble = low digit of day
- m_regs[4] = (make_bcd(day) >> 4); // low nibble = high digit of day
- m_regs[4] |= (make_bcd(month & 0x0f) << 4); // high nibble = low digit of month
- m_regs[5] = make_bcd(month & 0x0f) >> 4; // low nibble = high digit of month
- m_regs[5] |= (make_bcd(year % 10) << 4); // high nibble = low digit of year
- m_regs[6] = make_bcd(year % 100) >> 4; // low nibble = tens digit of year (BCD, 0-9)
+ m_regs[0] = convert_to_bcd(second); // seconds (BCD, 0-59) in bits 0-6, bit 7 = battery low
+ m_regs[1] = convert_to_bcd(minute); // minutes (BCD, 0-59)
+ m_regs[2] = convert_to_bcd(hour); // hour (BCD, 0-23)
+ m_regs[3] = convert_to_bcd(weekday[day_of_week - 1]); // day of the week (1-7)
+ m_regs[4] = convert_to_bcd(day); // day (BCD, 1-31)
+ m_regs[5] = convert_to_bcd(month); // month (BCD, 1-12)
+ m_regs[6] = convert_to_bcd(year % 100); // year (BCD, 0-99)
}
//-------------------------------------------------
@@ -119,18 +128,21 @@ void rtc4543_device::rtc_clock_updated(int year, int month, int day, int day_of_
WRITE_LINE_MEMBER( rtc4543_device::ce_w )
{
- if (VERBOSE) printf("RTC4543 '%s' CE: %u\n", tag(), state);
-
if (!state && m_ce) // complete transfer
{
+ if (VERBOSE) logerror("CE falling edge\n", state);
}
else if (state && !m_ce) // start new data transfer
{
- m_curreg = 0;
+ if (VERBOSE) logerror("CE rising edge\n", state);
+
m_curbit = 0; // force immediate reload of output data
}
m_ce = state;
+
+ // timer disabled during writes
+ m_clock_timer->enable(!m_ce || !m_wr);
}
//-------------------------------------------------
@@ -139,7 +151,8 @@ WRITE_LINE_MEMBER( rtc4543_device::ce_w )
WRITE_LINE_MEMBER( rtc4543_device::wr_w )
{
- if (VERBOSE) logerror("RTC4543 '%s' WR: %u\n", tag(), state);
+ if (VERBOSE && (state != m_wr))
+ logerror("WR: %u\n", state);
m_wr = state;
}
@@ -150,33 +163,18 @@ WRITE_LINE_MEMBER( rtc4543_device::wr_w )
WRITE_LINE_MEMBER( rtc4543_device::clk_w )
{
- if (VERBOSE) logerror("RTC4543 '%s' CLK: %u\n", tag(), state);
-
- if (!m_ce) return;
-
- // rising edge - read data becomes valid here
- if (!m_clk && state)
+ if (m_ce)
{
- if (!m_wr)
+ int bit = m_curbit;
+ if (!m_clk && state)
+ {
+ clk_rising();
+ if (VERBOSE) logerror("CLK rising edge (I/O: %u, bit %d)\n", m_data, bit);
+ }
+ else if (m_clk && !state)
{
- // reload data?
- if ((m_curbit & 7) == 0)
- {
- m_shiftreg = m_regs[m_curreg++];
-
- if (VERBOSE)
- logerror("RTC4543 '%s' sending byte: %02x\n", tag(), m_shiftreg);
- }
-
- // shift data bit
- // note: output data does not change when clk at final bit
- if (m_curbit != 55)
- {
- m_data = m_shiftreg & 1;
- m_curbit++;
- m_shiftreg >>= 1;
- data_cb(m_data);
- }
+ clk_falling();
+ if (VERBOSE) logerror("CLK falling edge (I/O: %u, bit %d)\n", m_data, bit);
}
}
@@ -185,13 +183,40 @@ WRITE_LINE_MEMBER( rtc4543_device::clk_w )
//-------------------------------------------------
+// clk_rising - CLK rising edge trigger
+//-------------------------------------------------
+
+void rtc4543_device::clk_rising()
+{
+ // note: output data does not change when clk at final bit
+ if (m_curbit == 56)
+ return;
+
+ // rising edge - read/write data becomes valid here
+ if (!m_wr)
+ load_bit(m_curbit / 8);
+ else
+ store_bit(m_curbit / 8);
+
+ advance_bit();
+}
+
+
+//-------------------------------------------------
+// clk_falling - CLK falling edge trigger
+//-------------------------------------------------
+
+void rtc4543_device::clk_falling()
+{
+}
+
+
+//-------------------------------------------------
// data_w - I/O write
//-------------------------------------------------
WRITE_LINE_MEMBER( rtc4543_device::data_w )
{
- if (VERBOSE) logerror("RTC4543 '%s' I/O: %u\n", tag(), state);
-
m_data = state & 1;
}
@@ -204,3 +229,125 @@ READ_LINE_MEMBER( rtc4543_device::data_r )
{
return m_data;
}
+
+
+//-------------------------------------------------
+// load_bit - serial read from register
+//-------------------------------------------------
+
+void rtc4543_device::load_bit(int reg)
+{
+ assert(reg < ARRAY_LENGTH(m_regs));
+ int bit = m_curbit & 7;
+
+ // reload data?
+ if (VERBOSE)
+ {
+ if (bit == 0)
+ logerror("RTC sending low digit of %s: %x\n", s_reg_names[reg], m_regs[reg] & 0xf);
+ else if (bit == 4)
+ logerror("RTC sending high digit of %s: %x\n", s_reg_names[reg], (m_regs[reg] >> 4) & 0xf);
+ }
+
+ // shift data bit
+ m_data = (m_regs[reg] >> bit) & 1;
+ data_cb(m_data);
+}
+
+
+//-------------------------------------------------
+// store_bit - serial write
+//-------------------------------------------------
+
+void rtc4543_device::store_bit(int reg)
+{
+ assert(reg < ARRAY_LENGTH(m_regs));
+ int bit = m_curbit & 7;
+
+ m_regs[reg] &= ~(1 << bit);
+ m_regs[reg] |= m_data << bit;
+
+ if (VERBOSE)
+ {
+ if (bit == 7)
+ logerror("RTC received high digit of %s: %X\n", s_reg_names[reg], (m_regs[reg] >> 4) & 0xf);
+ else if (bit == 3)
+ logerror("RTC received low digit of %s: %X\n", s_reg_names[reg], m_regs[reg] & 0xf);
+ }
+}
+
+
+//-------------------------------------------------
+// advance_bit - increment the bit counter
+//-------------------------------------------------
+
+void rtc4543_device::advance_bit()
+{
+ m_curbit++;
+
+ // day-of-week register only takes 4 bits
+ if (m_curbit == 28)
+ {
+ // skip 4 bits, Brother Maynard
+ m_curbit += 4;
+ }
+
+ // update only occurs when a write goes all the way through
+ if (m_wr && m_curbit == 56)
+ set_time(false,
+ bcd_to_integer(m_regs[6]), // year
+ bcd_to_integer(m_regs[5]), // month
+ bcd_to_integer(m_regs[4]), // day
+ (m_regs[3] % 7) + 1, // day of week
+ bcd_to_integer(m_regs[2]), // hour
+ bcd_to_integer(m_regs[1]), // minute
+ bcd_to_integer(m_regs[0])); // second
+}
+
+
+//**************************************************************************
+// JRC 6355E DEVICE
+//**************************************************************************
+
+// device type definition
+const device_type JRC6355E = &device_creator<jrc6355e_device>;
+
+
+//-------------------------------------------------
+// jrc6355e_device - constructor
+//-------------------------------------------------
+
+jrc6355e_device::jrc6355e_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
+ : rtc4543_device(mconfig, JRC6355E, "JRC 6355E RTC", tag, owner, clock, "jrc6355e", __FILE__)
+{
+}
+
+
+//-------------------------------------------------
+// clk_rising - CLK rising edge trigger
+//-------------------------------------------------
+
+void jrc6355e_device::clk_rising()
+{
+ if (m_curbit == 56)
+ return;
+
+ if (m_wr)
+ store_bit(6 - (m_curbit / 8));
+
+ advance_bit();
+}
+
+
+//-------------------------------------------------
+// clk_falling - CLK falling edge trigger
+//-------------------------------------------------
+
+void jrc6355e_device::clk_falling()
+{
+ if (m_curbit == 56)
+ return;
+
+ if (!m_wr)
+ load_bit(6 - (m_curbit / 8));
+}
diff --git a/src/devices/machine/rtc4543.h b/src/devices/machine/rtc4543.h
index e32e37370ee..30a6e2d1ed7 100644
--- a/src/devices/machine/rtc4543.h
+++ b/src/devices/machine/rtc4543.h
@@ -26,6 +26,9 @@
#define MCFG_RTC4543_DATA_CALLBACK(_devcb) \
devcb = &rtc4543_device::set_data_cb(*device, DEVCB_##_devcb);
+#define MCFG_JRC6355E_ADD(_tag, _clock) \
+ MCFG_DEVICE_ADD(_tag, JRC6355E, _clock)
+
//**************************************************************************
@@ -37,9 +40,12 @@
class rtc4543_device : public device_t,
public device_rtc_interface
{
+ static const char *s_reg_names[7];
+
public:
// construction/destruction
rtc4543_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+ rtc4543_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *filename);
DECLARE_WRITE_LINE_MEMBER( ce_w );
DECLARE_WRITE_LINE_MEMBER( wr_w );
@@ -59,16 +65,20 @@ protected:
virtual void rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second) override;
virtual bool rtc_feature_leap_year() override { return true; }
-private:
+ // helpers
+ virtual void clk_rising();
+ virtual void clk_falling();
+ void load_bit(int reg);
+ void store_bit(int reg);
+ void advance_bit();
+
devcb_write_line data_cb;
int m_ce;
int m_clk;
int m_wr;
int m_data;
- int m_shiftreg;
int m_regs[7];
- int m_curreg;
int m_curbit;
// timers
@@ -76,7 +86,24 @@ private:
};
+
+// ======================> jrc6355e_device
+
+class jrc6355e_device : public rtc4543_device
+{
+public:
+ // construction/destruction
+ jrc6355e_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+
+protected:
+ // rtc4543 overrides
+ virtual void clk_rising() override;
+ virtual void clk_falling() override;
+};
+
+
// device type definition
extern const device_type RTC4543;
+extern const device_type JRC6355E;
#endif
diff --git a/src/emu/output.cpp b/src/emu/output.cpp
index 026e5f84ad0..fefbf78246c 100644
--- a/src/emu/output.cpp
+++ b/src/emu/output.cpp
@@ -11,6 +11,10 @@
#include "coreutil.h"
#include "modules/output/output_module.h"
+
+#define OUTPUT_VERBOSE 0
+
+
//**************************************************************************
// OUTPUT MANAGER
//**************************************************************************
@@ -102,6 +106,9 @@ void output_manager::set_value(const char *outname, INT32 value)
/* if the value is different, signal the notifier */
if (oldval != value)
{
+ if (OUTPUT_VERBOSE)
+ machine().logerror("Output %s = %d (was %d)\n", outname, value, oldval);
+
/* call the local notifiers first */
for (auto notify : item->notifylist)
(*notify.m_notifier)(outname, value, notify.m_param);
diff --git a/src/mame/drivers/feversoc.cpp b/src/mame/drivers/feversoc.cpp
index eb810a83fc4..d7e214ce64b 100644
--- a/src/mame/drivers/feversoc.cpp
+++ b/src/mame/drivers/feversoc.cpp
@@ -9,8 +9,11 @@ A down-grade of the Seibu SPI Hardware with SH-2 as main cpu.
driver by Angelo Salese & Nicola Salmoria
TODO:
-- Add eeprom emulation;
-- Real Time Clock emulation (uses a JRC 6355E / NJU6355E)
+- Make RTC writes actually go through (SH2 interrupt/timing issue?)
+- Determine what buttons 5-7 actually do
+- Find out where the NVRAM maps to
+- Layout including lamps
+- Add hopper, etc.
============================================================================
@@ -64,6 +67,8 @@ U0564 LH28F800SU OBJ4-1
#include "cpu/sh2/sh2.h"
#include "machine/seibuspi.h"
#include "sound/okim6295.h"
+#include "machine/eepromser.h"
+#include "machine/rtc4543.h"
class feversoc_state : public driver_device
@@ -75,10 +80,11 @@ public:
m_spriteram(*this, "spriteram"),
m_maincpu(*this, "maincpu"),
m_oki(*this, "oki"),
+ m_eeprom(*this, "eeprom"),
+ m_rtc(*this, "rtc"),
m_gfxdecode(*this, "gfxdecode"),
m_palette(*this, "palette") { }
- UINT16 m_x;
required_shared_ptr<UINT32> m_mainram;
required_shared_ptr<UINT32> m_spriteram;
DECLARE_READ32_MEMBER(in0_r);
@@ -89,6 +95,8 @@ public:
INTERRUPT_GEN_MEMBER(feversoc_irq);
required_device<sh2_device> m_maincpu;
required_device<okim6295_device> m_oki;
+ required_device<eeprom_serial_93cxx_device> m_eeprom;
+ required_device<jrc6355e_device> m_rtc;
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
};
@@ -135,15 +143,13 @@ READ32_MEMBER(feversoc_state::in0_r)
{
UINT32 io0 = (ioport("IN1")->read()&0xffff) << 16;
UINT32 io1 = (ioport("IN0")->read()&0xffff) << 0;
- m_x^=0x40; //vblank? eeprom read bit?
- return io0 | io1 | m_x;
+ return io0 | io1;
}
WRITE32_MEMBER(feversoc_state::output_w)
{
if(ACCESSING_BITS_16_31)
{
- /* probably eeprom stuff too */
machine().bookkeeping().coin_lockout_w(0,~data>>16 & 0x40);
machine().bookkeeping().coin_lockout_w(1,~data>>16 & 0x40);
machine().bookkeeping().coin_counter_w(0,data>>16 & 1);
@@ -151,10 +157,26 @@ WRITE32_MEMBER(feversoc_state::output_w)
machine().bookkeeping().coin_counter_w(1,data>>16 & 4);
//data>>16 & 8 coin hopper
m_oki->set_bank_base(0x40000 * (((data>>16) & 0x20)>>5));
+
+ m_eeprom->di_write((data & 0x80000000) ? 1 : 0);
+ m_eeprom->clk_write((data & 0x40000000) ? ASSERT_LINE : CLEAR_LINE);
+ m_eeprom->cs_write((data & 0x20000000) ? ASSERT_LINE : CLEAR_LINE);
+
+ m_rtc->data_w((data & 0x08000000) ? 1 : 0);
+ m_rtc->wr_w((data & 0x04000000) ? ASSERT_LINE : CLEAR_LINE);
+ m_rtc->clk_w((data & 0x02000000) ? ASSERT_LINE : CLEAR_LINE);
+ m_rtc->ce_w((data & 0x01000000) ? ASSERT_LINE : CLEAR_LINE);
}
if(ACCESSING_BITS_0_15)
{
- /* -xxx xxxx lamps*/
+ machine().output().set_lamp_value(1, BIT(data, 0)); // LAMP1
+ machine().output().set_lamp_value(2, BIT(data, 1)); // LAMP2
+ machine().output().set_lamp_value(3, BIT(data, 2)); // LAMP3
+ machine().output().set_lamp_value(4, BIT(data, 3)); // LAMP4
+ machine().output().set_lamp_value(5, BIT(data, 4)); // LAMP5
+ machine().output().set_lamp_value(6, BIT(data, 5)); // LAMP6
+ machine().output().set_lamp_value(7, BIT(data, 6)); // LAMP7
+
machine().bookkeeping().coin_counter_w(2,data & 0x2000); //key in
//data & 0x4000 key out
}
@@ -169,7 +191,7 @@ static ADDRESS_MAP_START( feversoc_map, AS_PROGRAM, 32, feversoc_state )
AM_RANGE(0x06000008, 0x0600000b) AM_READ(in0_r)
AM_RANGE(0x0600000c, 0x0600000f) AM_DEVREADWRITE8("oki", okim6295_device, read, write, 0x00ff0000)
// AM_RANGE(0x06010000, 0x06017fff) AM_RAM //contains RISE11 keys and other related stuff.
-// AM_RANGE(0x06010060, 0x06010063) //bit 0 almost certainly irq ack
+ AM_RANGE(0x06010060, 0x06010063) AM_WRITENOP
AM_RANGE(0x06018000, 0x06019fff) AM_RAM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette")
ADDRESS_MAP_END
@@ -200,11 +222,9 @@ static INPUT_PORTS_START( feversoc )
PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_SERVICE )
PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_SERVICE1 )
PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_COIN1 )
- PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) //hopper i/o
- PORT_DIPSETTING( 0x20, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_UNKNOWN ) // maybe eeprom in / vblank
- PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNUSED ) //PORT_NAME("Slottle") PORT_CODE(KEYCODE_Z)
+ PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_OTHER ) PORT_NAME("Hopper") PORT_TOGGLE PORT_CODE(KEYCODE_H)
+ PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_READ_LINE_DEVICE_MEMBER("eeprom", eeprom_serial_93cxx_device, do_read)
+ PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_READ_LINE_DEVICE_MEMBER("rtc", rtc4543_device, data_r)
PORT_DIPNAME( 0x0100, 0x0100, "DIP 1-1" )
PORT_DIPSETTING( 0x0100, DEF_STR( Off ) )
PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
@@ -230,13 +250,13 @@ static INPUT_PORTS_START( feversoc )
PORT_DIPSETTING( 0x8000, DEF_STR( Off ) )
PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
PORT_START("IN1")
- PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_SLOT_STOP1 )
- PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_SLOT_STOP2 )
- PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_SLOT_STOP3 )
- PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_GAMBLE_BET )
- PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_CODE(KEYCODE_V) // ?
- PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_CODE(KEYCODE_B) // ?
- PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON7 ) PORT_CODE(KEYCODE_N) // ?
+ PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_SLOT_STOP1 ) PORT_NAME("Stop 1 (BTN1)")
+ PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_SLOT_STOP2 ) PORT_NAME("Stop 2 (BTN2)")
+ PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_SLOT_STOP3 ) PORT_NAME("Stop 3 (BTN3)")
+ PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_GAMBLE_BET ) PORT_NAME("Bet (BTN4)")
+ PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_GAMBLE_HIGH ) PORT_NAME("BTN5") // ?
+ PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_GAMBLE_LOW ) PORT_NAME("BTN6") // ?
+ PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_GAMBLE_HALF ) PORT_NAME("BTN7") // ?
PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_SERVICE2 ) PORT_NAME("Reset")
PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED )
INPUT_PORTS_END
@@ -271,6 +291,10 @@ static MACHINE_CONFIG_START( feversoc, feversoc_state )
MCFG_SPEAKER_STANDARD_MONO("mono")
MCFG_OKIM6295_ADD("oki", MASTER_CLOCK/16, OKIM6295_PIN7_LOW) //pin 7 & frequency not verified (clock should be 28,6363 / n)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.6)
+
+ MCFG_EEPROM_SERIAL_93C56_ADD("eeprom")
+
+ MCFG_JRC6355E_ADD("rtc", XTAL_32_768kHz)
MACHINE_CONFIG_END
/***************************************************************************