Previous 199869 Revisions Next

r40547 Sunday 30th August, 2015 at 09:32:23 UTC by Sergey Svishchev
at, at_keybc: hook up Display Switch
[src/emu/machine]68230pit.c at_keybc.c at_keybc.h
[src/mess/drivers]at.c besta.c

trunk/src/emu/machine/68230pit.c
r249058r249059
131131                m_pbddr = data;
132132                break;
133133
134        case PIT_68230_PCDDR:
135                m_pcddr = data;
136                break;
137
138134        case PIT_68230_PACR:
139135                m_pacr = data;
140136                // callbacks
r249058r249059
209205                data = m_pbddr;
210206                break;
211207
212        case PIT_68230_PCDDR:
213                data = m_pcddr;
214                break;
215
216208        case PIT_68230_PACR:
217209                data = m_pacr;
218210                break;
trunk/src/emu/machine/at_keybc.c
r249058r249059
2424   AM_RANGE(MCS48_PORT_P1, MCS48_PORT_P1) AM_READ( p1_r)
2525   AM_RANGE(MCS48_PORT_P2, MCS48_PORT_P2) AM_READWRITE(p2_r, p2_w)
2626ADDRESS_MAP_END
27
28static INPUT_PORTS_START( at_keybc )
29   PORT_START("DSW")
30   PORT_BIT(     0xbf, 0xbf, IPT_UNUSED )
31   PORT_DIPNAME( 0x40, 0x40, "Display switch")
32   PORT_DIPSETTING(    0x40, "Monochrome adapter" )
33   PORT_DIPSETTING(    0x00, "Color/Graphics adapter" )
34INPUT_PORTS_END
35
2736// machine fragment
2837static MACHINE_CONFIG_FRAGMENT( at_keybc )
2938   MCFG_CPU_ADD("at_keybc", I8042, DERIVED_CLOCK(1,1))
r249058r249059
7281}
7382
7483//-------------------------------------------------
84//  input_ports - device-specific input ports
85//-------------------------------------------------
86
87ioport_constructor at_keyboard_controller_device::device_input_ports() const
88{
89   return INPUT_PORTS_NAME( at_keybc );
90}
91
92//-------------------------------------------------
7593//  machine_config_additions - return a pointer to
7694//  the device's machine fragment
7795//-------------------------------------------------
r249058r249059
139157*/
140158READ8_MEMBER( at_keyboard_controller_device::p1_r )
141159{
142   return 0xbf;
160   return ioport("DSW")->read();
143161}
144162
145163READ8_MEMBER( at_keyboard_controller_device::p2_r )
trunk/src/emu/machine/at_keybc.h
r249058r249059
7979   virtual void device_reset();
8080
8181   virtual const rom_entry *device_rom_region() const;
82   virtual ioport_constructor device_input_ports() const;
8283   virtual machine_config_constructor device_mconfig_additions() const;
8384
8485private:
trunk/src/mess/drivers/at.c
r249058r249059
264264
265265
266266static INPUT_PORTS_START( atcga )
267   PORT_START("DSW0")
268   PORT_DIPNAME( 0xc0, 0x40, "Number of floppy drives")
269   PORT_DIPSETTING(    0x00, "1" )
270   PORT_DIPSETTING(    0x40, "2" )
271   PORT_DIPSETTING(    0x80, "3" )
272   PORT_DIPSETTING(    0xc0, "4" )
273   PORT_DIPNAME( 0x30, 0x00, "Graphics adapter")
274   PORT_DIPSETTING(    0x00, "EGA/VGA" )
275   PORT_DIPSETTING(    0x10, "Color 40x25" )
276   PORT_DIPSETTING(    0x20, "Color 80x25" )
277   PORT_DIPSETTING(    0x30, "Monochrome" )
278   PORT_DIPNAME( 0x0c, 0x0c, "RAM banks")
279   PORT_DIPSETTING(    0x00, "1 - 16  64 256K" )
280   PORT_DIPSETTING(    0x04, "2 - 32 128 512K" )
281   PORT_DIPSETTING(    0x08, "3 - 48 192 576K" )
282   PORT_DIPSETTING(    0x0c, "4 - 64 256 640K" )
283   PORT_DIPNAME( 0x02, 0x00, "80387 installed")
284   PORT_DIPSETTING(    0x00, DEF_STR( No ) )
285   PORT_DIPSETTING(    0x02, DEF_STR( Yes ) )
286   PORT_DIPNAME( 0x01, 0x01, "Floppy installed")
287   PORT_DIPSETTING(    0x00, DEF_STR( No ) )
288   PORT_DIPSETTING(    0x01, DEF_STR( Yes ) )
289267INPUT_PORTS_END
290268
291269static INPUT_PORTS_START( atvga )
r249058r249059
302280   PORT_DIPNAME( 0x01, 0x01, "VGA 4")
303281   PORT_DIPSETTING(    0x01, DEF_STR( Off ) )
304282   PORT_DIPSETTING(    0x00, DEF_STR( On ) )
305
306   PORT_START("DSW0")
307   PORT_DIPNAME( 0xc0, 0x40, "Number of floppy drives")
308   PORT_DIPSETTING(    0x00, "1" )
309   PORT_DIPSETTING(    0x40, "2" )
310   PORT_DIPSETTING(    0x80, "3" )
311   PORT_DIPSETTING(    0xc0, "4" )
312   PORT_DIPNAME( 0x30, 0x00, "Graphics adapter")
313   PORT_DIPSETTING(    0x00, "EGA/VGA" )
314   PORT_DIPSETTING(    0x10, "Color 40x25" )
315   PORT_DIPSETTING(    0x20, "Color 80x25" )
316   PORT_DIPSETTING(    0x30, "Monochrome" )
317   PORT_DIPNAME( 0x0c, 0x0c, "RAM banks")
318   PORT_DIPSETTING(    0x00, "1 - 16  64 256K" )
319   PORT_DIPSETTING(    0x04, "2 - 32 128 512K" )
320   PORT_DIPSETTING(    0x08, "3 - 48 192 576K" )
321   PORT_DIPSETTING(    0x0c, "4 - 64 256 640K" )
322   PORT_DIPNAME( 0x02, 0x00, "80387 installed")
323   PORT_DIPSETTING(    0x00, DEF_STR( No ) )
324   PORT_DIPSETTING(    0x02, DEF_STR( Yes ) )
325   PORT_DIPNAME( 0x01, 0x01, "Floppy installed")
326   PORT_DIPSETTING(    0x00, DEF_STR( No ) )
327   PORT_DIPSETTING(    0x01, DEF_STR( Yes ) )
328283INPUT_PORTS_END
329284
330285WRITE_LINE_MEMBER( at_state::at_mc146818_irq )
trunk/src/mess/drivers/besta.c
r249058r249059
1010
1111#include "emu.h"
1212#include "cpu/m68000/m68000.h"
13#include "machine/68230pit.h"
1413#include "machine/terminal.h"
1514
1615#define VERBOSE_DBG 1       /* general debug messages */
r249058r249059
3332   besta_state(const machine_config &mconfig, device_type type, const char *tag)
3433      : driver_device(mconfig, type, tag),
3534      m_maincpu(*this, "maincpu"),
36      m_pit1 (*this, "pit1"),
37      m_pit2 (*this, "pit2"),
3835      m_terminal(*this, TERMINAL_TAG),
3936      m_p_ram(*this, "p_ram")
4037   {
r249058r249059
4744   UINT8 m_mpcc_regs[32];
4845
4946   required_device<cpu_device> m_maincpu;
50   required_device<pit68230_device> m_pit1;
51   required_device<pit68230_device> m_pit2;
5247   virtual void machine_reset();
5348
5449   required_device<generic_terminal_device> m_terminal;
r249058r249059
10196
10297static ADDRESS_MAP_START(besta_mem, AS_PROGRAM, 32, besta_state)
10398   AM_RANGE(0x00000000, 0x001fffff) AM_RAM AM_SHARE("p_ram")       // local bus DRAM, 4MB
104//   AM_RANGE(0x08010000, 0x08011fff) AM_RAM                         // unknown -- accessed by cp31dssp
105//   AM_RANGE(0xfca03500, 0xfca0350f) AM_READWRITE8(iscsi_reg_r, iscsi_reg_w, 0xffffffff)
106   AM_RANGE(0xff000000, 0xff00ffff) AM_ROM AM_REGION("user1", 0)   // actual mapping is up to 0xff03ffff
99//  AM_RANGE(0x08010000, 0x08011fff) AM_RAM                         // unknown -- accessed by cp31dssp
100   AM_RANGE(0xff000000, 0xff00ffff) AM_ROM AM_REGION("user1",0)    // actual mapping is up to 0xff03ffff
107101   AM_RANGE(0xff040000, 0xff07ffff) AM_RAM                         // onboard SRAM
108//   AM_RANGE(0xff800000, 0xff80001f) AM_DEVREADWRITE8("mpcc", mpcc68561_t, reg_r, reg_w, 0xffffffff)
109   AM_RANGE(0xff800000, 0xff80001f) AM_READWRITE8(mpcc_reg_r, mpcc_reg_w, 0xffffffff) // console
110   AM_RANGE(0xff800200, 0xff800237) AM_DEVREADWRITE8 ("pit2", pit68230_device, read, write, 0xffffffff)
111//   AM_RANGE(0xff800400, 0xff800xxx) // ??? -- shows up in cp31dssp log
112//   AM_RANGE(0xff800800, 0xff800xxx) // 68153 BIM
113//   AM_RANGE(0xff800a00, 0xff800xxx) // 62421 RTC
114   AM_RANGE(0xff800c00, 0xff800c37) AM_DEVREADWRITE8 ("pit1", pit68230_device, read, write, 0xffffffff)
115//   AM_RANGE(0xff800e00, 0xff800xxx) // PIT3?
102//  68561 MPCC (console)
103//  AM_RANGE(0xff800000, 0xff80001f) AM_DEVREADWRITE8("mpcc", mpcc68561_t, reg_r, reg_w, 0xffffffff)
104   AM_RANGE(0xff800000, 0xff80001f) AM_READWRITE8(mpcc_reg_r, mpcc_reg_w, 0xffffffff)
105//  AM_RANGE(0xff800200, 0xff800xxx) // 68230 PIT2
106//  AM_RANGE(0xff800400, 0xff800xxx) // ??? -- shows up in cp31dssp log
107//  AM_RANGE(0xff800800, 0xff800xxx) // BIM
108//  AM_RANGE(0xff800a00, 0xff800xxx) // 62421 RTC
109//  AM_RANGE(0xff800c00, 0xff800xxx) // 68230 PIT
116110ADDRESS_MAP_END
117111
118112/* Input ports */
r249058r249059
137131   MCFG_CPU_ADD("maincpu", M68030, 2*16670000)
138132   MCFG_CPU_PROGRAM_MAP(besta_mem)
139133
140   MCFG_DEVICE_ADD ("pit1", PIT68230, 16670000 / 2)   // XXX verify clock
141
142   MCFG_DEVICE_ADD ("pit2", PIT68230, 16670000 / 2)   // XXX verify clock
143
144134   MCFG_DEVICE_ADD(TERMINAL_TAG, GENERIC_TERMINAL, 0)
145135   MCFG_GENERIC_TERMINAL_KEYBOARD_CB(WRITE8(besta_state, kbd_put))
146136MACHINE_CONFIG_END
r249058r249059
161151/* Driver */
162152
163153/*    YEAR  NAME    PARENT  COMPAT   MACHINE    INPUT                 INIT    COMPANY         FULLNAME       FLAGS */
164COMP( 1988, besta88,  0,      0,     besta,     besta,   driver_device,  0,  "Sapsan", "Besta-88", MACHINE_NOT_WORKING | MACHINE_NO_SOUND_HW)
154COMP( 1988, besta88,  0,      0,     besta,     besta,   driver_device,  0,  "Sapsan", "Besta-88", MACHINE_NOT_WORKING | MACHINE_NO_SOUND)


Previous 199869 Revisions Next


© 1997-2024 The MAME Team