summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/devices/bus/a2bus/a2themill.cpp22
-rw-r--r--src/devices/bus/a2bus/a2themill.h3
-rw-r--r--src/devices/bus/amiga/zorro/buddha.cpp32
-rw-r--r--src/devices/bus/gio64/newport.cpp7
-rw-r--r--src/devices/bus/gio64/newport.h2
-rw-r--r--src/devices/bus/hp9845_io/98036.cpp505
-rw-r--r--src/devices/bus/hp9845_io/98036.h96
-rw-r--r--src/devices/bus/hp9845_io/hp9845_io.cpp2
-rw-r--r--src/devices/bus/hp_ipc_io/82919.cpp252
-rw-r--r--src/devices/bus/hp_ipc_io/82919.h73
-rw-r--r--src/devices/bus/hp_ipc_io/hp_ipc_io.cpp86
-rw-r--r--src/devices/bus/hp_ipc_io/hp_ipc_io.h82
-rw-r--r--src/devices/bus/nubus/nubus_image.cpp4
-rw-r--r--src/devices/bus/odyssey2/4in1.cpp53
-rw-r--r--src/devices/bus/odyssey2/4in1.h47
-rw-r--r--src/devices/bus/odyssey2/chess.cpp77
-rw-r--r--src/devices/bus/odyssey2/chess.h26
-rw-r--r--src/devices/bus/odyssey2/rom.cpp11
-rw-r--r--src/devices/bus/odyssey2/rom.h5
-rw-r--r--src/devices/bus/odyssey2/slot.cpp15
-rw-r--r--src/devices/bus/odyssey2/slot.h13
-rw-r--r--src/devices/bus/odyssey2/voice.cpp63
-rw-r--r--src/devices/bus/odyssey2/voice.h28
-rw-r--r--src/devices/bus/spectrum/exp.cpp2
-rw-r--r--src/devices/bus/spectrum/kempdisc.cpp90
-rw-r--r--src/devices/bus/spectrum/kempdisc.h17
-rw-r--r--src/devices/bus/spectrum/lprint.cpp71
-rw-r--r--src/devices/bus/spectrum/lprint.h28
-rw-r--r--src/devices/cpu/arm7/arm7thmb.cpp28
-rw-r--r--src/devices/cpu/gigatron/gigatron.cpp128
-rw-r--r--src/devices/cpu/gigatron/gigatron.h11
-rw-r--r--src/devices/cpu/h16/hd641016.cpp2
-rw-r--r--src/devices/cpu/hpc/hpcdasm.cpp34
-rw-r--r--src/devices/cpu/i860/i860dec.hxx35
-rw-r--r--src/devices/cpu/m6502/oxavix2000.lst4
-rw-r--r--src/devices/cpu/z80/kc82.cpp247
-rw-r--r--src/devices/cpu/z80/kc82.h70
-rw-r--r--src/devices/cpu/z80/kl5c80a12.cpp225
-rw-r--r--src/devices/cpu/z80/kl5c80a12.h40
-rw-r--r--src/devices/cpu/z80/kl5c80a16.cpp98
-rw-r--r--src/devices/cpu/z80/kl5c80a16.h56
-rw-r--r--src/devices/cpu/z80/kp69.cpp477
-rw-r--r--src/devices/cpu/z80/kp69.h105
-rw-r--r--src/devices/cpu/z80/ky80.cpp56
-rw-r--r--src/devices/cpu/z80/ky80.h42
-rw-r--r--src/devices/cpu/z80/z80.cpp74
-rw-r--r--src/devices/cpu/z80/z80.h3
-rw-r--r--src/devices/machine/6821pia.h2
-rw-r--r--src/devices/machine/dp8390.cpp2
-rw-r--r--src/devices/machine/gayle.cpp8
-rw-r--r--src/devices/machine/mc6843.cpp61
-rw-r--r--src/devices/machine/mc6843.h2
-rw-r--r--src/devices/machine/mc68681.cpp143
-rw-r--r--src/devices/machine/mc68681.h9
-rw-r--r--src/devices/machine/netlist.cpp35
-rw-r--r--src/devices/machine/sensorboard.cpp40
-rw-r--r--src/devices/machine/sensorboard.h4
-rw-r--r--src/devices/sound/k054539.cpp9
-rw-r--r--src/devices/sound/k054539.h2
-rw-r--r--src/devices/video/ef9340_1.cpp2
-rw-r--r--src/devices/video/ef9340_1.h2
-rw-r--r--src/devices/video/hlcd0438.cpp41
-rw-r--r--src/devices/video/hlcd0438.h14
-rw-r--r--src/devices/video/i8244.cpp302
-rw-r--r--src/devices/video/i8244.h24
-rw-r--r--src/devices/video/voodoo.cpp38
-rw-r--r--src/emu/addrmap.h1
-rw-r--r--src/emu/debug/debugcmd.cpp112
-rw-r--r--src/emu/debug/debugcmd.h1
-rw-r--r--src/emu/debug/debughlp.cpp17
-rw-r--r--src/emu/emuopts.cpp1
-rw-r--r--src/emu/emuopts.h2
-rw-r--r--src/emu/rendlay.cpp4
-rw-r--r--src/emu/speaker.cpp85
-rw-r--r--src/emu/speaker.h19
-rw-r--r--src/emu/xtal.cpp10
-rw-r--r--src/lib/netlist/.gitignore2
-rw-r--r--src/lib/netlist/analog/nld_mosfet.cpp2
-rw-r--r--src/lib/netlist/build/doxygen.conf2
-rw-r--r--src/lib/netlist/build/makefile14
-rw-r--r--src/lib/netlist/build/nltool.help2man5
-rw-r--r--src/lib/netlist/core/analog.h162
-rw-r--r--src/lib/netlist/core/base_objects.h113
-rw-r--r--src/lib/netlist/core/device.h163
-rw-r--r--src/lib/netlist/core/logic.h208
-rw-r--r--src/lib/netlist/core/netlist_state.h275
-rw-r--r--src/lib/netlist/core/nets.h2
-rw-r--r--src/lib/netlist/core/object_array.h225
-rw-r--r--src/lib/netlist/core/param.h7
-rw-r--r--src/lib/netlist/core/queue.h114
-rw-r--r--src/lib/netlist/core/setup.h18
-rw-r--r--src/lib/netlist/devices/net_lib.cpp46
-rw-r--r--src/lib/netlist/devices/net_lib.h18
-rw-r--r--src/lib/netlist/devices/nld_2102A.cpp49
-rw-r--r--src/lib/netlist/devices/nld_2102A.h43
-rw-r--r--src/lib/netlist/devices/nld_4006.cpp67
-rw-r--r--src/lib/netlist/devices/nld_4006.h38
-rw-r--r--src/lib/netlist/devices/nld_4013.cpp68
-rw-r--r--src/lib/netlist/devices/nld_4013.h41
-rw-r--r--src/lib/netlist/devices/nld_4017.cpp118
-rw-r--r--src/lib/netlist/devices/nld_4017.h15
-rw-r--r--src/lib/netlist/devices/nld_4020.cpp105
-rw-r--r--src/lib/netlist/devices/nld_4020.h26
-rw-r--r--src/lib/netlist/devices/nld_4053.cpp143
-rw-r--r--src/lib/netlist/devices/nld_4053.h13
-rw-r--r--src/lib/netlist/devices/nld_4066.cpp18
-rw-r--r--src/lib/netlist/devices/nld_4066.h20
-rw-r--r--src/lib/netlist/devices/nld_4316.cpp19
-rw-r--r--src/lib/netlist/devices/nld_4316.h21
-rw-r--r--src/lib/netlist/devices/nld_74107.cpp97
-rw-r--r--src/lib/netlist/devices/nld_74107.h81
-rw-r--r--src/lib/netlist/devices/nld_74113.cpp118
-rw-r--r--src/lib/netlist/devices/nld_74113.h79
-rw-r--r--src/lib/netlist/devices/nld_74123.cpp43
-rw-r--r--src/lib/netlist/devices/nld_74123.h45
-rw-r--r--src/lib/netlist/devices/nld_74125.cpp18
-rw-r--r--src/lib/netlist/devices/nld_74153.cpp78
-rw-r--r--src/lib/netlist/devices/nld_74153.h58
-rw-r--r--src/lib/netlist/devices/nld_74161.cpp1
-rw-r--r--src/lib/netlist/devices/nld_74163.cpp1
-rw-r--r--src/lib/netlist/devices/nld_74164.cpp65
-rw-r--r--src/lib/netlist/devices/nld_74164.h52
-rw-r--r--src/lib/netlist/devices/nld_74165.cpp48
-rw-r--r--src/lib/netlist/devices/nld_74165.h45
-rw-r--r--src/lib/netlist/devices/nld_74166.cpp48
-rw-r--r--src/lib/netlist/devices/nld_74166.h46
-rw-r--r--src/lib/netlist/devices/nld_74174.cpp150
-rw-r--r--src/lib/netlist/devices/nld_74174.h53
-rw-r--r--src/lib/netlist/devices/nld_74175.cpp30
-rw-r--r--src/lib/netlist/devices/nld_74175.h32
-rw-r--r--src/lib/netlist/devices/nld_74192.cpp23
-rw-r--r--src/lib/netlist/devices/nld_74192.h25
-rw-r--r--src/lib/netlist/devices/nld_74193.cpp20
-rw-r--r--src/lib/netlist/devices/nld_74193.h22
-rw-r--r--src/lib/netlist/devices/nld_74194.cpp19
-rw-r--r--src/lib/netlist/devices/nld_74194.h23
-rw-r--r--src/lib/netlist/devices/nld_74365.cpp17
-rw-r--r--src/lib/netlist/devices/nld_74365.h22
-rw-r--r--src/lib/netlist/devices/nld_74377.cpp45
-rw-r--r--src/lib/netlist/devices/nld_74377.h47
-rw-r--r--src/lib/netlist/devices/nld_74393.cpp49
-rw-r--r--src/lib/netlist/devices/nld_74393.h30
-rw-r--r--src/lib/netlist/devices/nld_7442.cpp105
-rw-r--r--src/lib/netlist/devices/nld_7442.h63
-rw-r--r--src/lib/netlist/devices/nld_7448.cpp50
-rw-r--r--src/lib/netlist/devices/nld_7448.h38
-rw-r--r--src/lib/netlist/devices/nld_7450.cpp54
-rw-r--r--src/lib/netlist/devices/nld_7450.h34
-rw-r--r--src/lib/netlist/devices/nld_7473.cpp118
-rw-r--r--src/lib/netlist/devices/nld_7473.h78
-rw-r--r--src/lib/netlist/devices/nld_7474.cpp70
-rw-r--r--src/lib/netlist/devices/nld_7474.h52
-rw-r--r--src/lib/netlist/devices/nld_7475.cpp225
-rw-r--r--src/lib/netlist/devices/nld_7475.h57
-rw-r--r--src/lib/netlist/devices/nld_7483.cpp51
-rw-r--r--src/lib/netlist/devices/nld_7483.h42
-rw-r--r--src/lib/netlist/devices/nld_7485.cpp64
-rw-r--r--src/lib/netlist/devices/nld_7485.h40
-rw-r--r--src/lib/netlist/devices/nld_7490.cpp77
-rw-r--r--src/lib/netlist/devices/nld_7490.h67
-rw-r--r--src/lib/netlist/devices/nld_7492.cpp74
-rw-r--r--src/lib/netlist/devices/nld_7492.h63
-rw-r--r--src/lib/netlist/devices/nld_7493.cpp77
-rw-r--r--src/lib/netlist/devices/nld_7493.h67
-rw-r--r--src/lib/netlist/devices/nld_7497.cpp60
-rw-r--r--src/lib/netlist/devices/nld_7497.h52
-rw-r--r--src/lib/netlist/devices/nld_74ls629.cpp98
-rw-r--r--src/lib/netlist/devices/nld_74ls629.h31
-rw-r--r--src/lib/netlist/devices/nld_82S115.cpp63
-rw-r--r--src/lib/netlist/devices/nld_82S115.h46
-rw-r--r--src/lib/netlist/devices/nld_82S16.cpp53
-rw-r--r--src/lib/netlist/devices/nld_82S16.h22
-rw-r--r--src/lib/netlist/devices/nld_9310.cpp1
-rw-r--r--src/lib/netlist/devices/nld_9316.cpp77
-rw-r--r--src/lib/netlist/devices/nld_9316.h108
-rw-r--r--src/lib/netlist/devices/nld_9316_base.hxx34
-rw-r--r--src/lib/netlist/devices/nld_9322.cpp109
-rw-r--r--src/lib/netlist/devices/nld_9322.h38
-rw-r--r--src/lib/netlist/devices/nld_am2847.cpp13
-rw-r--r--src/lib/netlist/devices/nld_am2847.h17
-rw-r--r--src/lib/netlist/devices/nld_devinc.h440
-rw-r--r--src/lib/netlist/devices/nld_dm9314.cpp13
-rw-r--r--src/lib/netlist/devices/nld_dm9314.h17
-rw-r--r--src/lib/netlist/devices/nld_dm9334.cpp57
-rw-r--r--src/lib/netlist/devices/nld_dm9334.h61
-rw-r--r--src/lib/netlist/devices/nld_log.cpp14
-rw-r--r--src/lib/netlist/devices/nld_log.h14
-rw-r--r--src/lib/netlist/devices/nld_mm5837.cpp13
-rw-r--r--src/lib/netlist/devices/nld_mm5837.h15
-rw-r--r--src/lib/netlist/devices/nld_r2r_dac.cpp40
-rw-r--r--src/lib/netlist/devices/nld_r2r_dac.h42
-rw-r--r--src/lib/netlist/devices/nld_tms4800.cpp20
-rw-r--r--src/lib/netlist/devices/nld_tms4800.h24
-rw-r--r--src/lib/netlist/devices/nld_tristate.cpp2
-rw-r--r--src/lib/netlist/devices/nld_tristate.h6
-rw-r--r--src/lib/netlist/devices/nlid_system.h4
-rw-r--r--src/lib/netlist/devices/nlid_truthtable.cpp3
-rw-r--r--src/lib/netlist/examples/sn74ls629_osc.c1
-rw-r--r--src/lib/netlist/generated/static_solvers.cpp4088
-rw-r--r--src/lib/netlist/macro/nlm_base.cpp6
-rw-r--r--src/lib/netlist/macro/nlm_cd4xxx.cpp627
-rw-r--r--src/lib/netlist/macro/nlm_cd4xxx.h34
-rw-r--r--src/lib/netlist/macro/nlm_opamp.h2
-rw-r--r--src/lib/netlist/macro/nlm_other.h2
-rw-r--r--src/lib/netlist/macro/nlm_roms.cpp125
-rw-r--r--src/lib/netlist/macro/nlm_roms.h12
-rw-r--r--src/lib/netlist/macro/nlm_ttl74xx.cpp3289
-rw-r--r--src/lib/netlist/macro/nlm_ttl74xx.h128
-rw-r--r--src/lib/netlist/nl_base.cpp44
-rw-r--r--src/lib/netlist/nl_base.h901
-rw-r--r--src/lib/netlist/nl_errstr.h5
-rw-r--r--src/lib/netlist/nl_factory.h1
-rw-r--r--src/lib/netlist/nl_parser.cpp109
-rw-r--r--src/lib/netlist/nl_parser.h24
-rw-r--r--src/lib/netlist/nl_setup.cpp100
-rw-r--r--src/lib/netlist/nl_setup.h2
-rw-r--r--src/lib/netlist/nltypes.h31
-rw-r--r--src/lib/netlist/plib/palloc.h12
-rw-r--r--src/lib/netlist/plib/pchrono.h4
-rw-r--r--src/lib/netlist/plib/pconfig.h4
-rw-r--r--src/lib/netlist/plib/pfunction.cpp2
-rw-r--r--src/lib/netlist/plib/pmulti_threading.h2
-rw-r--r--src/lib/netlist/plib/ppreprocessor.cpp84
-rw-r--r--src/lib/netlist/plib/ppreprocessor.h15
-rw-r--r--src/lib/netlist/plib/pstream.h2
-rw-r--r--src/lib/netlist/plib/ptests.h8
-rw-r--r--src/lib/netlist/plib/ptimed_queue.h2
-rw-r--r--src/lib/netlist/plib/ptokenizer.cpp98
-rw-r--r--src/lib/netlist/plib/ptokenizer.h142
-rw-r--r--src/lib/netlist/plib/ptypes.h4
-rw-r--r--src/lib/netlist/plib/putil.h41
-rw-r--r--src/lib/netlist/prg/nltool.cpp62
-rw-r--r--src/lib/netlist/solver/nld_matrix_solver.cpp2
-rw-r--r--src/lib/netlist/solver/nld_matrix_solver.h2
-rw-r--r--src/lib/netlist/solver/nld_matrix_solver_ext.h18
-rw-r--r--src/lib/netlist/solver/nld_solver.cpp4
-rw-r--r--src/lib/netlist/tests/test_pfunction.cpp2
-rw-r--r--src/lib/netlist/tools/nl_convert.cpp29
-rwxr-xr-xsrc/lib/netlist/tools/nl_convert.h20
-rw-r--r--src/mame/audio/nl_280zzzap.cpp31
-rw-r--r--src/mame/audio/nl_mario.cpp18
-rw-r--r--src/mame/audio/nl_starcrus.cpp326
-rw-r--r--src/mame/audio/nl_starcrus.h10
-rw-r--r--src/mame/audio/nl_tankbatt.cpp165
-rw-r--r--src/mame/audio/nl_tankbatt.h10
-rw-r--r--src/mame/drivers/39in1.cpp74
-rw-r--r--src/mame/drivers/4enlinea.cpp25
-rw-r--r--src/mame/drivers/aci_prodigy.cpp14
-rw-r--r--src/mame/drivers/amstrad.cpp4
-rw-r--r--src/mame/drivers/apple2e.cpp11
-rw-r--r--src/mame/drivers/atari_s1.cpp22
-rw-r--r--src/mame/drivers/bbl380.cpp6
-rw-r--r--src/mame/drivers/bfcobra.cpp1175
-rw-r--r--src/mame/drivers/casloopy.cpp7
-rw-r--r--src/mame/drivers/cdi.cpp4
-rw-r--r--src/mame/drivers/cinemat.cpp58
-rw-r--r--src/mame/drivers/circus.cpp30
-rw-r--r--src/mame/drivers/cit101.cpp187
-rw-r--r--src/mame/drivers/cit101xl.cpp112
-rw-r--r--src/mame/drivers/cking_master.cpp12
-rw-r--r--src/mame/drivers/cxg_ch2001.cpp13
-rw-r--r--src/mame/drivers/dai.cpp54
-rw-r--r--src/mame/drivers/dblewing.cpp15
-rw-r--r--src/mame/drivers/dct11em.cpp287
-rw-r--r--src/mame/drivers/ddenlovr.cpp46
-rw-r--r--src/mame/drivers/fidel_cc1.cpp19
-rw-r--r--src/mame/drivers/fidel_vcc.cpp14
-rw-r--r--src/mame/drivers/funworld.cpp1528
-rw-r--r--src/mame/drivers/gaelcof3.cpp29
-rw-r--r--src/mame/drivers/gaiden.cpp194
-rw-r--r--src/mame/drivers/generalplus_gpl16250_rom.cpp12
-rw-r--r--src/mame/drivers/gigatron.cpp219
-rw-r--r--src/mame/drivers/goldnpkr.cpp63
-rw-r--r--src/mame/drivers/goldstar.cpp135
-rw-r--r--src/mame/drivers/hec2hrp.cpp498
-rw-r--r--src/mame/drivers/hp_ipc.cpp43
-rw-r--r--src/mame/drivers/interact.cpp305
-rw-r--r--src/mame/drivers/itech8.cpp2
-rw-r--r--src/mame/drivers/jaguar.cpp8
-rw-r--r--src/mame/drivers/kc.cpp12
-rw-r--r--src/mame/drivers/lucky37.cpp40
-rw-r--r--src/mame/drivers/lviv.cpp36
-rw-r--r--src/mame/drivers/megadriv_acbl.cpp46
-rw-r--r--src/mame/drivers/microvsn.cpp3
-rw-r--r--src/mame/drivers/midvunit.cpp21
-rw-r--r--src/mame/drivers/model3.cpp29
-rw-r--r--src/mame/drivers/mpu4vid.cpp1571
-rw-r--r--src/mame/drivers/nes_sh6578.cpp85
-rw-r--r--src/mame/drivers/nes_vt.cpp96
-rw-r--r--src/mame/drivers/novag_savant.cpp2
-rw-r--r--src/mame/drivers/odyssey2.cpp506
-rw-r--r--src/mame/drivers/pcd.cpp8
-rw-r--r--src/mame/drivers/qix.cpp66
-rw-r--r--src/mame/drivers/renegade.cpp206
-rw-r--r--src/mame/drivers/saitek_exchess.cpp2
-rw-r--r--src/mame/drivers/saitek_mark5.cpp2
-rw-r--r--src/mame/drivers/saitek_simultano.cpp3
-rw-r--r--src/mame/drivers/saitek_ssystem3.cpp202
-rw-r--r--src/mame/drivers/saitek_stratos.cpp2
-rw-r--r--src/mame/drivers/sigmab98.cpp605
-rw-r--r--src/mame/drivers/snesb51.cpp43
-rw-r--r--src/mame/drivers/spg2xx.cpp86
-rw-r--r--src/mame/drivers/spg2xx_zone_32bit.cpp68
-rw-r--r--src/mame/drivers/starcrus.cpp48
-rw-r--r--src/mame/drivers/taito_f3.cpp2
-rw-r--r--src/mame/drivers/tamag1.cpp1
-rw-r--r--src/mame/drivers/tankbatt.cpp293
-rw-r--r--src/mame/drivers/tecmo.cpp8
-rw-r--r--src/mame/drivers/tecnodar.cpp32
-rw-r--r--src/mame/drivers/votrtnt.cpp14
-rw-r--r--src/mame/drivers/vt1682.cpp92
-rw-r--r--src/mame/drivers/williams.cpp168
-rw-r--r--src/mame/drivers/xavix.cpp534
-rw-r--r--src/mame/drivers/xavix_2000.cpp287
-rw-r--r--src/mame/drivers/xavix_2002.cpp547
-rw-r--r--src/mame/drivers/z80ne.cpp183
-rw-r--r--src/mame/includes/cinemat.h79
-rw-r--r--src/mame/includes/dai.h76
-rw-r--r--src/mame/includes/funworld.h2
-rw-r--r--src/mame/includes/hec2hrp.h174
-rw-r--r--src/mame/includes/lviv.h29
-rw-r--r--src/mame/includes/megadriv_acbl.h2
-rw-r--r--src/mame/includes/model3.h3
-rw-r--r--src/mame/includes/mpu4.h9
-rw-r--r--src/mame/includes/qix.h5
-rw-r--r--src/mame/includes/spg2xx.h39
-rw-r--r--src/mame/includes/starcrus.h29
-rw-r--r--src/mame/includes/tankbatt.h45
-rw-r--r--src/mame/includes/xavix.h53
-rw-r--r--src/mame/includes/xavix_2000.h27
-rw-r--r--src/mame/includes/xavix_2002.h55
-rw-r--r--src/mame/includes/z80ne.h40
-rw-r--r--src/mame/layout/brkball.lay4131
-rw-r--r--src/mame/layout/ck_master.lay2
-rw-r--r--src/mame/layout/dct11em.lay80
-rw-r--r--src/mame/layout/gigatron.lay32
-rw-r--r--src/mame/layout/saitek_cp2000.lay6
-rw-r--r--src/mame/layout/saitek_ssystem3.lay175
-rw-r--r--src/mame/layout/speedfrk.lay111
-rw-r--r--src/mame/layout/spyhunt.lay162
-rw-r--r--src/mame/layout/v4psi.lay30
-rw-r--r--src/mame/machine/bacta_datalogger.cpp139
-rw-r--r--src/mame/machine/bacta_datalogger.h45
-rw-r--r--src/mame/machine/cit101_kbd.cpp489
-rw-r--r--src/mame/machine/cit101_kbd.h75
-rw-r--r--src/mame/machine/dai.cpp105
-rw-r--r--src/mame/machine/hec2hrp.cpp427
-rw-r--r--src/mame/machine/lviv.cpp56
-rw-r--r--src/mame/machine/mpu4.cpp31
-rw-r--r--src/mame/machine/nl_breakout.cpp12
-rw-r--r--src/mame/machine/nl_dpatrol.cpp4
-rw-r--r--src/mame/machine/nl_palestra.cpp8
-rw-r--r--src/mame/machine/nl_stuntcyc.cpp4
-rw-r--r--src/mame/machine/qix.cpp5
-rw-r--r--src/mame/machine/xavix.cpp51
-rw-r--r--src/mame/machine/z80ne.cpp137
-rw-r--r--src/mame/mame.lst67
-rw-r--r--src/mame/mess.flt4
-rw-r--r--src/mame/video/apple2.cpp160
-rw-r--r--src/mame/video/apple2.h4
-rw-r--r--src/mame/video/dai.cpp6
-rw-r--r--src/mame/video/hec2hrp.cpp75
-rw-r--r--src/mame/video/lviv.cpp2
-rw-r--r--src/mame/video/renegade.cpp8
-rw-r--r--src/mame/video/starcrus.cpp119
365 files changed, 27890 insertions, 12685 deletions
diff --git a/src/devices/bus/a2bus/a2themill.cpp b/src/devices/bus/a2bus/a2themill.cpp
index 87a4e330ddd..44925c4c68b 100644
--- a/src/devices/bus/a2bus/a2themill.cpp
+++ b/src/devices/bus/a2bus/a2themill.cpp
@@ -18,8 +18,6 @@
ProDOS "Stellation The Mill Disk.po" requires Mill in slot 2; boot
the disc and type "-DEMO1" and press Enter to launch the simple demo.
- TODO: Add DIP switch to select standard and OS-9 modes.
-
*********************************************************************/
#include "emu.h"
@@ -43,6 +41,23 @@ void a2bus_themill_device::m6809_mem(address_map &map)
map(0x0000, 0xffff).rw(FUNC(a2bus_themill_device::dma_r), FUNC(a2bus_themill_device::dma_w));
}
+static INPUT_PORTS_START( themill )
+ PORT_START("MILLCFG")
+ PORT_DIPNAME( 0x01, 0x01, "6809 Mapping" )
+ PORT_DIPSETTING( 0x00, "Original")
+ PORT_DIPSETTING( 0x01, "OS-9")
+INPUT_PORTS_END
+
+//-------------------------------------------------
+// input_ports - device-specific input ports
+//-------------------------------------------------
+
+ioport_constructor a2bus_themill_device::device_input_ports() const
+{
+ return INPUT_PORTS_NAME( themill );
+}
+
+
/***************************************************************************
FUNCTION PROTOTYPES
***************************************************************************/
@@ -65,6 +80,7 @@ a2bus_themill_device::a2bus_themill_device(const machine_config &mconfig, device
: device_t(mconfig, type, tag, owner, clock)
, device_a2bus_card_interface(mconfig, *this)
, m_6809(*this, "m6809")
+ , m_cfgsw(*this, "MILLCFG")
, m_bEnabled(false)
, m_flipAddrSpace(false)
, m_6809Mode(false)
@@ -93,7 +109,7 @@ void a2bus_themill_device::device_reset()
{
m_bEnabled = false;
m_flipAddrSpace = false;
- m_6809Mode = true;
+ m_6809Mode = (m_cfgsw->read() & 1) ? true : false;
m_status = 0xc0; // OS9 loader relies on this
m_6809->set_input_line(INPUT_LINE_HALT, ASSERT_LINE);
m_6809->set_input_line(INPUT_LINE_RESET, ASSERT_LINE);
diff --git a/src/devices/bus/a2bus/a2themill.h b/src/devices/bus/a2bus/a2themill.h
index 152cfa6882d..59f0c2316d1 100644
--- a/src/devices/bus/a2bus/a2themill.h
+++ b/src/devices/bus/a2bus/a2themill.h
@@ -33,6 +33,7 @@ protected:
virtual void device_start() override;
virtual void device_reset() override;
virtual void device_add_mconfig(machine_config &config) override;
+ virtual ioport_constructor device_input_ports() const override;
// overrides of standard a2bus slot functions
virtual uint8_t read_c0nx(uint8_t offset) override;
@@ -41,6 +42,8 @@ protected:
private:
required_device<cpu_device> m_6809;
+ required_ioport m_cfgsw;
+
bool m_bEnabled;
bool m_flipAddrSpace;
bool m_6809Mode;
diff --git a/src/devices/bus/amiga/zorro/buddha.cpp b/src/devices/bus/amiga/zorro/buddha.cpp
index 83fe8bbcfd1..842a32f7f2d 100644
--- a/src/devices/bus/amiga/zorro/buddha.cpp
+++ b/src/devices/bus/amiga/zorro/buddha.cpp
@@ -248,8 +248,8 @@ void buddha_device::ide_interrupt_enable_w(offs_t offset, uint16_t data, uint16_
uint16_t buddha_device::ide_0_cs0_r(offs_t offset, uint16_t mem_mask)
{
- uint16_t data = m_ata_0->cs0_r((offset >> 1) & 0x07, (mem_mask << 8) | (mem_mask >> 8));
- data = (data << 8) | (data >> 8);
+ uint16_t data = m_ata_0->cs0_r((offset >> 1) & 0x07, swapendian_int16(mem_mask));
+ data = swapendian_int16(data);
LOG("ide_0_cs0_r(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
@@ -260,16 +260,16 @@ void buddha_device::ide_0_cs0_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
LOG("ide_0_cs0_w(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
- mem_mask = (mem_mask << 8) | (mem_mask >> 8);
- data = (data << 8) | (data >> 8);
+ mem_mask = swapendian_int16(mem_mask);
+ data = swapendian_int16(data);
m_ata_0->cs0_w((offset >> 1) & 0x07, data, mem_mask);
}
uint16_t buddha_device::ide_0_cs1_r(offs_t offset, uint16_t mem_mask)
{
- uint16_t data = m_ata_0->cs1_r((offset >> 1) & 0x07, (mem_mask << 8) | (mem_mask >> 8));
- data = (data << 8) | (data >> 8);
+ uint16_t data = m_ata_0->cs1_r((offset >> 1) & 0x07, swapendian_int16(mem_mask));
+ data = swapendian_int16(data);
LOG("ide_0_cs1_r(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
@@ -280,16 +280,16 @@ void buddha_device::ide_0_cs1_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
LOG("ide_0_cs1_w(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
- mem_mask = (mem_mask << 8) | (mem_mask >> 8);
- data = (data << 8) | (data >> 8);
+ mem_mask = swapendian_int16(mem_mask);
+ data = swapendian_int16(data);
m_ata_0->cs1_w((offset >> 1) & 0x07, data, mem_mask);
}
uint16_t buddha_device::ide_1_cs0_r(offs_t offset, uint16_t mem_mask)
{
- uint16_t data = m_ata_1->cs0_r((offset >> 1) & 0x07, (mem_mask << 8) | (mem_mask >> 8));
- data = (data << 8) | (data >> 8);
+ uint16_t data = m_ata_1->cs0_r((offset >> 1) & 0x07, swapendian_int16(mem_mask));
+ data = swapendian_int16(data);
LOG("ide_1_cs0_r(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
@@ -300,16 +300,16 @@ void buddha_device::ide_1_cs0_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
LOG("ide_1_cs0_w(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
- mem_mask = (mem_mask << 8) | (mem_mask >> 8);
- data = (data << 8) | (data >> 8);
+ mem_mask = swapendian_int16(mem_mask);
+ data = swapendian_int16(data);
m_ata_1->cs0_w((offset >> 1) & 0x07, data, mem_mask);
}
uint16_t buddha_device::ide_1_cs1_r(offs_t offset, uint16_t mem_mask)
{
- uint16_t data = m_ata_1->cs1_r((offset >> 1) & 0x07, (mem_mask << 8) | (mem_mask >> 8));
- data = (data << 8) | (data >> 8);
+ uint16_t data = m_ata_1->cs1_r((offset >> 1) & 0x07, swapendian_int16(mem_mask));
+ data = swapendian_int16(data);
LOG("ide_1_cs1_r(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
@@ -320,8 +320,8 @@ void buddha_device::ide_1_cs1_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
LOG("ide_1_cs1_w(%04x) %04x [mask = %04x]\n", offset, data, mem_mask);
- mem_mask = (mem_mask << 8) | (mem_mask >> 8);
- data = (data << 8) | (data >> 8);
+ mem_mask = swapendian_int16(mem_mask);
+ data = swapendian_int16(data);
m_ata_1->cs1_w((offset >> 1) & 0x07, data, mem_mask);
}
diff --git a/src/devices/bus/gio64/newport.cpp b/src/devices/bus/gio64/newport.cpp
index fdf69a5e240..1be643afddd 100644
--- a/src/devices/bus/gio64/newport.cpp
+++ b/src/devices/bus/gio64/newport.cpp
@@ -2199,11 +2199,6 @@ uint64_t newport_base_device::rex3_r(offs_t offset, uint64_t mem_mask)
return ret;
}
-uint32_t newport_base_device::do_endian_swap(uint32_t color)
-{
- return (color >> 24) | (color << 24) | ((color >> 8) & 0x0000ff00) | ((color << 8) & 0x00ff0000);
-}
-
uint32_t newport_base_device::get_host_color()
{
static const uint32_t s_color_masks[4] = { 0xf, 0xff, 0xfff, 0xffffffff };
@@ -2259,7 +2254,7 @@ uint32_t newport_base_device::get_host_color()
break;
}
if (BIT(m_rex3.m_draw_mode1, 11))
- color = do_endian_swap(color);
+ color = swapendian_int32(color);
return color;
}
diff --git a/src/devices/bus/gio64/newport.h b/src/devices/bus/gio64/newport.h
index 2bca4c1d8b9..cd894510e05 100644
--- a/src/devices/bus/gio64/newport.h
+++ b/src/devices/bus/gio64/newport.h
@@ -476,8 +476,6 @@ protected:
uint32_t convert_8bpp_bgr_to_24bpp_rgb(uint8_t pix_in);
uint32_t convert_12bpp_bgr_to_24bpp_rgb(uint16_t pix_in);
- uint32_t do_endian_swap(uint32_t color);
-
struct bresenham_octant_info_t
{
int16_t incrx1;
diff --git a/src/devices/bus/hp9845_io/98036.cpp b/src/devices/bus/hp9845_io/98036.cpp
new file mode 100644
index 00000000000..4d0f5011118
--- /dev/null
+++ b/src/devices/bus/hp9845_io/98036.cpp
@@ -0,0 +1,505 @@
+// license:BSD-3-Clause
+// copyright-holders: F. Ulivi
+/*********************************************************************
+
+ 98036.cpp
+
+ 98036 module (RS232 interface)
+
+ Main reference for this module:
+ HP, 98036A Serial I/O interface installation & service manual
+
+*********************************************************************/
+
+#include "98036.h"
+
+// Debugging
+#define VERBOSE 0
+#include "logmacro.h"
+
+// Bit manipulation
+namespace {
+ template<typename T> constexpr T BIT_MASK(unsigned n)
+ {
+ return (T)1U << n;
+ }
+
+ template<typename T> void BIT_SET(T& w , unsigned n)
+ {
+ w |= BIT_MASK<T>(n);
+ }
+}
+
+// device type definitions
+DEFINE_DEVICE_TYPE(HP98036_IO_CARD, hp98036_io_card_device, "hp98036" , "HP98036 card")
+
+hp98036_io_card_device::hp98036_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+: device_t(mconfig, HP98036_IO_CARD, tag, owner, clock)
+ , device_hp9845_io_interface(mconfig, *this)
+ , m_uart(*this , "uart")
+ , m_clock_gen(*this , "clock_gen")
+ , m_rs232(*this , "rs232")
+ , m_s1_input(*this , "s1")
+ , m_s2_input(*this , "s2")
+ , m_s3_input(*this , "s3")
+ , m_jumper_input(*this , "jumper")
+ , m_loopback_en(*this , "loop")
+{
+}
+
+hp98036_io_card_device::~hp98036_io_card_device()
+{
+}
+
+uint16_t hp98036_io_card_device::reg_r(address_space &space, offs_t offset)
+{
+ uint16_t res = 0;
+
+ switch (offset) {
+ case 0:
+ // R4IN
+ m_r4_dir = false;
+ res = m_r4in_data;
+ break;
+
+ case 1:
+ // R5IN
+ if (m_tx_int_en) {
+ BIT_SET(res, 0);
+ }
+ if (m_rx_int_en) {
+ BIT_SET(res, 1);
+ }
+ BIT_SET(res, 4);
+ if (m_int_en) {
+ BIT_SET(res, 7);
+ }
+ break;
+
+ case 2:
+ // R6IN
+ // Bits 3&4: jumpers
+ res = (m_jumper_input->read() & 3) << 3;
+ if (m_loopback) {
+ res |= m_lineout;
+ } else {
+ if (!m_rs232->dcd_r()) {
+ BIT_SET(res, 0);
+ }
+ if (!m_rs232->ri_r()) {
+ BIT_SET(res, 1);
+ }
+ // Bit 2: secondary CD, always 0
+ }
+ BIT_SET(res, 5);
+ BIT_SET(res, 6);
+ BIT_SET(res, 7);
+ break;
+
+ default:
+ logerror("Unmapped read @%u\n" , offset);
+ break;
+ }
+
+ LOG("RD R%u=%02x\n" , offset + 4 , res);
+ return res;
+}
+
+void hp98036_io_card_device::reg_w(address_space &space, offs_t offset, uint16_t data)
+{
+ LOG("WR R%u=%02x\n" , offset + 4 , data);
+
+ switch (offset) {
+ case 0:
+ // R4OUT
+ m_r4_dir = true;
+ m_wrrq = true;
+ m_r4out_data = data;
+ uart_wr();
+ update_flg();
+ break;
+
+ case 1:
+ // R5OUT
+ m_uart_cmd = BIT(data , 0);
+ m_tx_int_en = BIT(data , 1);
+ m_rx_int_en = BIT(data , 2);
+ m_int_en = BIT(data , 7);
+ if (BIT(data , 5)) {
+ int_reset();
+ } else {
+ uart_rd();
+ uart_wr();
+ update_irq();
+ update_flg();
+ }
+ break;
+
+ case 2:
+ // R6OUT
+ m_half_baud = BIT(data , 4);
+ m_lineout = data & 7;
+ break;
+
+ case 3:
+ // R7OUT
+ if (!m_r4_dir) {
+ m_rdrq = true;
+ uart_rd();
+ update_irq();
+ update_flg();
+ }
+ break;
+
+ default:
+ logerror("Unmapped write @%u\n" , offset);
+ break;
+ }
+}
+
+void hp98036_io_card_device::device_add_mconfig(machine_config &config)
+{
+ I8251(config , m_uart , 0);
+ m_uart->txd_handler().set(FUNC(hp98036_io_card_device::txd_w));
+ m_uart->dtr_handler().set(FUNC(hp98036_io_card_device::dtr_w));
+ m_uart->rts_handler().set(FUNC(hp98036_io_card_device::rts_w));
+ m_uart->rxrdy_handler().set(FUNC(hp98036_io_card_device::rxrdy_w));
+ m_uart->txrdy_handler().set(FUNC(hp98036_io_card_device::txrdy_w));
+
+ MC14411(config , m_clock_gen , 1.8432_MHz_XTAL);
+ m_clock_gen->out_f<1>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<3>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<5>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<6>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<7>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<8>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<9>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<11>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<13>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<14>().set(FUNC(hp98036_io_card_device::bit_rate_clock));
+ m_clock_gen->out_f<12>().set(FUNC(hp98036_io_card_device::slow_clock));
+
+ RS232_PORT(config , m_rs232 , default_rs232_devices , nullptr);
+ m_rs232->rxd_handler().set(FUNC(hp98036_io_card_device::rxd_w));
+ m_rs232->dsr_handler().set(FUNC(hp98036_io_card_device::dsr_w));
+ m_rs232->cts_handler().set(FUNC(hp98036_io_card_device::cts_w));
+}
+
+static INPUT_PORTS_START(hp98036_port)
+ PORT_HP9845_IO_SC(11)
+
+ PORT_START("s1")
+ PORT_DIPNAME(3 , 3 , "Clock factor")
+ PORT_DIPLOCATION("S1:1,2")
+ PORT_DIPSETTING(1 , "x1")
+ PORT_DIPSETTING(2 , "x16")
+ PORT_DIPSETTING(3 , "x64")
+ PORT_DIPNAME(0x0c , 0x0c , "Character length")
+ PORT_DIPLOCATION("S1:3,4")
+ PORT_DIPSETTING(0x00 , "5")
+ PORT_DIPSETTING(0x04 , "6")
+ PORT_DIPSETTING(0x08 , "7")
+ PORT_DIPSETTING(0x0c , "8")
+ PORT_DIPNAME(0x10 , 0 , "Parity enable")
+ PORT_DIPLOCATION("S1:5")
+ PORT_DIPSETTING(0x00 , DEF_STR(Off))
+ PORT_DIPSETTING(0x10 , DEF_STR(On))
+ PORT_DIPNAME(0x20 , 0 , "Parity")
+ PORT_DIPLOCATION("S1:6")
+ PORT_DIPSETTING(0x00 , "Odd")
+ PORT_DIPSETTING(0x20 , "Even")
+ PORT_DIPNAME(0xc0 , 0xc0 , "Stop bits")
+ PORT_DIPLOCATION("S1:7,8")
+ PORT_DIPSETTING(0x40 , "1")
+ PORT_DIPSETTING(0x80 , "1.5")
+ PORT_DIPSETTING(0xc0 , "2")
+
+ PORT_START("s2")
+ PORT_DIPNAME(1 , 1 , "CTS")
+ PORT_DIPLOCATION("S2:1")
+ PORT_DIPSETTING(0 , "Device controlled")
+ PORT_DIPSETTING(1 , "Always active")
+
+ PORT_START("s3")
+ PORT_CONFNAME(0xf , 6 , "Baud rate")
+ PORT_CONFSETTING(0 , "9600")
+ PORT_CONFSETTING(1 , "4800")
+ PORT_CONFSETTING(2 , "2400")
+ PORT_CONFSETTING(3 , "1800")
+ PORT_CONFSETTING(4 , "1200")
+ PORT_CONFSETTING(5 , "600")
+ PORT_CONFSETTING(6 , "300")
+ PORT_CONFSETTING(7 , "150")
+ PORT_CONFSETTING(8 , "110")
+ PORT_CONFSETTING(9 , "75")
+
+ PORT_START("jumper")
+ PORT_CONFNAME(1 , 0 , "J1")
+ PORT_CONFSETTING(0 , DEF_STR(Off))
+ PORT_CONFSETTING(1 , DEF_STR(On))
+ PORT_CONFNAME(2 , 0 , "J2")
+ PORT_CONFSETTING(0 , DEF_STR(Off))
+ PORT_CONFSETTING(2 , DEF_STR(On))
+
+ PORT_START("loop")
+ PORT_CONFNAME(1 , 0 , "Test loopback")
+ PORT_CONFSETTING(0 , DEF_STR(Off))
+ PORT_CONFSETTING(1 , DEF_STR(On))
+INPUT_PORTS_END
+
+ioport_constructor hp98036_io_card_device::device_input_ports() const
+{
+ return INPUT_PORTS_NAME(hp98036_port);
+}
+
+void hp98036_io_card_device::device_start()
+{
+ save_item(NAME(m_init_state));
+ save_item(NAME(m_irq));
+ save_item(NAME(m_int_en));
+ save_item(NAME(m_tx_int_en));
+ save_item(NAME(m_rx_int_en));
+ save_item(NAME(m_txrdy));
+ save_item(NAME(m_rxrdy));
+ save_item(NAME(m_wrrq));
+ save_item(NAME(m_rdrq));
+ save_item(NAME(m_uart_cmd));
+ save_item(NAME(m_uart_wr_mode));
+ save_item(NAME(m_flg));
+ save_item(NAME(m_half_baud));
+ save_item(NAME(m_baud_div));
+ save_item(NAME(m_r4_dir));
+ save_item(NAME(m_r4in_data));
+ save_item(NAME(m_r4out_data));
+ save_item(NAME(m_lineout));
+}
+
+void hp98036_io_card_device::device_reset()
+{
+ sts_w(true);
+
+ ioport_value baud_sel = m_s3_input->read();
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F1 , baud_sel == 0);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F3 , baud_sel == 1);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F5 , baud_sel == 2);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F6 , baud_sel == 3);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F7 , baud_sel == 4);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F8 , baud_sel == 5);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F9 , baud_sel == 6);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F11 , baud_sel == 7);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F13 , baud_sel == 8);
+ m_clock_gen->timer_enable(mc14411_device::TIMER_F14 , baud_sel == 9);
+
+ m_loopback = m_loopback_en->read() != 0;
+
+ if (!m_loopback && BIT(m_s2_input->read() , 0)) {
+ m_uart->write_cts(0);
+ }
+
+ int_reset();
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::bit_rate_clock)
+{
+ if (m_half_baud) {
+ if (state) {
+ m_baud_div = !m_baud_div;
+ m_uart->write_txc(m_baud_div);
+ m_uart->write_rxc(m_baud_div);
+ }
+ } else {
+ m_uart->write_txc(state);
+ m_uart->write_rxc(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::slow_clock)
+{
+ switch (m_init_state) {
+ case 0:
+ // Reset
+ if (state) {
+ m_init_state++;
+ }
+ break;
+
+ case 1:
+ // Write mode word
+ if (state) {
+ m_init_state++;
+ } else {
+ write_uart(true , uint8_t(m_s1_input->read()));
+ }
+ break;
+
+ case 2:
+ // Write default control word
+ if (state) {
+ m_init_state++;
+ update_flg();
+ } else {
+ write_uart(true , 0x05);
+ }
+ break;
+
+ default:
+ break;
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::txd_w)
+{
+ if (m_loopback) {
+ m_uart->write_rxd(state);
+ } else {
+ m_rs232->write_txd(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::dtr_w)
+{
+ if (m_loopback) {
+ m_uart->write_dsr(state);
+ } else {
+ m_rs232->write_dtr(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::rts_w)
+{
+ if (m_loopback) {
+ m_uart->write_cts(state);
+ } else {
+ m_rs232->write_rts(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::txrdy_w)
+{
+ if (m_txrdy != state) {
+ m_txrdy = state;
+ LOG("txrdy %d\n" , m_txrdy);
+ uart_wr();
+ update_irq();
+ update_flg();
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::rxrdy_w)
+{
+ if (m_rxrdy != state) {
+ m_rxrdy = state;
+ LOG("rxrdy %d\n" , m_rxrdy);
+ uart_rd();
+ update_irq();
+ update_flg();
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::rxd_w)
+{
+ if (!m_loopback) {
+ m_uart->write_rxd(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::dsr_w)
+{
+ if (!m_loopback) {
+ m_uart->write_dsr(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp98036_io_card_device::cts_w)
+{
+ if (!m_loopback && !BIT(m_s2_input->read() , 0)) {
+ m_uart->write_cts(state);
+ }
+}
+
+void hp98036_io_card_device::int_reset()
+{
+ m_init_state = 0;
+ m_r4in_data = 0;
+ m_r4out_data = 0;
+ m_wrrq = false;
+ m_rdrq = false;
+ m_int_en = false;
+ m_tx_int_en = false;
+ m_rx_int_en = false;
+ m_uart_cmd = false;
+ m_uart_wr_mode = true;
+ m_half_baud = false;
+ m_lineout = 0;
+ m_clock_gen->rate_select_w(0);
+ m_flg = true; // Ensure update in update_flg
+ update_flg();
+ m_irq = true; // Ensure update in update_irq
+ update_irq();
+ m_uart->reset();
+}
+
+void hp98036_io_card_device::update_flg()
+{
+ bool new_flg = (m_init_state == 3) && (!m_wrrq || m_tx_int_en) && (!m_rdrq || m_rx_int_en);
+
+ if (m_flg != new_flg) {
+ m_flg = new_flg;
+ LOG("FLG %d\n" , m_flg);
+ flg_w(m_flg);
+ }
+}
+
+void hp98036_io_card_device::update_irq()
+{
+ bool new_irq = m_int_en && ((m_tx_int_en && m_txrdy) || (m_rx_int_en && !m_rdrq));
+
+ if (m_irq != new_irq) {
+ m_irq = new_irq;
+ LOG("IRQ %d\n" , m_irq);
+ irq_w(m_irq);
+ }
+}
+
+void hp98036_io_card_device::uart_rd()
+{
+ if (m_rdrq && (m_rxrdy || m_uart_cmd)) {
+ m_rdrq = false;
+ m_r4in_data = m_uart->read(m_uart_cmd);
+ LOG("uart rd%d=%02x\n" , m_uart_cmd , m_r4in_data);
+ update_flg();
+ }
+}
+
+void hp98036_io_card_device::uart_wr()
+{
+ if (m_wrrq && (m_txrdy || m_uart_cmd)) {
+ m_wrrq = false;
+ write_uart(m_uart_cmd , m_r4out_data);
+ update_flg();
+ }
+}
+
+void hp98036_io_card_device::write_uart(bool cmd , uint8_t data)
+{
+ if (cmd && m_uart_wr_mode) {
+ // Capture bits 1 & 0 of mode word (clock factor) and
+ // adjust rate selection in clock generator
+ // Mode word RSB/RSA Factor
+ // 0 0 0 0 -- INVALID --
+ // 0 1 0 0 x1
+ // 1 0 1 0 x16
+ // 1 1 1 1 x64
+ m_clock_gen->rate_select_w((BIT(data , 1) ? mc14411_device::RSB : 0) | ((BIT(data , 1) && BIT(data , 0)) ? mc14411_device::RSA : 0));
+ LOG("RS %u\n" , data & 3);
+ }
+ if (cmd) {
+ if (BIT(data , 6)) {
+ m_uart_wr_mode = !m_uart_wr_mode;
+ } else {
+ m_uart_wr_mode = false;
+ }
+ }
+ LOG("uart wr%d=%02x\n" , cmd , data);
+ m_uart->write(cmd , data);
+}
diff --git a/src/devices/bus/hp9845_io/98036.h b/src/devices/bus/hp9845_io/98036.h
new file mode 100644
index 00000000000..c73d32652a5
--- /dev/null
+++ b/src/devices/bus/hp9845_io/98036.h
@@ -0,0 +1,96 @@
+// license:BSD-3-Clause
+// copyright-holders: F. Ulivi
+/*********************************************************************
+
+ 98036.h
+
+ 98036 module (RS232 interface)
+
+*********************************************************************/
+
+#ifndef MAME_BUS_HP9845_IO_98036_H
+#define MAME_BUS_HP9845_IO_98036_H
+
+#pragma once
+
+#include "hp9845_io.h"
+#include "machine/i8251.h"
+#include "machine/mc14411.h"
+#include "bus/rs232/rs232.h"
+
+class hp98036_io_card_device : public device_t, public device_hp9845_io_interface
+{
+public:
+ // construction/destruction
+ hp98036_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+ virtual ~hp98036_io_card_device();
+
+ virtual uint16_t reg_r(address_space &space, offs_t offset) override;
+ virtual void reg_w(address_space &space, offs_t offset, uint16_t data) override;
+
+protected:
+ // device-level overrides
+ virtual void device_add_mconfig(machine_config &config) override;
+ virtual ioport_constructor device_input_ports() const override;
+ virtual void device_start() override;
+ virtual void device_reset() override;
+
+private:
+ required_device<i8251_device> m_uart;
+ required_device<mc14411_device> m_clock_gen;
+ required_device<rs232_port_device> m_rs232;
+ required_ioport m_s1_input;
+ required_ioport m_s2_input;
+ required_ioport m_s3_input;
+ required_ioport m_jumper_input;
+ required_ioport m_loopback_en;
+
+ DECLARE_WRITE_LINE_MEMBER(bit_rate_clock);
+ DECLARE_WRITE_LINE_MEMBER(slow_clock);
+ DECLARE_WRITE_LINE_MEMBER(txd_w);
+ DECLARE_WRITE_LINE_MEMBER(dtr_w);
+ DECLARE_WRITE_LINE_MEMBER(rts_w);
+ DECLARE_WRITE_LINE_MEMBER(txrdy_w);
+ DECLARE_WRITE_LINE_MEMBER(rxrdy_w);
+ DECLARE_WRITE_LINE_MEMBER(rxd_w);
+ DECLARE_WRITE_LINE_MEMBER(dsr_w);
+ DECLARE_WRITE_LINE_MEMBER(cts_w);
+
+ // State of initialization FSM
+ // State U11A-Q U11B-Q
+ // 0 0 0
+ // 1 1 0 Load mode word
+ // 2 1 1 Load control word
+ // 3 0 1 Done
+ uint8_t m_init_state;
+ bool m_irq; // U9-2
+ bool m_int_en; // U10-2
+ bool m_tx_int_en; // U10-10
+ bool m_rx_int_en; // U10-7
+ bool m_txrdy; // U31-15
+ bool m_rxrdy; // U31-14
+ bool m_wrrq; // U19-13
+ bool m_rdrq; // U19-7
+ bool m_uart_cmd; // U10-15
+ bool m_uart_wr_mode;// U17-15
+ bool m_flg; // U9-10
+ bool m_half_baud; // U21-13
+ bool m_baud_div; // U21-1
+ bool m_r4_dir; // U19-4
+ bool m_loopback;
+ uint8_t m_r4in_data; // U29, U30
+ uint8_t m_r4out_data; // U26, U27
+ uint8_t m_lineout; // U28
+
+ void int_reset();
+ void update_flg();
+ void update_irq();
+ void uart_rd();
+ void uart_wr();
+ void write_uart(bool cmd , uint8_t data);
+};
+
+// device type definitions
+DECLARE_DEVICE_TYPE(HP98036_IO_CARD, hp98036_io_card_device)
+
+#endif // MAME_BUS_HP9845_IO_98036_H
diff --git a/src/devices/bus/hp9845_io/hp9845_io.cpp b/src/devices/bus/hp9845_io/hp9845_io.cpp
index a6d09154671..bf304622f24 100644
--- a/src/devices/bus/hp9845_io/hp9845_io.cpp
+++ b/src/devices/bus/hp9845_io/hp9845_io.cpp
@@ -12,6 +12,7 @@
#include "hp9845_io.h"
#include "98032.h"
#include "98035.h"
+#include "98036.h"
#include "98034.h"
#include "98046.h"
@@ -36,6 +37,7 @@ hp9845_io_slot_device::hp9845_io_slot_device(const machine_config &mconfig, cons
option_add("98032_gpio" , HP98032_IO_CARD);
option_add("98034_hpib" , HP98034_IO_CARD);
option_add("98035_rtc" , HP98035_IO_CARD);
+ option_add("98036" , HP98036_IO_CARD);
option_add("98046" , HP98046_IO_CARD);
set_default_option(nullptr);
set_fixed(false);
diff --git a/src/devices/bus/hp_ipc_io/82919.cpp b/src/devices/bus/hp_ipc_io/82919.cpp
new file mode 100644
index 00000000000..f9b5024d4c3
--- /dev/null
+++ b/src/devices/bus/hp_ipc_io/82919.cpp
@@ -0,0 +1,252 @@
+// license:BSD-3-Clause
+// copyright-holders: F. Ulivi
+/*********************************************************************
+
+ 82919.cpp
+
+ 82919 module (RS232 interface)
+
+ Main reference for this module is:
+ HP 82919-90009, feb 85, HP82919A Integral PC Serial Interface -
+ Component level service manual
+
+*********************************************************************/
+
+#include "emu.h"
+#include "82919.h"
+#include "coreutil.h"
+
+// Debugging
+#define VERBOSE 0
+#include "logmacro.h"
+
+// Bit manipulation
+namespace {
+ template<typename T> constexpr T BIT_MASK(unsigned n)
+ {
+ return (T)1U << n;
+ }
+
+ template<typename T> void BIT_SET(T& w , unsigned n)
+ {
+ w |= BIT_MASK<T>(n);
+ }
+}
+
+hp82919_io_card_device::hp82919_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : device_t(mconfig , HP82919_IO_CARD , tag , owner , clock)
+ , device_hp_ipc_io_interface(mconfig, *this)
+ , m_rs232_prim(*this , "rs232_prim")
+ , m_rs232_sec(*this , "rs232_sec")
+ , m_uart(*this , "uart")
+ , m_loopback_en(*this, "loop")
+{
+}
+
+hp82919_io_card_device::~hp82919_io_card_device()
+{
+}
+
+uint8_t hp82919_io_card_device::read(offs_t addr)
+{
+ uint8_t res = 0;
+ offs_t uart_addr = (addr ^ 0xc) & 0xf;
+
+ if (BIT(addr , 4)) {
+ res = m_uart->read(uart_addr);
+ } else {
+ // 2 is 82919 ID code
+ res = 2;
+ res |= (m_int_level << 4);
+ if (m_int_pending) {
+ BIT_SET(res , 6);
+ }
+ if (m_int_en) {
+ BIT_SET(res , 7);
+ }
+ m_uart->write(uart_addr , res);
+ }
+ LOG("RD %04x=%02x\n" , addr , res);
+ return res;
+}
+
+void hp82919_io_card_device::write(offs_t addr , uint8_t data)
+{
+ LOG("WR %04x=%02x\n" , addr , data);
+ offs_t uart_addr = (addr ^ 0xc) & 0xf;
+ m_uart->write(uart_addr , data);
+ if (!BIT(addr , 4)) {
+ m_int_level = (data >> 4) & 3;
+ m_int_forced = BIT(data , 6);
+ m_int_en = BIT(data , 7);
+ update_irq();
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::uart_irq)
+{
+ m_uart_int = state;
+ update_irq();
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::uart_a_tx)
+{
+ m_rs232_prim->write_txd(state);
+ if (m_loopback) {
+ m_uart->rx_b_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::uart_b_tx)
+{
+ m_rs232_sec->write_txd(state);
+ if (m_loopback) {
+ m_uart->rx_a_w(state);
+ }
+}
+
+void hp82919_io_card_device::uart_output(uint8_t data)
+{
+ m_rs232_prim->write_dtr(BIT(data , 0));
+ m_rs232_prim->write_rts(BIT(data , 1));
+ // b2 is TxClock
+ m_rs232_prim->write_spds(BIT(data , 3));
+ m_rs232_sec->write_rts(BIT(data , 4));
+ if (m_loopback) {
+ m_uart->ip0_w(BIT(data , 0));
+ m_uart->ip1_w(BIT(data , 1));
+ m_uart->ip2_w(BIT(data , 2));
+ m_uart->ip3_w(BIT(data , 3));
+ m_uart->ip4_w(BIT(data , 4));
+ m_uart->ip5_w(BIT(data , 4));
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::prim_rxd)
+{
+ if (!m_loopback) {
+ m_uart->rx_a_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::prim_dcd)
+{
+ if (!m_loopback) {
+ m_uart->ip3_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::prim_dsr)
+{
+ if (!m_loopback) {
+ m_uart->ip1_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::prim_ri)
+{
+ if (!m_loopback) {
+ m_uart->ip2_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::prim_cts)
+{
+ if (!m_loopback) {
+ m_uart->ip0_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::sec_rxd)
+{
+ if (!m_loopback) {
+ m_uart->rx_b_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::sec_dcd)
+{
+ if (!m_loopback) {
+ m_uart->ip5_w(state);
+ }
+}
+
+WRITE_LINE_MEMBER(hp82919_io_card_device::sec_cts)
+{
+ if (!m_loopback) {
+ m_uart->ip4_w(state);
+ }
+}
+
+void hp82919_io_card_device::install_read_write_handlers(address_space& space , uint32_t base_addr)
+{
+ offs_t end_addr = base_addr + 0xffffU;
+
+ // Supervisor mode
+ space.install_readwrite_handler(base_addr, end_addr, read8sm_delegate(*this, FUNC(hp82919_io_card_device::read)), write8sm_delegate(*this, FUNC(hp82919_io_card_device::write)), 0x00ff);
+ // User mode
+ space.install_readwrite_handler(base_addr + USER_SPACE_OFFSET, end_addr + USER_SPACE_OFFSET, read8sm_delegate(*this, FUNC(hp82919_io_card_device::read)), write8sm_delegate(*this, FUNC(hp82919_io_card_device::write)), 0x00ff);
+}
+
+void hp82919_io_card_device::device_start()
+{
+}
+
+void hp82919_io_card_device::device_reset()
+{
+ m_loopback = m_loopback_en->read() != 0;
+ m_int_level = 0;
+ m_int_forced = false;
+ m_int_en = false;
+ m_uart_int = false;
+ m_irq = true;
+ update_irq();
+}
+
+void hp82919_io_card_device::device_add_mconfig(machine_config &config)
+{
+ RS232_PORT(config, m_rs232_prim, default_rs232_devices, nullptr);
+ RS232_PORT(config, m_rs232_sec, default_rs232_devices, nullptr);
+
+ MC68681(config , m_uart , 3.6864_MHz_XTAL);
+ m_uart->irq_cb().set(FUNC(hp82919_io_card_device::uart_irq));
+ m_uart->a_tx_cb().set(FUNC(hp82919_io_card_device::uart_a_tx));
+ m_uart->b_tx_cb().set(FUNC(hp82919_io_card_device::uart_b_tx));
+ m_uart->outport_cb().set(FUNC(hp82919_io_card_device::uart_output));
+
+ m_rs232_prim->rxd_handler().set(FUNC(hp82919_io_card_device::prim_rxd));
+ m_rs232_prim->dcd_handler().set(FUNC(hp82919_io_card_device::prim_dcd));
+ m_rs232_prim->dsr_handler().set(FUNC(hp82919_io_card_device::prim_dsr));
+ m_rs232_prim->ri_handler().set(FUNC(hp82919_io_card_device::prim_ri));
+ m_rs232_prim->cts_handler().set(FUNC(hp82919_io_card_device::prim_cts));
+
+ m_rs232_sec->rxd_handler().set(FUNC(hp82919_io_card_device::sec_rxd));
+ m_rs232_sec->dcd_handler().set(FUNC(hp82919_io_card_device::sec_dcd));
+ m_rs232_sec->cts_handler().set(FUNC(hp82919_io_card_device::sec_cts));
+}
+
+static INPUT_PORTS_START(hp82919_port)
+ PORT_START("loop")
+ PORT_CONFNAME(1 , 0 , "Test loopback")
+ PORT_CONFSETTING(0 , DEF_STR(Off))
+ PORT_CONFSETTING(1 , DEF_STR(On))
+INPUT_PORTS_END
+
+ioport_constructor hp82919_io_card_device::device_input_ports() const
+{
+ return INPUT_PORTS_NAME(hp82919_port);
+}
+
+void hp82919_io_card_device::update_irq()
+{
+ m_int_pending = m_int_forced || m_uart_int;
+ bool irq = m_int_en && m_int_pending;
+ if (m_irq != irq) {
+ m_irq = irq;
+ LOG("IRQ %u=%d\n" , m_int_level , irq);
+ irq_w(m_int_level , irq);
+ }
+}
+
+// device type definition
+DEFINE_DEVICE_TYPE(HP82919_IO_CARD, hp82919_io_card_device, "hp82919", "HP82919 card")
diff --git a/src/devices/bus/hp_ipc_io/82919.h b/src/devices/bus/hp_ipc_io/82919.h
new file mode 100644
index 00000000000..331a42b0b00
--- /dev/null
+++ b/src/devices/bus/hp_ipc_io/82919.h
@@ -0,0 +1,73 @@
+// license:BSD-3-Clause
+// copyright-holders: F. Ulivi
+/*********************************************************************
+
+ 82919.h
+
+ 82919 module (RS232 interface)
+
+*********************************************************************/
+
+#ifndef MAME_BUS_HP_IPC_IO_82919_H
+#define MAME_BUS_HP_IPC_IO_82919_H
+
+#pragma once
+
+#include "hp_ipc_io.h"
+#include "machine/mc68681.h"
+#include "bus/rs232/rs232.h"
+
+class hp82919_io_card_device : public device_t, public device_hp_ipc_io_interface
+{
+public:
+ // construction/destruction
+ hp82919_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+ virtual ~hp82919_io_card_device();
+
+ uint8_t read(offs_t addr);
+ void write(offs_t addr , uint8_t data);
+
+ DECLARE_WRITE_LINE_MEMBER(uart_irq);
+ DECLARE_WRITE_LINE_MEMBER(uart_a_tx);
+ DECLARE_WRITE_LINE_MEMBER(uart_b_tx);
+ void uart_output(uint8_t data);
+ DECLARE_WRITE_LINE_MEMBER(prim_rxd);
+ DECLARE_WRITE_LINE_MEMBER(prim_dcd);
+ DECLARE_WRITE_LINE_MEMBER(prim_dsr);
+ DECLARE_WRITE_LINE_MEMBER(prim_ri);
+ DECLARE_WRITE_LINE_MEMBER(prim_cts);
+ DECLARE_WRITE_LINE_MEMBER(sec_rxd);
+ DECLARE_WRITE_LINE_MEMBER(sec_dcd);
+ DECLARE_WRITE_LINE_MEMBER(sec_cts);
+
+protected:
+ virtual void device_start() override;
+ virtual void device_reset() override;
+
+ // device-level overrides
+ virtual void device_add_mconfig(machine_config &config) override;
+ virtual ioport_constructor device_input_ports() const override;
+
+ virtual void install_read_write_handlers(address_space& space , uint32_t base_addr) override;
+
+private:
+ required_device<rs232_port_device> m_rs232_prim;
+ required_device<rs232_port_device> m_rs232_sec;
+ required_device<mc68681_device> m_uart;
+ required_ioport m_loopback_en;
+
+ uint8_t m_int_level;
+ bool m_int_en;
+ bool m_int_forced;
+ bool m_int_pending;
+ bool m_uart_int;
+ bool m_irq;
+ bool m_loopback;
+
+ void update_irq();
+};
+
+// device type definition
+DECLARE_DEVICE_TYPE(HP82919_IO_CARD, hp82919_io_card_device)
+
+#endif // MAME_BUS_HP_IPC_IO_82919_H
diff --git a/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp b/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp
new file mode 100644
index 00000000000..8d5648754bf
--- /dev/null
+++ b/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp
@@ -0,0 +1,86 @@
+// license:BSD-3-Clause
+// copyright-holders: F. Ulivi
+/*********************************************************************
+
+ hp_ipc_io.cpp
+
+ I/O bus of HP IPC system
+
+*********************************************************************/
+
+#include "emu.h"
+#include "hp_ipc_io.h"
+
+// Debugging
+#define VERBOSE 0
+#include "logmacro.h"
+
+// device type definition
+DEFINE_DEVICE_TYPE(HP_IPC_IO_SLOT, hp_ipc_io_slot_device, "hp_ipc_io_slot", "HP IPC I/O Slot")
+
+// +---------------------+
+// |hp_ipc_io_slot_device|
+// +---------------------+
+hp_ipc_io_slot_device::hp_ipc_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ device_t(mconfig, HP_IPC_IO_SLOT, tag, owner, clock),
+ device_single_card_slot_interface<device_hp_ipc_io_interface>(mconfig, *this),
+ m_irq_cb_func(*this),
+ m_slot_idx(0)
+{
+}
+
+hp_ipc_io_slot_device::~hp_ipc_io_slot_device()
+{
+}
+
+void hp_ipc_io_slot_device::device_start()
+{
+ m_irq_cb_func.resolve_all_safe();
+}
+
+uint32_t hp_ipc_io_slot_device::get_slot_base_addr() const
+{
+ return m_slot_idx ? 0x710000 : 0x700000;
+}
+
+void hp_ipc_io_slot_device::install_read_write_handlers(address_space& space)
+{
+ device_hp_ipc_io_interface *card = get_card_device();
+
+ if (card != nullptr) {
+ card->install_read_write_handlers(space , get_slot_base_addr());
+ }
+}
+
+void hp_ipc_io_slot_device::irq_w(unsigned idx , bool state)
+{
+ m_irq_cb_func[ 0 ](state && idx == 0);
+ m_irq_cb_func[ 1 ](state && idx == 1);
+ m_irq_cb_func[ 2 ](state && idx == 2);
+ m_irq_cb_func[ 3 ](state && idx == 3);
+}
+
+// +--------------------------+
+// |device_hp_ipc_io_interface|
+// +--------------------------+
+device_hp_ipc_io_interface::device_hp_ipc_io_interface(const machine_config &mconfig, device_t &device) :
+ device_interface(device, "hp_ipcio")
+{
+}
+
+device_hp_ipc_io_interface::~device_hp_ipc_io_interface()
+{
+}
+
+void device_hp_ipc_io_interface::irq_w(unsigned idx , bool state)
+{
+ hp_ipc_io_slot_device *slot = downcast<hp_ipc_io_slot_device *>(device().owner());
+ slot->irq_w(idx , state);
+}
+
+#include "82919.h"
+
+void hp_ipc_io_slot_devices(device_slot_interface &device)
+{
+ device.option_add("82919_serial" , HP82919_IO_CARD);
+}
diff --git a/src/devices/bus/hp_ipc_io/hp_ipc_io.h b/src/devices/bus/hp_ipc_io/hp_ipc_io.h
new file mode 100644
index 00000000000..856b140c7ef
--- /dev/null
+++ b/src/devices/bus/hp_ipc_io/hp_ipc_io.h
@@ -0,0 +1,82 @@
+// license:BSD-3-Clause
+// copyright-holders: F. Ulivi
+/*********************************************************************
+
+ hp_ipc_io.h
+
+ I/O bus of HP IPC system
+
+*********************************************************************/
+
+#ifndef MAME_BUS_HP_IPC_IO_HP_IPC_IO_H
+#define MAME_BUS_HP_IPC_IO_HP_IPC_IO_H
+
+#pragma once
+
+void hp_ipc_io_slot_devices(device_slot_interface &device);
+
+class device_hp_ipc_io_interface;
+
+class hp_ipc_io_slot_device : public device_t,
+ public device_single_card_slot_interface<device_hp_ipc_io_interface>
+{
+public:
+ // construction/destruction
+ hp_ipc_io_slot_device(machine_config const &mconfig, char const *tag, device_t *owner)
+ : hp_ipc_io_slot_device(mconfig, tag, owner, (uint32_t)0)
+ {
+ option_reset();
+ hp_ipc_io_slot_devices(*this);
+ set_default_option(nullptr);
+ set_fixed(false);
+ }
+
+ hp_ipc_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+ virtual ~hp_ipc_io_slot_device();
+
+ // Set A/B slot
+ void set_slot_idx(unsigned idx) { m_slot_idx = idx; }
+
+ // Callback setups
+ auto irq3_cb() { return m_irq_cb_func[ 0 ].bind(); }
+ auto irq4_cb() { return m_irq_cb_func[ 1 ].bind(); }
+ auto irq5_cb() { return m_irq_cb_func[ 2 ].bind(); }
+ auto irq6_cb() { return m_irq_cb_func[ 3 ].bind(); }
+
+ uint32_t get_slot_base_addr() const;
+
+ void install_read_write_handlers(address_space& space);
+
+ void irq_w(unsigned idx , bool state);
+
+protected:
+ // device-level overrides
+ virtual void device_start() override;
+
+private:
+ devcb_write_line::array<4> m_irq_cb_func;
+ // 0: slot A
+ // 1: slot B
+ unsigned m_slot_idx;
+};
+
+class device_hp_ipc_io_interface : public device_interface
+{
+public:
+ virtual ~device_hp_ipc_io_interface();
+
+ virtual void install_read_write_handlers(address_space& space , uint32_t base_addr) = 0;
+
+ static constexpr offs_t USER_SPACE_OFFSET = 0x1800000;
+
+protected:
+ device_hp_ipc_io_interface(const machine_config &mconfig, device_t &device);
+
+ // card device handling
+ void irq_w(unsigned idx , bool state);
+};
+
+// device type definition
+DECLARE_DEVICE_TYPE(HP_IPC_IO_SLOT, hp_ipc_io_slot_device)
+
+#endif // MAME_BUS_HP_IPC_IO_HP_IPC_IO_H
diff --git a/src/devices/bus/nubus/nubus_image.cpp b/src/devices/bus/nubus/nubus_image.cpp
index 434d6bd2ded..32b1d33100a 100644
--- a/src/devices/bus/nubus/nubus_image.cpp
+++ b/src/devices/bus/nubus/nubus_image.cpp
@@ -315,7 +315,7 @@ void nubus_image_device::file_data_w(uint32_t data)
std::uint32_t count = 4;
std::uint32_t actualcount = 0;
- data = ((data & 0xff) << 24) | ((data & 0xff00) << 8) | ((data & 0xff0000) >> 8) | ((data & 0xff000000) >> 24);
+ data = swapendian_int32(data);
if(filectx.fd) {
//data = big_endianize_int32(data);
if((filectx.bytecount + count) > filectx.filelen) count = filectx.filelen - filectx.bytecount;
@@ -345,7 +345,7 @@ uint32_t nubus_image_device::file_data_r()
void nubus_image_device::file_len_w(uint32_t data)
{
- data = ((data & 0xff) << 24) | ((data & 0xff00) << 8) | ((data & 0xff0000) >> 8) | ((data & 0xff000000) >> 24);
+ data = swapendian_int32(data);
filectx.filelen = big_endianize_int32(data);
}
diff --git a/src/devices/bus/odyssey2/4in1.cpp b/src/devices/bus/odyssey2/4in1.cpp
new file mode 100644
index 00000000000..e1c382e7fe9
--- /dev/null
+++ b/src/devices/bus/odyssey2/4in1.cpp
@@ -0,0 +1,53 @@
+// license:BSD-3-Clause
+// copyright-holders:hap
+/******************************************************************************
+
+Videopac 40 cartridge emulation
+
+3KB program ROM + 1KB bankswitched data ROM
+
+Used in:
+- #31: Musician
+- #40: 4 in 1 Row
+
+******************************************************************************/
+
+#include "emu.h"
+#include "4in1.h"
+
+
+//-------------------------------------------------
+// o2_4in1_device - constructor
+//-------------------------------------------------
+
+DEFINE_DEVICE_TYPE(O2_ROM_4IN1, o2_4in1_device, "o2_4in1", "Odyssey 2 Videopac 40")
+
+
+o2_4in1_device::o2_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ o2_rom_device(mconfig, O2_ROM_4IN1, tag, owner, clock)
+{ }
+
+void o2_4in1_device::device_start()
+{
+ save_item(NAME(m_control));
+ save_item(NAME(m_bank));
+}
+
+void o2_4in1_device::cart_init()
+{
+ if (m_rom_size != 0x1000)
+ fatalerror("o2_4in1_device: Wrong ROM region size\n");
+}
+
+
+//-------------------------------------------------
+// mapper specific handlers
+//-------------------------------------------------
+
+u8 o2_4in1_device::io_read(offs_t offset)
+{
+ if (m_control & 2)
+ return m_rom[m_bank << 8 | offset];
+ else
+ return 0xff;
+}
diff --git a/src/devices/bus/odyssey2/4in1.h b/src/devices/bus/odyssey2/4in1.h
new file mode 100644
index 00000000000..825eeb3108a
--- /dev/null
+++ b/src/devices/bus/odyssey2/4in1.h
@@ -0,0 +1,47 @@
+// license:BSD-3-Clause
+// copyright-holders:hap
+/**********************************************************************
+
+ Videopac 40 cartridge emulation
+
+**********************************************************************/
+
+#ifndef MAME_BUS_ODYSSEY2_4IN1_H
+#define MAME_BUS_ODYSSEY2_4IN1_H
+
+#pragma once
+
+#include "slot.h"
+#include "rom.h"
+
+
+// ======================> o2_4in1_device
+
+class o2_4in1_device : public o2_rom_device
+{
+public:
+ // construction/destruction
+ o2_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ // device-level overrides
+ virtual void device_start() override;
+
+ virtual void cart_init() override;
+
+ virtual u8 read_rom04(offs_t offset) override { return m_rom[offset + 0x400]; }
+ virtual u8 read_rom0c(offs_t offset) override { return m_rom[offset + 0xc00]; }
+
+ virtual void write_p1(u8 data) override { m_control = data; }
+ virtual void write_p2(u8 data) override { m_bank = data & 3; }
+ virtual u8 io_read(offs_t offset) override;
+
+private:
+ u8 m_control = 0;
+ u8 m_bank = 0;
+};
+
+// device type definition
+DECLARE_DEVICE_TYPE(O2_ROM_4IN1, o2_4in1_device)
+
+#endif // MAME_BUS_ODYSSEY2_4IN1_H
diff --git a/src/devices/bus/odyssey2/chess.cpp b/src/devices/bus/odyssey2/chess.cpp
index 44890a394ce..068050a7dcd 100644
--- a/src/devices/bus/odyssey2/chess.cpp
+++ b/src/devices/bus/odyssey2/chess.cpp
@@ -1,15 +1,17 @@
// license:BSD-3-Clause
-// copyright-holders:Fabio Priuli
-/***********************************************************************************************************
+// copyright-holders:hap
+/******************************************************************************
+Videopac C7010 Chess Module emulation
+The chess engine is "Gambiet", written by Wim Rens
- Videopac Chess Module emulation
+Hardware notes:
+- NSC800 (Z80-compatible) @ 4.43MHz
+- 8KB ROM, 2KB RAM
- TODO:
- - this code is just a stub... hence, almost everything is still to do!
-
- ***********************************************************************************************************/
+Service manual with schematics is available.
+******************************************************************************/
#include "emu.h"
#include "chess.h"
@@ -19,25 +21,41 @@
// o2_chess_device - constructor
//-------------------------------------------------
-DEFINE_DEVICE_TYPE(O2_ROM_CHESS, o2_chess_device, "o2_chess", "Odyssey 2 Videopac Chess Module")
+DEFINE_DEVICE_TYPE(O2_ROM_CHESS, o2_chess_device, "o2_chess", "Odyssey 2 Videopac C7010")
+
+
+o2_chess_device::o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ o2_rom_device(mconfig, O2_ROM_CHESS, tag, owner, clock),
+ m_cpu(*this, "subcpu"),
+ m_latch(*this, "latch%u", 0)
+{ }
+void o2_chess_device::device_start()
+{
+ save_item(NAME(m_control));
+}
-o2_chess_device::o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : o2_rom_device(mconfig, O2_ROM_CHESS, tag, owner, clock)
- , m_cpu(*this, "subcpu")
+void o2_chess_device::cart_init()
{
+ if (m_rom_size != 0x2800)
+ fatalerror("o2_chess_device: Wrong ROM region size\n");
}
+//-------------------------------------------------
+// address maps
+//-------------------------------------------------
+
void o2_chess_device::chess_mem(address_map &map)
{
- map(0x0000, 0x07ff).r(FUNC(o2_chess_device::read_rom04));
+ map(0x0000, 0x1fff).r(FUNC(o2_chess_device::internal_rom_r));
+ map(0xe000, 0xe7ff).mirror(0x1800).ram();
}
void o2_chess_device::chess_io(address_map &map)
{
- map.unmap_value_high();
map.global_mask(0xff);
+ map(0x00, 0x00).mirror(0xff).r(m_latch[1], FUNC(generic_latch_8_device::read)).w(m_latch[0], FUNC(generic_latch_8_device::write));
}
@@ -47,7 +65,38 @@ void o2_chess_device::chess_io(address_map &map)
void o2_chess_device::device_add_mconfig(machine_config &config)
{
- NSC800(config, m_cpu, XTAL(4'000'000));
+ NSC800(config, m_cpu, 4.433619_MHz_XTAL);
m_cpu->set_addrmap(AS_PROGRAM, &o2_chess_device::chess_mem);
m_cpu->set_addrmap(AS_IO, &o2_chess_device::chess_io);
+
+ GENERIC_LATCH_8(config, m_latch[0]);
+ GENERIC_LATCH_8(config, m_latch[1]);
+}
+
+
+//-------------------------------------------------
+// mapper specific handlers
+//-------------------------------------------------
+
+void o2_chess_device::write_p1(u8 data)
+{
+ // P10,P14: must be low to access latches
+ // P11: reset
+ m_cpu->set_input_line(INPUT_LINE_RESET, (data & 2) ? CLEAR_LINE : ASSERT_LINE);
+
+ m_control = data;
+}
+
+u8 o2_chess_device::io_read(offs_t offset)
+{
+ if ((offset & 0xa0) == 0xa0 && (m_control & 0x11) == 0)
+ return m_latch[0]->read();
+ else
+ return 0xff;
+}
+
+void o2_chess_device::io_write(offs_t offset, u8 data)
+{
+ if (offset & 0x80 && (m_control & 0x11) == 0)
+ m_latch[1]->write(data);
}
diff --git a/src/devices/bus/odyssey2/chess.h b/src/devices/bus/odyssey2/chess.h
index da8bee54b9d..291f97e9b9d 100644
--- a/src/devices/bus/odyssey2/chess.h
+++ b/src/devices/bus/odyssey2/chess.h
@@ -1,5 +1,11 @@
// license:BSD-3-Clause
-// copyright-holders:Fabio Priuli
+// copyright-holders:hap
+/**********************************************************************
+
+ Videopac C7010 Chess Module emulation
+
+**********************************************************************/
+
#ifndef MAME_BUS_ODYSSEY2_CHESS_H
#define MAME_BUS_ODYSSEY2_CHESS_H
@@ -8,6 +14,7 @@
#include "slot.h"
#include "rom.h"
#include "cpu/z80/z80.h"
+#include "machine/gen_latch.h"
// ======================> o2_chess_device
@@ -19,14 +26,29 @@ public:
o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
protected:
+ // device-level overrides
+ virtual void device_start() override;
virtual void device_add_mconfig(machine_config &config) override;
-// virtual const rom_entry *device_rom_region() const;
+
+ virtual void cart_init() override;
+
+ virtual u8 read_rom04(offs_t offset) override { return m_rom[offset + 0x2000]; }
+ virtual u8 read_rom0c(offs_t offset) override { return m_rom[offset + 0x2000]; }
+
+ virtual void write_p1(u8 data) override;
+ virtual void io_write(offs_t offset, u8 data) override;
+ virtual u8 io_read(offs_t offset) override;
private:
required_device<nsc800_device> m_cpu;
+ required_device_array<generic_latch_8_device, 2> m_latch;
+
+ u8 internal_rom_r(offs_t offset) { return m_rom[offset]; }
void chess_io(address_map &map);
void chess_mem(address_map &map);
+
+ u8 m_control = 0;
};
// device type definition
diff --git a/src/devices/bus/odyssey2/rom.cpp b/src/devices/bus/odyssey2/rom.cpp
index c76759c5cc5..2db336ed247 100644
--- a/src/devices/bus/odyssey2/rom.cpp
+++ b/src/devices/bus/odyssey2/rom.cpp
@@ -1,5 +1,5 @@
// license:BSD-3-Clause
-// copyright-holders:Fabio Priuli
+// copyright-holders:Wilbert Pol, Fabio Priuli
/***********************************************************************************************************
@@ -54,20 +54,11 @@ void o2_rom_device::device_start()
save_item(NAME(m_bank_base));
}
-void o2_rom_device::device_reset()
-{
- m_bank_base = 0;
-}
/*-------------------------------------------------
mapper specific handlers
-------------------------------------------------*/
-void o2_rom_device::write_bank(int bank)
-{
- m_bank_base = bank;
-}
-
uint8_t o2_rom_device::read_rom04(offs_t offset)
{
return m_rom[(offset + (m_bank_base & 0x03) * 0x800) & (m_rom_size - 1)];
diff --git a/src/devices/bus/odyssey2/rom.h b/src/devices/bus/odyssey2/rom.h
index 68c63dc8e40..541a81ef742 100644
--- a/src/devices/bus/odyssey2/rom.h
+++ b/src/devices/bus/odyssey2/rom.h
@@ -1,5 +1,5 @@
// license:BSD-3-Clause
-// copyright-holders:Fabio Priuli
+// copyright-holders:Wilbert Pol, Fabio Priuli
#ifndef MAME_BUS_ODYSSEY2_ROM_H
#define MAME_BUS_ODYSSEY2_ROM_H
@@ -21,14 +21,13 @@ public:
virtual uint8_t read_rom04(offs_t offset) override;
virtual uint8_t read_rom0c(offs_t offset) override;
- virtual void write_bank(int bank) override;
+ virtual void write_p1(uint8_t data) override { m_bank_base = data & 3; }
protected:
o2_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
// device-level overrides
virtual void device_start() override;
- virtual void device_reset() override;
int m_bank_base;
};
diff --git a/src/devices/bus/odyssey2/slot.cpp b/src/devices/bus/odyssey2/slot.cpp
index 3b743b6964b..ee814e3cc26 100644
--- a/src/devices/bus/odyssey2/slot.cpp
+++ b/src/devices/bus/odyssey2/slot.cpp
@@ -116,6 +116,7 @@ static const o2_slot slot_list[] =
{ O2_STD, "o2_rom" },
{ O2_ROM12, "o2_rom12" },
{ O2_ROM16, "o2_rom16" },
+ { O2_4IN1, "o2_4in1" },
{ O2_CHESS, "o2_chess" },
{ O2_VOICE, "o2_voice" }
};
@@ -174,7 +175,7 @@ image_init_result o2_cart_slot_device::call_load()
m_type = o2_get_pcb_id(pcb_name);
}
- //printf("Type: %s\n", o2_get_slot(m_type));
+ m_cart->cart_init();
return image_init_result::PASS;
}
@@ -231,7 +232,7 @@ uint8_t o2_cart_slot_device::read_rom0c(offs_t offset)
}
/*-------------------------------------------------
- io_write
+ io
-------------------------------------------------*/
void o2_cart_slot_device::io_write(offs_t offset, uint8_t data)
@@ -240,8 +241,17 @@ void o2_cart_slot_device::io_write(offs_t offset, uint8_t data)
m_cart->io_write(offset, data);
}
+uint8_t o2_cart_slot_device::io_read(offs_t offset)
+{
+ if (m_cart)
+ return m_cart->io_read(offset);
+ else
+ return 0xff;
+}
+
#include "bus/odyssey2/rom.h"
+#include "bus/odyssey2/4in1.h"
#include "bus/odyssey2/chess.h"
#include "bus/odyssey2/voice.h"
@@ -250,6 +260,7 @@ void o2_cart(device_slot_interface &device)
device.option_add_internal("o2_rom", O2_ROM_STD);
device.option_add_internal("o2_rom12", O2_ROM_12K);
device.option_add_internal("o2_rom16", O2_ROM_16K);
+ device.option_add_internal("o2_4in1", O2_ROM_4IN1);
device.option_add_internal("o2_chess", O2_ROM_CHESS);
device.option_add_internal("o2_voice", O2_ROM_VOICE);
}
diff --git a/src/devices/bus/odyssey2/slot.h b/src/devices/bus/odyssey2/slot.h
index 69e107edc11..50119f71085 100644
--- a/src/devices/bus/odyssey2/slot.h
+++ b/src/devices/bus/odyssey2/slot.h
@@ -19,6 +19,7 @@ enum
O2_STD = 0,
O2_ROM12,
O2_ROM16,
+ O2_4IN1,
O2_CHESS,
O2_VOICE
};
@@ -35,11 +36,15 @@ public:
// reading and writing
virtual uint8_t read_rom04(offs_t offset) { return 0xff; }
virtual uint8_t read_rom0c(offs_t offset) { return 0xff; }
- virtual void write_bank(int bank) { }
+ virtual void write_p1(uint8_t data) { }
+ virtual void write_p2(uint8_t data) { }
virtual void io_write(offs_t offset, uint8_t data) { }
+ virtual uint8_t io_read(offs_t offset) { return 0xff; }
virtual DECLARE_READ_LINE_MEMBER(t0_read) { return 0; }
+ virtual void cart_init() { } // called after loading ROM
+
void rom_alloc(uint32_t size, const char *tag);
void ram_alloc(uint32_t size);
uint8_t* get_rom_base() { return m_rom; }
@@ -86,7 +91,7 @@ public:
virtual bool is_readable() const noexcept override { return true; }
virtual bool is_writeable() const noexcept override { return false; }
virtual bool is_creatable() const noexcept override { return false; }
- virtual bool must_be_loaded() const noexcept override { return false; }
+ virtual bool must_be_loaded() const noexcept override { return true; }
virtual bool is_reset_on_load() const noexcept override { return true; }
virtual const char *image_interface() const noexcept override { return "odyssey_cart"; }
virtual const char *file_extensions() const noexcept override { return "bin,rom"; }
@@ -100,9 +105,11 @@ public:
uint8_t read_rom04(offs_t offset);
uint8_t read_rom0c(offs_t offset);
void io_write(offs_t offset, uint8_t data);
+ uint8_t io_read(offs_t offset);
DECLARE_READ_LINE_MEMBER(t0_read) { if (m_cart) return m_cart->t0_read(); else return 0; }
- void write_bank(int bank) { if (m_cart) m_cart->write_bank(bank); }
+ void write_p1(uint8_t data) { if (m_cart) m_cart->write_p1(data); }
+ void write_p2(uint8_t data) { if (m_cart) m_cart->write_p2(data); }
protected:
// device-level overrides
diff --git a/src/devices/bus/odyssey2/voice.cpp b/src/devices/bus/odyssey2/voice.cpp
index 490b9b286ad..cfcbc1f03be 100644
--- a/src/devices/bus/odyssey2/voice.cpp
+++ b/src/devices/bus/odyssey2/voice.cpp
@@ -1,16 +1,14 @@
// license:BSD-3-Clause
-// copyright-holders:Fabio Priuli
-/***********************************************************************************************************
+// copyright-holders:Wilbert Pol, Fabio Priuli
+/******************************************************************************
+Magnavox The Voice emulation
- Magnavox The Voice emulation
-
- TODO:
- - load speech ROM from softlist
- - move external speech rom for S.I.D. the Spellbinder into the softlist entry
-
- ***********************************************************************************************************/
+TODO:
+- load speech ROM from softlist
+- move external speech rom for S.I.D. the Spellbinder into the softlist entry
+******************************************************************************/
#include "emu.h"
#include "voice.h"
@@ -24,18 +22,16 @@
DEFINE_DEVICE_TYPE(O2_ROM_VOICE, o2_voice_device, "o2_voice", "Odyssey 2 The Voice Passthrough Cart")
-o2_voice_device::o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : o2_rom_device(mconfig, O2_ROM_VOICE, tag, owner, clock)
- , m_speech(*this, "sp0256_speech")
- , m_subslot(*this, "subslot")
- , m_lrq_state(0)
-{
-}
-
+o2_voice_device::o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ o2_rom_device(mconfig, O2_ROM_VOICE, tag, owner, clock),
+ m_speech(*this, "sp0256_speech"),
+ m_subslot(*this, "subslot")
+{ }
void o2_voice_device::device_start()
{
save_item(NAME(m_lrq_state));
+ save_item(NAME(m_control));
}
@@ -47,7 +43,7 @@ void o2_voice_device::device_add_mconfig(machine_config &config)
{
SPEAKER(config, "mono").front_center();
- SP0256(config, m_speech, 3120000);
+ SP0256(config, m_speech, 3.12_MHz_XTAL);
m_speech->data_request_callback().set(FUNC(o2_voice_device::lrq_callback));
// The Voice uses a speaker with its own volume control so the relative volumes to use are subjective, these sound good
m_speech->add_route(ALL_OUTPUTS, "mono", 1.00);
@@ -81,15 +77,36 @@ const tiny_rom_entry *o2_voice_device::device_rom_region() const
return ROM_NAME( o2voice );
}
+
+//-------------------------------------------------
+// mapper specific handlers
+//-------------------------------------------------
+
WRITE_LINE_MEMBER(o2_voice_device::lrq_callback)
{
m_lrq_state = state;
}
-void o2_voice_device::io_write(offs_t offset, uint8_t data)
+READ_LINE_MEMBER(o2_voice_device::t0_read)
+{
+ // conflict with subslot T0
+ int state = (m_subslot->exists()) ? m_subslot->t0_read() : 0;
+ return state | (m_speech->lrq_r() ? 0 : 1);
+}
+
+void o2_voice_device::io_write(offs_t offset, u8 data)
{
- if (data & 0x20)
- m_speech->ald_w(offset & 0x7f);
- else
- m_speech->reset();
+ if (offset & 0x80 && ~m_control & 0x10)
+ {
+ // A0-A6: SP0256B A1-A7 (A8 to GND)
+ // D5: 7474 to SP0256B reset
+ if (data & 0x20)
+ m_speech->ald_w(offset & 0x7f);
+ else
+ m_speech->reset();
+ }
+
+ // possible conflict with subslot IO (works ok with 4in1, not with chess)
+ if (m_subslot->exists())
+ m_subslot->io_write(offset, data);
}
diff --git a/src/devices/bus/odyssey2/voice.h b/src/devices/bus/odyssey2/voice.h
index 37ac35dcdcb..65caab93d8d 100644
--- a/src/devices/bus/odyssey2/voice.h
+++ b/src/devices/bus/odyssey2/voice.h
@@ -1,5 +1,11 @@
// license:BSD-3-Clause
-// copyright-holders:Fabio Priuli
+// copyright-holders:Wilbert Pol, Fabio Priuli
+/******************************************************************************
+
+ Magnavox The Voice emulation
+
+******************************************************************************/
+
#ifndef MAME_BUS_ODYSSEY2_VOICE_H
#define MAME_BUS_ODYSSEY2_VOICE_H
@@ -19,29 +25,31 @@ public:
o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
// reading and writing
- virtual uint8_t read_rom04(offs_t offset) override { if (m_subslot->exists()) return m_subslot->read_rom04(offset); else return 0xff; }
- virtual uint8_t read_rom0c(offs_t offset) override { if (m_subslot->exists()) return m_subslot->read_rom0c(offset); else return 0xff; }
+ virtual u8 read_rom04(offs_t offset) override { return (m_subslot->exists()) ? m_subslot->read_rom04(offset) : 0xff; }
+ virtual u8 read_rom0c(offs_t offset) override { return (m_subslot->exists()) ? m_subslot->read_rom0c(offset) : 0xff; }
- virtual void write_bank(int bank) override { if (m_subslot->exists()) m_subslot->write_bank(bank); }
+ virtual void write_p1(u8 data) override { m_control = data; if (m_subslot->exists()) m_subslot->write_p1(data); }
+ virtual void write_p2(u8 data) override { if (m_subslot->exists()) m_subslot->write_p2(data); }
- virtual void io_write(offs_t offset, uint8_t data) override;
- virtual DECLARE_READ_LINE_MEMBER(t0_read) override { return m_speech->lrq_r() ? 0 : 1; }
+ virtual void io_write(offs_t offset, u8 data) override;
+ virtual u8 io_read(offs_t offset) override { return (m_subslot->exists()) ? m_subslot->io_read(offset) : 0xff; }
+ virtual DECLARE_READ_LINE_MEMBER(t0_read) override;
protected:
// device-level overrides
virtual void device_start() override;
- virtual void device_reset() override { }
virtual void device_add_mconfig(machine_config &config) override;
virtual const tiny_rom_entry *device_rom_region() const override;
private:
- DECLARE_WRITE_LINE_MEMBER(lrq_callback);
-
required_device<sp0256_device> m_speech;
required_device<o2_cart_slot_device> m_subslot;
- int m_lrq_state;
+ DECLARE_WRITE_LINE_MEMBER(lrq_callback);
+
+ int m_lrq_state = 0;
+ u8 m_control = 0;
};
diff --git a/src/devices/bus/spectrum/exp.cpp b/src/devices/bus/spectrum/exp.cpp
index 264ff55beb2..51950eb7bb7 100644
--- a/src/devices/bus/spectrum/exp.cpp
+++ b/src/devices/bus/spectrum/exp.cpp
@@ -200,6 +200,7 @@ void spectrum_expansion_devices(device_slot_interface &device)
device.option_add("fuller", SPECTRUM_FULLER);
device.option_add("kempjoy", SPECTRUM_KEMPJOY);
device.option_add("kempdisc", SPECTRUM_KEMPDISC);
+ device.option_add("kempcentrs", SPECTRUM_KEMPCENTRS);
device.option_add("kempcentref", SPECTRUM_KEMPCENTREF);
device.option_add("kempcentreu", SPECTRUM_KEMPCENTREU);
device.option_add("lprint", SPECTRUM_LPRINT);
@@ -215,6 +216,7 @@ void spectrum_expansion_devices(device_slot_interface &device)
device.option_add("protek", SPECTRUM_PROTEK);
device.option_add("sdi", SPECTRUM_SDI);
device.option_add("speccydos", SPECTRUM_SPECCYDOS);
+ device.option_add("spdos", SPECTRUM_SPDOS);
device.option_add("specdrum", SPECTRUM_SPECDRUM);
device.option_add("swiftdisc", SPECTRUM_SWIFTDISC);
device.option_add("swiftdisc2", SPECTRUM_SWIFTDISC2);
diff --git a/src/devices/bus/spectrum/kempdisc.cpp b/src/devices/bus/spectrum/kempdisc.cpp
index 64a466fc903..aabb847ef2a 100644
--- a/src/devices/bus/spectrum/kempdisc.cpp
+++ b/src/devices/bus/spectrum/kempdisc.cpp
@@ -22,6 +22,14 @@
- implement onboard Kempston Centronics E interace and joystick port
- add more docs/information
+*********************************************************************
+
+ Watford SP-DOS Interface
+ (c) Abbeydale Designers ltd 1984
+
+ Earlier version of Kempston Disc, uses 2Kbyte ROM with small boot loader, same FDC ports but slightly different paging.
+ Require "System disk" with DOS to function, which is not dumped / missing at the moment.
+
*********************************************************************/
#include "emu.h"
@@ -33,6 +41,7 @@
***************************************************************************/
DEFINE_DEVICE_TYPE(SPECTRUM_KEMPDISC, spectrum_kempdisc_device, "spectrum_kempdisc", "Kempston Disc Interface")
+DEFINE_DEVICE_TYPE(SPECTRUM_SPDOS, spectrum_spdos_device, "spectrum_spdos", "Watford SP-DOS Interface")
//-------------------------------------------------
@@ -67,8 +76,15 @@ ROM_START(kempdisc)
ROM_SYSTEM_BIOS(0, "kd20", "K-DOS v2.0")
ROMX_LOAD("kd20.rom", 0x0000, 0x2000, CRC(244816a7) SHA1(b08e0e30f1db4f57d38b112be0115256528c6621), ROM_BIOS(0))
ROM_SYSTEM_BIOS(1, "kd21", "K-DOS v2.1")
- ROMX_LOAD("kd21.rom", 0x0000, 0x2000, CRC(d18fb812) SHA1(b3e00bc4111ef6311789159024fb4cd25c32a72f), ROM_BIOS(1))
- // TODO add Italian clone
+ ROMX_LOAD("kd21.rom", 0x0000, 0x2000, CRC(3a0705eb) SHA1(adebc46c1b6718eaed7e2844506011787117cb05), ROM_BIOS(1))
+ //ROMX_LOAD("kd21.rom", 0x0000, 0x2000, CRC(d18fb812) SHA1(b3e00bc4111ef6311789159024fb4cd25c32a72f), ROM_BIOS(1)) // bad dump
+ ROM_SYSTEM_BIOS(2, "kd21it", "K-DOS v2.1 Italian") // copyrights and texts changed and translated
+ ROMX_LOAD("kd21it.rom", 0x0000, 0x2000, CRC(f8ccdf8a) SHA1(4a75fb4951d74e254c230d56b5566c924b3c38f6), ROM_BIOS(2))
+ROM_END
+
+ROM_START(spdos)
+ ROM_REGION(0x0800, "rom", 0)
+ ROM_LOAD("spdos.rom", 0x0000, 0x0800, CRC(87b954a3) SHA1(bb0706cf1538da8acd12b8c9cd2cd75ca689ec44))
ROM_END
//-------------------------------------------------
@@ -95,6 +111,11 @@ const tiny_rom_entry *spectrum_kempdisc_device::device_rom_region() const
return ROM_NAME(kempdisc);
}
+const tiny_rom_entry *spectrum_spdos_device::device_rom_region() const
+{
+ return ROM_NAME(spdos);
+}
+
//**************************************************************************
// LIVE DEVICE
@@ -104,8 +125,8 @@ const tiny_rom_entry *spectrum_kempdisc_device::device_rom_region() const
// spectrum_kempdisc_device - constructor
//-------------------------------------------------
-spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : device_t(mconfig, SPECTRUM_KEMPDISC, tag, owner, clock)
+spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
+ : device_t(mconfig, type, tag, owner, clock)
, device_spectrum_expansion_interface(mconfig, *this)
, m_rom(*this, "rom")
, m_fdc(*this, "fdc")
@@ -115,6 +136,16 @@ spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig
{
}
+spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : spectrum_kempdisc_device(mconfig, SPECTRUM_KEMPDISC, tag, owner, clock)
+{
+}
+
+spectrum_spdos_device::spectrum_spdos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : spectrum_kempdisc_device(mconfig, SPECTRUM_SPDOS, tag, owner, clock)
+{
+}
+
//-------------------------------------------------
// device_start - device-specific startup
//-------------------------------------------------
@@ -205,3 +236,54 @@ uint8_t spectrum_kempdisc_device::mreq_r(offs_t offset)
return data;
}
+
+
+void spectrum_spdos_device::iorq_w(offs_t offset, uint8_t data)
+{
+ switch (offset & 0xff)
+ {
+ case 0xe5: case 0xe7: case 0xed: case 0xef:
+ m_fdc->write(BIT(offset, 1) | (BIT(offset, 3) << 1), data);
+ break;
+ case 0xdf:
+ {
+ floppy_image_device* floppy = nullptr;
+ for (int i = 1; i < 5; i++)
+ if (BIT(data, i))
+ {
+ floppy = m_floppy[i - 1]->get_device();
+ break;
+ }
+
+// m_control = data;
+ m_fdc->set_floppy(floppy);
+ if (floppy) floppy->ss_w(BIT(data, 0));
+ if (data & 0xe0)
+ logerror("port DF unhandled %02X\n", data);
+ m_romcs = 0;
+ }
+ break;
+ // below probably is wrong/different for this device
+ case 0xfd:
+ m_romcs = 1;
+ break;
+ case 0xd7:
+ m_romcs = 0;
+ break;
+ }
+
+ m_exp->iorq_w(offset, data);
+}
+
+uint8_t spectrum_spdos_device::mreq_r(offs_t offset)
+{
+ uint8_t data = 0xff;
+
+ if (m_romcs)
+ data = m_rom->base()[offset & 0x7ff];
+
+ if (m_exp->romcs())
+ data &= m_exp->mreq_r(offset);
+
+ return data;
+}
diff --git a/src/devices/bus/spectrum/kempdisc.h b/src/devices/bus/spectrum/kempdisc.h
index 78009a05197..271d781d182 100644
--- a/src/devices/bus/spectrum/kempdisc.h
+++ b/src/devices/bus/spectrum/kempdisc.h
@@ -30,6 +30,7 @@ public:
DECLARE_FLOPPY_FORMATS(floppy_formats);
protected:
+ spectrum_kempdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
// device-level overrides
virtual void device_start() override;
virtual void device_reset() override;
@@ -59,9 +60,25 @@ protected:
// u8 m_control;
};
+class spectrum_spdos_device :
+ public spectrum_kempdisc_device
+{
+public:
+ // construction/destruction
+ spectrum_spdos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ // optional information overrides
+ virtual const tiny_rom_entry *device_rom_region() const override;
+
+ virtual void iorq_w(offs_t offset, uint8_t data) override;
+ virtual uint8_t mreq_r(offs_t offset) override;
+};
+
// device type definition
DECLARE_DEVICE_TYPE(SPECTRUM_KEMPDISC, spectrum_kempdisc_device)
+DECLARE_DEVICE_TYPE(SPECTRUM_SPDOS, spectrum_spdos_device)
#endif // MAME_BUS_SPECTRUM_KEMPDISC_H
diff --git a/src/devices/bus/spectrum/lprint.cpp b/src/devices/bus/spectrum/lprint.cpp
index 093c38cbac4..d6644be809b 100644
--- a/src/devices/bus/spectrum/lprint.cpp
+++ b/src/devices/bus/spectrum/lprint.cpp
@@ -11,8 +11,9 @@
(c) 1984 Euroelectronics (UK)
Centronics and RS232 interface, most common printer interface for ZX-Spectrum.
- (TODO) Kempston Centronics S Interface
- (c) 1983 Kempston Micro Electronics Ltd (UK)
+ Hilderbay Interface (c) 1983 Hilderbay Ltd (UK)
+ AKA
+ Kempston Centronics S Interface (c) 1983 Kempston Micro Electronics Ltd (UK)
ROM-less device, require printer driver to be loaded from tape.
Kempston Centronics E Interface
@@ -34,6 +35,7 @@
DEFINE_DEVICE_TYPE(SPECTRUM_LPRINT, spectrum_lprint_device, "spectrum_lprint", "ZX Lprint")
DEFINE_DEVICE_TYPE(SPECTRUM_LPRINT3, spectrum_lprint3_device, "spectrum_lprint3", "ZX Lprint III")
+DEFINE_DEVICE_TYPE(SPECTRUM_KEMPCENTRS, spectrum_kempcentrs_device, "spectrum_kempcentrs", "Hilderbay / Kempston Centronics S")
DEFINE_DEVICE_TYPE(SPECTRUM_KEMPCENTREF, spectrum_kempcentre_device, "spectrum_kempcentref", "Kempston Centronics E (flat)")
DEFINE_DEVICE_TYPE(SPECTRUM_KEMPCENTREU, spectrum_kempcentreu_device, "spectrum_kempcentreu", "Kempston Centronics E (upright)")
@@ -98,6 +100,12 @@ void spectrum_lprint3_device::device_add_mconfig(machine_config &config)
m_exp->nmi_handler().set(DEVICE_SELF_OWNER, FUNC(spectrum_expansion_slot_device::nmi_w));
}
+void spectrum_kempcentrs_device::device_add_mconfig(machine_config &config)
+{
+ CENTRONICS(config, m_centronics, centronics_devices, "printer");
+ m_centronics->busy_handler().set(FUNC(spectrum_kempcentrs_device::busy_w));
+}
+
void spectrum_kempcentre_device::device_add_mconfig(machine_config &config)
{
CENTRONICS(config, m_centronics, centronics_devices, "printer");
@@ -151,6 +159,13 @@ spectrum_lprint3_device::spectrum_lprint3_device(const machine_config &mconfig,
{
}
+spectrum_kempcentrs_device::spectrum_kempcentrs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : device_t(mconfig, SPECTRUM_KEMPCENTRS, tag, owner, clock)
+ , device_spectrum_expansion_interface(mconfig, *this)
+ , m_centronics(*this, "centronics")
+{
+}
+
spectrum_kempcentre_device::spectrum_kempcentre_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
: device_t(mconfig, type, tag, owner, clock)
, device_spectrum_expansion_interface(mconfig, *this)
@@ -188,6 +203,12 @@ void spectrum_lprint3_device::device_start()
save_item(NAME(m_busy));
}
+void spectrum_kempcentrs_device::device_start()
+{
+ m_busy = 0;
+ save_item(NAME(m_busy));
+}
+
void spectrum_kempcentre_device::device_start()
{
m_busy = 0;
@@ -212,6 +233,11 @@ void spectrum_lprint3_device::device_reset()
m_centronics->write_strobe(1);
}
+void spectrum_kempcentrs_device::device_reset()
+{
+ m_centronics->write_strobe(1);
+}
+
void spectrum_kempcentre_device::device_reset()
{
m_active = 0;
@@ -343,6 +369,47 @@ uint8_t spectrum_lprint3_device::mreq_r(offs_t offset)
//**************************************************************************
+// IMPLEMENTATION (kempcentrs)
+//**************************************************************************
+
+uint8_t spectrum_kempcentrs_device::iorq_r(offs_t offset)
+{
+ uint8_t data = 0xff;
+
+ switch (offset)
+ {
+ case 0xe2bf:
+ data &= ~1;
+ data |= m_busy << 0;
+ break;
+ }
+
+ return data;
+}
+
+void spectrum_kempcentrs_device::iorq_w(offs_t offset, uint8_t data)
+{
+ switch (offset)
+ {
+ case 0xe0bf:
+ m_centronics->write_data0(BIT(data, 0));
+ m_centronics->write_data1(BIT(data, 1));
+ m_centronics->write_data2(BIT(data, 2));
+ m_centronics->write_data3(BIT(data, 3));
+ m_centronics->write_data4(BIT(data, 4));
+ m_centronics->write_data5(BIT(data, 5));
+ m_centronics->write_data6(BIT(data, 6));
+ m_centronics->write_data7(BIT(data, 7));
+ break;
+ case 0xe3bf:
+ // bit 0 is /STROBE, other bits not known, upon init driver writes to this port 0x81 then 0x0f
+ m_centronics->write_strobe(BIT(data, 0));
+ break;
+ }
+}
+
+
+//**************************************************************************
// IMPLEMENTATION (kempcentre)
//**************************************************************************
diff --git a/src/devices/bus/spectrum/lprint.h b/src/devices/bus/spectrum/lprint.h
index 814b9ae9c62..9b673402e63 100644
--- a/src/devices/bus/spectrum/lprint.h
+++ b/src/devices/bus/spectrum/lprint.h
@@ -91,6 +91,33 @@ protected:
int m_busy;
};
+class spectrum_kempcentrs_device :
+ public device_t,
+ public device_spectrum_expansion_interface
+
+{
+public:
+ // construction/destruction
+ spectrum_kempcentrs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+
+protected:
+ // device-level overrides
+ virtual void device_start() override;
+ virtual void device_reset() override;
+
+ // optional information overrides
+ virtual void device_add_mconfig(machine_config &config) override;
+
+ virtual uint8_t iorq_r(offs_t offset) override;
+ virtual void iorq_w(offs_t offset, uint8_t data) override;
+
+ DECLARE_WRITE_LINE_MEMBER(busy_w) { m_busy = state; };
+
+ required_device<centronics_device> m_centronics;
+
+ int m_busy;
+};
+
class spectrum_kempcentre_device :
public device_t,
public device_spectrum_expansion_interface
@@ -150,6 +177,7 @@ protected:
// device type definition
DECLARE_DEVICE_TYPE(SPECTRUM_LPRINT, spectrum_lprint_device)
DECLARE_DEVICE_TYPE(SPECTRUM_LPRINT3, spectrum_lprint3_device)
+DECLARE_DEVICE_TYPE(SPECTRUM_KEMPCENTRS, spectrum_kempcentrs_device)
DECLARE_DEVICE_TYPE(SPECTRUM_KEMPCENTREF, spectrum_kempcentre_device)
DECLARE_DEVICE_TYPE(SPECTRUM_KEMPCENTREU, spectrum_kempcentreu_device)
diff --git a/src/devices/cpu/arm7/arm7thmb.cpp b/src/devices/cpu/arm7/arm7thmb.cpp
index 154e0b85095..a916e767868 100644
--- a/src/devices/cpu/arm7/arm7thmb.cpp
+++ b/src/devices/cpu/arm7/arm7thmb.cpp
@@ -654,18 +654,22 @@ void arm7_cpu_device::tg04_00_06(uint32_t pc, uint32_t op) /* SBC Rd, Rs */
void arm7_cpu_device::tg04_00_07(uint32_t pc, uint32_t op) /* ROR Rd, Rs */
{
- uint32_t rs = (op & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
- uint32_t rd = (op & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
- uint32_t rrd = GetRegister(rd);
- uint32_t imm = GetRegister(rs) & 0x0000001f;
- SetRegister(rd, (rrd >> imm) | (rrd << (32 - imm)));
- if (rrd & (1 << (imm - 1)))
- {
- set_cpsr(GET_CPSR | C_MASK);
- }
- else
- {
- set_cpsr(GET_CPSR & ~C_MASK);
+ const uint32_t rs = (op & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
+ const uint32_t rd = (op & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
+ const uint32_t rrd = GetRegister(rd);
+ const uint32_t imm = GetRegister(rs) & 0xff;
+ const uint32_t imm_masked = imm & 0x1f;
+ if (imm > 0)
+ {
+ SetRegister(rd, (rrd >> imm_masked) | (rrd << (32 - imm_masked)));
+ if (rrd & (1 << ((imm - 1) & 0x1f)))
+ {
+ set_cpsr(GET_CPSR | C_MASK);
+ }
+ else
+ {
+ set_cpsr(GET_CPSR & ~C_MASK);
+ }
}
set_cpsr(GET_CPSR & ~(Z_MASK | N_MASK));
set_cpsr(GET_CPSR | HandleALUNZFlags(GetRegister(rd)));
diff --git a/src/devices/cpu/gigatron/gigatron.cpp b/src/devices/cpu/gigatron/gigatron.cpp
index e2d3d8f6624..b40b03c08b7 100644
--- a/src/devices/cpu/gigatron/gigatron.cpp
+++ b/src/devices/cpu/gigatron/gigatron.cpp
@@ -2,12 +2,15 @@
// copyright-holders:Sterophonick, Phil Thomas
/*****************************************************************************
*
- * Skeleton device for Gigatron CPU Core
+ * Gigatron CPU Core
+ *
+ * Based on Gigatron.js by Phil Thomas
+ * https://github.com/PhilThomas/gigatron
+ *
+ * Ported to MAME framework by Sterophonick
*
*****************************************************************************/
- //https://github.com/PhilThomas/gigatron/blob/master/src/gigatron.js
-
#include "emu.h"
#include "gigatron.h"
#include "gigatrondasm.h"
@@ -30,7 +33,6 @@ DEFINE_DEVICE_TYPE(GTRON, gigatron_cpu_device, "gigatron_cpu", "Gigatron CPU")
#define gigatron_writemem16(A,B) m_data->write_dword((A),B)
#define gigatron_writemem8(A,B) m_data->write_byte((A),B)
-
/***********************************
* illegal opcodes
***********************************/
@@ -40,49 +42,6 @@ void gigatron_cpu_device::gigatron_illegal()
m_icount -= 1;
}
-/* Execute cycles */
-void gigatron_cpu_device::execute_run()
-{
- uint16_t opcode;
-
- do
- {
- m_ppc = m_pc;
- debugger_instruction_hook(m_pc);
-
- opcode = gigatron_readop(m_pc);
- m_pc = m_npc;
- m_npc = (m_pc + 1) & m_romMask;
-
- uint8_t op = (opcode >> 13) & 0x0007;
- uint8_t mode = (opcode >> 10) & 0x0007;
- uint8_t bus = (opcode >> 8) & 0x0003;
- uint8_t d = (opcode >> 0) & 0x00ff;
-
- switch (op)
- {
- case 0:
- case 1:
- case 2:
- case 3:
- case 4:
- case 5:
- aluOp(op, mode, bus, d);
- break;
- case 6:
- storeOp(op, mode, bus, d);
- break;
- case 7:
- branchOp(op, mode, bus, d);
- break;
- default:
- gigatron_illegal();
- break;
- }
- m_icount--;
- } while (m_icount > 0);
-}
-
void gigatron_cpu_device::device_start()
{
@@ -130,13 +89,62 @@ void gigatron_cpu_device::reset_cpu()
m_inReg = 0xff;
m_outx = 0;
m_out = 0;
+
+ m_out_cb(0, 0);
+ m_outx_cb(0, 0);
+
+ for(uint16_t i = 0; i < m_ramMask; i++)
+ gigatron_writemem8(i, floor(machine().rand() & 0xff));
+}
+
+/* Execute cycles */
+void gigatron_cpu_device::execute_run()
+{
+ uint16_t opcode;
+ m_inReg = m_ir_cb();
+ do
+ {
+ m_ppc = m_pc;
+ debugger_instruction_hook(m_pc);
+
+ opcode = gigatron_readop(m_pc);
+ m_pc = m_npc;
+ m_npc = (m_pc + 1) & m_romMask;
+
+ uint8_t op = (opcode >> 13) & 0x0007;
+ uint8_t mode = (opcode >> 10) & 0x0007;
+ uint8_t bus = (opcode >> 8) & 0x0003;
+ uint8_t d = (opcode >> 0) & 0x00ff;
+
+ switch (op)
+ {
+ case 0:
+ case 1:
+ case 2:
+ case 3:
+ case 4:
+ case 5:
+ aluOp(op, mode, bus, d);
+ break;
+ case 6:
+ storeOp(op, mode, bus, d);
+ break;
+ case 7:
+ branchOp(op, mode, bus, d);
+ break;
+ default:
+ gigatron_illegal();
+ break;
+ }
+ m_icount--;
+ } while (m_icount > 0);
}
void gigatron_cpu_device::branchOp(uint8_t op, uint8_t mode, uint8_t bus, uint8_t d)
{
const uint8_t ZERO = 0x80;
bool c = false;
- uint8_t ac2 = m_ac ^ ZERO;
+ uint8_t ac = m_ac ^ ZERO;
uint16_t base = m_pc & 0xff00;
switch (mode)
{
@@ -145,22 +153,22 @@ void gigatron_cpu_device::branchOp(uint8_t op, uint8_t mode, uint8_t bus, uint8_
base = m_y << 8;
break;
case 1: //bgt
- c = (ac2 > ZERO);
+ c = (ac > ZERO);
break;
case 2: //blt
- c = (ac2 < ZERO);
+ c = (ac < ZERO);
break;
case 3: //bne
- c = (ac2 != ZERO);
+ c = (ac != ZERO);
break;
case 4: //beq
- c = (ac2 == ZERO);
+ c = (ac == ZERO);
break;
case 5: //bge
- c = (ac2 >= ZERO);
+ c = (ac >= ZERO);
break;
case 6: //ble
- c = (ac2 <= ZERO);
+ c = (ac <= ZERO);
break;
case 7: //bra
c = true;
@@ -226,15 +234,15 @@ void gigatron_cpu_device::aluOp(uint8_t op, uint8_t mode, uint8_t bus, uint8_t d
break;
case 6:
case 7:
- uint16_t rising = ~(m_out & b);
+ uint16_t rising = ~m_out & b;
m_out = b;
- m_out_cb(0, m_out, 0xff);
+ m_out_cb(0, m_out);
// rising edge of out[6] registers outx from ac
if (rising & 0x40)
{
m_outx = m_ac;
- m_outx_cb(0, m_outx, 0xff);
+ m_outx_cb(0, m_outx);
}
break;
}
@@ -333,10 +341,10 @@ void gigatron_cpu_device::execute_set_input(int irqline, int state)
gigatron_cpu_device::gigatron_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
: cpu_device(mconfig, GTRON, tag, owner, clock)
- , m_ramMask(0x7fff)
+ , m_ramMask(0xffff)
, m_romMask(0xffff)
- , m_program_config("program", ENDIANNESS_BIG, 16, 14, -1)
- , m_data_config("data", ENDIANNESS_BIG, 8, 15, 0)
+ , m_program_config("program", ENDIANNESS_BIG, 16, 16, -1)
+ , m_data_config("data", ENDIANNESS_BIG, 8, 16, 0)
, m_outx_cb(*this)
, m_out_cb(*this)
, m_ir_cb(*this)
diff --git a/src/devices/cpu/gigatron/gigatron.h b/src/devices/cpu/gigatron/gigatron.h
index 411c8a041af..b224b4ab280 100644
--- a/src/devices/cpu/gigatron/gigatron.h
+++ b/src/devices/cpu/gigatron/gigatron.h
@@ -2,12 +2,15 @@
// copyright-holders:Sterophonick, Phil Thomas
/*****************************************************************************
*
- * Skeleton device for Gigatron CPU Core
+ * Gigatron CPU Core
+ *
+ * Based on Gigatron.js by Phil Thomas
+ * https://github.com/PhilThomas/gigatron
+ *
+ * Ported to MAME framework by Sterophonick
*
*****************************************************************************/
- //https://github.com/PhilThomas/gigatron/blob/master/src/gigatron.js
-
#ifndef MAME_CPU_GTRON_H
#define MAME_CPU_GTRON_H
@@ -74,7 +77,7 @@ private:
address_space_config m_program_config;
address_space_config m_data_config;
- uint16_t m_pc; /* registers */
+ uint16_t m_pc; /* program counter */
uint8_t m_flags; /* flags */
address_space *m_program;
address_space *m_data;
diff --git a/src/devices/cpu/h16/hd641016.cpp b/src/devices/cpu/h16/hd641016.cpp
index 2fa5249d562..b52b50c20bf 100644
--- a/src/devices/cpu/h16/hd641016.cpp
+++ b/src/devices/cpu/h16/hd641016.cpp
@@ -42,7 +42,7 @@ void hd641016_device::ram_map(address_map &map)
void hd641016_device::io_map(address_map &map)
{
- map.unmap_value(0);
+ map.unmap_value_low();
//map(0x128, 0x129).rw(FUNC(hd641016_device::abr0_r), FUNC(hd641016_device::abr0_w));
//map(0x12a, 0x12b).rw(FUNC(hd641016_device::arr0_r), FUNC(hd641016_device::arr0_w));
//map(0x12c, 0x12d).rw(FUNC(hd641016_device::awcr0_r), FUNC(hd641016_device::awcr0_w));
diff --git a/src/devices/cpu/hpc/hpcdasm.cpp b/src/devices/cpu/hpc/hpcdasm.cpp
index 9773ab8f444..132416cbb64 100644
--- a/src/devices/cpu/hpc/hpcdasm.cpp
+++ b/src/devices/cpu/hpc/hpcdasm.cpp
@@ -5,22 +5,16 @@
National Semiconductor HPC disassembler
Note that though all 16-bit fields in instructions have the MSB first,
- the HPC's memory organization is in fact little-endian. This is why r16
- is not used to read them.
+ the HPC's memory organization is in fact little-endian (including
+ vector and JIDW tables). This is why r16 is always swapped here.
***************************************************************************/
#include "emu.h"
-#include "util/disasmintf.h"
#include "hpcdasm.h"
-#include "util/strformat.h"
#include <cctype>
-using osd::u32;
-using util::BIT;
-using offs_t = u32;
-
const char *const hpc16083_disassembler::s_regs[128] =
{
"psw", nullptr, "SP", "PC", "A", "K", "B", "X",
@@ -270,7 +264,7 @@ offs_t hpc_disassembler::disassemble(std::ostream &stream, offs_t pc, const hpc_
if (BIT(opcode, 1))
imm = true;
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
+ src = swapendian_int16(opcodes.r16(pc + 1));
reg = opcodes.r8(pc + 3);
opcode = opcodes.r8(pc + 4);
bytes = 5;
@@ -284,7 +278,7 @@ offs_t hpc_disassembler::disassemble(std::ostream &stream, offs_t pc, const hpc_
imm = true;
src = opcodes.r8(pc + 1);
- reg = (opcodes.r8(pc + 2) << 8) | opcodes.r8(pc + 3);
+ reg = swapendian_int16(opcodes.r16(pc + 2));
opcode = opcodes.r8(pc + 4);
bytes = 5;
break;
@@ -304,15 +298,15 @@ offs_t hpc_disassembler::disassemble(std::ostream &stream, offs_t pc, const hpc_
if (BIT(opcode, 1))
imm = true;
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
- reg = (opcodes.r8(pc + 3) << 8) | opcodes.r8(pc + 4);
+ src = swapendian_int16(opcodes.r16(pc + 1));
+ reg = swapendian_int16(opcodes.r16(pc + 3));
opcode = opcodes.r8(pc + 5);
bytes = 6;
break;
case 0xa6:
idx = true;
- reg = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
+ reg = swapendian_int16(opcodes.r16(pc + 1));
src = opcodes.r8(pc + 3);
opcode = opcodes.r8(pc + 4);
bytes = 5;
@@ -389,8 +383,8 @@ offs_t hpc_disassembler::disassemble(std::ostream &stream, offs_t pc, const hpc_
case 0xa7:
imm = true;
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
- reg = (opcodes.r8(pc + 3) << 8) | opcodes.r8(pc + 4);
+ src = swapendian_int16(opcodes.r16(pc + 1));
+ reg = swapendian_int16(opcodes.r16(pc + 3));
bytes = 5;
break;
@@ -403,33 +397,33 @@ offs_t hpc_disassembler::disassemble(std::ostream &stream, offs_t pc, const hpc_
case 0xb0: case 0xb1: case 0xb2: case 0xb3:
imm = true;
reg = 0x00c8 | ((opcode & 0x03) << 1);
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
+ src = swapendian_int16(opcodes.r16(pc + 1));
bytes = 3;
break;
case 0xb8: case 0xb9: case 0xba: case 0xbb:
case 0xbc: case 0xbd: case 0xbe: case 0xbf:
imm = true;
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
+ src = swapendian_int16(opcodes.r16(pc + 1));
bytes = 3;
break;
case 0xb4: case 0xb5:
jmp = true;
- src = pc + 3 + ((opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2));
+ src = pc + 3 + swapendian_int16(opcodes.r16(pc + 1));
bytes = 3;
break;
case 0xb6:
indir = false;
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
+ src = swapendian_int16(opcodes.r16(pc + 1));
opcode = opcodes.r8(pc + 3);
bytes = 4;
break;
case 0xb7:
imm = true;
- src = (opcodes.r8(pc + 1) << 8) | opcodes.r8(pc + 2);
+ src = swapendian_int16(opcodes.r16(pc + 1));
reg = opcodes.r8(pc + 3);
bytes = 4;
break;
diff --git a/src/devices/cpu/i860/i860dec.hxx b/src/devices/cpu/i860/i860dec.hxx
index b3a6e0c00b4..af286b04c4b 100644
--- a/src/devices/cpu/i860/i860dec.hxx
+++ b/src/devices/cpu/i860/i860dec.hxx
@@ -57,21 +57,6 @@ enum {
};
-/* TODO: THESE WILL BE REPLACED BY MAME FUNCTIONS
-#define BYTE_REV32(t) \
- do { \
- (t) = ((uint32_t)(t) >> 16) | ((uint32_t)(t) << 16); \
- (t) = (((uint32_t)(t) >> 8) & 0x00ff00ff) | (((uint32_t)(t) << 8) & 0xff00ff00); \
- } while (0);
-
-#define BYTE_REV16(t) \
- do { \
- (t) = (((uint16_t)(t) >> 8) & 0x00ff) | (((uint16_t)(t) << 8) & 0xff00); \
- } while (0);
-#endif
-*/
-
-
/* Get/set general register value -- watch for r0 on writes. */
#define get_iregval(gr) (m_iregs[(gr)])
#define set_iregval(gr, val) (m_iregs[(gr)] = ((gr) == 0 ? 0 : (val)))
@@ -352,7 +337,7 @@ uint32_t i860_cpu_device::ifetch (uint32_t pc)
the BE bit), we need to adjust the instruction below on MSB hosts. */
w1 = m_program->read_dword(phys_pc);
#ifdef HOST_MSB
- BYTE_REV32 (w1);
+ w1 = swapendian_int32(w1);
#endif /* HOST_MSB. */
return w1;
}
@@ -390,7 +375,7 @@ uint32_t i860_cpu_device::get_address_translation (uint32_t vaddr, int is_datare
pg_dir_entry_a = dtb | (vdir << 2);
pg_dir_entry = m_program->read_dword(pg_dir_entry_a);
#ifdef HOST_MSB
- BYTE_REV32 (pg_dir_entry);
+ pg_dir_entry = swapendian_int32(pg_dir_entry);
#endif
/* Check for non-present PDE. */
@@ -438,7 +423,7 @@ uint32_t i860_cpu_device::get_address_translation (uint32_t vaddr, int is_datare
pg_tbl_entry_a = pfa1 | (vpage << 2);
pg_tbl_entry = m_program->read_dword(pg_tbl_entry_a);
#ifdef HOST_MSB
- BYTE_REV32 (pg_tbl_entry);
+ pg_tbl_entry = swapendian_int32(pg_tbl_entry);
#endif
/* Check for non-present PTE. */
@@ -483,8 +468,8 @@ uint32_t i860_cpu_device::get_address_translation (uint32_t vaddr, int is_datare
ttpde = pg_dir_entry | 0x20;
ttpte = pg_tbl_entry | 0x20;
#ifdef HOST_MSB
- BYTE_REV32 (ttpde);
- BYTE_REV32 (ttpte);
+ ttpde = swapendian_int32(ttpde);
+ ttpte = swapendian_int32(ttpte);
#endif
m_program->write_dword(pg_dir_entry_a, ttpde);
m_program->write_dword(pg_tbl_entry_a, ttpte);
@@ -555,7 +540,7 @@ uint32_t i860_cpu_device::readmemi_emu (uint32_t addr, int size)
{
uint32_t ret = m_program->read_word(addr);
#ifdef HOST_MSB
- BYTE_REV16 (ret);
+ ret = swapendian_int16(ret);
#endif
return ret & 0xffff;
}
@@ -563,7 +548,7 @@ uint32_t i860_cpu_device::readmemi_emu (uint32_t addr, int size)
{
uint32_t ret = m_program->read_dword(addr);
#ifdef HOST_MSB
- BYTE_REV32 (ret);
+ ret = swapendian_int32(ret);
#endif
return ret;
}
@@ -615,14 +600,14 @@ void i860_cpu_device::writememi_emu (uint32_t addr, int size, uint32_t data)
else if (size == 2)
{
#ifdef HOST_MSB
- BYTE_REV16 (data);
+ data = swapendian_int16(data);
#endif
m_program->write_word(addr, data);
}
else if (size == 4)
{
#ifdef HOST_MSB
- BYTE_REV32 (data);
+ data = swapendian_int32(data);
#endif
m_program->write_dword(addr, data);
}
@@ -4523,7 +4508,7 @@ void i860_cpu_device::disasm (uint32_t addr, int len)
fprintf (stderr, " (%s) 0x%08x: ", m_device->tag(), addr);
insn = m_program->read_dword(phys_addr);
#ifdef HOST_MSB
- BYTE_REV32 (insn);
+ insn = swapendian_int32(insn);
#endif /* HOST_MSB. */
disasm_i860 (buf, addr, insn); fprintf (stderr, "%s", buf);
fprintf (stderr, "\n");
diff --git a/src/devices/cpu/m6502/oxavix2000.lst b/src/devices/cpu/m6502/oxavix2000.lst
index a457c651418..def34dfaefe 100644
--- a/src/devices/cpu/m6502/oxavix2000.lst
+++ b/src/devices/cpu/m6502/oxavix2000.lst
@@ -355,8 +355,8 @@ ldapa_imp
prefetch();
cmppa_imp
- fatalerror("unhandled opcode %02x%04x: %02x\n", m_codebank, PPC, inst_state);
- read_pc_noinc();
+ TMP = read_full_data(m_pa);
+ do_cmp(A, TMP);
prefetch();
sbcpa_imp
diff --git a/src/devices/cpu/z80/kc82.cpp b/src/devices/cpu/z80/kc82.cpp
new file mode 100644
index 00000000000..33ede26b774
--- /dev/null
+++ b/src/devices/cpu/z80/kc82.cpp
@@ -0,0 +1,247 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Kawasaki Steel (Kawatetsu) KC82 CPU core with MMU
+
+***************************************************************************/
+
+#include "emu.h"
+#include "kc82.h"
+
+
+//-------------------------------------------------
+// kc82_device - constructor
+//-------------------------------------------------
+
+kc82_device::kc82_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor io_map)
+ : z80_device(mconfig, type, tag, owner, clock)
+ , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, 16, 10, mem_map)
+ , m_opcodes_config("opcodes", ENDIANNESS_LITTLE, 8, 20, 0, 16, 10, mem_map)
+ , m_io_config("io", ENDIANNESS_LITTLE, 8, 16, 0, io_map)
+{
+ std::fill_n(&m_mmu_a[0], 4, 0);
+ std::fill_n(&m_mmu_b[0], 5, 0);
+ std::fill_n(&m_mmu_base[0], 0x40, 0);
+}
+
+
+//-------------------------------------------------
+// memory_space_config - return a vector of
+// address space configurations for this device
+//-------------------------------------------------
+
+device_memory_interface::space_config_vector kc82_device::memory_space_config() const
+{
+ if (has_space(AS_OPCODES))
+ {
+ return space_config_vector {
+ std::make_pair(AS_PROGRAM, &m_program_config),
+ std::make_pair(AS_IO, &m_io_config),
+ std::make_pair(AS_OPCODES, &m_opcodes_config)
+ };
+ }
+ else
+ {
+ return space_config_vector {
+ std::make_pair(AS_PROGRAM, &m_program_config),
+ std::make_pair(AS_IO, &m_io_config)
+ };
+ }
+}
+
+
+//-------------------------------------------------
+// device_start - device-specific startup
+//-------------------------------------------------
+
+void kc82_device::device_start()
+{
+ z80_device::device_start();
+
+ for (int n = 1; n <= 4; n++)
+ {
+ state_add<u8>(KC82_B1 + n - 1, string_format("B%d", n).c_str(),
+ [this, n]() { return m_mmu_b[n]; },
+ [this, n](u8 data) { m_mmu_b[n] = data; mmu_remap_pages(); }
+ ).mask(0x3f);
+ if (n != 4)
+ state_add<u16>(KC82_A1 + n - 1, string_format("A%d", n).c_str(),
+ [this, n]() { return m_mmu_a[n]; },
+ [this, n](u16 data) { m_mmu_a[n] = data; mmu_remap_pages(); }
+ ).mask(0x3ff);
+ }
+
+ save_item(NAME(m_mmu_a));
+ save_item(NAME(m_mmu_b));
+}
+
+
+//-------------------------------------------------
+// device_reset - device-specific reset
+//-------------------------------------------------
+
+void kc82_device::device_reset()
+{
+ z80_device::device_reset();
+
+ std::fill_n(&m_mmu_a[1], 3, 0);
+ std::fill_n(&m_mmu_b[1], 4, 0x3f);
+ std::fill_n(&m_mmu_base[0], 0x40, 0);
+}
+
+
+//-------------------------------------------------
+// device_post_load - called after loading a
+// saved state
+//-------------------------------------------------
+
+void kc82_device::device_post_load()
+{
+ z80_device::device_post_load();
+
+ mmu_remap_pages();
+}
+
+
+//**************************************************************************
+// KC82 MMU
+//**************************************************************************
+
+//-------------------------------------------------
+// mmu_remap_pages - recalculate base addresses
+// for memory pages
+//-------------------------------------------------
+
+void kc82_device::mmu_remap_pages()
+{
+ int n = 4;
+ u32 base = 0xf0000; // A4 is fixed
+ for (u8 i = 0x3f; i != 0; --i)
+ {
+ while (n != 0 && m_mmu_b[n] >= i)
+ {
+ --n;
+ base = u32(m_mmu_a[n]) << 10;
+ }
+ m_mmu_base[i] = base;
+ }
+}
+
+
+//-------------------------------------------------
+// mmu_r - read MMU register
+//-------------------------------------------------
+
+u8 kc82_device::mmu_r(offs_t offset)
+{
+ int n = (offset >> 1) + 1;
+ if (BIT(offset, 0))
+ {
+ // read base register BRn
+ return n == 4 ? 0xf0 : (m_mmu_a[n] & 0x3fc) >> 2;
+ }
+ else
+ {
+ // read boundary/base register BBRn
+ return (n == 4 ? 0 : (m_mmu_a[n] & 0x003) << 6) | m_mmu_b[n];
+ }
+}
+
+
+//-------------------------------------------------
+// mmu_w - write to MMU register
+//-------------------------------------------------
+
+void kc82_device::mmu_w(offs_t offset, u8 data)
+{
+ int n = (offset >> 1) + 1;
+ if (BIT(offset, 0))
+ {
+ // write to base register BRn
+ if (n != 4)
+ m_mmu_a[n] = u16(data) << 2 | (m_mmu_a[n] & 0x003);
+ else if (data != 0xf0)
+ logerror("%s: Attempt to write %02X to upper 8 bits of A4\n", machine().describe_context(), data);
+ }
+ else
+ {
+ // write to boundary/base register BBRn
+ m_mmu_b[n] = data & 0x3f;
+ if (n != 4)
+ m_mmu_a[n] = (m_mmu_a[n] & 0x3fc) | (data & 0xc0) >> 6;
+ else if ((data & 0xc0) != 0)
+ logerror("%s: Attempt to write %d to lower 2 bits of A4\n", machine().describe_context(), (data & 0xc0) >> 6);
+ }
+ mmu_remap_pages();
+}
+
+
+//-------------------------------------------------
+// memory_translate - translate from logical to
+// physical addresses
+//-------------------------------------------------
+
+bool kc82_device::memory_translate(int spacenum, int intention, offs_t &address)
+{
+ if (spacenum == AS_PROGRAM || spacenum == AS_OPCODES)
+ address = (address + m_mmu_base[(address & 0xfc00) >> 10]) & 0xfffff;
+ return true;
+}
+
+
+//-------------------------------------------------
+// rm - read one byte from memory
+//-------------------------------------------------
+
+u8 kc82_device::rm(u16 addr)
+{
+ return m_data.read_byte(addr + m_mmu_base[addr >> 10]);
+}
+
+
+//-------------------------------------------------
+// wm - write one byte to memory
+//-------------------------------------------------
+
+void kc82_device::wm(u16 addr, u8 value)
+{
+ m_data.write_byte(addr + m_mmu_base[addr >> 10], value);
+}
+
+
+//-------------------------------------------------
+// rop - read opcode
+//-------------------------------------------------
+
+u8 kc82_device::rop()
+{
+ u32 pc = m_pc.w.l + m_mmu_base[m_pc.b.h >> 2];
+ m_pc.w.l++;
+ // no refresh
+ return m_opcodes.read_byte(pc);
+}
+
+
+//-------------------------------------------------
+// arg - read 8-bit argument
+//-------------------------------------------------
+
+u8 kc82_device::arg()
+{
+ u32 pc = m_pc.w.l + m_mmu_base[m_pc.b.h >> 2];
+ m_pc.w.l++;
+ return m_args.read_byte(pc);
+}
+
+
+//-------------------------------------------------
+// arg16 - read 16-bit argument
+//-------------------------------------------------
+
+u16 kc82_device::arg16()
+{
+ u16 d16 = arg();
+ d16 |= u16(arg()) << 8;
+ return d16;
+}
diff --git a/src/devices/cpu/z80/kc82.h b/src/devices/cpu/z80/kc82.h
new file mode 100644
index 00000000000..c78269c77fe
--- /dev/null
+++ b/src/devices/cpu/z80/kc82.h
@@ -0,0 +1,70 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Kawasaki Steel (Kawatetsu) KC82 CPU core with MMU
+
+***************************************************************************/
+
+#ifndef MAME_CPU_Z80_KC82_H
+#define MAME_CPU_Z80_KC82_H
+
+#pragma once
+
+#include "z80.h"
+
+
+//**************************************************************************
+// TYPE DEFINITIONS
+//**************************************************************************
+
+class kc82_device : public z80_device
+{
+public:
+ enum
+ {
+ KC82_B1 = Z80_WZ + 1, KC82_B2, KC82_B3, KC82_B4,
+ KC82_A1, KC82_A2, KC82_A3
+ };
+
+protected:
+ // construction/destruction
+ kc82_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor io_map);
+
+ // device-level overrides
+ virtual void device_start() override;
+ virtual void device_reset() override;
+ virtual void device_post_load() override;
+
+ // device_memory_interface overrides
+ virtual space_config_vector memory_space_config() const override;
+ virtual bool memory_translate(int spacenum, int intention, offs_t &address) override;
+
+ // z80_device overrides
+ virtual u8 rm(u16 addr) override;
+ virtual void wm(u16 addr, u8 value) override;
+ virtual u8 rop() override;
+ virtual u8 arg() override;
+ virtual u16 arg16() override;
+
+ // MMU access
+ u8 mmu_r(offs_t offset);
+ void mmu_w(offs_t offset, u8 data);
+
+private:
+ // internal helpers
+ void mmu_remap_pages();
+
+ // address spaces
+ address_space_config m_program_config;
+ address_space_config m_opcodes_config;
+ address_space_config m_io_config;
+
+ // MMU registers
+ u16 m_mmu_a[4];
+ u8 m_mmu_b[5];
+ u32 m_mmu_base[0x40];
+};
+
+
+#endif // MAME_CPU_Z80_KC82_H
diff --git a/src/devices/cpu/z80/kl5c80a12.cpp b/src/devices/cpu/z80/kl5c80a12.cpp
index 6e052b0a216..dd7bd6060a6 100644
--- a/src/devices/cpu/z80/kl5c80a12.cpp
+++ b/src/devices/cpu/z80/kl5c80a12.cpp
@@ -13,7 +13,7 @@
— MMU
— USART (KP51) (unemulated)
— 16-bit timer/counters (KP64, KP63) (unemulated)
- — 16-level interrupt controller (KP69) (unemulated)
+ — 16-level interrupt controller (KP69)
— Parallel ports (KP65, KP66) (unemulated)
— 512-byte high-speed RAM
— External bus interface unit (unemulated)
@@ -23,18 +23,22 @@
#include "emu.h"
#include "kl5c80a12.h"
+// device type definition
DEFINE_DEVICE_TYPE(KL5C80A12, kl5c80a12_device, "kl5c80a12", "Kawasaki Steel KL5C80A12")
+static const z80_daisy_config pseudo_daisy_config[] = { { "kp69" }, { nullptr } };
+
+
+//-------------------------------------------------
+// kl5c80a12_device - constructor
+//-------------------------------------------------
kl5c80a12_device::kl5c80a12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
- : z80_device(mconfig, KL5C80A12, tag, owner, clock)
- , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, 16, 10, address_map_constructor(FUNC(kl5c80a12_device::internal_ram), this))
- , m_opcodes_config("opcodes", ENDIANNESS_LITTLE, 8, 20, 0, 16, 10, address_map_constructor(FUNC(kl5c80a12_device::internal_ram), this))
- , m_io_config("io", ENDIANNESS_LITTLE, 8, 16, 0, address_map_constructor(FUNC(kl5c80a12_device::internal_io), this))
+ : kc82_device(mconfig, KL5C80A12, tag, owner, clock,
+ address_map_constructor(FUNC(kl5c80a12_device::internal_ram), this),
+ address_map_constructor(FUNC(kl5c80a12_device::internal_io), this))
+ , m_kp69(*this, "kp69")
{
- std::fill_n(&m_mmu_a[0], 4, 0);
- std::fill_n(&m_mmu_b[0], 5, 0);
- std::fill_n(&m_mmu_base[0], 0x40, 0);
}
@@ -55,31 +59,10 @@ void kl5c80a12_device::internal_ram(address_map &map)
void kl5c80a12_device::internal_io(address_map &map)
{
map(0x00, 0x07).mirror(0xff00).rw(FUNC(kl5c80a12_device::mmu_r), FUNC(kl5c80a12_device::mmu_w));
-}
-
-
-//-------------------------------------------------
-// memory_space_config - return a vector of
-// address space configurations for this device
-//-------------------------------------------------
-
-device_memory_interface::space_config_vector kl5c80a12_device::memory_space_config() const
-{
- if (has_space(AS_OPCODES))
- {
- return space_config_vector {
- std::make_pair(AS_PROGRAM, &m_program_config),
- std::make_pair(AS_IO, &m_io_config),
- std::make_pair(AS_OPCODES, &m_opcodes_config)
- };
- }
- else
- {
- return space_config_vector {
- std::make_pair(AS_PROGRAM, &m_program_config),
- std::make_pair(AS_IO, &m_io_config)
- };
- }
+ map(0x34, 0x34).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::isrl_r), FUNC(kp69_device::lerl_pgrl_w));
+ map(0x35, 0x35).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::isrh_r), FUNC(kp69_device::lerh_pgrh_w));
+ map(0x36, 0x36).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::imrl_r), FUNC(kp69_device::imrl_w));
+ map(0x37, 0x37).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::imrh_r), FUNC(kp69_device::ivr_imrh_w));
}
@@ -89,23 +72,9 @@ device_memory_interface::space_config_vector kl5c80a12_device::memory_space_conf
void kl5c80a12_device::device_start()
{
- z80_device::device_start();
-
- for (int n = 1; n <= 4; n++)
- {
- state_add<u8>(KC82_B1 + n - 1, string_format("B%d", n).c_str(),
- [this, n]() { return m_mmu_b[n]; },
- [this, n](u8 data) { m_mmu_b[n] = data; mmu_remap_pages(); }
- ).mask(0x3f);
- if (n != 4)
- state_add<u16>(KC82_A1 + n - 1, string_format("A%d", n).c_str(),
- [this, n]() { return m_mmu_a[n]; },
- [this, n](u16 data) { m_mmu_a[n] = data; mmu_remap_pages(); }
- ).mask(0x3ff);
- }
+ kc82_device::device_start();
- save_item(NAME(m_mmu_a));
- save_item(NAME(m_mmu_b));
+ m_kp69->add_to_state(*this, KP69_IRR);
}
@@ -115,167 +84,29 @@ void kl5c80a12_device::device_start()
void kl5c80a12_device::device_reset()
{
- z80_device::device_reset();
-
- std::fill_n(&m_mmu_a[1], 3, 0);
- std::fill_n(&m_mmu_b[1], 4, 0x3f);
- std::fill_n(&m_mmu_base[0], 0x40, 0);
+ kc82_device::device_reset();
}
//-------------------------------------------------
-// device_post_load - called after loading a
-// saved state
+// device_add_mconfig - add device-specific
+// machine configuration
//-------------------------------------------------
-void kl5c80a12_device::device_post_load()
-{
- z80_device::device_post_load();
-
- mmu_remap_pages();
-}
-
-
-/* CPU interface */
void kl5c80a12_device::device_add_mconfig(machine_config &config)
{
-}
-
-
-//**************************************************************************
-// KC82 MMU
-//**************************************************************************
-
-//-------------------------------------------------
-// mmu_remap_pages - recalculate base addresses
-// for memory pages
-//-------------------------------------------------
-
-void kl5c80a12_device::mmu_remap_pages()
-{
- int n = 4;
- u32 base = 0xf0000; // A4 is fixed
- for (u8 i = 0x3f; i != 0; --i)
- {
- while (n != 0 && m_mmu_b[n] >= i)
- {
- --n;
- base = u32(m_mmu_a[n]) << 10;
- }
- m_mmu_base[i] = base;
- }
-}
-
-
-//-------------------------------------------------
-// mmu_r - read MMU register
-//-------------------------------------------------
-
-u8 kl5c80a12_device::mmu_r(offs_t offset)
-{
- int n = (offset >> 1) + 1;
- if (BIT(offset, 0))
- {
- // read base register BRn
- return n == 4 ? 0xf0 : (m_mmu_a[n] & 0x3fc) >> 2;
- }
- else
- {
- // read boundary/base register BBRn
- return (n == 4 ? 0 : (m_mmu_a[n] & 0x003) << 6) | m_mmu_b[n];
- }
-}
-
-
-//-------------------------------------------------
-// mmu_w - write to MMU register
-//-------------------------------------------------
-
-void kl5c80a12_device::mmu_w(offs_t offset, u8 data)
-{
- int n = (offset >> 1) + 1;
- if (BIT(offset, 0))
- {
- // write to base register BRn
- if (n != 4)
- m_mmu_a[n] = u16(data) << 2 | (m_mmu_a[n] & 0x003);
- }
- else
- {
- // write to boundary/base register BBRn
- m_mmu_b[n] = data & 0x3f;
- if (n != 4)
- m_mmu_a[n] = (m_mmu_a[n] & 0x3fc) | (data & 0xc0) >> 6;
- }
- mmu_remap_pages();
-}
-
-
-//-------------------------------------------------
-// memory_translate - translate from logical to
-// physical addresses
-//-------------------------------------------------
-
-bool kl5c80a12_device::memory_translate(int spacenum, int intention, offs_t &address)
-{
- if (spacenum == AS_PROGRAM || spacenum == AS_OPCODES)
- address = (address + m_mmu_base[(address & 0xfc00) >> 10]) & 0xfffff;
- return true;
-}
-
-
-//-------------------------------------------------
-// rm - read one byte from memory
-//-------------------------------------------------
-
-u8 kl5c80a12_device::rm(u16 addr)
-{
- return m_data.read_byte(addr + m_mmu_base[addr >> 10]);
-}
-
-
-//-------------------------------------------------
-// wm - write one byte to memory
-//-------------------------------------------------
-
-void kl5c80a12_device::wm(u16 addr, u8 value)
-{
- m_data.write_byte(addr + m_mmu_base[addr >> 10], value);
-}
-
-
-//-------------------------------------------------
-// rop - read opcode
-//-------------------------------------------------
-
-u8 kl5c80a12_device::rop()
-{
- u32 pc = m_pc.w.l + m_mmu_base[m_pc.b.h >> 2];
- m_pc.w.l++;
- // no refresh
- return m_opcodes.read_byte(pc);
-}
-
-
-//-------------------------------------------------
-// arg - read 8-bit argument
-//-------------------------------------------------
-
-u8 kl5c80a12_device::arg()
-{
- u32 pc = m_pc.w.l + m_mmu_base[m_pc.b.h >> 2];
- m_pc.w.l++;
- return m_args.read_byte(pc);
+ KP69(config, m_kp69);
+ m_kp69->int_callback().set_inputline(*this, INPUT_LINE_IRQ0);
}
//-------------------------------------------------
-// arg16 - read 16-bit argument
+// device_config_complete - perform any
+// operations now that the configuration is
+// complete
//-------------------------------------------------
-u16 kl5c80a12_device::arg16()
+void kl5c80a12_device::device_config_complete()
{
- u16 d16 = arg();
- d16 |= u16(arg()) << 8;
- return d16;
+ set_daisy_config(pseudo_daisy_config);
}
diff --git a/src/devices/cpu/z80/kl5c80a12.h b/src/devices/cpu/z80/kl5c80a12.h
index 511c1214061..ebe1cb3bea3 100644
--- a/src/devices/cpu/z80/kl5c80a12.h
+++ b/src/devices/cpu/z80/kl5c80a12.h
@@ -11,67 +11,47 @@
#pragma once
-#include "z80.h"
+#include "kc82.h"
+#include "kp69.h"
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
-class kl5c80a12_device : public z80_device
+class kl5c80a12_device : public kc82_device
{
public:
enum
{
- KC82_B1 = Z80_WZ + 1, KC82_B2, KC82_B3, KC82_B4,
- KC82_A1, KC82_A2, KC82_A3
+ KP69_IRR = KC82_A3 + 1, KP69_ISR, KP69_IVR, KP69_LER, KP69_PGR, KP69_IMR
};
+ // device type constructor
kl5c80a12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
protected:
// device-level overrides
virtual void device_add_mconfig(machine_config &config) override;
+ virtual void device_config_complete() override;
virtual void device_start() override;
virtual void device_reset() override;
- virtual void device_post_load() override;
// device_execute_interface overrides
virtual u64 execute_clocks_to_cycles(u64 clocks) const noexcept override { return (clocks + 2 - 1) / 2; }
virtual u64 execute_cycles_to_clocks(u64 cycles) const noexcept override { return (cycles * 2); }
- // device_memory_interface overrides
- virtual space_config_vector memory_space_config() const override;
- virtual bool memory_translate(int spacenum, int intention, offs_t &address) override;
-
- // z80_device overrides
- virtual u8 rm(u16 addr) override;
- virtual void wm(u16 addr, u8 value) override;
- virtual u8 rop() override;
- virtual u8 arg() override;
- virtual u16 arg16() override;
-
private:
+ // internal address maps
void internal_ram(address_map &map);
void internal_io(address_map &map);
- void mmu_remap_pages();
- u8 mmu_r(offs_t offset);
- void mmu_w(offs_t offset, u8 data);
-
- // address spaces
- address_space_config m_program_config;
- address_space_config m_opcodes_config;
- address_space_config m_io_config;
-
- // MMU registers
- u16 m_mmu_a[4];
- u8 m_mmu_b[5];
- u32 m_mmu_base[0x40];
+ // subdevice finders
+ required_device<kp69_device> m_kp69;
};
-// device type definition
+// device type declaration
DECLARE_DEVICE_TYPE(KL5C80A12, kl5c80a12_device)
#endif // MAME_CPU_Z80_KL5C80A12_H
diff --git a/src/devices/cpu/z80/kl5c80a16.cpp b/src/devices/cpu/z80/kl5c80a16.cpp
new file mode 100644
index 00000000000..6328a7322f4
--- /dev/null
+++ b/src/devices/cpu/z80/kl5c80a16.cpp
@@ -0,0 +1,98 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Kawasaki Steel (Kawatetsu) KL5C80A16 CPU
+
+ Important functional blocks:
+ — MMU
+ — DMA controller (KP27) (unemulated)
+ — UART (KP61) (unemulated)
+ — Synchronous serial port (KP62) (unemulated)
+ — 16-bit timer/counters (KP63A) (unemulated)
+ — 16-level interrupt controller (KP69)
+ — Parallel ports (KP67) (unemulated)
+ — External bus/DRAM interface unit (unemulated)
+
+***************************************************************************/
+
+#include "emu.h"
+#include "kl5c80a16.h"
+
+// device type definition
+DEFINE_DEVICE_TYPE(KL5C80A16, kl5c80a16_device, "kl5c80a16", "Kawasaki Steel KL5C80A16")
+
+static const z80_daisy_config pseudo_daisy_config[] = { { "kp69" }, { nullptr } };
+
+
+//-------------------------------------------------
+// kl5c80a16_device - constructor
+//-------------------------------------------------
+
+kl5c80a16_device::kl5c80a16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
+ : kc82_device(mconfig, KL5C80A16, tag, owner, clock,
+ address_map_constructor(),
+ address_map_constructor(FUNC(kl5c80a16_device::internal_io), this))
+ , m_kp69(*this, "kp69")
+{
+}
+
+
+//-------------------------------------------------
+// internal_io - map for internal I/O registers
+//-------------------------------------------------
+
+void kl5c80a16_device::internal_io(address_map &map)
+{
+ map(0x00, 0x07).mirror(0xff00).rw(FUNC(kl5c80a16_device::mmu_r), FUNC(kl5c80a16_device::mmu_w));
+ map(0x34, 0x34).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::isrl_r), FUNC(kp69_device::lerl_pgrl_w));
+ map(0x35, 0x35).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::isrh_r), FUNC(kp69_device::lerh_pgrh_w));
+ map(0x36, 0x36).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::imrl_r), FUNC(kp69_device::imrl_w));
+ map(0x37, 0x37).mirror(0xff00).rw(m_kp69, FUNC(kp69_device::imrh_r), FUNC(kp69_device::ivr_imrh_w));
+}
+
+
+//-------------------------------------------------
+// device_start - device-specific startup
+//-------------------------------------------------
+
+void kl5c80a16_device::device_start()
+{
+ kc82_device::device_start();
+
+ m_kp69->add_to_state(*this, KP69_IRR);
+}
+
+
+//-------------------------------------------------
+// device_reset - device-specific reset
+//-------------------------------------------------
+
+void kl5c80a16_device::device_reset()
+{
+ kc82_device::device_reset();
+}
+
+
+//-------------------------------------------------
+// device_add_mconfig - add device-specific
+// machine configuration
+//-------------------------------------------------
+
+void kl5c80a16_device::device_add_mconfig(machine_config &config)
+{
+ KP69(config, m_kp69);
+ m_kp69->int_callback().set_inputline(*this, INPUT_LINE_IRQ0);
+}
+
+
+//-------------------------------------------------
+// device_config_complete - perform any
+// operations now that the configuration is
+// complete
+//-------------------------------------------------
+
+void kl5c80a16_device::device_config_complete()
+{
+ set_daisy_config(pseudo_daisy_config);
+}
diff --git a/src/devices/cpu/z80/kl5c80a16.h b/src/devices/cpu/z80/kl5c80a16.h
new file mode 100644
index 00000000000..1593787010b
--- /dev/null
+++ b/src/devices/cpu/z80/kl5c80a16.h
@@ -0,0 +1,56 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Kawasaki Steel (Kawatetsu) KL5C80A16 CPU
+
+***************************************************************************/
+
+#ifndef MAME_CPU_Z80_KL5C80A16_H
+#define MAME_CPU_Z80_KL5C80A16_H
+
+#pragma once
+
+#include "kc82.h"
+#include "kp69.h"
+
+
+//**************************************************************************
+// TYPE DEFINITIONS
+//**************************************************************************
+
+class kl5c80a16_device : public kc82_device
+{
+public:
+ enum
+ {
+ KP69_IRR = KC82_A3 + 1, KP69_ISR, KP69_IVR, KP69_LER, KP69_PGR, KP69_IMR
+ };
+
+ // device type constructor
+ kl5c80a16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
+
+protected:
+ // device-level overrides
+ virtual void device_add_mconfig(machine_config &config) override;
+ virtual void device_config_complete() override;
+ virtual void device_start() override;
+ virtual void device_reset() override;
+
+ // device_execute_interface overrides
+ virtual u64 execute_clocks_to_cycles(u64 clocks) const noexcept override { return (clocks + 2 - 1) / 2; }
+ virtual u64 execute_cycles_to_clocks(u64 cycles) const noexcept override { return (cycles * 2); }
+
+private:
+ // internal address map
+ void internal_io(address_map &map);
+
+ // subdevice finders
+ required_device<kp69_device> m_kp69;
+};
+
+
+// device type declaration
+DECLARE_DEVICE_TYPE(KL5C80A16, kl5c80a16_device)
+
+#endif // MAME_CPU_Z80_KL5C80A16_H
diff --git a/src/devices/cpu/z80/kp69.cpp b/src/devices/cpu/z80/kp69.cpp
new file mode 100644
index 00000000000..dca74ff3b25
--- /dev/null
+++ b/src/devices/cpu/z80/kp69.cpp
@@ -0,0 +1,477 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Kawasaki Steel (Kawatetsu) KP69 Interrupt Controller
+
+ This macro cell is the sole provider of maskable interrupts for
+ KC80/KC82-based microcontrollers. It responds to the CPU's internal
+ IACK and EOI outputs (the latter associated with the RETI instruction)
+ with prioritized Mode 2 vectors and nested in-service lockouts. It
+ offers no support for polled operation or daisy-chaining other
+ interrupt controllers, but it does allow code to recognize spurious
+ interrupts.
+
+ Each of the 16 interrupt sources may be programmed either as level-
+ triggered or edge-triggered, though the latter is required for
+ interrupts that are internal timer/counter outputs. These and the
+ interrupt vector register must be written first after a reset before
+ the mask and priority group registers can be defined, with no way of
+ returning to the initial mode once the vector has been set.
+
+***************************************************************************/
+
+#include "emu.h"
+#include "kp69.h"
+
+#define VERBOSE 0
+#include "logmacro.h"
+
+// device type definition
+DEFINE_DEVICE_TYPE(KP69, kp69_device, "kp69", "Kawasaki Steel KP69 Interrupt Controller")
+
+
+//-------------------------------------------------
+// kp69_base_device - constructor
+//-------------------------------------------------
+
+kp69_base_device::kp69_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
+ : device_t(mconfig, type, tag, owner, clock)
+ , device_z80daisy_interface(mconfig, *this)
+ , m_int_callback(*this)
+ , m_input_levels(0)
+ , m_irr(0)
+ , m_isr(0)
+ , m_illegal_state(false)
+ , m_ivr(0)
+ , m_imr(0xffff)
+ , m_ler(0)
+ , m_pgr(0)
+ , m_int_active(false)
+{
+}
+
+
+//-------------------------------------------------
+// kp69_device - constructor
+//-------------------------------------------------
+
+kp69_device::kp69_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
+ : kp69_base_device(mconfig, KP69, tag, owner, clock)
+ , m_ivr_written(false)
+{
+}
+
+
+//-------------------------------------------------
+// device_resolve_objects - resolve objects that
+// may be needed for other devices to set
+// initial conditions at start time
+//-------------------------------------------------
+
+void kp69_base_device::device_resolve_objects()
+{
+ // Resolve output callback
+ m_int_callback.resolve_safe();
+}
+
+
+//-------------------------------------------------
+// device_start - device-specific startup
+//-------------------------------------------------
+
+void kp69_base_device::device_start()
+{
+ // Register state for saving
+ save_item(NAME(m_input_levels));
+ save_item(NAME(m_irr));
+ save_item(NAME(m_isr));
+ save_item(NAME(m_illegal_state));
+ save_item(NAME(m_ivr));
+ save_item(NAME(m_imr));
+ save_item(NAME(m_ler));
+ save_item(NAME(m_pgr));
+ save_item(NAME(m_int_active));
+}
+
+void kp69_device::device_start()
+{
+ kp69_base_device::device_start();
+ save_item(NAME(m_ivr_written));
+}
+
+
+//-------------------------------------------------
+// add_to_state - debug state interface for MCU
+//-------------------------------------------------
+
+void kp69_base_device::add_to_state(device_state_interface &state, int index)
+{
+ state.state_add<u16>(index, "IRR", [this]() { return m_irr; }, [this](u16 data) { set_irr(data); });
+ state.state_add<u16>(index + 1, "ISR", [this]() { return m_isr; }, [this](u16 data) { set_isr(data); });
+ state.state_add(index + 2, "IVR", m_ivr).mask(0xe0);
+ state.state_add<u16>(index + 3, "LER", [this]() { return m_ler; }, [this](u16 data) { set_ler(data); });
+ state.state_add<u16>(index + 4, "PGR", [this]() { return m_pgr; }, [this](u16 data) { set_pgr(data); });
+ state.state_add<u16>(index + 5, "IMR", [this]() { return m_imr; }, [this](u16 data) { set_imr(data); });
+}
+
+
+//-------------------------------------------------
+// device_reset - device-specific reset
+//-------------------------------------------------
+
+void kp69_base_device::device_reset()
+{
+ // Reset inputs to level mode
+ m_ler = 0;
+
+ // Mask all interrupts, cancel requests and end service
+ m_imr = 0xffff;
+ m_irr = 0;
+ m_isr = 0;
+ m_illegal_state = false;
+
+ // Reset priority groups
+ m_pgr = 0;
+
+ // Deassert interrupt output
+ set_int(false);
+}
+
+void kp69_device::device_reset()
+{
+ kp69_base_device::device_reset();
+
+ // Allow LER and IVR to be written first
+ m_ivr_written = false;
+}
+
+
+//-------------------------------------------------
+// isrl_r - read lower 8 bits of ISR
+//-------------------------------------------------
+
+u8 kp69_base_device::isrl_r()
+{
+ return m_isr & 0x00ff;
+}
+
+
+//-------------------------------------------------
+// isrh_r - read upper 8 bits of ISR
+//-------------------------------------------------
+
+u8 kp69_base_device::isrh_r()
+{
+ return (m_isr & 0xff00) >> 8;
+}
+
+
+//-------------------------------------------------
+// imrl_r - read lower 8 bits of IMR
+//-------------------------------------------------
+
+u8 kp69_base_device::imrl_r()
+{
+ return m_imr & 0x00ff;
+}
+
+
+//-------------------------------------------------
+// imrh_r - read upper 8 bits of IMR
+//-------------------------------------------------
+
+u8 kp69_base_device::imrh_r()
+{
+ return (m_imr & 0xff00) >> 8;
+}
+
+
+//-------------------------------------------------
+// lerl_pgrl_w - write lower 8 bits of LER or PGR
+//-------------------------------------------------
+
+void kp69_device::lerl_pgrl_w(u8 data)
+{
+ if (m_ivr_written)
+ set_pgr((m_pgr & 0xff00) | data);
+ else
+ set_ler((m_ler & 0xff00) | data);
+}
+
+
+//-------------------------------------------------
+// lerh_pgrh_w - write upper 8 bits of LER or PGR
+//-------------------------------------------------
+
+void kp69_device::lerh_pgrh_w(u8 data)
+{
+ if (m_ivr_written)
+ set_pgr(u16(data) << 8 | (m_pgr & 0x00ff));
+ else
+ set_ler(u16(data) << 8 | (m_ler & 0x00ff));
+}
+
+
+//-------------------------------------------------
+// imrl_w - write lower 8 bits of IMR
+//-------------------------------------------------
+
+void kp69_device::imrl_w(u8 data)
+{
+ if (!m_ivr_written)
+ logerror("%s: IMRL written before IVR\n", machine().describe_context());
+
+ set_imr((m_imr & 0xff00) | data);
+}
+
+
+//-------------------------------------------------
+// ivr_imrh_w - write IVR or upper 8 bits of IMR
+//-------------------------------------------------
+
+void kp69_device::ivr_imrh_w(u8 data)
+{
+ if (m_ivr_written)
+ set_imr(u16(data) << 8 | (m_imr & 0x00ff));
+ else
+ {
+ m_ivr = data & 0xe0;
+ m_ivr_written = true;
+ }
+}
+
+
+//-------------------------------------------------
+// int_active - determine whether or not the INT
+// output is currently active
+//-------------------------------------------------
+
+bool kp69_base_device::int_active() const
+{
+ if (m_illegal_state)
+ return false;
+
+ // Compare priority of pending interrupt request with any being serviced
+ if ((m_irr & m_pgr) != 0 || (m_isr & m_pgr) != 0)
+ return (m_irr & ~m_isr & m_pgr) > (m_isr & m_pgr);
+ else
+ return (m_irr & ~m_isr) > m_isr;
+}
+
+
+//-------------------------------------------------
+// set_int - update the INT output state
+//-------------------------------------------------
+
+void kp69_base_device::set_int(bool active)
+{
+ if (m_int_active != active)
+ {
+ m_int_active = active;
+ m_int_callback(m_int_active ? ASSERT_LINE : CLEAR_LINE);
+ }
+}
+
+
+//-------------------------------------------------
+// set_input_level - set the level state of one
+// out of 16 interrupt inputs
+//-------------------------------------------------
+
+void kp69_base_device::set_input_level(int level, bool state)
+{
+ if (!BIT(m_input_levels, level) && state)
+ {
+ m_input_levels |= 1 << level;
+
+ // Masked-out interrupts cannot be requested
+ if (!BIT(m_irr, level) && !BIT(m_imr, level))
+ {
+ u16 old_ints = m_irr | m_isr;
+ m_irr |= 1 << level;
+ LOG("IRR[%d] asserted\n", level);
+ if (!m_illegal_state && (1 << level) > (BIT(m_pgr, level) ? old_ints & m_pgr : old_ints))
+ set_int(true);
+ }
+ }
+ else if (BIT(m_input_levels, level) && !state)
+ {
+ m_input_levels &= ~(1 << level);
+
+ // Level-triggered interrupts may be deasserted
+ if (!BIT(m_ler, level) && BIT(m_irr, level))
+ {
+ m_irr &= ~(1 << level);
+ LOG("IRR[%d] cleared\n", level);
+ if (!m_illegal_state)
+ set_int(int_active());
+ }
+ }
+}
+
+
+//-------------------------------------------------
+// set_irr - write a new value to the Interrupt
+// Request Register (not accessible by software)
+//-------------------------------------------------
+
+void kp69_base_device::set_irr(u16 data)
+{
+ m_irr = (data & ~m_imr & m_ler) | (m_irr & ~m_ler);
+ set_int(int_active());
+}
+
+
+//-------------------------------------------------
+// set_isr - write a new value to the In Service
+// Register (not writable by software)
+//-------------------------------------------------
+
+void kp69_base_device::set_isr(u16 data)
+{
+ m_isr = data;
+ set_int(int_active());
+}
+
+
+//-------------------------------------------------
+// set_imr - write a new value to the Interrupt
+// Mask Register
+//-------------------------------------------------
+
+void kp69_base_device::set_imr(u16 data)
+{
+ u16 old_irr = m_irr;
+ m_imr = data;
+ m_irr = (m_irr & ~data & m_ler) | (m_input_levels & ~data & ~m_ler);
+ if (m_irr != old_irr)
+ {
+ bool active = int_active();
+ if (active != m_int_active)
+ LOG("%s: INT %s (IRR = %04X, was %04X)\n", machine().describe_context(), active ? "unmasked" : "masked out", m_irr, old_irr);
+ set_int(active);
+ }
+}
+
+
+//-------------------------------------------------
+// set_ler - write a new value to the Level/Edge
+// Register
+//-------------------------------------------------
+
+void kp69_base_device::set_ler(u16 data)
+{
+ u16 old_irr = m_irr;
+ m_irr = (m_input_levels & ~data) | (m_irr & m_ler & data);
+ m_ler = data;
+ if (m_irr != old_irr)
+ set_int(int_active());
+}
+
+
+//-------------------------------------------------
+// set_pgr - write a new value to the Priority
+// Group Register
+//-------------------------------------------------
+
+void kp69_base_device::set_pgr(u16 data)
+{
+ if (m_pgr != data)
+ {
+ m_pgr = data;
+ if (!m_illegal_state && m_isr != 0)
+ set_int(int_active());
+ }
+}
+
+
+//-------------------------------------------------
+// z80daisy_irq_state - return the overall IRQ
+// state for this device
+//-------------------------------------------------
+
+int kp69_base_device::z80daisy_irq_state()
+{
+ return m_int_active ? (Z80_DAISY_INT | Z80_DAISY_IEO) : Z80_DAISY_IEO;
+}
+
+
+//-------------------------------------------------
+// z80daisy_irq_ack - acknowledge an IRQ and
+// return the appropriate vector
+//-------------------------------------------------
+
+int kp69_base_device::z80daisy_irq_ack()
+{
+ int level = -1;
+
+ // Restrict to high-priority interrupts if any of those are pending
+ if ((m_irr & m_pgr) != 0)
+ {
+ level = 31 - count_leading_zeros(u32(m_irr & m_pgr));
+ assert(level >= 0 && level < 16);
+ if ((1 << level) < (m_isr & m_pgr))
+ level = -1;
+ }
+ else if (m_irr != 0 && (m_isr & m_pgr) == 0)
+ {
+ level = 31 - count_leading_zeros(u32(m_irr));
+ assert(level >= 0 && level < 16);
+ if ((1 << level) < m_isr)
+ level = -1;
+ }
+
+ if (level != -1)
+ {
+ u8 vector = m_ivr | (level << 1);
+ if (BIT(m_ler, level))
+ {
+ LOG("%s: IRR[%d] acknowledged and cleared (vector = %02X)\n", machine().describe_context(), level, vector);
+ m_irr &= ~(1 << level);
+ }
+ else
+ LOG("%s: IR[%d] acknowledged (vector = %02X)\n", machine().describe_context(), level, vector);
+
+ m_isr |= 1 << level;
+ set_int(false);
+
+ return vector;
+ }
+
+ // Illegal interrupt operation: same vector as IR[0] but ISR[0] not set
+ LOG("%s: Illegal interrupt at IACK (vector = %02X)\n", machine().describe_context(), m_ivr);
+ m_illegal_state = true;
+ set_int(false);
+ return m_ivr;
+}
+
+
+//-------------------------------------------------
+// z80daisy_irq_reti - clear the interrupt
+// pending state to allow other interrupts through
+//-------------------------------------------------
+
+void kp69_base_device::z80daisy_irq_reti()
+{
+ if (m_illegal_state)
+ {
+ LOG("%s: End of illegal interrupt\n", machine().describe_context());
+ m_illegal_state = false;
+ }
+ else if (m_isr != 0)
+ {
+ int level = 31 - count_leading_zeros(u32((m_isr & m_pgr) != 0 ? (m_isr & m_pgr) : m_isr));
+ assert(level >= 0 && level < 16);
+
+ m_isr &= ~(1 << level);
+ LOG("%s: EOI for ISR[%d]\n", machine().describe_context(), level);
+ }
+ else
+ {
+ logerror("%s: RETI before interrupt acknowledged\n", machine().describe_context());
+ return;
+ }
+
+ set_int(int_active());
+}
diff --git a/src/devices/cpu/z80/kp69.h b/src/devices/cpu/z80/kp69.h
new file mode 100644
index 00000000000..f7747f795d6
--- /dev/null
+++ b/src/devices/cpu/z80/kp69.h
@@ -0,0 +1,105 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Kawasaki Steel (Kawatetsu) KP69 Interrupt Controller
+
+***************************************************************************/
+
+#ifndef MAME_CPU_Z80_KP69_H
+#define MAME_CPU_Z80_KP69_H
+
+#pragma once
+
+#include "machine/z80daisy.h"
+
+
+//**************************************************************************
+// TYPE DEFINITIONS
+//**************************************************************************
+
+class kp69_base_device : public device_t, public device_z80daisy_interface
+{
+public:
+ // callback to CPU
+ auto int_callback() { return m_int_callback.bind(); }
+
+ // read handlers
+ u8 isrl_r();
+ u8 isrh_r();
+ u8 imrl_r();
+ u8 imrh_r();
+
+ // interrupt inputs
+ template <int N> DECLARE_WRITE_LINE_MEMBER(ir_w)
+ {
+ static_assert(N >= 0 && N < 16, "Invalid level");
+ set_input_level(N, state);
+ }
+
+ void add_to_state(device_state_interface &state, int index);
+
+protected:
+ // construction/destruction
+ kp69_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
+
+ // device-level overrides
+ virtual void device_resolve_objects() override;
+ virtual void device_start() override;
+ virtual void device_reset() override;
+
+ // device_z80daisy_interface overrides
+ virtual int z80daisy_irq_state() override;
+ virtual int z80daisy_irq_ack() override;
+ virtual void z80daisy_irq_reti() override;
+
+ // internal helpers
+ bool int_active() const;
+ void set_int(bool active);
+ void set_input_level(int level, bool state);
+ void set_irr(u16 data);
+ void set_isr(u16 data);
+ void set_imr(u16 data);
+ void set_ler(u16 data);
+ void set_pgr(u16 data);
+
+ // callback object
+ devcb_write_line m_int_callback;
+
+ // internal state
+ u16 m_input_levels;
+ u16 m_irr;
+ u16 m_isr;
+ bool m_illegal_state;
+ u8 m_ivr;
+ u16 m_imr;
+ u16 m_ler;
+ u16 m_pgr;
+ bool m_int_active;
+};
+
+class kp69_device : public kp69_base_device
+{
+public:
+ // device type constructor
+ kp69_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
+
+ // write handlers
+ void lerl_pgrl_w(u8 data);
+ void lerh_pgrh_w(u8 data);
+ void imrl_w(u8 data);
+ void ivr_imrh_w(u8 data);
+
+protected:
+ // device-level overrides
+ virtual void device_start() override;
+ virtual void device_reset() override;
+
+private:
+ bool m_ivr_written;
+};
+
+// device type declaration
+DECLARE_DEVICE_TYPE(KP69, kp69_device)
+
+#endif // MAME_CPU_Z80_KP69_H
diff --git a/src/devices/cpu/z80/ky80.cpp b/src/devices/cpu/z80/ky80.cpp
new file mode 100644
index 00000000000..a19e0140470
--- /dev/null
+++ b/src/devices/cpu/z80/ky80.cpp
@@ -0,0 +1,56 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Taxan KY-80
+
+ This 160-pin QFP device seems to be a custom derivative of the
+ Kawasaki KC82 CPU core (fast Z80-like with built-in MMU). It seems
+ possible that it was built entirely out of Kawasaki LSI macrocells,
+ but the on-chip peripherals are at least mapped differently than in
+ either KL5C80A12 or KL5C80A16 (in the top 3/8ths of the I/O space
+ rather the bottom quarter).
+
+ On-chip features appear to include 1024 bytes of RAM, an interrupt
+ controller (not quite the same as KP69), 5 parallel ports and 2 8251-
+ like serial ports.
+
+***************************************************************************/
+
+#include "emu.h"
+#include "ky80.h"
+
+// device type definition
+DEFINE_DEVICE_TYPE(KY80, ky80_device, "ky80", "Taxan KY-80")
+
+
+//-------------------------------------------------
+// ky80_device - constructor
+//-------------------------------------------------
+
+ky80_device::ky80_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
+ : kc82_device(mconfig, KY80, tag, owner, clock,
+ address_map_constructor(FUNC(ky80_device::internal_ram), this),
+ address_map_constructor(FUNC(ky80_device::internal_io), this))
+{
+}
+
+
+//-------------------------------------------------
+// internal_ram - map for high-speed internal RAM
+//-------------------------------------------------
+
+void ky80_device::internal_ram(address_map &map)
+{
+ map(0xffc00, 0xfffff).ram().share("ram");
+}
+
+
+//-------------------------------------------------
+// internal_io - map for internal I/O registers
+//-------------------------------------------------
+
+void ky80_device::internal_io(address_map &map)
+{
+ map(0xa0, 0xa7).mirror(0xff00).rw(FUNC(ky80_device::mmu_r), FUNC(ky80_device::mmu_w));
+}
diff --git a/src/devices/cpu/z80/ky80.h b/src/devices/cpu/z80/ky80.h
new file mode 100644
index 00000000000..fce065a9c8f
--- /dev/null
+++ b/src/devices/cpu/z80/ky80.h
@@ -0,0 +1,42 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***************************************************************************
+
+ Taxan KY-80
+
+***************************************************************************/
+
+#ifndef MAME_CPU_Z80_KY80_H
+#define MAME_CPU_Z80_KY80_H
+
+#pragma once
+
+#include "kc82.h"
+
+
+//**************************************************************************
+// TYPE DEFINITIONS
+//**************************************************************************
+
+class ky80_device : public kc82_device
+{
+public:
+ // device type constructor
+ ky80_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
+
+protected:
+ // device_execute_interface overrides
+ virtual u64 execute_clocks_to_cycles(u64 clocks) const noexcept override { return (clocks + 2 - 1) / 2; }
+ virtual u64 execute_cycles_to_clocks(u64 cycles) const noexcept override { return (cycles * 2); }
+
+private:
+ // internal address maps
+ void internal_ram(address_map &map);
+ void internal_io(address_map &map);
+};
+
+
+// device type declaration
+DECLARE_DEVICE_TYPE(KY80, ky80_device)
+
+#endif // MAME_CPU_Z80_KY80_H
diff --git a/src/devices/cpu/z80/z80.cpp b/src/devices/cpu/z80/z80.cpp
index 203b62a2f17..e3575a90af7 100644
--- a/src/devices/cpu/z80/z80.cpp
+++ b/src/devices/cpu/z80/z80.cpp
@@ -125,7 +125,7 @@
/****************************************************************************/
/* The Z80 registers. halt is set to 1 when the CPU is halted, the refresh */
-/* register is calculated as follows: refresh=(r&127)|(r2&128) */
+/* register is calculated as follows: refresh=(r&127)|(r2&128) */
/****************************************************************************/
#define CF 0x01
@@ -400,7 +400,6 @@ static const uint8_t cc_ex[0x100] = {
***************************************************************/
inline void z80_device::halt()
{
- PC--;
if (!m_halt)
{
m_halt = 1;
@@ -413,11 +412,10 @@ inline void z80_device::halt()
***************************************************************/
inline void z80_device::leave_halt()
{
- if( m_halt )
+ if (m_halt)
{
m_halt = 0;
m_halt_cb(0);
- PC++;
}
}
@@ -2844,7 +2842,7 @@ OP(ed,ff) { illegal_2(); } /* DB ED
**********************************************************/
OP(op,00) { } /* NOP */
OP(op,01) { BC = arg16(); } /* LD BC,w */
-OP(op,02) { wm(BC,A); WZ_L = (BC + 1) & 0xFF; WZ_H = A; } /* LD (BC),A */
+OP(op,02) { wm(BC,A); WZ_L = (BC + 1) & 0xFF; WZ_H = A; } /* LD (BC),A */
OP(op,03) { BC++; } /* INC BC */
OP(op,04) { B = inc(B); } /* INC B */
OP(op,05) { B = dec(B); } /* DEC B */
@@ -2862,7 +2860,7 @@ OP(op,0f) { rrca();
OP(op,10) { B--; jr_cond(B, 0x10); } /* DJNZ o */
OP(op,11) { DE = arg16(); } /* LD DE,w */
-OP(op,12) { wm(DE,A); WZ_L = (DE + 1) & 0xFF; WZ_H = A; } /* LD (DE),A */
+OP(op,12) { wm(DE,A); WZ_L = (DE + 1) & 0xFF; WZ_H = A; } /* LD (DE),A */
OP(op,13) { DE++; } /* INC DE */
OP(op,14) { D = inc(D); } /* INC D */
OP(op,15) { D = dec(D); } /* DEC D */
@@ -2912,7 +2910,7 @@ OP(op,3b) { SP--;
OP(op,3c) { A = inc(A); } /* INC A */
OP(op,3d) { A = dec(A); } /* DEC A */
OP(op,3e) { A = arg(); } /* LD A,n */
-OP(op,3f) { F = ((F&(SF|ZF|YF|XF|PF|CF))|((F&CF)<<4)|(A&(YF|XF)))^CF; } /* CCF */
+OP(op,3f) { F = ((F&(SF|ZF|YF|XF|PF|CF))|((F&CF)<<4)|(A&(YF|XF)))^CF; } /* CCF */
OP(op,40) { } /* LD B,B */
OP(op,41) { B = C; } /* LD B,C */
@@ -2974,7 +2972,7 @@ OP(op,72) { wm(HL, D);
OP(op,73) { wm(HL, E); } /* LD (HL),E */
OP(op,74) { wm(HL, H); } /* LD (HL),H */
OP(op,75) { wm(HL, L); } /* LD (HL),L */
-OP(op,76) { halt(); } /* halt */
+OP(op,76) { halt(); } /* HALT */
OP(op,77) { wm(HL, A); } /* LD (HL),A */
OP(op,78) { A = B; } /* LD A,B */
@@ -3088,7 +3086,7 @@ OP(op,d7) { rst(0x10);
OP(op,d8) { ret_cond(F & CF, 0xd8); } /* RET C */
OP(op,d9) { exx(); } /* EXX */
OP(op,da) { jp_cond(F & CF); } /* JP C,a */
-OP(op,db) { unsigned n = arg() | (A << 8); A = in(n); WZ = n + 1; } /* IN A,(n) */
+OP(op,db) { unsigned n = arg() | (A << 8); A = in(n); WZ = n + 1; } /* IN A,(n) */
OP(op,dc) { call_cond(F & CF, 0xdc); } /* CALL C,a */
OP(op,dd) { m_r++; EXEC(dd,rop()); } /* **** DD xx */
OP(op,de) { sbc_a(arg()); } /* SBC A,n */
@@ -3496,6 +3494,7 @@ void nsc800_device::device_reset()
/****************************************************************************
* Execute 'cycles' T-states.
****************************************************************************/
+
void z80_device::execute_run()
{
do
@@ -3508,50 +3507,35 @@ void z80_device::execute_run()
}
// check for interrupts before each instruction
- if (m_nmi_pending)
- take_nmi();
- else if (m_irq_state != CLEAR_LINE && m_iff1 && !m_after_ei)
- take_interrupt();
+ check_interrupts();
m_after_ei = false;
m_after_ldair = false;
PRVPC = PCD;
debugger_instruction_hook(PCD);
+
m_r++;
- EXEC(op,rop());
- } while (m_icount > 0);
-}
+ uint8_t opcode = rop();
-void nsc800_device::execute_run()
-{
- do
- {
- if (m_wait_state)
+ // when in HALT state, the fetched opcode is not dispatched (aka a NOP)
+ if (m_halt)
{
- // stalled
- m_icount = 0;
- return;
+ PC--;
+ opcode = 0;
}
-
- // check for interrupts before each instruction
- if (m_nmi_pending)
- take_nmi();
- else if ((m_nsc800_irq_state[NSC800_RSTA] != CLEAR_LINE || m_nsc800_irq_state[NSC800_RSTB] != CLEAR_LINE || m_nsc800_irq_state[NSC800_RSTC] != CLEAR_LINE) && m_iff1 && !m_after_ei)
- take_interrupt_nsc800();
- else if (m_irq_state != CLEAR_LINE && m_iff1 && !m_after_ei)
- take_interrupt();
-
- m_after_ei = false;
- m_after_ldair = false;
-
- PRVPC = PCD;
- debugger_instruction_hook(PCD);
- m_r++;
- EXEC(op,rop());
+ EXEC(op,opcode);
} while (m_icount > 0);
}
+void z80_device::check_interrupts()
+{
+ if (m_nmi_pending)
+ take_nmi();
+ else if (m_irq_state != CLEAR_LINE && m_iff1 && !m_after_ei)
+ take_interrupt();
+}
+
void z80_device::execute_set_input(int inputnum, int state)
{
switch (inputnum)
@@ -3585,6 +3569,16 @@ void z80_device::execute_set_input(int inputnum, int state)
}
}
+void nsc800_device::check_interrupts()
+{
+ if (m_nmi_pending)
+ take_nmi();
+ else if ((m_nsc800_irq_state[NSC800_RSTA] != CLEAR_LINE || m_nsc800_irq_state[NSC800_RSTB] != CLEAR_LINE || m_nsc800_irq_state[NSC800_RSTC] != CLEAR_LINE) && m_iff1 && !m_after_ei)
+ take_interrupt_nsc800();
+ else if (m_irq_state != CLEAR_LINE && m_iff1 && !m_after_ei)
+ take_interrupt();
+}
+
void nsc800_device::execute_set_input(int inputnum, int state)
{
switch (inputnum)
diff --git a/src/devices/cpu/z80/z80.h b/src/devices/cpu/z80/z80.h
index 4829ab76027..8e82ccd3353 100644
--- a/src/devices/cpu/z80/z80.h
+++ b/src/devices/cpu/z80/z80.h
@@ -229,6 +229,7 @@ protected:
void otdr();
void ei();
+ virtual void check_interrupts();
void take_interrupt();
void take_nmi();
@@ -299,9 +300,9 @@ protected:
// device_execute_interface overrides
virtual uint32_t execute_input_lines() const noexcept override { return 7; }
- virtual void execute_run() override;
virtual void execute_set_input(int inputnum, int state) override;
+ virtual void check_interrupts() override;
void take_interrupt_nsc800();
uint8_t m_nsc800_irq_state[4]; /* state of NSC800 restart interrupts A, B, C */
};
diff --git a/src/devices/machine/6821pia.h b/src/devices/machine/6821pia.h
index cceff8a5a09..f6ffa71ca8b 100644
--- a/src/devices/machine/6821pia.h
+++ b/src/devices/machine/6821pia.h
@@ -57,7 +57,7 @@ public:
uint8_t read_alt(offs_t offset) { return read(((offset << 1) & 0x02) | ((offset >> 1) & 0x01)); }
void write_alt(offs_t offset, uint8_t data) { write(((offset << 1) & 0x02) | ((offset >> 1) & 0x01), data); }
- uint8_t port_b_z_mask() const { return ~m_ddr_b; } // see first note in .c
+ uint8_t port_b_z_mask() const { return ~m_ddr_b; } // see notes
void porta_w(uint8_t data);
void write_porta_line(int line, bool state);
diff --git a/src/devices/machine/dp8390.cpp b/src/devices/machine/dp8390.cpp
index c238801122b..75217661215 100644
--- a/src/devices/machine/dp8390.cpp
+++ b/src/devices/machine/dp8390.cpp
@@ -3,7 +3,7 @@
#include "emu.h"
#include "dp8390.h"
-#define DP8390_BYTE_ORDER(w) ((m_regs.dcr & 3) == 3 ? ((data << 8) | (data >> 8)) : data)
+#define DP8390_BYTE_ORDER(w) ((m_regs.dcr & 3) == 3 ? swapendian_int16(data) : data)
#define LOOPBACK (!(m_regs.dcr & 8) && (m_regs.tcr & 6))
DEFINE_DEVICE_TYPE(DP8390D, dp8390d_device, "dp8390d", "DP8390D NIC")
diff --git a/src/devices/machine/gayle.cpp b/src/devices/machine/gayle.cpp
index 1f048a83e30..0e55fcd2bb6 100644
--- a/src/devices/machine/gayle.cpp
+++ b/src/devices/machine/gayle.cpp
@@ -86,7 +86,7 @@ uint16_t gayle_device::gayle_r(offs_t offset, uint16_t mem_mask)
offset <<= 1;
// swap
- mem_mask = (mem_mask << 8) | (mem_mask >> 8);
+ mem_mask = swapendian_int16(mem_mask);
if (BIT(offset, 15))
{
@@ -113,7 +113,7 @@ uint16_t gayle_device::gayle_r(offs_t offset, uint16_t mem_mask)
logerror("gayle_r(%06x): %04x & %04x\n", offset, data, mem_mask);
// swap data
- data = (data << 8) | (data >> 8);
+ data = swapendian_int16(data);
return data;
}
@@ -123,8 +123,8 @@ void gayle_device::gayle_w(offs_t offset, uint16_t data, uint16_t mem_mask)
offset <<= 1;
// swap
- mem_mask = (mem_mask << 8) | (mem_mask >> 8);
- data = ((data << 8) | (data >> 8)) & mem_mask;
+ mem_mask = swapendian_int16(mem_mask);
+ data = swapendian_int16(data) & mem_mask;
if (VERBOSE)
logerror("gayle_w(%06x): %04x & %04x\n", offset, data, mem_mask);
diff --git a/src/devices/machine/mc6843.cpp b/src/devices/machine/mc6843.cpp
index 597cc7ee865..74945094b40 100644
--- a/src/devices/machine/mc6843.cpp
+++ b/src/devices/machine/mc6843.cpp
@@ -56,6 +56,7 @@
/* coarse delays */
#define DELAY_SEEK attotime::from_usec( 100 ) /* track seek time */
#define DELAY_ADDR attotime::from_usec( 100 ) /* search-address time */
+#define DELAY_CRC attotime::from_usec( 64 ) /* read crc time */
@@ -68,7 +69,7 @@ static const char *const mc6843_cmd[16] =
-DEFINE_DEVICE_TYPE(MC6843, mc6843_device, "mc5843", "Motorola MC6843 FDC")
+DEFINE_DEVICE_TYPE(MC6843, mc6843_device, "mc6843", "Motorola MC6843 FDC")
mc6843_device::mc6843_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
: device_t(mconfig, MC6843, tag, owner, clock),
@@ -90,6 +91,7 @@ mc6843_device::mc6843_device(const machine_config &mconfig, const char *tag, dev
m_data_idx(0),
m_data_id(0),
m_index_pulse(0),
+ m_crc_wait(0),
m_timer_cont(nullptr)
{
for (auto & elem : m_data)
@@ -124,6 +126,7 @@ void mc6843_device::device_start()
save_item(NAME(m_data_size));
save_item(NAME(m_data_idx));
save_item(NAME(m_data_id));
+ save_item(NAME(m_crc_wait));
}
//-------------------------------------------------
@@ -155,6 +158,7 @@ void mc6843_device::device_reset()
m_data_size = 0;
m_data_idx = 0;
+ m_crc_wait = 0;
m_timer_cont->adjust( attotime::never );
}
@@ -219,6 +223,7 @@ void mc6843_device::set_index_pulse( int index_pulse )
void mc6843_device::cmd_end( )
{
int cmd = m_CMR & 0x0f;
+
if ( ( cmd == CMD_STZ ) || ( cmd == CMD_SEK ) )
{
m_ISR |= 0x02; /* set Settling Time Complete */
@@ -392,7 +397,11 @@ void mc6843_device::cont_SR( )
status_update( );
}
-
+void mc6843_device::finish_SR( )
+{
+ m_crc_wait = 0;
+ cmd_end( );
+}
/* Single / Multiple Sector Write bottom half */
void mc6843_device::cont_SW( )
@@ -430,12 +439,17 @@ void mc6843_device::device_timer(emu_timer &timer, device_timer_id id, int param
{
case CMD_STZ: finish_STZ( ); break;
case CMD_SEK: finish_SEK( ); break;
- case CMD_SSR: cont_SR( ); break;
+ case CMD_SSR:
+ case CMD_MSR:
+ if ( m_crc_wait )
+ finish_SR( );
+ else
+ cont_SR( );
+ break;
case CMD_SSW: cont_SW( ); break;
case CMD_RCR: finish_RCR( ); break;
case CMD_SWD: cont_SW( ); break;
case CMD_MSW: cont_SW( ); break;
- case CMD_MSR: cont_SR( ); break;
}
}
break;
@@ -460,6 +474,12 @@ uint8_t mc6843_device::read(offs_t offset)
{
int cmd = m_CMR & 0x0f;
+ if (machine().side_effects_disabled())
+ {
+ data = m_data[0];
+ break;
+ }
+
LOG( "%f %s mc6843_r: data input cmd=%s(%i), pos=%i/%i, GCR=%i, ",
machine().time().as_double(), machine().describe_context(),
mc6843_cmd[cmd], cmd, m_data_idx,
@@ -487,13 +507,15 @@ uint8_t mc6843_device::read(offs_t offset)
m_SAR++;
if ( m_GCR == 0xff )
{
- cmd_end( );
+ m_crc_wait = 1;
+ m_timer_cont->adjust( DELAY_CRC );
}
else if ( m_SAR > 26 )
{
m_STRB |= 0x08; /* set Sector Address Undetected */
- cmd_end( );
+ m_crc_wait = 1;
+ m_timer_cont->adjust( DELAY_CRC );
}
else
{
@@ -502,7 +524,8 @@ uint8_t mc6843_device::read(offs_t offset)
}
else
{
- cmd_end( );
+ m_crc_wait = 1;
+ m_timer_cont->adjust( DELAY_CRC );
}
}
}
@@ -524,6 +547,8 @@ uint8_t mc6843_device::read(offs_t offset)
case 1: /* Current-Track Address Register (CTAR) */
data = m_CTAR;
+ if (machine().side_effects_disabled())
+ break;
LOG( "%f %s mc6843_r: read CTAR %i (actual=%i)\n",
machine().time().as_double(), machine().describe_context(), data,
floppy_image()->floppy_drive_get_current_track());
@@ -531,6 +556,8 @@ uint8_t mc6843_device::read(offs_t offset)
case 2: /* Interrupt Status Register (ISR) */
data = m_ISR;
+ if (machine().side_effects_disabled())
+ break;
LOG( "%f %s mc6843_r: read ISR %02X: cmd=%scomplete settle=%scomplete sense-rq=%i STRB=%i\n",
machine().time().as_double(), machine().describe_context(), data,
(data & 1) ? "" : "not-" , (data & 2) ? "" : "not-",
@@ -546,17 +573,20 @@ uint8_t mc6843_device::read(offs_t offset)
/* update */
legacy_floppy_image_device* img = floppy_image( );
int flag = img->floppy_drive_get_flag_state( FLOPPY_DRIVE_READY);
- m_STRA &= 0xa3;
+ data = m_STRA & 0xa3;
if ( flag & FLOPPY_DRIVE_READY )
- m_STRA |= 0x04;
+ data |= 0x04;
- m_STRA |= !img->floppy_tk00_r() << 3;
- m_STRA |= !img->floppy_wpt_r() << 4;
+ data |= !img->floppy_tk00_r() << 3;
+ data |= !img->floppy_wpt_r() << 4;
if ( m_index_pulse )
- m_STRA |= 0x40;
+ data |= 0x40;
- data = m_STRA;
+ if (machine().side_effects_disabled())
+ break;
+
+ m_STRA = data;
LOG( "%f %s mc6843_r: read STRA %02X: data-rq=%i del-dta=%i ready=%i t0=%i wp=%i trk-dif=%i idx=%i busy=%i\n",
machine().time().as_double(), machine().describe_context(), data,
data & 1, (data >> 1) & 1, (data >> 2) & 1, (data >> 3) & 1,
@@ -566,6 +596,8 @@ uint8_t mc6843_device::read(offs_t offset)
case 4: /* Status Register B (STRB) */
data = m_STRB;
+ if (machine().side_effects_disabled())
+ break;
LOG( "%f %s mc6843_r: read STRB %02X: data-err=%i CRC-err=%i dta--mrk-err=%i sect-mrk-err=%i seek-err=%i fi=%i wr-err=%i hard-err=%i\n",
machine().time().as_double(), machine().describe_context(), data,
data & 1, (data >> 1) & 1, (data >> 2) & 1, (data >> 3) & 1,
@@ -578,6 +610,8 @@ uint8_t mc6843_device::read(offs_t offset)
case 7: /* Logical-Track Address Register (LTAR) */
data = m_LTAR;
+ if (machine().side_effects_disabled())
+ break;
LOG( "%f %s mc6843_r: read LTAR %i (actual=%i)\n",
machine().time().as_double(), machine().describe_context(), data,
floppy_image()->floppy_drive_get_current_track());
@@ -682,6 +716,7 @@ void mc6843_device::write(offs_t offset, uint8_t data)
uint8_t filler = 0xe5; /* standard Thomson filler */
LOG( "%f %s mc6843_w: address id detected track=%i sector=%i\n", machine().time().as_double(), machine().describe_context(), track, sector);
img->floppy_drive_format_sector( m_side, sector, track, 0, sector, 0, filler );
+ m_data_idx = 0;
}
else
{
diff --git a/src/devices/machine/mc6843.h b/src/devices/machine/mc6843.h
index 895e80d9458..488b4671026 100644
--- a/src/devices/machine/mc6843.h
+++ b/src/devices/machine/mc6843.h
@@ -75,6 +75,7 @@ private:
uint32_t m_data_idx; /* current read/write position in data */
uint32_t m_data_id; /* chrd_id for sector write */
uint8_t m_index_pulse;
+ uint8_t m_crc_wait;
/* trigger delayed actions (bottom halves) */
emu_timer* m_timer_cont;
@@ -88,6 +89,7 @@ private:
int address_search_read(chrn_id* id);
void finish_RCR();
void cont_SR();
+ void finish_SR();
void cont_SW();
};
diff --git a/src/devices/machine/mc68681.cpp b/src/devices/machine/mc68681.cpp
index 2787720cc64..0f6f8830ea1 100644
--- a/src/devices/machine/mc68681.cpp
+++ b/src/devices/machine/mc68681.cpp
@@ -439,28 +439,25 @@ TIMER_CALLBACK_MEMBER(duart_base_device::duart_timer_callback)
}
// timer driving any serial channels?
- if (BIT(ACR, 7) == 1)
- {
- uint8_t csr = m_chanA->get_chan_CSR();
+ uint8_t csr = m_chanA->get_chan_CSR();
- if ((csr & 0xf0) == 0xd0) // tx is timer driven
- {
- m_chanA->tx_clock_w(half_period);
- }
- if ((csr & 0x0f) == 0x0d) // rx is timer driven
- {
- m_chanA->rx_clock_w(half_period);
- }
+ if ((csr & 0x0f) == 0x0d) // tx is timer driven
+ {
+ m_chanA->tx_16x_clock_w(half_period);
+ }
+ if ((csr & 0xf0) == 0xd0) // rx is timer driven
+ {
+ m_chanA->rx_16x_clock_w(half_period);
+ }
- csr = m_chanB->get_chan_CSR();
- if ((csr & 0xf0) == 0xd0) // tx is timer driven
- {
- m_chanB->tx_clock_w(half_period);
- }
- if ((csr & 0x0f) == 0x0d) // rx is timer driven
- {
- m_chanB->rx_clock_w(half_period);
- }
+ csr = m_chanB->get_chan_CSR();
+ if ((csr & 0x0f) == 0x0d) // tx is timer driven
+ {
+ m_chanB->tx_16x_clock_w(half_period);
+ }
+ if ((csr & 0xf0) == 0xd0) // rx is timer driven
+ {
+ m_chanB->rx_16x_clock_w(half_period);
}
if (!half_period)
@@ -1148,8 +1145,9 @@ duart_channel::duart_channel(const machine_config &mconfig, const char *tag, dev
, rx_enabled(0)
, rx_fifo_num(0)
, tx_enabled(0)
+ , m_tx_break(false)
{
- std::fill_n(&rx_fifo[0], MC68681_RX_FIFO_SIZE, 0);
+ std::fill_n(&rx_fifo[0], MC68681_RX_FIFO_SIZE + 1, 0);
}
void duart_channel::device_start()
@@ -1173,6 +1171,7 @@ void duart_channel::device_start()
save_item(NAME(tx_enabled));
save_item(NAME(tx_data));
save_item(NAME(tx_ready));
+ save_item(NAME(m_tx_break));
}
void duart_channel::device_reset()
@@ -1186,6 +1185,7 @@ void duart_channel::device_reset()
tx_baud_rate = rx_baud_rate = 0;
CSR = 0;
+ m_tx_break = false;
}
// serial device virtual overrides
@@ -1208,18 +1208,28 @@ void duart_channel::rcv_complete()
void duart_channel::rx_fifo_push(uint8_t data, uint8_t errors)
{
- if (rx_fifo_num >= MC68681_RX_FIFO_SIZE)
+ if (rx_fifo_num == (MC68681_RX_FIFO_SIZE + 1))
{
logerror("68681: FIFO overflow\n");
SR |= STATUS_OVERRUN_ERROR;
- return;
+ // In case of overrun the FIFO tail entry is overwritten
+ // Back rx_fifo_write_ptr up by one position
+ if (rx_fifo_write_ptr)
+ rx_fifo_write_ptr--;
+ else
+ rx_fifo_write_ptr = MC68681_RX_FIFO_SIZE;
}
rx_fifo[rx_fifo_write_ptr++] = data | (errors << 8);
- if (rx_fifo_write_ptr == MC68681_RX_FIFO_SIZE)
+ if (rx_fifo_write_ptr > MC68681_RX_FIFO_SIZE)
rx_fifo_write_ptr = 0;
- if (rx_fifo_num++ == 0)
+ if (rx_fifo_num <= MC68681_RX_FIFO_SIZE)
+ {
+ rx_fifo_num++;
+ }
+
+ if (rx_fifo_num == 1)
{
SR |= STATUS_RECEIVER_READY;
if (!(MR1 & MODE_BLOCK_ERROR))
@@ -1238,9 +1248,9 @@ void duart_channel::tra_complete()
SR |= STATUS_TRANSMITTER_READY;
if (m_ch == 0)
- m_uart->clear_ISR_bits(INT_TXRDYA);
+ m_uart->set_ISR_bits(INT_TXRDYA);
else
- m_uart->clear_ISR_bits(INT_TXRDYB);
+ m_uart->set_ISR_bits(INT_TXRDYB);
// if local loopback is on, write the transmitted data as if a byte had been received
if ((MR2 & 0xc0) == 0x80)
@@ -1363,13 +1373,17 @@ uint8_t duart_channel::read_rx_fifo()
}
rv = rx_fifo[rx_fifo_read_ptr++];
- if (rx_fifo_read_ptr == MC68681_RX_FIFO_SIZE)
+ if (rx_fifo_read_ptr > MC68681_RX_FIFO_SIZE)
{
rx_fifo_read_ptr = 0;
}
rx_fifo_num--;
- SR &= ~STATUS_FIFO_FULL;
+ if (rx_fifo_num == (MC68681_RX_FIFO_SIZE - 1))
+ {
+ SR &= ~STATUS_FIFO_FULL;
+ }
+
if (!(MR1 & MODE_BLOCK_ERROR))
SR &= ~(STATUS_RECEIVED_BREAK | STATUS_FRAMING_ERROR | STATUS_PARITY_ERROR);
if (rx_fifo_num == 0)
@@ -1549,7 +1563,36 @@ void duart_channel::write_CR(uint8_t data)
else
m_uart->clear_ISR_bits(INT_DELTA_BREAK_B);
break;
- /* TODO: case 6 and case 7 are start break and stop break respectively, which start or stop holding the TxDA or TxDB line low (space) after whatever data is in the buffer finishes transmitting (following the stop bit?), or after two bit-times if no data is being transmitted */
+ case 6: /* Start Tx break */
+ if (!m_tx_break)
+ {
+ m_tx_break = true;
+ if ((MR2 & 0xc0) == 0x80)
+ {
+ // Local loopback mode: set delta break in ISR, simulate break rx
+ if (m_ch == 0)
+ m_uart->set_ISR_bits(INT_DELTA_BREAK_A);
+ else
+ m_uart->set_ISR_bits(INT_DELTA_BREAK_B);
+ rx_fifo_push(0 , STATUS_RECEIVED_BREAK);
+ }
+ // TODO: Actually send break signal
+ }
+ break;
+ case 7: /* Stop tx break */
+ if (m_tx_break)
+ {
+ m_tx_break = false;
+ if ((MR2 & 0xc0) == 0x80)
+ {
+ // Local loopback mode: set delta break in ISR
+ if (m_ch == 0)
+ m_uart->set_ISR_bits(INT_DELTA_BREAK_A);
+ else
+ m_uart->set_ISR_bits(INT_DELTA_BREAK_B);
+ }
+ }
+ break;
default:
LOG("68681: Unhandled command (%x) in CR%d\n", (data >> 4) & 0x07, m_ch);
break;
@@ -1623,3 +1666,43 @@ uint8_t duart_channel::get_chan_CSR()
{
return CSR;
}
+
+void duart_channel::tx_16x_clock_w(bool state)
+{
+ if (state)
+ {
+ m_tx_prescaler--;
+ if (m_tx_prescaler == 8)
+ {
+ tx_clock_w(true);
+ }
+ else if (m_tx_prescaler == 0)
+ {
+ m_tx_prescaler = 16;
+ tx_clock_w(false);
+ }
+ }
+}
+
+void duart_channel::rx_16x_clock_w(bool state)
+{
+ if (!is_receive_register_synchronized())
+ {
+ // Skip over the start bit once synchonization is achieved
+ m_rx_prescaler = 32;
+ rx_clock_w(true);
+ }
+ else if (state)
+ {
+ m_rx_prescaler--;
+ if (m_rx_prescaler == 8)
+ {
+ rx_clock_w(false);
+ }
+ else if (m_rx_prescaler == 0)
+ {
+ m_rx_prescaler = 16;
+ rx_clock_w(true);
+ }
+ }
+}
diff --git a/src/devices/machine/mc68681.h b/src/devices/machine/mc68681.h
index 480fad6aba7..b1127642c02 100644
--- a/src/devices/machine/mc68681.h
+++ b/src/devices/machine/mc68681.h
@@ -44,6 +44,9 @@ public:
void write_MR1(uint8_t data){ MR1 = data; }
void write_MR2(uint8_t data){ MR2 = data; }
+ void tx_16x_clock_w(bool state);
+ void rx_16x_clock_w(bool state);
+
private:
/* Registers */
uint8_t CR; /* Command register */
@@ -58,7 +61,7 @@ private:
/* Receiver */
uint8_t rx_enabled;
- uint16_t rx_fifo[MC68681_RX_FIFO_SIZE];
+ uint16_t rx_fifo[MC68681_RX_FIFO_SIZE + 1];
int rx_fifo_read_ptr;
int rx_fifo_write_ptr;
int rx_fifo_num;
@@ -69,6 +72,10 @@ private:
uint8_t tx_enabled;
uint8_t tx_data;
uint8_t tx_ready;
+ bool m_tx_break;
+
+ /* Rx/Tx clocking */
+ uint8_t m_rx_prescaler , m_tx_prescaler;
duart_base_device *m_uart;
diff --git a/src/devices/machine/netlist.cpp b/src/devices/machine/netlist.cpp
index 757d084c415..b98ffddbe1e 100644
--- a/src/devices/machine/netlist.cpp
+++ b/src/devices/machine/netlist.cpp
@@ -261,8 +261,8 @@ netlist_source_memregion_t::stream_ptr netlist_source_memregion_t::stream(const
if (m_dev.has_running_machine())
{
memory_region *mem = m_dev.memregion(m_name.c_str());
- stream_ptr ret(std::make_unique<std::istringstream>(pstring(reinterpret_cast<char *>(mem->base()), mem->bytes())));
- ret->imbue(std::locale::classic());
+ stream_ptr ret(std::make_unique<std::istringstream>(pstring(reinterpret_cast<char *>(mem->base()), mem->bytes())), name);
+ ret.stream().imbue(std::locale::classic());
return ret;
}
else
@@ -302,12 +302,12 @@ netlist_data_memregions_t::stream_ptr netlist_data_memregions_t::stream(const ps
memory_region *mem = m_dev.memregion(name.c_str());
if (mem != nullptr)
{
- stream_ptr ret(std::make_unique<std::istringstream>(std::string(reinterpret_cast<char *>(mem->base()), mem->bytes()), std::ios_base::binary));
- ret->imbue(std::locale::classic());
+ stream_ptr ret(std::make_unique<std::istringstream>(std::string(reinterpret_cast<char *>(mem->base()), mem->bytes()), std::ios_base::binary), name);
+ ret.stream().imbue(std::locale::classic());
return ret;
}
else
- return stream_ptr(nullptr);
+ return stream_ptr();
}
else
{
@@ -315,12 +315,12 @@ netlist_data_memregions_t::stream_ptr netlist_data_memregions_t::stream(const ps
if (rom_exists(m_dev.mconfig().root_device(), pstring(m_dev.tag()) + ":" + name))
{
// Create an empty stream.
- stream_ptr ret(std::make_unique<std::istringstream>(std::ios_base::binary));
- ret->imbue(std::locale::classic());
+ stream_ptr ret(std::make_unique<std::istringstream>(std::ios_base::binary), name);
+ ret.stream().imbue(std::locale::classic());
return ret;
}
else
- return stream_ptr(nullptr);
+ return stream_ptr();
}
}
@@ -881,13 +881,15 @@ void netlist_mame_stream_output_device::process(netlist::netlist_time_ext tim, n
m_buffer.push_back(static_cast<stream_sample_t>(m_cur));
}
- /* ignore spikes */
- if (plib::abs(val) < 32767.0)
+ // clamp to avoid spikes, but not too hard, as downstream processing, volume
+ // controls, etc may bring values above 32767 back down in range; some clamping
+ // is still useful, however, as the mixing is done with integral values
+ if (plib::abs(val) < 32767.0*256.0)
m_cur = val;
else if (val > 0.0)
- m_cur = 32767.0;
+ m_cur = 32767.0*256.0;
else
- m_cur = -32767.0;
+ m_cur = -32767.0*256.0;
}
@@ -976,6 +978,8 @@ std::unique_ptr<netlist::netlist_state_t> netlist_mame_device::base_validity_che
{
try
{
+ plib::chrono::timer<plib::chrono::system_ticks> t;
+ t.start();
auto lnetlist = std::make_unique<netlist::netlist_state_t>("netlist",
plib::make_unique<netlist_validate_callbacks_t, netlist::host_arena>());
// enable validation mode
@@ -993,6 +997,8 @@ std::unique_ptr<netlist::netlist_state_t> netlist_mame_device::base_validity_che
}
}
+ t.stop();
+ //printf("time %s %f\n", this->mconfig().gamedrv().name, t.as_seconds<double>());
return lnetlist;
}
catch (memregion_not_set &err)
@@ -1013,6 +1019,7 @@ std::unique_ptr<netlist::netlist_state_t> netlist_mame_device::base_validity_che
void netlist_mame_device::device_validity_check(validity_checker &valid) const
{
+
base_validity_check(valid);
//rom_exists(mconfig().root_device());
LOGDEVCALLS("device_validity_check %s\n", this->mconfig().gamedrv().name);
@@ -1022,7 +1029,6 @@ void netlist_mame_device::device_validity_check(validity_checker &valid) const
void netlist_mame_device::device_start()
{
LOGDEVCALLS("device_start entry\n");
-
m_attotime_per_clock = attotime(0, m_attoseconds_per_clock);
//netlist().save(*this, m_cur_time, pstring(this->name()), "m_cur_time");
@@ -1084,7 +1090,8 @@ void netlist_mame_device::device_reset()
void netlist_mame_device::device_stop()
{
LOGDEVCALLS("device_stop\n");
- netlist().exec().stop();
+ if (m_netlist)
+ m_netlist->exec().stop();
}
void netlist_mame_device::device_post_load()
diff --git a/src/devices/machine/sensorboard.cpp b/src/devices/machine/sensorboard.cpp
index 62d98add57c..e3e168d6e16 100644
--- a/src/devices/machine/sensorboard.cpp
+++ b/src/devices/machine/sensorboard.cpp
@@ -84,7 +84,7 @@ sensorboard_device::sensorboard_device(const machine_config &mconfig, const char
m_nosensors = false;
m_magnets = false;
m_inductive = false;
- m_ui_enabled = 3;
+ m_ui_enabled = 7;
set_delay(attotime::never);
// set defaults for most common use case (aka chess)
@@ -789,16 +789,25 @@ static INPUT_PORTS_START( sensorboard )
PORT_BIT(0x8000, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("SS_CHECK", 1<<15, EQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_spawn, 16) PORT_NAME("Spawn Piece 16")
PORT_START("UI")
- PORT_BIT(0x0001, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1, NOTEQUALS, 0) PORT_CODE(KEYCODE_LSHIFT) PORT_CODE(KEYCODE_RSHIFT) PORT_NAME("Modifier 2 / Force Sensor") // hold while clicking to force sensor (ignore piece)
- PORT_BIT(0x0002, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1, NOTEQUALS, 0) PORT_CODE(KEYCODE_LCONTROL) PORT_CODE(KEYCODE_RCONTROL) PORT_NAME("Modifier 1 / Force Piece") // hold while clicking to force piece (ignore sensor)
+ PORT_BIT(0x0001, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<0, NOTEQUALS, 0) PORT_CODE(KEYCODE_LSHIFT) PORT_CODE(KEYCODE_RSHIFT) PORT_NAME("Modifier 2 / Force Sensor") // hold while clicking to force sensor (ignore piece)
+ PORT_BIT(0x0002, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<0, NOTEQUALS, 0) PORT_CODE(KEYCODE_LCONTROL) PORT_CODE(KEYCODE_RCONTROL) PORT_NAME("Modifier 1 / Force Piece") // hold while clicking to force piece (ignore sensor)
PORT_BIT(0x0004, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(sensorboard_device, check_sensor_busy) // check if any sensor is busy / pressed (read-only)
- PORT_BIT(0x0008, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_hand, 0) PORT_NAME("Remove Piece")
- PORT_BIT(0x0010, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 0) PORT_NAME("Undo Buffer First")
- PORT_BIT(0x0020, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 1) PORT_NAME("Undo Buffer Previous")
- PORT_BIT(0x0040, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 2) PORT_NAME("Undo Buffer Next")
- PORT_BIT(0x0080, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 3) PORT_NAME("Undo Buffer Last")
- PORT_BIT(0x0100, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_init, 0) PORT_NAME("Board Clear")
- PORT_BIT(0x0200, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_init, 1) PORT_NAME("Board Reset")
+ PORT_BIT(0x0008, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_hand, 0) PORT_NAME("Remove Piece")
+ PORT_BIT(0x0010, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 0) PORT_NAME("Undo Buffer First")
+ PORT_BIT(0x0020, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 1) PORT_NAME("Undo Buffer Previous")
+ PORT_BIT(0x0040, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 2) PORT_NAME("Undo Buffer Next")
+ PORT_BIT(0x0080, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_undo, 3) PORT_NAME("Undo Buffer Last")
+ PORT_BIT(0x0100, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_init, 0) PORT_NAME("Board Clear")
+ PORT_BIT(0x0200, IP_ACTIVE_HIGH, IPT_OTHER) PORT_CONDITION("UI_CHECK", 1<<1, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_init, 1) PORT_NAME("Board Reset")
+
+ PORT_START("CONF")
+ PORT_CONFNAME( 0x03, 0x00, "Remember Position" ) PORT_CONDITION("UI_CHECK", 1<<2, NOTEQUALS, 0)
+ PORT_CONFSETTING( 0x01, DEF_STR( No ) )
+ PORT_CONFSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_CONFSETTING( 0x00, "Auto" )
+ PORT_CONFNAME( 0x04, 0x00, "Show Pieces" ) PORT_CONDITION("UI_CHECK", 1<<2, NOTEQUALS, 0) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_refresh, 0)
+ PORT_CONFSETTING( 0x04, DEF_STR( No ) )
+ PORT_CONFSETTING( 0x00, DEF_STR( Yes ) )
PORT_START("BS_CHECK") // board size (internal use)
PORT_BIT( 0xffffffff, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(sensorboard_device, check_bs_mask)
@@ -807,16 +816,7 @@ static INPUT_PORTS_START( sensorboard )
PORT_BIT( 0xffffffff, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(sensorboard_device, check_ss_mask)
PORT_START("UI_CHECK") // UI enabled (internal use)
- PORT_BIT( 0x03, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(sensorboard_device, check_ui_enabled)
-
- PORT_START("CONF")
- PORT_CONFNAME( 0x03, 0x00, "Remember Position" )
- PORT_CONFSETTING( 0x01, DEF_STR( No ) )
- PORT_CONFSETTING( 0x02, DEF_STR( Yes ) )
- PORT_CONFSETTING( 0x00, "Auto" )
- PORT_CONFNAME( 0x04, 0x00, "Show Pieces" ) PORT_CHANGED_MEMBER(DEVICE_SELF, sensorboard_device, ui_refresh, 0)
- PORT_CONFSETTING( 0x04, DEF_STR( No ) )
- PORT_CONFSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_BIT( 0xffffffff, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(sensorboard_device, check_ui_enabled)
INPUT_PORTS_END
ioport_constructor sensorboard_device::device_input_ports() const
diff --git a/src/devices/machine/sensorboard.h b/src/devices/machine/sensorboard.h
index a0e663f4744..50b428c04b4 100644
--- a/src/devices/machine/sensorboard.h
+++ b/src/devices/machine/sensorboard.h
@@ -31,8 +31,8 @@ public:
sensorboard_device &set_max_id(u8 i) { m_maxid = i; return *this; } // maximum piece id (if larger than set_spawnpoints)
sensorboard_device &set_delay(attotime delay) { m_sensordelay = delay; return *this; } // delay when activating a sensor (like PORT_IMPULSE), set to attotime::never to disable
sensorboard_device &set_nvram_enable(bool b) { m_nvram_auto = b; return *this; } // load last board position on start
- sensorboard_device &set_ui_enable(bool b) { if (!b) m_maxspawn = 0; m_ui_enabled = (b) ? 3 : 0; return *this; } // enable UI inputs
- sensorboard_device &set_mod_enable(bool b) { if (b) m_ui_enabled |= 1; else m_ui_enabled &= 2; return *this; } // enable modifier keys
+ sensorboard_device &set_ui_enable(bool b) { if (!b) m_maxspawn = 0; m_ui_enabled = (b) ? 7 : 0; return *this; } // enable UI inputs
+ sensorboard_device &set_mod_enable(bool b) { if (b) m_ui_enabled |= 1; else m_ui_enabled &= ~1; return *this; } // enable modifier keys
auto init_cb() { return m_custom_init_cb.bind(); } // for setting pieces starting position
auto sensor_cb() { return m_custom_sensor_cb.bind(); } // x = offset & 0xf, y = offset >> 4 & 0xf
diff --git a/src/devices/sound/k054539.cpp b/src/devices/sound/k054539.cpp
index 6178afa7af7..5fbeaa14b3d 100644
--- a/src/devices/sound/k054539.cpp
+++ b/src/devices/sound/k054539.cpp
@@ -483,9 +483,12 @@ u8 k054539_device::read(offs_t offset)
case 0x22d:
if(regs[0x22f] & 0x10) {
uint8_t res = (rom_addr == 0x80) ? ram[cur_ptr] : read_byte((0x20000*rom_addr)+cur_ptr);
- cur_ptr++;
- if(cur_ptr == cur_limit)
- cur_ptr = 0;
+ if (!machine().side_effects_disabled())
+ {
+ cur_ptr++;
+ if(cur_ptr == cur_limit)
+ cur_ptr = 0;
+ }
return res;
} else
return 0;
diff --git a/src/devices/sound/k054539.h b/src/devices/sound/k054539.h
index b2732b8cad3..ba1c96ffc64 100644
--- a/src/devices/sound/k054539.h
+++ b/src/devices/sound/k054539.h
@@ -20,6 +20,8 @@ class k054539_device : public device_t,
public device_rom_interface<24>
{
public:
+ static constexpr feature_type imperfect_features() { return feature::SOUND; } // effector and/or some registers aren't verified/emulated
+
// control flags, may be set at DRIVER_INIT().
enum {
RESET_FLAGS = 0,
diff --git a/src/devices/video/ef9340_1.cpp b/src/devices/video/ef9340_1.cpp
index 763a45eff48..a60224d3975 100644
--- a/src/devices/video/ef9340_1.cpp
+++ b/src/devices/video/ef9340_1.cpp
@@ -2,8 +2,6 @@
// copyright-holders:Wilbert Pol
/***************************************************************************
- ef9340_1.h
-
Thomson EF9340 + EF9341 teletext graphics chips with 1KB external
character ram.
diff --git a/src/devices/video/ef9340_1.h b/src/devices/video/ef9340_1.h
index 4d687d227d6..52f0278a36f 100644
--- a/src/devices/video/ef9340_1.h
+++ b/src/devices/video/ef9340_1.h
@@ -2,8 +2,6 @@
// copyright-holders:Wilbert Pol
/***************************************************************************
- ef9340_1.h
-
Thomson EF9340 + EF9341 teletext graphics chips with 1KB external
character ram.
diff --git a/src/devices/video/hlcd0438.cpp b/src/devices/video/hlcd0438.cpp
index e349654e592..42317ddb087 100644
--- a/src/devices/video/hlcd0438.cpp
+++ b/src/devices/video/hlcd0438.cpp
@@ -5,8 +5,7 @@
Hughes HLCD 0438 LCD Driver
32 segment outputs, may also be used as a column driver
-TODO:
-- OSC (LCD phi pin)
+LCD pin can be driven manually, or oscillating.
*/
@@ -32,15 +31,23 @@ hlcd0438_device::hlcd0438_device(const machine_config &mconfig, const char *tag,
void hlcd0438_device::device_start()
{
+ // resolve callbacks
m_write_segs.resolve_safe();
m_write_data.resolve_safe();
+ // timer (when LCD pin is oscillator)
+ m_lcd_timer = timer_alloc();
+ attotime period = (clock() != 0) ? attotime::from_hz(2 * clock()) : attotime::never;
+ m_lcd_timer->adjust(period, 0, period);
+
// register for savestates
save_item(NAME(m_data_in));
save_item(NAME(m_data_out));
save_item(NAME(m_clk));
save_item(NAME(m_load));
+ save_item(NAME(m_lcd));
save_item(NAME(m_shift));
+ save_item(NAME(m_latch));
}
@@ -48,13 +55,6 @@ void hlcd0438_device::device_start()
// handlers
//-------------------------------------------------
-void hlcd0438_device::update_output()
-{
- // load output latches while LOAD pin is high
- if (m_load)
- m_write_segs(0, m_shift);
-}
-
void hlcd0438_device::clock_w(int state)
{
state = state ? 1 : 0;
@@ -67,10 +67,29 @@ void hlcd0438_device::clock_w(int state)
m_shift = m_shift << 1 | m_data_in;
- // output
m_write_data(m_data_out);
- update_output();
+ load_w(m_load);
}
m_clk = state;
}
+
+void hlcd0438_device::load_w(int state)
+{
+ m_load = state ? 1 : 0;
+
+ // load to output latches while LOAD pin is high
+ if (m_load)
+ m_latch = m_shift;
+}
+
+void hlcd0438_device::lcd_w(int state)
+{
+ state = state ? 1 : 0;
+
+ // LCD pin drives backplate
+ if (state != m_lcd)
+ m_write_segs(m_lcd, m_latch);
+
+ m_lcd = state;
+}
diff --git a/src/devices/video/hlcd0438.h b/src/devices/video/hlcd0438.h
index a8a1b68d465..2b1ec257d1c 100644
--- a/src/devices/video/hlcd0438.h
+++ b/src/devices/video/hlcd0438.h
@@ -24,7 +24,7 @@
SEG 28 7 | | 34 DATA IN
SEG 27 8 | | 33 SEG 4
SEG 26 9 | | 32 SEG 5
- SEG 25 10 | HLCD 0438 | 31 LCD phi
+ SEG 25 10 | HLCD 0438 | 31 LCD
SEG 24 11 | | 30 BP
SEG 23 12 | | 29 SEG 6
SEG 22 13 | | 28 SEG 7
@@ -45,29 +45,33 @@ public:
hlcd0438_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
// configuration helpers
- auto write_segs() { return m_write_segs.bind(); } // SEG pins
+ auto write_segs() { return m_write_segs.bind(); } // BP pin in offset, SEG pins in data
auto write_data() { return m_write_data.bind(); } // DATA OUT pin
hlcd0438_device &set_load(int state) { m_load = state ? 1 : 0; return *this; } // if hardwired, can just set LOAD pin state here
void data_w(int state) { m_data_in = state ? 1 : 0; }
int data_r() { return m_data_out; }
- void load_w(int state) { m_load = state ? 1 : 0; update_output(); }
void clock_w(int state);
+ void load_w(int state);
+ void lcd_w(int state);
protected:
// device-level overrides
virtual void device_start() override;
+ virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override { lcd_w(!m_lcd); }
private:
+ emu_timer *m_lcd_timer;
+
// pin state
int m_data_in = 0;
int m_data_out = 0;
int m_clk = 0;
int m_load = 0;
+ int m_lcd = 0;
u32 m_shift = 0;
-
- void update_output();
+ u32 m_latch = 0;
devcb_write32 m_write_segs;
devcb_write_line m_write_data;
diff --git a/src/devices/video/i8244.cpp b/src/devices/video/i8244.cpp
index cc19dd2081e..141b2e85198 100644
--- a/src/devices/video/i8244.cpp
+++ b/src/devices/video/i8244.cpp
@@ -2,10 +2,12 @@
// copyright-holders:Wilbert Pol
/***************************************************************************
- i8244.c
-
- Intel 8244 (NTSC)/8245 (PAL) Graphics and sound chip
+Intel 8244 (NTSC)/8245 (PAL) Graphics and sound chip
+TODO:
+- NTSC has 263 scanlines, PAL has 313 scanlines, a quick fix will probably
+ cause small regressions here and there
+- PAL has 228 clocks per line (so, 456 half clocks)
***************************************************************************/
@@ -21,76 +23,6 @@ DEFINE_DEVICE_TYPE(I8244, i8244_device, "i8244", "Intel 8244")
DEFINE_DEVICE_TYPE(I8245, i8245_device, "i8245", "Intel 8245")
-// Kevtris verified that the data below matches a dump
-// taken from a real chip.
-static const uint8_t c_shape[0x40 * 8] =
-{
- 0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00, // 0
- 0x18,0x38,0x18,0x18,0x18,0x18,0x3C,0x00,
- 0x3C,0x66,0x0C,0x18,0x30,0x60,0x7E,0x00,
- 0x7C,0xC6,0x06,0x3C,0x06,0xC6,0x7C,0x00,
- 0xCC,0xCC,0xCC,0xFE,0x0C,0x0C,0x0C,0x00,
- 0xFE,0xC0,0xC0,0x7C,0x06,0xC6,0x7C,0x00,
- 0x7C,0xC6,0xC0,0xFC,0xC6,0xC6,0x7C,0x00,
- 0xFE,0x06,0x0C,0x18,0x30,0x60,0xC0,0x00,
- 0x7C,0xC6,0xC6,0x7C,0xC6,0xC6,0x7C,0x00,
- 0x7C,0xC6,0xC6,0x7E,0x06,0xC6,0x7C,0x00,
- 0x00,0x18,0x18,0x00,0x18,0x18,0x00,0x00,
- 0x18,0x7E,0x58,0x7E,0x1A,0x7E,0x18,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x3C,0x66,0x0C,0x18,0x18,0x00,0x18,0x00,
- 0xC0,0xC0,0xC0,0xC0,0xC0,0xC0,0xFE,0x00,
- 0xFC,0xC6,0xC6,0xFC,0xC0,0xC0,0xC0,0x00,
- 0x00,0x18,0x18,0x7E,0x18,0x18,0x00,0x00,
- 0xC6,0xC6,0xC6,0xD6,0xFE,0xEE,0xC6,0x00,
- 0xFE,0xC0,0xC0,0xF8,0xC0,0xC0,0xFE,0x00,
- 0xFC,0xC6,0xC6,0xFC,0xD8,0xCC,0xC6,0x00,
- 0x7E,0x18,0x18,0x18,0x18,0x18,0x18,0x00,
- 0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,
- 0x3C,0x18,0x18,0x18,0x18,0x18,0x3C,0x00,
- 0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00,
- 0x7C,0xC6,0xC6,0xC6,0xDE,0xCC,0x76,0x00,
- 0x7C,0xC6,0xC0,0x7C,0x06,0xC6,0x7C,0x00,
- 0xFC,0xC6,0xC6,0xC6,0xC6,0xC6,0xFC,0x00,
- 0xFE,0xC0,0xC0,0xF8,0xC0,0xC0,0xC0,0x00,
- 0x7C,0xC6,0xC0,0xC0,0xCE,0xC6,0x7E,0x00,
- 0xC6,0xC6,0xC6,0xFE,0xC6,0xC6,0xC6,0x00,
- 0x06,0x06,0x06,0x06,0x06,0xC6,0x7C,0x00,
- 0xC6,0xCC,0xD8,0xF0,0xD8,0xCC,0xC6,0x00,
- 0x38,0x6C,0xC6,0xC6,0xFE,0xC6,0xC6,0x00,
- 0x7E,0x06,0x0C,0x18,0x30,0x60,0x7E,0x00,
- 0xC6,0xC6,0x6C,0x38,0x6C,0xC6,0xC6,0x00,
- 0x7C,0xC6,0xC0,0xC0,0xC0,0xC6,0x7C,0x00,
- 0xC6,0xC6,0xC6,0xC6,0xC6,0x6C,0x38,0x00,
- 0xFC,0xC6,0xC6,0xFC,0xC6,0xC6,0xFC,0x00,
- 0xC6,0xEE,0xFE,0xD6,0xC6,0xC6,0xC6,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x18,0x18,0x00,
- 0x00,0x00,0x00,0x7E,0x00,0x00,0x00,0x00,
- 0x00,0x66,0x3C,0x18,0x3C,0x66,0x00,0x00,
- 0x00,0x18,0x00,0x7E,0x00,0x18,0x00,0x00,
- 0x00,0x00,0x7E,0x00,0x7E,0x00,0x00,0x00,
- 0x66,0x66,0x66,0x3C,0x18,0x18,0x18,0x00,
- 0xC6,0xE6,0xF6,0xFE,0xDE,0xCE,0xC6,0x00,
- 0x03,0x06,0x0C,0x18,0x30,0x60,0xC0,0x00,
- 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x00,
- 0xCE,0xDB,0xDB,0xDB,0xDB,0xDB,0xCE,0x00,
- 0x00,0x00,0x3C,0x7E,0x7E,0x7E,0x3C,0x00,
- 0x1C,0x1C,0x18,0x1E,0x18,0x18,0x1C,0x00,
- 0x1C,0x1C,0x18,0x1E,0x18,0x34,0x26,0x00,
- 0x38,0x38,0x18,0x78,0x18,0x2C,0x64,0x00,
- 0x38,0x38,0x18,0x78,0x18,0x18,0x38,0x00,
- 0x00,0x18,0x0C,0xFE,0x0C,0x18,0x00,0x00,
- 0x18,0x3C,0x7E,0xFF,0xFF,0x18,0x18,0x00,
- 0x03,0x07,0x0F,0x1F,0x3F,0x7F,0xFF,0x00,
- 0xC0,0xE0,0xF0,0xF8,0xFC,0xFE,0xFF,0x00,
- 0x38,0x38,0x12,0xFE,0xB8,0x28,0x6C,0x00,
- 0xC0,0x60,0x30,0x18,0x0C,0x06,0x03,0x00,
- 0x00,0x00,0x0C,0x08,0x08,0x7F,0x3E,0x00,
- 0x00,0x03,0x63,0xFF,0xFF,0x18,0x08,0x00,
- 0x00,0x00,0x00,0x10,0x38,0xFF,0x7E,0x00
-};
-
-
// Background and grid information is stored in RGB format
// while the character and sprite colors are stored in BGR
// format.
@@ -116,6 +48,7 @@ i8244_device::i8244_device(const machine_config &mconfig, device_type type, cons
, device_video_interface(mconfig, *this)
, m_irq_func(*this)
, m_postprocess_func(*this)
+ , m_charset(*this, "cgrom")
, m_start_vpos(START_Y)
, m_start_vblank(START_Y + SCREEN_HEIGHT)
, m_screen_lines(lines)
@@ -130,6 +63,22 @@ i8245_device::i8245_device(const machine_config &mconfig, const char *tag, devic
//-------------------------------------------------
+// internal character set rom
+//-------------------------------------------------
+
+ROM_START( i8244 )
+ ROM_REGION( 0x200, "cgrom", 0 )
+ ROM_LOAD( "charset_i8244.bin", 0x0000, 0x0200, CRC(b46a3f31) SHA1(415382715455b47b69401b3d60bd8f0036dd7fef) )
+ROM_END
+
+
+const tiny_rom_entry *i8244_device::device_rom_region() const
+{
+ return ROM_NAME( i8244 );
+}
+
+
+//-------------------------------------------------
// device_config_complete - perform any
// operations now that the configuration is
// complete
@@ -141,7 +90,7 @@ void i8244_device::device_config_complete()
return;
if (!screen().refresh_attoseconds())
- screen().set_raw(clock(), LINE_CLOCKS, START_ACTIVE_SCAN, END_ACTIVE_SCAN, m_screen_lines, START_Y, START_Y + SCREEN_HEIGHT);
+ screen().set_raw(clock()*2, LINE_CLOCKS, START_ACTIVE_SCAN, END_ACTIVE_SCAN, m_screen_lines, START_Y, START_Y + SCREEN_HEIGHT);
}
@@ -164,7 +113,7 @@ void i8244_device::device_start()
m_postprocess_func.resolve_safe();
// allocate a stream
- m_stream = stream_alloc( 0, 1, clock()/(LINE_CLOCKS*4) );
+ m_stream = stream_alloc( 0, 1, (clock()*2)/(LINE_CLOCKS*4) );
// register our state
save_pointer(NAME(m_vdc.reg), 0x100);
@@ -276,19 +225,51 @@ int i8244_device::get_x_beam()
offs_t i8244_device::fix_register_mirrors( offs_t offset )
{
- // registers $40,$41 are mirrored at $44,$45, $48,$49, and $4C,$4D
- if ( ( offset & 0xF2 ) == 0x40 )
+ // quad x/y registers are mirrored for each quad
+ if ( ( offset & 0xC2 ) == 0x40 )
{
offset &= ~0x0C;
}
// registers $A0-$AF are mirrored at $B0-$BF
- if ( ( offset & 0xF0 ) == 0xB0 )
+ if ( ( offset & 0xE0 ) == 0xA0 )
{
offset &= ~0x10;
}
- return offset;
+ return offset & 0xFF;
+}
+
+bool i8244_device::unused_register( offs_t offset )
+{
+ bool unused = false;
+
+ u8 low = offset & 0xf;
+
+ // these registers are inaccessible
+ switch (offset & 0xf0)
+ {
+ case 0x00:
+ unused = ((low & 0x3) == 0x3);
+ break;
+ case 0xa0:
+ unused = (low == 0x6 || low >= 0xb);
+ break;
+ case 0xc0: case 0xd0:
+ unused = (low >= 0x9);
+ break;
+ case 0xe0:
+ unused = (low >= 0xa);
+ break;
+ case 0xf0:
+ unused = true;
+ break;
+
+ default:
+ break;
+ }
+
+ return unused;
}
@@ -296,7 +277,10 @@ uint8_t i8244_device::read(offs_t offset)
{
uint8_t data;
- offset = fix_register_mirrors( offset );
+ offset = fix_register_mirrors(offset);
+
+ if (unused_register(offset))
+ return 0;
switch (offset)
{
@@ -324,7 +308,6 @@ uint8_t i8244_device::read(offs_t offset)
data = m_y_beam_pos;
break;
-
case 0xa5:
if ((m_vdc.s.control & VDC_CONTROL_REG_STROBE_XY))
{
@@ -333,6 +316,12 @@ uint8_t i8244_device::read(offs_t offset)
data = m_x_beam_pos;
break;
+ case 0x02: case 0x06: case 0x0a: case 0x0e:
+ case 0xa3: case 0xa7: case 0xa8: case 0xa9:
+ // write-only registers
+ data = 0;
+ break;
+
default:
data = m_vdc.reg[offset];
break;
@@ -344,11 +333,32 @@ uint8_t i8244_device::read(offs_t offset)
void i8244_device::write(offs_t offset, uint8_t data)
{
- offset = fix_register_mirrors( offset );
+ offset = fix_register_mirrors(offset);
+
+ if (unused_register(offset))
+ return;
+
+ // read-only registers
+ if (offset == 0xa1 || offset == 0xa4 || offset == 0xa5)
+ return;
+
+ // Color registers d4-d7 are not connected
+ if ((offset & 0x83) == 0x03)
+ data &= 0x0f;
+
+ // Major systems Y CAM d0 is not connected!
+ if (offset >= 0x10 && (offset & 0x83) == 0x00)
+ data &= ~0x01;
+
+ // Horizontal grid high byte only d0 is connected
+ if ((offset & 0xf0) == 0xd0)
+ data &= 0x01;
- /* Update the sound */
- if( offset >= 0xa7 && offset <= 0xaa )
+ // Update the sound
+ if (offset >= 0xa7 && offset <= 0xaa)
{
+ if (offset == 0xaa)
+ data &= 0xbf;
m_stream->update();
}
@@ -357,7 +367,7 @@ void i8244_device::write(offs_t offset, uint8_t data)
if ( ( m_vdc.s.control & VDC_CONTROL_REG_STROBE_XY )
&& !(data & VDC_CONTROL_REG_STROBE_XY))
{
- /* Toggling strobe bit, tuck away values */
+ // Toggling strobe bit, tuck away values
m_x_beam_pos = get_x_beam();
m_y_beam_pos = get_y_beam();
}
@@ -416,27 +426,26 @@ void i8244_device::render_scanline(int vpos)
//static const uint8_t COLLISION_EXTERNAL_UNUSED = 0x40;
static const uint8_t COLLISION_CHARACTERS = 0x80;
- uint8_t collision_map[160];
-
if ( vpos == m_start_vpos )
{
m_control_status &= ~0x08;
}
+ /* Clear collision map */
+ uint8_t collision_map[160];
+ memset( collision_map, 0, sizeof( collision_map ) );
+
+ /* Draw background color */
+ rectangle rect(START_ACTIVE_SCAN, END_ACTIVE_SCAN - 1, vpos, vpos);
+ rect &= screen().visible_area();
+ m_tmp_bitmap.fill( (m_vdc.s.color >> 3) & 0x7, rect );
+
if ( m_start_vpos < vpos && vpos < m_start_vblank )
{
- rectangle rect;
int scanline = vpos - m_start_vpos;
m_control_status &= ~ 0x01;
- /* Draw a line */
- rect.set(START_ACTIVE_SCAN, END_ACTIVE_SCAN - 1, vpos, vpos);
- m_tmp_bitmap.fill( (m_vdc.s.color >> 3) & 0x7, rect );
-
- /* Clear collision map */
- memset( collision_map, 0, sizeof( collision_map ) );
-
/* Display grid if enabled */
if ( m_vdc.s.control & 0x08 )
{
@@ -447,7 +456,7 @@ void i8244_device::render_scanline(int vpos)
int height = 24;
int w = ( m_vdc.s.control & 0x80 ) ? width : 2;
- /* Draw horizontal part of grid */
+ /* Draw horizontal part of the grid */
for ( int j = 1, y = 0; y < 9; y++, j <<= 1 )
{
if ( y_grid_offset + y * height <= scanline && scanline < y_grid_offset + y * height + 3 )
@@ -472,7 +481,7 @@ void i8244_device::render_scanline(int vpos)
}
}
- /* Draw vertical part of grid */
+ /* Draw vertical part of the grid */
for( int j = 1, y = 0; y < 8; y++, j <<= 1 )
{
if ( y_grid_offset + y * height <= scanline && scanline < y_grid_offset + ( y + 1 ) * height )
@@ -487,16 +496,6 @@ void i8244_device::render_scanline(int vpos)
if ( px < 160 )
{
- /* Check if we collide with an already drawn source object */
- if ( collision_map[ px ] & m_vdc.s.collision )
- {
- m_collision_status |= COLLISION_VERTICAL_GRID;
- }
- /* Check if an already drawn object would collide with us */
- if ( COLLISION_VERTICAL_GRID & m_vdc.s.collision && collision_map[ px ] )
- {
- m_collision_status |= collision_map[ px ];
- }
collision_map[ px ] |= COLLISION_VERTICAL_GRID;
m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * px ) = color;
m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * px + 1 ) = color;
@@ -506,22 +505,48 @@ void i8244_device::render_scanline(int vpos)
}
}
}
+
+ /* Draw dots part of the grid */
+ if ( m_vdc.s.control & 0x40 )
+ {
+ for ( int y = 0; y < 9; y++ )
+ {
+ if ( y_grid_offset + y * height <= scanline && scanline < y_grid_offset + y * height + 3 )
+ {
+ for ( int i = 0; i < 10; i++ )
+ {
+ for ( int k = 0; k < 2; k++ )
+ {
+ int px = x_grid_offset + i * width + k;
+
+ if ( px < 160 )
+ {
+ collision_map[ px ] |= COLLISION_HORIZ_GRID_DOTS;
+ m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * px ) = color;
+ m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * px + 1 ) = color;
+ }
+ }
+ }
+ }
+ }
+ }
}
/* Display objects if enabled */
if ( m_vdc.s.control & 0x20 )
{
/* Regular foreground objects */
- for ( int i = 0; i < ARRAY_LENGTH( m_vdc.s.foreground ); i++ )
+ for ( int i = ARRAY_LENGTH( m_vdc.s.foreground ) - 1; i >= 0; i-- )
{
- int y = m_vdc.s.foreground[i].y & 0xFE;
+ int y = m_vdc.s.foreground[i].y;
int height = 8 - ( ( ( y >> 1 ) + m_vdc.s.foreground[i].ptr ) & 7 );
+ if (height == 1) height = 8;
- if ( y >= 0x0E && y <= scanline && scanline < y + height * 2 )
+ if ( y <= scanline && scanline < y + height * 2 )
{
uint16_t color = 8 + bgr2rgb[ ( ( m_vdc.s.foreground[i].color >> 1 ) & 0x07 ) ];
int offset = ( m_vdc.s.foreground[i].ptr | ( ( m_vdc.s.foreground[i].color & 0x01 ) << 8 ) ) + ( y >> 1 ) + ( ( scanline - y ) >> 1 );
- uint8_t chr = c_shape[ offset & 0x1FF ];
+ uint8_t chr = m_charset[ offset & 0x1FF ];
int x = m_vdc.s.foreground[i].x;
for ( uint8_t m = 0x80; m > 0; m >>= 1, x++ )
@@ -550,59 +575,52 @@ void i8244_device::render_scanline(int vpos)
}
/* Quad objects */
- for ( int i = 0; i < ARRAY_LENGTH( m_vdc.s.quad ); i++ )
+ for ( int i = ARRAY_LENGTH( m_vdc.s.quad ) - 1; i >= 0; i-- )
{
int y = m_vdc.s.quad[i].single[0].y;
- int height = 8;
+
+ // Character height is always determined by the height of the 4th character
+ int height = 8 - ( ( ( y >> 1 ) + m_vdc.s.quad[i].single[3].ptr ) & 7 );
+ if (height == 1) height = 8;
if ( y <= scanline && scanline < y + height * 2 )
{
int x = m_vdc.s.quad[i].single[0].x;
- // Charaecter height is always determined by the height of the 4th character
- int char_height = 8 - ( ( ( y >> 1 ) + m_vdc.s.quad[i].single[3].ptr ) & 7 );
-
for ( int j = 0; j < ARRAY_LENGTH( m_vdc.s.quad[0].single ); j++, x += 8 )
{
- if ( y <= scanline && scanline < y + char_height * 2 )
- {
- uint16_t color = 8 + bgr2rgb[ ( ( m_vdc.s.quad[i].single[j].color >> 1 ) & 0x07 ) ];
- int offset = ( m_vdc.s.quad[i].single[j].ptr | ( ( m_vdc.s.quad[i].single[j].color & 0x01 ) << 8 ) ) + ( y >> 1 ) + ( ( scanline - y ) >> 1 );
- uint8_t chr = c_shape[ offset & 0x1FF ];
+ uint16_t color = 8 + bgr2rgb[ ( ( m_vdc.s.quad[i].single[j].color >> 1 ) & 0x07 ) ];
+ int offset = ( m_vdc.s.quad[i].single[j].ptr | ( ( m_vdc.s.quad[i].single[j].color & 0x01 ) << 8 ) ) + ( y >> 1 ) + ( ( scanline - y ) >> 1 );
+ uint8_t chr = m_charset[ offset & 0x1FF ];
- for ( uint8_t m = 0x80; m > 0; m >>= 1, x++ )
+ for ( uint8_t m = 0x80; m > 0; m >>= 1, x++ )
+ {
+ if ( chr & m )
{
- if ( chr & m )
+ if ( x >= 0 && x < 160 )
{
- if ( x >= 0 && x < 160 )
+ /* Check if we collide with an already drawn source object */
+ if ( collision_map[ x ] & m_vdc.s.collision )
{
- /* Check if we collide with an already drawn source object */
- if ( collision_map[ x ] & m_vdc.s.collision )
- {
- m_collision_status |= COLLISION_CHARACTERS;
- }
- /* Check if an already drawn object would collide with us */
- if ( COLLISION_CHARACTERS & m_vdc.s.collision && collision_map[ x ] )
- {
- m_collision_status |= collision_map[ x ];
- }
- collision_map[ x ] |= COLLISION_CHARACTERS;
- m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * x ) = color;
- m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * x + 1 ) = color;
+ m_collision_status |= COLLISION_CHARACTERS;
}
+ /* Check if an already drawn object would collide with us */
+ if ( COLLISION_CHARACTERS & m_vdc.s.collision && collision_map[ x ] )
+ {
+ m_collision_status |= collision_map[ x ];
+ }
+ collision_map[ x ] |= COLLISION_CHARACTERS;
+ m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * x ) = color;
+ m_tmp_bitmap.pix16( vpos, START_ACTIVE_SCAN + 10 + 2 * x + 1 ) = color;
}
}
}
- else
- {
- x += 8;
- }
}
}
}
/* Sprites */
- for ( int i = 0; i < ARRAY_LENGTH( m_vdc.s.sprites ); i++ )
+ for ( int i = ARRAY_LENGTH( m_vdc.s.sprites ) - 1; i >= 0; i-- )
{
int y = m_vdc.s.sprites[i].y;
int height = 8;
diff --git a/src/devices/video/i8244.h b/src/devices/video/i8244.h
index b9c28d070af..8db0fb511d9 100644
--- a/src/devices/video/i8244.h
+++ b/src/devices/video/i8244.h
@@ -2,8 +2,6 @@
// copyright-holders:Wilbert Pol
/***************************************************************************
- i8244.h
-
Intel 8244 (NTSC)/8245 (PAL) Graphics and sound chip
***************************************************************************/
@@ -58,32 +56,44 @@ protected:
union vdc_t {
uint8_t reg[0x100];
struct {
+ // 0x00
struct {
- uint8_t y,x,color,res;
+ uint8_t y,x,color,unused;
} sprites[4];
+
+ // 0x10
struct {
uint8_t y,x,ptr,color;
} foreground[12];
+
+ // 0x40
struct {
struct {
uint8_t y,x,ptr,color;
} single[4];
} quad[4];
+
+ // 0x80
uint8_t shape[4][8];
+
+ // 0xa0
uint8_t control;
uint8_t status;
uint8_t collision;
uint8_t color;
uint8_t y;
uint8_t x;
- uint8_t res;
+ uint8_t unused;
uint8_t shift1;
uint8_t shift2;
uint8_t shift3;
uint8_t sound;
- uint8_t res2[5+0x10];
+ uint8_t unused2[5+0x10];
+
+ // 0xc0
uint8_t hgrid[2][0x10];
uint8_t vgrid[0x10];
+ uint8_t unused3[0x10];
} s;
};
@@ -94,6 +104,7 @@ protected:
virtual void device_start() override;
virtual void device_reset() override;
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
+ virtual const tiny_rom_entry *device_rom_region() const override;
// device_sound_interface overrides
virtual void sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) override;
@@ -102,6 +113,7 @@ protected:
int get_y_beam();
int get_x_beam();
offs_t fix_register_mirrors( offs_t offset );
+ bool unused_register( offs_t offset );
// Local constants
static constexpr uint8_t VDC_CONTROL_REG_STROBE_XY = 0x02;
@@ -114,6 +126,8 @@ protected:
devcb_write_line m_irq_func;
devcb_write16 m_postprocess_func;
+ required_region_ptr<uint8_t> m_charset;
+
bitmap_ind16 m_tmp_bitmap;
emu_timer *m_line_timer;
emu_timer *m_hblank_timer;
diff --git a/src/devices/video/voodoo.cpp b/src/devices/video/voodoo.cpp
index 4b20ca8d97d..72ef43032ef 100644
--- a/src/devices/video/voodoo.cpp
+++ b/src/devices/video/voodoo.cpp
@@ -157,6 +157,7 @@ bits(7:4) and bit(24)), X, and Y:
#define DEBUG_DEPTH (0)
#define DEBUG_BACKBUF (0)
+#define DEBUG_STATS (0)
#define LOG_VBLANK_SWAP (0)
#define LOG_FIFO (0)
@@ -824,7 +825,6 @@ int voodoo_device::voodoo_update(bitmap_rgb32 &bitmap, const rectangle &cliprect
{
int changed = fbi.video_changed;
int drawbuf = fbi.frontbuf;
- int statskey;
int x, y;
/* reset the video changed flag */
@@ -924,25 +924,31 @@ int voodoo_device::voodoo_update(bitmap_rgb32 &bitmap, const rectangle &cliprect
}
/* update stats display */
- statskey = (machine().input().code_pressed(KEYCODE_BACKSLASH) != 0);
- if (statskey && statskey != stats.lastkey)
- stats.display = !stats.display;
- stats.lastkey = statskey;
-
- /* display stats */
- if (stats.display)
- popmessage(stats.buffer, 0, 0);
+ if (DEBUG_STATS)
+ {
+ int statskey = (machine().input().code_pressed(KEYCODE_BACKSLASH));
+ if (statskey && statskey != stats.lastkey)
+ stats.display = !stats.display;
+ stats.lastkey = statskey;
+
+ /* display stats */
+ if (stats.display)
+ popmessage(stats.buffer, 0, 0);
+ }
/* update render override */
- stats.render_override = machine().input().code_pressed(KEYCODE_ENTER);
- if (DEBUG_DEPTH && stats.render_override)
+ if (DEBUG_DEPTH)
{
- for (y = cliprect.min_y; y <= cliprect.max_y; y++)
+ stats.render_override = machine().input().code_pressed(KEYCODE_ENTER);
+ if (stats.render_override)
{
- uint16_t *src = (uint16_t *)(fbi.ram + fbi.auxoffs) + (y - fbi.yoffs) * fbi.rowpixels - fbi.xoffs;
- uint32_t *dst = &bitmap.pix32(y);
- for (x = cliprect.min_x; x <= cliprect.max_x; x++)
- dst[x] = ((src[x] << 8) & 0xff0000) | ((src[x] >> 0) & 0xff00) | ((src[x] >> 8) & 0xff);
+ for (y = cliprect.min_y; y <= cliprect.max_y; y++)
+ {
+ uint16_t* src = (uint16_t*)(fbi.ram + fbi.auxoffs) + (y - fbi.yoffs) * fbi.rowpixels - fbi.xoffs;
+ uint32_t* dst = &bitmap.pix32(y);
+ for (x = cliprect.min_x; x <= cliprect.max_x; x++)
+ dst[x] = ((src[x] << 8) & 0xff0000) | ((src[x] >> 0) & 0xff00) | ((src[x] >> 8) & 0xff);
+ }
}
}
return changed;
diff --git a/src/emu/addrmap.h b/src/emu/addrmap.h
index b201201c4dd..1795f9808a5 100644
--- a/src/emu/addrmap.h
+++ b/src/emu/addrmap.h
@@ -483,7 +483,6 @@ public:
void global_mask(offs_t mask);
void unmap_value_low() { m_unmapval = 0; }
void unmap_value_high() { m_unmapval = ~0; }
- void unmap_value(u8 value) { m_unmapval = value; }
// add a new entry of the given type
address_map_entry &operator()(offs_t start, offs_t end);
diff --git a/src/emu/debug/debugcmd.cpp b/src/emu/debug/debugcmd.cpp
index 309c73ecf22..c6dda192e59 100644
--- a/src/emu/debug/debugcmd.cpp
+++ b/src/emu/debug/debugcmd.cpp
@@ -272,6 +272,11 @@ debugger_commands::debugger_commands(running_machine& machine, debugger_cpu& cpu
m_console.register_command("fo", CMDFLAG_KEEP_QUOTES, AS_OPCODES, 3, MAX_COMMAND_PARAMS, std::bind(&debugger_commands::execute_find, this, _1, _2));
m_console.register_command("findo", CMDFLAG_KEEP_QUOTES, AS_OPCODES, 3, MAX_COMMAND_PARAMS, std::bind(&debugger_commands::execute_find, this, _1, _2));
+ m_console.register_command("fill", CMDFLAG_KEEP_QUOTES, AS_PROGRAM, 3, MAX_COMMAND_PARAMS, std::bind(&debugger_commands::execute_fill, this, _1, _2));
+ m_console.register_command("filld", CMDFLAG_KEEP_QUOTES, AS_DATA, 3, MAX_COMMAND_PARAMS, std::bind(&debugger_commands::execute_fill, this, _1, _2));
+ m_console.register_command("filli", CMDFLAG_KEEP_QUOTES, AS_IO, 3, MAX_COMMAND_PARAMS, std::bind(&debugger_commands::execute_fill, this, _1, _2));
+ m_console.register_command("fillo", CMDFLAG_KEEP_QUOTES, AS_OPCODES, 3, MAX_COMMAND_PARAMS, std::bind(&debugger_commands::execute_fill, this, _1, _2));
+
m_console.register_command("dasm", CMDFLAG_NONE, 0, 3, 5, std::bind(&debugger_commands::execute_dasm, this, _1, _2));
m_console.register_command("trace", CMDFLAG_NONE, 0, 1, 4, std::bind(&debugger_commands::execute_trace, this, _1, _2));
@@ -2907,6 +2912,113 @@ void debugger_commands::execute_find(int ref, const std::vector<std::string> &pa
}
+//-------------------------------------------------
+// execute_fill - execute the fill command
+//-------------------------------------------------
+
+void debugger_commands::execute_fill(int ref, const std::vector<std::string> &params)
+{
+ u64 offset, length;
+ address_space *space;
+
+ // validate parameters
+ if (!validate_number_parameter(params[0], offset))
+ return;
+ if (!validate_number_parameter(params[1], length))
+ return;
+ if (!validate_cpu_space_parameter(nullptr, ref, space))
+ return;
+
+ // further validation
+ offset = space->address_to_byte(offset & space->addrmask());
+ int cur_data_size = space->addr_shift() > 0 ? 2 : 1 << -space->addr_shift();
+ if (cur_data_size == 0)
+ cur_data_size = 1;
+
+ // parse the data parameters
+ u64 fill_data[256];
+ u8 fill_data_size[256];
+ int data_count = 0;
+ for (int i = 2; i < params.size(); i++)
+ {
+ const char *pdata = params[i].c_str();
+ size_t pdatalen = strlen(pdata) - 1;
+
+ // check for a string
+ if (pdata[0] == '"' && pdata[pdatalen] == '"')
+ {
+ for (int j = 1; j < pdatalen; j++)
+ {
+ fill_data[data_count] = pdata[j];
+ fill_data_size[data_count++] = 1;
+ }
+ }
+
+ // otherwise, validate as a number
+ else
+ {
+ // check for a 'b','w','d',or 'q' prefix
+ fill_data_size[data_count] = cur_data_size;
+ if (tolower(u8(pdata[0])) == 'b' && pdata[1] == '.') { fill_data_size[data_count] = cur_data_size = 1; pdata += 2; }
+ if (tolower(u8(pdata[0])) == 'w' && pdata[1] == '.') { fill_data_size[data_count] = cur_data_size = 2; pdata += 2; }
+ if (tolower(u8(pdata[0])) == 'd' && pdata[1] == '.') { fill_data_size[data_count] = cur_data_size = 4; pdata += 2; }
+ if (tolower(u8(pdata[0])) == 'q' && pdata[1] == '.') { fill_data_size[data_count] = cur_data_size = 8; pdata += 2; }
+
+ // validate as a number
+ if (!validate_number_parameter(pdata, fill_data[data_count++]))
+ return;
+ }
+ }
+ if (data_count == 0)
+ return;
+
+ // now fill memory
+ device_memory_interface &memory = space->device().memory();
+ auto dis = space->device().machine().disable_side_effects();
+ u64 count = space->address_to_byte(length);
+ while (count != 0)
+ {
+ // write the entire string
+ for (int j = 0; j < data_count; j++)
+ {
+ offs_t address = space->byte_to_address(offset) & space->logaddrmask();
+ if (!memory.translate(space->spacenum(), TRANSLATE_WRITE_DEBUG, address))
+ {
+ m_console.printf("Fill aborted due to page fault at %0*X\n", space->logaddrchars(), space->byte_to_address(offset) & space->logaddrmask());
+ length = 0;
+ break;
+ }
+ switch (fill_data_size[j])
+ {
+ case 1:
+ space->write_byte(address, fill_data[j]);
+ break;
+
+ case 2:
+ space->write_word_unaligned(address, fill_data[j]);
+ break;
+
+ case 4:
+ space->write_dword_unaligned(address, fill_data[j]);
+ break;
+
+ case 8:
+ space->read_qword_unaligned(address, fill_data[j]);
+ break;
+ }
+ offset += fill_data_size[j];
+ if (count <= fill_data_size[j])
+ {
+ count = 0;
+ break;
+ }
+ else
+ count -= fill_data_size[j];
+ }
+ }
+}
+
+
/*-------------------------------------------------
execute_dasm - execute the dasm command
-------------------------------------------------*/
diff --git a/src/emu/debug/debugcmd.h b/src/emu/debug/debugcmd.h
index 04f54a4d75d..dad1979da39 100644
--- a/src/emu/debug/debugcmd.h
+++ b/src/emu/debug/debugcmd.h
@@ -152,6 +152,7 @@ private:
void execute_cheatundo(int ref, const std::vector<std::string> &params);
void execute_dasm(int ref, const std::vector<std::string> &params);
void execute_find(int ref, const std::vector<std::string> &params);
+ void execute_fill(int ref, const std::vector<std::string> &params);
void execute_trace(int ref, const std::vector<std::string> &params);
void execute_traceover(int ref, const std::vector<std::string> &params);
void execute_traceflush(int ref, const std::vector<std::string> &params);
diff --git a/src/emu/debug/debughlp.cpp b/src/emu/debug/debughlp.cpp
index 014c574c586..88dcf85bda8 100644
--- a/src/emu/debug/debughlp.cpp
+++ b/src/emu/debug/debughlp.cpp
@@ -603,6 +603,23 @@ static const help_item static_help_list[] =
"followed by the string \"BEN\", followed by a word-sized 0.\n"
},
{
+ "fill",
+ "\n"
+ " fill[{d|i}] <address>,<length>[,<data>[,...]]\n"
+ "\n"
+ "The fill/filld/filli commands overwrite a block of memory with copies of the specified "
+ "sequence of data. 'fill' will fill program space memory, while 'filld' will fill data space "
+ "memory and 'filli' will fill I/O space memory. <address> indicates the address to begin "
+ "writing, and <length> indicates how much memory to fill. <data> can either be a quoted "
+ "string or a numeric value or expression. Non-string data is written by default in the "
+ "native word size of the CPU. To override the data size for non-strings, you can prefix "
+ "the value with b. to force byte-sized fill, w. for word-sized fill, d. for dword-sized, "
+ "and q. for qword-sized. Overrides are remembered, so if you want to fill with a series of "
+ "words, you need only to prefix the first value with a w. Note also that you can intermix "
+ "sizes in order to perform more complex fills. The fill operation may be truncated if a page "
+ "fault occurs or if part of the sequence or string would fall beyond <address>+<length>-1.\n"
+ },
+ {
"dump",
"\n"
" dump[{d|i}] <filename>,<address>,<length>[,<size>[,<ascii>[,<CPU>]]]\n"
diff --git a/src/emu/emuopts.cpp b/src/emu/emuopts.cpp
index 1a38e725ff5..d28d1bede37 100644
--- a/src/emu/emuopts.cpp
+++ b/src/emu/emuopts.cpp
@@ -138,6 +138,7 @@ const options_entry emu_options::s_option_entries[] =
{ OPTION_SAMPLERATE ";sr(1000-1000000)", "48000", OPTION_INTEGER, "set sound output sample rate" },
{ OPTION_SAMPLES, "1", OPTION_BOOLEAN, "enable the use of external samples if available" },
{ OPTION_VOLUME ";vol", "0", OPTION_INTEGER, "sound volume in decibels (-32 min, 0 max)" },
+ { OPTION_SPEAKER_REPORT, "0", OPTION_INTEGER, "print report of speaker ouput maxima (0=none, or 1-4 for more detail)" },
// input options
{ nullptr, nullptr, OPTION_HEADER, "CORE INPUT OPTIONS" },
diff --git a/src/emu/emuopts.h b/src/emu/emuopts.h
index 648644304b0..bb989016cf3 100644
--- a/src/emu/emuopts.h
+++ b/src/emu/emuopts.h
@@ -119,6 +119,7 @@
#define OPTION_SAMPLERATE "samplerate"
#define OPTION_SAMPLES "samples"
#define OPTION_VOLUME "volume"
+#define OPTION_SPEAKER_REPORT "speaker_report"
// core input options
#define OPTION_COIN_LOCKOUT "coin_lockout"
@@ -399,6 +400,7 @@ public:
int sample_rate() const { return int_value(OPTION_SAMPLERATE); }
bool samples() const { return bool_value(OPTION_SAMPLES); }
int volume() const { return int_value(OPTION_VOLUME); }
+ int speaker_report() const { return int_value(OPTION_SPEAKER_REPORT); }
// core input options
bool coin_lockout() const { return bool_value(OPTION_COIN_LOCKOUT); }
diff --git a/src/emu/rendlay.cpp b/src/emu/rendlay.cpp
index a7d6411a1e9..4db27e47762 100644
--- a/src/emu/rendlay.cpp
+++ b/src/emu/rendlay.cpp
@@ -2244,7 +2244,7 @@ protected:
int endpos = basey+ourheight/num_shown;
- // only render the symbol / text if it's atually in view because the code is SLOW
+ // only render the symbol / text if it's actually in view because the code is SLOW
if ((endpos >= bounds.top()) && (basey <= bounds.bottom()))
{
while (1)
@@ -2403,7 +2403,7 @@ private:
int endpos = basex+(ourwidth/num_shown);
- // only render the symbol / text if it's atually in view because the code is SLOW
+ // only render the symbol / text if it's actually in view because the code is SLOW
if ((endpos >= bounds.left()) && (basex <= bounds.right()))
{
while (1)
diff --git a/src/emu/speaker.cpp b/src/emu/speaker.cpp
index c8ae8129c74..f5f507d242b 100644
--- a/src/emu/speaker.cpp
+++ b/src/emu/speaker.cpp
@@ -9,6 +9,7 @@
***************************************************************************/
#include "emu.h"
+#include "emuopts.h"
#include "speaker.h"
@@ -36,11 +37,8 @@ speaker_device::speaker_device(const machine_config &mconfig, const char *tag, d
, m_x(0.0)
, m_y(0.0)
, m_z(0.0)
-#if SPEAKER_TRACK_MAX_SAMPLE
- , m_max_sample(0)
- , m_clipped_samples(0)
- , m_total_samples(0)
-#endif
+ , m_current_max(0)
+ , m_samples_this_bucket(0)
{
}
@@ -51,11 +49,6 @@ speaker_device::speaker_device(const machine_config &mconfig, const char *tag, d
speaker_device::~speaker_device()
{
-#if SPEAKER_TRACK_MAX_SAMPLE
- // log the maximum sample values for all speakers
- if (m_max_sample > 0)
- osd_printf_verbose("Speaker \"%s\" - max = %d (gain *= %f) - %d%% samples clipped\n", tag(), m_max_sample, 32767.0 / (m_max_sample ? m_max_sample : 1), (int)((double)m_clipped_samples * 100.0 / m_total_samples));
-#endif
}
@@ -84,24 +77,21 @@ void speaker_device::mix(s32 *leftmix, s32 *rightmix, int &samples_this_update,
}
assert(samples_this_update == numsamples);
-#if SPEAKER_TRACK_MAX_SAMPLE
- // debug version: keep track of the maximum sample
- // ignore the first 100k or so samples to avoid biasing in favor
- // of initial sound glitches
- if (m_total_samples < 100000)
- m_total_samples += samples_this_update;
- else
+ // track maximum sample value for each 0.1s bucket
+ if (machine().options().speaker_report() != 0)
+ {
+ u32 samples_per_bucket = m_mixer_stream->sample_rate() / BUCKETS_PER_SECOND;
for (int sample = 0; sample < samples_this_update; sample++)
{
- if (stream_buf[sample] > m_max_sample)
- m_max_sample = stream_buf[sample];
- else if (-stream_buf[sample] > m_max_sample)
- m_max_sample = -stream_buf[sample];
- if (stream_buf[sample] > 32767 || stream_buf[sample] < -32768)
- m_clipped_samples++;
- m_total_samples++;
+ m_current_max = std::max(m_current_max, abs(stream_buf[sample]));
+ if (++m_samples_this_bucket >= samples_per_bucket)
+ {
+ m_max_sample.push_back(m_current_max);
+ m_current_max = 0;
+ m_samples_this_bucket = 0;
+ }
}
-#endif
+ }
// mix if sound is enabled
if (!suppress)
@@ -135,3 +125,48 @@ void speaker_device::device_start()
{
// dummy save to make device.c happy
}
+
+
+//-------------------------------------------------
+// device_stop - cleanup and report
+//-------------------------------------------------
+
+void speaker_device::device_stop()
+{
+ // level 1: just report if there was any clipping
+ // level 2: report the overall maximum, even if no clipping
+ // level 3: print a detailed list of all the times there was clipping
+ // level 4: print a detailed list of every bucket
+ int report = machine().options().speaker_report();
+ if (report != 0)
+ {
+ m_max_sample.push_back(m_current_max);
+
+ // determine overall maximum and number of clipped buckets
+ s32 overallmax = 0;
+ u32 clipped = 0;
+ for (auto &curmax : m_max_sample)
+ {
+ overallmax = std::max(overallmax, curmax);
+ if (curmax > 32767)
+ clipped++;
+ }
+
+ // levels 1 and 2 just get a summary
+ if (clipped != 0 || report == 2 || report == 4)
+ osd_printf_info("Speaker \"%s\" - max = %d (gain *= %.3f) - clipped in %d/%d (%d%%) buckets\n", tag(), overallmax, 32767.0 / (overallmax ? overallmax : 1), clipped, m_max_sample.size(), clipped * 100 / m_max_sample.size());
+
+ // levels 3 and 4 get a full dump
+ if (report >= 3)
+ {
+ double t = 0;
+ for (auto &curmax : m_max_sample)
+ {
+ if (curmax > 32767 || report == 4)
+ osd_printf_info(" t=%5.1f max=%6d\n", t, curmax);
+ t += 1.0 / double(BUCKETS_PER_SECOND);
+ }
+ }
+ }
+}
+
diff --git a/src/emu/speaker.h b/src/emu/speaker.h
index 0aa3dc6b66f..26896dd7e3f 100644
--- a/src/emu/speaker.h
+++ b/src/emu/speaker.h
@@ -26,15 +26,6 @@
#pragma once
-#ifndef SPEAKER_TRACK_MAX_SAMPLE
-#ifdef MAME_DEBUG
-#define SPEAKER_TRACK_MAX_SAMPLE (1)
-#else
-#define SPEAKER_TRACK_MAX_SAMPLE (0)
-#endif
-#endif
-
-
//**************************************************************************
// GLOBAL VARIABLES
//**************************************************************************
@@ -83,6 +74,7 @@ public:
protected:
// device-level overrides
virtual void device_start() override ATTR_COLD;
+ virtual void device_stop() override ATTR_COLD;
// inline configuration state
double m_x;
@@ -90,11 +82,10 @@ protected:
double m_z;
// internal state
-#if SPEAKER_TRACK_MAX_SAMPLE
- s32 m_max_sample; // largest sample value we've seen
- s32 m_clipped_samples; // total number of clipped samples
- s32 m_total_samples; // total number of samples
-#endif
+ static constexpr int BUCKETS_PER_SECOND = 10;
+ std::vector<s32> m_max_sample;
+ s32 m_current_max;
+ u32 m_samples_this_bucket;
};
diff --git a/src/emu/xtal.cpp b/src/emu/xtal.cpp
index 7e6227f9487..543aafc3499 100644
--- a/src/emu/xtal.cpp
+++ b/src/emu/xtal.cpp
@@ -80,6 +80,7 @@ const double XTAL::known_xtals[] = {
2'000'000, /* 2_MHz_XTAL - */
2'012'160, /* 2.01216_MHz_XTAL Cidelsa Draco sound board */
2'097'152, /* 2.097152_MHz_XTAL Icatel 1995 - Brazilian public payphone */
+ 2'376'000, /* 2.376_MHz_XTAL CIT-101 keyboard */
2'457'600, /* 2.4576_MHz_XTAL Atari ST MFP */
2'500'000, /* 2.5_MHz_XTAL Janken Man units */
2'600'000, /* 2.6_MHz_XTAL Sharp PC-1500 */
@@ -89,6 +90,7 @@ const double XTAL::known_xtals[] = {
3'120'000, /* 3.12_MHz_XTAL SP0250 clock on Gottlieb games */
3'276'800, /* 3.2768_MHz_XTAL SP0256 clock in Speech Synthesis for Dragon 32 */
3'521'280, /* 3.52128_MHz_XTAL RCA COSMAC VIP */
+ 3'546'800, /* 3.5468_MHz_XTAL Atari 400 PAL, Philips G7200 */
3'570'000, /* 3.57_MHz_XTAL Telmac TMC-600 */
3'578'640, /* 3.57864_MHz_XTAL Atari Portfolio PCD3311T */
3'579'000, /* 3.579_MHz_XTAL BeebOPL */
@@ -141,6 +143,7 @@ const double XTAL::known_xtals[] = {
8'467'200, /* 8.4672_MHz_XTAL Subsino's Ying Hua Lian */
8'664'000, /* 8.664_MHz_XTAL Touchmaster */
8'700'000, /* 8.7_MHz_XTAL Tandberg TDV 2324 */
+ 8'867'000, /* 8.867_MHz_XTAL Philips G7400 (~2x PAL subcarrier) */
8'867'236, /* 8.867236_MHz_XTAL RCA CDP1869 PAL color clock (~2x PAL subcarrier) */
8'867'238, /* 8.867238_MHz_XTAL ETI-660 (~2x PAL subcarrier) */
8'945'000, /* 8.945_MHz_XTAL Hit Me */
@@ -263,6 +266,7 @@ const double XTAL::known_xtals[] = {
17'600'000, /* 17.6_MHz_XTAL LSI Octopus */
17'734'470, /* 17.73447_MHz_XTAL (~4x PAL subcarrier) */
17'734'472, /* 17.734472_MHz_XTAL actually ~4x PAL subcarrier */
+ 17'812'000, /* 17.812_MHz_XTAL Videopac C52 */
17'971'200, /* 17.9712_MHz_XTAL Compucolor II, Hazeltine Esprit III */
18'000'000, /* 18_MHz_XTAL S.A.R, Ikari Warriors 3 */
18'414'000, /* 18.414_MHz_XTAL Ann Arbor Ambassador */
@@ -296,7 +300,7 @@ const double XTAL::known_xtals[] = {
21'300'000, /* 21.3_MHz_XTAL - */
21'328'100, /* 21.3281_MHz_XTAL Philips NMS8245 */
21'477'272, /* 21.477272_MHz_XTAL BMC bowling, some Data East 90's games, Vtech Socrates; (6x NTSC subcarrier) */
- 21'667'500, /* 21.6675_MHz_XTAL AT&T 610 (80-column display clock) */
+ 21'667'500, /* 21.6675_MHz_XTAL AT&T 610 80-column display clock */
22'000'000, /* 22_MHz_XTAL - */
22'032'000, /* 22.032_MHz_XTAL Intellec Series II I/O controller */
22'096'000, /* 22.096_MHz_XTAL ADDS Viewpoint 122 */
@@ -312,6 +316,7 @@ const double XTAL::known_xtals[] = {
23'961'600, /* 23.9616_MHz_XTAL Osborne 4 (Vixen) */
24'000'000, /* 24_MHz_XTAL Mario, 80's Data East games, 80's Konami games */
24'073'400, /* 24.0734_MHz_XTAL DEC Rainbow 100 */
+ 24'270'000, /* 24.27_MHz_XTAL CIT-101XL */
24'300'000, /* 24.3_MHz_XTAL ADM 36 132-column display clock */
24'576'000, /* 24.576_MHz_XTAL Pole Position h/w, Model 3 CPU board */
24'883'200, /* 24.8832_MHz_XTAL DEC VT100 */
@@ -339,7 +344,8 @@ const double XTAL::known_xtals[] = {
27'164'000, /* 27.164_MHz_XTAL Typically used on 90's Taito PCBs to drive the custom chips */
27'210'900, /* 27.2109_MHz_XTAL LA Girl */
27'562'000, /* 27.562_MHz_XTAL Visual 220 */
- 27'720'000, /* 27.72_MHz_XTAL AT&T 610 (132-column display clock) */
+ 27'720'000, /* 27.72_MHz_XTAL AT&T 610 132-column display clock */
+ 27'956'000, /* 27.956_MHz_XTAL CIT-101e 132-column display clock */
28'000'000, /* 28_MHz_XTAL - */
28'322'000, /* 28.322_MHz_XTAL Saitek RISC 2500, Mephisto Montreux */
28'375'160, /* 28.37516_MHz_XTAL Amiga PAL systems */
diff --git a/src/lib/netlist/.gitignore b/src/lib/netlist/.gitignore
index 946de7294de..b5665c29b92 100644
--- a/src/lib/netlist/.gitignore
+++ b/src/lib/netlist/.gitignore
@@ -1,3 +1,5 @@
+build/html/*
+build/man/*
build/doxy/*
build/obj/*
buildVS/Release/*
diff --git a/src/lib/netlist/analog/nld_mosfet.cpp b/src/lib/netlist/analog/nld_mosfet.cpp
index acc7ad8359f..3e74ac617c3 100644
--- a/src/lib/netlist/analog/nld_mosfet.cpp
+++ b/src/lib/netlist/analog/nld_mosfet.cpp
@@ -279,7 +279,7 @@ namespace analog
m_vto = m_modacc.m_VTO;
// FIXME zero conversion
- if(m_vto != nlconst::zero())
+ if(m_vto == nlconst::zero())
log().warning(MW_MOSFET_THRESHOLD_VOLTAGE(m_model.name()));
// FIXME: VTO if missing may be calculated from TPG, NSS and temperature. Usually models
diff --git a/src/lib/netlist/build/doxygen.conf b/src/lib/netlist/build/doxygen.conf
index 110a41acf43..fc500b3aabb 100644
--- a/src/lib/netlist/build/doxygen.conf
+++ b/src/lib/netlist/build/doxygen.conf
@@ -844,7 +844,7 @@ EXCLUDE_SYMBOLS =
# that contain example code fragments that are included (see the \include
# command).
-EXAMPLE_PATH = ../documentation ../examples
+EXAMPLE_PATH = ../documentation ../examples ./html
# If the value of the EXAMPLE_PATH tag contains directories, you can use the
# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and
diff --git a/src/lib/netlist/build/makefile b/src/lib/netlist/build/makefile
index e46e1ac4c26..e142f7c0d7e 100644
--- a/src/lib/netlist/build/makefile
+++ b/src/lib/netlist/build/makefile
@@ -53,7 +53,7 @@ TIDY_SOURCES = $(SOURCES)
#TIDY_SOURCES = $(SRC)/devices/nld_7442.cpp $(SRC)/devices/nld_7492.cpp
-#TIDY_FLAGS = -p $(OBJ) -checks=llvm-include-order,llvm-namespace-comment,modernize-use-override,modernize-use-using -fix
+TIDY_FLAGS = -p $(OBJ) -checks=llvm-include-order,llvm-namespace-comment,modernize-use-override,modernize-use-using -fix
#TIDY_FLAGS = -checks=llvm-include-order -fix
#TIDY_FLAGS = -checks=llvm-namespace-comment -fix
#TIDY_FLAGS = -checks=modernize-use-override -fix
@@ -154,10 +154,11 @@ NLOBJS := \
$(NLOBJ)/devices/nld_tms4800.o \
$(NLOBJ)/devices/nld_4006.o \
$(NLOBJ)/devices/nld_4013.o \
+ $(NLOBJ)/devices/nld_4017.o \
$(NLOBJ)/devices/nld_4020.o \
+ $(NLOBJ)/devices/nld_4053.o \
$(NLOBJ)/devices/nld_4066.o \
$(NLOBJ)/devices/nld_4316.o \
- $(NLOBJ)/devices/nld_7442.o \
$(NLOBJ)/devices/nld_7448.o \
$(NLOBJ)/devices/nld_7450.o \
$(NLOBJ)/devices/nld_7473.o \
@@ -250,7 +251,7 @@ MAKEFILE_TARGETS_WITHOUT_INCLUDE := gcc9 clang clang-5 mingw doc native maketree
# PHONY
#-------------------------------------------------
-.PHONY: all gcc9 clang clang-5 mingw doc native maketree $(DEPEND) depend runtests
+.PHONY: all gcc9 clang clang-5 mingw doc man native maketree $(DEPEND) depend runtests
#-------------------------------------------------
# all
@@ -360,8 +361,13 @@ mingw:
# LDEXTRAFLAGS = -municode
#
+man: nltool$(EXESUFFIX) nlwav$(EXESUFFIX)
+ @mkdir -p man
+ @mkdir -p html
+ help2man --include=nltool.help2man --no-info ./nltool$(EXESUFFIX) > man/nltool.1
+ groff -mandoc -Thtml man/nltool.1 > html/nltool.html
-doc: nltool$(EXESUFFIX)
+doc: nltool$(EXESUFFIX) nlwav$(EXESUFFIX)
./nltool$(EXESUFFIX) -c docheader > ../documentation/devsyn.dox.h
$(DOXYGEN) doxygen.conf
diff --git a/src/lib/netlist/build/nltool.help2man b/src/lib/netlist/build/nltool.help2man
new file mode 100644
index 00000000000..76b0f15b8d0
--- /dev/null
+++ b/src/lib/netlist/build/nltool.help2man
@@ -0,0 +1,5 @@
+[see also]
+More documentation for the
+.B nltool
+program is available in doxygen format.
+
diff --git a/src/lib/netlist/core/analog.h b/src/lib/netlist/core/analog.h
new file mode 100644
index 00000000000..a868443b8d2
--- /dev/null
+++ b/src/lib/netlist/core/analog.h
@@ -0,0 +1,162 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+///
+/// \file param.h
+///
+
+#ifndef NL_CORE_ANALOG_H_
+#define NL_CORE_ANALOG_H_
+
+#include "../nltypes.h"
+#include "base_objects.h"
+#include "nets.h"
+
+#include "../plib/plists.h"
+#include "../plib/pstring.h"
+
+#include <array>
+#include <utility>
+
+namespace netlist
+{
+ // -----------------------------------------------------------------------------
+ // analog_t
+ // -----------------------------------------------------------------------------
+
+ class analog_t : public detail::core_terminal_t
+ {
+ public:
+
+ analog_t(core_device_t &dev, const pstring &aname, state_e state,
+ nldelegate delegate);
+
+ const analog_net_t & net() const noexcept
+ {
+ return plib::downcast<const analog_net_t &>(core_terminal_t::net());
+ }
+
+ analog_net_t & net() noexcept
+ {
+ return plib::downcast<analog_net_t &>(core_terminal_t::net());
+ }
+
+ solver::matrix_solver_t *solver() const noexcept;
+ };
+
+ /// \brief Base class for terminals.
+ ///
+ /// Each \ref nld_twoterm object consists of two terminals. Terminals
+ /// are at the core of analog netlists and are connected to \ref net_t
+ /// objects.
+ ///
+ class terminal_t : public analog_t
+ {
+ public:
+
+ /// \brief constructor
+ ///
+ /// @param dev core_devict_t object owning the terminal
+ /// @param aname name of this terminal
+ /// @param otherterm pointer to the sibling terminal
+ terminal_t(core_device_t &dev, const pstring &aname, terminal_t *otherterm, nldelegate delegate);
+
+ /// \brief Returns voltage of connected net
+ ///
+ /// @return voltage of net this terminal is connected to
+ nl_fptype operator ()() const noexcept
+ {
+ return net().Q_Analog();
+ }
+
+ /// @brief sets conductivity value of this terminal
+ ///
+ /// @param G Conductivity
+ void set_conductivity(nl_fptype G) const noexcept
+ {
+ set_go_gt_I(-G, G, nlconst::zero());
+ }
+
+ void set_go_gt(nl_fptype GO, nl_fptype GT) const noexcept
+ {
+ set_go_gt_I(GO, GT, nlconst::zero());
+ }
+
+ void set_go_gt_I(nl_fptype GO, nl_fptype GT, nl_fptype I) const noexcept
+ {
+ // Check for rail nets ...
+ if (m_go != nullptr)
+ {
+ *m_Idr = I;
+ *m_go = GO;
+ *m_gt = GT;
+ }
+ }
+
+ void set_ptrs(nl_fptype *gt, nl_fptype *go, nl_fptype *Idr) noexcept(false);
+
+ private:
+ nl_fptype *m_Idr; ///< drive current
+ nl_fptype *m_go; ///< conductance for Voltage from other term
+ nl_fptype *m_gt; ///< conductance for total conductance
+
+ };
+
+ // -----------------------------------------------------------------------------
+ // analog_input_t
+ // -----------------------------------------------------------------------------
+
+ /// \brief terminal providing analog input voltage.
+ ///
+ /// This terminal class provides a voltage measurement. The conductance against
+ /// ground is infinite.
+
+ class analog_input_t : public analog_t
+ {
+ public:
+ /// \brief Constructor
+ analog_input_t(core_device_t &dev, ///< owning device
+ const pstring &aname, ///< name of terminal
+ nldelegate delegate ///< delegate
+ );
+
+ /// \brief returns voltage at terminal.
+ /// \returns voltage at terminal.
+ nl_fptype operator()() const noexcept { return Q_Analog(); }
+
+ /// \brief returns voltage at terminal.
+ /// \returns voltage at terminal.
+ nl_fptype Q_Analog() const noexcept
+ {
+ return net().Q_Analog();
+ }
+ };
+
+ // -----------------------------------------------------------------------------
+ // analog_output_t
+ // -----------------------------------------------------------------------------
+
+ class analog_output_t : public analog_t
+ {
+ public:
+ analog_output_t(core_device_t &dev, const pstring &aname);
+
+ void push(nl_fptype val) noexcept
+ {
+ if (val != m_my_net.Q_Analog())
+ {
+ m_my_net.set_Q_Analog(val);
+ m_my_net.toggle_and_push_to_queue(netlist_time::quantum());
+ }
+ }
+
+ void initial(nl_fptype val) noexcept;
+
+ private:
+ analog_net_t m_my_net;
+ };
+
+} // namespace netlist
+
+
+#endif // NL_CORE_ANALOG_H_
diff --git a/src/lib/netlist/core/base_objects.h b/src/lib/netlist/core/base_objects.h
index c697617e265..656898b21d0 100644
--- a/src/lib/netlist/core/base_objects.h
+++ b/src/lib/netlist/core/base_objects.h
@@ -8,48 +8,22 @@
#ifndef NL_CORE_BASE_OBJECTS_H_
#define NL_CORE_BASE_OBJECTS_H_
+#include "netlist_state.h"
#include "state_var.h"
#include "../nltypes.h"
#include "../plib/palloc.h"
-#include "../plib/pmempool.h"
#include "../plib/pchrono.h"
#include "../plib/pexception.h"
#include "../plib/plists.h"
+#include "../plib/pmempool.h"
#include <unordered_map>
namespace netlist
{
- //============================================================
- // Exceptions
- //============================================================
-
- /// \brief Generic netlist exception.
- /// The exception is used in all events which are considered fatal.
-
- class nl_exception : public plib::pexception
- {
- public:
- /// \brief Constructor.
- /// Allows a descriptive text to be passed to the exception
-
- explicit nl_exception(const pstring &text //!< text to be passed
- )
- : plib::pexception(text) { }
-
- /// \brief Constructor.
- /// Allows to use \ref plib::pfmt logic to be used in exception
-
- template<typename... Args>
- explicit nl_exception(const pstring &fmt //!< format to be used
- , Args&&... args //!< arguments to be passed
- )
- : plib::pexception(plib::pfmt(fmt)(std::forward<Args>(args)...)) { }
- };
-
namespace detail {
template <typename C, typename T>
@@ -142,6 +116,7 @@ namespace netlist
/// The object provides adds \ref netlist_state_t and \ref netlist_t
/// accessors.
///
+
class netlist_object_t : public object_t
{
public:
@@ -162,7 +137,10 @@ namespace netlist
// to ease template design
template<typename T, typename... Args>
- device_arena::unique_ptr<T> make_pool_object(Args&&... args);
+ device_arena::unique_ptr<T> make_pool_object(Args&&... args)
+ {
+ return state().make_pool_object<T>(std::forward<Args>(args)...);
+ }
private:
netlist_t & m_netlist;
@@ -305,83 +283,6 @@ namespace netlist
} // namespace detail
- // -----------------------------------------------------------------------------
- // core_device_t
- // -----------------------------------------------------------------------------
- // FIXME: belongs into detail namespace
- class core_device_t : public detail::netlist_object_t
- {
- public:
- core_device_t(netlist_state_t &owner, const pstring &name);
- core_device_t(core_device_t &owner, const pstring &name);
-
- PCOPYASSIGNMOVE(core_device_t, delete)
-
- virtual ~core_device_t() noexcept = default;
-
- void do_inc_active() noexcept
- {
- if (m_hint_deactivate)
- {
- if (++m_active_outputs == 1)
- {
- if (m_stats)
- m_stats->m_stat_inc_active.inc();
- inc_active();
- }
- }
- }
-
- void do_dec_active() noexcept
- {
- if (m_hint_deactivate)
- if (--m_active_outputs == 0)
- {
- dec_active();
- }
- }
-
- void set_hint_deactivate(bool v) noexcept { m_hint_deactivate = v; }
- bool get_hint_deactivate() const noexcept { return m_hint_deactivate; }
- // Has to be set in device reset
- void set_active_outputs(int n) noexcept { m_active_outputs = n; }
-
- // stats
- struct stats_t
- {
- // NL_KEEP_STATISTICS
- plib::pperftime_t<true> m_stat_total_time;
- plib::pperfcount_t<true> m_stat_call_count;
- plib::pperfcount_t<true> m_stat_inc_active;
- };
-
- stats_t * stats() const noexcept { return m_stats.get(); }
-#if 0
- virtual void update() noexcept { }
-#endif
- virtual void reset() { }
-
- protected:
-
- virtual void inc_active() noexcept { }
- virtual void dec_active() noexcept { }
-
- log_type & log();
-
- public:
- virtual void timestep(timestep_type ts_type, nl_fptype st) noexcept { plib::unused_var(ts_type, st); }
- virtual void update_terminals() noexcept { }
-
- virtual void update_param() noexcept {}
- virtual bool is_dynamic() const noexcept { return false; }
- virtual bool is_timestep() const noexcept { return false; }
-
- private:
- bool m_hint_deactivate;
- state_var_s32 m_active_outputs;
- device_arena::unique_ptr<stats_t> m_stats;
- };
-
} // namespace netlist
diff --git a/src/lib/netlist/core/device.h b/src/lib/netlist/core/device.h
new file mode 100644
index 00000000000..99a5a1884ec
--- /dev/null
+++ b/src/lib/netlist/core/device.h
@@ -0,0 +1,163 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+///
+/// \file device.h
+///
+
+#ifndef NL_CORE_DEVICE_H_
+#define NL_CORE_DEVICE_H_
+
+#include "../nltypes.h"
+#include "../plib/pstring.h"
+#include "base_objects.h"
+#include "logic_family.h"
+#include "param.h"
+
+namespace netlist
+{
+ // -----------------------------------------------------------------------------
+ // core_device_t
+ // -----------------------------------------------------------------------------
+ // FIXME: belongs into detail namespace
+ class core_device_t : public detail::netlist_object_t
+ {
+ public:
+ core_device_t(netlist_state_t &owner, const pstring &name);
+ core_device_t(core_device_t &owner, const pstring &name);
+
+ PCOPYASSIGNMOVE(core_device_t, delete)
+
+ virtual ~core_device_t() noexcept = default;
+
+ void do_inc_active() noexcept
+ {
+ if (m_hint_deactivate)
+ {
+ if (++m_active_outputs == 1)
+ {
+ if (m_stats)
+ m_stats->m_stat_inc_active.inc();
+ inc_active();
+ }
+ }
+ }
+
+ void do_dec_active() noexcept
+ {
+ if (m_hint_deactivate)
+ if (--m_active_outputs == 0)
+ {
+ dec_active();
+ }
+ }
+
+ void set_hint_deactivate(bool v) noexcept { m_hint_deactivate = v; }
+ bool get_hint_deactivate() const noexcept { return m_hint_deactivate; }
+ // Has to be set in device reset
+ void set_active_outputs(int n) noexcept { m_active_outputs = n; }
+
+ // stats
+ struct stats_t
+ {
+ // NL_KEEP_STATISTICS
+ plib::pperftime_t<true> m_stat_total_time;
+ plib::pperfcount_t<true> m_stat_call_count;
+ plib::pperfcount_t<true> m_stat_inc_active;
+ };
+
+ stats_t * stats() const noexcept { return m_stats.get(); }
+#if 0
+ virtual void update() noexcept { }
+#endif
+ virtual void reset() { }
+
+ protected:
+
+ virtual void inc_active() noexcept { }
+ virtual void dec_active() noexcept { }
+
+ log_type & log();
+
+ public:
+ virtual void timestep(timestep_type ts_type, nl_fptype st) noexcept { plib::unused_var(ts_type, st); }
+ virtual void update_terminals() noexcept { }
+
+ virtual void update_param() noexcept {}
+ virtual bool is_dynamic() const noexcept { return false; }
+ virtual bool is_timestep() const noexcept { return false; }
+
+ private:
+ bool m_hint_deactivate;
+ state_var_s32 m_active_outputs;
+ device_arena::unique_ptr<stats_t> m_stats;
+ };
+
+ // -----------------------------------------------------------------------------
+ // base_device_t
+ // -----------------------------------------------------------------------------
+
+ class base_device_t : public core_device_t
+ {
+ public:
+ base_device_t(netlist_state_t &owner, const pstring &name);
+ base_device_t(base_device_t &owner, const pstring &name);
+
+ PCOPYASSIGNMOVE(base_device_t, delete)
+
+ ~base_device_t() noexcept override = default;
+
+ template<class O, class C, typename... Args>
+ void create_and_register_subdevice(O& owner, const pstring &name, device_arena::unique_ptr<C> &dev, Args&&... args)
+ {
+ dev = state().make_pool_object<C>(owner, name, std::forward<Args>(args)...);
+ }
+
+ void register_subalias(const pstring &name, const detail::core_terminal_t &term);
+ void register_subalias(const pstring &name, const pstring &aliased);
+
+ void connect(const pstring &t1, const pstring &t2);
+ void connect(const detail::core_terminal_t &t1, const detail::core_terminal_t &t2);
+ protected:
+
+ //NETLIB_UPDATE_TERMINALSI() { }
+
+ private:
+ };
+
+ // -----------------------------------------------------------------------------
+ // device_t
+ // -----------------------------------------------------------------------------
+
+ class device_t : public base_device_t,
+ public logic_family_t
+ {
+ public:
+ device_t(netlist_state_t &owner, const pstring &name);
+ device_t(netlist_state_t &owner, const pstring &name,
+ const pstring &model);
+ // only needed by proxies
+ device_t(netlist_state_t &owner, const pstring &name,
+ const logic_family_desc_t *desc);
+
+ device_t(device_t &owner, const pstring &name);
+ // pass in a default model - this may be overwritten by PARAM(DEVICE.MODEL, "XYZ(...)")
+ device_t(device_t &owner, const pstring &name,
+ const pstring &model);
+
+ PCOPYASSIGNMOVE(device_t, delete)
+
+ ~device_t() noexcept override = default;
+
+ protected:
+
+ //NETLIB_UPDATE_TERMINALSI() { }
+
+ private:
+ param_model_t m_model;
+ };
+
+} // namespace netlist
+
+
+#endif // NL_CORE_DEVICE_H_
diff --git a/src/lib/netlist/core/logic.h b/src/lib/netlist/core/logic.h
new file mode 100644
index 00000000000..c8ff979cc65
--- /dev/null
+++ b/src/lib/netlist/core/logic.h
@@ -0,0 +1,208 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+///
+/// \file param.h
+///
+
+#ifndef NL_CORE_LOGIC_H_
+#define NL_CORE_LOGIC_H_
+
+#include "../nltypes.h"
+#include "base_objects.h"
+#include "logic_family.h"
+#include "nets.h"
+#include "state_var.h"
+
+#include "../plib/plists.h"
+#include "../plib/pstring.h"
+
+#include <array>
+#include <utility>
+
+namespace netlist
+{
+ // -----------------------------------------------------------------------------
+ // logic_t
+ // -----------------------------------------------------------------------------
+
+ class logic_t : public detail::core_terminal_t, public logic_family_t
+ {
+ public:
+ logic_t(device_t &dev, const pstring &aname,
+ state_e terminal_state, nldelegate delegate);
+
+ logic_net_t & net() noexcept
+ {
+ return plib::downcast<logic_net_t &>(core_terminal_t::net());
+ }
+ const logic_net_t & net() const noexcept
+ {
+ return plib::downcast<const logic_net_t &>(core_terminal_t::net());
+ }
+ };
+
+ // -----------------------------------------------------------------------------
+ // logic_input_t
+ // -----------------------------------------------------------------------------
+
+ class logic_input_t : public logic_t
+ {
+ public:
+ logic_input_t(device_t &dev, const pstring &aname,
+ nldelegate delegate);
+
+ inline netlist_sig_t operator()() const noexcept
+ {
+ nl_assert(terminal_state() != STATE_INP_PASSIVE);
+ #if NL_USE_COPY_INSTEAD_OF_REFERENCE
+ return m_Q;
+ #else
+ return net().Q();
+ #endif
+ }
+
+ void inactivate() noexcept
+ {
+ if (!is_state(STATE_INP_PASSIVE))
+ {
+ set_state(STATE_INP_PASSIVE);
+ net().remove_from_active_list(*this);
+ }
+ }
+
+ void activate() noexcept
+ {
+ if (is_state(STATE_INP_PASSIVE))
+ {
+ net().add_to_active_list(*this);
+ set_state(STATE_INP_ACTIVE);
+ }
+ }
+
+ void activate_hl() noexcept
+ {
+ if (is_state(STATE_INP_PASSIVE))
+ {
+ net().add_to_active_list(*this);
+ set_state(STATE_INP_HL);
+ }
+ }
+
+ void activate_lh() noexcept
+ {
+ if (is_state(STATE_INP_PASSIVE))
+ {
+ net().add_to_active_list(*this);
+ set_state(STATE_INP_LH);
+ }
+ }
+ };
+
+ // -----------------------------------------------------------------------------
+ // logic_output_t
+ // -----------------------------------------------------------------------------
+
+ class logic_output_t : public logic_t
+ {
+ public:
+
+ /// \brief logic output constructor
+ ///
+ /// The third parameter does nothing. It is provided only for
+ /// compatibility with tristate_output_t in templatized device models
+ ///
+ /// \param dev Device owning this output
+ /// \param aname The name of this output
+ /// \param dummy Dummy parameter to allow construction like tristate output
+ ///
+ logic_output_t(device_t &dev, const pstring &aname, bool dummy = false);
+
+ void initial(netlist_sig_t val) noexcept;
+
+ inline void push(const netlist_sig_t &newQ, const netlist_time &delay) noexcept
+ {
+ m_my_net.set_Q_and_push(newQ, delay); // take the shortcut
+ }
+
+ inline void set_Q_time(const netlist_sig_t &newQ, const netlist_time_ext &at) noexcept
+ {
+ m_my_net.set_Q_time(newQ, at); // take the shortcut
+ }
+
+ /// \brief Dummy implementation for templatized generic devices
+ ///
+ /// This function shall never be called. It is defined here so that
+ /// templatized generic device models do not have to do tons of
+ /// template magic.
+ ///
+ /// This function terminates if actually called.
+ ///
+ [[noreturn]] static void set_tristate(netlist_sig_t v,
+ netlist_time ts_off_on, netlist_time ts_on_off)
+ {
+ plib::unused_var(v, ts_off_on, ts_on_off);
+ plib::terminate("set_tristate on logic_output should never be called!");
+ }
+ private:
+ logic_net_t m_my_net;
+ };
+
+ // -----------------------------------------------------------------------------
+ // tristate_output_t
+ // -----------------------------------------------------------------------------
+
+ /// \brief Tristate output
+ ///
+ /// In a lot of applications tristate enable inputs are just connected to
+ /// VCC/GND to permanently enable the outputs. In this case a pure
+ /// implementation using analog outputs would not perform well.
+ ///
+ /// For this object during creation it can be decided if a logic output or
+ /// a tristate output is used. Generally the owning device uses parameter
+ /// FORCE_TRISTATE_LOGIC to determine this.
+ ///
+ /// This is the preferred way to implement tristate outputs.
+ ///
+
+ class tristate_output_t : public logic_output_t
+ {
+ public:
+
+ tristate_output_t(device_t &dev, const pstring &aname, bool force_logic);
+
+ void push(netlist_sig_t newQ, netlist_time delay) noexcept
+ {
+ if (!m_tristate)
+ logic_output_t::push(newQ, delay);
+ m_last_logic = newQ;
+ }
+
+ void set_tristate(netlist_sig_t v,
+ netlist_time ts_off_on, netlist_time ts_on_off) noexcept
+ {
+ if (!m_force_logic)
+ if (v != m_tristate)
+ {
+ logic_output_t::push((v != 0) ? OUT_TRISTATE() : m_last_logic, v ? ts_off_on : ts_on_off);
+ m_tristate = v;
+ }
+ }
+
+ bool is_force_logic() const noexcept
+ {
+ return m_force_logic;
+ }
+
+ private:
+ using logic_output_t::initial;
+ using logic_output_t::set_Q_time;
+ state_var<netlist_sig_t> m_last_logic;
+ state_var<netlist_sig_t> m_tristate;
+ bool m_force_logic;
+ };
+
+} // namespace netlist
+
+
+#endif // NL_CORE_LOGIC_H_
diff --git a/src/lib/netlist/core/netlist_state.h b/src/lib/netlist/core/netlist_state.h
new file mode 100644
index 00000000000..318eaae6b2d
--- /dev/null
+++ b/src/lib/netlist/core/netlist_state.h
@@ -0,0 +1,275 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+///
+/// \file netlist_state.h
+///
+
+#ifndef NL_CORE_NETLIST_STATE_H_
+#define NL_CORE_NETLIST_STATE_H_
+
+#include "queue.h"
+
+#include "../nltypes.h"
+
+#include "../plib/plists.h"
+#include "../plib/pstate.h"
+#include "../plib/pstring.h"
+
+#include <array>
+#include <unordered_map>
+#include <utility>
+#include <vector>
+
+namespace netlist
+{
+ // -----------------------------------------------------------------------------
+ // netlist_state__t
+ // -----------------------------------------------------------------------------
+
+ class netlist_state_t
+ {
+ public:
+
+ using nets_collection_type = std::vector<device_arena::owned_ptr<detail::net_t>>;
+ using family_collection_type = std::unordered_map<pstring, host_arena::unique_ptr<logic_family_desc_t>>;
+
+ // need to preserve order of device creation ...
+ using devices_collection_type = std::vector<std::pair<pstring, device_arena::owned_ptr<core_device_t>>>;
+ netlist_state_t(const pstring &name, host_arena::unique_ptr<callbacks_t> &&callbacks);
+
+ PCOPYASSIGNMOVE(netlist_state_t, delete)
+
+ /// \brief Destructor
+ ///
+ /// The destructor is virtual to allow implementation specific devices
+ /// to connect to the outside world. For examples see MAME netlist.cpp.
+ ///
+ virtual ~netlist_state_t() noexcept = default;
+
+ template<class C>
+ static bool check_class(core_device_t *p) noexcept
+ {
+ return dynamic_cast<C *>(p) != nullptr;
+ }
+
+ core_device_t *get_single_device(const pstring &classname, bool (*cc)(core_device_t *)) const noexcept(false);
+
+ /// \brief Get single device filtered by class and name
+ ///
+ /// \tparam C Device class for which devices will be returned
+ /// \param name Name of the device
+ ///
+ /// \return pointers to device
+
+ template<class C>
+ C *get_single_device(const pstring &name) const
+ {
+ return dynamic_cast<C *>(get_single_device(name, check_class<C>));
+ }
+
+ /// \brief Get vector of devices
+ ///
+ /// \tparam C Device class for which devices will be returned
+ ///
+ /// \return vector with pointers to devices
+
+ template<class C>
+ inline std::vector<C *> get_device_list() const
+ {
+ std::vector<C *> tmp;
+ for (const auto &d : m_devices)
+ {
+ auto * const dev = dynamic_cast<C *>(d.second.get());
+ if (dev != nullptr)
+ tmp.push_back(dev);
+ }
+ return tmp;
+ }
+
+ // logging
+
+ log_type & log() noexcept { return m_log; }
+ const log_type &log() const noexcept { return m_log; }
+
+ plib::dynlib_base &lib() const noexcept { return *m_lib; }
+
+ netlist_t &exec() noexcept { return *m_netlist; }
+ const netlist_t &exec() const noexcept { return *m_netlist; }
+
+ // state handling
+ plib::state_manager_t &run_state_manager() noexcept { return m_state; }
+
+ template<typename O, typename C>
+ void save(O &owner, C &state, const pstring &module, const pstring &stname)
+ {
+ this->run_state_manager().save_item(static_cast<void *>(&owner), state, module + "." + stname);
+ }
+
+ template<typename O, typename C>
+ void save(O &owner, C *state, const pstring &module, const pstring &stname, const std::size_t count)
+ {
+ this->run_state_manager().save_state_ptr(static_cast<void *>(&owner), module + "." + stname, plib::state_manager_t::dtype<C>(), count, state);
+ }
+
+ // FIXME: only used by queue_t save state
+ std::size_t find_net_id(const detail::net_t *net) const;
+ detail::net_t *net_by_id(std::size_t id) const;
+
+ template <typename T>
+ void register_net(device_arena::owned_ptr<T> &&net) { m_nets.push_back(std::move(net)); }
+
+ /// \brief Get device pointer by name
+ ///
+ ///
+ /// \param name Name of the device
+ ///
+ /// \return core_device_t pointer if device exists, else nullptr
+
+ core_device_t *find_device(const pstring &name) const
+ {
+ for (const auto & d : m_devices)
+ if (d.first == name)
+ return d.second.get();
+ return nullptr;
+ }
+
+ /// \brief Register device using owned_ptr
+ ///
+ /// Used to register owned devices. These are devices declared as objects
+ /// in another devices.
+ ///
+ /// \param name Name of the device
+ /// \param dev Device to be registered
+
+ template <typename T>
+ void register_device(const pstring &name, device_arena::owned_ptr<T> &&dev) noexcept(false)
+ {
+ for (auto & d : m_devices)
+ if (d.first == name)
+ {
+ dev.release();
+ log().fatal(MF_DUPLICATE_NAME_DEVICE_LIST(name));
+ throw nl_exception(MF_DUPLICATE_NAME_DEVICE_LIST(name));
+ }
+ //m_devices.push_back(std::move(dev));
+ m_devices.insert(m_devices.end(), { name, std::move(dev) });
+ }
+
+ /// \brief Register device using unique_ptr
+ ///
+ /// Used to register devices.
+ ///
+ /// \param name Name of the device
+ /// \param dev Device to be registered
+
+ template <typename T>
+ void register_device(const pstring &name, device_arena::unique_ptr<T> &&dev)
+ {
+ register_device(name, device_arena::owned_ptr<T>(dev.release(), true, dev.get_deleter()));
+ }
+
+ /// \brief Remove device
+ ///
+ /// Care needs to be applied if this is called to remove devices with
+ /// sub-devices which may have registered state.
+ ///
+ /// \param dev Device to be removed
+
+ void remove_device(core_device_t *dev);
+
+ setup_t &setup() noexcept { return *m_setup; }
+ const setup_t &setup() const noexcept { return *m_setup; }
+
+ nlparse_t &parser();
+ const nlparse_t &parser() const;
+
+ // FIXME: make a postload member and include code there
+ void rebuild_lists(); // must be called after post_load !
+
+ static void compile_defines(std::vector<std::pair<pstring, pstring>> &defs);
+ static pstring version();
+ static pstring version_patchlevel();
+
+ nets_collection_type & nets() noexcept { return m_nets; }
+ const nets_collection_type & nets() const noexcept { return m_nets; }
+
+ devices_collection_type & devices() noexcept { return m_devices; }
+ const devices_collection_type & devices() const noexcept { return m_devices; }
+
+ family_collection_type &family_cache() { return m_family_cache; }
+
+ template<typename T, typename... Args>
+ device_arena::unique_ptr<T> make_pool_object(Args&&... args)
+ {
+ return plib::make_unique<T>(m_pool, std::forward<Args>(args)...);
+ }
+ // memory pool - still needed in some places
+ device_arena &pool() noexcept { return m_pool; }
+ const device_arena &pool() const noexcept { return m_pool; }
+
+ /// \brief set extended validation mode.
+ ///
+ /// The extended validation mode is not intended for running.
+ /// The intention is to identify power pins which are not properly
+ /// connected. The downside is that this mode creates a netlist which
+ /// is different (and not able to run).
+ ///
+ /// Extended validation is supported by nltool validate option.
+ ///
+ /// \param val Boolean value enabling/disabling extended validation mode
+ void set_extended_validation(bool val) { m_extended_validation = val; }
+
+ /// \brief State of extended validation mode.
+ ///
+ /// \returns boolean value indicating if extended validation mode is
+ /// turned on.
+ bool is_extended_validation() const { return m_extended_validation; }
+
+ struct stats_info
+ {
+ const detail::queue_t &m_queue;// performance
+ const plib::pperftime_t<true> &m_stat_mainloop;
+ const plib::pperfcount_t<true> &m_perf_out_processed;
+ };
+
+ /// \brief print statistics gathered during run
+ ///
+ void print_stats(stats_info &si) const;
+
+ /// \brief call reset on all netlist components
+ ///
+ void reset();
+
+ /// \brief prior to running free no longer needed resources
+ ///
+ void free_setup_resources();
+
+ private:
+
+ device_arena m_pool; // must be deleted last!
+
+ device_arena::unique_ptr<netlist_t> m_netlist;
+ std::unique_ptr<plib::dynlib_base> m_lib;
+ plib::state_manager_t m_state;
+ host_arena::unique_ptr<callbacks_t> m_callbacks;
+ log_type m_log;
+
+ // FIXME: should only be available during device construcion
+ host_arena::unique_ptr<setup_t> m_setup;
+
+ nets_collection_type m_nets;
+ // sole use is to manage lifetime of net objects
+ devices_collection_type m_devices;
+ // sole use is to manage lifetime of family objects
+ family_collection_type m_family_cache;
+ bool m_extended_validation;
+
+ // dummy version
+ int m_dummy_version;
+ };
+
+} // namespace netlist
+
+
+#endif // NL_CORE_NETLIST_STATE_H_
diff --git a/src/lib/netlist/core/nets.h b/src/lib/netlist/core/nets.h
index 96ecdf1836f..5eced2379e4 100644
--- a/src/lib/netlist/core/nets.h
+++ b/src/lib/netlist/core/nets.h
@@ -12,8 +12,8 @@
#include "state_var.h"
#include "../nltypes.h"
-#include "../plib/pstring.h"
#include "../plib/plists.h"
+#include "../plib/pstring.h"
namespace netlist
{
diff --git a/src/lib/netlist/core/object_array.h b/src/lib/netlist/core/object_array.h
new file mode 100644
index 00000000000..0079d819c3e
--- /dev/null
+++ b/src/lib/netlist/core/object_array.h
@@ -0,0 +1,225 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+///
+/// \file param.h
+///
+
+#ifndef NL_CORE_OBJECT_ARRAY_H_
+#define NL_CORE_OBJECT_ARRAY_H_
+
+#include "../nltypes.h"
+
+#include "../plib/plists.h"
+#include "../plib/pstring.h"
+
+#include <array>
+#include <utility>
+
+namespace netlist
+{
+ template<class C, std::size_t N>
+ class object_array_base_t : public plib::static_vector<C, N>
+ {
+ public:
+ template<class D, typename... Args>
+ //object_array_base_t(D &dev, const std::initializer_list<const char *> &names, Args&&... args)
+ object_array_base_t(D &dev, std::array<const char *, N> &&names, Args&&... args)
+ {
+ for (std::size_t i = 0; i<N; i++)
+ this->emplace_back(dev, pstring(names[i]), std::forward<Args>(args)...);
+ }
+
+ template<class D>
+ object_array_base_t(D &dev, const pstring &fmt)
+ {
+ for (std::size_t i = 0; i<N; i++)
+ this->emplace_back(dev, formatted(fmt, i));
+ }
+
+ template<class D, typename... Args>
+ object_array_base_t(D &dev, std::size_t offset, const pstring &fmt, Args&&... args)
+ {
+ for (std::size_t i = 0; i<N; i++)
+ this->emplace_back(dev, formatted(fmt, i+offset), std::forward<Args>(args)...);
+ }
+
+ template<class D>
+ object_array_base_t(D &dev, std::size_t offset, const pstring &fmt, nldelegate delegate)
+ {
+ for (std::size_t i = 0; i<N; i++)
+ this->emplace_back(dev, formatted(fmt, i+offset), delegate);
+ }
+
+ template<class D>
+ object_array_base_t(D &dev, std::size_t offset, std::size_t qmask, const pstring &fmt)
+ {
+ for (std::size_t i = 0; i<N; i++)
+ {
+ pstring name(formatted(fmt, i+offset));
+ if ((qmask >> i) & 1)
+ name += "Q";
+ this->emplace(i, dev, name);
+ }
+ }
+ protected:
+ object_array_base_t() = default;
+
+ static pstring formatted(const pstring &fmt, std::size_t n)
+ {
+ if (N != 1)
+ return plib::pfmt(fmt)(n);
+ return plib::pfmt(fmt)("");
+ }
+ };
+
+
+ template<class C, std::size_t N>
+ class object_array_t : public object_array_base_t<C, N>
+ {
+ public:
+ using base_type = object_array_base_t<C, N>;
+ using base_type::base_type;
+ };
+
+ template<std::size_t N>
+ class object_array_t<logic_input_t,N> : public object_array_base_t<logic_input_t, N>
+ {
+ public:
+ using base_type = object_array_base_t<logic_input_t, N>;
+ using base_type::base_type;
+
+ template<class D, std::size_t ND>
+ object_array_t(D &dev, std::size_t offset, std::size_t qmask,
+ const pstring &fmt, std::array<nldelegate, ND> &&delegates)
+ {
+ static_assert(N <= ND, "initializer_list size mismatch");
+ std::size_t i = 0;
+ for (auto &e : delegates)
+ {
+ if (i < N)
+ {
+ pstring name(this->formatted(fmt, i+offset));
+ if ((qmask >> i) & 1)
+ name += "Q";
+ this->emplace_back(dev, name, e);
+ }
+ i++;
+ }
+ }
+
+ //using value_type = typename plib::fast_type_for_bits<N>::type;
+ using value_type = std::uint32_t;
+ value_type operator ()()
+ {
+ if (N == 1) return e<0>() ;
+ if (N == 2) return e<0>() | (e<1>() << 1);
+ if (N == 3) return e<0>() | (e<1>() << 1) | (e<2>() << 2);
+ if (N == 4) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3);
+ if (N == 5) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
+ | (e<4>() << 4);
+ if (N == 6) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
+ | (e<4>() << 4) | (e<5>() << 5);
+ if (N == 7) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
+ | (e<4>() << 4) | (e<5>() << 5) | (e<6>() << 6);
+ if (N == 8) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
+ | (e<4>() << 4) | (e<5>() << 5) | (e<6>() << 6) | (e<7>() << 7);
+
+ value_type r(0);
+ for (std::size_t i = 0; i < N; i++)
+ r = static_cast<value_type>((*this)[i]() << (N-1)) | (r >> 1);
+ return r;
+ }
+
+ private:
+ template <std::size_t P>
+ inline constexpr value_type e() const { return (*this)[P](); }
+ };
+
+ template<std::size_t N>
+ class object_array_t<logic_output_t,N> : public object_array_base_t<logic_output_t, N>
+ {
+ public:
+ using base_type = object_array_base_t<logic_output_t, N>;
+ using base_type::base_type;
+
+ template <typename T>
+ inline void push(const T &v, const netlist_time &t)
+ {
+ if (N >= 1) (*this)[0].push((v >> 0) & 1, t);
+ if (N >= 2) (*this)[1].push((v >> 1) & 1, t);
+ if (N >= 3) (*this)[2].push((v >> 2) & 1, t);
+ if (N >= 4) (*this)[3].push((v >> 3) & 1, t);
+ if (N >= 5) (*this)[4].push((v >> 4) & 1, t);
+ if (N >= 6) (*this)[5].push((v >> 5) & 1, t);
+ if (N >= 7) (*this)[6].push((v >> 6) & 1, t);
+ if (N >= 8) (*this)[7].push((v >> 7) & 1, t);
+ for (std::size_t i = 8; i < N; i++)
+ (*this)[i].push((v >> i) & 1, t);
+ }
+
+ template<typename T>
+ void push(const T &v, const netlist_time * t)
+ {
+ if (N >= 1) (*this)[0].push((v >> 0) & 1, t[0]);
+ if (N >= 2) (*this)[1].push((v >> 1) & 1, t[1]);
+ if (N >= 3) (*this)[2].push((v >> 2) & 1, t[2]);
+ if (N >= 4) (*this)[3].push((v >> 3) & 1, t[3]);
+ if (N >= 5) (*this)[4].push((v >> 4) & 1, t[4]);
+ if (N >= 6) (*this)[5].push((v >> 5) & 1, t[5]);
+ if (N >= 7) (*this)[6].push((v >> 6) & 1, t[6]);
+ if (N >= 8) (*this)[7].push((v >> 7) & 1, t[7]);
+ for (std::size_t i = 8; i < N; i++)
+ (*this)[i].push((v >> i) & 1, t[i]);
+ }
+
+ template<typename T, std::size_t NT>
+ void push(const T &v, const std::array<netlist_time, NT> &t)
+ {
+ static_assert(NT >= N, "Not enough timing entries provided");
+
+ push(v, t.data());
+ }
+
+ void set_tristate(netlist_sig_t v,
+ netlist_time ts_off_on, netlist_time ts_on_off) noexcept
+ {
+ for (std::size_t i = 0; i < N; i++)
+ (*this)[i].set_tristate(v, ts_off_on, ts_on_off);
+ }
+ };
+
+ template<std::size_t N>
+ class object_array_t<tristate_output_t, N> : public object_array_base_t<tristate_output_t, N>
+ {
+ public:
+ using base_type = object_array_base_t<tristate_output_t, N>;
+ using base_type::base_type;
+
+ template <typename T>
+ inline void push(const T &v, const netlist_time &t)
+ {
+ if (N >= 1) (*this)[0].push((v >> 0) & 1, t);
+ if (N >= 2) (*this)[1].push((v >> 1) & 1, t);
+ if (N >= 3) (*this)[2].push((v >> 2) & 1, t);
+ if (N >= 4) (*this)[3].push((v >> 3) & 1, t);
+ if (N >= 5) (*this)[4].push((v >> 4) & 1, t);
+ if (N >= 6) (*this)[5].push((v >> 5) & 1, t);
+ if (N >= 7) (*this)[6].push((v >> 6) & 1, t);
+ if (N >= 8) (*this)[7].push((v >> 7) & 1, t);
+ for (std::size_t i = 8; i < N; i++)
+ (*this)[i].push((v >> i) & 1, t);
+ }
+
+ void set_tristate(netlist_sig_t v,
+ netlist_time ts_off_on, netlist_time ts_on_off) noexcept
+ {
+ for (std::size_t i = 0; i < N; i++)
+ (*this)[i].set_tristate(v, ts_off_on, ts_on_off);
+ }
+ };
+
+} // namespace netlist
+
+
+#endif // NL_CORE_OBJECT_ARRAY_H_
diff --git a/src/lib/netlist/core/param.h b/src/lib/netlist/core/param.h
index 80769f2d47e..9b353d0bdef 100644
--- a/src/lib/netlist/core/param.h
+++ b/src/lib/netlist/core/param.h
@@ -25,9 +25,10 @@
#include "base_objects.h"
+#include "../plib/palloc.h"
#include "../plib/pstream.h"
#include "../plib/pstring.h"
-#include "../plib/palloc.h"
+#include "../plib/putil.h" // psource_t
#include <memory>
@@ -241,7 +242,7 @@ namespace netlist
{
}
- std::unique_ptr<std::istream> stream();
+ plib::psource_t::stream_ptr stream();
protected:
void changed() noexcept override { }
};
@@ -261,7 +262,7 @@ namespace netlist
protected:
void changed() noexcept override
{
- plib::istream_read(*stream(), m_data.data(), 1<<AW);
+ plib::istream_read(stream().stream(), m_data.data(), 1<<AW);
}
private:
diff --git a/src/lib/netlist/core/queue.h b/src/lib/netlist/core/queue.h
new file mode 100644
index 00000000000..7e38c3f0ef9
--- /dev/null
+++ b/src/lib/netlist/core/queue.h
@@ -0,0 +1,114 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+///
+/// \file queue.h
+///
+
+#ifndef NL_CORE_QUEUE_H_
+#define NL_CORE_QUEUE_H_
+
+#include "queue.h"
+
+#include "../nl_errstr.h"
+#include "../nltypes.h"
+
+#include "../plib/pstate.h"
+#include "../plib/pstring.h"
+#include "../plib/ptimed_queue.h"
+
+#include <array>
+#include <unordered_map>
+#include <utility>
+#include <vector>
+
+namespace netlist
+{
+ namespace detail {
+ // Use timed_queue_heap to use stdc++ heap functions instead of linear processing.
+ // This slows down processing by about 25% on a Kaby Lake.
+ // template <class T, bool TS>
+ // using timed_queue = plib::timed_queue_heap<T, TS>;
+
+ template <class T, bool TS>
+ using timed_queue = plib::timed_queue_linear<T, TS>;
+
+ // -----------------------------------------------------------------------------
+ // queue_t
+ // -----------------------------------------------------------------------------
+
+ // We don't need a thread-safe queue currently. Parallel processing of
+ // solvers will update inputs after parallel processing.
+
+ template <typename O, bool TS>
+ class queue_base :
+ public timed_queue<plib::pqentry_t<netlist_time_ext, O *>, false>,
+ public plib::state_manager_t::callback_t
+ {
+ public:
+ using entry_t = plib::pqentry_t<netlist_time_ext, O *>;
+ using base_queue = timed_queue<entry_t, false>;
+ using id_delegate = plib::pmfp<std::size_t, const O *>;
+ using obj_delegate = plib::pmfp<O *, std::size_t>;
+
+ explicit queue_base(std::size_t size, id_delegate get_id, obj_delegate get_obj)
+ : timed_queue<plib::pqentry_t<netlist_time_ext, O *>, false>(size)
+ , m_qsize(0)
+ , m_times(size)
+ , m_net_ids(size)
+ , m_get_id(get_id)
+ , m_obj_by_id(get_obj)
+ {
+ }
+
+ ~queue_base() noexcept override = default;
+
+ queue_base(const queue_base &) = delete;
+ queue_base(queue_base &&) = delete;
+ queue_base &operator=(const queue_base &) = delete;
+ queue_base &operator=(queue_base &&) = delete;
+
+ protected:
+
+ void register_state(plib::state_manager_t &manager, const pstring &module) override
+ {
+ manager.save_item(this, m_qsize, module + "." + "qsize");
+ manager.save_item(this, &m_times[0], module + "." + "times", m_times.size());
+ manager.save_item(this, &m_net_ids[0], module + "." + "names", m_net_ids.size());
+ }
+ void on_pre_save(plib::state_manager_t &manager) override
+ {
+ plib::unused_var(manager);
+ m_qsize = this->size();
+ for (std::size_t i = 0; i < m_qsize; i++ )
+ {
+ m_times[i] = this->listptr()[i].exec_time().as_raw();
+ m_net_ids[i] = m_get_id(this->listptr()[i].object());
+ }
+ }
+ void on_post_load(plib::state_manager_t &manager) override
+ {
+ plib::unused_var(manager);
+ this->clear();
+ for (std::size_t i = 0; i < m_qsize; i++ )
+ {
+ O *n = m_obj_by_id(m_net_ids[i]);
+ this->template push<false>(entry_t(netlist_time_ext::from_raw(m_times[i]),n));
+ }
+ }
+
+ private:
+ std::size_t m_qsize;
+ std::vector<netlist_time_ext::internal_type> m_times;
+ std::vector<std::size_t> m_net_ids;
+ id_delegate m_get_id;
+ obj_delegate m_obj_by_id;
+ };
+
+ using queue_t = queue_base<net_t, false>;
+
+ } // namespace detail
+} // namespace netlist
+
+
+#endif // NL_CORE_QUEUE_H_
diff --git a/src/lib/netlist/core/setup.h b/src/lib/netlist/core/setup.h
index d21b948f4ee..5048c2ae765 100644
--- a/src/lib/netlist/core/setup.h
+++ b/src/lib/netlist/core/setup.h
@@ -9,9 +9,9 @@
#define NL_CORE_SETUP_H_
#include "../nl_config.h"
-#include "../nltypes.h"
#include "../nl_factory.h"
#include "../nl_setup.h"
+#include "../nltypes.h"
#include "../plib/ppreprocessor.h"
#include "../plib/pstream.h"
@@ -283,6 +283,22 @@ namespace netlist
pstring m_filename;
};
+ class source_pattern_t : public source_netlist_t
+ {
+ public:
+
+ explicit source_pattern_t(const pstring &pat)
+ : m_pattern(pat)
+ {
+ }
+
+ protected:
+ stream_ptr stream(const pstring &name) override;
+
+ private:
+ pstring m_pattern;
+ };
+
class source_mem_t : public source_netlist_t
{
public:
diff --git a/src/lib/netlist/devices/net_lib.cpp b/src/lib/netlist/devices/net_lib.cpp
index da6babfc092..ef88713b556 100644
--- a/src/lib/netlist/devices/net_lib.cpp
+++ b/src/lib/netlist/devices/net_lib.cpp
@@ -69,64 +69,39 @@ namespace devices
LIB_ENTRY(nicRSFF)
LIB_ENTRY(nicDelay)
LIB_ENTRY(2102A)
- LIB_ENTRY(2102A_dip)
LIB_ENTRY(2716)
#if !(NL_USE_TRUTHTABLE_7448)
LIB_ENTRY(7448)
- LIB_ENTRY(7448_dip)
#endif
- LIB_ENTRY(7442)
- LIB_ENTRY(7442_dip)
LIB_ENTRY(7450)
- LIB_ENTRY(7450_dip)
LIB_ENTRY(7473)
- LIB_ENTRY(7473_dip)
LIB_ENTRY(7473A)
- LIB_ENTRY(7473A_dip)
LIB_ENTRY(7474)
- LIB_ENTRY(7474_dip)
- LIB_ENTRY(7475)
- LIB_ENTRY(7475_dip)
- LIB_ENTRY(7477)
- LIB_ENTRY(7477_dip)
+ LIB_ENTRY(7475_GATE)
+ LIB_ENTRY(7477_GATE)
LIB_ENTRY(7483)
- LIB_ENTRY(7483_dip)
LIB_ENTRY(7485)
- LIB_ENTRY(7485_dip)
LIB_ENTRY(7490)
- LIB_ENTRY(7490_dip)
LIB_ENTRY(7492)
- LIB_ENTRY(7492_dip)
LIB_ENTRY(7493)
- LIB_ENTRY(7493_dip)
LIB_ENTRY(7497)
- LIB_ENTRY(7497_dip)
#if (!NL_USE_TRUTHTABLE_74107)
LIB_ENTRY(74107)
- LIB_ENTRY(74107_dip)
#endif
- LIB_ENTRY(74107A) // FIXME: implement missing DIP
+ LIB_ENTRY(74107A)
LIB_ENTRY(74113)
- LIB_ENTRY(74113_dip)
LIB_ENTRY(74113A)
- LIB_ENTRY(74113A_dip)
LIB_ENTRY(74121)
LIB_ENTRY(74123)
LIB_ENTRY(74125)
LIB_ENTRY(74126)
LIB_ENTRY(74153)
- LIB_ENTRY(74153_dip)
LIB_ENTRY(74161)
LIB_ENTRY(74161_fixme)
- LIB_ENTRY(74161_dip)
LIB_ENTRY(74163)
- LIB_ENTRY(74163_dip)
LIB_ENTRY(74164)
- LIB_ENTRY(74164_dip)
LIB_ENTRY(74165)
- LIB_ENTRY(74165_dip)
LIB_ENTRY(74166)
- LIB_ENTRY(74166_dip)
LIB_ENTRY(74174)
LIB_ENTRY(74175)
LIB_ENTRY(74192)
@@ -135,7 +110,6 @@ namespace devices
LIB_ENTRY(74365)
LIB_ENTRY(74377_GATE)
LIB_ENTRY(74393)
- LIB_ENTRY(74393_dip)
//ENTRY(74279, TTL_74279, "") // only dip available
LIB_ENTRY(SN74LS629)
LIB_ENTRY(82S16)
@@ -146,14 +120,19 @@ namespace devices
LIB_ENTRY(9310)
LIB_ENTRY(9314)
LIB_ENTRY(9316)
+ LIB_ENTRY(9322_GATE)
LIB_ENTRY(9322)
LIB_ENTRY(9334)
LIB_ENTRY(AM2847)
// FIXME: duplicate?
LIB_ENTRY(CD4006)
- LIB_ENTRY(CD4006_dip)
+ LIB_ENTRY(CD4013)
+ LIB_ENTRY(CD4017)
+ LIB_ENTRY(CD4022)
LIB_ENTRY(CD4020_WI)
LIB_ENTRY(CD4020)
+ LIB_ENTRY(CD4024)
+ LIB_ENTRY(CD4053_GATE)
LIB_ENTRY(CD4066_GATE)
LIB_ENTRY(CD4316_GATE)
LIB_ENTRY(4538)
@@ -169,22 +148,15 @@ namespace devices
LIB_ENTRY(r2r_dac)
LIB_ENTRY(tristate)
LIB_ENTRY(tristate3)
- LIB_ENTRY(74174_dip)
LIB_ENTRY(74175_dip)
LIB_ENTRY(74192_dip)
LIB_ENTRY(74193_dip)
LIB_ENTRY(74194_dip)
LIB_ENTRY(74365_dip)
- LIB_ENTRY(82S16_dip)
- LIB_ENTRY(82S115_dip)
LIB_ENTRY(9602)
- LIB_ENTRY(9310_dip)
LIB_ENTRY(9314_dip)
- LIB_ENTRY(9316_dip)
- LIB_ENTRY(9322_dip)
LIB_ENTRY(9334_dip)
LIB_ENTRY(AM2847_dip)
- LIB_ENTRY(SN74LS629_dip)
LIB_ENTRY(MM5837_dip)
}
diff --git a/src/lib/netlist/devices/net_lib.h b/src/lib/netlist/devices/net_lib.h
index b4f65bf2322..9511abf1eb5 100644
--- a/src/lib/netlist/devices/net_lib.h
+++ b/src/lib/netlist/devices/net_lib.h
@@ -28,17 +28,16 @@
#define IND_P(ind) ((ind) * 1e-12)
#endif
+NETLIST_EXTERNAL(base)
+NETLIST_EXTERNAL(CD4XXX_lib)
+NETLIST_EXTERNAL(OPAMP_lib)
+NETLIST_EXTERNAL(otheric_lib)
+NETLIST_EXTERNAL(TTL74XX_lib)
+NETLIST_EXTERNAL(ROMS_lib)
+
#if NL_AUTO_DEVICES
#include "nld_devinc.h"
-#include "netlist/macro/nlm_cd4xxx.h"
-#include "netlist/macro/nlm_opamp.h"
-#include "netlist/macro/nlm_other.h"
-#include "netlist/macro/nlm_ttl74xx.h"
-#include "netlist/macro/nlm_roms.h"
-
-#include "nld_7448.h"
-
#else
#define SOLVER(name, freq) \
@@ -49,7 +48,9 @@
#include "nld_2102A.h"
#include "nld_4006.h"
#include "nld_4013.h"
+#include "nld_4017.h"
#include "nld_4020.h"
+#include "nld_4053.h"
#include "nld_4066.h"
#include "nld_4316.h"
#include "nld_74107.h"
@@ -76,6 +77,7 @@
#include "nld_7483.h"
#include "nld_7485.h"
#include "nld_7490.h"
+#include "nld_7492.h"
#include "nld_7493.h"
#include "nld_7497.h"
#include "nld_74ls629.h"
diff --git a/src/lib/netlist/devices/nld_2102A.cpp b/src/lib/netlist/devices/nld_2102A.cpp
index d60b661ad21..e2fcd7ef9e1 100644
--- a/src/lib/netlist/devices/nld_2102A.cpp
+++ b/src/lib/netlist/devices/nld_2102A.cpp
@@ -3,6 +3,22 @@
/*
* nld_2102A.cpp
*
+ * 2102: 1024 x 1-bit Static RAM
+ *
+ * +--------------+
+ * A6 |1 ++ 16| A7
+ * A5 |2 15| A8
+ * RWQ |3 14| A9
+ * A1 |4 82S16 13| CEQ
+ * A2 |5 12| DO
+ * A3 |6 11| DI
+ * A4 |7 10| VCC
+ * A0 |8 9| GND
+ * +--------------+
+ *
+ *
+ * Naming conventions follow Intel datasheet
+ *
*/
#include "nld_2102A.h"
@@ -60,7 +76,6 @@ namespace netlist
}
}
- friend class NETLIB_NAME(2102A_dip);
private:
object_array_t<logic_input_t, 10> m_A;
logic_input_t m_CEQ;
@@ -74,39 +89,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(2102A_dip)
- {
- NETLIB_CONSTRUCTOR(2102A_dip)
- , A(*this, "A")
- {
- register_subalias("8", A.m_A[0]);
- register_subalias("4", A.m_A[1]);
- register_subalias("5", A.m_A[2]);
- register_subalias("6", A.m_A[3]);
- register_subalias("7", A.m_A[4]);
- register_subalias("2", A.m_A[5]);
- register_subalias("1", A.m_A[6]);
- register_subalias("16", A.m_A[7]);
- register_subalias("15", A.m_A[8]);
- register_subalias("14", A.m_A[9]);
-
- register_subalias("13", A.m_CEQ);
- register_subalias("3", A.m_RWQ);
-
- register_subalias("11", A.m_DI);
- register_subalias("12", A.m_DO);
-
- register_subalias("10", "A.VCC");
- register_subalias("9", "A.GND");
-
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(2102A) A;
- };
-
NETLIB_DEVICE_IMPL(2102A, "RAM_2102A", "+CEQ,+A0,+A1,+A2,+A3,+A4,+A5,+A6,+A7,+A8,+A9,+RWQ,+DI,@VCC,@GND")
- NETLIB_DEVICE_IMPL(2102A_dip,"RAM_2102A_DIP","")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_2102A.h b/src/lib/netlist/devices/nld_2102A.h
index 9d2279445f1..30e693f0e00 100644
--- a/src/lib/netlist/devices/nld_2102A.h
+++ b/src/lib/netlist/devices/nld_2102A.h
@@ -1,50 +1,13 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_2102A.h
- *
- * 2102: 1024 x 1-bit Static RAM
- *
- * +--------------+
- * A6 |1 ++ 16| A7
- * A5 |2 15| A8
- * RWQ |3 14| A9
- * A1 |4 82S16 13| CEQ
- * A2 |5 12| DO
- * A3 |6 11| DI
- * A4 |7 10| VCC
- * A0 |8 9| GND
- * +--------------+
- *
- *
- * Naming conventions follow Intel datasheet
- *
- */
#ifndef NLD_2102A_H_
#define NLD_2102A_H_
#include "netlist/nl_setup.h"
-#define RAM_2102A(name, cCEQ, cA0, cA1, cA2, cA3, cA4, cA5, cA6, cA7, cA8, cA9, cRWQ, cDI) \
- NET_REGISTER_DEV(RAM_2102A, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CEQ, cCEQ) \
- NET_CONNECT(name, A0, cA0) \
- NET_CONNECT(name, A1, cA1) \
- NET_CONNECT(name, A2, cA2) \
- NET_CONNECT(name, A3, cA3) \
- NET_CONNECT(name, A4, cA4) \
- NET_CONNECT(name, A5, cA5) \
- NET_CONNECT(name, A6, cA6) \
- NET_CONNECT(name, A7, cA7) \
- NET_CONNECT(name, A8, cA8) \
- NET_CONNECT(name, A9, cA9) \
- NET_CONNECT(name, RWQ, cRWQ) \
- NET_CONNECT(name, DI, cDI)
-
-#define RAM_2102A_DIP(name) \
- NET_REGISTER_DEV(RAM_2102A_DIP, name)
+// expects: RAM_2102A(name, cCEQ, cA0, cA1, cA2, cA3, cA4, cA5, cA6, cA7, cA8, cA9, cRWQ, cDI)
+#define RAM_2102A(...) \
+ NET_REGISTER_DEVEXT(RAM_2102A, __VA_ARGS__)
#endif /* NLD_2102A_H_ */
diff --git a/src/lib/netlist/devices/nld_4006.cpp b/src/lib/netlist/devices/nld_4006.cpp
index 45f885b91d5..1e49a46b724 100644
--- a/src/lib/netlist/devices/nld_4006.cpp
+++ b/src/lib/netlist/devices/nld_4006.cpp
@@ -1,7 +1,41 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_4006.c
+ * nld_4006.cpp
+ *
+ * CD4006: CMOS 18-Stage Static Register
+ *
+ * Description
+ *
+ * CD4006BMS types are composed of 4 separate shift register sections: two
+ * sections of four stages and two sections of five stages with an output tap
+ * at the fourth stage. Each section has an independent single-rail data path.
+ *
+ * A common clock signal is used for all stages. Data are shifted to the next
+ * stages on negative-going transitions of the clock. Through appropriate
+ * connections of inputs and outputs, multiple register sections of 4, 5, 8,
+ * and 9 stages or single register sections of 10, 12, 13, 14, 16, 17 and 18
+ * stages can be implemented using one CD4006BMS package. Longer shift register
+ * sections can be assembled by using more than one CD4006BMS.
+ *
+ * To facilitate cascading stages when clock rise and fall times are slow,
+ * an optional output (D1 + 4’) that is delayed one-half clockcycle, is
+ * provided.
+ *
+ * +--------------+
+ * D1 |1 ++ 14| VDD
+ * D1+4' |2 13| D1+4
+ * CLOCK |3 12| D2+5
+ * D2 |4 4006 11| D2+4
+ * D3 |5 10| D3+4
+ * D4 |6 9| D4+5
+ * VSS |7 8| D4+4
+ * +--------------+
+ *
+ *
+ * Naming conventions follow SYC datasheet
+ *
+ * FIXME: Timing depends on VDD-VSS
*
*/
@@ -20,7 +54,7 @@ namespace netlist
NETLIB_CONSTRUCTOR_MODEL(CD4006, "CD4XXX")
, m_CLOCK(*this, "CLOCK", NETLIB_DELEGATE(inputs))
, m_I(*this, {"D1", "D2", "D3", "D4"}, NETLIB_DELEGATE(inputs))
- , m_Q(*this, {"D1P4", "D1P4S", "D2P4", "D2P5", "D3P4", "D4P4", "D3P5"})
+ , m_Q(*this, {"D1P4", "D1P4S", "D2P4", "D2P5", "D3P4", "D4P4", "D4P5"})
, m_d(*this, "m_d", 0)
, m_last_clock(*this, "m_last_clock", 0)
, m_supply(*this)
@@ -69,34 +103,7 @@ namespace netlist
nld_power_pins m_supply;
};
- NETLIB_OBJECT(CD4006_dip)
- {
- NETLIB_CONSTRUCTOR(CD4006_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_I[0]);
- register_subalias("2", A.m_Q[1]);
- register_subalias("3", A.m_CLOCK);
- register_subalias("4", A.m_I[1]);
- register_subalias("5", A.m_I[2]);
- register_subalias("6", A.m_I[3]);
- register_subalias("7", "A.VSS");
-
- register_subalias("8", A.m_Q[5]);
- register_subalias("9", A.m_Q[6]);
- register_subalias("10", A.m_Q[4]);
- register_subalias("11", A.m_Q[2]);
- register_subalias("12", A.m_Q[3]);
- register_subalias("13", A.m_Q[0]);
- register_subalias("14", "A.VDD");
-
- }
- private:
- NETLIB_SUB(CD4006) A;
- };
-
- NETLIB_DEVICE_IMPL(CD4006, "CD4006", "+CLOCK,+D1,+D2,+D3,+D4,+D1P4,+D1P4S,+D2P4,+D2P5,+D3P4,+D4P4,+D3P5,@VCC,@GND")
- NETLIB_DEVICE_IMPL(CD4006_dip, "CD4006_DIP", "")
+ NETLIB_DEVICE_IMPL(CD4006, "CD4006", "+CLOCK,+D1,+D2,+D3,+D4,+D1P4,+D1P4S,+D2P4,+D2P5,+D3P4,+D4P4,+D4P5,@VCC,@GND")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_4006.h b/src/lib/netlist/devices/nld_4006.h
index 77ff7528fc8..86092c254dc 100644
--- a/src/lib/netlist/devices/nld_4006.h
+++ b/src/lib/netlist/devices/nld_4006.h
@@ -1,43 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_4006.h
- *
- * CD4006: CMOS 18-Stage Static Register
- *
- * Description
- *
- * CD4006BMS types are composed of 4 separate shift register sections: two
- * sections of four stages and two sections of five stages with an output tap
- * at the fourth stage. Each section has an independent single-rail data path.
- *
- * A common clock signal is used for all stages. Data are shifted to the next
- * stages on negative-going transitions of the clock. Through appropriate
- * connections of inputs and outputs, multiple register sections of 4, 5, 8,
- * and 9 stages or single register sections of 10, 12, 13, 14, 16, 17 and 18
- * stages can be implemented using one CD4006BMS package. Longer shift register
- * sections can be assembled by using more than one CD4006BMS.
- *
- * To facilitate cascading stages when clock rise and fall times are slow,
- * an optional output (D1 + 4’) that is delayed one-half clockcycle, is
- * provided.
- *
- * +--------------+
- * D1 |1 ++ 14| VDD
- * D1+4' |2 13| D1+4
- * CLOCK |3 12| D2+5
- * D2 |4 4006 11| D2+4
- * D3 |5 10| D3+4
- * D4 |6 9| D4+5
- * VSS |7 8| D4+4
- * +--------------+
- *
- *
- * Naming conventions follow SYC datasheet
- *
- * FIXME: Timing depends on VDD-VSS
- *
- */
#ifndef NLD_4006_H_
#define NLD_4006_H_
diff --git a/src/lib/netlist/devices/nld_4013.cpp b/src/lib/netlist/devices/nld_4013.cpp
index 42c2eb71350..66d03e09fbd 100644
--- a/src/lib/netlist/devices/nld_4013.cpp
+++ b/src/lib/netlist/devices/nld_4013.cpp
@@ -3,6 +3,40 @@
/*
* nld_4013.cpp
*
+ * CD4013: Dual Positive-Edge-Triggered D Flip-Flops
+ * with Set, Reset and Complementary Outputs
+ *
+ * +--------------+
+ * Q1 |1 ++ 14| VDD
+ * Q1Q |2 13| Q2
+ * CLOCK1 |3 12| Q2Q
+ * RESET1 |4 4013 11| CLOCK2
+ * DATA1 |5 10| RESET2
+ * SET1 |6 9| DATA2
+ * VSS |7 8| SET2
+ * +--------------+
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | SET | RES | CLK | D || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 1 | 0 | X | X || 1 | 0 |
+ * | 0 | 1 | X | X || 0 | 1 |
+ * | 1 | 1 | X | X || 1 | 1 | (*)
+ * | 0 | 0 | R | 1 || 1 | 0 |
+ * | 0 | 0 | R | 0 || 0 | 1 |
+ * | 0 | 0 | 0 | X || Q0| Q0Q |
+ * +-----+-----+-----+---++---+-----+
+ *
+ * (*) This configuration is not stable, i.e. it will not persist
+ * when either the preset and or clear inputs return to their inactive (high) level
+ *
+ * Q0 The output logic level of Q before the indicated input conditions were established
+ *
+ * R: 0 -. 1
+ *
+ * Naming conventions follow National Semiconductor datasheet
+ *
+ * FIXME: Check that (*) is emulated properly
*/
#include "netlist/nl_base.h"
@@ -86,41 +120,7 @@ namespace netlist
}
};
- NETLIB_OBJECT(CD4013_dip)
- {
- NETLIB_CONSTRUCTOR(CD4013_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", "A.Q");
- register_subalias("2", "A.QQ");
- register_subalias("3", "A.CLOCK");
- register_subalias("4", "A.RESET");
- register_subalias("5", "A.DATA");
- register_subalias("6", "A.SET");
- register_subalias("7", "A.VSS");
-
- register_subalias("8", "B.SET");
- register_subalias("9", "B.DATA");
- register_subalias("10", "B.RESET");
- register_subalias("11", "B.CLOCK");
- register_subalias("12", "B.QQ");
- register_subalias("13", "B.Q");
- register_subalias("14", "A.VDD");
-
- connect("A.VSS", "B.VSS");
- connect("A.VDD", "B.VDD");
- }
- //NETLIB_UPDATEI();
- //NETLIB_RESETI();
-
- private:
- NETLIB_SUB(CD4013) m_A;
- NETLIB_SUB(CD4013) m_B;
- };
-
NETLIB_DEVICE_IMPL(CD4013, "CD4013", "+CLOCK,+DATA,+RESET,+SET,@VDD,@VSS")
- NETLIB_DEVICE_IMPL(CD4013_dip, "CD4013_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_4013.h b/src/lib/netlist/devices/nld_4013.h
index 3d77a45b70b..7a2623bb8df 100644
--- a/src/lib/netlist/devices/nld_4013.h
+++ b/src/lib/netlist/devices/nld_4013.h
@@ -1,43 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_4013.h
- *
- * CD4013: Dual Positive-Edge-Triggered D Flip-Flops
- * with Set, Reset and Complementary Outputs
- *
- * +--------------+
- * Q1 |1 ++ 14| VDD
- * Q1Q |2 13| Q2
- * CLOCK1 |3 12| Q2Q
- * RESET1 |4 4013 11| CLOCK2
- * DATA1 |5 10| RESET2
- * SET1 |6 9| DATA2
- * VSS |7 8| SET2
- * +--------------+
- *
- * +-----+-----+-----+---++---+-----+
- * | SET | RES | CLK | D || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 1 | 0 | X | X || 1 | 0 |
- * | 0 | 1 | X | X || 0 | 1 |
- * | 1 | 1 | X | X || 1 | 1 | (*)
- * | 0 | 0 | R | 1 || 1 | 0 |
- * | 0 | 0 | R | 0 || 0 | 1 |
- * | 0 | 0 | 0 | X || Q0| Q0Q |
- * +-----+-----+-----+---++---+-----+
- *
- * (*) This configuration is not stable, i.e. it will not persist
- * when either the preset and or clear inputs return to their inactive (high) level
- *
- * Q0 The output logic level of Q before the indicated input conditions were established
- *
- * R: 0 -. 1
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- * FIXME: Check that (*) is emulated properly
- */
#ifndef NLD_4013_H_
#define NLD_4013_H_
@@ -48,7 +10,4 @@
#define CD4013(...) \
NET_REGISTER_DEVEXT(CD4013, __VA_ARGS__)
-#define CD4013_DIP(name) \
- NET_REGISTER_DEV(CD4013_DIP, name)
-
#endif /* NLD_4013_H_ */
diff --git a/src/lib/netlist/devices/nld_4017.cpp b/src/lib/netlist/devices/nld_4017.cpp
new file mode 100644
index 00000000000..d680eaa4829
--- /dev/null
+++ b/src/lib/netlist/devices/nld_4017.cpp
@@ -0,0 +1,118 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+/*
+ * nld_4017.cpp
+ *
+ * CD4017: Decade Counter/Divider with 10 Decoded Outputs
+ *
+ * +--------------+
+ * Q5 |1 ++ 16| VDD
+ * Q1 |2 15| RESET
+ * Q0 |3 14| CLOCK
+ * Q2 |4 4017 13| CLOCK ENABLE
+ * Q6 |5 12| CARRY OUT
+ * Q7 |6 11| Q9
+ * Q3 |7 10| Q4
+ * VSS |8 9| Q8
+ * +--------------+
+ *
+ *
+ * CD4022: Divide-by-8 Counter/Divider with 8 Decoded Outputs
+ *
+ * +--------------+
+ * Q1 |1 ++ 16| VDD
+ * Q0 |2 15| RESET
+ * Q2 |3 14| CLOCK
+ * Q5 |4 4022 13| CLOCK ENABLE
+ * Q6 |5 12| CARRY OUT
+ * NC |6 11| Q4
+ * Q3 |7 10| Q7
+ * VSS |8 9| NC
+ * +--------------+
+ *
+ * Naming conventions follow Fairchild datasheet
+ *
+ * FIXME: Timing depends on VDD-VSS
+ * This needs a cmos d-a/a-d proxy implementation.
+ *
+ */
+
+#include "nld_4017.h"
+#include "nl_base.h"
+#include "nl_factory.h"
+
+namespace netlist
+{
+ namespace devices
+ {
+
+ template <std::size_t _MaxCount>
+ NETLIB_OBJECT(CD4017_base)
+ {
+ NETLIB_CONSTRUCTOR_MODEL(CD4017_base, "CD4XXX")
+ , m_CLK(*this, "CLK", NETLIB_DELEGATE(clk))
+ , m_CLKEN(*this, "CLKEN", NETLIB_DELEGATE(inputs))
+ , m_RESET(*this, "RESET", NETLIB_DELEGATE(inputs))
+ , m_CO(*this, "CO")
+ , m_Q(*this, 0, "Q{}")
+ , m_cnt(*this, "m_cnt", 0)
+ , m_supply(*this)
+ {
+ }
+
+ NETLIB_RESETI()
+ {
+ m_CLK.set_state(logic_t::STATE_INP_LH);
+ m_cnt = 0;
+ }
+
+ NETLIB_HANDLERI(clk)
+ {
+ ++m_cnt;
+ update_outputs(m_cnt);
+ }
+
+ NETLIB_HANDLERI(inputs)
+ {
+ if (m_RESET())
+ {
+ m_CLK.inactivate();
+ m_cnt = 0;
+ update_outputs(m_cnt);
+ }
+ else if (m_CLKEN())
+ {
+ m_CLK.inactivate();
+ }
+ else
+ {
+ m_CLK.activate_lh();
+ }
+ }
+
+ public:
+ void update_outputs(const unsigned cnt) noexcept
+ {
+ for (std::size_t i = 0; i < _MaxCount; i++)
+ m_Q[i].push(i == cnt, NLTIME_FROM_NS(200));
+ m_CO.push(cnt < _MaxCount / 2, NLTIME_FROM_NS(160));
+ }
+ logic_input_t m_CLK;
+ logic_input_t m_CLKEN;
+ logic_input_t m_RESET;
+ logic_output_t m_CO;
+ object_array_t<logic_output_t, _MaxCount> m_Q;
+
+ state_var<unsigned> m_cnt;
+ nld_power_pins m_supply;
+ };
+
+ using NETLIB_NAME(CD4017) = NETLIB_NAME(CD4017_base)<10>;
+ using NETLIB_NAME(CD4022) = NETLIB_NAME(CD4017_base)<8>;
+
+
+ NETLIB_DEVICE_IMPL(CD4017, "CD4017", "")
+ NETLIB_DEVICE_IMPL(CD4022, "CD4022", "")
+
+ } //namespace devices
+} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_4017.h b/src/lib/netlist/devices/nld_4017.h
new file mode 100644
index 00000000000..e97c45586ca
--- /dev/null
+++ b/src/lib/netlist/devices/nld_4017.h
@@ -0,0 +1,15 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+
+#ifndef NLD_4017_H_
+#define NLD_4017_H_
+
+#include "netlist/nl_setup.h"
+
+#define CD4017(name) \
+ NET_REGISTER_DEV(CD4017, name)
+
+#define CD4022(name) \
+ NET_REGISTER_DEV(CD4022, name)
+
+#endif /* NLD_4017_H_ */
diff --git a/src/lib/netlist/devices/nld_4020.cpp b/src/lib/netlist/devices/nld_4020.cpp
index 9fe5bb2ec0a..4143f66da8d 100644
--- a/src/lib/netlist/devices/nld_4020.cpp
+++ b/src/lib/netlist/devices/nld_4020.cpp
@@ -1,7 +1,39 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_4020.c
+ * nld_4020.cpp
+ *
+ * CD4020: 14-Stage Ripple Carry Binary Counters
+ *
+ * +--------------+
+ * Q12 |1 ++ 16| VDD
+ * Q13 |2 15| Q11
+ * Q14 |3 14| Q10
+ * Q6 |4 4020 13| Q8
+ * Q5 |5 12| Q9
+ * Q7 |6 11| RESET
+ * Q4 |7 10| IP (Input pulses)
+ * VSS |8 9| Q1
+ * +--------------+
+ *
+ *
+ * CD4024: 7-Stage Ripple Carry Binary Counters
+ *
+ * +--------------+
+ * IP |1 ++ 14| VDD
+ * RESET |2 13| NC
+ * Q7 |3 12| Q1
+ * Q6 |4 4024 11| Q2
+ * Q5 |5 10| NC
+ * Q4 |6 9| Q3
+ * VSS |7 8| NC
+ * +--------------+
+ *
+ *
+ * Naming conventions follow Texas Instruments datasheet
+ *
+ * FIXME: Timing depends on VDD-VSS
+ * This needs a cmos d-a/a-d proxy implementation.
*
*/
@@ -13,10 +45,16 @@ namespace netlist
{
namespace devices
{
+
+ template <unsigned _LiveBitmask>
NETLIB_OBJECT(CD4020_sub)
{
+ static constexpr unsigned MAX_BITS = 14;
+ static constexpr unsigned MAX_BITMASK = (1 << MAX_BITS) - 1;
+
NETLIB_CONSTRUCTOR_MODEL(CD4020_sub, "CD4XXX")
, m_IP(*this, "IP", NETLIB_DELEGATE(ip))
+ , m_RESET(*this, "RESET", NETLIB_DELEGATE(reseti))
, m_Q(*this, {"Q1", "_Q2", "_Q3", "Q4", "Q5", "Q6", "Q7", "Q8", "Q9",
"Q10", "Q11", "Q12", "Q13", "Q14"})
, m_cnt(*this, "m_cnt", 0)
@@ -33,10 +71,24 @@ namespace netlist
NETLIB_HANDLERI(ip)
{
++m_cnt;
- m_cnt &= 0x3fff;
update_outputs(m_cnt);
}
+ NETLIB_HANDLERI(reseti)
+ {
+ if (m_RESET())
+ {
+ m_cnt = 0;
+ m_IP.inactivate();
+ /* static */ const netlist_time reset_time = netlist_time::from_nsec(140);
+ for (unsigned i = 0; i < MAX_BITS; i++)
+ if (((_LiveBitmask >> i) & 1) != 0)
+ m_Q[i].push(0, reset_time);
+ }
+ else
+ m_IP.activate_hl();
+ }
+
public:
void update_outputs(const unsigned cnt) noexcept
{
@@ -50,12 +102,13 @@ namespace netlist
NLTIME_FROM_NS(1380), NLTIME_FROM_NS(1480),
};
- m_Q[0].push(cnt & 1, out_delayQn[0]);
- for (std::size_t i=3; i<14; i++)
- m_Q[i].push((cnt >> i) & 1, out_delayQn[i]);
+ for (unsigned i = 0; i < MAX_BITS; i++)
+ if (((_LiveBitmask >> i) & 1) != 0)
+ m_Q[i].push(cnt & 1, out_delayQn[i]);
}
logic_input_t m_IP;
- object_array_t<logic_output_t, 14> m_Q;
+ logic_input_t m_RESET;
+ object_array_t<logic_output_t, MAX_BITS> m_Q;
state_var<unsigned> m_cnt;
nld_power_pins m_supply;
@@ -65,9 +118,9 @@ namespace netlist
{
NETLIB_CONSTRUCTOR_MODEL(CD4020, "CD4XXX")
, m_sub(*this, "sub")
- , m_RESET(*this, "RESET", NETLIB_DELEGATE(inputs))
{
register_subalias("IP", m_sub.m_IP);
+ register_subalias("RESET", m_sub.m_RESET);
register_subalias("Q1", m_sub.m_Q[0]);
register_subalias("Q4", m_sub.m_Q[3]);
register_subalias("Q5", m_sub.m_Q[4]);
@@ -86,24 +139,32 @@ namespace netlist
//NETLIB_RESETI() {}
- NETLIB_HANDLERI(inputs)
+ private:
+ NETLIB_SUB(CD4020_sub)<0x3ff9> m_sub;
+ };
+
+ NETLIB_OBJECT(CD4024)
+ {
+ NETLIB_CONSTRUCTOR_MODEL(CD4024, "CD4XXX")
+ , m_sub(*this, "sub")
{
- if (m_RESET())
- {
- m_sub.m_cnt = 0;
- m_sub.m_IP.inactivate();
- /* static */ const netlist_time reset_time = netlist_time::from_nsec(140);
- m_sub.m_Q[0].push(0, reset_time);
- for (std::size_t i=3; i<14; i++)
- m_sub.m_Q[i].push(0, reset_time);
- }
- else
- m_sub.m_IP.activate_hl();
+ register_subalias("IP", m_sub.m_IP);
+ register_subalias("RESET", m_sub.m_RESET);
+ register_subalias("Q1", m_sub.m_Q[0]);
+ register_subalias("Q2", m_sub.m_Q[1]);
+ register_subalias("Q3", m_sub.m_Q[2]);
+ register_subalias("Q4", m_sub.m_Q[3]);
+ register_subalias("Q5", m_sub.m_Q[4]);
+ register_subalias("Q6", m_sub.m_Q[5]);
+ register_subalias("Q7", m_sub.m_Q[6]);
+ register_subalias("VDD", "sub.VDD");
+ register_subalias("VSS", "sub.VSS");
}
+ //NETLIB_RESETI() {}
+
private:
- NETLIB_SUB(CD4020_sub) m_sub;
- logic_input_t m_RESET;
+ NETLIB_SUB(CD4020_sub)<0x7f> m_sub;
};
@@ -111,5 +172,7 @@ namespace netlist
NETLIB_DEVICE_IMPL(CD4020, "CD4020", "")
NETLIB_DEVICE_IMPL_ALIAS(CD4020_WI, CD4020, "CD4020_WI", "+IP,+RESET,+VDD,+VSS")
+ NETLIB_DEVICE_IMPL(CD4024, "CD4024", "")
+
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_4020.h b/src/lib/netlist/devices/nld_4020.h
index f24251fb1dc..942b2f2d457 100644
--- a/src/lib/netlist/devices/nld_4020.h
+++ b/src/lib/netlist/devices/nld_4020.h
@@ -1,28 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_4020.h
- *
- * CD4020: 14-Stage Ripple Carry Binary Counters
- *
- * +--------------+
- * Q12 |1 ++ 16| VDD
- * Q13 |2 15| Q11
- * Q14 |3 14| Q10
- * Q6 |4 4020 13| Q8
- * Q5 |5 12| Q9
- * Q7 |6 11| RESET
- * Q4 |7 10| IP (Input pulses)
- * VSS |8 9| Q1
- * +--------------+
- *
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- * FIXME: Timing depends on VDD-VSS
- * This needs a cmos d-a/a-d proxy implementation.
- *
- */
#ifndef NLD_4020_H_
#define NLD_4020_H_
@@ -40,4 +17,7 @@
#define CD4020(name) \
NET_REGISTER_DEV(CD4020, name)
+#define CD4024(name) \
+ NET_REGISTER_DEV(CD4024, name)
+
#endif /* NLD_4020_H_ */
diff --git a/src/lib/netlist/devices/nld_4053.cpp b/src/lib/netlist/devices/nld_4053.cpp
new file mode 100644
index 00000000000..62db781fbfa
--- /dev/null
+++ b/src/lib/netlist/devices/nld_4053.cpp
@@ -0,0 +1,143 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+/*
+ * nld_4053.cpp
+ *
+ * CD4053: Triple 2-Channel Analog Multiplexer/Demultiplexer
+ *
+ * +--------------+
+ * INOUTBY |1 ++ 16| VDD
+ * INOUTBX |2 15| OUTINB
+ * INOUTCY |3 14| OUTINA
+ * OUTINC |4 4053 13| INOUTAY
+ * INOUTCX |5 12| INOUTAX
+ * INH |6 11| A
+ * VEE |7 10| B
+ * VSS |8 9| C
+ * +--------------+
+ *
+ * FIXME: These devices are slow (~125 ns). This is currently not reflected
+ *
+ * Naming conventions follow National semiconductor datasheet
+ *
+ */
+
+
+#include "nld_4053.h"
+
+#include "netlist/analog/nlid_twoterm.h"
+#include "netlist/solver/nld_solver.h"
+
+namespace netlist
+{
+ namespace devices
+ {
+ NETLIB_OBJECT(CD4053_GATE)
+ {
+ NETLIB_CONSTRUCTOR_MODEL(CD4053_GATE, "CD4XXX")
+ , m_RX(*this, "RX")
+ , m_RY(*this, "RY")
+ , m_select(*this, "S", NETLIB_DELEGATE(controls))
+ , m_inhibit(*this, "INH", NETLIB_DELEGATE(controls))
+ , m_VEE(*this, "VEE", NETLIB_DELEGATE(controls))
+ , m_base_r(*this, "BASER", nlconst::magic(270.0))
+ , m_lastx(*this, "m_lastx", false)
+ , m_lasty(*this, "m_lasty", false)
+ , m_select_state(*this, "m_select_state", false)
+ , m_inhibit_state(*this, "m_inhibit_state", false)
+ , m_supply(*this)
+ {
+ connect(m_RX.N(), m_RY.N());
+
+ register_subalias("X", m_RX.P());
+ register_subalias("Y", m_RY.P());
+
+ register_subalias("XY", m_RX.N());
+ }
+
+ NETLIB_RESETI()
+ {
+ // Start in off condition
+ // FIXME: is ROFF correct?
+ m_RX.set_R(plib::reciprocal(exec().gmin()));
+ m_RY.set_R(plib::reciprocal(exec().gmin()));
+ }
+
+ private:
+ NETLIB_HANDLERI(controls)
+ {
+ bool newx = false, newy = false;
+ if (!on(m_inhibit, m_inhibit_state))
+ {
+ if (!on(m_select, m_select_state))
+ {
+ newx = true;
+ }
+ else
+ {
+ newy = true;
+ }
+ }
+
+ if (newx != m_lastx || newy != m_lasty)
+ {
+ const nl_fptype sup = (m_supply.VCC().Q_Analog() - m_supply.GND().Q_Analog());
+ const nl_fptype Ron = m_base_r() * nlconst::magic(5.0) / sup;
+ const nl_fptype Roff = plib::reciprocal(exec().gmin());
+ const nl_fptype RX = (newx != 0) ? Ron : Roff;
+ const nl_fptype RY = (newy != 0) ? Ron : Roff;
+ if (m_RX.solver() == m_RY.solver())
+ {
+ m_RX.change_state([this, &RX, &RY]()
+ {
+ m_RX.set_R(RX);
+ m_RY.set_R(RY);
+ });
+ }
+ else
+ {
+ m_RX.change_state([this, &RX]()
+ {
+ m_RX.set_R(RX);
+ });
+ m_RY.change_state([this, &RY]()
+ {
+ m_RY.set_R(RY);
+ });
+ }
+ }
+ }
+
+ bool on(analog_input_t &input, bool &state)
+ {
+ nl_fptype sup = (m_supply.VCC().Q_Analog() - m_supply.GND().Q_Analog());
+ nl_fptype in = input() - m_supply.GND().Q_Analog();
+ nl_fptype low = nlconst::magic(0.45) * sup;
+ nl_fptype high = nlconst::magic(0.55) * sup;
+ if (in < low)
+ {
+ state = false;
+ }
+ else if (in > high)
+ {
+ state = true;
+ }
+ return state;
+ }
+
+ analog::NETLIB_SUB(R_base) m_RX;
+ analog::NETLIB_SUB(R_base) m_RY;
+ analog_input_t m_select;
+ analog_input_t m_inhibit;
+ analog_input_t m_VEE;
+ param_fp_t m_base_r;
+ state_var<bool> m_lastx;
+ state_var<bool> m_lasty;
+ state_var<bool> m_select_state;
+ state_var<bool> m_inhibit_state;
+ nld_power_pins m_supply;
+ };
+
+ NETLIB_DEVICE_IMPL(CD4053_GATE, "CD4053_GATE", "")
+ } //namespace devices
+} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_4053.h b/src/lib/netlist/devices/nld_4053.h
new file mode 100644
index 00000000000..83636ef636c
--- /dev/null
+++ b/src/lib/netlist/devices/nld_4053.h
@@ -0,0 +1,13 @@
+// license:GPL-2.0+
+// copyright-holders:Couriersud
+#ifndef NLD_4053_H_
+#define NLD_4053_H_
+
+#include "netlist/nl_setup.h"
+
+// FIXME: Implement pure CMOS version
+
+#define CD4053_GATE(name) \
+ NET_REGISTER_DEV(CD4053_GATE, name)
+
+#endif /* NLD_4053_H_ */
diff --git a/src/lib/netlist/devices/nld_4066.cpp b/src/lib/netlist/devices/nld_4066.cpp
index fd66d982ac5..1c6723dcb1e 100644
--- a/src/lib/netlist/devices/nld_4066.cpp
+++ b/src/lib/netlist/devices/nld_4066.cpp
@@ -1,7 +1,23 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_4066.c
+ * nld_4066.cpp
+ *
+ * CD4066: Quad Bilateral Switch
+ *
+ * +--------------+
+ * INOUTA |1 ++ 14| VDD
+ * OUTINA |2 13| CONTROLA
+ * OUTINB |3 12| CONTROLD
+ * INOUTB |4 4066 11| INOUTD
+ * CONTROLB |5 10| OUTIND
+ * CONTROLC |6 9| OUTINC
+ * VSS |7 8| INOUTC
+ * +--------------+
+ *
+ * FIXME: These devices are slow (~125 ns). This is currently not reflected
+ *
+ * Naming conventions follow National semiconductor datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_4066.h b/src/lib/netlist/devices/nld_4066.h
index 0a43911d3ce..f30369f28d3 100644
--- a/src/lib/netlist/devices/nld_4066.h
+++ b/src/lib/netlist/devices/nld_4066.h
@@ -1,25 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_4066.h
- *
- * CD4066: Quad Bilateral Switch
- *
- * +--------------+
- * INOUTA |1 ++ 14| VDD
- * OUTINA |2 13| CONTROLA
- * OUTINB |3 12| CONTROLD
- * INOUTB |4 4066 11| INOUTD
- * CONTROLB |5 10| OUTIND
- * CONTROLC |6 9| OUTINC
- * VSS |7 8| INOUTC
- * +--------------+
- *
- * FIXME: These devices are slow (~125 ns). This is currently not reflected
- *
- * Naming conventions follow National semiconductor datasheet
- *
- */
#ifndef NLD_4066_H_
#define NLD_4066_H_
diff --git a/src/lib/netlist/devices/nld_4316.cpp b/src/lib/netlist/devices/nld_4316.cpp
index 7c0159dbe91..0c6c10cc71f 100644
--- a/src/lib/netlist/devices/nld_4316.cpp
+++ b/src/lib/netlist/devices/nld_4316.cpp
@@ -1,7 +1,24 @@
// license:BSD-3-Clause
// copyright-holders:Vas Crabb
/*
- * nld_4316.c
+ * nld_4316.cpp
+ *
+ * CD74HC4316: Quad Analog Switch with Level Translation
+ *
+ * +--------------+
+ * 1Z |1 ++ 16| VCC
+ * 1Y |2 15| 1S
+ * 2Y |3 14| 4S
+ * 2Z |4 4316 13| 4Z
+ * 2S |5 12| 4Y
+ * 3S |6 11| 3Y
+ * /E |7 10| 3Z
+ * GND |8 9| VEE
+ * +--------------+
+ *
+ * FIXME: These devices are slow (can be over 200 ns in HC types). This is currently not reflected
+ *
+ * Naming conventions follow Texas Instruments datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_4316.h b/src/lib/netlist/devices/nld_4316.h
index 3cf05aeb9cf..35c94bd30a0 100644
--- a/src/lib/netlist/devices/nld_4316.h
+++ b/src/lib/netlist/devices/nld_4316.h
@@ -1,26 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Vas Crabb
-/*
- * nld_4316.h
- *
- * CD4066: Quad Analog Switch with Level Translation
- *
- * +--------------+
- * 1Z |1 ++ 16| VCC
- * 1Y |2 15| 1S
- * 2Y |3 14| 4S
- * 2Z |4 4066 13| 4Z
- * 2S |5 12| 4Y
- * 3S |6 11| 3Y
- * /E |7 10| 3Z
- * GND |8 9| VEE
- * +--------------+
- *
- * FIXME: These devices are slow (can be over 200 ns in HC types). This is currently not reflected
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- */
#ifndef NLD_4316_H_
#define NLD_4316_H_
diff --git a/src/lib/netlist/devices/nld_74107.cpp b/src/lib/netlist/devices/nld_74107.cpp
index dbf7f40d34b..26df3f65bee 100644
--- a/src/lib/netlist/devices/nld_74107.cpp
+++ b/src/lib/netlist/devices/nld_74107.cpp
@@ -1,7 +1,63 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74107.c
+ * nld_74107.cpp
+ *
+ * DM74107: DUAL J-K FLIP-FLOPS WITH CLEAR
+ *
+ * +--------------+
+ * 1J |1 ++ 14| VCC
+ * 1QQ |2 13| 1CLRQ
+ * 1Q |3 12| 1CLK
+ * 1K |4 74107 11| 2K
+ * 2Q |5 10| 2CLRQ
+ * 2QQ |6 9| 2CLK
+ * GND |7 8| 2J
+ * +--------------+
+ *
+ *
+ * Function table 107
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | CLRQ| CLK | J | K || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | X | X | X || 0 | 1 |
+ * | 1 | * | 0 | 0 || Q0| Q0Q |
+ * | 1 | * | 1 | 0 || 1 | 0 |
+ * | 1 | * | 0 | 1 || 0 | 1 |
+ * | 1 | * | 1 | 1 || TOGGLE |
+ * +-----+-----+-----+---++---+-----+
+ * _
+ * * = _| |_
+ *
+ * This is positive triggered, J and K
+ * are latched during clock high and
+ * transferred when CLK falls. The
+ * datasheet requires J and K to be
+ * stable during clock high.
+ *
+ * Function table 107A
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | CLRQ| CLK | J | K || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | X | X | X || 0 | 1 |
+ * | 1 | F | 0 | 0 || Q0| Q0Q |
+ * | 1 | F | 1 | 0 || 1 | 0 |
+ * | 1 | F | 0 | 1 || 0 | 1 |
+ * | 1 | F | 1 | 1 || TOGGLE |
+ * | 1 | 1 | X | X || Q0| Q0Q |
+ * +-----+-----+-----+---++---+-----+
+ *
+ * THe 107A is negative triggered.
+ *
+ * Naming conventions follow Texas instruments datasheet
+ *
+ * TODO: Currently, only the 107A is implemented.
+ * The 107 uses the same model, but different timings.
+ * The requirement that J and K must be stable during
+ * clock high indicates that the chip may exhibit undefined
+ * behaviour.
*
*/
@@ -101,47 +157,8 @@ namespace netlist
}
};
- NETLIB_OBJECT(74107_dip)
- {
- NETLIB_CONSTRUCTOR(74107_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_J);
- register_subalias("2", m_A.m_QQ);
- register_subalias("3", m_A.m_Q);
-
- register_subalias("4", m_A.m_K);
- register_subalias("5", m_B.m_Q);
- register_subalias("6", m_B.m_QQ);
-
- register_subalias("7", "A.GND");
-
- register_subalias("8", m_B.m_J);
- register_subalias("9", m_B.m_clk);
- register_subalias("10", m_B.m_clrQ);
-
- register_subalias("11", m_B.m_K);
- register_subalias("12", m_A.m_clk);
- register_subalias("13", m_A.m_clrQ);
-
- register_subalias("14", "A.VCC" );
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
-
- }
- //NETLIB_RESETI();
- //NETLIB_UPDATEI();
-
- private:
- NETLIB_SUB(74107) m_A;
- NETLIB_SUB(74107) m_B;
- };
-
#if (!NL_USE_TRUTHTABLE_74107)
NETLIB_DEVICE_IMPL(74107, "TTL_74107", "+CLK,+J,+K,+CLRQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74107_dip, "TTL_74107_DIP", "")
#endif
NETLIB_DEVICE_IMPL(74107A, "TTL_74107A", "+CLK,+J,+K,+CLRQ,@VCC,@GND")
diff --git a/src/lib/netlist/devices/nld_74107.h b/src/lib/netlist/devices/nld_74107.h
index 306ae8b1174..3a954dbe09a 100644
--- a/src/lib/netlist/devices/nld_74107.h
+++ b/src/lib/netlist/devices/nld_74107.h
@@ -1,87 +1,18 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74107.h
- *
- * DM74107: DUAL J-K FLIP-FLOPS WITH CLEAR
- *
- * +--------------+
- * 1J |1 ++ 14| VCC
- * 1QQ |2 13| 1CLRQ
- * 1Q |3 12| 1CLK
- * 1K |4 74107 11| 2K
- * 2Q |5 10| 2CLRQ
- * 2QQ |6 9| 2CLK
- * GND |7 8| 2J
- * +--------------+
- *
- *
- * Function table 107
- *
- * +-----+-----+-----+---++---+-----+
- * | CLRQ| CLK | J | K || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | X | X | X || 0 | 1 |
- * | 1 | * | 0 | 0 || Q0| Q0Q |
- * | 1 | * | 1 | 0 || 1 | 0 |
- * | 1 | * | 0 | 1 || 0 | 1 |
- * | 1 | * | 1 | 1 || TOGGLE |
- * +-----+-----+-----+---++---+-----+
- * _
- * * = _| |_
- *
- * This is positive triggered, J and K
- * are latched during clock high and
- * transferred when CLK falls. The
- * datasheet requires J and K to be
- * stable during clock high.
- *
- * Function table 107A
- *
- * +-----+-----+-----+---++---+-----+
- * | CLRQ| CLK | J | K || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | X | X | X || 0 | 1 |
- * | 1 | F | 0 | 0 || Q0| Q0Q |
- * | 1 | F | 1 | 0 || 1 | 0 |
- * | 1 | F | 0 | 1 || 0 | 1 |
- * | 1 | F | 1 | 1 || TOGGLE |
- * | 1 | 1 | X | X || Q0| Q0Q |
- * +-----+-----+-----+---++---+-----+
- *
- * THe 107A is negative triggered.
- *
- * Naming conventions follow Texas instruments datasheet
- *
- * TODO: Currently, only the 107A is implemented.
- * The 107 uses the same model, but different timings.
- * The requirement that J and K must be stable during
- * clock high indicates that the chip may exhibit undefined
- * behaviour.
- *
- */
#ifndef NLD_74107_H_
#define NLD_74107_H_
#include "netlist/nl_setup.h"
-#define TTL_74107A(name, cCLK, cJ, cK, cCLRQ) \
- NET_REGISTER_DEV(TTL_74107A, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, J, cJ) \
- NET_CONNECT(name, K, cK) \
- NET_CONNECT(name, CLRQ, cCLRQ)
-
#if (!NL_USE_TRUTHTABLE_74107)
-#define TTL_74107(name, cCLK, cJ, cK, cCLRQ) \
- TTL_74107A(name, cCLK, cJ, cK, cCLRQ)
-
-#define TTL_74107_DIP(name) \
- NET_REGISTER_DEV(TTL_74107_DIP, name)
-
+#define TTL_74107(...) \
+ NET_REGISTER_DEVEXT(TTL_74107, __VA_ARGS__)
#endif
+// usage: TTL_74107A(name, cCLK, cJ, cK, cCLRQ)
+#define TTL_74107A(...) \
+ NET_REGISTER_DEVEXT(TTL_74107A, __VA_ARGS__)
+
#endif /* NLD_74107_H_ */
diff --git a/src/lib/netlist/devices/nld_74113.cpp b/src/lib/netlist/devices/nld_74113.cpp
index 784e866570a..1198771695e 100644
--- a/src/lib/netlist/devices/nld_74113.cpp
+++ b/src/lib/netlist/devices/nld_74113.cpp
@@ -1,7 +1,59 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74113.c
+ * nld_74113.cpp
+ *
+ * 74113: Dual Master-Slave J-K Flip-Flops with Set and Complementary Outputs
+ * 74113A: Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Set and Complementary Outputs
+ *
+ * +----------+
+ * 1CLK |1 ++ 14| VCC
+ * 1K |2 13| 2CLK
+ * 1J |3 12| 2K
+ * 1SETQ |4 74113 11| 2J
+ * 1Q |5 10| 2SETQ
+ * 1QQ |6 9| 2Q
+ * GND |7 8| 2QQ
+ * +----------+
+ *
+ *
+ * Function table 113
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | SETQ| CLK | J | K || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | X | X | X || 1 | 0 |
+ * | 1 | * | 0 | 0 || Q0| Q0Q |
+ * | 1 | * | 1 | 0 || 1 | 0 |
+ * | 1 | * | 0 | 1 || 0 | 1 |
+ * | 1 | * | 1 | 1 || TOGGLE |
+ * +-----+-----+-----+---++---+-----+
+ * _
+ * * = _| |_
+ *
+ * This is positive triggered, J and K
+ * are latched during clock high and
+ * transferred when CLK falls.
+ *
+ * Function table 113A
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | CLRQ| CLK | J | K || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | X | X | X || 0 | 1 |
+ * | 1 | F | 0 | 0 || Q0| Q0Q |
+ * | 1 | F | 1 | 0 || 1 | 0 |
+ * | 1 | F | 0 | 1 || 0 | 1 |
+ * | 1 | F | 1 | 1 || TOGGLE |
+ * | 1 | 1 | X | X || Q0| Q0Q |
+ * +-----+-----+-----+---++---+-----+
+ *
+ * THe 113A is negative triggered.
+ *
+ * Naming conventions follow Texas instruments datasheet
+ *
+ * FIXME: Currently, only the 113 is implemented.
+ * The 113A uses the same model.
*
*/
@@ -91,72 +143,8 @@ namespace netlist
};
- NETLIB_OBJECT(74113_dip)
- {
- NETLIB_CONSTRUCTOR(74113_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_CLK);
- register_subalias("2", m_A.m_K);
- register_subalias("3", m_A.m_J);
- register_subalias("4", m_A.m_SETQ);
- register_subalias("5", m_A.m_Q);
- register_subalias("6", m_A.m_QQ);
- register_subalias("7", "A.GND");
-
- register_subalias("8", m_B.m_QQ);
- register_subalias("9", m_B.m_Q);
- register_subalias("10", m_B.m_SETQ);
- register_subalias("11", m_B.m_J);
- register_subalias("12", m_B.m_K);
- register_subalias("13", m_B.m_CLK);
- register_subalias("14", "A.VCC");
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- }
-
- private:
- NETLIB_SUB(74113) m_A;
- NETLIB_SUB(74113) m_B;
- };
-
- NETLIB_OBJECT(74113A_dip)
- {
- NETLIB_CONSTRUCTOR(74113A_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_CLK);
- register_subalias("2", m_A.m_K);
- register_subalias("3", m_A.m_J);
- register_subalias("4", m_A.m_SETQ);
- register_subalias("5", m_A.m_Q);
- register_subalias("6", m_A.m_QQ);
- register_subalias("7", "A.GND");
-
- register_subalias("8", m_B.m_QQ);
- register_subalias("9", m_B.m_Q);
- register_subalias("10", m_B.m_SETQ);
- register_subalias("11", m_B.m_J);
- register_subalias("12", m_B.m_K);
- register_subalias("13", m_B.m_CLK);
- register_subalias("14", "A.VCC");
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- }
-
- private:
- NETLIB_SUB(74113A) m_A;
- NETLIB_SUB(74113A) m_B;
- };
-
NETLIB_DEVICE_IMPL(74113, "TTL_74113", "+CLK,+J,+K,+CLRQ,@VCC,@GND")
NETLIB_DEVICE_IMPL(74113A, "TTL_74113A", "+CLK,+J,+K,+CLRQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74113_dip, "TTL_74113_DIP", "")
- NETLIB_DEVICE_IMPL(74113A_dip, "TTL_74113A_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74113.h b/src/lib/netlist/devices/nld_74113.h
index 02f38973594..0a33de8cac6 100644
--- a/src/lib/netlist/devices/nld_74113.h
+++ b/src/lib/netlist/devices/nld_74113.h
@@ -1,84 +1,17 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74113.h
- *
- * 74113: Dual Master-Slave J-K Flip-Flops with Set and Complementary Outputs
- * 74113A: Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Set and Complementary Outputs
- *
- * +----------+
- * 1CLK |1 ++ 14| VCC
- * 1K |2 13| 2CLK
- * 1J |3 12| 2K
- * 1SETQ |4 74113 11| 2J
- * 1Q |5 10| 2SETQ
- * 1QQ |6 9| 2Q
- * GND |7 8| 2QQ
- * +----------+
- *
- *
- * Function table 113
- *
- * +-----+-----+-----+---++---+-----+
- * | SETQ| CLK | J | K || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | X | X | X || 1 | 0 |
- * | 1 | * | 0 | 0 || Q0| Q0Q |
- * | 1 | * | 1 | 0 || 1 | 0 |
- * | 1 | * | 0 | 1 || 0 | 1 |
- * | 1 | * | 1 | 1 || TOGGLE |
- * +-----+-----+-----+---++---+-----+
- * _
- * * = _| |_
- *
- * This is positive triggered, J and K
- * are latched during clock high and
- * transferred when CLK falls.
- *
- * Function table 113A
- *
- * +-----+-----+-----+---++---+-----+
- * | CLRQ| CLK | J | K || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | X | X | X || 0 | 1 |
- * | 1 | F | 0 | 0 || Q0| Q0Q |
- * | 1 | F | 1 | 0 || 1 | 0 |
- * | 1 | F | 0 | 1 || 0 | 1 |
- * | 1 | F | 1 | 1 || TOGGLE |
- * | 1 | 1 | X | X || Q0| Q0Q |
- * +-----+-----+-----+---++---+-----+
- *
- * THe 113A is negative triggered.
- *
- * Naming conventions follow Texas instruments datasheet
- *
- * FIXME: Currently, only the 113 is implemented.
- * The 113A uses the same model.
- *
- */
#ifndef NLD_74113_H_
#define NLD_74113_H_
#include "netlist/nl_setup.h"
-#define TTL_74113(name, cCLK, cJ, cK, cCLRQ) \
- NET_REGISTER_DEV(TTL_74113, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, J, cJ) \
- NET_CONNECT(name, K, cK) \
- NET_CONNECT(name, CLRQ, cCLRQ)
+// usage: TTL_74113(name, cCLK, cJ, cK, cCLRQ)
+#define TTL_74113(...) \
+ NET_REGISTER_DEVEXT(TTL_74113, __VA_ARGS__)
-#define TTL_74113A(name, cCLK, cJ, cK, cCLRQ) \
- TTL_74113(name, cCLK, cJ, cK, cCLRQ)
-
-#define TTL_74113_DIP(name) \
- NET_REGISTER_DEV(TTL_74113_DIP, name)
-
-
-#define TTL_74113A_DIP(name) \
- NET_REGISTER_DEV(TTL_74113A_DIP, name)
+// usage: TTL_74113A(name, cCLK, cJ, cK, cCLRQ)
+#define TTL_74113A(...) \
+ NET_REGISTER_DEVEXT(TTL_74113, __VA_ARGS__)
#endif /* NLD_74113_H_ */
diff --git a/src/lib/netlist/devices/nld_74123.cpp b/src/lib/netlist/devices/nld_74123.cpp
index 31f59dbbc22..f19f0042be1 100644
--- a/src/lib/netlist/devices/nld_74123.cpp
+++ b/src/lib/netlist/devices/nld_74123.cpp
@@ -1,7 +1,48 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74123.c
+ * nld_74123.cpp
+ *
+ * 74123: Dual Retriggerable One-Shot with Clear and Complementary Outputs
+ *
+ * +--------------+
+ * A1 |1 ++ 16| VCC
+ * B1 |2 15| RC1
+ * CLR1 |3 14| C1
+ * Q1Q |4 74123 13| Q1
+ * Q2 |5 12| Q2Q
+ * C2 |6 11| CLR2
+ * RC2 |7 10| B2
+ * GND |8 9| A2
+ * +--------------+
+ *
+ * Naming conventions follow Fairchild Semiconductor datasheet
+ *
+ * DM9602: Dual Retriggerable, Resettable One Shots
+ *
+ * +--------------+
+ * C1 |1 ++ 16| VCC
+ * RC1 |2 15| C2
+ * CLR1 |3 14| RC2
+ * B1 |4 9602 13| CLR2
+ * A1 |5 12| B2
+ * Q1 |6 11| A2
+ * Q1Q |7 10| Q2
+ * GND |8 9| Q2Q
+ * +--------------+
+ *
+ * CD4538: Dual Retriggerable, Resettable One Shots
+ *
+ * +--------------+
+ * C1 |1 ++ 16| VCC
+ * RC1 |2 15| C2
+ * CLR1 |3 14| RC2
+ * A1 |4 4538 13| CLR2
+ * B1 |5 12| A2
+ * Q1 |6 11| B2
+ * Q1Q |7 10| Q2
+ * GND |8 9| Q2Q
+ * +--------------+
*
*/
diff --git a/src/lib/netlist/devices/nld_74123.h b/src/lib/netlist/devices/nld_74123.h
index 9557b0382b6..be07c60f6d4 100644
--- a/src/lib/netlist/devices/nld_74123.h
+++ b/src/lib/netlist/devices/nld_74123.h
@@ -1,50 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74123.h
- *
- * 74123: Dual Retriggerable One-Shot with Clear and Complementary Outputs
- *
- * +--------------+
- * A1 |1 ++ 16| VCC
- * B1 |2 15| RC1
- * CLR1 |3 14| C1
- * Q1Q |4 74123 13| Q1
- * Q2 |5 12| Q2Q
- * C2 |6 11| CLR2
- * RC2 |7 10| B2
- * GND |8 9| A2
- * +--------------+
- *
- * Naming conventions follow Fairchild Semiconductor datasheet
- *
- * DM9602: Dual Retriggerable, Resettable One Shots
- *
- * +--------------+
- * C1 |1 ++ 16| VCC
- * RC1 |2 15| C2
- * CLR1 |3 14| RC2
- * B1 |4 9602 13| CLR2
- * A1 |5 12| B2
- * Q1 |6 11| A2
- * Q1Q |7 10| Q2
- * GND |8 9| Q2Q
- * +--------------+
- *
- * CD4538: Dual Retriggerable, Resettable One Shots
- *
- * +--------------+
- * C1 |1 ++ 16| VCC
- * RC1 |2 15| C2
- * CLR1 |3 14| RC2
- * A1 |4 4538 13| CLR2
- * B1 |5 12| A2
- * Q1 |6 11| B2
- * Q1Q |7 10| Q2
- * GND |8 9| Q2Q
- * +--------------+
- *
- */
#ifndef NLD_74123_H_
#define NLD_74123_H_
diff --git a/src/lib/netlist/devices/nld_74125.cpp b/src/lib/netlist/devices/nld_74125.cpp
index 094803ea803..f60d5b37c5c 100644
--- a/src/lib/netlist/devices/nld_74125.cpp
+++ b/src/lib/netlist/devices/nld_74125.cpp
@@ -12,22 +12,6 @@
namespace netlist
{
- template <typename T>
- struct uptr : public device_arena::unique_ptr<T>
- {
- uptr() = default;
-
- using base_type = device_arena::unique_ptr<T>;
-
- template<typename O, typename... Args>
- uptr(O &owner, const pstring &name, Args&&... args)
- : device_arena::unique_ptr<T>(owner.template make_pool_object<T>(owner, name, std::forward<Args>(args)...))
- { }
-
- constexpr auto operator ()() noexcept -> decltype((*device_arena::unique_ptr<T>::get())()) { return (*this->get())(); }
- constexpr auto operator ()() const noexcept -> const decltype((*device_arena::unique_ptr<T>::get())()) { return (*this->get())(); }
- };
-
namespace devices
{
@@ -69,7 +53,7 @@ namespace netlist
param_logic_t m_TE;
logic_input_t m_A;
- uptr<logic_input_t> m_G;
+ logic_input_t m_G;
tristate_output_t m_Y;
nld_power_pins m_power_pins;
};
diff --git a/src/lib/netlist/devices/nld_74153.cpp b/src/lib/netlist/devices/nld_74153.cpp
index 80b460ef52b..6fea1a711d3 100644
--- a/src/lib/netlist/devices/nld_74153.cpp
+++ b/src/lib/netlist/devices/nld_74153.cpp
@@ -1,7 +1,44 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74153.c
+ * nld_74153.cpp
+ *
+ * DM74153: Dual 4-Line to 1-Line Data Selectors Multiplexers
+ *
+ * +--------------+
+ * G1 |1 ++ 16| VCC
+ * B |2 15| G2
+ * 1C3 |3 14| A
+ * 1C2 |4 74153 13| 2C3
+ * 1C1 |5 12| 2C2
+ * 1C0 |6 11| 2C1
+ * Y1 |7 10| 2C0
+ * GND |8 9| Y2
+ * +--------------+
+ *
+ *
+ * Function table
+ *
+ * +-----+-----++----+----+----+----++----+----+
+ * | B | A || C0 | C1 | C2 | C3 || G | Y |
+ * +=====+=====++====+====+====+====++====+====+
+ * | X | X || X | X | X | X || H | L |
+ * | L | L || L | X | X | X || L | L |
+ * | L | L || H | X | X | X || L | H |
+ * | L | H || X | L | X | X || L | L |
+ * | L | H || X | H | X | X || L | H |
+ * | H | L || X | X | L | X || L | L |
+ * | H | L || X | X | H | X || L | H |
+ * | H | H || X | X | X | L || L | L |
+ * | H | H || X | X | X | H || L | H |
+ * +-----+-----++----+----+----+----++----+----+
+ *
+ * A, B : Select Inputs
+ * C* : Data inputs
+ * G : Strobe
+ * Y : Output
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
@@ -69,46 +106,7 @@ namespace devices
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(74153_dip)
- {
- NETLIB_CONSTRUCTOR(74153_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_G);
- register_subalias("2", m_A.m_B);
- register_subalias("3", m_A.m_C[3]);
- register_subalias("4", m_A.m_C[2]);
- register_subalias("5", m_A.m_C[1]);
- register_subalias("6", m_A.m_C[0]);
- register_subalias("7", m_A.m_Y);
- register_subalias("8", "A.GND");
-
- register_subalias("9", m_B.m_Y);
- register_subalias("10", m_B.m_C[0]);
- register_subalias("11", m_B.m_C[1]);
- register_subalias("12", m_B.m_C[2]);
- register_subalias("13", m_B.m_C[3]);
- register_subalias("14", m_A.m_A);
-
- register_subalias("15", m_B.m_G);
- register_subalias("16", "A.VCC");
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- connect(m_A.m_A, m_B.m_A);
- connect(m_A.m_B, m_B.m_B);
- }
- //NETLIB_RESETI();
- //NETLIB_UPDATEI();
-
- protected:
- NETLIB_SUB(74153) m_A;
- NETLIB_SUB(74153) m_B;
- };
-
NETLIB_DEVICE_IMPL(74153, "TTL_74153", "+C0,+C1,+C2,+C3,+A,+B,+G,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74153_dip, "TTL_74153_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74153.h b/src/lib/netlist/devices/nld_74153.h
index 996ca5931af..b291e1dd231 100644
--- a/src/lib/netlist/devices/nld_74153.h
+++ b/src/lib/netlist/devices/nld_74153.h
@@ -1,65 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74153.h
- *
- * DM74153: Dual 4-Line to 1-Line Data Selectors Multiplexers
- *
- * +--------------+
- * G1 |1 ++ 16| VCC
- * B |2 15| G2
- * 1C3 |3 14| A
- * 1C2 |4 74153 13| 2C3
- * 1C1 |5 12| 2C2
- * 1C0 |6 11| 2C1
- * Y1 |7 10| 2C0
- * GND |8 9| Y2
- * +--------------+
- *
- *
- * Function table
- *
- * +-----+-----++----+----+----+----++----+----+
- * | B | A || C0 | C1 | C2 | C3 || G | Y |
- * +=====+=====++====+====+====+====++====+====+
- * | X | X || X | X | X | X || H | L |
- * | L | L || L | X | X | X || L | L |
- * | L | L || H | X | X | X || L | H |
- * | L | H || X | L | X | X || L | L |
- * | L | H || X | H | X | X || L | H |
- * | H | L || X | X | L | X || L | L |
- * | H | L || X | X | H | X || L | H |
- * | H | H || X | X | X | L || L | L |
- * | H | H || X | X | X | H || L | H |
- * +-----+-----++----+----+----+----++----+----+
- *
- * A, B : Select Inputs
- * C* : Data inputs
- * G : Strobe
- * Y : Output
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_74153_H_
#define NLD_74153_H_
#include "netlist/nl_setup.h"
-#define TTL_74153(name, cC0, cC1, cC2, cC3, cA, cB, cG) \
- NET_REGISTER_DEV(TTL_74153, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, C0, cC0) \
- NET_CONNECT(name, C1, cC1) \
- NET_CONNECT(name, C2, cC2) \
- NET_CONNECT(name, C3, cC3) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, G, cG)
-
-#define TTL_74153_DIP(name) \
- NET_REGISTER_DEV(TTL_74153_DIP, name)
+// usage: TTL_74153(name, cC0, cC1, cC2, cC3, cA, cB, cG)
+#define TTL_74153(...) \
+ NET_REGISTER_DEVEXT(TTL_74153, __VA_ARGS__)
#endif /* NLD_74153_H_ */
diff --git a/src/lib/netlist/devices/nld_74161.cpp b/src/lib/netlist/devices/nld_74161.cpp
index 71d6453d1b1..e60c106f76a 100644
--- a/src/lib/netlist/devices/nld_74161.cpp
+++ b/src/lib/netlist/devices/nld_74161.cpp
@@ -23,7 +23,6 @@ namespace netlist
{
NETLIB_DEVICE_IMPL(74161, "TTL_74161", "+CLK,+ENP,+ENT,+CLRQ,+LOADQ,+A,+B,+C,+D,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74161_dip, "TTL_74161_DIP", "")
// FIXME: This happens on copy/paste
NETLIB_DEVICE_IMPL(74161_fixme, "TTL_74161_FIXME", "+A,+B,+C,+D,+CLRQ,+LOADQ,+CLK,+ENP,+ENT,@VCC,@GND")
diff --git a/src/lib/netlist/devices/nld_74163.cpp b/src/lib/netlist/devices/nld_74163.cpp
index 51e3b1c767d..ceb88c809cf 100644
--- a/src/lib/netlist/devices/nld_74163.cpp
+++ b/src/lib/netlist/devices/nld_74163.cpp
@@ -23,7 +23,6 @@ namespace netlist
{
NETLIB_DEVICE_IMPL(74163, "TTL_74163", "+CLK,+ENP,+ENT,+CLRQ,+LOADQ,+A,+B,+C,+D,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74163_dip, "TTL_74163_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74164.cpp b/src/lib/netlist/devices/nld_74164.cpp
index 8bbff391157..9626232a309 100644
--- a/src/lib/netlist/devices/nld_74164.cpp
+++ b/src/lib/netlist/devices/nld_74164.cpp
@@ -7,6 +7,44 @@
* implementing this was simple.
*
*/
+/*****************************************************************************
+
+ 5/74164 8-bit parallel-out serial shift registers
+
+***********************************************************************
+
+ Connection Diagram:
+ ___ ___
+ A 1 |* u | 14 Vcc
+ B 2 | | 13 QH
+ QA 3 | | 12 QG
+ QB 4 | | 11 QF
+ QC 5 | | 10 QE
+ QD 6 | | 9 *Clear
+ GND 7 |_______| 8 Clock
+
+***********************************************************************
+ Function Table:
+ +-------------------------+----------------+
+ | Inputs | Qutputs* |
+ +-------+-------+---------+----------------+
+ | Clear | Clock | A B | QA QB ... QH |
+ +-------+-------+---------+----------------+
+ | L | X | X X | L L L |
+ | H | L | X X | QA0 QB0 QH0 |
+ | H | ^ | H H | H QAn QGn |
+ | H | ^ | L X | L QAn QGn |
+ | H | ^ | X L | L QAn QGn |
+ +-------+-------+---------+----------------+
+
+ H = High Level (steady state)
+ L = Low Level (steady state)
+ X = Don't Care
+ ^ = Transition from low to high level
+ QA0, QB0 ... QH0 = The level of QA, QB ... QH before the indicated steady-state input conditions were established.
+ QAn, QGn = The level of QA or QG before the most recent ^ transition of the clock; indicates a 1 bit shift.
+
+**********************************************************************/
#include "nld_74164.h"
#include "netlist/nl_base.h"
@@ -78,34 +116,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(74164_dip)
- {
- NETLIB_CONSTRUCTOR(74164_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_AB[0]);
- register_subalias("2", A.m_AB[1]);
- register_subalias("3", A.m_Q[0]);
- register_subalias("4", A.m_Q[1]);
- register_subalias("5", A.m_Q[2]);
- register_subalias("6", A.m_Q[3]);
- register_subalias("7", "A.GND");
-
- register_subalias("8", A.m_CLK);
- register_subalias("9", A.m_CLRQ);
- register_subalias("10", A.m_Q[4]);
- register_subalias("11", A.m_Q[5]);
- register_subalias("12", A.m_Q[6]);
- register_subalias("13", A.m_Q[7]);
- register_subalias("14", "A.VCC");
- }
- private:
- NETLIB_SUB(74164) A;
- };
-
-
NETLIB_DEVICE_IMPL(74164, "TTL_74164", "+A,+B,+CLRQ,+CLK,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74164_dip, "TTL_74164_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74164.h b/src/lib/netlist/devices/nld_74164.h
index 2efe339df2b..f732301e1f9 100644
--- a/src/lib/netlist/devices/nld_74164.h
+++ b/src/lib/netlist/devices/nld_74164.h
@@ -1,59 +1,13 @@
// license:BSD-3-Clause
// copyright-holders:Joakim Larsson Edstrom
-/*****************************************************************************
-
- 5/74164 8-bit parallel-out serial shift registers
-
-***********************************************************************
-
- Connection Diagram:
- ___ ___
- A 1 |* u | 14 Vcc
- B 2 | | 13 QH
- QA 3 | | 12 QG
- QB 4 | | 11 QF
- QC 5 | | 10 QE
- QD 6 | | 9 *Clear
- GND 7 |_______| 8 Clock
-
-***********************************************************************
- Function Table:
- +-------------------------+----------------+
- | Inputs | Qutputs* |
- +-------+-------+---------+----------------+
- | Clear | Clock | A B | QA QB ... QH |
- +-------+-------+---------+----------------+
- | L | X | X X | L L L |
- | H | L | X X | QA0 QB0 QH0 |
- | H | ^ | H H | H QAn QGn |
- | H | ^ | L X | L QAn QGn |
- | H | ^ | X L | L QAn QGn |
- +-------+-------+---------+----------------+
-
- H = High Level (steady state)
- L = Low Level (steady state)
- X = Don't Care
- ^ = Transition from low to high level
- QA0, QB0 ... QH0 = The level of QA, QB ... QH before the indicated steady-state input conditions were established.
- QAn, QGn = The level of QA or QG before the most recent ^ transition of the clock; indicates a 1 bit shift.
-
-**********************************************************************/
#ifndef NLD_74164_H_
#define NLD_74164_H_
#include "netlist/nl_setup.h"
-#define TTL_74164(name, cA, cB, cCLRQ, cCLK) \
- NET_REGISTER_DEV(TTL_74164, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, CLRQ, cCLRQ) \
- NET_CONNECT(name, CLK, cCLK)
-
-#define TTL_74164_DIP(name) \
- NET_REGISTER_DEV(TTL_74164_DIP, name)
+// usage: TTL_74164(name, cA, cB, cCLRQ, cCLK)
+#define TTL_74164(...) \
+ NET_REGISTER_DEVEXT(TTL_74164, __VA_ARGS__)
#endif /* NLD_74164_H_ */
diff --git a/src/lib/netlist/devices/nld_74165.cpp b/src/lib/netlist/devices/nld_74165.cpp
index afa5f3de90d..3db58672418 100644
--- a/src/lib/netlist/devices/nld_74165.cpp
+++ b/src/lib/netlist/devices/nld_74165.cpp
@@ -3,6 +3,25 @@
/*
* nld_74165.cpp
*
+ * 74165: Parallel-Load 8-Bit Shift Register
+ *
+ * +--------------+
+ * SH/LDQ |1 ++ 16| VCC
+ * CLK |2 15| CLKINH
+ * E |3 14| D
+ * F |4 74165 13| C
+ * G |5 12| B
+ * H |6 11| A
+ * QHQ |7 10| SER
+ * GND |8 9| QH
+ * +--------------+
+ *
+ * SH/LDQ: Shift / !Load
+ * CLKINH: Clock Inhibit
+ * SER: Serial In
+ *
+ * Naming convention attempts to follow NTE Electronics datasheet
+ *
*/
#include "nld_74165.h"
@@ -81,37 +100,8 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(74165_dip)
- {
- NETLIB_CONSTRUCTOR(74165_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_SH_LDQ);
- register_subalias("2", A.m_CLK);
- register_subalias("3", A.m_DATA[4]);
- register_subalias("4", A.m_DATA[5]);
- register_subalias("5", A.m_DATA[6]);
- register_subalias("6", A.m_DATA[7]);
- register_subalias("7", A.m_QHQ);
- register_subalias("8", "A.GND");
-
- register_subalias("9", A.m_QH);
- register_subalias("10", A.m_SER);
- register_subalias("11", A.m_DATA[0]);
- register_subalias("12", A.m_DATA[1]);
- register_subalias("13", A.m_DATA[2]);
- register_subalias("14", A.m_DATA[3]);
- register_subalias("15", A.m_CLKINH);
- register_subalias("16", "A.VCC");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(74165) A;
- };
-
// FIXME: Timing
NETLIB_DEVICE_IMPL(74165, "TTL_74165", "+CLK,+CLKINH,+SH_LDQ,+SER,+A,+B,+C,+D,+E,+F,+G,+H,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74165_dip, "TTL_74165_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74165.h b/src/lib/netlist/devices/nld_74165.h
index 51133157dbd..72e1a415342 100644
--- a/src/lib/netlist/devices/nld_74165.h
+++ b/src/lib/netlist/devices/nld_74165.h
@@ -1,52 +1,13 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_74165.h
- *
- * 74165: Parallel-Load 8-Bit Shift Register
- *
- * +--------------+
- * SH/LDQ |1 ++ 16| VCC
- * CLK |2 15| CLKINH
- * E |3 14| D
- * F |4 74165 13| C
- * G |5 12| B
- * H |6 11| A
- * QHQ |7 10| SER
- * GND |8 9| QH
- * +--------------+
- *
- * SH/LDQ: Shift / !Load
- * CLKINH: Clock Inhibit
- * SER: Serial In
- *
- * Naming convention attempts to follow NTE Electronics datasheet
- *
- */
#ifndef NLD_74165_H_
#define NLD_74165_H_
#include "netlist/nl_setup.h"
-#define TTL_74165(name, cCLK, cCLKINH, cSH_LDQ, cSER, cA, cB, cC, cD, cE, cF, cG, cH) \
- NET_REGISTER_DEV(TTL_74165, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, CLKINH, cCLKINH) \
- NET_CONNECT(name, SH_LDQ, cSH_LDQ) \
- NET_CONNECT(name, SER, cSER) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, C, cC) \
- NET_CONNECT(name, D, cD) \
- NET_CONNECT(name, E, cE) \
- NET_CONNECT(name, F, cF) \
- NET_CONNECT(name, G, cG) \
- NET_CONNECT(name, H, cH)
-
-#define TTL_74165_DIP(name) \
- NET_REGISTER_DEV(TTL_74165_DIP, name)
+// usage: TTL_74165(name, cCLK, cCLKINH, cSH_LDQ, cSER, cA, cB, cC, cD, cE, cF, cG, cH)
+#define TTL_74165(...) \
+ NET_REGISTER_DEVEXT(TTL_74165, __VA_ARGS__)
#endif /* NLD_74165_H_ */
diff --git a/src/lib/netlist/devices/nld_74166.cpp b/src/lib/netlist/devices/nld_74166.cpp
index d8da82a1e7a..467132c9451 100644
--- a/src/lib/netlist/devices/nld_74166.cpp
+++ b/src/lib/netlist/devices/nld_74166.cpp
@@ -3,6 +3,25 @@
/*
* nld_74166.cpp
*
+ * 74166: Parallel-Load 8-Bit Shift Register
+ *
+ * +--------------+
+ * SER |1 ++ 16| VCC
+ * A |2 15| SH/LDQ
+ * B |3 14| H
+ * C |4 74166 13| QH
+ * D |5 12| G
+ * CLKINH |6 11| F
+ * CLK |7 10| E
+ * GND |8 9| CLRQ
+ * +--------------+
+ *
+ * SH/LDQ: Shift / !Load
+ * CLKINH: Clock Inhibit
+ * SER: Serial In
+ *
+ * Naming convention attempts to follow Texas Instruments datasheet
+ *
*/
#include "nld_74166.h"
@@ -100,36 +119,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(74166_dip)
- {
- NETLIB_CONSTRUCTOR(74166_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_SER);
- register_subalias("2", A.m_DATA[7]);
- register_subalias("3", A.m_DATA[6]);
- register_subalias("4", A.m_DATA[5]);
- register_subalias("5", A.m_DATA[4]);
- register_subalias("6", A.m_CLKINH);
- register_subalias("7", A.m_CLK);
- register_subalias("8", "A.GND");
-
- register_subalias("9", A.m_CLRQ);
- register_subalias("10", A.m_DATA[3]);
- register_subalias("11", A.m_DATA[2]);
- register_subalias("12", A.m_DATA[1]);
- register_subalias("13", A.m_QH);
- register_subalias("14", A.m_DATA[0]);
- register_subalias("15", A.m_SH_LDQ);
- register_subalias("16", "A.VCC");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(74166) A;
- };
-
NETLIB_DEVICE_IMPL(74166, "TTL_74166", "+CLK,+CLKINH,+SH_LDQ,+SER,+A,+B,+C,+D,+E,+F,+G,+H,+CLRQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74166_dip,"TTL_74166_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74166.h b/src/lib/netlist/devices/nld_74166.h
index be9cb7fdc4c..8184c2610d3 100644
--- a/src/lib/netlist/devices/nld_74166.h
+++ b/src/lib/netlist/devices/nld_74166.h
@@ -1,53 +1,13 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_74166.h
- *
- * 74166: Parallel-Load 8-Bit Shift Register
- *
- * +--------------+
- * SER |1 ++ 16| VCC
- * A |2 15| SH/LDQ
- * B |3 14| H
- * C |4 74166 13| QH
- * D |5 12| G
- * CLKINH |6 11| F
- * CLK |7 10| E
- * GND |8 9| CLRQ
- * +--------------+
- *
- * SH/LDQ: Shift / !Load
- * CLKINH: Clock Inhibit
- * SER: Serial In
- *
- * Naming convention attempts to follow Texas Instruments datasheet
- *
- */
#ifndef NLD_74166_H_
#define NLD_74166_H_
#include "netlist/nl_setup.h"
-#define TTL_74166(name, cCLK, cCLKINH, cSH_LDQ, cSER, cA, cB, cC, cD, cE, cF, cG, cH, cCLRQ) \
- NET_REGISTER_DEV(TTL_74166, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, CLKINH, cCLKINH) \
- NET_CONNECT(name, SH_LDQ, cSH_LDQ) \
- NET_CONNECT(name, SER, cSER) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, C, cC) \
- NET_CONNECT(name, D, cD) \
- NET_CONNECT(name, E, cE) \
- NET_CONNECT(name, F, cF) \
- NET_CONNECT(name, G, cG) \
- NET_CONNECT(name, H, cH) \
- NET_CONNECT(name, CLRQ, cCLRQ)
-
-#define TTL_74166_DIP(name) \
- NET_REGISTER_DEV(TTL_74166_DIP, name)
+// usage: TTL_74166(name, cCLK, cCLKINH, cSH_LDQ, cSER, cA, cB, cC, cD, cE, cF, cG, cH, cCLRQ)
+#define TTL_74166(...) \
+ NET_REGISTER_DEVEXT(TTL_74166, __VA_ARGS__)
#endif /* NLD_74166_H_ */
diff --git a/src/lib/netlist/devices/nld_74174.cpp b/src/lib/netlist/devices/nld_74174.cpp
index 37071e190ed..cdc08aa8d8e 100644
--- a/src/lib/netlist/devices/nld_74174.cpp
+++ b/src/lib/netlist/devices/nld_74174.cpp
@@ -3,6 +3,34 @@
/*
* nld_74174.cpp
*
+ * DM74174: Hex D Flip-Flops with Clear
+ *
+ * +--------------+
+ * CLR |1 ++ 16| VCC
+ * Q1 |2 15| Q6
+ * D1 |3 14| D6
+ * D2 |4 74174 13| D5
+ * Q2 |5 12| Q5
+ * D3 |6 11| D4
+ * Q3 |7 10| Q4
+ * GND |8 9| CLK
+ * +--------------+
+ *
+ * +-----+-----+---++---+-----+
+ * | CLR | CLK | D || Q | QQ |
+ * +=====+=====+===++===+=====+
+ * | 0 | X | X || 0 | 1 |
+ * | 1 | R | 1 || 1 | 0 |
+ * | 1 | R | 0 || 0 | 1 |
+ * | 1 | 0 | X || Q0| Q0Q |
+ * +-----+-----+---++---+-----+
+ *
+ * Q0 The output logic level of Q before the indicated input conditions were established
+ *
+ * R: 0 -> 1
+ *
+ * Naming conventions follow National Semiconductor datasheet
+ *
*/
#include "nld_74174.h"
@@ -12,14 +40,14 @@ namespace netlist
{
namespace devices
{
- NETLIB_OBJECT(74174)
+ NETLIB_OBJECT(74174_GATE)
{
- NETLIB_CONSTRUCTOR(74174)
+ NETLIB_CONSTRUCTOR(74174_GATE)
, m_CLK(*this, "CLK", NETLIB_DELEGATE(clk))
- , m_Q(*this, {"Q1", "Q2", "Q3", "Q4", "Q5", "Q6"})
+ , m_Q(*this, "Q")
, m_clrq(*this, "m_clr", 0)
, m_data(*this, "m_data", 0)
- , m_D(*this, {"D1", "D2", "D3", "D4", "D5", "D6"}, NETLIB_DELEGATE(other))
+ , m_D(*this, "D", NETLIB_DELEGATE(other))
, m_CLRQ(*this, "CLRQ", NETLIB_DELEGATE(other))
, m_power_pins(*this)
{
@@ -34,18 +62,11 @@ namespace devices
NETLIB_HANDLERI(other)
{
- uint_fast8_t d = 0;
- for (std::size_t i=0; i<6; i++)
- {
- d |= (m_D[i]() << i);
- }
+ netlist_sig_t d = m_D();
m_clrq = m_CLRQ();
if (!m_clrq)
{
- for (std::size_t i=0; i<6; i++)
- {
- m_Q[i].push(0, NLTIME_FROM_NS(40));
- }
+ m_Q.push(0, NLTIME_FROM_NS(40));
m_data = 0;
} else if (d != m_data)
{
@@ -54,68 +75,95 @@ namespace devices
}
}
+ private:
NETLIB_HANDLERI(clk)
{
if (m_clrq)
{
- for (std::size_t i=0; i<6; i++)
- {
- netlist_sig_t d = (m_data >> i) & 1;
- m_Q[i].push(d, NLTIME_FROM_NS(25));
- }
+ m_Q.push(m_data, NLTIME_FROM_NS(25));
m_CLK.inactivate();
}
}
- friend class NETLIB_NAME(74174_dip);
- private:
logic_input_t m_CLK;
- object_array_t<logic_output_t, 6> m_Q;
+ logic_output_t m_Q;
state_var<netlist_sig_t> m_clrq;
- state_var<unsigned> m_data;
+ state_var<netlist_sig_t> m_data;
- object_array_t<logic_input_t, 6> m_D;
+ logic_input_t m_D;
logic_input_t m_CLRQ;
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(74174_dip)
+ NETLIB_OBJECT(74174)
{
- NETLIB_CONSTRUCTOR(74174_dip)
+ NETLIB_CONSTRUCTOR(74174)
, A(*this, "A")
+ , B(*this, "B")
+ , C(*this, "C")
+ , D(*this, "D")
+ , E(*this, "E")
+ , F(*this, "F")
{
- register_subalias("1", A.m_CLRQ);
- register_subalias("9", A.m_CLK);
-
- register_subalias("3", A.m_D[0]);
- register_subalias("2", A.m_Q[0]);
-
- register_subalias("4", A.m_D[1]);
- register_subalias("5", A.m_Q[1]);
-
- register_subalias("6", A.m_D[2]);
- register_subalias("7", A.m_Q[2]);
-
- register_subalias("11", A.m_D[3]);
- register_subalias("10", A.m_Q[3]);
-
- register_subalias("13", A.m_D[4]);
- register_subalias("12", A.m_Q[4]);
-
- register_subalias("14", A.m_D[5]);
- register_subalias("15", A.m_Q[5]);
-
- register_subalias("8", "A.GND");
- register_subalias("16", "A.VCC");
+ register_subalias("CLRQ", "A.CLRQ");
+ connect("A.CLRQ", "B.CLRQ");
+ connect("A.CLRQ", "C.CLRQ");
+ connect("A.CLRQ", "D.CLRQ");
+ connect("A.CLRQ", "E.CLRQ");
+ connect("A.CLRQ", "F.CLRQ");
+
+ register_subalias("CLK", "A.CLK");
+ connect("A.CLK", "B.CLK");
+ connect("A.CLK", "C.CLK");
+ connect("A.CLK", "D.CLK");
+ connect("A.CLK", "E.CLK");
+ connect("A.CLK", "F.CLK");
+
+ register_subalias("D1", "A.D");
+ register_subalias("Q1", "A.Q");
+
+ register_subalias("D2", "B.D");
+ register_subalias("Q2", "B.Q");
+
+ register_subalias("D3", "C.D");
+ register_subalias("Q3", "C.Q");
+
+ register_subalias("D4", "D.D");
+ register_subalias("Q4", "D.Q");
+
+ register_subalias("D5", "E.D");
+ register_subalias("Q5", "E.Q");
+
+ register_subalias("D6", "F.D");
+ register_subalias("Q6", "F.Q");
+
+ register_subalias("GND", "A.GND");
+ connect("A.GND", "B.GND");
+ connect("A.GND", "C.GND");
+ connect("A.GND", "D.GND");
+ connect("A.GND", "E.GND");
+ connect("A.GND", "F.GND");
+
+ register_subalias("VCC", "A.VCC");
+ connect("A.VCC", "B.VCC");
+ connect("A.VCC", "C.VCC");
+ connect("A.VCC", "D.VCC");
+ connect("A.VCC", "E.VCC");
+ connect("A.VCC", "F.VCC");
}
//NETLIB_RESETI() {}
private:
- NETLIB_SUB(74174) A;
+ NETLIB_SUB(74174_GATE) A;
+ NETLIB_SUB(74174_GATE) B;
+ NETLIB_SUB(74174_GATE) C;
+ NETLIB_SUB(74174_GATE) D;
+ NETLIB_SUB(74174_GATE) E;
+ NETLIB_SUB(74174_GATE) F;
};
- NETLIB_DEVICE_IMPL(74174, "TTL_74174", "+CLK,+D1,+D2,+D3,+D4,+D5,+D6,+CLRQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74174_dip,"TTL_74174_DIP", "")
+ NETLIB_DEVICE_IMPL(74174_GATE, "TTL_74174_GATE", "")
+ NETLIB_DEVICE_IMPL(74174, "TTL_74174", "+CLK,+D1,+D2,+D3,+D4,+D5,+D6,+CLRQ,@VCC,@GND")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74174.h b/src/lib/netlist/devices/nld_74174.h
index 4fe23739aad..7b41f818787 100644
--- a/src/lib/netlist/devices/nld_74174.h
+++ b/src/lib/netlist/devices/nld_74174.h
@@ -1,58 +1,17 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74174.h
- *
- * DM74174: Hex D Flip-Flops with Clear
- *
- * +--------------+
- * CLR |1 ++ 16| VCC
- * Q1 |2 15| Q6
- * D1 |3 14| D6
- * D2 |4 74174 13| D5
- * Q2 |5 12| Q5
- * D3 |6 11| D4
- * Q3 |7 10| Q4
- * GND |8 9| CLK
- * +--------------+
- *
- * +-----+-----+---++---+-----+
- * | CLR | CLK | D || Q | QQ |
- * +=====+=====+===++===+=====+
- * | 0 | X | X || 0 | 1 |
- * | 1 | R | 1 || 1 | 0 |
- * | 1 | R | 0 || 0 | 1 |
- * | 1 | 0 | X || Q0| Q0Q |
- * +-----+-----+---++---+-----+
- *
- * Q0 The output logic level of Q before the indicated input conditions were established
- *
- * R: 0 -> 1
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_74174_H_
#define NLD_74174_H_
#include "netlist/nl_setup.h"
-#define TTL_74174(name, cCLK, cD1, cD2, cD3, cD4, cD5, cD6, cCLRQ) \
- NET_REGISTER_DEV(TTL_74174, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, D1, cD1) \
- NET_CONNECT(name, D2, cD2) \
- NET_CONNECT(name, D3, cD3) \
- NET_CONNECT(name, D4, cD4) \
- NET_CONNECT(name, D5, cD5) \
- NET_CONNECT(name, D6, cD6) \
- NET_CONNECT(name, CLRQ, cCLRQ)
-
-#define TTL_74174_DIP(name) \
- NET_REGISTER_DEV(TTL_74174_DIP, name)
+// usage: TTL_74174_GATE(name)
+#define TTL_74174_GATE(...) \
+ NET_REGISTER_DEVEXT(TTL_74174_GATE, __VA_ARGS__)
+// usage: TTL_74174(name, cCLK, cD1, cD2, cD3, cD4, cD5, cD6, cCLRQ)
+#define TTL_74174(...) \
+ NET_REGISTER_DEVEXT(TTL_74174, __VA_ARGS__)
#endif /* NLD_74174_H_ */
diff --git a/src/lib/netlist/devices/nld_74175.cpp b/src/lib/netlist/devices/nld_74175.cpp
index 5f1b483e5c3..4e30785de08 100644
--- a/src/lib/netlist/devices/nld_74175.cpp
+++ b/src/lib/netlist/devices/nld_74175.cpp
@@ -1,7 +1,35 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74175.c
+ * nld_74175.cpp
+ *
+ * DM74175: Quad D Flip-Flops with Clear
+ *
+ * +--------------+
+ * CLR |1 ++ 16| VCC
+ * Q1 |2 15| Q4
+ * Q1Q |3 14| Q4Q
+ * D1 |4 74175 13| D4
+ * D2 |5 12| D3
+ * Q2Q |6 11| Q3Q
+ * Q2 |7 10| Q3
+ * GND |8 9| CLK
+ * +--------------+
+ *
+ * +-----+-----+---++---+-----+
+ * | CLR | CLK | D || Q | QQ |
+ * +=====+=====+===++===+=====+
+ * | 0 | X | X || 0 | 1 |
+ * | 1 | R | 1 || 1 | 0 |
+ * | 1 | R | 0 || 0 | 1 |
+ * | 1 | 0 | X || Q0| Q0Q |
+ * +-----+-----+---++---+-----+
+ *
+ * Q0 The output logic level of Q before the indicated input conditions were established
+ *
+ * R: 0 -> 1
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_74175.h b/src/lib/netlist/devices/nld_74175.h
index b29d4680813..0687df96947 100644
--- a/src/lib/netlist/devices/nld_74175.h
+++ b/src/lib/netlist/devices/nld_74175.h
@@ -1,37 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74175.h
- *
- * DM74175: Quad D Flip-Flops with Clear
- *
- * +--------------+
- * CLR |1 ++ 16| VCC
- * Q1 |2 15| Q4
- * Q1Q |3 14| Q4Q
- * D1 |4 74175 13| D4
- * D2 |5 12| D3
- * Q2Q |6 11| Q3Q
- * Q2 |7 10| Q3
- * GND |8 9| CLK
- * +--------------+
- *
- * +-----+-----+---++---+-----+
- * | CLR | CLK | D || Q | QQ |
- * +=====+=====+===++===+=====+
- * | 0 | X | X || 0 | 1 |
- * | 1 | R | 1 || 1 | 0 |
- * | 1 | R | 0 || 0 | 1 |
- * | 1 | 0 | X || Q0| Q0Q |
- * +-----+-----+---++---+-----+
- *
- * Q0 The output logic level of Q before the indicated input conditions were established
- *
- * R: 0 -> 1
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_74175_H_
#define NLD_74175_H_
diff --git a/src/lib/netlist/devices/nld_74192.cpp b/src/lib/netlist/devices/nld_74192.cpp
index f395e8e3df4..5e77e245f97 100644
--- a/src/lib/netlist/devices/nld_74192.cpp
+++ b/src/lib/netlist/devices/nld_74192.cpp
@@ -1,7 +1,28 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74192.c
+ * nld_74192.cpp
+ *
+ * DM74192: Synchronous 4-Bit Binary Counter with Dual Clock
+ * Decade counter
+ *
+ * FIXME: This should be merged with the 74193 which counts to 16
+ *
+ * +--------------+
+ * B |1 ++ 16| VCC
+ * QB |2 15| A
+ * QA |3 14| CLEAR
+ * CD |4 74192 13| BORROWQ
+ * CU |5 12| CARRYQ
+ * QC |6 11| LOADQ
+ * QD |7 10| C
+ * GND |8 9| D
+ * +--------------+
+ *
+ * CD: Count up
+ * CU: Count down
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_74192.h b/src/lib/netlist/devices/nld_74192.h
index 81397f355ae..30e80ad28fa 100644
--- a/src/lib/netlist/devices/nld_74192.h
+++ b/src/lib/netlist/devices/nld_74192.h
@@ -1,30 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74192.h
- *
- * DM74192: Synchronous 4-Bit Binary Counter with Dual Clock
- * Decade counter
- *
- * FIXME: This should be merged with the 74193 which counts to 16
- *
- * +--------------+
- * B |1 ++ 16| VCC
- * QB |2 15| A
- * QA |3 14| CLEAR
- * CD |4 74192 13| BORROWQ
- * CU |5 12| CARRYQ
- * QC |6 11| LOADQ
- * QD |7 10| C
- * GND |8 9| D
- * +--------------+
- *
- * CD: Count up
- * CU: Count down
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_74192_H_
#define NLD_74192_H_
diff --git a/src/lib/netlist/devices/nld_74193.cpp b/src/lib/netlist/devices/nld_74193.cpp
index 38933a89a62..40ea170087b 100644
--- a/src/lib/netlist/devices/nld_74193.cpp
+++ b/src/lib/netlist/devices/nld_74193.cpp
@@ -1,7 +1,25 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74193.c
+ * nld_74193.cpp
+ *
+ * DM74193: Synchronous 4-Bit Binary Counter with Dual Clock
+ *
+ * +--------------+
+ * B |1 ++ 16| VCC
+ * QB |2 15| A
+ * QA |3 14| CLEAR
+ * CD |4 74193 13| BORROWQ
+ * CU |5 12| CARRYQ
+ * QC |6 11| LOADQ
+ * QD |7 10| C
+ * GND |8 9| D
+ * +--------------+
+ *
+ * CD: Count up
+ * CU: Count down
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_74193.h b/src/lib/netlist/devices/nld_74193.h
index 493e6854266..5049f783016 100644
--- a/src/lib/netlist/devices/nld_74193.h
+++ b/src/lib/netlist/devices/nld_74193.h
@@ -1,27 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74193.h
- *
- * DM74193: Synchronous 4-Bit Binary Counter with Dual Clock
- *
- * +--------------+
- * B |1 ++ 16| VCC
- * QB |2 15| A
- * QA |3 14| CLEAR
- * CD |4 74193 13| BORROWQ
- * CU |5 12| CARRYQ
- * QC |6 11| LOADQ
- * QD |7 10| C
- * GND |8 9| D
- * +--------------+
- *
- * CD: Count up
- * CU: Count down
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_74193_H_
#define NLD_74193_H_
diff --git a/src/lib/netlist/devices/nld_74194.cpp b/src/lib/netlist/devices/nld_74194.cpp
index 6cd30ff648a..5eba4549a5e 100644
--- a/src/lib/netlist/devices/nld_74194.cpp
+++ b/src/lib/netlist/devices/nld_74194.cpp
@@ -3,8 +3,27 @@
/*
* nld_74194.cpp
*
+ * 74194: Parallel-Load 8-Bit Shift Register
+ *
+ * +--------------+
+ * CLRQ |1 ++ 16| VCC
+ * SRIN |2 15| QA
+ * A |3 14| QB
+ * B |4 74194 13| QC
+ * C |5 12| QD
+ * D |6 11| CLK
+ * SLIN |7 10| S1
+ * GND |8 9| S0
+ * +--------------+
+ *
+ * CLR: Clear
+ * SRIN: Shift Right Serial Input
+ * SLIN: Shift Left Serial Input
+ * CLK: Clock
+ *
*/
+
#include "nld_74194.h"
#include "netlist/nl_base.h"
diff --git a/src/lib/netlist/devices/nld_74194.h b/src/lib/netlist/devices/nld_74194.h
index 2432a6ece97..838c3c96406 100644
--- a/src/lib/netlist/devices/nld_74194.h
+++ b/src/lib/netlist/devices/nld_74194.h
@@ -1,28 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_74194.h
- *
- * 74194: Parallel-Load 8-Bit Shift Register
- *
- * +--------------+
- * CLRQ |1 ++ 16| VCC
- * SRIN |2 15| QA
- * A |3 14| QB
- * B |4 74194 13| QC
- * C |5 12| QD
- * D |6 11| CLK
- * SLIN |7 10| S1
- * GND |8 9| S0
- * +--------------+
- *
- * CLR: Clear
- * SRIN: Shift Right Serial Input
- * SLIN: Shift Left Serial Input
- * CLK: Clock
- *
- */
-
#ifndef NLD_74194_H_
#define NLD_74194_H_
diff --git a/src/lib/netlist/devices/nld_74365.cpp b/src/lib/netlist/devices/nld_74365.cpp
index 46a13a4d086..4b9f7be9afa 100644
--- a/src/lib/netlist/devices/nld_74365.cpp
+++ b/src/lib/netlist/devices/nld_74365.cpp
@@ -3,6 +3,23 @@
/*
* nld_74365.cpp
*
+ * SN74365: Hex Bus Driver with 3-State Outputs
+ *
+ * +--------------+
+ * G1Q |1 ++ 16| VCC
+ * A1 |2 15| G2Q
+ * Y1 |3 14| A6
+ * A2 |4 74365 13| Y6
+ * Y2 |5 12| A5
+ * A3 |6 11| Y5
+ * Y3 |7 10| A4
+ * GND |8 9| Y4
+ * +--------------+
+ *
+ * Naming conventions follow Texas Instruments datasheet
+ *
+ * Note: Currently the netlist system does not support proper tristate output, so this
+ * is not a "real" bus driver, it simply outputs 0 if the chip is not enabled.
*/
#include "nld_74365.h"
diff --git a/src/lib/netlist/devices/nld_74365.h b/src/lib/netlist/devices/nld_74365.h
index 1aeeddaff8d..9fc55f52243 100644
--- a/src/lib/netlist/devices/nld_74365.h
+++ b/src/lib/netlist/devices/nld_74365.h
@@ -1,27 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_74365.h
- *
- * SN74365: Hex Bus Driver with 3-State Outputs
- *
- * +--------------+
- * G1Q |1 ++ 16| VCC
- * A1 |2 15| G2Q
- * Y1 |3 14| A6
- * A2 |4 74365 13| Y6
- * Y2 |5 12| A5
- * A3 |6 11| Y5
- * Y3 |7 10| A4
- * GND |8 9| Y4
- * +--------------+
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- * Note: Currently the netlist system does not support proper tristate output, so this
- * is not a "real" bus driver, it simply outputs 0 if the chip is not enabled.
- */
-
#ifndef NLD_74365_H_
#define NLD_74365_H_
diff --git a/src/lib/netlist/devices/nld_74377.cpp b/src/lib/netlist/devices/nld_74377.cpp
index 4f2e00f229a..8d5381ce92a 100644
--- a/src/lib/netlist/devices/nld_74377.cpp
+++ b/src/lib/netlist/devices/nld_74377.cpp
@@ -1,7 +1,50 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74377.c
+ * nld_74377.cpp
+ *
+ * DM74377: Octal D Flip-Flop With Enable
+ *
+ * +--------------+
+ * /E |1 ++ 20| VCC
+ * Q0 |2 19| Q7
+ * D0 |3 18| D7
+ * D1 |4 74377 17| D6
+ * Q1 |5 16| Q6
+ * Q2 |6 15| Q5
+ * D2 |7 14| D5
+ * D3 |8 13| D4
+ * Q3 |9 12| Q4
+ * GND |10 11| CP
+ * +--------------+
+ *
+ * DM74378: Hex D Flip-Flop With Enable
+ *
+ * +--------------+
+ * /E |1 ++ 16| VCC
+ * Q0 |2 15| Q5
+ * D0 |3 14| D5
+ * D1 |4 74378 13| D4
+ * Q1 |5 12| Q4
+ * D2 |6 11| D3
+ * Q2 |7 10| Q3
+ * GND |8 9| CP
+ * +--------------+
+ *
+ * DM74379: 4-bit D Flip-Flop With Enable
+ *
+ * +--------------+
+ * /E |1 ++ 16| VCC
+ * Q0 |2 15| Q3
+ * /Q0 |3 14| /Q3
+ * D0 |4 74379 13| D3
+ * D1 |5 12| D2
+ * /Q1 |6 11| /Q2
+ * Q1 |7 10| Q2
+ * GND |8 9| CP
+ * +--------------+
+ *
+ * Naming conventions follow Motorola datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_74377.h b/src/lib/netlist/devices/nld_74377.h
index 6f5a3aed14e..9b3d2b87210 100644
--- a/src/lib/netlist/devices/nld_74377.h
+++ b/src/lib/netlist/devices/nld_74377.h
@@ -1,52 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud,Aaron Giles
-/*
- * nld_74377.h
- *
- * DM74377: Octal D Flip-Flop With Enable
- *
- * +--------------+
- * /E |1 ++ 20| VCC
- * Q0 |2 19| Q7
- * D0 |3 18| D7
- * D1 |4 74377 17| D6
- * Q1 |5 16| Q6
- * Q2 |6 15| Q5
- * D2 |7 14| D5
- * D3 |8 13| D4
- * Q3 |9 12| Q4
- * GND |10 11| CP
- * +--------------+
- *
- * DM74378: Hex D Flip-Flop With Enable
- *
- * +--------------+
- * /E |1 ++ 16| VCC
- * Q0 |2 15| Q5
- * D0 |3 14| D5
- * D1 |4 74378 13| D4
- * Q1 |5 12| Q4
- * D2 |6 11| D3
- * Q2 |7 10| Q3
- * GND |8 9| CP
- * +--------------+
- *
- * DM74379: 4-bit D Flip-Flop With Enable
- *
- * +--------------+
- * /E |1 ++ 16| VCC
- * Q0 |2 15| Q3
- * /Q0 |3 14| /Q3
- * D0 |4 74379 13| D3
- * D1 |5 12| D2
- * /Q1 |6 11| /Q2
- * Q1 |7 10| Q2
- * GND |8 9| CP
- * +--------------+
- *
- * Naming conventions follow Motorola datasheet
- *
- */
#ifndef NLD_74377_H_
#define NLD_74377_H_
diff --git a/src/lib/netlist/devices/nld_74393.cpp b/src/lib/netlist/devices/nld_74393.cpp
index 10195cee0ae..38e42475eda 100644
--- a/src/lib/netlist/devices/nld_74393.cpp
+++ b/src/lib/netlist/devices/nld_74393.cpp
@@ -1,7 +1,21 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_74393.c
+ * nld_74393.cpp
+ *
+ * DM74393: Dual 4-Stage Binary Counter
+ *
+ * +--------------+
+ * /CP |1 ++ 14| VCC
+ * MR |2 13| /CP
+ * Q0 |3 12| MR
+ * Q1 |4 74393 11| Q0
+ * Q2 |5 10| Q1
+ * Q3 |6 9| Q2
+ * GND |7 8| Q3
+ * +--------------+
+ *
+ * Naming conventions follow Motorola datasheet
*
*/
@@ -72,40 +86,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(74393_dip)
- {
- NETLIB_CONSTRUCTOR(74393_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", "A.CP");
- register_subalias("2", "A.MR");
- register_subalias("3", "A.Q0");
- register_subalias("4", "A.Q1");
- register_subalias("5", "A.Q2");
- register_subalias("6", "A.Q3");
- register_subalias("7", "A.GND");
-
- register_subalias("8", "B.Q3");
- register_subalias("9", "B.Q2");
- register_subalias("10", "B.Q1");
- register_subalias("11", "B.Q0");
- register_subalias("12", "B.MR");
- register_subalias("13", "B.CP");
- register_subalias("14", "A.VCC");
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- }
- //NETLIB_RESETI() {}
-
- private:
- NETLIB_SUB(74393) m_A;
- NETLIB_SUB(74393) m_B;
- };
-
NETLIB_DEVICE_IMPL(74393, "TTL_74393", "+CP,+MR,@VCC,@GND")
- NETLIB_DEVICE_IMPL(74393_dip, "TTL_74393_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74393.h b/src/lib/netlist/devices/nld_74393.h
index b17f63b016a..cf4d3b82932 100644
--- a/src/lib/netlist/devices/nld_74393.h
+++ b/src/lib/netlist/devices/nld_74393.h
@@ -1,37 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74393.h
- *
- * DM74393: Dual 4-Stage Binary Counter
- *
- * +--------------+
- * /CP |1 ++ 14| VCC
- * MR |2 13| /CP
- * Q0 |3 12| MR
- * Q1 |4 74393 11| Q0
- * Q2 |5 10| Q1
- * Q3 |6 9| Q2
- * GND |7 8| Q3
- * +--------------+
- *
- * Naming conventions follow Motorola datasheet
- *
- */
#ifndef NLD_74393_H_
#define NLD_74393_H_
#include "netlist/nl_setup.h"
-#define TTL_74393(name, cCP, cMR) \
- NET_REGISTER_DEV(TTL_74393, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CP, cCP) \
- NET_CONNECT(name, MR, cMR)
-
-#define TTL_74393_DIP(name) \
- NET_REGISTER_DEV(TTL_74393_DIP, name)
+// usage: TTL_74393(name, cCP, cMR)
+#define TTL_74393(...) \
+ NET_REGISTER_DEVEXT(TTL_74393, __VA_ARGS__)
#endif /* NLD_74193_H_ */
diff --git a/src/lib/netlist/devices/nld_7442.cpp b/src/lib/netlist/devices/nld_7442.cpp
deleted file mode 100644
index e25b56e60d3..00000000000
--- a/src/lib/netlist/devices/nld_7442.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-// license:GPL-2.0+
-// copyright-holders:Ryan Holtz
-/*
- * nld_7442.cpp
- *
- */
-
-#include "nld_7442.h"
-#include "netlist/nl_base.h"
-
-namespace netlist
-{
-namespace devices
-{
- static constexpr const netlist_time delay = NLTIME_FROM_NS(30); // Worst-case through 3 levels of logic
-
- // FIXME: stateless device, convert to TRUTHTABLE
- NETLIB_OBJECT(7442)
- {
- NETLIB_CONSTRUCTOR(7442)
- , m_A(*this, "A", NETLIB_DELEGATE(inputs))
- , m_B(*this, "B", NETLIB_DELEGATE(inputs))
- , m_C(*this, "C", NETLIB_DELEGATE(inputs))
- , m_D(*this, "D", NETLIB_DELEGATE(inputs))
- , m_val(*this, "m_val", 0)
- , m_last_val(*this, "m_last_val", 0)
- , m_Q(*this, {"Q0", "Q1", "Q2", "Q3", "Q4", "Q5", "Q6", "Q7", "Q8", "Q9"})
- , m_power_pins(*this)
- {
- }
-
- private:
- NETLIB_RESETI()
- {
- m_val = 0;
- m_last_val = 0;
- }
-
- NETLIB_HANDLERI(inputs)
- {
- const netlist_sig_t new_A = m_A();
- const netlist_sig_t new_B = m_B();
- const netlist_sig_t new_C = m_C();
- const netlist_sig_t new_D = m_D();
-
- m_last_val = m_val;
- m_val = static_cast<uint8_t>((new_D << 3) | (new_C << 2) | (new_B << 1) | new_A);
-
- if (m_last_val != m_val)
- {
- update_outputs();
- }
- }
-
- void update_outputs() noexcept
- {
- for (std::size_t i=0; i<10; i++)
- m_Q[i].push(i == m_val ? 0 : 1, delay);
- }
-
- logic_input_t m_A;
- logic_input_t m_B;
- logic_input_t m_C;
- logic_input_t m_D;
-
- state_var_u8 m_val;
- state_var_u8 m_last_val;
-
- object_array_t<logic_output_t, 10> m_Q;
- nld_power_pins m_power_pins;
- };
-
- NETLIB_OBJECT(7442_dip)
- {
- NETLIB_CONSTRUCTOR(7442_dip)
- , A(*this, "A")
- {
- register_subalias("1", "A.Q0");
- register_subalias("2", "A.Q1");
- register_subalias("3", "A.Q2");
- register_subalias("4", "A.Q3");
- register_subalias("5", "A.Q4");
- register_subalias("6", "A.Q5");
- register_subalias("7", "A.Q6");
- register_subalias("8", "A.GND");
-
- register_subalias("9", "A.Q7");
- register_subalias("10", "A.Q8");
- register_subalias("11", "A.Q9");
- register_subalias("12", "A.D");
- register_subalias("13", "A.C");
- register_subalias("14", "A.B");
- register_subalias("15", "A.A");
- register_subalias("16", "A.VCC");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7442) A;
- };
-
- NETLIB_DEVICE_IMPL(7442, "TTL_7442", "+A,+B,+C,+D,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7442_dip, "TTL_7442_DIP", "")
-
-} // namespace devices
-} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7442.h b/src/lib/netlist/devices/nld_7442.h
deleted file mode 100644
index faf3aa1e93b..00000000000
--- a/src/lib/netlist/devices/nld_7442.h
+++ /dev/null
@@ -1,63 +0,0 @@
-// license:GPL-2.0+
-// copyright-holders:Ryan Holtz
-/*
- * nld_7442.h
- *
- * SN7442: 4-Line BCD to 10-Line Decimal Decoder
- *
- * +--------------+
- * 0 |1 ++ 16| VCC
- * 1 |2 15| A
- * 2 |3 14| B
- * 3 |4 13| C
- * 4 |5 7442 12| D
- * 5 |6 11| 9
- * 6 |7 10| 8
- * GND |8 9| 7
- * +--------------+
- *
- * Truth Table
- *
- * +------++---+---+---+---++---+---+---+---+---+---+---+---+---+---+
- * | Num. || D | C | B | A || 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
- * +======++===+===+===+===++===+===+===+===+===+===+===+===+===+===+
- * | 0 || 0 | 0 | 0 | 0 || 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | 1 || 0 | 0 | 0 | 1 || 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | 2 || 0 | 0 | 1 | 0 || 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | 3 || 0 | 0 | 1 | 1 || 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | 4 || 0 | 1 | 0 | 0 || 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 |
- * | 5 || 0 | 1 | 0 | 1 || 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 |
- * | 6 || 0 | 1 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 |
- * | 7 || 0 | 1 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 |
- * | 8 || 1 | 0 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 |
- * | 9 || 1 | 0 | 0 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 |
- * | - || 1 | 0 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | - || 1 | 0 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | - || 1 | 1 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | - || 1 | 1 | 0 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | - || 1 | 1 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * | - || 1 | 1 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
- * +------++---+---+---+---++---+---+---+---+---+---+---+---+---+---+
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- */
-
-#ifndef NLD_7442_H_
-#define NLD_7442_H_
-
-#include "netlist/nl_setup.h"
-
-#define TTL_7442(name, cA, cB, cC, cD) \
- NET_REGISTER_DEV(TTL_7442, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, C, cC) \
- NET_CONNECT(name, D, cD)
-
-#define TTL_7442_DIP(name) \
- NET_REGISTER_DEV(TTL_7442_DIP, name)
-
-#endif /* NLD_7442_H_ */
diff --git a/src/lib/netlist/devices/nld_7448.cpp b/src/lib/netlist/devices/nld_7448.cpp
index 13a9b171258..4ed102a4671 100644
--- a/src/lib/netlist/devices/nld_7448.cpp
+++ b/src/lib/netlist/devices/nld_7448.cpp
@@ -1,7 +1,23 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_7448.c
+ * nld_7448.cpp
+ *
+ * DM7448: BCD to 7-Segment decoders/drivers
+ *
+ * +--------------+
+ * B |1 ++ 16| VCC
+ * C |2 15| f
+ * LAMP TEST |3 14| g
+ * BI/RBQ |4 7448 13| a
+ * RBI |5 12| b
+ * D |6 11| c
+ * A |7 10| d
+ * GND |8 9| e
+ * +--------------+
+ *
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
@@ -36,7 +52,6 @@ namespace netlist
m_state = 0;
}
- friend class NETLIB_NAME(7448_dip);
private:
void update_outputs(unsigned v) noexcept
{
@@ -98,36 +113,6 @@ namespace netlist
static const std::array<uint8_t, 16> tab7448;
};
- NETLIB_OBJECT(7448_dip)
- {
- NETLIB_CONSTRUCTOR(7448_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_B);
- register_subalias("2", A.m_C);
- register_subalias("3", A.m_LTQ);
- register_subalias("4", A.m_BIQ);
- register_subalias("5", A.m_RBIQ);
- register_subalias("6", A.m_D);
- register_subalias("7", A.m_A);
- register_subalias("8", "A.GND");
-
- register_subalias("9", A.m_Q[4]); // e
- register_subalias("10", A.m_Q[3]); // d
- register_subalias("11", A.m_Q[2]); // c
- register_subalias("12", A.m_Q[1]); // b
- register_subalias("13", A.m_Q[0]); // a
- register_subalias("14", A.m_Q[6]); // g
- register_subalias("15", A.m_Q[5]); // f
- register_subalias("16", "A.VCC");
- }
- private:
- NETLIB_SUB(7448) A;
- };
- #endif
-
- #if !(NL_USE_TRUTHTABLE_7448)
-
#define BITS7(b6,b5,b4,b3,b2,b1,b0) ((b6)<<6) | ((b5)<<5) | ((b4)<<4) | ((b3)<<3) | ((b2)<<2) | ((b1)<<1) | ((b0)<<0)
const std::array<uint8_t, 16> NETLIB_NAME(7448)::tab7448 =
@@ -151,7 +136,6 @@ namespace netlist
};
NETLIB_DEVICE_IMPL(7448, "TTL_7448", "+A,+B,+C,+D,+LTQ,+BIQ,+RBIQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7448_dip, "TTL_7448_DIP", "")
#endif
diff --git a/src/lib/netlist/devices/nld_7448.h b/src/lib/netlist/devices/nld_7448.h
index a4caeafed8b..670f453ac0f 100644
--- a/src/lib/netlist/devices/nld_7448.h
+++ b/src/lib/netlist/devices/nld_7448.h
@@ -1,25 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7448.h
- *
- * DM7448: BCD to 7-Segment decoders/drivers
- *
- * +--------------+
- * B |1 ++ 16| VCC
- * C |2 15| f
- * LAMP TEST |3 14| g
- * BI/RBQ |4 7448 13| a
- * RBI |5 12| b
- * D |6 11| c
- * A |7 10| d
- * GND |8 9| e
- * +--------------+
- *
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_7448_H_
#define NLD_7448_H_
@@ -28,20 +8,10 @@
#if !NL_AUTO_DEVICES
#if !(NL_USE_TRUTHTABLE_7448)
-#define TTL_7448(name, cA0, cA1, cA2, cA3, cLTQ, cBIQ, cRBIQ) \
- NET_REGISTER_DEV(TTL_7448, name) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, A, cA0) \
- NET_CONNECT(name, B, cA1) \
- NET_CONNECT(name, C, cA2) \
- NET_CONNECT(name, D, cA3) \
- NET_CONNECT(name, LTQ, cLTQ) \
- NET_CONNECT(name, BIQ, cBIQ) \
- NET_CONNECT(name, RBIQ, cRBIQ)
-
-#define TTL_7448_DIP(name) \
- NET_REGISTER_DEV(TTL_7448_DIP, name)
+// usage : TTL_7448(name, pA, pB, pC, pD, pLTQ, pBIQ, pRBIQ)
+// auto connect: VCC, GND
+#define TTL_7448(...) \
+ NET_REGISTER_DEVEXT(TTL_7448, __VA_ARGS__)
#endif
#endif
diff --git a/src/lib/netlist/devices/nld_7450.cpp b/src/lib/netlist/devices/nld_7450.cpp
index 5099ec5eea1..1c997d466df 100644
--- a/src/lib/netlist/devices/nld_7450.cpp
+++ b/src/lib/netlist/devices/nld_7450.cpp
@@ -1,7 +1,23 @@
- // license:GPL-2.0+
+// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_7450.c
+ * nld_7450.cpp
+ *
+ * DM7450: DUAL 2-WIDE 2-INPUT AND-OR-INVERT GATES (ONE GATE EXPANDABLE)
+ *
+ * +--------------+
+ * 1A |1 ++ 14| VCC
+ * 2A |2 13| 1B
+ * 2B |3 12| 1XQ
+ * 2C |4 7450 11| 1X
+ * 2D |5 10| 1D
+ * 2Y |6 9| 1C
+ * GND |7 8| 1Y
+ * +--------------+
+ * _________________
+ * Y = (A & B) | (C & D)
+ *
+ * Naming conventions follow Texas Instruments datasheet
*
*/
@@ -71,41 +87,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(7450_dip)
- {
- NETLIB_CONSTRUCTOR(7450_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_A);
- register_subalias("2", m_B.m_A);
- register_subalias("3", m_B.m_B);
- register_subalias("4", m_B.m_C);
- register_subalias("5", m_B.m_D);
- register_subalias("6", m_B.m_Q);
- register_subalias("7", "A.GND");
-
- register_subalias("8", m_A.m_Q);
- register_subalias("9", m_A.m_C);
- register_subalias("10", m_A.m_D);
- //register_subalias("11", m_1.m_X1);
- //register_subalias("12", m_1.m_X1Q);
- register_subalias("13", m_A.m_B);
- register_subalias("14", "A.VCC");
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
-
- }
- //NETLIB_RESETI();
- //NETLIB_UPDATEI();
-
- NETLIB_SUB(7450) m_A;
- NETLIB_SUB(7450) m_B;
- };
-
NETLIB_DEVICE_IMPL(7450, "TTL_7450_ANDORINVERT", "+A,+B,+C,+D,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7450_dip, "TTL_7450_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7450.h b/src/lib/netlist/devices/nld_7450.h
index 431eaaaa65d..f12d1b6d844 100644
--- a/src/lib/netlist/devices/nld_7450.h
+++ b/src/lib/netlist/devices/nld_7450.h
@@ -1,41 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7450.h
- *
- * DM7450: DUAL 2-WIDE 2-INPUT AND-OR-INVERT GATES (ONE GATE EXPANDABLE)
- *
- * +--------------+
- * 1A |1 ++ 14| VCC
- * 2A |2 13| 1B
- * 2B |3 12| 1XQ
- * 2C |4 7450 11| 1X
- * 2D |5 10| 1D
- * 2Y |6 9| 1C
- * GND |7 8| 1Y
- * +--------------+
- * _________________
- * Y = (A & B) | (C & D)
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- */
#ifndef NLD_7450_H_
#define NLD_7450_H_
#include "netlist/nl_setup.h"
-#define TTL_7450_ANDORINVERT(name, cI1, cI2, cI3, cI4) \
- NET_REGISTER_DEV(TTL_7450_ANDORINVERT, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A, cI1) \
- NET_CONNECT(name, B, cI2) \
- NET_CONNECT(name, C, cI3) \
- NET_CONNECT(name, D, cI4)
-
-#define TTL_7450_DIP(name) \
- NET_REGISTER_DEV(TTL_7450_DIP, name)
+// usage: TTL_7450_ANDORINVERT(name, cI1, cI2, cI3, cI4)
+#define TTL_7450_ANDORINVERT(...) \
+ NET_REGISTER_DEVEXT(TTL_7450_ANDORINVERT, __VA_ARGS__)
#endif /* NLD_7450_H_ */
diff --git a/src/lib/netlist/devices/nld_7473.cpp b/src/lib/netlist/devices/nld_7473.cpp
index d724ca16a3b..4a9d1ac27b3 100644
--- a/src/lib/netlist/devices/nld_7473.cpp
+++ b/src/lib/netlist/devices/nld_7473.cpp
@@ -1,7 +1,59 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_7473.c
+ * nld_7473.cpp
+ *
+ * 7473: Dual Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
+ * 7473A: Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
+ *
+ * +----------+
+ * 1CLK |1 ++ 14| 1J
+ * 1CLRQ |2 13| 1QQ
+ * 1K |3 12| 1Q
+ * VCC |4 7473 11| GND
+ * 2CLK |5 10| 2K
+ * 2CLRQ |6 9| 2Q
+ * 2J |7 8| 2QQ
+ * +----------+
+ *
+ *
+ * Function table 73
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | CLRQ| CLK | J | K || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | X | X | X || 0 | 1 |
+ * | 1 | * | 0 | 0 || Q0| Q0Q |
+ * | 1 | * | 1 | 0 || 1 | 0 |
+ * | 1 | * | 0 | 1 || 0 | 1 |
+ * | 1 | * | 1 | 1 || TOGGLE |
+ * +-----+-----+-----+---++---+-----+
+ * _
+ * * = _| |_
+ *
+ * This is positive triggered, J and K
+ * are latched during clock high and
+ * transferred when CLK falls.
+ *
+ * Function table 73A
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | CLRQ| CLK | J | K || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | X | X | X || 0 | 1 |
+ * | 1 | F | 0 | 0 || Q0| Q0Q |
+ * | 1 | F | 1 | 0 || 1 | 0 |
+ * | 1 | F | 0 | 1 || 0 | 1 |
+ * | 1 | F | 1 | 1 || TOGGLE |
+ * | 1 | 1 | X | X || Q0| Q0Q |
+ * +-----+-----+-----+---++---+-----+
+ *
+ * THe 73A is negative triggered.
+ *
+ * Naming conventions follow Texas instruments datasheet
+ *
+ * FIXME: Currently, only the 73 is implemented.
+ * The 73A uses the same model.
*
*/
@@ -85,72 +137,8 @@ namespace netlist
};
- NETLIB_OBJECT(7473_dip)
- {
- NETLIB_CONSTRUCTOR(7473_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_CLK);
- register_subalias("2", m_A.m_CLRQ);
- register_subalias("3", m_A.m_K);
- register_subalias("4", "A.VCC");
- register_subalias("5", m_B.m_CLK);
- register_subalias("6", m_B.m_CLRQ);
- register_subalias("7", m_B.m_J);
-
- register_subalias("8", m_B.m_QQ);
- register_subalias("9", m_B.m_Q);
- register_subalias("10", m_B.m_K);
- register_subalias("11", "A.GND");
- register_subalias("12", m_B.m_Q);
- register_subalias("13", m_A.m_QQ);
- register_subalias("14", m_A.m_J);
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- }
-
- private:
- NETLIB_SUB(7473) m_A;
- NETLIB_SUB(7473) m_B;
- };
-
- NETLIB_OBJECT(7473A_dip)
- {
- NETLIB_CONSTRUCTOR(7473A_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_A.m_CLK);
- register_subalias("2", m_A.m_CLRQ);
- register_subalias("3", m_A.m_K);
- register_subalias("4", "A.VCC");
- register_subalias("5", m_B.m_CLK);
- register_subalias("6", m_B.m_CLRQ);
- register_subalias("7", m_B.m_J);
-
- register_subalias("8", m_B.m_QQ);
- register_subalias("9", m_B.m_Q);
- register_subalias("10", m_B.m_K);
- register_subalias("11", "A.GND");
- register_subalias("12", m_B.m_Q);
- register_subalias("13", m_A.m_QQ);
- register_subalias("14", m_A.m_J);
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- }
-
- private:
- NETLIB_SUB(7473A) m_A;
- NETLIB_SUB(7473A) m_B;
- };
-
NETLIB_DEVICE_IMPL(7473, "TTL_7473", "+CLK,+J,+K,+CLRQ,@VCC,@GND")
NETLIB_DEVICE_IMPL(7473A, "TTL_7473A", "+CLK,+J,+K,+CLRQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7473_dip, "TTL_7473_DIP", "")
- NETLIB_DEVICE_IMPL(7473A_dip, "TTL_7473A_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7473.h b/src/lib/netlist/devices/nld_7473.h
index e0dc8bdb428..0ba195d4476 100644
--- a/src/lib/netlist/devices/nld_7473.h
+++ b/src/lib/netlist/devices/nld_7473.h
@@ -1,84 +1,16 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7473.h
- *
- * 7473: Dual Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
- * 7473A: Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
- *
- * +----------+
- * 1CLK |1 ++ 14| 1J
- * 1CLRQ |2 13| 1QQ
- * 1K |3 12| 1Q
- * VCC |4 7473 11| GND
- * 2CLK |5 10| 2K
- * 2CLRQ |6 9| 2Q
- * 2J |7 8| 2QQ
- * +----------+
- *
- *
- * Function table 73
- *
- * +-----+-----+-----+---++---+-----+
- * | CLRQ| CLK | J | K || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | X | X | X || 0 | 1 |
- * | 1 | * | 0 | 0 || Q0| Q0Q |
- * | 1 | * | 1 | 0 || 1 | 0 |
- * | 1 | * | 0 | 1 || 0 | 1 |
- * | 1 | * | 1 | 1 || TOGGLE |
- * +-----+-----+-----+---++---+-----+
- * _
- * * = _| |_
- *
- * This is positive triggered, J and K
- * are latched during clock high and
- * transferred when CLK falls.
- *
- * Function table 73A
- *
- * +-----+-----+-----+---++---+-----+
- * | CLRQ| CLK | J | K || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | X | X | X || 0 | 1 |
- * | 1 | F | 0 | 0 || Q0| Q0Q |
- * | 1 | F | 1 | 0 || 1 | 0 |
- * | 1 | F | 0 | 1 || 0 | 1 |
- * | 1 | F | 1 | 1 || TOGGLE |
- * | 1 | 1 | X | X || Q0| Q0Q |
- * +-----+-----+-----+---++---+-----+
- *
- * THe 73A is negative triggered.
- *
- * Naming conventions follow Texas instruments datasheet
- *
- * FIXME: Currently, only the 73 is implemented.
- * The 73A uses the same model.
- *
- */
#ifndef NLD_7473_H_
#define NLD_7473_H_
#include "netlist/nl_setup.h"
-#define TTL_7473(name, cCLK, cJ, cK, cCLRQ) \
- NET_REGISTER_DEV(TTL_7473, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, J, cJ) \
- NET_CONNECT(name, K, cK) \
- NET_CONNECT(name, CLRQ, cCLRQ)
+// usage: TTL_7473(name, cCLK, cJ, cK, cCLRQ)
+#define TTL_7473(...) \
+ NET_REGISTER_DEVEXT(TTL_7473, __VA_ARGS__)
-#define TTL_7473A(name, cCLK, cJ, cK, cCLRQ) \
- TTL_7473(name, cCLK, cJ, cK, cCLRQ)
-
-#define TTL_7473_DIP(name) \
- NET_REGISTER_DEV(TTL_7473_DIP, name)
-
-
-#define TTL_7473A_DIP(name) \
- NET_REGISTER_DEV(TTL_7473A_DIP, name)
+#define TTL_7473A(...) \
+ TTL_7473(__VA_ARGS__)
#endif /* NLD_7473_H_ */
diff --git a/src/lib/netlist/devices/nld_7474.cpp b/src/lib/netlist/devices/nld_7474.cpp
index ac01a769f1e..2bf97703374 100644
--- a/src/lib/netlist/devices/nld_7474.cpp
+++ b/src/lib/netlist/devices/nld_7474.cpp
@@ -2,8 +2,42 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_7474.c
+ * nld_7474.cpp
*
+ * DM7474: Dual Positive-Edge-Triggered D Flip-Flops
+ * with Preset, Clear and Complementary Outputs
+ *
+ * +--------------+
+ * CLR1 |1 ++ 14| VCC
+ * D1 |2 13| CLR2
+ * CLK1 |3 12| D2
+ * PR1 |4 7474 11| CLK2
+ * Q1 |5 10| PR2
+ * Q1Q |6 9| Q2
+ * GND |7 8| Q2Q
+ * +--------------+
+ *
+ * +-----+-----+-----+---++---+-----+
+ * | PR | CLR | CLK | D || Q | QQ |
+ * +=====+=====+=====+===++===+=====+
+ * | 0 | 1 | X | X || 1 | 0 |
+ * | 1 | 0 | X | X || 0 | 1 |
+ * | 0 | 0 | X | X || 1 | 1 | (*)
+ * | 1 | 1 | R | 1 || 1 | 0 |
+ * | 1 | 1 | R | 0 || 0 | 1 |
+ * | 1 | 1 | 0 | X || Q0| Q0Q |
+ * +-----+-----+-----+---++---+-----+
+ *
+ * (*) This configuration is not stable, i.e. it will not persist
+ * when either the preset and or clear inputs return to their inactive (high) level
+ *
+ * Q0 The output logic level of Q before the indicated input conditions were established
+ *
+ * R: 0 -. 1
+ *
+ * Naming conventions follow National Semiconductor datasheet
+ *
+ * FIXME: Check that (*) is emulated properly
*/
#include "nld_7474.h"
@@ -82,41 +116,7 @@ namespace netlist
}
};
- NETLIB_OBJECT(7474_dip)
- {
- NETLIB_CONSTRUCTOR(7474_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", "A.CLRQ");
- register_subalias("2", "A.D");
- register_subalias("3", "A.CLK");
- register_subalias("4", "A.PREQ");
- register_subalias("5", "A.Q");
- register_subalias("6", "A.QQ");
- register_subalias("7", "A.GND");
-
- register_subalias("8", "B.QQ");
- register_subalias("9", "B.Q");
- register_subalias("10", "B.PREQ");
- register_subalias("11", "B.CLK");
- register_subalias("12", "B.D");
- register_subalias("13", "B.CLRQ");
- register_subalias("14", "A.VCC");
-
- connect("A.GND", "B.GND");
- connect("A.VCC", "B.VCC");
- }
- //NETLIB_UPDATEI();
- //NETLIB_RESETI();
-
- private:
- NETLIB_SUB(7474) m_A;
- NETLIB_SUB(7474) m_B;
- };
-
NETLIB_DEVICE_IMPL(7474, "TTL_7474", "+CLK,+D,+CLRQ,+PREQ,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7474_dip, "TTL_7474_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7474.h b/src/lib/netlist/devices/nld_7474.h
index ccf75b42c6b..d44a2759e67 100644
--- a/src/lib/netlist/devices/nld_7474.h
+++ b/src/lib/netlist/devices/nld_7474.h
@@ -1,59 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7474.h
- *
- * DM7474: Dual Positive-Edge-Triggered D Flip-Flops
- * with Preset, Clear and Complementary Outputs
- *
- * +--------------+
- * CLR1 |1 ++ 14| VCC
- * D1 |2 13| CLR2
- * CLK1 |3 12| D2
- * PR1 |4 7474 11| CLK2
- * Q1 |5 10| PR2
- * Q1Q |6 9| Q2
- * GND |7 8| Q2Q
- * +--------------+
- *
- * +-----+-----+-----+---++---+-----+
- * | PR | CLR | CLK | D || Q | QQ |
- * +=====+=====+=====+===++===+=====+
- * | 0 | 1 | X | X || 1 | 0 |
- * | 1 | 0 | X | X || 0 | 1 |
- * | 0 | 0 | X | X || 1 | 1 | (*)
- * | 1 | 1 | R | 1 || 1 | 0 |
- * | 1 | 1 | R | 0 || 0 | 1 |
- * | 1 | 1 | 0 | X || Q0| Q0Q |
- * +-----+-----+-----+---++---+-----+
- *
- * (*) This configuration is not stable, i.e. it will not persist
- * when either the preset and or clear inputs return to their inactive (high) level
- *
- * Q0 The output logic level of Q before the indicated input conditions were established
- *
- * R: 0 -. 1
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- * FIXME: Check that (*) is emulated properly
- */
#ifndef NLD_7474_H_
#define NLD_7474_H_
#include "netlist/nl_setup.h"
-#define TTL_7474(name, cCLK, cD, cCLRQ, cPREQ) \
- NET_REGISTER_DEV(TTL_7474, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, D, cD) \
- NET_CONNECT(name, CLRQ, cCLRQ) \
- NET_CONNECT(name, PREQ, cPREQ)
-
-#define TTL_7474_DIP(name) \
- NET_REGISTER_DEV(TTL_7474_DIP, name)
+// usage: TTL_7474(name, cCLK, cD, cCLRQ, cPREQ)
+#define TTL_7474(...) \
+ NET_REGISTER_DEVEXT(TTL_7474, __VA_ARGS__)
#endif /* NLD_7474_H_ */
diff --git a/src/lib/netlist/devices/nld_7475.cpp b/src/lib/netlist/devices/nld_7475.cpp
index e80326c8cb1..785906e7b9b 100644
--- a/src/lib/netlist/devices/nld_7475.cpp
+++ b/src/lib/netlist/devices/nld_7475.cpp
@@ -4,6 +4,34 @@
* nld_7475.cpp
*
* TODO: Correct timing for clock-induced state changes, rather than assuming timing is always due to data-induced state changes
+ *
+ * 7475: 4-Bit Bistable Latches with Complementary Outputs
+ * 7477: 4-Bit Bistable Latches
+ *
+ * +----------+ +----------+
+ * 1QQ |1 ++ 16| 1Q 1D |1 ++ 14| 1Q
+ * 1D |2 15| 2Q 2D |2 13| 2Q
+ * 2D |3 14| 2QQ 3C4C |3 12| 1C2C
+ * 3C4C |4 7475 13| 1C2C VCC |4 7477 11| GND
+ * VCC |5 12| GND 3D |5 10| NC
+ * 3D |6 11| 3QQ 4D |6 9| 3Q
+ * 4D |7 10| 3Q NC |7 8| 4Q
+ * 4QQ |8 9| 4Q +----------+
+ * +----------+
+ *
+ *
+ * Function table
+ *
+ * +---+---++---+-----+
+ * | D | C || Q | QQ |
+ * +===+===++===+=====+
+ * | 0 | 1 || 0 | 1 |
+ * | 1 | 1 || 1 | 0 |
+ * | X | 0 || Q0| Q0Q |
+ * +---+---++---+-----+
+ *
+ * Naming conventions follow Texas instruments datasheet
+ *
*/
#include "nld_7475.h"
@@ -13,197 +41,62 @@ namespace netlist
{
namespace devices
{
- NETLIB_OBJECT(7477)
+ template<bool _HasQQ>
+ NETLIB_OBJECT(7475_GATE_BASE)
{
- NETLIB_CONSTRUCTOR(7477)
- , m_C1C2(*this, "C1C2", NETLIB_DELEGATE(inputs))
- , m_C3C4(*this, "C3C4", NETLIB_DELEGATE(inputs))
- , m_last_Q(*this, "m_last_Q", 0)
- , m_D(*this, {"D1", "D2", "D3", "D4"}, NETLIB_DELEGATE(inputs))
- , m_Q(*this, {"Q1", "Q2", "Q3", "Q4"})
+ NETLIB_CONSTRUCTOR(7475_GATE_BASE)
+ , m_D(*this, "D", NETLIB_DELEGATE(inputs))
+ , m_CLK(*this, "CLK", NETLIB_DELEGATE(clk))
+ , m_Q(*this, "Q")
+ , m_QQ(*this, "QQ")
+ , m_nextD(*this, "m_nextD", 0)
, m_power_pins(*this)
{
- register_subalias("Q1", m_Q[0]);
}
NETLIB_RESETI()
{
- m_last_Q = 0;
+ m_CLK.set_state(logic_t::STATE_INP_LH);
+ m_nextD = 0;
}
- NETLIB_HANDLERI(inputs)
+ NETLIB_HANDLERI(clk)
{
- netlist_sig_t c1c2 = m_C1C2();
- netlist_sig_t c3c4 = m_C3C4();
- if (c1c2 && c3c4)
- {
- update_outputs(0, 4);
- }
- else if (c1c2)
- {
- update_outputs(0, 2);
- }
- else if (c3c4)
- {
- update_outputs(2, 4);
- }
-
+ newstate(m_nextD, !m_nextD);
+ m_CLK.inactivate();
}
- void update_outputs(std::size_t start, std::size_t end)
+ NETLIB_HANDLERI(inputs)
{
- for (std::size_t i=start; i<end; i++)
- {
- netlist_sig_t d = m_D[i]();
- if (d != ((m_last_Q >> i) & 1))
- m_Q[i].push(d, d != 0 ? NLTIME_FROM_NS(30) : NLTIME_FROM_NS(25));
- m_last_Q &= ~(1 << i);
- m_last_Q |= d << i;
- }
+ m_nextD = m_D();
+ m_CLK.activate_lh();
}
- friend class NETLIB_NAME(7477_dip);
- friend class NETLIB_NAME(7475_dip);
- // FIXME: needs cleanup
- friend class NETLIB_NAME(7475);
private:
- logic_input_t m_C1C2;
- logic_input_t m_C3C4;
- state_var<unsigned> m_last_Q;
- object_array_t<logic_input_t, 4> m_D;
- object_array_t<logic_output_t, 4> m_Q;
- nld_power_pins m_power_pins;
- };
-
- NETLIB_OBJECT(7475)
- {
- NETLIB_CONSTRUCTOR(7475)
- , m_C1C2(*this, "C1C2", NETLIB_DELEGATE(inputs))
- , m_C3C4(*this, "C3C4", NETLIB_DELEGATE(inputs))
- , m_last_Q(*this, "m_last_Q", 0)
- , m_D(*this, {"D1", "D2", "D3", "D4"}, NETLIB_DELEGATE(inputs))
- , m_Q(*this, {"Q1", "Q2", "Q3", "Q4"})
- , m_QQ(*this, {"QQ1", "QQ2", "QQ3", "QQ4"})
- , m_power_pins(*this)
- {
- register_subalias("Q1", m_Q[0]);
- }
-
- NETLIB_RESETI()
- {
- m_last_Q = 0;
- }
-
- NETLIB_HANDLERI(inputs)
- {
- unsigned start_q = m_last_Q;
-
- netlist_sig_t c1c2 = m_C1C2();
- netlist_sig_t c3c4 = m_C3C4();
- if (c1c2 && c3c4)
- {
- update_outputs(0, 4);
- }
- else if (c1c2)
- {
- update_outputs(0, 2);
- }
- else if (c3c4)
- {
- update_outputs(2, 4);
- }
+ logic_input_t m_D;
+ logic_input_t m_CLK;
+ logic_output_t m_Q;
+ logic_output_t m_QQ;
- for (std::size_t i=0; i<4; i++)
- {
- unsigned last_bit = (m_last_Q >> i) & 1;
- unsigned start_bit = (start_q >> i) & 1;
- if (last_bit != start_bit)
- m_QQ[i].push(last_bit ^ 1, last_bit != 0 ? NLTIME_FROM_NS(15) : NLTIME_FROM_NS(40));
- }
- }
+ state_var<netlist_sig_t> m_nextD;
- void update_outputs(std::size_t start, std::size_t end)
- {
- for (std::size_t i=start; i<end; i++)
- {
- netlist_sig_t d = m_D[i]();
- if (d != ((m_last_Q >> i) & 1))
- m_Q[i].push(d, d != 0 ? NLTIME_FROM_NS(30) : NLTIME_FROM_NS(25));
- m_last_Q &= ~(1 << i);
- m_last_Q |= d << i;
- }
- }
-
- friend class NETLIB_NAME(7477_dip);
- friend class NETLIB_NAME(7475_dip);
- private:
- logic_input_t m_C1C2;
- logic_input_t m_C3C4;
- state_var<unsigned> m_last_Q;
- object_array_t<logic_input_t, 4> m_D;
- object_array_t<logic_output_t, 4> m_Q;
- object_array_t<logic_output_t, 4> m_QQ;
nld_power_pins m_power_pins;
- };
- NETLIB_OBJECT(7475_dip)
- {
- NETLIB_CONSTRUCTOR(7475_dip)
- , A(*this, "A")
+ void newstate(const netlist_sig_t stateQ, const netlist_sig_t stateQQ)
{
- register_subalias("1", A.m_QQ[0]);
- register_subalias("2", A.m_D[0]);
- register_subalias("3", A.m_D[1]);
- register_subalias("4", A.m_C3C4);
- register_subalias("5", "A.VCC");
- register_subalias("6", A.m_D[2]);
- register_subalias("7", A.m_D[3]);
- register_subalias("8", A.m_QQ[3]);
-
- register_subalias("9", A.m_Q[3]);
- register_subalias("10", A.m_Q[2]);
- register_subalias("11", A.m_QQ[2]);
- register_subalias("12", "A.GND");
- register_subalias("13", A.m_C1C2);
- register_subalias("14", A.m_QQ[1]);
- register_subalias("15", A.m_Q[1]);
- register_subalias("16", A.m_Q[0]);
+ // 0: High-to-low 40 ns, 1: Low-to-high 25 ns
+ static constexpr const std::array<netlist_time, 2> delay = { NLTIME_FROM_NS(40), NLTIME_FROM_NS(25) };
+ m_Q.push(stateQ, delay[stateQ]);
+ if (_HasQQ)
+ m_QQ.push(stateQQ, delay[stateQQ]);
}
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7475) A;
};
- NETLIB_OBJECT(7477_dip)
- {
- NETLIB_CONSTRUCTOR(7477_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_D[0]);
- register_subalias("2", A.m_D[1]);
- register_subalias("3", A.m_C3C4);
- register_subalias("4", "A.VCC");
- register_subalias("5", A.m_D[2]);
- register_subalias("6", A.m_D[3]);
- //register_subalias("7", ); ==> NC
-
- register_subalias("8", A.m_Q[3]);
- register_subalias("9", A.m_Q[2]);
- //register_subalias("10", ); ==> NC
- register_subalias("11", "A.GND");
- register_subalias("12", A.m_C1C2);
- register_subalias("13", A.m_Q[1]);
- register_subalias("14", A.m_Q[0]);
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7477) A;
- };
+ using NETLIB_NAME(7475_GATE) = NETLIB_NAME(7475_GATE_BASE)<true>;
+ using NETLIB_NAME(7477_GATE) = NETLIB_NAME(7475_GATE_BASE)<false>;
- NETLIB_DEVICE_IMPL(7475, "TTL_7475", "")
- NETLIB_DEVICE_IMPL(7475_dip, "TTL_7475_DIP", "")
- NETLIB_DEVICE_IMPL(7477, "TTL_7477", "")
- NETLIB_DEVICE_IMPL(7477_dip, "TTL_7477_DIP", "")
+ NETLIB_DEVICE_IMPL(7475_GATE, "TTL_7475_GATE", "")
+ NETLIB_DEVICE_IMPL(7477_GATE, "TTL_7477_GATE", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7475.h b/src/lib/netlist/devices/nld_7475.h
index 78ece9ff443..0e44886f7de 100644
--- a/src/lib/netlist/devices/nld_7475.h
+++ b/src/lib/netlist/devices/nld_7475.h
@@ -1,64 +1,15 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_7475.h
- *
- * 7475: 4-Bit Bistable Latches with Complementary Outputs
- * 7477: 4-Bit Bistable Latches
- *
- * +----------+ +----------+
- * 1QQ |1 ++ 16| 1Q 1D |1 ++ 14| 1Q
- * 1D |2 15| 2Q 2D |2 13| 2Q
- * 2D |3 14| 2QQ 3C4C |3 12| 1C2C
- * 3C4C |4 7475 13| 1C2C VCC |4 7477 11| GND
- * VCC |5 12| GND 3D |5 10| NC
- * 3D |6 11| 3QQ 4D |6 9| 3Q
- * 4D |7 10| 3Q NC |7 8| 4Q
- * 4QQ |8 9| 4Q +----------+
- * +----------+
- *
- *
- * Function table
- *
- * +---+---++---+-----+
- * | D | C || Q | QQ |
- * +===+===++===+=====+
- * | 0 | 1 || 0 | 1 |
- * | 1 | 1 || 1 | 0 |
- * | X | 0 || Q0| Q0Q |
- * +---+---++---+-----+
- *
- * Naming conventions follow Texas instruments datasheet
- *
- */
#ifndef NLD_7475_H_
#define NLD_7475_H_
#include "netlist/nl_setup.h"
-#define PARAMS_7475_7477(name, cC1C2, cC3C4, cD1, cD2, cD3, cD4) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, C1C2, cC1C2) \
- NET_CONNECT(name, C3C4, cC3C4) \
- NET_CONNECT(name, D1, cD1) \
- NET_CONNECT(name, D2, cD2) \
- NET_CONNECT(name, D3, cD3) \
- NET_CONNECT(name, D4, cD4)
+#define TTL_7475_GATE(...) \
+ NET_REGISTER_DEVEXT(TTL_7475_GATE, __VA_ARGS__)
-#define TTL_7475(name, cC1C2, cC3C4, cD1, cD2, cD3, cD4) \
- NET_REGISTER_DEV(TTL_7475, name) \
- PARAMS_7475_7477(name, cC1C2, cC3C4, cD1, cD2, cD3, cD4)
-
-#define TTL_7477(name, cC1C2, cC3C4, cD1, cD2, cD3, cD4) \
- NET_REGISTER_DEV(TTL_7477, name) \
- PARAMS_7475_7477(name, cC1C2, cC3C4, cD1, cD2, cD3, cD4)
-
-#define TTL_7475_DIP(name) \
- NET_REGISTER_DEV(TTL_7475_DIP, name)
-
-#define TTL_7477_DIP(name) \
- NET_REGISTER_DEV(TTL_7477_DIP, name)
+#define TTL_7477_GATE(...) \
+ NET_REGISTER_DEVEXT(TTL_7477_GATE, __VA_ARGS__)
#endif /* NLD_7475_H_ */
diff --git a/src/lib/netlist/devices/nld_7483.cpp b/src/lib/netlist/devices/nld_7483.cpp
index a38c6123e7d..08905727ef4 100644
--- a/src/lib/netlist/devices/nld_7483.cpp
+++ b/src/lib/netlist/devices/nld_7483.cpp
@@ -1,7 +1,26 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_7483.c
+ * nld_7483.cpp
+ *
+ * DM7483: 4-Bit Binary Adder with Fast Carry
+ *
+ * +--------------+
+ * A4 |1 ++ 16| B4
+ * S3 |2 15| S4
+ * A3 |3 14| C4
+ * B3 |4 7483 13| C0
+ * VCC |5 12| GND
+ * S2 |6 11| B1
+ * B2 |7 10| A1
+ * A2 |8 9| S1
+ * +--------------+
+ *
+ * S = (A + B + C0) & 0x0f
+ *
+ * C4 = (A + B + C) > 15 ? 1 : 0
+ *
+ * Naming conventions follow Fairchild Semiconductor datasheet
*
*/
@@ -40,7 +59,6 @@ namespace netlist
m_lastr = 0;
}
- friend class NETLIB_NAME(7483_dip);
private:
NETLIB_HANDLERI(c0)
{
@@ -92,36 +110,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(7483_dip)
- {
- NETLIB_CONSTRUCTOR(7483_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_A4);
- register_subalias("2", A.m_S3);
- register_subalias("3", A.m_A3);
- register_subalias("4", A.m_B3);
- register_subalias("5", "A.VCC");
- register_subalias("6", A.m_S2);
- register_subalias("7", A.m_B2);
- register_subalias("8", A.m_A2);
-
- register_subalias("9", A.m_S1);
- register_subalias("10", A.m_A1);
- register_subalias("11", A.m_B1);
- register_subalias("12", "A.GND");
- register_subalias("13", A.m_C0);
- register_subalias("14", A.m_C4);
- register_subalias("15", A.m_S4);
- register_subalias("16", A.m_B4);
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7483) A;
- };
-
NETLIB_DEVICE_IMPL(7483, "TTL_7483", "+A1,+A2,+A3,+A4,+B1,+B2,+B3,+B4,+C0,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7483_dip, "TTL_7483_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7483.h b/src/lib/netlist/devices/nld_7483.h
index fba46f32457..a8751f2a7c5 100644
--- a/src/lib/netlist/devices/nld_7483.h
+++ b/src/lib/netlist/devices/nld_7483.h
@@ -1,49 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7483.h
- *
- * DM7483: 4-Bit Binary Adder with Fast Carry
- *
- * +--------------+
- * A4 |1 ++ 16| B4
- * S3 |2 15| S4
- * A3 |3 14| C4
- * B3 |4 7483 13| C0
- * VCC |5 12| GND
- * S2 |6 11| B1
- * B2 |7 10| A1
- * A2 |8 9| S1
- * +--------------+
- *
- * S = (A + B + C0) & 0x0f
- *
- * C4 = (A + B + C) > 15 ? 1 : 0
- *
- * Naming conventions follow Fairchild Semiconductor datasheet
- *
- */
#ifndef NLD_7483_H_
#define NLD_7483_H_
#include "netlist/nl_setup.h"
-#define TTL_7483(name, cA1, cA2, cA3, cA4, cB1, cB2, cB3, cB4, cCI) \
- NET_REGISTER_DEV(TTL_7483, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A1, cA1) \
- NET_CONNECT(name, A2, cA2) \
- NET_CONNECT(name, A3, cA3) \
- NET_CONNECT(name, A4, cA4) \
- NET_CONNECT(name, B1, cB1) \
- NET_CONNECT(name, B2, cB2) \
- NET_CONNECT(name, B3, cB3) \
- NET_CONNECT(name, B4, cB4) \
- NET_CONNECT(name, C0, cCI)
-
-#define TTL_7483_DIP(name) \
- NET_REGISTER_DEV(TTL_7483_DIP, name)
+// usage: TTL_7483(name, cA1, cA2, cA3, cA4, cB1, cB2, cB3, cB4, cCI)
+#define TTL_7483(...) \
+ NET_REGISTER_DEVEXT(TTL_7483, __VA_ARGS__)
#endif /* NLD_7483_H_ */
diff --git a/src/lib/netlist/devices/nld_7485.cpp b/src/lib/netlist/devices/nld_7485.cpp
index 0fa0bc982a2..0d960ac9006 100644
--- a/src/lib/netlist/devices/nld_7485.cpp
+++ b/src/lib/netlist/devices/nld_7485.cpp
@@ -3,6 +3,23 @@
/*
* nld_7485.cpp
*
+ * FIXME: Truthtable candidate
+ *
+ * DM7485: 4-bit Magnitude Comparators
+ *
+ * +------------+
+ * B3 |1 ++ 16| VCC
+ * LTIN |2 15| A3
+ * EQIN |3 14| B2
+ * GTIN |4 7485 13| A2
+ * GTOUT |5 12| A1
+ * EQOUT |6 11| B1
+ * LTOUT |7 10| A0
+ * GND |8 9| B0
+ * +------------+
+ *
+ * Naming convention attempts to follow Texas Instruments datasheet
+ *
*/
#include "nld_7485.h"
@@ -27,9 +44,6 @@ namespace netlist
{
}
- void update_outputs(unsigned gt, unsigned lt, unsigned eq);
-
- friend class NETLIB_NAME(7485_dip);
private:
// FIXME: Timing
NETLIB_HANDLERI(inputs)
@@ -62,6 +76,13 @@ namespace netlist
update_outputs(1, 1, 0);
}
+ void update_outputs(unsigned gt, unsigned lt, unsigned eq)
+ {
+ m_GTOUT.push(gt, NLTIME_FROM_NS(23));
+ m_LTOUT.push(lt, NLTIME_FROM_NS(23));
+ m_EQOUT.push(eq, NLTIME_FROM_NS(23));
+ }
+
object_array_t<logic_input_t, 4> m_A;
object_array_t<logic_input_t, 4> m_B;
logic_input_t m_LTIN;
@@ -73,44 +94,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(7485_dip)
- {
- NETLIB_CONSTRUCTOR(7485_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_B[3]);
- register_subalias("2", A.m_LTIN);
- register_subalias("3", A.m_EQIN);
- register_subalias("4", A.m_GTIN);
- register_subalias("5", A.m_GTOUT);
- register_subalias("6", A.m_EQOUT);
- register_subalias("7", A.m_LTOUT);
- register_subalias("8", "A.GND");
-
- register_subalias("9", A.m_B[0]);
- register_subalias("10", A.m_A[0]);
- register_subalias("11", A.m_B[1]);
- register_subalias("12", A.m_A[1]);
- register_subalias("13", A.m_A[2]);
- register_subalias("14", A.m_B[2]);
- register_subalias("15", A.m_A[3]);
- register_subalias("16", "A.VCC");
-
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7485) A;
- };
-
- void NETLIB_NAME(7485)::update_outputs(unsigned gt, unsigned lt, unsigned eq)
- {
- m_GTOUT.push(gt, NLTIME_FROM_NS(23));
- m_LTOUT.push(lt, NLTIME_FROM_NS(23));
- m_EQOUT.push(eq, NLTIME_FROM_NS(23));
- }
-
NETLIB_DEVICE_IMPL(7485, "TTL_7485", "+A0,+A1,+A2,+A3,+B0,+B1,+B2,+B3,+LTIN,+EQIN,+GTIN,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7485_dip, "TTL_7485_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7485.h b/src/lib/netlist/devices/nld_7485.h
index d8fcb5c7701..1211c47c4d5 100644
--- a/src/lib/netlist/devices/nld_7485.h
+++ b/src/lib/netlist/devices/nld_7485.h
@@ -1,47 +1,13 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_7485.h
- *
- * DM7485: 4-bit Magnitude Comparators
- *
- * +------------+
- * B3 |1 ++ 16| VCC
- * LTIN |2 15| A3
- * EQIN |3 14| B2
- * GTIN |4 7485 13| A2
- * GTOUT |5 12| A1
- * EQOUT |6 11| B1
- * LTOUT |7 10| A0
- * GND |8 9| B0
- * +------------+
- *
- * Naming convention attempts to follow Texas Instruments datasheet
- *
- */
#ifndef NLD_7485_H_
#define NLD_7485_H_
#include "netlist/nl_setup.h"
-#define TTL_7485(name, cA0, cA1, cA2, cA3, cB0, cB1, cB2, cB3, cLTIN, cEQIN, cGTIN) \
- NET_REGISTER_DEV(TTL_7485, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A0, cA0) \
- NET_CONNECT(name, A1, cA1) \
- NET_CONNECT(name, A2, cA2) \
- NET_CONNECT(name, A3, cA3) \
- NET_CONNECT(name, B0, cB0) \
- NET_CONNECT(name, B1, cB1) \
- NET_CONNECT(name, B2, cB2) \
- NET_CONNECT(name, B3, cB3) \
- NET_CONNECT(name, LTIN, cLTIN) \
- NET_CONNECT(name, EQIN, cEQIN) \
- NET_CONNECT(name, GTIN, cGTIN)
-
-#define TTL_7485_DIP(name) \
- NET_REGISTER_DEV(TTL_7485_DIP, name)
+// usage: TTL_7485(name, cA0, cA1, cA2, cA3, cB0, cB1, cB2, cB3, cLTIN, cEQIN, cGTIN)
+#define TTL_7485(...) \
+ NET_REGISTER_DEVEXT(TTL_7485, __VA_ARGS__)
#endif /* NLD_7485_H_ */
diff --git a/src/lib/netlist/devices/nld_7490.cpp b/src/lib/netlist/devices/nld_7490.cpp
index e7b57044c59..aa8388c2615 100644
--- a/src/lib/netlist/devices/nld_7490.cpp
+++ b/src/lib/netlist/devices/nld_7490.cpp
@@ -1,7 +1,54 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_7490.c
+ * nld_7490.cpp
+ *
+ * DM7490: Decade Counters
+ *
+ * +--------------+
+ * B |1 ++ 14| A
+ * R01 |2 13| NC
+ * R02 |3 12| QA
+ * NC |4 7490 11| QD
+ * VCC |5 10| GND
+ * R91 |6 9| QB
+ * R92 |7 8| QC
+ * +--------------+
+ *
+ * Counter Sequence
+ *
+ * +-------++----+----+----+----+
+ * | COUNT || QD | QC | QB | QA |
+ * +=======++====+====+====+====+
+ * | 0 || 0 | 0 | 0 | 0 |
+ * | 1 || 0 | 0 | 0 | 1 |
+ * | 2 || 0 | 0 | 1 | 0 |
+ * | 3 || 0 | 0 | 1 | 1 |
+ * | 4 || 0 | 1 | 0 | 0 |
+ * | 5 || 0 | 1 | 0 | 1 |
+ * | 6 || 0 | 1 | 1 | 0 |
+ * | 7 || 0 | 1 | 1 | 1 |
+ * | 8 || 1 | 0 | 0 | 0 |
+ * | 9 || 1 | 0 | 0 | 1 |
+ * +-------++----+----+----+----+
+ *
+ * Note A Output QA is connected to input B for BCD count
+ *
+ * Reset Count Function table
+ *
+ * +-----+-----+-----+-----++----+----+----+----+
+ * | R01 | R02 | R91 | R92 || QD | QC | QB | QA |
+ * +=====+=====+=====+=====++====+====+====+====+
+ * | 1 | 1 | 0 | X || 0 | 0 | 0 | 0 |
+ * | 1 | 1 | X | 0 || 0 | 0 | 0 | 0 |
+ * | X | X | 1 | 1 || 1 | 0 | 0 | 1 |
+ * | X | 0 | X | 0 || COUNT |
+ * | 0 | X | 0 | X || COUNT |
+ * | 0 | X | X | 0 || COUNT |
+ * | X | 0 | 0 | X || COUNT |
+ * +-----+-----+-----+-----++----+----+----+----+
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
@@ -95,35 +142,7 @@ namespace devices
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(7490_dip)
- {
- NETLIB_CONSTRUCTOR(7490_dip)
- , A(*this, "A")
- {
- register_subalias("1", "A.B");
- register_subalias("2", "A.R1");
- register_subalias("3", "A.R2");
-
- // register_subalias("4", ); --> NC
- register_subalias("5", "A.VCC");
- register_subalias("6", "A.R91");
- register_subalias("7", "A.R92");
-
- register_subalias("8", "A.QC");
- register_subalias("9", "A.QB");
- register_subalias("10", "A.GND");
- register_subalias("11", "A.QD");
- register_subalias("12", "A.QA");
- // register_subalias("13", ); --> NC
- register_subalias("14", "A.A");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7490) A;
- };
-
NETLIB_DEVICE_IMPL(7490, "TTL_7490", "+A,+B,+R1,+R2,+R91,+R92,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7490_dip, "TTL_7490_DIP", "")
} // namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7490.h b/src/lib/netlist/devices/nld_7490.h
index e0479ba14b0..725ebb8b949 100644
--- a/src/lib/netlist/devices/nld_7490.h
+++ b/src/lib/netlist/devices/nld_7490.h
@@ -1,74 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7490.h
- *
- * DM7490: Decade Counters
- *
- * +--------------+
- * B |1 ++ 14| A
- * R01 |2 13| NC
- * R02 |3 12| QA
- * NC |4 7490 11| QD
- * VCC |5 10| GND
- * R91 |6 9| QB
- * R92 |7 8| QC
- * +--------------+
- *
- * Counter Sequence
- *
- * +-------++----+----+----+----+
- * | COUNT || QD | QC | QB | QA |
- * +=======++====+====+====+====+
- * | 0 || 0 | 0 | 0 | 0 |
- * | 1 || 0 | 0 | 0 | 1 |
- * | 2 || 0 | 0 | 1 | 0 |
- * | 3 || 0 | 0 | 1 | 1 |
- * | 4 || 0 | 1 | 0 | 0 |
- * | 5 || 0 | 1 | 0 | 1 |
- * | 6 || 0 | 1 | 1 | 0 |
- * | 7 || 0 | 1 | 1 | 1 |
- * | 8 || 1 | 0 | 0 | 0 |
- * | 9 || 1 | 0 | 0 | 1 |
- * +-------++----+----+----+----+
- *
- * Note A Output QA is connected to input B for BCD count
- *
- * Reset Count Function table
- *
- * +-----+-----+-----+-----++----+----+----+----+
- * | R01 | R02 | R91 | R92 || QD | QC | QB | QA |
- * +=====+=====+=====+=====++====+====+====+====+
- * | 1 | 1 | 0 | X || 0 | 0 | 0 | 0 |
- * | 1 | 1 | X | 0 || 0 | 0 | 0 | 0 |
- * | X | X | 1 | 1 || 1 | 0 | 0 | 1 |
- * | X | 0 | X | 0 || COUNT |
- * | 0 | X | 0 | X || COUNT |
- * | 0 | X | X | 0 || COUNT |
- * | X | 0 | 0 | X || COUNT |
- * +-----+-----+-----+-----++----+----+----+----+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_7490_H_
#define NLD_7490_H_
#include "netlist/nl_setup.h"
-#define TTL_7490(name, cA, cB, cR1, cR2, cR91, cR92) \
- NET_REGISTER_DEV(TTL_7490, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, R1, cR1) \
- NET_CONNECT(name, R2, cR2) \
- NET_CONNECT(name, R91, cR91) \
- NET_CONNECT(name, R92, cR92)
-
-#define TTL_7490_DIP(name) \
- NET_REGISTER_DEV(TTL_7490_DIP, name)
+// usage: TTL_7490(name, cA, cB, cR1, cR2, cR91, cR92)
+#define TTL_7490(...) \
+ NET_REGISTER_DEVEXT(TTL_7490, __VA_ARGS__)
#endif /* NLD_7490_H_ */
diff --git a/src/lib/netlist/devices/nld_7492.cpp b/src/lib/netlist/devices/nld_7492.cpp
index d4130081cb6..56a579dcb8a 100644
--- a/src/lib/netlist/devices/nld_7492.cpp
+++ b/src/lib/netlist/devices/nld_7492.cpp
@@ -3,9 +3,53 @@
/*
* nld_7492.cpp
*
+ * SN7492: Divide-by-12 Counter
+ *
+ * +--------------+
+ * B |1 ++ 14| A
+ * NC |2 13| NC
+ * NC |3 12| QA
+ * NC |4 7492 11| QD
+ * VCC |5 10| GND
+ * R01 |6 9| QB
+ * R02 |7 8| QC
+ * +--------------+
+ *
+ * Counter Sequence
+ *
+ * +-------++----+----+----+----+
+ * | COUNT || QD | QC | QB | QA |
+ * +=======++====+====+====+====+
+ * | 0 || 0 | 0 | 0 | 0 |
+ * | 1 || 0 | 0 | 0 | 1 |
+ * | 2 || 0 | 0 | 1 | 0 |
+ * | 3 || 0 | 0 | 1 | 1 |
+ * | 4 || 0 | 1 | 0 | 0 |
+ * | 5 || 0 | 1 | 0 | 1 |
+ * | 6 || 1 | 0 | 0 | 0 |
+ * | 7 || 1 | 0 | 0 | 1 |
+ * | 8 || 1 | 0 | 1 | 0 |
+ * | 9 || 1 | 0 | 1 | 1 |
+ * | 10 || 1 | 1 | 0 | 0 |
+ * | 11 || 1 | 1 | 0 | 1 |
+ * +-------++----+----+----+----+
+ *
+ * Note A Output QA is connected to input B
+ *
+ * Reset Count Function table
+ *
+ * +-----+-----++----+----+----+----+
+ * | R01 | R02 || QD | QC | QB | QA |
+ * +=====+=====++====+====+====+====+
+ * | 1 | 1 || 0 | 0 | 0 | 0 |
+ * | 0 | X || COUNT |
+ * | X | 0 || COUNT |
+ * +-----+-----++----+----+----+----+
+ *
+ * Naming conventions follow Texas Instruments datasheet
+ *
*/
-#include "nld_7492.h"
#include "netlist/nl_base.h"
namespace netlist
@@ -89,35 +133,7 @@ namespace devices
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(7492_dip)
- {
- NETLIB_CONSTRUCTOR(7492_dip)
- , A(*this, "A")
- {
- register_subalias("1", "A.B");
- // register_subalias("2", ); --> NC
- // register_subalias("3", ); --> NC
-
- // register_subalias("4", ); --> NC
- register_subalias("5", "A.VCC");
- register_subalias("6", "A.R1");
- register_subalias("7", "A.R2");
-
- register_subalias("8", "A.QC");
- register_subalias("9", "A.QB");
- register_subalias("10", "A.GND");
- register_subalias("11", "A.QD");
- register_subalias("12", "A.QA");
- // register_subalias("13", ); --> NC
- register_subalias("14", "A.A");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7492) A;
- };
-
NETLIB_DEVICE_IMPL(7492, "TTL_7492", "+A,+B,+R1,+R2,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7492_dip, "TTL_7492_DIP", "")
} // namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7492.h b/src/lib/netlist/devices/nld_7492.h
index 9595a7d89b0..c4cab8909e8 100644
--- a/src/lib/netlist/devices/nld_7492.h
+++ b/src/lib/netlist/devices/nld_7492.h
@@ -1,70 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7492.h
- *
- * SN7492: Divide-by-12 Counter
- *
- * +--------------+
- * B |1 ++ 14| A
- * NC |2 13| NC
- * NC |3 12| QA
- * NC |4 7492 11| QD
- * VCC |5 10| GND
- * R01 |6 9| QB
- * R02 |7 8| QC
- * +--------------+
- *
- * Counter Sequence
- *
- * +-------++----+----+----+----+
- * | COUNT || QD | QC | QB | QA |
- * +=======++====+====+====+====+
- * | 0 || 0 | 0 | 0 | 0 |
- * | 1 || 0 | 0 | 0 | 1 |
- * | 2 || 0 | 0 | 1 | 0 |
- * | 3 || 0 | 0 | 1 | 1 |
- * | 4 || 0 | 1 | 0 | 0 |
- * | 5 || 0 | 1 | 0 | 1 |
- * | 6 || 1 | 0 | 0 | 0 |
- * | 7 || 1 | 0 | 0 | 1 |
- * | 8 || 1 | 0 | 1 | 0 |
- * | 9 || 1 | 0 | 1 | 1 |
- * | 10 || 1 | 1 | 0 | 0 |
- * | 11 || 1 | 1 | 0 | 1 |
- * +-------++----+----+----+----+
- *
- * Note A Output QA is connected to input B
- *
- * Reset Count Function table
- *
- * +-----+-----++----+----+----+----+
- * | R01 | R02 || QD | QC | QB | QA |
- * +=====+=====++====+====+====+====+
- * | 1 | 1 || 0 | 0 | 0 | 0 |
- * | 0 | X || COUNT |
- * | X | 0 || COUNT |
- * +-----+-----++----+----+----+----+
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- */
#ifndef NLD_7492_H_
#define NLD_7492_H_
#include "netlist/nl_setup.h"
-#define TTL_7492(name, cA, cB, cR1, cR2) \
- NET_REGISTER_DEV(TTL_7492, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, R1, cR1) \
- NET_CONNECT(name, R2, cR2)
-
-#define TTL_7492_DIP(name) \
- NET_REGISTER_DEV(TTL_7492_DIP, name)
+// usage: TTL_7492(name, cA, cB, cR1, cR2)
+#define TTL_7492(...) \
+ NET_REGISTER_DEVEXT(TTL_7492, __VA_ARGS__)
#endif /* NLD_7492_H_ */
diff --git a/src/lib/netlist/devices/nld_7493.cpp b/src/lib/netlist/devices/nld_7493.cpp
index a6514183f76..7ad8aedc13f 100644
--- a/src/lib/netlist/devices/nld_7493.cpp
+++ b/src/lib/netlist/devices/nld_7493.cpp
@@ -3,6 +3,55 @@
/*
* nld_7493.cpp
*
+ * DM7493: Binary Counters
+ *
+ * +--------------+
+ * B |1 ++ 14| A
+ * R01 |2 13| NC
+ * R02 |3 12| QA
+ * NC |4 7493 11| QD
+ * VCC |5 10| GND
+ * NC |6 9| QB
+ * NC |7 8| QC
+ * +--------------+
+ *
+ * Counter Sequence
+ *
+ * +-------++----+----+----+----+
+ * | COUNT || QD | QC | QB | QA |
+ * +=======++====+====+====+====+
+ * | 0 || 0 | 0 | 0 | 0 |
+ * | 1 || 0 | 0 | 0 | 1 |
+ * | 2 || 0 | 0 | 1 | 0 |
+ * | 3 || 0 | 0 | 1 | 1 |
+ * | 4 || 0 | 1 | 0 | 0 |
+ * | 5 || 0 | 1 | 0 | 1 |
+ * | 6 || 0 | 1 | 1 | 0 |
+ * | 7 || 0 | 1 | 1 | 1 |
+ * | 8 || 1 | 0 | 0 | 0 |
+ * | 9 || 1 | 0 | 0 | 1 |
+ * | 10 || 1 | 0 | 1 | 0 |
+ * | 11 || 1 | 0 | 1 | 1 |
+ * | 12 || 1 | 1 | 0 | 0 |
+ * | 13 || 1 | 1 | 0 | 1 |
+ * | 14 || 1 | 1 | 1 | 0 |
+ * | 15 || 1 | 1 | 1 | 1 |
+ * +-------++----+----+----+----+
+ *
+ * Note C Output QA is connected to input B
+ *
+ * Reset Count Function table
+ *
+ * +-----+-----++----+----+----+----+
+ * | R01 | R02 || QD | QC | QB | QA |
+ * +=====+=====++====+====+====+====+
+ * | 1 | 1 || 0 | 0 | 0 | 0 |
+ * | 0 | X || COUNT |
+ * | X | 0 || COUNT |
+ * +-----+-----++----+----+----+----+
+ *
+ * Naming conventions follow National Semiconductor datasheet
+ *
*/
#include "nld_7493.h"
@@ -149,35 +198,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(7493_dip)
- {
- NETLIB_CONSTRUCTOR(7493_dip)
- , A(*this, "A")
- {
- register_subalias("1", "A.CLKB");
- register_subalias("2", "A.R1");
- register_subalias("3", "A.R2");
-
- // register_subalias("4", ); --> NC
- register_subalias("5", "A.VCC");
- // register_subalias("6", ); --> NC
- // register_subalias("7", ); --> NC
-
- register_subalias("8", "A.QC");
- register_subalias("9", "A.QB");
- register_subalias("10", "A.GND");
- register_subalias("11", "A.QD");
- register_subalias("12", "A.QA");
- // register_subalias("13", ); -. NC
- register_subalias("14", "A.CLKA");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7493) A;
- };
-
NETLIB_DEVICE_IMPL(7493, "TTL_7493", "+CLKA,+CLKB,+R1,+R2,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7493_dip, "TTL_7493_DIP", "")
} // namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7493.h b/src/lib/netlist/devices/nld_7493.h
index 3498d216b08..34041d61373 100644
--- a/src/lib/netlist/devices/nld_7493.h
+++ b/src/lib/netlist/devices/nld_7493.h
@@ -1,74 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_7493.h
- *
- * DM7493: Binary Counters
- *
- * +--------------+
- * B |1 ++ 14| A
- * R01 |2 13| NC
- * R02 |3 12| QA
- * NC |4 7493 11| QD
- * VCC |5 10| GND
- * NC |6 9| QB
- * NC |7 8| QC
- * +--------------+
- *
- * Counter Sequence
- *
- * +-------++----+----+----+----+
- * | COUNT || QD | QC | QB | QA |
- * +=======++====+====+====+====+
- * | 0 || 0 | 0 | 0 | 0 |
- * | 1 || 0 | 0 | 0 | 1 |
- * | 2 || 0 | 0 | 1 | 0 |
- * | 3 || 0 | 0 | 1 | 1 |
- * | 4 || 0 | 1 | 0 | 0 |
- * | 5 || 0 | 1 | 0 | 1 |
- * | 6 || 0 | 1 | 1 | 0 |
- * | 7 || 0 | 1 | 1 | 1 |
- * | 8 || 1 | 0 | 0 | 0 |
- * | 9 || 1 | 0 | 0 | 1 |
- * | 10 || 1 | 0 | 1 | 0 |
- * | 11 || 1 | 0 | 1 | 1 |
- * | 12 || 1 | 1 | 0 | 0 |
- * | 13 || 1 | 1 | 0 | 1 |
- * | 14 || 1 | 1 | 1 | 0 |
- * | 15 || 1 | 1 | 1 | 1 |
- * +-------++----+----+----+----+
- *
- * Note C Output QA is connected to input B
- *
- * Reset Count Function table
- *
- * +-----+-----++----+----+----+----+
- * | R01 | R02 || QD | QC | QB | QA |
- * +=====+=====++====+====+====+====+
- * | 1 | 1 || 0 | 0 | 0 | 0 |
- * | 0 | X || COUNT |
- * | X | 0 || COUNT |
- * +-----+-----++----+----+----+----+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_7493_H_
#define NLD_7493_H_
#include "netlist/nl_setup.h"
-#define TTL_7493(name, cCLKA, cCLKB, cR1, cR2) \
- NET_REGISTER_DEV(TTL_7493, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLKA, cCLKA) \
- NET_CONNECT(name, CLKB, cCLKB) \
- NET_CONNECT(name, R1, cR1) \
- NET_CONNECT(name, R2, cR2)
-
-#define TTL_7493_DIP(name) \
- NET_REGISTER_DEV(TTL_7493_DIP, name)
+// usage: TTL_7493(name, cCLKA, cCLKB, cR1, cR2)
+#define TTL_7493(...) \
+ NET_REGISTER_DEVEXT(TTL_7493, __VA_ARGS__)
#endif /* NLD_7493_H_ */
diff --git a/src/lib/netlist/devices/nld_7497.cpp b/src/lib/netlist/devices/nld_7497.cpp
index a5140e9593f..4fdf282a9fd 100644
--- a/src/lib/netlist/devices/nld_7497.cpp
+++ b/src/lib/netlist/devices/nld_7497.cpp
@@ -7,6 +7,34 @@
*
* - STRB and EN
* - Timing
+ *
+ * SN7497: Synchronous 6-Bit Binary Rate Multiplier
+ *
+ * +--------------+
+ * B1 |1 16| VCC
+ * B4 |2 15| B3
+ * B5 |3 14| B2
+ * B0 |4 7497 13| CLR
+ * Z |5 12| UNITY/CAS
+ * Y |6 11| ENin (EN)
+ * ENout |7 10| STRB
+ * GND |8 9| CLK
+ * +--------------+
+ *
+ * Naming conventions follow TI datasheet
+ *
+ * The counter is enabled when the clear, strobe, and enable inputs are low.
+ *
+ * When the rate input is binary 0 (all rate inputs low), Z remains high [and Y low].
+ *
+ * The unity/cascade input, when connected to the clock input, passes
+ * clock frequency (inverted) to the Y output when the rate input/decoding
+ * gates are inhibited by the strobe.
+ *
+ * When CLR is H, states of CLK and STRB can affect Y and Z. Default are
+ * Y L, Z H, ENout H.
+ *
+ * Unity/cascade is used to inhibit output Y (UNITY L -> Y H)
*/
#include "nld_7497.h"
@@ -102,8 +130,6 @@ namespace netlist
clk_strb();
}
- friend class NETLIB_NAME(7497_dip);
-
object_array_t<logic_input_t, 6> m_B;
logic_input_t m_CLK;
logic_input_t m_STRBQ;
@@ -141,37 +167,7 @@ namespace netlist
}
};
- NETLIB_OBJECT(7497_dip)
- {
- NETLIB_CONSTRUCTOR(7497_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_B[4]); // B0
- register_subalias("2", A.m_B[1]); // B4
- register_subalias("3", A.m_B[0]); // B5
- register_subalias("4", A.m_B[5]); // B0
- register_subalias("5", A.m_ZQ);
- register_subalias("6", A.m_Y);
- register_subalias("7", A.m_ENOUTQ);
- register_subalias("8", "A.GND");
-
- register_subalias("9", A.m_CLK);
- register_subalias("10", A.m_STRBQ);
- register_subalias("11", A.m_UNITYQ);
- register_subalias("12", A.m_ENQ);
- register_subalias("13", A.m_CLR);
- register_subalias("14", A.m_B[3]); // B2
- register_subalias("15", A.m_B[2]); // B3
- register_subalias("16", "A.VCC");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(7497) A;
- };
-
-
NETLIB_DEVICE_IMPL(7497, "TTL_7497", "+CLK,+STRBQ,+ENQ,+UNITYQ,+CLR,+B0,+B1,+B2,+B3,+B4,+B5,@VCC,@GND")
- NETLIB_DEVICE_IMPL(7497_dip, "TTL_7497_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_7497.h b/src/lib/netlist/devices/nld_7497.h
index 3e3e2e89e40..c187ad24b3b 100644
--- a/src/lib/netlist/devices/nld_7497.h
+++ b/src/lib/netlist/devices/nld_7497.h
@@ -1,59 +1,13 @@
// license:GPL-2.0+
// copyright-holders:Sergey Svishchev
-/*
- * nld_7497.h
- *
- * SN7497: Synchronous 6-Bit Binary Rate Multiplier
- *
- * +--------------+
- * B1 |1 16| VCC
- * B4 |2 15| B3
- * B5 |3 14| B2
- * B0 |4 7497 13| CLR
- * Z |5 12| UNITY/CAS
- * Y |6 11| ENin (EN)
- * ENout |7 10| STRB
- * GND |8 9| CLK
- * +--------------+
- *
- * Naming conventions follow TI datasheet
- *
- * The counter is enabled when the clear, strobe, and enable inputs are low.
- *
- * When the rate input is binary 0 (all rate inputs low), Z remains high [and Y low].
- *
- * The unity/cascade input, when connected to the clock input, passes
- * clock frequency (inverted) to the Y output when the rate input/decoding
- * gates are inhibited by the strobe.
- *
- * When CLR is H, states of CLK and STRB can affect Y and Z. Default are
- * Y L, Z H, ENout H.
- *
- * Unity/cascade is used to inhibit output Y (UNITY L -> Y H)
- */
#ifndef NLD_7497_H_
#define NLD_7497_H_
#include "netlist/nl_setup.h"
-#define TTL_7497(name, cCLK, cSTRB, cEN, cUNITY, cCLR, cB0, cB1, cB2, cB3, cB4, cB5) \
- NET_REGISTER_DEV(TTL_7497, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, STRBQ, cSTRB) \
- NET_CONNECT(name, ENQ, cEN) \
- NET_CONNECT(name, UNITYQ,cUNITY) \
- NET_CONNECT(name, CLR, cCLR) \
- NET_CONNECT(name, B0, cB0) \
- NET_CONNECT(name, B1, cB1) \
- NET_CONNECT(name, B2, cB2) \
- NET_CONNECT(name, B3, cB3) \
- NET_CONNECT(name, B4, cB4) \
- NET_CONNECT(name, B5, cB5)
-
-#define TTL_7497_DIP(name) \
- NET_REGISTER_DEV(TTL_7497_DIP, name)
+// usage: TTL_7497(name, cCLK, cSTRB, cEN, cUNITY, cCLR, cB0, cB1, cB2, cB3, cB4, cB5)
+#define TTL_7497(...) \
+ NET_REGISTER_DEVEXT(TTL_7497, __VA_ARGS__)
#endif /* NLD_7497_H_ */
diff --git a/src/lib/netlist/devices/nld_74ls629.cpp b/src/lib/netlist/devices/nld_74ls629.cpp
index cc924450eca..669c57912e3 100644
--- a/src/lib/netlist/devices/nld_74ls629.cpp
+++ b/src/lib/netlist/devices/nld_74ls629.cpp
@@ -1,7 +1,27 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_SN74LS629.c
+ * nld_SN74LS629.cpp
+ *
+ * SN74LS629: VOLTAGE-CONTROLLED OSCILLATORS
+ *
+ * +--------------+
+ * 2FC |1 ++ 16| VCC
+ * 1FC |2 15| QSC VCC
+ * 1RNG |3 14| 2RNG
+ * 1CX1 |4 74LS629 13| 2CX1
+ * 1CX2 |5 12| 2CX2
+ * 1ENQ |6 11| 2ENQ
+ * 1Y |7 10| 2Y
+ * OSC GND |8 9| GND
+ * +--------------+
+ *
+ * Naming conventions follow Texas Instruments datasheet
+ *
+ * NOTE: The CX1 and CX2 pins are not connected!
+ * The capacitor value has to be specified as a parameter.
+ * There are more comments on the challenges of emulating this
+ * chip in the *.c file
*
*/
@@ -46,23 +66,17 @@ namespace netlist
{
namespace devices
{
- NETLIB_OBJECT(SN74LS629clk)
- {
- NETLIB_CONSTRUCTOR(SN74LS629clk)
- , m_FB(*this, "FB", NETLIB_DELEGATE(fb))
- , m_Y(*this, "Y")
- , m_enableq(*this, "m_enableq", 1)
- , m_out(*this, "m_out", 0)
- , m_inc(*this, "m_inc", netlist_time::zero())
- {
- connect(m_FB, m_Y);
- }
- NETLIB_RESETI()
+ struct SN74LS629clk
+ {
+ SN74LS629clk(device_t &owner)
+ : m_FB(owner, "FB", nldelegate(&SN74LS629clk::fb, this))
+ , m_Y(owner, "Y")
+ , m_enableq(owner, "m_enableq", 0)
+ , m_out(owner, "m_out", 0)
+ , m_inc(owner, "m_inc", netlist_time::zero())
{
- m_enableq = 0;
- m_out = 0;
- m_inc = netlist_time::zero();
+ owner.connect(m_FB, m_Y);
}
public:
@@ -72,6 +86,7 @@ namespace netlist
state_var<netlist_sig_t> m_enableq;
state_var<netlist_sig_t> m_out;
state_var<netlist_time> m_inc;
+
private:
NETLIB_HANDLERI(fb)
{
@@ -91,15 +106,17 @@ namespace netlist
NETLIB_OBJECT(SN74LS629)
{
NETLIB_CONSTRUCTOR(SN74LS629)
- , m_clock(*this, "OSC")
+ , m_clock(*this)
, m_R_FC(*this, "R_FC")
, m_R_RNG(*this, "R_RNG")
, m_ENQ(*this, "ENQ", NETLIB_DELEGATE(inputs))
, m_RNG(*this, "RNG", NETLIB_DELEGATE(inputs))
, m_FC(*this, "FC", NETLIB_DELEGATE(inputs))
, m_CAP(*this, "CAP", nlconst::magic(1e-6))
+ , m_power_pins(*this)
+ , m_power_pins_osc(*this, "OSCVCC", "OSCGND")
{
- register_subalias("GND", m_R_FC.N());
+ connect(m_power_pins_osc.GND(), m_R_FC.N());
connect(m_FC, m_R_FC.P());
connect(m_RNG, m_R_RNG.P());
@@ -112,7 +129,6 @@ namespace netlist
{
m_R_FC.set_R( nlconst::magic(90000.0));
m_R_RNG.set_R(nlconst::magic(90000.0));
- m_clock.reset();
}
NETLIB_UPDATE_PARAMI()
@@ -121,7 +137,7 @@ namespace netlist
}
public:
- NETLIB_SUB(SN74LS629clk) m_clock;
+ SN74LS629clk m_clock;
analog::NETLIB_SUB(R_base) m_R_FC;
analog::NETLIB_SUB(R_base) m_R_RNG;
@@ -130,6 +146,8 @@ namespace netlist
analog_input_t m_FC;
param_fp_t m_CAP;
+ nld_power_pins m_power_pins;
+ nld_power_pins m_power_pins_osc;
private:
NETLIB_HANDLERI(inputs)
@@ -174,8 +192,6 @@ namespace netlist
// FIXME: we need a possibility to remove entries from queue ...
// or an exact model ...
m_clock.m_inc = netlist_time::from_fp(nlconst::half() / freq);
-
- //NL_VERBOSE_OUT(("{1} {2} {3} {4}\n", name(), v_freq, v_rng, freq));
}
if (!m_clock.m_enableq && m_ENQ())
@@ -194,43 +210,7 @@ namespace netlist
};
- NETLIB_OBJECT(SN74LS629_dip)
- {
- NETLIB_CONSTRUCTOR(SN74LS629_dip)
- , m_A(*this, "A")
- , m_B(*this, "B")
- {
- register_subalias("1", m_B.m_FC);
- register_subalias("2", m_A.m_FC);
- register_subalias("3", m_A.m_RNG);
-
- register_subalias("6", m_A.m_ENQ);
- register_subalias("7", m_A.m_clock.m_Y);
-
- register_subalias("8", m_A.m_R_FC.N());
- register_subalias("9", m_A.m_R_FC.N());
- connect(m_A.m_R_FC.N(), m_B.m_R_FC.N());
-
- register_subalias("10", m_B.m_clock.m_Y);
-
- register_subalias("11", m_B.m_ENQ);
- register_subalias("14", m_B.m_RNG);
- }
-
-
- NETLIB_RESETI()
- {
- m_A.reset();
- m_B.reset();
- }
-
- private:
- NETLIB_SUB(SN74LS629) m_A;
- NETLIB_SUB(SN74LS629) m_B;
- };
-
- NETLIB_DEVICE_IMPL(SN74LS629, "SN74LS629", "CAP")
- NETLIB_DEVICE_IMPL(SN74LS629_dip, "SN74LS629_DIP", "1.CAP1,2.CAP2")
+ NETLIB_DEVICE_IMPL(SN74LS629, "SN74LS629", "CAP,@VCC,@GND")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_74ls629.h b/src/lib/netlist/devices/nld_74ls629.h
index 7a695e16a17..840dae357b8 100644
--- a/src/lib/netlist/devices/nld_74ls629.h
+++ b/src/lib/netlist/devices/nld_74ls629.h
@@ -1,39 +1,12 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_74LS629.h
- *
- * SN74LS629: VOLTAGE-CONTROLLED OSCILLATORS
- *
- * +--------------+
- * 2FC |1 ++ 16| VCC
- * 1FC |2 15| QSC VCC
- * 1RNG |3 14| 2RNG
- * 1CX1 |4 74LS629 13| 2CX1
- * 1CX2 |5 12| 2CX2
- * 1ENQ |6 11| 2ENQ
- * 1Y |7 10| 2Y
- * OSC GND |8 9| GND
- * +--------------+
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- * NOTE: The CX1 and CX2 pins are not connected!
- * The capacitor value has to be specified as a parameter.
- * There are more comments on the challenges of emulating this
- * chip in the *.c file
- *
- */
#ifndef NLD_74LS629_H_
#define NLD_74LS629_H_
#include "netlist/nl_setup.h"
-#define SN74LS629(name, p_cap) \
- NET_REGISTER_DEVEXT(SN74LS629, name, p_cap)
-
-#define SN74LS629_DIP(name, p_cap1, p_cap2) \
- NET_REGISTER_DEVEXT(SN74LS629_DIP, name, p_cap1, p_cap2)
+#define SN74LS629(name, ...) \
+ NET_REGISTER_DEVEXT(SN74LS629, name,__VA_ARGS__)
#endif /* NLD_74LS629_H_ */
diff --git a/src/lib/netlist/devices/nld_82S115.cpp b/src/lib/netlist/devices/nld_82S115.cpp
index 1b1235817f0..317b16e5e80 100644
--- a/src/lib/netlist/devices/nld_82S115.cpp
+++ b/src/lib/netlist/devices/nld_82S115.cpp
@@ -3,6 +3,26 @@
/*
* nld_82S115.cpp
*
+ * 82S115: 4K-bit TTL bipolar PROM (512 x 8)
+ *
+ * +--------------+
+ * A3 |1 ++ 24| VCC
+ * A4 |2 23| A2
+ * A5 |3 22| A1
+ * A6 |4 82S115 21| A0
+ * A7 |5 20| CE1Q
+ * A8 |6 19| CE2
+ * O1 |7 18| STROBE
+ * O2 |8 17| O8
+ * O3 |9 16| O7
+ * O4 |10 15| O6
+ * FE2 |11 14| O5
+ * GND |12 13| FE1
+ * +--------------+
+ *
+ *
+ * Naming conventions follow Signetics datasheet
+ *
*/
#include "nld_82S115.h"
@@ -31,7 +51,6 @@ namespace netlist
m_last_O = 0;
}
- friend class NETLIB_NAME(82S115_dip);
private:
// FIXME: timing!
NETLIB_HANDLERI(inputs)
@@ -73,49 +92,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(82S115_dip)
- {
- NETLIB_CONSTRUCTOR(82S115_dip)
- , A(*this, "A")
- {
- register_subalias("21", A.m_A[0]);
- register_subalias("22", A.m_A[1]);
- register_subalias("23", A.m_A[2]);
- register_subalias("1", A.m_A[3]);
- register_subalias("2", A.m_A[4]);
- register_subalias("3", A.m_A[5]);
- register_subalias("4", A.m_A[6]);
- register_subalias("5", A.m_A[7]);
- register_subalias("6", A.m_A[8]);
-
- register_subalias("20", A.m_CE1Q);
- register_subalias("19", A.m_CE2);
-
- // FIXME: implement FE1, FE2
- // register_subalias("13", m_FE1);
- // register_subalias("11", m_FE2);
-
- register_subalias("18", A.m_STROBE);
-
- register_subalias("7", A.m_O[0]);
- register_subalias("8", A.m_O[1]);
- register_subalias("9", A.m_O[2]);
- register_subalias("10", A.m_O[3]);
- register_subalias("14", A.m_O[4]);
- register_subalias("15", A.m_O[5]);
- register_subalias("16", A.m_O[6]);
- register_subalias("17", A.m_O[7]);
-
- register_subalias("12", "A.GND");
- register_subalias("24", "A.VCC");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(82S115) A;
- };
-
NETLIB_DEVICE_IMPL(82S115, "PROM_82S115", "+CE1Q,+CE2,+A0,+A1,+A2,+A3,+A4,+A5,+A6,+A7,+A8,+STROBE,@VCC,@GND")
- NETLIB_DEVICE_IMPL(82S115_dip, "PROM_82S115_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_82S115.h b/src/lib/netlist/devices/nld_82S115.h
index da4c1209e81..c3f22dffee4 100644
--- a/src/lib/netlist/devices/nld_82S115.h
+++ b/src/lib/netlist/devices/nld_82S115.h
@@ -1,53 +1,13 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_82S115.h
- *
- * 82S115: 4K-bit TTL bipolar PROM (512 x 8)
- *
- * +--------------+
- * A3 |1 ++ 24| VCC
- * A4 |2 23| A2
- * A5 |3 22| A1
- * A6 |4 82S115 21| A0
- * A7 |5 20| CE1Q
- * A8 |6 19| CE2
- * O1 |7 18| STROBE
- * O2 |8 17| O8
- * O3 |9 16| O7
- * O4 |10 15| O6
- * FE2 |11 14| O5
- * GND |12 13| FE1
- * +--------------+
- *
- *
- * Naming conventions follow Signetics datasheet
- *
- */
#ifndef NLD_82S115_H_
#define NLD_82S115_H_
#include "netlist/nl_setup.h"
-#define PROM_82S115(name, cCE1Q, cCE2, cA0, cA1, cA2, cA3, cA4, cA5, cA6, cA7, cA8, cSTROBE) \
- NET_REGISTER_DEV(PROM_82S115, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CE1Q, cCE1Q) \
- NET_CONNECT(name, CE2, cCE2) \
- NET_CONNECT(name, A0, cA0) \
- NET_CONNECT(name, A1, cA1) \
- NET_CONNECT(name, A2, cA2) \
- NET_CONNECT(name, A3, cA3) \
- NET_CONNECT(name, A4, cA4) \
- NET_CONNECT(name, A5, cA5) \
- NET_CONNECT(name, A6, cA6) \
- NET_CONNECT(name, A7, cA7) \
- NET_CONNECT(name, A8, cA8) \
- NET_CONNECT(name, STROBE, cSTROBE)
-
-#define PROM_82S115_DIP(name) \
- NET_REGISTER_DEV(PROM_82S115_DIP, name)
+// expects: PROM_82S115(name, cCE1Q, cCE2, cA0, cA1, cA2, cA3, cA4, cA5, cA6, cA7, cA8, cSTROBE)
+#define PROM_82S115(...) \
+ NET_REGISTER_DEVEXT(PROM_82S115, __VA_ARGS__)
#endif /* NLD_82S115_H_ */
diff --git a/src/lib/netlist/devices/nld_82S16.cpp b/src/lib/netlist/devices/nld_82S16.cpp
index 370f2c0104d..ee798e11eb5 100644
--- a/src/lib/netlist/devices/nld_82S16.cpp
+++ b/src/lib/netlist/devices/nld_82S16.cpp
@@ -1,7 +1,24 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_82S16.c
+ * nld_82S16.cpp
+ *
+ *
+ * DM82S16: 256 Bit bipolar ram
+ *
+ * +--------------+
+ * A1 |1 ++ 16| VCC
+ * A0 |2 15| A2
+ * CE1Q |3 14| A3
+ * CE2Q |4 82S16 13| DIN
+ * CE3Q |5 12| WEQ
+ * DOUTQ |6 11| A7
+ * A4 |7 10| A6
+ * GND |8 9| A5
+ * +--------------+
+ *
+ *
+ * Naming conventions follow Signetics datasheet
*
*/
@@ -38,7 +55,7 @@ namespace netlist
m_addr = 0;
m_enq = 0;
}
- friend class NETLIB_NAME(82S16_dip);
+
private:
// FIXME: timing!
// FIXME: optimize device (separate address decoder!)
@@ -105,39 +122,7 @@ namespace netlist
nld_power_pins m_power_pins;
};
- NETLIB_OBJECT(82S16_dip)
- {
- NETLIB_CONSTRUCTOR(82S16_dip)
- , A(*this, "A")
- {
- register_subalias("2", A.m_A[0]);
- register_subalias("1", A.m_A[1]);
- register_subalias("15", A.m_A[2]);
- register_subalias("14", A.m_A[3]);
- register_subalias("7", A.m_A[4]);
- register_subalias("9", A.m_A[5]);
- register_subalias("10", A.m_A[6]);
- register_subalias("11", A.m_A[7]);
-
- register_subalias("3", A.m_CE1Q);
- register_subalias("4", A.m_CE2Q);
- register_subalias("5", A.m_CE3Q);
-
- register_subalias("12", A.m_WEQ);
- register_subalias("13", A.m_DIN);
-
- register_subalias("6", A.m_DOUTQ);
-
- register_subalias("8", "A.GND");
- register_subalias("16", "A.VCC");
- }
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(82S16) A;
- };
-
NETLIB_DEVICE_IMPL(82S16, "TTL_82S16", "")
- NETLIB_DEVICE_IMPL(82S16_dip, "TTL_82S16_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_82S16.h b/src/lib/netlist/devices/nld_82S16.h
index 47d6189a79b..60e6fb22994 100644
--- a/src/lib/netlist/devices/nld_82S16.h
+++ b/src/lib/netlist/devices/nld_82S16.h
@@ -1,25 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_82S16.h
- *
- * DM82S16: 256 Bit bipolar ram
- *
- * +--------------+
- * A1 |1 ++ 16| VCC
- * A0 |2 15| A2
- * CE1Q |3 14| A3
- * CE2Q |4 82S16 13| DIN
- * CE3Q |5 12| WEQ
- * DOUTQ |6 11| A7
- * A4 |7 10| A6
- * GND |8 9| A5
- * +--------------+
- *
- *
- * Naming conventions follow Signetics datasheet
- *
- */
#ifndef NLD_82S16_H_
#define NLD_82S16_H_
@@ -28,7 +8,5 @@
#define TTL_82S16(name) \
NET_REGISTER_DEV(TTL_82S16, name)
-#define TTL_82S16_DIP(name) \
- NET_REGISTER_DEV(TTL_82S16_DIP, name)
#endif /* NLD_82S16_H_ */
diff --git a/src/lib/netlist/devices/nld_9310.cpp b/src/lib/netlist/devices/nld_9310.cpp
index 956ab3fb3bc..f58f8cd59bf 100644
--- a/src/lib/netlist/devices/nld_9310.cpp
+++ b/src/lib/netlist/devices/nld_9310.cpp
@@ -23,7 +23,6 @@ namespace netlist
{
NETLIB_DEVICE_IMPL(9310, "TTL_9310", "+CLK,+ENP,+ENT,+CLRQ,+LOADQ,+A,+B,+C,+D,@VCC,@GND")
- NETLIB_DEVICE_IMPL(9310_dip, "TTL_9310_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_9316.cpp b/src/lib/netlist/devices/nld_9316.cpp
index 1ebb8547a19..1444eab368e 100644
--- a/src/lib/netlist/devices/nld_9316.cpp
+++ b/src/lib/netlist/devices/nld_9316.cpp
@@ -3,6 +3,82 @@
/*
* nld_9316.cpp
*
+ * DM9316: Synchronous 4-Bit Counters
+ *
+ * +--------------+
+ * /CLEAR |1 ++ 16| VCC
+ * CLOCK |2 15| RC (Ripple Carry)
+ * A |3 14| QA
+ * B |4 9316 13| QB
+ * C |5 12| QC
+ * D |6 11| QD
+ * Enable P |7 10| Enable T
+ * GND |8 9| /LOAD
+ * +--------------+
+ *
+ * Counter Sequence
+ *
+ * +-------++----+----+----+----+----+
+ * | COUNT || QD | QC | QB | QA | RC |
+ * +=======++====+====+====+====+====+
+ * | 0 || 0 | 0 | 0 | 0 | 0 |
+ * | 1 || 0 | 0 | 0 | 1 | 0 |
+ * | 2 || 0 | 0 | 1 | 0 | 0 |
+ * | 3 || 0 | 0 | 1 | 1 | 0 |
+ * | 4 || 0 | 1 | 0 | 0 | 0 |
+ * | 5 || 0 | 1 | 0 | 1 | 0 |
+ * | 6 || 0 | 1 | 1 | 0 | 0 |
+ * | 7 || 0 | 1 | 1 | 1 | 0 |
+ * | 8 || 1 | 0 | 0 | 0 | 0 |
+ * | 9 || 1 | 0 | 0 | 1 | 0 |
+ * | 10 || 1 | 0 | 1 | 0 | 0 |
+ * | 11 || 1 | 0 | 1 | 1 | 0 |
+ * | 12 || 1 | 1 | 0 | 0 | 0 |
+ * | 13 || 1 | 1 | 0 | 1 | 0 |
+ * | 14 || 1 | 1 | 1 | 0 | 0 |
+ * | 15 || 1 | 1 | 1 | 1 | 1 |
+ * +-------++----+----+----+----+----+
+ *
+ * Reset count function: Please refer to
+ * National Semiconductor datasheet (timing diagram)
+ *
+ * Naming conventions follow National Semiconductor datasheet
+ *
+ * DM9310: Synchronous 4-Bit Counters
+ *
+ * +--------------+
+ * CLEAR |1 ++ 16| VCC
+ * CLOCK |2 15| RC (Ripple Carry)
+ * A |3 14| QA
+ * B |4 9310 13| QB
+ * C |5 12| QC
+ * D |6 11| QD
+ * Enable P |7 10| Enable T
+ * GND |8 9| LOAD
+ * +--------------+
+ *
+ * Counter Sequence
+ *
+ * +-------++----+----+----+----+----+
+ * | COUNT || QD | QC | QB | QA | RC |
+ * +=======++====+====+====+====+====+
+ * | 0 || 0 | 0 | 0 | 0 | 0 |
+ * | 1 || 0 | 0 | 0 | 1 | 0 |
+ * | 2 || 0 | 0 | 1 | 0 | 0 |
+ * | 3 || 0 | 0 | 1 | 1 | 0 |
+ * | 4 || 0 | 1 | 0 | 0 | 0 |
+ * | 5 || 0 | 1 | 0 | 1 | 0 |
+ * | 6 || 0 | 1 | 1 | 0 | 0 |
+ * | 7 || 0 | 1 | 1 | 1 | 0 |
+ * | 8 || 1 | 0 | 0 | 0 | 0 |
+ * | 9 || 1 | 0 | 0 | 1 | 0 |
+ * +-------++----+----+----+----+----+
+ *
+ * Reset count function: Please refer to
+ * National Semiconductor datasheet (timing diagram)
+ *
+ * Naming conventions follow National Semiconductor datasheet
+ *
*/
#include "nl_base.h"
@@ -23,7 +99,6 @@ namespace netlist
{
NETLIB_DEVICE_IMPL(9316, "TTL_9316", "+CLK,+ENP,+ENT,+CLRQ,+LOADQ,+A,+B,+C,+D,@VCC,@GND")
- NETLIB_DEVICE_IMPL(9316_dip, "TTL_9316_DIP", "")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_9316.h b/src/lib/netlist/devices/nld_9316.h
index bb09cb342de..008104888ef 100644
--- a/src/lib/netlist/devices/nld_9316.h
+++ b/src/lib/netlist/devices/nld_9316.h
@@ -1,104 +1,14 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_9316.h
- *
- * DM9316: Synchronous 4-Bit Counters
- *
- * +--------------+
- * /CLEAR |1 ++ 16| VCC
- * CLOCK |2 15| RC (Ripple Carry)
- * A |3 14| QA
- * B |4 9316 13| QB
- * C |5 12| QC
- * D |6 11| QD
- * Enable P |7 10| Enable T
- * GND |8 9| /LOAD
- * +--------------+
- *
- * Counter Sequence
- *
- * +-------++----+----+----+----+----+
- * | COUNT || QD | QC | QB | QA | RC |
- * +=======++====+====+====+====+====+
- * | 0 || 0 | 0 | 0 | 0 | 0 |
- * | 1 || 0 | 0 | 0 | 1 | 0 |
- * | 2 || 0 | 0 | 1 | 0 | 0 |
- * | 3 || 0 | 0 | 1 | 1 | 0 |
- * | 4 || 0 | 1 | 0 | 0 | 0 |
- * | 5 || 0 | 1 | 0 | 1 | 0 |
- * | 6 || 0 | 1 | 1 | 0 | 0 |
- * | 7 || 0 | 1 | 1 | 1 | 0 |
- * | 8 || 1 | 0 | 0 | 0 | 0 |
- * | 9 || 1 | 0 | 0 | 1 | 0 |
- * | 10 || 1 | 0 | 1 | 0 | 0 |
- * | 11 || 1 | 0 | 1 | 1 | 0 |
- * | 12 || 1 | 1 | 0 | 0 | 0 |
- * | 13 || 1 | 1 | 0 | 1 | 0 |
- * | 14 || 1 | 1 | 1 | 0 | 0 |
- * | 15 || 1 | 1 | 1 | 1 | 1 |
- * +-------++----+----+----+----+----+
- *
- * Reset count function: Please refer to
- * National Semiconductor datasheet (timing diagram)
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- * DM9310: Synchronous 4-Bit Counters
- *
- * +--------------+
- * CLEAR |1 ++ 16| VCC
- * CLOCK |2 15| RC (Ripple Carry)
- * A |3 14| QA
- * B |4 9310 13| QB
- * C |5 12| QC
- * D |6 11| QD
- * Enable P |7 10| Enable T
- * GND |8 9| LOAD
- * +--------------+
- *
- * Counter Sequence
- *
- * +-------++----+----+----+----+----+
- * | COUNT || QD | QC | QB | QA | RC |
- * +=======++====+====+====+====+====+
- * | 0 || 0 | 0 | 0 | 0 | 0 |
- * | 1 || 0 | 0 | 0 | 1 | 0 |
- * | 2 || 0 | 0 | 1 | 0 | 0 |
- * | 3 || 0 | 0 | 1 | 1 | 0 |
- * | 4 || 0 | 1 | 0 | 0 | 0 |
- * | 5 || 0 | 1 | 0 | 1 | 0 |
- * | 6 || 0 | 1 | 1 | 0 | 0 |
- * | 7 || 0 | 1 | 1 | 1 | 0 |
- * | 8 || 1 | 0 | 0 | 0 | 0 |
- * | 9 || 1 | 0 | 0 | 1 | 0 |
- * +-------++----+----+----+----+----+
- *
- * Reset count function: Please refer to
- * National Semiconductor datasheet (timing diagram)
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_9316_H_
#define NLD_9316_H_
#include "netlist/nl_setup.h"
-#define TTL_9316(name, cCLK, cENP, cENT, cCLRQ, cLOADQ, cA, cB, cC, cD) \
- NET_REGISTER_DEV(TTL_9316, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, ENP, cENP) \
- NET_CONNECT(name, ENT, cENT) \
- NET_CONNECT(name, CLRQ, cCLRQ) \
- NET_CONNECT(name, LOADQ, cLOADQ) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, C, cC) \
- NET_CONNECT(name, D, cD)
+// usage: TTL_9316(name, cCLK, cENP, cENT, cCLRQ, cLOADQ, cA, cB, cC, cD)
+#define TTL_9316(...) \
+ NET_REGISTER_DEVEXT(TTL_74161, __VA_ARGS__)
#define TTL_74161(...) \
NET_REGISTER_DEVEXT(TTL_74161, __VA_ARGS__)
@@ -112,16 +22,4 @@
#define TTL_9310(...) \
NET_REGISTER_DEVEXT(TTL_9310, __VA_ARGS__)
-#define TTL_9310_DIP(name) \
- NET_REGISTER_DEV(TTL_9310_DIP, name)
-
-#define TTL_9316_DIP(name) \
- NET_REGISTER_DEV(TTL_9316_DIP, name)
-
-#define TTL_74161_DIP(name) \
- NET_REGISTER_DEV(TTL_74161_DIP, name)
-
-#define TTL_74163_DIP(name) \
- NET_REGISTER_DEV(TTL_74163_DIP, name)
-
#endif /* NLD_9316_H_ */
diff --git a/src/lib/netlist/devices/nld_9316_base.hxx b/src/lib/netlist/devices/nld_9316_base.hxx
index dee25a8397f..3e8e977cb87 100644
--- a/src/lib/netlist/devices/nld_9316_base.hxx
+++ b/src/lib/netlist/devices/nld_9316_base.hxx
@@ -112,35 +112,6 @@ namespace netlist
nld_power_pins m_power_pins;
};
-
- template <typename D>
- NETLIB_OBJECT(9316_dip_base)
- {
- NETLIB_CONSTRUCTOR(9316_dip_base)
- , A(*this, "A")
- {
- this->register_subalias("1", "A.CLRQ");
- this->register_subalias("2", "A.CLK");
- this->register_subalias("3", "A.A");
- this->register_subalias("4", "A.B");
- this->register_subalias("5", "A.C");
- this->register_subalias("6", "A.D");
- this->register_subalias("7", "A.ENP");
- this->register_subalias("8", "A.GND");
-
- this->register_subalias("9", "A.LOADQ");
- this->register_subalias("10", "A.ENT");
- this->register_subalias("11", "A.QD");
- this->register_subalias("12", "A.QC");
- this->register_subalias("13", "A.QB");
- this->register_subalias("14", "A.QA");
- this->register_subalias("15", "A.RC");
- this->register_subalias("16", "A.VCC");
- }
- private:
- NETLIB_SUB(9316_base)<D> A;
- };
-
struct desc_9316 : public desc_base
{
using ASYNC = desc_const_t<bool, true>;
@@ -183,10 +154,5 @@ namespace netlist
using NETLIB_NAME(74161_fixme) = NETLIB_NAME(9316_base)<desc_74161>;
using NETLIB_NAME(74163) = NETLIB_NAME(9316_base)<desc_74163>;
- using NETLIB_NAME(9310_dip) = NETLIB_NAME(9316_dip_base)<desc_9310>;
- using NETLIB_NAME(9316_dip) = NETLIB_NAME(9316_dip_base)<desc_9316>;
- using NETLIB_NAME(74161_dip) = NETLIB_NAME(9316_dip_base)<desc_74161>;
- using NETLIB_NAME(74163_dip) = NETLIB_NAME(9316_dip_base)<desc_74163>;
-
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_9322.cpp b/src/lib/netlist/devices/nld_9322.cpp
index 8c7742360b9..11b7659b581 100644
--- a/src/lib/netlist/devices/nld_9322.cpp
+++ b/src/lib/netlist/devices/nld_9322.cpp
@@ -3,6 +3,19 @@
/*
* nld_9322.cpp
*
+ * 9322: Quad 2-Line to 1-Line Data Selectors/Multiplexers
+ *
+ * +------------+
+ * SELECT |1 ++ 16| VCC
+ * A1 |2 15| STROBE
+ * B1 |3 14| A4
+ * Y1 |4 9322 13| B4
+ * A2 |5 12| Y4
+ * B2 |6 11| A3
+ * Y2 |7 10| B3
+ * GND |8 9| Y3
+ * +------------+
+ *
*/
#include "nld_9322.h"
@@ -14,24 +27,34 @@ namespace netlist
{
class NETLIB_NAME(9322);
- NETLIB_OBJECT(9322_selector)
+ NETLIB_OBJECT(9322_GATE)
{
- NETLIB_CONSTRUCTOR(9322_selector)
- , m_parent(owner)
+ NETLIB_CONSTRUCTOR(9322_GATE)
, m_A(*this, "A", NETLIB_DELEGATE(inputs))
, m_B(*this, "B", NETLIB_DELEGATE(inputs))
+ , m_SELECT(*this, "SELECT", NETLIB_DELEGATE(inputs))
+ , m_STROBE(*this, "STROBE", NETLIB_DELEGATE(inputs))
, m_Y(*this, "Y")
, m_power_pins(*this)
{
}
// FIXME: Timing
- NETLIB_HANDLERI(inputs);
+ NETLIB_HANDLERI(inputs)
+ {
+ if (m_STROBE())
+ m_Y.push(0, NLTIME_FROM_NS(21));
+ else if (m_SELECT())
+ m_Y.push(m_B(), NLTIME_FROM_NS(14));
+ else
+ m_Y.push(m_A(), NLTIME_FROM_NS(14));
+ }
public:
- NETLIB_NAME(9322) &m_parent;
logic_input_t m_A;
logic_input_t m_B;
+ logic_input_t m_SELECT;
+ logic_input_t m_STROBE;
logic_output_t m_Y;
nld_power_pins m_power_pins;
};
@@ -39,8 +62,6 @@ namespace netlist
NETLIB_OBJECT(9322)
{
NETLIB_CONSTRUCTOR(9322)
- , m_SELECT(*this, "SELECT", NETLIB_DELEGATE(inputs))
- , m_STROBE(*this, "STROBE", NETLIB_DELEGATE(inputs))
, m_1(*this, "A")
, m_2(*this, "B")
, m_3(*this, "C")
@@ -65,73 +86,29 @@ namespace netlist
connect("A.GND", "B.GND");
connect("A.GND", "C.GND");
connect("A.GND", "D.GND");
-
+ connect("A.SELECT", "B.SELECT");
+ connect("A.SELECT", "C.SELECT");
+ connect("A.SELECT", "D.SELECT");
+ connect("A.STROBE", "B.STROBE");
+ connect("A.STROBE", "C.STROBE");
+ connect("A.STROBE", "D.STROBE");
+
+ register_subalias("SELECT", "A.SELECT");
+ register_subalias("STROBE", "A.STROBE");
register_subalias("GND", "A.GND");
register_subalias("VCC", "B.VCC");
-
}
- friend class NETLIB_NAME(9322_dip);
- public:
- logic_input_t m_SELECT;
- logic_input_t m_STROBE;
private:
- NETLIB_HANDLERI(inputs)
- {
- m_1.inputs();
- m_2.inputs();
- m_3.inputs();
- m_4.inputs();
- }
+ NETLIB_SUB(9322_GATE) m_1;
+ NETLIB_SUB(9322_GATE) m_2;
+ NETLIB_SUB(9322_GATE) m_3;
+ NETLIB_SUB(9322_GATE) m_4;
- NETLIB_SUB(9322_selector) m_1;
- NETLIB_SUB(9322_selector) m_2;
- NETLIB_SUB(9322_selector) m_3;
- NETLIB_SUB(9322_selector) m_4;
-
- };
-
- NETLIB_HANDLER(9322_selector, inputs)
- {
- if (m_parent.m_STROBE())
- m_Y.push(0, NLTIME_FROM_NS(21));
- else if (m_parent.m_SELECT())
- m_Y.push(m_B(), NLTIME_FROM_NS(14));
- else
- m_Y.push(m_A(), NLTIME_FROM_NS(14));
- }
-
- NETLIB_OBJECT(9322_dip)
- {
- NETLIB_CONSTRUCTOR(9322_dip)
- , A(*this, "A")
- {
- register_subalias("1", A.m_SELECT);
- register_subalias("2", A.m_1.m_A);
- register_subalias("3", A.m_1.m_B);
- register_subalias("4", A.m_1.m_Y);
- register_subalias("5", A.m_2.m_A);
- register_subalias("6", A.m_2.m_B);
- register_subalias("7", A.m_2.m_Y);
- register_subalias("8", "A.GND");
-
- register_subalias("9", A.m_3.m_Y);
- register_subalias("10", A.m_3.m_B);
- register_subalias("11", A.m_3.m_A);
- register_subalias("12", A.m_4.m_Y);
- register_subalias("13", A.m_4.m_B);
- register_subalias("14", A.m_4.m_A);
- register_subalias("15", A.m_STROBE);
- register_subalias("16", "A.VCC");
- }
-
- //NETLIB_RESETI() {}
- private:
- NETLIB_SUB(9322) A;
};
- NETLIB_DEVICE_IMPL(9322, "TTL_9322", "+SELECT,+A1,+B1,+A2,+B2,+A3,+B3,+A4,+B4,+STROBE,@VCC,@GND")
- NETLIB_DEVICE_IMPL(9322_dip, "TTL_9322_DIP", "")
+ NETLIB_DEVICE_IMPL(9322_GATE, "TTL_9322_GATE", "")
+ NETLIB_DEVICE_IMPL(9322, "TTL_9322", "+SELECT,+A1,+B1,+A2,+B2,+A3,+B3,+A4,+B4,+STROBE,@VCC,@GND")
} //namespace devices
} // namespace netlist
diff --git a/src/lib/netlist/devices/nld_9322.h b/src/lib/netlist/devices/nld_9322.h
index e55c73847b3..d53d0c210e5 100644
--- a/src/lib/netlist/devices/nld_9322.h
+++ b/src/lib/netlist/devices/nld_9322.h
@@ -1,44 +1,16 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_9322.h
- *
- * 9322: Quad 2-Line to 1-Line Data Selectors/Multiplexers
- *
- * +------------+
- * SELECT |1 ++ 16| VCC
- * A1 |2 15| STROBE
- * B1 |3 14| A4
- * Y1 |4 9322 13| B4
- * A2 |5 12| Y4
- * B2 |6 11| A3
- * Y2 |7 10| B3
- * GND |8 9| Y3
- * +------------+
- *
- */
#ifndef NLD_9322_H_
#define NLD_9322_H_
#include "netlist/nl_setup.h"
-#define TTL_9322(name, cSELECT, cA1, cB1, cA2, cB2, cA3, cB3, cA4, cB4, cSTROBE) \
- NET_REGISTER_DEV(TTL_9322, name) \
- NET_CONNECT(name, SELECT, cSELECT) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, A1, cA1) \
- NET_CONNECT(name, B1, cB1) \
- NET_CONNECT(name, A2, cA2) \
- NET_CONNECT(name, B2, cB2) \
- NET_CONNECT(name, A3, cA3) \
- NET_CONNECT(name, B3, cB3) \
- NET_CONNECT(name, A4, cA4) \
- NET_CONNECT(name, B4, cB4) \
- NET_CONNECT(name, STROBE, cSTROBE)
+#define TTL_9322_GATE(...) \
+ NET_REGISTER_DEVEXT(TTL_9322_GATE, __VA_ARGS__)
-#define TTL_9322_DIP(name) \
- NET_REGISTER_DEV(TTL_9322_DIP, name)
+// usage: TTL_9322(name, cSELECT, cA1, cB1, cA2, cB2, cA3, cB3, cA4, cB4, cSTROBE)
+#define TTL_9322(...) \
+ NET_REGISTER_DEVEXT(TTL_9322, __VA_ARGS__)
#endif /* NLD_9322_H_ */
diff --git a/src/lib/netlist/devices/nld_am2847.cpp b/src/lib/netlist/devices/nld_am2847.cpp
index 7dff2cdb07e..0b0b321efa4 100644
--- a/src/lib/netlist/devices/nld_am2847.cpp
+++ b/src/lib/netlist/devices/nld_am2847.cpp
@@ -3,6 +3,19 @@
/*
* nld_am2847.cpp
*
+ * Am2847: Quad 80-Bit Static Shift Register
+ *
+ * +--------------+
+ * OUTA |1 ++ 16| VSS
+ * RCA |2 15| IND
+ * INA |3 14| RCD
+ * OUTB |4 Am2847 13| OUTD
+ * RCB |5 12| VGG
+ * INB |6 11| CP
+ * OUTC |7 10| INC
+ * VDD |8 9| RCC
+ * +--------------+
+ *
*/
#include "nld_am2847.h"
diff --git a/src/lib/netlist/devices/nld_am2847.h b/src/lib/netlist/devices/nld_am2847.h
index f1347545984..bad7331e8f6 100644
--- a/src/lib/netlist/devices/nld_am2847.h
+++ b/src/lib/netlist/devices/nld_am2847.h
@@ -1,22 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_am2847.h
- *
- * Am2847: Quad 80-Bit Static Shift Register
- *
- * +--------------+
- * OUTA |1 ++ 16| VSS
- * RCA |2 15| IND
- * INA |3 14| RCD
- * OUTB |4 Am2847 13| OUTD
- * RCB |5 12| VGG
- * INB |6 11| CP
- * OUTC |7 10| INC
- * VDD |8 9| RCC
- * +--------------+
- *
- */
#ifndef NLD_AM2847_H_
#define NLD_AM2847_H_
diff --git a/src/lib/netlist/devices/nld_devinc.h b/src/lib/netlist/devices/nld_devinc.h
index 46afe121fdb..c43bf9dbcd5 100644
--- a/src/lib/netlist/devices/nld_devinc.h
+++ b/src/lib/netlist/devices/nld_devinc.h
@@ -148,7 +148,7 @@
#define CLOCK(...) \
NET_REGISTER_DEVEXT(CLOCK, __VA_ARGS__)
-// usage : VARCLOCK(name, pFUNC)
+// usage : VARCLOCK(name, pN, pFUNC)
#define VARCLOCK(...) \
NET_REGISTER_DEVEXT(VARCLOCK, __VA_ARGS__)
@@ -228,10 +228,6 @@
#define RAM_2102A(...) \
NET_REGISTER_DEVEXT(RAM_2102A, __VA_ARGS__)
-// usage : RAM_2102A_DIP(name)
-#define RAM_2102A_DIP(...) \
- NET_REGISTER_DEVEXT(RAM_2102A_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_roms.cpp
// ---------------------------------------------------------------------
@@ -248,22 +244,6 @@
#define TTL_7448(...) \
NET_REGISTER_DEVEXT(TTL_7448, __VA_ARGS__)
-// usage : TTL_7448_DIP(name)
-#define TTL_7448_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7448_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_7442.cpp
-// ---------------------------------------------------------------------
-// usage : TTL_7442(name, pA, pB, pC, pD)
-// auto connect: VCC, GND
-#define TTL_7442(...) \
- NET_REGISTER_DEVEXT(TTL_7442, __VA_ARGS__)
-
-// usage : TTL_7442_DIP(name)
-#define TTL_7442_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7442_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7450.cpp
// ---------------------------------------------------------------------
@@ -272,10 +252,6 @@
#define TTL_7450_ANDORINVERT(...) \
NET_REGISTER_DEVEXT(TTL_7450_ANDORINVERT, __VA_ARGS__)
-// usage : TTL_7450_DIP(name)
-#define TTL_7450_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7450_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7473.cpp
// ---------------------------------------------------------------------
@@ -284,19 +260,11 @@
#define TTL_7473(...) \
NET_REGISTER_DEVEXT(TTL_7473, __VA_ARGS__)
-// usage : TTL_7473_DIP(name)
-#define TTL_7473_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7473_DIP, __VA_ARGS__)
-
// usage : TTL_7473A(name, pCLK, pJ, pK, pCLRQ)
// auto connect: VCC, GND
#define TTL_7473A(...) \
NET_REGISTER_DEVEXT(TTL_7473A, __VA_ARGS__)
-// usage : TTL_7473A_DIP(name)
-#define TTL_7473A_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7473A_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7474.cpp
// ---------------------------------------------------------------------
@@ -316,18 +284,10 @@
#define TTL_7475(...) \
NET_REGISTER_DEVEXT(TTL_7475, __VA_ARGS__)
-// usage : TTL_7475_DIP(name)
-#define TTL_7475_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7475_DIP, __VA_ARGS__)
-
// usage : TTL_7477(name)
#define TTL_7477(...) \
NET_REGISTER_DEVEXT(TTL_7477, __VA_ARGS__)
-// usage : TTL_7477_DIP(name)
-#define TTL_7477_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7477_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7483.cpp
// ---------------------------------------------------------------------
@@ -336,10 +296,6 @@
#define TTL_7483(...) \
NET_REGISTER_DEVEXT(TTL_7483, __VA_ARGS__)
-// usage : TTL_7483_DIP(name)
-#define TTL_7483_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7483_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7485.cpp
// ---------------------------------------------------------------------
@@ -348,10 +304,6 @@
#define TTL_7485(...) \
NET_REGISTER_DEVEXT(TTL_7485, __VA_ARGS__)
-// usage : TTL_7485_DIP(name)
-#define TTL_7485_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7485_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7490.cpp
// ---------------------------------------------------------------------
@@ -360,10 +312,6 @@
#define TTL_7490(...) \
NET_REGISTER_DEVEXT(TTL_7490, __VA_ARGS__)
-// usage : TTL_7490_DIP(name)
-#define TTL_7490_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7490_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7492.cpp
// ---------------------------------------------------------------------
@@ -372,10 +320,6 @@
#define TTL_7492(...) \
NET_REGISTER_DEVEXT(TTL_7492, __VA_ARGS__)
-// usage : TTL_7492_DIP(name)
-#define TTL_7492_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7492_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7493.cpp
// ---------------------------------------------------------------------
@@ -384,10 +328,6 @@
#define TTL_7493(...) \
NET_REGISTER_DEVEXT(TTL_7493, __VA_ARGS__)
-// usage : TTL_7493_DIP(name)
-#define TTL_7493_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7493_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_7497.cpp
// ---------------------------------------------------------------------
@@ -396,10 +336,6 @@
#define TTL_7497(...) \
NET_REGISTER_DEVEXT(TTL_7497, __VA_ARGS__)
-// usage : TTL_7497_DIP(name)
-#define TTL_7497_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_7497_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74107.cpp
// ---------------------------------------------------------------------
@@ -408,10 +344,6 @@
#define TTL_74107(...) \
NET_REGISTER_DEVEXT(TTL_74107, __VA_ARGS__)
-// usage : TTL_74107_DIP(name)
-#define TTL_74107_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74107_DIP, __VA_ARGS__)
-
// usage : TTL_74107A(name, pCLK, pJ, pK, pCLRQ)
// auto connect: VCC, GND
#define TTL_74107A(...) \
@@ -425,30 +357,22 @@
#define TTL_74113(...) \
NET_REGISTER_DEVEXT(TTL_74113, __VA_ARGS__)
-// usage : TTL_74113_DIP(name)
-#define TTL_74113_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74113_DIP, __VA_ARGS__)
-
// usage : TTL_74113A(name, pCLK, pJ, pK, pCLRQ)
// auto connect: VCC, GND
#define TTL_74113A(...) \
NET_REGISTER_DEVEXT(TTL_74113A, __VA_ARGS__)
-// usage : TTL_74113A_DIP(name)
-#define TTL_74113A_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74113A_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74123.cpp
// ---------------------------------------------------------------------
+// usage : TTL_74121(name)
+#define TTL_74121(...) \
+ NET_REGISTER_DEVEXT(TTL_74121, __VA_ARGS__)
+
// usage : TTL_74123(name)
#define TTL_74123(...) \
NET_REGISTER_DEVEXT(TTL_74123, __VA_ARGS__)
-// usage : TTL_74123_DIP(name)
-#define TTL_74123_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74123_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74125.cpp
// ---------------------------------------------------------------------
@@ -468,34 +392,27 @@
#define TTL_74153(...) \
NET_REGISTER_DEVEXT(TTL_74153, __VA_ARGS__)
-// usage : TTL_74153_DIP(name)
-#define TTL_74153_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74153_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74161.cpp
// ---------------------------------------------------------------------
-// usage : TTL_74161(name, pA, pB, pC, pD, pCLRQ, pLOADQ, pCLK, pENABLEP, pENABLET)
+// usage : TTL_74161(name, pCLK, pENP, pENT, pCLRQ, pLOADQ, pA, pB, pC, pD)
// auto connect: VCC, GND
#define TTL_74161(...) \
NET_REGISTER_DEVEXT(TTL_74161, __VA_ARGS__)
-// usage : TTL_74161_DIP(name)
-#define TTL_74161_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74161_DIP, __VA_ARGS__)
+// usage : TTL_74161_FIXME(name, pA, pB, pC, pD, pCLRQ, pLOADQ, pCLK, pENP, pENT)
+// auto connect: VCC, GND
+#define TTL_74161_FIXME(...) \
+ NET_REGISTER_DEVEXT(TTL_74161_FIXME, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_9316.cpp
+// Source: src/lib/netlist/devices/nld_74163.cpp
// ---------------------------------------------------------------------
// usage : TTL_74163(name, pCLK, pENP, pENT, pCLRQ, pLOADQ, pA, pB, pC, pD)
// auto connect: VCC, GND
#define TTL_74163(...) \
NET_REGISTER_DEVEXT(TTL_74163, __VA_ARGS__)
-// usage : TTL_74163_DIP(name)
-#define TTL_74163_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74163_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74164.cpp
// ---------------------------------------------------------------------
@@ -504,10 +421,6 @@
#define TTL_74164(...) \
NET_REGISTER_DEVEXT(TTL_74164, __VA_ARGS__)
-// usage : TTL_74164_DIP(name)
-#define TTL_74164_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74164_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74165.cpp
// ---------------------------------------------------------------------
@@ -516,10 +429,6 @@
#define TTL_74165(...) \
NET_REGISTER_DEVEXT(TTL_74165, __VA_ARGS__)
-// usage : TTL_74165_DIP(name)
-#define TTL_74165_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74165_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74166.cpp
// ---------------------------------------------------------------------
@@ -528,13 +437,13 @@
#define TTL_74166(...) \
NET_REGISTER_DEVEXT(TTL_74166, __VA_ARGS__)
-// usage : TTL_74166_DIP(name)
-#define TTL_74166_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74166_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74174.cpp
// ---------------------------------------------------------------------
+// usage : TTL_74174_GATE(name)
+#define TTL_74174_GATE(...) \
+ NET_REGISTER_DEVEXT(TTL_74174, __VA_ARGS__)
+
// usage : TTL_74174(name, pCLK, pD1, pD2, pD3, pD4, pD5, pD6, pCLRQ)
// auto connect: VCC, GND
#define TTL_74174(...) \
@@ -595,10 +504,6 @@
#define TTL_74393(...) \
NET_REGISTER_DEVEXT(TTL_74393, __VA_ARGS__)
-// usage : TTL_74393_DIP(name)
-#define TTL_74393_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74393_DIP, __VA_ARGS__)
-
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74ls629.cpp
// ---------------------------------------------------------------------
@@ -690,14 +595,21 @@
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_4006.cpp
// ---------------------------------------------------------------------
-// usage : CD4006(name, pCLOCK, pD1, pD2, pD3, pD4, pD1P4, pD1P4S, pD2P4, pD2P5, pD3P4, pD4P4, pD3P5)
+// usage : CD4006(name, pCLOCK, pD1, pD2, pD3, pD4, pD1P4, pD1P4S, pD2P4, pD2P5, pD3P4, pD4P4, pD4P5)
// auto connect: VCC, GND
#define CD4006(...) \
NET_REGISTER_DEVEXT(CD4006, __VA_ARGS__)
-// usage : CD4006_DIP(name)
-#define CD4006_DIP(...) \
- NET_REGISTER_DEVEXT(CD4006_DIP, __VA_ARGS__)
+// ---------------------------------------------------------------------
+// Source: src/lib/netlist/devices/nld_4017.cpp
+// ---------------------------------------------------------------------
+// usage : CD4017(name)
+#define CD4017(...) \
+ NET_REGISTER_DEVEXT(CD4017, __VA_ARGS__)
+
+// usage : CD4022(name)
+#define CD4022(...) \
+ NET_REGISTER_DEVEXT(CD4022, __VA_ARGS__)
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_4020.cpp
@@ -710,6 +622,17 @@
#define CD4020(...) \
NET_REGISTER_DEVEXT(CD4020, __VA_ARGS__)
+// usage : CD4024(name)
+#define CD4024(...) \
+ NET_REGISTER_DEVEXT(CD4024, __VA_ARGS__)
+
+// ---------------------------------------------------------------------
+// Source: src/lib/netlist/devices/nld_4053.cpp
+// ---------------------------------------------------------------------
+// usage : CD4053_GATE(name)
+#define CD4053_GATE(...) \
+ NET_REGISTER_DEVEXT(CD4053_GATE, __VA_ARGS__)
+
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_4066.cpp
// ---------------------------------------------------------------------
@@ -727,9 +650,9 @@
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74123.cpp
// ---------------------------------------------------------------------
-// usage : CD4538_DIP(name)
-#define CD4538_DIP(...) \
- NET_REGISTER_DEVEXT(CD4538_DIP, __VA_ARGS__)
+// usage : CD4538(name)
+#define CD4538(...) \
+ NET_REGISTER_DEVEXT(CD4538, __VA_ARGS__)
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_schmitt.cpp
@@ -788,13 +711,6 @@
NET_REGISTER_DEVEXT(TTL_TRISTATE3, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_74174.cpp
-// ---------------------------------------------------------------------
-// usage : TTL_74174_DIP(name)
-#define TTL_74174_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_74174_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74175.cpp
// ---------------------------------------------------------------------
// usage : TTL_74175_DIP(name)
@@ -830,32 +746,11 @@
NET_REGISTER_DEVEXT(TTL_74365_DIP, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_82S16.cpp
-// ---------------------------------------------------------------------
-// usage : TTL_82S16_DIP(name)
-#define TTL_82S16_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_82S16_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_82S115.cpp
-// ---------------------------------------------------------------------
-// usage : PROM_82S115_DIP(name)
-#define PROM_82S115_DIP(...) \
- NET_REGISTER_DEVEXT(PROM_82S115_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_74123.cpp
// ---------------------------------------------------------------------
-// usage : TTL_9602_DIP(name)
-#define TTL_9602_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_9602_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_9310.cpp
-// ---------------------------------------------------------------------
-// usage : TTL_9310_DIP(name)
-#define TTL_9310_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_9310_DIP, __VA_ARGS__)
+// usage : TTL_9602(name)
+#define TTL_9602(...) \
+ NET_REGISTER_DEVEXT(TTL_9602, __VA_ARGS__)
// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_dm9314.cpp
@@ -865,20 +760,6 @@
NET_REGISTER_DEVEXT(TTL_9314_DIP, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_9316.cpp
-// ---------------------------------------------------------------------
-// usage : TTL_9316_DIP(name)
-#define TTL_9316_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_9316_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_9322.cpp
-// ---------------------------------------------------------------------
-// usage : TTL_9322_DIP(name)
-#define TTL_9322_DIP(...) \
- NET_REGISTER_DEVEXT(TTL_9322_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_dm9334.cpp
// ---------------------------------------------------------------------
// usage : TTL_9334_DIP(name)
@@ -893,13 +774,6 @@
NET_REGISTER_DEVEXT(TTL_AM2847_DIP, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/devices/nld_74ls629.cpp
-// ---------------------------------------------------------------------
-// usage : SN74LS629_DIP(name, p1_CAP1, p2_CAP2)
-#define SN74LS629_DIP(...) \
- NET_REGISTER_DEVEXT(SN74LS629_DIP, __VA_ARGS__)
-
-// ---------------------------------------------------------------------
// Source: src/lib/netlist/devices/nld_mm5837.cpp
// ---------------------------------------------------------------------
// usage : MM5837_DIP(name)
@@ -907,7 +781,7 @@
NET_REGISTER_DEVEXT(MM5837_DIP, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/macro/nlm_ttl74xx.cpp
+// Source: TTL74XX_lib
// ---------------------------------------------------------------------
// usage : TTL_7400_GATE(name)
#define TTL_7400_GATE(...) \
@@ -940,6 +814,10 @@
#define TTL_7406_GATE(...) \
NET_REGISTER_DEVEXT(TTL_7406_GATE, __VA_ARGS__)
+// usage : TTL_7407_GATE(name)
+#define TTL_7407_GATE(...) \
+ NET_REGISTER_DEVEXT(TTL_7407_GATE, __VA_ARGS__)
+
// usage : TTL_7408_GATE(name)
#define TTL_7408_GATE(...) \
NET_REGISTER_DEVEXT(TTL_7408_GATE, __VA_ARGS__)
@@ -986,7 +864,7 @@
// usage : TTL_7421_AND(name, pA, pB, pC, pD)
// auto connect: VCC, GND
-#define TTL_7421_AND(...) \
+#define TTL_7421_AND(...) \
NET_REGISTER_DEVEXT(TTL_7421_AND, __VA_ARGS__)
// usage : TTL_7425_GATE(name)
@@ -1033,6 +911,38 @@
#define TTL_7437_NAND(...) \
NET_REGISTER_DEVEXT(TTL_7437_NAND, __VA_ARGS__)
+// usage : TTL_7448_DIP(name)
+#define TTL_7448_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7448_DIP, __VA_ARGS__)
+
+// usage : TTL_7450_DIP(name)
+#define TTL_7450_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7450_DIP, __VA_ARGS__)
+
+// usage : TTL_7473_DIP(name)
+#define TTL_7473_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7473_DIP, __VA_ARGS__)
+
+// usage : TTL_7473A_DIP(name)
+#define TTL_7473A_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7473A_DIP, __VA_ARGS__)
+
+// usage : TTL_7475_DIP(name)
+#define TTL_7475_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7475_DIP, __VA_ARGS__)
+
+// usage : TTL_7477_DIP(name)
+#define TTL_7477_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7477_DIP, __VA_ARGS__)
+
+// usage : TTL_7483_DIP(name)
+#define TTL_7483_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7483_DIP, __VA_ARGS__)
+
+// usage : TTL_7485_DIP(name)
+#define TTL_7485_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7485_DIP, __VA_ARGS__)
+
// usage : TTL_7486_GATE(name)
#define TTL_7486_GATE(...) \
NET_REGISTER_DEVEXT(TTL_7486_GATE, __VA_ARGS__)
@@ -1042,6 +952,38 @@
#define TTL_7486_XOR(...) \
NET_REGISTER_DEVEXT(TTL_7486_XOR, __VA_ARGS__)
+// usage : TTL_7490_DIP(name)
+#define TTL_7490_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7490_DIP, __VA_ARGS__)
+
+// usage : TTL_7492_DIP(name)
+#define TTL_7492_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7492_DIP, __VA_ARGS__)
+
+// usage : TTL_7493_DIP(name)
+#define TTL_7493_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7493_DIP, __VA_ARGS__)
+
+// usage : TTL_7497_DIP(name)
+#define TTL_7497_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7497_DIP, __VA_ARGS__)
+
+// usage : TTL_74107_DIP(name)
+#define TTL_74107_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74107_DIP, __VA_ARGS__)
+
+// usage : TTL_74107_DIP(name)
+#define TTL_74107A_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74107A_DIP, __VA_ARGS__)
+
+// usage : TTL_74113_DIP(name)
+#define TTL_74113_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74113_DIP, __VA_ARGS__)
+
+// usage : TTL_74113A_DIP(name)
+#define TTL_74113A_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74113A_DIP, __VA_ARGS__)
+
// usage : TTL_74155A_GATE(name)
#define TTL_74155A_GATE(...) \
NET_REGISTER_DEVEXT(TTL_74155A_GATE, __VA_ARGS__)
@@ -1062,6 +1004,30 @@
#define TTL_74157_GATE(...) \
NET_REGISTER_DEVEXT(TTL_74157_GATE, __VA_ARGS__)
+// usage : TTL_74161_DIP(name)
+#define TTL_74161_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74161_DIP, __VA_ARGS__)
+
+// usage : TTL_74163_DIP(name)
+#define TTL_74163_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74163_DIP, __VA_ARGS__)
+
+// usage : TTL_74164_DIP(name)
+#define TTL_74164_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74164_DIP, __VA_ARGS__)
+
+// usage : TTL_74165_DIP(name)
+#define TTL_74165_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74165_DIP, __VA_ARGS__)
+
+// usage : TTL_74165_DIP(name)
+#define TTL_74166_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74166_DIP, __VA_ARGS__)
+
+// usage : TTL_74174_DIP(name)
+#define TTL_74174_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74174_DIP, __VA_ARGS__)
+
// usage : TTL_74260_GATE(name)
#define TTL_74260_GATE(...) \
NET_REGISTER_DEVEXT(TTL_74260_GATE, __VA_ARGS__)
@@ -1079,11 +1045,14 @@
#define TTL_74279B(...) \
NET_REGISTER_DEVEXT(TTL_74279B, __VA_ARGS__)
-// usage : DM9312(name, pA, pB, pC, pG, pD0, pD1, pD2, pD3, pD4, pD5, pD6, pD7)
+// usage : TTL_9312(name, pA, pB, pC, pG, pD0, pD1, pD2, pD3, pD4, pD5, pD6, pD7)
// auto connect: VCC, GND
-#define DM9312(...) \
- NET_REGISTER_DEVEXT(DM9312, __VA_ARGS__)
+#define TTL_9312(...) \
+ NET_REGISTER_DEVEXT(TTL_9312, __VA_ARGS__)
+// ---------------------------------------------------------------------
+// Source: parser: TTL74XX_lib
+// ---------------------------------------------------------------------
// usage : TTL_7400_DIP(name)
#define TTL_7400_DIP(...) \
NET_REGISTER_DEVEXT(TTL_7400_DIP, __VA_ARGS__)
@@ -1100,6 +1069,10 @@
#define TTL_7406_DIP(...) \
NET_REGISTER_DEVEXT(TTL_7406_DIP, __VA_ARGS__)
+// usage : TTL_7407_DIP(name)
+#define TTL_7407_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7407_DIP, __VA_ARGS__)
+
// usage : TTL_7408_DIP(name)
#define TTL_7408_DIP(...) \
NET_REGISTER_DEVEXT(TTL_7408_DIP, __VA_ARGS__)
@@ -1160,10 +1133,30 @@
#define TTL_7437_DIP(...) \
NET_REGISTER_DEVEXT(TTL_7437_DIP, __VA_ARGS__)
+// usage : TTL_7442(name, cA, cB, cC, cD)
+#define TTL_7442(...) \
+ NET_REGISTER_DEVEXT(TTL_7442, __VA_ARGS__)
+
+// usage : TTL_7442_DIP(name)
+#define TTL_7442_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_7442_DIP, __VA_ARGS__)
+
// usage : TTL_7486_DIP(name)
#define TTL_7486_DIP(...) \
NET_REGISTER_DEVEXT(TTL_7486_DIP, __VA_ARGS__)
+// usage : TTL_74121_DIP(name)
+#define TTL_74121_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74121_DIP, __VA_ARGS__)
+
+// usage : TTL_74123_DIP(name)
+#define TTL_74123_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74123_DIP, __VA_ARGS__)
+
+// usage : TTL_9602_DIP(name)
+#define TTL_9602_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_9602_DIP, __VA_ARGS__)
+
// usage : TTL_74125_DIP(name)
#define TTL_74125_DIP(...) \
NET_REGISTER_DEVEXT(TTL_74125_DIP, __VA_ARGS__)
@@ -1172,6 +1165,10 @@
#define TTL_74126_DIP(...) \
NET_REGISTER_DEVEXT(TTL_74126_DIP, __VA_ARGS__)
+// usage : TTL_74153_DIP(name)
+#define TTL_74153_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74153_DIP, __VA_ARGS__)
+
// usage : TTL_74155_DIP(name)
#define TTL_74155_DIP(...) \
NET_REGISTER_DEVEXT(TTL_74155_DIP, __VA_ARGS__)
@@ -1204,17 +1201,41 @@
#define TTL_74379_DIP(...) \
NET_REGISTER_DEVEXT(TTL_74379_DIP, __VA_ARGS__)
-// usage : DM9312_DIP(name)
-#define DM9312_DIP(...) \
- NET_REGISTER_DEVEXT(DM9312_DIP, __VA_ARGS__)
+// usage : TTL_74393_DIP(name)
+#define TTL_74393_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_74393_DIP, __VA_ARGS__)
+
+// usage : SN74LS629_DIP(name, p1_CAP1, p2_CAP2)
+#define SN74LS629_DIP(...) \
+ NET_REGISTER_DEVEXT(SN74LS629_DIP, __VA_ARGS__)
+
+// usage : TTL_9312_DIP(name)
+#define TTL_9312_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_9312_DIP, __VA_ARGS__)
+
+// usage : TTL_9310_DIP(name)
+#define TTL_9310_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_9310_DIP, __VA_ARGS__)
+
+// usage : TTL_9316_DIP(name)
+#define TTL_9316_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_9316_DIP, __VA_ARGS__)
+
+// usage : TTL_9322_DIP(name)
+#define TTL_9322_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_9322_DIP, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/macro/nlm_cd4xxx.cpp
+// Source: CD4XXX_lib
// ---------------------------------------------------------------------
// usage : CD4001_GATE(name)
#define CD4001_GATE(...) \
NET_REGISTER_DEVEXT(CD4001_GATE, __VA_ARGS__)
+// usage : CD4011_GATE(name)
+#define CD4011_GATE(...) \
+ NET_REGISTER_DEVEXT(CD4011_GATE, __VA_ARGS__)
+
// usage : CD4069_GATE(name)
#define CD4069_GATE(...) \
NET_REGISTER_DEVEXT(CD4069_GATE, __VA_ARGS__)
@@ -1223,10 +1244,21 @@
#define CD4070_GATE(...) \
NET_REGISTER_DEVEXT(CD4070_GATE, __VA_ARGS__)
+// ---------------------------------------------------------------------
+// Source: parser: CD4XXX_lib
+// ---------------------------------------------------------------------
// usage : CD4001_DIP(name)
#define CD4001_DIP(...) \
NET_REGISTER_DEVEXT(CD4001_DIP, __VA_ARGS__)
+// usage : CD4006_DIP(name)
+#define CD4006_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4006_DIP, __VA_ARGS__)
+
+// usage : CD4011_DIP(name)
+#define CD4011_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4011_DIP, __VA_ARGS__)
+
// usage : CD4069_DIP(name)
#define CD4069_DIP(...) \
NET_REGISTER_DEVEXT(CD4069_DIP, __VA_ARGS__)
@@ -1235,24 +1267,48 @@
#define CD4070_DIP(...) \
NET_REGISTER_DEVEXT(CD4070_DIP, __VA_ARGS__)
+// usage : CD4013_DIP(name)
+#define CD4013_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4013_DIP, __VA_ARGS__)
+
+// usage : CD4017_DIP(name)
+#define CD4017_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4017_DIP, __VA_ARGS__)
+
+// usage : CD4022_DIP(name)
+#define CD4022_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4022_DIP, __VA_ARGS__)
+
// usage : CD4020_DIP(name)
#define CD4020_DIP(...) \
NET_REGISTER_DEVEXT(CD4020_DIP, __VA_ARGS__)
-// usage : CD4016_DIP(name)
-#define CD4016_DIP(...) \
- NET_REGISTER_DEVEXT(CD4016_DIP, __VA_ARGS__)
+// usage : CD4024_DIP(name)
+#define CD4024_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4024_DIP, __VA_ARGS__)
+
+// usage : CD4053_DIP(name)
+#define CD4053_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4053_DIP, __VA_ARGS__)
// usage : CD4066_DIP(name)
#define CD4066_DIP(...) \
NET_REGISTER_DEVEXT(CD4066_DIP, __VA_ARGS__)
+// usage : CD4016_DIP(name)
+#define CD4016_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4016_DIP, __VA_ARGS__)
+
// usage : CD4316_DIP(name)
#define CD4316_DIP(...) \
NET_REGISTER_DEVEXT(CD4316_DIP, __VA_ARGS__)
+// usage : CD4538_DIP(name)
+#define CD4538_DIP(...) \
+ NET_REGISTER_DEVEXT(CD4538_DIP, __VA_ARGS__)
+
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/macro/nlm_opamp.cpp
+// Source: parser: OPAMP_lib
// ---------------------------------------------------------------------
// usage : opamp_layout_4_4_11(name)
#define opamp_layout_4_4_11(...) \
@@ -1327,12 +1383,15 @@
NET_REGISTER_DEVEXT(LM3900, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/macro/nlm_other.cpp
+// Source: otheric_lib
// ---------------------------------------------------------------------
// usage : MC14584B_GATE(name)
#define MC14584B_GATE(...) \
NET_REGISTER_DEVEXT(MC14584B_GATE, __VA_ARGS__)
+// ---------------------------------------------------------------------
+// Source: parser: otheric_lib
+// ---------------------------------------------------------------------
// usage : MC14584B_DIP(name)
#define MC14584B_DIP(...) \
NET_REGISTER_DEVEXT(MC14584B_DIP, __VA_ARGS__)
@@ -1342,7 +1401,7 @@
NET_REGISTER_DEVEXT(NE566_DIP, __VA_ARGS__)
// ---------------------------------------------------------------------
-// Source: src/lib/netlist/macro/nlm_roms.cpp
+// Source: parser: ROMS_lib
// ---------------------------------------------------------------------
// usage : PROM_82S123_DIP(name)
#define PROM_82S123_DIP(...) \
@@ -1360,5 +1419,18 @@
#define EPROM_2716_DIP(...) \
NET_REGISTER_DEVEXT(EPROM_2716_DIP, __VA_ARGS__)
+// usage : TTL_82S16_DIP(name)
+#define TTL_82S16_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_82S16_DIP, __VA_ARGS__)
+
+// usage : PROM_82S115_DIP(name)
+#define PROM_82S115_DIP(...) \
+ NET_REGISTER_DEVEXT(PROM_82S115_DIP, __VA_ARGS__)
+
+// usage : RAM_2102A_DIP(name)
+#define RAM_2102A_DIP(...) \
+ NET_REGISTER_DEVEXT(RAM_2102A_DIP, __VA_ARGS__)
+
+
#endif // __PLIB_PREPROCESSOR__
#endif
diff --git a/src/lib/netlist/devices/nld_dm9314.cpp b/src/lib/netlist/devices/nld_dm9314.cpp
index 2ded51abbd4..c941aadc0cf 100644
--- a/src/lib/netlist/devices/nld_dm9314.cpp
+++ b/src/lib/netlist/devices/nld_dm9314.cpp
@@ -3,6 +3,19 @@
/*
* nld_dm9314.cpp
*
+ * DM9314: 4-Bit Latches
+ *
+ * +--------------+
+ * /E |1 ++ 16| VCC
+ * /S0 |2 15| Q0
+ * D0 |3 14| /S1
+ * D1 |4 DM9314 13| Q1
+ * /S2 |5 12| Q2
+ * D2 |6 11| /S3
+ * D3 |7 10| Q3
+ * GND |8 9| /MR
+ * +--------------+
+ *
*/
#include "nld_dm9314.h"
diff --git a/src/lib/netlist/devices/nld_dm9314.h b/src/lib/netlist/devices/nld_dm9314.h
index 73edfaa1205..4fc855c40b2 100644
--- a/src/lib/netlist/devices/nld_dm9314.h
+++ b/src/lib/netlist/devices/nld_dm9314.h
@@ -1,22 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Felipe Sanches
-/*
- * nld_DM9314.h
- *
- * DM9314: 4-Bit Latches
- *
- * +--------------+
- * /E |1 ++ 16| VCC
- * /S0 |2 15| Q0
- * D0 |3 14| /S1
- * D1 |4 DM9314 13| Q1
- * /S2 |5 12| Q2
- * D2 |6 11| /S3
- * D3 |7 10| Q3
- * GND |8 9| /MR
- * +--------------+
- *
- */
#ifndef NLD_DM9314_H_
#define NLD_DM9314_H_
diff --git a/src/lib/netlist/devices/nld_dm9334.cpp b/src/lib/netlist/devices/nld_dm9334.cpp
index cdc38827755..0755c4532f1 100644
--- a/src/lib/netlist/devices/nld_dm9334.cpp
+++ b/src/lib/netlist/devices/nld_dm9334.cpp
@@ -3,6 +3,63 @@
/*
* nld_dm9334.cpp
*
+ * DM9334: 8-Bit Addressable Latch
+ *
+ * +--------------+
+ * A0 |1 ++ 16| VCC
+ * A1 |2 15| /C
+ * A2 |3 14| /E
+ * Q0 |4 DM9334 13| D
+ * Q1 |5 12| Q7
+ * Q2 |6 11| Q6
+ * Q3 |7 10| Q5
+ * GND |8 9| Q4
+ * +--------------+
+ *
+ * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
+ * | C | E || D || A0| A1| A2|| Q0| Q1| Q2| Q3| Q4| Q5| Q6| Q7|
+ * +===+===++===++===+===+===++===+===+===+===+===+===+===+===+
+ * | 1 | 0 || X || X | X | X || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
+ * | 1 | 1 || 0 || 0 | 0 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 0 | 0 | 0 || 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 0 || 0 | 0 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 0 | 0 | 1 || 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 0 || 0 | 1 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 0 | 1 | 0 || 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 0 || 0 | 1 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 0 | 1 | 1 || 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 0 || 1 | 0 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 1 | 0 | 0 || 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 |
+ * | 1 | 1 || 0 || 1 | 0 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 1 | 0 | 1 || 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 |
+ * | 1 | 1 || 0 || 1 | 1 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 1 | 1 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
+ * | 1 | 1 || 0 || 1 | 1 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+ * | 1 | 1 || 1 || 1 | 1 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
+ * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
+ * | 0 | 0 || X || X | X | X || P | P | P | P | P | P | P | P |
+ * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
+ * | 0 | 1 || 0 || 0 | 0 | 0 || 0 | P | P | P | P | P | P | P |
+ * | 0 | 1 || 1 || 0 | 0 | 0 || 1 | P | P | P | P | P | P | P |
+ * | 0 | 1 || 0 || 0 | 0 | 1 || P | 0 | P | P | P | P | P | P |
+ * | 0 | 1 || 1 || 0 | 0 | 1 || P | 1 | P | P | P | P | P | P |
+ * | 0 | 1 || 0 || 0 | 1 | 0 || P | P | 0 | P | P | P | P | P |
+ * | 0 | 1 || 1 || 0 | 1 | 0 || P | P | 1 | P | P | P | P | P |
+ * | 0 | 1 || 0 || 0 | 1 | 1 || P | P | P | 0 | P | P | P | P |
+ * | 0 | 1 || 1 || 0 | 1 | 1 || P | P | P | 1 | P | P | P | P |
+ * | 0 | 1 || 0 || 1 | 0 | 0 || P | P | P | P | 0 | P | P | P |
+ * | 0 | 1 || 1 || 1 | 0 | 0 || P | P | P | P | 1 | P | P | P |
+ * | 0 | 1 || 0 || 1 | 0 | 1 || P | P | P | P | P | 0 | P | P |
+ * | 0 | 1 || 1 || 1 | 0 | 1 || P | P | P | P | P | 1 | P | P |
+ * | 0 | 1 || 0 || 1 | 1 | 0 || P | P | P | P | P | P | 0 | P |
+ * | 0 | 1 || 1 || 1 | 1 | 0 || P | P | P | P | P | P | 1 | P |
+ * | 0 | 1 || 0 || 1 | 1 | 1 || P | P | P | P | P | P | P | 0 |
+ * | 0 | 1 || 1 || 1 | 1 | 1 || P | P | P | P | P | P | P | 1 |
+ * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
+ *
+ * Naming convention attempts to follow Texas Instruments / National Semiconductor datasheet Literature Number SNOS382A
+ *
*/
#include "nld_dm9334.h"
diff --git a/src/lib/netlist/devices/nld_dm9334.h b/src/lib/netlist/devices/nld_dm9334.h
index 2f4ab1f18c1..f4edeb97306 100644
--- a/src/lib/netlist/devices/nld_dm9334.h
+++ b/src/lib/netlist/devices/nld_dm9334.h
@@ -1,66 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_DM9334.h
- *
- * DM9334: 8-Bit Addressable Latch
- *
- * +--------------+
- * A0 |1 ++ 16| VCC
- * A1 |2 15| /C
- * A2 |3 14| /E
- * Q0 |4 DM9334 13| D
- * Q1 |5 12| Q7
- * Q2 |6 11| Q6
- * Q3 |7 10| Q5
- * GND |8 9| Q4
- * +--------------+
- *
- * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
- * | C | E || D || A0| A1| A2|| Q0| Q1| Q2| Q3| Q4| Q5| Q6| Q7|
- * +===+===++===++===+===+===++===+===+===+===+===+===+===+===+
- * | 1 | 0 || X || X | X | X || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
- * | 1 | 1 || 0 || 0 | 0 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 0 | 0 | 0 || 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 0 || 0 | 0 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 0 | 0 | 1 || 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 0 || 0 | 1 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 0 | 1 | 0 || 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 0 || 0 | 1 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 0 | 1 | 1 || 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 0 || 1 | 0 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 1 | 0 | 0 || 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 |
- * | 1 | 1 || 0 || 1 | 0 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 1 | 0 | 1 || 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 |
- * | 1 | 1 || 0 || 1 | 1 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 1 | 1 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
- * | 1 | 1 || 0 || 1 | 1 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
- * | 1 | 1 || 1 || 1 | 1 | 1 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
- * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
- * | 0 | 0 || X || X | X | X || P | P | P | P | P | P | P | P |
- * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
- * | 0 | 1 || 0 || 0 | 0 | 0 || 0 | P | P | P | P | P | P | P |
- * | 0 | 1 || 1 || 0 | 0 | 0 || 1 | P | P | P | P | P | P | P |
- * | 0 | 1 || 0 || 0 | 0 | 1 || P | 0 | P | P | P | P | P | P |
- * | 0 | 1 || 1 || 0 | 0 | 1 || P | 1 | P | P | P | P | P | P |
- * | 0 | 1 || 0 || 0 | 1 | 0 || P | P | 0 | P | P | P | P | P |
- * | 0 | 1 || 1 || 0 | 1 | 0 || P | P | 1 | P | P | P | P | P |
- * | 0 | 1 || 0 || 0 | 1 | 1 || P | P | P | 0 | P | P | P | P |
- * | 0 | 1 || 1 || 0 | 1 | 1 || P | P | P | 1 | P | P | P | P |
- * | 0 | 1 || 0 || 1 | 0 | 0 || P | P | P | P | 0 | P | P | P |
- * | 0 | 1 || 1 || 1 | 0 | 0 || P | P | P | P | 1 | P | P | P |
- * | 0 | 1 || 0 || 1 | 0 | 1 || P | P | P | P | P | 0 | P | P |
- * | 0 | 1 || 1 || 1 | 0 | 1 || P | P | P | P | P | 1 | P | P |
- * | 0 | 1 || 0 || 1 | 1 | 0 || P | P | P | P | P | P | 0 | P |
- * | 0 | 1 || 1 || 1 | 1 | 0 || P | P | P | P | P | P | 1 | P |
- * | 0 | 1 || 0 || 1 | 1 | 1 || P | P | P | P | P | P | P | 0 |
- * | 0 | 1 || 1 || 1 | 1 | 1 || P | P | P | P | P | P | P | 1 |
- * +---+---++---++---+---+---++---+---+---+---+---+---+---+---+
- *
- * Naming convention attempts to follow Texas Instruments / National Semiconductor datasheet Literature Number SNOS382A
- *
- */
#ifndef NLD_DM9334_H_
#define NLD_DM9334_H_
diff --git a/src/lib/netlist/devices/nld_log.cpp b/src/lib/netlist/devices/nld_log.cpp
index b00dc62ff0d..dacc208f5a0 100644
--- a/src/lib/netlist/devices/nld_log.cpp
+++ b/src/lib/netlist/devices/nld_log.cpp
@@ -1,15 +1,25 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_log.c
+ * nld_log.cpp
+ *
+ * Devices supporting analysis and logging
+ *
+ * nld_log:
+ *
+ * +---------+
+ * | ++ |
+ * I | | ==> Log to file "netlist_" + name() + ".log"
+ * | |
+ * +---------+
*
*/
#include "netlist/nl_base.h"
#include "nld_log.h"
#include "plib/pfmtlog.h"
-#include "plib/pstream.h"
#include "plib/pmulti_threading.h"
+#include "plib/pstream.h"
//#include "sound/wavwrite.h"
#include <array>
diff --git a/src/lib/netlist/devices/nld_log.h b/src/lib/netlist/devices/nld_log.h
index 13c71ea7257..470506a430e 100644
--- a/src/lib/netlist/devices/nld_log.h
+++ b/src/lib/netlist/devices/nld_log.h
@@ -1,19 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_log.h
- *
- * Devices supporting analysis and logging
- *
- * nld_log:
- *
- * +---------+
- * | ++ |
- * I | | ==> Log to file "netlist_" + name() + ".log"
- * | |
- * +---------+
- *
- */
#ifndef NLD_LOG_H_
#define NLD_LOG_H_
diff --git a/src/lib/netlist/devices/nld_mm5837.cpp b/src/lib/netlist/devices/nld_mm5837.cpp
index aac0d38fe82..c43509fac7d 100644
--- a/src/lib/netlist/devices/nld_mm5837.cpp
+++ b/src/lib/netlist/devices/nld_mm5837.cpp
@@ -1,7 +1,18 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_MM5837.c
+ * nld_MM5837.cpp
+ *
+ * MM5837: Digital noise source
+ *
+ * +--------+
+ * VDD |1 ++ 8| NC
+ * VGG |2 7| NC
+ * OUT |3 6| NC
+ * VSS |4 5| NC
+ * +--------+
+ *
+ * Naming conventions follow National Semiconductor datasheet
*
*/
diff --git a/src/lib/netlist/devices/nld_mm5837.h b/src/lib/netlist/devices/nld_mm5837.h
index 8f764aa651f..0fe862f964e 100644
--- a/src/lib/netlist/devices/nld_mm5837.h
+++ b/src/lib/netlist/devices/nld_mm5837.h
@@ -1,20 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_MM5837.h
- *
- * MM5837: Digital noise source
- *
- * +--------+
- * VDD |1 ++ 8| NC
- * VGG |2 7| NC
- * OUT |3 6| NC
- * VSS |4 5| NC
- * +--------+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
#ifndef NLD_MM5837_H_
#define NLD_MM5837_H_
diff --git a/src/lib/netlist/devices/nld_r2r_dac.cpp b/src/lib/netlist/devices/nld_r2r_dac.cpp
index 2ea95ca4996..703ba3a536e 100644
--- a/src/lib/netlist/devices/nld_r2r_dac.cpp
+++ b/src/lib/netlist/devices/nld_r2r_dac.cpp
@@ -1,7 +1,45 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
/*
- * nld_R2R_dac.c
+ * nld_r2r_dac.cpp
+ *
+ * DMR2R_DAC: R-2R DAC
+ *
+ * Generic R-2R DAC ... This is fast.
+ * 2R
+ * Bit n >----RRR----+---------> Vout
+ * |
+ * R
+ * R R
+ * R
+ * |
+ * .
+ * .
+ * 2R |
+ * Bit 2 >----RRR----+
+ * |
+ * R
+ * R R
+ * R
+ * |
+ * 2R |
+ * Bit 1 >----RRR----+
+ * |
+ * R
+ * R 2R
+ * R
+ * |
+ * V0
+ *
+ * Using Thevenin's Theorem, this can be written as
+ *
+ * +---RRR-----------> Vout
+ * |
+ * V
+ * V V = VAL / 2^n * Vin
+ * V
+ * |
+ * V0
*
*/
diff --git a/src/lib/netlist/devices/nld_r2r_dac.h b/src/lib/netlist/devices/nld_r2r_dac.h
index d440f999d67..85af880bddb 100644
--- a/src/lib/netlist/devices/nld_r2r_dac.h
+++ b/src/lib/netlist/devices/nld_r2r_dac.h
@@ -1,47 +1,5 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-/*
- * nld_R2R_DAC.h
- *
- * DMR2R_DAC: R-2R DAC
- *
- * Generic R-2R DAC ... This is fast.
- * 2R
- * Bit n >----RRR----+---------> Vout
- * |
- * R
- * R R
- * R
- * |
- * .
- * .
- * 2R |
- * Bit 2 >----RRR----+
- * |
- * R
- * R R
- * R
- * |
- * 2R |
- * Bit 1 >----RRR----+
- * |
- * R
- * R 2R
- * R
- * |
- * V0
- *
- * Using Thevenin's Theorem, this can be written as
- *
- * +---RRR-----------> Vout
- * |
- * V
- * V V = VAL / 2^n * Vin
- * V
- * |
- * V0
- *
- */
#ifndef NLD_R2R_DAC_H_
#define NLD_R2R_DAC_H_
diff --git a/src/lib/netlist/devices/nld_tms4800.cpp b/src/lib/netlist/devices/nld_tms4800.cpp
index 3f9de696ea8..d55827c2416 100644
--- a/src/lib/netlist/devices/nld_tms4800.cpp
+++ b/src/lib/netlist/devices/nld_tms4800.cpp
@@ -3,6 +3,26 @@
/*
* nld_tms4800.cpp
*
+ * TMS-4800: 16 Kbit (2Kb x 8) READ ONLY MEMORY
+ *
+ * +----------------+
+ * VSS |1 ++ 24| OE1
+ * A1 |2 23| O1
+ * A2 |3 22| O2
+ * A3 |4 TMS-4800 21| O3
+ * A4 |5 20| O4
+ * A5 |6 19| O5
+ * A6 |7 18| O6
+ * A10 |8 17| O7
+ * VGG |9 16| O8
+ * A9 |10 15| A11
+ * A8 |11 14| OE2
+ * A7 |12 13| AR
+ * +----------------+
+ *
+ *
+ * Naming conventions follow Texas Instruments datasheet:
+ * http://bitsavers.trailing-edge.com/components/ti/_dataBooks/1975_TI_The_Semiconductor_Memory_Data_Book.pdf
*/
#include "nld_tms4800.h"
diff --git a/src/lib/netlist/devices/nld_tms4800.h b/src/lib/netlist/devices/nld_tms4800.h
index 14d7d40dc64..63bcff9e7e9 100644
--- a/src/lib/netlist/devices/nld_tms4800.h
+++ b/src/lib/netlist/devices/nld_tms4800.h
@@ -1,29 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Felipe Sanches
-/*
- * nld_tms4800.h
- *
- * TMS-4800: 16 Kbit (2Kb x 8) READ ONLY MEMORY
- *
- * +----------------+
- * VSS |1 ++ 24| OE1
- * A1 |2 23| O1
- * A2 |3 22| O2
- * A3 |4 TMS-4800 21| O3
- * A4 |5 20| O4
- * A5 |6 19| O5
- * A6 |7 18| O6
- * A10 |8 17| O7
- * VGG |9 16| O8
- * A9 |10 15| A11
- * A8 |11 14| OE2
- * A7 |12 13| AR
- * +----------------+
- *
- *
- * Naming conventions follow Texas Instruments datasheet:
- * http://bitsavers.trailing-edge.com/components/ti/_dataBooks/1975_TI_The_Semiconductor_Memory_Data_Book.pdf
- */
#ifndef NLD_TMS4800_H_
#define NLD_TMS4800_H_
diff --git a/src/lib/netlist/devices/nld_tristate.cpp b/src/lib/netlist/devices/nld_tristate.cpp
index 93dcbb4913d..013a0514420 100644
--- a/src/lib/netlist/devices/nld_tristate.cpp
+++ b/src/lib/netlist/devices/nld_tristate.cpp
@@ -3,6 +3,8 @@
/*
* nld_tristate.cpp
*
+ * tristate: Hack to merge two tri-stated outputs together
+ *
*/
#include "nld_tristate.h"
diff --git a/src/lib/netlist/devices/nld_tristate.h b/src/lib/netlist/devices/nld_tristate.h
index 71f97d9812d..0cb32c73d12 100644
--- a/src/lib/netlist/devices/nld_tristate.h
+++ b/src/lib/netlist/devices/nld_tristate.h
@@ -1,11 +1,5 @@
// license:BSD-3-Clause
// copyright-holders:Ryan Holtz
-/*
- * nld_tristate.h
- *
- * tristate: Hack to merge two tri-stated outputs together
- *
- */
#ifndef NLD_TRISTATE_H_
#define NLD_TRISTATE_H_
diff --git a/src/lib/netlist/devices/nlid_system.h b/src/lib/netlist/devices/nlid_system.h
index b3bc9c6434e..a8ba6937164 100644
--- a/src/lib/netlist/devices/nlid_system.h
+++ b/src/lib/netlist/devices/nlid_system.h
@@ -102,7 +102,7 @@ namespace devices
for (int i=0; i < m_N(); i++)
{
pstring inpname = plib::pfmt("A{1}")(i);
- m_I.push_back(state().make_pool_object<analog_input_t>(*this, inpname, NETLIB_DELEGATE(fb)));
+ m_I.push_back(owner.template make_pool_object<analog_input_t>(*this, inpname, NETLIB_DELEGATE(fb)));
inps.push_back(inpname);
m_vals.push_back(nlconst::zero());
}
@@ -460,7 +460,7 @@ namespace devices
for (int i=0; i < m_N(); i++)
{
pstring inpname = plib::pfmt("A{1}")(i);
- m_I.push_back(state().make_pool_object<analog_input_t>(*this, inpname, NETLIB_DELEGATE(inputs)));
+ m_I.push_back(owner.template make_pool_object<analog_input_t>(*this, inpname, NETLIB_DELEGATE(inputs)));
inps.push_back(inpname);
m_vals.push_back(nlconst::zero());
}
diff --git a/src/lib/netlist/devices/nlid_truthtable.cpp b/src/lib/netlist/devices/nlid_truthtable.cpp
index 947b2651acb..12219353283 100644
--- a/src/lib/netlist/devices/nlid_truthtable.cpp
+++ b/src/lib/netlist/devices/nlid_truthtable.cpp
@@ -677,7 +677,8 @@ namespace factory
#define ENTRY(n, s) ENTRYY(n, 1, s); ENTRYY(n, 2, s); ENTRYY(n, 3, s); \
ENTRYY(n, 4, s); ENTRYY(n, 5, s); ENTRYY(n, 6, s); \
- ENTRYY(n, 7, s); ENTRYY(n, 8, s)
+ ENTRYY(n, 7, s); ENTRYY(n, 8, s); ENTRYY(n, 9, s); \
+ ENTRYY(n, 10, s)
host_arena::unique_ptr<truthtable_base_element_t> truthtable_create(tt_desc &desc, properties &&props)
{
diff --git a/src/lib/netlist/examples/sn74ls629_osc.c b/src/lib/netlist/examples/sn74ls629_osc.c
index c51007a1bd3..748f549651f 100644
--- a/src/lib/netlist/examples/sn74ls629_osc.c
+++ b/src/lib/netlist/examples/sn74ls629_osc.c
@@ -25,6 +25,7 @@ NETLIST_START(ls629)
SN74LS629(OSC, 0.022e-6)
NET_C(GND, OSC.GND)
+ NET_C(V5, OSC.VCC)
NET_C(VR, OSC.RNG)
NET_C(VF, OSC.FC)
NET_C(GND, OSC.ENQ)
diff --git a/src/lib/netlist/generated/static_solvers.cpp b/src/lib/netlist/generated/static_solvers.cpp
index 029120c53ce..e184c0337cc 100644
--- a/src/lib/netlist/generated/static_solvers.cpp
+++ b/src/lib/netlist/generated/static_solvers.cpp
@@ -1,5 +1,138 @@
#include "plib/pdynlib.h"
+// tankbatt
+static void nl_gcr_124f7aa10f044582_16_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
+
+{
+
+ plib::unused_var(cnV);
+ double m_A0(0.0);
+ double m_A1(0.0);
+ double m_A2(0.0);
+ double m_A3(0.0);
+ double m_A4(0.0);
+ double m_A5(0.0);
+ double m_A6(0.0);
+ double m_A7(0.0);
+ double m_A8(0.0);
+ double m_A9(0.0);
+ double m_A10(0.0);
+ double m_A11(0.0);
+ double m_A12(0.0);
+ double m_A13(0.0);
+ double m_A14(0.0);
+ double m_A15(0.0);
+ m_A0 += gt[0];
+ m_A0 += gt[1];
+ m_A0 += gt[2];
+ m_A1 += go[0];
+ double RHS0 = Idr[0];
+ RHS0 += Idr[1];
+ RHS0 += Idr[2];
+ RHS0 -= go[1] * *cnV[1];
+ RHS0 -= go[2] * *cnV[2];
+ m_A2 += gt[3];
+ m_A2 += gt[4];
+ m_A2 += gt[5];
+ m_A2 += gt[6];
+ m_A2 += gt[7];
+ m_A2 += gt[8];
+ m_A2 += gt[9];
+ m_A3 += go[3];
+ m_A4 += go[4];
+ double RHS1 = Idr[3];
+ RHS1 += Idr[4];
+ RHS1 += Idr[5];
+ RHS1 += Idr[6];
+ RHS1 += Idr[7];
+ RHS1 += Idr[8];
+ RHS1 += Idr[9];
+ RHS1 -= go[5] * *cnV[5];
+ RHS1 -= go[6] * *cnV[6];
+ RHS1 -= go[7] * *cnV[7];
+ RHS1 -= go[8] * *cnV[8];
+ RHS1 -= go[9] * *cnV[9];
+ m_A5 += gt[10];
+ m_A5 += gt[11];
+ m_A5 += gt[12];
+ m_A5 += gt[13];
+ m_A7 += go[10];
+ m_A6 += go[11];
+ double RHS2 = Idr[10];
+ RHS2 += Idr[11];
+ RHS2 += Idr[12];
+ RHS2 += Idr[13];
+ RHS2 -= go[12] * *cnV[12];
+ RHS2 -= go[13] * *cnV[13];
+ m_A10 += gt[14];
+ m_A10 += gt[15];
+ m_A10 += gt[16];
+ m_A10 += gt[17];
+ m_A11 += go[14];
+ m_A9 += go[15];
+ m_A8 += go[16];
+ double RHS3 = Idr[14];
+ RHS3 += Idr[15];
+ RHS3 += Idr[16];
+ RHS3 += Idr[17];
+ RHS3 -= go[17] * *cnV[17];
+ m_A15 += gt[18];
+ m_A15 += gt[19];
+ m_A15 += gt[20];
+ m_A15 += gt[21];
+ m_A15 += gt[22];
+ m_A15 += gt[23];
+ m_A12 += go[18];
+ m_A13 += go[19];
+ m_A14 += go[20];
+ double RHS4 = Idr[18];
+ RHS4 += Idr[19];
+ RHS4 += Idr[20];
+ RHS4 += Idr[21];
+ RHS4 += Idr[22];
+ RHS4 += Idr[23];
+ RHS4 -= go[21] * *cnV[21];
+ RHS4 -= go[22] * *cnV[22];
+ RHS4 -= go[23] * *cnV[23];
+ const double f0 = 1.0 / m_A0;
+ const double f0_3 = -f0 * m_A8;
+ m_A10 += m_A1 * f0_3;
+ RHS3 += f0_3 * RHS0;
+ const double f1 = 1.0 / m_A2;
+ const double f1_4 = -f1 * m_A12;
+ m_A13 += m_A3 * f1_4;
+ m_A14 += m_A4 * f1_4;
+ RHS4 += f1_4 * RHS1;
+ const double f2 = 1.0 / m_A5;
+ const double f2_3 = -f2 * m_A9;
+ m_A10 += m_A6 * f2_3;
+ m_A11 += m_A7 * f2_3;
+ RHS3 += f2_3 * RHS2;
+ const double f2_4 = -f2 * m_A13;
+ m_A14 += m_A6 * f2_4;
+ m_A15 += m_A7 * f2_4;
+ RHS4 += f2_4 * RHS2;
+ const double f3 = 1.0 / m_A10;
+ const double f3_4 = -f3 * m_A14;
+ m_A15 += m_A11 * f3_4;
+ RHS4 += f3_4 * RHS3;
+ V[4] = RHS4 / m_A15;
+ double tmp3 = 0.0;
+ tmp3 += m_A11 * V[4];
+ V[3] = (RHS3 - tmp3) / m_A10;
+ double tmp2 = 0.0;
+ tmp2 += m_A6 * V[3];
+ tmp2 += m_A7 * V[4];
+ V[2] = (RHS2 - tmp2) / m_A5;
+ double tmp1 = 0.0;
+ tmp1 += m_A3 * V[2];
+ tmp1 += m_A4 * V[3];
+ V[1] = (RHS1 - tmp1) / m_A2;
+ double tmp0 = 0.0;
+ tmp0 += m_A1 * V[3];
+ V[0] = (RHS0 - tmp0) / m_A0;
+}
+
// armora
static void nl_gcr_1250f340dea396ae_22_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -3711,6 +3844,869 @@ static void nl_gcr_2f84bc98d737730b_22_double_double(double * __restrict V, cons
V[0] = (RHS0 - tmp0) / m_A0;
}
+// tankbatt
+static void nl_gcr_328d886b444b586b_137_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
+
+{
+
+ plib::unused_var(cnV);
+ double m_A0(0.0);
+ double m_A1(0.0);
+ double m_A2(0.0);
+ double m_A3(0.0);
+ double m_A4(0.0);
+ double m_A5(0.0);
+ double m_A6(0.0);
+ double m_A7(0.0);
+ double m_A8(0.0);
+ double m_A9(0.0);
+ double m_A10(0.0);
+ double m_A11(0.0);
+ double m_A12(0.0);
+ double m_A13(0.0);
+ double m_A14(0.0);
+ double m_A15(0.0);
+ double m_A16(0.0);
+ double m_A17(0.0);
+ double m_A18(0.0);
+ double m_A19(0.0);
+ double m_A20(0.0);
+ double m_A21(0.0);
+ double m_A22(0.0);
+ double m_A23(0.0);
+ double m_A24(0.0);
+ double m_A25(0.0);
+ double m_A26(0.0);
+ double m_A27(0.0);
+ double m_A28(0.0);
+ double m_A29(0.0);
+ double m_A30(0.0);
+ double m_A31(0.0);
+ double m_A32(0.0);
+ double m_A33(0.0);
+ double m_A34(0.0);
+ double m_A35(0.0);
+ double m_A36(0.0);
+ double m_A37(0.0);
+ double m_A38(0.0);
+ double m_A39(0.0);
+ double m_A40(0.0);
+ double m_A41(0.0);
+ double m_A42(0.0);
+ double m_A43(0.0);
+ double m_A44(0.0);
+ double m_A45(0.0);
+ double m_A46(0.0);
+ double m_A47(0.0);
+ double m_A48(0.0);
+ double m_A49(0.0);
+ double m_A50(0.0);
+ double m_A51(0.0);
+ double m_A52(0.0);
+ double m_A53(0.0);
+ double m_A54(0.0);
+ double m_A55(0.0);
+ double m_A56(0.0);
+ double m_A57(0.0);
+ double m_A58(0.0);
+ double m_A59(0.0);
+ double m_A60(0.0);
+ double m_A61(0.0);
+ double m_A62(0.0);
+ double m_A63(0.0);
+ double m_A64(0.0);
+ double m_A65(0.0);
+ double m_A66(0.0);
+ double m_A67(0.0);
+ double m_A68(0.0);
+ double m_A69(0.0);
+ double m_A70(0.0);
+ double m_A71(0.0);
+ double m_A72(0.0);
+ double m_A73(0.0);
+ double m_A74(0.0);
+ double m_A75(0.0);
+ double m_A76(0.0);
+ double m_A77(0.0);
+ double m_A78(0.0);
+ double m_A79(0.0);
+ double m_A80(0.0);
+ double m_A81(0.0);
+ double m_A82(0.0);
+ double m_A83(0.0);
+ double m_A84(0.0);
+ double m_A85(0.0);
+ double m_A86(0.0);
+ double m_A87(0.0);
+ double m_A88(0.0);
+ double m_A89(0.0);
+ double m_A90(0.0);
+ double m_A91(0.0);
+ double m_A92(0.0);
+ double m_A93(0.0);
+ double m_A94(0.0);
+ double m_A95(0.0);
+ double m_A96(0.0);
+ double m_A97(0.0);
+ double m_A98(0.0);
+ double m_A99(0.0);
+ double m_A100(0.0);
+ double m_A101(0.0);
+ double m_A102(0.0);
+ double m_A103(0.0);
+ double m_A104(0.0);
+ double m_A105(0.0);
+ double m_A106(0.0);
+ double m_A107(0.0);
+ double m_A108(0.0);
+ double m_A109(0.0);
+ double m_A110(0.0);
+ double m_A111(0.0);
+ double m_A112(0.0);
+ double m_A113(0.0);
+ double m_A114(0.0);
+ double m_A115(0.0);
+ double m_A116(0.0);
+ double m_A117(0.0);
+ double m_A118(0.0);
+ double m_A119(0.0);
+ double m_A120(0.0);
+ double m_A121(0.0);
+ double m_A122(0.0);
+ double m_A123(0.0);
+ double m_A124(0.0);
+ double m_A125(0.0);
+ double m_A126(0.0);
+ double m_A127(0.0);
+ double m_A128(0.0);
+ double m_A129(0.0);
+ double m_A130(0.0);
+ double m_A131(0.0);
+ double m_A132(0.0);
+ double m_A133(0.0);
+ double m_A134(0.0);
+ double m_A135(0.0);
+ double m_A136(0.0);
+ m_A0 += gt[0];
+ m_A0 += gt[1];
+ m_A0 += gt[2];
+ m_A1 += go[0];
+ double RHS0 = Idr[0];
+ RHS0 += Idr[1];
+ RHS0 += Idr[2];
+ RHS0 -= go[1] * *cnV[1];
+ RHS0 -= go[2] * *cnV[2];
+ m_A2 += gt[3];
+ m_A2 += gt[4];
+ m_A2 += gt[5];
+ m_A2 += gt[6];
+ m_A3 += go[3];
+ m_A3 += go[4];
+ double RHS1 = Idr[3];
+ RHS1 += Idr[4];
+ RHS1 += Idr[5];
+ RHS1 += Idr[6];
+ RHS1 -= go[5] * *cnV[5];
+ RHS1 -= go[6] * *cnV[6];
+ m_A4 += gt[7];
+ m_A4 += gt[8];
+ m_A4 += gt[9];
+ m_A4 += gt[10];
+ m_A4 += gt[11];
+ m_A5 += go[7];
+ m_A7 += go[8];
+ m_A6 += go[9];
+ double RHS2 = Idr[7];
+ RHS2 += Idr[8];
+ RHS2 += Idr[9];
+ RHS2 += Idr[10];
+ RHS2 += Idr[11];
+ RHS2 -= go[10] * *cnV[10];
+ RHS2 -= go[11] * *cnV[11];
+ m_A8 += gt[12];
+ m_A8 += gt[13];
+ m_A8 += gt[14];
+ m_A9 += go[12];
+ double RHS3 = Idr[12];
+ RHS3 += Idr[13];
+ RHS3 += Idr[14];
+ RHS3 -= go[13] * *cnV[13];
+ RHS3 -= go[14] * *cnV[14];
+ m_A10 += gt[15];
+ m_A10 += gt[16];
+ m_A10 += gt[17];
+ m_A10 += gt[18];
+ m_A10 += gt[19];
+ m_A10 += gt[20];
+ m_A10 += gt[21];
+ m_A11 += go[15];
+ m_A12 += go[16];
+ double RHS4 = Idr[15];
+ RHS4 += Idr[16];
+ RHS4 += Idr[17];
+ RHS4 += Idr[18];
+ RHS4 += Idr[19];
+ RHS4 += Idr[20];
+ RHS4 += Idr[21];
+ RHS4 -= go[17] * *cnV[17];
+ RHS4 -= go[18] * *cnV[18];
+ RHS4 -= go[19] * *cnV[19];
+ RHS4 -= go[20] * *cnV[20];
+ RHS4 -= go[21] * *cnV[21];
+ m_A13 += gt[22];
+ m_A13 += gt[23];
+ m_A13 += gt[24];
+ m_A14 += go[22];
+ double RHS5 = Idr[22];
+ RHS5 += Idr[23];
+ RHS5 += Idr[24];
+ RHS5 -= go[23] * *cnV[23];
+ RHS5 -= go[24] * *cnV[24];
+ m_A15 += gt[25];
+ m_A15 += gt[26];
+ m_A15 += gt[27];
+ m_A16 += go[25];
+ double RHS6 = Idr[25];
+ RHS6 += Idr[26];
+ RHS6 += Idr[27];
+ RHS6 -= go[26] * *cnV[26];
+ RHS6 -= go[27] * *cnV[27];
+ m_A17 += gt[28];
+ m_A17 += gt[29];
+ m_A17 += gt[30];
+ m_A19 += go[28];
+ m_A18 += go[29];
+ double RHS7 = Idr[28];
+ RHS7 += Idr[29];
+ RHS7 += Idr[30];
+ RHS7 -= go[30] * *cnV[30];
+ m_A20 += gt[31];
+ m_A20 += gt[32];
+ m_A20 += gt[33];
+ m_A21 += go[31];
+ double RHS8 = Idr[31];
+ RHS8 += Idr[32];
+ RHS8 += Idr[33];
+ RHS8 -= go[32] * *cnV[32];
+ RHS8 -= go[33] * *cnV[33];
+ m_A22 += gt[34];
+ m_A22 += gt[35];
+ m_A22 += gt[36];
+ m_A24 += go[34];
+ m_A23 += go[35];
+ double RHS9 = Idr[34];
+ RHS9 += Idr[35];
+ RHS9 += Idr[36];
+ RHS9 -= go[36] * *cnV[36];
+ m_A25 += gt[37];
+ m_A25 += gt[38];
+ m_A25 += gt[39];
+ m_A25 += gt[40];
+ m_A25 += gt[41];
+ m_A25 += gt[42];
+ m_A25 += gt[43];
+ m_A27 += go[37];
+ m_A26 += go[38];
+ double RHS10 = Idr[37];
+ RHS10 += Idr[38];
+ RHS10 += Idr[39];
+ RHS10 += Idr[40];
+ RHS10 += Idr[41];
+ RHS10 += Idr[42];
+ RHS10 += Idr[43];
+ RHS10 -= go[39] * *cnV[39];
+ RHS10 -= go[40] * *cnV[40];
+ RHS10 -= go[41] * *cnV[41];
+ RHS10 -= go[42] * *cnV[42];
+ RHS10 -= go[43] * *cnV[43];
+ m_A28 += gt[44];
+ m_A28 += gt[45];
+ m_A28 += gt[46];
+ m_A28 += gt[47];
+ m_A28 += gt[48];
+ m_A28 += gt[49];
+ m_A30 += go[44];
+ m_A31 += go[45];
+ m_A29 += go[46];
+ double RHS11 = Idr[44];
+ RHS11 += Idr[45];
+ RHS11 += Idr[46];
+ RHS11 += Idr[47];
+ RHS11 += Idr[48];
+ RHS11 += Idr[49];
+ RHS11 -= go[47] * *cnV[47];
+ RHS11 -= go[48] * *cnV[48];
+ RHS11 -= go[49] * *cnV[49];
+ m_A32 += gt[50];
+ m_A32 += gt[51];
+ m_A32 += gt[52];
+ m_A32 += gt[53];
+ m_A35 += go[50];
+ m_A34 += go[51];
+ m_A33 += go[52];
+ double RHS12 = Idr[50];
+ RHS12 += Idr[51];
+ RHS12 += Idr[52];
+ RHS12 += Idr[53];
+ RHS12 -= go[53] * *cnV[53];
+ m_A36 += gt[54];
+ m_A36 += gt[55];
+ m_A36 += gt[56];
+ m_A37 += go[54];
+ double RHS13 = Idr[54];
+ RHS13 += Idr[55];
+ RHS13 += Idr[56];
+ RHS13 -= go[55] * *cnV[55];
+ RHS13 -= go[56] * *cnV[56];
+ m_A38 += gt[57];
+ m_A38 += gt[58];
+ m_A38 += gt[59];
+ m_A39 += go[57];
+ double RHS14 = Idr[57];
+ RHS14 += Idr[58];
+ RHS14 += Idr[59];
+ RHS14 -= go[58] * *cnV[58];
+ RHS14 -= go[59] * *cnV[59];
+ m_A44 += gt[60];
+ m_A44 += gt[61];
+ m_A41 += go[60];
+ m_A40 += go[61];
+ double RHS15 = Idr[60];
+ RHS15 += Idr[61];
+ m_A50 += gt[62];
+ m_A50 += gt[63];
+ m_A49 += go[62];
+ m_A48 += go[63];
+ double RHS16 = Idr[62];
+ RHS16 += Idr[63];
+ m_A52 += gt[64];
+ m_A52 += gt[65];
+ m_A52 += gt[66];
+ m_A52 += gt[67];
+ m_A55 += go[64];
+ m_A54 += go[65];
+ m_A53 += go[66];
+ double RHS17 = Idr[64];
+ RHS17 += Idr[65];
+ RHS17 += Idr[66];
+ RHS17 += Idr[67];
+ RHS17 -= go[67] * *cnV[67];
+ m_A58 += gt[68];
+ m_A58 += gt[69];
+ m_A57 += go[68];
+ m_A56 += go[69];
+ double RHS18 = Idr[68];
+ RHS18 += Idr[69];
+ m_A60 += gt[70];
+ m_A60 += gt[71];
+ m_A60 += gt[72];
+ m_A61 += go[70];
+ double RHS19 = Idr[70];
+ RHS19 += Idr[71];
+ RHS19 += Idr[72];
+ RHS19 -= go[71] * *cnV[71];
+ RHS19 -= go[72] * *cnV[72];
+ m_A63 += gt[73];
+ m_A63 += gt[74];
+ m_A64 += go[73];
+ m_A62 += go[74];
+ double RHS20 = Idr[73];
+ RHS20 += Idr[74];
+ m_A66 += gt[75];
+ m_A66 += gt[76];
+ m_A67 += go[75];
+ m_A65 += go[76];
+ double RHS21 = Idr[75];
+ RHS21 += Idr[76];
+ m_A73 += gt[77];
+ m_A73 += gt[78];
+ m_A73 += gt[79];
+ m_A73 += gt[80];
+ m_A71 += go[77];
+ m_A69 += go[78];
+ m_A68 += go[79];
+ m_A68 += go[80];
+ double RHS22 = Idr[77];
+ RHS22 += Idr[78];
+ RHS22 += Idr[79];
+ RHS22 += Idr[80];
+ m_A79 += gt[81];
+ m_A79 += gt[82];
+ m_A77 += go[81];
+ m_A76 += go[82];
+ double RHS23 = Idr[81];
+ RHS23 += Idr[82];
+ m_A84 += gt[83];
+ m_A84 += gt[84];
+ m_A84 += gt[85];
+ m_A84 += gt[86];
+ m_A84 += gt[87];
+ m_A84 += gt[88];
+ m_A84 += gt[89];
+ m_A85 += go[83];
+ m_A82 += go[84];
+ double RHS24 = Idr[83];
+ RHS24 += Idr[84];
+ RHS24 += Idr[85];
+ RHS24 += Idr[86];
+ RHS24 += Idr[87];
+ RHS24 += Idr[88];
+ RHS24 += Idr[89];
+ RHS24 -= go[85] * *cnV[85];
+ RHS24 -= go[86] * *cnV[86];
+ RHS24 -= go[87] * *cnV[87];
+ RHS24 -= go[88] * *cnV[88];
+ RHS24 -= go[89] * *cnV[89];
+ m_A91 += gt[90];
+ m_A91 += gt[91];
+ m_A91 += gt[92];
+ m_A93 += go[90];
+ m_A88 += go[91];
+ m_A87 += go[92];
+ double RHS25 = Idr[90];
+ RHS25 += Idr[91];
+ RHS25 += Idr[92];
+ m_A97 += gt[93];
+ m_A97 += gt[94];
+ m_A96 += go[93];
+ m_A94 += go[94];
+ double RHS26 = Idr[93];
+ RHS26 += Idr[94];
+ m_A105 += gt[95];
+ m_A105 += gt[96];
+ m_A105 += gt[97];
+ m_A107 += go[95];
+ m_A101 += go[96];
+ m_A100 += go[97];
+ double RHS27 = Idr[95];
+ RHS27 += Idr[96];
+ RHS27 += Idr[97];
+ m_A111 += gt[98];
+ m_A111 += gt[99];
+ m_A111 += gt[100];
+ m_A111 += gt[101];
+ m_A111 += gt[102];
+ m_A112 += go[98];
+ m_A110 += go[99];
+ m_A109 += go[100];
+ m_A108 += go[101];
+ double RHS28 = Idr[98];
+ RHS28 += Idr[99];
+ RHS28 += Idr[100];
+ RHS28 += Idr[101];
+ RHS28 += Idr[102];
+ RHS28 -= go[102] * *cnV[102];
+ m_A118 += gt[103];
+ m_A118 += gt[104];
+ m_A118 += gt[105];
+ m_A118 += gt[106];
+ m_A118 += gt[107];
+ m_A118 += gt[108];
+ m_A115 += go[103];
+ m_A120 += go[104];
+ m_A116 += go[105];
+ m_A113 += go[106];
+ double RHS29 = Idr[103];
+ RHS29 += Idr[104];
+ RHS29 += Idr[105];
+ RHS29 += Idr[106];
+ RHS29 += Idr[107];
+ RHS29 += Idr[108];
+ RHS29 -= go[107] * *cnV[107];
+ RHS29 -= go[108] * *cnV[108];
+ m_A129 += gt[109];
+ m_A129 += gt[110];
+ m_A129 += gt[111];
+ m_A129 += gt[112];
+ m_A129 += gt[113];
+ m_A129 += gt[114];
+ m_A121 += go[109];
+ m_A130 += go[110];
+ m_A127 += go[111];
+ m_A123 += go[112];
+ double RHS30 = Idr[109];
+ RHS30 += Idr[110];
+ RHS30 += Idr[111];
+ RHS30 += Idr[112];
+ RHS30 += Idr[113];
+ RHS30 += Idr[114];
+ RHS30 -= go[113] * *cnV[113];
+ RHS30 -= go[114] * *cnV[114];
+ m_A136 += gt[115];
+ m_A136 += gt[116];
+ m_A136 += gt[117];
+ m_A136 += gt[118];
+ m_A136 += gt[119];
+ m_A133 += go[115];
+ m_A134 += go[116];
+ m_A135 += go[117];
+ m_A132 += go[118];
+ m_A131 += go[119];
+ double RHS31 = Idr[115];
+ RHS31 += Idr[116];
+ RHS31 += Idr[117];
+ RHS31 += Idr[118];
+ RHS31 += Idr[119];
+ const double f0 = 1.0 / m_A0;
+ const double f0_15 = -f0 * m_A40;
+ m_A44 += m_A1 * f0_15;
+ RHS15 += f0_15 * RHS0;
+ const double f1 = 1.0 / m_A2;
+ const double f1_22 = -f1 * m_A68;
+ m_A73 += m_A3 * f1_22;
+ RHS22 += f1_22 * RHS1;
+ const double f2 = 1.0 / m_A4;
+ const double f2_15 = -f2 * m_A41;
+ m_A42 += m_A5 * f2_15;
+ m_A44 += m_A6 * f2_15;
+ m_A45 += m_A7 * f2_15;
+ RHS15 += f2_15 * RHS2;
+ const double f2_22 = -f2 * m_A69;
+ m_A70 += m_A5 * f2_22;
+ m_A72 += m_A6 * f2_22;
+ m_A73 += m_A7 * f2_22;
+ RHS22 += f2_22 * RHS2;
+ const double f3 = 1.0 / m_A8;
+ const double f3_16 = -f3 * m_A48;
+ m_A50 += m_A9 * f3_16;
+ RHS16 += f3_16 * RHS3;
+ const double f4 = 1.0 / m_A10;
+ const double f4_15 = -f4 * m_A42;
+ m_A43 += m_A11 * f4_15;
+ m_A45 += m_A12 * f4_15;
+ RHS15 += f4_15 * RHS4;
+ const double f4_22 = -f4 * m_A70;
+ m_A71 += m_A11 * f4_22;
+ m_A73 += m_A12 * f4_22;
+ RHS22 += f4_22 * RHS4;
+ const double f5 = 1.0 / m_A13;
+ const double f5_20 = -f5 * m_A62;
+ m_A63 += m_A14 * f5_20;
+ RHS20 += f5_20 * RHS5;
+ const double f6 = 1.0 / m_A15;
+ const double f6_18 = -f6 * m_A56;
+ m_A58 += m_A16 * f6_18;
+ RHS18 += f6_18 * RHS6;
+ const double f7 = 1.0 / m_A17;
+ const double f7_16 = -f7 * m_A49;
+ m_A50 += m_A18 * f7_16;
+ m_A51 += m_A19 * f7_16;
+ RHS16 += f7_16 * RHS7;
+ const double f7_26 = -f7 * m_A94;
+ m_A95 += m_A18 * f7_26;
+ m_A97 += m_A19 * f7_26;
+ RHS26 += f7_26 * RHS7;
+ const double f8 = 1.0 / m_A20;
+ const double f8_21 = -f8 * m_A65;
+ m_A66 += m_A21 * f8_21;
+ RHS21 += f8_21 * RHS8;
+ const double f9 = 1.0 / m_A22;
+ const double f9_18 = -f9 * m_A57;
+ m_A58 += m_A23 * f9_18;
+ m_A59 += m_A24 * f9_18;
+ RHS18 += f9_18 * RHS9;
+ const double f9_23 = -f9 * m_A76;
+ m_A78 += m_A23 * f9_23;
+ m_A79 += m_A24 * f9_23;
+ RHS23 += f9_23 * RHS9;
+ const double f10 = 1.0 / m_A25;
+ const double f10_30 = -f10 * m_A121;
+ m_A122 += m_A26 * f10_30;
+ m_A127 += m_A27 * f10_30;
+ RHS30 += f10_30 * RHS10;
+ const double f11 = 1.0 / m_A28;
+ const double f11_15 = -f11 * m_A43;
+ m_A45 += m_A29 * f11_15;
+ m_A46 += m_A30 * f11_15;
+ m_A47 += m_A31 * f11_15;
+ RHS15 += f11_15 * RHS11;
+ const double f11_22 = -f11 * m_A71;
+ m_A73 += m_A29 * f11_22;
+ m_A74 += m_A30 * f11_22;
+ m_A75 += m_A31 * f11_22;
+ RHS22 += f11_22 * RHS11;
+ const double f11_24 = -f11 * m_A82;
+ m_A83 += m_A29 * f11_24;
+ m_A85 += m_A30 * f11_24;
+ m_A86 += m_A31 * f11_24;
+ RHS24 += f11_24 * RHS11;
+ const double f11_25 = -f11 * m_A87;
+ m_A89 += m_A29 * f11_25;
+ m_A91 += m_A30 * f11_25;
+ m_A92 += m_A31 * f11_25;
+ RHS25 += f11_25 * RHS11;
+ const double f11_27 = -f11 * m_A100;
+ m_A102 += m_A29 * f11_27;
+ m_A103 += m_A30 * f11_27;
+ m_A105 += m_A31 * f11_27;
+ RHS27 += f11_27 * RHS11;
+ const double f11_30 = -f11 * m_A122;
+ m_A124 += m_A29 * f11_30;
+ m_A125 += m_A30 * f11_30;
+ m_A127 += m_A31 * f11_30;
+ RHS30 += f11_30 * RHS11;
+ const double f12 = 1.0 / m_A32;
+ const double f12_23 = -f12 * m_A77;
+ m_A79 += m_A33 * f12_23;
+ m_A80 += m_A34 * f12_23;
+ m_A81 += m_A35 * f12_23;
+ RHS23 += f12_23 * RHS12;
+ const double f12_25 = -f12 * m_A88;
+ m_A90 += m_A33 * f12_25;
+ m_A91 += m_A34 * f12_25;
+ m_A93 += m_A35 * f12_25;
+ RHS25 += f12_25 * RHS12;
+ const double f12_29 = -f12 * m_A113;
+ m_A114 += m_A33 * f12_29;
+ m_A116 += m_A34 * f12_29;
+ m_A118 += m_A35 * f12_29;
+ RHS29 += f12_29 * RHS12;
+ const double f13 = 1.0 / m_A36;
+ const double f13_28 = -f13 * m_A108;
+ m_A111 += m_A37 * f13_28;
+ RHS28 += f13_28 * RHS13;
+ const double f14 = 1.0 / m_A38;
+ const double f14_28 = -f14 * m_A109;
+ m_A111 += m_A39 * f14_28;
+ RHS28 += f14_28 * RHS14;
+ const double f15 = 1.0 / m_A44;
+ const double f15_22 = -f15 * m_A72;
+ m_A73 += m_A45 * f15_22;
+ m_A74 += m_A46 * f15_22;
+ m_A75 += m_A47 * f15_22;
+ RHS22 += f15_22 * RHS15;
+ const double f16 = 1.0 / m_A50;
+ const double f16_26 = -f16 * m_A95;
+ m_A97 += m_A51 * f16_26;
+ RHS26 += f16_26 * RHS16;
+ const double f17 = 1.0 / m_A52;
+ const double f17_26 = -f17 * m_A96;
+ m_A97 += m_A53 * f17_26;
+ m_A98 += m_A54 * f17_26;
+ m_A99 += m_A55 * f17_26;
+ RHS26 += f17_26 * RHS17;
+ const double f17_27 = -f17 * m_A101;
+ m_A104 += m_A53 * f17_27;
+ m_A105 += m_A54 * f17_27;
+ m_A107 += m_A55 * f17_27;
+ RHS27 += f17_27 * RHS17;
+ const double f17_30 = -f17 * m_A123;
+ m_A126 += m_A53 * f17_30;
+ m_A127 += m_A54 * f17_30;
+ m_A129 += m_A55 * f17_30;
+ RHS30 += f17_30 * RHS17;
+ const double f18 = 1.0 / m_A58;
+ const double f18_23 = -f18 * m_A78;
+ m_A79 += m_A59 * f18_23;
+ RHS23 += f18_23 * RHS18;
+ const double f19 = 1.0 / m_A60;
+ const double f19_28 = -f19 * m_A110;
+ m_A111 += m_A61 * f19_28;
+ RHS28 += f19_28 * RHS19;
+ const double f20 = 1.0 / m_A63;
+ const double f20_31 = -f20 * m_A131;
+ m_A136 += m_A64 * f20_31;
+ RHS31 += f20_31 * RHS20;
+ const double f21 = 1.0 / m_A66;
+ const double f21_31 = -f21 * m_A132;
+ m_A136 += m_A67 * f21_31;
+ RHS31 += f21_31 * RHS21;
+ const double f22 = 1.0 / m_A73;
+ const double f22_24 = -f22 * m_A83;
+ m_A85 += m_A74 * f22_24;
+ m_A86 += m_A75 * f22_24;
+ RHS24 += f22_24 * RHS22;
+ const double f22_25 = -f22 * m_A89;
+ m_A91 += m_A74 * f22_25;
+ m_A92 += m_A75 * f22_25;
+ RHS25 += f22_25 * RHS22;
+ const double f22_27 = -f22 * m_A102;
+ m_A103 += m_A74 * f22_27;
+ m_A105 += m_A75 * f22_27;
+ RHS27 += f22_27 * RHS22;
+ const double f22_30 = -f22 * m_A124;
+ m_A125 += m_A74 * f22_30;
+ m_A127 += m_A75 * f22_30;
+ RHS30 += f22_30 * RHS22;
+ const double f23 = 1.0 / m_A79;
+ const double f23_25 = -f23 * m_A90;
+ m_A91 += m_A80 * f23_25;
+ m_A93 += m_A81 * f23_25;
+ RHS25 += f23_25 * RHS23;
+ const double f23_29 = -f23 * m_A114;
+ m_A116 += m_A80 * f23_29;
+ m_A118 += m_A81 * f23_29;
+ RHS29 += f23_29 * RHS23;
+ const double f24 = 1.0 / m_A84;
+ const double f24_29 = -f24 * m_A115;
+ m_A116 += m_A85 * f24_29;
+ m_A117 += m_A86 * f24_29;
+ RHS29 += f24_29 * RHS24;
+ const double f25 = 1.0 / m_A91;
+ const double f25_27 = -f25 * m_A103;
+ m_A105 += m_A92 * f25_27;
+ m_A106 += m_A93 * f25_27;
+ RHS27 += f25_27 * RHS25;
+ const double f25_29 = -f25 * m_A116;
+ m_A117 += m_A92 * f25_29;
+ m_A118 += m_A93 * f25_29;
+ RHS29 += f25_29 * RHS25;
+ const double f25_30 = -f25 * m_A125;
+ m_A127 += m_A92 * f25_30;
+ m_A128 += m_A93 * f25_30;
+ RHS30 += f25_30 * RHS25;
+ const double f26 = 1.0 / m_A97;
+ const double f26_27 = -f26 * m_A104;
+ m_A105 += m_A98 * f26_27;
+ m_A107 += m_A99 * f26_27;
+ RHS27 += f26_27 * RHS26;
+ const double f26_30 = -f26 * m_A126;
+ m_A127 += m_A98 * f26_30;
+ m_A129 += m_A99 * f26_30;
+ RHS30 += f26_30 * RHS26;
+ const double f27 = 1.0 / m_A105;
+ const double f27_29 = -f27 * m_A117;
+ m_A118 += m_A106 * f27_29;
+ m_A119 += m_A107 * f27_29;
+ RHS29 += f27_29 * RHS27;
+ const double f27_30 = -f27 * m_A127;
+ m_A128 += m_A106 * f27_30;
+ m_A129 += m_A107 * f27_30;
+ RHS30 += f27_30 * RHS27;
+ const double f28 = 1.0 / m_A111;
+ const double f28_31 = -f28 * m_A133;
+ m_A136 += m_A112 * f28_31;
+ RHS31 += f28_31 * RHS28;
+ const double f29 = 1.0 / m_A118;
+ const double f29_30 = -f29 * m_A128;
+ m_A129 += m_A119 * f29_30;
+ m_A130 += m_A120 * f29_30;
+ RHS30 += f29_30 * RHS29;
+ const double f29_31 = -f29 * m_A134;
+ m_A135 += m_A119 * f29_31;
+ m_A136 += m_A120 * f29_31;
+ RHS31 += f29_31 * RHS29;
+ const double f30 = 1.0 / m_A129;
+ const double f30_31 = -f30 * m_A135;
+ m_A136 += m_A130 * f30_31;
+ RHS31 += f30_31 * RHS30;
+ V[31] = RHS31 / m_A136;
+ double tmp30 = 0.0;
+ tmp30 += m_A130 * V[31];
+ V[30] = (RHS30 - tmp30) / m_A129;
+ double tmp29 = 0.0;
+ tmp29 += m_A119 * V[30];
+ tmp29 += m_A120 * V[31];
+ V[29] = (RHS29 - tmp29) / m_A118;
+ double tmp28 = 0.0;
+ tmp28 += m_A112 * V[31];
+ V[28] = (RHS28 - tmp28) / m_A111;
+ double tmp27 = 0.0;
+ tmp27 += m_A106 * V[29];
+ tmp27 += m_A107 * V[30];
+ V[27] = (RHS27 - tmp27) / m_A105;
+ double tmp26 = 0.0;
+ tmp26 += m_A98 * V[27];
+ tmp26 += m_A99 * V[30];
+ V[26] = (RHS26 - tmp26) / m_A97;
+ double tmp25 = 0.0;
+ tmp25 += m_A92 * V[27];
+ tmp25 += m_A93 * V[29];
+ V[25] = (RHS25 - tmp25) / m_A91;
+ double tmp24 = 0.0;
+ tmp24 += m_A85 * V[25];
+ tmp24 += m_A86 * V[27];
+ V[24] = (RHS24 - tmp24) / m_A84;
+ double tmp23 = 0.0;
+ tmp23 += m_A80 * V[25];
+ tmp23 += m_A81 * V[29];
+ V[23] = (RHS23 - tmp23) / m_A79;
+ double tmp22 = 0.0;
+ tmp22 += m_A74 * V[25];
+ tmp22 += m_A75 * V[27];
+ V[22] = (RHS22 - tmp22) / m_A73;
+ double tmp21 = 0.0;
+ tmp21 += m_A67 * V[31];
+ V[21] = (RHS21 - tmp21) / m_A66;
+ double tmp20 = 0.0;
+ tmp20 += m_A64 * V[31];
+ V[20] = (RHS20 - tmp20) / m_A63;
+ double tmp19 = 0.0;
+ tmp19 += m_A61 * V[28];
+ V[19] = (RHS19 - tmp19) / m_A60;
+ double tmp18 = 0.0;
+ tmp18 += m_A59 * V[23];
+ V[18] = (RHS18 - tmp18) / m_A58;
+ double tmp17 = 0.0;
+ tmp17 += m_A53 * V[26];
+ tmp17 += m_A54 * V[27];
+ tmp17 += m_A55 * V[30];
+ V[17] = (RHS17 - tmp17) / m_A52;
+ double tmp16 = 0.0;
+ tmp16 += m_A51 * V[26];
+ V[16] = (RHS16 - tmp16) / m_A50;
+ double tmp15 = 0.0;
+ tmp15 += m_A45 * V[22];
+ tmp15 += m_A46 * V[25];
+ tmp15 += m_A47 * V[27];
+ V[15] = (RHS15 - tmp15) / m_A44;
+ double tmp14 = 0.0;
+ tmp14 += m_A39 * V[28];
+ V[14] = (RHS14 - tmp14) / m_A38;
+ double tmp13 = 0.0;
+ tmp13 += m_A37 * V[28];
+ V[13] = (RHS13 - tmp13) / m_A36;
+ double tmp12 = 0.0;
+ tmp12 += m_A33 * V[23];
+ tmp12 += m_A34 * V[25];
+ tmp12 += m_A35 * V[29];
+ V[12] = (RHS12 - tmp12) / m_A32;
+ double tmp11 = 0.0;
+ tmp11 += m_A29 * V[22];
+ tmp11 += m_A30 * V[25];
+ tmp11 += m_A31 * V[27];
+ V[11] = (RHS11 - tmp11) / m_A28;
+ double tmp10 = 0.0;
+ tmp10 += m_A26 * V[11];
+ tmp10 += m_A27 * V[27];
+ V[10] = (RHS10 - tmp10) / m_A25;
+ double tmp9 = 0.0;
+ tmp9 += m_A23 * V[18];
+ tmp9 += m_A24 * V[23];
+ V[9] = (RHS9 - tmp9) / m_A22;
+ double tmp8 = 0.0;
+ tmp8 += m_A21 * V[21];
+ V[8] = (RHS8 - tmp8) / m_A20;
+ double tmp7 = 0.0;
+ tmp7 += m_A18 * V[16];
+ tmp7 += m_A19 * V[26];
+ V[7] = (RHS7 - tmp7) / m_A17;
+ double tmp6 = 0.0;
+ tmp6 += m_A16 * V[18];
+ V[6] = (RHS6 - tmp6) / m_A15;
+ double tmp5 = 0.0;
+ tmp5 += m_A14 * V[20];
+ V[5] = (RHS5 - tmp5) / m_A13;
+ double tmp4 = 0.0;
+ tmp4 += m_A11 * V[11];
+ tmp4 += m_A12 * V[22];
+ V[4] = (RHS4 - tmp4) / m_A10;
+ double tmp3 = 0.0;
+ tmp3 += m_A9 * V[16];
+ V[3] = (RHS3 - tmp3) / m_A8;
+ double tmp2 = 0.0;
+ tmp2 += m_A5 * V[4];
+ tmp2 += m_A6 * V[15];
+ tmp2 += m_A7 * V[22];
+ V[2] = (RHS2 - tmp2) / m_A4;
+ double tmp1 = 0.0;
+ tmp1 += m_A3 * V[22];
+ V[1] = (RHS1 - tmp1) / m_A2;
+ double tmp0 = 0.0;
+ tmp0 += m_A1 * V[15];
+ V[0] = (RHS0 - tmp0) / m_A0;
+}
+
// solarq
static void nl_gcr_34e910fc1896999f_76_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -16629,681 +17625,6 @@ static void nl_gcr_7a42b97d838ca073_7_double_double(double * __restrict V, const
V[0] = (RHS0 - tmp0) / m_A0;
}
-// 280zzzap
-static void nl_gcr_7afaac594132b463_104_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
-
-{
-
- plib::unused_var(cnV);
- double m_A0(0.0);
- double m_A1(0.0);
- double m_A2(0.0);
- double m_A3(0.0);
- double m_A4(0.0);
- double m_A5(0.0);
- double m_A6(0.0);
- double m_A7(0.0);
- double m_A8(0.0);
- double m_A9(0.0);
- double m_A10(0.0);
- double m_A11(0.0);
- double m_A12(0.0);
- double m_A13(0.0);
- double m_A14(0.0);
- double m_A15(0.0);
- double m_A16(0.0);
- double m_A17(0.0);
- double m_A18(0.0);
- double m_A19(0.0);
- double m_A20(0.0);
- double m_A21(0.0);
- double m_A22(0.0);
- double m_A23(0.0);
- double m_A24(0.0);
- double m_A25(0.0);
- double m_A26(0.0);
- double m_A27(0.0);
- double m_A28(0.0);
- double m_A29(0.0);
- double m_A30(0.0);
- double m_A31(0.0);
- double m_A32(0.0);
- double m_A33(0.0);
- double m_A34(0.0);
- double m_A35(0.0);
- double m_A36(0.0);
- double m_A37(0.0);
- double m_A38(0.0);
- double m_A39(0.0);
- double m_A40(0.0);
- double m_A41(0.0);
- double m_A42(0.0);
- double m_A43(0.0);
- double m_A44(0.0);
- double m_A45(0.0);
- double m_A46(0.0);
- double m_A47(0.0);
- double m_A48(0.0);
- double m_A49(0.0);
- double m_A50(0.0);
- double m_A51(0.0);
- double m_A52(0.0);
- double m_A53(0.0);
- double m_A54(0.0);
- double m_A55(0.0);
- double m_A56(0.0);
- double m_A57(0.0);
- double m_A58(0.0);
- double m_A59(0.0);
- double m_A60(0.0);
- double m_A61(0.0);
- double m_A62(0.0);
- double m_A63(0.0);
- double m_A64(0.0);
- double m_A65(0.0);
- double m_A66(0.0);
- double m_A67(0.0);
- double m_A68(0.0);
- double m_A69(0.0);
- double m_A70(0.0);
- double m_A71(0.0);
- double m_A72(0.0);
- double m_A73(0.0);
- double m_A74(0.0);
- double m_A75(0.0);
- double m_A76(0.0);
- double m_A77(0.0);
- double m_A78(0.0);
- double m_A79(0.0);
- double m_A80(0.0);
- double m_A81(0.0);
- double m_A82(0.0);
- double m_A83(0.0);
- double m_A84(0.0);
- double m_A85(0.0);
- double m_A86(0.0);
- double m_A87(0.0);
- double m_A88(0.0);
- double m_A89(0.0);
- double m_A90(0.0);
- double m_A91(0.0);
- double m_A92(0.0);
- double m_A93(0.0);
- double m_A94(0.0);
- double m_A95(0.0);
- double m_A96(0.0);
- double m_A97(0.0);
- double m_A98(0.0);
- double m_A99(0.0);
- double m_A100(0.0);
- double m_A101(0.0);
- double m_A102(0.0);
- double m_A103(0.0);
- m_A0 += gt[0];
- m_A0 += gt[1];
- m_A1 += go[0];
- double RHS0 = Idr[0];
- RHS0 += Idr[1];
- RHS0 -= go[1] * *cnV[1];
- m_A2 += gt[2];
- m_A2 += gt[3];
- m_A2 += gt[4];
- m_A2 += gt[5];
- m_A5 += go[2];
- m_A4 += go[3];
- m_A3 += go[4];
- double RHS1 = Idr[2];
- RHS1 += Idr[3];
- RHS1 += Idr[4];
- RHS1 += Idr[5];
- RHS1 -= go[5] * *cnV[5];
- m_A6 += gt[6];
- m_A6 += gt[7];
- m_A6 += gt[8];
- m_A7 += go[6];
- double RHS2 = Idr[6];
- RHS2 += Idr[7];
- RHS2 += Idr[8];
- RHS2 -= go[7] * *cnV[7];
- RHS2 -= go[8] * *cnV[8];
- m_A8 += gt[9];
- m_A8 += gt[10];
- m_A9 += go[9];
- double RHS3 = Idr[9];
- RHS3 += Idr[10];
- RHS3 -= go[10] * *cnV[10];
- m_A10 += gt[11];
- m_A10 += gt[12];
- m_A10 += gt[13];
- m_A12 += go[11];
- m_A11 += go[12];
- double RHS4 = Idr[11];
- RHS4 += Idr[12];
- RHS4 += Idr[13];
- RHS4 -= go[13] * *cnV[13];
- m_A13 += gt[14];
- m_A13 += gt[15];
- m_A14 += go[14];
- double RHS5 = Idr[14];
- RHS5 += Idr[15];
- RHS5 -= go[15] * *cnV[15];
- m_A15 += gt[16];
- m_A15 += gt[17];
- m_A15 += gt[18];
- m_A15 += gt[19];
- m_A15 += gt[20];
- m_A15 += gt[21];
- m_A15 += gt[22];
- m_A19 += go[16];
- m_A18 += go[17];
- m_A17 += go[18];
- m_A16 += go[19];
- double RHS6 = Idr[16];
- RHS6 += Idr[17];
- RHS6 += Idr[18];
- RHS6 += Idr[19];
- RHS6 += Idr[20];
- RHS6 += Idr[21];
- RHS6 += Idr[22];
- RHS6 -= go[20] * *cnV[20];
- RHS6 -= go[21] * *cnV[21];
- RHS6 -= go[22] * *cnV[22];
- m_A20 += gt[23];
- m_A20 += gt[24];
- m_A20 += gt[25];
- m_A20 += gt[26];
- m_A20 += gt[27];
- m_A20 += gt[28];
- m_A20 += gt[29];
- m_A24 += go[23];
- m_A23 += go[24];
- m_A22 += go[25];
- m_A21 += go[26];
- double RHS7 = Idr[23];
- RHS7 += Idr[24];
- RHS7 += Idr[25];
- RHS7 += Idr[26];
- RHS7 += Idr[27];
- RHS7 += Idr[28];
- RHS7 += Idr[29];
- RHS7 -= go[27] * *cnV[27];
- RHS7 -= go[28] * *cnV[28];
- RHS7 -= go[29] * *cnV[29];
- m_A25 += gt[30];
- m_A25 += gt[31];
- m_A25 += gt[32];
- m_A26 += go[30];
- m_A27 += go[31];
- double RHS8 = Idr[30];
- RHS8 += Idr[31];
- RHS8 += Idr[32];
- RHS8 -= go[32] * *cnV[32];
- m_A28 += gt[33];
- m_A28 += gt[34];
- m_A29 += go[33];
- double RHS9 = Idr[33];
- RHS9 += Idr[34];
- RHS9 -= go[34] * *cnV[34];
- m_A30 += gt[35];
- m_A30 += gt[36];
- m_A30 += gt[37];
- m_A30 += gt[38];
- m_A31 += go[35];
- double RHS10 = Idr[35];
- RHS10 += Idr[36];
- RHS10 += Idr[37];
- RHS10 += Idr[38];
- RHS10 -= go[36] * *cnV[36];
- RHS10 -= go[37] * *cnV[37];
- RHS10 -= go[38] * *cnV[38];
- m_A32 += gt[39];
- m_A32 += gt[40];
- m_A33 += go[39];
- double RHS11 = Idr[39];
- RHS11 += Idr[40];
- RHS11 -= go[40] * *cnV[40];
- m_A36 += gt[41];
- m_A36 += gt[42];
- m_A36 += gt[43];
- m_A36 += gt[44];
- m_A35 += go[41];
- m_A34 += go[42];
- double RHS12 = Idr[41];
- RHS12 += Idr[42];
- RHS12 += Idr[43];
- RHS12 += Idr[44];
- RHS12 -= go[43] * *cnV[43];
- RHS12 -= go[44] * *cnV[44];
- m_A42 += gt[45];
- m_A42 += gt[46];
- m_A42 += gt[47];
- m_A42 += gt[48];
- m_A40 += go[45];
- m_A41 += go[46];
- m_A43 += go[47];
- m_A39 += go[48];
- double RHS13 = Idr[45];
- RHS13 += Idr[46];
- RHS13 += Idr[47];
- RHS13 += Idr[48];
- m_A45 += gt[49];
- m_A45 += gt[50];
- m_A45 += gt[51];
- m_A45 += gt[52];
- m_A44 += go[49];
- m_A46 += go[50];
- double RHS14 = Idr[49];
- RHS14 += Idr[50];
- RHS14 += Idr[51];
- RHS14 += Idr[52];
- RHS14 -= go[51] * *cnV[51];
- RHS14 -= go[52] * *cnV[52];
- m_A50 += gt[53];
- m_A50 += gt[54];
- m_A50 += gt[55];
- m_A50 += gt[56];
- m_A48 += go[53];
- m_A47 += go[54];
- double RHS15 = Idr[53];
- RHS15 += Idr[54];
- RHS15 += Idr[55];
- RHS15 += Idr[56];
- RHS15 -= go[55] * *cnV[55];
- RHS15 -= go[56] * *cnV[56];
- m_A57 += gt[57];
- m_A57 += gt[58];
- m_A57 += gt[59];
- m_A57 += gt[60];
- m_A56 += go[57];
- m_A55 += go[58];
- m_A58 += go[59];
- double RHS16 = Idr[57];
- RHS16 += Idr[58];
- RHS16 += Idr[59];
- RHS16 += Idr[60];
- RHS16 -= go[60] * *cnV[60];
- m_A63 += gt[61];
- m_A63 += gt[62];
- m_A63 += gt[63];
- m_A63 += gt[64];
- m_A66 += go[61];
- m_A60 += go[62];
- m_A59 += go[63];
- double RHS17 = Idr[61];
- RHS17 += Idr[62];
- RHS17 += Idr[63];
- RHS17 += Idr[64];
- RHS17 -= go[64] * *cnV[64];
- m_A74 += gt[65];
- m_A74 += gt[66];
- m_A74 += gt[67];
- m_A74 += gt[68];
- m_A74 += gt[69];
- m_A74 += gt[70];
- m_A77 += go[65];
- m_A70 += go[66];
- m_A69 += go[67];
- m_A68 += go[68];
- m_A71 += go[69];
- double RHS18 = Idr[65];
- RHS18 += Idr[66];
- RHS18 += Idr[67];
- RHS18 += Idr[68];
- RHS18 += Idr[69];
- RHS18 += Idr[70];
- RHS18 -= go[70] * *cnV[70];
- m_A85 += gt[71];
- m_A85 += gt[72];
- m_A85 += gt[73];
- m_A85 += gt[74];
- m_A85 += gt[75];
- m_A85 += gt[76];
- m_A82 += go[71];
- m_A87 += go[72];
- m_A79 += go[73];
- m_A80 += go[74];
- m_A78 += go[75];
- double RHS19 = Idr[71];
- RHS19 += Idr[72];
- RHS19 += Idr[73];
- RHS19 += Idr[74];
- RHS19 += Idr[75];
- RHS19 += Idr[76];
- RHS19 -= go[76] * *cnV[76];
- m_A93 += gt[77];
- m_A93 += gt[78];
- m_A93 += gt[79];
- m_A93 += gt[80];
- m_A93 += gt[81];
- m_A89 += go[77];
- m_A88 += go[78];
- m_A90 += go[79];
- double RHS20 = Idr[77];
- RHS20 += Idr[78];
- RHS20 += Idr[79];
- RHS20 += Idr[80];
- RHS20 += Idr[81];
- RHS20 -= go[80] * *cnV[80];
- RHS20 -= go[81] * *cnV[81];
- m_A103 += gt[82];
- m_A103 += gt[83];
- m_A103 += gt[84];
- m_A103 += gt[85];
- m_A103 += gt[86];
- m_A103 += gt[87];
- m_A103 += gt[88];
- m_A97 += go[82];
- m_A96 += go[83];
- m_A101 += go[84];
- m_A95 += go[85];
- m_A100 += go[86];
- double RHS21 = Idr[82];
- RHS21 += Idr[83];
- RHS21 += Idr[84];
- RHS21 += Idr[85];
- RHS21 += Idr[86];
- RHS21 += Idr[87];
- RHS21 += Idr[88];
- RHS21 -= go[87] * *cnV[87];
- RHS21 -= go[88] * *cnV[88];
- const double f0 = 1.0 / m_A0;
- const double f0_12 = -f0 * m_A34;
- m_A36 += m_A1 * f0_12;
- RHS12 += f0_12 * RHS0;
- const double f1 = 1.0 / m_A2;
- const double f1_12 = -f1 * m_A35;
- m_A36 += m_A3 * f1_12;
- m_A37 += m_A4 * f1_12;
- m_A38 += m_A5 * f1_12;
- RHS12 += f1_12 * RHS1;
- const double f1_15 = -f1 * m_A47;
- m_A49 += m_A3 * f1_15;
- m_A50 += m_A4 * f1_15;
- m_A51 += m_A5 * f1_15;
- RHS15 += f1_15 * RHS1;
- const double f1_17 = -f1 * m_A59;
- m_A61 += m_A3 * f1_17;
- m_A62 += m_A4 * f1_17;
- m_A63 += m_A5 * f1_17;
- RHS17 += f1_17 * RHS1;
- const double f2 = 1.0 / m_A6;
- const double f2_13 = -f2 * m_A39;
- m_A42 += m_A7 * f2_13;
- RHS13 += f2_13 * RHS2;
- const double f3 = 1.0 / m_A8;
- const double f3_13 = -f3 * m_A40;
- m_A42 += m_A9 * f3_13;
- RHS13 += f3_13 * RHS3;
- const double f4 = 1.0 / m_A10;
- const double f4_13 = -f4 * m_A41;
- m_A42 += m_A11 * f4_13;
- m_A43 += m_A12 * f4_13;
- RHS13 += f4_13 * RHS4;
- const double f4_18 = -f4 * m_A68;
- m_A71 += m_A11 * f4_18;
- m_A74 += m_A12 * f4_18;
- RHS18 += f4_18 * RHS4;
- const double f5 = 1.0 / m_A13;
- const double f5_14 = -f5 * m_A44;
- m_A45 += m_A14 * f5_14;
- RHS14 += f5_14 * RHS5;
- const double f6 = 1.0 / m_A15;
- const double f6_15 = -f6 * m_A48;
- m_A50 += m_A16 * f6_15;
- m_A52 += m_A17 * f6_15;
- m_A53 += m_A18 * f6_15;
- m_A54 += m_A19 * f6_15;
- RHS15 += f6_15 * RHS6;
- const double f6_18 = -f6 * m_A69;
- m_A72 += m_A16 * f6_18;
- m_A74 += m_A17 * f6_18;
- m_A75 += m_A18 * f6_18;
- m_A77 += m_A19 * f6_18;
- RHS18 += f6_18 * RHS6;
- const double f6_19 = -f6 * m_A78;
- m_A81 += m_A16 * f6_19;
- m_A84 += m_A17 * f6_19;
- m_A85 += m_A18 * f6_19;
- m_A87 += m_A19 * f6_19;
- RHS19 += f6_19 * RHS6;
- const double f6_21 = -f6 * m_A95;
- m_A98 += m_A16 * f6_21;
- m_A100 += m_A17 * f6_21;
- m_A101 += m_A18 * f6_21;
- m_A103 += m_A19 * f6_21;
- RHS21 += f6_21 * RHS6;
- const double f7 = 1.0 / m_A20;
- const double f7_17 = -f7 * m_A60;
- m_A63 += m_A21 * f7_17;
- m_A64 += m_A22 * f7_17;
- m_A65 += m_A23 * f7_17;
- m_A67 += m_A24 * f7_17;
- RHS17 += f7_17 * RHS7;
- const double f7_18 = -f7 * m_A70;
- m_A73 += m_A21 * f7_18;
- m_A74 += m_A22 * f7_18;
- m_A75 += m_A23 * f7_18;
- m_A77 += m_A24 * f7_18;
- RHS18 += f7_18 * RHS7;
- const double f7_19 = -f7 * m_A79;
- m_A83 += m_A21 * f7_19;
- m_A84 += m_A22 * f7_19;
- m_A85 += m_A23 * f7_19;
- m_A87 += m_A24 * f7_19;
- RHS19 += f7_19 * RHS7;
- const double f7_21 = -f7 * m_A96;
- m_A99 += m_A21 * f7_21;
- m_A100 += m_A22 * f7_21;
- m_A101 += m_A23 * f7_21;
- m_A103 += m_A24 * f7_21;
- RHS21 += f7_21 * RHS7;
- const double f8 = 1.0 / m_A25;
- const double f8_16 = -f8 * m_A55;
- m_A57 += m_A26 * f8_16;
- m_A58 += m_A27 * f8_16;
- RHS16 += f8_16 * RHS8;
- const double f8_19 = -f8 * m_A80;
- m_A82 += m_A26 * f8_19;
- m_A85 += m_A27 * f8_19;
- RHS19 += f8_19 * RHS8;
- const double f9 = 1.0 / m_A28;
- const double f9_16 = -f9 * m_A56;
- m_A57 += m_A29 * f9_16;
- RHS16 += f9_16 * RHS9;
- const double f10 = 1.0 / m_A30;
- const double f10_20 = -f10 * m_A88;
- m_A93 += m_A31 * f10_20;
- RHS20 += f10_20 * RHS10;
- const double f11 = 1.0 / m_A32;
- const double f11_20 = -f11 * m_A89;
- m_A93 += m_A33 * f11_20;
- RHS20 += f11_20 * RHS11;
- const double f12 = 1.0 / m_A36;
- const double f12_15 = -f12 * m_A49;
- m_A50 += m_A37 * f12_15;
- m_A51 += m_A38 * f12_15;
- RHS15 += f12_15 * RHS12;
- const double f12_17 = -f12 * m_A61;
- m_A62 += m_A37 * f12_17;
- m_A63 += m_A38 * f12_17;
- RHS17 += f12_17 * RHS12;
- const double f13 = 1.0 / m_A42;
- const double f13_18 = -f13 * m_A71;
- m_A74 += m_A43 * f13_18;
- RHS18 += f13_18 * RHS13;
- const double f14 = 1.0 / m_A45;
- const double f14_21 = -f14 * m_A97;
- m_A103 += m_A46 * f14_21;
- RHS21 += f14_21 * RHS14;
- const double f15 = 1.0 / m_A50;
- const double f15_17 = -f15 * m_A62;
- m_A63 += m_A51 * f15_17;
- m_A64 += m_A52 * f15_17;
- m_A65 += m_A53 * f15_17;
- m_A67 += m_A54 * f15_17;
- RHS17 += f15_17 * RHS15;
- const double f15_18 = -f15 * m_A72;
- m_A73 += m_A51 * f15_18;
- m_A74 += m_A52 * f15_18;
- m_A75 += m_A53 * f15_18;
- m_A77 += m_A54 * f15_18;
- RHS18 += f15_18 * RHS15;
- const double f15_19 = -f15 * m_A81;
- m_A83 += m_A51 * f15_19;
- m_A84 += m_A52 * f15_19;
- m_A85 += m_A53 * f15_19;
- m_A87 += m_A54 * f15_19;
- RHS19 += f15_19 * RHS15;
- const double f15_21 = -f15 * m_A98;
- m_A99 += m_A51 * f15_21;
- m_A100 += m_A52 * f15_21;
- m_A101 += m_A53 * f15_21;
- m_A103 += m_A54 * f15_21;
- RHS21 += f15_21 * RHS15;
- const double f16 = 1.0 / m_A57;
- const double f16_19 = -f16 * m_A82;
- m_A85 += m_A58 * f16_19;
- RHS19 += f16_19 * RHS16;
- const double f17 = 1.0 / m_A63;
- const double f17_18 = -f17 * m_A73;
- m_A74 += m_A64 * f17_18;
- m_A75 += m_A65 * f17_18;
- m_A76 += m_A66 * f17_18;
- m_A77 += m_A67 * f17_18;
- RHS18 += f17_18 * RHS17;
- const double f17_19 = -f17 * m_A83;
- m_A84 += m_A64 * f17_19;
- m_A85 += m_A65 * f17_19;
- m_A86 += m_A66 * f17_19;
- m_A87 += m_A67 * f17_19;
- RHS19 += f17_19 * RHS17;
- const double f17_20 = -f17 * m_A90;
- m_A91 += m_A64 * f17_20;
- m_A92 += m_A65 * f17_20;
- m_A93 += m_A66 * f17_20;
- m_A94 += m_A67 * f17_20;
- RHS20 += f17_20 * RHS17;
- const double f17_21 = -f17 * m_A99;
- m_A100 += m_A64 * f17_21;
- m_A101 += m_A65 * f17_21;
- m_A102 += m_A66 * f17_21;
- m_A103 += m_A67 * f17_21;
- RHS21 += f17_21 * RHS17;
- const double f18 = 1.0 / m_A74;
- const double f18_19 = -f18 * m_A84;
- m_A85 += m_A75 * f18_19;
- m_A86 += m_A76 * f18_19;
- m_A87 += m_A77 * f18_19;
- RHS19 += f18_19 * RHS18;
- const double f18_20 = -f18 * m_A91;
- m_A92 += m_A75 * f18_20;
- m_A93 += m_A76 * f18_20;
- m_A94 += m_A77 * f18_20;
- RHS20 += f18_20 * RHS18;
- const double f18_21 = -f18 * m_A100;
- m_A101 += m_A75 * f18_21;
- m_A102 += m_A76 * f18_21;
- m_A103 += m_A77 * f18_21;
- RHS21 += f18_21 * RHS18;
- const double f19 = 1.0 / m_A85;
- const double f19_20 = -f19 * m_A92;
- m_A93 += m_A86 * f19_20;
- m_A94 += m_A87 * f19_20;
- RHS20 += f19_20 * RHS19;
- const double f19_21 = -f19 * m_A101;
- m_A102 += m_A86 * f19_21;
- m_A103 += m_A87 * f19_21;
- RHS21 += f19_21 * RHS19;
- const double f20 = 1.0 / m_A93;
- const double f20_21 = -f20 * m_A102;
- m_A103 += m_A94 * f20_21;
- RHS21 += f20_21 * RHS20;
- V[21] = RHS21 / m_A103;
- double tmp20 = 0.0;
- tmp20 += m_A94 * V[21];
- V[20] = (RHS20 - tmp20) / m_A93;
- double tmp19 = 0.0;
- tmp19 += m_A86 * V[20];
- tmp19 += m_A87 * V[21];
- V[19] = (RHS19 - tmp19) / m_A85;
- double tmp18 = 0.0;
- tmp18 += m_A75 * V[19];
- tmp18 += m_A76 * V[20];
- tmp18 += m_A77 * V[21];
- V[18] = (RHS18 - tmp18) / m_A74;
- double tmp17 = 0.0;
- tmp17 += m_A64 * V[18];
- tmp17 += m_A65 * V[19];
- tmp17 += m_A66 * V[20];
- tmp17 += m_A67 * V[21];
- V[17] = (RHS17 - tmp17) / m_A63;
- double tmp16 = 0.0;
- tmp16 += m_A58 * V[19];
- V[16] = (RHS16 - tmp16) / m_A57;
- double tmp15 = 0.0;
- tmp15 += m_A51 * V[17];
- tmp15 += m_A52 * V[18];
- tmp15 += m_A53 * V[19];
- tmp15 += m_A54 * V[21];
- V[15] = (RHS15 - tmp15) / m_A50;
- double tmp14 = 0.0;
- tmp14 += m_A46 * V[21];
- V[14] = (RHS14 - tmp14) / m_A45;
- double tmp13 = 0.0;
- tmp13 += m_A43 * V[18];
- V[13] = (RHS13 - tmp13) / m_A42;
- double tmp12 = 0.0;
- tmp12 += m_A37 * V[15];
- tmp12 += m_A38 * V[17];
- V[12] = (RHS12 - tmp12) / m_A36;
- double tmp11 = 0.0;
- tmp11 += m_A33 * V[20];
- V[11] = (RHS11 - tmp11) / m_A32;
- double tmp10 = 0.0;
- tmp10 += m_A31 * V[20];
- V[10] = (RHS10 - tmp10) / m_A30;
- double tmp9 = 0.0;
- tmp9 += m_A29 * V[16];
- V[9] = (RHS9 - tmp9) / m_A28;
- double tmp8 = 0.0;
- tmp8 += m_A26 * V[16];
- tmp8 += m_A27 * V[19];
- V[8] = (RHS8 - tmp8) / m_A25;
- double tmp7 = 0.0;
- tmp7 += m_A21 * V[17];
- tmp7 += m_A22 * V[18];
- tmp7 += m_A23 * V[19];
- tmp7 += m_A24 * V[21];
- V[7] = (RHS7 - tmp7) / m_A20;
- double tmp6 = 0.0;
- tmp6 += m_A16 * V[15];
- tmp6 += m_A17 * V[18];
- tmp6 += m_A18 * V[19];
- tmp6 += m_A19 * V[21];
- V[6] = (RHS6 - tmp6) / m_A15;
- double tmp5 = 0.0;
- tmp5 += m_A14 * V[14];
- V[5] = (RHS5 - tmp5) / m_A13;
- double tmp4 = 0.0;
- tmp4 += m_A11 * V[13];
- tmp4 += m_A12 * V[18];
- V[4] = (RHS4 - tmp4) / m_A10;
- double tmp3 = 0.0;
- tmp3 += m_A9 * V[13];
- V[3] = (RHS3 - tmp3) / m_A8;
- double tmp2 = 0.0;
- tmp2 += m_A7 * V[13];
- V[2] = (RHS2 - tmp2) / m_A6;
- double tmp1 = 0.0;
- tmp1 += m_A3 * V[12];
- tmp1 += m_A4 * V[15];
- tmp1 += m_A5 * V[17];
- V[1] = (RHS1 - tmp1) / m_A2;
- double tmp0 = 0.0;
- tmp0 += m_A1 * V[12];
- V[0] = (RHS0 - tmp0) / m_A0;
-}
-
// cheekyms
static void nl_gcr_7c86a9bc1c6aef4c_7_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -20283,6 +20604,859 @@ static void nl_gcr_8c0f7f2284333de5_16_double_double(double * __restrict V, cons
V[0] = (RHS0 - tmp0) / m_A0;
}
+// starcrus
+static void nl_gcr_8d7bddf33d942482_129_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
+
+{
+
+ plib::unused_var(cnV);
+ double m_A0(0.0);
+ double m_A1(0.0);
+ double m_A2(0.0);
+ double m_A3(0.0);
+ double m_A4(0.0);
+ double m_A5(0.0);
+ double m_A6(0.0);
+ double m_A7(0.0);
+ double m_A8(0.0);
+ double m_A9(0.0);
+ double m_A10(0.0);
+ double m_A11(0.0);
+ double m_A12(0.0);
+ double m_A13(0.0);
+ double m_A14(0.0);
+ double m_A15(0.0);
+ double m_A16(0.0);
+ double m_A17(0.0);
+ double m_A18(0.0);
+ double m_A19(0.0);
+ double m_A20(0.0);
+ double m_A21(0.0);
+ double m_A22(0.0);
+ double m_A23(0.0);
+ double m_A24(0.0);
+ double m_A25(0.0);
+ double m_A26(0.0);
+ double m_A27(0.0);
+ double m_A28(0.0);
+ double m_A29(0.0);
+ double m_A30(0.0);
+ double m_A31(0.0);
+ double m_A32(0.0);
+ double m_A33(0.0);
+ double m_A34(0.0);
+ double m_A35(0.0);
+ double m_A36(0.0);
+ double m_A37(0.0);
+ double m_A38(0.0);
+ double m_A39(0.0);
+ double m_A40(0.0);
+ double m_A41(0.0);
+ double m_A42(0.0);
+ double m_A43(0.0);
+ double m_A44(0.0);
+ double m_A45(0.0);
+ double m_A46(0.0);
+ double m_A47(0.0);
+ double m_A48(0.0);
+ double m_A49(0.0);
+ double m_A50(0.0);
+ double m_A51(0.0);
+ double m_A52(0.0);
+ double m_A53(0.0);
+ double m_A54(0.0);
+ double m_A55(0.0);
+ double m_A56(0.0);
+ double m_A57(0.0);
+ double m_A58(0.0);
+ double m_A59(0.0);
+ double m_A60(0.0);
+ double m_A61(0.0);
+ double m_A62(0.0);
+ double m_A63(0.0);
+ double m_A64(0.0);
+ double m_A65(0.0);
+ double m_A66(0.0);
+ double m_A67(0.0);
+ double m_A68(0.0);
+ double m_A69(0.0);
+ double m_A70(0.0);
+ double m_A71(0.0);
+ double m_A72(0.0);
+ double m_A73(0.0);
+ double m_A74(0.0);
+ double m_A75(0.0);
+ double m_A76(0.0);
+ double m_A77(0.0);
+ double m_A78(0.0);
+ double m_A79(0.0);
+ double m_A80(0.0);
+ double m_A81(0.0);
+ double m_A82(0.0);
+ double m_A83(0.0);
+ double m_A84(0.0);
+ double m_A85(0.0);
+ double m_A86(0.0);
+ double m_A87(0.0);
+ double m_A88(0.0);
+ double m_A89(0.0);
+ double m_A90(0.0);
+ double m_A91(0.0);
+ double m_A92(0.0);
+ double m_A93(0.0);
+ double m_A94(0.0);
+ double m_A95(0.0);
+ double m_A96(0.0);
+ double m_A97(0.0);
+ double m_A98(0.0);
+ double m_A99(0.0);
+ double m_A100(0.0);
+ double m_A101(0.0);
+ double m_A102(0.0);
+ double m_A103(0.0);
+ double m_A104(0.0);
+ double m_A105(0.0);
+ double m_A106(0.0);
+ double m_A107(0.0);
+ double m_A108(0.0);
+ double m_A109(0.0);
+ double m_A110(0.0);
+ double m_A111(0.0);
+ double m_A112(0.0);
+ double m_A113(0.0);
+ double m_A114(0.0);
+ double m_A115(0.0);
+ double m_A116(0.0);
+ double m_A117(0.0);
+ double m_A118(0.0);
+ double m_A119(0.0);
+ double m_A120(0.0);
+ double m_A121(0.0);
+ double m_A122(0.0);
+ double m_A123(0.0);
+ double m_A124(0.0);
+ double m_A125(0.0);
+ double m_A126(0.0);
+ double m_A127(0.0);
+ double m_A128(0.0);
+ m_A0 += gt[0];
+ m_A0 += gt[1];
+ m_A0 += gt[2];
+ m_A1 += go[0];
+ double RHS0 = Idr[0];
+ RHS0 += Idr[1];
+ RHS0 += Idr[2];
+ RHS0 -= go[1] * *cnV[1];
+ RHS0 -= go[2] * *cnV[2];
+ m_A2 += gt[3];
+ m_A2 += gt[4];
+ m_A2 += gt[5];
+ m_A2 += gt[6];
+ m_A2 += gt[7];
+ m_A4 += go[3];
+ m_A3 += go[4];
+ m_A3 += go[5];
+ double RHS1 = Idr[3];
+ RHS1 += Idr[4];
+ RHS1 += Idr[5];
+ RHS1 += Idr[6];
+ RHS1 += Idr[7];
+ RHS1 -= go[6] * *cnV[6];
+ RHS1 -= go[7] * *cnV[7];
+ m_A5 += gt[8];
+ m_A5 += gt[9];
+ m_A7 += go[8];
+ m_A6 += go[9];
+ double RHS2 = Idr[8];
+ RHS2 += Idr[9];
+ m_A8 += gt[10];
+ m_A8 += gt[11];
+ m_A9 += go[10];
+ double RHS3 = Idr[10];
+ RHS3 += Idr[11];
+ RHS3 -= go[11] * *cnV[11];
+ m_A10 += gt[12];
+ m_A10 += gt[13];
+ m_A10 += gt[14];
+ m_A11 += go[12];
+ m_A12 += go[13];
+ double RHS4 = Idr[12];
+ RHS4 += Idr[13];
+ RHS4 += Idr[14];
+ RHS4 -= go[14] * *cnV[14];
+ m_A13 += gt[15];
+ m_A13 += gt[16];
+ m_A13 += gt[17];
+ m_A15 += go[15];
+ m_A14 += go[16];
+ double RHS5 = Idr[15];
+ RHS5 += Idr[16];
+ RHS5 += Idr[17];
+ RHS5 -= go[17] * *cnV[17];
+ m_A16 += gt[18];
+ m_A16 += gt[19];
+ m_A16 += gt[20];
+ m_A16 += gt[21];
+ m_A16 += gt[22];
+ m_A17 += go[18];
+ m_A18 += go[19];
+ double RHS6 = Idr[18];
+ RHS6 += Idr[19];
+ RHS6 += Idr[20];
+ RHS6 += Idr[21];
+ RHS6 += Idr[22];
+ RHS6 -= go[20] * *cnV[20];
+ RHS6 -= go[21] * *cnV[21];
+ RHS6 -= go[22] * *cnV[22];
+ m_A19 += gt[23];
+ m_A19 += gt[24];
+ m_A19 += gt[25];
+ m_A19 += gt[26];
+ m_A19 += gt[27];
+ m_A19 += gt[28];
+ m_A19 += gt[29];
+ m_A21 += go[23];
+ m_A20 += go[24];
+ double RHS7 = Idr[23];
+ RHS7 += Idr[24];
+ RHS7 += Idr[25];
+ RHS7 += Idr[26];
+ RHS7 += Idr[27];
+ RHS7 += Idr[28];
+ RHS7 += Idr[29];
+ RHS7 -= go[25] * *cnV[25];
+ RHS7 -= go[26] * *cnV[26];
+ RHS7 -= go[27] * *cnV[27];
+ RHS7 -= go[28] * *cnV[28];
+ RHS7 -= go[29] * *cnV[29];
+ m_A22 += gt[30];
+ m_A22 += gt[31];
+ m_A24 += go[30];
+ m_A23 += go[31];
+ double RHS8 = Idr[30];
+ RHS8 += Idr[31];
+ m_A25 += gt[32];
+ m_A25 += gt[33];
+ m_A25 += gt[34];
+ m_A25 += gt[35];
+ m_A25 += gt[36];
+ m_A25 += gt[37];
+ m_A25 += gt[38];
+ m_A27 += go[32];
+ m_A27 += go[33];
+ m_A26 += go[34];
+ m_A28 += go[35];
+ double RHS9 = Idr[32];
+ RHS9 += Idr[33];
+ RHS9 += Idr[34];
+ RHS9 += Idr[35];
+ RHS9 += Idr[36];
+ RHS9 += Idr[37];
+ RHS9 += Idr[38];
+ RHS9 -= go[36] * *cnV[36];
+ RHS9 -= go[37] * *cnV[37];
+ RHS9 -= go[38] * *cnV[38];
+ m_A29 += gt[39];
+ m_A29 += gt[40];
+ m_A29 += gt[41];
+ m_A29 += gt[42];
+ m_A29 += gt[43];
+ m_A29 += gt[44];
+ m_A31 += go[39];
+ m_A30 += go[40];
+ m_A30 += go[41];
+ double RHS10 = Idr[39];
+ RHS10 += Idr[40];
+ RHS10 += Idr[41];
+ RHS10 += Idr[42];
+ RHS10 += Idr[43];
+ RHS10 += Idr[44];
+ RHS10 -= go[42] * *cnV[42];
+ RHS10 -= go[43] * *cnV[43];
+ RHS10 -= go[44] * *cnV[44];
+ m_A32 += gt[45];
+ m_A32 += gt[46];
+ m_A32 += gt[47];
+ m_A32 += gt[48];
+ m_A32 += gt[49];
+ m_A33 += go[45];
+ m_A33 += go[46];
+ m_A34 += go[47];
+ double RHS11 = Idr[45];
+ RHS11 += Idr[46];
+ RHS11 += Idr[47];
+ RHS11 += Idr[48];
+ RHS11 += Idr[49];
+ RHS11 -= go[48] * *cnV[48];
+ RHS11 -= go[49] * *cnV[49];
+ m_A35 += gt[50];
+ m_A35 += gt[51];
+ m_A35 += gt[52];
+ m_A35 += gt[53];
+ m_A37 += go[50];
+ m_A37 += go[51];
+ m_A36 += go[52];
+ double RHS12 = Idr[50];
+ RHS12 += Idr[51];
+ RHS12 += Idr[52];
+ RHS12 += Idr[53];
+ RHS12 -= go[53] * *cnV[53];
+ m_A38 += gt[54];
+ m_A38 += gt[55];
+ m_A38 += gt[56];
+ m_A38 += gt[57];
+ m_A40 += go[54];
+ m_A40 += go[55];
+ m_A39 += go[56];
+ double RHS13 = Idr[54];
+ RHS13 += Idr[55];
+ RHS13 += Idr[56];
+ RHS13 += Idr[57];
+ RHS13 -= go[57] * *cnV[57];
+ m_A41 += gt[58];
+ m_A41 += gt[59];
+ m_A41 += gt[60];
+ m_A41 += gt[61];
+ m_A42 += go[58];
+ double RHS14 = Idr[58];
+ RHS14 += Idr[59];
+ RHS14 += Idr[60];
+ RHS14 += Idr[61];
+ RHS14 -= go[59] * *cnV[59];
+ RHS14 -= go[60] * *cnV[60];
+ RHS14 -= go[61] * *cnV[61];
+ m_A45 += gt[62];
+ m_A45 += gt[63];
+ m_A45 += gt[64];
+ m_A45 += gt[65];
+ m_A45 += gt[66];
+ m_A44 += go[62];
+ m_A44 += go[63];
+ m_A43 += go[64];
+ double RHS15 = Idr[62];
+ RHS15 += Idr[63];
+ RHS15 += Idr[64];
+ RHS15 += Idr[65];
+ RHS15 += Idr[66];
+ RHS15 -= go[65] * *cnV[65];
+ RHS15 -= go[66] * *cnV[66];
+ m_A49 += gt[67];
+ m_A49 += gt[68];
+ m_A48 += go[67];
+ m_A47 += go[68];
+ double RHS16 = Idr[67];
+ RHS16 += Idr[68];
+ m_A56 += gt[69];
+ m_A56 += gt[70];
+ m_A56 += gt[71];
+ m_A54 += go[69];
+ m_A52 += go[70];
+ m_A55 += go[71];
+ double RHS17 = Idr[69];
+ RHS17 += Idr[70];
+ RHS17 += Idr[71];
+ m_A63 += gt[72];
+ m_A63 += gt[73];
+ m_A63 += gt[74];
+ m_A63 += gt[75];
+ m_A61 += go[72];
+ m_A61 += go[73];
+ m_A60 += go[74];
+ double RHS18 = Idr[72];
+ RHS18 += Idr[73];
+ RHS18 += Idr[74];
+ RHS18 += Idr[75];
+ RHS18 -= go[75] * *cnV[75];
+ m_A71 += gt[76];
+ m_A71 += gt[77];
+ m_A71 += gt[78];
+ m_A71 += gt[79];
+ m_A71 += gt[80];
+ m_A71 += gt[81];
+ m_A71 += gt[82];
+ m_A71 += gt[83];
+ m_A68 += go[76];
+ m_A68 += go[77];
+ m_A67 += go[78];
+ m_A67 += go[79];
+ double RHS19 = Idr[76];
+ RHS19 += Idr[77];
+ RHS19 += Idr[78];
+ RHS19 += Idr[79];
+ RHS19 += Idr[80];
+ RHS19 += Idr[81];
+ RHS19 += Idr[82];
+ RHS19 += Idr[83];
+ RHS19 -= go[80] * *cnV[80];
+ RHS19 -= go[81] * *cnV[81];
+ RHS19 -= go[82] * *cnV[82];
+ RHS19 -= go[83] * *cnV[83];
+ m_A76 += gt[84];
+ m_A76 += gt[85];
+ m_A77 += go[84];
+ m_A74 += go[85];
+ double RHS20 = Idr[84];
+ RHS20 += Idr[85];
+ m_A83 += gt[86];
+ m_A83 += gt[87];
+ m_A83 += gt[88];
+ m_A83 += gt[89];
+ m_A80 += go[86];
+ m_A79 += go[87];
+ m_A78 += go[88];
+ double RHS21 = Idr[86];
+ RHS21 += Idr[87];
+ RHS21 += Idr[88];
+ RHS21 += Idr[89];
+ RHS21 -= go[89] * *cnV[89];
+ m_A89 += gt[90];
+ m_A89 += gt[91];
+ m_A89 += gt[92];
+ m_A89 += gt[93];
+ m_A89 += gt[94];
+ m_A89 += gt[95];
+ m_A87 += go[90];
+ m_A86 += go[91];
+ m_A86 += go[92];
+ double RHS22 = Idr[90];
+ RHS22 += Idr[91];
+ RHS22 += Idr[92];
+ RHS22 += Idr[93];
+ RHS22 += Idr[94];
+ RHS22 += Idr[95];
+ RHS22 -= go[93] * *cnV[93];
+ RHS22 -= go[94] * *cnV[94];
+ RHS22 -= go[95] * *cnV[95];
+ m_A95 += gt[96];
+ m_A95 += gt[97];
+ m_A95 += gt[98];
+ m_A95 += gt[99];
+ m_A95 += gt[100];
+ m_A93 += go[96];
+ m_A92 += go[97];
+ m_A92 += go[98];
+ double RHS23 = Idr[96];
+ RHS23 += Idr[97];
+ RHS23 += Idr[98];
+ RHS23 += Idr[99];
+ RHS23 += Idr[100];
+ RHS23 -= go[99] * *cnV[99];
+ RHS23 -= go[100] * *cnV[100];
+ m_A98 += gt[101];
+ m_A98 += gt[102];
+ m_A98 += gt[103];
+ m_A98 += gt[104];
+ m_A98 += gt[105];
+ m_A99 += go[101];
+ m_A99 += go[102];
+ m_A97 += go[103];
+ double RHS24 = Idr[101];
+ RHS24 += Idr[102];
+ RHS24 += Idr[103];
+ RHS24 += Idr[104];
+ RHS24 += Idr[105];
+ RHS24 -= go[104] * *cnV[104];
+ RHS24 -= go[105] * *cnV[105];
+ m_A109 += gt[106];
+ m_A109 += gt[107];
+ m_A109 += gt[108];
+ m_A109 += gt[109];
+ m_A109 += gt[110];
+ m_A110 += go[106];
+ m_A101 += go[107];
+ m_A100 += go[108];
+ double RHS25 = Idr[106];
+ RHS25 += Idr[107];
+ RHS25 += Idr[108];
+ RHS25 += Idr[109];
+ RHS25 += Idr[110];
+ RHS25 -= go[109] * *cnV[109];
+ RHS25 -= go[110] * *cnV[110];
+ m_A115 += gt[111];
+ m_A115 += gt[112];
+ m_A115 += gt[113];
+ m_A115 += gt[114];
+ m_A115 += gt[115];
+ m_A115 += gt[116];
+ m_A115 += gt[117];
+ m_A113 += go[111];
+ m_A112 += go[112];
+ double RHS26 = Idr[111];
+ RHS26 += Idr[112];
+ RHS26 += Idr[113];
+ RHS26 += Idr[114];
+ RHS26 += Idr[115];
+ RHS26 += Idr[116];
+ RHS26 += Idr[117];
+ RHS26 -= go[113] * *cnV[113];
+ RHS26 -= go[114] * *cnV[114];
+ RHS26 -= go[115] * *cnV[115];
+ RHS26 -= go[116] * *cnV[116];
+ RHS26 -= go[117] * *cnV[117];
+ m_A123 += gt[118];
+ m_A123 += gt[119];
+ m_A123 += gt[120];
+ m_A123 += gt[121];
+ m_A118 += go[118];
+ m_A124 += go[119];
+ m_A117 += go[120];
+ m_A120 += go[121];
+ double RHS27 = Idr[118];
+ RHS27 += Idr[119];
+ RHS27 += Idr[120];
+ RHS27 += Idr[121];
+ m_A128 += gt[122];
+ m_A128 += gt[123];
+ m_A128 += gt[124];
+ m_A128 += gt[125];
+ m_A128 += gt[126];
+ m_A127 += go[122];
+ m_A126 += go[123];
+ m_A126 += go[124];
+ m_A125 += go[125];
+ double RHS28 = Idr[122];
+ RHS28 += Idr[123];
+ RHS28 += Idr[124];
+ RHS28 += Idr[125];
+ RHS28 += Idr[126];
+ RHS28 -= go[126] * *cnV[126];
+ const double f0 = 1.0 / m_A0;
+ const double f0_15 = -f0 * m_A43;
+ m_A45 += m_A1 * f0_15;
+ RHS15 += f0_15 * RHS0;
+ const double f1 = 1.0 / m_A2;
+ const double f1_15 = -f1 * m_A44;
+ m_A45 += m_A3 * f1_15;
+ m_A46 += m_A4 * f1_15;
+ RHS15 += f1_15 * RHS1;
+ const double f1_20 = -f1 * m_A74;
+ m_A75 += m_A3 * f1_20;
+ m_A76 += m_A4 * f1_20;
+ RHS20 += f1_20 * RHS1;
+ const double f2 = 1.0 / m_A5;
+ const double f2_24 = -f2 * m_A97;
+ m_A98 += m_A6 * f2_24;
+ m_A99 += m_A7 * f2_24;
+ RHS24 += f2_24 * RHS2;
+ const double f2_28 = -f2 * m_A125;
+ m_A126 += m_A6 * f2_28;
+ m_A128 += m_A7 * f2_28;
+ RHS28 += f2_28 * RHS2;
+ const double f3 = 1.0 / m_A8;
+ const double f3_27 = -f3 * m_A117;
+ m_A123 += m_A9 * f3_27;
+ RHS27 += f3_27 * RHS3;
+ const double f4 = 1.0 / m_A10;
+ const double f4_16 = -f4 * m_A47;
+ m_A49 += m_A11 * f4_16;
+ m_A51 += m_A12 * f4_16;
+ RHS16 += f4_16 * RHS4;
+ const double f4_26 = -f4 * m_A112;
+ m_A113 += m_A11 * f4_26;
+ m_A116 += m_A12 * f4_26;
+ RHS26 += f4_26 * RHS4;
+ const double f4_27 = -f4 * m_A118;
+ m_A119 += m_A11 * f4_27;
+ m_A123 += m_A12 * f4_27;
+ RHS27 += f4_27 * RHS4;
+ const double f5 = 1.0 / m_A13;
+ const double f5_16 = -f5 * m_A48;
+ m_A49 += m_A14 * f5_16;
+ m_A50 += m_A15 * f5_16;
+ RHS16 += f5_16 * RHS5;
+ const double f5_25 = -f5 * m_A100;
+ m_A102 += m_A14 * f5_25;
+ m_A109 += m_A15 * f5_25;
+ RHS25 += f5_25 * RHS5;
+ const double f6 = 1.0 / m_A16;
+ const double f6_17 = -f6 * m_A52;
+ m_A53 += m_A17 * f6_17;
+ m_A56 += m_A18 * f6_17;
+ RHS17 += f6_17 * RHS6;
+ const double f7 = 1.0 / m_A19;
+ const double f7_17 = -f7 * m_A53;
+ m_A55 += m_A20 * f7_17;
+ m_A56 += m_A21 * f7_17;
+ RHS17 += f7_17 * RHS7;
+ const double f8 = 1.0 / m_A22;
+ const double f8_17 = -f8 * m_A54;
+ m_A56 += m_A23 * f8_17;
+ m_A57 += m_A24 * f8_17;
+ RHS17 += f8_17 * RHS8;
+ const double f8_18 = -f8 * m_A60;
+ m_A62 += m_A23 * f8_18;
+ m_A63 += m_A24 * f8_18;
+ RHS18 += f8_18 * RHS8;
+ const double f9 = 1.0 / m_A25;
+ const double f9_17 = -f9 * m_A55;
+ m_A56 += m_A26 * f9_17;
+ m_A58 += m_A27 * f9_17;
+ m_A59 += m_A28 * f9_17;
+ RHS17 += f9_17 * RHS9;
+ const double f9_19 = -f9 * m_A67;
+ m_A69 += m_A26 * f9_19;
+ m_A71 += m_A27 * f9_19;
+ m_A73 += m_A28 * f9_19;
+ RHS19 += f9_19 * RHS9;
+ const double f9_25 = -f9 * m_A101;
+ m_A103 += m_A26 * f9_25;
+ m_A105 += m_A27 * f9_25;
+ m_A109 += m_A28 * f9_25;
+ RHS25 += f9_25 * RHS9;
+ const double f10 = 1.0 / m_A29;
+ const double f10_18 = -f10 * m_A61;
+ m_A63 += m_A30 * f10_18;
+ m_A65 += m_A31 * f10_18;
+ RHS18 += f10_18 * RHS10;
+ const double f10_21 = -f10 * m_A78;
+ m_A81 += m_A30 * f10_21;
+ m_A83 += m_A31 * f10_21;
+ RHS21 += f10_21 * RHS10;
+ const double f11 = 1.0 / m_A32;
+ const double f11_19 = -f11 * m_A68;
+ m_A71 += m_A33 * f11_19;
+ m_A72 += m_A34 * f11_19;
+ RHS19 += f11_19 * RHS11;
+ const double f11_21 = -f11 * m_A79;
+ m_A82 += m_A33 * f11_21;
+ m_A83 += m_A34 * f11_21;
+ RHS21 += f11_21 * RHS11;
+ const double f12 = 1.0 / m_A35;
+ const double f12_21 = -f12 * m_A80;
+ m_A83 += m_A36 * f12_21;
+ m_A84 += m_A37 * f12_21;
+ RHS21 += f12_21 * RHS12;
+ const double f12_22 = -f12 * m_A86;
+ m_A88 += m_A36 * f12_22;
+ m_A89 += m_A37 * f12_22;
+ RHS22 += f12_22 * RHS12;
+ const double f13 = 1.0 / m_A38;
+ const double f13_22 = -f13 * m_A87;
+ m_A89 += m_A39 * f13_22;
+ m_A90 += m_A40 * f13_22;
+ RHS22 += f13_22 * RHS13;
+ const double f13_23 = -f13 * m_A92;
+ m_A94 += m_A39 * f13_23;
+ m_A95 += m_A40 * f13_23;
+ RHS23 += f13_23 * RHS13;
+ const double f14 = 1.0 / m_A41;
+ const double f14_23 = -f14 * m_A93;
+ m_A95 += m_A42 * f14_23;
+ RHS23 += f14_23 * RHS14;
+ const double f15 = 1.0 / m_A45;
+ const double f15_20 = -f15 * m_A75;
+ m_A76 += m_A46 * f15_20;
+ RHS20 += f15_20 * RHS15;
+ const double f16 = 1.0 / m_A49;
+ const double f16_25 = -f16 * m_A102;
+ m_A109 += m_A50 * f16_25;
+ m_A111 += m_A51 * f16_25;
+ RHS25 += f16_25 * RHS16;
+ const double f16_26 = -f16 * m_A113;
+ m_A114 += m_A50 * f16_26;
+ m_A116 += m_A51 * f16_26;
+ RHS26 += f16_26 * RHS16;
+ const double f16_27 = -f16 * m_A119;
+ m_A121 += m_A50 * f16_27;
+ m_A123 += m_A51 * f16_27;
+ RHS27 += f16_27 * RHS16;
+ const double f17 = 1.0 / m_A56;
+ const double f17_18 = -f17 * m_A62;
+ m_A63 += m_A57 * f17_18;
+ m_A64 += m_A58 * f17_18;
+ m_A66 += m_A59 * f17_18;
+ RHS18 += f17_18 * RHS17;
+ const double f17_19 = -f17 * m_A69;
+ m_A70 += m_A57 * f17_19;
+ m_A71 += m_A58 * f17_19;
+ m_A73 += m_A59 * f17_19;
+ RHS19 += f17_19 * RHS17;
+ const double f17_25 = -f17 * m_A103;
+ m_A104 += m_A57 * f17_25;
+ m_A105 += m_A58 * f17_25;
+ m_A109 += m_A59 * f17_25;
+ RHS25 += f17_25 * RHS17;
+ const double f18 = 1.0 / m_A63;
+ const double f18_19 = -f18 * m_A70;
+ m_A71 += m_A64 * f18_19;
+ m_A72 += m_A65 * f18_19;
+ m_A73 += m_A66 * f18_19;
+ RHS19 += f18_19 * RHS18;
+ const double f18_21 = -f18 * m_A81;
+ m_A82 += m_A64 * f18_21;
+ m_A83 += m_A65 * f18_21;
+ m_A85 += m_A66 * f18_21;
+ RHS21 += f18_21 * RHS18;
+ const double f18_25 = -f18 * m_A104;
+ m_A105 += m_A64 * f18_25;
+ m_A106 += m_A65 * f18_25;
+ m_A109 += m_A66 * f18_25;
+ RHS25 += f18_25 * RHS18;
+ const double f19 = 1.0 / m_A71;
+ const double f19_21 = -f19 * m_A82;
+ m_A83 += m_A72 * f19_21;
+ m_A85 += m_A73 * f19_21;
+ RHS21 += f19_21 * RHS19;
+ const double f19_25 = -f19 * m_A105;
+ m_A106 += m_A72 * f19_25;
+ m_A109 += m_A73 * f19_25;
+ RHS25 += f19_25 * RHS19;
+ const double f20 = 1.0 / m_A76;
+ const double f20_27 = -f20 * m_A120;
+ m_A123 += m_A77 * f20_27;
+ RHS27 += f20_27 * RHS20;
+ const double f21 = 1.0 / m_A83;
+ const double f21_22 = -f21 * m_A88;
+ m_A89 += m_A84 * f21_22;
+ m_A91 += m_A85 * f21_22;
+ RHS22 += f21_22 * RHS21;
+ const double f21_25 = -f21 * m_A106;
+ m_A107 += m_A84 * f21_25;
+ m_A109 += m_A85 * f21_25;
+ RHS25 += f21_25 * RHS21;
+ const double f22 = 1.0 / m_A89;
+ const double f22_23 = -f22 * m_A94;
+ m_A95 += m_A90 * f22_23;
+ m_A96 += m_A91 * f22_23;
+ RHS23 += f22_23 * RHS22;
+ const double f22_25 = -f22 * m_A107;
+ m_A108 += m_A90 * f22_25;
+ m_A109 += m_A91 * f22_25;
+ RHS25 += f22_25 * RHS22;
+ const double f23 = 1.0 / m_A95;
+ const double f23_25 = -f23 * m_A108;
+ m_A109 += m_A96 * f23_25;
+ RHS25 += f23_25 * RHS23;
+ const double f24 = 1.0 / m_A98;
+ const double f24_28 = -f24 * m_A126;
+ m_A128 += m_A99 * f24_28;
+ RHS28 += f24_28 * RHS24;
+ const double f25 = 1.0 / m_A109;
+ const double f25_26 = -f25 * m_A114;
+ m_A115 += m_A110 * f25_26;
+ m_A116 += m_A111 * f25_26;
+ RHS26 += f25_26 * RHS25;
+ const double f25_27 = -f25 * m_A121;
+ m_A122 += m_A110 * f25_27;
+ m_A123 += m_A111 * f25_27;
+ RHS27 += f25_27 * RHS25;
+ const double f26 = 1.0 / m_A115;
+ const double f26_27 = -f26 * m_A122;
+ m_A123 += m_A116 * f26_27;
+ RHS27 += f26_27 * RHS26;
+ const double f27 = 1.0 / m_A123;
+ const double f27_28 = -f27 * m_A127;
+ m_A128 += m_A124 * f27_28;
+ RHS28 += f27_28 * RHS27;
+ V[28] = RHS28 / m_A128;
+ double tmp27 = 0.0;
+ tmp27 += m_A124 * V[28];
+ V[27] = (RHS27 - tmp27) / m_A123;
+ double tmp26 = 0.0;
+ tmp26 += m_A116 * V[27];
+ V[26] = (RHS26 - tmp26) / m_A115;
+ double tmp25 = 0.0;
+ tmp25 += m_A110 * V[26];
+ tmp25 += m_A111 * V[27];
+ V[25] = (RHS25 - tmp25) / m_A109;
+ double tmp24 = 0.0;
+ tmp24 += m_A99 * V[28];
+ V[24] = (RHS24 - tmp24) / m_A98;
+ double tmp23 = 0.0;
+ tmp23 += m_A96 * V[25];
+ V[23] = (RHS23 - tmp23) / m_A95;
+ double tmp22 = 0.0;
+ tmp22 += m_A90 * V[23];
+ tmp22 += m_A91 * V[25];
+ V[22] = (RHS22 - tmp22) / m_A89;
+ double tmp21 = 0.0;
+ tmp21 += m_A84 * V[22];
+ tmp21 += m_A85 * V[25];
+ V[21] = (RHS21 - tmp21) / m_A83;
+ double tmp20 = 0.0;
+ tmp20 += m_A77 * V[27];
+ V[20] = (RHS20 - tmp20) / m_A76;
+ double tmp19 = 0.0;
+ tmp19 += m_A72 * V[21];
+ tmp19 += m_A73 * V[25];
+ V[19] = (RHS19 - tmp19) / m_A71;
+ double tmp18 = 0.0;
+ tmp18 += m_A64 * V[19];
+ tmp18 += m_A65 * V[21];
+ tmp18 += m_A66 * V[25];
+ V[18] = (RHS18 - tmp18) / m_A63;
+ double tmp17 = 0.0;
+ tmp17 += m_A57 * V[18];
+ tmp17 += m_A58 * V[19];
+ tmp17 += m_A59 * V[25];
+ V[17] = (RHS17 - tmp17) / m_A56;
+ double tmp16 = 0.0;
+ tmp16 += m_A50 * V[25];
+ tmp16 += m_A51 * V[27];
+ V[16] = (RHS16 - tmp16) / m_A49;
+ double tmp15 = 0.0;
+ tmp15 += m_A46 * V[20];
+ V[15] = (RHS15 - tmp15) / m_A45;
+ double tmp14 = 0.0;
+ tmp14 += m_A42 * V[23];
+ V[14] = (RHS14 - tmp14) / m_A41;
+ double tmp13 = 0.0;
+ tmp13 += m_A39 * V[22];
+ tmp13 += m_A40 * V[23];
+ V[13] = (RHS13 - tmp13) / m_A38;
+ double tmp12 = 0.0;
+ tmp12 += m_A36 * V[21];
+ tmp12 += m_A37 * V[22];
+ V[12] = (RHS12 - tmp12) / m_A35;
+ double tmp11 = 0.0;
+ tmp11 += m_A33 * V[19];
+ tmp11 += m_A34 * V[21];
+ V[11] = (RHS11 - tmp11) / m_A32;
+ double tmp10 = 0.0;
+ tmp10 += m_A30 * V[18];
+ tmp10 += m_A31 * V[21];
+ V[10] = (RHS10 - tmp10) / m_A29;
+ double tmp9 = 0.0;
+ tmp9 += m_A26 * V[17];
+ tmp9 += m_A27 * V[19];
+ tmp9 += m_A28 * V[25];
+ V[9] = (RHS9 - tmp9) / m_A25;
+ double tmp8 = 0.0;
+ tmp8 += m_A23 * V[17];
+ tmp8 += m_A24 * V[18];
+ V[8] = (RHS8 - tmp8) / m_A22;
+ double tmp7 = 0.0;
+ tmp7 += m_A20 * V[9];
+ tmp7 += m_A21 * V[17];
+ V[7] = (RHS7 - tmp7) / m_A19;
+ double tmp6 = 0.0;
+ tmp6 += m_A17 * V[7];
+ tmp6 += m_A18 * V[17];
+ V[6] = (RHS6 - tmp6) / m_A16;
+ double tmp5 = 0.0;
+ tmp5 += m_A14 * V[16];
+ tmp5 += m_A15 * V[25];
+ V[5] = (RHS5 - tmp5) / m_A13;
+ double tmp4 = 0.0;
+ tmp4 += m_A11 * V[16];
+ tmp4 += m_A12 * V[27];
+ V[4] = (RHS4 - tmp4) / m_A10;
+ double tmp3 = 0.0;
+ tmp3 += m_A9 * V[27];
+ V[3] = (RHS3 - tmp3) / m_A8;
+ double tmp2 = 0.0;
+ tmp2 += m_A6 * V[24];
+ tmp2 += m_A7 * V[28];
+ V[2] = (RHS2 - tmp2) / m_A5;
+ double tmp1 = 0.0;
+ tmp1 += m_A3 * V[15];
+ tmp1 += m_A4 * V[20];
+ V[1] = (RHS1 - tmp1) / m_A2;
+ double tmp0 = 0.0;
+ tmp0 += m_A1 * V[15];
+ V[0] = (RHS0 - tmp0) / m_A0;
+}
+
// gamemachine
static void nl_gcr_934712b55bb3b2b2_10_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -22403,6 +23577,727 @@ static void nl_gcr_a1132c8737d5d463_96_double_double(double * __restrict V, cons
V[0] = (RHS0 - tmp0) / m_A0;
}
+// 280zzzap
+static void nl_gcr_a29a3ea050cc0879_113_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
+
+{
+
+ plib::unused_var(cnV);
+ double m_A0(0.0);
+ double m_A1(0.0);
+ double m_A2(0.0);
+ double m_A3(0.0);
+ double m_A4(0.0);
+ double m_A5(0.0);
+ double m_A6(0.0);
+ double m_A7(0.0);
+ double m_A8(0.0);
+ double m_A9(0.0);
+ double m_A10(0.0);
+ double m_A11(0.0);
+ double m_A12(0.0);
+ double m_A13(0.0);
+ double m_A14(0.0);
+ double m_A15(0.0);
+ double m_A16(0.0);
+ double m_A17(0.0);
+ double m_A18(0.0);
+ double m_A19(0.0);
+ double m_A20(0.0);
+ double m_A21(0.0);
+ double m_A22(0.0);
+ double m_A23(0.0);
+ double m_A24(0.0);
+ double m_A25(0.0);
+ double m_A26(0.0);
+ double m_A27(0.0);
+ double m_A28(0.0);
+ double m_A29(0.0);
+ double m_A30(0.0);
+ double m_A31(0.0);
+ double m_A32(0.0);
+ double m_A33(0.0);
+ double m_A34(0.0);
+ double m_A35(0.0);
+ double m_A36(0.0);
+ double m_A37(0.0);
+ double m_A38(0.0);
+ double m_A39(0.0);
+ double m_A40(0.0);
+ double m_A41(0.0);
+ double m_A42(0.0);
+ double m_A43(0.0);
+ double m_A44(0.0);
+ double m_A45(0.0);
+ double m_A46(0.0);
+ double m_A47(0.0);
+ double m_A48(0.0);
+ double m_A49(0.0);
+ double m_A50(0.0);
+ double m_A51(0.0);
+ double m_A52(0.0);
+ double m_A53(0.0);
+ double m_A54(0.0);
+ double m_A55(0.0);
+ double m_A56(0.0);
+ double m_A57(0.0);
+ double m_A58(0.0);
+ double m_A59(0.0);
+ double m_A60(0.0);
+ double m_A61(0.0);
+ double m_A62(0.0);
+ double m_A63(0.0);
+ double m_A64(0.0);
+ double m_A65(0.0);
+ double m_A66(0.0);
+ double m_A67(0.0);
+ double m_A68(0.0);
+ double m_A69(0.0);
+ double m_A70(0.0);
+ double m_A71(0.0);
+ double m_A72(0.0);
+ double m_A73(0.0);
+ double m_A74(0.0);
+ double m_A75(0.0);
+ double m_A76(0.0);
+ double m_A77(0.0);
+ double m_A78(0.0);
+ double m_A79(0.0);
+ double m_A80(0.0);
+ double m_A81(0.0);
+ double m_A82(0.0);
+ double m_A83(0.0);
+ double m_A84(0.0);
+ double m_A85(0.0);
+ double m_A86(0.0);
+ double m_A87(0.0);
+ double m_A88(0.0);
+ double m_A89(0.0);
+ double m_A90(0.0);
+ double m_A91(0.0);
+ double m_A92(0.0);
+ double m_A93(0.0);
+ double m_A94(0.0);
+ double m_A95(0.0);
+ double m_A96(0.0);
+ double m_A97(0.0);
+ double m_A98(0.0);
+ double m_A99(0.0);
+ double m_A100(0.0);
+ double m_A101(0.0);
+ double m_A102(0.0);
+ double m_A103(0.0);
+ double m_A104(0.0);
+ double m_A105(0.0);
+ double m_A106(0.0);
+ double m_A107(0.0);
+ double m_A108(0.0);
+ double m_A109(0.0);
+ double m_A110(0.0);
+ double m_A111(0.0);
+ double m_A112(0.0);
+ m_A0 += gt[0];
+ m_A0 += gt[1];
+ m_A1 += go[0];
+ double RHS0 = Idr[0];
+ RHS0 += Idr[1];
+ RHS0 -= go[1] * *cnV[1];
+ m_A2 += gt[2];
+ m_A2 += gt[3];
+ m_A2 += gt[4];
+ m_A2 += gt[5];
+ m_A5 += go[2];
+ m_A4 += go[3];
+ m_A3 += go[4];
+ double RHS1 = Idr[2];
+ RHS1 += Idr[3];
+ RHS1 += Idr[4];
+ RHS1 += Idr[5];
+ RHS1 -= go[5] * *cnV[5];
+ m_A6 += gt[6];
+ m_A6 += gt[7];
+ m_A7 += go[6];
+ double RHS2 = Idr[6];
+ RHS2 += Idr[7];
+ RHS2 -= go[7] * *cnV[7];
+ m_A8 += gt[8];
+ m_A8 += gt[9];
+ m_A9 += go[8];
+ double RHS3 = Idr[8];
+ RHS3 += Idr[9];
+ RHS3 -= go[9] * *cnV[9];
+ m_A10 += gt[10];
+ m_A10 += gt[11];
+ m_A10 += gt[12];
+ m_A11 += go[10];
+ m_A12 += go[11];
+ double RHS4 = Idr[10];
+ RHS4 += Idr[11];
+ RHS4 += Idr[12];
+ RHS4 -= go[12] * *cnV[12];
+ m_A13 += gt[13];
+ m_A13 += gt[14];
+ m_A14 += go[13];
+ double RHS5 = Idr[13];
+ RHS5 += Idr[14];
+ RHS5 -= go[14] * *cnV[14];
+ m_A15 += gt[15];
+ m_A15 += gt[16];
+ m_A15 += gt[17];
+ m_A15 += gt[18];
+ m_A15 += gt[19];
+ m_A15 += gt[20];
+ m_A15 += gt[21];
+ m_A18 += go[15];
+ m_A19 += go[16];
+ m_A17 += go[17];
+ m_A16 += go[18];
+ double RHS6 = Idr[15];
+ RHS6 += Idr[16];
+ RHS6 += Idr[17];
+ RHS6 += Idr[18];
+ RHS6 += Idr[19];
+ RHS6 += Idr[20];
+ RHS6 += Idr[21];
+ RHS6 -= go[19] * *cnV[19];
+ RHS6 -= go[20] * *cnV[20];
+ RHS6 -= go[21] * *cnV[21];
+ m_A20 += gt[22];
+ m_A20 += gt[23];
+ m_A20 += gt[24];
+ m_A20 += gt[25];
+ m_A20 += gt[26];
+ m_A20 += gt[27];
+ m_A20 += gt[28];
+ m_A23 += go[22];
+ m_A24 += go[23];
+ m_A21 += go[24];
+ m_A22 += go[25];
+ double RHS7 = Idr[22];
+ RHS7 += Idr[23];
+ RHS7 += Idr[24];
+ RHS7 += Idr[25];
+ RHS7 += Idr[26];
+ RHS7 += Idr[27];
+ RHS7 += Idr[28];
+ RHS7 -= go[26] * *cnV[26];
+ RHS7 -= go[27] * *cnV[27];
+ RHS7 -= go[28] * *cnV[28];
+ m_A25 += gt[29];
+ m_A25 += gt[30];
+ m_A25 += gt[31];
+ m_A26 += go[29];
+ m_A27 += go[30];
+ double RHS8 = Idr[29];
+ RHS8 += Idr[30];
+ RHS8 += Idr[31];
+ RHS8 -= go[31] * *cnV[31];
+ m_A28 += gt[32];
+ m_A28 += gt[33];
+ m_A29 += go[32];
+ double RHS9 = Idr[32];
+ RHS9 += Idr[33];
+ RHS9 -= go[33] * *cnV[33];
+ m_A30 += gt[34];
+ m_A30 += gt[35];
+ m_A30 += gt[36];
+ m_A30 += gt[37];
+ m_A31 += go[34];
+ double RHS10 = Idr[34];
+ RHS10 += Idr[35];
+ RHS10 += Idr[36];
+ RHS10 += Idr[37];
+ RHS10 -= go[35] * *cnV[35];
+ RHS10 -= go[36] * *cnV[36];
+ RHS10 -= go[37] * *cnV[37];
+ m_A32 += gt[38];
+ m_A32 += gt[39];
+ m_A33 += go[38];
+ double RHS11 = Idr[38];
+ RHS11 += Idr[39];
+ RHS11 -= go[39] * *cnV[39];
+ m_A36 += gt[40];
+ m_A36 += gt[41];
+ m_A36 += gt[42];
+ m_A36 += gt[43];
+ m_A35 += go[40];
+ m_A34 += go[41];
+ double RHS12 = Idr[40];
+ RHS12 += Idr[41];
+ RHS12 += Idr[42];
+ RHS12 += Idr[43];
+ RHS12 -= go[42] * *cnV[42];
+ RHS12 -= go[43] * *cnV[43];
+ m_A40 += gt[44];
+ m_A40 += gt[45];
+ m_A40 += gt[46];
+ m_A39 += go[44];
+ m_A41 += go[45];
+ double RHS13 = Idr[44];
+ RHS13 += Idr[45];
+ RHS13 += Idr[46];
+ RHS13 -= go[46] * *cnV[46];
+ m_A45 += gt[47];
+ m_A45 += gt[48];
+ m_A45 += gt[49];
+ m_A45 += gt[50];
+ m_A43 += go[47];
+ m_A42 += go[48];
+ double RHS14 = Idr[47];
+ RHS14 += Idr[48];
+ RHS14 += Idr[49];
+ RHS14 += Idr[50];
+ RHS14 -= go[49] * *cnV[49];
+ RHS14 -= go[50] * *cnV[50];
+ m_A51 += gt[51];
+ m_A51 += gt[52];
+ m_A51 += gt[53];
+ m_A51 += gt[54];
+ m_A50 += go[51];
+ m_A52 += go[52];
+ double RHS15 = Idr[51];
+ RHS15 += Idr[52];
+ RHS15 += Idr[53];
+ RHS15 += Idr[54];
+ RHS15 -= go[53] * *cnV[53];
+ RHS15 -= go[54] * *cnV[54];
+ m_A57 += gt[55];
+ m_A57 += gt[56];
+ m_A57 += gt[57];
+ m_A57 += gt[58];
+ m_A57 += gt[59];
+ m_A57 += gt[60];
+ m_A60 += go[55];
+ m_A55 += go[56];
+ m_A54 += go[57];
+ m_A53 += go[58];
+ m_A59 += go[59];
+ double RHS16 = Idr[55];
+ RHS16 += Idr[56];
+ RHS16 += Idr[57];
+ RHS16 += Idr[58];
+ RHS16 += Idr[59];
+ RHS16 += Idr[60];
+ RHS16 -= go[60] * *cnV[60];
+ m_A64 += gt[61];
+ m_A64 += gt[62];
+ m_A64 += gt[63];
+ m_A64 += gt[64];
+ m_A63 += go[61];
+ m_A62 += go[62];
+ m_A65 += go[63];
+ double RHS17 = Idr[61];
+ RHS17 += Idr[62];
+ RHS17 += Idr[63];
+ RHS17 += Idr[64];
+ RHS17 -= go[64] * *cnV[64];
+ m_A71 += gt[65];
+ m_A71 += gt[66];
+ m_A71 += gt[67];
+ m_A71 += gt[68];
+ m_A74 += go[65];
+ m_A67 += go[66];
+ m_A66 += go[67];
+ double RHS18 = Idr[65];
+ RHS18 += Idr[66];
+ RHS18 += Idr[67];
+ RHS18 += Idr[68];
+ RHS18 -= go[68] * *cnV[68];
+ m_A81 += gt[69];
+ m_A81 += gt[70];
+ m_A81 += gt[71];
+ m_A81 += gt[72];
+ m_A76 += go[69];
+ m_A77 += go[70];
+ m_A79 += go[71];
+ m_A78 += go[72];
+ double RHS19 = Idr[69];
+ RHS19 += Idr[70];
+ RHS19 += Idr[71];
+ RHS19 += Idr[72];
+ m_A92 += gt[73];
+ m_A92 += gt[74];
+ m_A92 += gt[75];
+ m_A92 += gt[76];
+ m_A92 += gt[77];
+ m_A92 += gt[78];
+ m_A92 += gt[79];
+ m_A88 += go[73];
+ m_A86 += go[74];
+ m_A94 += go[75];
+ m_A85 += go[76];
+ m_A89 += go[77];
+ double RHS20 = Idr[73];
+ RHS20 += Idr[74];
+ RHS20 += Idr[75];
+ RHS20 += Idr[76];
+ RHS20 += Idr[77];
+ RHS20 += Idr[78];
+ RHS20 += Idr[79];
+ RHS20 -= go[78] * *cnV[78];
+ RHS20 -= go[79] * *cnV[79];
+ m_A100 += gt[80];
+ m_A100 += gt[81];
+ m_A100 += gt[82];
+ m_A100 += gt[83];
+ m_A100 += gt[84];
+ m_A96 += go[80];
+ m_A95 += go[81];
+ m_A97 += go[82];
+ double RHS21 = Idr[80];
+ RHS21 += Idr[81];
+ RHS21 += Idr[82];
+ RHS21 += Idr[83];
+ RHS21 += Idr[84];
+ RHS21 -= go[83] * *cnV[83];
+ RHS21 -= go[84] * *cnV[84];
+ m_A112 += gt[85];
+ m_A112 += gt[86];
+ m_A112 += gt[87];
+ m_A112 += gt[88];
+ m_A112 += gt[89];
+ m_A112 += gt[90];
+ m_A107 += go[85];
+ m_A110 += go[86];
+ m_A103 += go[87];
+ m_A104 += go[88];
+ m_A102 += go[89];
+ double RHS22 = Idr[85];
+ RHS22 += Idr[86];
+ RHS22 += Idr[87];
+ RHS22 += Idr[88];
+ RHS22 += Idr[89];
+ RHS22 += Idr[90];
+ RHS22 -= go[90] * *cnV[90];
+ const double f0 = 1.0 / m_A0;
+ const double f0_12 = -f0 * m_A34;
+ m_A36 += m_A1 * f0_12;
+ RHS12 += f0_12 * RHS0;
+ const double f1 = 1.0 / m_A2;
+ const double f1_12 = -f1 * m_A35;
+ m_A36 += m_A3 * f1_12;
+ m_A37 += m_A4 * f1_12;
+ m_A38 += m_A5 * f1_12;
+ RHS12 += f1_12 * RHS1;
+ const double f1_14 = -f1 * m_A42;
+ m_A44 += m_A3 * f1_14;
+ m_A45 += m_A4 * f1_14;
+ m_A47 += m_A5 * f1_14;
+ RHS14 += f1_14 * RHS1;
+ const double f1_18 = -f1 * m_A66;
+ m_A68 += m_A3 * f1_18;
+ m_A69 += m_A4 * f1_18;
+ m_A71 += m_A5 * f1_18;
+ RHS18 += f1_18 * RHS1;
+ const double f2 = 1.0 / m_A6;
+ const double f2_13 = -f2 * m_A39;
+ m_A40 += m_A7 * f2_13;
+ RHS13 += f2_13 * RHS2;
+ const double f3 = 1.0 / m_A8;
+ const double f3_19 = -f3 * m_A76;
+ m_A81 += m_A9 * f3_19;
+ RHS19 += f3_19 * RHS3;
+ const double f4 = 1.0 / m_A10;
+ const double f4_16 = -f4 * m_A53;
+ m_A57 += m_A11 * f4_16;
+ m_A59 += m_A12 * f4_16;
+ RHS16 += f4_16 * RHS4;
+ const double f4_19 = -f4 * m_A77;
+ m_A79 += m_A11 * f4_19;
+ m_A81 += m_A12 * f4_19;
+ RHS19 += f4_19 * RHS4;
+ const double f5 = 1.0 / m_A13;
+ const double f5_15 = -f5 * m_A50;
+ m_A51 += m_A14 * f5_15;
+ RHS15 += f5_15 * RHS5;
+ const double f6 = 1.0 / m_A15;
+ const double f6_14 = -f6 * m_A43;
+ m_A45 += m_A16 * f6_14;
+ m_A46 += m_A17 * f6_14;
+ m_A48 += m_A18 * f6_14;
+ m_A49 += m_A19 * f6_14;
+ RHS14 += f6_14 * RHS6;
+ const double f6_16 = -f6 * m_A54;
+ m_A56 += m_A16 * f6_16;
+ m_A57 += m_A17 * f6_16;
+ m_A60 += m_A18 * f6_16;
+ m_A61 += m_A19 * f6_16;
+ RHS16 += f6_16 * RHS6;
+ const double f6_20 = -f6 * m_A85;
+ m_A87 += m_A16 * f6_20;
+ m_A89 += m_A17 * f6_20;
+ m_A92 += m_A18 * f6_20;
+ m_A94 += m_A19 * f6_20;
+ RHS20 += f6_20 * RHS6;
+ const double f6_22 = -f6 * m_A102;
+ m_A105 += m_A16 * f6_22;
+ m_A106 += m_A17 * f6_22;
+ m_A110 += m_A18 * f6_22;
+ m_A112 += m_A19 * f6_22;
+ RHS22 += f6_22 * RHS6;
+ const double f7 = 1.0 / m_A20;
+ const double f7_16 = -f7 * m_A55;
+ m_A57 += m_A21 * f7_16;
+ m_A58 += m_A22 * f7_16;
+ m_A60 += m_A23 * f7_16;
+ m_A61 += m_A24 * f7_16;
+ RHS16 += f7_16 * RHS7;
+ const double f7_18 = -f7 * m_A67;
+ m_A70 += m_A21 * f7_18;
+ m_A71 += m_A22 * f7_18;
+ m_A73 += m_A23 * f7_18;
+ m_A75 += m_A24 * f7_18;
+ RHS18 += f7_18 * RHS7;
+ const double f7_20 = -f7 * m_A86;
+ m_A89 += m_A21 * f7_20;
+ m_A90 += m_A22 * f7_20;
+ m_A92 += m_A23 * f7_20;
+ m_A94 += m_A24 * f7_20;
+ RHS20 += f7_20 * RHS7;
+ const double f7_22 = -f7 * m_A103;
+ m_A106 += m_A21 * f7_22;
+ m_A108 += m_A22 * f7_22;
+ m_A110 += m_A23 * f7_22;
+ m_A112 += m_A24 * f7_22;
+ RHS22 += f7_22 * RHS7;
+ const double f8 = 1.0 / m_A25;
+ const double f8_17 = -f8 * m_A62;
+ m_A64 += m_A26 * f8_17;
+ m_A65 += m_A27 * f8_17;
+ RHS17 += f8_17 * RHS8;
+ const double f8_22 = -f8 * m_A104;
+ m_A107 += m_A26 * f8_22;
+ m_A112 += m_A27 * f8_22;
+ RHS22 += f8_22 * RHS8;
+ const double f9 = 1.0 / m_A28;
+ const double f9_17 = -f9 * m_A63;
+ m_A64 += m_A29 * f9_17;
+ RHS17 += f9_17 * RHS9;
+ const double f10 = 1.0 / m_A30;
+ const double f10_21 = -f10 * m_A95;
+ m_A100 += m_A31 * f10_21;
+ RHS21 += f10_21 * RHS10;
+ const double f11 = 1.0 / m_A32;
+ const double f11_21 = -f11 * m_A96;
+ m_A100 += m_A33 * f11_21;
+ RHS21 += f11_21 * RHS11;
+ const double f12 = 1.0 / m_A36;
+ const double f12_14 = -f12 * m_A44;
+ m_A45 += m_A37 * f12_14;
+ m_A47 += m_A38 * f12_14;
+ RHS14 += f12_14 * RHS12;
+ const double f12_18 = -f12 * m_A68;
+ m_A69 += m_A37 * f12_18;
+ m_A71 += m_A38 * f12_18;
+ RHS18 += f12_18 * RHS12;
+ const double f13 = 1.0 / m_A40;
+ const double f13_19 = -f13 * m_A78;
+ m_A81 += m_A41 * f13_19;
+ RHS19 += f13_19 * RHS13;
+ const double f14 = 1.0 / m_A45;
+ const double f14_16 = -f14 * m_A56;
+ m_A57 += m_A46 * f14_16;
+ m_A58 += m_A47 * f14_16;
+ m_A60 += m_A48 * f14_16;
+ m_A61 += m_A49 * f14_16;
+ RHS16 += f14_16 * RHS14;
+ const double f14_18 = -f14 * m_A69;
+ m_A70 += m_A46 * f14_18;
+ m_A71 += m_A47 * f14_18;
+ m_A73 += m_A48 * f14_18;
+ m_A75 += m_A49 * f14_18;
+ RHS18 += f14_18 * RHS14;
+ const double f14_20 = -f14 * m_A87;
+ m_A89 += m_A46 * f14_20;
+ m_A90 += m_A47 * f14_20;
+ m_A92 += m_A48 * f14_20;
+ m_A94 += m_A49 * f14_20;
+ RHS20 += f14_20 * RHS14;
+ const double f14_22 = -f14 * m_A105;
+ m_A106 += m_A46 * f14_22;
+ m_A108 += m_A47 * f14_22;
+ m_A110 += m_A48 * f14_22;
+ m_A112 += m_A49 * f14_22;
+ RHS22 += f14_22 * RHS14;
+ const double f15 = 1.0 / m_A51;
+ const double f15_20 = -f15 * m_A88;
+ m_A92 += m_A52 * f15_20;
+ RHS20 += f15_20 * RHS15;
+ const double f16 = 1.0 / m_A57;
+ const double f16_18 = -f16 * m_A70;
+ m_A71 += m_A58 * f16_18;
+ m_A72 += m_A59 * f16_18;
+ m_A73 += m_A60 * f16_18;
+ m_A75 += m_A61 * f16_18;
+ RHS18 += f16_18 * RHS16;
+ const double f16_19 = -f16 * m_A79;
+ m_A80 += m_A58 * f16_19;
+ m_A81 += m_A59 * f16_19;
+ m_A82 += m_A60 * f16_19;
+ m_A84 += m_A61 * f16_19;
+ RHS19 += f16_19 * RHS16;
+ const double f16_20 = -f16 * m_A89;
+ m_A90 += m_A58 * f16_20;
+ m_A91 += m_A59 * f16_20;
+ m_A92 += m_A60 * f16_20;
+ m_A94 += m_A61 * f16_20;
+ RHS20 += f16_20 * RHS16;
+ const double f16_22 = -f16 * m_A106;
+ m_A108 += m_A58 * f16_22;
+ m_A109 += m_A59 * f16_22;
+ m_A110 += m_A60 * f16_22;
+ m_A112 += m_A61 * f16_22;
+ RHS22 += f16_22 * RHS16;
+ const double f17 = 1.0 / m_A64;
+ const double f17_22 = -f17 * m_A107;
+ m_A112 += m_A65 * f17_22;
+ RHS22 += f17_22 * RHS17;
+ const double f18 = 1.0 / m_A71;
+ const double f18_19 = -f18 * m_A80;
+ m_A81 += m_A72 * f18_19;
+ m_A82 += m_A73 * f18_19;
+ m_A83 += m_A74 * f18_19;
+ m_A84 += m_A75 * f18_19;
+ RHS19 += f18_19 * RHS18;
+ const double f18_20 = -f18 * m_A90;
+ m_A91 += m_A72 * f18_20;
+ m_A92 += m_A73 * f18_20;
+ m_A93 += m_A74 * f18_20;
+ m_A94 += m_A75 * f18_20;
+ RHS20 += f18_20 * RHS18;
+ const double f18_21 = -f18 * m_A97;
+ m_A98 += m_A72 * f18_21;
+ m_A99 += m_A73 * f18_21;
+ m_A100 += m_A74 * f18_21;
+ m_A101 += m_A75 * f18_21;
+ RHS21 += f18_21 * RHS18;
+ const double f18_22 = -f18 * m_A108;
+ m_A109 += m_A72 * f18_22;
+ m_A110 += m_A73 * f18_22;
+ m_A111 += m_A74 * f18_22;
+ m_A112 += m_A75 * f18_22;
+ RHS22 += f18_22 * RHS18;
+ const double f19 = 1.0 / m_A81;
+ const double f19_20 = -f19 * m_A91;
+ m_A92 += m_A82 * f19_20;
+ m_A93 += m_A83 * f19_20;
+ m_A94 += m_A84 * f19_20;
+ RHS20 += f19_20 * RHS19;
+ const double f19_21 = -f19 * m_A98;
+ m_A99 += m_A82 * f19_21;
+ m_A100 += m_A83 * f19_21;
+ m_A101 += m_A84 * f19_21;
+ RHS21 += f19_21 * RHS19;
+ const double f19_22 = -f19 * m_A109;
+ m_A110 += m_A82 * f19_22;
+ m_A111 += m_A83 * f19_22;
+ m_A112 += m_A84 * f19_22;
+ RHS22 += f19_22 * RHS19;
+ const double f20 = 1.0 / m_A92;
+ const double f20_21 = -f20 * m_A99;
+ m_A100 += m_A93 * f20_21;
+ m_A101 += m_A94 * f20_21;
+ RHS21 += f20_21 * RHS20;
+ const double f20_22 = -f20 * m_A110;
+ m_A111 += m_A93 * f20_22;
+ m_A112 += m_A94 * f20_22;
+ RHS22 += f20_22 * RHS20;
+ const double f21 = 1.0 / m_A100;
+ const double f21_22 = -f21 * m_A111;
+ m_A112 += m_A101 * f21_22;
+ RHS22 += f21_22 * RHS21;
+ V[22] = RHS22 / m_A112;
+ double tmp21 = 0.0;
+ tmp21 += m_A101 * V[22];
+ V[21] = (RHS21 - tmp21) / m_A100;
+ double tmp20 = 0.0;
+ tmp20 += m_A93 * V[21];
+ tmp20 += m_A94 * V[22];
+ V[20] = (RHS20 - tmp20) / m_A92;
+ double tmp19 = 0.0;
+ tmp19 += m_A82 * V[20];
+ tmp19 += m_A83 * V[21];
+ tmp19 += m_A84 * V[22];
+ V[19] = (RHS19 - tmp19) / m_A81;
+ double tmp18 = 0.0;
+ tmp18 += m_A72 * V[19];
+ tmp18 += m_A73 * V[20];
+ tmp18 += m_A74 * V[21];
+ tmp18 += m_A75 * V[22];
+ V[18] = (RHS18 - tmp18) / m_A71;
+ double tmp17 = 0.0;
+ tmp17 += m_A65 * V[22];
+ V[17] = (RHS17 - tmp17) / m_A64;
+ double tmp16 = 0.0;
+ tmp16 += m_A58 * V[18];
+ tmp16 += m_A59 * V[19];
+ tmp16 += m_A60 * V[20];
+ tmp16 += m_A61 * V[22];
+ V[16] = (RHS16 - tmp16) / m_A57;
+ double tmp15 = 0.0;
+ tmp15 += m_A52 * V[20];
+ V[15] = (RHS15 - tmp15) / m_A51;
+ double tmp14 = 0.0;
+ tmp14 += m_A46 * V[16];
+ tmp14 += m_A47 * V[18];
+ tmp14 += m_A48 * V[20];
+ tmp14 += m_A49 * V[22];
+ V[14] = (RHS14 - tmp14) / m_A45;
+ double tmp13 = 0.0;
+ tmp13 += m_A41 * V[19];
+ V[13] = (RHS13 - tmp13) / m_A40;
+ double tmp12 = 0.0;
+ tmp12 += m_A37 * V[14];
+ tmp12 += m_A38 * V[18];
+ V[12] = (RHS12 - tmp12) / m_A36;
+ double tmp11 = 0.0;
+ tmp11 += m_A33 * V[21];
+ V[11] = (RHS11 - tmp11) / m_A32;
+ double tmp10 = 0.0;
+ tmp10 += m_A31 * V[21];
+ V[10] = (RHS10 - tmp10) / m_A30;
+ double tmp9 = 0.0;
+ tmp9 += m_A29 * V[17];
+ V[9] = (RHS9 - tmp9) / m_A28;
+ double tmp8 = 0.0;
+ tmp8 += m_A26 * V[17];
+ tmp8 += m_A27 * V[22];
+ V[8] = (RHS8 - tmp8) / m_A25;
+ double tmp7 = 0.0;
+ tmp7 += m_A21 * V[16];
+ tmp7 += m_A22 * V[18];
+ tmp7 += m_A23 * V[20];
+ tmp7 += m_A24 * V[22];
+ V[7] = (RHS7 - tmp7) / m_A20;
+ double tmp6 = 0.0;
+ tmp6 += m_A16 * V[14];
+ tmp6 += m_A17 * V[16];
+ tmp6 += m_A18 * V[20];
+ tmp6 += m_A19 * V[22];
+ V[6] = (RHS6 - tmp6) / m_A15;
+ double tmp5 = 0.0;
+ tmp5 += m_A14 * V[15];
+ V[5] = (RHS5 - tmp5) / m_A13;
+ double tmp4 = 0.0;
+ tmp4 += m_A11 * V[16];
+ tmp4 += m_A12 * V[19];
+ V[4] = (RHS4 - tmp4) / m_A10;
+ double tmp3 = 0.0;
+ tmp3 += m_A9 * V[19];
+ V[3] = (RHS3 - tmp3) / m_A8;
+ double tmp2 = 0.0;
+ tmp2 += m_A7 * V[13];
+ V[2] = (RHS2 - tmp2) / m_A6;
+ double tmp1 = 0.0;
+ tmp1 += m_A3 * V[12];
+ tmp1 += m_A4 * V[14];
+ tmp1 += m_A5 * V[18];
+ V[1] = (RHS1 - tmp1) / m_A2;
+ double tmp0 = 0.0;
+ tmp0 += m_A1 * V[12];
+ V[0] = (RHS0 - tmp0) / m_A0;
+}
+
// rebound
static void nl_gcr_a41a44bd5c424f88_13_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -27427,6 +29322,229 @@ static void nl_gcr_bff07f8d339f7cc4_89_double_double(double * __restrict V, cons
V[0] = (RHS0 - tmp0) / m_A0;
}
+// starcrus
+static void nl_gcr_c2e616f3de30f15b_31_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
+
+{
+
+ plib::unused_var(cnV);
+ double m_A0(0.0);
+ double m_A1(0.0);
+ double m_A2(0.0);
+ double m_A3(0.0);
+ double m_A4(0.0);
+ double m_A5(0.0);
+ double m_A6(0.0);
+ double m_A7(0.0);
+ double m_A8(0.0);
+ double m_A9(0.0);
+ double m_A10(0.0);
+ double m_A11(0.0);
+ double m_A12(0.0);
+ double m_A13(0.0);
+ double m_A14(0.0);
+ double m_A15(0.0);
+ double m_A16(0.0);
+ double m_A17(0.0);
+ double m_A18(0.0);
+ double m_A19(0.0);
+ double m_A20(0.0);
+ double m_A21(0.0);
+ double m_A22(0.0);
+ double m_A23(0.0);
+ double m_A24(0.0);
+ double m_A25(0.0);
+ double m_A26(0.0);
+ double m_A27(0.0);
+ double m_A28(0.0);
+ double m_A29(0.0);
+ double m_A30(0.0);
+ m_A0 += gt[0];
+ m_A0 += gt[1];
+ m_A0 += gt[2];
+ m_A1 += go[0];
+ double RHS0 = Idr[0];
+ RHS0 += Idr[1];
+ RHS0 += Idr[2];
+ RHS0 -= go[1] * *cnV[1];
+ RHS0 -= go[2] * *cnV[2];
+ m_A2 += gt[3];
+ m_A2 += gt[4];
+ m_A3 += go[3];
+ double RHS1 = Idr[3];
+ RHS1 += Idr[4];
+ RHS1 -= go[4] * *cnV[4];
+ m_A4 += gt[5];
+ m_A4 += gt[6];
+ m_A5 += go[5];
+ double RHS2 = Idr[5];
+ RHS2 += Idr[6];
+ RHS2 -= go[6] * *cnV[6];
+ m_A6 += gt[7];
+ m_A6 += gt[8];
+ m_A7 += go[7];
+ double RHS3 = Idr[7];
+ RHS3 += Idr[8];
+ RHS3 -= go[8] * *cnV[8];
+ m_A8 += gt[9];
+ m_A8 += gt[10];
+ m_A9 += go[9];
+ double RHS4 = Idr[9];
+ RHS4 += Idr[10];
+ RHS4 -= go[10] * *cnV[10];
+ m_A10 += gt[11];
+ m_A10 += gt[12];
+ m_A10 += gt[13];
+ m_A10 += gt[14];
+ m_A12 += go[11];
+ m_A10 += go[12];
+ m_A10 += go[13];
+ m_A11 += go[14];
+ double RHS5 = Idr[11];
+ RHS5 += Idr[12];
+ RHS5 += Idr[13];
+ RHS5 += Idr[14];
+ m_A14 += gt[15];
+ m_A14 += gt[16];
+ m_A14 += gt[17];
+ m_A14 += gt[18];
+ m_A14 += gt[19];
+ m_A14 += gt[20];
+ m_A14 += gt[21];
+ m_A13 += go[15];
+ m_A15 += go[16];
+ double RHS6 = Idr[15];
+ RHS6 += Idr[16];
+ RHS6 += Idr[17];
+ RHS6 += Idr[18];
+ RHS6 += Idr[19];
+ RHS6 += Idr[20];
+ RHS6 += Idr[21];
+ RHS6 -= go[17] * *cnV[17];
+ RHS6 -= go[18] * *cnV[18];
+ RHS6 -= go[19] * *cnV[19];
+ RHS6 -= go[20] * *cnV[20];
+ RHS6 -= go[21] * *cnV[21];
+ m_A16 += gt[22];
+ m_A16 += gt[23];
+ m_A17 += go[22];
+ double RHS7 = Idr[22];
+ RHS7 += Idr[23];
+ RHS7 -= go[23] * *cnV[23];
+ m_A24 += gt[24];
+ m_A24 += gt[25];
+ m_A24 += gt[26];
+ m_A24 += gt[27];
+ m_A24 += gt[28];
+ m_A24 += gt[29];
+ m_A24 += gt[30];
+ m_A22 += go[24];
+ m_A21 += go[25];
+ m_A20 += go[26];
+ m_A19 += go[27];
+ m_A18 += go[28];
+ m_A25 += go[29];
+ m_A23 += go[30];
+ double RHS8 = Idr[24];
+ RHS8 += Idr[25];
+ RHS8 += Idr[26];
+ RHS8 += Idr[27];
+ RHS8 += Idr[28];
+ RHS8 += Idr[29];
+ RHS8 += Idr[30];
+ m_A30 += gt[31];
+ m_A30 += gt[32];
+ m_A30 += gt[33];
+ m_A30 += gt[34];
+ m_A30 += gt[35];
+ m_A30 += gt[36];
+ m_A27 += go[31];
+ m_A28 += go[32];
+ m_A26 += go[33];
+ m_A29 += go[34];
+ double RHS9 = Idr[31];
+ RHS9 += Idr[32];
+ RHS9 += Idr[33];
+ RHS9 += Idr[34];
+ RHS9 += Idr[35];
+ RHS9 += Idr[36];
+ RHS9 -= go[35] * *cnV[35];
+ RHS9 -= go[36] * *cnV[36];
+ const double f0 = 1.0 / m_A0;
+ const double f0_6 = -f0 * m_A13;
+ m_A15 += m_A1 * f0_6;
+ RHS6 += f0_6 * RHS0;
+ const double f0_8 = -f0 * m_A18;
+ m_A24 += m_A1 * f0_8;
+ RHS8 += f0_8 * RHS0;
+ const double f1 = 1.0 / m_A2;
+ const double f1_8 = -f1 * m_A19;
+ m_A24 += m_A3 * f1_8;
+ RHS8 += f1_8 * RHS1;
+ const double f2 = 1.0 / m_A4;
+ const double f2_8 = -f2 * m_A20;
+ m_A24 += m_A5 * f2_8;
+ RHS8 += f2_8 * RHS2;
+ const double f3 = 1.0 / m_A6;
+ const double f3_8 = -f3 * m_A21;
+ m_A24 += m_A7 * f3_8;
+ RHS8 += f3_8 * RHS3;
+ const double f4 = 1.0 / m_A8;
+ const double f4_8 = -f4 * m_A22;
+ m_A24 += m_A9 * f4_8;
+ RHS8 += f4_8 * RHS4;
+ const double f5 = 1.0 / m_A10;
+ const double f5_8 = -f5 * m_A23;
+ m_A24 += m_A11 * f5_8;
+ m_A25 += m_A12 * f5_8;
+ RHS8 += f5_8 * RHS5;
+ const double f5_9 = -f5 * m_A26;
+ m_A29 += m_A11 * f5_9;
+ m_A30 += m_A12 * f5_9;
+ RHS9 += f5_9 * RHS5;
+ const double f6 = 1.0 / m_A14;
+ const double f6_9 = -f6 * m_A27;
+ m_A29 += m_A15 * f6_9;
+ RHS9 += f6_9 * RHS6;
+ const double f7 = 1.0 / m_A16;
+ const double f7_9 = -f7 * m_A28;
+ m_A30 += m_A17 * f7_9;
+ RHS9 += f7_9 * RHS7;
+ const double f8 = 1.0 / m_A24;
+ const double f8_9 = -f8 * m_A29;
+ m_A30 += m_A25 * f8_9;
+ RHS9 += f8_9 * RHS8;
+ V[9] = RHS9 / m_A30;
+ double tmp8 = 0.0;
+ tmp8 += m_A25 * V[9];
+ V[8] = (RHS8 - tmp8) / m_A24;
+ double tmp7 = 0.0;
+ tmp7 += m_A17 * V[9];
+ V[7] = (RHS7 - tmp7) / m_A16;
+ double tmp6 = 0.0;
+ tmp6 += m_A15 * V[8];
+ V[6] = (RHS6 - tmp6) / m_A14;
+ double tmp5 = 0.0;
+ tmp5 += m_A11 * V[8];
+ tmp5 += m_A12 * V[9];
+ V[5] = (RHS5 - tmp5) / m_A10;
+ double tmp4 = 0.0;
+ tmp4 += m_A9 * V[8];
+ V[4] = (RHS4 - tmp4) / m_A8;
+ double tmp3 = 0.0;
+ tmp3 += m_A7 * V[8];
+ V[3] = (RHS3 - tmp3) / m_A6;
+ double tmp2 = 0.0;
+ tmp2 += m_A5 * V[8];
+ V[2] = (RHS2 - tmp2) / m_A4;
+ double tmp1 = 0.0;
+ tmp1 += m_A3 * V[8];
+ V[1] = (RHS1 - tmp1) / m_A2;
+ double tmp0 = 0.0;
+ tmp0 += m_A1 * V[8];
+ V[0] = (RHS0 - tmp0) / m_A0;
+}
+
// tailg
static void nl_gcr_c4cec7aed23b7b94_23_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -34883,6 +37001,612 @@ static void nl_gcr_ee2cacaa15d32491_67_double_double(double * __restrict V, cons
V[0] = (RHS0 - tmp0) / m_A0;
}
+// starcrus
+static void nl_gcr_ef2f49641f433a74_94_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
+
+{
+
+ plib::unused_var(cnV);
+ double m_A0(0.0);
+ double m_A1(0.0);
+ double m_A2(0.0);
+ double m_A3(0.0);
+ double m_A4(0.0);
+ double m_A5(0.0);
+ double m_A6(0.0);
+ double m_A7(0.0);
+ double m_A8(0.0);
+ double m_A9(0.0);
+ double m_A10(0.0);
+ double m_A11(0.0);
+ double m_A12(0.0);
+ double m_A13(0.0);
+ double m_A14(0.0);
+ double m_A15(0.0);
+ double m_A16(0.0);
+ double m_A17(0.0);
+ double m_A18(0.0);
+ double m_A19(0.0);
+ double m_A20(0.0);
+ double m_A21(0.0);
+ double m_A22(0.0);
+ double m_A23(0.0);
+ double m_A24(0.0);
+ double m_A25(0.0);
+ double m_A26(0.0);
+ double m_A27(0.0);
+ double m_A28(0.0);
+ double m_A29(0.0);
+ double m_A30(0.0);
+ double m_A31(0.0);
+ double m_A32(0.0);
+ double m_A33(0.0);
+ double m_A34(0.0);
+ double m_A35(0.0);
+ double m_A36(0.0);
+ double m_A37(0.0);
+ double m_A38(0.0);
+ double m_A39(0.0);
+ double m_A40(0.0);
+ double m_A41(0.0);
+ double m_A42(0.0);
+ double m_A43(0.0);
+ double m_A44(0.0);
+ double m_A45(0.0);
+ double m_A46(0.0);
+ double m_A47(0.0);
+ double m_A48(0.0);
+ double m_A49(0.0);
+ double m_A50(0.0);
+ double m_A51(0.0);
+ double m_A52(0.0);
+ double m_A53(0.0);
+ double m_A54(0.0);
+ double m_A55(0.0);
+ double m_A56(0.0);
+ double m_A57(0.0);
+ double m_A58(0.0);
+ double m_A59(0.0);
+ double m_A60(0.0);
+ double m_A61(0.0);
+ double m_A62(0.0);
+ double m_A63(0.0);
+ double m_A64(0.0);
+ double m_A65(0.0);
+ double m_A66(0.0);
+ double m_A67(0.0);
+ double m_A68(0.0);
+ double m_A69(0.0);
+ double m_A70(0.0);
+ double m_A71(0.0);
+ double m_A72(0.0);
+ double m_A73(0.0);
+ double m_A74(0.0);
+ double m_A75(0.0);
+ double m_A76(0.0);
+ double m_A77(0.0);
+ double m_A78(0.0);
+ double m_A79(0.0);
+ double m_A80(0.0);
+ double m_A81(0.0);
+ double m_A82(0.0);
+ double m_A83(0.0);
+ double m_A84(0.0);
+ double m_A85(0.0);
+ double m_A86(0.0);
+ double m_A87(0.0);
+ double m_A88(0.0);
+ double m_A89(0.0);
+ double m_A90(0.0);
+ double m_A91(0.0);
+ double m_A92(0.0);
+ double m_A93(0.0);
+ m_A0 += gt[0];
+ m_A0 += gt[1];
+ m_A1 += go[0];
+ double RHS0 = Idr[0];
+ RHS0 += Idr[1];
+ RHS0 -= go[1] * *cnV[1];
+ m_A2 += gt[2];
+ m_A2 += gt[3];
+ m_A3 += go[2];
+ m_A4 += go[3];
+ double RHS1 = Idr[2];
+ RHS1 += Idr[3];
+ m_A5 += gt[4];
+ m_A5 += gt[5];
+ m_A5 += gt[6];
+ m_A5 += gt[7];
+ m_A5 += gt[8];
+ m_A6 += go[4];
+ m_A7 += go[5];
+ double RHS2 = Idr[4];
+ RHS2 += Idr[5];
+ RHS2 += Idr[6];
+ RHS2 += Idr[7];
+ RHS2 += Idr[8];
+ RHS2 -= go[6] * *cnV[6];
+ RHS2 -= go[7] * *cnV[7];
+ RHS2 -= go[8] * *cnV[8];
+ m_A8 += gt[9];
+ m_A8 += gt[10];
+ m_A8 += gt[11];
+ m_A8 += gt[12];
+ m_A9 += go[9];
+ m_A10 += go[10];
+ m_A10 += go[11];
+ double RHS3 = Idr[9];
+ RHS3 += Idr[10];
+ RHS3 += Idr[11];
+ RHS3 += Idr[12];
+ RHS3 -= go[12] * *cnV[12];
+ m_A11 += gt[13];
+ m_A11 += gt[14];
+ m_A11 += gt[15];
+ m_A11 += gt[16];
+ m_A13 += go[13];
+ m_A12 += go[14];
+ m_A12 += go[15];
+ double RHS4 = Idr[13];
+ RHS4 += Idr[14];
+ RHS4 += Idr[15];
+ RHS4 += Idr[16];
+ RHS4 -= go[16] * *cnV[16];
+ m_A14 += gt[17];
+ m_A14 += gt[18];
+ m_A14 += gt[19];
+ m_A14 += gt[20];
+ m_A14 += gt[21];
+ m_A14 += gt[22];
+ m_A15 += go[17];
+ m_A15 += go[18];
+ m_A16 += go[19];
+ m_A16 += go[20];
+ double RHS5 = Idr[17];
+ RHS5 += Idr[18];
+ RHS5 += Idr[19];
+ RHS5 += Idr[20];
+ RHS5 += Idr[21];
+ RHS5 += Idr[22];
+ RHS5 -= go[21] * *cnV[21];
+ RHS5 -= go[22] * *cnV[22];
+ m_A17 += gt[23];
+ m_A17 += gt[24];
+ m_A17 += gt[25];
+ m_A18 += go[23];
+ double RHS6 = Idr[23];
+ RHS6 += Idr[24];
+ RHS6 += Idr[25];
+ RHS6 -= go[24] * *cnV[24];
+ RHS6 -= go[25] * *cnV[25];
+ m_A19 += gt[26];
+ m_A19 += gt[27];
+ m_A19 += gt[28];
+ m_A19 += gt[29];
+ m_A21 += go[26];
+ m_A20 += go[27];
+ double RHS7 = Idr[26];
+ RHS7 += Idr[27];
+ RHS7 += Idr[28];
+ RHS7 += Idr[29];
+ RHS7 -= go[28] * *cnV[28];
+ RHS7 -= go[29] * *cnV[29];
+ m_A22 += gt[30];
+ m_A22 += gt[31];
+ m_A24 += go[30];
+ m_A23 += go[31];
+ double RHS8 = Idr[30];
+ RHS8 += Idr[31];
+ m_A25 += gt[32];
+ m_A25 += gt[33];
+ m_A25 += gt[34];
+ m_A25 += gt[35];
+ m_A26 += go[32];
+ double RHS9 = Idr[32];
+ RHS9 += Idr[33];
+ RHS9 += Idr[34];
+ RHS9 += Idr[35];
+ RHS9 -= go[33] * *cnV[33];
+ RHS9 -= go[34] * *cnV[34];
+ RHS9 -= go[35] * *cnV[35];
+ m_A28 += gt[36];
+ m_A28 += gt[37];
+ m_A27 += go[36];
+ double RHS10 = Idr[36];
+ RHS10 += Idr[37];
+ RHS10 -= go[37] * *cnV[37];
+ m_A31 += gt[38];
+ m_A31 += gt[39];
+ m_A31 += gt[40];
+ m_A30 += go[38];
+ double RHS11 = Idr[38];
+ RHS11 += Idr[39];
+ RHS11 += Idr[40];
+ RHS11 -= go[39] * *cnV[39];
+ RHS11 -= go[40] * *cnV[40];
+ m_A37 += gt[41];
+ m_A37 += gt[42];
+ m_A37 += gt[43];
+ m_A37 += gt[44];
+ m_A35 += go[41];
+ m_A34 += go[42];
+ m_A38 += go[43];
+ double RHS12 = Idr[41];
+ RHS12 += Idr[42];
+ RHS12 += Idr[43];
+ RHS12 += Idr[44];
+ RHS12 -= go[44] * *cnV[44];
+ m_A42 += gt[45];
+ m_A42 += gt[46];
+ m_A42 += gt[47];
+ m_A42 += gt[48];
+ m_A42 += gt[49];
+ m_A42 += gt[50];
+ m_A41 += go[45];
+ m_A41 += go[46];
+ m_A40 += go[47];
+ double RHS13 = Idr[45];
+ RHS13 += Idr[46];
+ RHS13 += Idr[47];
+ RHS13 += Idr[48];
+ RHS13 += Idr[49];
+ RHS13 += Idr[50];
+ RHS13 -= go[48] * *cnV[48];
+ RHS13 -= go[49] * *cnV[49];
+ RHS13 -= go[50] * *cnV[50];
+ m_A48 += gt[51];
+ m_A48 += gt[52];
+ m_A48 += gt[53];
+ m_A48 += gt[54];
+ m_A48 += gt[55];
+ m_A45 += go[51];
+ m_A45 += go[52];
+ m_A46 += go[53];
+ double RHS14 = Idr[51];
+ RHS14 += Idr[52];
+ RHS14 += Idr[53];
+ RHS14 += Idr[54];
+ RHS14 += Idr[55];
+ RHS14 -= go[54] * *cnV[54];
+ RHS14 -= go[55] * *cnV[55];
+ m_A54 += gt[56];
+ m_A54 += gt[57];
+ m_A54 += gt[58];
+ m_A54 += gt[59];
+ m_A54 += gt[60];
+ m_A55 += go[56];
+ m_A51 += go[57];
+ m_A52 += go[58];
+ double RHS15 = Idr[56];
+ RHS15 += Idr[57];
+ RHS15 += Idr[58];
+ RHS15 += Idr[59];
+ RHS15 += Idr[60];
+ RHS15 -= go[59] * *cnV[59];
+ RHS15 -= go[60] * *cnV[60];
+ m_A58 += gt[61];
+ m_A58 += gt[62];
+ m_A58 += gt[63];
+ m_A57 += go[61];
+ m_A56 += go[62];
+ double RHS16 = Idr[61];
+ RHS16 += Idr[62];
+ RHS16 += Idr[63];
+ RHS16 -= go[63] * *cnV[63];
+ m_A63 += gt[64];
+ m_A63 += gt[65];
+ m_A65 += go[64];
+ m_A60 += go[65];
+ double RHS17 = Idr[64];
+ RHS17 += Idr[65];
+ m_A67 += gt[66];
+ m_A67 += gt[67];
+ m_A67 += gt[68];
+ m_A67 += gt[69];
+ m_A68 += go[66];
+ m_A66 += go[67];
+ m_A66 += go[68];
+ double RHS18 = Idr[66];
+ RHS18 += Idr[67];
+ RHS18 += Idr[68];
+ RHS18 += Idr[69];
+ RHS18 -= go[69] * *cnV[69];
+ m_A72 += gt[70];
+ m_A72 += gt[71];
+ m_A72 += gt[72];
+ m_A72 += gt[73];
+ m_A72 += gt[74];
+ m_A74 += go[70];
+ m_A74 += go[71];
+ m_A69 += go[72];
+ double RHS19 = Idr[70];
+ RHS19 += Idr[71];
+ RHS19 += Idr[72];
+ RHS19 += Idr[73];
+ RHS19 += Idr[74];
+ RHS19 -= go[73] * *cnV[73];
+ RHS19 -= go[74] * *cnV[74];
+ m_A80 += gt[75];
+ m_A80 += gt[76];
+ m_A80 += gt[77];
+ m_A80 += gt[78];
+ m_A77 += go[75];
+ m_A76 += go[76];
+ m_A75 += go[77];
+ double RHS20 = Idr[75];
+ RHS20 += Idr[76];
+ RHS20 += Idr[77];
+ RHS20 += Idr[78];
+ RHS20 -= go[78] * *cnV[78];
+ m_A86 += gt[79];
+ m_A86 += gt[80];
+ m_A86 += gt[81];
+ m_A86 += gt[82];
+ m_A86 += gt[83];
+ m_A86 += gt[84];
+ m_A84 += go[79];
+ m_A83 += go[80];
+ m_A82 += go[81];
+ m_A82 += go[82];
+ double RHS21 = Idr[79];
+ RHS21 += Idr[80];
+ RHS21 += Idr[81];
+ RHS21 += Idr[82];
+ RHS21 += Idr[83];
+ RHS21 += Idr[84];
+ RHS21 -= go[83] * *cnV[83];
+ RHS21 -= go[84] * *cnV[84];
+ m_A93 += gt[85];
+ m_A93 += gt[86];
+ m_A93 += gt[87];
+ m_A93 += gt[88];
+ m_A93 += gt[89];
+ m_A89 += go[85];
+ m_A91 += go[86];
+ m_A91 += go[87];
+ m_A88 += go[88];
+ double RHS22 = Idr[85];
+ RHS22 += Idr[86];
+ RHS22 += Idr[87];
+ RHS22 += Idr[88];
+ RHS22 += Idr[89];
+ RHS22 -= go[89] * *cnV[89];
+ const double f0 = 1.0 / m_A0;
+ const double f0_15 = -f0 * m_A51;
+ m_A54 += m_A1 * f0_15;
+ RHS15 += f0_15 * RHS0;
+ const double f1 = 1.0 / m_A2;
+ const double f1_10 = -f1 * m_A27;
+ m_A28 += m_A3 * f1_10;
+ m_A29 += m_A4 * f1_10;
+ RHS10 += f1_10 * RHS1;
+ const double f1_12 = -f1 * m_A34;
+ m_A36 += m_A3 * f1_12;
+ m_A38 += m_A4 * f1_12;
+ RHS12 += f1_12 * RHS1;
+ const double f1_15 = -f1 * m_A52;
+ m_A53 += m_A3 * f1_15;
+ m_A54 += m_A4 * f1_15;
+ RHS15 += f1_15 * RHS1;
+ const double f1_20 = -f1 * m_A75;
+ m_A77 += m_A3 * f1_20;
+ m_A79 += m_A4 * f1_20;
+ RHS20 += f1_20 * RHS1;
+ const double f2 = 1.0 / m_A5;
+ const double f2_11 = -f2 * m_A30;
+ m_A32 += m_A6 * f2_11;
+ m_A33 += m_A7 * f2_11;
+ RHS11 += f2_11 * RHS2;
+ const double f2_12 = -f2 * m_A35;
+ m_A37 += m_A6 * f2_12;
+ m_A39 += m_A7 * f2_12;
+ RHS12 += f2_12 * RHS2;
+ const double f2_20 = -f2 * m_A76;
+ m_A78 += m_A6 * f2_20;
+ m_A80 += m_A7 * f2_20;
+ RHS20 += f2_20 * RHS2;
+ const double f3 = 1.0 / m_A8;
+ const double f3_13 = -f3 * m_A40;
+ m_A42 += m_A9 * f3_13;
+ m_A43 += m_A10 * f3_13;
+ RHS13 += f3_13 * RHS3;
+ const double f3_14 = -f3 * m_A45;
+ m_A47 += m_A9 * f3_14;
+ m_A48 += m_A10 * f3_14;
+ RHS14 += f3_14 * RHS3;
+ const double f4 = 1.0 / m_A11;
+ const double f4_13 = -f4 * m_A41;
+ m_A42 += m_A12 * f4_13;
+ m_A44 += m_A13 * f4_13;
+ RHS13 += f4_13 * RHS4;
+ const double f4_17 = -f4 * m_A60;
+ m_A61 += m_A12 * f4_17;
+ m_A63 += m_A13 * f4_17;
+ RHS17 += f4_17 * RHS4;
+ const double f5 = 1.0 / m_A14;
+ const double f5_18 = -f5 * m_A66;
+ m_A67 += m_A15 * f5_18;
+ m_A68 += m_A16 * f5_18;
+ RHS18 += f5_18 * RHS5;
+ const double f5_21 = -f5 * m_A82;
+ m_A84 += m_A15 * f5_21;
+ m_A86 += m_A16 * f5_21;
+ RHS21 += f5_21 * RHS5;
+ const double f6 = 1.0 / m_A17;
+ const double f6_16 = -f6 * m_A56;
+ m_A58 += m_A18 * f6_16;
+ RHS16 += f6_16 * RHS6;
+ const double f7 = 1.0 / m_A19;
+ const double f7_14 = -f7 * m_A46;
+ m_A48 += m_A20 * f7_14;
+ m_A50 += m_A21 * f7_14;
+ RHS14 += f7_14 * RHS7;
+ const double f7_19 = -f7 * m_A69;
+ m_A70 += m_A20 * f7_19;
+ m_A72 += m_A21 * f7_19;
+ RHS19 += f7_19 * RHS7;
+ const double f8 = 1.0 / m_A22;
+ const double f8_16 = -f8 * m_A57;
+ m_A58 += m_A23 * f8_16;
+ m_A59 += m_A24 * f8_16;
+ RHS16 += f8_16 * RHS8;
+ const double f8_22 = -f8 * m_A88;
+ m_A90 += m_A23 * f8_22;
+ m_A93 += m_A24 * f8_22;
+ RHS22 += f8_22 * RHS8;
+ const double f9 = 1.0 / m_A25;
+ const double f9_22 = -f9 * m_A89;
+ m_A93 += m_A26 * f9_22;
+ RHS22 += f9_22 * RHS9;
+ const double f10 = 1.0 / m_A28;
+ const double f10_12 = -f10 * m_A36;
+ m_A38 += m_A29 * f10_12;
+ RHS12 += f10_12 * RHS10;
+ const double f10_15 = -f10 * m_A53;
+ m_A54 += m_A29 * f10_15;
+ RHS15 += f10_15 * RHS10;
+ const double f10_20 = -f10 * m_A77;
+ m_A79 += m_A29 * f10_20;
+ RHS20 += f10_20 * RHS10;
+ const double f12 = 1.0 / m_A37;
+ const double f12_20 = -f12 * m_A78;
+ m_A79 += m_A38 * f12_20;
+ m_A80 += m_A39 * f12_20;
+ RHS20 += f12_20 * RHS12;
+ const double f13 = 1.0 / m_A42;
+ const double f13_14 = -f13 * m_A47;
+ m_A48 += m_A43 * f13_14;
+ m_A49 += m_A44 * f13_14;
+ RHS14 += f13_14 * RHS13;
+ const double f13_17 = -f13 * m_A61;
+ m_A62 += m_A43 * f13_17;
+ m_A63 += m_A44 * f13_17;
+ RHS17 += f13_17 * RHS13;
+ const double f14 = 1.0 / m_A48;
+ const double f14_17 = -f14 * m_A62;
+ m_A63 += m_A49 * f14_17;
+ m_A64 += m_A50 * f14_17;
+ RHS17 += f14_17 * RHS14;
+ const double f14_19 = -f14 * m_A70;
+ m_A71 += m_A49 * f14_19;
+ m_A72 += m_A50 * f14_19;
+ RHS19 += f14_19 * RHS14;
+ const double f15 = 1.0 / m_A54;
+ const double f15_20 = -f15 * m_A79;
+ m_A81 += m_A55 * f15_20;
+ RHS20 += f15_20 * RHS15;
+ const double f16 = 1.0 / m_A58;
+ const double f16_22 = -f16 * m_A90;
+ m_A93 += m_A59 * f16_22;
+ RHS22 += f16_22 * RHS16;
+ const double f17 = 1.0 / m_A63;
+ const double f17_19 = -f17 * m_A71;
+ m_A72 += m_A64 * f17_19;
+ m_A73 += m_A65 * f17_19;
+ RHS19 += f17_19 * RHS17;
+ const double f17_21 = -f17 * m_A83;
+ m_A85 += m_A64 * f17_21;
+ m_A86 += m_A65 * f17_21;
+ RHS21 += f17_21 * RHS17;
+ const double f18 = 1.0 / m_A67;
+ const double f18_21 = -f18 * m_A84;
+ m_A86 += m_A68 * f18_21;
+ RHS21 += f18_21 * RHS18;
+ const double f19 = 1.0 / m_A72;
+ const double f19_21 = -f19 * m_A85;
+ m_A86 += m_A73 * f19_21;
+ m_A87 += m_A74 * f19_21;
+ RHS21 += f19_21 * RHS19;
+ const double f19_22 = -f19 * m_A91;
+ m_A92 += m_A73 * f19_22;
+ m_A93 += m_A74 * f19_22;
+ RHS22 += f19_22 * RHS19;
+ const double f21 = 1.0 / m_A86;
+ const double f21_22 = -f21 * m_A92;
+ m_A93 += m_A87 * f21_22;
+ RHS22 += f21_22 * RHS21;
+ V[22] = RHS22 / m_A93;
+ double tmp21 = 0.0;
+ tmp21 += m_A87 * V[22];
+ V[21] = (RHS21 - tmp21) / m_A86;
+ double tmp20 = 0.0;
+ tmp20 += m_A81 * V[21];
+ V[20] = (RHS20 - tmp20) / m_A80;
+ double tmp19 = 0.0;
+ tmp19 += m_A73 * V[21];
+ tmp19 += m_A74 * V[22];
+ V[19] = (RHS19 - tmp19) / m_A72;
+ double tmp18 = 0.0;
+ tmp18 += m_A68 * V[21];
+ V[18] = (RHS18 - tmp18) / m_A67;
+ double tmp17 = 0.0;
+ tmp17 += m_A64 * V[19];
+ tmp17 += m_A65 * V[21];
+ V[17] = (RHS17 - tmp17) / m_A63;
+ double tmp16 = 0.0;
+ tmp16 += m_A59 * V[22];
+ V[16] = (RHS16 - tmp16) / m_A58;
+ double tmp15 = 0.0;
+ tmp15 += m_A55 * V[21];
+ V[15] = (RHS15 - tmp15) / m_A54;
+ double tmp14 = 0.0;
+ tmp14 += m_A49 * V[17];
+ tmp14 += m_A50 * V[19];
+ V[14] = (RHS14 - tmp14) / m_A48;
+ double tmp13 = 0.0;
+ tmp13 += m_A43 * V[14];
+ tmp13 += m_A44 * V[17];
+ V[13] = (RHS13 - tmp13) / m_A42;
+ double tmp12 = 0.0;
+ tmp12 += m_A38 * V[15];
+ tmp12 += m_A39 * V[20];
+ V[12] = (RHS12 - tmp12) / m_A37;
+ double tmp11 = 0.0;
+ tmp11 += m_A32 * V[12];
+ tmp11 += m_A33 * V[20];
+ V[11] = (RHS11 - tmp11) / m_A31;
+ double tmp10 = 0.0;
+ tmp10 += m_A29 * V[15];
+ V[10] = (RHS10 - tmp10) / m_A28;
+ double tmp9 = 0.0;
+ tmp9 += m_A26 * V[22];
+ V[9] = (RHS9 - tmp9) / m_A25;
+ double tmp8 = 0.0;
+ tmp8 += m_A23 * V[16];
+ tmp8 += m_A24 * V[22];
+ V[8] = (RHS8 - tmp8) / m_A22;
+ double tmp7 = 0.0;
+ tmp7 += m_A20 * V[14];
+ tmp7 += m_A21 * V[19];
+ V[7] = (RHS7 - tmp7) / m_A19;
+ double tmp6 = 0.0;
+ tmp6 += m_A18 * V[16];
+ V[6] = (RHS6 - tmp6) / m_A17;
+ double tmp5 = 0.0;
+ tmp5 += m_A15 * V[18];
+ tmp5 += m_A16 * V[21];
+ V[5] = (RHS5 - tmp5) / m_A14;
+ double tmp4 = 0.0;
+ tmp4 += m_A12 * V[13];
+ tmp4 += m_A13 * V[17];
+ V[4] = (RHS4 - tmp4) / m_A11;
+ double tmp3 = 0.0;
+ tmp3 += m_A9 * V[13];
+ tmp3 += m_A10 * V[14];
+ V[3] = (RHS3 - tmp3) / m_A8;
+ double tmp2 = 0.0;
+ tmp2 += m_A6 * V[12];
+ tmp2 += m_A7 * V[20];
+ V[2] = (RHS2 - tmp2) / m_A5;
+ double tmp1 = 0.0;
+ tmp1 += m_A3 * V[10];
+ tmp1 += m_A4 * V[15];
+ V[1] = (RHS1 - tmp1) / m_A2;
+ double tmp0 = 0.0;
+ tmp0 += m_A1 * V[15];
+ V[0] = (RHS0 - tmp0) / m_A0;
+}
+
// barrier
static void nl_gcr_f425d4008ae1d2c6_13_double_double(double * __restrict V, const double * __restrict go, const double * __restrict gt, const double * __restrict Idr, const double * const * __restrict cnV)
@@ -37142,6 +39866,8 @@ static void nl_gcr_fc9971724787b82b_149_double_double(double * __restrict V, con
extern const plib::dynlib_static_sym nl_static_solver_syms[];
const plib::dynlib_static_sym nl_static_solver_syms[] = {
+// tankbatt
+ {"nl_gcr_124f7aa10f044582_16_double_double", reinterpret_cast<void *>(&nl_gcr_124f7aa10f044582_16_double_double)},
// armora
{"nl_gcr_1250f340dea396ae_22_double_double", reinterpret_cast<void *>(&nl_gcr_1250f340dea396ae_22_double_double)},
// pongf
@@ -37168,6 +39894,8 @@ const plib::dynlib_static_sym nl_static_solver_syms[] = {
{"nl_gcr_295cf2e2f3d489bf_12_double_double", reinterpret_cast<void *>(&nl_gcr_295cf2e2f3d489bf_12_double_double)},
// boxingb
{"nl_gcr_2f84bc98d737730b_22_double_double", reinterpret_cast<void *>(&nl_gcr_2f84bc98d737730b_22_double_double)},
+// tankbatt
+ {"nl_gcr_328d886b444b586b_137_double_double", reinterpret_cast<void *>(&nl_gcr_328d886b444b586b_137_double_double)},
// solarq
{"nl_gcr_34e910fc1896999f_76_double_double", reinterpret_cast<void *>(&nl_gcr_34e910fc1896999f_76_double_double)},
// warrior
@@ -37242,8 +39970,6 @@ const plib::dynlib_static_sym nl_static_solver_syms[] = {
{"nl_gcr_79e756c5892cf87d_31_double_double", reinterpret_cast<void *>(&nl_gcr_79e756c5892cf87d_31_double_double)},
// breakout
{"nl_gcr_7a42b97d838ca073_7_double_double", reinterpret_cast<void *>(&nl_gcr_7a42b97d838ca073_7_double_double)},
-// 280zzzap
- {"nl_gcr_7afaac594132b463_104_double_double", reinterpret_cast<void *>(&nl_gcr_7afaac594132b463_104_double_double)},
// cheekyms
{"nl_gcr_7c86a9bc1c6aef4c_7_double_double", reinterpret_cast<void *>(&nl_gcr_7c86a9bc1c6aef4c_7_double_double)},
// solarq
@@ -37274,6 +40000,8 @@ const plib::dynlib_static_sym nl_static_solver_syms[] = {
{"nl_gcr_8bec817b324dcc3_28_double_double", reinterpret_cast<void *>(&nl_gcr_8bec817b324dcc3_28_double_double)},
// cocoloco
{"nl_gcr_8c0f7f2284333de5_16_double_double", reinterpret_cast<void *>(&nl_gcr_8c0f7f2284333de5_16_double_double)},
+// starcrus
+ {"nl_gcr_8d7bddf33d942482_129_double_double", reinterpret_cast<void *>(&nl_gcr_8d7bddf33d942482_129_double_double)},
// gamemachine
{"nl_gcr_934712b55bb3b2b2_10_double_double", reinterpret_cast<void *>(&nl_gcr_934712b55bb3b2b2_10_double_double)},
// kidniki
@@ -37288,6 +40016,8 @@ const plib::dynlib_static_sym nl_static_solver_syms[] = {
{"nl_gcr_a0bf548977306172_25_double_double", reinterpret_cast<void *>(&nl_gcr_a0bf548977306172_25_double_double)},
// boxingb
{"nl_gcr_a1132c8737d5d463_96_double_double", reinterpret_cast<void *>(&nl_gcr_a1132c8737d5d463_96_double_double)},
+// 280zzzap
+ {"nl_gcr_a29a3ea050cc0879_113_double_double", reinterpret_cast<void *>(&nl_gcr_a29a3ea050cc0879_113_double_double)},
// rebound
{"nl_gcr_a41a44bd5c424f88_13_double_double", reinterpret_cast<void *>(&nl_gcr_a41a44bd5c424f88_13_double_double)},
// tp1985
@@ -37330,6 +40060,8 @@ const plib::dynlib_static_sym nl_static_solver_syms[] = {
{"nl_gcr_be7c805100c522fd_59_double_double", reinterpret_cast<void *>(&nl_gcr_be7c805100c522fd_59_double_double)},
// warrior
{"nl_gcr_bff07f8d339f7cc4_89_double_double", reinterpret_cast<void *>(&nl_gcr_bff07f8d339f7cc4_89_double_double)},
+// starcrus
+ {"nl_gcr_c2e616f3de30f15b_31_double_double", reinterpret_cast<void *>(&nl_gcr_c2e616f3de30f15b_31_double_double)},
// tailg
{"nl_gcr_c4cec7aed23b7b94_23_double_double", reinterpret_cast<void *>(&nl_gcr_c4cec7aed23b7b94_23_double_double)},
// popeye
@@ -37388,6 +40120,8 @@ const plib::dynlib_static_sym nl_static_solver_syms[] = {
{"nl_gcr_ecf17036ce1c07cf_10_double_double", reinterpret_cast<void *>(&nl_gcr_ecf17036ce1c07cf_10_double_double)},
// armora
{"nl_gcr_ee2cacaa15d32491_67_double_double", reinterpret_cast<void *>(&nl_gcr_ee2cacaa15d32491_67_double_double)},
+// starcrus
+ {"nl_gcr_ef2f49641f433a74_94_double_double", reinterpret_cast<void *>(&nl_gcr_ef2f49641f433a74_94_double_double)},
// barrier
{"nl_gcr_f425d4008ae1d2c6_13_double_double", reinterpret_cast<void *>(&nl_gcr_f425d4008ae1d2c6_13_double_double)},
// boxingb
diff --git a/src/lib/netlist/macro/nlm_base.cpp b/src/lib/netlist/macro/nlm_base.cpp
index b399a2c360c..193e53eae6f 100644
--- a/src/lib/netlist/macro/nlm_base.cpp
+++ b/src/lib/netlist/macro/nlm_base.cpp
@@ -1,8 +1,6 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-#include "netlist/nl_setup.h"
#include "netlist/devices/net_lib.h"
-#include "nlm_base.h"
/* ----------------------------------------------------------------------------
* Diode Models
@@ -16,6 +14,8 @@ static NETLIST_START(diode_models)
NET_MODEL("1N916 D(Is=2.52n Rs=.568 N=1.752 Cjo=4p M=.4 tt=20n Iave=200m Vpk=75 mfg=OnSemi type=silicon)")
NET_MODEL("1N4001 D(Is=14.11n N=1.984 Rs=33.89m Ikf=94.81 Xti=3 Eg=1.11 Cjo=25.89p M=.44 Vj=.3245 Fc=.5 Bv=75 Ibv=10u Tt=5.7u Iave=1 Vpk=50 mfg=GI type=silicon)")
NET_MODEL("1N4148 D(Is=2.52n Rs=.568 N=1.752 Cjo=4p M=.4 tt=20n Iave=200m Vpk=75 mfg=OnSemi type=silicon)")
+ // FIXME: Unsure of the peak voltage of the 1N4154!
+ NET_MODEL("1N4154 D(Is=0.1n Rs=4 N=1.67 Cjo=2p M=.333 tt=3n Iave=150m Vpk=35 Bv=60 Ibv=0.1p mfg=Vishay type=silicon)")
NET_MODEL("1S1588 D(Is=2.52n Rs=.568 N=1.752 Cjo=4p M=.4 tt=20n Iave=200m Vpk=75)")
NET_MODEL("1N34A D( Bv=75 Cjo=0.5e-12 Eg=0.67 Ibv=18e-3 Is=2e-7 Rs=7 N=1.3 Vj=0.1 M=0.27 type=germanium)")
@@ -60,6 +60,8 @@ static NETLIST_START(bjt_models)
NET_MODEL("2N5190 NPN(IS=9.198E-14 NF=1.003 ISE=4.468E-16 NE=1.65 BF=338.8 IKF=0.4913 VAF=107.9 NR=1.002 ISC=5.109E-15 NC=1.071 BR=29.48 IKR=0.193 VAR=25 RB=1 IRB=1000 RBM=1 RE=0.2126 RC=0.143 XTB=0 EG=1.11 XTI=3 CJE=3.825E-11 VJE=0.7004 MJE=0.364 TF=5.229E-10 XTF=219.7 VTF=3.502 ITF=7.257 PTF=0 CJC=1.27E-11 VJC=0.4431 MJC=0.3983 XCJC=0.4555 TR=7E-11 CJS=0 VJS=0.75 MJS=0.333 FC=0.905 Vceo=45 Icrating=500m mfg=Philips)")
NET_MODEL("2N4401 NPN(IS=26.03f XTI=3 EG=1.11 VAF=90.7 BF=4.292K NE=1.244 ISE=26.03f IKF=0.2061 XTB=1.5 BR=1.01 NC=2 ISC=0 IKR=0 RC=0.5 CJC=11.01p MJC=0.3763 VJC=0.75 FC=0.5 CJE=24.07p MJE=0.3641 VJE=0.75 TR=233.7n TF=466.5p ITF=0 VTF=0 XTF=0 RB=10 VCEO=40)")
+ NET_MODEL("2N4124 NPN(IS=6.734f XTI=3 EG=1.11 VAF=74.03 BF=495 NE=1.28 ISE=6.734f IKF=69.35m XTB=1.5 BR=0.7214 NC=2 ISC=0 IKR=0 RC=1 CJC=3.638p MJC=0.3085 VJC=0.75 FC=0.5 CJE=4.493p MJE=0.2593 VJE=0.75 TR=238.3n TF=301.3p ITF=.4 VTF=4 XTF=2 RB=10 VCEO=25)")
+ NET_MODEL("2N4126 PNP(IS=1.41f XTI=3 EG=1.11 VAF=18.7 BF=203.7 NE=1.5 ISE=0 IKF=80m XTB=1.5 BR=4.924 NC=2 ISC=0 IKR=0 RC=2.5 CJC=9.728p MJC=0.5776 VJC=0.75 FC=0.5 CJE=8.063p MJE=0.3677 VJE=0.75 TR=33.23n TF=179.3p ITF=.4 VTF=4 XTF=6 RB=10 VCEO=25)")
NET_MODEL("2SC945 NPN(IS=3.577E-14 BF=2.382E+02 NF=1.01 VAF=1.206E+02 IKF=3.332E-01 ISE=3.038E-16 NE=1.205 BR=1.289E+01 NR=1.015 VAR=1.533E+01 IKR=2.037E-01 ISC=3.972E-14 NC=1.115 RB=3.680E+01 IRB=1.004E-04 RBM=1 RE=8.338E-01 RC=1.557E+00 CJE=1.877E-11 VJE=7.211E-01 MJE=3.486E-01 TF=4.149E-10 XTF=1.000E+02 VTF=9.956 ITF=5.118E-01 PTF=0 CJC=6.876p VJC=3.645E-01 MJC=3.074E-01 TR=5.145E-08 XTB=1.5 EG=1.11 XTI=3 FC=0.5 Vceo=50 Icrating=100m MFG=NEC)")
NET_MODEL("BC237B NPN(IS=1.8E-14 ISE=5.0E-14 ISC=1.72E-13 XTI=3 BF=400 BR=35.5 IKF=0.14 IKR=0.03 XTB=1.5 VAF=80 VAR=12.5 VJE=0.58 VJC=0.54 RE=0.6 RC=0.25 RB=0.56 CJE=13E-12 CJC=4E-12 XCJC=0.75 FC=0.5 NF=0.9955 NR=1.005 NE=1.46 NC=1.27 MJE=0.33 MJC=0.33 TF=0.64E-9 TR=50.72E-9 EG=1.11 KF=0 AF=1 VCEO=45 ICRATING=100M MFG=ZETEX)")
diff --git a/src/lib/netlist/macro/nlm_cd4xxx.cpp b/src/lib/netlist/macro/nlm_cd4xxx.cpp
index 1db02040006..56150a2d31e 100644
--- a/src/lib/netlist/macro/nlm_cd4xxx.cpp
+++ b/src/lib/netlist/macro/nlm_cd4xxx.cpp
@@ -3,100 +3,172 @@
#include "netlist/devices/net_lib.h"
-/*
- * CD4001BC: Quad 2-Input NOR Buffered B Series Gate
- *
- * +--------------+
- * A1 |1 ++ 14| VDD
- * B1 |2 13| A6
- * A2 |3 12| Y6
- * Y2 |4 4001 11| A5
- * A3 |5 10| Y5
- * Y3 |6 9| A4
- * VSS |7 8| Y4
- * +--------------+
- *
- */
-
+//- Identifier: CD4001_DIP
+//- Title: CD4001BM/CD4001BC Quad 2-Input NOR Buffered B Series Gate
+//- Description: These quad gates are monolithic complementary MOS (CMOS) integrated circuits constructed with N- and P-channel enhancement mode transistors.
+//- They have equal source and sink current capabilities and conform to standard B series output drive.
+//- The devices also have buffered outputs which improve transfer characteristics by providing very high gain.
+//- All inputs are protected against static discharge with diodes to VDD and VSS.
+//- Pinalias: A1,B1,Y1,Y2,A2,B2,VSS,A3,B3,Y3,Y4,A4,B4,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/166/108518_DS.pdf
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 1 |
+//- | X | 1 || 0 |
+//- | 1 | X || 0 |
+//- +---+---++---+
+//-
static NETLIST_START(CD4001_DIP)
- CD4001_GATE(s1)
- CD4001_GATE(s2)
- CD4001_GATE(s3)
- CD4001_GATE(s4)
-
- NET_C(s1.VDD, s2.VDD, s3.VDD, s4.VDD)
- NET_C(s1.VSS, s2.VSS, s3.VSS, s4.VSS)
- DIPPINS( /* +--------------+ */
- s1.A, /* A1 |1 ++ 14| VDD */ s1.VDD,
- s1.B, /* B1 |2 13| A6 */ s4.B,
- s1.Q, /* A2 |3 12| Y6 */ s4.A,
- s2.Q, /* Y2 |4 4001 11| A5 */ s4.Q,
- s2.A, /* A3 |5 10| Y5 */ s3.Q,
- s2.B, /* Y3 |6 9| A4 */ s3.B,
- s1.VSS, /* VSS |7 8| Y4 */ s3.A
- /* +--------------+ */
+ CD4001_GATE(A)
+ CD4001_GATE(B)
+ CD4001_GATE(C)
+ CD4001_GATE(D)
+
+ NET_C(A.VDD, B.VDD, C.VDD, D.VDD)
+ NET_C(A.VSS, B.VSS, C.VSS, D.VSS)
+
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VDD */ A.VDD,
+ A.B, /* B1 |2 13| B4 */ D.B,
+ A.Q, /* Y1 |3 12| A4 */ D.A,
+ B.Q, /* Y2 |4 4001 11| Y4 */ D.Q,
+ B.A, /* A2 |5 10| Y3 */ C.Q,
+ B.B, /* B2 |6 9| B3 */ C.B,
+ A.VSS, /* VSS |7 8| A3 */ C.A
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: CD4006_DIP
+//- Title: CD4006BM/CD4006BC 18-Stage Static Shift Register
+//- Description: The CD4006BM/CD4006BC 18-stage static shift register is comprised of four separate shift register sections, two sections of four stages and two sections of five stages.
+//- Each section has an independent data input.
+//- Outputs are available at the fourth stage and the fifth stage of each section.
+//- A common clock signal is used for all stages.
+//- Data is shifted to the next stage on the negative-going transition of the clock.
+//- Through appropriate connections of inputs and outputs, multiple register sections of 4, 5, 8, and 9 stages, or single register sections of 10, 12, 13, 14, 16, 17, and 18 stages can be implemented using one package.
+//- Pinalias: D1,NC,CLOCK,D2,D3,D4,VSS,D4P4,D4P5,D3P4,D2P4,D2P5,D1P4,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS005942.PDF
+//-
+static NETLIST_START(CD4006_DIP)
+ CD4006(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.D1, /* D1 |1 ++ 14| VDD */ A.VDD,
+ NC.I, /* NC |2 13| D1+4 */ A.D1P4,
+ A.CLOCK, /* CLOCK |3 12| D2+5 */ A.D2P5,
+ A.D2, /* D2 |4 4006 11| D2+4 */ A.D2P4,
+ A.D3, /* D3 |5 10| D3+4 */ A.D3P4,
+ A.D4, /* D4 |6 9| D4+5 */ A.D4P5,
+ A.VSS, /* VSS |7 8| D4+4 */ A.D4P4
+ /* +--------------+ */
)
+NETLIST_END()
+//- Identifier: CD4011_DIP
+//- Title: CD4011BM/CD4011BC Quad 2-Input NAND Buffered B Series Gate
+//- Description: These quad gates are monolithic complementary MOS (CMOS) integrated circuits constructed with N- and P-channel enhancement mode transistors.
+//- They have equal source and sink current capabilities and conform to standard B series output drive.
+//- The devices also have buffered outputs which improve transfer characteristics by providing very high gain.
+//- All inputs are protected against static discharge with diodes to VDD and VSS.
+//- Pinalias: A1,B1,Y1,Y2,A2,B2,VSS,A3,B3,Y3,Y4,A4,B4,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/166/108518_DS.pdf
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | X | 0 || 1 |
+//- | 0 | X || 1 |
+//- | 1 | 1 || 0 |
+//- +---+---++---+
+//-
+static NETLIST_START(CD4011_DIP)
+ CD4011_GATE(A)
+ CD4011_GATE(B)
+ CD4011_GATE(C)
+ CD4011_GATE(D)
+
+ NET_C(A.VDD, B.VDD, C.VDD, D.VDD)
+ NET_C(A.VSS, B.VSS, C.VSS, D.VSS)
+
+ DIPPINS( /* +--------------+ */
+ A.A, /* A |1 ++ 14| VDD */ A.VDD,
+ A.B, /* B |2 13| H */ D.B,
+ A.Q, /* J |3 12| G */ D.A,
+ B.Q, /* K |4 4011 11| M */ D.Q,
+ B.A, /* C |5 10| L */ C.Q,
+ B.B, /* D |6 9| F */ C.B,
+ A.VSS, /* VSS |7 8| E */ C.A
+ /* +--------------+ */
+ )
NETLIST_END()
-/* CD4020: 14-Stage Ripple Carry Binary Counters
- *
- * +--------------+
- * Q12 |1 ++ 16| VDD
- * Q13 |2 15| Q11
- * Q14 |3 14| Q10
- * Q6 |4 4020 13| Q8
- * Q5 |5 12| Q9
- * Q7 |6 11| RESET
- * Q4 |7 10| IP (Input pulses)
- * VSS |8 9| Q1
- * +--------------+
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- * FIXME: Timing depends on VDD-VSS
- * This needs a cmos d-a/a-d proxy implementation.
- */
+//- Identifier: CD4013_DIP
+//- Title: CD4013BM/CD4013BC Dual D Flip-Flop
+//- Description: The CD4013B dual D flip-flop is a monolithic complementary MOS (CMOS) integrated circuit constructed with N- and P-channel enhancement mode transistors.
+//- Each flip-flop has independent data, set, reset, and clock inputs and Q and QQ outputs.
+//- These devices can be used for shift register applications, and by connecting Q output to the data input, for counter and toggle applications.
+//- The logic levelpresent at the D input is transferred to the Q output during the positive-going transition of the clock pulse.
+//- Setting or resetting is independent of the clock and is accomplished by a high level on the set or reset line respectively.
+//- Pinalias: Q1,QQ1,CLOCK1,RESET1,DATA1,SET1,VSS,SET2,DATA2,RESET2,CLOCK2,QQ2,Q2,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/150/108670_DS.pdf
+//-
+//- +-----+---+---+---++---+----+
+//- | CLK | D | R | S || Q | QQ |
+//- +=====+===+===+===++===+====+
+//- | 0-1 | 0 | 0 | 0 || 0 | 1 |
+//- | 0-1 | 1 | 0 | 0 || 1 | 0 |
+//- | 1-0 | X | 0 | 0 || Q | QQ |
+//- | X | X | 1 | 0 || 0 | 1 |
+//- | X | X | 0 | 1 || 1 | 0 |
+//- | X | X | 1 | 1 || 1 | 1 |
+//- +-----+---+---+---++---+----+
+//-
+static NETLIST_START(CD4013_DIP)
+ CD4013(A)
+ CD4013(B)
-static NETLIST_START(CD4020_DIP)
+ NET_C(A.VDD, B.VDD)
+ NET_C(A.VSS, B.VSS)
- CD4020(s1)
- DIPPINS( /* +--------------+ */
- s1.Q12, /* Q12 |1 ++ 16| VDD */ s1.VDD,
- s1.Q13, /* Q13 |2 15| Q11 */ s1.Q11,
- s1.Q14, /* Q14 |3 14| Q10 */ s1.Q10,
- s1.Q6, /* Q6 |4 4020 13| Q8 */ s1.Q8,
- s1.Q5, /* Q5 |5 12| Q9 */ s1.Q9,
- s1.Q7, /* Q7 |6 11| RESET */ s1.RESET,
- s1.Q4, /* Q4 |7 10| IP */ s1.IP,
- s1.VSS, /* VSS |8 9| Q1 */ s1.Q1
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.Q, /* Q1 |1 ++ 14| VDD */ A.VDD,
+ A.QQ, /* Q1Q |2 13| Q2 */ B.Q,
+ A.CLOCK, /* CLOCK1 |3 12| Q2Q */ B.QQ,
+ A.RESET, /* RESET1 |4 4013 11| CLOCK2 */ B.CLOCK,
+ A.DATA, /* DATA1 |5 10| RESET2 */ B.RESET,
+ A.SET, /* SET1 |6 9| DATA2 */ B.DATA,
+ A.VSS, /* VSS |7 8| SET2 */ B.SET
+ /* +--------------+ */
)
- /*
- * IP = (Input pulses)
- */
-
NETLIST_END()
-/* CD4066: Quad Bilateral Switch
- *
- * +--------------+
- * INOUTA |1 ++ 14| VDD
- * OUTINA |2 13| CONTROLA
- * OUTINB |3 12| CONTROLD
- * INOUTB |4 4066 11| INOUTD
- * CONTROLB |5 10| OUTIND
- * CONTROLC |6 9| OUTINC
- * VSS |7 8| INOUTC
- * +--------------+
- *
- * FIXME: These devices are slow (~125 ns). THis is currently not reflected
- *
- * Naming conventions follow National semiconductor datasheet
- *
- */
-
-static NETLIST_START(CD4066_DIP)
+//- Identifier: CD4016_DIP
+//- Title: CD4016BM/CD4016BC Quad Bilateral Switch
+//- Description: The CD4016BM/CD4016BC is a quad bilateral switch intended for the transmission or multiplexing of analog or digital signals.
+//- It is pin-for-pin compatible with CD4066BM/CD4066BC.
+//- Pinalias: INOUTA,OUTINA,OUTINB,INOUTB,CONTROLB,CONTROLC,VSS,INOUTC,OUTINC,OUTIND,INOUTD,CONTROLD,CONTROLA,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/185/108711_DS.pdf
+//-
+static NETLIST_START(CD4016_DIP)
CD4066_GATE(A)
CD4066_GATE(B)
CD4066_GATE(C)
@@ -105,16 +177,16 @@ static NETLIST_START(CD4066_DIP)
NET_C(A.VDD, B.VDD, C.VDD, D.VDD)
NET_C(A.VSS, B.VSS, C.VSS, D.VSS)
- PARAM(A.BASER, 270.0)
- PARAM(B.BASER, 270.0)
- PARAM(C.BASER, 270.0)
- PARAM(D.BASER, 270.0)
+ PARAM(A.BASER, 1000.0)
+ PARAM(B.BASER, 1000.0)
+ PARAM(C.BASER, 1000.0)
+ PARAM(D.BASER, 1000.0)
DIPPINS( /* +--------------+ */
A.R.1, /* INOUTA |1 ++ 14| VDD */ A.VDD,
A.R.2, /* OUTINA |2 13| CONTROLA */ A.CTL,
B.R.1, /* OUTINB |3 12| CONTROLD */ D.CTL,
- B.R.2, /* INOUTB |4 4066 11| INOUTD */ D.R.1,
+ B.R.2, /* INOUTB |4 4016 11| INOUTD */ D.R.1,
B.CTL, /* CONTROLB |5 10| OUTIND */ D.R.2,
C.CTL, /* CONTROLC |6 9| OUTINC */ C.R.1,
A.VSS, /* VSS |7 8| INOUTC */ C.R.2
@@ -122,7 +194,175 @@ static NETLIST_START(CD4066_DIP)
)
NETLIST_END()
-static NETLIST_START(CD4016_DIP)
+//- Identifier: CD4017_DIP
+//- Title: CD4017BM/CD4017BC Decade Counter/Divider with 10 Decoded Outputs
+//- Description: The CD4017BM/CD4017BC is a 5-stage divide-by-10 Johnson counter with 10 decoded outputs and a carry out bit.
+//- These counters are cleared to their zero count by a logical 1 on their reset line.
+//- These counters are advanced on the positive edge of the clock signal when the clock enable signal is in the logical 0 state.
+//- The configuration of the CD4017BM/CD4017BC permits medium speed operation and assures a hazard free counting sequence.
+//- The 10 decoded outputs are normally in the logical 0 state and go to the logical 1 state only at their respective time slot.
+//- Each decoded output remains high for 1 full clock cycle.
+//- The carry-out signal completes a full cycle for every 10 clock input cycles and is used as a ripple carry signal to any succeeding stages.
+//- Pinalias: Q5,Q1,Q0,Q2,Q6,Q7,Q3,VSS,Q8,Q4,Q9,CARRY_OUT,CLOCK_ENABLE,CLOCK,RESET,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/166/108736_DS.pdf
+//-
+static NETLIST_START(CD4017_DIP)
+ CD4017(A)
+
+ DIPPINS( /* +--------------+ */
+ A.Q5, /* Q5 |1 ++ 16| VDD */ A.VDD,
+ A.Q1, /* Q1 |2 15| RESET */ A.RESET,
+ A.Q0, /* Q0 |3 14| CLOCK */ A.CLK,
+ A.Q2, /* Q2 |4 4017 13| CLOCK ENABLE */ A.CLKEN,
+ A.Q6, /* Q6 |5 12| CARRY OUT */ A.CO,
+ A.Q7, /* Q7 |6 11| Q9 */ A.Q9,
+ A.Q3, /* Q3 |7 10| Q4 */ A.Q4,
+ A.VSS, /* VSS |8 9| Q8 */ A.Q8
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: CD4020_DIP
+//- Title: CD4020BC 14-Stage Ripple Carry Binary Counters
+//- Description: The CD4020BC is a 14-stage ripple carry binary counter.
+//- The counters are advanced one count on the negative transition of each clock pulse.
+//- The counters are reset to the zero state by a logical 1 at the reset input independent of clock.
+//- Pinalias: Q12,Q13,Q14,Q6,Q5,Q7,Q4,VSS,Q1,PHI1,RESET,Q9,Q8,Q10,Q11,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Fairchild Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/90/109006_DS.pdf
+//-
+static NETLIST_START(CD4020_DIP)
+ CD4020(A)
+
+ DIPPINS( /* +--------------+ */
+ A.Q12, /* Q12 |1 ++ 16| VDD */ A.VDD,
+ A.Q13, /* Q13 |2 15| Q11 */ A.Q11,
+ A.Q14, /* Q14 |3 14| Q10 */ A.Q10,
+ A.Q6, /* Q6 |4 4020 13| Q8 */ A.Q8,
+ A.Q5, /* Q5 |5 12| Q9 */ A.Q9,
+ A.Q7, /* Q7 |6 11| RESET */ A.RESET,
+ A.Q4, /* Q4 |7 10| PHI1 */ A.IP,
+ A.VSS, /* VSS |8 9| Q1 */ A.Q1
+ /* +--------------+ */)
+NETLIST_END()
+
+//- Identifier: CD4022_DIP
+//- Title: CD4022BM/CD4022BC Divide-by-8 Counter/Divider with 8 Decoded Outputs
+//- Description: The CD4022BM/CD4022BC is a 4-stage divide-by-8 Johnson counter with 8 decoded outputs and a carry-out bit.
+//- These counters are cleared to their zero count by a logical 1 on their reset line.
+//- These counters are advanced on the positive edge of the clock signal when the clock enable signal is in the logical 0 state.
+//- The configuration of the CD4022BM/CD4022BC permits medium speed operation and assures a hazard free counting sequence.
+//- The 8 decoded outputs are normally in the logical 0 state and go to the logical 1 state only at their respective time slot.
+//- Each decoded output remains high for 1 full clock cycle.
+//- The carry-out signal completes a full cycle for every 8 clock input cycles and is used as a ripple carry signal to any succeeding stages
+//- Pinalias: Q1,Q0,Q2,Q5,Q6,NC,Q3,VSS,NC,Q7,Q4,CARRY_OUT,CLOCK_ENABLE,CLOCK,RESET,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/166/108736_DS.pdf
+//-
+static NETLIST_START(CD4022_DIP)
+ CD4022(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.Q1, /* Q1 |1 ++ 16| VDD */ A.VDD,
+ A.Q0, /* Q0 |2 15| RESET */ A.RESET,
+ A.Q2, /* Q2 |3 14| CLOCK */ A.CLK,
+ A.Q5, /* Q5 |4 4022 13| CLOCK ENABLE */ A.CLKEN,
+ A.Q6, /* Q6 |5 12| CARRY OUT */ A.CO,
+ NC.I, /* NC |6 11| Q4 */ A.Q4,
+ A.Q3, /* Q3 |7 10| Q7 */ A.Q7,
+ A.VSS, /* VSS |8 9| NC */ NC.I
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: CD4024_DIP
+//- Title: CD4024BM/CD4024BC 7-Stage Ripple Carry Binary Counter
+//- Description: The CD4024BM/CD4024BC is a 7-stage ripple-carry binary counter.
+//- Buffered outputs are externally available from stages 1 through 7.
+//- The counter is reset to its logical 0 stage by a logical 1 on the reset input.
+//- The counter is advanced one count on the negative transition of each clock pulse.
+//- Pinalias: IP,RESET,Q7,Q6,Q5,Q4,VSS,NC,Q3,NC,Q2,Q1,NC,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/120/108894_DS.pdf
+//-
+static NETLIST_START(CD4024_DIP)
+ CD4024(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.IP, /* IP |1 ++ 14| VDD */ A.VDD,
+ A.RESET, /* RESET |2 13| NC */ NC.I,
+ A.Q7, /* Q7 |3 12| Q1 */ A.Q1,
+ A.Q6, /* Q6 |4 4024 11| Q2 */ A.Q2,
+ A.Q5, /* Q5 |5 10| NC */ NC.I,
+ A.Q4, /* Q4 |6 9| Q3 */ A.Q3,
+ A.VSS, /* VSS |7 8| NC */ NC.I
+ /* +--------------+ */)
+NETLIST_END()
+
+//- Identifier: CD4053_DIP
+//- Title: CD4053BM/CD4053BC Triple 2-Channel AnalogMultiplexer/Demultiplexer
+//- Description: These analog multiplexers/demultiplexers are digitally controlled analog switches having low ON impedance andvery low OFF leakage currents.
+//- Control of analog signalsup to 15V(p-p) can be achieved by digital signal amplitudes of 3–15V.
+//- For example, if VDD=5V, VSS=0V and VEE=-5V, analog signals from -5V to +5V can be controlled by digital inputs of 0–5V.
+//- The multiplexer circuits dissipate extremely low quiescent power over the full VDD-VSS and VDD-VEE supply voltage ranges, independent of the logic state of the control signals.
+//- When a logical 1 is present atthe inhibit input terminal all channels are OFF.
+//- CD4053BM/CD4053BC is a triple 2-channel multiplexer having three separate digital control inputs, A, B, and C, and an inhibit input.
+//- Each control input selects one of a pair of channels which are connected in a single-pole double-throw configuration.
+//- Pinalias: INOUTBY,INOUTBX,INOUTCY,OUTINC,INOUTCX,INH,VEE,VSS,C,B,A,INOUTAX,INOUTAY,OUTINA,OUTINB,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS005662.PDF
+//-
+static NETLIST_START(CD4053_DIP)
+ CD4053_GATE(A)
+ CD4053_GATE(B)
+ CD4053_GATE(C)
+
+ NET_C(A.VEE, B.VEE, C.VEE)
+ NET_C(A.VDD, B.VDD, C.VDD)
+ NET_C(A.VSS, B.VSS, C.VSS)
+ NET_C(A.INH, B.INH, C.INH)
+
+ PARAM(A.BASER, 270.0)
+ PARAM(B.BASER, 270.0)
+ PARAM(C.BASER, 270.0)
+
+ DIPPINS( /* +--------------+ */
+ B.Y, /* INOUTBY |1 ++ 16| VDD */ A.VDD,
+ B.X, /* INOUTBX |2 15| OUTINB */ B.XY,
+ C.Y, /* INOUTCY |3 14| OUTINA */ A.XY,
+ C.XY, /* OUTINC |4 4053 13| INOUTAY */ A.Y,
+ C.X, /* INOUTCX |5 12| INOUTAX */ A.X,
+ A.INH, /* INH |6 11| A */ A.S,
+ A.VEE, /* VEE |7 10| B */ B.S,
+ A.VSS, /* VSS |8 9| C */ C.S
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: CD4066_DIP
+//- Title: CD4066BM/CD4066BC Quad Bilateral Switch
+//- Description: The CD4066BM/CD4066BC is a quad bilateral switch intended for the transmission or multiplexing of analog or digital signals.
+//- It is pin-for-pin compatible with CD4016BM/CD4016BC, but has a much lower ON resistance, and ON resistance is relatively constant over the input-signal range.
+//- Pinalias: INOUTA,OUTINA,OUTINB,INOUTB,CONTROLB,CONTROLC,VSS,INOUTC,OUTINC,OUTIND,INOUTD,CONTROLD,CONTROLA,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS005665.PDF
+//-
+static NETLIST_START(CD4066_DIP)
CD4066_GATE(A)
CD4066_GATE(B)
CD4066_GATE(C)
@@ -131,38 +371,35 @@ static NETLIST_START(CD4016_DIP)
NET_C(A.VDD, B.VDD, C.VDD, D.VDD)
NET_C(A.VSS, B.VSS, C.VSS, D.VSS)
- PARAM(A.BASER, 1000.0)
- PARAM(B.BASER, 1000.0)
- PARAM(C.BASER, 1000.0)
- PARAM(D.BASER, 1000.0)
+ PARAM(A.BASER, 270.0)
+ PARAM(B.BASER, 270.0)
+ PARAM(C.BASER, 270.0)
+ PARAM(D.BASER, 270.0)
- DIPPINS( /* +--------------+ */
- A.R.1, /* INOUTA |1 ++ 14| VDD */ A.VDD,
- A.R.2, /* OUTINA |2 13| CONTROLA */ A.CTL,
- B.R.1, /* OUTINB |3 12| CONTROLD */ D.CTL,
- B.R.2, /* INOUTB |4 4016 11| INOUTD */ D.R.1,
- B.CTL, /* CONTROLB |5 10| OUTIND */ D.R.2,
- C.CTL, /* CONTROLC |6 9| OUTINC */ C.R.1,
- A.VSS, /* VSS |7 8| INOUTC */ C.R.2
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.R.1, /* INOUTA |1 ++ 14| VDD */ A.VDD,
+ A.R.2, /* OUTINA |2 13| CONTROLA */ A.CTL,
+ B.R.1, /* OUTINB |3 12| CONTROLD */ D.CTL,
+ B.R.2, /* INOUTB |4 4066 11| INOUTD */ D.R.1,
+ B.CTL, /* CONTROLB |5 10| OUTIND */ D.R.2,
+ C.CTL, /* CONTROLC |6 9| OUTINC */ C.R.1,
+ A.VSS, /* VSS |7 8| INOUTC */ C.R.2
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * CD4069: Hex Inverter
- * _
- * Y = A
- * +---++---+
- * | A || Y |
- * +===++===+
- * | 0 || 1 |
- * | 1 || 0 |
- * +---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: CD4069_DIP
+//- Title: CD4069UBM/CD4069UBC Inverter Circuits
+//- Description: The CD4069UB consists of six inverter circuits and is manufactured using complementary MOS (CMOS) to achieve wide power supply operating range, low power consumption, high noise immunity, and symmetric controlled rise and fall times.
+//- This device is intended for all general purpose inverter applications where the special characteristics of the MM74C901, MM74C903, MM74C907, and CD4049A Hex Inverter/Buffers are not required.
+//- In those applications requiring larger noise immunity the MM74C14 or MM74C914 Hex Schmitt Trigger is suggested.
+//- All inputs are protected from damage due to static discharge by diode clamps to VDD and VSS.
+//- Pinalias: A1,Y1,A2,Y2,A3,Y3,VSS,Y4,A4,Y5,A5,Y6,A6,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/150/206783_DS.pdf
+//-
static NETLIST_START(CD4069_DIP)
CD4069_GATE(A)
CD4069_GATE(B)
@@ -171,36 +408,33 @@ static NETLIST_START(CD4069_DIP)
CD4069_GATE(E)
CD4069_GATE(F)
- NET_C(A.VDD, B.VDD, C.VDD, D.VDD, E.VDD, E.VDD)
+ NET_C(A.VDD, B.VDD, C.VDD, D.VDD, E.VDD, F.VDD)
NET_C(A.VSS, B.VSS, C.VSS, D.VSS, E.VSS, F.VSS)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VDD */ A.VDD,
- A.Q, /* Y1 |2 13| A6 */ F.A,
- B.A, /* A2 |3 12| Y6 */ F.Q,
- B.Q, /* Y2 |4 4069 11| A5 */ E.A,
- C.A, /* A3 |5 10| Y5 */ E.Q,
- C.Q, /* Y3 |6 9| A4 */ D.A,
- A.VSS,/* VSS |7 8| Y4 */ D.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VDD */ A.VDD,
+ A.Q, /* Y1 |2 13| A6 */ F.A,
+ B.A, /* A2 |3 12| Y6 */ F.Q,
+ B.Q, /* Y2 |4 4069 11| A5 */ E.A,
+ C.A, /* A3 |5 10| Y5 */ E.Q,
+ C.Q, /* Y3 |6 9| A4 */ D.A,
+ A.VSS, /* VSS |7 8| Y4 */ D.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * CD4070: Quad 2-Input Exclusive-OR Gates
- *
- * Y = A+B
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 0 |
- * | 0 | 1 || 1 |
- * | 1 | 0 || 1 |
- * | 1 | 1 || 0 |
- * +---+---++---+
- *
- */
-
+//- Identifier: CD4070_DIP
+//- Title: CD4070BM/CD4070BC Quad 2-Input EXCLUSIVE-OR Gate
+//- Description: Employing complementary MOS (CMOS) transistors to achieve wide power supply operating range, low power consumption, and high noise margin, the CD4070BM/BC provides basic functions used in the implementation of digital integrated circuit systems.
+//- The N- and P-channel enhancement mode transistors provide a symmetrical circuit with output swing essentially equal to the supply voltage.
+//- No DC power other than that caused by leakage current is consumed during static condition.
+//- All inputs are protected from damage due to static discharge by diode clamps to VDD and VSS.
+//- Pinalias: A,B,J,K,C,D,VSS,E,F,L,M,G,H,VDD
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/150/206783_DS.pdf
+//-
static NETLIST_START(CD4070_DIP)
CD4070_GATE(A)
CD4070_GATE(B)
@@ -210,19 +444,37 @@ static NETLIST_START(CD4070_DIP)
NET_C(A.VDD, B.VDD, C.VDD, D.VDD)
NET_C(A.VSS, B.VSS, C.VSS, D.VSS)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VDD */ A.VDD,
- A.B, /* B1 |2 13| B4 */ D.B,
- A.Q, /* Y1 |3 12| A4 */ D.A,
- B.Q, /* Y2 |4 4070 11| Y4 */ D.Q,
- B.A, /* A2 |5 10| Y3 */ C.Q,
- B.B, /* B2 |6 9| B3 */ C.B,
- A.VSS,/* VSS |7 8| A3 */ C.A
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A |1 ++ 14| VDD */ A.VDD,
+ A.B, /* B |2 13| H */ D.B,
+ A.Q, /* J |3 12| G */ D.A,
+ B.Q, /* K |4 4070 11| M */ D.Q,
+ B.A, /* C |5 10| L */ C.Q,
+ B.B, /* D |6 9| F */ C.B,
+ A.VSS, /* VSS |7 8| E */ C.A
+ /* +--------------+ */
)
NETLIST_END()
-
+//- Identifier: CD4316_DIP
+//- Title: 74HC/HCT4316 Quad bilateral switches
+//- Description: The 74HC/HCT4316 are high-speed Si-gate CMOS devices.
+//- They are specified in compliance with JEDEC standard no. 7A.
+//- The 74HC/HCT4316 have four independent analog switches.
+//- Each switch has two input/output terminals (nY, nZ) and an active HIGH select input (nS).
+//- When the enable input (E) is HIGH, all four analog switches are turned off.
+//- Current through a switch will not cause additional VCC current provided the voltage at the terminals of the switch is maintained within the supply voltage range; VCC >> (VY, VZ) >> VEE.
+//- Inputs nY and nZ are electrically equivalent terminals.
+//- VCC and GND are the supply voltage pins for the digital control inputs (EQ and nS).
+//- The VCC to GND ranges are 2.0 to 10.0V for HC and 4.5 to 5.5V for HCT.
+//- The analog inputs/outputs (nY and nZ) can swing between VCC as a positive limit and VEE as a negative limit.
+//- VCC−VEE may not exceed 10.0 V
+//- Pinalias: 1Z,1Y,2Y,2Z,2S,3S,EQ,GND,VEE,3Z,3Y,4Y,4Z,4S,1S,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Philips datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/philips/74HCT4316.pdf
+//-
static NETLIST_START(CD4316_DIP)
CD4316_GATE(A)
CD4316_GATE(B)
@@ -238,18 +490,17 @@ static NETLIST_START(CD4316_DIP)
PARAM(C.BASER, 45.0)
PARAM(D.BASER, 45.0)
- DIPPINS( /* +--------------+ */
- A.R.2, /* 1Z |1 ++ 16| VCC */ A.VDD,
- A.R.1, /* 1Y |2 15| 1S */ A.S,
- B.R.1, /* 2Y |3 14| 4S */ D.S,
- B.R.2, /* 2Z |4 4316 13| 4Z */ D.R.2,
- B.S, /* 2S |5 12| 4Y */ D.R.1,
- C.S, /* 3S |6 11| 3Y */ C.R.1,
- A.E, /* /E |7 10| 3Z */ C.R.2,
- A.VSS, /* GND |8 9| VEE */ VEE
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.R.2, /* 1Z |1 ++ 16| VCC */ A.VDD,
+ A.R.1, /* 1Y |2 15| 1S */ A.S,
+ B.R.1, /* 2Y |3 14| 4S */ D.S,
+ B.R.2, /* 2Z |4 4316 13| 4Z */ D.R.2,
+ B.S, /* 2S |5 12| 4Y */ D.R.1,
+ C.S, /* 3S |6 11| 3Y */ C.R.1,
+ A.E, /* EQ |7 10| 3Z */ C.R.2,
+ A.VSS, /* GND |8 9| VEE */ VEE
+ /* +--------------+ */
)
-
NETLIST_END()
//- Identifier: CD4538_DIP
@@ -281,30 +532,23 @@ NETLIST_END()
//- https://pdf1.alldatasheet.com/datasheet-pdf/view/50871/FAIRCHILD/CD4538.html
//-
static NETLIST_START(CD4538_DIP)
-
CD4538(A)
CD4538(B)
- ALIAS(1, A.C) // C1
- ALIAS(2, A.RC) // RC1
- ALIAS(3, A.CLRQ)
- ALIAS(4, A.A)
- ALIAS(5, A.B)
- ALIAS(6, A.Q)
- ALIAS(7, A.QQ)
- ALIAS(8, A.VSS)
-
- ALIAS(9, B.QQ)
- ALIAS(10, B.Q)
- ALIAS(11, B.B)
- ALIAS(12, B.A)
- ALIAS(13, B.CLRQ)
- ALIAS(14, B.RC) // RC2
- ALIAS(15, B.C) // C2
- ALIAS(16, A.VDD)
-
NET_C(A.VDD, B.VDD)
NET_C(A.VSS, B.VSS)
+
+ DIPPINS( /* +--------------+ */
+ A.C, /* 1Z |1 ++ 16| VCC */ A.VDD,
+ A.RC, /* 1Y |2 15| 1S */ B.C,
+ A.CLRQ, /* 2Y |3 14| 4S */ B.RC,
+ A.A, /* 2Z |4 4316 13| 4Z */ B.CLRQ,
+ A.B, /* 2S |5 12| 4Y */ B.A,
+ A.Q, /* 3S |6 11| 3Y */ B.B,
+ A.QQ, /* EQ |7 10| 3Z */ B.Q,
+ A.VSS, /* GND |8 9| VEE */ B.QQ
+ /* +--------------+ */
+ )
NETLIST_END()
@@ -318,6 +562,14 @@ NETLIST_START(CD4XXX_lib)
TT_FAMILY("CD4XXX")
TRUTHTABLE_END()
+ TRUTHTABLE_START(CD4011_GATE, 2, 1, "")
+ TT_HEAD("A,B|Q ")
+ TT_LINE("0,X|1|100")
+ TT_LINE("X,0|1|100")
+ TT_LINE("1,1|0|100")
+ TT_FAMILY("CD4XXX")
+ TRUTHTABLE_END()
+
TRUTHTABLE_START(CD4069_GATE, 1, 1, "")
TT_HEAD("A|Q ")
TT_LINE("0|1|55")
@@ -335,13 +587,20 @@ NETLIST_START(CD4XXX_lib)
TRUTHTABLE_END()
LOCAL_LIB_ENTRY(CD4001_DIP)
+ LOCAL_LIB_ENTRY(CD4011_DIP)
LOCAL_LIB_ENTRY(CD4069_DIP)
LOCAL_LIB_ENTRY(CD4070_DIP)
/* DIP ONLY */
+ LOCAL_LIB_ENTRY(CD4006_DIP)
+ LOCAL_LIB_ENTRY(CD4013_DIP)
+ LOCAL_LIB_ENTRY(CD4017_DIP)
+ LOCAL_LIB_ENTRY(CD4022_DIP)
LOCAL_LIB_ENTRY(CD4020_DIP)
- LOCAL_LIB_ENTRY(CD4016_DIP)
+ LOCAL_LIB_ENTRY(CD4024_DIP)
+ LOCAL_LIB_ENTRY(CD4053_DIP)
LOCAL_LIB_ENTRY(CD4066_DIP)
+ LOCAL_LIB_ENTRY(CD4016_DIP)
LOCAL_LIB_ENTRY(CD4316_DIP)
LOCAL_LIB_ENTRY(CD4538_DIP)
diff --git a/src/lib/netlist/macro/nlm_cd4xxx.h b/src/lib/netlist/macro/nlm_cd4xxx.h
index ba90ad0fe64..d6ecade6658 100644
--- a/src/lib/netlist/macro/nlm_cd4xxx.h
+++ b/src/lib/netlist/macro/nlm_cd4xxx.h
@@ -13,8 +13,11 @@
*
* CD4001_NOR : single gate
* CD4001_DIP : dip package
+ * CD4013_DIP : dip package (device model in core)
* CD4020_DIP : dip package (device model in core)
+ * CD4024_DIP : dip package (device model in core)
* CD4016_DIP : dip package (device model in core)
+ * CD4053_DIP : dip package (device model in core)
* CD4066_DIP : dip package (device model in core)
*
*/
@@ -33,6 +36,12 @@
#define CD4001_DIP(name) \
NET_REGISTER_DEV(CD4001_DIP, name)
+#define CD4011_GATE(name) \
+ NET_REGISTER_DEV(CD4011_GATE, name)
+
+#define CD4011_DIP(name) \
+ NET_REGISTER_DEV(CD4011_DIP, name)
+
#define CD4069_GATE(name) \
NET_REGISTER_DEV(CD4069_GATE, name)
@@ -49,9 +58,27 @@
* DIP only macros
* ---------------------------------------------------------------------------*/
+#define CD4006_DIP(name) \
+ NET_REGISTER_DEV(CD4006_DIP, name)
+
+#define CD4013_DIP(name) \
+ NET_REGISTER_DEV(CD4013_DIP, name)
+
+#define CD4017_DIP(name) \
+ NET_REGISTER_DEV(CD4017_DIP, name)
+
+#define CD4022_DIP(name) \
+ NET_REGISTER_DEV(CD4022_DIP, name)
+
#define CD4020_DIP(name) \
NET_REGISTER_DEV(CD4020_DIP, name)
+#define CD4024_DIP(name) \
+ NET_REGISTER_DEV(CD4024_DIP, name)
+
+#define CD4053_DIP(name) \
+ NET_REGISTER_DEV(CD4053_DIP, name)
+
#define CD4066_DIP(name) \
NET_REGISTER_DEV(CD4066_DIP, name)
@@ -64,13 +91,14 @@
#define CD4538_DIP(name) \
NET_REGISTER_DEV(CD4538_DIP, name)
-#endif
+#endif // !NL_AUTO_DEVICES
+
/* ----------------------------------------------------------------------------
* External declarations
* ---------------------------------------------------------------------------*/
-NETLIST_EXTERNAL(CD4XXX_lib)
+// moved to net_lib.h
#endif
-#endif
+#endif // NLD_CD4XXX_H_
diff --git a/src/lib/netlist/macro/nlm_opamp.h b/src/lib/netlist/macro/nlm_opamp.h
index 06c31acc71b..eefb95b478d 100644
--- a/src/lib/netlist/macro/nlm_opamp.h
+++ b/src/lib/netlist/macro/nlm_opamp.h
@@ -60,7 +60,7 @@
* External declarations
* ---------------------------------------------------------------------------*/
-NETLIST_EXTERNAL(OPAMP_lib)
+// moved to net_lib.h
#endif // __PLIB_PREPROCESSOR__
diff --git a/src/lib/netlist/macro/nlm_other.h b/src/lib/netlist/macro/nlm_other.h
index b028d829e4b..c69b4d61224 100644
--- a/src/lib/netlist/macro/nlm_other.h
+++ b/src/lib/netlist/macro/nlm_other.h
@@ -33,7 +33,7 @@
* External declarations
* ---------------------------------------------------------------------------*/
-NETLIST_EXTERNAL(otheric_lib)
+// moved to net_lib.h
#endif
diff --git a/src/lib/netlist/macro/nlm_roms.cpp b/src/lib/netlist/macro/nlm_roms.cpp
index e5d6cdc7d06..30bd4b98e06 100644
--- a/src/lib/netlist/macro/nlm_roms.cpp
+++ b/src/lib/netlist/macro/nlm_roms.cpp
@@ -185,6 +185,27 @@ static NETLIST_START(PROM_82S123_DIP)
ALIAS(16, A.VCC)
NETLIST_END()
+/*
+ * nld_82S16.h
+ *
+ * DM82S16: 256 Bit bipolar ram
+ *
+ * +--------------+
+ * A1 |1 ++ 16| VCC
+ * A0 |2 15| A2
+ * CE1Q |3 14| A3
+ * CE2Q |4 82S16 13| DIN
+ * CE3Q |5 12| WEQ
+ * DOUTQ |6 11| A7
+ * A4 |7 10| A6
+ * GND |8 9| A5
+ * +--------------+
+ *
+ *
+ * Naming conventions follow Signetics datasheet
+ */
+
+
//- Identifier: EPROM_2716_DIP
//- Title: 2716 16K (2K x 8) UV ERASABLE PROM
//- Description: The Intel®2716 is a 16,384-bit ultraviolet erasable and
@@ -263,6 +284,107 @@ static NETLIST_START(EPROM_2716_DIP)
ALIAS(24, A.VCC)
NETLIST_END()
+/* DM82S16: 256 Bit bipolar ram
+ *
+ * +--------------+
+ * A1 |1 ++ 16| VCC
+ * A0 |2 15| A2
+ * CE1Q |3 14| A3
+ * CE2Q |4 82S16 13| DIN
+ * CE3Q |5 12| WEQ
+ * DOUTQ |6 11| A7
+ * A4 |7 10| A6
+ * GND |8 9| A5
+ * +--------------+
+ *
+ * Naming conventions follow Signetics datasheet
+ */
+
+static NETLIST_START(TTL_82S16_DIP)
+ TTL_82S16(A)
+
+ DIPPINS( /* +--------------+ */
+ A.A1, /* A1 |1 ++ 16| VCC */ A.VCC,
+ A.A0, /* A0 |2 15| A2 */ A.A2,
+ A.CE1Q, /* CE1Q |3 14| A3 */ A.A3,
+ A.CE2Q, /* CE2Q |4 82S16 13| DIN */ A.DIN,
+ A.CE3Q, /* CE3Q |5 12| WEQ */ A.WEQ,
+ A.DOUTQ, /* DOUTQ |6 11| A7 */ A.A7,
+ A.A4, /* A4 |7 10| A6 */ A.A6,
+ A.GND, /* GND |8 9| A5 */ A.A5
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+/* 82S115: 4K-bit TTL bipolar PROM (512 x 8)
+ *
+ * +--------------+
+ * A3 |1 ++ 24| VCC
+ * A4 |2 23| A2
+ * A5 |3 22| A1
+ * A6 |4 82S115 21| A0
+ * A7 |5 20| CE1Q
+ * A8 |6 19| CE2
+ * O1 |7 18| STROBE
+ * O2 |8 17| O8
+ * O3 |9 16| O7
+ * O4 |10 15| O6
+ * FE2 |11 14| O5
+ * GND |12 13| FE1
+ * +--------------+
+ */
+
+static NETLIST_START(PROM_82S115_DIP)
+ PROM_82S115(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.A3, /* A3 |1 ++ 24| VCC */ A.VCC,
+ A.A4, /* A4 |2 23| A2 */ A.A2,
+ A.A5, /* A5 |3 22| A1 */ A.A1,
+ A.A6, /* A6 |4 82S115 21| A0 */ A.A0,
+ A.A7, /* A7 |5 20| CE1Q */ A.CE1Q,
+ A.A8, /* A8 |6 19| CE2 */ A.CE2,
+ A.O1, /* O1 |7 18| STROBE */ A.STROBE,
+ A.O2, /* O2 |8 17| O8 */ A.O8,
+ A.O3, /* O3 |9 16| O7 */ A.O7,
+ A.O4, /* O4 |10 15| O6 */ A.O6,
+ NC.I, /* FE2 |11 14| O5 */ A.O5,
+ A.GND, /* GND |12 13| FE1 */ NC.I
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+/* 2102: 1024 x 1-bit Static RAM
+ *
+ * +--------------+
+ * A6 |1 ++ 16| A7
+ * A5 |2 15| A8
+ * RWQ |3 14| A9
+ * A1 |4 82S16 13| CEQ
+ * A2 |5 12| DO
+ * A3 |6 11| DI
+ * A4 |7 10| VCC
+ * A0 |8 9| GND
+ * +--------------+
+ */
+
+ static NETLIST_START(RAM_2102A_DIP)
+ RAM_2102A(A)
+
+ DIPPINS( /* +--------------+ */
+ A.A6, /* A6 |1 ++ 16| A7 */ A.A7,
+ A.A5, /* A5 |2 15| A8 */ A.A8,
+ A.RWQ, /* RWQ |3 14| A9 */ A.A9,
+ A.A1, /* A1 |4 82S16 13| CEQ */ A.CEQ,
+ A.A2, /* A2 |5 12| DO */ A.DO,
+ A.A3, /* A3 |6 11| DI */ A.DI,
+ A.A4, /* A4 |7 10| VCC */ A.VCC,
+ A.A0, /* A0 |8 9| GND */ A.GND
+ /* +--------------+ */
+ )
+NETLIST_END()
+
NETLIST_START(ROMS_lib)
@@ -270,6 +392,9 @@ NETLIST_START(ROMS_lib)
LOCAL_LIB_ENTRY(PROM_82S126_DIP)
LOCAL_LIB_ENTRY(PROM_74S287_DIP)
LOCAL_LIB_ENTRY(EPROM_2716_DIP)
+ LOCAL_LIB_ENTRY(TTL_82S16_DIP)
+ LOCAL_LIB_ENTRY(PROM_82S115_DIP)
+ LOCAL_LIB_ENTRY(RAM_2102A_DIP)
NETLIST_END()
diff --git a/src/lib/netlist/macro/nlm_roms.h b/src/lib/netlist/macro/nlm_roms.h
index 1900e693e04..ab754f34c86 100644
--- a/src/lib/netlist/macro/nlm_roms.h
+++ b/src/lib/netlist/macro/nlm_roms.h
@@ -18,6 +18,9 @@
#if !NL_AUTO_DEVICES
+#define PROM_82S115_DIP(name) \
+ NET_REGISTER_DEV(PROM_82S115_DIP, name)
+
#define PROM_82S126_DIP(name) \
NET_REGISTER_DEV(PROM_82S126_DIP, name)
@@ -30,6 +33,13 @@
#define EPROM_2716_DIP(name) \
NET_REGISTER_DEV(EPROM_2716_DIP, name)
+// usage : TTL_82S16_DIP(name)
+#define TTL_82S16_DIP(...) \
+ NET_REGISTER_DEVEXT(TTL_82S16_DIP, __VA_ARGS__)
+
+#define RAM_2102A_DIP(name) \
+ NET_REGISTER_DEV(RAM_2102A_DIP, name)
+
#endif // NL_AUTO_DEVICES
@@ -37,7 +47,7 @@
* External declarations
* ---------------------------------------------------------------------------*/
-NETLIST_EXTERNAL(ROMS_lib)
+// moved to net_lib.h
#endif // __PLIB_PREPROCESSOR__
diff --git a/src/lib/netlist/macro/nlm_ttl74xx.cpp b/src/lib/netlist/macro/nlm_ttl74xx.cpp
index 4c51e01055b..5c3529e22b5 100644
--- a/src/lib/netlist/macro/nlm_ttl74xx.cpp
+++ b/src/lib/netlist/macro/nlm_ttl74xx.cpp
@@ -3,24 +3,38 @@
#include "netlist/devices/net_lib.h"
-/*
- * DM7400: Quad 2-Input NAND Gates
- *
- * _
- * Y = AB
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 1 |
- * | 0 | 1 || 1 |
- * | 1 | 0 || 1 |
- * | 1 | 1 || 0 |
- * +---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
+#ifndef NL_USE_TRUTHTABLE_74107
+#define NL_USE_TRUTHTABLE_74107 0
+#endif
+
+#ifndef NL_USE_TRUTHTABLE_7448
+#define NL_USE_TRUTHTABLE_7448 0
+#endif
+
+#if 1
+//
+#elif %&/()
+//
+#endif
+//- Identifier: TTL_7400_DIP
+//- Title: 5400/DM5400/DM7400 Quad 2-Input NAND Gates
+//- Description: This device contains four independent gates each of which performs the logic NAND function.
+//- Pinalias: A1,B1,Y1,A2,B2,Y2,GND,Y3,A3,B3,Y4,A4,B4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006613.PDF
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 1 |
+//- | 0 | 1 || 1 |
+//- | 1 | 0 || 1 |
+//- | 1 | 1 || 0 |
+//- +---+---++---+
+//-
static NETLIST_START(TTL_7400_DIP)
TTL_7400_GATE(A)
TTL_7400_GATE(B)
@@ -30,35 +44,36 @@ static NETLIST_START(TTL_7400_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| B4 */ D.B,
- A.Q, /* Y1 |3 12| A4 */ D.A,
- B.A, /* A2 |4 7400 11| Y4 */ D.Q,
- B.B, /* B2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| B4 */ D.B,
+ A.Q, /* Y1 |3 12| A4 */ D.A,
+ B.A, /* A2 |4 7400 11| Y4 */ D.Q,
+ B.B, /* B2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7402: Quad 2-Input NOR Gates
- *
- * Y = A+B
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 1 |
- * | 0 | 1 || 0 |
- * | 1 | 0 || 0 |
- * | 1 | 1 || 0 |
- * +---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7402_DIP
+//- Title: 5402/DM5402/DM7402 Quad 2-Input NOR Gates
+//- Description: This device contains four independent gates each of which performs the logic NOR function.
+//- Pinalias: Y1,A1,B1,Y2,A2,B2,GND,A3,B3,Y3,A4,B4,Y4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006492.PDF
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 1 |
+//- | 0 | 1 || 0 |
+//- | 1 | 0 || 0 |
+//- | 1 | 1 || 0 |
+//- +---+---++---+
+//-
static NETLIST_START(TTL_7402_DIP)
TTL_7402_GATE(A)
TTL_7402_GATE(B)
@@ -68,33 +83,34 @@ static NETLIST_START(TTL_7402_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.Q, /* Y1 |1 ++ 14| VCC */ A.VCC,
- A.A, /* A1 |2 13| Y4 */ D.Q,
- A.B, /* B1 |3 12| B4 */ D.B,
- B.Q, /* Y2 |4 7402 11| A4 */ D.A,
- B.A, /* A2 |5 10| Y3 */ C.Q,
- B.B, /* B2 |6 9| B3 */ C.B,
- A.GND,/* GND |7 8| A3 */ C.A
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.Q, /* Y1 |1 ++ 14| VCC */ A.VCC,
+ A.A, /* A1 |2 13| Y4 */ D.Q,
+ A.B, /* B1 |3 12| B4 */ D.B,
+ B.Q, /* Y2 |4 7402 11| A4 */ D.A,
+ B.A, /* A2 |5 10| Y3 */ C.Q,
+ B.B, /* B2 |6 9| B3 */ C.B,
+ A.GND, /* GND |7 8| A3 */ C.A
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7404: Hex Inverting Gates
- *
- * Y = A
- * +---++---+
- * | A || Y |
- * +===++===+
- * | 0 || 1 |
- * | 1 || 0 |
- * +---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7404_DIP
+//- Title: 5404/DM5404/DM7404 Hex Inverting Gates
+//- Description: This device contains six independent gates each of which performs the logic INVERT function.
+//- Pinalias: A1,Y1,A2,Y2,A3,Y3,GND,Y4,A4,Y5,A5,Y6,A6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006494.PDF
+//-
+//- +---++---+
+//- | A || Y |
+//- +===++===+
+//- | 0 || 1 |
+//- | 1 || 0 |
+//- +---++---+
+//-
static NETLIST_START(TTL_7404_DIP)
TTL_7404_GATE(A)
TTL_7404_GATE(B)
@@ -106,26 +122,36 @@ static NETLIST_START(TTL_7404_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC, E.VCC, F.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND, E.GND, F.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.Q, /* Y1 |2 13| A6 */ F.A,
- B.A, /* A2 |3 12| Y6 */ F.Q,
- B.Q, /* Y2 |4 7404 11| A5 */ E.A,
- C.A, /* A3 |5 10| Y5 */ E.Q,
- C.Q, /* Y3 |6 9| A4 */ D.A,
- A.GND,/* GND |7 8| Y4 */ D.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.Q, /* Y1 |2 13| A6 */ F.A,
+ B.A, /* A2 |3 12| Y6 */ F.Q,
+ B.Q, /* Y2 |4 7404 11| A5 */ E.A,
+ C.A, /* A3 |5 10| Y5 */ E.Q,
+ C.Q, /* Y3 |6 9| A4 */ D.A,
+ A.GND, /* GND |7 8| Y4 */ D.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7406: Hex Inverting Buffers with
- * High Voltage Open-Collector Outputs
- *
- * Naming conventions follow Fairchild Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7406_DIP
+//- Title: DM5406/DM7406 Hex Inverting Buffers with High Voltage Open-Collector Outputs
+//- Description: This device contains six independent buffers each of which performs the logic INVERT function.
+//- The open-collector outputs require external pull-up resistors for proper logical operation.
+//- Pinalias: A1,Y1,A2,Y2,A3,Y3,GND,Y4,A4,Y5,A5,Y6,A6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- Limitations: Open collector behavior currently not simulated.
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006496.PDF
+//-
+//- +---++---+
+//- | A || Y |
+//- +===++===+
+//- | 0 || 1 |
+//- | 1 || 0 |
+//- +---++---+
+//-
static NETLIST_START(TTL_7406_DIP)
TTL_7406_GATE(A)
TTL_7406_GATE(B)
@@ -137,11 +163,52 @@ static NETLIST_START(TTL_7406_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC, E.VCC, F.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND, E.GND, F.GND)
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.Y, /* Y1 |2 13| A6 */ F.A,
+ B.A, /* A2 |3 12| Y6 */ F.Y,
+ B.Y, /* Y2 |4 7406 11| A5 */ E.A,
+ C.A, /* A3 |5 10| Y5 */ E.Y,
+ C.Y, /* Y3 |6 9| A4 */ D.A,
+ A.GND, /* GND |7 8| Y4 */ D.Y
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7407_DIP
+//- Title: DM5407/DM7407 Hex Buffers with High Voltage Open-Collector Outputs
+//- Description: This device contains six independent gates each of which performs a buffer function.
+//- The open-collector outputs re-quire external pull-up resistors for proper logical operation.
+//- Pinalias: A1,Y1,A2,Y2,A3,Y3,GND,Y4,A4,Y5,A5,Y6,A6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- Limitations: Open collector behavior currently not simulated.
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006497.PDF
+//-
+//- +---++---+
+//- | A || Y |
+//- +===++===+
+//- | 0 || 0 |
+//- | 1 || 1 |
+//- +---++---+
+//-
+static NETLIST_START(TTL_7407_DIP)
+ TTL_7407_GATE(A)
+ TTL_7407_GATE(B)
+ TTL_7407_GATE(C)
+ TTL_7407_GATE(D)
+ TTL_7407_GATE(E)
+ TTL_7407_GATE(F)
+
+ NET_C(A.VCC, B.VCC, C.VCC, D.VCC, E.VCC, F.VCC)
+ NET_C(A.GND, B.GND, C.GND, D.GND, E.GND, F.GND)
+
DIPPINS( /* +--------------+ */
A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
A.Y, /* Y1 |2 13| A6 */ F.A,
B.A, /* A2 |3 12| Y6 */ F.Y,
- B.Y, /* Y2 |4 7406 11| A5 */ E.A,
+ B.Y, /* Y2 |4 7407 11| A5 */ E.A,
C.A, /* A3 |5 10| Y5 */ E.Y,
C.Y, /* Y3 |6 9| A4 */ D.A,
A.GND,/* GND |7 8| Y4 */ D.Y
@@ -149,24 +216,24 @@ static NETLIST_START(TTL_7406_DIP)
)
NETLIST_END()
-/*
- * DM7408: Quad 2-Input AND Gates
- *
- *
- * Y = AB
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 0 |
- * | 0 | 1 || 0 |
- * | 1 | 0 || 0 |
- * | 1 | 1 || 1 |
- * +---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7408_DIP
+//- Title: 5408/DM5408/DM7408 Quad 2-Input AND Gates
+//- Description: This device contains four independent gates each of which performs the logic AND function.
+//- Pinalias: A1,B1,Y1,A2,B2,Y2,GND,Y3,A3,B3,Y4,A4,B4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006498.PDF
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 0 |
+//- | 0 | 1 || 0 |
+//- | 1 | 0 || 0 |
+//- | 1 | 1 || 1 |
+//- +---+---++---+
+//-
static NETLIST_START(TTL_7408_DIP)
TTL_7408_GATE(A)
TTL_7408_GATE(B)
@@ -176,35 +243,36 @@ static NETLIST_START(TTL_7408_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| B4 */ D.B,
- A.Q, /* Y1 |3 12| A4 */ D.A,
- B.A, /* A2 |4 7400 11| Y4 */ D.Q,
- B.B, /* B2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| B4 */ D.B,
+ A.Q, /* Y1 |3 12| A4 */ D.A,
+ B.A, /* A2 |4 7408 11| Y4 */ D.Q,
+ B.B, /* B2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7410: Triple 3-Input NAND Gates
- * __
- * Y = ABC
- * +---+---+---++---+
- * | A | B | C || Y |
- * +===+===+===++===+
- * | X | X | 0 || 1 |
- * | X | 0 | X || 1 |
- * | 0 | X | X || 1 |
- * | 1 | 1 | 1 || 0 |
- * +---+---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7410_DIP
+//- Title: 5410/DM5410/DM7410 Triple 3-Input NAND Gates
+//- Description: This device contains three independent gates each of which performs the logic NAND function.
+//- Pinalias: A1,B1,A2,B2,C2,Y2,GND,Y3,A3,B3,C3,Y1,C1,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006500.PDF
+//-
+//- +---+---+---++---+
+//- | A | B | C || Y |
+//- +===+===+===++===+
+//- | X | X | 0 || 1 |
+//- | X | 0 | X || 1 |
+//- | 0 | X | X || 1 |
+//- | 1 | 1 | 1 || 0 |
+//- +---+---+---++---+
+//-
static NETLIST_START(TTL_7410_DIP)
TTL_7410_GATE(A)
TTL_7410_GATE(B)
@@ -213,35 +281,36 @@ static NETLIST_START(TTL_7410_DIP)
NET_C(A.VCC, B.VCC, C.VCC)
NET_C(A.GND, B.GND, C.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| C1 */ A.C,
- B.A, /* A2 |3 12| Y1 */ A.Q,
- B.B, /* B2 |4 7410 11| C3 */ C.C,
- B.C, /* C2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| C1 */ A.C,
+ B.A, /* A2 |3 12| Y1 */ A.Q,
+ B.B, /* B2 |4 7410 11| C3 */ C.C,
+ B.C, /* C2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7411: Triple 3-Input AND Gates
- *
- * Y = ABC
- * +---+---+---++---+
- * | A | B | C || Y |
- * +===+===+===++===+
- * | X | X | 0 || 0 |
- * | X | 0 | X || 0 |
- * | 0 | X | X || 0 |
- * | 1 | 1 | 1 || 1 |
- * +---+---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7411_DIP
+//- Title: DM7411 Triple 3-Input AND Gate
+//- Description: This device contains three independent gates with three data inputs each which perform the logic AND function.
+//- Pinalias: A1,B1,A2,B2,C2,Y2,GND,Y3,A3,B3,C3,Y1,C1,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009774.PDF
+//-
+//- +---+---+---++---+
+//- | A | B | C || Y |
+//- +===+===+===++===+
+//- | X | X | 0 || 0 |
+//- | X | 0 | X || 0 |
+//- | 0 | X | X || 0 |
+//- | 1 | 1 | 1 || 1 |
+//- +---+---+---++---+
+//-
static NETLIST_START(TTL_7411_DIP)
TTL_7411_GATE(A)
TTL_7411_GATE(B)
@@ -250,24 +319,36 @@ static NETLIST_START(TTL_7411_DIP)
NET_C(A.VCC, B.VCC, C.VCC)
NET_C(A.GND, B.GND, C.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| C1 */ A.C,
- B.A, /* A2 |3 12| Y1 */ A.Q,
- B.B, /* B2 |4 7411 11| C3 */ C.C,
- B.C, /* C2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| C1 */ A.C,
+ B.A, /* A2 |3 12| Y1 */ A.Q,
+ B.B, /* B2 |4 7411 11| C3 */ C.C,
+ B.C, /* C2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7414/DM74LS14: Hex Inverter with
- * Schmitt Trigger Inputs
- *
- */
-
+//- Identifier: TTL_7414_DIP
+//- Title: DM5414/DM7414 Hex Inverter withSchmitt Trigger Inputs
+//- Description: This device contains six independent gates each of whichperforms the logic INVERT function.
+//- Each input has hysteresis which increases the noise immunity and transforms a slowly changing input
+//- signal to a fast changing, jitter free output.
+//- Pinalias: A1,Y1,A2,Y2,A3,Y3,GND,Y4,A4,Y5,A5,Y6,A6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006503.PDF
+//-
+//- +---++---+
+//- | A || Y |
+//- +===++===+
+//- | 0 || 1 |
+//- | 1 || 0 |
+//- +---++---+
+//-
static NETLIST_START(TTL_7414_GATE)
SCHMITT_TRIGGER(X, "DM7414")
ALIAS(A, X.A)
@@ -296,12 +377,12 @@ static NETLIST_START(TTL_7414_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC, E.VCC, F.VCC)
DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.Q, /* Y1 |2 13| A6 */ F.A,
- B.A, /* A2 |3 12| Y6 */ F.Q,
- B.Q, /* Y2 |4 7414 11| A5 */ E.A,
- C.A, /* A3 |5 10| Y5 */ E.Q,
- C.Q, /* Y3 |6 9| A4 */ D.A,
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.Q, /* Y1 |2 13| A6 */ F.A,
+ B.A, /* A2 |3 12| Y6 */ F.Q,
+ B.Q, /* Y2 |4 7414 11| A5 */ E.A,
+ C.A, /* A3 |5 10| Y5 */ E.Q,
+ C.Q, /* Y3 |6 9| A4 */ D.A,
A.GND, /* GND |7 8| Y4 */ D.Q
/* +--------------+ */
)
@@ -319,23 +400,34 @@ static NETLIST_START(TTL_74LS14_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC, E.VCC, F.VCC)
DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.Q, /* Y1 |2 13| A6 */ F.A,
- B.A, /* A2 |3 12| Y6 */ F.Q,
- B.Q, /* Y2 |4 74LS14 11| A5 */ E.A,
- C.A, /* A3 |5 10| Y5 */ E.Q,
- C.Q, /* Y3 |6 9| A4 */ D.A,
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.Q, /* Y1 |2 13| A6 */ F.A,
+ B.A, /* A2 |3 12| Y6 */ F.Q,
+ B.Q, /* Y2 |4 74LS14 11| A5 */ E.A,
+ C.A, /* A3 |5 10| Y5 */ E.Q,
+ C.Q, /* Y3 |6 9| A4 */ D.A,
A.GND, /* GND |7 8| Y4 */ D.Q
/* +--------------+ */
)
NETLIST_END()
-/*
- * DM7416: Hex Inverting Buffers with
- * High Voltage Open-Collector Outputs
- *
- */
-
+//- Identifier: TTL_7416_DIP
+//- Title: DM5416/DM7416 Hex Inverting Buffers with High Voltage Open-Collector Outputs
+//- Description: This device contains six independent gates each of which performs the logic INVERT function.
+//- The open-collector outputs require external pull-up resistors for proper logical operation.
+//- Pinalias: A1,Y1,A2,Y2,A3,Y3,GND,Y4,A4,Y5,A5,Y6,A6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006504.PDF
+//-
+//- +---++---+
+//- | A || Y |
+//- +===++===+
+//- | 0 || 1 |
+//- | 1 || 0 |
+//- +---++---+
+//-
static NETLIST_START(TTL_7416_DIP)
TTL_7416_GATE(A)
TTL_7416_GATE(B)
@@ -347,36 +439,37 @@ static NETLIST_START(TTL_7416_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC, E.VCC, F.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND, E.GND, F.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.Q, /* Y1 |2 13| A6 */ F.A,
- B.A, /* A2 |3 12| Y6 */ F.Q,
- B.Q, /* Y2 |4 7416 11| A5 */ E.A,
- C.A, /* A3 |5 10| Y5 */ E.Q,
- C.Q, /* Y3 |6 9| A4 */ D.A,
- A.GND,/* GND |7 8| Y4 */ D.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.Q, /* Y1 |2 13| A6 */ F.A,
+ B.A, /* A2 |3 12| Y6 */ F.Q,
+ B.Q, /* Y2 |4 7416 11| A5 */ E.A,
+ C.A, /* A3 |5 10| Y5 */ E.Q,
+ C.Q, /* Y3 |6 9| A4 */ D.A,
+ A.GND, /* GND |7 8| Y4 */ D.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7420: Dual 4-Input NAND Gates
- *
- * ___
- * Y = ABCD
- * +---+---+---+---++---+
- * | A | B | C | D || Y |
- * +===+===+===+===++===+
- * | X | X | X | 0 || 1 |
- * | X | X | 0 | X || 1 |
- * | X | 0 | X | X || 1 |
- * | 0 | X | X | X || 1 |
- * | 1 | 1 | 1 | 1 || 0 |
- * +---+---+---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet *
- */
-
+//- Identifier: TTL_7420_DIP
+//- Title: 5420/DM5420/DM7420 Dual 4-Input NAND Gates
+//- Description: This device contains two independent gates each of which performs the logic NAND function.
+//- Pinalias: A1,B1,NC,C1,D1,Y1,GND,Y2,A2,B2,NC,C2,D2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006506.PDF
+//-
+//- +---+---+---+---++---+
+//- | A | B | C | D || Y |
+//- +===+===+===+===++===+
+//- | X | X | X | 0 || 1 |
+//- | X | X | 0 | X || 1 |
+//- | X | 0 | X | X || 1 |
+//- | 0 | X | X | X || 1 |
+//- | 1 | 1 | 1 | 1 || 0 |
+//- +---+---+---+---++---+
+//-
static NETLIST_START(TTL_7420_DIP)
TTL_7420_GATE(A)
TTL_7420_GATE(B)
@@ -385,36 +478,37 @@ static NETLIST_START(TTL_7420_DIP)
NET_C(A.GND, B.GND)
NC_PIN(NC)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| D2 */ B.D,
- NC.I, /* NC |3 12| C2 */ B.C,
- A.C, /* C1 |4 7420 11| NC */ NC.I,
- A.D, /* D1 |5 10| B2 */ B.B,
- A.Q, /* Y1 |6 9| A2 */ B.A,
- A.GND,/* GND |7 8| Y2 */ B.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| D2 */ B.D,
+ NC.I, /* NC |3 12| C2 */ B.C,
+ A.C, /* C1 |4 7420 11| NC */ NC.I,
+ A.D, /* D1 |5 10| B2 */ B.B,
+ A.Q, /* Y1 |6 9| A2 */ B.A,
+ A.GND, /* GND |7 8| Y2 */ B.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7421: Dual 4-Input AND Gates
- *
- * ___
- * Y = ABCD
- * +---+---+---+---++---+
- * | A | B | C | D || Y |
- * +===+===+===+===++===+
- * | X | X | X | 0 || 0 |
- * | X | X | 0 | X || 0 |
- * | X | 0 | X | X || 0 |
- * | 0 | X | X | X || 0 |
- * | 1 | 1 | 1 | 1 || 1 |
- * +---+---+---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet *
- */
-
+//- Identifier: TTL_7421_DIP
+//- Title: 54LS21/DM54LS21/DM74LS21 Dual 4-Input AND Gates
+//- Description: This device contains two independent 4-input gates each of which performs the logic AND function.
+//- Pinalias: A1,B1,NC,C1,D1,Y1,GND,Y2,A2,B2,NC,C2,D2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006356.PDF
+//-
+//- +---+---+---+---++---+
+//- | A | B | C | D || Y |
+//- +===+===+===+===++===+
+//- | X | X | X | 0 || 1 |
+//- | X | X | 0 | X || 1 |
+//- | X | 0 | X | X || 1 |
+//- | 0 | X | X | X || 1 |
+//- | 1 | 1 | 1 | 1 || 0 |
+//- +---+---+---+---++---+
+//-
static NETLIST_START(TTL_7421_DIP)
TTL_7421_GATE(A)
TTL_7421_GATE(B)
@@ -423,40 +517,40 @@ static NETLIST_START(TTL_7421_DIP)
NET_C(A.GND, B.GND)
NC_PIN(NC)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| D2 */ B.D,
- NC.I, /* NC |3 12| C2 */ B.C,
- A.C, /* C1 |4 7420 11| NC */ NC.I,
- A.D, /* D1 |5 10| B2 */ B.B,
- A.Q, /* Y1 |6 9| A2 */ B.A,
- A.GND,/* GND |7 8| Y2 */ B.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| D2 */ B.D,
+ NC.I, /* NC |3 12| C2 */ B.C,
+ A.C, /* C1 |4 7421 11| NC */ NC.I,
+ A.D, /* D1 |5 10| B2 */ B.B,
+ A.Q, /* Y1 |6 9| A2 */ B.A,
+ A.GND, /* GND |7 8| Y2 */ B.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7425: Dual 4-Input NOR Gates
- *
- * ______
- * Y = A+B+C+D
- * +---+---+---+---+---++---+
- * | A | B | C | D | X || Y |
- * +===+===+===+===+===++===+
- * | X | X | X | X | 0 || Z |
- * | 0 | 0 | 0 | 0 | 1 || 1 |
- * | X | X | X | 1 | 1 || 0 |
- * | X | X | 1 | X | 1 || 0 |
- * | X | 1 | X | X | 1 || 0 |
- * | 1 | X | X | X | 1 || 0 |
- * +---+---+---+---+---++---+
- *
- * FIXME: The "X" input and high impedance output are currently not simulated.
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7425_DIP
+//- Title: 5425/DM7425 Dual 4-Input NOR Gate (with Strobe)
+//- Description: This device contains 2, 4-input gates that perform the logical NOR function.
+//- The output of each NOR gate is gated (strobed) by pin 3 and 11 by positive true logic, i.e., logic "1" equals output on.
+//- Pinalias: A1,B1,X1,C1,D1,Y1,GND,Y2,A2,B2,X2,C2,D2
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- Limitations: The "X" input and high impedance output are currently not simulated.
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet_pdf/national-semiconductor/5425DMQB_to_DM7425N.pdf
+//-
+//- +---+---+---+---+---++---+
+//- | A | B | C | D | X || Y |
+//- +===+===+===+===+===++===+
+//- | X | X | X | X | 0 || Z |
+//- | 0 | 0 | 0 | 0 | 1 || 1 |
+//- | X | X | X | 1 | 1 || 0 |
+//- | X | X | 1 | X | 1 || 0 |
+//- | X | 1 | X | X | 1 || 0 |
+//- | 1 | X | X | X | 1 || 0 |
+//- +---+---+---+---+---++---+
+//-
static NETLIST_START(TTL_7425_DIP)
TTL_7425_GATE(A)
TTL_7425_GATE(B)
@@ -466,36 +560,36 @@ static NETLIST_START(TTL_7425_DIP)
NC_PIN(XA) // FIXME: Functionality needs to be implemented
NC_PIN(XB) // FIXME: Functionality needs to be implemented
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| D2 */ B.D,
- XA.I, /* X1 |3 12| C2 */ B.C,
- A.C, /* C1 |4 7425 11| X2 */ XB.I,
- A.D, /* D1 |5 10| B2 */ B.B,
- A.Q, /* Y1 |6 9| A2 */ B.A,
- A.GND,/* GND |7 8| Y2 */ B.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| D2 */ B.D,
+ XA.I, /* X1 |3 12| C2 */ B.C,
+ A.C, /* C1 |4 7425 11| X2 */ XB.I,
+ A.D, /* D1 |5 10| B2 */ B.B,
+ A.Q, /* Y1 |6 9| A2 */ B.A,
+ A.GND, /* GND |7 8| Y2 */ B.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7427: Triple 3-Input NOR Gates
- *
- * ____
- * Y = A+B+C
- * +---+---+---++---+
- * | A | B | C || Y |
- * +===+===+===++===+
- * | X | X | 1 || 0 |
- * | X | 1 | X || 0 |
- * | 1 | X | X || 0 |
- * | 0 | 0 | 0 || 1 |
- * +---+---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7427_DIP
+//- Title: DM7427 Triple 3-Input NOR Gates
+//- Description: This device contains three independent gates each of which performs the logic NOR function.
+//- Pinalias: A1,B1,A2,B2,C2,Y2,GND,Y3,A3,B3,C3,Y1,C1,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006509.PDF
+//-
+//- +---+---+---++---+
+//- | A | B | C || Y |
+//- +===+===+===++===+
+//- | X | X | 1 || 0 |
+//- | X | 1 | X || 0 |
+//- | 1 | X | X || 0 |
+//- | 0 | 0 | 0 || 1 |
+//- +---+---+---++---+
+//-
static NETLIST_START(TTL_7427_DIP)
TTL_7427_GATE(A)
TTL_7427_GATE(B)
@@ -504,76 +598,74 @@ static NETLIST_START(TTL_7427_DIP)
NET_C(A.VCC, B.VCC, C.VCC)
NET_C(A.GND, B.GND, C.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| C1 */ A.C,
- B.A, /* A2 |3 12| Y1 */ A.Q,
- B.B, /* B2 |4 7427 11| C3 */ C.C,
- B.C, /* C2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| C1 */ A.C,
+ B.A, /* A2 |3 12| Y1 */ A.Q,
+ B.B, /* B2 |4 7427 11| C3 */ C.C,
+ B.C, /* C2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7430: 8-Input NAND Gate
- *
- * _______
- * Y = ABCDEFGH
- * +---+---+---+---+---+---+---+---++---+
- * | A | B | C | D | E | F | G | H || Y |
- * +===+===+===+===+===+===+===+===++===+
- * | X | X | X | X | X | X | X | 0 || 1 |
- * | X | X | X | X | X | X | 0 | X || 1 |
- * | X | X | X | X | X | 0 | X | X || 1 |
- * | X | X | X | X | 0 | X | X | X || 1 |
- * | X | X | X | 0 | X | X | X | X || 1 |
- * | X | X | 0 | X | X | X | X | X || 1 |
- * | X | 0 | X | X | X | X | X | X || 1 |
- * | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 || 0 |
- * +---+---+---+---+---+---+---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- */
-
+//- Identifier: TTL_7430_DIP
+//- Title: 5430/DM5430/DM7430 8-Input NAND Gate
+//- Description: This device contains a single gate which performs the logic NAND function.
+//- Pinalias: A,B,C,D,E,F,GND,Y,NC,NC,G,H,NC,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006510.PDF
+//-
+//- +---+---+---+---+---+---+---+---++---+
+//- | A | B | C | D | E | F | G | H || Y |
+//- +===+===+===+===+===+===+===+===++===+
+//- | X | X | X | X | X | X | X | 0 || 1 |
+//- | X | X | X | X | X | X | 0 | X || 1 |
+//- | X | X | X | X | X | 0 | X | X || 1 |
+//- | X | X | X | X | 0 | X | X | X || 1 |
+//- | X | X | X | 0 | X | X | X | X || 1 |
+//- | X | X | 0 | X | X | X | X | X || 1 |
+//- | X | 0 | X | X | X | X | X | X || 1 |
+//- | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 || 0 |
+//- +---+---+---+---+---+---+---+---++---+
+//-
static NETLIST_START(TTL_7430_DIP)
TTL_7430_GATE(A)
+ NC_PIN(NC)
- NC_PIN(NC9)
- NC_PIN(NC10)
- NC_PIN(NC13)
-
- DIPPINS( /* +--------------+ */
- A.A, /* A |1 ++ 14| VCC */ A.VCC,
- A.B, /* B |2 13| NC */ NC13.I,
- A.C, /* C |3 12| H */ A.H,
- A.D, /* D |4 7430 11| G */ A.G,
- A.E, /* E |5 10| NC */ NC10.I,
- A.F, /* F |6 9| NC */ NC9.I,
- A.GND,/* GND |7 8| Y */ A.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B |2 13| NC */ NC.I,
+ A.C, /* C |3 12| H */ A.H,
+ A.D, /* D |4 7430 11| G */ A.G,
+ A.E, /* E |5 10| NC */ NC.I,
+ A.F, /* F |6 9| NC */ NC.I,
+ A.GND, /* GND |7 8| Y */ A.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7432: Quad 2-Input OR Gates
- *
- * __
- * Y = A+B
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 0 |
- * | 0 | 1 || 1 |
- * | 1 | 0 || 1 |
- * | 1 | 1 || 1 |
- * +---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-
+//- Identifier: TTL_7432_DIP
+//- Title: 5432/DM5432/DM7432 Quad 2-Input OR Gates
+//- Description: This device contains four independent gates each of whichperforms the logic OR function.
+//- Pinalias: A1,B1,Y1,A2,B2,Y2,GND,Y3,A3,B3,Y4,A4,B4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006511.PDF
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 0 |
+//- | 0 | 1 || 1 |
+//- | 1 | 0 || 1 |
+//- | 1 | 1 || 1 |
+//- +---+---++---+
+//-
static NETLIST_START(TTL_7432_DIP)
TTL_7432_GATE(A)
TTL_7432_GATE(B)
@@ -583,39 +675,37 @@ static NETLIST_START(TTL_7432_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| B4 */ D.B,
- A.Q, /* Y1 |3 12| A4 */ D.A,
- B.A, /* A2 |4 7400 11| Y4 */ D.Q,
- B.B, /* B2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| B4 */ D.B,
+ A.Q, /* Y1 |3 12| A4 */ D.A,
+ B.A, /* A2 |4 7432 11| Y4 */ D.Q,
+ B.B, /* B2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-
-/*
- * DM7437: Quad 2-Input NAND Gates
- *
- * _
- * Y = AB
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 1 |
- * | 0 | 1 || 1 |
- * | 1 | 0 || 1 |
- * | 1 | 1 || 0 |
- * +---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- * NOTE: Same as 7400, but drains higher output currents.
- * Netlist currently does not model over currents (should it ever?)
- */
-
+//- Identifier: TTL_7437_DIP
+//- Title: 5437/DM5437/DM7437 Quad 2-Input NAND Buffers
+//- Description: This device contains four independent gates each of whichperforms the logic OR function.
+//- Pinalias: A1,B1,Y1,A2,B2,Y2,GND,Y3,A3,B3,Y4,A4,B4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- Limitations: Same as 7400, but drains higher output currents. Netlist currently does not model over currents (should it ever?)
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/105/236976_DS.pdf
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 1 |
+//- | 0 | 1 || 1 |
+//- | 1 | 0 || 1 |
+//- | 1 | 1 || 0 |
+//- +---+---++---+
+//-
static NETLIST_START(TTL_7437_DIP)
TTL_7437_GATE(A)
TTL_7437_GATE(B)
@@ -625,35 +715,510 @@ static NETLIST_START(TTL_7437_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| B4 */ D.B,
- A.Q, /* Y1 |3 12| A4 */ D.A,
- B.A, /* A2 |4 7400 11| Y4 */ D.Q,
- B.B, /* B2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| B4 */ D.B,
+ A.Q, /* Y1 |3 12| A4 */ D.A,
+ B.A, /* A2 |4 7437 11| Y4 */ D.Q,
+ B.B, /* B2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7442_DIP
+//- Title: 5442A/DM5442A/DM7442A BCD to Decimal Decoders
+//- Description: These BCD-to-decimal decoders consist of eight inverters
+//- and ten, four-input NAND gates. The inverters are
+//- connected in pairs to make BCD input data available for
+//- decoding by the NAND gates. Full decoding of input
+//- logic ensures that all outputs remain off for all invalid
+//- (10-15) input conditions.
+//- Pinalias: 0,1,2,3,4,5,6,GND,7,8,9,D,C,B,A,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006516.PDF
+//-
+//- +---+---+---+---++---+---+---+---+---+---+---+---+---+---+
+//- | D | C | B | A || 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
+//- +===+===+===+===++===+===+===+===+===+===+===+===+===+===+
+//- | 0 | 0 | 0 | 0 || 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 0 | 1 || 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 1 | 0 || 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 1 | 1 || 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 0 | 0 || 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 0 | 1 || 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 |
+//- | 0 | 1 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 |
+//- | 1 | 0 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 |
+//- | 1 | 0 | 0 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 |
+//- | 1 | 0 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | 0 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | 1 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | 1 | 0 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | 1 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | 1 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- +---+---+---+---++---+---+---+---+---+---+---+---+---+---+
+//-
+static NETLIST_START(TTL_7442_DIP)
+ NET_REGISTER_DEV(TTL_7442, A)
+
+ DIPPINS( /* +--------------+ */
+ A.Q0, /* 0 |1 ++ 16| VCC */ A.VCC,
+ A.Q1, /* 1 |2 15| A */ A.A,
+ A.Q2, /* 2 |3 14| B */ A.B,
+ A.Q3, /* 3 |4 13| C */ A.C,
+ A.Q4, /* 4 |5 7442 12| D */ A.D,
+ A.Q5, /* 5 |6 11| 9 */ A.Q9,
+ A.Q6, /* 6 |7 10| 8 */ A.Q8,
+ A.GND, /* GND |8 9| 7 */ A.Q7
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7448_DIP
+//- Title: DM5448/DM48LS48/DM7448/DM74LS48 BCD to 7-Segment Decoder
+//- Description: The 48 and LS48 feature active-high outputs for
+//- driving lamp buffers or common-cathode LED's.
+//- These circuits have full ripple-blanking input/output controls
+//- and a lamp test input. Display patterns
+//- for BCD input counts above nine are unique symbols
+//- to authenticate input conditions.
+//- These circuits incorporate automatic
+//- leading and/or trailing-edge, zero-blanking control
+//- (RBI and RBO). Lamp test (LT) of these devices may
+//- be performed at any time when the BI/RBO node is at
+//- a high logic level. They contain
+//- an overriding blanking input (BI) which can be used
+//- to control the lamp intensity (by pulsing), or to inhibit
+//- the outputs.
+//- Pinalias: A1,A2,LTQ,BIQ,RBIQ,A3,A0,GND,e,d,c,b,a,g,f,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS010172.PDF
+//-
+//- +-----+------+----+----+----+----++-----+---+---+---+---+---+---+---+
+//- | LTQ | RBIQ | A3 | A2 | A1 | A0 || BIQ | a | b | c | d | e | f | g |
+//- +=====+======+====+====+====+====++=====+===+===+===+===+===+===+===+
+//- | 1 | 1 | 0 | 0 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 |
+//- | 1 | X | 0 | 0 | 0 | 1 || 1 | 0 | 1 | 1 | 0 | 0 | 0 | 0 |
+//- | 1 | X | 0 | 0 | 1 | 0 || 1 | 1 | 1 | 0 | 1 | 1 | 0 | 1 |
+//- | 1 | X | 0 | 0 | 1 | 1 || 1 | 1 | 1 | 1 | 1 | 0 | 0 | 1 |
+//- | 1 | X | 0 | 1 | 0 | 0 || 1 | 0 | 1 | 1 | 0 | 0 | 1 | 1 |
+//- | 1 | X | 0 | 1 | 0 | 1 || 1 | 1 | 0 | 1 | 1 | 0 | 1 | 1 |
+//- | 1 | X | 0 | 1 | 1 | 0 || 1 | 0 | 0 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | X | 0 | 1 | 1 | 1 || 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 |
+//- | 1 | X | 1 | 0 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 1 | X | 1 | 0 | 0 | 1 || 1 | 1 | 1 | 1 | 0 | 0 | 1 | 1 |
+//- | 1 | X | 1 | 0 | 1 | 0 || 1 | 0 | 0 | 0 | 1 | 1 | 0 | 1 |
+//- | 1 | X | 1 | 0 | 1 | 1 || 1 | 0 | 0 | 1 | 1 | 0 | 0 | 1 |
+//- | 1 | X | 1 | 1 | 0 | 0 || 1 | 0 | 1 | 0 | 0 | 0 | 1 | 1 |
+//- | 1 | X | 1 | 1 | 0 | 1 || 1 | 1 | 0 | 0 | 1 | 0 | 1 | 1 |
+//- | 1 | X | 1 | 1 | 1 | 0 || 1 | 0 | 0 | 0 | 1 | 1 | 1 | 1 |
+//- | 1 | X | 1 | 1 | 1 | 1 || 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+//- | X | X | X | X | X | X || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+//- | 1 | 0 | 0 | 0 | 0 | 0 || 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+//- | 0 | X | X | X | X | X || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- +-----+------+----+----+----+----++-----+---+---+---+---+---+---+---+
+//-
+static NETLIST_START(TTL_7448_DIP)
+
+#if (NL_USE_TRUTHTABLE_7448)
+ NET_REGISTER_DEV(TTL_7448_TT, A)
+#else
+ NET_REGISTER_DEV(TTL_7448, A)
+#endif
+
+ DIPPINS( /* +--------------+ */
+ A.B, /* B |1 ++ 16| VCC */ A.VCC,
+ A.C, /* C |2 15| f */ A.f,
+ A.LTQ, /* LTQ |3 14| g */ A.g,
+ A.BIQ, /* BIQ |4 7448 13| a */ A.a,
+ A.RBIQ, /* RBIQ |5 12| b */ A.b,
+ A.D, /* D |6 11| c */ A.c,
+ A.A, /* A |7 10| d */ A.d,
+ A.GND, /* GND |8 9| e */ A.e
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7450_DIP
+//- Title: DM7450 Expandable Dual 2-Wide 2-Input AND-OR-INVERT Gate
+//- Description: This device contains two independent combinations of gates, each of which perform the logic AND-OR-INVERT function.
+//- One set of gates has an expander node.
+//- Pinalias: A1,B1,Y1,A2,B2,Y2,GND,Y3,A3,B3,Y4,A4,B4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- Limitations: Expander signal is not implemented
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/105/236976_DS.pdf
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 1 |
+//- | 0 | 1 || 1 |
+//- | 1 | 0 || 1 |
+//- | 1 | 1 || 0 |
+//- +---+---++---+
+//-
+static NETLIST_START(TTL_7450_DIP)
+ TTL_7450_ANDORINVERT(A)
+ TTL_7450_ANDORINVERT(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.A, /* 1A |1 ++ 14| VCC */ A.VCC,
+ B.A, /* 2A |2 13| 1B */ A.B,
+ B.B, /* 2B |3 12| 1XQ */ NC.I,
+ B.C, /* 2C |4 7450 11| 1X */ NC.I,
+ B.D, /* 2D |5 10| 1D */ A.D,
+ B.Q, /* 2Y |6 9| 1C */ A.C,
+ A.GND, /* GND |7 8| 1Y */ A.Q
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7473_DIP
+//- Title: 5473/DM5473/DM7473 Dual Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
+//- Description: This device contains two independent positive pulse triggered J-K flip-flops with complementary outputs.
+//- The J and K data is processed by the flip-flops after a complete clock pulse.
+//- While the clock is low the slave is isolated from the master.
+//- On the positive transition of the clock, the data from the J and K inputs is transferred to teh master.
+//- While the clock is high the J and K inputs are disabled.
+//- On the negative transition of the clock, the data from the master is transferred to the slave.
+//- The logic states of the J and K inputs must not be allowed to change while the clock is high.
+//- Data transfers to the outputs on the falling edge of the clock pulse.
+//- A low logic level on the clear input will reset the outputs regardless of the logic states of the other inputs.
+//- Pinalias: CLK1,CLR1,K1,VCC,CLK2,CLR2,J2,QQ2,Q2,K2,GND,Q1,QQ1,J1
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet_pdf/national-semiconductor/5473DMQB_to_DM7473N.pdf
+//-
+//- +-----+-------+---+---++---+----+
+//- | CLR | CLK | J | K || Q | QQ |
+//- +=====+=======+===+===++===+====+
+//- | 0 | X | X | X || 0 | 1 |
+//- | 1 | 0-1-0 | 0 | 0 || Q | QQ |
+//- | 1 | 0-1-0 | 1 | 0 || 1 | 0 |
+//- | 1 | 0-1-0 | 0 | 1 || 0 | 1 |
+//- | 1 | 0-1-0 | 1 | 1 || Toggle |
+//- +-----+-------+---+---++---+----+
+//-
+static NETLIST_START(TTL_7473_DIP)
+ TTL_7473(A)
+ TTL_7473(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.CLK, /* CLK1 |1 ++ 14| J1 */ A.J,
+ A.CLRQ, /* CLR1 |2 13| QQ1 */ A.QQ,
+ A.K, /* K1 |3 12| Q1 */ A.Q,
+ A.VCC, /* VCC |4 7473 11| GND */ A.GND,
+ B.CLK, /* CLK2 |5 10| K2 */ B.K,
+ B.CLRQ, /* CLR2 |6 9| Q2 */ B.Q,
+ B.J, /* J2 |7 8| QQ2 */ B.QQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7473A_DIP
+//- Title: DM54LS73A/DM74LS73A Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
+//- Description: This device contains two independent negative-edge-triggered J-K flip-flops with complementary outputs.
+//- The J and K data is processed by the flip-flops on the falling edge of the clock pulse.
+//- The clock triggering occurs at a voltage level and is not directly related to the transition time of the negative going edge of the clock pulse.
+//- The data on the J and K inputs is allowed to change while the clock is high or low without affecting the outputs as long as setup and hold times are not violated.
+//- A low logic level on the clear input will reset the outputs regardless of the levels of the other inputs.
+//- Pinalias: CLK1,CLR1,K1,VCC,CLK2,CLR2,J2,QQ2,Q2,K2,GND,Q1,QQ1,J1
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semicouductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006372.PDF
+//-
+//- +-----+-----+---+---++---+----+
+//- | CLR | CLK | J | K || Q | QQ |
+//- +=====+=====+===+===++===+====+
+//- | 0 | X | X | X || 0 | 1 |
+//- | 1 | 1-0 | 0 | 0 || Q | QQ |
+//- | 1 | 1-0 | 1 | 0 || 1 | 0 |
+//- | 1 | 1-0 | 0 | 1 || 0 | 1 |
+//- | 1 | 1-0 | 1 | 1 || Toggle |
+//- | 1 | 1 | X | X || Q | QQ |
+//- +-----+-----+---+---++---+----+
+//-
+static NETLIST_START(TTL_7473A_DIP)
+ TTL_7473A(A)
+ TTL_7473A(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.CLK, /* CLK1 |1 ++ 14| J1 */ A.J,
+ A.CLRQ, /* CLR1 |2 13| QQ1 */ A.QQ,
+ A.K, /* K1 |3 12| Q1 */ A.Q,
+ A.VCC, /* VCC |4 7473A 11| GND */ A.GND,
+ B.CLK, /* CLK2 |5 10| K2 */ B.K,
+ B.CLRQ, /* CLR2 |6 9| Q2 */ B.Q,
+ B.J, /* J2 |7 8| QQ2 */ B.QQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7474_DIP
+//- Title: 5474/DM5474/DM7474 Dual Positive-Edge-Triggered D Flip-Flops with Preset, Clear and Complementary Outputs
+//- Description: This device contains two independent positive-edge-triggered D flip-flops with complementary outputs.
+//- The information on the D input is accepted by the flip-flops on the positive going edge of the clock pulse.
+//- The triggering occurs at a voltage level and is not directly related to the transition time of the rising edge of the clock.
+//- The data on the D input may be changed while the clock is low or high without affecting the outputs as long as the data setup and hold times are not violated.
+//- A low logic level on the preset or clear inputs will set or reset the outputs regardless of the logic levels of the other inputs.
+//- Pinalias: CLR1,D1,CLK1,PR1,Q1,QQ1,GND,QQ2,Q2,PR2,CLK2,D2,CLR2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006526.PDF
+//-
+//- +----+-----+-----+---++---+----+
+//- | PR | CLR | CLK | D || Q | QQ |
+//- +====+=====+=====+===++===+====+
+//- | 0 | 1 | X | X || 1 | 0 |
+//- | 1 | 0 | X | X || 0 | 1 |
+//- | 0 | 0 | X | X || 1 | 1 | (unstable)
+//- | 1 | 1 | 0-1 | 1 || 1 | 0 |
+//- | 1 | 1 | 0-1 | 0 || 0 | 1 |
+//- | 1 | 1 | 0 | X || Q | QQ |
+//- +----+-----+-----+---++---+----+
+//-
+static NETLIST_START(TTL_7474_DIP)
+ TTL_7474(A)
+ TTL_7474(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.CLRQ, /* CLR1 |1 ++ 14| VCC */ A.VCC,
+ A.D, /* D1 |2 13| CLR2 */ B.CLRQ,
+ A.CLK, /* CLK1 |3 12| D2 */ B.D,
+ A.PREQ, /* PR1 |4 7474 11| CLK2 */ B.CLK,
+ A.Q, /* Q1 |5 10| PR2 */ B.PREQ,
+ A.QQ, /* QQ1 |6 9| Q2 */ B.Q,
+ A.GND, /* GND |7 8| QQ2 */ B.QQ
+ /* +-------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7475_DIP
+//- Title: DM5475/DM7475/DM7475A/DM74LS75 4-bit D Latch
+//- Description: These latches are ideally suited for use as temporary
+//- storage for binary information between processing units
+//- and input/output or indicator units. Information present
+//- at a data (D) input is transferred to the Q output when
+//- the enable (G) is high, and the Q output will follow
+//- the data input as long as the enable remains high. When
+//- the enable goes low, the information (that was present
+//- at the data input at the time the transition occurred) is
+//- retained at the Q output until the enable is permitted
+//- to go high.
+//-
+//- The DM5475/DM7475, DM54L75A/DM74L75A, and
+//- DM54LS75/DM74LS75 feature complementary Q and
+//- QQ outputs from a 4-bit latch, and are available in 16-pin
+//- packages.
+//- Pinalias: QQ1,D1,D2,E34,VCC,D3,D4,QQ4,Q4,Q3,QQ3,GND,E12,QQ2,Q2,Q1
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- https://ia800608.us.archive.org/5/items/bitsavers_nationaldaTTLDatabook_40452765/1976_National_TTL_Databook.pdf
+//-
+//- +---+---++---+----+
+//- | D | G || Q | QQ |
+//- +===+===++===+====+
+//- | 0 | 1 || 0 | 1 |
+//- | 1 | 1 || 1 | 0 |
+//- | X | 0 || Q | QQ |
+//- +---+---++---+----+
+//-
+static NETLIST_START(TTL_7475_DIP)
+ TTL_7475_GATE(A)
+ TTL_7475_GATE(B)
+ TTL_7475_GATE(C)
+ TTL_7475_GATE(D)
+
+ NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
+ NET_C(A.GND, B.GND, C.GND, D.GND)
+
+ NET_C(A.CLK, B.CLK)
+ NET_C(C.CLK, D.CLK)
+
+ DIPPINS( /* +--------------+ */
+ A.QQ, /* QQ1 |1 ++ 16| Q1 */ A.Q,
+ A.D, /* D1 |2 15| Q2 */ B.Q,
+ B.D, /* D2 |3 14| QQ2 */ B.QQ,
+ C.CLK, /* E34 |4 7475 13| E12 */ A.CLK,
+ A.VCC, /* VCC |5 12| GND */ A.GND,
+ C.D, /* D3 |6 11| QQ3 */ C.QQ,
+ D.D, /* D4 |7 10| Q3 */ C.Q,
+ D.QQ, /* QQ4 |8 9| Q4 */ D.Q
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7477_DIP
+//- Title: DM74LS77 4-bit D Latch
+//- Description: These latches are ideally suited for use as temporary
+//- storage for binary information between processing units
+//- and input/output or indicator units. Information present
+//- at a data (D) input is transferred to the Q output when
+//- the enable (G) is high, and the Q output will follow
+//- the data input as long as the enable remains high. When
+//- the enable goes low, the information (that was present
+//- at the data input at the time the transition occurred) is
+//- retained at the Q output until the enable is permitted
+//- to go high.
+//- Pinalias: D1,D2,E34,VCC,D3,D4,NC,Q4,Q3,NC,GND,E12,Q2,Q1
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- https://ia800608.us.archive.org/5/items/bitsavers_nationaldaTTLDatabook_40452765/1976_National_TTL_Databook.pdf
+//-
+//- +---+---++---+----+
+//- | D | G || Q | QQ |
+//- +===+===++===+====+
+//- | 0 | 1 || 0 | 1 |
+//- | 1 | 1 || 1 | 0 |
+//- | X | 0 || Q | QQ |
+//- +---+---++---+----+
+//-
+static NETLIST_START(TTL_7477_DIP)
+ TTL_7477_GATE(A)
+ TTL_7477_GATE(B)
+ TTL_7477_GATE(C)
+ TTL_7477_GATE(D)
+
+ NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
+ NET_C(A.GND, B.GND, C.GND, D.GND)
+
+ NET_C(A.CLK, B.CLK)
+ NET_C(C.CLK, D.CLK)
+
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.D, /* D1 |1 ++ 14| Q1 */ A.Q,
+ B.D, /* D2 |2 13| Q2 */ B.Q,
+ C.CLK, /* E34 |3 12| E12 */ A.CLK,
+ A.VCC, /* VCC |4 7477 11| GND */ A.GND,
+ C.D, /* D3 |5 10| NC */ NC.I,
+ D.D, /* D4 |6 9| Q3 */ C.Q,
+ NC.I, /* NC |7 8| Q4 */ D.Q
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7483_DIP
+//- Title: DM5483/DM7483/DM74LS83A 4-bit Binary Adders With Fast Carry
+//- Description: These full adders perform the addition of two 4-bit
+//- binary numbers. The sum (S) outputs are provided for
+//- each bit and the resultant carry (C4) is obtained from
+//- the fourth bit. These adders feature full internal look
+//- ahead across all four bits. This provides the system
+//- designer with partial look-ahead performance at the
+//- economy and reduced package count of a ripple-carry
+//- implementation.
+//-
+//- The adder logic, including the carry, is implemented in
+//- its true form meaning that the end-around carry can be
+//- accomplished without the need for logic or level inversion.
+//- Pinalias: A4,S3,A3,B3,VCC,S2,B2,A2,S1,A1,B1,GND,C0,C4,S4,B4
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006378.PDF
+//-
+static NETLIST_START(TTL_7483_DIP)
+ TTL_7483(A)
+
+ DIPPINS( /* +--------------+ */
+ A.A4, /* A4 |1 ++ 16| B4 */ A.B4,
+ A.S3, /* S3 |2 15| S4 */ A.S4,
+ A.A3, /* A3 |3 14| C4 */ A.C4,
+ A.B3, /* B3 |4 7483 13| C0 */ A.C0,
+ A.VCC, /* VCC |5 12| GND */ A.GND,
+ A.S2, /* S2 |6 11| B1 */ A.B1,
+ A.B2, /* B2 |7 10| A1 */ A.A1,
+ A.A2, /* A2 |8 9| S1 */ A.S1
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM7486: Quad 2-Input Exclusive-OR Gates
- *
- * Y = A+B
- * +---+---++---+
- * | A | B || Y |
- * +===+===++===+
- * | 0 | 0 || 0 |
- * | 0 | 1 || 1 |
- * | 1 | 0 || 1 |
- * | 1 | 1 || 0 |
- * +---+---++---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
+//- Identifier: TTL_7485_DIP
+//- Title: DM5485/DM7485/DM74L85/DM74LS85 4-Bit Magnitude Comparators
+//- Description: These four-bit magnitude comparators perform comparison
+//- of straight binary or BCD codes. Three
+//- fully-decoded decisions about two, 4-bit words (A, B)
+//- are made and are externally available at three outputs.
+//- These devices are fully expandable to any number of
+//- bits without external gates. Words of greater length may
+//- be compared by connecting comparators in cascade. The
+//- A > B, A < B, and A = B outputs of a stage handling
+//- less-significant bits are connected to the corresponding
+//- inputs of the next stage handling more-significant bits.
+//- The stage handling the least-significant bits must have a
+//- high-level voltage applied to the A = B input and in
+//- addition for the L85, low-level voltages applied to the
+//- A> B and A < B inputs. The cascading paths of the 85,
+//- and LS85 are implemented with only a two-gate-Ievel
+//- delay to reduce overall comparison times for long words.
+//- Pinalias: B3,LTIN,EQIN,GTIN,GTOUT,EQOUT,LTOUT,GND,B0,A0,B1,A1,A2,B2,A3,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006379.PDF
+//-
+static NETLIST_START(TTL_7485_DIP)
+ TTL_7485(A)
+
+ DIPPINS( /* +--------------+ */
+ A.B3, /* B3 |1 ++ 16| VCC */ A.VCC,
+ A.LTIN, /* LTIN |2 15| A3 */ A.A3,
+ A.EQIN, /* EQIN |3 14| B2 */ A.B2,
+ A.GTIN, /* GTIN |4 7485 13| A2 */ A.A2,
+ A.GTOUT, /* GTOUT |5 12| A1 */ A.A1,
+ A.EQOUT, /* EQOUT |6 11| B1 */ A.B1,
+ A.LTOUT, /* LTOUT |7 10| A0 */ A.A0,
+ A.GND, /* GND |8 9| B0 */ A.B0
+ /* +--------------+ */
+ )
+NETLIST_END()
+//- Identifier: TTL_7486_DIP
+//- Title: 5486/DM5486/DM7486 Quad 2-Input Exclusive-OR Gates
+//- Description: This device contains four independent gates each of which performs the logic exclusive-OR function.
+//- Pinalias: A1,B1,Y1,A2,B2,Y2,GND,Y3,A3,B3,Y4,A4,B4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006531.PDF
+//-
+//- +---+---++---+
+//- | A | B || Y |
+//- +===+===++===+
+//- | 0 | 0 || 0 |
+//- | 0 | 1 || 1 |
+//- | 1 | 0 || 1 |
+//- | 1 | 1 || 0 |
+//- +---+---++---+
+//-
static NETLIST_START(TTL_7486_DIP)
TTL_7486_GATE(A)
TTL_7486_GATE(B)
@@ -663,44 +1228,419 @@ static NETLIST_START(TTL_7486_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
- A.B, /* B1 |2 13| B4 */ D.B,
- A.Q, /* Y1 |3 12| A4 */ D.A,
- B.A, /* A2 |4 7486 11| Y4 */ D.Q,
- B.B, /* B2 |5 10| B3 */ C.B,
- B.Q, /* Y2 |6 9| A3 */ C.A,
- A.GND,/* GND |7 8| Y3 */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B1 |2 13| B4 */ D.B,
+ A.Q, /* Y1 |3 12| A4 */ D.A,
+ B.A, /* A2 |4 7486 11| Y4 */ D.Q,
+ B.B, /* B2 |5 10| B3 */ C.B,
+ B.Q, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-#if (NL_USE_TRUTHTABLE_74107)
-#ifndef __PLIB_PREPROCESSOR__
-#define TTL_74107_TT(name) \
- NET_REGISTER_DEV(TTL_74107, name)
-#endif
+//- Identifier: TTL_7490_DIP
+//- Title: DM5490/DM7490A Decade Counter
+//- Description: These monolithic counters contain four
+//- master-slave flip-flops and additional gating to provide
+//- a divide-by-two counter and a three-stage binary counter
+//- for which the count cycle length is divide-by-five.
+//-
+//- These counters have a gated zero reset and
+//- also have gated set-to-nine inputs
+//- for use in BCD nine's complement applications.
+//-
+//- To use their maximum count length (decade), the B input is connected
+//- to the QA output. The input count pulses are applied to
+//- input A and the outputs are as described in the appropriate
+//- truth table. A symmetrical divide-by-ten count can be
+//- obtained from the by connecting the QD output to
+//- the A input and applying the input count to the B input
+//- which gives a divide-by-ten square wave at output QA.
+//- Pinalias: B,R01,R02,NC,VCC,R91,R92,QC,QB,GND,QD,QA,NC,A
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006533.PDF
+//-
+//- BCD Count Sequence BCD Bi-Quinary
+//- +-------++----+----+----+----+ +-------++----+----+----+----+
+//- | Count || QD | QC | QB | QA | | Count || QD | QC | QB | QA |
+//- +=======++====+====+====+====+ +=======++====+====+====+====+
+//- | 0 || 0 | 0 | 0 | 0 | | 0 || 0 | 0 | 0 | 0 |
+//- | 1 || 0 | 0 | 0 | 1 | | 1 || 0 | 0 | 0 | 1 |
+//- | 2 || 0 | 0 | 1 | 0 | | 2 || 0 | 0 | 1 | 0 |
+//- | 3 || 0 | 0 | 1 | 1 | | 3 || 0 | 0 | 1 | 1 |
+//- | 4 || 0 | 1 | 0 | 0 | | 4 || 0 | 1 | 0 | 0 |
+//- | 5 || 0 | 1 | 0 | 1 | | 5 || 1 | 0 | 0 | 0 |
+//- | 6 || 0 | 1 | 1 | 0 | | 6 || 1 | 0 | 0 | 1 |
+//- | 7 || 0 | 1 | 1 | 1 | | 7 || 1 | 0 | 1 | 0 |
+//- | 8 || 1 | 0 | 0 | 0 | | 8 || 1 | 0 | 1 | 1 |
+//- | 9 || 1 | 0 | 0 | 1 | | 9 || 1 | 1 | 0 | 0 |
+//- +-------++----+----+----+----+ +-------++----+----+----+----+
+//-
+//- Reset/Count Function Table
+//- +-----+-----+-----+-----++----+----+----+----+
+//- | R01 | R02 | R91 | R92 || QD | QC | QB | QA |
+//- +=====+=====+=====+=====++====+====+====+====+
+//- | 1 | 1 | 0 | X || 0 | 0 | 0 | 0 |
+//- | 1 | 1 | X | 0 || 0 | 0 | 0 | 0 |
+//- | X | X | 1 | 1 || 1 | 0 | 0 | 1 |
+//- | X | 0 | X | 0 || COUNT |
+//- | 0 | X | 0 | X || COUNT |
+//- | 0 | X | X | 0 || COUNT |
+//- | X | 0 | 0 | X || COUNT |
+//- +-----+-----+-----+-----++----+----+----+----+
+//-
+static NETLIST_START(TTL_7490_DIP)
+ TTL_7490(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.B, /* B |1 ++ 14| A */ A.A,
+ A.R1, /* R01 |2 13| NC */ NC.I,
+ A.R2, /* R02 |3 12| QA */ A.QA,
+ NC.I, /* NC |4 7490 11| QD */ A.QD,
+ A.VCC, /* VCC |5 10| GND */ A.GND,
+ A.R91, /* R91 |6 9| QB */ A.QB,
+ A.R92, /* R92 |7 8| QC */ A.QC
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7492_DIP
+//- Title: SN5492A, SN54LS92, SN7492A, SN74LS92 Divide-By-Twelve Counter
+//- Description: These monolithic counters contains four
+//- master-slave flip-flops and additional gating to provide
+//- a divide-by-two counter and a three-stage binary counter
+//- for which the count cycle length is divide-by-six.
+//-
+//- These counters have a gated zero reset.
+//-
+//- To use their maximum count length (divide-by-
+//- twelve), the B input is connected
+//- to the QA output. The input count pulses are applied to
+//- input A and the outputs are as described in the appropriate
+//- truth table.
+//- Pinalias: CKB,NC,NC,NC,VCC,R01,R02,QD,QC,GND,QB,QA,NC,CLKA
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Texas Instruments datasheet
+//- FunctionTable:
+//- https://pdf1.alldatasheet.com/datasheet-pdf/view/27430/TI/SN7492A.html
+//-
+//- Count Sequence
+//- +-------++----+----+----+----+
+//- | Count || QD | QC | QB | QA |
+//- +=======++====+====+====+====+
+//- | 0 || 0 | 0 | 0 | 0 |
+//- | 1 || 0 | 0 | 0 | 1 |
+//- | 2 || 0 | 0 | 1 | 0 |
+//- | 3 || 0 | 0 | 1 | 1 |
+//- | 4 || 0 | 1 | 0 | 0 |
+//- | 5 || 0 | 1 | 0 | 1 |
+//- | 6 || 1 | 0 | 0 | 0 |
+//- | 7 || 1 | 0 | 0 | 1 |
+//- | 8 || 1 | 0 | 1 | 0 |
+//- | 9 || 1 | 0 | 1 | 1 |
+//- | 10 || 1 | 1 | 0 | 0 |
+//- | 11 || 1 | 1 | 0 | 1 |
+//- +-------++----+----+----+----+
+//-
+//- Reset/Count Function Table
+//- +-----+-----++----+----+----+----+
+//- | R01 | R02 || QD | QC | QB | QA |
+//- +=====+=====++====+====+====+====+
+//- | 1 | 1 || 0 | 0 | 0 | 0 |
+//- | 0 | X || COUNT |
+//- | X | 0 || COUNT |
+//- +-----+-----++----+----+----+----+
+//-
+ static NETLIST_START(TTL_7492_DIP)
+ TTL_7492(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.B, /* CLKB |1 ++ 14| CLKA */ A.A,
+ NC.I, /* NC |2 13| NC */ NC.I,
+ NC.I, /* NC |3 12| QA */ A.QA,
+ NC.I, /* NC |4 7492 11| QD */ A.QD,
+ A.VCC, /* VCC |5 10| GND */ A.GND,
+ A.R1, /* R01 |6 9| QB */ A.QB,
+ A.R2, /* R02 |7 8| QC */ A.QC
+ /* +--------------+ */
+ )
+NETLIST_END()
+//- Identifier: TTL_7493_DIP
+//- Title: DM7493A Binary Counter
+//- Description: These monolithic counters contains four
+//- master-slave flip-flops and additional gating to provide
+//- a divide-by-two counter and a three-stage binary counter
+//- for which the count cycle length is divide-by-eight.
+//-
+//- These counters have a gated zero reset.
+//-
+//- To use their maximum count length (four-bit binary), the B input is connected
+//- to the QA output. The input count pulses are applied to
+//- input A and the outputs are as described in the appropriate
+//- truth table.
+//- Pinalias: B,R01,R02,NC,VCC,NC,NC,QC,QB,GND,QD,QA,NC,A
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006533.PDF
+//-
+//- Count Sequence
+//- +-------++----+----+----+----+
+//- | Count || QD | QC | QB | QA |
+//- +=======++====+====+====+====+
+//- | 0 || 0 | 0 | 0 | 0 |
+//- | 1 || 0 | 0 | 0 | 1 |
+//- | 2 || 0 | 0 | 1 | 0 |
+//- | 3 || 0 | 0 | 1 | 1 |
+//- | 4 || 0 | 1 | 0 | 0 |
+//- | 5 || 0 | 1 | 0 | 1 |
+//- | 6 || 0 | 1 | 1 | 0 |
+//- | 7 || 0 | 1 | 1 | 1 |
+//- | 8 || 1 | 0 | 0 | 0 |
+//- | 9 || 1 | 0 | 0 | 1 |
+//- | 10 || 1 | 0 | 1 | 0 |
+//- | 11 || 1 | 0 | 1 | 1 |
+//- | 12 || 1 | 1 | 0 | 0 |
+//- | 13 || 1 | 1 | 0 | 1 |
+//- | 14 || 1 | 1 | 1 | 0 |
+//- | 15 || 1 | 1 | 1 | 1 |
+//- +-------++----+----+----+----+
+//-
+//- Reset/Count Function Table
+//- +-----+-----++----+----+----+----+
+//- | R01 | R02 || QD | QC | QB | QA |
+//- +=====+=====++====+====+====+====+
+//- | 1 | 1 || 0 | 0 | 0 | 0 |
+//- | 0 | X || COUNT |
+//- | X | 0 || COUNT |
+//- +-----+-----++----+----+----+----+
+//-
+ static NETLIST_START(TTL_7493_DIP)
+ TTL_7493(A)
+ NC_PIN(NC)
+
+ DIPPINS( /* +--------------+ */
+ A.CLKB, /* CLKB |1 ++ 14| CLKA */ A.CLKA,
+ A.R1, /* R01 |2 13| NC */ NC.I,
+ A.R2, /* R02 |3 12| QA */ A.QA,
+ NC.I, /* NC |4 7493 11| QD */ A.QD,
+ A.VCC, /* VCC |5 10| GND */ A.GND,
+ NC.I, /* NC |6 9| QB */ A.QB,
+ NC.I, /* NC |7 8| QC */ A.QC
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_7497_DIP
+//- Title: 5497/DM7497 Synchronous Modulo-64 Bit Rate Multiplier
+//- Description: The ’97 contains a synchronous 6-stage binary counter and six decoding gates that serve to gate the clock through to the output at a sub-multiple of the input frequency.
+//- The output pulse rate, relative to the clock frequency, is determined by signals applied to the Select (S0–S5) inputs.
+//- Both true and complement outputs are available, along with an enable input for each.
+//- A Count Enable input and a Terminal Count output are provided for cascading two or more packages.
+//- An asynchronous Master Reset input prevents counting and resets the counter.
+//- Pinalias: S1,S4,S5,S0,ZQ,Y,TCQ,GND,CP,EZQ,CEQ,EY,MR,S2,S3,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009780.PDF
+//-
+static NETLIST_START(TTL_7497_DIP)
+ TTL_7497(A)
+
+ DIPPINS( /* +--------------+ */
+ A.B1, /* S1 |1 ++ 16| VCC */ A.VCC,
+ A.B4, /* S4 |2 15| S3 */ A.B3,
+ A.B5, /* S5 |3 14| S2 */ A.B2,
+ A.B0, /* S0 |4 7497 13| MR */ A.CLR,
+ A.ZQ, /* ZQ |5 12| EY */ A.UNITYQ,
+ A.Y, /* Y |6 11| CEQ */ A.ENQ,
+ A.ENOUTQ, /* TCQ |7 10| EZQ */ A.STRBQ,
+ A.GND, /* GND |8 9| CP */ A.CLK
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74107_DIP
+//- Title: SN54107, SN74107 Dual J-K Flip-Flops With Clear
+//- Description: The '107 contains two independent J-K flip-flops with individual J-K, clock, and direct clear inputs.
+//- The '107 is a positive pulse-triggered flip-flop.
+//- The J-K input data is loaded into the master while the clock is high and transferred to teh slave and the outputs on the high-to-low clock transition.
+//- For these devices the J and K inputs must be stable while the clock is high.
+//- Pinalias: 1J,1QQ,1Q,1K,2Q,2QQ,GND,2J,2CLK,2CLRQ,2K,1CLK,1CLRQ,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Texas Instruments datasheet
+//- FunctionTable:
+//- https://pdf1.alldatasheet.com/datasheet-pdf/view/840452/TI1/SN74107.html
+//-
+//- +------+-------+---+---++---+----+
+//- | CLRQ | CLK | J | K || Q | QQ |
+//- +======+=======+===+===++===+====+
+//- | 0 | X | X | X || 0 | 1 |
+//- | 1 | 0-1-0 | 0 | 0 || Q | QQ |
+//- | 1 | 0-1-0 | 1 | 0 || 1 | 0 |
+//- | 1 | 0-1-0 | 0 | 1 || 0 | 1 |
+//- | 1 | 0-1-0 | 1 | 1 || TOGGLE |
+//- +------+-------+---+---++---+----+
+//-
static NETLIST_START(TTL_74107_DIP)
+#if (NL_USE_TRUTHTABLE_74107)
TTL_74107_TT(A)
TTL_74107_TT(B)
+#else
+ TTL_74107(A)
+ TTL_74107(B)
+#endif
NET_C(A.VCC, B.VCC)
NET_C(A.GND, B.GND)
- DIPPINS( /* +--------------+ */
- A.J, /* 1J |1 ++ 14| VCC */ A.VCC,
- A.QQ, /* 1QQ |2 13| 1CLRQ */ A.CLRQ,
- A.Q, /* 1Q |3 12| 1CLK */ A.CLK,
- A.K, /* 1K |4 74107 11| 2K */ B.K,
- B.Q, /* 2Q |5 10| 2CLRQ */ B.CLRQ,
- B.QQ, /* 2QQ |6 9| 2CLK */ B.CLK,
- B.GND, /* GND |7 8| 2J */ B.J
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.J, /* 1J |1 ++ 14| VCC */ A.VCC,
+ A.QQ, /* 1QQ |2 13| 1CLRQ */ A.CLRQ,
+ A.Q, /* 1Q |3 12| 1CLK */ A.CLK,
+ A.K, /* 1K |4 74107 11| 2K */ B.K,
+ B.Q, /* 2Q |5 10| 2CLRQ */ B.CLRQ,
+ B.QQ, /* 2QQ |6 9| 2CLK */ B.CLK,
+ B.GND, /* GND |7 8| 2J */ B.J
+ /* +--------------+ */
)
+NETLIST_END()
+
+//- Identifier: TTL_74107A_DIP
+//- Title: DM54LS107A/DM74LS107A Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops withClear and Complementary Outputs
+//- Description: This device contains two independent negative-edge-triggered J-K flip-flops with complementary outputs.
+//- The J and K data is processed by the flip-flops on the falling edge of the clock pulse.
+//- The clock triggering occurs at a voltage level and is not directly related to the transition time of the negative going edge of the clock pulse.
+//- The data on the J and K inputs may change while the clock is high or low without affecting the outputs as long as setup and hold times are not violated.
+//- A low logic level on the clear input will reset the outputs regardless of the logic levels of the other inputs.
+//- Pinalias: J1,QQ1,Q1,K1,Q2,QQ2,GND,J2,CLK2,CLRQ2,K2,CLK1,CLRQ1,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006367.PDF
+//-
+//- +------+-----+---+---++---+----+
+//- | CLRQ | CLK | J | K || Q | QQ |
+//- +======+=====+===+===++===+====+
+//- | 0 | X | X | X || 0 | 1 |
+//- | 1 | 1-0 | 0 | 0 || Q | QQ |
+//- | 1 | 1-0 | 1 | 0 || 1 | 0 |
+//- | 1 | 1-0 | 0 | 1 || 0 | 1 |
+//- | 1 | 1-0 | 1 | 1 || TOGGLE |
+//- | 1 | 1 | X | X || Q | QQ |
+//- +------+-----+---+---++---+----+
+//-
+static NETLIST_START(TTL_74107A_DIP)
+ TTL_74107A(A)
+ TTL_74107A(B)
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.J, /* J1 |1 ++ 14| VCC */ A.VCC,
+ A.QQ, /* QQ1 |2 13| CLRQ1 */ A.CLRQ,
+ A.Q, /* Q1 |3 12| CLK1 */ A.CLK,
+ A.K, /* K1 |4 74107A 11| K2 */ B.K,
+ B.Q, /* Q2 |5 10| CLRQ2 */ B.CLRQ,
+ B.QQ, /* QQ2 |6 9| CLK2 */ B.CLK,
+ B.GND, /* GND |7 8| J2 */ B.J
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74113_DIP
+//- Title: DM54S113/DM74S113 Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Preset and Complementary Outputs
+//- Description: This device contains two independent negative-edge-triggered J-K flip-flops with complementary outputs.
+//- The J and K data is processed by the flip-flops on the falling edge of the clock pulse.
+//- The clock triggering occurs at a voltage level and is not directly related to the transition time of the negative going edge of the clock pulse.
+//- Data on the J and K inputs may be changed while the clock is high or low without affecting the outputs as long as setup and hold times are not violated.
+//- A low logic level on the preset input will set the outputs regardless of the logic levels of the other inputs.
+//- Pinalias: CLK1,K1,J1,PRQ1,Q1,QQ1,GND,QQ2,Q2,PRQ2,J2,K2,CLK2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Texas Instruments datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006460.PDF
+//-
+//- +-----+-----+---+---++---+----+
+//- | PRQ | CLK | J | K || Q | QQ |
+//- +=====+=====+===+===++===+====+
+//- | 0 | X | X | X || 1 | 0 |
+//- | 1 | 1-0 | 0 | 0 || Q | QQ |
+//- | 1 | 1-0 | 1 | 0 || 1 | 0 |
+//- | 1 | 1-0 | 0 | 1 || 0 | 1 |
+//- | 1 | 1-0 | 1 | 1 || TOGGLE |
+//- | 1 | 1 | X | X || Q | QQ |
+//- +-----+-----+---+---++---+----+
+//-
+static NETLIST_START(TTL_74113_DIP)
+ TTL_74113(A)
+ TTL_74113(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.CLK, /* CLK1 |1 ++ 14| VCC */ A.VCC,
+ A.K, /* K1 |2 13| CLK2 */ B.CLK,
+ A.J, /* J1 |3 12| K2 */ B.K,
+ A.SETQ, /* PRQ1 |4 74113 11| J2 */ B.J,
+ A.Q, /* Q1 |5 10| PRQ2 */ B.SETQ,
+ A.QQ, /* QQ1 |6 9| Q2 */ B.Q,
+ A.GND, /* GND |7 8| QQ2 */ B.QQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74113A_DIP
+//- Title: DM54S113/DM74S113 Dual Negative-Edge-Triggered Master-Slave J-K Flip-Flops with Preset and Complementary Outputs
+//- Description: This device contains two independent negative-edge-triggered J-K flip-flops with complementary outputs.
+//- The J and K data is processed by the flip-flops on the falling edge of the clock pulse.
+//- The clock triggering occurs at a voltage level and is not directly related to the transition time of the negative going edge of the clock pulse.
+//- Data on the J and K inputs may be changed while the clock is high or low without affecting the outputs as long as setup and hold times are not violated.
+//- A low logic level on the preset input will set the outputs regardless of the logic levels of the other inputs.
+//- Pinalias: CLK1,K1,J1,PRQ1,Q1,QQ1,GND,QQ2,Q2,PRQ2,J2,K2,CLK2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Texas Instruments datasheet
+//- FunctionTable:
+//- https://pdf1.alldatasheet.com/datasheet-pdf/view/131122/TI/SN74LS113A.html
+//-
+//- +------+-----+---+---++---+----+
+//- | PREQ | CLK | J | K || Q | QQ |
+//- +======+=====+===+===++===+====+
+//- | 0 | X | X | X || 1 | 0 |
+//- | 1 | 1-0 | 0 | 0 || Q | QQ |
+//- | 1 | 1-0 | 1 | 0 || 1 | 0 |
+//- | 1 | 1-0 | 0 | 1 || 0 | 1 |
+//- | 1 | 1-0 | 1 | 1 || TOGGLE |
+//- | 1 | 1 | X | X || Q | QQ |
+//- +------+-----+---+---++---+----+
+//-
+static NETLIST_START(TTL_74113A_DIP)
+ TTL_74113A(A)
+ TTL_74113A(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.CLK, /* CLK1 |1 ++ 14| VCC */ A.VCC,
+ A.K, /* K1 |2 13| CLK2 */ B.CLK,
+ A.J, /* J1 |3 12| K2 */ B.K,
+ A.SETQ, /* PRQ1 |4 74113A 11| J2 */ B.J,
+ A.Q, /* Q1 |5 10| PRQ2 */ B.SETQ,
+ A.QQ, /* QQ1 |6 9| Q2 */ B.Q,
+ A.GND, /* GND |7 8| QQ2 */ B.QQ
+ /* +--------------+ */
+ )
NETLIST_END()
-#endif
//- Identifier: TTL_74121_DIP
//- Title: DM74121 One-Shot with Clear and Complementary Outputs
@@ -728,33 +1668,26 @@ NETLIST_END()
//- https://pdf1.alldatasheet.com/datasheet-pdf/view/50894/FAIRCHILD/74121.html
//-
static NETLIST_START(TTL_74121_DIP)
-
TTL_74121(A)
+ NC_PIN(NC)
RES(RINT, RES_K(2))
- RES(RD, RES_M(1000))
-
- ALIAS(1, A.QQ)
- //ALIAS(2", ); NC
- ALIAS(3, A.A1)
- ALIAS(4, A.A2)
- ALIAS(5, A.B)
- ALIAS(6, A.Q)
- ALIAS(7, A.GND)
-
- //ALIAS(8", ); NC
- ALIAS(9, RINT.1) // RINT
- ALIAS(10, A.C) // CEXT
- ALIAS(11, A.RC) // REXT
- //ALIAS(12", ); NC
- //ALIAS(13", ); NC
- ALIAS(14, A.VCC)
+ RES(RD, RES_M(1000))
NET_C(RINT.2, A.RC)
-
// Avoid error messages if RINT is not used.
NET_C(RINT.1, RD.2)
NET_C(RD.1, A.GND)
+ DIPPINS( /* +--------------+ */
+ A.QQ, /* QQ |1 ++ 14| VCC */ A.VCC,
+ NC.I, /* NC |2 13| NC */ NC.I,
+ A.A1, /* A1 |3 12| NC */ NC.I,
+ A.A2, /* A2 |4 74121 11| REXT/CEXT */ A.RC,
+ A.B, /* B |5 10| CEXT */ A.C,
+ A.Q, /* Q |6 9| RINT */ RINT.1,
+ A.GND, /* GND |7 8| NC */ NC.I
+ /* +--------------+ */
+ )
NETLIST_END()
//- Identifier: TTL_74123_DIP
@@ -785,85 +1718,23 @@ NETLIST_END()
//- https://pdf1.alldatasheet.com/datasheet-pdf/view/50893/FAIRCHILD/DM74123.html
//-
static NETLIST_START(TTL_74123_DIP)
-
TTL_74123(A)
TTL_74123(B)
- ALIAS(1, A.A)
- ALIAS(2, A.B)
- ALIAS(3, A.CLRQ)
- ALIAS(4, A.QQ)
- ALIAS(5, B.Q)
- ALIAS(6, B.C) // CEXT
- ALIAS(7, B.RC) // REXT
- ALIAS(8, A.GND)
-
- ALIAS(9, B.A)
- ALIAS(10, B.B)
- ALIAS(11, B.CLRQ)
- ALIAS(12, B.QQ)
- ALIAS(13, A.Q)
- ALIAS(14, A.C) // CEXT
- ALIAS(15, A.RC) // REXT
- ALIAS(16, A.VCC)
-
NET_C(A.VCC, B.VCC)
NET_C(A.GND, B.GND)
-NETLIST_END()
-
-//- Identifier: TTL_9602_DIP
-//- Title: DM9602 Dual Retriggerable, Resettable One Shots
-//- Description: These dual resettable, retriggerable one shots have two
-//- inputs per function; one which is active HIGH, and one
-//- which is active LOW. This allows the designer to employ
-//- either leading-edge or trailing-edge triggering, which is
-//- independent of input transition times. When input conditions for triggering are met, a new cycle starts and the
-//- external capacitor is allowed to rapidly discharge and then
-//- charge again. The retriggerable feature permits output
-//- pulse widths to be extended. In fact a continuous true output can be maintained by having an input cycle time which
-//- is shorter than the output cycle time. The output pulse may
-//- then be terminated at any time by applying a LOW logic
-//- level to the RESET pin. Retriggering may be inhibited by
-//- either connecting the Q output to an active HIGH input, or
-//- the Q output to an active LOW input.
-//- The DM74123 is a dual retriggerable monostable multivibrator
-//-
-//- Pinalias: C1,RC1,CLRQ1,B1,A1,Q1,QQ1,GND,QQ2,Q2,A2,B2,CLRQ2,RC2,C2,VCC
-//- Package: DIP
-//- NamingConvention: Naming conventions follow Fairchild Semiconductor datasheet
-//- Limitations:
-//- Timing inaccuracies may occur for capacitances < 1nF. Please consult datasheet
-//-
-//- Example: 74123.cpp,74123_example
-//-
-//- FunctionTable:
-//- https://pdf1.alldatasheet.com/datasheet-pdf/view/51137/FAIRCHILD/DM9602.html
-//-
-static NETLIST_START(TTL_9602_DIP)
-
- TTL_9602(A)
- TTL_9602(B)
-
- ALIAS(1, A.C) // C1
- ALIAS(2, A.RC) // RC1
- ALIAS(3, A.CLRQ)
- ALIAS(4, A.B)
- ALIAS(5, A.A)
- ALIAS(6, A.Q)
- ALIAS(7, A.QQ)
- ALIAS(8, A.GND)
-
- ALIAS(9, B.QQ)
- ALIAS(10, B.Q)
- ALIAS(11, B.A)
- ALIAS(12, B.B)
- ALIAS(13, B.CLRQ)
- ALIAS(14, B.RC) // RC2
- ALIAS(15, B.C) // C2
- ALIAS(16, A.VCC)
- NET_C(A.VCC, B.VCC)
- NET_C(A.GND, B.GND)
+ DIPPINS( /* +--------------+ */
+ A.A, /* A1 |1 ++ 16| VCC */ A.VCC,
+ A.B, /* B1 |2 15| RC1 */ A.RC,
+ A.CLRQ, /* CLRQ1 |3 14| C1 */ A.C,
+ A.QQ, /* QQ1 |4 74123 13| Q1 */ A.Q,
+ B.Q, /* Q2 |5 12| QQ2 */ B.QQ,
+ B.C, /* C2 |6 11| CLRQ */ B.CLRQ,
+ B.RC, /* RC2 |7 10| B2 */ B.B,
+ A.GND, /* GND |8 9| A2 */ B.A
+ /* +--------------+ */
+ )
NETLIST_END()
//- Identifier: TTL_74125_DIP
@@ -898,103 +1769,170 @@ NETLIST_END()
//- | L | H | H |
//- | H | X | Z |
//-
-
static NETLIST_START(TTL_74125_DIP)
+ TTL_74125_GATE(A)
+ TTL_74125_GATE(B)
+ TTL_74125_GATE(C)
+ TTL_74125_GATE(D)
- TTL_74125_GATE(A1)
- TTL_74125_GATE(A2)
- TTL_74125_GATE(A3)
- TTL_74125_GATE(A4)
-
- DEFPARAM(FORCE_TRISTATE_LOGIC, "$(@.A1.FORCE_TRISTATE_LOGIC")
+ NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
+ NET_C(A.GND, B.GND, C.GND, D.GND)
- PARAM(A1.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
- PARAM(A2.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
- PARAM(A3.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
- PARAM(A4.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ DEFPARAM(FORCE_TRISTATE_LOGIC, "$(@.A.FORCE_TRISTATE_LOGIC")
+ PARAM(A.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ PARAM(B.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ PARAM(C.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ PARAM(D.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+
+ DIPPINS( /* +--------------+ */
+ A.GQ, /* 1GQ |1 ++ 14| VCC */ A.VCC,
+ A.A, /* 1A |2 13| 4GQ */ D.GQ,
+ A.Y, /* 1Y |3 12| 4A */ D.A,
+ B.GQ, /* 2GQ |4 74125 11| 4Y */ D.Y,
+ B.A, /* 2A |5 10| 3GQ */ C.GQ,
+ B.Y, /* 2Y |6 9| 3A */ C.A,
+ A.GND, /* GND |7 8| 3Y */ C.Y
+ /* +--------------+ */
+ )
+NETLIST_END()
- ALIAS(1, A1.GQ)
- ALIAS(2, A1.A)
- ALIAS(3, A1.Y)
- ALIAS(4, A2.GQ)
- ALIAS(5, A2.A)
- ALIAS(6, A2.Y)
- ALIAS(7, A1.GND)
+//- Identifier: TTL_74126_DIP
+//- Title: DM74LS126A Quad 3-STATE Buffer
+//- Description: This device contains four independent gates each of which performs a non-inverting buffer function.
+//- The outputs have the 3-STATE feature.
+//- When enabled, the outputs exhibit the low impedance characteristics of a standard LS output with additional drive capability to permit the driving of buslines without external resistors.
+//- When disabled, both the output transistors are turned OFF presenting a high-impedance state to the bus line.
+//- Thus the output will act neither as a significant load nor as a driver.
+//- To minimize the possibility that two outputs will attempt to take a common bus to opposite logic levels, the disable time is shorter than the enable time of the outputs.
+//- Pinalias: C1,A1,Y1,C2,A2,Y2,GND,Y3,A3,C3,Y4,A4,C4,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/50/232293_DS.pdf
+//-
+//- +---+---++------+
+//- | A | C || Y |
+//- +===+===++======+
+//- | 0 | 1 || 0 |
+//- | 1 | 1 || 1 |
+//- | X | 0 || Hi-Z |
+//- +---+---++------+
+//-
+static NETLIST_START(TTL_74126_DIP)
+ TTL_74126_GATE(A)
+ TTL_74126_GATE(B)
+ TTL_74126_GATE(C)
+ TTL_74126_GATE(D)
- ALIAS(8, A3.Y)
- ALIAS(9, A3.A)
- ALIAS(10, A3.GQ)
- ALIAS(11, A4.Y)
- ALIAS(12, A4.A)
- ALIAS(13, A4.GQ)
- ALIAS(14, A1.VCC)
+ NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
+ NET_C(A.GND, B.GND, C.GND, D.GND)
- NET_C(A1.VCC, A2.VCC, A3.VCC, A4.VCC)
- NET_C(A1.GND, A2.GND, A3.GND, A4.GND)
+ DEFPARAM(FORCE_TRISTATE_LOGIC, 0)
+ PARAM(A.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ PARAM(B.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ PARAM(C.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+ PARAM(D.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
+
+ DIPPINS( /* +--------------+ */
+ A.G, /* C1 |1 ++ 14| VCC */ A.VCC,
+ A.A, /* A1 |2 13| C4 */ D.G,
+ A.Y, /* Y1 |3 12| A4 */ D.A,
+ B.G, /* C2 |4 74126 11| Y4 */ D.Y,
+ B.A, /* A2 |5 10| C3 */ C.G,
+ B.Y, /* Y2 |6 9| A3 */ C.A,
+ A.GND, /* GND |7 8| Y3 */ C.Y
+ /* +--------------+ */
+ )
NETLIST_END()
-static NETLIST_START(TTL_74126_DIP)
+//- Identifier: TTL_74153_DIP
+//- Title: 54153/DM54153/DM74153 Dual 4-Line to 1-LineData Selectors/Multiplexers
+//- Description: Each of these data selectors/multiplexers contains inverters and drivers to supply fully complementary, on-chip, binary decoding data selection to the AND-OR-invert gates.
+//- Separate strobe inputs are provided for each of the two four-line sections.
+//- Pinalias: G1,B,1C3,1C2,1C1,1C0,Y1,GND,Y2,2C0,2C1,2C2,2C3,A,G2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006547.PDF
+//-
+//- +---+---+----+----+----+----+---++---+
+//- | B | A | C0 | C1 | C2 | C3 | G || Y |
+//- +===+===+====+====+====+====+===++===+
+//- | X | X | X | X | X | X | 1 || 0 |
+//- | 0 | 0 | 0 | X | X | X | 0 || 0 |
+//- | 0 | 0 | 1 | X | X | X | 0 || 1 |
+//- | 0 | 1 | X | 0 | X | X | 0 || 0 |
+//- | 0 | 1 | X | 1 | X | X | 0 || 1 |
+//- | 1 | 0 | X | X | 0 | X | 0 || 0 |
+//- | 1 | 0 | X | X | 1 | X | 0 || 1 |
+//- | 1 | 1 | X | X | X | 0 | 0 || 0 |
+//- | 1 | 1 | X | X | X | 1 | 0 || 1 |
+//- +---+---+----+----+----+----+---++---+
+//-
+static NETLIST_START(TTL_74153_DIP)
+ NET_REGISTER_DEV(TTL_74153, A)
+ NET_REGISTER_DEV(TTL_74153, B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
- TTL_74126_GATE(A1)
- TTL_74126_GATE(A2)
- TTL_74126_GATE(A3)
- TTL_74126_GATE(A4)
+ NET_C(A.A, B.A)
+ NET_C(A.B, B.B)
- DEFPARAM(FORCE_TRISTATE_LOGIC, 0)
- PARAM(A1.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
- PARAM(A2.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
- PARAM(A3.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
- PARAM(A4.FORCE_TRISTATE_LOGIC, "$(@.FORCE_TRISTATE_LOGIC)")
-
- ALIAS(1, A1.G)
- ALIAS(2, A1.A)
- ALIAS(3, A1.Y)
- ALIAS(4, A2.G)
- ALIAS(5, A2.A)
- ALIAS(6, A2.Y)
- ALIAS(7, A1.GND)
-
- ALIAS(8, A3.Y)
- ALIAS(9, A3.A)
- ALIAS(10, A3.G)
- ALIAS(11, A4.Y)
- ALIAS(12, A4.A)
- ALIAS(13, A4.G)
- ALIAS(14, A1.VCC)
-
- NET_C(A1.VCC, A2.VCC, A3.VCC, A4.VCC)
- NET_C(A1.GND, A2.GND, A3.GND, A4.GND)
-NETLIST_END()
-
-/*
- * DM74155/DM74156: Dual 2-Line to 4-Line Decoders/Demultiplexers
- *
- * +-----+-------++-----------------+
- * | B A | G1 C1 || 1Y0 1Y1 1Y2 1Y3 |
- * +=====+=======++=================+
- * | X X | 1 X || 1 1 1 1 |
- * | 0 0 | 0 1 || 0 1 1 1 |
- * | 0 1 | 0 1 || 1 0 1 1 |
- * | 1 0 | 0 1 || 1 1 0 1 |
- * | 1 1 | 0 1 || 1 1 1 0 |
- * | X X | X 0 || 1 1 1 1 |
- * +-----+-------++-----------------+
- *
- * +-----+-------++-----------------+
- * | B A | G2 C2 || 2Y0 2Y1 2Y2 2Y3 |
- * +=====+=======++=================+
- * | X X | 1 X || 1 1 1 1 |
- * | 0 0 | 0 0 || 0 1 1 1 |
- * | 0 1 | 0 0 || 1 0 1 1 |
- * | 1 0 | 0 0 || 1 1 0 1 |
- * | 1 1 | 0 0 || 1 1 1 0 |
- * | X X | X 1 || 1 1 1 1 |
- * +-----+-------++-----------------+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
+ DIPPINS( /* +--------------+ */
+ A.G, /* G1 |1 ++ 16| VCC */ A.VCC,
+ A.B, /* B |2 15| G2 */ B.G,
+ A.C3, /* 1C3 |3 14| A */ A.A,
+ A.C2, /* 1C2 |4 74153 13| 2C3 */ B.C3,
+ A.C1, /* 1C1 |5 12| 2C2 */ B.C2,
+ A.C0, /* 1C0 |6 11| 2C1 */ B.C1,
+ A.AY, /* Y1 |7 10| 2C0 */ B.C0,
+ A.GND, /* GND |8 9| Y2 */ B.AY
+ /* +--------------+ */
+ )
+NETLIST_END()
+//- Identifier: TTL_74155_DIP
+//- Title: 54LS155/DM54LS155/DM74LS155 Dual 2-Line to 4-Line Decoders/Demultiplexers
+//- Description: These TTL circuits feature dual 1-line-to-4-line demultiplexers with individual strobes and common binary-address inputs in a single 16-pin package.
+//- When both sections are enabled by the strobes, the common address inputs sequentially select and route associated input data to the appropriate output of each section.
+//- The individual strobes permit activating or inhibiting each of the 4-bit sections as desired.
+//- Data applied to input C1 is inverted at its outputs anddata applied at C2 is true through its outputs.
+//- The inverter following the C1 data input permits use as a 3-to-8-line decoder, or 1-to-8-line demultiplexer, without external gating.
+//- Input clamping diodes are provided on these circuits to minimize transmission-line effects and simplify system design.
+//- Pinalias: C1,G1,B,1Y3,1Y2,1Y1,1Y0,GND,2Y0,2Y1,2Y2,2Y3,A,G2,C2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006395.PDF
+//-
+//- 2-line-to-4-line decoder 2-line-to-4-line decoder
+//- +---+---+----+----++-----+-----+-----+-----+ +---+---+----+----++-----+-----+-----+-----+
+//- | B | A | G1 | C1 || 1Y0 | 1Y1 | 1Y2 | 1Y3 | | B | A | G2 | C2 || 2Y0 | 2Y1 | 2Y2 | 2Y3 |
+//- +===+===+====+====++=====+=====+=====+=====+ +===+===+====+====++=====+=====+=====+=====+
+//- | X | X | 1 | X || 1 | 1 | 1 | 1 | | X | X | 1 | X || 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 0 | 1 || 0 | 1 | 1 | 1 | | 0 | 0 | 0 | 0 || 0 | 1 | 1 | 1 |
+//- | 0 | 1 | 0 | 1 || 1 | 0 | 1 | 1 | | 0 | 1 | 0 | 0 || 1 | 0 | 1 | 1 |
+//- | 1 | 0 | 0 | 1 || 1 | 1 | 0 | 1 | | 1 | 0 | 0 | 0 || 1 | 1 | 0 | 1 |
+//- | 1 | 1 | 0 | 1 || 1 | 1 | 1 | 0 | | 1 | 1 | 0 | 0 || 1 | 1 | 1 | 0 |
+//- | X | X | X | 0 || 1 | 1 | 1 | 1 | | X | X | X | 1 || 1 | 1 | 1 | 1 |
+//- +---+---+----+----++-----+-----+-----+-----+ +---+---+----+----++-----+-----+-----+-----+
+//-
+//- 3-line-to-8-line decoder
+//- +---+---+---+---++-----+-----+-----+-----+-----+-----+-----+-----+
+//- | C | B | A | G || 2Y0 | 2Y1 | 2Y2 | 2Y3 | 1Y0 | 1Y1 | 1Y2 | 1Y3 |
+//- +===+===+===+===++=====+=====+=====+=====+=====+=====+=====+=====+
+//- | X | X | X | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 0 | 0 || 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 1 | 0 || 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 0 | 0 || 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 1 | 0 || 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 |
+//- | 1 | 0 | 0 | 0 || 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 |
+//- | 1 | 0 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 |
+//- | 1 | 1 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 |
+//- | 1 | 1 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 |
+//- +---+---+---+---++-----+-----+-----+-----+-----+-----+-----+-----+
+//-
static NETLIST_START(TTL_74155_DIP)
NET_REGISTER_DEV(TTL_74155A_GATE, A)
NET_REGISTER_DEV(TTL_74155B_GATE, B)
@@ -1005,19 +1943,60 @@ static NETLIST_START(TTL_74155_DIP)
NET_C(A.VCC, B.VCC)
NET_C(A.GND, B.GND)
- DIPPINS( /* +--------------+ */
- A.C, /* C1 |1 ++ 16| VCC */ A.VCC,
- A.G, /* G1 |2 15| B4 */ B.C,
- A.B, /* B |3 14| B4 */ B.G,
- A.3, /* 1Y3 |4 74155 13| A4 */ B.A,
- B.2, /* 1Y2 |5 12| Y4 */ B.3,
- B.1, /* 1Y1 |6 11| B3 */ B.2,
- B.0, /* 1Y0 |7 10| A3 */ B.1,
- A.GND,/* GND |8 9| Y3 */ B.0
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.C, /* C1 |1 ++ 16| VCC */ A.VCC,
+ A.G, /* G1 |2 15| B4 */ B.C,
+ A.B, /* B |3 14| B4 */ B.G,
+ A.3, /* 1Y3 |4 74155 13| A4 */ B.A,
+ B.2, /* 1Y2 |5 12| Y4 */ B.3,
+ B.1, /* 1Y1 |6 11| B3 */ B.2,
+ B.0, /* 1Y0 |7 10| A3 */ B.1,
+ A.GND, /* GND |8 9| Y3 */ B.0
+ /* +--------------+ */
)
NETLIST_END()
+//- Identifier: TTL_74156_DIP
+//- Title: 54LS156/DM54LS156/DM74LS156 Dual 2-Line to 4-Line Decoders/Demultiplexers with Open-Collector Outputs
+//- Description: These TTL circuits feature dual 1-line-to-4-line demultiplexers with individual strobes and common binary-address inputs in a single 16-pin package.
+//- When both sections are enabled by the strobes, the common address inputs sequentially select and route associated input data to the appropriate output of each section.
+//- The individual strobes permit activating or inhibiting each of the 4-bit sections as desired.
+//- Data applied to input C1 is inverted at its outputs anddata applied at C2 is true through its outputs.
+//- The inverter following the C1 data input permits use as a 3-to-8-line decoder, or 1-to-8-line demultiplexer, without external gating.
+//- Input clamping diodes are provided on these circuits to minimize transmission-line effects and simplify system design.
+//- Pinalias: C1,G1,B,1Y3,1Y2,1Y1,1Y0,GND,2Y0,2Y1,2Y2,2Y3,A,G2,C2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006395.PDF
+//-
+//- 2-line-to-4-line decoder 2-line-to-4-line decoder
+//- +---+---+----+----++-----+-----+-----+-----+ +---+---+----+----++-----+-----+-----+-----+
+//- | B | A | G1 | C1 || 1Y0 | 1Y1 | 1Y2 | 1Y3 | | B | A | G2 | C2 || 2Y0 | 2Y1 | 2Y2 | 2Y3 |
+//- +===+===+====+====++=====+=====+=====+=====+ +===+===+====+====++=====+=====+=====+=====+
+//- | X | X | 1 | X || 1 | 1 | 1 | 1 | | X | X | 1 | X || 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 0 | 1 || 0 | 1 | 1 | 1 | | 0 | 0 | 0 | 0 || 0 | 1 | 1 | 1 |
+//- | 0 | 1 | 0 | 1 || 1 | 0 | 1 | 1 | | 0 | 1 | 0 | 0 || 1 | 0 | 1 | 1 |
+//- | 1 | 0 | 0 | 1 || 1 | 1 | 0 | 1 | | 1 | 0 | 0 | 0 || 1 | 1 | 0 | 1 |
+//- | 1 | 1 | 0 | 1 || 1 | 1 | 1 | 0 | | 1 | 1 | 0 | 0 || 1 | 1 | 1 | 0 |
+//- | X | X | X | 0 || 1 | 1 | 1 | 1 | | X | X | X | 1 || 1 | 1 | 1 | 1 |
+//- +---+---+----+----++-----+-----+-----+-----+ +---+---+----+----++-----+-----+-----+-----+
+//-
+//- 3-line-to-8-line decoder
+//- +---+---+---+---++-----+-----+-----+-----+-----+-----+-----+-----+
+//- | C | B | A | G || 2Y0 | 2Y1 | 2Y2 | 2Y3 | 1Y0 | 1Y1 | 1Y2 | 1Y3 |
+//- +===+===+===+===++=====+=====+=====+=====+=====+=====+=====+=====+
+//- | X | X | X | 1 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 0 | 0 || 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 0 | 1 | 0 || 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 0 | 0 || 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 |
+//- | 0 | 1 | 1 | 0 || 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 |
+//- | 1 | 0 | 0 | 0 || 1 | 1 | 1 | 1 | 0 | 1 | 1 | 1 |
+//- | 1 | 0 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 0 | 1 | 1 |
+//- | 1 | 1 | 0 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 |
+//- | 1 | 1 | 1 | 0 || 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 |
+//- +---+---+---+---++-----+-----+-----+-----+-----+-----+-----+-----+
+//-
static NETLIST_START(TTL_74156_DIP)
NET_REGISTER_DEV(TTL_74156A_GATE, A)
NET_REGISTER_DEV(TTL_74156B_GATE, B)
@@ -1028,36 +2007,40 @@ static NETLIST_START(TTL_74156_DIP)
NET_C(A.VCC, B.VCC)
NET_C(A.GND, B.GND)
- DIPPINS( /* +--------------+ */
- A.C, /* C1 |1 ++ 16| VCC */ A.VCC,
- A.G, /* G1 |2 15| B4 */ B.C,
- A.B, /* B |3 14| B4 */ B.G,
- A.3, /* 1Y3 |4 74156 13| A4 */ B.A,
- B.2, /* 1Y2 |5 12| Y4 */ B.3,
- B.1, /* 1Y1 |6 11| B3 */ B.2,
- B.0, /* 1Y0 |7 10| A3 */ B.1,
- A.GND,/* GND |8 9| Y3 */ B.0
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.C, /* C1 |1 ++ 16| VCC */ A.VCC,
+ A.G, /* G1 |2 15| B4 */ B.C,
+ A.B, /* B |3 14| B4 */ B.G,
+ A.3, /* 1Y3 |4 74156 13| A4 */ B.A,
+ B.2, /* 1Y2 |5 12| Y4 */ B.3,
+ B.1, /* 1Y1 |6 11| B3 */ B.2,
+ B.0, /* 1Y0 |7 10| A3 */ B.1,
+ A.GND, /* GND |8 9| Y3 */ B.0
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM74157: Quad 2-Input Multiplexor
- *
- * +---+---+-------+---+
- * | E | S | I0 I1 | Z |
- * +===+===+=======+===+
- * | 1 | X | X X | 0 |
- * | 0 | 1 | X 0 | 0 |
- * | 0 | 1 | X 1 | 1 |
- * | 0 | 0 | 0 X | 0 |
- * | 0 | 0 | 1 X | 1 |
- * +---+---+-------+---+
- *
- * Naming conventions follow TI datasheet
- *
- */
-
+//- Identifier: TTL_74157_DIP
+//- Title: 54157/DM54157/DM74157 Quad 2-Line to 1-Line Data Selectors/Multiplexers
+//- Description: These data selectors/multiplexers contain inverters and drivers to supply full on-chip data selection to the four output gates.
+//- A separate strobe input is provided.
+//- A 4-bit word is selected from one of two sources and is routed to the four outputs.
+//- Pinalias: S,A1,B1,Y1,A2,B2,Y2,GND,Y3,B3,A3,Y4,B4,A4,G,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/120/236599_DS.pdf
+//-
+//- +---+---+---+---++---+
+//- | G | S | A | B || Y |
+//- +===+===+===+===++===+
+//- | 1 | X | X | X || 0 |
+//- | 0 | 0 | 0 | X || 0 |
+//- | 0 | 0 | 1 | X || 1 |
+//- | 0 | 1 | X | 0 || 0 |
+//- | 0 | 1 | X | 1 || 1 |
+//- +---+---+---+---++---+
+//-
static NETLIST_START(TTL_74157_DIP)
NET_REGISTER_DEV(TTL_74157_GATE, A)
NET_REGISTER_DEV(TTL_74157_GATE, B)
@@ -1070,38 +2053,286 @@ static NETLIST_START(TTL_74157_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.S, /* S |1 ++ 16| VCC */ A.VCC,
- A.I, /* I0a |2 15| /E */ A.E,
- A.J, /* I1a |3 14| I0c */ C.I,
- A.O, /* Za |4 74157 13| I1c */ C.J,
- B.I, /* I0b |5 12| Zc */ C.O,
- B.J, /* I1b |6 11| I0d */ D.I,
- B.O, /* Zb |7 10| I1d */ D.J,
- A.GND,/* GND |8 9| Zd */ D.O
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.S, /* S |1 ++ 16| VCC */ A.VCC,
+ A.I, /* A1 |2 15| G */ A.E,
+ A.J, /* B1 |3 14| A4 */ D.I,
+ A.O, /* Y1 |4 74157 13| B4 */ D.J,
+ B.I, /* A2 |5 12| Y4 */ D.O,
+ B.J, /* B2 |6 11| A3 */ C.I,
+ B.O, /* Y2 |7 10| B3 */ C.J,
+ A.GND, /* GND |8 9| Y3 */ C.O
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM74260: Dual 5-Input NOR Gates
- * _________
- * Y = A+B+C+D+E
- * +---+---+---+---+---++---+
- * | A | B | B | B | B || Y |
- * +===+===+===+===+===++===+
- * | 0 | 0 | 0 | 0 | 0 || 1 |
- * | 0 | 0 | 0 | 0 | 1 || 0 |
- * | 0 | 0 | 0 | 1 | 0 || 0 |
- * | 0 | 0 | 1 | 0 | 0 || 0 |
- * | 0 | 1 | 0 | 0 | 0 || 0 |
- * | 1 | 0 | 0 | 0 | 0 || 0 |
- * +---+---+---+---+---++---+
- *
- * Naming conventions follow Texas Instruments datasheet
- *
- */
+//- Identifier: TTL_74161_DIP
+//- Title: DM54161/DM74161 Synchronous 4-Bit Counter
+//- Description: These synchronous, presettable counters feature an internal carry look-ahead for application in high-speed counting designs.
+//- The 161 is a 4-bit binary counter.
+//- The carry output is decoded by means of a NOR gate, thus preventing spikes during the normal counting mode of operation.
+//- Synchronous operation is provided by having all flip-flops clocked simultaneously so that the outputs change co-incident with each other when so instructed by the count-enable inputs and internal gating.
+//- This mode of operation eliminates the output counting spikes which are normally associated with asynchronous (ripple clock) counters.
+//- A buffered clock input triggers the four flip-flops on the rising (positive-going) edge of the clock input waveform.
+//- These counters are fully programmable; that is, the outputs may be preset to either level.
+//- As presetting is synchronous, setting up a low level at the load input disables the counter and causes the outputs to agree with the setup data after the next clock pulse, regardless of the levels of the enable input.
+//- The clear function for the 161 is asynchronous; and a low level at the clear input sets all four of the flip-flop outputs low, regardless of the levels of clock, load, or enable inputs.
+//- The carry look-ahead circuitry provides for cascading counters for n-bit synchronous applications without additional gating.
+//- Instrumental in accomplishing this function are two count-enable inputs and a ripple carry output.
+//- Both count-enable inputs (P and T) must be high to count, and input T is fed forward to enable the ripple carry output.
+//- The ripple carry output thus enabled will produce a high-level output pulse with a duration approximately equal to the high-level portion of the QA output.
+//- This high-level overflow ripple carry pulse can be used to enable successive cascaded stages.
+//- High-to-low-level transitions at the enable P or T inputs of the 161 may occur, regardless of the logic level on the clock.
+//- Pinalias: CLRQ,CLK,A,B,C,D,ENP,GND,LOADQ,ENT,QD,QC,QB,QA,RC,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006551.PDF
+//-
+static NETLIST_START(TTL_74161_DIP)
+ TTL_74161(A)
+
+ DIPPINS( /* +--------------+ */
+ A.CLRQ, /* /CLEAR |1 ++ 16| VCC */ A.VCC,
+ A.CLK, /* CLOCK |2 15| RC */ A.RC,
+ A.A, /* A |3 14| QA */ A.QA,
+ A.B, /* B |4 74161 13| QB */ A.QB,
+ A.C, /* C |5 12| QC */ A.QC,
+ A.D, /* D |6 11| QD */ A.QD,
+ A.ENP, /* Enable P |7 10| Enable T */ A.ENT,
+ A.GND, /* GND |8 9| /LOAD */ A.LOADQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74163_DIP
+//- Title: DM74163 Synchronous 4-Bit Counter
+//- Description: These synchronous, presettable counters feature an internal carry look-ahead for application in high-speed counting designs.
+//- The 163 is a 4-bit binary counter.
+//- The carry output is decoded by means of a NOR gate, thus preventing spikes during the normal counting mode of operation.
+//- Synchronous operation is provided by having all flip-flops clocked simultaneously so that the outputs change co-incident with each other when so instructed by the count-enable inputs and internal gating.
+//- This mode of operation eliminates the output counting spikes which are normally associated with asynchronous (ripple clock) counters.
+//- A buffered clock input triggers the four flip-flops on the rising (positive-going) edge of the clock input waveform.
+//- These counters are fully programmable; that is, the outputs may be preset to either level.
+//- As presetting is synchronous, setting up a low level at the load input disables the counter and causes the outputs to agree with the setup data after the next clock pulse, regardless of the levels of the enable input.
+//- The clear function for the 163 is synchronous; and a low level at the clear input sets all four of the flip-flop outputs low after the next clock pulse, regardless of the levels of the enable inputs.
+//- This synchronous clear allows the count length to be modified easily, as decoding the maximum count desired can be accomplished with one external NAND gate.
+//- The gate output is connected to the clear input to synchronously clear the counter to all low outputs.
+//- Low-to-high transitions at the clear input of the 163 are also permissible, regardless of the logic levels on the clock,enable, or load inputs.
+//- The carry look-ahead circuitry provides for cascading counters for n-bit synchronous applications without additional gating.
+//- Instrumental in accomplishing this function are two count-enable inputs and a ripple carry output.
+//- Both count-enable inputs (P and T) must be high to count, and input T is fed forward to enable the ripple carry output.
+//- The ripple carry output thus enabled will produce a high-level output pulse with a duration approximately equal to the high-level portion of the QA output.
+//- This high-level overflow ripple carry pulse can be used to enable successive cascaded stages.
+//- High-to-low-level transitions at the enable P or T inputs of the 163 may occur, regardless of the logic level on the clock.
+//- Pinalias: CLRQ,CLK,A,B,C,D,ENP,GND,LOADQ,ENT,QD,QC,QB,QA,RC,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006551.PDF
+//-
+static NETLIST_START(TTL_74163_DIP)
+ TTL_74163(A)
+
+ DIPPINS( /* +--------------+ */
+ A.CLRQ, /* /CLEAR |1 ++ 16| VCC */ A.VCC,
+ A.CLK, /* CLOCK |2 15| RC */ A.RC,
+ A.A, /* A |3 14| QA */ A.QA,
+ A.B, /* B |4 74163 13| QB */ A.QB,
+ A.C, /* C |5 12| QC */ A.QC,
+ A.D, /* D |6 11| QD */ A.QD,
+ A.ENP, /* Enable P |7 10| Enable T */ A.ENT,
+ A.GND, /* GND |8 9| /LOAD */ A.LOADQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74164_DIP
+//- Title: DM74164 8-Bit Serial In/Parallel Out Shift Registers
+//- Description: These 8-bit shift registers feature gated serial inputs and an asynchronous clear.
+//- A LOW logic level at either serial input inhibits entry of the new data, and resets the first flip-flop to the LOW level at the next clock pulse, thus providing complete control over incoming data.
+//- A HIGH logic level on either input enables the other input, which will then determine the state of the first flip-flop.
+//- Data at the serial inputs may be changed while the clock is HIGH or LOW, but only information meeting the setup and hold time requirements will be entered.
+//- Clocking occurs on the LOW-to-HIGH level transition of the clock input.
+//- All inputs are diode-clamped to minimize transmission-line effects
+//- Pinalias: A,B,QA,QB,QC,QD,GND,CLOCK,CLEAR,QE,QF,QG,QH,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Fairchild Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/fairchild/DM74164.pdf
+//-
+//- +-------+-------+---+---++----+----+-----+----+
+//- | CLEAR | CLOCK | A | B || QA | QB | ... | QH |
+//- +=======+=======+===+===++====+====+=====+====+
+//- | 0 | X | X | X || 0 | 0 | ... | 0 |
+//- | 1 | 0 | X | X || QA | QB | ... | QH |
+//- | 1 | 0-1 | 1 | 1 || 1 | QA | ... | QG |
+//- | 1 | 0-1 | 0 | X || 0 | QA | ... | QG |
+//- | 1 | 0-1 | X | 0 || 0 | QA | ... | QG |
+//- +-------+-------+---+---++----+----+-----+----+
+//-
+static NETLIST_START(TTL_74164_DIP)
+ TTL_74164(A)
+
+ DIPPINS( /* +--------------+ */
+ A.A, /* A |1 ++ 14| VCC */ A.VCC,
+ A.B, /* B |2 13| QH */ A.QH,
+ A.QA, /* QA |3 12| QG */ A.QG,
+ A.QB, /* QB |4 74164 11| QF */ A.QF,
+ A.QC, /* QC |5 10| QE */ A.QE,
+ A.QD, /* QD |6 9| CLRQ */ A.CLRQ,
+ A.GND, /* GND |7 8| CLK */ A.CLK
+ /* +--------------+ */
+ )
+NETLIST_END()
+//- Identifier: TTL_74165_DIP
+//- Title: 54165/DM74165 8-Bit Parallel-to-Serial Converter
+//- Description: The ’165 is an 8-bit parallel load or serial-in register with complementary outputs available from the last stage.
+//- Parallel inputting occurs asynchronously when the Parallel Load (PL) input is LOW.
+//- With PL HIGH, serial shifting occurs on the rising edge of the clock; new data enters via the Serial Data (DS) input.
+//- The 2-input OR clock can be used to combine two independent clock sources, or one input can act as an active LOW clock enable.
+//- Pinalias: PLQ,CP1,P4,P5,P6,P7,QQ7,GND,Q7,DS,P0,P1,P2,P3,CP2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009782.PDF
+//-
+//- +-----+-----+-----++----+----+----+----+----+----+----+----+
+//- | PLQ | CP1 | CP2 || Q0 | Q1 | Q2 | Q3 | Q4 | Q5 | Q6 | Q7 |
+//- +=====+=====+=====++====+====+====+====+====+====+====+====+
+//- | 0 | X | X || P0 | P1 | P2 | P3 | P4 | P5 | P6 | P7 |
+//- | 1 | 0 | 0-1 || DS | Q0 | Q1 | Q2 | Q3 | Q4 | Q5 | Q6 |
+//- | 1 | 1 | 0-1 || Q0 | Q1 | Q2 | Q3 | Q4 | Q5 | Q6 | Q7 |
+//- | 1 | 0-1 | 0 || DS | Q0 | Q1 | Q2 | Q3 | Q4 | Q5 | Q6 |
+//- | 1 | 0-1 | 1 || Q0 | Q1 | Q2 | Q3 | Q4 | Q5 | Q6 | Q7 |
+//- +-----+-----+-----++----+----+----+----+----+----+----+----+
+//-
+static NETLIST_START(TTL_74165_DIP)
+ TTL_74165(A)
+
+ DIPPINS( /* +--------------+ */
+ A.SH_LDQ, /* PLQ |1 ++ 16| VCC */ A.VCC,
+ A.CLK, /* CP1 |2 15| CP2 */ A.CLKINH,
+ A.E, /* P4 |3 14| P3 */ A.D,
+ A.F, /* P5 |4 74165 13| P2 */ A.C,
+ A.G, /* P6 |5 12| P1 */ A.B,
+ A.H, /* P7 |6 11| P0 */ A.A,
+ A.QHQ, /* QQ7 |7 10| DS */ A.SER,
+ A.GND, /* GND |8 9| Q7 */ A.QH
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74166_DIP
+//- Title: DM74LS166 8-Bit Parallel-In/Serial-Out Shift Registers
+//- Description: These parallel-in or serial-in, serial-out shift registers feature gated clock inputs and an overriding clear input.
+//- All inputs are buffered to lower the drive requirements to one normalized load, and input clamping diodes minimize switching transients to simplify system design.
+//- The load mode is established by the shift/load input.
+//- When high, this input enables the serial data input and couples the eight flip-flops for serial shifting with each clock pulse.
+//- When low, the parallel (broadside) data inputs are enabled and synchronous loading occurs on the next clock pulse.
+//- During parallel loading, serial data flow is inhibited.
+//- Clocking is accomplished on the low-to-high-level edge of the clock pulse through a two-input NOR gate, permitting one input to be used as a clock-enable or clock-inhibit function.
+//- Holding either of the clock inputs high inhibits clocking; holding either low enables the other clock input.
+//- This allows the system clock to be free running, and the register can be stopped on command with the other clock input.
+//- The clock-inhibit input should be changed to the high level only while the clock input is high.
+//- A buffered, direct clear input overrides all other inputs, including the clock, and sets all flip-flops to zero.
+//- Pinalias: SER,A,B,C,D,CLKINH,CLK,GND,CLRQ,E,F,G,QH,H,SH/LDQ,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006400.PDF
+//-
+//- +------+--------+--------+-----+-----+------++----+----+-----+----+
+//- | CLRQ | SH/LDQ | CLKINH | CLK | SER | A..H || QA | QB | ... | QH |
+//- +======+========+========+=====+=====+======++====+====+=====+====+
+//- | 0 | X | X | X | X | X || 0 | 0 | ... | 0 |
+//- | 1 | X | 0 | 0 | X | X || QA | QB | ... | QH |
+//- | 1 | 0 | 0 | 0-1 | X | a..h || a | b | ... | h |
+//- | 1 | 1 | 0 | 0-1 | 1 | X || 1 | QA | ... | QG |
+//- | 1 | 1 | 0 | 0-1 | 0 | X || 0 | QA | ... | QG |
+//- | 1 | X | 1 | 0-1 | X | X || QA | QB | ... | QH |
+//- +------+--------+--------+-----+-----+------++----+----+-----+----+
+//-
+static NETLIST_START(TTL_74166_DIP)
+ TTL_74166(A)
+
+ DIPPINS( /* +--------------+ */
+ A.SER, /* SER |1 ++ 16| VCC */ A.VCC,
+ A.A, /* A |2 15| SH/LDQ */ A.SH_LDQ,
+ A.B, /* B |3 14| H */ A.H,
+ A.C, /* C |4 74166 13| QH */ A.QH,
+ A.D, /* D |5 12| G */ A.G,
+ A.CLKINH, /* CLKINH |6 11| F */ A.F,
+ A.CLK, /* CLK |7 10| E */ A.E,
+ A.GND, /* GND |8 9| CLRQ */ A.CLRQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74174_DIP
+//- Title: DM74174 Hex/Quad D-Type Flip-Flop with Clear
+//- Description: These positive-edge triggered flip-flops utilize TTL circuitry to implement D-type flip-flop logic.
+//- All have a direct clear input.
+//- Information at the D inputs meeting the setup and hold time requirements is transferred to the Q outputs on the positive-going edge of the clock pulse.
+//- Clock triggering occurs at a particular voltage level and is not directly related to the transition time of the positive-going pulse.
+//- When the clock input is at either the HIGH or LOW level, the D input signal has no effect at the output.
+//- Pinalias: CLRQ,Q1,D1,D2,Q2,D3,Q3,GND,CLK,Q4,D4,Q5,D5,Q6,D6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Fairchild Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/fairchild/DM74174.pdf
+//-
+//- +------+-----+---++---+
+//- | CLRQ | CLK | D || Q |
+//- +======+=====+===++===+
+//- | 0 | X | X || 0 |
+//- | 1 | 0-1 | 1 || 1 |
+//- | 1 | 0-1 | 0 || 0 |
+//- | 1 | 0 | X || Q |
+//- +------+-----+---++---+
+//-
+static NETLIST_START(TTL_74174_DIP)
+ TTL_74174_GATE(A)
+ TTL_74174_GATE(B)
+ TTL_74174_GATE(C)
+ TTL_74174_GATE(D)
+ TTL_74174_GATE(E)
+ TTL_74174_GATE(F)
+
+ DIPPINS( /* +--------------+ */
+ A.CLRQ, /* CLRQ |1 ++ 16| VCC */ A.VCC,
+ A.Q, /* Q1 |2 15| Q6 */ F.Q,
+ A.D, /* D1 |3 14| D6 */ F.D,
+ B.D, /* D2 |4 74174 13| D5 */ E.D,
+ B.Q, /* Q2 |5 12| Q5 */ E.Q,
+ C.D, /* D3 |6 11| D4 */ D.D,
+ C.Q, /* Q3 |7 10| Q4 */ D.Q,
+ A.GND, /* GND |8 9| CLK */ A.CLK
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_74260_DIP
+//- Title: DM54LS260/DM74LS260 Dual 5-Input NOR Gate
+//- Description: This device contains two individual five input gates, each of which perform the logic NOR function.
+//- Pinalias: A1,B1,C1,A2,Q1,Q2,GND,B2,C2,D2,E2,D1,E1,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009824.PDF
+//-
+//- +---+---+---+---+---++---+
+//- | A | B | C | D | E || Y |
+//- +===+===+===+===+===++===+
+//- | 0 | 0 | 0 | 0 | 0 || 1 |
+//- | X | X | X | X | 1 || 0 |
+//- | X | X | X | 1 | X || 0 |
+//- | X | X | 1 | X | X || 0 |
+//- | X | 1 | X | X | X || 0 |
+//- | 1 | X | X | X | X || 0 |
+//- +---+---+---+---+---++---+
+//-
static NETLIST_START(TTL_74260_DIP)
TTL_74260_GATE(A)
TTL_74260_GATE(B)
@@ -1109,39 +2340,47 @@ static NETLIST_START(TTL_74260_DIP)
NET_C(A.VCC, B.VCC)
NET_C(A.GND, B.GND)
- DIPPINS( /* +--------------+ */
- A.C, /* C1 |1 ++ 14| VCC */ A.VCC,
- A.D, /* D1 |2 13| B1 */ A.B,
- A.E, /* E1 |3 12| A1 */ A.A,
- B.E, /* E2 |4 74260 11| D2 */ B.D,
- A.Q, /* Y1 |5 10| C2 */ B.C,
- B.Q, /* Y2 |6 9| B2 */ B.B,
- A.GND,/* GND |7 8| A2 */ B.A
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.C, /* C1 |1 ++ 14| VCC */ A.VCC,
+ A.D, /* D1 |2 13| B1 */ A.B,
+ A.E, /* E1 |3 12| A1 */ A.A,
+ B.E, /* E2 |4 74260 11| D2 */ B.D,
+ A.Q, /* Y1 |5 10| C2 */ B.C,
+ B.Q, /* Y2 |6 9| B2 */ B.B,
+ A.GND, /* GND |7 8| A2 */ B.A
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM74279: Quad S-R Latch
- *
- * +---+---+---++---+
- * |S1 |S2 | R || Q |
- * +===+===+===++===+
- * | 0 | 0 | 0 || 1 |
- * | 0 | 1 | 1 || 1 |
- * | 1 | 0 | 1 || 1 |
- * | 1 | 1 | 0 || 0 |
- * | 1 | 1 | 1 ||QP |
- * +---+---+---++---+
- *
- * QP: Previous Q
- *
- * Naming conventions follow Fairchild Semiconductor datasheet
- *
- */
-
-#if !NL_AUTO_DEVICES
+//- Identifier: TTL_74279_DIP
+//- Title: 54279/DM74279 Quad Set-Reset Latch
+//- Description: These latches are ideaily suited ·for use as temporary
+//- storage of bfnary information between processing units
+//- and I/O units. When either one of the data inputs is at
+//- a low logic level, the output will follow the level of the
+//- R input. When both data inputs are high, the output will
+//- remain latched in its previous state. When both inputs
+//- are low, the output will .go high. However, this high
+//- level may not persist when either one of the data inputs
+//- returns to the high state.
+//- Pinalias: 1RQ,1S1Q,1S2Q,1Q,2RQ,2SQ,2Q,GND,3Q,3RQ,3S1Q,3S2Q,4Q,4RQ,4SQ,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009785.PDF
+//-
+//- +-----+-----+----++---+
+//- | S1Q | S2Q | RQ || Q |
+//- +=====+=====+====++===+
+//- | 0 | 0 | 0 || 1 | (as long as SQ1 or SQ2 are low)
+//- | 0 | X | 1 || 1 |
+//- | X | 0 | 1 || 1 |
+//- | 1 | 1 | 0 || 0 |
+//- | 1 | 1 | 1 || Q |
+//- +-----+-----+----++---+
+//-
#ifndef __PLIB_PREPROCESSOR__
+#if !NL_AUTO_DEVICES
#define TTL_74279A(name) \
NET_REGISTER_DEV(TTL_74279A, name)
#define TTL_74279B(name) \
@@ -1158,26 +2397,38 @@ static NETLIST_START(TTL_74279_DIP)
NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
NET_C(A.GND, B.GND, C.GND, D.GND)
- DIPPINS( /* +--------------+ */
- A.R, /* 1R |1 ++ 16| VCC */ A.VCC,
- A.S1, /* 1S1 |2 15| 4S */ D.S,
- A.S2, /* 1S2 |3 14| 4R */ D.R,
- A.Q, /* 1Q |4 74279 13| 4Q */ D.Q,
- B.R, /* 2R |5 12| 3S2 */ C.S2,
- B.S, /* 2S |6 11| 3S1 */ C.S1,
- B.Q, /* 2Q |7 10| 3R */ C.R,
- A.GND, /* GND |8 9| 3Q */ C.Q
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.R, /* 1RQ |1 ++ 16| VCC */ A.VCC,
+ A.S1, /* 1S1Q |2 15| 4SQ */ D.S,
+ A.S2, /* 1S2Q |3 14| 4RQ */ D.R,
+ A.Q, /* 1Q |4 74279 13| 4Q */ D.Q,
+ B.R, /* 2RQ |5 12| 3S2Q */ C.S2,
+ B.S, /* 2SQ |6 11| 3S1Q */ C.S1,
+ B.Q, /* 2Q |7 10| 3RQ */ C.R,
+ A.GND, /* GND |8 9| 3Q */ C.Q
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM74377: Octal D Flip-Flop With Enable
- * DM74378: Hex D Flip-Flop With Enable
- * DM74379: 4-bit D Flip-Flop With Enable
- *
- */
-
+//- Identifier: TTL_74377_DIP
+//- Title: DM54LS377/DM74LS377 Octal D Flip-Flop with Common Enable and Clock
+//- Description: The ’LS377 is an 8-bit register built using advanced low power Schottky technology.
+//- This register consists of eight D-type flip-flops with a buffered common clock and a buffered common input enable.
+//- The device is packaged in the space-saving (0.3 inch row spacing) 20-pin package.
+//- Pinalias: EQ,Q0,D0,D1,Q1,Q2,D2,D3,Q3,GND,CP,Q4,D4,D5,Q5,Q6,D6,D7,Q7,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009785.PDF
+//-
+//- +----+-----+----++----+
+//- | EQ | CP | Dn || Qn |
+//- +====+=====+====++====+
+//- | 1 | X | X || Qn |
+//- | 0 | 0-1 | 1 || 1 |
+//- | 0 | 0-1 | 0 || 0 |
+//- +----+-----+----++----+
+//-
static NETLIST_START(TTL_74377_DIP)
TTL_74377_GATE(A)
TTL_74377_GATE(B)
@@ -1202,21 +2453,39 @@ static NETLIST_START(TTL_74377_DIP)
HINT(G.QQ, NC)
HINT(H.QQ, NC)
- DIPPINS( /* +--------------+ */
- A.E, /* /E |1 ++ 20| VCC */ A.VCC,
- A.Q, /* Q0 |2 19| Q7 */ H.Q,
- A.D, /* D0 |3 18| D7 */ H.D,
- B.D, /* D1 |4 74377 17| D6 */ G.D,
- B.Q, /* Q1 |5 16| Q6 */ G.Q,
- C.Q, /* Q2 |6 15| Q5 */ F.Q,
- C.D, /* D2 |7 14| D5 */ F.D,
- D.D, /* D3 |8 13| D4 */ E.D,
- D.Q, /* Q3 |9 12| Q4 */ E.Q,
- A.GND,/* GND |10 11| CP */ A.CP
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.E, /* EQ |1 ++ 20| VCC */ A.VCC,
+ A.Q, /* Q0 |2 19| Q7 */ H.Q,
+ A.D, /* D0 |3 18| D7 */ H.D,
+ B.D, /* D1 |4 74377 17| D6 */ G.D,
+ B.Q, /* Q1 |5 16| Q6 */ G.Q,
+ C.Q, /* Q2 |6 15| Q5 */ F.Q,
+ C.D, /* D2 |7 14| D5 */ F.D,
+ D.D, /* D3 |8 13| D4 */ E.D,
+ D.Q, /* Q3 |9 12| Q4 */ E.Q,
+ A.GND, /* GND |10 11| CP */ A.CP
+ /* +--------------+ */
)
NETLIST_END()
+//- Identifier: TTL_74378_DIP
+//- Title: DM54LS378/DM74LS378 Parallel D Register with Enable
+//- Description: The ’LS378 is a 6-bit register with a buffered common enable.
+//- This device is similar to the ’LS174, but with common Enable rather than common Master Reset.
+//- Pinalias: EQ,Q0,D0,D1,Q1,D2,Q2,GND,CP,Q3,D3,Q4,D4,D5,Q6,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009832.PDF
+//-
+//- +----+-----+----++----+
+//- | EQ | CP | Dn || Qn |
+//- +====+=====+====++====+
+//- | 1 | X | X || Qn |
+//- | 0 | 0-1 | 1 || 1 |
+//- | 0 | 0-1 | 0 || 0 |
+//- +----+-----+----++----+
+//-
static NETLIST_START(TTL_74378_DIP)
TTL_74377_GATE(A)
TTL_74377_GATE(B)
@@ -1230,19 +2499,37 @@ static NETLIST_START(TTL_74378_DIP)
NET_C(A.CP, B.CP, C.CP, D.CP, E.CP, F.CP)
NET_C(A.E, B.E, C.E, D.E, E.E, F.E)
- DIPPINS( /* +--------------+ */
- A.E, /* /E |1 ++ 16| VCC */ A.VCC,
- A.Q, /* Q0 |2 15| Q5 */ F.Q,
- A.D, /* D0 |3 14| D5 */ F.D,
- B.D, /* D1 |4 74378 13| D4 */ E.D,
- B.Q, /* Q1 |5 12| Q4 */ E.Q,
- C.D, /* D2 |6 11| D3 */ D.D,
- C.Q, /* Q2 |7 10| Q3 */ D.Q,
- A.GND,/* GND |8 9| CP */ A.CP
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.E, /* EQ |1 ++ 16| VCC */ A.VCC,
+ A.Q, /* Q0 |2 15| Q5 */ F.Q,
+ A.D, /* D0 |3 14| D5 */ F.D,
+ B.D, /* D1 |4 74378 13| D4 */ E.D,
+ B.Q, /* Q1 |5 12| Q4 */ E.Q,
+ C.D, /* D2 |6 11| D3 */ D.D,
+ C.Q, /* Q2 |7 10| Q3 */ D.Q,
+ A.GND, /* GND |8 9| CP */ A.CP
+ /* +--------------+ */
)
NETLIST_END()
+//- Identifier: TTL_74379_DIP
+//- Title: 54LS379/DM74LS379 Quad Parallel Register with Enable
+//- Description: The LS379 is a 4-bit register with buffered common Enable.
+//- This device is similar to the LS175 but features the common Enable rather than common Master Reset.
+//- Pinalias: EEQ,Q0,QQ0,D0,QQ1,Q1,GND,CP,Q2,QQ2,D2,D3,QQ3,Q3,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS009832.PDF
+//-
+//- +----+-----+----++----+-----+
+//- | EQ | CP | Dn || Qn | QQn |
+//- +====+=====+====++====+=====+
+//- | 1 | X | X || Qn | QQn |
+//- | 0 | 0-1 | 1 || 1 | 0 |
+//- | 0 | 0-1 | 0 || 0 | 1 |
+//- +----+-----+----++----+-----+
+//-
static NETLIST_START(TTL_74379_DIP)
TTL_74377_GATE(A)
TTL_74377_GATE(B)
@@ -1254,113 +2541,360 @@ static NETLIST_START(TTL_74379_DIP)
NET_C(A.CP, B.CP, C.CP, D.CP)
NET_C(A.E, B.E, C.E, D.E)
- DIPPINS( /* +--------------+ */
- A.E, /* /E |1 ++ 16| VCC */ A.VCC,
- A.Q, /* Q0 |2 15| Q3 */ D.Q,
- A.QQ, /* /Q0 |3 14| /Q3 */ D.QQ,
- A.D, /* D0 |4 74379 13| D3 */ D.D,
- B.D, /* D1 |5 12| D2 */ C.D,
- B.QQ, /* /Q1 |6 11| /Q2 */ C.QQ,
- B.Q, /* Q1 |7 10| Q2 */ C.Q,
- A.GND,/* GND |8 9| CP */ A.CP
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.E, /* EQ |1 ++ 16| VCC */ A.VCC,
+ A.Q, /* Q0 |2 15| Q3 */ D.Q,
+ A.QQ, /* QQ0 |3 14| QQ3 */ D.QQ,
+ A.D, /* D0 |4 74379 13| D3 */ D.D,
+ B.D, /* D1 |5 12| D2 */ C.D,
+ B.QQ, /* QQ1 |6 11| QQ2 */ C.QQ,
+ B.Q, /* Q1 |7 10| Q2 */ C.Q,
+ A.GND, /* GND |8 9| CP */ A.CP
+ /* +--------------+ */
)
NETLIST_END()
-/*
- * DM9312: One of Eight Line Data Selectors/Multiplexers
- *
- * +--------------+
- * D0 |1 ++ 16| VCC
- * D1 |2 15| Y
- * D2 |3 14| YQ
- * D3 |4 9312 13| C
- * D4 |5 12| B
- * D5 |6 11| A
- * D6 |7 10| G Strobe
- * GND |8 9| D7
- * +--------------+
- * __
- * +---+---+---+---++---+---+
- * | C | B | A | G || Y | YQ|
- * +===+===+===+===++===+===+
- * | X | X | X | 1 || 0| 1 |
- * | 0 | 0 | 0 | 0 || D0|D0Q|
- * | 0 | 0 | 1 | 0 || D1|D1Q|
- * | 0 | 1 | 0 | 0 || D2|D2Q|
- * | 0 | 1 | 1 | 0 || D3|D3Q|
- * | 1 | 0 | 0 | 0 || D4|D4Q|
- * | 1 | 0 | 1 | 0 || D5|D5Q|
- * | 1 | 1 | 0 | 0 || D6|D6Q|
- * | 1 | 1 | 1 | 0 || D7|D7Q|
- * +---+---+---+---++---+---+
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
+//- Identifier: TTL_74393_DIP
+//- Title: Dual 4-Bit Binary Counter
+//- Description: DM74LS393 Each of these monolithic circuits contains eight master-slave flip-flops and additional gating to implement two individual four-bit counters in a single package.
+//- The ’LS393 comprises two independent four-bit binary counters each having a clear and a clock input.
+//- N-bit binary counters can be implemented with each package providing the capability of divide-by-256.
+//- The LS393 has parallel outputs from each counter stage so that any submultiple of the input count freqency is available for system-timing signals.
+//- Pinalias: 1A,1CLR,1QA,1QB,1QC,1QD,GND,2QD,2QC,2QB,2QA,2CLR,2A,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006434.PDF
+//-
+static NETLIST_START(TTL_74393_DIP)
+ TTL_74393(A)
+ TTL_74393(B)
-#ifndef __PLIB_PREPROCESSOR__
-#define DM9312_TT(name) \
- NET_REGISTER_DEV(DM9312, name)
-#endif
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
-static NETLIST_START(DM9312_DIP)
- DM9312_TT(s)
-
- DIPPINS( /* +--------------+ */
- s.D0, /* D0 |1 ++ 16| VCC */ s.VCC,
- s.D1, /* D1 |2 15| Y */ s.Y,
- s.D2, /* D2 |3 14| YQ */ s.YQ,
- s.D3, /* D3 |4 9312 13| C */ s.C,
- s.D4, /* D4 |5 12| B */ s.B,
- s.D5, /* D5 |6 11| A */ s.A,
- s.D6, /* D6 |7 10| G */ s.G, //Strobe
- s.GND, /* GND |8 9| D7 */ s.D7
- /* +--------------+ */
+ DIPPINS( /* +--------------+ */
+ A.CP, /* 1A |1 ++ 14| VCC */ A.VCC,
+ A.MR, /* 1CLR |2 13| 2A */ B.CP,
+ A.Q0, /* 1QA |3 12| 2CLR */ B.MR,
+ A.Q1, /* 1QB |4 74393 11| 2QA */ B.Q0,
+ A.Q2, /* 1QC |5 10| 2QB */ B.Q1,
+ A.Q3, /* 1QD |6 9| 2QC */ B.Q2,
+ A.GND, /* GND |7 8| 2QD */ B.Q3
+ /* +--------------+ */
)
NETLIST_END()
-#if (NL_USE_TRUTHTABLE_7448)
+//- Identifier: SN74LS629_DIP
+//- Title: SN74LS629 VOLTAGE-CONTROLLED OSCILLATORS
+//- Description: Please add a detailed description
+//- FIXME: Missing description
+//-
+//- Pinalias: 2FC,1FC,1RNG,1CX1,1CX2,1ENQ,1Y,OSC_GND,GND,2Y,2ENQ,2CX2,2CX1,2RNG,OSC_VCC,VCC
+//- Package: DIP
+//- Param: A.CAP
+//- Capacitor value of capacitor connected to 1CX1 and 1CX2 pins
+//- Param: B.CAP
+//- Capacitor value of capacitor connected to 2CX1 and 2CX2 pins
+//- Limitations:
+//- The capacitor inputs are NC. Capacitor values need to be specified as
+//- ```
+//- SN74LS629_DIP(X)
+//- PARAM(X.A.CAP, CAP_U(1))
+//- PARAM(X.B.CAP, CAP_U(2))
+//- ```
+//-
+//- Example: 74ls629.cpp,74ls629_example
+//-
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheets/400/335051_DS.pdf
+//-
+static NETLIST_START(SN74LS629_DIP)
+ SN74LS629(A, CAP_U(1))
+ SN74LS629(B, CAP_U(1))
-/*
- * DM7448: BCD to 7-Segment decoders/drivers
- *
- * +--------------+
- * B |1 ++ 16| VCC
- * C |2 15| f
- * LAMP TEST |3 14| g
- * BI/RBQ |4 7448 13| a
- * RBI |5 12| b
- * D |6 11| c
- * A |7 10| d
- * GND |8 9| e
- * +--------------+
- *
- *
- * Naming conventions follow National Semiconductor datasheet
- *
- */
-#ifndef __PLIB_PREPROCESSOR__
-#define TTL_7448_TT(name) \
- NET_REGISTER_DEV(TTL_7448_TT, name)
-#endif
+ NET_C(A.GND, B.GND)
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.OSCGND, B.OSCGND)
+ NET_C(A.OSCVCC, B.OSCVCC)
+ NC_PIN(NC)
-static NETLIST_START(TTL_7448_DIP)
- TTL_7448_TT(s)
+ DIPPINS( /* +--------------+ */
+ B.FC, /* 2FC |1 ++ 16| VCC */ A.VCC,
+ A.FC, /* 1FC |2 15| OSC VCC */ A.OSCVCC,
+ A.RNG, /* 1RNG |3 14| 2RNG */ B.RNG,
+ NC.I, /* 1CX1 |4 74LS629 13| 2CX1 */ NC.I,
+ NC.I, /* 1CX2 |5 12| 2CX2 */ NC.I,
+ A.ENQ, /* 1ENQ |6 11| 2ENQ */ B.ENQ,
+ B.Y, /* 1Y |7 10| 2Y */ B.Y,
+ A.OSCGND, /* OSC GND |8 9| GND */ A.GND
+ /* +--------------+ */
+ )
+NETLIST_END()
- DIPPINS( /* +--------------+ */
- s.B, /* B |1 ++ 16| VCC */ s.VCC,
- s.C, /* C |2 15| f */ s.f,
- s.LTQ, /* LTQ |3 14| g */ s.g,
- s.BIQ, /* BIQ |4 7448 13| a */ s.a,
- s.RBIQ, /* RBIQ |5 12| b */ s.b,
- s.D, /* D |6 11| c */ s.c,
- s.A, /* A |7 10| d */ s.d,
- s.GND, /* GND |8 9| e */ s.e
- /* +--------------+ */
+//- Identifier: TTL_9310_DIP
+//- Title: DM9310/DM8310 Synchronous 4-Bit Decade Counter
+//- Description: These synchronous, presettable counters feature an
+//- internal carry look-ahead for application in high-speed
+//- counting designs. The DM9310/DM8310 are decade
+//- counters. The carry output is decoded by means of a
+//- NOR gate, thus preventing spikes during the normal
+//- counting mode of operation. Synchronous operation
+//- is provided by having all flip-flops clocked simultaneously
+//- so that the outputs change coincident with each
+//- other when so instructed by the count-enable inputs
+//- and internal gating. This mode of operation eliminates
+//- the output counting spikes which are normally
+//- associated with asynchronous (ripple clock) counters.
+//- A buffered clock input triggers the four flip-flops on
+//- the rising (positive-going) edge of the clock input
+//- waveform.
+//-
+//- These counters are fully programmable; that is, the
+//- outputs may be preset to either level. As presetting is
+//- synchronous, setting up a low level at the load input
+//- disables the counter and causes the outputs to agree
+//- with the setup data after the next clock pulse regardless
+//- of the levels of the enable input. Low-to-high transitions
+//- at the· load input are perfectly acceptable regardless of
+//- the logic levels on the clock or enable inputs. The clear
+//- function is asynchronous and a low level at the clear
+//- input sets all four of the flip-flop outputs low regardless
+//- of the levels of clock, load, or enable inputs.
+//-
+//- The carry look-ahead circuitry provides for cascading
+//- counters for n-bit synchronous applications without
+//- additional gating. Instrumental in accomplishing this
+//- function are two count-enable inputs and a ripple carry
+//- output. Both count-enable inputs (P and T) must be
+//- high to count, and input T is fed-forward to enable the
+//- ripple carry output. The ripple carry output thus
+//- enabled will produce a high-level output pulse with a
+//- duration approximately equal to the high-level portion
+//- of the QA output. This high-level overflow ripply carry
+//- pulse can be used to enable successive cascaded stages.
+//- High-to-Low level transitions at the enable P or T inputs
+//- may occur regardless of the logic level in the clock.
+//- Pinalias: CLEARQ,CLOCK,A,B,C,D,ENABLEP,GND,LOADQ,ENABLET,QD,QC,QB,QA,RC,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- https://ia800608.us.archive.org/5/items/bitsavers_nationaldaTTLDatabook_40452765/1976_National_TTL_Databook.pdf
+//-
+static NETLIST_START(TTL_9310_DIP)
+ TTL_9310(A)
+
+ DIPPINS( /* +--------------+ */
+ A.CLRQ, /* /CLEAR |1 ++ 16| VCC */ A.VCC,
+ A.CLK, /* CLOCK |2 15| RC */ A.RC,
+ A.A, /* A |3 14| QA */ A.QA,
+ A.B, /* B |4 9310 13| QB */ A.QB,
+ A.C, /* C |5 12| QC */ A.QC,
+ A.D, /* D |6 11| QD */ A.QD,
+ A.ENP, /* Enable P |7 10| Enable T */ A.ENT,
+ A.GND, /* GND |8 9| /LOAD */ A.LOADQ
+ /* +--------------+ */
)
NETLIST_END()
-#endif
+
+//- Identifier: TTL_9312_DIP
+//- Title: DM9312/DM8312 One of Eight Line Data Selectors/Multiplexers
+//- Description: These data selectors/multiplexers contain inverter/
+//- drivers to supply full complementary, on-chip, binary
+//- decoded data selection to the AND-OR-INVERT gates.
+//-
+//- The DM9312/8312 is a single 8-bit multiplexer with
+//- complementary outputs and a strobe control. When the
+//- strobe is low, the function is enabled. When a high logic
+//- level is applied to the strobe, the outputs are latched.
+//- Pinalias: D0,D1,D2,D3,D4,D5,D6,GND,D7,G,A,B,C,YQ,Y,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DM9312.pdf
+//-
+//- +---+---+---+---++----+-----+
+//- | C | B | A | G || Y | YQ |
+//- +===+===+===+===++====+=====+
+//- | X | X | X | 1 || 0 | 1 |
+//- | 0 | 0 | 0 | 0 || D0 | D0Q |
+//- | 0 | 0 | 1 | 0 || D1 | D1Q |
+//- | 0 | 1 | 0 | 0 || D2 | D2Q |
+//- | 0 | 1 | 1 | 0 || D3 | D3Q |
+//- | 1 | 0 | 0 | 0 || D4 | D4Q |
+//- | 1 | 0 | 1 | 0 || D5 | D5Q |
+//- | 1 | 1 | 0 | 0 || D6 | D6Q |
+//- | 1 | 1 | 1 | 0 || D7 | D7Q |
+//- +---+---+---+---++----+-----+
+//-
+static NETLIST_START(TTL_9312_DIP)
+ TTL_9312(A)
+
+ DIPPINS( /* +--------------+ */
+ A.D0, /* D0 |1 ++ 16| VCC */ A.VCC,
+ A.D1, /* D1 |2 15| Y */ A.Y,
+ A.D2, /* D2 |3 14| YQ */ A.YQ,
+ A.D3, /* D3 |4 9312 13| C */ A.C,
+ A.D4, /* D4 |5 12| B */ A.B,
+ A.D5, /* D5 |6 11| A */ A.A,
+ A.D6, /* D6 |7 10| G */ A.G, //Strobe
+ A.GND, /* GND |8 9| D7 */ A.D7
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_9316_DIP
+//- Title: DM9316/DM8316 Synchronous 4-Bit Counters
+//- Description: These synchronous, presettable counters feature an
+//- internal carry look-ahead for application in high-speed
+//- counting designs. The DM9316/DM8316 are 4-bit binary
+//- counters. The carry output is decoded by means of a
+//- NOR gate, thus preventing spikes during the normal
+//- counting mode of operation. Synchronous operation
+//- is provided by having all flip-flops clocked simultaneously
+//- so that the outputs change coincident with each
+//- other when so instructed by the count-enable inputs
+//- and internal gating. This mode of operation eliminates
+//- the output counting spikes which are normally
+//- associated with asynchronous (ripple clock) counters.
+//- A buffered clock input triggers the four flip-flops on
+//- the rising (positive-going) edge of the clock input
+//- waveform.
+//-
+//- These counters are fully programmable; that is, the
+//- outputs may be preset to either level. As presetting is
+//- synchronous, setting up a low level at the load input
+//- disables the counter and causes the outputs to agree
+//- with the setup data after the next clock pulse regardless
+//- of the levels of the enable input. Low-to-high transitions
+//- at the· load input are perfectly acceptable regardless of
+//- the logic levels on the clock or enable inputs. The clear
+//- function is asynchronous and a low level at the clear
+//- input sets all four of the flip-flop outputs low regardless
+//- of the levels of clock, load, or enable inputs.
+//-
+//- The carry look-ahead circuitry provides for cascading
+//- counters for n-bit synchronous applications without
+//- additional gating. Instrumental in accomplishing this
+//- function are two count-enable inputs and a ripple carry
+//- output. Both count-enable inputs (P and T) must be
+//- high to count, and input T is fed-forward to enable the
+//- ripple carry output. The ripple carry output thus
+//- enabled will produce a high-level output pulse with a
+//- duration approximately equal to the high-level portion
+//- of the QA output. This high-level overflow ripply carry
+//- pulse can be used to enable successive cascaded stages.
+//- High-to-Low level transitions at the enable P or T inputs
+//- may occur regardless of the logic level in the clock.
+//- Pinalias: CLEARQ,CLOCK,A,B,C,D,ENABLEP,GND,LOADQ,ENABLET,QD,QC,QB,QA,RC,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006606.PDF
+//-
+static NETLIST_START(TTL_9316_DIP)
+ TTL_9316(A)
+
+ DIPPINS( /* +--------------+ */
+ A.CLRQ, /* CLEARQ |1 ++ 16| VCC */ A.VCC,
+ A.CLK, /* CLOCK |2 15| RC */ A.RC,
+ A.A, /* A |3 14| QA */ A.QA,
+ A.B, /* B |4 9316 13| QB */ A.QB,
+ A.C, /* C |5 12| QC */ A.QC,
+ A.D, /* D |6 11| QD */ A.QD,
+ A.ENP, /* Enable P |7 10| Enable T */ A.ENT,
+ A.GND, /* GND |8 9| LOADQ */ A.LOADQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_9322_DIP
+//- Title: DM9322/DM8322 Quad 2-Line to 1-Line Data Selectors/Multiplexers
+//- Description: These data selectors/multiplexers contain inverters and
+//- drivers to supply full on-chip data selection to the four
+//- output gates. A separate strobe input is provided. A
+//- 4-bit word is selected from one of two sources and is
+//- routed to the four outputs. True data is presented
+//- at the outputs.
+//- Pinalias: SELECT,A1,B1,Y1,A2,B2,Y2,GND,Y3,B3,A3,Y4,B4,A4,STROBE,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow National Semiconductor datasheet
+//- FunctionTable:
+//- http://pdf.datasheetcatalog.com/datasheet/nationalsemiconductor/DS006606.PDF
+//-
+static NETLIST_START(TTL_9322_DIP)
+ TTL_9322_GATE(A)
+ TTL_9322_GATE(B)
+ TTL_9322_GATE(C)
+ TTL_9322_GATE(D)
+
+ NET_C(A.SELECT, B.SELECT, C.SELECT, D.SELECT)
+ NET_C(A.STROBE, B.STROBE, C.STROBE, D.STROBE)
+ NET_C(A.VCC, B.VCC, C.VCC, D.VCC)
+ NET_C(A.GND, B.GND, C.GND, D.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.SELECT, /* SELECT |1 ++ 16| VCC */ A.VCC,
+ A.A, /* A1 |2 15| STROBE */ A.STROBE,
+ A.B, /* B1 |3 14| A4 */ D.A,
+ A.Y, /* Y1 |4 9322 13| B4 */ D.B,
+ B.A, /* A2 |5 12| Y4 */ D.Y,
+ B.B, /* B2 |6 11| A3 */ C.A,
+ B.Y, /* Y2 |7 10| B3 */ C.B,
+ A.GND, /* GND |8 9| Y3 */ C.Y
+ /* +--------------+ */
+ )
+NETLIST_END()
+
+//- Identifier: TTL_9602_DIP
+//- Title: DM9602/DM6802 Dual Retriggerable, Resettable One Shots
+//- Description: These dual resettable, retriggerable one shots have two
+//- inputs per function; one which is active high, and one
+//- which is active low. This allows the designer to employ
+//- either leading-edge or trailing-edge triggering, which is
+//- independent of input transition times. When input con·
+//- ditions for triggering are met, a new cycle starts and the
+//- external capacitor is allowed to rapidly discharge and
+//- then charge again. The retriggerable feature permits
+//- output pulse widths to be extended. In fact a continuous
+//- true output can be maintained by having an input cycle
+//- time which is shorter than the output cycle time. The
+//- output pulse may then be terminated at any time by
+//- applying a low logic level to the RESET pin. Retriggering
+//- may be inhibited by either connecting the Q output to
+//- an active high input, or the Q output to an active
+//- low input.
+//- Pinalias: C1,RC1,CLRQ1,B1,A1,Q1,QQ1,GND,QQ2,Q2,A2,B2,CLRQ2,RC2,C2,VCC
+//- Package: DIP
+//- NamingConvention: Naming conventions follow Fairchild Semiconductor datasheet
+//- Limitations:
+//- Timing inaccuracies may occur for capacitances < 1nF. Please consult datasheet
+//-
+//- Example: 74123.cpp,74123_example
+//-
+//- FunctionTable:
+//- https://pdf1.alldatasheet.com/datasheet-pdf/view/51137/FAIRCHILD/DM9602.html
+//-
+static NETLIST_START(TTL_9602_DIP)
+ TTL_9602(A)
+ TTL_9602(B)
+
+ NET_C(A.VCC, B.VCC)
+ NET_C(A.GND, B.GND)
+
+ DIPPINS( /* +--------------+ */
+ A.C, /* C1 |1 ++ 16| VCC */ A.VCC,
+ A.RC, /* RC1 |2 15| C2 */ B.C,
+ A.CLRQ, /* CLRQ1 |3 14| RC2 */ B.RC,
+ A.B, /* B1 |4 9602 13| CLRQ2 */ B.CLRQ,
+ A.A, /* A1 |5 12| B2 */ B.B,
+ A.Q, /* Q1 |6 11| A2 */ B.A,
+ A.QQ, /* QQ1 |7 10| Q2 */ B.Q,
+ A.GND, /* GND |8 9| QQ2 */ B.QQ
+ /* +--------------+ */
+ )
+NETLIST_END()
+
NETLIST_START(TTL74XX_lib)
NET_MODEL("DM7414 SCHMITT_TRIGGER(VTP=1.7 VTM=0.9 VI=4.35 RI=6.15k VOH=3.5 ROH=120 VOL=0.1 ROL=37.5 TPLH=15 TPHL=15)")
@@ -1423,6 +2957,14 @@ NETLIST_START(TTL74XX_lib)
TT_FAMILY("74XXOC")
TRUTHTABLE_END()
+ TRUTHTABLE_START(TTL_7407_GATE, 1, 1, "")
+ TT_HEAD("A|Y ")
+ TT_LINE("0|0|15")
+ TT_LINE("1|1|23")
+ /* Open Collector */
+ TT_FAMILY("74XXOC")
+ TRUTHTABLE_END()
+
TRUTHTABLE_START(TTL_7408_GATE, 2, 1, "")
TT_HEAD("A,B|Q ")
TT_LINE("0,X|0|15")
@@ -1617,6 +3159,22 @@ NETLIST_START(TTL74XX_lib)
TT_FAMILY("74XX")
TRUTHTABLE_END()
+ TRUTHTABLE_START(TTL_7442, 4, 10, "")
+ TT_HEAD("D,C,B,A|0,1,2,3,4,5,6,7,8,9")
+ TT_LINE("0,0,0,0|0,1,1,1,1,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,0,0,1|1,0,1,1,1,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,0,1,0|1,1,0,1,1,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,0,1,1|1,1,1,0,1,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,1,0,0|1,1,1,1,0,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,1,0,1|1,1,1,1,1,0,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,1,1,0|1,1,1,1,1,1,0,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("0,1,1,1|1,1,1,1,1,1,1,0,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("1,0,0,0|1,1,1,1,1,1,1,1,0,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("1,0,0,1|1,1,1,1,1,1,1,1,1,0|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("1,0,1,X|1,1,1,1,1,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TT_LINE("1,1,X,X|1,1,1,1,1,1,1,1,1,1|30,30,30,30,30,30,30,30,30,30")
+ TRUTHTABLE_END()
+
#if (NL_USE_TRUTHTABLE_7448)
TRUTHTABLE_START(TTL_7448, 7, 7, "+A,+B,+C,+D,+LTQ,+BIQ,+RBIQ,@VCC,@GND")
TT_HEAD(" LTQ,BIQ,RBIQ, A , B , C , D | a, b, c, d, e, f, g")
@@ -1721,7 +3279,7 @@ NETLIST_START(TTL74XX_lib)
* | 1 | * | 1 | 1 || TOGGLE |
* +-----+-----+-----+---++---+-----+
*/
- TRUTHTABLE_START(TTL_74107, 6, 4, "+CLK,+J,+K,+CLRQ,@VCC,@GND")
+ TRUTHTABLE_START(TTL_74107_TT, 6, 4, "+CLK,+J,+K,+CLRQ,@VCC,@GND")
TT_HEAD("CLRQ, CLK, _CO, J, K,_QX | Q, QQ, CO, QX")
TT_LINE(" 0, 0, X, X, X, X | 0, 1, 0, 0 | 16, 25, 1, 1")
TT_LINE(" 0, 1, X, X, X, X | 0, 1, 1, 0 | 16, 25, 1, 1")
@@ -1852,7 +3410,7 @@ NETLIST_START(TTL74XX_lib)
TT_FAMILY("74XX")
TRUTHTABLE_END()
- TRUTHTABLE_START(DM9312, 12, 2, "+A,+B,+C,+G,+D0,+D1,+D2,+D3,+D4,+D5,+D6,+D7,@VCC,@GND")
+ TRUTHTABLE_START(TTL_9312, 12, 2, "+A,+B,+C,+G,+D0,+D1,+D2,+D3,+D4,+D5,+D6,+D7,@VCC,@GND")
TT_HEAD(" C, B, A, G,D0,D1,D2,D3,D4,D5,D6,D7| Y,YQ")
TT_LINE(" X, X, X, 1, X, X, X, X, X, X, X, X| 0, 1|33,19")
TT_LINE(" 0, 0, 0, 0, 0, X, X, X, X, X, X, X| 0, 1|33,28")
@@ -1878,6 +3436,7 @@ NETLIST_START(TTL74XX_lib)
LOCAL_LIB_ENTRY(TTL_7402_DIP)
LOCAL_LIB_ENTRY(TTL_7404_DIP)
LOCAL_LIB_ENTRY(TTL_7406_DIP)
+ LOCAL_LIB_ENTRY(TTL_7407_DIP)
LOCAL_LIB_ENTRY(TTL_7408_DIP)
LOCAL_LIB_ENTRY(TTL_7410_DIP)
LOCAL_LIB_ENTRY(TTL_7411_DIP)
@@ -1893,25 +3452,49 @@ NETLIST_START(TTL74XX_lib)
LOCAL_LIB_ENTRY(TTL_7430_DIP)
LOCAL_LIB_ENTRY(TTL_7432_DIP)
LOCAL_LIB_ENTRY(TTL_7437_DIP)
-#if (NL_USE_TRUTHTABLE_7448)
+ LOCAL_LIB_ENTRY(TTL_7442_DIP)
LOCAL_LIB_ENTRY(TTL_7448_DIP)
-#endif
+ LOCAL_LIB_ENTRY(TTL_7450_DIP)
+ LOCAL_LIB_ENTRY(TTL_7473_DIP)
+ LOCAL_LIB_ENTRY(TTL_7473A_DIP)
+ LOCAL_LIB_ENTRY(TTL_7474_DIP)
+ LOCAL_LIB_ENTRY(TTL_7475_DIP)
+ LOCAL_LIB_ENTRY(TTL_7477_DIP)
+ LOCAL_LIB_ENTRY(TTL_7483_DIP)
+ LOCAL_LIB_ENTRY(TTL_7485_DIP)
LOCAL_LIB_ENTRY(TTL_7486_DIP)
+ LOCAL_LIB_ENTRY(TTL_7490_DIP)
+ LOCAL_LIB_ENTRY(TTL_7492_DIP)
+ LOCAL_LIB_ENTRY(TTL_7493_DIP)
+ LOCAL_LIB_ENTRY(TTL_7497_DIP)
+ LOCAL_LIB_ENTRY(TTL_74107_DIP)
+ LOCAL_LIB_ENTRY(TTL_74107A_DIP)
+ LOCAL_LIB_ENTRY(TTL_74113_DIP)
+ LOCAL_LIB_ENTRY(TTL_74113A_DIP)
LOCAL_LIB_ENTRY(TTL_74121_DIP)
LOCAL_LIB_ENTRY(TTL_74123_DIP)
LOCAL_LIB_ENTRY(TTL_9602_DIP)
LOCAL_LIB_ENTRY(TTL_74125_DIP)
LOCAL_LIB_ENTRY(TTL_74126_DIP)
-#if (NL_USE_TRUTHTABLE_74107)
- LOCAL_LIB_ENTRY(TTL_74107_DIP)
-#endif
+ LOCAL_LIB_ENTRY(TTL_74153_DIP)
LOCAL_LIB_ENTRY(TTL_74155_DIP)
LOCAL_LIB_ENTRY(TTL_74156_DIP)
LOCAL_LIB_ENTRY(TTL_74157_DIP)
+ LOCAL_LIB_ENTRY(TTL_74161_DIP)
+ LOCAL_LIB_ENTRY(TTL_74163_DIP)
+ LOCAL_LIB_ENTRY(TTL_74164_DIP)
+ LOCAL_LIB_ENTRY(TTL_74165_DIP)
+ LOCAL_LIB_ENTRY(TTL_74166_DIP)
+ LOCAL_LIB_ENTRY(TTL_74174_DIP)
LOCAL_LIB_ENTRY(TTL_74260_DIP)
LOCAL_LIB_ENTRY(TTL_74279_DIP)
LOCAL_LIB_ENTRY(TTL_74377_DIP)
LOCAL_LIB_ENTRY(TTL_74378_DIP)
LOCAL_LIB_ENTRY(TTL_74379_DIP)
- LOCAL_LIB_ENTRY(DM9312_DIP)
+ LOCAL_LIB_ENTRY(TTL_74393_DIP)
+ LOCAL_LIB_ENTRY(SN74LS629_DIP)
+ LOCAL_LIB_ENTRY(TTL_9312_DIP)
+ LOCAL_LIB_ENTRY(TTL_9310_DIP)
+ LOCAL_LIB_ENTRY(TTL_9316_DIP)
+ LOCAL_LIB_ENTRY(TTL_9322_DIP)
NETLIST_END()
diff --git a/src/lib/netlist/macro/nlm_ttl74xx.h b/src/lib/netlist/macro/nlm_ttl74xx.h
index d041a9e6e3d..b797bfd6cc9 100644
--- a/src/lib/netlist/macro/nlm_ttl74xx.h
+++ b/src/lib/netlist/macro/nlm_ttl74xx.h
@@ -65,6 +65,13 @@
NET_REGISTER_DEV(TTL_7406_DIP, name)
+#define TTL_7407_GATE(name) \
+ NET_REGISTER_DEV(TTL_7407_GATE, name)
+
+#define TTL_7407_DIP(name) \
+ NET_REGISTER_DEV(TTL_7407_DIP, name)
+
+
#define TTL_7408_GATE(name) \
NET_REGISTER_DEV(TTL_7408_GATE, name)
@@ -238,6 +245,10 @@
NET_REGISTER_DEV(TTL_7437_DIP, name)
+#define TTL_7442_DIP(name) \
+ NET_REGISTER_DEV(TTL_7442_DIP, name)
+
+
#if (NL_USE_TRUTHTABLE_7448)
#define TTL_7448(name, cA0, cA1, cA2, cA3, cLTQ, cBIQ, cRBIQ) \
NET_REGISTER_DEV(TTL_7448, name) \
@@ -250,11 +261,34 @@
NET_CONNECT(name, LTQ, cLTQ) \
NET_CONNECT(name, BIQ, cBIQ) \
NET_CONNECT(name, RBIQ, cRBIQ)
+#endif
#define TTL_7448_DIP(name) \
NET_REGISTER_DEV(TTL_7448_DIP, name)
-#endif
+#define TTL_7450_DIP(name) \
+ NET_REGISTER_DEV(TTL_7450_DIP, name)
+
+#define TTL_7473_DIP(name) \
+ NET_REGISTER_DEV(TTL_7473_DIP, name)
+
+#define TTL_7473A_DIP(name) \
+ NET_REGISTER_DEV(TTL_7473A_DIP, name)
+
+#define TTL_7474_DIP(name) \
+ NET_REGISTER_DEV(TTL_7474_DIP, name)
+
+#define TTL_7475_DIP(name) \
+ NET_REGISTER_DEV(TTL_7475_DIP, name)
+
+#define TTL_7477_DIP(name) \
+ NET_REGISTER_DEV(TTL_7477_DIP, name)
+
+#define TTL_7483_DIP(name) \
+ NET_REGISTER_DEV(TTL_7483_DIP, name)
+
+#define TTL_7485_DIP(name) \
+ NET_REGISTER_DEV(TTL_7485_DIP, name)
#define TTL_7486_GATE(name) \
NET_REGISTER_DEV(TTL_7486_GATE, name)
@@ -269,20 +303,35 @@
#define TTL_7486_DIP(name) \
NET_REGISTER_DEV(TTL_7486_DIP, name)
+#define TTL_7490_DIP(name) \
+ NET_REGISTER_DEV(TTL_7490_DIP, name)
+
+#define TTL_7492_DIP(name) \
+ NET_REGISTER_DEV(TTL_7492_DIP, name)
+
+#define TTL_7493_DIP(name) \
+ NET_REGISTER_DEV(TTL_7493_DIP, name)
+
+#define TTL_7497_DIP(name) \
+ NET_REGISTER_DEV(TTL_7497_DIP, name)
+
#if (NL_USE_TRUTHTABLE_74107)
-#define TTL_74107(name, cCLK, cJ, cK, cCLRQ) \
- NET_REGISTER_DEV(TTL_74107, name) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, CLK, cCLK) \
- NET_CONNECT(name, J, cJ) \
- NET_CONNECT(name, K, cK) \
- NET_CONNECT(name, CLRQ, cCLRQ)
+// usage: TTL_74107(name, cCLK, cJ, cK, cCLRQ)
+#define TTL_74107(...) \
+ NET_REGISTER_DEVEXT(TTL_74107_TT, __VA_ARGS__)
+#endif
#define TTL_74107_DIP(name) \
NET_REGISTER_DEV(TTL_74107_DIP, name)
-#endif
+#define TTL_74107A_DIP(name) \
+ NET_REGISTER_DEV(TTL_74107A_DIP, name)
+
+#define TTL_74113_DIP(name) \
+ NET_REGISTER_DEV(TTL_74113_DIP, name)
+
+#define TTL_74113A_DIP(name) \
+ NET_REGISTER_DEV(TTL_74113A_DIP, name)
#define TTL_74121_DIP(name) \
NET_REGISTER_DEV(TTL_74121_DIP, name)
@@ -296,6 +345,9 @@
#define TTL_74125_DIP(name) \
NET_REGISTER_DEV(TTL_74125_DIP, name)
+#define TTL_74153_DIP(name) \
+ NET_REGISTER_DEV(TTL_74153_DIP, name)
+
#define TTL_74155_DIP(name) \
NET_REGISTER_DEV(TTL_74155_DIP, name)
@@ -305,6 +357,24 @@
#define TTL_74157_DIP(name) \
NET_REGISTER_DEV(TTL_74157_DIP, name)
+#define TTL_74161_DIP(name) \
+ NET_REGISTER_DEV(TTL_74161_DIP, name)
+
+#define TTL_74163_DIP(name) \
+ NET_REGISTER_DEV(TTL_74163_DIP, name)
+
+#define TTL_74164_DIP(name) \
+ NET_REGISTER_DEV(TTL_74164_DIP, name)
+
+#define TTL_74165_DIP(name) \
+ NET_REGISTER_DEV(TTL_74165_DIP, name)
+
+#define TTL_74166_DIP(name) \
+ NET_REGISTER_DEV(TTL_74166_DIP, name)
+
+#define TTL_74174_DIP(name) \
+ NET_REGISTER_DEV(TTL_74174_DIP, name)
+
#define TTL_74260_GATE(name) \
NET_REGISTER_DEV(TTL_74260_GATE, name)
@@ -333,25 +403,23 @@
#define TTL_74379_DIP(name) \
NET_REGISTER_DEV(TTL_74379_DIP, name)
-#define DM9312(name, cA, cB, cC, cSTROBE, cD0, cD1, cD2, cD3, cD4, cD5, cD6, cD7) \
- NET_REGISTER_DEV(DM9312, name) \
- NET_CONNECT(name, VCC, VCC) \
- NET_CONNECT(name, GND, GND) \
- NET_CONNECT(name, A, cA) \
- NET_CONNECT(name, B, cB) \
- NET_CONNECT(name, C, cC) \
- NET_CONNECT(name, G, cSTROBE) \
- NET_CONNECT(name, D0, cD0) \
- NET_CONNECT(name, D1, cD1) \
- NET_CONNECT(name, D2, cD2) \
- NET_CONNECT(name, D3, cD3) \
- NET_CONNECT(name, D4, cD4) \
- NET_CONNECT(name, D5, cD5) \
- NET_CONNECT(name, D6, cD6) \
- NET_CONNECT(name, D7, cD7)
-
-#define DM9312_DIP(name) \
- NET_REGISTER_DEV(DM9312_DIP, name)
+#define TTL_74393_DIP(name) \
+ NET_REGISTER_DEV(TTL_74393_DIP, name)
+
+#define TTL_9312(...) \
+ NET_REGISTER_DEVEXT(TTL_9312, __VA_ARGS__)
+
+#define TTL_9312_DIP(name) \
+ NET_REGISTER_DEV(TTL_9312_DIP, name)
+
+#define TTL_9310_DIP(name) \
+ NET_REGISTER_DEV(TTL_9310_DIP, name)
+
+#define TTL_9316_DIP(name) \
+ NET_REGISTER_DEV(TTL_9316_DIP, name)
+
+#define TTL_9322_DIP(name) \
+ NET_REGISTER_DEV(TTL_9322_DIP, name)
#endif // NL_AUTO_DEVICES
@@ -359,7 +427,7 @@
* External declarations
* ---------------------------------------------------------------------------*/
-NETLIST_EXTERNAL(TTL74XX_lib)
+// moved to net_lib.h
#endif // __PLIB_PREPROCESSOR__
diff --git a/src/lib/netlist/nl_base.cpp b/src/lib/netlist/nl_base.cpp
index 22baf636461..d53606e52b8 100644
--- a/src/lib/netlist/nl_base.cpp
+++ b/src/lib/netlist/nl_base.cpp
@@ -115,7 +115,6 @@ namespace netlist
, m_extended_validation(false)
, m_dummy_version(1)
{
-
m_lib = m_callbacks->static_solver_lib();
m_setup = plib::make_unique<setup_t, host_arena>(*this);
@@ -130,7 +129,6 @@ namespace netlist
devices::initialize_factory(m_setup->parser().factory());
// Add default include file
- using a = plib::psource_str_t;
const pstring content =
"#define RES_R(res) (res) \n"
"#define RES_K(res) ((res) * 1e3) \n"
@@ -141,8 +139,25 @@ namespace netlist
"#define IND_U(ind) ((ind) * 1e-6) \n"
"#define IND_N(ind) ((ind) * 1e-9) \n"
"#define IND_P(ind) ((ind) * 1e-12) \n";
- m_setup->parser().add_include<a>("netlist/devices/net_lib.h", content);
+ m_setup->parser().add_include<plib::psource_str_t>("netlist/devices/net_lib.h", content);
+#if 1
NETLIST_NAME(base)(m_setup->parser());
+#else
+ // FIXME: This is very slow - need optimized parsing scanning
+#if 0
+ m_setup->parser().register_source<source_pattern_t>("src/lib/netlist/macro/nlm_{}.cpp");
+#else
+ pstring dir = "src/lib/netlist/macro/";
+ //m_setup->parser().register_source<source_pattern_t>("src/lib/netlist/macro/nlm_{}.cpp");
+ m_setup->parser().register_source<source_file_t>(dir + "nlm_base.cpp");
+ m_setup->parser().register_source<source_file_t>(dir + "nlm_opamp.cpp");
+ m_setup->parser().register_source<source_file_t>(dir + "nlm_roms.cpp");
+ m_setup->parser().register_source<source_file_t>(dir + "nlm_cd4xxx.cpp");
+ m_setup->parser().register_source<source_file_t>(dir + "nlm_other.cpp");
+ m_setup->parser().register_source<source_file_t>(dir + "nlm_ttl74xx.cpp");
+ m_setup->parser().include("base");
+#endif
+#endif
}
@@ -759,6 +774,16 @@ namespace netlist
net().initial(val);
}
+ // -----------------------------------------------------------------------------
+ // tristate_output_t
+ // -----------------------------------------------------------------------------
+ tristate_output_t::tristate_output_t(device_t &dev, const pstring &aname, bool force_logic)
+ : logic_output_t(dev, aname)
+ , m_last_logic(dev, name() + "." + "m_last_logic", 1) // force change
+ , m_tristate(dev, name() + "." + "m_tristate", force_logic ? 0 : 2) // force change
+ , m_force_logic(force_logic)
+ {}
+
// ----------------------------------------------------------------------------------------
// analog_input_t
// ----------------------------------------------------------------------------------------
@@ -881,7 +906,7 @@ namespace netlist
}
- std::unique_ptr<std::istream> param_data_t::stream()
+ plib::psource_t::stream_ptr param_data_t::stream()
{
return device().state().parser().get_data_stream(str());
}
@@ -939,6 +964,17 @@ namespace netlist
nlparse_t &netlist_state_t::parser() { return m_setup->parser(); }
const nlparse_t &netlist_state_t::parser() const { return m_setup->parser(); }
+ void netlist_state_t::remove_device(core_device_t *dev)
+ {
+ for (auto it = m_devices.begin(); it != m_devices.end(); it++)
+ if (it->second.get() == dev)
+ {
+ m_state.remove_save_items(dev);
+ m_devices.erase(it);
+ return;
+ }
+ }
+
template struct state_var<std::uint8_t>;
template struct state_var<std::uint16_t>;
template struct state_var<std::uint32_t>;
diff --git a/src/lib/netlist/nl_base.h b/src/lib/netlist/nl_base.h
index 45b64c5e122..b6f5da80461 100644
--- a/src/lib/netlist/nl_base.h
+++ b/src/lib/netlist/nl_base.h
@@ -12,11 +12,16 @@
#error "nl_base.h included. Please correct."
#endif
+#include "core/analog.h"
#include "core/base_objects.h"
-#include "core/param.h"
-#include "core/state_var.h"
+#include "core/device.h"
+#include "core/logic.h"
#include "core/logic_family.h"
+#include "core/netlist_state.h"
#include "core/nets.h"
+#include "core/object_array.h"
+#include "core/param.h"
+#include "core/state_var.h"
#include "plib/palloc.h" // owned_ptr
#include "plib/pfunction.h"
@@ -211,664 +216,6 @@ namespace netlist
- // -----------------------------------------------------------------------------
- // analog_t
- // -----------------------------------------------------------------------------
-
- class analog_t : public detail::core_terminal_t
- {
- public:
-
- analog_t(core_device_t &dev, const pstring &aname, state_e state,
- nldelegate delegate);
-
- const analog_net_t & net() const noexcept;
- analog_net_t & net() noexcept;
-
- solver::matrix_solver_t *solver() const noexcept;
- };
-
- /// \brief Base clase for terminals.
- ///
- /// Each \ref nld_twoterm object consists of two terminals. Terminals
- /// are at the core of analog netlists and provide. \ref net_t objects
- /// connect terminals.
- ///
- class terminal_t : public analog_t
- {
- public:
-
- /// \brief constructor
- ///
- /// @param dev core_devict_t object owning the terminal
- /// @param aname name of this terminal
- /// @param otherterm pointer to the sibling terminal
- terminal_t(core_device_t &dev, const pstring &aname, terminal_t *otherterm, nldelegate delegate);
-
- /// \brief Returns voltage of connected net
- ///
- /// @return voltage of net this terminal is connected to
- nl_fptype operator ()() const noexcept;
-
- /// @brief sets conductivity value of this terminal
- ///
- /// @param G Conductivity
- void set_conductivity(nl_fptype G) const noexcept
- {
- set_go_gt_I(-G, G, nlconst::zero());
- }
-
- void set_go_gt(nl_fptype GO, nl_fptype GT) const noexcept
- {
- set_go_gt_I(GO, GT, nlconst::zero());
- }
-
- void set_go_gt_I(nl_fptype GO, nl_fptype GT, nl_fptype I) const noexcept
- {
- // Check for rail nets ...
- if (m_go != nullptr)
- {
- *m_Idr = I;
- *m_go = GO;
- *m_gt = GT;
- }
- }
-
- void set_ptrs(nl_fptype *gt, nl_fptype *go, nl_fptype *Idr) noexcept(false);
-
- private:
- nl_fptype *m_Idr; ///< drive current
- nl_fptype *m_go; ///< conductance for Voltage from other term
- nl_fptype *m_gt; ///< conductance for total conductance
-
- };
-
-
- // -----------------------------------------------------------------------------
- // logic_t
- // -----------------------------------------------------------------------------
-
- class logic_t : public detail::core_terminal_t, public logic_family_t
- {
- public:
- logic_t(device_t &dev, const pstring &aname,
- state_e terminal_state, nldelegate delegate);
-
- logic_net_t & net() noexcept;
- const logic_net_t & net() const noexcept;
- };
-
- // -----------------------------------------------------------------------------
- // logic_input_t
- // -----------------------------------------------------------------------------
-
- class logic_input_t : public logic_t
- {
- public:
- logic_input_t(device_t &dev, const pstring &aname,
- nldelegate delegate);
-
- inline netlist_sig_t operator()() const noexcept;
-
- void inactivate() noexcept;
- void activate() noexcept;
- void activate_hl() noexcept;
- void activate_lh() noexcept;
- };
-
- // -----------------------------------------------------------------------------
- // analog_input_t
- // -----------------------------------------------------------------------------
-
- /// \brief terminal providing analog input voltage.
- ///
- /// This terminal class provides a voltage measurement. The conductance against
- /// ground is infinite.
-
- class analog_input_t : public analog_t
- {
- public:
- /// \brief Constructor
- analog_input_t(core_device_t &dev, ///< owning device
- const pstring &aname, ///< name of terminal
- nldelegate delegate ///< delegate
- );
-
- /// \brief returns voltage at terminal.
- /// \returns voltage at terminal.
- nl_fptype operator()() const noexcept { return Q_Analog(); }
-
- /// \brief returns voltage at terminal.
- /// \returns voltage at terminal.
- nl_fptype Q_Analog() const noexcept;
- };
-
- // -----------------------------------------------------------------------------
- // logic_output_t
- // -----------------------------------------------------------------------------
-
- class logic_output_t : public logic_t
- {
- public:
-
- /// \brief logic output constructor
- ///
- /// The third parameter does nothing. It is provided only for
- /// compatibility with tristate_output_t in templatized device models
- ///
- /// \param dev Device owning this output
- /// \param aname The name of this output
- /// \param dummy Dummy parameter to allow construction like tristate output
- ///
- logic_output_t(device_t &dev, const pstring &aname, bool dummy = false);
-
- void initial(netlist_sig_t val) noexcept;
-
- inline void push(const netlist_sig_t &newQ, const netlist_time &delay) noexcept
- {
- m_my_net.set_Q_and_push(newQ, delay); // take the shortcut
- }
-
- inline void set_Q_time(const netlist_sig_t &newQ, const netlist_time_ext &at) noexcept
- {
- m_my_net.set_Q_time(newQ, at); // take the shortcut
- }
-
- /// \brief Dummy implementation for templatized generic devices
- ///
- /// This function shall never be called. It is defined here so that
- /// templatized generic device models do not have to do tons of
- /// template magic.
- ///
- /// This function terminates if actually called.
- ///
- [[noreturn]] static void set_tristate(netlist_sig_t v,
- netlist_time ts_off_on, netlist_time ts_on_off)
- {
- plib::unused_var(v, ts_off_on, ts_on_off);
- plib::terminate("set_tristate on logic_output should never be called!");
- }
- private:
- logic_net_t m_my_net;
- };
-
- // -----------------------------------------------------------------------------
- // tristate_output_t
- // -----------------------------------------------------------------------------
-
- /// \brief Tristate output
- ///
- /// In a lot of applications tristate enable inputs are just connected to
- /// VCC/GND to permanently enable the outputs. In this case a pure
- /// implementation using analog outputs would not perform well.
- ///
- /// For this object during creation it can be decided if a logic output or
- /// a tristate output is used. Generally the owning device uses parameter
- /// FORCE_TRISTATE_LOGIC to determine this.
- ///
- /// This is the preferred way to implement tristate outputs.
- ///
-
- class tristate_output_t : public logic_output_t
- {
- public:
-
- tristate_output_t(device_t &dev, const pstring &aname, bool force_logic)
- : logic_output_t(dev, aname)
- , m_last_logic(dev, name() + "." + "m_last_logic", 1) // force change
- , m_tristate(dev, name() + "." + "m_tristate", force_logic ? 0 : 2) // force change
- , m_force_logic(force_logic)
- {}
-
- void push(netlist_sig_t newQ, netlist_time delay) noexcept
- {
- if (!m_tristate)
- logic_output_t::push(newQ, delay);
- m_last_logic = newQ;
- }
-
- void set_tristate(netlist_sig_t v,
- netlist_time ts_off_on, netlist_time ts_on_off) noexcept
- {
- if (!m_force_logic)
- if (v != m_tristate)
- {
- logic_output_t::push((v != 0) ? OUT_TRISTATE() : m_last_logic, v ? ts_off_on : ts_on_off);
- m_tristate = v;
- }
- }
-
- bool is_force_logic() const noexcept
- {
- return m_force_logic;
- }
-
- private:
- using logic_output_t::initial;
- using logic_output_t::set_Q_time;
- state_var<netlist_sig_t> m_last_logic;
- state_var<netlist_sig_t> m_tristate;
- bool m_force_logic;
- };
-
-
- // -----------------------------------------------------------------------------
- // analog_output_t
- // -----------------------------------------------------------------------------
-
- class analog_output_t : public analog_t
- {
- public:
- analog_output_t(core_device_t &dev, const pstring &aname);
-
- void push(nl_fptype val) noexcept;
- void initial(nl_fptype val) noexcept;
-
- private:
- analog_net_t m_my_net;
- };
-
-
- // -----------------------------------------------------------------------------
- // base_device_t
- // -----------------------------------------------------------------------------
-
- class base_device_t : public core_device_t
- {
- public:
- base_device_t(netlist_state_t &owner, const pstring &name);
- base_device_t(base_device_t &owner, const pstring &name);
-
- PCOPYASSIGNMOVE(base_device_t, delete)
-
- ~base_device_t() noexcept override = default;
-
- template<class O, class C, typename... Args>
- void create_and_register_subdevice(O& owner, const pstring &name, device_arena::unique_ptr<C> &dev, Args&&... args);
-
- void register_subalias(const pstring &name, const detail::core_terminal_t &term);
- void register_subalias(const pstring &name, const pstring &aliased);
-
- void connect(const pstring &t1, const pstring &t2);
- void connect(const detail::core_terminal_t &t1, const detail::core_terminal_t &t2);
- protected:
-
- //NETLIB_UPDATE_TERMINALSI() { }
-
- private:
- };
-
- // -----------------------------------------------------------------------------
- // device_t
- // -----------------------------------------------------------------------------
-
- class device_t : public base_device_t,
- public logic_family_t
- {
- public:
- device_t(netlist_state_t &owner, const pstring &name);
- device_t(netlist_state_t &owner, const pstring &name,
- const pstring &model);
- // only needed by proxies
- device_t(netlist_state_t &owner, const pstring &name,
- const logic_family_desc_t *desc);
-
- device_t(device_t &owner, const pstring &name);
- // pass in a default model - this may be overwritten by PARAM(DEVICE.MODEL, "XYZ(...)")
- device_t(device_t &owner, const pstring &name,
- const pstring &model);
-
- PCOPYASSIGNMOVE(device_t, delete)
-
- ~device_t() noexcept override = default;
-
- protected:
-
- //NETLIB_UPDATE_TERMINALSI() { }
-
- private:
- param_model_t m_model;
- };
-
- namespace detail {
- // Use timed_queue_heap to use stdc++ heap functions instead of linear processing.
- // This slows down processing by about 25% on a Kaby Lake.
- // template <class T, bool TS>
- // using timed_queue = plib::timed_queue_heap<T, TS>;
-
- template <class T, bool TS>
- using timed_queue = plib::timed_queue_linear<T, TS>;
-
- // -----------------------------------------------------------------------------
- // queue_t
- // -----------------------------------------------------------------------------
-
- // We don't need a thread-safe queue currently. Parallel processing of
- // solvers will update inputs after parallel processing.
-
- template <typename O, bool TS>
- class queue_base :
- public timed_queue<plib::pqentry_t<netlist_time_ext, O *>, false>,
- public plib::state_manager_t::callback_t
- {
- public:
- using entry_t = plib::pqentry_t<netlist_time_ext, O *>;
- using base_queue = timed_queue<entry_t, false>;
- using id_delegate = plib::pmfp<std::size_t, const O *>;
- using obj_delegate = plib::pmfp<O *, std::size_t>;
-
- explicit queue_base(std::size_t size, id_delegate get_id, obj_delegate get_obj)
- : timed_queue<plib::pqentry_t<netlist_time_ext, O *>, false>(size)
- , m_qsize(0)
- , m_times(size)
- , m_net_ids(size)
- , m_get_id(get_id)
- , m_obj_by_id(get_obj)
- {
- }
-
- ~queue_base() noexcept override = default;
-
- queue_base(const queue_base &) = delete;
- queue_base(queue_base &&) = delete;
- queue_base &operator=(const queue_base &) = delete;
- queue_base &operator=(queue_base &&) = delete;
-
- protected:
-
- void register_state(plib::state_manager_t &manager, const pstring &module) override
- {
- manager.save_item(this, m_qsize, module + "." + "qsize");
- manager.save_item(this, &m_times[0], module + "." + "times", m_times.size());
- manager.save_item(this, &m_net_ids[0], module + "." + "names", m_net_ids.size());
- }
- void on_pre_save(plib::state_manager_t &manager) override
- {
- plib::unused_var(manager);
- m_qsize = this->size();
- for (std::size_t i = 0; i < m_qsize; i++ )
- {
- m_times[i] = this->listptr()[i].exec_time().as_raw();
- m_net_ids[i] = m_get_id(this->listptr()[i].object());
- }
- }
- void on_post_load(plib::state_manager_t &manager) override
- {
- plib::unused_var(manager);
- this->clear();
- for (std::size_t i = 0; i < m_qsize; i++ )
- {
- O *n = m_obj_by_id(m_net_ids[i]);
- this->template push<false>(entry_t(netlist_time_ext::from_raw(m_times[i]),n));
- }
- }
-
- private:
- std::size_t m_qsize;
- std::vector<netlist_time_ext::internal_type> m_times;
- std::vector<std::size_t> m_net_ids;
- id_delegate m_get_id;
- obj_delegate m_obj_by_id;
- };
-
- using queue_t = queue_base<net_t, false>;
-
- } // namespace detail
-
- // -----------------------------------------------------------------------------
- // netlist_state__t
- // -----------------------------------------------------------------------------
-
- class netlist_state_t
- {
- public:
-
- using nets_collection_type = std::vector<device_arena::owned_ptr<detail::net_t>>;
- using family_collection_type = std::unordered_map<pstring, host_arena::unique_ptr<logic_family_desc_t>>;
-
- // need to preserve order of device creation ...
- using devices_collection_type = std::vector<std::pair<pstring, device_arena::owned_ptr<core_device_t>>>;
- netlist_state_t(const pstring &name, host_arena::unique_ptr<callbacks_t> &&callbacks);
-
- PCOPYASSIGNMOVE(netlist_state_t, delete)
-
- /// \brief Destructor
- ///
- /// The destructor is virtual to allow implementation specific devices
- /// to connect to the outside world. For examples see MAME netlist.cpp.
- ///
- virtual ~netlist_state_t() noexcept = default;
-
- template<class C>
- static bool check_class(core_device_t *p) noexcept
- {
- return dynamic_cast<C *>(p) != nullptr;
- }
-
- core_device_t *get_single_device(const pstring &classname, bool (*cc)(core_device_t *)) const noexcept(false);
-
- /// \brief Get single device filtered by class and name
- ///
- /// \tparam C Device class for which devices will be returned
- /// \param name Name of the device
- ///
- /// \return pointers to device
-
- template<class C>
- C *get_single_device(const pstring &name) const
- {
- return dynamic_cast<C *>(get_single_device(name, check_class<C>));
- }
-
- /// \brief Get vector of devices
- ///
- /// \tparam C Device class for which devices will be returned
- ///
- /// \return vector with pointers to devices
-
- template<class C>
- inline std::vector<C *> get_device_list() const
- {
- std::vector<C *> tmp;
- for (const auto &d : m_devices)
- {
- auto * const dev = dynamic_cast<C *>(d.second.get());
- if (dev != nullptr)
- tmp.push_back(dev);
- }
- return tmp;
- }
-
- // logging
-
- log_type & log() noexcept { return m_log; }
- const log_type &log() const noexcept { return m_log; }
-
- plib::dynlib_base &lib() const noexcept { return *m_lib; }
-
- netlist_t &exec() noexcept { return *m_netlist; }
- const netlist_t &exec() const noexcept { return *m_netlist; }
-
- // state handling
- plib::state_manager_t &run_state_manager() noexcept { return m_state; }
-
- template<typename O, typename C>
- void save(O &owner, C &state, const pstring &module, const pstring &stname)
- {
- this->run_state_manager().save_item(static_cast<void *>(&owner), state, module + "." + stname);
- }
-
- template<typename O, typename C>
- void save(O &owner, C *state, const pstring &module, const pstring &stname, const std::size_t count)
- {
- this->run_state_manager().save_state_ptr(static_cast<void *>(&owner), module + "." + stname, plib::state_manager_t::dtype<C>(), count, state);
- }
-
- // FIXME: only used by queue_t save state
- std::size_t find_net_id(const detail::net_t *net) const;
- detail::net_t *net_by_id(std::size_t id) const;
-
- template <typename T>
- void register_net(device_arena::owned_ptr<T> &&net) { m_nets.push_back(std::move(net)); }
-
- /// \brief Get device pointer by name
- ///
- ///
- /// \param name Name of the device
- ///
- /// \return core_device_t pointer if device exists, else nullptr
-
- core_device_t *find_device(const pstring &name) const
- {
- for (const auto & d : m_devices)
- if (d.first == name)
- return d.second.get();
- return nullptr;
- }
-
- /// \brief Register device using owned_ptr
- ///
- /// Used to register owned devices. These are devices declared as objects
- /// in another devices.
- ///
- /// \param name Name of the device
- /// \param dev Device to be registered
-
- template <typename T>
- void register_device(const pstring &name, device_arena::owned_ptr<T> &&dev) noexcept(false)
- {
- for (auto & d : m_devices)
- if (d.first == name)
- {
- dev.release();
- log().fatal(MF_DUPLICATE_NAME_DEVICE_LIST(name));
- throw nl_exception(MF_DUPLICATE_NAME_DEVICE_LIST(name));
- }
- //m_devices.push_back(std::move(dev));
- m_devices.insert(m_devices.end(), { name, std::move(dev) });
- }
-
- /// \brief Register device using unique_ptr
- ///
- /// Used to register devices.
- ///
- /// \param name Name of the device
- /// \param dev Device to be registered
-
- template <typename T>
- void register_device(const pstring &name, device_arena::unique_ptr<T> &&dev)
- {
- register_device(name, device_arena::owned_ptr<T>(dev.release(), true, dev.get_deleter()));
- }
-
- /// \brief Remove device
- ///
- /// Care needs to be applied if this is called to remove devices with
- /// sub-devices which may have registered state.
- ///
- /// \param dev Device to be removed
-
- void remove_device(core_device_t *dev)
- {
- for (auto it = m_devices.begin(); it != m_devices.end(); it++)
- if (it->second.get() == dev)
- {
- m_state.remove_save_items(dev);
- m_devices.erase(it);
- return;
- }
- }
-
- setup_t &setup() noexcept { return *m_setup; }
- const setup_t &setup() const noexcept { return *m_setup; }
-
- nlparse_t &parser();
- const nlparse_t &parser() const;
-
- // FIXME: make a postload member and include code there
- void rebuild_lists(); // must be called after post_load !
-
- static void compile_defines(std::vector<std::pair<pstring, pstring>> &defs);
- static pstring version();
- static pstring version_patchlevel();
-
- nets_collection_type & nets() noexcept { return m_nets; }
- const nets_collection_type & nets() const noexcept { return m_nets; }
-
- devices_collection_type & devices() noexcept { return m_devices; }
- const devices_collection_type & devices() const noexcept { return m_devices; }
-
- family_collection_type &family_cache() { return m_family_cache; }
-
- template<typename T, typename... Args>
- device_arena::unique_ptr<T> make_pool_object(Args&&... args)
- {
- return plib::make_unique<T>(m_pool, std::forward<Args>(args)...);
- }
- // memory pool - still needed in some places
- device_arena &pool() noexcept { return m_pool; }
- const device_arena &pool() const noexcept { return m_pool; }
-
- /// \brief set extended validation mode.
- ///
- /// The extended validation mode is not intended for running.
- /// The intention is to identify power pins which are not properly
- /// connected. The downside is that this mode creates a netlist which
- /// is different (and not able to run).
- ///
- /// Extended validation is supported by nltool validate option.
- ///
- /// \param val Boolean value enabling/disabling extended validation mode
- void set_extended_validation(bool val) { m_extended_validation = val; }
-
- /// \brief State of extended validation mode.
- ///
- /// \returns boolean value indicating if extended validation mode is
- /// turned on.
- bool is_extended_validation() const { return m_extended_validation; }
-
- struct stats_info
- {
- const detail::queue_t &m_queue;// performance
- const plib::pperftime_t<true> &m_stat_mainloop;
- const plib::pperfcount_t<true> &m_perf_out_processed;
- };
-
- /// \brief print statistics gathered during run
- ///
- void print_stats(stats_info &si) const;
-
- /// \brief call reset on all netlist components
- ///
- void reset();
-
- /// \brief prior to running free no longer needed resources
- ///
- void free_setup_resources();
-
- private:
-
- device_arena m_pool; // must be deleted last!
-
- device_arena::unique_ptr<netlist_t> m_netlist;
- std::unique_ptr<plib::dynlib_base> m_lib;
- plib::state_manager_t m_state;
- host_arena::unique_ptr<callbacks_t> m_callbacks;
- log_type m_log;
-
- // FIXME: should only be available during device construcion
- host_arena::unique_ptr<setup_t> m_setup;
-
- nets_collection_type m_nets;
- // sole use is to manage lifetime of net objects
- devices_collection_type m_devices;
- // sole use is to manage lifetime of family objects
- family_collection_type m_family_cache;
- bool m_extended_validation;
-
- // dummy version
- int m_dummy_version;
- };
namespace devices
{
@@ -1001,206 +348,6 @@ namespace netlist
// Support classes for devices
// -----------------------------------------------------------------------------
- template<class C, std::size_t N>
- class object_array_base_t : public plib::static_vector<C, N>
- {
- public:
- template<class D, typename... Args>
- //object_array_base_t(D &dev, const std::initializer_list<const char *> &names, Args&&... args)
- object_array_base_t(D &dev, std::array<const char *, N> &&names, Args&&... args)
- {
- for (std::size_t i = 0; i<N; i++)
- this->emplace_back(dev, pstring(names[i]), std::forward<Args>(args)...);
- }
-
- template<class D>
- object_array_base_t(D &dev, const pstring &fmt)
- {
- for (std::size_t i = 0; i<N; i++)
- this->emplace_back(dev, formatted(fmt, i));
- }
-
- template<class D, typename... Args>
- object_array_base_t(D &dev, std::size_t offset, const pstring &fmt, Args&&... args)
- {
- for (std::size_t i = 0; i<N; i++)
- this->emplace_back(dev, formatted(fmt, i+offset), std::forward<Args>(args)...);
- }
-
- template<class D>
- object_array_base_t(D &dev, std::size_t offset, const pstring &fmt, nldelegate delegate)
- {
- for (std::size_t i = 0; i<N; i++)
- this->emplace_back(dev, formatted(fmt, i+offset), delegate);
- }
-
- template<class D>
- object_array_base_t(D &dev, std::size_t offset, std::size_t qmask, const pstring &fmt)
- {
- for (std::size_t i = 0; i<N; i++)
- {
- pstring name(formatted(fmt, i+offset));
- if ((qmask >> i) & 1)
- name += "Q";
- this->emplace(i, dev, name);
- }
- }
- protected:
- object_array_base_t() = default;
-
- static pstring formatted(const pstring &fmt, std::size_t n)
- {
- if (N != 1)
- return plib::pfmt(fmt)(n);
- return plib::pfmt(fmt)("");
- }
- };
-
-
- template<class C, std::size_t N>
- class object_array_t : public object_array_base_t<C, N>
- {
- public:
- using base_type = object_array_base_t<C, N>;
- using base_type::base_type;
- };
-
- template<std::size_t N>
- class object_array_t<logic_input_t,N> : public object_array_base_t<logic_input_t, N>
- {
- public:
- using base_type = object_array_base_t<logic_input_t, N>;
- using base_type::base_type;
-
- template<class D, std::size_t ND>
- object_array_t(D &dev, std::size_t offset, std::size_t qmask,
- const pstring &fmt, std::array<nldelegate, ND> &&delegates)
- {
- static_assert(N <= ND, "initializer_list size mismatch");
- std::size_t i = 0;
- for (auto &e : delegates)
- {
- if (i < N)
- {
- pstring name(this->formatted(fmt, i+offset));
- if ((qmask >> i) & 1)
- name += "Q";
- this->emplace_back(dev, name, e);
- }
- i++;
- }
- }
-
- //using value_type = typename plib::fast_type_for_bits<N>::type;
- using value_type = std::uint32_t;
- value_type operator ()()
- {
- if (N == 1) return e<0>() ;
- if (N == 2) return e<0>() | (e<1>() << 1);
- if (N == 3) return e<0>() | (e<1>() << 1) | (e<2>() << 2);
- if (N == 4) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3);
- if (N == 5) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
- | (e<4>() << 4);
- if (N == 6) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
- | (e<4>() << 4) | (e<5>() << 5);
- if (N == 7) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
- | (e<4>() << 4) | (e<5>() << 5) | (e<6>() << 6);
- if (N == 8) return e<0>() | (e<1>() << 1) | (e<2>() << 2) | (e<3>() << 3)
- | (e<4>() << 4) | (e<5>() << 5) | (e<6>() << 6) | (e<7>() << 7);
-
- value_type r(0);
- for (std::size_t i = 0; i < N; i++)
- r = static_cast<value_type>((*this)[i]() << (N-1)) | (r >> 1);
- return r;
- }
-
- private:
- template <std::size_t P>
- inline constexpr value_type e() const { return (*this)[P](); }
- };
-
- template<std::size_t N>
- class object_array_t<logic_output_t,N> : public object_array_base_t<logic_output_t, N>
- {
- public:
- using base_type = object_array_base_t<logic_output_t, N>;
- using base_type::base_type;
-
- template <typename T>
- inline void push(const T &v, const netlist_time &t)
- {
- if (N >= 1) (*this)[0].push((v >> 0) & 1, t);
- if (N >= 2) (*this)[1].push((v >> 1) & 1, t);
- if (N >= 3) (*this)[2].push((v >> 2) & 1, t);
- if (N >= 4) (*this)[3].push((v >> 3) & 1, t);
- if (N >= 5) (*this)[4].push((v >> 4) & 1, t);
- if (N >= 6) (*this)[5].push((v >> 5) & 1, t);
- if (N >= 7) (*this)[6].push((v >> 6) & 1, t);
- if (N >= 8) (*this)[7].push((v >> 7) & 1, t);
- for (std::size_t i = 8; i < N; i++)
- (*this)[i].push((v >> i) & 1, t);
- }
-
- template<typename T>
- void push(const T &v, const netlist_time * t)
- {
- if (N >= 1) (*this)[0].push((v >> 0) & 1, t[0]);
- if (N >= 2) (*this)[1].push((v >> 1) & 1, t[1]);
- if (N >= 3) (*this)[2].push((v >> 2) & 1, t[2]);
- if (N >= 4) (*this)[3].push((v >> 3) & 1, t[3]);
- if (N >= 5) (*this)[4].push((v >> 4) & 1, t[4]);
- if (N >= 6) (*this)[5].push((v >> 5) & 1, t[5]);
- if (N >= 7) (*this)[6].push((v >> 6) & 1, t[6]);
- if (N >= 8) (*this)[7].push((v >> 7) & 1, t[7]);
- for (std::size_t i = 8; i < N; i++)
- (*this)[i].push((v >> i) & 1, t[i]);
- }
-
- template<typename T, std::size_t NT>
- void push(const T &v, const std::array<netlist_time, NT> &t)
- {
- static_assert(NT >= N, "Not enough timing entries provided");
-
- push(v, t.data());
- }
-
- void set_tristate(netlist_sig_t v,
- netlist_time ts_off_on, netlist_time ts_on_off) noexcept
- {
- for (std::size_t i = 0; i < N; i++)
- (*this)[i].set_tristate(v, ts_off_on, ts_on_off);
- }
- };
-
- template<std::size_t N>
- class object_array_t<tristate_output_t,N> : public object_array_base_t<tristate_output_t, N>
- {
- public:
- using base_type = object_array_base_t<tristate_output_t, N>;
- using base_type::base_type;
-
- template <typename T>
- inline void push(const T &v, const netlist_time &t)
- {
- if (N >= 1) (*this)[0].push((v >> 0) & 1, t);
- if (N >= 2) (*this)[1].push((v >> 1) & 1, t);
- if (N >= 3) (*this)[2].push((v >> 2) & 1, t);
- if (N >= 4) (*this)[3].push((v >> 3) & 1, t);
- if (N >= 5) (*this)[4].push((v >> 4) & 1, t);
- if (N >= 6) (*this)[5].push((v >> 5) & 1, t);
- if (N >= 7) (*this)[6].push((v >> 6) & 1, t);
- if (N >= 8) (*this)[7].push((v >> 7) & 1, t);
- for (std::size_t i = 8; i < N; i++)
- (*this)[i].push((v >> i) & 1, t);
- }
-
- void set_tristate(netlist_sig_t v,
- netlist_time ts_off_on, netlist_time ts_on_off) noexcept
- {
- for (std::size_t i = 0; i < N; i++)
- (*this)[i].set_tristate(v, ts_off_on, ts_on_off);
- }
- };
// -----------------------------------------------------------------------------
// power pins - not a device, but a helper
@@ -1222,6 +369,14 @@ namespace netlist
{
}
+ // Some devices like the 74LS629 have two pairs of supply pins.
+ explicit nld_power_pins(device_t &owner,
+ const pstring &vcc, const pstring &gnd)
+ : m_VCC(owner, vcc, NETLIB_DELEGATE(noop))
+ , m_GND(owner, gnd, NETLIB_DELEGATE(noop))
+ {
+ }
+
const analog_input_t &VCC() const noexcept
{
return m_VCC;
@@ -1254,7 +409,7 @@ namespace netlist
// -----------------------------------------------------------------------------
// logic_input_t
// -----------------------------------------------------------------------------
-
+#if 0
inline void logic_input_t::inactivate() noexcept
{
if (!is_state(STATE_INP_PASSIVE))
@@ -1290,7 +445,7 @@ namespace netlist
set_state(STATE_INP_LH);
}
}
-
+#endif
inline void detail::net_t::push_to_queue(const netlist_time &delay) noexcept
{
if (has_connections())
@@ -1352,6 +507,12 @@ namespace netlist
railterminal().device().do_dec_active();
}
+#if 0
+ inline nl_fptype terminal_t::operator ()() const noexcept
+ {
+ return net().Q_Analog();
+ }
+
inline const analog_net_t & analog_t::net() const noexcept
{
return plib::downcast<const analog_net_t &>(core_terminal_t::net());
@@ -1362,7 +523,6 @@ namespace netlist
return plib::downcast<analog_net_t &>(core_terminal_t::net());
}
- inline nl_fptype terminal_t::operator ()() const noexcept { return net().Q_Analog(); }
inline logic_net_t & logic_t::net() noexcept
{
@@ -1373,7 +533,6 @@ namespace netlist
{
return plib::downcast<const logic_net_t &>(core_terminal_t::net());
}
-
inline netlist_sig_t logic_input_t::operator()() const noexcept
{
nl_assert(terminal_state() != STATE_INP_PASSIVE);
@@ -1397,6 +556,7 @@ namespace netlist
m_my_net.toggle_and_push_to_queue(netlist_time::quantum());
}
}
+#endif
inline netlist_t &detail::device_object_t::exec() noexcept
{
@@ -1524,13 +684,13 @@ namespace netlist
// -----------------------------------------------------------------------------
// inline implementations - cold
// -----------------------------------------------------------------------------
-
+#if 0
template<typename T, typename... Args>
inline device_arena::unique_ptr<T> detail::netlist_object_t::make_pool_object(Args&&... args)
{
return state().make_pool_object<T>(std::forward<Args>(args)...);
}
-
+#endif
inline void param_t::update_param() noexcept
{
device().update_param();
@@ -1583,22 +743,23 @@ namespace netlist
param_rom_t<ST, AW, DW>::param_rom_t(core_device_t &device, const pstring &name)
: param_data_t(device, name)
{
- auto f = stream();
- if (f != nullptr)
+ auto f = this->stream();
+ if (!f.empty())
{
- plib::istream_read(*f, m_data.data(), 1<<AW);
+ plib::istream_read(f.stream(), m_data.data(), 1<<AW);
// FIXME: check for failbit if not in validation.
}
else
device.state().log().warning(MW_ROM_NOT_FOUND(str()));
}
+#if 0
template<class O, class C, typename... Args>
void base_device_t::create_and_register_subdevice(O &owner, const pstring &name, device_arena::unique_ptr<C> &dev, Args&&... args)
{
dev = state().make_pool_object<C>(owner, name, std::forward<Args>(args)...);
}
-
+#endif
inline solver::matrix_solver_t *analog_t::solver() const noexcept
{
return (this->has_net() ? net().solver() : nullptr);
diff --git a/src/lib/netlist/nl_errstr.h b/src/lib/netlist/nl_errstr.h
index 93225a99023..67510fbf453 100644
--- a/src/lib/netlist/nl_errstr.h
+++ b/src/lib/netlist/nl_errstr.h
@@ -24,7 +24,7 @@ namespace netlist
PERRMSGV(MF_NULLPTR_FAMILY, 2, "Unable to determine family for device {1} from model {2}")
PERRMSGV(MF_REMOVE_TERMINAL_1_FROM_NET_2, 2, "Can not remove terminal {1} from net {2}.")
PERRMSGV(MF_UNKNOWN_PARAM_TYPE, 1, "Can not determine param_type for {1}")
- PERRMSGV(MF_ERROR_CONNECTING_1_TO_2, 2, "Error connecting {1} to {2}")
+ //PERRMSGV(MF_ERROR_CONNECTING_1_TO_2, 2, "Error connecting {1} to {2}")
PERRMSGV(ME_HND_VAL_NOT_SUPPORTED, 1, "HINT_NO_DEACTIVATE value not supported: <{1}>")
PERRMSGV(MW_ROM_NOT_FOUND, 1, "Rom {1} not found")
@@ -43,6 +43,7 @@ namespace netlist
PERRMSGV(MF_UNEXPECTED_NETLIST_END, 0, "Unexpected NETLIST_END")
PERRMSGV(MF_UNEXPECTED_END_OF_FILE, 0, "Unexpected end of file, missing NETLIST_END")
PERRMSGV(MF_UNEXPECTED_NETLIST_START, 0, "Unexpected NETLIST_START")
+ PERRMSGV(MF_EXPECTED_NETLIST_START_1, 1, "Expected NETLIST_START but got {1}")
PERRMSGV(MF_EXPECTED_IDENTIFIER_GOT_1, 1, "Expected an identifier, but got {1}")
PERRMSGV(MF_EXPECTED_COMMA_OR_RP_1, 1, "Expected comma or right parenthesis but found <{1}>")
PERRMSGV(MF_DIPPINS_EQUAL_NUMBER_1, 1, "DIPPINS requires equal number of pins to DIPPINS, first pin is {}")
@@ -111,7 +112,7 @@ namespace netlist
"but has been forced to act as a logic output. Parameter "
" FORCE_TRISTATE_LOGIC for device {2} needs to be disabled!.")
- PERRMSGV(MI_REMOVE_DEVICE_1_CONNECTED_ONLY_TO_RAILS_2_3, 3, "Found device {1} connected only to railterminals {2}/{3}. Will be removed")
+ PERRMSGV(MI_REMOVE_DEVICE_1_CONNECTED_ONLY_TO_RAILS_2_3, 3, "Found device {1} connected only to railterminals {2}/{3}. Please consider commenting those out.")
PERRMSGV(MW_DATA_1_NOT_FOUND, 1, "unable to find data {1} in sources collection")
diff --git a/src/lib/netlist/nl_factory.h b/src/lib/netlist/nl_factory.h
index 25c957e5a07..ad26a505453 100644
--- a/src/lib/netlist/nl_factory.h
+++ b/src/lib/netlist/nl_factory.h
@@ -129,6 +129,7 @@ namespace factory {
const pstring &name, std::tuple<Args...>& args, std::index_sequence<Is...>)
{
return plib::make_unique<C>(pool, anetlist, name, std::forward<Args>(std::get<Is>(args))...);
+ //return anetlist.make_pool_object<C>(anetlist, name, std::forward<Args>(std::get<Is>(args))...);
}
dev_uptr make_device(device_arena &pool,
diff --git a/src/lib/netlist/nl_parser.cpp b/src/lib/netlist/nl_parser.cpp
index 7c0ad9e7ff7..791ac073dd1 100644
--- a/src/lib/netlist/nl_parser.cpp
+++ b/src/lib/netlist/nl_parser.cpp
@@ -3,6 +3,7 @@
#include "nl_parser.h"
#include "nl_base.h"
+#include "nl_setup.h"
#include "nl_errstr.h"
#include "nl_factory.h"
@@ -18,42 +19,64 @@ void parser_t::verror(const pstring &msg)
throw nl_exception(plib::pfmt("{1}")(msg));
}
-bool parser_t::parse(const pstring &nlname)
+parser_t::parser_t(nlparse_t &setup)
+ : m_setup(setup)
{
- this->identifier_chars("abcdefghijklmnopqrstuvwvxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890_.-$@")
+ m_tokenizer.identifier_chars("abcdefghijklmnopqrstuvwvxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890_.-$@")
.number_chars(".0123456789", "0123456789eE-.") //FIXME: processing of numbers
.whitespace(pstring("") + ' ' + static_cast<char>(9) + static_cast<char>(10) + static_cast<char>(13))
.comment("/*", "*/", "//");
- m_tok_paren_left = register_token("(");
- m_tok_paren_right = register_token(")");
- m_tok_comma = register_token(",");
-
- m_tok_ALIAS = register_token("ALIAS");
- m_tok_DIPPINS = register_token("DIPPINS");
- m_tok_NET_C = register_token("NET_C");
- m_tok_FRONTIER = register_token("OPTIMIZE_FRONTIER");
- m_tok_PARAM = register_token("PARAM");
- m_tok_DEFPARAM = register_token("DEFPARAM");
- m_tok_HINT = register_token("HINT");
- m_tok_NET_MODEL = register_token("NET_MODEL");
- m_tok_INCLUDE = register_token("INCLUDE");
- m_tok_LOCAL_SOURCE = register_token("LOCAL_SOURCE");
- m_tok_LOCAL_LIB_ENTRY = register_token("LOCAL_LIB_ENTRY");
- m_tok_SUBMODEL = register_token("SUBMODEL");
- m_tok_NETLIST_START = register_token("NETLIST_START");
- m_tok_NETLIST_END = register_token("NETLIST_END");
- m_tok_TRUTHTABLE_START = register_token("TRUTHTABLE_START");
- m_tok_TRUTHTABLE_END = register_token("TRUTHTABLE_END");
- m_tok_TT_HEAD = register_token("TT_HEAD");
- m_tok_TT_LINE = register_token("TT_LINE");
- m_tok_TT_FAMILY = register_token("TT_FAMILY");
-
- register_token("RES_R");
- register_token("RES_K");
- register_token("RES_M");
- register_token("CAP_U");
- register_token("CAP_N");
- register_token("CAP_P");
+ m_tok_paren_left = m_tokenizer.register_token("(");
+ m_tok_paren_right = m_tokenizer.register_token(")");
+ m_tok_comma = m_tokenizer.register_token(",");
+
+ m_tok_static = m_tokenizer.register_token("static");
+ m_tok_ALIAS = m_tokenizer.register_token("ALIAS");
+ m_tok_DIPPINS = m_tokenizer.register_token("DIPPINS");
+ m_tok_NET_C = m_tokenizer.register_token("NET_C");
+ m_tok_FRONTIER = m_tokenizer.register_token("OPTIMIZE_FRONTIER");
+ m_tok_PARAM = m_tokenizer.register_token("PARAM");
+ m_tok_DEFPARAM = m_tokenizer.register_token("DEFPARAM");
+ m_tok_HINT = m_tokenizer.register_token("HINT");
+ m_tok_NET_MODEL = m_tokenizer.register_token("NET_MODEL");
+ m_tok_NET_REGISTER_DEV = m_tokenizer.register_token("NET_REGISTER_DEV");
+ m_tok_INCLUDE = m_tokenizer.register_token("INCLUDE");
+ m_tok_LOCAL_SOURCE = m_tokenizer.register_token("LOCAL_SOURCE");
+ m_tok_LOCAL_LIB_ENTRY = m_tokenizer.register_token("LOCAL_LIB_ENTRY");
+ m_tok_SUBMODEL = m_tokenizer.register_token("SUBMODEL");
+ m_tok_NETLIST_START = m_tokenizer.register_token("NETLIST_START");
+ m_tok_NETLIST_END = m_tokenizer.register_token("NETLIST_END");
+ m_tok_TRUTHTABLE_START = m_tokenizer.register_token("TRUTHTABLE_START");
+ m_tok_TRUTHTABLE_END = m_tokenizer.register_token("TRUTHTABLE_END");
+ m_tok_TT_HEAD = m_tokenizer.register_token("TT_HEAD");
+ m_tok_TT_LINE = m_tokenizer.register_token("TT_LINE");
+ m_tok_TT_FAMILY = m_tokenizer.register_token("TT_FAMILY");
+
+ m_tokenizer.register_token("RES_R");
+ m_tokenizer.register_token("RES_K");
+ m_tokenizer.register_token("RES_M");
+ m_tokenizer.register_token("CAP_U");
+ m_tokenizer.register_token("CAP_N");
+ m_tokenizer.register_token("CAP_P");
+
+}
+
+bool parser_t::parse(plib::psource_t::stream_ptr &&strm, const pstring &nlname)
+{
+ token_store tokstor;
+ parse_tokens(std::move(strm), tokstor);
+ return parse(tokstor, nlname);
+}
+
+void parser_t::parse_tokens(plib::psource_t::stream_ptr &&strm, token_store &tokstor)
+{
+ plib::putf8_reader u8reader(strm.release_stream());
+ m_tokenizer.append_to_store(&u8reader, tokstor);
+}
+
+bool parser_t::parse(token_store &tokstor, const pstring &nlname)
+{
+ set_token_source(&tokstor);
bool in_nl = false;
@@ -91,6 +114,11 @@ bool parser_t::parse(const pstring &nlname)
in_nl = true;
}
+ else if (!in_nl)
+ {
+ if (!token.is(m_tok_static))
+ error(MF_EXPECTED_NETLIST_START_1(token.str()));
+ }
}
}
@@ -136,6 +164,10 @@ void parser_t::parse_netlist(const pstring &nlname)
m_setup.register_lib_entry(get_identifier(), "", plib::source_location("parser: " + nlname, 1));
require_token(m_tok_paren_right);
}
+ else if (token.is(m_tok_NET_REGISTER_DEV))
+ {
+ net_register_dev();
+ }
else if (token.is(m_tok_NETLIST_END))
{
netdev_netlist_end();
@@ -199,7 +231,7 @@ void parser_t::net_truthtable_start(const pstring &nlname)
require_token(m_tok_paren_left);
require_token(m_tok_paren_right);
// FIXME: proper location
- m_setup.truthtable_create(desc, "+" + def_param, plib::source_location(nlname, 1));
+ m_setup.truthtable_create(desc, def_param, plib::source_location(nlname, 1));
return;
}
}
@@ -382,6 +414,17 @@ void parser_t::netdev_hint()
require_token(m_tok_paren_right);
}
+void parser_t::net_register_dev()
+{
+ require_token(m_tok_paren_left);
+ pstring type(get_identifier());
+ require_token(m_tok_comma);
+ pstring name(get_identifier());
+ require_token(m_tok_paren_right);
+
+ m_setup.register_dev(type, name);
+}
+
void parser_t::device(const pstring &dev_type)
{
std::vector<pstring> params;
diff --git a/src/lib/netlist/nl_parser.h b/src/lib/netlist/nl_parser.h
index 4f7bc012d43..e4308786e3a 100644
--- a/src/lib/netlist/nl_parser.h
+++ b/src/lib/netlist/nl_parser.h
@@ -8,22 +8,24 @@
#ifndef NL_PARSER_H_
#define NL_PARSER_H_
-#include "nl_setup.h"
+#include "nltypes.h" // for setup_t
#include "plib/ptokenizer.h"
namespace netlist
{
- class parser_t : public plib::ptokenizer
+ class parser_t : public plib::ptoken_reader
{
public:
- template <typename T>
- parser_t(T &&strm, nlparse_t &setup)
- : plib::ptokenizer(std::forward<T>(strm))
- , m_setup(setup)
- {
- }
+ using token_t = plib::ptokenizer::token_t;
+ using token_type = plib::ptokenizer::token_type;
+ using token_id_t = plib::ptokenizer::token_id_t;
+ using token_store = plib::ptokenizer::token_store;
- bool parse(const pstring &nlname = "");
+ parser_t(nlparse_t &setup);
+
+ bool parse(plib::psource_t::stream_ptr &&strm, const pstring &nlname);
+ bool parse(token_store &tokstor, const pstring &nlname);
+ void parse_tokens(plib::psource_t::stream_ptr &&strm, token_store &tokstor);
protected:
void parse_netlist(const pstring &nlname);
@@ -40,6 +42,7 @@ namespace netlist
void net_submodel();
void net_include();
void net_local_source();
+ void net_register_dev();
void net_truthtable_start(const pstring &nlname);
void verror(const pstring &msg) override;
@@ -48,6 +51,7 @@ namespace netlist
token_id_t m_tok_paren_left;
token_id_t m_tok_paren_right;
token_id_t m_tok_comma;
+ token_id_t m_tok_static;
token_id_t m_tok_ALIAS;
token_id_t m_tok_NET_C;
token_id_t m_tok_DIPPINS;
@@ -56,6 +60,7 @@ namespace netlist
token_id_t m_tok_DEFPARAM;
token_id_t m_tok_HINT;
token_id_t m_tok_NET_MODEL;
+ token_id_t m_tok_NET_REGISTER_DEV;
token_id_t m_tok_NETLIST_START;
token_id_t m_tok_NETLIST_END;
token_id_t m_tok_SUBMODEL;
@@ -68,6 +73,7 @@ namespace netlist
token_id_t m_tok_TT_LINE;
token_id_t m_tok_TT_FAMILY;
+ plib::ptokenizer m_tokenizer;
nlparse_t &m_setup;
};
diff --git a/src/lib/netlist/nl_setup.cpp b/src/lib/netlist/nl_setup.cpp
index e6424649149..aed7a509d5e 100644
--- a/src/lib/netlist/nl_setup.cpp
+++ b/src/lib/netlist/nl_setup.cpp
@@ -16,6 +16,8 @@
#include "solver/nld_solver.h"
+#include <sstream>
+
namespace netlist
{
// ----------------------------------------------------------------------------------------
@@ -110,7 +112,7 @@ namespace netlist
//break;
}
pstring output_name = *ptok;
- log().debug("Link: {1} {2}\n", tp, output_name);
+ log().debug("Link: {1} {2}", tp, output_name);
register_link(name + "." + tp.substr(1), output_name);
++ptok;
@@ -118,7 +120,7 @@ namespace netlist
else if (plib::startsWith(tp, "@"))
{
pstring term = tp.substr(1);
- log().debug("Link: {1} {2}\n", tp, term);
+ log().debug("Link: {1} {2}", tp, term);
register_link(name + "." + term, term);
}
@@ -352,10 +354,26 @@ namespace netlist
bool nlparse_t::parse_stream(plib::psource_t::stream_ptr &&istrm, const pstring &name)
{
- auto y = std::make_unique<plib::ppreprocessor>(m_includes, &m_defines);
- y->process(std::move(istrm));
- return parser_t(std::move(y), *this).parse(name);
- //return parser_t(std::move(plib::ppreprocessor(&m_defines).process(std::move(istrm))), *this).parse(name);
+ auto key = istrm.filename();
+
+ if (m_source_cache.find(key) != m_source_cache.end())
+ {
+ return parser_t(*this).parse(m_source_cache[key], name);
+ }
+ else
+ {
+ //printf("searching %s\n", name.c_str());
+ plib::ppreprocessor y(m_includes, &m_defines);
+ y.process(std::move(istrm), istrm.filename());
+
+ auto abc = std::make_unique<std::stringstream>();
+ plib::copystream(*abc, y);
+
+ parser_t::token_store &st = m_source_cache[key];
+ parser_t parser(*this);
+ parser.parse_tokens(plib::psource_t::stream_ptr(std::move(abc), key), st);
+ return parser.parse(st, name);
+ }
}
void nlparse_t::add_define(const pstring &defstr)
@@ -422,10 +440,10 @@ namespace netlist
plib::psource_t::stream_ptr nlparse_t::get_data_stream(const pstring &name)
{
auto strm = m_sources.get_stream<source_data_t>(name);
- if (strm)
+ if (!strm.empty())
return strm;
log().warning(MW_DATA_1_NOT_FOUND(name));
- return plib::psource_t::stream_ptr(nullptr);
+ return plib::psource_t::stream_ptr();
}
// ----------------------------------------------------------------------------------------
@@ -733,9 +751,8 @@ devices::nld_base_proxy *setup_t::get_a_d_proxy(detail::core_terminal_t &inp)
return iter_proxy->second;
log().debug("connect_terminal_input: connecting proxy\n");
- pstring x = plib::pfmt("proxy_ad_{1}_{2}")(inp.name())(m_proxy_cnt);
- auto new_proxy = incast.logic_family()->create_a_d_proxy(m_nlstate, x, &incast);
- //auto new_proxy = plib::owned_ptr<devices::nld_a_to_d_proxy>::Create(netlist(), x, &incast);
+ auto new_proxy = incast.logic_family()->create_a_d_proxy(m_nlstate,
+ plib::pfmt("proxy_ad_{1}_{2}")(inp.name())(m_proxy_cnt), &incast);
auto *ret(new_proxy.get());
@@ -748,20 +765,25 @@ devices::nld_base_proxy *setup_t::get_a_d_proxy(detail::core_terminal_t &inp)
if (inp.has_net())
{
- for (auto & p : inp.net().core_terms())
+ for (detail::core_terminal_t * p : inp.net().core_terms())
{
- p->clear_net(); // de-link from all nets ...
- if (!connect(ret->proxy_term(), *p))
+ // inp may already belongs to the logic net. Thus skip it here.
+ // It will be removed by the clear further down.
+ if (p != &inp)
{
- log().fatal(MF_CONNECTING_1_TO_2(
- ret->proxy_term().name(), (*p).name()));
- throw nl_exception(MF_CONNECTING_1_TO_2(
- ret->proxy_term().name(), (*p).name()));
-
+ p->clear_net(); // de-link from all nets ...
+ if (!connect(ret->proxy_term(), *p))
+ {
+ log().fatal(MF_CONNECTING_1_TO_2(
+ ret->proxy_term().name(), (*p).name()));
+ throw nl_exception(MF_CONNECTING_1_TO_2(
+ ret->proxy_term().name(), (*p).name()));
+ }
}
}
inp.net().core_terms().clear(); // clear the list
}
+ inp.clear_net();
add_terminal(ret->out().net(), inp);
m_nlstate.register_device(new_proxy->name(), std::move(new_proxy));
return ret;
@@ -1012,7 +1034,9 @@ bool setup_t::connect(detail::core_terminal_t &t1_in, detail::core_terminal_t &t
ret = connect_input_input(t1, t2);
}
else
+ {
ret = false;
+ }
return ret;
}
@@ -1587,9 +1611,12 @@ void setup_t::prepare_to_run()
{
log().info(MI_REMOVE_DEVICE_1_CONNECTED_ONLY_TO_RAILS_2_3(
t->name(), t->N().net().name(), t->P().net().name()));
+ // The following would remove internal devices in e.g. MOSFETs as well.
+#if 0
remove_terminal(t->setup_N().net(), t->setup_N());
remove_terminal(t->setup_P().net(), t->setup_P());
m_nlstate.remove_device(t);
+#endif
}
}
@@ -1650,32 +1677,50 @@ void setup_t::prepare_to_run()
bool source_netlist_t::parse(nlparse_t &setup, const pstring &name)
{
auto strm(stream(name));
- return (strm) ? setup.parse_stream(std::move(strm), name) : false;
+ return (!strm.empty()) ? setup.parse_stream(std::move(strm), name) : false;
}
source_string_t::stream_ptr source_string_t::stream(const pstring &name)
{
plib::unused_var(name);
- source_string_t::stream_ptr ret(std::make_unique<std::istringstream>(m_str));
- ret->imbue(std::locale::classic());
+ source_string_t::stream_ptr ret(std::make_unique<std::istringstream>(m_str), name);
+ ret.stream().imbue(std::locale::classic());
return ret;
}
source_mem_t::stream_ptr source_mem_t::stream(const pstring &name)
{
plib::unused_var(name);
- source_mem_t::stream_ptr ret(std::make_unique<std::istringstream>(m_str, std::ios_base::binary));
- ret->imbue(std::locale::classic());
+ source_mem_t::stream_ptr ret(std::make_unique<std::istringstream>(m_str, std::ios_base::binary), name);
+ ret.stream().imbue(std::locale::classic());
return ret;
}
source_file_t::stream_ptr source_file_t::stream(const pstring &name)
{
plib::unused_var(name);
- auto ret(std::make_unique<plib::ifstream>(plib::filesystem::u8path(m_filename)));
- return (ret->is_open()) ? std::move(ret) : stream_ptr(nullptr);
+ auto f = std::make_unique<plib::ifstream>(plib::filesystem::u8path(m_filename));
+ if (f->is_open())
+ {
+ return stream_ptr(std::move(f), m_filename);
+ }
+ else
+ return stream_ptr();
}
+source_file_t::stream_ptr source_pattern_t::stream(const pstring &name)
+{
+ pstring filename = plib::pfmt(m_pattern)(name);
+ auto f = std::make_unique<plib::ifstream>(plib::filesystem::u8path(filename));
+ if (f->is_open())
+ {
+ return stream_ptr(std::move(f), filename);
+ }
+ else
+ return stream_ptr();
+}
+
+
bool source_proc_t::parse(nlparse_t &setup, const pstring &name)
{
if (name == m_setup_func_name)
@@ -1690,8 +1735,7 @@ bool source_proc_t::parse(nlparse_t &setup, const pstring &name)
source_proc_t::stream_ptr source_proc_t::stream(const pstring &name)
{
plib::unused_var(name);
- stream_ptr p(nullptr);
- return p;
+ return stream_ptr();
}
} // namespace netlist
diff --git a/src/lib/netlist/nl_setup.h b/src/lib/netlist/nl_setup.h
index ac922f0fb32..31fad70a746 100644
--- a/src/lib/netlist/nl_setup.h
+++ b/src/lib/netlist/nl_setup.h
@@ -17,6 +17,7 @@
#include "nl_config.h"
#include "nltypes.h"
+#include "nl_parser.h"
// FIXME: avoid including factory
//#include "nl_factory.h"
@@ -270,6 +271,7 @@ namespace netlist
plib::psource_collection_t<> m_sources;
detail::abstract_t & m_abstract;
+ std::unordered_map<pstring, parser_t::token_store> m_source_cache;
log_type &m_log;
unsigned m_frontier_cnt;
};
diff --git a/src/lib/netlist/nltypes.h b/src/lib/netlist/nltypes.h
index be1de61aa44..1dcb1f943c9 100644
--- a/src/lib/netlist/nltypes.h
+++ b/src/lib/netlist/nltypes.h
@@ -14,11 +14,11 @@
#include "nl_config.h"
+#include "plib/pmempool.h"
+#include "plib/ppmf.h"
#include "plib/pstring.h"
#include "plib/ptime.h"
#include "plib/ptypes.h"
-#include "plib/ppmf.h"
-#include "plib/pmempool.h"
#include <memory>
@@ -45,6 +45,7 @@ namespace netlist
// -----------------------------------------------------------------------------
class logic_output_t;
+ class tristate_output_t;
class logic_input_t;
class analog_net_t;
class logic_net_t;
@@ -294,6 +295,32 @@ namespace netlist
using desc_const_t = std::integral_constant<const T, V>;
};
+ //============================================================
+ // Exceptions
+ //============================================================
+
+ /// \brief Generic netlist exception.
+ /// The exception is used in all events which are considered fatal.
+
+ class nl_exception : public plib::pexception
+ {
+ public:
+ /// \brief Constructor.
+ /// Allows a descriptive text to be passed to the exception
+
+ explicit nl_exception(const pstring &text //!< text to be passed
+ )
+ : plib::pexception(text) { }
+
+ /// \brief Constructor.
+ /// Allows to use \ref plib::pfmt logic to be used in exception
+
+ template<typename... Args>
+ explicit nl_exception(const pstring &fmt //!< format to be used
+ , Args&&... args //!< arguments to be passed
+ )
+ : plib::pexception(plib::pfmt(fmt)(std::forward<Args>(args)...)) { }
+ };
} // namespace netlist
diff --git a/src/lib/netlist/plib/palloc.h b/src/lib/netlist/plib/palloc.h
index 230b05f03c4..74170e08e0f 100644
--- a/src/lib/netlist/plib/palloc.h
+++ b/src/lib/netlist/plib/palloc.h
@@ -10,9 +10,9 @@
#include "pconfig.h"
#include "pgsl.h"
+#include "pgsl.h"
#include "pmath.h" // FIXME: only uses lcm ... move to ptypes.
#include "ptypes.h"
-#include "pgsl.h"
#include <algorithm>
#include <cstddef> // for std::max_align_t (usually long long)
@@ -623,8 +623,8 @@ namespace plib {
struct align_traits : public align_traits_base<T, has_align<T>::value>
{};
- template <typename BASEARENA = aligned_arena, std::size_t PAGESIZE = 1024>
- class paged_arena : public arena_base<paged_arena<BASEARENA, PAGESIZE>, true, true>
+ template <typename BASEARENA = aligned_arena, std::size_t PG_SIZE = 1024>
+ class paged_arena : public arena_base<paged_arena<BASEARENA, PG_SIZE>, true, true>
{
public:
paged_arena() = default;
@@ -636,13 +636,13 @@ namespace plib {
static void *allocate(size_t align, size_t size)
{
plib::unused_var(align);
- //size = ((size + PAGESIZE - 1) / PAGESIZE) * PAGESIZE;
- return arena().allocate(PAGESIZE, size);
+ //size = ((size + PG_SIZE - 1) / PG_SIZE) * PG_SIZE;
+ return arena().allocate(PG_SIZE, size);
}
static void deallocate(void *ptr, size_t size) noexcept
{
- //size = ((size + PAGESIZE - 1) / PAGESIZE) * PAGESIZE;
+ //size = ((size + PG_SIZE - 1) / PG_SIZE) * PG_SIZE;
arena().deallocate(ptr, size);
}
diff --git a/src/lib/netlist/plib/pchrono.h b/src/lib/netlist/plib/pchrono.h
index 03edeeebe6f..6695f238290 100644
--- a/src/lib/netlist/plib/pchrono.h
+++ b/src/lib/netlist/plib/pchrono.h
@@ -219,8 +219,8 @@ namespace plib {
guard_t guard() noexcept { return guard_t(*this); }
// pause must be followed by cont(inue)
- void pause() noexcept { m_time += T::stop(); }
- void cont() noexcept { m_time -= T::start(); }
+ void stop() noexcept { m_time += T::stop(); }
+ void start() noexcept { m_time -= T::start(); }
private:
diff --git a/src/lib/netlist/plib/pconfig.h b/src/lib/netlist/plib/pconfig.h
index 848a813e094..c80f1bbadd6 100644
--- a/src/lib/netlist/plib/pconfig.h
+++ b/src/lib/netlist/plib/pconfig.h
@@ -41,8 +41,12 @@
/// Set this to one if you want to use aligned storage optimizations.
///
#ifndef PUSE_ALIGNED_OPTIMIZATIONS
+#if defined(__EMSCRIPTEN__)
+#define PUSE_ALIGNED_OPTIMIZATIONS (0)
+#else
#define PUSE_ALIGNED_OPTIMIZATIONS (1)
#endif
+#endif
/// \brief Use aligned allocations.
///
diff --git a/src/lib/netlist/plib/pfunction.cpp b/src/lib/netlist/plib/pfunction.cpp
index 1fc2615ed42..526243d4e90 100644
--- a/src/lib/netlist/plib/pfunction.cpp
+++ b/src/lib/netlist/plib/pfunction.cpp
@@ -11,10 +11,10 @@
#include <array>
#include <map>
+#include <map>
#include <stack>
#include <type_traits>
#include <utility>
-#include <map>
namespace plib {
diff --git a/src/lib/netlist/plib/pmulti_threading.h b/src/lib/netlist/plib/pmulti_threading.h
index b359af084e6..9f470054e2d 100644
--- a/src/lib/netlist/plib/pmulti_threading.h
+++ b/src/lib/netlist/plib/pmulti_threading.h
@@ -12,10 +12,10 @@
#include <algorithm>
#include <atomic>
+#include <condition_variable>
#include <mutex>
#include <type_traits>
#include <utility>
-#include <condition_variable>
namespace plib {
diff --git a/src/lib/netlist/plib/ppreprocessor.cpp b/src/lib/netlist/plib/ppreprocessor.cpp
index 05cdb648f34..7e8c363fbd3 100644
--- a/src/lib/netlist/plib/ppreprocessor.cpp
+++ b/src/lib/netlist/plib/ppreprocessor.cpp
@@ -17,6 +17,8 @@ namespace plib {
: std::istream(new readbuffer(this))
, m_sources(sources)
, m_if_flag(0)
+ , m_if_seen(0)
+ , m_elif(0)
, m_if_level(0)
, m_pos(0)
, m_state(PROCESS)
@@ -197,7 +199,14 @@ namespace plib {
CHECKTOK2(||, 15)
else
{
- val = plib::pstonum<decltype(val)>(tok);
+ try
+ {
+ val = plib::pstonum<decltype(val)>(tok);
+ }
+ catch (pexception &e)
+ {
+ sexpr.error(e.text());
+ }
has_val = true;
sexpr.next();
}
@@ -460,45 +469,78 @@ namespace plib {
if (lti[0] == "#if")
{
m_if_level++;
- lt = replace_macros(lt);
- simple_iter<ppreprocessor> t(this, tokenize(lt.substr(3), m_expr_sep, true, true));
- auto val = narrow_cast<int>(prepro_expr(t, 255));
- t.skip_ws();
- if (!t.eod())
- error("found unprocessed content at end of line");
- if (val == 0)
- m_if_flag |= (1 << m_if_level);
+ m_if_seen |= (1 << m_if_level);
+ if (m_if_flag == 0)
+ {
+ lt = replace_macros(lt);
+ simple_iter<ppreprocessor> t(this, tokenize(lt.substr(3), m_expr_sep, true, true));
+ auto val = narrow_cast<int>(prepro_expr(t, 255));
+ t.skip_ws();
+ if (!t.eod())
+ error("found unprocessed content at end of line");
+ if (val == 0)
+ m_if_flag |= (1 << m_if_level);
+ else
+ m_elif |= (1 << m_if_level);
+ }
}
else if (lti[0] == "#ifdef")
{
m_if_level++;
+ m_if_seen |= (1 << m_if_level);
if (get_define(lti[1]) == nullptr)
m_if_flag |= (1 << m_if_level);
+ else
+ m_elif |= (1 << m_if_level);
}
else if (lti[0] == "#ifndef")
{
m_if_level++;
+ m_if_seen |= (1 << m_if_level);
if (get_define(lti[1]) != nullptr)
m_if_flag |= (1 << m_if_level);
+ else
+ m_elif |= (1 << m_if_level);
}
else if (lti[0] == "#else")
{
+ if (!(m_if_seen & (1 << m_if_level)))
+ error("#else without #if");
m_if_flag ^= (1 << m_if_level);
+ m_elif &= ~(1 << m_if_level);
}
else if (lti[0] == "#elif")
{
- m_if_flag ^= (1 << m_if_level);
- lt = replace_macros(lt);
- simple_iter<ppreprocessor> t(this, tokenize(lt.substr(5), m_expr_sep, true, true));
- auto val = narrow_cast<int>(prepro_expr(t, 255));
- t.skip_ws();
- if (!t.eod())
- error("found unprocessed content at end of line");
- if (val == 0)
+ if (!(m_if_seen & (1 << m_if_level)))
+ error("#elif without #if");
+
+ //if ((m_if_flag & (1 << m_if_level)) == 0)
+ // m_if_flag ^= (1 << m_if_level);
+ if (m_elif & (1 << m_if_level))
m_if_flag |= (1 << m_if_level);
+ else
+ m_if_flag &= ~(1 << m_if_level);
+ if (m_if_flag == 0)
+ {
+ //m_if_flag ^= (1 << m_if_level);
+ lt = replace_macros(lt);
+ simple_iter<ppreprocessor> t(this, tokenize(lt.substr(5), m_expr_sep, true, true));
+ auto val = narrow_cast<int>(prepro_expr(t, 255));
+ t.skip_ws();
+ if (!t.eod())
+ error("found unprocessed content at end of line");
+ if (val == 0)
+ m_if_flag |= (1 << m_if_level);
+ else
+ m_elif |= ~(1 << m_if_level);
+ }
}
else if (lti[0] == "#endif")
{
+ if (!(m_if_seen & (1 << m_if_level)))
+ error("#else without #if");
+ m_if_seen &= ~(1 << m_if_level);
+ m_elif &= ~(1 << m_if_level);
m_if_flag &= ~(1 << m_if_level);
m_if_level--;
}
@@ -518,16 +560,16 @@ namespace plib {
// first try local context
auto l(plib::util::buildpath({m_stack.back().m_local_path, arg}));
auto lstrm(m_sources.get_stream(l));
- if (lstrm)
+ if (!lstrm.empty())
{
- m_stack.emplace_back(input_context(std::move(lstrm), plib::util::path(l), l));
+ m_stack.emplace_back(input_context(lstrm.release_stream(), plib::util::path(l), l));
}
else
{
auto strm(m_sources.get_stream(arg));
- if (strm)
+ if (!strm.empty())
{
- m_stack.emplace_back(input_context(std::move(strm), plib::util::path(arg), arg));
+ m_stack.emplace_back(input_context(strm.release_stream(), plib::util::path(arg), arg));
}
else
error("include not found:" + arg);
diff --git a/src/lib/netlist/plib/ppreprocessor.h b/src/lib/netlist/plib/ppreprocessor.h
index 467db358264..4b460d42ec8 100644
--- a/src/lib/netlist/plib/ppreprocessor.h
+++ b/src/lib/netlist/plib/ppreprocessor.h
@@ -68,10 +68,17 @@ namespace plib {
delete rdbuf();
}
+ /// \brief process stream
+ ///
+ /// \param filename a filename or identifier identifying the stream.
+ ///
+ /// FIXME: this is sub-optimal. Refactor input_context into pinput_context
+ /// and pass this to ppreprocessor.
+ ///
template <typename T>
- ppreprocessor & process(T &&istrm)
+ ppreprocessor & process(T &&istrm, const pstring &filename)
{
- m_stack.emplace_back(input_context(std::forward<T>(istrm),"","<stream>"));
+ m_stack.emplace_back(input_context(istrm.release_stream(),plib::util::path(filename), filename));
process_stack();
return *this;
}
@@ -139,7 +146,9 @@ namespace plib {
psource_collection_t<> &m_sources;
string_list m_expr_sep;
- std::uint_least64_t m_if_flag; // 31 if levels
+ std::uint_least64_t m_if_flag; // 63 if levels
+ std::uint_least64_t m_if_seen; // 63 if levels
+ std::uint_least64_t m_elif; // 63 if levels - for #elif
int m_if_level;
struct input_context
diff --git a/src/lib/netlist/plib/pstream.h b/src/lib/netlist/plib/pstream.h
index 21d5531848c..97a4a0eea5f 100644
--- a/src/lib/netlist/plib/pstream.h
+++ b/src/lib/netlist/plib/pstream.h
@@ -68,6 +68,8 @@ public:
putf8_reader(std::unique_ptr<std::istream> &&rhs) noexcept
: m_strm(std::move(rhs))
{
+ // no bad surprises
+ m_strm->imbue(std::locale::classic());
}
bool eof() const { return m_strm->eof(); }
diff --git a/src/lib/netlist/plib/ptests.h b/src/lib/netlist/plib/ptests.h
index 9755d49c240..e0faaf99bbb 100644
--- a/src/lib/netlist/plib/ptests.h
+++ b/src/lib/netlist/plib/ptests.h
@@ -10,11 +10,11 @@
/// google tests compatible (hopefully) test macros. This is work in progress!
///
+#include <exception>
+#include <functional>
+#include <iostream>
#include <string>
#include <vector>
-#include <iostream>
-#include <functional>
-#include <exception>
#if defined(__clang__)
#pragma clang diagnostic ignored "-Wglobal-constructors"
@@ -115,7 +115,7 @@ namespace testing
{
using reg_entry_base::reg_entry_base;
- virtual Test *create() const override { return new T(); }
+ Test *create() const override { return new T(); }
};
template <typename C, typename T1, typename T2>
diff --git a/src/lib/netlist/plib/ptimed_queue.h b/src/lib/netlist/plib/ptimed_queue.h
index 5e62d5b82aa..fe60fadb75f 100644
--- a/src/lib/netlist/plib/ptimed_queue.h
+++ b/src/lib/netlist/plib/ptimed_queue.h
@@ -8,10 +8,10 @@
/// \file ptimed_queue.h
///
+#include "palloc.h" // FIXME: for aligned_vector
#include "pchrono.h"
#include "pmulti_threading.h"
#include "ptypes.h"
-#include "palloc.h" // FIXME: for aligned_vector
#include <algorithm>
#include <mutex>
diff --git a/src/lib/netlist/plib/ptokenizer.cpp b/src/lib/netlist/plib/ptokenizer.cpp
index a0542b61a86..cc3d6538f8d 100644
--- a/src/lib/netlist/plib/ptokenizer.cpp
+++ b/src/lib/netlist/plib/ptokenizer.cpp
@@ -1,9 +1,9 @@
// license:GPL-2.0+
// copyright-holders:Couriersud
-#include "ptokenizer.h"
#include "palloc.h"
#include "pstonum.h"
+#include "ptokenizer.h"
#include "putil.h"
namespace plib {
@@ -21,11 +21,6 @@ namespace plib {
// A simple tokenizer
// ----------------------------------------------------------------------------------------
- pstring ptokenizer::currentline_str() const
- {
- return m_cur_line;
- }
-
void ptokenizer::skipeol()
{
pstring::value_type c = getc();
@@ -52,9 +47,13 @@ namespace plib {
}
if (m_px == m_cur_line.end())
{
- ++m_source_location.back();
- if (m_strm.readline(m_cur_line))
+ //++m_source_location.back();
+ if (m_strm->readline(m_cur_line))
+ {
m_px = m_cur_line.begin();
+ if (*m_px != '#')
+ m_token_queue->push_back(token_t(token_type::SOURCELINE, m_cur_line));
+ }
else
return 0;
return '\n';
@@ -68,23 +67,19 @@ namespace plib {
m_unget = c;
}
- void ptokenizer::require_token(const token_id_t &token_num)
+ void ptoken_reader::require_token(const token_id_t &token_num)
{
require_token(get_token(), token_num);
}
- void ptokenizer::require_token(const token_t &tok, const token_id_t &token_num)
+ void ptoken_reader::require_token(const token_t &tok, const token_id_t &token_num)
{
if (!tok.is(token_num))
{
- pstring val("");
- for (auto &i : m_tokens)
- if (i.second.id() == token_num.id())
- val = i.first;
- error(MF_EXPECTED_TOKEN_1_GOT_2(val, tok.str()));
+ error(MF_EXPECTED_TOKEN_1_GOT_2(token_num.name(), tok.str()));
}
}
- pstring ptokenizer::get_string()
+ pstring ptoken_reader::get_string()
{
token_t tok = get_token();
if (!tok.is_type(token_type::STRING))
@@ -95,7 +90,7 @@ namespace plib {
}
- pstring ptokenizer::get_identifier()
+ pstring ptoken_reader::get_identifier()
{
token_t tok = get_token();
if (!tok.is_type(token_type::IDENTIFIER))
@@ -105,7 +100,7 @@ namespace plib {
return tok.str();
}
- pstring ptokenizer::get_identifier_or_number()
+ pstring ptoken_reader::get_identifier_or_number()
{
token_t tok = get_token();
if (!(tok.is_type(token_type::IDENTIFIER) || tok.is_type(token_type::NUMBER)))
@@ -116,7 +111,7 @@ namespace plib {
}
// FIXME: combine into template
- double ptokenizer::get_number_double()
+ double ptoken_reader::get_number_double()
{
token_t tok = get_token();
if (!tok.is_type(token_type::NUMBER))
@@ -130,7 +125,7 @@ namespace plib {
return ret;
}
- long ptokenizer::get_number_long()
+ long ptoken_reader::get_number_long()
{
token_t tok = get_token();
if (!tok.is_type(token_type::NUMBER))
@@ -144,30 +139,31 @@ namespace plib {
return ret;
}
- ptokenizer::token_t ptokenizer::get_token()
+ ptoken_reader::token_t ptoken_reader::get_token()
{
- token_t ret = get_token_internal();
+ token_t ret = get_token_queue();
while (true)
{
if (ret.is_type(token_type::token_type::ENDOFFILE))
return ret;
- if (m_support_line_markers && ret.is_type(token_type::LINEMARKER))
+ //printf("%s\n", ret.str().c_str());
+ if (ret.is_type(token_type::LINEMARKER))
{
bool benter(false);
bool bexit(false);
pstring file;
unsigned lineno(0);
- ret = get_token_internal();
+ ret = get_token_queue();
if (!ret.is_type(token_type::NUMBER))
error(MF_EXPECTED_LINENUM_GOT_1(ret.str()));
lineno = pstonum<unsigned>(ret.str());
- ret = get_token_internal();
+ ret = get_token_queue();
if (!ret.is_type(token_type::STRING))
error(MF_EXPECTED_FILENAME_GOT_1(ret.str()));
file = ret.str();
- ret = get_token_internal();
+ ret = get_token_queue();
while (ret.is_type(token_type::NUMBER))
{
if (ret.str() == "1")
@@ -175,7 +171,7 @@ namespace plib {
if (ret.str() == "2")
bexit = false;
// FIXME: process flags; actually only 1 (file enter) and 2 (after file exit)
- ret = get_token_internal();
+ ret = get_token_queue();
}
if (bexit) // pop the last location
m_source_location.pop_back();
@@ -183,17 +179,11 @@ namespace plib {
m_source_location.pop_back();
m_source_location.emplace_back(plib::source_location(file, lineno));
}
- else if (ret.is(m_tok_comment_start))
+ else if (ret.is_type(token_type::SOURCELINE))
{
- do {
- ret = get_token_internal();
- } while (ret.is_not(m_tok_comment_end));
- ret = get_token_internal();
- }
- else if (ret.is(m_tok_line_comment))
- {
- skipeol();
- ret = get_token_internal();
+ m_line = ret.str();
+ ++m_source_location.back();
+ ret = get_token_queue();
}
else
{
@@ -202,7 +192,7 @@ namespace plib {
}
}
- ptokenizer::token_t ptokenizer::get_token_internal()
+ ptoken_reader::token_t ptokenizer::get_token_internal()
{
// skip ws
pstring::value_type c = getc();
@@ -287,7 +277,35 @@ namespace plib {
}
}
- void ptokenizer::error(const perrmsg &errs)
+ ptoken_reader::token_t ptokenizer::get_token_comment()
+ {
+ token_t ret = get_token_internal();
+ while (true)
+ {
+ if (ret.is_type(token_type::token_type::ENDOFFILE))
+ return ret;
+
+ if (ret.is(m_tok_comment_start))
+ {
+ do {
+ ret = get_token_internal();
+ } while (ret.is_not(m_tok_comment_end));
+ ret = get_token_internal();
+ }
+ else if (ret.is(m_tok_line_comment))
+ {
+ skipeol();
+ ret = get_token_internal();
+ }
+ else
+ {
+ return ret;
+ }
+ }
+ }
+
+
+ void ptoken_reader::error(const perrmsg &errs)
{
pstring s("");
pstring trail (" from ");
@@ -302,7 +320,7 @@ namespace plib {
s = plib::pfmt("{1}{2}:{3}:0\n{4}")(trail, m_source_location.back().file_name(), m_source_location.back().line(), s);
m_source_location.pop_back();
}
- verror("\n" + s + e + " " + currentline_str() + "\n");
+ verror("\n" + s + e + " " + m_line + "\n");
}
} // namespace plib
diff --git a/src/lib/netlist/plib/ptokenizer.h b/src/lib/netlist/plib/ptokenizer.h
index 5a71990aca7..23dcd2da923 100644
--- a/src/lib/netlist/plib/ptokenizer.h
+++ b/src/lib/netlist/plib/ptokenizer.h
@@ -22,17 +22,13 @@ namespace plib {
class ptokenizer
{
public:
- template <typename T>
- explicit ptokenizer(T &&strm) // NOLINT(misc-forwarding-reference-overload, bugprone-forwarding-reference-overload)
- : m_strm(std::forward<T>(strm))
- , m_cur_line("")
- , m_px(m_cur_line.begin())
- , m_unget(0)
+ explicit ptokenizer() // NOLINT(misc-forwarding-reference-overload, bugprone-forwarding-reference-overload)
+ : m_strm(nullptr)
, m_string('"')
, m_support_line_markers(true) // FIXME
+ , m_token_queue(nullptr)
{
- // add a first entry to the stack
- m_source_location.emplace_back(plib::source_location("Unknown", 0));
+ clear();
}
PCOPYASSIGNMOVE(ptokenizer, delete)
@@ -46,6 +42,7 @@ namespace plib {
STRING,
COMMENT,
LINEMARKER,
+ SOURCELINE,
UNKNOWN,
ENDOFFILE
)
@@ -57,28 +54,33 @@ namespace plib {
static constexpr std::size_t npos = static_cast<std::size_t>(-1);
token_id_t() : m_id(npos) {}
- explicit token_id_t(const std::size_t id) : m_id(id) {}
+ explicit token_id_t(std::size_t id, const pstring &name)
+ : m_id(id)
+ , m_name(name)
+ {}
std::size_t id() const { return m_id; }
+ pstring name() const { return m_name; }
private:
std::size_t m_id;
+ pstring m_name;
};
struct token_t
{
explicit token_t(token_type type)
- : m_type(type), m_token("")
+ : m_type(type), m_id(token_id_t::npos), m_token("")
{
}
token_t(token_type type, const pstring &str)
- : m_type(type), m_token(str)
+ : m_type(type), m_id(token_id_t::npos), m_token(str)
{
}
token_t(const token_id_t &id, const pstring &str)
- : m_type(token_type::TOKEN), m_id(id), m_token(str)
+ : m_type(token_type::TOKEN), m_id(id.id()), m_token(str)
{
}
- bool is(const token_id_t &tok_id) const noexcept { return m_id.id() == tok_id.id(); }
+ bool is(const token_id_t &tok_id) const noexcept { return m_id == tok_id.id(); }
bool is_not(const token_id_t &tok_id) const noexcept { return !is(tok_id); }
bool is_type(const token_type type) const noexcept { return m_type == type; }
@@ -89,28 +91,17 @@ namespace plib {
private:
token_type m_type;
- token_id_t m_id;
+ std::size_t m_id;
pstring m_token;
};
- pstring currentline_str() const;
+ using token_store = std::vector<token_t>;
// tokenizer stuff follows ...
- token_t get_token();
- pstring get_string();
- pstring get_identifier();
- pstring get_identifier_or_number();
-
- double get_number_double();
- long get_number_long();
-
- void require_token(const token_id_t &token_num);
- void require_token(const token_t &tok, const token_id_t &token_num);
-
token_id_t register_token(const pstring &token)
{
- token_id_t ret(m_tokens.size());
+ token_id_t ret(m_tokens.size(), token);
m_tokens.emplace(token, ret);
return ret;
}
@@ -127,22 +118,42 @@ namespace plib {
return *this;
}
+ void append_to_store(putf8_reader *reader, token_store &tokstor)
+ {
+ clear();
+ m_strm = reader;
+ // Process tokens into queue
+ token_t ret(token_type::UNKNOWN);
+ m_token_queue = &tokstor;
+ do {
+ ret = get_token_comment();
+ tokstor.push_back(ret);
+ } while (!ret.is_type(token_type::token_type::ENDOFFILE));
+ m_token_queue = nullptr;
+ }
+
+ private:
+
+ void clear()
+ {
+ m_cur_line = "";
+ m_px = m_cur_line.begin();
+ m_unget = 0;
+ }
+
token_t get_token_internal();
- void error(const perrmsg &errs);
- putf8_reader &stream() { return m_strm; }
- protected:
- virtual void verror(const pstring &msg) = 0;
+ // get internal token with comment processing
+ token_t get_token_comment();
- private:
void skipeol();
pstring::value_type getc();
void ungetc(pstring::value_type c);
- bool eof() const { return m_strm.eof(); }
+ bool eof() const { return m_strm->eof(); }
- putf8_reader m_strm;
+ putf8_reader *m_strm;
pstring m_cur_line;
pstring::const_iterator m_px;
@@ -161,10 +172,71 @@ namespace plib {
token_id_t m_tok_comment_end;
token_id_t m_tok_line_comment;
+ protected:
+ bool m_support_line_markers;
+ token_store *m_token_queue;
+ };
+
+ class ptoken_reader
+ {
+ public:
+
+ using token_t = ptokenizer::token_t;
+ using token_type = ptokenizer::token_type;
+ using token_id_t = ptokenizer::token_id_t;
+ using token_store = ptokenizer::token_store;
+
+ explicit ptoken_reader()
+ : m_idx(0)
+ , m_token_store(nullptr)
+ {
+ // add a first entry to the stack
+ m_source_location.emplace_back(plib::source_location("Unknown", 0));
+ }
+
+ PCOPYASSIGNMOVE(ptoken_reader, delete)
+
+ virtual ~ptoken_reader() = default;
+
+ void set_token_source(const token_store *tokstor)
+ {
+ m_token_store = tokstor;
+ }
+
+ pstring currentline_str() const;
+
+ // tokenizer stuff follows ...
+
+ token_t get_token();
+ pstring get_string();
+ pstring get_identifier();
+ pstring get_identifier_or_number();
+
+ double get_number_double();
+ long get_number_long();
+
+ void require_token(const token_id_t &token_num);
+ void require_token(const token_t &tok, const token_id_t &token_num);
+
+ void error(const perrmsg &errs);
+
+ protected:
+ virtual void verror(const pstring &msg) = 0;
+
+ private:
+ token_t get_token_queue()
+ {
+ if (m_idx < m_token_store->size())
+ return (*m_token_store)[m_idx++];
+ return token_t(token_type::ENDOFFILE);
+ }
+
// source locations, vector used as stack because we need to loop through stack
- bool m_support_line_markers;
std::vector<plib::source_location> m_source_location;
+ pstring m_line;
+ std::size_t m_idx;
+ const token_store * m_token_store;
};
} // namespace plib
diff --git a/src/lib/netlist/plib/ptypes.h b/src/lib/netlist/plib/ptypes.h
index 5efac1fbad5..5c5cb37695a 100644
--- a/src/lib/netlist/plib/ptypes.h
+++ b/src/lib/netlist/plib/ptypes.h
@@ -35,6 +35,10 @@
name(name &&) /*noexcept*/ = def; \
name &operator=(name &&) /*noexcept*/ = def;
+#if defined(EMSCRIPTEN)
+#undef EMSCRIPTEN
+#endif
+
namespace plib
{
//============================================================
diff --git a/src/lib/netlist/plib/putil.h b/src/lib/netlist/plib/putil.h
index 4754730e55e..7cc855e2802 100644
--- a/src/lib/netlist/plib/putil.h
+++ b/src/lib/netlist/plib/putil.h
@@ -154,7 +154,38 @@ namespace plib
{
public:
- using stream_ptr = std::unique_ptr<std::istream>;
+ struct stream_ext
+ {
+ explicit stream_ext() = default;
+
+ stream_ext(std::unique_ptr<std::istream> &&strm, const pstring &filename)
+ : m_strm(std::move(strm))
+ , m_filename(filename)
+ {
+ }
+ stream_ext(const stream_ext &) = delete;
+ stream_ext &operator=(const stream_ext &) = delete;
+ stream_ext(stream_ext &&rhs) /*noexcept*/
+ {
+ m_strm = std::move(rhs.m_strm);
+ m_filename = rhs.m_filename;
+ }
+ stream_ext &operator=(stream_ext &&) /*noexcept*/ = delete;
+
+ std::istream &stream() noexcept { return *m_strm; }
+ pstring filename() { return m_filename; }
+
+ bool empty() { return m_strm == nullptr; }
+
+ // FIXME: workaround input context should accept stream_ptr
+
+ std::unique_ptr<std::istream> release_stream() { return std::move(m_strm); }
+ private:
+ std::unique_ptr<std::istream> m_strm;
+ pstring m_filename;
+ };
+
+ using stream_ptr = stream_ext; //FIXME: rename to stream_type
psource_t() noexcept = default;
@@ -184,9 +215,9 @@ namespace plib
typename psource_t::stream_ptr stream(const pstring &name) override
{
if (name == m_name)
- return std::make_unique<std::stringstream>(m_str);
+ return stream_ptr(std::make_unique<std::stringstream>(m_str), name);
- return psource_t::stream_ptr(nullptr);
+ return psource_t::stream_ptr();
}
private:
pstring m_name;
@@ -223,11 +254,11 @@ namespace plib
if (source)
{
auto strm = source->stream(name);
- if (strm)
+ if (!strm.empty())
return strm;
}
}
- return typename S::stream_ptr(nullptr);
+ return typename S::stream_ptr();
}
template <typename S, typename F>
diff --git a/src/lib/netlist/prg/nltool.cpp b/src/lib/netlist/prg/nltool.cpp
index eeeabc772c2..f8bedd1b993 100644
--- a/src/lib/netlist/prg/nltool.cpp
+++ b/src/lib/netlist/prg/nltool.cpp
@@ -216,11 +216,11 @@ public:
stream_ptr stream(const pstring &file) override
{
pstring name = m_folder + "/" + file;
- stream_ptr strm(std::make_unique<plib::ifstream>(plib::filesystem::u8path(name)));
- if (strm->fail())
- return stream_ptr(nullptr);
+ stream_ptr strm(std::make_unique<plib::ifstream>(plib::filesystem::u8path(name)), plib::filesystem::u8path(name));
+ if (strm.stream().fail())
+ return stream_ptr();
- strm->imbue(std::locale::classic());
+ strm.stream().imbue(std::locale::classic());
return strm;
}
@@ -459,32 +459,28 @@ void tool_app_t::run()
if (!plib::util::exists(opt_files()[0]))
throw netlist::nl_exception("nltool: file doesn't exists: {}", opt_files()[0]);
- netlist_tool_t nt(*this, "netlist", opt_boostlib());
-
- {
- auto t_guard(t.guard());
- //plib::perftime_t<plib::exact_ticks> t;
+ t.start();
- nt.exec().enable_stats(opt_stats());
+ netlist_tool_t nt(*this, "netlist", opt_boostlib());
- if (!opt_verb())
- nt.log().verbose.set_enabled(false);
- if (opt_quiet())
- nt.log().info.set_enabled(false);
+ nt.exec().enable_stats(opt_stats());
- nt.read_netlist(opt_files()[0], opt_name(),
- opt_logs(),
- m_defines, opt_rfolders(), opt_includes());
-
- // Inputs must be read before reset -> will clear setup and parser
- inps = read_input(nt.setup(), opt_inp());
- nt.free_setup_resources();
- nt.exec().reset();
+ if (!opt_verb())
+ nt.log().verbose.set_enabled(false);
+ if (opt_quiet())
+ nt.log().info.set_enabled(false);
- ttr = netlist::netlist_time_ext::from_fp(opt_ttr());
- }
+ nt.read_netlist(opt_files()[0], opt_name(),
+ opt_logs(),
+ m_defines, opt_rfolders(), opt_includes());
+ // Inputs must be read before reset -> will clear setup and parser
+ inps = read_input(nt.setup(), opt_inp());
+ nt.free_setup_resources();
+ nt.exec().reset();
+ ttr = netlist::netlist_time_ext::from_fp(opt_ttr());
+ t.stop();
pout("startup time ==> {1:5.3f}\n", t.as_seconds<netlist::nl_fptype>() );
// FIXME: error handling
@@ -1034,15 +1030,19 @@ void tool_app_t::create_docheader()
poutprefix("///", "");
poutprefix("///", " @snippet devsyn.dox.h {} csynopsis", d.id);
poutprefix("///", "");
-#if 1
+
poutprefix("///", " @section {}_2 Parameters", d.id);
poutprefix("///", "");
- poutprefix("///", " <table>");
- poutprefix("///", " <tr><th>Name</th><th>Description</th></tr>");
- for (auto &e : d.params)
- poutprefix("///", " <tr><td>{1}</td><td>{2}</td></tr>", e.first, e.second);
- poutprefix("///", " </table>");
-#endif
+ if (!d.params.empty())
+ {
+ poutprefix("///", " <table>");
+ poutprefix("///", " <tr><th>Name</th><th>Description</th></tr>");
+ for (auto &e : d.params)
+ poutprefix("///", " <tr><td>{1}</td><td>{2}</td></tr>", e.first, e.second);
+ poutprefix("///", " </table>");
+ }
+ else
+ poutprefix("///", " This device has no parameters.");
poutprefix("///", "");
poutprefix("///", " @section {}_3 Connection Diagram", d.id);
poutprefix("///", "");
diff --git a/src/lib/netlist/solver/nld_matrix_solver.cpp b/src/lib/netlist/solver/nld_matrix_solver.cpp
index b518e92918d..4076de4bd12 100644
--- a/src/lib/netlist/solver/nld_matrix_solver.cpp
+++ b/src/lib/netlist/solver/nld_matrix_solver.cpp
@@ -2,9 +2,9 @@
// copyright-holders:Couriersud
#include "nld_solver.h"
-#include "nld_matrix_solver.h"
#include "core/setup.h"
#include "nl_setup.h"
+#include "nld_matrix_solver.h"
#include "plib/putil.h"
namespace netlist
diff --git a/src/lib/netlist/solver/nld_matrix_solver.h b/src/lib/netlist/solver/nld_matrix_solver.h
index 3d1a025d289..a5bda6a070e 100644
--- a/src/lib/netlist/solver/nld_matrix_solver.h
+++ b/src/lib/netlist/solver/nld_matrix_solver.h
@@ -80,7 +80,7 @@ namespace solver
constexpr nl_fptype m_gmin() { return nlconst::magic(1e-9); }
constexpr bool m_pivot() { return false; }
constexpr nl_fptype m_nr_recalc_delay(){ return netlist_time::quantum().as_fp<nl_fptype>(); }
- constexpr std::size_t m_parallel() { return 0; }
+ constexpr int m_parallel() { return 0; }
constexpr nl_fptype m_min_ts_ts() { return nlconst::magic(1e-9); }
// automatic time step
diff --git a/src/lib/netlist/solver/nld_matrix_solver_ext.h b/src/lib/netlist/solver/nld_matrix_solver_ext.h
index d308f1cf7c1..8938d7c25e4 100644
--- a/src/lib/netlist/solver/nld_matrix_solver_ext.h
+++ b/src/lib/netlist/solver/nld_matrix_solver_ext.h
@@ -171,7 +171,7 @@ namespace solver
netlist_time compute_next_timestep(fptype cur_ts, fptype min_ts, fptype max_ts) override
{
- fptype new_solver_timestep(max_ts);
+ fptype new_solver_timestep_sq(max_ts * max_ts);
for (std::size_t k = 0; k < size(); k++)
{
@@ -185,21 +185,21 @@ namespace solver
const fptype hn = cur_ts;
fptype DD2 = (DD_n / hn - m_DD_n_m_1[k] / m_h_n_m_1[k]) / (hn + m_h_n_m_1[k]);
- fptype new_net_timestep(0);
m_h_n_m_1[k] = hn;
m_DD_n_m_1[k] = DD_n;
if (plib::abs(DD2) > fp_constants<fptype>::TIMESTEP_MINDIV()) // avoid div-by-zero
- new_net_timestep = plib::sqrt(m_params.m_dynamic_lte / plib::abs(nlconst::half()*DD2));
- else
- new_net_timestep = max_ts;
-
- new_solver_timestep = std::min(new_net_timestep, new_solver_timestep);
+ {
+ // save the sqrt for the end
+ const fptype new_net_timestep_sq = m_params.m_dynamic_lte / plib::abs(nlconst::half()*DD2);
+ new_solver_timestep_sq = std::min(new_net_timestep_sq, new_solver_timestep_sq);
+ }
}
- new_solver_timestep = std::max(new_solver_timestep, min_ts);
+
+ new_solver_timestep_sq = std::max(plib::sqrt(new_solver_timestep_sq), min_ts);
// FIXME: Factor 2 below is important. Without, we get timing issues. This must be a bug elsewhere.
- return std::max(netlist_time::from_fp(new_solver_timestep), netlist_time::quantum() * 2);
+ return std::max(netlist_time::from_fp(new_solver_timestep_sq), netlist_time::quantum() * 2);
}
template <typename M>
diff --git a/src/lib/netlist/solver/nld_solver.cpp b/src/lib/netlist/solver/nld_solver.cpp
index f429dc66843..53f501ecbd6 100644
--- a/src/lib/netlist/solver/nld_solver.cpp
+++ b/src/lib/netlist/solver/nld_solver.cpp
@@ -81,14 +81,14 @@ namespace devices
}
else
{
- stats()->m_stat_total_time.pause();
+ stats()->m_stat_total_time.stop();
for (std::size_t i = 0; i < p; i++)
{
tmp[i]->stats()->m_stat_call_count.inc();
auto g(tmp[i]->stats()->m_stat_total_time.guard());
nt[i] = tmp[i]->solve(now, "no-parallel");
}
- stats()->m_stat_total_time.cont();
+ stats()->m_stat_total_time.start();
}
for (std::size_t i = 0; i < p; i++)
diff --git a/src/lib/netlist/tests/test_pfunction.cpp b/src/lib/netlist/tests/test_pfunction.cpp
index cb0cad8e188..60e6753b7ac 100644
--- a/src/lib/netlist/tests/test_pfunction.cpp
+++ b/src/lib/netlist/tests/test_pfunction.cpp
@@ -9,8 +9,8 @@
#include "plib/ptests.h"
-#include "plib/pfunction.h"
#include "plib/pexception.h"
+#include "plib/pfunction.h"
#define PFUNCEXPECT(formula, val) \
PEXPECT_EQ(val, plib::pfunction<double>(formula)())
diff --git a/src/lib/netlist/tools/nl_convert.cpp b/src/lib/netlist/tools/nl_convert.cpp
index 607dfa680bd..013de026df5 100644
--- a/src/lib/netlist/tools/nl_convert.cpp
+++ b/src/lib/netlist/tools/nl_convert.cpp
@@ -731,8 +731,8 @@ void nl_convert_spice_t::process_line(const pstring &line)
// Eagle converter
// -------------------------------------------------
-nl_convert_eagle_t::tokenizer::tokenizer(nl_convert_eagle_t &convert, plib::putf8_reader &&strm)
- : plib::ptokenizer(std::move(strm))
+nl_convert_eagle_t::tokenizer::tokenizer(nl_convert_eagle_t &convert)
+ : plib::ptokenizer()
, m_convert(convert)
{
this->identifier_chars("abcdefghijklmnopqrstuvwvxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890_.-")
@@ -759,8 +759,13 @@ void nl_convert_eagle_t::tokenizer::verror(const pstring &msg)
void nl_convert_eagle_t::convert(const pstring &contents)
{
- tokenizer tok(*this, plib::putf8_reader(std::make_unique<std::istringstream>(contents)));
- tok.stream().stream().imbue(std::locale::classic());
+ tokenizer tok(*this);
+
+ tokenizer::token_store tokstor;
+ plib::putf8_reader u8reader(std::make_unique<std::istringstream>(contents));
+
+ tok.append_to_store(&u8reader, tokstor);
+ tok.set_token_source(&tokstor);
out("NETLIST_START(dummy)\n");
add_term("GND", "GND");
@@ -869,8 +874,8 @@ void nl_convert_eagle_t::convert(const pstring &contents)
// RINF converter
// -------------------------------------------------
-nl_convert_rinf_t::tokenizer::tokenizer(nl_convert_rinf_t &convert, plib::putf8_reader &&strm)
- : plib::ptokenizer(std::move(strm))
+nl_convert_rinf_t::tokenizer::tokenizer(nl_convert_rinf_t &convert)
+ : plib::ptokenizer()
, m_convert(convert)
{
this->identifier_chars(".abcdefghijklmnopqrstuvwvxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890_-")
@@ -906,8 +911,14 @@ void nl_convert_rinf_t::tokenizer::verror(const pstring &msg)
void nl_convert_rinf_t::convert(const pstring &contents)
{
- tokenizer tok(*this, plib::putf8_reader(std::make_unique<std::istringstream>(contents)));
- tok.stream().stream().imbue(std::locale::classic());
+ tokenizer tok(*this);
+
+ tokenizer::token_store tokstor;
+ plib::putf8_reader u8reader(std::make_unique<std::istringstream>(contents));
+
+ tok.append_to_store(&u8reader, tokstor);
+ tok.set_token_source(&tokstor);
+
auto lm = read_lib_map(s_lib_map);
out("NETLIST_START(dummy)\n");
@@ -1009,7 +1020,7 @@ void nl_convert_rinf_t::convert(const pstring &contents)
if (token.is(tok.m_tok_TER))
{
token = tok.get_token();
- while (token.is_type(plib::ptokenizer::token_type::IDENTIFIER))
+ while (token.is_type(plib::ptoken_reader::token_type::IDENTIFIER))
{
pin = tok.get_identifier_or_number();
add_term(net, token.str() + "." + pin);
diff --git a/src/lib/netlist/tools/nl_convert.h b/src/lib/netlist/tools/nl_convert.h
index 185216b3a09..31be680c11b 100755
--- a/src/lib/netlist/tools/nl_convert.h
+++ b/src/lib/netlist/tools/nl_convert.h
@@ -10,11 +10,12 @@
#include "plib/palloc.h"
#include "plib/pstring.h"
-#include "plib/ptokenizer.h"
#include "plib/ptypes.h"
#include <memory>
+#include "../plib/ptokenizer.h"
+
// -------------------------------------------------
// convert - convert a spice netlist
// -------------------------------------------------
@@ -212,10 +213,15 @@ public:
nl_convert_eagle_t() = default;
- class tokenizer : public plib::ptokenizer
+ class tokenizer : public plib::ptokenizer, public plib::ptoken_reader
{
public:
- tokenizer(nl_convert_eagle_t &convert, plib::putf8_reader &&strm);
+ using token_t = ptokenizer::token_t;
+ using token_type = ptokenizer::token_type;
+ using token_id_t = ptokenizer::token_id_t;
+ using token_store = ptokenizer::token_store;
+
+ tokenizer(nl_convert_eagle_t &convert);
token_id_t m_tok_ADD; // NOLINT
token_id_t m_tok_VALUE; // NOLINT
@@ -244,10 +250,14 @@ public:
nl_convert_rinf_t() = default;
- class tokenizer : public plib::ptokenizer
+ class tokenizer : public plib::ptokenizer, public plib::ptoken_reader
{
public:
- tokenizer(nl_convert_rinf_t &convert, plib::putf8_reader &&strm);
+ using token_t = ptokenizer::token_t;
+ using token_type = ptokenizer::token_type;
+ using token_id_t = ptokenizer::token_id_t;
+ using token_store = ptokenizer::token_store;
+ tokenizer(nl_convert_rinf_t &convert);
token_id_t m_tok_HEA; // NOLINT
token_id_t m_tok_APP; // NOLINT
diff --git a/src/mame/audio/nl_280zzzap.cpp b/src/mame/audio/nl_280zzzap.cpp
index 4d547b5df03..87b07828f34 100644
--- a/src/mame/audio/nl_280zzzap.cpp
+++ b/src/mame/audio/nl_280zzzap.cpp
@@ -89,11 +89,13 @@ static NETLIST_START(mc3340)
// amplify properly, generating only a very weak output signal.
// The 1990s schematics also omit a couple of diodes which are present
- // in the 1970s schematics. One of these omitted diodes noticeably
- // raises the minimum control voltage at which signal attenuation
- // starts; that diode has been included here, to get the netlist's
- // profile of attenuation vs. control voltage to better match
- // Motorola's charts for the device.
+ // in the 1970s schematics. Both of these diodes have been included
+ // here. One raises the minimum control voltage at which signal
+ // attenuation starts, so it makes the netlist's profile of
+ // attenuation vs. control voltage better match Motorola's charts for
+ // the device. The other affects the level of the input "midpoint",
+ // and including it makes the engine sound closer to that on real
+ // 280-ZZZAP machines.
// The Motorola schematics do not label components, so I've created my
// own labeling scheme based on numbering components on the schematics
@@ -134,9 +136,8 @@ static NETLIST_START(mc3340)
RES(R7_5K1, RES_K(5.1))
RES(R8_20K, RES_K(20))
- // 1970s Motorola schematics have another diode just above what I call
- // "R9_510"; this diode doesn't seem to affect normal operation much,
- // so I've left it out.
+ DIODE(D2_MC3340, "D(IS=1e-15 N=1)")
+
RES(R9_510, RES_R(510))
QBJT_EB(Q3, "NPN1")
@@ -171,7 +172,7 @@ static NETLIST_START(mc3340)
RES(R17_5K1, RES_K(5.1))
- DIODE(D2_MC3340, "D(IS=1e-15 N=1)")
+ DIODE(D3_MC3340, "D(IS=1e-15 N=1)")
RES(R18_510, RES_R(510))
@@ -195,9 +196,11 @@ static NETLIST_START(mc3340)
ALIAS(MC3340_INPUT, Q5.B)
NET_C(MC3340_INPUT, R8_20K.1)
- NET_C(R7_5K1.2, R8_20K.2, R9_510.1)
- // (This is approximately where the other omitted diode, which I've
- // left out, would go.)
+ // Location of second diode present on 1970s schematics but omitted on
+ // 1990s ones. Including it is critical to making the tone of the
+ // output engine sound match that of real 280-ZZZAP machines.
+ NET_C(R7_5K1.2, R8_20K.2, D2_MC3340.A)
+ NET_C(D2_MC3340.K, R9_510.1)
NET_C(R9_510.2, GND)
NET_C(Q4.E, Q6.E, Q5.C)
@@ -226,8 +229,8 @@ static NETLIST_START(mc3340)
NET_C(R15_5K1.2, GND)
ALIAS(MC3340_OUTPUT, R16_200.2)
- NET_C(R17_5K1.2, D2_MC3340.A, Q8.B)
- NET_C(D2_MC3340.K, R18_510.1)
+ NET_C(R17_5K1.2, D3_MC3340.A, Q8.B)
+ NET_C(D3_MC3340.K, R18_510.1)
NET_C(R18_510.2, GND)
NETLIST_END()
diff --git a/src/mame/audio/nl_mario.cpp b/src/mame/audio/nl_mario.cpp
index 5b427e48314..a009988fff5 100644
--- a/src/mame/audio/nl_mario.cpp
+++ b/src/mame/audio/nl_mario.cpp
@@ -53,14 +53,16 @@ static NETLIST_START(nl_mario_snd0)
SN74LS629(1J_A, CAP_N(3.9))
NET_C(1J_A.RNG, V5)
NET_C(1J_A.ENQ, ttllow)
- NET_C(GND, 1J_A.GND)
+ NET_C(GND, 1J_A.OSCGND)
+ NET_C(VCC, 1J_A.OSCVCC)
// #define MR_C17 CAP_N(22) /* verified */
SN74LS629(2J_A, CAP_N(22))
NET_C(2J_A.RNG, V5)
NET_C(2J_A.ENQ, ttllow)
- NET_C(GND, 2J_A.GND)
+ NET_C(GND, 2J_A.OSCGND)
+ NET_C(VCC, 2J_A.OSCVCC)
TTL_7486_XOR(1K_A, 1J_A.Y, 2J_A.Y)
TTL_7408_AND(2K_A, 2H_A.Q, 1K_A)
@@ -99,12 +101,14 @@ static NETLIST_START(nl_mario_snd1)
SN74LS629(1J_B, CAP_N(39)) /* C5 */
NET_C(1J_B.RNG, V5)
NET_C(1J_B.ENQ, ttllow)
- NET_C(GND, 1J_B.GND)
+ NET_C(GND, 1J_B.OSCGND)
+ NET_C(VCC, 1J_B.OSCVCC)
SN74LS629(2J_B, CAP_N(6.8)) /* C16 */
NET_C(2J_B.RNG, V5)
NET_C(2J_B.ENQ, ttllow)
- NET_C(GND, 2J_B.GND)
+ NET_C(GND, 2J_B.OSCGND)
+ NET_C(VCC, 2J_B.OSCVCC)
TTL_7486_XOR(1K_B, 1J_B.Y, 2J_B.Y)
TTL_7408_AND(2K_B, 2H_B.Q, 1K_B)
@@ -139,7 +143,8 @@ static NETLIST_START(nl_mario_snd7)
SN74LS629(4K_A, CAP_U(0.022))
NET_C(4K_A.RNG, V5)
NET_C(4K_A.ENQ, ttllow)
- NET_C(GND, 4K_A.GND)
+ NET_C(GND, 4K_A.OSCGND)
+ NET_C(VCC, 4K_A.OSCVCC)
NET_C(R65.1, 4J_A.Q)
NET_C(R65.2, 4K_A.FC, C44.1)
NET_C(C44.2, GND)
@@ -153,7 +158,8 @@ static NETLIST_START(nl_mario_snd7)
SN74LS629(4K_B, CAP_U(0.0047))
NET_C(4K_B.RNG, V5)
NET_C(4K_B.ENQ, ttllow)
- NET_C(GND, 4K_B.GND)
+ NET_C(GND, 4K_B.OSCGND)
+ NET_C(VCC, 4K_B.OSCVCC)
NET_C(R64.1, 4J_B.Q)
NET_C(R64.2, 4K_B.FC, C43.1)
NET_C(C43.2, GND)
diff --git a/src/mame/audio/nl_starcrus.cpp b/src/mame/audio/nl_starcrus.cpp
new file mode 100644
index 00000000000..27624caf999
--- /dev/null
+++ b/src/mame/audio/nl_starcrus.cpp
@@ -0,0 +1,326 @@
+// license:BSD-3-Clause
+// copyright-holders:Ryan Holtz
+
+//
+// Netlist for Star Cruiser
+//
+// Derived from the schematics in the Star Cruiser manual.
+//
+// Known problems/issues:
+//
+// * Uses HLE noise due to abusing a 2N4124 in breakdown as a noise source.
+//
+
+#include "netlist/devices/net_lib.h"
+#include "nl_starcrus.h"
+
+//
+// Main netlist
+//
+
+NETLIST_START(starcrus)
+
+ SOLVER(Solver, 48000)
+ ANALOG_INPUT(V12, 12)
+ ANALOG_INPUT(V5, 5)
+ ANALOG_INPUT(VM5, -5)
+ ALIAS(VCC, V5)
+
+ TTL_INPUT(EXPLODE_1, 1) // active low
+ TTL_INPUT(EXPLODE_2, 1) // active low
+ TTL_INPUT(LAUNCH_1, 1) // active low
+ TTL_INPUT(LAUNCH_2, 1) // active low
+ TTL_INPUT(ENGINE_1, 1) // active low
+ TTL_INPUT(ENGINE_2, 1) // active low
+
+ NET_C(GND, EXPLODE_1.GND, EXPLODE_2.GND, LAUNCH_1.GND, LAUNCH_2.GND, ENGINE_1.GND, ENGINE_2.GND)
+ NET_C(V5, EXPLODE_1.VCC, EXPLODE_2.VCC, LAUNCH_1.VCC, LAUNCH_2.VCC, ENGINE_1.VCC, ENGINE_2.VCC)
+
+ RES(R22, 470)
+ POT(R23, RES_K(2.5))
+ RES(R24, RES_K(10))
+ RES(R25, RES_K(15))
+ RES(R26, RES_K(2.2))
+ RES(R28, RES_K(100))
+ RES(R29, RES_K(220))
+ RES(R30, RES_K(220))
+ RES(R31, RES_K(470))
+ RES(R32, RES_K(100))
+ RES(R33, RES_K(2.2))
+ RES(R34, RES_K(2.2))
+ RES(R35, RES_K(2.2))
+ RES(R36, RES_K(2.2))
+ RES(R37, 220)
+ RES(R38, RES_K(10))
+ RES(R39, RES_K(10))
+ RES(R40, RES_K(56))
+ RES(R41, RES_K(100))
+ RES(R42, RES_K(1))
+ RES(R43, RES_K(100))
+ RES(R44, RES_K(2.2))
+ RES(R45, RES_K(2.2))
+ RES(R46, RES_K(10))
+ RES(R47, RES_K(3))
+ RES(R48, RES_K(10))
+ RES(R49, 220)
+ RES(R50, RES_K(150))
+ RES(R51, RES_K(10))
+ RES(R52, RES_K(10))
+ RES(R53, RES_K(2.2))
+ RES(R54, RES_K(10))
+ RES(R55, 220)
+ RES(R56, RES_K(2.2))
+ RES(R57, RES_K(2.2))
+ RES(R58, RES_K(2.2))
+ RES(R59, RES_K(10))
+ RES(R60, RES_K(3))
+ RES(R61, RES_K(10))
+ RES(R62, 220)
+ RES(R63, RES_K(150))
+ RES(R64, RES_K(10))
+ RES(R65, RES_K(10))
+ RES(R66, RES_K(2.2))
+ RES(R67, RES_K(10))
+ RES(R68, 220)
+ RES(R69, RES_K(2.2))
+ RES(R70, RES_K(47))
+ RES(R71, RES_K(100))
+ RES(R72, RES_K(6.8))
+ RES(R73, RES_K(6.8))
+ RES(R74, RES_K(3.3))
+ POT(R75, RES_K(50))
+ RES(R76, RES_K(22))
+ RES(R77, 470)
+
+ CAP(C12, CAP_U(0.1))
+ //CAP(C13, CAP_U(3.3))
+ CAP(C14, CAP_U(0.1))
+ CAP(C16, CAP_U(1.0))
+ CAP(C17, CAP_U(0.47))
+ CAP(C18, CAP_U(39))
+ CAP(C19, CAP_U(4.7))
+ CAP(C20, CAP_U(22))
+ CAP(C21, CAP_U(0.15))
+ CAP(C22, CAP_U(0.047))
+ CAP(C23, CAP_U(1.0))
+ CAP(C24, CAP_U(22))
+ CAP(C25, CAP_U(0.15))
+ CAP(C26, CAP_U(0.047))
+ CAP(C27, CAP_U(1.0))
+ CAP(C28, CAP_P(470))
+ CAP(C29, CAP_U(4.7))
+ CAP(C30, CAP_U(4.7))
+ CAP(C31, CAP_U(4.7))
+ CAP(C32, CAP_U(0.1))
+
+ QBJT_EB(Q6, "2N4124")
+ //QBJT_EB(Q7, "2N4124")
+ QBJT_EB(Q8, "2N4124")
+ QBJT_EB(Q9, "2N4124")
+ QBJT_EB(Q10, "2N4126")
+ QBJT_EB(Q11, "2N4124")
+ QBJT_EB(Q12, "2N4124")
+ QBJT_EB(Q13, "2N4124")
+ QBJT_EB(Q14, "2N4124")
+ QBJT_EB(Q15, "2N4126")
+ QBJT_EB(Q16, "2N4124")
+ QBJT_EB(Q17, "2N4124")
+ QBJT_EB(Q18, "2N4124")
+ QBJT_EB(Q19, "2N4126")
+ QBJT_EB(Q20, "2N4124")
+ QBJT_EB(Q21, "2N4124")
+
+ UA741_DIP8(U1)
+ UA741_DIP8(U2)
+ UA741_DIP8(U5)
+
+ NE566_DIP(U3)
+ NE566_DIP(U4)
+
+ DIODE(CR29, "1N4154")
+ DIODE(CR30, "1N4154")
+ DIODE(CR31, "1N4154")
+ DIODE(CR32, "1N4154")
+
+ TTL_7408_DIP(H6)
+ NET_C(H6.7, GND)
+ NET_C(H6.14, V5)
+ NET_C(ENGINE_1, H6.9)
+ NET_C(ENGINE_2, H6.10)
+ NET_C(EXPLODE_1, H6.4)
+ NET_C(EXPLODE_2, H6.5)
+ NET_C(LAUNCH_1, H6.1, H6.2)
+ NET_C(LAUNCH_2, H6.12, H6.13)
+
+ TTL_7404_GATE(F8)
+ NET_C(F8.GND, GND)
+ NET_C(F8.VCC, V5)
+ NET_C(H6.6, F8.A)
+
+ // HLE Noise Gen
+ CLOCK(NOISE_CLOCK, 10000)
+ NET_C(NOISE_CLOCK.GND, GND)
+ NET_C(NOISE_CLOCK.VCC, V5)
+
+ SYS_NOISE_MT_N(NOISE, 0.05)
+ NET_C(NOISE.I, NOISE_CLOCK.Q)
+ NET_C(NOISE.1, R24.2)
+ NET_C(NOISE.2, Q6.B)
+
+ // Engine Sound
+ NET_C(H6.8, R26.1)
+ NET_C(R26.2, Q8.B)
+ NET_C(Q8.E, GND)
+ NET_C(Q8.C, R25.1, R70.1)
+ NET_C(R25.2, C14.1)
+ NET_C(C14.2, R23.2, C12.1)
+ NET_C(R23.1, R22.1)
+ NET_C(R22.2, V12)
+ NET_C(R23.3, R24.1, Q6.C)
+ //NET_C(R24.2, Q7.E, C13.1)
+ //NET_C(C13.2, GND)
+ //NET_C(Q7.B, Q7.C, Q6.B)
+ NET_C(Q6.E, GND)
+ NET_C(C12.2, U2.3, R28.1)
+ NET_C(R28.2, GND)
+ NET_C(U2.7, V5)
+ NET_C(U2.4, VM5)
+ NET_C(U2.2, R29.1)
+ NET_C(R29.2, C16.1, R30.1)
+ NET_C(C16.2, GND)
+ NET_C(R30.2, U2.6, R31.1)
+ NET_C(R31.2, C17.1, Q12.C, R32.1, U1.3)
+ NET_C(C17.2, GND)
+ NET_C(R32.2, GND)
+ NET_C(U1.7, V5)
+ NET_C(U1.4, VM5)
+ NET_C(U1.2, R43.1, R42.1)
+ NET_C(R43.2, U1.6, R71.1)
+ NET_C(R42.2, C19.1)
+ NET_C(C19.2, Q13.C)
+ NET_C(Q13.E, GND)
+ NET_C(Q13.B, R41.1, R40.1)
+ NET_C(R41.2, GND)
+ NET_C(R40.2, C18.1, R38.1, R37.1)
+ NET_C(C18.2, GND)
+ NET_C(R38.2, Q11.B)
+ NET_C(Q11.E, GND)
+ NET_C(Q12.E, GND)
+ NET_C(Q11.C, R39.1, Q12.B)
+ NET_C(R39.2, V5)
+ NET_C(R37.2, Q10.C)
+ NET_C(Q10.E, R35.1, V5)
+ NET_C(R35.2, Q10.B, R36.1)
+ NET_C(R36.2, Q9.C)
+ NET_C(Q9.E, GND)
+ NET_C(Q9.B, R34.1)
+ NET_C(R34.2, R33.1, F8.Q)
+ NET_C(R33.2, V5)
+
+ // Launch Sound 1
+ NET_C(H6.3, R44.1)
+ NET_C(R44.2, Q14.B)
+ NET_C(Q14.E, GND)
+ NET_C(Q14.C, R46.1)
+ NET_C(R46.2, Q15.B)
+ NET_C(R46.2, R45.1)
+ NET_C(R45.2, R47.1)
+ NET_C(R45.2, Q15.E)
+ NET_C(R47.2, R48.1)
+ NET_C(R48.2, GND)
+ NET_C(R48.1, Q16.B)
+ NET_C(Q15.C, CR29.A)
+ NET_C(CR29.K, R49.1)
+ NET_C(R49.2, Q16.C)
+ NET_C(Q16.E, R50.1)
+ NET_C(R50.2, GND)
+ NET_C(Q15.E, R51.1)
+ NET_C(Q15.E, V12)
+ NET_C(Q15.E, U3.8)
+ NET_C(R51.2, U3.6)
+ NET_C(Q16.C, C20.1)
+ NET_C(C20.2, GND)
+ NET_C(C20.1, U3.5)
+ NET_C(U3.1, GND)
+ NET_C(U3.7, C21.1)
+ NET_C(C21.2, GND)
+ NET_C(U3.3, C22.1)
+ NET_C(C22.2, R52.1)
+ NET_C(R52.2, GND)
+ NET_C(R52.1, CR30.A)
+ NET_C(CR30.K, R53.1)
+ NET_C(R53.2, Q17.C)
+ NET_C(Q17.E, GND)
+ NET_C(Q17.B, R56.1)
+ NET_C(R56.2, R44.1)
+ NET_C(Q17.C, R54.1)
+ NET_C(R54.2, R55.1)
+ NET_C(R55.2, GND)
+ NET_C(R55.1, C23.1)
+ NET_C(C23.2, GND)
+ NET_C(C23.1, R72.1)
+
+ // Launch Sound 2
+ NET_C(H6.11, R57.1)
+ NET_C(R57.2, Q18.B)
+ NET_C(Q18.E, GND)
+ NET_C(Q18.C, R59.1)
+ NET_C(R59.2, Q19.B)
+ NET_C(R59.2, R58.1)
+ NET_C(R58.2, R60.1)
+ NET_C(R58.2, Q19.E)
+ NET_C(R60.2, R61.1)
+ NET_C(R61.2, GND)
+ NET_C(R61.1, Q20.B)
+ NET_C(Q19.C, CR31.A)
+ NET_C(CR31.K, R62.1)
+ NET_C(R62.2, Q20.C)
+ NET_C(Q20.E, R63.1)
+ NET_C(R63.2, GND)
+ NET_C(Q19.E, R64.1)
+ NET_C(Q19.E, V12)
+ NET_C(Q19.E, U4.8)
+ NET_C(R64.2, U4.6)
+ NET_C(Q20.C, C24.1)
+ NET_C(C24.2, GND)
+ NET_C(C24.1, U4.5)
+ NET_C(U4.1, GND)
+ NET_C(U4.7, C25.1)
+ NET_C(C25.2, GND)
+ NET_C(U4.3, C26.1)
+ NET_C(C26.2, R65.1)
+ NET_C(R65.2, GND)
+ NET_C(R65.1, CR32.A)
+ NET_C(CR32.K, R66.1)
+ NET_C(R66.2, Q21.C)
+ NET_C(Q21.E, GND)
+ NET_C(Q21.B, R69.1)
+ NET_C(R69.2, R57.1)
+ NET_C(Q21.C, R67.1)
+ NET_C(R67.2, R68.1)
+ NET_C(R68.2, GND)
+ NET_C(R68.1, C27.1)
+ NET_C(C27.2, GND)
+ NET_C(C27.1, R73.1)
+
+ NET_C(R70.2, R71.2, R72.2, R73.2, R74.1, U5.2, C28.1)
+
+ NET_C(R74.2, R75.2, R75.3)
+ NET_C(C28.2, R75.1, R77.1, U5.6)
+ NET_C(C29.1, U5.7, V5)
+ NET_C(C29.2, GND)
+ NET_C(U5.3, C31.1, R76.1)
+ NET_C(C31.2, GND)
+ NET_C(R76.2, GND)
+ NET_C(U5.4, C30.1, VM5)
+ NET_C(C30.2, GND)
+ NET_C(R77.2, C32.1)
+ NET_C(C32.2, GND)
+
+ // Separate each input into the summing network
+ OPTIMIZE_FRONTIER(R70.1, RES_M(1), 50)
+ OPTIMIZE_FRONTIER(R71.1, RES_M(1), 50)
+ OPTIMIZE_FRONTIER(R72.1, RES_M(1), 50)
+ OPTIMIZE_FRONTIER(R73.1, RES_M(1), 50)
+
+NETLIST_END()
diff --git a/src/mame/audio/nl_starcrus.h b/src/mame/audio/nl_starcrus.h
new file mode 100644
index 00000000000..22bb3e77773
--- /dev/null
+++ b/src/mame/audio/nl_starcrus.h
@@ -0,0 +1,10 @@
+// license:BSD-3-Clause
+// copyright-holders:Ryan Holtz
+#ifndef MAME_AUDIO_NL_STARCRUS_H
+#define MAME_AUDIO_NL_STARCRUS_H
+
+#pragma once
+
+NETLIST_EXTERNAL(starcrus)
+
+#endif // MAME_AUDIO_NL_STARCRUS_H
diff --git a/src/mame/audio/nl_tankbatt.cpp b/src/mame/audio/nl_tankbatt.cpp
new file mode 100644
index 00000000000..f318daf1cd1
--- /dev/null
+++ b/src/mame/audio/nl_tankbatt.cpp
@@ -0,0 +1,165 @@
+// license:BSD-3-Clause
+// copyright-holders:Ryan Holtz
+
+//
+// Netlist for Tank Battalion
+//
+// Derived from the schematics in the manual.
+//
+// Known problems/issues:
+//
+// * None.
+//
+
+#include "netlist/devices/net_lib.h"
+#include "nl_tankbatt.h"
+
+//
+// Main netlist
+//
+
+NETLIST_START(tankbatt)
+
+ SOLVER(Solver, 48000)
+ ANALOG_INPUT(V5, 5)
+ ALIAS(VCC, V5)
+
+ CLOCK(2V, 4000) // 18.432MHz / (3 * 384 * 2)
+ CLOCK(4V, 2000) // 18.432MHz / (3 * 384 * 4)
+
+ TTL_INPUT(S1, 0) // active high
+ TTL_INPUT(S2, 0) // active high
+ TTL_INPUT(OFF, 1) // active high
+ TTL_INPUT(ENGINE_HI, 0) // active high
+ TTL_INPUT(SHOOT, 0) // active high
+ TTL_INPUT(HIT, 0) // active high
+
+ RES(R31, 470)
+ RES(R32, 470)
+ RES(R35, RES_K(4.7))
+ RES(R36, RES_K(4.7))
+ RES(R37, RES_K(6.8))
+ RES(R38, RES_K(10))
+ //RES(R41, RES_K(22))
+ RES(R42, RES_K(22))
+ RES(R43, RES_K(22))
+ RES(R44, RES_K(33))
+ RES(R45, RES_K(47))
+ RES(R46, RES_K(4.7)) // Possible schematic or scan-quality error: Schematic says 47K
+ RES(R47, RES_K(4.7))
+ RES(R48, RES_K(4.7))
+ RES(R49, RES_K(4.7)) // Possible schematic or scan-quality error: Schematic says 47K
+ RES(R50, RES_K(150))
+ RES(R51, RES_K(150))
+ RES(R52, RES_K(220))
+ RES(R53, RES_K(470))
+ RES(R54, RES_K(470))
+ RES(R56_1, RES_K(1))
+ RES(R56_2, RES_K(1))
+ RES(R57, RES_K(10))
+ RES(R58, RES_K(1))
+ RES(R59, RES_K(1))
+ RES(R60, RES_K(1))
+ RES(R61, RES_K(1))
+
+ CAP(C10, CAP_U(2.2))
+ CAP(C11, CAP_U(2.2))
+ CAP(C12, CAP_U(2.2))
+ CAP(C13, CAP_U(2.2))
+ CAP(C14, CAP_U(0.1))
+ CAP(C15, CAP_U(0.01))
+ CAP(C16, CAP_U(0.01))
+ CAP(C17, CAP_U(0.01))
+ CAP(C18, CAP_U(0.01))
+ CAP(C42, CAP_U(0.1))
+
+ DIODE(D8, "D") // Generic diodes, types not listed on schematic
+ DIODE(D9, "D")
+ DIODE(D10, "D")
+ DIODE(D11, "D")
+
+ CD4006(_6F)
+ CD4066_DIP(_6L)
+ LM324_DIP(_6J)
+ TTL_7486_DIP(_6K)
+ TTL_7492_DIP(_5K)
+
+ NET_C(VCC, _5K.5, _6F.VDD, _6J.4, _6K.7, _6L.14, S1.VCC, S2.VCC, OFF.VCC, ENGINE_HI.VCC, SHOOT.VCC, HIT.VCC, 2V.VCC, 4V.VCC)
+ NET_C(GND, _5K.10, _6F.VSS, _6J.11, _6K.14, _6L.7, S1.GND, S2.GND, OFF.GND, ENGINE_HI.GND, SHOOT.GND, HIT.GND, 2V.GND, 4V.GND)
+
+ // Noise generation (presumably)
+ NET_C(_6F.CLOCK, 2V)
+ NET_C(_6F.D1P4, _6F.D3)
+ NET_C(_6F.D3P4, _6F.D4, _6L.12, _6L.6)
+ NET_C(_6F.D1, _6F.D2P5, _6K.A.A)
+ NET_C(_6F.D4P4, _6K.A.B)
+ NET_C(_6K.A.Q, R38.1)
+ NET_C(_6F.D2, R38.2, D9.K)
+ NET_C(_6F.D4P5, D8.A, R53.1)
+ NET_C(D8.K, R53.2, C42.1, _6J.2)
+ NET_C(_6J.1, C42.2, D9.A)
+ NET_C(_6J.3, C12.1, R43.1, R44.1, _6J.12, _6J.10)
+ NET_C(C12.2, GND)
+ NET_C(R43.2, GND)
+ NET_C(R44.2, V5)
+
+ // S1
+ NET_C(S1.Q, _6L.5)
+ NET_C(4V, _6L.4)
+ NET_C(_6L.3, R35.1)
+
+ // S2
+ NET_C(S2.Q, _6L.13)
+ NET_C(2V, _6L.1)
+ NET_C(_6L.2, R36.1)
+
+ // Hit
+ NET_C(HIT.Q, R31.1)
+ NET_C(R31.2, D10.A)
+ NET_C(D10.K, C10.1, _6L.8)
+ NET_C(C10.2, GND)
+ NET_C(_6L.9, R50.1)
+ NET_C(R50.2, R42.1, C15.1, C16.1)
+ NET_C(R42.2, GND)
+ NET_C(C16.2, R54.1, _6J.9)
+ NET_C(C15.2, R54.2, _6J.8, R56_1.1)
+
+ // Shoot
+ NET_C(SHOOT.Q, R32.1)
+ NET_C(R32.2, D11.A)
+ NET_C(D11.K, C11.1, _6L.11)
+ NET_C(C11.2, GND)
+ NET_C(_6L.10, R45.1)
+ NET_C(R45.2, R37.1, C17.1, C18.1)
+ NET_C(R37.2, GND)
+ NET_C(C18.2, R51.1, _6J.13)
+ NET_C(C17.2, R51.2, _6J.14, R56_2.1)
+
+ // Engine Rumble
+ NET_C(ENGINE_HI.Q, _6K.B.A)
+ NET_C(_6K.B.B, _6K.C.Q)
+ NET_C(_6K.B.Q, R52.1, _5K.1)
+ NET_C(R52.2, R46.1, _6J.6, C14.1)
+ NET_C(C14.2, GND)
+ NET_C(_6J.5, R47.1, R48.1, R49.1)
+ NET_C(R47.2, V5)
+ NET_C(R48.2, GND)
+ NET_C(R49.2, R57.1, _6J.7, R46.2, _6K.C.A)
+ NET_C(R57.2, GND)
+ NET_C(_6K.C.B, VCC)
+ NET_C(_5K.7, VCC)
+ NET_C(_5K.6, OFF.Q)
+ NET_C(_5K.11, R60.1, _6K.D.A)
+ NET_C(_5K.8, R58.1, _6K.D.B)
+ NET_C(_6K.D.Q, _5K.14)
+ NET_C(_5K.12, R61.1)
+ NET_C(R58.2, R60.2, R61.2, C13.1, R59.1)
+ NET_C(C13.2, GND)
+
+ // Mixing
+ //NET_C(R56_1.2, R56_2.2)
+ //NET_C(R35.2, R36.2)
+ //NET_C(R56_2.2, R59.2)
+ NET_C(R35.2, R36.2, R56_1.2, R56_2.2, R59.2)
+ //NET_C(R41.2, GND)
+NETLIST_END()
diff --git a/src/mame/audio/nl_tankbatt.h b/src/mame/audio/nl_tankbatt.h
new file mode 100644
index 00000000000..6fa318cc2d6
--- /dev/null
+++ b/src/mame/audio/nl_tankbatt.h
@@ -0,0 +1,10 @@
+// license:BSD-3-Clause
+// copyright-holders:Ryan Holtz
+#ifndef MAME_AUDIO_NL_TANKBATT_H
+#define MAME_AUDIO_NL_TANKBATT_H
+
+#pragma once
+
+NETLIST_EXTERNAL(tankbatt)
+
+#endif // MAME_AUDIO_NL_TANKBATT_H
diff --git a/src/mame/drivers/39in1.cpp b/src/mame/drivers/39in1.cpp
index 50d8853b5d9..0558a4e4ff5 100644
--- a/src/mame/drivers/39in1.cpp
+++ b/src/mame/drivers/39in1.cpp
@@ -49,10 +49,13 @@ public:
, m_maincpu(*this, "maincpu")
{ }
- void _60in1(machine_config &config);
void _39in1(machine_config &config);
void driver_init() override;
+ void init_39in1();
+ void init_60in1();
+ void init_rodent();
+
private:
uint32_t m_seed;
uint32_t m_magic;
@@ -68,8 +71,6 @@ private:
uint32_t cpld_r(offs_t offset);
void cpld_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0);
uint32_t prot_cheater_r();
- DECLARE_MACHINE_START(60in1);
- virtual void machine_start() override;
required_device<cpu_device> m_maincpu;
void _39in1_map(address_map &map);
@@ -267,17 +268,30 @@ static INPUT_PORTS_START( 39in1 )
*/
INPUT_PORTS_END
-void _39in1_state::machine_start()
+void _39in1_state::init_39in1()
{
- uint8_t *ROM = memregion("maincpu")->base();
+ driver_init();
+
+ uint8_t *rom = memregion("maincpu")->base();
+
for (int i = 0; i < 0x80000; i += 2)
{
- ROM[i] = bitswap<8>(ROM[i],7,2,5,6,0,3,1,4) ^ bitswap<8>((i>>3)&0xf, 3,2,4,1,4,4,0,4) ^ 0x90;
+ if (i & 0x08)
+ rom[i] ^= 0x02;
+ if (i & 0x10)
+ rom[i] ^= 0x40;
+ if (i & 0x20)
+ rom[i] ^= 0x04;
+ if (i & 0x40)
+ rom[i] ^= 0x80;
+
+ rom[i] = bitswap<8>(rom[i] ^ 0xc0, 7, 2, 5, 6, 0, 3, 1, 4);
}
}
-MACHINE_START_MEMBER(_39in1_state,60in1)
+void _39in1_state::init_60in1()
{
+ driver_init();
// TODO: Machine is marked as MNW; is this decrypt correct?
uint8_t *ROM = memregion("maincpu")->base();
for (int i = 0; i < 0x80000; i += 2)
@@ -289,6 +303,28 @@ MACHINE_START_MEMBER(_39in1_state,60in1)
}
}
+void _39in1_state::init_rodent()
+{
+ driver_init();
+ // TODO: verify decryption. Game needs appropriate cpld_r() and cpld_w() and possibly protection_cheater_r() methods anyway
+ // what's below gives extremely similar code to the decrypted one for 39in1 up to 0x069C, where the code base seems to start differing
+ uint8_t *rom = memregion("maincpu")->base();
+
+ for (int i = 0; i < 0x80000; i += 2)
+ {
+ if (i & 0x08)
+ rom[i] ^= 0x80;
+ if (i & 0x10)
+ rom[i] ^= 0x04;
+ if (i & 0x20)
+ rom[i] ^= 0x40;
+ if (i & 0x40)
+ rom[i] ^= 0x08;
+
+ rom[i] = bitswap<8>(rom[i] ^ 0x43, 2, 4, 0, 6, 7, 3, 1, 5);
+ }
+}
+
void _39in1_state::_39in1(machine_config &config)
{
PXA255(config, m_maincpu, 200000000);
@@ -301,12 +337,6 @@ void _39in1_state::_39in1(machine_config &config)
m_pxa_periphs->gpio0_read().set(FUNC(_39in1_state::eeprom_r));
}
-void _39in1_state::_60in1(machine_config &config)
-{
- _39in1(config);
- MCFG_MACHINE_START_OVERRIDE(_39in1_state,60in1)
-}
-
ROM_START( 39in1 )
// main program, encrypted
ROM_REGION( 0x80000, "maincpu", 0 )
@@ -436,12 +466,12 @@ ROM_START( rodent )
ROM_LOAD( "93c66.u32", 0x000, 0x200, CRC(c311c7bc) SHA1(8328002b7f6a8b7a3ffca079b7960bc990211d7b) )
ROM_END
-GAME(2004, 4in1a, 39in1, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "4 in 1 MAME bootleg (set 1, ver 3.00)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2004, 4in1b, 39in1, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "4 in 1 MAME bootleg (set 2)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2004, 19in1, 39in1, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "19 in 1 MAME bootleg", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2004, 39in1, 0, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "39 in 1 MAME bootleg", MACHINE_IMPERFECT_SOUND)
-GAME(2004, 48in1, 39in1, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "48 in 1 MAME bootleg (set 1, ver 3.09)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2004, 48in1b, 39in1, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "48 in 1 MAME bootleg (set 2, ver 3.09, alt flash)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2004, 48in1a, 39in1, _39in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "48 in 1 MAME bootleg (set 3, ver 3.02)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2004, 60in1, 39in1, _60in1, 39in1, _39in1_state, driver_init, ROT270, "bootleg", "60 in 1 MAME bootleg (ver 3.00)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
-GAME(2005, rodent, 0, _39in1, 39in1, _39in1_state, driver_init, ROT270, "The Game Room", "Rodent Exterminator", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 4in1a, 39in1, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "4 in 1 MAME bootleg (set 1, ver 3.00)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 4in1b, 39in1, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "4 in 1 MAME bootleg (set 2)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 19in1, 39in1, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "19 in 1 MAME bootleg", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 39in1, 0, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "39 in 1 MAME bootleg", MACHINE_IMPERFECT_SOUND)
+GAME(2004, 48in1, 39in1, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "48 in 1 MAME bootleg (set 1, ver 3.09)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 48in1b, 39in1, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "48 in 1 MAME bootleg (set 2, ver 3.09, alt flash)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 48in1a, 39in1, _39in1, 39in1, _39in1_state, init_39in1, ROT270, "bootleg", "48 in 1 MAME bootleg (set 3, ver 3.02)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2004, 60in1, 39in1, _39in1, 39in1, _39in1_state, init_60in1, ROT270, "bootleg", "60 in 1 MAME bootleg (ver 3.00)", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
+GAME(2005, rodent, 0, _39in1, 39in1, _39in1_state, init_rodent, ROT270, "The Game Room", "Rodent Exterminator", MACHINE_NOT_WORKING|MACHINE_IMPERFECT_SOUND)
diff --git a/src/mame/drivers/4enlinea.cpp b/src/mame/drivers/4enlinea.cpp
index e7ea3f88c58..4e9fc05ef40 100644
--- a/src/mame/drivers/4enlinea.cpp
+++ b/src/mame/drivers/4enlinea.cpp
@@ -679,13 +679,27 @@ ROM_START( 4enlinea )
ROM_REGION( 0x10000, "audiocpu", 0 )
ROM_LOAD( "cuatro_en_linea_27c256__cicplay-1.ic19", 0x0000, 0x8000, CRC(307a57a3) SHA1(241329d919ec43d0eeb1dad0a4db6cf6de06e7e1) )
- ROM_REGION( 0x0800, "eeprom", 0 ) // default serial EEPROM
+ ROM_REGION( 0x0800, "eeprom", 0 ) // default serial EEPROM
ROM_LOAD( "cuatro_en_linea_x24c16p__nosticker.ic17", 0x0000, 0x0800, CRC(21f81f5a) SHA1(00b10eee5af1ca79ced2878f4be4cac2bb8d26a0) )
ROM_REGION( 0x0200, "plds", 0 )
ROM_LOAD( "cuatro_en_linea_gal16v8as__nosticker.ic04", 0x0000, 0x0117, CRC(094edf29) SHA1(428a2f6568ac1032833ee0c65fa8304967a58607) )
ROM_END
+ROM_START( 4enlineb )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "cuatro_en_linea_2_a06.ic6", 0x0000, 0x8000, CRC(f8f14bf8) SHA1(e48fbedbd1b9be6fb56a0f65db80eddbedb487c7) )
+
+ ROM_REGION( 0x10000, "audiocpu", 0 )
+ ROM_LOAD( "cuatro_en_linea_1_a06.ic19", 0x0000, 0x8000, CRC(993d0581) SHA1(d6e366dd827543508037d2071c4b6e638c2cf87b) )
+
+ ROM_REGION( 0x0800, "eeprom", 0 ) // From an operated PCB, a clean one for default need to be created...
+ ROM_LOAD( "cuatro_en_linea_24c16.ic17", 0x0000, 0x0800, CRC(56722dd4) SHA1(f818d882b3070f9b1fac486987a044ab1d418985) )
+
+ ROM_REGION( 0x0200, "plds", 0 )
+ ROM_LOAD( "cuatro_en_linea_gal16v8a.ic04", 0x0000, 0x0117, CRC(1edaf06c) SHA1(51e44c2e6b54991330d6ef945e98fa2c8a49408d) )
+ROM_END
+
/* Kursaal K7 Olympic Darts PCB
__________________________________________________ SUBBOARD CM3080
| ________ __ ______ ______________ | ________________
@@ -747,7 +761,8 @@ ROM_END
* Game Drivers *
***********************************/
-// YEAR NAME PARENT MACHINE INPUT CLASS INIT ROT COMPANY FULLNAME FLAGS
-GAME( 1991, 4enlinea, 0, _4enlinea, 4enlinea, _4enlinea_state, empty_init, ROT0, "Compumatic", "Cuatro en Linea", MACHINE_NOT_WORKING )
-GAME( 1994, k7_olym, 0, k7_olym, k7_olym, _4enlinea_state, empty_init, ROT0, "K7 Kursaal", "Olympic Darts (K7)", MACHINE_NOT_WORKING | MACHINE_MECHANICAL )
-GAME( 1993, sprtdart, 0, k7_olym, k7_olym, _4enlinea_state, empty_init, ROT0, "Compumatic / Desarrollos y Recambios S.L.", "Sport Dart TV", MACHINE_NOT_WORKING | MACHINE_MECHANICAL )
+// YEAR NAME PARENT MACHINE INPUT CLASS INIT ROT COMPANY FULLNAME FLAGS
+GAME( 1991, 4enlinea, 0, _4enlinea, 4enlinea, _4enlinea_state, empty_init, ROT0, "Compumatic / CIC Play", "Cuatro en Linea (rev. A-07)", MACHINE_NOT_WORKING )
+GAME( 1991, 4enlineb, 4enlinea, _4enlinea, 4enlinea, _4enlinea_state, empty_init, ROT0, "Compumatic / CIC Play", "Cuatro en Linea (rev. A-06)", MACHINE_NOT_WORKING )
+GAME( 1994, k7_olym, 0, k7_olym, k7_olym, _4enlinea_state, empty_init, ROT0, "K7 Kursaal", "Olympic Darts (K7)", MACHINE_NOT_WORKING | MACHINE_MECHANICAL )
+GAME( 1993, sprtdart, 0, k7_olym, k7_olym, _4enlinea_state, empty_init, ROT0, "Compumatic / Desarrollos y Recambios S.L.", "Sport Dart TV", MACHINE_NOT_WORKING | MACHINE_MECHANICAL )
diff --git a/src/mame/drivers/aci_prodigy.cpp b/src/mame/drivers/aci_prodigy.cpp
index 07031bce59f..e3ad7abf893 100644
--- a/src/mame/drivers/aci_prodigy.cpp
+++ b/src/mame/drivers/aci_prodigy.cpp
@@ -116,20 +116,14 @@ private:
void shift_clock_w(int state);
void shift_data_w(int state);
- u8 m_select;
- u8 m_led_data;
- u8 m_shift_data;
- u8 m_shift_clock;
+ u8 m_select = 0;
+ u8 m_led_data = 0;
+ u8 m_shift_data = 0;
+ u8 m_shift_clock = 0;
};
void prodigy_state::machine_start()
{
- // zerofill
- m_select = 0;
- m_led_data = 0;
- m_shift_data = 0;
- m_shift_clock = 0;
-
// register for savestates
save_item(NAME(m_select));
save_item(NAME(m_led_data));
diff --git a/src/mame/drivers/amstrad.cpp b/src/mame/drivers/amstrad.cpp
index 67f76a86eda..5d2700c011c 100644
--- a/src/mame/drivers/amstrad.cpp
+++ b/src/mame/drivers/amstrad.cpp
@@ -86,7 +86,7 @@ Some bugs left :
- Implement full Asic for CPC+ emulation. Soft scroll is rather dodgy.
- The KC Compact should not reuse the gate array functionality. Instead z8536 support should be added. (bug #42)
- ******************************************************************************/
+******************************************************************************/
/* Core includes */
#include "emu.h"
@@ -1327,5 +1327,5 @@ COMP( 1985, cpc6128sp, cpc464, 0, cpc6128, cpc6128sp, amstrad_state, empty_
COMP( 1990, cpc464p, 0, 0, cpcplus, plus, amstrad_state, empty_init, "Amstrad plc", "Amstrad CPC464+", 0 )
COMP( 1990, cpc6128p, 0, 0, cpcplus, plus, amstrad_state, empty_init, "Amstrad plc", "Amstrad CPC6128+", 0 )
CONS( 1990, gx4000, 0, 0, gx4000, gx4000, amstrad_state, empty_init, "Amstrad plc", "Amstrad GX4000", 0 )
-COMP( 1989, kccomp, cpc464, 0, kccomp, kccomp, amstrad_state, empty_init, "VEB Mikroelektronik \"Wilhelm Pieck\" Muehlhausen", "KC Compact", 0 )
+COMP( 1989, kccomp, cpc464, 0, kccomp, kccomp, amstrad_state, empty_init, u8"VEB Mikroelektronik \"Wilhelm Pieck\" Mühlhausen", "KC Compact", 0 )
COMP( 1993, al520ex, cpc464, 0, aleste, aleste, amstrad_state, empty_init, "Patisonic", "Aleste 520EX", MACHINE_IMPERFECT_SOUND )
diff --git a/src/mame/drivers/apple2e.cpp b/src/mame/drivers/apple2e.cpp
index 9a3b5f01b43..3366c68a326 100644
--- a/src/mame/drivers/apple2e.cpp
+++ b/src/mame/drivers/apple2e.cpp
@@ -3100,7 +3100,7 @@ void apple2e_state::apple2c_map(address_map &map)
map(0xc000, 0xc07f).rw(FUNC(apple2e_state::c000_iic_r), FUNC(apple2e_state::c000_iic_w));
map(0xc080, 0xc0ff).rw(FUNC(apple2e_state::c080_r), FUNC(apple2e_state::c080_w));
map(0xc098, 0xc09b).rw(m_acia1, FUNC(mos6551_device::read), FUNC(mos6551_device::write));
- map(0xc0a8, 0xc0ab).rw(IIC_ACIA2_TAG, FUNC(mos6551_device::read), FUNC(mos6551_device::write));
+ map(0xc0a8, 0xc0ab).rw(m_acia2, FUNC(mos6551_device::read), FUNC(mos6551_device::write));
map(0xc100, 0xc2ff).m(m_c100bank, FUNC(address_map_bank_device::amap8));
map(0xc300, 0xc3ff).m(m_c300bank, FUNC(address_map_bank_device::amap8));
map(0xc400, 0xc7ff).m(m_c400bank, FUNC(address_map_bank_device::amap8));
@@ -3119,7 +3119,7 @@ void apple2e_state::apple2c_memexp_map(address_map &map)
map(0xc000, 0xc07f).rw(FUNC(apple2e_state::c000_iic_r), FUNC(apple2e_state::c000_iic_w));
map(0xc080, 0xc0ff).rw(FUNC(apple2e_state::c080_r), FUNC(apple2e_state::c080_w));
map(0xc098, 0xc09b).rw(m_acia1, FUNC(mos6551_device::read), FUNC(mos6551_device::write));
- map(0xc0a8, 0xc0ab).rw(IIC_ACIA2_TAG, FUNC(mos6551_device::read), FUNC(mos6551_device::write));
+ map(0xc0a8, 0xc0ab).rw(m_acia2, FUNC(mos6551_device::read), FUNC(mos6551_device::write));
map(0xc0c0, 0xc0c3).rw(FUNC(apple2e_state::memexp_r), FUNC(apple2e_state::memexp_w));
map(0xc100, 0xc2ff).m(m_c100bank, FUNC(address_map_bank_device::amap8));
map(0xc300, 0xc3ff).m(m_c300bank, FUNC(address_map_bank_device::amap8));
@@ -3352,11 +3352,12 @@ TIMER_DEVICE_CALLBACK_MEMBER(apple2e_state::ay3600_repeat)
static INPUT_PORTS_START( apple2_sysconfig )
PORT_START("a2_config")
- PORT_CONFNAME(0x03, 0x00, "Composite monitor type")
+ PORT_CONFNAME(0x07, 0x00, "Monitor type")
PORT_CONFSETTING(0x00, "Color")
PORT_CONFSETTING(0x01, "B&W")
PORT_CONFSETTING(0x02, "Green")
PORT_CONFSETTING(0x03, "Amber")
+ PORT_CONFSETTING(0x04, "Video-7 RGB")
PORT_CONFNAME(0x10, 0x00, "CPU type")
PORT_CONFSETTING(0x00, "Standard")
@@ -4691,10 +4692,12 @@ void apple2e_state::apple2c(machine_config &config)
MOS6551(config, m_acia1, 0);
m_acia1->set_xtal(XTAL(14'318'181) / 8); // ~1.789 MHz
m_acia1->txd_handler().set(PRINTER_PORT_TAG, FUNC(rs232_port_device::write_txd));
+ m_acia1->irq_handler().set(FUNC(apple2e_state::a2bus_irq_w));
MOS6551(config, m_acia2, 0);
- m_acia2->set_xtal(XTAL(1'843'200)); // matches SSC so modem software is compatible
+ m_acia2->set_xtal(1.8432_MHz_XTAL); // matches SSC so modem software is compatible
m_acia2->txd_handler().set("modem", FUNC(rs232_port_device::write_txd));
+ m_acia2->irq_handler().set(FUNC(apple2e_state::a2bus_irq_w));
rs232_port_device &printer(RS232_PORT(config, PRINTER_PORT_TAG, default_rs232_devices, nullptr));
printer.rxd_handler().set(m_acia1, FUNC(mos6551_device::write_rxd));
diff --git a/src/mame/drivers/atari_s1.cpp b/src/mame/drivers/atari_s1.cpp
index fd7770a10be..fbadc60c190 100644
--- a/src/mame/drivers/atari_s1.cpp
+++ b/src/mame/drivers/atari_s1.cpp
@@ -531,7 +531,16 @@ ROM_START(midearth)
ROM_LOAD("608.bin", 0x7800, 0x0800, CRC(28b92faf) SHA1(8585770f4059049f1dcbc0c6ef5718b6ff1a5431))
ROM_REGION(0x0200, "proms", 0)
- ROM_LOAD("82s130.bin", 0x0000, 0x0200, CRC(da1f77b4) SHA1(b21fdc1c6f196c320ec5404013d672c35f95890b))
+ ROM_LOAD("20252-01.bin", 0x0000, 0x0200, CRC(3d44551d) SHA1(926100f8169ab20230ad2168f94e6ad65fb1a7dc))
+ROM_END
+
+ROM_START(mideartha)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("20855-01.bin", 0x7000, 0x0800, CRC(4a9d47ca) SHA1(57c4458822109c3ba2fa53ac1c1cd6e169e51b24))
+ ROM_LOAD("20856-01.bin", 0x7800, 0x0800, CRC(8f119e37) SHA1(5a4d63605865f3ceca4c09dbdcd888498c615b89))
+
+ ROM_REGION(0x0200, "proms", 0)
+ ROM_LOAD("20252-01.bin", 0x0000, 0x0200, CRC(3d44551d) SHA1(926100f8169ab20230ad2168f94e6ad65fb1a7dc))
ROM_END
/*-------------------------------------------------------------------
@@ -547,8 +556,9 @@ ROM_START(spcrider)
ROM_END
-GAME( 1976, atarians, 0, atarians, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "The Atarians", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
-GAME( 1977, time2000, 0, atari_s1, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Time 2000", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
-GAME( 1977, aavenger, 0, atari_s1, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Airborne Avenger", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
-GAME( 1978, midearth, 0, midearth, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Middle Earth", MACHINE_IS_SKELETON_MECHANICAL)
-GAME( 1978, spcrider, 0, atari_s1, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Space Riders", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
+GAME( 1976, atarians, 0, atarians, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "The Atarians", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
+GAME( 1977, time2000, 0, atari_s1, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Time 2000", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
+GAME( 1977, aavenger, 0, atari_s1, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Airborne Avenger", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
+GAME( 1978, midearth, 0, midearth, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Middle Earth", MACHINE_IS_SKELETON_MECHANICAL)
+GAME( 1978, mideartha, midearth, midearth, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Middle Earth (alternate)", MACHINE_IS_SKELETON_MECHANICAL)
+GAME( 1978, spcrider, 0, atari_s1, atari_s1, atari_s1_state, empty_init, ROT0, "Atari", "Space Riders", MACHINE_MECHANICAL | MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
diff --git a/src/mame/drivers/bbl380.cpp b/src/mame/drivers/bbl380.cpp
index c73a1b3c488..78952bcb52f 100644
--- a/src/mame/drivers/bbl380.cpp
+++ b/src/mame/drivers/bbl380.cpp
@@ -4,6 +4,12 @@
// the BBL 380 - 180 in 1 features similar menus / presentation / games to the 'ORB Gaming Retro Arcade Pocket Handheld Games Console with 153 Games' (eg has Matchstick Man, Gang Tie III etc.)
// https://www.youtube.com/watch?v=NacY2WHd-CY
+// BIOS calls are made very frequently to the undumped firmware.
+// The most common call ($6058 in bbl380, $6062 in ragc153 & dphh8630) seems to involve downloading a snippet of code from Flash and executing it from RAM.
+// A variant of this call ($60d2 in bbl380, $60e3 in ragc153 & dphh8630) is invoked with jsr.
+// For these calls, a 24-bit starting address is specified in $82:$81:$80, and the length in bytes is twice the number specified in $84:$83.
+// ST2205U cannot execute code directly from Flash, but has a built-in DMA-compatible NAND interface on Port F ($05).
+
#include "emu.h"
#include "cpu/m6502/st2205u.h"
diff --git a/src/mame/drivers/bfcobra.cpp b/src/mame/drivers/bfcobra.cpp
index 62b258c02e9..d50d32661a5 100644
--- a/src/mame/drivers/bfcobra.cpp
+++ b/src/mame/drivers/bfcobra.cpp
@@ -52,14 +52,32 @@
==================
A compact video expansion board for Scorpion II.
- The Z80 is replaced by a Z180 and there is no Flare DSP or FDC
+ The Z80 is replaced by a Z180 and there is no Flare DSP.
+ The FDC is replaced by a NCR53C80 SCSI controller.
+ Cyclone was never released due to reliability issues.
+ Cobra II Jamma
+ ==============
+ Based on Cobra II but with a JAMMA edge connector for easy use in video game cabinets.
+ This is a standalone board which is not paired with any Scorpion boards.
+ Break Ball is the only released game for this platform.
+ The only other known software is for a functional test unit (FTU).
+
+ Note that for Z8S180 boards the CPU has 20 address lines so can select the entire memory map
+ without using the Flare chipset paging option. I believe changing the addresses using chipset_w
+ have no effect on Z8S180 boards.
To do:
* Complete blitter emulation
- * Cobra II support
+ * Cobra II support.
* Hook up additional inputs, EM meters, lamps etc
+ * The prom range selected for the first 16K of Z80 memory map is not fixed so chipset_w
+ function needs changing to process offset 0. Note that no released software changes this anyway.
+ * Frame interrupt for Z80 boards is wrong. It isn't a frame interrupt but an interrupt which can be
+ triggered on any scan line. For Z80 boards the fact that it's treated as a frame interrupt doesn't
+ matter as no released software changes the position of the interrupt. Emulation for Z8S180 boards
+ is correct as Break Ball uses multiple scan line interrupts.
Known issues:
@@ -71,35 +89,50 @@
* Plane priority is probably wrong but it's only used in Treble Top.
* Blitter loop counts and step are wrong - they are 9 bit counts, not 8.
* Blitter emulation doesn't support hi-res mode (needed for Inquizitor)
+ * Blitter emulation currently runs until blit is complete then burns the required number of Z80
+ cycles to simulate it holding the bus. On the real hardware the blitter halts the CPU until the
+ operation is complete or an interrupt is issued to CPU. When the interrupt line is asserted the
+ CPU is allowed to run until the interrupt line is released. This allows all interrupts to run at
+ the correct time. The current emulation is OK for Z80 boards and all released software for those
+ boards, however, for Cobra II/JAMMA this causes problems due to the UPD7759 audio chip issuing
+ dma requests which are then processed too late if the Z8S180 cycles are burnt. To get round this
+ the Z8S180 blitter emulation does not burn CPU cycles.
+ The blitter emulation ought to take account of irq/dma requests but I don't know how to do that!
******************************************************************************/
#include "emu.h"
#include "cpu/m6809/m6809.h"
#include "cpu/z80/z80.h"
+#include "cpu/z180/z180.h"
#include "machine/6850acia.h"
#include "machine/clock.h"
+#include "machine/i2cmem.h"
#include "machine/meters.h"
#include "machine/nvram.h"
#include "sound/ay8910.h"
#include "sound/upd7759.h"
+#include "sound/ym2413.h"
+#include "video/bfm_dm01.h"
#include "video/ramdac.h"
#include "emupal.h"
#include "screen.h"
#include "speaker.h"
+#include "brkball.lh"
/*
Defines
*/
+#define Z8S180_XTAL 24000000
#define Z80_XTAL 5910000 /* Unconfirmed */
-#define M6809_XTAL 4000000 /* Unconfirmed */
+#define M6809_XTAL 4000000
/***************************************************************************
- Split into video\cobra.c !
+ Split into video\bfcobra.cpp !
***************************************************************************/
@@ -641,8 +674,7 @@ void bfcobra_state::RunBlit()
}
if (blitter.compfunc & CMPFUNC_LT)
{
- /* Might be wrong */
- if ((srcdata & 0xc0) < (dstdata & 0xc0))
+ if ((srcdata & 0xc0) > (dstdata & 0xc0))
{
inhibit = 1;
@@ -664,8 +696,7 @@ void bfcobra_state::RunBlit()
}
if (blitter.compfunc & CMPFUNC_GT)
{
- /* Might be wrong */
- if ((srcdata & 0xc0) > (dstdata & 0xc0))
+ if ((srcdata & 0xc0) < (dstdata & 0xc0))
{
inhibit = 1;
@@ -984,7 +1015,7 @@ void bfcobra_state::rombank_w(uint8_t data)
/***************************************************************************
- Split into machine\cobra.c !
+ Split into machine\bfcobra.cpp !
Alternatively chuck it all away and borrow the MESS implementation
because it's a million times better.
@@ -1691,6 +1722,1100 @@ void bfcobra_state::bfcobra(machine_config &config)
}
/***************************************************************************
+ Cobra II Jamma.
+
+ This has a Z180 and no 6809
+
+***************************************************************************/
+class bfcobjam_state : public driver_device
+{
+public:
+ bfcobjam_state(const machine_config &mconfig, device_type type, const char *tag) :
+ driver_device(mconfig, type, tag),
+ m_maincpu(*this, "maincpu"),
+ m_acia6850_0(*this, "acia6850_0"),
+ m_screen(*this, "screen"),
+ m_palette(*this, "palette"),
+ m_aux_upd7759(*this, "upd"),
+ m_upd7759_int(*this, "updint"),
+ m_ym2413(*this, "ymsnd"),
+ m_i2cmem(*this, "i2cmem"),
+ m_dm01(*this, "dm01"),
+ m_work_ram(*this, "work_ram"),
+ m_video_ram(*this, "video_ram")
+ {
+ }
+
+ void init_bfcobjam();
+ void bfcobjam(machine_config &config);
+ void bfcobjam_with_dmd(machine_config &config);
+
+protected:
+ virtual void machine_start() override;
+ virtual void machine_reset() override;
+ virtual void video_start() override;
+
+private:
+ uint8_t m_bank_data[4];
+ uint8_t m_rompage;
+ uint8_t m_h_scroll;
+ uint8_t m_v_scroll;
+ uint8_t m_flip_8;
+ uint8_t m_flip_22;
+ uint8_t m_videomode;
+ uint8_t m_data_r;
+ uint8_t m_data_t;
+ uint8_t m_port_0;
+ int m_irq_state;
+ int m_acia_irq;
+ int m_scanline_irq;
+ int m_blitter_irq;
+ int m_global_volume;
+ uint8_t dm_shift_data ;
+ int dm_shift = 0 ;
+ int dm_last_data = 0 ;
+
+ uint8_t m_z8s180_int;
+ uint8_t m_z8s180_inten;
+ uint8_t m_col4bit[16];
+ uint8_t m_col3bit[16];
+ uint8_t m_col8bit[256];
+ uint8_t m_col7bit[256];
+ uint8_t m_col6bit[256];
+ struct bf_blitter_t m_blitter;
+ emu_timer *m_scanline_timer;
+ uint8_t m_genio ;
+ required_device<cpu_device> m_maincpu;
+ required_device<acia6850_device> m_acia6850_0;
+ required_device<screen_device> m_screen;
+ required_device<palette_device> m_palette;
+ optional_device<upd7759_device> m_aux_upd7759;
+ required_device<upd7759_device> m_upd7759_int;
+ required_device<ym2413_device> m_ym2413;
+ required_device<i2c_24c08_device> m_i2cmem;
+ optional_device<bfm_dm01_device> m_dm01;
+ required_shared_ptr<uint8_t> m_work_ram;
+ required_shared_ptr<uint8_t> m_video_ram;
+
+ uint8_t chipset_r(offs_t offset);
+ void chipset_w(offs_t offset, uint8_t data);
+ void rombank_w(uint8_t data);
+ void upd7759_w(uint8_t data);
+ uint8_t aux_upd7759_r();
+ void aux_upd7759_w(uint8_t data);
+ void output0_w(uint8_t data);
+ uint8_t input0_r();
+ uint8_t input1_r();
+ DECLARE_WRITE_LINE_MEMBER(z8s180_acia_irq);
+ DECLARE_WRITE_LINE_MEMBER(data_acia_tx_w);
+ DECLARE_WRITE_LINE_MEMBER(write_acia_clock);
+ DECLARE_WRITE_LINE_MEMBER(upd7759_generate_dreq );
+ uint32_t screen_update_bfcobjam(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(timer_irq);
+ TIMER_CALLBACK_MEMBER( scanline_callback ) ;
+ void RunBlit();
+ void update_irqs();
+ void genio_w( uint8_t data ) ;
+ void dotmatrix_w( uint8_t data );
+ inline uint8_t* blitter_get_addr(uint32_t addr);
+ inline void z8s180_bank(int num, int data);
+
+ void ramdac_map(address_map &map);
+ void z8s180_io_map(address_map &map);
+ void z8s180_prog_map(address_map &map);
+};
+
+void bfcobjam_state::init_bfcobjam()
+{
+ m_rompage = 0 ;
+ m_bank_data[0] = 0;
+ m_bank_data[1] = 0;
+ m_bank_data[2] = 0;
+ m_bank_data[3] = 0;
+
+ /* Fixed 16kB ROM region */
+ membank("bank4")->set_base(memregion("user1")->base());
+ membank("bank1")->set_base(memregion("user1")->base()+0x04000);
+ membank("bank2")->set_base(memregion("user1")->base()+0x08000);
+ membank("bank3")->set_base(memregion("user1")->base()+0x0c000);
+
+ m_scanline_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(bfcobjam_state::scanline_callback),this));
+
+ /* Finish this */
+ save_item(NAME(m_data_r));
+ save_item(NAME(m_data_t));
+ save_item(NAME(m_h_scroll));
+ save_item(NAME(m_v_scroll));
+ save_item(NAME(m_flip_8));
+ save_item(NAME(m_flip_22));
+ save_item(NAME(m_z8s180_int));
+ save_item(NAME(m_z8s180_inten));
+ save_item(NAME(m_bank_data));
+ save_item(NAME(m_genio));
+ save_item(NAME(m_global_volume));
+
+}
+
+/*
+ This is based this on the Slipstream technical reference manual.
+ The Flare One blitter is a simpler design with slightly different parameters
+ and will require hardware tests to figure everything out correctly.
+*/
+void bfcobjam_state::RunBlit()
+{
+#define BLITPRG_READ(x) blitter.x = *(blitter_get_addr(blitter.program.addr++))
+
+ struct bf_blitter_t &blitter = m_blitter;
+ int cycles_used = 0;
+
+
+ do
+ {
+ uint8_t srcdata = 0;
+ uint8_t dstdata = 0;
+
+ /* Read the blitter command */
+ BLITPRG_READ(source.as8bit.addr0);
+ BLITPRG_READ(source.as8bit.addr1);
+ BLITPRG_READ(source.as8bit.addr2);
+ BLITPRG_READ(dest.as8bit.addr0);
+ BLITPRG_READ(dest.as8bit.addr1);
+ BLITPRG_READ(dest.as8bit.addr2);
+ BLITPRG_READ(modectl);
+ BLITPRG_READ(compfunc);
+ BLITPRG_READ(outercnt);
+ BLITPRG_READ(innercnt);
+ BLITPRG_READ(step);
+ BLITPRG_READ(pattern);
+
+#if 0
+ /* This debug is now wrong ! */
+ if (DEBUG_BLITTER)
+ {
+ osd_printf_debug("\n%s:Blitter: Running command from 0x%.5x\n\n", device->machine().describe_context(), blitter.program.addr - 12);
+ osd_printf_debug("Command Reg %.2x", blitter.command);
+ osd_printf_debug(" %s %s %s %s %s %s %s\n",
+ blitter.command & CMD_RUN ? "RUN" : " ",
+ blitter.command & CMD_COLST ? "COLST" : " ",
+ blitter.command & CMD_PARRD ? "PARRD" : " ",
+ blitter.command & CMD_SRCUP ? "SRCUP" : " ",
+ blitter.command & CMD_DSTUP ? "DSTUP" : " ");
+
+ osd_printf_debug("Src Address Byte 0 %.2x\n", blitter.source.as8bit.addr0);
+ osd_printf_debug("Src Address Byte 1 %.2x\n", blitter.source.as8bit.addr1);
+ osd_printf_debug("Src Control %.2x\n", blitter.source.as8bit.addr2);
+ osd_printf_debug(" Src Address %.5x\n", blitter.source.addr & 0xfffff);
+ osd_printf_debug("Dest Address Byte 0 %.2x\n", blitter.dest.as8bit.addr0);
+ osd_printf_debug("Dest Address Byte 1 %.2x\n", blitter.dest.as8bit.addr1);
+ osd_printf_debug("Dest Control %.2x\n", blitter.dest.as8bit.addr2);
+ osd_printf_debug(" Dst. Address %.5x\n", blitter.dest.addr & 0xfffff);
+ osd_printf_debug("Mode Control %.2x", blitter.modectl);
+ osd_printf_debug(" %s\n", blitter.modectl & MODE_BITTOBYTE ? "BIT_TO_BYTE" : "");
+
+ osd_printf_debug("Comp. and LFU %.2x\n", blitter.compfunc);
+ osd_printf_debug("Outer Loop Count %.2x (%d)\n", blitter.outercnt, blitter.outercnt);
+ osd_printf_debug("Inner Loop Count %.2x (%d)\n", blitter.innercnt, blitter.innercnt);
+ osd_printf_debug("Step Value %.2x\n", blitter.step);
+ osd_printf_debug("Pattern Byte %.2x\n", blitter.pattern);
+ }
+#endif
+
+ /* Ignore these writes */
+ if (blitter.dest.addr == 0)
+ return;
+
+ /* Begin outer loop */
+ for (;;)
+ {
+ uint8_t innercnt = blitter.innercnt;
+ dstdata = blitter.pattern;
+
+ if (blitter.command & CMD_LINEDRAW)
+ {
+ do
+ {
+ if (blitter.modectl & MODE_YFRAC)
+ {
+ if (blitter.modectl & MODE_SSIGN )
+ blitter.dest.as8bit.addr0--;
+ else
+ blitter.dest.as8bit.addr0++;
+ }
+ else
+ {
+ if (blitter.modectl & MODE_DSIGN )
+ blitter.dest.as8bit.addr1--;
+ else
+ blitter.dest.as8bit.addr1++;
+ }
+ if( blitter.source.as8bit.addr0 < blitter.step )
+ {
+ blitter.source.as8bit.addr0 -= blitter.step ;
+ blitter.source.as8bit.addr0 += blitter.source.as8bit.addr1;
+
+ if ( blitter.modectl & MODE_YFRAC )
+ {
+ if (blitter.modectl & MODE_DSIGN )
+ blitter.dest.as8bit.addr1--;
+ else
+ blitter.dest.as8bit.addr1++;
+ }
+ else
+ {
+ if (blitter.modectl & MODE_SSIGN )
+ blitter.dest.as8bit.addr0--;
+ else
+ blitter.dest.as8bit.addr0++;
+ }
+ }
+ else
+ {
+ blitter.source.as8bit.addr0 -= blitter.step;
+ }
+
+ *blitter_get_addr( blitter.dest.addr) = blitter.pattern;
+ cycles_used++;
+
+ } while (--innercnt);
+ }
+ else do
+ {
+ uint8_t inhibit = 0;
+
+ /* TODO: Set this correctly */
+ uint8_t result = blitter.pattern;
+
+ if (LOOPTYPE == 3 && innercnt == blitter.innercnt)
+ {
+ srcdata = *(blitter_get_addr( blitter.source.addr & 0xfffff));
+ blitter.source.as16bit.loword++;
+ cycles_used++;
+ }
+
+ /* Enable source address read and increment? */
+ if (!(blitter.modectl & (MODE_BITTOBYTE | MODE_PALREMAP)))
+ {
+ if (LOOPTYPE == 0 || LOOPTYPE == 1)
+ {
+ srcdata = *(blitter_get_addr( blitter.source.addr & 0xfffff));
+ cycles_used++;
+
+ if (blitter.modectl & MODE_SSIGN)
+ blitter.source.as16bit.loword-- ;
+ else
+ blitter.source.as16bit.loword++;
+
+ result = srcdata;
+ }
+ }
+
+ /* Read destination pixel? */
+ if (LOOPTYPE == 0)
+ {
+ dstdata = *blitter_get_addr( blitter.dest.addr & 0xfffff);
+ cycles_used++;
+ }
+
+ /* Inhibit depending on the bit selected by the inner count */
+
+ /* Switch on comparator type? */
+ if (blitter.modectl & MODE_BITTOBYTE)
+ {
+ inhibit = !(srcdata & (1 << (8 - innercnt)));
+ }
+
+ if (blitter.compfunc & CMPFUNC_BEQ)
+ {
+ if (srcdata == blitter.pattern)
+ {
+ inhibit = 1;
+
+ /* TODO: Resume from inhibit? */
+ if (blitter.command & CMD_COLST)
+ return;
+ }
+ }
+ if (blitter.compfunc & CMPFUNC_LT)
+ {
+ if ((srcdata & 0xc0) > (dstdata & 0xc0))
+ {
+ inhibit = 1;
+
+ /* TODO: Resume from inhibit? */
+ if (blitter.command & CMD_COLST)
+ return;
+ }
+ }
+ if (blitter.compfunc & CMPFUNC_EQ)
+ {
+ if ((srcdata & 0xc0) == (dstdata & 0xc0))
+ {
+ inhibit = 1;
+
+ /* TODO: Resume from inhibit? */
+ if (blitter.command & CMD_COLST)
+ return;
+ }
+ }
+ if (blitter.compfunc & CMPFUNC_GT)
+ {
+ if ((srcdata & 0xc0) < (dstdata & 0xc0))
+ {
+ inhibit = 1;
+
+ /* TODO: Resume from inhibit? */
+ if (blitter.command & CMD_COLST)
+ return;
+ }
+ }
+
+ /* Write the data if not inhibited */
+ if (!inhibit)
+ {
+ if (blitter.modectl == MODE_PALREMAP)
+ {
+ /*
+ In this mode, the source points to a 256 entry lookup table.
+ The existing destination pixel is used as a lookup
+ into the table and the colours is replaced.
+ */
+ uint8_t dest = *blitter_get_addr( blitter.dest.addr);
+ uint8_t newcol = *(blitter_get_addr( (blitter.source.addr + dest) & 0xfffff));
+
+ *blitter_get_addr( blitter.dest.addr) = newcol;
+ cycles_used += 3;
+ }
+ else
+ {
+ uint8_t final_result = 0;
+
+ if (blitter.compfunc & CMPFUNC_LOG3)
+ final_result |= result & dstdata;
+
+ if (blitter.compfunc & CMPFUNC_LOG2)
+ final_result |= result & ~dstdata;
+
+ if (blitter.compfunc & CMPFUNC_LOG1)
+ final_result |= ~result & dstdata;
+
+ if (blitter.compfunc & CMPFUNC_LOG0)
+ final_result |= ~result & ~dstdata;
+
+ *blitter_get_addr( blitter.dest.addr) = final_result;
+ cycles_used++;
+ }
+ }
+
+ /* Update destination address */
+ if (blitter.modectl & MODE_DSIGN)
+ blitter.dest.as16bit.loword--;
+ else
+ blitter.dest.as16bit.loword++;
+
+ } while (--innercnt);
+
+ if (!--blitter.outercnt)
+ {
+ break;
+ }
+ else
+ {
+ if (blitter.command & CMD_DSTUP)
+ blitter.dest.as16bit.loword += blitter.step;
+
+ if (blitter.command & CMD_SRCUP)
+ blitter.source.as16bit.loword += blitter.step;
+
+ if (blitter.command & CMD_PARRD)
+ {
+ BLITPRG_READ(innercnt);
+ BLITPRG_READ(step);
+ BLITPRG_READ(pattern);
+ }
+ }
+ }
+
+ /* Read next command header */
+ BLITPRG_READ(command);
+
+ } while (blitter.command & CMD_RUN);
+
+ /* Burn Z180 cycles while blitter is in operation */
+ /* Don't burn for Z8S180 */
+// m_maincpu->spin_until_time(attotime::from_nsec( (1000000000 / Z8S180_XTAL)*cycles_used * 2 ) );
+}
+
+uint8_t* bfcobjam_state::blitter_get_addr(uint32_t addr)
+{
+ if (addr < 0x10000)
+ {
+ /* Is this region fixed? */
+ return (uint8_t*)(memregion("user1")->base() + addr);
+ }
+ else if(addr < 0x20000)
+ {
+ addr &= 0xffff;
+ addr += m_rompage * 0x10000 ;
+
+ return (uint8_t*)(memregion("user1")->base() + addr );
+ }
+ else if (addr >= 0x20000 && addr < 0x40000)
+ {
+ return (uint8_t*)&m_video_ram[addr - 0x20000];
+ }
+ else
+ {
+ return (uint8_t*)&m_work_ram[addr - 0x40000];
+ }
+}
+
+uint8_t bfcobjam_state::chipset_r(offs_t offset)
+{
+ uint8_t val = 0xff;
+
+ switch(offset)
+ {
+ case 0:
+ case 1:
+ case 2:
+ case 3:
+ {
+ val = m_bank_data[offset];
+ break;
+ }
+ case 6:
+ {
+ /* TODO */
+ val = m_scanline_irq << 4;
+ break;
+ }
+ case 7:
+ {
+ m_scanline_irq = 0;
+ val = 0x1;
+
+ /* TODO */
+ update_irqs();
+ break;
+ }
+ case 0x1C:
+ {
+ /* Blitter status ? */
+ val = ioport("CJIN3")->read();
+ break;
+ }
+ case 0x20:
+ {
+ /* Seems correct - used during RLE pic decoding */
+ val = m_blitter.dest.as8bit.addr0;
+ break;
+ }
+ case 0x22:
+ {
+ val = 0x40 | ioport("CJIN2")->read() | ( m_upd7759_int->busy_r() ? 0x20 : 0 ) ;
+ break;
+ }
+ default:
+ {
+ osd_printf_debug("Flare One unknown read: 0x%.2x (PC:0x%.4x)\n", offset, m_maincpu->pcbase());
+ }
+ }
+
+ return val;
+}
+
+void bfcobjam_state::chipset_w(offs_t offset, uint8_t data)
+{
+ switch (offset)
+ {
+ case 0x00:
+ case 0x01:
+ case 0x02:
+ case 0x03:
+ {
+ popmessage("%x: Unusual bank access (%x)\n", m_maincpu->pcbase(), data);
+
+ data &= 0x3f;
+ m_bank_data[offset] = data;
+ z8s180_bank(offset, data);
+ break;
+ }
+
+ case 0x07:
+ m_scanline_timer->adjust(m_screen->time_until_pos(data));
+ break ;
+
+ case 0x08:
+ {
+ m_flip_8 = data;
+ break;
+ }
+ case 9:
+ m_videomode = data;
+ break;
+
+ case 0x0B:
+ {
+ m_h_scroll = data;
+ break;
+ }
+ case 0x0C:
+ {
+ m_v_scroll = data;
+ break;
+ }
+ case 0x0E:
+ {
+ m_col4bit[5] = data;
+ m_col3bit[5] = data;
+ m_col3bit[5 + 8] = data;
+ break;
+ }
+ case 0x0f:
+ {
+ m_col4bit[6] = data;
+ m_col3bit[6] = data;
+ m_col3bit[6 + 8] = data;
+ break;
+ }
+ case 0x18:
+ {
+ m_blitter.program.as8bit.addr0 = data;
+ break;
+ }
+ case 0x19:
+ {
+ m_blitter.program.as8bit.addr1 = data;
+ break;
+ }
+ case 0x1A:
+ {
+ m_blitter.program.as8bit.addr2 = data;
+ break;
+ }
+ case 0x20:
+ {
+ m_blitter.command = data;
+
+ if (data & CMD_RUN)
+ RunBlit();
+ else
+ osd_printf_debug("Blitter stopped by IO.\n");
+
+ break;
+ }
+ case 0x22:
+ {
+ m_flip_22 = data;
+ genio_w( data ) ;
+ break;
+ }
+ default:
+ {
+ osd_printf_debug("Flare One unknown write: 0x%.2x with 0x%.2x (PC:0x%.4x)\n", offset, data, m_maincpu->pcbase());
+ }
+ }
+}
+
+uint32_t bfcobjam_state::screen_update_bfcobjam(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
+{
+ int x, y;
+ uint8_t *src;
+ uint32_t *dest;
+ uint32_t offset;
+ uint8_t *hirescol;
+ uint8_t *lorescol;
+
+
+ /* Select screen has to be programmed into two registers */
+ /* No idea what happens if the registers are different */
+ if (m_flip_8 & 0x40 && m_flip_22 & 0x40)
+ offset = 0x10000;
+ else
+ offset = 0;
+
+ if(m_videomode & 0x20)
+ {
+ hirescol = m_col3bit;
+ lorescol = m_col7bit;
+ }
+ else if(m_videomode & 0x40)
+ {
+ hirescol = m_col4bit;
+ lorescol = m_col6bit;
+ }
+ else
+ {
+ hirescol = m_col4bit;
+ lorescol = m_col8bit;
+ }
+
+ for (y = cliprect.top(); y <= cliprect.bottom(); ++y)
+ {
+ uint16_t y_offset = (y + m_v_scroll) * 256;
+ src = &m_video_ram[offset + y_offset];
+ dest = &bitmap.pix32(y);
+
+ for (x = cliprect.left(); x <= cliprect.right() / 2; ++x)
+ {
+ uint8_t x_offset = x + m_h_scroll;
+ uint8_t pen = *(src + x_offset);
+
+ if ( ( m_videomode & 0x81 ) == 1 || (m_videomode & 0x80 && pen & 0x80) )
+ {
+ *dest++ = m_palette->pen(hirescol[pen & 0x0f]);
+ *dest++ = m_palette->pen(hirescol[(pen >> 4) & 0x0f]);
+ }
+ else
+ {
+ *dest++ = m_palette->pen(lorescol[pen]);
+ *dest++ = m_palette->pen(lorescol[pen]);
+ }
+ }
+ }
+
+ return 0;
+}
+
+void bfcobjam_state::ramdac_map(address_map &map)
+{
+ map(0x000, 0x3ff).rw("ramdac", FUNC(ramdac_device::ramdac_pal_r), FUNC(ramdac_device::ramdac_rgb666_w));
+}
+
+
+void bfcobjam_state::z8s180_bank(int num, int data)
+{
+ static const char * const bank_names[] = { "bank4","bank1", "bank2", "bank3" };
+
+ if (data < 0x04)
+ {
+ membank(bank_names[num])->set_base(memregion("user1")->base() + (data*0x4000));
+ }
+ else if (data < 0x08)
+ {
+ uint32_t offset ;
+ offset = m_rompage * 0x10000 ;
+ offset += (data-4) * 0x4000 ;
+
+ membank(bank_names[num])->set_base(memregion("user1")->base() + offset);
+ }
+ else if (data < 0x10)
+ {
+ membank(bank_names[num])->set_base(&m_video_ram[(data - 0x08) * 0x4000]);
+ }
+ else
+ {
+ membank(bank_names[num])->set_base(&m_work_ram[(data - 0x10) * 0x4000]);
+ }
+}
+
+void bfcobjam_state::update_irqs()
+{
+ int newstate = m_blitter_irq || m_scanline_irq || m_acia_irq;
+
+ if (newstate != m_irq_state)
+ {
+ m_irq_state = newstate;
+ m_maincpu->set_input_line(0, m_irq_state ? ASSERT_LINE : CLEAR_LINE);
+ }
+}
+
+TIMER_CALLBACK_MEMBER( bfcobjam_state::scanline_callback )
+{
+ m_scanline_timer->adjust(m_screen->time_until_pos(0));
+ m_scanline_irq = 1;
+ update_irqs();
+}
+
+WRITE_LINE_MEMBER(bfcobjam_state::z8s180_acia_irq)
+{
+ m_acia_irq = state;
+ update_irqs();
+}
+
+
+void bfcobjam_state::rombank_w(uint8_t data)
+{
+ m_rompage = data ;
+
+ membank("bank5")->set_entry(m_rompage & 0x0f);
+}
+
+/*
+ This parallel port is used for bit-bashing the following devices.
+ 1. Dot matrix display
+ 2. I2C 24C08
+ The bit use is as follows:
+ b0 =
+ b1 =
+ b2 = Dot matrix clock
+ b3 = Dot matrix data
+ b4 = Dot matrix reset
+ b5 = I2C SDA
+ b6 = I2C SCL
+ b7 =
+*/
+void bfcobjam_state::output0_w(uint8_t data)
+{
+ uint8_t changed = m_port_0 ^ data ;
+ m_port_0 = data ;
+
+ dotmatrix_w( data ) ;
+
+ //cobra handling of scl and sda is wrong but devices handle it ok
+ //unfortunately mame emulation of i2c 24c08 doesn't :(
+ //we frig the driving of scl/sda to correct this
+ changed &= 0x60 ;
+
+ if( changed == 0x60 )
+ {
+ if( data & 0x40 )
+ {
+ m_i2cmem->write_scl(!(BIT(data, 6)));
+ m_i2cmem->write_sda(!(BIT(data, 5)));
+ }
+ else
+ {
+ m_i2cmem->write_sda(!(BIT(data, 5)));
+ m_i2cmem->write_scl(!(BIT(data, 6)));
+ }
+ }
+ else
+ {
+ m_i2cmem->write_scl(!(BIT(data, 6)));
+ m_i2cmem->write_sda(!(BIT(data, 5)));
+ }
+}
+
+void bfcobjam_state::dotmatrix_w( uint8_t data )
+{
+ if( m_dm01 )
+ {
+ data &= 0x1c ;
+
+ if( data != dm_last_data )
+ {
+ if( data & 0x10 )
+ {
+ }
+ else
+ {
+ m_dm01->reset() ;
+ dm_shift=0;
+ dm_shift_data=0;
+ }
+ if( !(data & 4 ) && ( dm_last_data & 4 ) && data & 0x10 ) // clock is low but was high and out of reset
+ {
+ dm_shift_data <<= 1 ;
+ if( !(data & 0x08 ))
+ {
+ dm_shift_data |=1 ;
+ }
+ dm_shift++;
+ if( dm_shift == 8 )
+ {
+ dm_shift=0;
+ m_dm01->writedata( dm_shift_data ) ;
+ }
+ }
+ dm_last_data = data ;
+ }
+ }
+}
+
+uint8_t bfcobjam_state::input0_r()
+{
+ return ioport("CJIN0")->read() | (m_i2cmem->read_sda() ? 0x80 : 0x00);
+}
+
+uint8_t bfcobjam_state::input1_r()
+{
+ return ioport("CJIN1")->read();
+}
+
+void bfcobjam_state::aux_upd7759_w(uint8_t data)
+{
+ if( m_aux_upd7759 )
+ {
+ m_aux_upd7759->set_rom_bank((data>>2)&3);
+
+ m_aux_upd7759->port_w((data>>4)&0xf);
+
+ m_aux_upd7759->md_w(1);
+
+ m_aux_upd7759->reset_w(BIT(data, 0));
+
+ m_aux_upd7759->start_w(!BIT(data, 1));
+ }
+}
+
+uint8_t bfcobjam_state::aux_upd7759_r()
+{
+ if( m_aux_upd7759 )
+ {
+ return m_aux_upd7759->busy_r();
+ }
+ else
+ {
+ return 0 ;
+ }
+}
+
+void bfcobjam_state::genio_w( uint8_t data )
+{
+ //bit 0 = ??
+ //bit 1 = upd7759 start
+ //bit 2 = upd7759 reset
+ //bit 3 = ??
+ //bit 4 = digital volume clock
+ //bit 5 = digital volume up/down
+ //bit 6 = ??
+ //bit 7 = ??
+
+ uint8_t changed = m_genio ^ data ;
+
+ m_genio = data ;
+
+ if ( changed & 0x10)
+ { // digital volume clock line changed
+ if ( !(data & 0x10) )
+ { // changed from high to low,
+ if ( data & 0x20 )
+ {
+ if ( m_global_volume < 31 ) m_global_volume++; //0-31 expressed as 1-32
+ }
+ else
+ {
+ if ( m_global_volume > 0 ) m_global_volume--;
+ }
+
+ {
+ if (m_ym2413)
+ {
+ float percent = (32 - m_global_volume) / 32.0f;
+
+ m_ym2413->set_output_gain(ALL_OUTPUTS, percent);
+ m_upd7759_int->set_output_gain(ALL_OUTPUTS, percent);
+ if( m_aux_upd7759 )
+ {
+ m_aux_upd7759->set_output_gain(ALL_OUTPUTS, percent);
+ }
+ }
+ }
+ }
+ }
+
+ //bits 1 and 2 are for upd7759
+ m_upd7759_int->md_w(0);
+ m_upd7759_int->reset_w(!BIT(data,2));
+ m_upd7759_int->start_w(BIT(data,1));
+}
+
+void bfcobjam_state::upd7759_w(uint8_t data)
+{
+ m_upd7759_int->port_w(data);
+}
+
+WRITE_LINE_MEMBER( bfcobjam_state::upd7759_generate_dreq )
+{
+ if( state )
+ {
+ m_maincpu->set_input_line(Z180_INPUT_LINE_DREQ0, ASSERT_LINE );
+ }
+ else
+ {
+ m_maincpu->set_input_line(Z180_INPUT_LINE_DREQ0, CLEAR_LINE );
+ }
+}
+
+void bfcobjam_state::video_start()
+{
+ memcpy(m_col4bit, col4bit_default, sizeof(m_col4bit));
+ memcpy(m_col3bit, col3bit_default, sizeof(m_col3bit));
+ for (int i = 0; i < 256; ++i)
+ {
+ uint8_t col;
+
+ m_col8bit[i] = i;
+ col = i & 0x7f;
+ col = (col & 0x1f) | (col76index[ ( (col & 0x60) >> 5 ) & 3] << 5);
+ m_col7bit[i] = col;
+
+ col = (col & 3) | (col76index[( (col & 0x0c) >> 2) & 3] << 2 ) |
+ (col76index[( (col & 0x30) >> 4) & 3] << 5 );
+ m_col6bit[i] = col;
+ }
+}
+
+/***************************************************************************
+
+ Cobra II Z8S180 Memory Map
+
+***************************************************************************/
+
+void bfcobjam_state::z8s180_prog_map(address_map &map)
+{
+ map(0x00000, 0x03fff).bankrw("bank4");
+ map(0x04000, 0x07fff).bankrw("bank1");
+ map(0x08000, 0x0bfff).bankrw("bank2");
+ map(0x0c000, 0x0ffff).bankrw("bank3");
+ map(0x10000, 0x1ffff).bankrw("bank5");
+ map(0x20000, 0x3ffff).ram().share(m_video_ram);
+ map(0x40000, 0xfffff).ram().share(m_work_ram);
+}
+
+void bfcobjam_state::z8s180_io_map(address_map &map)
+{
+ map.global_mask(0xff);
+ map(0x00, 0x23).rw(FUNC(bfcobjam_state::chipset_r), FUNC(bfcobjam_state::chipset_w));
+ map(0x24, 0x25).w(m_acia6850_0, FUNC(acia6850_device::write));
+ map(0x26, 0x27).r(m_acia6850_0, FUNC(acia6850_device::read));
+ map(0x2c, 0x2c).w(FUNC(bfcobjam_state::rombank_w));
+ map(0x30, 0x30).w(FUNC(bfcobjam_state::upd7759_w));
+ map(0x50, 0x50).w("ramdac", FUNC(ramdac_device::index_w));
+ map(0x51, 0x51).rw("ramdac", FUNC(ramdac_device::pal_r), FUNC(ramdac_device::pal_w));
+ map(0x52, 0x52).w("ramdac", FUNC(ramdac_device::mask_w));
+ map(0x53, 0x53).w("ramdac", FUNC(ramdac_device::index_r_w));
+ map(0x80, 0x87).r(FUNC(bfcobjam_state::input1_r));
+ map(0x88, 0x8f).r(FUNC(bfcobjam_state::input0_r));
+ map(0x88, 0x8f).w(FUNC(bfcobjam_state::output0_w));
+ map(0x90, 0x97).r(FUNC(bfcobjam_state::aux_upd7759_r));
+ map(0x90, 0x97).w(m_ym2413,FUNC(ym2413_device::write));
+ map(0x98, 0x9f).w(FUNC(bfcobjam_state::aux_upd7759_w));
+}
+
+
+static INPUT_PORTS_START( brkball )
+ PORT_START("CJIN0")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_PLAYER(2) PORT_NAME("P2 FIRE C")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_START1 )
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(2)
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(2)
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_COIN1 )
+
+ PORT_START("CJIN1")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START2 )
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT )
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("P1 Left Flip")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("P1 Right Flip")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+
+ PORT_START("CJIN2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_NAME("P1 Left Flip")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_PLAYER(2) PORT_NAME("P1 Right Flip")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_SERVICE1 )
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_COIN2 )
+
+ PORT_START("CJIN3")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_TILT ) PORT_NAME("TEST") PORT_CODE(KEYCODE_F1)
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+INPUT_PORTS_END
+
+
+void bfcobjam_state::machine_start()
+{
+ membank("bank5")->configure_entries(0, 0x10, memregion("user1")->base(), 0x10000);
+ membank("bank5")->set_entry(1);
+}
+
+void bfcobjam_state::machine_reset()
+{
+ for (unsigned int pal = 0; pal < 256; ++pal)
+ {
+ m_palette->set_pen_color(pal, pal3bit((pal>>5)&7), pal3bit((pal>>2)&7), pal2bit(pal&3));
+ }
+
+ m_rompage = 0 ;
+ m_bank_data[0] = 0;
+ m_bank_data[1] = 0;
+ m_bank_data[2] = 0;
+ m_bank_data[3] = 0;
+
+ m_genio = 0 ;
+ m_global_volume = 0;
+
+ m_ym2413->reset();
+
+
+ m_irq_state = m_blitter_irq = m_scanline_irq = m_acia_irq = 0;
+
+ m_scanline_timer->adjust(m_screen->time_until_pos(0));
+
+ if( m_dm01 )
+ m_dm01->reset() ;
+}
+
+WRITE_LINE_MEMBER(bfcobjam_state::write_acia_clock)
+{
+ m_acia6850_0->write_txc(state);
+ m_acia6850_0->write_rxc(state);
+}
+
+void bfcobjam_state::bfcobjam(machine_config &config)
+{
+ Z8S180(config, m_maincpu, Z8S180_XTAL);
+ m_maincpu->set_addrmap(AS_PROGRAM, &bfcobjam_state::z8s180_prog_map);
+ m_maincpu->set_addrmap(AS_IO, &bfcobjam_state::z8s180_io_map);
+
+ /* TODO */
+ SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
+ m_screen->set_refresh_hz(50);
+ m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
+ m_screen->set_size(512, 256);
+ m_screen->set_visarea_full();
+ m_screen->set_screen_update(FUNC(bfcobjam_state::screen_update_bfcobjam));
+
+ PALETTE(config, m_palette).set_entries(256);
+
+ ramdac_device &ramdac(RAMDAC(config, "ramdac", 0, m_palette)); // MUSIC Semiconductor TR9C1710 RAMDAC or equivalent
+ ramdac.set_addrmap(0, &bfcobjam_state::ramdac_map);
+ ramdac.set_split_read(1);
+
+ SPEAKER(config, "mono").front_center();
+
+ UPD7759(config, m_upd7759_int);
+ m_upd7759_int->add_route(ALL_OUTPUTS, "mono", 0.40);
+ m_upd7759_int->drq().set(FUNC(bfcobjam_state::upd7759_generate_dreq));
+
+ YM2413(config, m_ym2413, XTAL(3'579'545)).add_route(ALL_OUTPUTS, "mono", 1.0);
+
+
+ /* ACIAs */
+ ACIA6850(config, m_acia6850_0, 0);
+ m_acia6850_0->irq_handler().set(FUNC(bfcobjam_state::z8s180_acia_irq));
+
+ clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); // What are the correct ACIA clocks ?
+ acia_clock.signal_handler().set(FUNC(bfcobjam_state::write_acia_clock));
+
+ I2C_24C08(config, m_i2cmem);
+}
+
+void bfcobjam_state::bfcobjam_with_dmd(machine_config &config)
+{
+ bfcobjam( config ) ;
+
+ UPD7759(config, m_aux_upd7759);
+ m_aux_upd7759->add_route(ALL_OUTPUTS, "mono", 0.40);
+
+ BFM_DM01(config, m_dm01, 0);
+}
+
+/***************************************************************************
Game driver(s)
@@ -1846,12 +2971,28 @@ ROM_START( qosb )
ROM_END
+/* The dot matrix software "ledv1.bin" is development software and not the release version.
+ Everything appears to work correctly except there are issues when the machine first starts with the
+ display showing a strange animation.
+*/
+ROM_START( brkball )
+ ROM_REGION( 0x200000, "user1", 0 )
+ ROM_LOAD( "95000352.bin", 0x000000, 0x80000, CRC(8daad60a) SHA1(10ac31b7791c2215d0561972ae63e1405361b908) )
+ ROM_LOAD( "95000353.bin", 0x080000, 0x80000, CRC(8e7b84ed) SHA1(b5e9ffe08eabe1446aa583fb85548451d944e811) )
+
+ ROM_REGION( 0x80000, "upd", 0 )
+ ROM_LOAD( "sounds.bin", 0x00000, 0x80000, CRC(4e84402d) SHA1(f6056669f005d8790331be5b0f34d9441190b120) )
+
+ ROM_REGION( 0x20000, "dm01:matrix", 0 )
+ ROM_LOAD("ledv1.bin", 0x00000, 0x10000, CRC(ea918cb9) SHA1(9e7047613cf1cb4b9a7fefb8a02d8479a7b09e6a))
+ROM_END
-GAME( 1989, inquiztr, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Inquizitor", MACHINE_NOT_WORKING )
-GAME( 1990, escounts, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Every Second Counts (39-360-053)", MACHINE_IMPERFECT_GRAPHICS )
-GAME( 1991, trebltop, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Treble Top (39-360-070)", MACHINE_IMPERFECT_GRAPHICS )
-GAME( 1991, beeline, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Beeline (39-360-075)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS )
-GAME( 1991, quizvadr, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Quizvaders (39-360-078)", MACHINE_IMPERFECT_GRAPHICS )
-GAME( 1992, qos, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "A Question of Sport (set 1, 39-960-107)", MACHINE_IMPERFECT_GRAPHICS )
-GAME( 1992, qosa, qos, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "A Question of Sport (set 2, 39-960-099)", MACHINE_IMPERFECT_GRAPHICS )
-GAME( 1992, qosb, qos, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "A Question of Sport (set 3, 39-960-089)", MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1989, inquiztr, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Inquizitor", MACHINE_NOT_WORKING )
+GAME( 1990, escounts, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Every Second Counts (39-360-053)", MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1991, trebltop, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Treble Top (39-360-070)", MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1991, beeline, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Beeline (39-360-075)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1991, quizvadr, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "Quizvaders (39-360-078)", MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1992, qos, 0, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "A Question of Sport (set 1, 39-960-107)", MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1992, qosa, qos, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "A Question of Sport (set 2, 39-960-099)", MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1992, qosb, qos, bfcobra, bfcobra, bfcobra_state, init_bfcobra, ROT0, "BFM", "A Question of Sport (set 3, 39-960-089)", MACHINE_IMPERFECT_GRAPHICS )
+GAMEL(1994, brkball, 0, bfcobjam_with_dmd,brkball, bfcobjam_state,init_bfcobjam,ROT0, "BFM/ATOD", "Break Ball", MACHINE_IMPERFECT_GRAPHICS, layout_brkball )
diff --git a/src/mame/drivers/casloopy.cpp b/src/mame/drivers/casloopy.cpp
index 81819feafcb..4ade93aa0eb 100644
--- a/src/mame/drivers/casloopy.cpp
+++ b/src/mame/drivers/casloopy.cpp
@@ -81,9 +81,8 @@ Notes:
like a V60. The BIOS is tied directly to it.
RH-7500 - Casio RH-7500 5C315 (QFP208). This is the graphics generator chip.
RH-7501 - Casio RH-7501 5C350 (QFP64). This is probably the sound chip.
- SH7021 - Hitachi HD6437021TE20 SuperH RISC Engine SH-2A CPU with 32k internal maskROM (TQFP100)
- The internal ROM (BIOS1) is not dumped. A SH-2A software programming manual is available here...
- http://documentation.renesas.com/eng/products/mpumcu/rej09b0051_sh2a.pdf
+ SH7021 - Hitachi HD6437021TE20 SuperH RISC Engine SH-1 CPU with 32k internal maskROM (TQFP100)
+ The internal ROM (BIOS1) is not dumped.
CXA1645M - Sony CXA1645M RGB Encoder (RGB -> Composite Video) (SOIC24)
A1603C - NEC uPA1603C Compound Field Effect Power Transistor Array (DIP16)
HM514260 - Hitachi HM514260 256k x 16 DRAM (SOJ40)
@@ -431,7 +430,7 @@ void casloopy_state::casloopy_map(address_map &map)
// map(0x05ffff00, 0x05ffffff).rw(FUNC(casloopy_state::sh7021_r), FUNC(casloopy_state::sh7021_w));
// map(0x05ffff00, 0x05ffffff) - SH7021 internal i/o
map(0x06000000, 0x062fffff).r(m_cart, FUNC(generic_cartslot_device::read32_rom));
- map(0x07000000, 0x070003ff).ram().share("oram");// on-chip RAM, actually at 0xf000000 (1 kb)
+ //map(0x07000000, 0x070003ff).ram();// area 7 (CS7), NOT on-chip RAM mirror
map(0x09000000, 0x0907ffff).ram().share("wram");
map(0x0e000000, 0x0e2fffff).r(m_cart, FUNC(generic_cartslot_device::read32_rom));
map(0x0f000000, 0x0f0003ff).ram().share("oram");
diff --git a/src/mame/drivers/cdi.cpp b/src/mame/drivers/cdi.cpp
index 41da9a40d8f..94e939df12b 100644
--- a/src/mame/drivers/cdi.cpp
+++ b/src/mame/drivers/cdi.cpp
@@ -885,14 +885,14 @@ ROM_END
/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME */
// BIOS / System
-CONS( 1991, cdimono1, 0, 0, cdimono1, cdi, cdi_state, empty_init, "Philips", "CD-i (Mono-I) (PAL)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+CONS( 1991, cdimono1, 0, 0, cdimono1, cdi, cdi_state, empty_init, "Philips", "CD-i (Mono-I) (PAL)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
CONS( 1991, cdimono2, 0, 0, cdimono2, cdimono2, cdi_state, empty_init, "Philips", "CD-i (Mono-II) (NTSC)", MACHINE_NOT_WORKING )
CONS( 1991, cdi910, 0, 0, cdi910, cdimono2, cdi_state, empty_init, "Philips", "CD-i 910-17P Mini-MMC (PAL)", MACHINE_NOT_WORKING )
CONS( 1991, cdi490a, 0, 0, cdimono1, cdi, cdi_state, empty_init, "Philips", "CD-i 490", MACHINE_NOT_WORKING )
// The Quizard games are retail CD-i units in a cabinet, with an additional JAMMA adapter and dongle for protection, hence being clones of the system.
/* YEAR NAME PARENT MACHINE INPUT DEVICE INIT MONITOR COMPANY FULLNAME */
-GAME( 1995, cdibios, 0, cdimono1, quizard, cdi_state, empty_init, ROT0, "Philips", "CD-i (Mono-I) (PAL) BIOS", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IS_BIOS_ROOT )
+GAME( 1995, cdibios, 0, cdimono1, quizard, cdi_state, empty_init, ROT0, "Philips", "CD-i (Mono-I) (PAL) BIOS", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IS_BIOS_ROOT )
GAME( 1995, quizard, cdibios, quizard, quizard, quizard_state, empty_init, ROT0, "TAB Austria", "Quizard (v1.8, German, i8751 DE 11 D3)", MACHINE_IMPERFECT_SOUND )
GAME( 1995, quizard_17, quizard, quizard, quizard, quizard_state, empty_init, ROT0, "TAB Austria", "Quizard (v1.7, German, i8751 DE 11 D3)", MACHINE_IMPERFECT_SOUND )
diff --git a/src/mame/drivers/cinemat.cpp b/src/mame/drivers/cinemat.cpp
index 5a1500b32e7..cdf9babd997 100644
--- a/src/mame/drivers/cinemat.cpp
+++ b/src/mame/drivers/cinemat.cpp
@@ -37,6 +37,7 @@
#include "demon.lh"
#include "starcas.lh"
#include "solarq.lh"
+#include "speedfrk.lh"
#include "sundance.lh"
#include "tailg.lh"
#include "warrior.lh"
@@ -82,15 +83,15 @@ void cinemat_state::machine_reset()
*
*************************************/
-uint8_t cinemat_state::inputs_r(offs_t offset)
+u8 cinemat_state::inputs_r(offs_t offset)
{
return (m_inputs->read() >> offset) & 1;
}
-uint8_t cinemat_state::switches_r(offs_t offset)
+u8 cinemat_state::switches_r(offs_t offset)
{
- static const uint8_t switch_shuffle[8] = { 2,5,4,3,0,1,6,7 };
+ static const u8 switch_shuffle[8] = { 2,5,4,3,0,1,6,7 };
return (m_switches->read() >> switch_shuffle[offset]) & 1;
}
@@ -110,7 +111,7 @@ INPUT_CHANGED_MEMBER(cinemat_state::coin_inserted)
}
-uint8_t cinemat_state::coin_input_r()
+u8 cinemat_state::coin_input_r()
{
return !m_coin_detected;
}
@@ -144,13 +145,13 @@ WRITE_LINE_MEMBER(cinemat_state::mux_select_w)
*
*************************************/
-uint8_t cinemat_state::joystick_read()
+u8 cinemat_state::joystick_read()
{
if (machine().phase() != machine_phase::RUNNING)
return 0;
else
{
- int const xval = int16_t(m_maincpu->state_int(ccpu_cpu_device::CCPU_X) << 4) >> 4;
+ int const xval = s16(m_maincpu->state_int(ccpu_cpu_device::CCPU_X) << 4) >> 4;
return ((m_mux_select ? m_analog_x : m_analog_y).read_safe(0) - xval) < 0x800;
}
}
@@ -163,13 +164,13 @@ uint8_t cinemat_state::joystick_read()
*
*************************************/
-uint8_t cinemat_state::speedfrk_wheel_r(offs_t offset)
+u8 cinemat_state::speedfrk_wheel_r(offs_t offset)
{
- static const uint8_t speedfrk_steer[] = {0xe, 0x6, 0x2, 0x0, 0x3, 0x7, 0xf};
+ static const u8 speedfrk_steer[] = {0xe, 0x6, 0x2, 0x0, 0x3, 0x7, 0xf};
int delta_wheel;
/* the shift register is cleared once per 'frame' */
- delta_wheel = int8_t(m_wheel->read()) / 8;
+ delta_wheel = s8(m_wheel->read()) / 8;
if (delta_wheel > 3)
delta_wheel = 3;
else if (delta_wheel < -3)
@@ -179,23 +180,14 @@ uint8_t cinemat_state::speedfrk_wheel_r(offs_t offset)
}
-uint8_t cinemat_state::speedfrk_gear_r(offs_t offset)
+u8 cinemat_state::speedfrk_gear_r(offs_t offset)
{
- int gearval = m_gear_input->read();
-
- /* check the fake gear input port and determine the bit settings for the gear */
- if ((gearval & 0x0f) != 0x0f)
- m_gear = gearval & 0x0f;
-
- /* add the start key into the mix -- note that it overlaps 4th gear */
- if (!(m_inputs->read() & 0x80))
- m_gear &= ~0x08;
-
- return (m_gear >> offset) & 1;
+ return (m_gear != offset);
}
+
/*************************************
*
* Sundance inputs
@@ -205,7 +197,7 @@ uint8_t cinemat_state::speedfrk_gear_r(offs_t offset)
static const struct
{
const char *portname;
- uint16_t bitmask;
+ u16 bitmask;
} sundance_port_map[16] =
{
{ "PAD1", 0x155 }, /* bit 0 is set if P1 1,3,5,7,9 is pressed */
@@ -230,7 +222,7 @@ static const struct
};
-uint8_t cinemat_16level_state::sundance_inputs_r(offs_t offset)
+u8 cinemat_16level_state::sundance_inputs_r(offs_t offset)
{
/* handle special keys first */
if (sundance_port_map[offset].portname)
@@ -247,7 +239,7 @@ uint8_t cinemat_16level_state::sundance_inputs_r(offs_t offset)
*
*************************************/
-uint8_t cinemat_color_state::boxingb_dial_r(offs_t offset)
+u8 cinemat_color_state::boxingb_dial_r(offs_t offset)
{
int value = ioport("DIAL")->read();
if (!m_mux_select) offset += 4;
@@ -262,7 +254,7 @@ uint8_t cinemat_color_state::boxingb_dial_r(offs_t offset)
*
*************************************/
-uint8_t qb3_state::qb3_frame_r()
+u8 qb3_state::qb3_frame_r()
{
attotime next_update = m_screen->time_until_update();
attotime frame_period = m_screen->frame_period();
@@ -273,7 +265,7 @@ uint8_t qb3_state::qb3_frame_r()
}
-void qb3_state::qb3_ram_bank_w(uint8_t data)
+void qb3_state::qb3_ram_bank_w(u8 data)
{
membank("bank1")->set_entry(m_maincpu->state_int(ccpu_cpu_device::CCPU_P) & 3);
}
@@ -480,10 +472,13 @@ static INPUT_PORTS_START( speedfrk )
PORT_BIT( 0xff, 0x00, IPT_DIAL ) PORT_SENSITIVITY(100) PORT_KEYDELTA(10) PORT_RESET
PORT_START("GEAR")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_NAME("1st gear") PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_NAME("2nd gear") PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_NAME("3rd gear") PORT_PLAYER(2)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_NAME("4th gear") PORT_PLAYER(2)
+ PORT_BIT (0x03, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(cinemat_state, speedfrk_gear_number_r)
+
+ PORT_START("GEARRAW")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("1st gear") PORT_PLAYER(2) PORT_WRITE_LINE_MEMBER(cinemat_state, speedfrk_gear_change_w<0>)
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("2nd gear") PORT_PLAYER(2) PORT_WRITE_LINE_MEMBER(cinemat_state, speedfrk_gear_change_w<1>)
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("3rd gear") PORT_PLAYER(2) PORT_WRITE_LINE_MEMBER(cinemat_state, speedfrk_gear_change_w<2>)
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("4th gear") PORT_PLAYER(2) PORT_WRITE_LINE_MEMBER(cinemat_state, speedfrk_gear_change_w<3>)
INPUT_PORTS_END
@@ -1504,7 +1499,6 @@ ROM_END
void cinemat_state::init_speedfrk()
{
- m_gear = 0xe;
m_maincpu->space(AS_IO).install_read_handler(0x00, 0x03, read8sm_delegate(*this, FUNC(cinemat_state::speedfrk_wheel_r)));
m_maincpu->space(AS_IO).install_read_handler(0x04, 0x06, read8sm_delegate(*this, FUNC(cinemat_state::speedfrk_gear_r)));
save_item(NAME(m_gear));
@@ -1542,7 +1536,7 @@ void qb3_state::init_qb3()
GAME( 1977, spacewar, 0, spacewar, spacewar, cinemat_state, empty_init, ORIENTATION_FLIP_Y, "Cinematronics", "Space Wars", MACHINE_SUPPORTS_SAVE )
GAME( 1978, spaceshp, spacewar, spacewar, spaceshp, cinemat_state, empty_init, ORIENTATION_FLIP_Y, "Cinematronics (Sega license)", "Space Ship", MACHINE_SUPPORTS_SAVE )
GAMEL( 1979, barrier, 0, barrier, barrier, cinemat_state, empty_init, ORIENTATION_FLIP_X ^ ROT270, "Cinematronics (Vectorbeam license)", "Barrier", MACHINE_SUPPORTS_SAVE, layout_barrier ) // developed by Cinematronics, then (when they noticed it wasn't going to be a successful game) sold to Vectorbeam, and ultimately back in the hands of Cinematronics again after they bought the dying company Vectorbeam
-GAME( 1979, speedfrk, 0, speedfrk, speedfrk, cinemat_state, init_speedfrk, ORIENTATION_FLIP_Y, "Vectorbeam", "Speed Freak", MACHINE_SUPPORTS_SAVE )
+GAMEL( 1979, speedfrk, 0, speedfrk, speedfrk, cinemat_state, init_speedfrk, ORIENTATION_FLIP_Y, "Vectorbeam", "Speed Freak", MACHINE_SUPPORTS_SAVE, layout_speedfrk )
GAME( 1979, starhawk, 0, starhawk, starhawk, cinemat_state, empty_init, ORIENTATION_FLIP_Y, "Cinematronics", "Star Hawk", MACHINE_SUPPORTS_SAVE )
GAMEL( 1979, sundance, 0, sundance, sundance, cinemat_16level_state, init_sundance, ORIENTATION_FLIP_X ^ ROT270, "Cinematronics", "Sundance", MACHINE_SUPPORTS_SAVE, layout_sundance )
GAMEL( 1979, tailg, 0, tailg, tailg, cinemat_state, empty_init, ORIENTATION_FLIP_Y, "Cinematronics", "Tailgunner", MACHINE_SUPPORTS_SAVE, layout_tailg )
diff --git a/src/mame/drivers/circus.cpp b/src/mame/drivers/circus.cpp
index bde941740c6..0e9df4e55c6 100644
--- a/src/mame/drivers/circus.cpp
+++ b/src/mame/drivers/circus.cpp
@@ -501,23 +501,27 @@ ROM_END
ROM_START( robotbwl )
ROM_REGION( 0x10000, "maincpu", 0 ) // code
- ROM_LOAD( "robotbwl.1a", 0xf000, 0x0200, CRC(df387a0b) SHA1(97291f1a93cbbff987b0fbc16c2e87ad0db96e12) )
- ROM_LOAD( "robotbwl.2a", 0xf200, 0x0200, CRC(c948274d) SHA1(1bf8c6e994d601d4e6d30ca2a9da97e140ff5eee) )
- ROM_LOAD( "robotbwl.3a", 0xf400, 0x0200, CRC(8fdb3ec5) SHA1(a9290edccb8f75e7ec91416d46617516260d5944) )
- ROM_LOAD( "robotbwl.5a", 0xf600, 0x0200, CRC(ba9a6929) SHA1(9cc6e85431b5d82bf3a624f7b35ddec399ad6c80) )
- ROM_LOAD( "robotbwl.6a", 0xf800, 0x0200, CRC(16fd8480) SHA1(935bb0c87d25086f326571c83f94f831b1a8b036) )
- ROM_LOAD( "robotbwl.7a", 0xfa00, 0x0200, CRC(4cadbf06) SHA1(380c10aa83929bfbfd89facb252e68c307545755) )
- ROM_LOAD( "robotbwl.8a", 0xfc00, 0x0200, CRC(bc809ed3) SHA1(2bb4cdae8c9619eebea30cc323960a46a509bb58) )
- ROM_LOAD( "robotbwl.9a", 0xfe00, 0x0200, CRC(07487e27) SHA1(b5528fb3fec474df2b66f36e28df13a7e81f9ce3) )
+ ROM_LOAD( "4020.1a", 0xf000, 0x0200, CRC(df387a0b) SHA1(97291f1a93cbbff987b0fbc16c2e87ad0db96e12) ) // these are all N82S141N BPROMs
+ ROM_LOAD( "4021.2a", 0xf200, 0x0200, CRC(c948274d) SHA1(1bf8c6e994d601d4e6d30ca2a9da97e140ff5eee) )
+ ROM_LOAD( "4022.3a", 0xf400, 0x0200, CRC(8fdb3ec5) SHA1(a9290edccb8f75e7ec91416d46617516260d5944) )
+ ROM_LOAD( "4023.5a", 0xf600, 0x0200, CRC(ba9a6929) SHA1(9cc6e85431b5d82bf3a624f7b35ddec399ad6c80) )
+ ROM_LOAD( "4024.6a", 0xf800, 0x0200, CRC(16fd8480) SHA1(935bb0c87d25086f326571c83f94f831b1a8b036) )
+ ROM_LOAD( "4025.7a", 0xfa00, 0x0200, CRC(4cadbf06) SHA1(380c10aa83929bfbfd89facb252e68c307545755) )
+ ROM_LOAD( "4026a.8a", 0xfc00, 0x0200, CRC(bc809ed3) SHA1(2bb4cdae8c9619eebea30cc323960a46a509bb58) )
+ ROM_LOAD( "4027b.9a", 0xfe00, 0x0200, CRC(07487e27) SHA1(b5528fb3fec474df2b66f36e28df13a7e81f9ce3) )
ROM_REGION( 0x0800, "gfx1", 0 ) // character set
- ROM_LOAD( "robotbwl.4c", 0x0000, 0x0200, CRC(a5f7acb9) SHA1(556dd34d0fa50415b128477e208e96bf0c050c2c) )
- ROM_LOAD( "robotbwl.3c", 0x0200, 0x0200, CRC(d5380c9b) SHA1(b9670e87011a1b3aebd1d386f1fe6a74f8c77be9) )
- ROM_LOAD( "robotbwl.2c", 0x0400, 0x0200, CRC(47b3e39c) SHA1(393c680fba3bd384e2c773150c3bae4d735a91bf) )
- ROM_LOAD( "robotbwl.1c", 0x0600, 0x0200, CRC(b2991e7e) SHA1(32b6d42bb9312d6cbe5b4113fcf2262bfeef3777) )
+ ROM_LOAD( "4010.4c", 0x0000, 0x0200, CRC(a5f7acb9) SHA1(556dd34d0fa50415b128477e208e96bf0c050c2c) ) // these are all N82S141N BPROMs
+ ROM_LOAD( "4011.3c", 0x0200, 0x0200, CRC(d5380c9b) SHA1(b9670e87011a1b3aebd1d386f1fe6a74f8c77be9) )
+ ROM_LOAD( "4012.2c", 0x0400, 0x0200, CRC(47b3e39c) SHA1(393c680fba3bd384e2c773150c3bae4d735a91bf) )
+ ROM_LOAD( "4013.1c", 0x0600, 0x0200, CRC(b2991e7e) SHA1(32b6d42bb9312d6cbe5b4113fcf2262bfeef3777) )
ROM_REGION( 0x0020, "gfx2", ROMREGION_INVERT ) // ball sprite
- ROM_LOAD( "robotbwl.14d",0x0000, 0x0020, CRC(a402ac06) SHA1(3bd75630786bcc86d9e9fbc826adc909eef9b41f) )
+ ROM_LOAD( "6000.14d",0x0000, 0x0020, CRC(a402ac06) SHA1(3bd75630786bcc86d9e9fbc826adc909eef9b41f) )
+
+ ROM_REGION( 0x100, "extra_proms", 0 ) // timing? not used by the emulation
+ ROM_LOAD( "5000.4d", 0x000, 0x020, NO_DUMP ) // both of these are MMI6306-1J (N82S131 equivalent) BPROMs
+ ROM_LOAD( "5001.5d", 0x020, 0x020, NO_DUMP )
ROM_END
ROM_START( crash )
diff --git a/src/mame/drivers/cit101.cpp b/src/mame/drivers/cit101.cpp
index 7aa8a514439..46fda3d4f4d 100644
--- a/src/mame/drivers/cit101.cpp
+++ b/src/mame/drivers/cit101.cpp
@@ -2,7 +2,7 @@
// copyright-holders:AJR
/***********************************************************************************************************************************
-Preliminary driver for first-generation C. Itoh video terminals.
+Preliminary driver for first-generation C. Itoh/CIE video terminals.
CIT-101 (released December 1980)
C. Itoh's first terminal, based on DEC VT100. ANSI X3.64 and V52 compatible.
@@ -30,6 +30,8 @@ CIT-101e (released 1983)
Ergonomic redesign of CIT-101.
Competitive with DEC VT220 (which was released several months later).
14-inch monochrome screen with tilt/swivel, 24 lines of 80 or 132 characters.
+ 10 x 12 (80 columns)/9 x 12 (132 columns) display cell.
+ 19,610 Hz (80 columns)/18,870 Hz (132 columns) horizontal frequency.
85-key low-profile keyboard.
CIG-201
Plug-in graphics card for CIT-101 and CIT-101e.
@@ -47,7 +49,9 @@ Special SET-UP control codes:
* CTRL+D: Restore default NVR settings
* CTRL+A: Set answerback message
* CTRL+X: Enable/disable Bidirectional Auxiliary I/O Channel and SET-UP D Mode
- (undocumented; SET-UP B Mode only)
+ (SET-UP B Mode only; documented only for CIT-101e but also valid on original)
+
+The NVR checksum error reported when the terminal is first used is nonfatal. Default settings will be used and can be saved.
************************************************************************************************************************************/
@@ -63,27 +67,35 @@ Special SET-UP control codes:
#include "machine/cit101_kbd.h"
-
class cit101_state : public driver_device
{
public:
cit101_state(const machine_config &mconfig, device_type type, const char *tag)
: driver_device(mconfig, type, tag)
+ , m_maincpu(*this, "maincpu")
, m_screen(*this, "screen")
, m_nvr(*this, "nvr")
, m_comuart(*this, "comuart")
, m_kbduart(*this, "kbduart")
+ , m_rombank(*this, "rombank")
, m_chargen(*this, "chargen")
, m_mainram(*this, "mainram")
, m_extraram(*this, "extraram")
- { }
+ {
+ }
void cit101(machine_config &config);
+ void cit101e(machine_config &config);
+
protected:
virtual void machine_start() override;
+
private:
void draw_line(uint32_t *pixptr, int minx, int maxx, int line, bool last_line, u16 rowaddr, u16 rowattr, u8 scrattr);
u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ void screen_reconfigure(const XTAL &xtal, int visible_width, int total_width, int visible_height, int total_height);
+
+ u8 bank_switch_r(offs_t offset);
u8 c000_ram_r(offs_t offset);
void c000_ram_w(offs_t offset, u8 data);
@@ -92,23 +104,29 @@ private:
DECLARE_WRITE_LINE_MEMBER(blink_w);
void screen_control_w(u8 data);
+ void screen_control_101e_w(u8 data);
void brightness_w(u8 data);
+ void brightness_101e_w(u8 data);
void nvr_address_w(u8 data);
void nvr_control_w(u8 data);
void mem_map(address_map &map);
+ void mem_map_101e(address_map &map);
void io_map(address_map &map);
+ void io_map_101e(address_map &map);
u8 m_e0_latch;
bool m_blink;
u8 m_brightness;
+ required_device<i8085a_cpu_device> m_maincpu;
required_device<screen_device> m_screen;
required_device<er2055_device> m_nvr;
required_device<i8251_device> m_comuart;
required_device<i8251_device> m_kbduart;
+ optional_memory_bank m_rombank;
required_region_ptr<u8> m_chargen;
required_shared_ptr<u8> m_mainram;
required_shared_ptr<u8> m_extraram;
@@ -117,6 +135,12 @@ private:
void cit101_state::machine_start()
{
+ if (m_rombank.found())
+ {
+ m_rombank->configure_entries(0, 8, memregion("banked")->base(), 0x1000);
+ m_rombank->set_entry(0);
+ }
+
m_comuart->write_cts(0);
m_kbduart->write_cts(0);
@@ -217,6 +241,24 @@ u32 cit101_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, con
}
+void cit101_state::screen_reconfigure(const XTAL &xtal, int visible_width, int total_width, int visible_height, int total_height)
+{
+ const rectangle visarea(0, visible_width - 1, 0, visible_height - 1);
+ const attoseconds_t frame_period = attotime::from_ticks(total_width * total_height, xtal).as_attoseconds();
+
+ m_screen->set_unscaled_clock(xtal);
+ m_screen->configure(total_width, total_height, visarea, frame_period);
+}
+
+
+u8 cit101_state::bank_switch_r(offs_t offset)
+{
+ if (!machine().side_effects_disabled())
+ m_rombank->set_entry(offset);
+
+ return 0xc9; // RET
+}
+
u8 cit101_state::c000_ram_r(offs_t offset)
{
if (!machine().side_effects_disabled())
@@ -250,19 +292,25 @@ void cit101_state::screen_control_w(u8 data)
if ((m_extraram[0] & 0x06) != (data & 0x06))
{
const int height = BIT(data, 2) ? 312 : 260;
- const attoseconds_t frame_period = HZ_TO_ATTOSECONDS(BIT(data, 2) ? 50 : 60);
if (BIT(data, 1))
- {
- const rectangle visarea(0, 799, 0, 239);
- m_screen->set_unscaled_clock(14.976_MHz_XTAL);
- m_screen->configure(960, height, visarea, frame_period);
- }
+ screen_reconfigure(14.976_MHz_XTAL, 800, 960, 240, height);
else
- {
- const rectangle visarea(0, 1187, 0, 239);
- m_screen->set_unscaled_clock(22.464_MHz_XTAL);
- m_screen->configure(1440, height, visarea, frame_period);
- }
+ screen_reconfigure(22.464_MHz_XTAL, 1188, 1440, 240, height);
+ }
+
+ m_extraram[0] = data;
+}
+
+void cit101_state::screen_control_101e_w(u8 data)
+{
+ if ((m_extraram[0] & 0x06) != (data & 0x06))
+ {
+ // TODO: interlace mode
+ const int height = 300;
+ if (BIT(data, 1))
+ screen_reconfigure(19.6608_MHz_XTAL, 800, 1000, 288, height);
+ else
+ screen_reconfigure(27.956_MHz_XTAL, 1188, 1476, 288, height);
}
m_extraram[0] = data;
@@ -274,6 +322,12 @@ void cit101_state::brightness_w(u8 data)
m_brightness = pal5bit(~data & 0x1f);
}
+void cit101_state::brightness_101e_w(u8 data)
+{
+ // Function of most significant bit is unknown
+ m_brightness = pal7bit(~data & 0x7f);
+}
+
void cit101_state::nvr_address_w(u8 data)
{
m_nvr->set_address(data & 0x3f);
@@ -300,6 +354,23 @@ void cit101_state::mem_map(address_map &map)
map(0xfcc0, 0xfcc3).w("pit1", FUNC(pit8253_device::write));
}
+void cit101_state::mem_map_101e(address_map &map)
+{
+ map(0x0000, 0x2fff).rom().region("maincpu", 0);
+ map(0x3000, 0x3ff7).bankr("rombank");
+ map(0x3ff8, 0x3fff).r(FUNC(cit101_state::bank_switch_r));
+ map(0x4000, 0x7fff).ram().share("mainram");
+ map(0x8000, 0xbfff).ram().share("extraram"); // 6 bits wide here?
+ map(0x8000, 0x8000).w(FUNC(cit101_state::screen_control_101e_w));
+ map(0xc000, 0xfbff).rw(FUNC(cit101_state::c000_ram_r), FUNC(cit101_state::c000_ram_w));
+ map(0xfc00, 0xfc01).rw("auxuart", FUNC(i8251_device::read), FUNC(i8251_device::write));
+ map(0xfc20, 0xfc21).rw("comuart", FUNC(i8251_device::read), FUNC(i8251_device::write));
+ map(0xfc40, 0xfc41).rw("kbduart", FUNC(i8251_device::read), FUNC(i8251_device::write));
+ map(0xfc60, 0xfc63).rw("ppi", FUNC(i8255_device::read), FUNC(i8255_device::write));
+ map(0xfc80, 0xfc83).w("pit0", FUNC(pit8253_device::write));
+ map(0xfcc0, 0xfcc3).w("pit1", FUNC(pit8253_device::write));
+}
+
void cit101_state::io_map(address_map &map)
{
map(0x00, 0x01).rw("auxuart", FUNC(i8251_device::read), FUNC(i8251_device::write));
@@ -310,18 +381,24 @@ void cit101_state::io_map(address_map &map)
map(0xe0, 0xe0).rw(FUNC(cit101_state::e0_latch_r), FUNC(cit101_state::e0_latch_w));
}
+void cit101_state::io_map_101e(address_map &map)
+{
+ io_map(map);
+ map(0xa0, 0xa0).w(FUNC(cit101_state::brightness_101e_w));
+}
+
-static INPUT_PORTS_START( cit101 )
+static INPUT_PORTS_START(cit101)
INPUT_PORTS_END
void cit101_state::cit101(machine_config &config)
{
- i8085a_cpu_device &maincpu(I8085A(config, "maincpu", 6.144_MHz_XTAL));
- maincpu.set_addrmap(AS_PROGRAM, &cit101_state::mem_map);
- maincpu.set_addrmap(AS_IO, &cit101_state::io_map);
- maincpu.in_sid_func().set_constant(0); // used to time NVR reads
- maincpu.out_sod_func().set(FUNC(cit101_state::blink_w));
+ I8085A(config, m_maincpu, 6.144_MHz_XTAL);
+ m_maincpu->set_addrmap(AS_PROGRAM, &cit101_state::mem_map);
+ m_maincpu->set_addrmap(AS_IO, &cit101_state::io_map);
+ m_maincpu->in_sid_func().set_constant(0); // used to time NVR reads
+ m_maincpu->out_sod_func().set(FUNC(cit101_state::blink_w));
SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
//m_screen->set_raw(14.976_MHz_XTAL, 960, 0, 800, 260, 0, 240);
@@ -354,10 +431,10 @@ void cit101_state::cit101(machine_config &config)
INPUT_MERGER_ANY_HIGH(config, "uartint").output_handler().set_inputline("maincpu", I8085_RST55_LINE);
I8251(config, m_kbduart, 6.144_MHz_XTAL / 2);
- m_kbduart->txd_handler().set("keyboard", FUNC(cit101_hle_keyboard_device::write_rxd));
+ m_kbduart->txd_handler().set("keyboard", FUNC(cit101_keyboard_device::write_rxd));
m_kbduart->rxrdy_handler().set_inputline("maincpu", I8085_RST65_LINE);
- CIT101_HLE_KEYBOARD(config, "keyboard").txd_callback().set("kbduart", FUNC(i8251_device::write_rxd));
+ CIT101_KEYBOARD(config, "keyboard").txd_callback().set("kbduart", FUNC(i8251_device::write_rxd));
pit8253_device &pit0(PIT8253(config, "pit0", 0));
pit0.set_clk<0>(6.144_MHz_XTAL / 4);
@@ -390,29 +467,69 @@ void cit101_state::cit101(machine_config &config)
ER2055(config, m_nvr);
}
+void cit101_state::cit101e(machine_config &config)
+{
+ cit101(config);
+
+ m_maincpu->set_addrmap(AS_PROGRAM, &cit101_state::mem_map_101e);
+ m_maincpu->set_addrmap(AS_IO, &cit101_state::io_map_101e);
+
+ //m_screen->set_raw(19.6608_MHz_XTAL, 1000, 0, 800, 300, 0, 288); // 65.3 Hz nominal vertical frequency
+ m_screen->set_raw(27.956_MHz_XTAL, 1476, 0, 1188, 300, 0, 288); // 63.2 Hz nominal vertical frequency
+
+ CIT101E_KEYBOARD(config.replace(), "keyboard").txd_callback().set("kbduart", FUNC(i8251_device::write_rxd));
+}
+
// PCB ID: HAV-2P005B / CIT-101 / C. ITOH
// CPU: NEC D8085AC
// RAM: 12x NEC D416C-2 (16 positions labeled 8116E, including 4 unpopulated ones)
// Peripherals: 3x M5L8251AP-5 (2M, 7J, 7K); 2x NEC D8253C-2 (7I, 7L); NEC D8255AC-2 (7N); GI ER-2055 (8P)
// Oscillators: 6.144 (XTAL1), 14.976 (XTAL2), 22.464 (XTAL3)
-ROM_START( cit101 )
+ROM_START(cit101)
ROM_REGION(0x4000, "maincpu", 0)
- ROM_LOAD( "ic1_=3g04=_v10a.bin", 0x0000, 0x1000, CRC(5601fcac) SHA1(cad0d0335d133dd43993bc718ff72d12b8445cd1) ) // TMM2732D-45
- ROM_LOAD( "ic2_=3h04=_v10a.bin", 0x1000, 0x1000, CRC(23d263e0) SHA1(586e8185f9804987e0a4081724c060e74769d41d) ) // TMM2732D-45
- ROM_LOAD( "ic3_=3i04=_v10a.bin", 0x2000, 0x1000, CRC(15994b1d) SHA1(6d125db4ef5e1dd4d5a4d2f4d6f6bdf574e5bad8) ) // TMM2732D-45
- ROM_LOAD( "ic4_=3j04=_v10a.bin", 0x3000, 0x0800, CRC(d786995f) SHA1(943b521dcc7abc0662d6e136169b7db480ae1e5c) ) // MB8516
+ ROM_LOAD("ic1_=3g04=_v10a.bin", 0x0000, 0x1000, CRC(5601fcac) SHA1(cad0d0335d133dd43993bc718ff72d12b8445cd1)) // TMM2732D-45
+ ROM_LOAD("ic2_=3h04=_v10a.bin", 0x1000, 0x1000, CRC(23d263e0) SHA1(586e8185f9804987e0a4081724c060e74769d41d)) // TMM2732D-45
+ ROM_LOAD("ic3_=3i04=_v10a.bin", 0x2000, 0x1000, CRC(15994b1d) SHA1(6d125db4ef5e1dd4d5a4d2f4d6f6bdf574e5bad8)) // TMM2732D-45
+ ROM_LOAD("ic4_=3j04=_v10a.bin", 0x3000, 0x0800, CRC(d786995f) SHA1(943b521dcc7abc0662d6e136169b7db480ae1e5c)) // MB8516
ROM_RELOAD(0x3800, 0x0800)
ROM_REGION(0x1000, "chargen", 0)
- ROM_LOAD( "1h =5h 1 02= char rom.bin", 0x0000, 0x1000, CRC(ee0ff889) SHA1(a74ada19d19041b29e1b49aaf57ba7d9d54575e1) ) // TMM2332P
+ ROM_LOAD("1h =5h 1 02= char rom.bin", 0x0000, 0x1000, CRC(ee0ff889) SHA1(a74ada19d19041b29e1b49aaf57ba7d9d54575e1)) // TMM2332P
ROM_REGION(0x180, "proms", 0)
- ROM_LOAD( "2i_=3a00=.bin", 0x000, 0x100, NO_DUMP ) // position labeled (MB)7052
- ROM_LOAD( "2f_=6g00=.bin", 0x100, 0x020, NO_DUMP ) // position labeled TBP18S030
- ROM_LOAD( "2e_=7i00=.bin", 0x120, 0x020, NO_DUMP ) // position labeled TBP18S030
- ROM_LOAD( "5d_=4l00=.bin", 0x140, 0x020, NO_DUMP ) // position labeled TBP18S030
- ROM_LOAD( "5g_=7f00=.bin", 0x160, 0x020, NO_DUMP ) // position labeled TBP18S030
+ ROM_LOAD("2i_=3a00=.bin", 0x000, 0x100, NO_DUMP) // position labeled (MB)7052
+ ROM_LOAD("2f_=6g00=.bin", 0x100, 0x020, NO_DUMP) // position labeled TBP18S030
+ ROM_LOAD("2e_=7i00=.bin", 0x120, 0x020, NO_DUMP) // position labeled TBP18S030
+ ROM_LOAD("5d_=4l00=.bin", 0x140, 0x020, NO_DUMP) // position labeled TBP18S030
+ ROM_LOAD("5g_=7f00=.bin", 0x160, 0x020, NO_DUMP) // position labeled TBP18S030
+ROM_END
+
+// PCB ID: C.ITOH CIT-101e HBG-2P002
+// CPU: NEC D8085AHC
+// RAM: 14x Fujitsu MB8118-12 (16 positions labeled 8118, including 2 unpopulated ones)
+// Peripherals: 3x NEC D8251AFC (7M, 7N, 7R); 2x NEC D8253C-2 (7J, 7K); NEC D8255AC-2 (6N); GI ER-2055 (5R)
+// Oscillators: 19.6608 (XTAL1), 27.956 (XTAL2), 6.144 (XTAL3)
+ROM_START(cit101e)
+ ROM_REGION(0x3000, "maincpu", 0)
+ ROM_LOAD("101e_v12c__12.7a", 0x0000, 0x2000, CRC(bc71ad27) SHA1(e61481752e20b115531b76688242691d265853e7))
+ ROM_LOAD("101e_v12c__3.7c", 0x2000, 0x1000, CRC(b4c63dd1) SHA1(aff9bd8e79e83c176c882fa3251a1419a283e753))
+
+ ROM_REGION(0x8000, "banked", ROMREGION_ERASEFF)
+ ROM_LOAD("101e_v12c__ab.7f", 0x0000, 0x2000, CRC(6d6bc1ee) SHA1(f42596b379bfda0468045d9e3810a1f0990f76f6))
+
+ ROM_REGION(0x1000, "chargen", 0)
+ ROM_LOAD("cit-101e_char_gen.3g", 0x0000, 0x1000, CRC(ccf259b4) SHA1(d918f16ce148c813a865280a43a766983673464a)) // position labeled 2732/2332
+
+ ROM_REGION(0x1c0, "proms", 0)
+ ROM_LOAD("2c=atr=__.bin", 0x000, 0x100, NO_DUMP) // position labeled MB7052
+ ROM_LOAD("6j=adr=00.bin", 0x100, 0x020, NO_DUMP) // position labeled (TBP)18S030
+ ROM_LOAD("1n=hs=00.bin", 0x120, 0x020, NO_DUMP) // position labeled (TBP)18S030
+ ROM_LOAD("2n=hl=__.bin", 0x140, 0x020, NO_DUMP) // position labeled (TBP)18S030
+ ROM_LOAD("1s=vs=__.bin", 0x160, 0x020, NO_DUMP) // position labeled (TBP)18S030
+ ROM_LOAD("4s=it1=__.bin", 0x180, 0x020, NO_DUMP) // position labeled (TBP)18S030
+ ROM_LOAD("4t=it2=06.bin", 0x1a0, 0x020, NO_DUMP) // position labeled (TBP)18S030
ROM_END
-COMP( 1980, cit101, 0, 0, cit101, cit101, cit101_state, empty_init, "C. Itoh Electronics", "CIT-101", MACHINE_NOT_WORKING )
+COMP(1980, cit101, 0, 0, cit101, cit101, cit101_state, empty_init, "C. Itoh Electronics", "CIT-101 Video Terminal", MACHINE_NOT_WORKING)
+COMP(1983, cit101e, 0, 0, cit101e, cit101, cit101_state, empty_init, "C. Itoh Electronics", "CIT-101e Video Terminal", MACHINE_NOT_WORKING)
diff --git a/src/mame/drivers/cit101xl.cpp b/src/mame/drivers/cit101xl.cpp
new file mode 100644
index 00000000000..ccb56d6bb82
--- /dev/null
+++ b/src/mame/drivers/cit101xl.cpp
@@ -0,0 +1,112 @@
+// license:BSD-3-Clause
+// copyright-holders:AJR
+/***********************************************************************************************************************************
+
+Skeleton driver for CIE Terminals (C. Itoh) CIT-50+ and CIT-101XL video terminals.
+
+***********************************************************************************************************************************/
+
+#include "emu.h"
+//#include "bus/rs232/rs232.h"
+#include "cpu/z180/z180.h"
+#include "machine/nvram.h"
+#include "video/scn2674.h"
+#include "screen.h"
+
+class cit101xl_state : public driver_device
+{
+public:
+ cit101xl_state(const machine_config &mconfig, device_type type, const char *tag)
+ : driver_device(mconfig, type, tag)
+ , m_maincpu(*this, "maincpu")
+ , m_avdc(*this, "avdc")
+ {
+ }
+
+ void cit101xl(machine_config &config);
+
+private:
+ SCN2674_DRAW_CHARACTER_MEMBER(draw_character);
+
+ void mem_map(address_map &map);
+ void io_map(address_map &map);
+ void char_map(address_map &map);
+ void attr_map(address_map &map);
+
+ required_device<z180_device> m_maincpu;
+ required_device<scn2674_device> m_avdc;
+};
+
+
+SCN2674_DRAW_CHARACTER_MEMBER(cit101xl_state::draw_character)
+{
+}
+
+
+void cit101xl_state::mem_map(address_map &map)
+{
+ map(0x00000, 0x07fff).rom().region("program", 0);
+ map(0x1c000, 0x1ffff).rom().region("program", 0x8000);
+ map(0x2e000, 0x2ffff).ram().share("nvram");
+}
+
+void cit101xl_state::io_map(address_map &map)
+{
+ map.global_mask(0xff);
+ map(0x00, 0x3f).noprw(); // HD64180 internal registers
+ map(0x40, 0x47).rw(m_avdc, FUNC(scn2674_device::read), FUNC(scn2674_device::write));
+ map(0x48, 0x48).nopr(); // watchdog?
+ map(0x60, 0x60).w(m_avdc, FUNC(scn2674_device::buffer_w));
+ map(0x68, 0x68).r(m_avdc, FUNC(scn2674_device::buffer_r));
+ map(0x70, 0x70).w(m_avdc, FUNC(scn2674_device::attr_buffer_w));
+ map(0x78, 0x78).r(m_avdc, FUNC(scn2674_device::attr_buffer_r));
+}
+
+void cit101xl_state::char_map(address_map &map)
+{
+ map(0x0000, 0x3fff).ram(); // TMM2063P-12 x2
+}
+
+void cit101xl_state::attr_map(address_map &map)
+{
+ map(0x0000, 0x3fff).ram(); // TMM2063P-12 x2
+}
+
+
+static INPUT_PORTS_START(cit101xl)
+INPUT_PORTS_END
+
+
+void cit101xl_state::cit101xl(machine_config &config)
+{
+ HD64180RP(config, m_maincpu, 12.288_MHz_XTAL); // HD64B180R0P
+ m_maincpu->set_addrmap(AS_PROGRAM, &cit101xl_state::mem_map);
+ m_maincpu->set_addrmap(AS_IO, &cit101xl_state::io_map);
+
+ NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0); // TC5564APL-15 + battery?
+
+ screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
+ screen.set_raw(24.27_MHz_XTAL, 980, 0, 820, 413, 0, 364);
+ screen.set_screen_update(m_avdc, FUNC(scn2674_device::screen_update));
+
+ SCN2674(config, m_avdc, 24.27_MHz_XTAL / 10); // SCN2674BC4N40
+ //m_avdc->intr_callback().set_inputline(m_maincpu, ???);
+ m_avdc->set_character_width(10); // 10x13 character cell
+ m_avdc->set_display_callback(FUNC(cit101xl_state::draw_character));
+ m_avdc->set_addrmap(0, &cit101xl_state::char_map);
+ m_avdc->set_addrmap(1, &cit101xl_state::attr_map);
+ m_avdc->set_screen("screen");
+}
+
+// XTAL OSCs: 12.288 MHz (CPU), 24.270 MHz, 36.000 MHz
+// Gate arrays: HG61H09R84F (QFP80), L7A0084 4155P 00416A (LCC68)
+ROM_START(cit101xl)
+ ROM_REGION(0xc000, "program", 0)
+ ROM_LOAD("cit50p-101xl_v.1.1_0800.u2", 0x0000, 0x8000, CRC(2dbbd7f6) SHA1(f87b32e803bda5a8dd0e39e2e339357cfa4082ad)) // HN27256G-25 with handwritten label
+ ROM_LOAD("cit50p-101xl_v.1.1_8456.u4", 0x8000, 0x4000, CRC(4df0b677) SHA1(1916c65935c47cb0e11a8c7f293b608e648c542b)) // M5L27128K with handwritten label
+
+ ROM_REGION(0x2000, "chargen", 0)
+ ROM_LOAD("tmm2464ap_1104_cit50p_v1.2.u3", 0x0000, 0x2000, CRC(e07723f7) SHA1(466d69382cc75ac0abcda08e1a227da73fc77980)) // Toshiba OTP ROM with silkscreened label
+ROM_END
+
+COMP(1987, cit101xl, 0, 0, cit101xl, cit101xl, cit101xl_state, empty_init, "CIE Terminals", "CIT-101XL Video Display Terminal", MACHINE_IS_SKELETON)
diff --git a/src/mame/drivers/cking_master.cpp b/src/mame/drivers/cking_master.cpp
index 0769b55fc8f..c5f580105ef 100644
--- a/src/mame/drivers/cking_master.cpp
+++ b/src/mame/drivers/cking_master.cpp
@@ -4,6 +4,7 @@
/******************************************************************************
Chess King Master (yes, it's plainly named "Master")
+According to the manual, the chess engine is Cyrus (by Richard Lang).
Hardware notes:
- Z80 CPU(NEC D780C-1) @ 4MHz(8MHz XTAL), IRQ from 555 timer
@@ -80,13 +81,12 @@ private:
u8 input_r();
void control_w(u8 data);
- u16 m_inp_mux;
+ u16 m_inp_mux = 0;
};
void master_state::machine_start()
{
- // zerofill, register for savestates
- m_inp_mux = 0;
+ // register for savestates
save_item(NAME(m_inp_mux));
}
@@ -225,14 +225,14 @@ void master_state::master(machine_config &config)
m_maincpu->set_addrmap(AS_PROGRAM, &master_state::main_trampoline);
ADDRESS_MAP_BANK(config, "mainmap").set_map(&master_state::main_map).set_options(ENDIANNESS_LITTLE, 8, 16);
- const attotime irq_period = attotime::from_hz(429); // theoretical frequency from 555 timer (22nF, 150K, 1K5), measurement was 418Hz
+ const attotime irq_period = attotime::from_hz(418); // 555 timer (22nF, 150K, 1K5), measured 418Hz
TIMER(config, m_irq_on).configure_periodic(FUNC(master_state::irq_on<INPUT_LINE_IRQ0>), irq_period);
m_irq_on->set_start_delay(irq_period - attotime::from_nsec(22870)); // active for 22.87us
TIMER(config, "irq_off").configure_periodic(FUNC(master_state::irq_off<INPUT_LINE_IRQ0>), irq_period);
SENSORBOARD(config, m_board).set_type(sensorboard_device::BUTTONS);
m_board->init_cb().set(m_board, FUNC(sensorboard_device::preset_chess));
- m_board->set_delay(attotime::from_msec(100));
+ m_board->set_delay(attotime::from_msec(150));
/* video hardware */
PWM_DISPLAY(config, m_display).set_size(9, 2);
@@ -254,7 +254,7 @@ void master_state::master(machine_config &config)
ROM_START( ckmaster )
ROM_REGION( 0x10000, "maincpu", 0 )
- ROM_LOAD("ckmaster.ic2", 0x0000, 0x2000, CRC(59cbec9e) SHA1(2e0629e65778da62bed857406b91a334698d2fe8) ) // D2764C, no label
+ ROM_LOAD("d2764c-3.ic2", 0x0000, 0x2000, CRC(59cbec9e) SHA1(2e0629e65778da62bed857406b91a334698d2fe8) ) // no custom label
ROM_END
} // anonymous namespace
diff --git a/src/mame/drivers/cxg_ch2001.cpp b/src/mame/drivers/cxg_ch2001.cpp
index 9d28ce1eed2..be9b15e54ed 100644
--- a/src/mame/drivers/cxg_ch2001.cpp
+++ b/src/mame/drivers/cxg_ch2001.cpp
@@ -3,7 +3,8 @@
// thanks-to:Berger
/******************************************************************************
-CXG Chess 2001, also sold by Hanimex as HCG 1900 and by CGL as Computachess Champion.
+CXG Chess 2001, also sold by Hanimex as Computachess (model HCG 1900),
+and by CGL as Computachess Champion.
CXG Chess 3000 is assumed to be on similar hardware as this.
The chess engine is by Richard Lang, based on Cyrus.
@@ -74,16 +75,12 @@ private:
void leds_w(u8 data);
u8 input_r();
- u16 m_inp_mux;
- int m_dac_data;
+ u16 m_inp_mux = 0;
+ int m_dac_data = 0;
};
void ch2001_state::machine_start()
{
- // zerofill
- m_inp_mux = 0;
- m_dac_data = 0;
-
// register for savestates
save_item(NAME(m_inp_mux));
save_item(NAME(m_dac_data));
@@ -188,7 +185,7 @@ void ch2001_state::ch2001(machine_config &config)
Z80(config, m_maincpu, 8_MHz_XTAL/2);
m_maincpu->set_addrmap(AS_PROGRAM, &ch2001_state::main_map);
- const attotime irq_period = attotime::from_hz(533); // theoretical frequency from 555 timer (20nF, 100K+33K, 1K2), measurement was 568Hz
+ const attotime irq_period = attotime::from_hz(568); // 555 timer (20nF, 100K+33K, 1K2), measured 568Hz
TIMER(config, m_irq_on).configure_periodic(FUNC(ch2001_state::irq_on<INPUT_LINE_IRQ0>), irq_period);
m_irq_on->set_start_delay(irq_period - attotime::from_nsec(16600)); // active for 16.6us
TIMER(config, "irq_off").configure_periodic(FUNC(ch2001_state::irq_off<INPUT_LINE_IRQ0>), irq_period);
diff --git a/src/mame/drivers/dai.cpp b/src/mame/drivers/dai.cpp
index 7bc2af9a8e2..5cc6d97261f 100644
--- a/src/mame/drivers/dai.cpp
+++ b/src/mame/drivers/dai.cpp
@@ -63,26 +63,21 @@ Timings:
#include "emu.h"
#include "includes/dai.h"
#include "screen.h"
-#include "softlist.h"
#include "speaker.h"
-/* I/O ports */
-void dai_state::dai_io(address_map &map)
-{
-}
/* memory w/r functions */
-void dai_state::dai_mem(address_map &map)
+void dai_state::mem_map(address_map &map)
{
- map(0x0000, 0xbfff).bankrw("bank1");
- map(0xc000, 0xdfff).rom();
+ map(0x0000, 0xbfff).ram().share("mainram");
+ map(0xc000, 0xdfff).rom().region("maincpu",0);
map(0xe000, 0xefff).bankr("bank2");
- map(0xf000, 0xf7ff).w(FUNC(dai_state::dai_stack_interrupt_circuit_w));
+ map(0xf000, 0xf7ff).w(FUNC(dai_state::stack_interrupt_circuit_w));
map(0xf800, 0xf8ff).ram();
- map(0xfb00, 0xfbff).rw(FUNC(dai_state::dai_amd9511_r), FUNC(dai_state::dai_amd9511_w));
- map(0xfc00, 0xfcff).rw(FUNC(dai_state::dai_pit_r), FUNC(dai_state::dai_pit_w)); // .rw("pit8253", FUNC(pit8253_device::read), FUNC(pit8253_device::write));
- map(0xfd00, 0xfdff).rw(FUNC(dai_state::dai_io_discrete_devices_r), FUNC(dai_state::dai_io_discrete_devices_w));
- map(0xfe00, 0xfeff).rw("ppi8255", FUNC(i8255_device::read), FUNC(i8255_device::write));
+ map(0xfb00, 0xfbff).rw(FUNC(dai_state::amd9511_r), FUNC(dai_state::amd9511_w));
+ map(0xfc00, 0xfcff).rw(FUNC(dai_state::pit_r), FUNC(dai_state::pit_w)); // .rw(m_pit, FUNC(pit8253_device::read), FUNC(pit8253_device::write));
+ map(0xfd00, 0xfdff).rw(FUNC(dai_state::io_discrete_devices_r), FUNC(dai_state::io_discrete_devices_w));
+ map(0xfe00, 0xfeff).rw("ppi", FUNC(i8255_device::read), FUNC(i8255_device::write));
map(0xff00, 0xff0f).mirror(0xf0).m(m_tms5501, FUNC(tms5501_device::io_map));
}
@@ -183,7 +178,7 @@ static const gfx_layout dai_charlayout =
};
static GFXDECODE_START( gfx_dai )
- GFXDECODE_ENTRY( "gfx1", 0x0000, dai_charlayout, 0, 8 )
+ GFXDECODE_ENTRY( "chargen", 0x0000, dai_charlayout, 0, 8 )
GFXDECODE_END
/* machine definition */
@@ -191,8 +186,7 @@ void dai_state::dai(machine_config &config)
{
/* basic machine hardware */
I8080(config, m_maincpu, 2000000);
- m_maincpu->set_addrmap(AS_PROGRAM, &dai_state::dai_mem);
- m_maincpu->set_addrmap(AS_IO, &dai_state::dai_io);
+ m_maincpu->set_addrmap(AS_PROGRAM, &dai_state::mem_map);
m_maincpu->set_irq_acknowledge_callback(FUNC(dai_state::int_ack));
config.set_maximum_quantum(attotime::from_hz(60));
@@ -204,7 +198,7 @@ void dai_state::dai(machine_config &config)
m_pit->set_clk<2>(2000000);
m_pit->out_handler<2>().set(m_sound, FUNC(dai_sound_device::set_input_ch2));
- I8255(config, "ppi8255");
+ I8255(config, "ppi");
/* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
@@ -212,7 +206,7 @@ void dai_state::dai(machine_config &config)
screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
screen.set_size(1056, 542);
screen.set_visarea(0, 1056-1, 0, 302-1);
- screen.set_screen_update(FUNC(dai_state::screen_update_dai));
+ screen.set_screen_update(FUNC(dai_state::screen_update));
screen.set_palette(m_palette);
GFXDECODE(config, "gfxdecode", m_palette, gfx_dai);
@@ -234,11 +228,8 @@ void dai_state::dai(machine_config &config)
/* tms5501 */
TMS5501(config, m_tms5501, 2000000);
m_tms5501->int_callback().set_inputline("maincpu", I8085_INTR_LINE);
- m_tms5501->xi_callback().set(FUNC(dai_state::dai_keyboard_r));
- m_tms5501->xo_callback().set(FUNC(dai_state::dai_keyboard_w));
-
- /* internal ram */
- RAM(config, RAM_TAG).set_default_size("48K");
+ m_tms5501->xi_callback().set(FUNC(dai_state::keyboard_r));
+ m_tms5501->xo_callback().set(FUNC(dai_state::keyboard_w));
/* software lists */
SOFTWARE_LIST(config, "cass_list").set_original("dai_cass");
@@ -246,15 +237,16 @@ void dai_state::dai(machine_config &config)
ROM_START(dai)
- ROM_REGION(0x14000,"maincpu",0)
- ROM_LOAD("dai.bin", 0xc000, 0x2000, CRC(ca71a7d5) SHA1(6bbe2336c717354beab2ae201debeb4fd055bdcb))
- ROM_LOAD("dai00.bin", 0x10000, 0x1000, CRC(fa7d39ac) SHA1(3d1824a1f273882f934249ef3cb1b38ef99de7b9))
- ROM_LOAD("dai01.bin", 0x11000, 0x1000, CRC(cb5809f2) SHA1(523656f0a9d98888cd3e2bd66886c589e9ae75b4))
- ROM_LOAD("dai02.bin", 0x12000, 0x1000, CRC(03f72d4a) SHA1(573d65dc82321970dcaf81d7638a02252ea18a7a))
- ROM_LOAD("dai03.bin", 0x13000, 0x1000, CRC(c475c96f) SHA1(96fc3cc4b8a2873f0d044bd8033d1e7b7197dd97))
- ROM_REGION(0x2000, "gfx1",0)
+ ROM_REGION(0x6000,"maincpu",0)
+ ROM_LOAD("dai.bin", 0x0000, 0x2000, CRC(ca71a7d5) SHA1(6bbe2336c717354beab2ae201debeb4fd055bdcb))
+ ROM_LOAD("dai00.bin", 0x2000, 0x1000, CRC(fa7d39ac) SHA1(3d1824a1f273882f934249ef3cb1b38ef99de7b9))
+ ROM_LOAD("dai01.bin", 0x3000, 0x1000, CRC(cb5809f2) SHA1(523656f0a9d98888cd3e2bd66886c589e9ae75b4))
+ ROM_LOAD("dai02.bin", 0x4000, 0x1000, CRC(03f72d4a) SHA1(573d65dc82321970dcaf81d7638a02252ea18a7a))
+ ROM_LOAD("dai03.bin", 0x5000, 0x1000, CRC(c475c96f) SHA1(96fc3cc4b8a2873f0d044bd8033d1e7b7197dd97))
+
+ ROM_REGION(0x2000, "chargen",0)
ROM_LOAD ("nch.bin", 0x0000, 0x1000, CRC(a9f5b30b) SHA1(24119b2984ab4e50dc0dabae1065ff6d6c1f237d))
ROM_END
/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME */
-COMP( 1978, dai, 0, 0, dai, dai, dai_state, empty_init, "Data Applications International", "DAI Personal Computer", 0)
+COMP( 1978, dai, 0, 0, dai, dai, dai_state, empty_init, "Data Applications International", "DAI Personal Computer", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/dblewing.cpp b/src/mame/drivers/dblewing.cpp
index 6f6c61ecbea..5e086058158 100644
--- a/src/mame/drivers/dblewing.cpp
+++ b/src/mame/drivers/dblewing.cpp
@@ -423,6 +423,11 @@ ROM_START( dblewing )
ROM_REGION( 0x40000, "oki", 0 ) /* Oki samples */
ROM_LOAD( "kp_03-.16h", 0x000000, 0x020000, CRC(5d7f930d) SHA1(ad23aa804ea3ccbd7630ade9b53fc3ea2718a6ec) )
ROM_RELOAD( 0x020000, 0x020000 )
+
+ ROM_REGION( 0x600, "plds", 0 )
+ ROM_LOAD( "pal16l8-vg-00.1f", 0x000, 0x117, CRC(8c2849e5) SHA1(72c5142dd78ea7d009229bad9f1a5651eec1e858) )
+ ROM_LOAD( "pal16l8-vg-01.1h", 0x200, 0x117, CRC(04b0bab6) SHA1(6b1ad69506b385eeeac6cb952e166304bf6fbb40) )
+ ROM_LOAD( "pal16r8-vg-02.11b", 0x400, 0x117, NO_DUMP )
ROM_END
ROM_START( dblewinga )
@@ -443,6 +448,11 @@ ROM_START( dblewinga )
ROM_REGION( 0x40000, "oki", 0 ) /* Oki samples */
ROM_LOAD( "kp_03-.16h", 0x000000, 0x020000, CRC(5d7f930d) SHA1(ad23aa804ea3ccbd7630ade9b53fc3ea2718a6ec) )
ROM_RELOAD( 0x020000, 0x020000 )
+
+ ROM_REGION( 0x600, "plds", 0 )
+ ROM_LOAD( "pal16l8-vg-00.1f", 0x000, 0x117, CRC(8c2849e5) SHA1(72c5142dd78ea7d009229bad9f1a5651eec1e858) )
+ ROM_LOAD( "pal16l8-vg-01.1h", 0x200, 0x117, CRC(04b0bab6) SHA1(6b1ad69506b385eeeac6cb952e166304bf6fbb40) )
+ ROM_LOAD( "pal16r8-vg-02.11b", 0x400, 0x117, NO_DUMP )
ROM_END
/*
@@ -467,6 +477,11 @@ ROM_START( dblewingb )
ROM_REGION( 0x40000, "oki", 0 ) /* Oki samples */
ROM_LOAD( "kp_03-.16h", 0x000000, 0x020000, CRC(5d7f930d) SHA1(ad23aa804ea3ccbd7630ade9b53fc3ea2718a6ec) )
ROM_RELOAD( 0x020000, 0x020000 )
+
+ ROM_REGION( 0x600, "plds", 0 )
+ ROM_LOAD( "pal16l8-vg-00.1f", 0x000, 0x117, CRC(8c2849e5) SHA1(72c5142dd78ea7d009229bad9f1a5651eec1e858) )
+ ROM_LOAD( "pal16l8-vg-01.1h", 0x200, 0x117, CRC(04b0bab6) SHA1(6b1ad69506b385eeeac6cb952e166304bf6fbb40) )
+ ROM_LOAD( "pal16r8-vg-02.11b", 0x400, 0x117, NO_DUMP )
ROM_END
void dblewing_state::init_dblewing()
diff --git a/src/mame/drivers/dct11em.cpp b/src/mame/drivers/dct11em.cpp
index 29f03b71d49..c273b2b667a 100644
--- a/src/mame/drivers/dct11em.cpp
+++ b/src/mame/drivers/dct11em.cpp
@@ -1,17 +1,31 @@
// license:BSD-3-Clause
-// copyright-holders:Miodrag Milanovic
+// copyright-holders:Miodrag Milanovic,Robbbert
/***************************************************************************
- DEC DCT11-EM
+DEC DCT11-EM (Evaluation Module)
+
+2010-12-03 Skeleton driver.
+
+System currently works, but with some hacks to replace the unemulated DC319
+DLART (Digital Link Asynchronous Receiver/Transmitter).
+
+
+TODO:
+- user LED (it's there but it doesn't work)
+- DLART device to be emulated
+- hookups between DLART (and its DL terminal), UART and remaining interrupts
- 03/12/2010 Skeleton driver.
****************************************************************************/
#include "emu.h"
#include "cpu/t11/t11.h"
-#include "emupal.h"
-#include "screen.h"
+#include "machine/i8251.h"
+#include "machine/i8255.h"
+#include "bus/rs232/rs232.h"
+#include "machine/clock.h"
+#include "machine/terminal.h"
+#include "dct11em.lh"
class dct11em_state : public driver_device
@@ -20,77 +34,280 @@ public:
dct11em_state(const machine_config &mconfig, device_type type, const char *tag)
: driver_device(mconfig, type, tag)
, m_maincpu(*this, "maincpu")
+ , m_ppi(*this, "ppi")
+ , m_uart(*this, "uart")
+ , m_terminal(*this, "terminal")
+ , m_io_keyboard(*this, "X%u", 0U)
+ , m_digits(*this, "digit%d", 0U)
{ }
void dct11em(machine_config &config);
+ DECLARE_INPUT_CHANGED_MEMBER(halt_button);
+ DECLARE_INPUT_CHANGED_MEMBER(int_button);
private:
- virtual void machine_reset() override;
- virtual void video_start() override;
+ void machine_reset() override;
+ void machine_start() override;
+
+ void porta_w(u8);
+ void portc_w(u8);
+ u8 portc_r();
+ void irq_encoder(u8, bool);
+ u8 dlart_r(offs_t);
+ void dlart_w(offs_t, u8);
+ void kbd_put(u8 data);
- void dct11em_mem(address_map &map);
+ u8 m_term_data;
+ u8 m_seg_lower;
+ u8 m_seg_upper;
+ u8 m_portc;
+ u16 m_irqs;
+ bool m_dlart_maintmode;
- uint32_t screen_update_dct11em(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ void mem_map(address_map &map);
required_device<t11_device> m_maincpu;
+ required_device<i8255_device> m_ppi;
+ required_device<i8251_device> m_uart;
+ required_device<generic_terminal_device> m_terminal;
+ required_ioport_array<5> m_io_keyboard;
+ output_finder<12> m_digits;
};
-void dct11em_state::dct11em_mem(address_map &map)
+void dct11em_state::mem_map(address_map &map)
{
map.unmap_value_high();
- map(0x0000, 0x0fff).ram(); // RAM
- map(0x2000, 0x2fff).ram(); // Optional RAM
- map(0xa000, 0xdfff).rom(); // RAM
+ map(0x0000, 0x0fff).ram(); // 2x 6116
+ map(0x1000, 0x1fff).noprw(); // the ram test reads/writes here even though there's no ram
+ map(0x2000, 0x2fff).ram(); // expansion sockets, 2x 6116
+ map(0xa000, 0xdfff).rom();
+ map(0xff20, 0xff27).nopr().lw8(NAME([this] (offs_t offset, u8 data) { m_ppi->write(offset>>1, data); }));
+ map(0xff28, 0xff2b).nopr().lw8(NAME([this] (offs_t offset, u8 data) { m_uart->write(offset>>1, data); }));
+ map(0xff60, 0xff67).lr8(NAME([this] (offs_t offset) { return m_ppi->read(offset>>1); }));
+ map(0xff68, 0xff6b).lr8(NAME([this] (offs_t offset) { return m_uart->read(offset>>1); }));
+ //map(0xff70, 0xff7f). // DC319 DLART unemulated device - uart to terminal
+ map(0xff70, 0xff7f).rw(FUNC(dct11em_state::dlart_r), FUNC(dct11em_state::dlart_w));
}
-/* Input ports */
-static INPUT_PORTS_START( dct11em )
-INPUT_PORTS_END
+// dummy routines to pass the DLART test and to talk to the ascii terminal
+u8 dct11em_state::dlart_r(offs_t offset)
+{
+ offset >>= 1;
+ switch (offset)
+ {
+ case 0:
+ if (m_term_data)
+ return 0xff;
+ else
+ return 0xfd;
+ case 1:
+ {
+ u8 ret = m_term_data;
+ irq_encoder(3, 0); // Release IRQ3
+ m_term_data = 0;
+ return ret;
+ }
+ default:
+ return 0xfd;
+ }
+}
+
+void dct11em_state::dlart_w(offs_t offset, u8 data)
+{
+ offset >>= 1;
+ switch (offset)
+ {
+ case 3:
+ if (m_dlart_maintmode)
+ m_term_data = data;
+ else
+ m_terminal->write(data);
+ break;
+ case 2:
+ m_dlart_maintmode = BIT(data, 4);
+ break;
+ default:
+ break;
+ }
+}
+
+void dct11em_state::porta_w(u8 data)
+{
+ m_seg_lower = data;
+ if (BIT(m_portc, 3))
+ m_seg_upper = data;
+}
+
+void dct11em_state::portc_w(u8 data)
+{
+ data &= 15;
+ m_portc = data;
+ if (BIT(data, 3))
+ {
+ m_seg_upper = m_seg_lower;
+ irq_encoder(10, 0); // Release IRQ10
+ }
+ if (data < 6)
+ {
+ m_digits[data] = m_seg_lower;
+ m_digits[data+6] = m_seg_upper;
+ }
+ output().set_value("led0", (data!=9));
+}
+
+u8 dct11em_state::portc_r()
+{
+ if (m_portc < 5)
+ return m_io_keyboard[m_portc]->read();
+ else
+ return 0;
+}
+/*
+ * interrupts (p. 101)
+ *
+ * IRQ CPx Pri Vec Device
+ * --- --- --- --- ------
+ * 15 LLLL 7 140 DLART receiver break
+ * 11 LHLL 6 100 External interrupt
+ * 10 LHLH 6 104 Keypad/LED scanning
+ * 7 HLLL 5 120 8251 receiver
+ * 6 HLLH 5 124 8251 transmitter
+ * 3 HHLL 4 060 DLART receiver
+ * 2 HHLH 4 064 DLART transmitter */
+ void dct11em_state::irq_encoder(u8 irq, bool state)
+{
+ if (state)
+ m_irqs |= (1 << irq);
+ else
+ m_irqs &= ~(1 << irq);
+
+ int i;
+ for (i = 15; i > 0; i--)
+ if (BIT(m_irqs, i))
+ break;
+
+ m_maincpu->set_input_line(t11_device::CP3_LINE, BIT(i, 3) ? ASSERT_LINE : CLEAR_LINE);
+ m_maincpu->set_input_line(t11_device::CP2_LINE, BIT(i, 2) ? ASSERT_LINE : CLEAR_LINE);
+ m_maincpu->set_input_line(t11_device::CP1_LINE, BIT(i, 1) ? ASSERT_LINE : CLEAR_LINE);
+ m_maincpu->set_input_line(t11_device::CP0_LINE, BIT(i, 0) ? ASSERT_LINE : CLEAR_LINE);
+}
void dct11em_state::machine_reset()
{
+ m_irqs = 0;
}
-void dct11em_state::video_start()
+void dct11em_state::machine_start()
+{
+ m_digits.resolve();
+ save_item(NAME(m_seg_lower));
+ save_item(NAME(m_seg_upper));
+ save_item(NAME(m_portc));
+ save_item(NAME(m_irqs));
+ save_item(NAME(m_term_data));
+ save_item(NAME(m_dlart_maintmode));
+}
+
+
+/* Input ports */
+static INPUT_PORTS_START( dct11em )
+ PORT_START("X0")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("CLR") PORT_CODE(KEYCODE_SPACE)
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("1/GOLED") PORT_CODE(KEYCODE_1) // Go with LEDs
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("4/PROTEC") PORT_CODE(KEYCODE_4) // Release protection
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("7/PC") PORT_CODE(KEYCODE_7)
+ PORT_START("X1")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("0/CANCEL") PORT_CODE(KEYCODE_0) // Cancel breakpoints
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("2/CONSOL") PORT_CODE(KEYCODE_2) // Start console
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("5") PORT_CODE(KEYCODE_5)
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("8/PS") PORT_CODE(KEYCODE_8)
+ PORT_START("X2")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("EXA/ENTER") PORT_CODE(KEYCODE_ENTER)
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("3/BAUD") PORT_CODE(KEYCODE_3) // Set baud rates
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("6/SP") PORT_CODE(KEYCODE_6)
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("9/WP") PORT_CODE(KEYCODE_9)
+ PORT_START("X3")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("ADV") PORT_CODE(KEYCODE_UP)
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("BAC") PORT_CODE(KEYCODE_DOWN)
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("REG") PORT_CODE(KEYCODE_R)
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("ADR") PORT_CODE(KEYCODE_MINUS) // Address
+ PORT_START("X4")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("SST") PORT_CODE(KEYCODE_S) // Single-step
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("GO") PORT_CODE(KEYCODE_X)
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("BPT") PORT_CODE(KEYCODE_B) // Breakpoint
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("FNC") PORT_CODE(KEYCODE_LALT) // Function
+ PORT_START("X5")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("HALT") PORT_CODE(KEYCODE_H) PORT_CHANGED_MEMBER(DEVICE_SELF, dct11em_state, halt_button, 0)
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("INT") PORT_CODE(KEYCODE_I) PORT_CHANGED_MEMBER(DEVICE_SELF, dct11em_state, int_button, 0)
+INPUT_PORTS_END
+
+INPUT_CHANGED_MEMBER(dct11em_state::halt_button)
{
+ m_maincpu->set_input_line(t11_device::HLT_LINE, newval ? ASSERT_LINE : CLEAR_LINE);
}
-uint32_t dct11em_state::screen_update_dct11em(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
+INPUT_CHANGED_MEMBER(dct11em_state::int_button)
{
- return 0;
+ m_maincpu->set_input_line(t11_device::PF_LINE, newval ? ASSERT_LINE : CLEAR_LINE);
}
+void dct11em_state::kbd_put(u8 data)
+{
+ m_term_data = data;
+ irq_encoder(3, 1); // Assert IRQ3
+}
void dct11em_state::dct11em(machine_config &config)
{
/* basic machine hardware */
- T11(config, m_maincpu, 7500000); // 7.5MHz XTAL
+ T11(config, m_maincpu, 7'500'000); // 7.5MHz XTAL
m_maincpu->set_initial_mode(0x1403); /* according to specs */
- m_maincpu->set_addrmap(AS_PROGRAM, &dct11em_state::dct11em_mem);
-
- /* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(50);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
- screen.set_size(640, 480);
- screen.set_visarea(0, 640-1, 0, 480-1);
- screen.set_screen_update(FUNC(dct11em_state::screen_update_dct11em));
- screen.set_palette("palette");
-
- PALETTE(config, "palette", palette_device::MONOCHROME);
+ m_maincpu->set_addrmap(AS_PROGRAM, &dct11em_state::mem_map);
+
+ config.set_default_layout(layout_dct11em);
+
+ I8255(config, m_ppi);
+ m_ppi->out_pa_callback().set(FUNC(dct11em_state::porta_w)); // segments
+ // port B - expansion interface
+ m_ppi->in_pc_callback().set(FUNC(dct11em_state::portc_r)); // keyboard
+ m_ppi->out_pc_callback().set(FUNC(dct11em_state::portc_w)); // digits
+
+ I8251(config, m_uart, 2'457'600 / 8);
+ m_uart->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd));
+ m_uart->dtr_handler().set("rs232", FUNC(rs232_port_device::write_dtr));
+ m_uart->rts_handler().set("rs232", FUNC(rs232_port_device::write_rts));
+ m_uart->rxrdy_handler().set([this] (bool state) { irq_encoder(7, state); });
+ m_uart->txrdy_handler().set([this] (bool state) { irq_encoder(6, state); });
+
+ clock_device &inta_clock(CLOCK(config, "inta_clock", 614'400 / 768)); // 800Hz, from DLART pin 25
+ inta_clock.signal_handler().set([this] (bool state) { if (state) irq_encoder(10, 1); }); // Assert IRQ10
+
+ //clock_device &dlart_clock(CLOCK(config, "dlart_clock", 2'457'600 / 4)); --> to DLART CLK pin 32
+
+ clock_device &uart_clock(CLOCK(config, "uart_clock", 2'457'600 / 32)); // from DLART pin 34
+ uart_clock.signal_handler().set(m_uart, FUNC(i8251_device::write_txc));
+ uart_clock.signal_handler().append(m_uart, FUNC(i8251_device::write_rxc));
+
+ rs232_port_device &rs232(RS232_PORT(config, "rs232", default_rs232_devices, nullptr)); // connection to host mainframe, does nothing for us
+ rs232.rxd_handler().set(m_uart, FUNC(i8251_device::write_rxd));
+ rs232.dsr_handler().set(m_uart, FUNC(i8251_device::write_dsr));
+ rs232.cts_handler().set(m_uart, FUNC(i8251_device::write_cts));
+
+ GENERIC_TERMINAL(config, m_terminal, 0); // Main terminal for now
+ m_terminal->set_keyboard_callback(FUNC(dct11em_state::kbd_put));
}
/* ROM definition */
ROM_START( dct11em )
ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
// Highest address line inverted
- ROM_LOAD16_BYTE( "23-213e4.bin", 0x8000, 0x2000, CRC(bdd82f39) SHA1(347deeff77596b67eee27a39a9c40075fcf5c10d))
- ROM_LOAD16_BYTE( "23-214e4.bin", 0x8001, 0x2000, CRC(b523dae8) SHA1(cd1a64a2bce9730f7a9177d391663919c7f56073))
+ ROM_LOAD16_BYTE( "23-213e4.e53", 0x8000, 0x2000, CRC(bdd82f39) SHA1(347deeff77596b67eee27a39a9c40075fcf5c10d))
+ ROM_LOAD16_BYTE( "23-214e4.e45", 0x8001, 0x2000, CRC(b523dae8) SHA1(cd1a64a2bce9730f7a9177d391663919c7f56073))
ROM_COPY("maincpu", 0x8000, 0xc000, 0x2000)
ROM_END
/* Driver */
/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
-COMP( 1983, dct11em, 0, 0, dct11em, dct11em, dct11em_state, empty_init, "Digital Equipment Corporation", "DCT11-EM", MACHINE_NOT_WORKING | MACHINE_NO_SOUND)
+COMP( 1983, dct11em, 0, 0, dct11em, dct11em, dct11em_state, empty_init, "Digital Equipment Corporation", "DCT11-EM", MACHINE_NOT_WORKING | MACHINE_NO_SOUND_HW | MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/ddenlovr.cpp b/src/mame/drivers/ddenlovr.cpp
index 16b0e7c0f11..e56cb13e93a 100644
--- a/src/mame/drivers/ddenlovr.cpp
+++ b/src/mame/drivers/ddenlovr.cpp
@@ -254,10 +254,8 @@ private:
DECLARE_WRITE_LINE_MEMBER(ddenlovr_irq);
DECLARE_WRITE_LINE_MEMBER(mmpanic_irq);
DECLARE_WRITE_LINE_MEMBER(mmpanic_rtc_irq);
- DECLARE_WRITE_LINE_MEMBER(hanakanz_irq);
DECLARE_WRITE_LINE_MEMBER(funkyfig_sound_irq);
DECLARE_WRITE_LINE_MEMBER(mjflove_irq);
- DECLARE_WRITE_LINE_MEMBER(hanakanz_rtc_irq);
DECLARE_WRITE_LINE_MEMBER(mjflove_rtc_irq);
void ddenlovr_bgcolor_w(uint8_t data);
@@ -9992,34 +9990,6 @@ void ddenlovr_state::mmpanic(machine_config &config)
0xe2 is from the 6242RTC
*/
-WRITE_LINE_MEMBER(ddenlovr_state::hanakanz_irq)
-{
- if (!state)
- return;
-
- /* I haven't found a irq ack register, so I need this kludge to
- make sure I don't lose any interrupt generated by the blitter,
- otherwise quizchq would lock up. */
- //if (downcast<cpu_device *>(m_maincpu)->input_state(0))
- // return;
-
- m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0xe0); // Z80
-}
-
-WRITE_LINE_MEMBER(ddenlovr_state::hanakanz_rtc_irq)
-{
- if (!state)
- return;
-
- /* I haven't found a irq ack register, so I need this kludge to
- make sure I don't lose any interrupt generated by the blitter,
- otherwise quizchq would lock up. */
- //if (downcast<cpu_device *>(drvm_maincpu)->input_state(0))
- // return;
-
- m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0xe2); // Z80
-}
-
void ddenlovr_state::hanakanz(machine_config &config)
{
/* basic machine hardware */
@@ -10038,7 +10008,7 @@ void ddenlovr_state::hanakanz(machine_config &config)
m_screen->set_visarea(0, 336-1, 5, 256-11-1);
m_screen->set_screen_update(FUNC(ddenlovr_state::screen_update_ddenlovr));
m_screen->set_video_attributes(VIDEO_ALWAYS_UPDATE);
- m_screen->screen_vblank().set(FUNC(ddenlovr_state::hanakanz_irq));
+ m_screen->screen_vblank().set("maincpu:kp69", FUNC(kp69_device::ir_w<0>));
PALETTE(config, m_palette, palette_device::BLACK).set_entries(0x200);
@@ -10054,7 +10024,7 @@ void ddenlovr_state::hanakanz(machine_config &config)
/* devices */
msm6242_device &rtc(MSM6242(config, "rtc", XTAL(32'768)));
- rtc.out_int_handler().set(FUNC(ddenlovr_state::hanakanz_rtc_irq));
+ rtc.out_int_handler().set("maincpu:kp69", FUNC(kp69_device::ir_w<1>));
}
void ddenlovr_state::hkagerou(machine_config &config)
@@ -10083,7 +10053,7 @@ void ddenlovr_state::kotbinyo(machine_config &config)
m_screen->set_visarea(0, 336-1-1, 1+4, 256-15-1+4);
m_screen->set_screen_update(FUNC(ddenlovr_state::screen_update_ddenlovr));
m_screen->set_video_attributes(VIDEO_ALWAYS_UPDATE);
- m_screen->screen_vblank().set(FUNC(ddenlovr_state::hanakanz_irq));
+ m_screen->screen_vblank().set("maincpu:kp69", FUNC(kp69_device::ir_w<0>));
PALETTE(config, m_palette, palette_device::BLACK).set_entries(0x200);
@@ -10098,7 +10068,7 @@ void ddenlovr_state::kotbinyo(machine_config &config)
m_oki->add_route(ALL_OUTPUTS, "mono", 0.80);
/* devices */
-// MSM6242(config, "rtc", XTAL(32'768)).out_int_handler().set(FUNC(ddenlovr_state::hanakanz_rtc_irq));
+// MSM6242(config, "rtc", XTAL(32'768)).out_int_handler().set("maincpu:kp69", FUNC(kp69_device::ir_w<1>));
}
void ddenlovr_state::kotbinsp(machine_config &config)
@@ -10486,7 +10456,7 @@ void ddenlovr_state::jongtei(machine_config &config)
m_screen->set_visarea(0, 336-1, 5, 256-11-1);
m_screen->set_screen_update(FUNC(ddenlovr_state::screen_update_ddenlovr));
m_screen->set_video_attributes(VIDEO_ALWAYS_UPDATE);
- m_screen->screen_vblank().set(FUNC(ddenlovr_state::hanakanz_irq));
+ m_screen->screen_vblank().set("maincpu:kp69", FUNC(kp69_device::ir_w<0>));
PALETTE(config, m_palette, palette_device::BLACK).set_entries(0x200);
@@ -10502,7 +10472,7 @@ void ddenlovr_state::jongtei(machine_config &config)
OKIM6295(config, m_oki, XTAL(28'636'363) / 28, okim6295_device::PIN7_HIGH).add_route(ALL_OUTPUTS, "mono", 0.80);
/* devices */
- MSM6242(config, "rtc", XTAL(32'768)).out_int_handler().set(FUNC(ddenlovr_state::hanakanz_rtc_irq));
+ MSM6242(config, "rtc", XTAL(32'768)).out_int_handler().set("maincpu:kp69", FUNC(kp69_device::ir_w<1>));
}
void ddenlovr_state::mjgnight(machine_config &config)
@@ -10700,7 +10670,7 @@ void ddenlovr_state::daimyojn(machine_config &config)
m_screen->set_visarea(0, 336-1-1, 1, 256-15-1);
m_screen->set_screen_update(FUNC(ddenlovr_state::screen_update_ddenlovr));
m_screen->set_video_attributes(VIDEO_ALWAYS_UPDATE);
- m_screen->screen_vblank().set(FUNC(ddenlovr_state::hanakanz_irq));
+ m_screen->screen_vblank().set("maincpu:kp69", FUNC(kp69_device::ir_w<0>));
PALETTE(config, m_palette, palette_device::BLACK).set_entries(0x200);
@@ -10714,7 +10684,7 @@ void ddenlovr_state::daimyojn(machine_config &config)
OKIM6295(config, m_oki, XTAL(28'636'363) / 28, okim6295_device::PIN7_HIGH).add_route(ALL_OUTPUTS, "mono", 0.80);
/* devices */
- MSM6242(config, "rtc", XTAL(32'768)).out_int_handler().set(FUNC(ddenlovr_state::hanakanz_rtc_irq));
+ MSM6242(config, "rtc", XTAL(32'768)).out_int_handler().set("maincpu:kp69", FUNC(kp69_device::ir_w<1>));
}
diff --git a/src/mame/drivers/fidel_cc1.cpp b/src/mame/drivers/fidel_cc1.cpp
index d08b37b116c..19cfdb94f48 100644
--- a/src/mame/drivers/fidel_cc1.cpp
+++ b/src/mame/drivers/fidel_cc1.cpp
@@ -90,7 +90,7 @@ public:
// machine configs
void cc1(machine_config &config);
void cc3(machine_config &config);
- void cc10(machine_config &config);
+ void cc10c(machine_config &config);
protected:
virtual void machine_start() override;
@@ -106,7 +106,7 @@ private:
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
- void cc10_map(address_map &map);
+ void cc10c_map(address_map &map);
// I/O handlers
void update_display();
@@ -144,6 +144,7 @@ u8 cc1_state::ppi_porta_r()
// 74148(priority encoder) I0-I7: inputs
// d0-d2: 74148 S0-S2, d3: 74148 GS
u8 data = count_leading_zeros(m_inputs[0]->read()) - 24;
+ if (data == 8) data = 0xf;
// d5-d7: more inputs (direct)
data |= ~m_inputs[1]->read() << 5 & 0xe0;
@@ -190,7 +191,7 @@ void cc1_state::main_io(address_map &map)
map(0x00, 0x03).mirror(0x04).rw(m_ppi8255, FUNC(i8255_device::read), FUNC(i8255_device::write));
}
-void cc1_state::cc10_map(address_map &map)
+void cc1_state::cc10c_map(address_map &map)
{
map.global_mask(0x3fff);
map(0x0000, 0x0fff).rom();
@@ -238,7 +239,7 @@ static INPUT_PORTS_START( cc3 )
PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_NAME("A1") PORT_CODE(KEYCODE_1) PORT_CODE(KEYCODE_1_PAD) PORT_CODE(KEYCODE_A)
INPUT_PORTS_END
-static INPUT_PORTS_START( cc10 )
+static INPUT_PORTS_START( cc10c )
PORT_INCLUDE( cc3 )
PORT_MODIFY("IN.1")
@@ -279,12 +280,12 @@ void cc1_state::cc3(machine_config &config)
config.set_default_layout(layout_fidel_cc3);
}
-void cc1_state::cc10(machine_config &config)
+void cc1_state::cc10c(machine_config &config)
{
cc1(config);
/* basic machine hardware */
- m_maincpu->set_addrmap(AS_PROGRAM, &cc1_state::cc10_map);
+ m_maincpu->set_addrmap(AS_PROGRAM, &cc1_state::cc10c_map);
config.set_default_layout(layout_fidel_cc10c);
}
@@ -297,7 +298,7 @@ void cc1_state::cc10(machine_config &config)
ROM_START( cc1 )
ROM_REGION(0x10000, "maincpu", ROMREGION_ERASEFF)
- ROM_LOAD("d2316ac_011", 0x0000, 0x0800, BAD_DUMP CRC(e27f9816) SHA1(ad9881b3bf8341829a27e86de27805fc2ccb5f7d) ) // A4 line was broken
+ ROM_LOAD("d2316ac_011", 0x0000, 0x0800, CRC(4af38ed6) SHA1(3f07691266196f3aa5c440a40bfe4802303e7c07) )
ROM_END
ROM_START( cc3 )
@@ -320,6 +321,6 @@ ROM_END
******************************************************************************/
// YEAR NAME PARENT CMP MACHINE INPUT STATE INIT COMPANY, FULLNAME, FLAGS
-CONS( 1977, cc1, 0, 0, cc1, cc1, cc1_state, empty_init, "Fidelity Electronics", "Chess Challenger", MACHINE_SUPPORTS_SAVE | MACHINE_CLICKABLE_ARTWORK | MACHINE_NO_SOUND_HW | MACHINE_NOT_WORKING )
+CONS( 1977, cc1, 0, 0, cc1, cc1, cc1_state, empty_init, "Fidelity Electronics", "Chess Challenger", MACHINE_SUPPORTS_SAVE | MACHINE_CLICKABLE_ARTWORK | MACHINE_NO_SOUND_HW )
CONS( 1977, cc3, 0, 0, cc3, cc3, cc1_state, empty_init, "Fidelity Electronics", "Chess Challenger (upgraded version, 3 levels)", MACHINE_SUPPORTS_SAVE | MACHINE_CLICKABLE_ARTWORK | MACHINE_NO_SOUND_HW ) // aka Chess Challenger 3
-CONS( 1979, cc10c, 0, 0, cc10, cc10, cc1_state, empty_init, "Fidelity Electronics", "Chess Challenger (model UCC10, 10 levels)", MACHINE_SUPPORTS_SAVE | MACHINE_CLICKABLE_ARTWORK | MACHINE_NO_SOUND_HW ) // aka Chess Challenger 10 C
+CONS( 1979, cc10c, 0, 0, cc10c, cc10c, cc1_state, empty_init, "Fidelity Electronics", "Chess Challenger (model UCC10, 10 levels)", MACHINE_SUPPORTS_SAVE | MACHINE_CLICKABLE_ARTWORK | MACHINE_NO_SOUND_HW ) // aka Chess Challenger 10 C
diff --git a/src/mame/drivers/fidel_vcc.cpp b/src/mame/drivers/fidel_vcc.cpp
index 3ea064afb4c..495dd5d298a 100644
--- a/src/mame/drivers/fidel_vcc.cpp
+++ b/src/mame/drivers/fidel_vcc.cpp
@@ -159,20 +159,14 @@ private:
u8 ppi_portc_r();
void ppi_portc_w(u8 data);
- u8 m_led_select;
- u8 m_7seg_data;
- u8 m_inp_mux;
- u8 m_speech_bank;
+ u8 m_led_select = 0;
+ u8 m_7seg_data = 0;
+ u8 m_inp_mux = 0;
+ u8 m_speech_bank = 0;
};
void vcc_state::machine_start()
{
- // zerofill
- m_led_select = 0;
- m_7seg_data = 0;
- m_inp_mux = 0;
- m_speech_bank = 0;
-
// register for savestates
save_item(NAME(m_led_select));
save_item(NAME(m_7seg_data));
diff --git a/src/mame/drivers/funworld.cpp b/src/mame/drivers/funworld.cpp
index c95182c93ac..2d97088d3e2 100644
--- a/src/mame/drivers/funworld.cpp
+++ b/src/mame/drivers/funworld.cpp
@@ -5,9 +5,10 @@
Fun World / TAB / Impera
Series 7000 hardware.
- 65C02 + 2x PIAs + M6845 CRTC + AY8910
+ 65C02/65SC02 + 2x 6821 PIAs + 6845 CRTC + AY-3-8910.
+ From raw, to different ways of encryption. Even through custom CPUs.
- Also from Amatic, CMC, Dino4 encrypted, and Leopard 4.
+ Also from Amatic, CMC, Dino4 (encrypted), and Leopard 4.
Driver by Roberto Fresca.
Based on a preliminary work of Curt Coder & Peter Trauner.
@@ -71,7 +72,6 @@
* Royal Card Professional 2.0, Digital Dreams, 1993.
* Royal Card / Royal Jackpot (with a third draw)(encrypted), TAB / Video Klein, 1991
* Witch Royal (Export version 2.1), Video Klein, 199?.
- * Royal Card (Italian, Dino 4 hardware, encrypted), unknown, 1998.
* Lucky Lady (3x3 deal), TAB Austria, 1991.
* Lucky Lady (4x1 aces), TAB Austria, 1991.
* Magic Card II (Bulgarian), Impera, 1996.
@@ -82,12 +82,14 @@
* Royal Vegas Joker Card (Fast deal), Soft Design, 1993.
* Royal Vegas Joker Card (Fast deal, english gfx), Soft Design, 1993.
* Royal Vegas Joker Card (Fast deal, Mile), Mile, 1993.
- * Jolly Joker (original, interleaved GFX). Impera, 198?.
- * Jolly Joker (original, different encoded GFX). Impera, 198?.
- * Jolly Joker (98bet, set 1). Impera, 198?.
- * Jolly Joker (98bet, set 2). Impera, 198?.
- * Jolly Joker (40bet, croatian hack), Impera, 198?.
- * Jolly Joker (Apple Time), Apple Time, 198?.
+ * Jolly Joker (original, interleaved GFX). Impera, 199?.
+ * Jolly Joker (original, different encoded GFX). Impera, 199?.
+ * Jolly Joker (Solid State module in suicide board). Impera, 199?.
+ * Jolly Joker (98bet, set 1). Impera, 199?.
+ * Jolly Joker (98bet, set 2). Impera, 199?.
+ * Jolly Joker (40bet, higher paytable), Impera, 1985.
+ * Jolly Joker (40bet, lower paytable), Impera, 1985.
+ * Jolly Joker (Apple Time), Apple Time, 199?.
* Multi Win (Ver.0167, encrypted), Fun World, 1992.
* Power Card (Ver 0263, encrypted), Fun World, 1993.
* Mega Card (Ver.0210, encrypted), Fun World, 1993.
@@ -98,7 +100,9 @@
* Jolly Card (Italian, blue TAB board, encrypted), bootleg, 199?.
* Jolly Card (Italian, encrypted bootleg, set 1), bootleg, 1990.
* Jolly Card (Italian, encrypted bootleg, set 2), bootleg, 1993.
+ * Jolly Card (Italian, encrypted bootleg, set 3), bootleg, 1993.
* Pool 10 (Italian, Dino 4 hardware, encrypted), C.M.C., 1997.
+ * Royal Card (Italian, Dino 4 hardware, encrypted), unknown, 1998.
* China Town (Ver 1B, Dino4 HW), unknown, 1998.
* Royal Card (Italian, Dino 4 hardware, encrypted), TAB Austria, 1998.
* Mongolfier New (Italian), unknown, 199?.
@@ -112,10 +116,17 @@
* Unknown Fun World A7-11 game 2, Fun World, 1985.
* Unknown Fun World A0-1 game, Fun World, 1991.
* Joker Card / Multi Card (Epoxy brick CPU), Fun World, 1991.
+ * Gratis Poker (V.204, Set 1), Mega Soft, 1995.
+ * Gratis Poker (V.204, Set 2), Mega Soft, 1995.
+ * Nkoulit (Gullit) (encrypted GFX), JK Amusement, 1995.
+ * Reflex Cards (English, serial protected), TAB Austria, 1999.
* Royal Card (stealth with NES multigame), bootleg, 1991.
* Royal Card (stealth with MSX multigame), bootleg, 1991.
+ Supported games: 104
+
+
*****************************************************************************************
The hardware is generally composed by:
@@ -173,11 +184,12 @@
- Encryption.
- A) Encrypted CPU. At least two Fun World boards have custom encrypted CPUs:
+ A) Encrypted CPU. At least five Fun World boards have custom encrypted CPUs:
- - Joker Card from Vesely Svet use a custom unknown CPU and use encrypted prg roms.
+ - Joker Card from Vesely Svet, Mega Card, Power Card and Multi Win,
+ use custom unknown CPUs and also encrypted/scrambled prg roms.
- Royal Card (slovak, encrypted) from Evona Electronic seems to use a block
- with CPU + extras (ICs, TTL, etc) to manage the encryption.
+ with CPU + extras (ICs, TTL, etc) to manage the encryption.
B) General encryption. Managed through hardware:
@@ -353,6 +365,8 @@
* Joker Card 300 (Ver.A267BC, encrypted).
* Multi Win (Fun World)
+ * Power Card (Fun World)
+ * Mega Card (Fun World)
These sets seems to run in the same modified hardware. They are highly encrypted.
@@ -620,16 +634,12 @@
*** TO DO ***
- - Figure out the royalcdc encryption.
- Figure out the remaining PIA connections for almost all games.
- Reverse-engineering the boot code of Jolly Card Professional 2.0,
and Royal Card Professional 2.0 to get the proper codes to boot.
- Analyze the unknown writes to $2000/$4000 in some games.
- Check for the reads to the ay8910 output ports in some games.
- Implement the MCU in monglfir and soccernw.
- - Check for a possible bug in the royalcrdf decryption scheme, that
- doesn't cover the BRK instruction properly, changing the next value
- on the fly turning a NOP into a PLA, messing the Stack Pointer.
****************************************************************************************/
@@ -673,17 +683,17 @@ void funworld_state::funworld_lamp_a_w(uint8_t data)
-x-- ---- Hopper Motor (inverted).
x--- ---- HOLD4 lamp.
*/
- m_lamps[0] = BIT(~data, 1); /* Hold1 (inverted) */
- m_lamps[2] = BIT(~data, 1); /* Hold3 (inverted, see pinouts) */
+ m_lamps[0] = BIT(~data, 1); // Hold1 (inverted)
+ m_lamps[2] = BIT(~data, 1); // Hold3 (inverted, see pinouts)
- m_lamps[1] = BIT(~data, 3); /* Hold2 / Low (inverted) */
- m_lamps[3] = BIT(data, 7); /* Hold4 / High */
- m_lamps[5] = BIT(~data, 5); /* Cancel / Collect (inverted) */
+ m_lamps[1] = BIT(~data, 3); // Hold2 / Low (inverted)
+ m_lamps[3] = BIT(data, 7); // Hold4 / High
+ m_lamps[5] = BIT(~data, 5); // Cancel / Collect (inverted)
- machine().bookkeeping().coin_counter_w(0, data & 0x01); /* Credit In counter */
- machine().bookkeeping().coin_counter_w(7, data & 0x04); /* Credit Out counter, mapped as coin 8 */
+ machine().bookkeeping().coin_counter_w(0, data & 0x01); // Credit In counter
+ machine().bookkeeping().coin_counter_w(7, data & 0x04); // Credit Out counter, mapped as coin 8
- m_lamps[7] = BIT(~data, 6); /* Hopper Motor (inverted) */
+ m_lamps[7] = BIT(~data, 6); // Hopper Motor (inverted)
// popmessage("Lamps A: %02X", (data ^ 0xff));
}
@@ -697,17 +707,17 @@ void funworld_state::funworld_lamp_b_w(uint8_t data)
---- -x-- Unknown (inverted).
xxxx x--- Unknown.
*/
- m_lamps[4] = BIT(data, 0); /* Hold5 / Bet */
- m_lamps[6] = BIT(data, 1); /* Start / Deal / Draw */
+ m_lamps[4] = BIT(data, 0); // Hold5 / Bet
+ m_lamps[6] = BIT(data, 1); // Start / Deal / Draw
// popmessage("Lamps B: %02X", data);
}
WRITE_LINE_MEMBER(funworld_state::pia1_ca2_w)
{
-/* TAB and Impera games are writing 0x01 constantly, and 0x00 with each screen change.
- This line is tied to sort of reset circuitery.
-*/
+// TAB and Impera games are writing 0x01 constantly, and 0x00 with each screen change.
+// This line is tied to some sort of reset circuitery.
+
// popmessage("PIA1 CA2: %02X", state);
}
@@ -779,9 +789,9 @@ void funworld_state::magicrd2_map(address_map &map)
map(0x0c00, 0x0c01).w("ay8910", FUNC(ay8910_device::address_data_w));
map(0x0e00, 0x0e00).w("crtc", FUNC(mc6845_device::address_w));
map(0x0e01, 0x0e01).rw("crtc", FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w));
- map(0x2c00, 0x2cff).ram(); /* range for protection */
- map(0x3600, 0x36ff).ram(); /* some games use $3603-05 range for protection */
- map(0x3c00, 0x3cff).ram(); /* range for protection */
+ map(0x2c00, 0x2cff).ram(); // range for protection
+ map(0x3600, 0x36ff).ram(); // some games use $3603-05 range for protection
+ map(0x3c00, 0x3cff).ram(); // range for protection
map(0x4000, 0x4fff).ram().w(FUNC(funworld_state::funworld_videoram_w)).share("videoram");
map(0x5000, 0x5fff).ram().w(FUNC(funworld_state::funworld_colorram_w)).share("colorram");
map(0x6000, 0xffff).rom();
@@ -796,9 +806,9 @@ void funworld_state::cuoreuno_map(address_map &map)
map(0x0c00, 0x0c01).w("ay8910", FUNC(ay8910_device::address_data_w));
map(0x0e00, 0x0e00).w("crtc", FUNC(mc6845_device::address_w));
map(0x0e01, 0x0e01).rw("crtc", FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w));
- map(0x2000, 0x2000).nopr(); /* some unknown reads */
- map(0x3e00, 0x3fff).ram(); /* some games use $3e03-05 range for protection */
- map(0x4000, 0x5fff).rom(); /* used by rcdino4 (dino4 hw ) */
+ map(0x2000, 0x2000).nopr(); // some unknown reads
+ map(0x3e00, 0x3fff).ram(); // some games use $3e03-05 range for protection
+ map(0x4000, 0x5fff).rom(); // used by rcdino4 (dino4 hw )
map(0x6000, 0x6fff).ram().w(FUNC(funworld_state::funworld_videoram_w)).share("videoram");
map(0x7000, 0x7fff).ram().w(FUNC(funworld_state::funworld_colorram_w)).share("colorram");
map(0x8000, 0xffff).rom();
@@ -984,6 +994,21 @@ void royalcrdf_state::royalcrdf_map(address_map &map)
}
+void funworld_state::gratispk_map(address_map &map)
+{
+ map(0x0000, 0x07ff).ram().share("nvram");
+ map(0x0800, 0x0803).rw("pia0", FUNC(pia6821_device::read), FUNC(pia6821_device::write));
+ map(0x0a00, 0x0a03).rw("pia1", FUNC(pia6821_device::read), FUNC(pia6821_device::write));
+ map(0x0c00, 0x0c00).r("ay8910", FUNC(ay8910_device::data_r));
+ map(0x0c00, 0x0c01).w("ay8910", FUNC(ay8910_device::address_data_w));
+ map(0x0e00, 0x0e00).w("crtc", FUNC(mc6845_device::address_w));
+ map(0x0e01, 0x0e01).rw("crtc", FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w));
+ map(0x4000, 0x4fff).ram().w(FUNC(funworld_state::funworld_videoram_w)).share("videoram");
+ map(0x5000, 0x5fff).ram().w(FUNC(funworld_state::funworld_colorram_w)).share("colorram");
+ map(0x6000, 0xffff).rom();
+}
+
+
/*************************
* Input ports *
*************************/
@@ -1036,14 +1061,14 @@ static INPUT_PORTS_START( funworld )
PORT_DIPSETTING( 0x00, "Dattl Insert" )
PORT_DIPSETTING( 0x10, "TAB Insert" )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1085,7 +1110,7 @@ static INPUT_PORTS_START( jolycdcr )
PORT_DIPNAME( 0x01, 0x01, "State" ) PORT_DIPLOCATION("SW1:8")
PORT_DIPSETTING( 0x00, "Keyboard Test" )
PORT_DIPSETTING( 0x01, "Play" )
- PORT_DIPNAME( 0x02, 0x00, "Remote Value" ) PORT_DIPLOCATION("SW1:7")
+ PORT_DIPNAME( 0x02, 0x00, "Remote Value" ) PORT_DIPLOCATION("SW1:7")
PORT_DIPSETTING( 0x00, "10 Points/Pulse" )
PORT_DIPSETTING( 0x02, "100 Points/Pulse" )
PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:6")
@@ -1098,14 +1123,14 @@ static INPUT_PORTS_START( jolycdcr )
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x10, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1159,14 +1184,14 @@ static INPUT_PORTS_START( jolycdit )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1208,7 +1233,7 @@ static INPUT_PORTS_START( jolycdib )
PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:8")
PORT_DIPSETTING( 0x01, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, "Remote Value" ) PORT_DIPLOCATION("SW1:7")
+ PORT_DIPNAME( 0x02, 0x00, "Remote Value" ) PORT_DIPLOCATION("SW1:7")
PORT_DIPSETTING( 0x00, "10 Points/Pulse" )
PORT_DIPSETTING( 0x02, "100 Points/Pulse" )
PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:6")
@@ -1221,14 +1246,14 @@ static INPUT_PORTS_START( jolycdib )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enables Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Auto Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x40, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) ) /* when is ON, allow the player to activate/deactivate the autohold through CANCEL button */
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) ) // when is ON, allows the player to activate/deactivate the autohold through CANCEL button
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1283,11 +1308,11 @@ static INPUT_PORTS_START( jolycdic )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enables Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Auto Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x40, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x00, DEF_STR( On ) ) /* when is ON, allow the player to activate/deactivate the autohold through CANCEL button */
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) ) // when is ON, allows the player to activate/deactivate the autohold through CANCEL button
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1342,7 +1367,7 @@ static INPUT_PORTS_START( jolyc980 )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
@@ -1385,9 +1410,9 @@ static INPUT_PORTS_START( bonuscrd )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
PORT_START("DSW")
-/* DIP switch 8 should be left ON by default (all remaining ones in OFF)
- to allow initialization. You can change settings later, after the boot.
-*/
+// DIP switch 8 should be left ON by default (all remaining ones in OFF)
+// to allow initialization. You can change settings later, after the boot.
+
PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:8")
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x01, DEF_STR( On ) )
@@ -1410,8 +1435,8 @@ static INPUT_PORTS_START( bonuscrd )
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1450,9 +1475,9 @@ static INPUT_PORTS_START( bigdeal )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
PORT_START("DSW")
-/* DIP switch 8 should be left ON by default (all remaining ones in OFF)
- to allow initialization. You can change settings later, after the boot.
-*/
+// DIP switch 8 should be left ON by default (all remaining ones in OFF)
+// to allow initialization. You can change settings later, after the boot.
+
PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:8")
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x01, DEF_STR( On ) )
@@ -1475,8 +1500,8 @@ static INPUT_PORTS_START( bigdeal )
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1518,7 +1543,7 @@ static INPUT_PORTS_START( magicrd2 )
PORT_DIPNAME( 0x01, 0x01, "State" ) PORT_DIPLOCATION("SW1:8")
PORT_DIPSETTING( 0x00, "Keyboard Test" )
PORT_DIPSETTING( 0x01, "Play" )
- PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:7") /* remote credits settings are always 10 points/pulse */
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:7") // remote credits settings are always 10 points/pulse
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x02, DEF_STR( On ) )
PORT_DIPNAME( 0x04, 0x00, DEF_STR( Coin_B ) ) PORT_DIPLOCATION("SW1:6")
@@ -1537,8 +1562,8 @@ static INPUT_PORTS_START( magicrd2 )
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1580,7 +1605,7 @@ static INPUT_PORTS_START( royalcrd )
PORT_DIPNAME( 0x01, 0x01, "State" ) PORT_DIPLOCATION("SW1:8")
PORT_DIPSETTING( 0x00, "Keyboard Test" )
PORT_DIPSETTING( 0x01, "Play" )
- PORT_DIPNAME( 0x02, 0x02, "Remote Value" ) PORT_DIPLOCATION("SW1:7") /* listed as 'Coin-C' in some sources */
+ PORT_DIPNAME( 0x02, 0x02, "Remote Value" ) PORT_DIPLOCATION("SW1:7") // listed as 'Coin-C' in some sources
PORT_DIPSETTING( 0x00, "10 Points/Pulse" )
PORT_DIPSETTING( 0x02, "100 Points/Pulse" )
PORT_DIPNAME( 0x04, 0x04, DEF_STR( Coin_B ) ) PORT_DIPLOCATION("SW1:6")
@@ -1593,14 +1618,14 @@ static INPUT_PORTS_START( royalcrd )
PORT_DIPSETTING( 0x00, "Dattl Insert" )
PORT_DIPSETTING( 0x10, "TAB Insert" )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1655,14 +1680,14 @@ static INPUT_PORTS_START( royalcrdf )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x40, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -1757,7 +1782,7 @@ INPUT_PORTS_END
static INPUT_PORTS_START( cuoreuno )
PORT_START("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* no remote credits */
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // no remote credits
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_POKER_HOLD1 ) PORT_NAME("Stop 1 / Switch Bet (1-Max)")
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_POKER_CANCEL ) PORT_NAME("Clear / Bet / Prendi (Take)")
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start / Gioca (Play)")
@@ -1808,8 +1833,8 @@ static INPUT_PORTS_START( cuoreuno )
PORT_DIPSETTING( 0x40, "Manual - Tickets" )
PORT_DIPSETTING( 0x60, "Manual - User Choice 2" )
- /* the following one (1st DSW) seems to be disconnected
- to avoid the use of remote credits or direct payout */
+// the following one (1st DSW) seems to be disconnected
+// to avoid the use of remote credits or direct payout
PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unused ) ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
@@ -1818,7 +1843,7 @@ INPUT_PORTS_END
static INPUT_PORTS_START( pool10 )
PORT_START("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* no remote credits */
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // no remote credits
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_POKER_HOLD1 ) PORT_NAME("Stop 1 / Switch Bet (1-Max)")
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_POKER_CANCEL ) PORT_NAME("Clear / Bet / Prendi (Take)")
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start / Gioca (Play)")
@@ -1869,7 +1894,7 @@ static INPUT_PORTS_START( pool10 )
PORT_DIPSETTING( 0x40, "Manual - Tickets" )
PORT_DIPSETTING( 0x60, "Manual - User Choice 2" )
- /* direct payout without play Super Game */
+// direct payout without play Super Game
PORT_DIPNAME( 0x80, 0x80, "Direct Payout (tickets)" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
@@ -1878,7 +1903,7 @@ INPUT_PORTS_END
static INPUT_PORTS_START( lunapark )
PORT_START("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* no remote credits */
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // no remote credits
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_POKER_HOLD1 ) PORT_NAME("Stop 1 / Switch Bet (1-Max)")
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_POKER_CANCEL ) PORT_NAME("Clear / Bet / Prendi (Take)")
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start / Gioca (Play)")
@@ -1930,13 +1955,13 @@ static INPUT_PORTS_START( lunapark )
PORT_DIPSETTING( 0x40, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- /* the following one seems to be disconnected
- to avoid the use of remote credits or direct payout */
+// the following one seems to be disconnected
+// to avoid the use of remote credits or direct payout
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN )
- /* the following one is connected to 1st DSW and is meant
- for switch between different programs stored in different
- halves of the program ROM */
+// the following one is connected to 1st DSW and is meant
+// for switch between different programs stored in different
+// halves of the program ROM
PORT_START("SELDSW")
PORT_DIPNAME( 0x01, 0x00, "Game Selector" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "PROGRAM 1, (5 TIRI LIRE 500, ABILITA VINTE)" )
@@ -1992,15 +2017,14 @@ static INPUT_PORTS_START( jolyjokra )
PORT_DIPSETTING( 0x00, "disabled" )
PORT_DIPSETTING( 0x10, "enabled" )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x40, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
-
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -2055,14 +2079,14 @@ static INPUT_PORTS_START( vegasslw )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -2117,14 +2141,14 @@ static INPUT_PORTS_START( vegasfst )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -2179,14 +2203,14 @@ static INPUT_PORTS_START( vegasfte )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x80, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -2241,14 +2265,14 @@ static INPUT_PORTS_START( vegasmil )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
PORT_DIPSETTING( 0x40, "No Auto Hold" )
- /* after nvram init, set the following one to 'manual'
- to allow the remote credits mode to work */
+// after nvram init, set the following one to 'manual'
+// to allow the remote credits mode to work
PORT_DIPNAME( 0x80, 0x00, "Payout" ) PORT_DIPLOCATION("SW1:1")
PORT_DIPSETTING( 0x00, "Hopper" )
PORT_DIPSETTING( 0x80, "Manual Payout SW" )
@@ -2534,7 +2558,7 @@ static INPUT_PORTS_START( witchryl )
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x20, 0x00, "Joker" ) PORT_DIPLOCATION("SW1:3")
- PORT_DIPSETTING( 0x00, "With Joker" ) /* also enable Five of a Kind */
+ PORT_DIPSETTING( 0x00, "With Joker" ) // also enables Five of a Kind
PORT_DIPSETTING( 0x20, "Without Joker" )
PORT_DIPNAME( 0x40, 0x00, "Hold" ) PORT_DIPLOCATION("SW1:2")
PORT_DIPSETTING( 0x00, "Auto Hold" )
@@ -2632,7 +2656,7 @@ INPUT_PORTS_END
static INPUT_PORTS_START( chinatow )
PORT_START("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* no remote credits */
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // no remote credits
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_POKER_HOLD1 ) PORT_NAME("Stop 1 / Switch Bet (1-Max)")
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_POKER_CANCEL ) PORT_NAME("Clear / Bet / Prendi (Take)")
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start / Gioca (Play) / Gmable")
@@ -2689,7 +2713,7 @@ INPUT_PORTS_END
static INPUT_PORTS_START( rcdino4 )
PORT_START("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* no remote credits */
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // no remote credits
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_POKER_HOLD1 ) PORT_NAME("Stop 1")
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_POKER_CANCEL ) PORT_NAME("Clear / Bet")
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start")
@@ -2746,7 +2770,7 @@ INPUT_PORTS_END
static INPUT_PORTS_START( royal )
PORT_START("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* no remote credits */
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // no remote credits
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_POKER_HOLD1 ) PORT_NAME("Stop 1 / Switch Bet (1-Max)")
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_POKER_CANCEL ) PORT_NAME("Clear / Bet / Prendi (Take)")
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start / Gioca (Play)")
@@ -2896,11 +2920,11 @@ static const gfx_layout charlayout =
in the first and second half of the bipolar PROM.
*/
-static GFXDECODE_START( gfx_fw1stpal ) /* Adressing the first half of the palette */
+static GFXDECODE_START( gfx_fw1stpal ) // Adressing the first half of the palette
GFXDECODE_ENTRY( "gfx1", 0, charlayout, 0, 16 )
GFXDECODE_END
-static GFXDECODE_START( gfx_fw2ndpal ) /* Adressing the second half of the palette */
+static GFXDECODE_START( gfx_fw2ndpal ) // Adressing the second half of the palette
GFXDECODE_ENTRY( "gfx1", 0, charlayout, 0x100, 16 )
GFXDECODE_END
@@ -2967,7 +2991,8 @@ GFXDECODE_END
*/
-/* these ports are set to output anyway, but this quietens the log */
+
+// these ports are set to output anyway, but this quietens the log
uint8_t funworld_state::funquiz_ay8910_a_r()
{
return 0x00;
@@ -2978,6 +3003,7 @@ uint8_t funworld_state::funquiz_ay8910_b_r()
return 0x00;
}
+
/********************************
* Machine Start & Reset *
********************************/
@@ -2997,14 +3023,15 @@ void lunapark_state::machine_reset()
membank("bank1")->set_entry(seldsw);
}
+
/**************************
* Machine Drivers *
**************************/
void funworld_state::fw1stpal(machine_config &config)
{
- /* basic machine hardware */
- M65SC02(config, m_maincpu, CPU_CLOCK); /* 2MHz */
+ // basic machine hardware
+ M65SC02(config, m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::funworld_map);
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0);
@@ -3018,31 +3045,31 @@ void funworld_state::fw1stpal(machine_config &config)
pia1.readpb_handler().set_ioport("DSW");
pia1.ca2_handler().set(FUNC(funworld_state::pia1_ca2_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
screen.set_refresh_hz(60);
screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
- screen.set_size((124+1)*4, (30+1)*8); /* Taken from MC6845 init, registers 00 & 04. Normally programmed with (value-1) */
- screen.set_visarea(0*4, 96*4-1, 0*8, 29*8-1); /* Taken from MC6845 init, registers 01 & 06 */
+ screen.set_size((124+1)*4, (30+1)*8); // Taken from MC6845 init, registers 00 & 04. Normally programmed with (value-1)
+ screen.set_visarea(0*4, 96*4-1, 0*8, 29*8-1); // Taken from MC6845 init, registers 01 & 06
screen.set_screen_update(FUNC(funworld_state::screen_update_funworld));
GFXDECODE(config, m_gfxdecode, m_palette, gfx_fw1stpal);
PALETTE(config, m_palette, FUNC(funworld_state::funworld_palette), 0x200);
- mc6845_device &crtc(MC6845(config, "crtc", CRTC_CLOCK)); /* 2MHz, verified on jollycrd & royalcrd */
+ mc6845_device &crtc(MC6845(config, "crtc", CRTC_CLOCK)); // 2 MHz, verified on jollycrd & royalcrd
crtc.set_screen("screen");
crtc.set_show_border_area(false);
crtc.set_char_width(4);
crtc.out_vsync_callback().set_inputline(m_maincpu, INPUT_LINE_NMI);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
- ay8910_device &ay8910(AY8910(config, "ay8910", SND_CLOCK)); /* 2MHz */
+ ay8910_device &ay8910(AY8910(config, "ay8910", SND_CLOCK)); // 2 MHz.
ay8910.port_a_write_callback().set(FUNC(funworld_state::funworld_lamp_a_w));
ay8910.port_b_write_callback().set(FUNC(funworld_state::funworld_lamp_b_w));
- ay8910.add_route(ALL_OUTPUTS, "mono", 2.5); /* analyzed to avoid clips */
+ ay8910.add_route(ALL_OUTPUTS, "mono", 2.5); // analyzed to avoid clips
}
@@ -3050,7 +3077,7 @@ void funworld_state::fw2ndpal(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::funworld_map);
m_gfxdecode->set_info(gfx_fw2ndpal);
@@ -3063,7 +3090,7 @@ void funworld_state::funquiz(machine_config &config)
fw1stpal(config); // gray background.
// fw2ndpal(config); // blue background.
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::funquiz_map);
subdevice<ay8910_device>("ay8910")->port_a_read_callback().set(FUNC(funworld_state::funquiz_ay8910_a_r));
@@ -3075,15 +3102,15 @@ void magicrd2_state::magicrd2(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &magicrd2_state::magicrd2_map);
subdevice<mc6845_device>("crtc")->set_visarea_adjust(0, -56, 0, 0);
- ay8910_device &ay8910(AY8910(config.replace(), "ay8910", SND_CLOCK)); /* 2MHz */
+ ay8910_device &ay8910(AY8910(config.replace(), "ay8910", SND_CLOCK)); // 2 MHz.
ay8910.port_a_write_callback().set(FUNC(magicrd2_state::funworld_lamp_a_w));
ay8910.port_b_write_callback().set(FUNC(magicrd2_state::funworld_lamp_b_w));
- ay8910.add_route(ALL_OUTPUTS, "mono", 1.5); /* analyzed to avoid clips */
+ ay8910.add_route(ALL_OUTPUTS, "mono", 1.5); // analyzed to avoid clips
}
@@ -3091,7 +3118,7 @@ void funworld_state::royalcd1(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* (G65SC02P in pro version) 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // (G65SC02P in pro version) 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::magicrd2_map);
}
@@ -3100,7 +3127,7 @@ void funworld_state::royalcd2(machine_config &config)
{
fw2ndpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::magicrd2_map);
}
@@ -3109,7 +3136,7 @@ void funworld_state::cuoreuno(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::cuoreuno_map);
}
@@ -3118,13 +3145,13 @@ void funworld_state::saloon(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::saloon_map);
config.device_remove("pia0");
config.device_remove("pia1");
- /* Serial Memory */
+ // Serial Memory
I2C_24C02(config, "i2cmem", 0).set_e0(1); // ? or maybe 2nd half of 24C04?
}
@@ -3133,7 +3160,7 @@ void funworld_state::witchryl(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::witchryl_map);
}
@@ -3142,7 +3169,7 @@ void lunapark_state::lunapark(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &lunapark_state::lunapark_map); // mirrored video RAM (4000/5000 to 6000/7000).
}
@@ -3151,7 +3178,7 @@ void chinatow_state::chinatow(machine_config &config)
{
fw2ndpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &chinatow_state::chinatow_map);
}
@@ -3159,7 +3186,7 @@ void chinatow_state::rcdino4(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &chinatow_state::chinatow_map);
}
@@ -3168,7 +3195,7 @@ void intergames_state::intrgmes(machine_config &config)
{
fw1stpal(config);
- M65SC02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ M65SC02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &intergames_state::intergames_map);
//m_maincpu->set_periodic_int(FUNC(intergames_state::nmi_line_pulse), attotime::from_hz(60));
@@ -3180,7 +3207,7 @@ void funworld_state::fw_brick_1(machine_config &config)
{
fw1stpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::fw_brick_map);
NVRAM(config, "nvram1", nvram_device::DEFAULT_ALL_0);
@@ -3191,12 +3218,22 @@ void funworld_state::fw_brick_2(machine_config &config)
{
fw2ndpal(config);
- R65C02(config.replace(), m_maincpu, CPU_CLOCK); /* 2MHz */
+ R65C02(config.replace(), m_maincpu, CPU_CLOCK); // 2 MHz.
m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::fw_brick_map);
NVRAM(config, "nvram1", nvram_device::DEFAULT_ALL_0);
}
+
+void funworld_state::gratispk(machine_config &config)
+{
+// fw1stpal(config); // card deck wrong colors.
+ fw2ndpal(config); // correct palette
+
+ m_maincpu->set_addrmap(AS_PROGRAM, &funworld_state::gratispk_map);
+}
+
+
uint8_t royalcrdf_state::royalcrdf_opcode_r(offs_t offset)
{
// address-based data bitswap; 4 address bits are involved, but only
@@ -3210,39 +3247,39 @@ uint8_t royalcrdf_state::royalcrdf_opcode_r(offs_t offset)
// 1-bit-to-1-bit bitswaps; furthermore, in both sets one of the
// bitswaps is equal to the one applied to all the data (but notice
// that, in those cases, we are applying it twice to opcodes here)
- constexpr std::array<std::array<int,4>,16> bs{{ // bitswaps for data bits 1,2,5 & 7, in that order
- { 1,5,2,7 },
- { 1,5,2,7 },
- { 5,1,7,2 },
- { 7,2,5,1 },
- { 1,5,2,7 },
- { 1,5,2,7 },
- { 5,2,1,7 },
- { 7,2,5,1 },
- { 1,5,2,7 },
- { 1,5,2,7 },
- { 5,1,7,2 },
- { 1,7,5,2 },
- { 1,5,2,7 },
- { 1,5,2,7 },
- { 5,2,1,7 },
- { 1,7,5,2 }
+ constexpr std::array<std::array<int, 4>, 16> bs{{ // bitswaps for data bits 1, 2, 5 & 7, in that order
+ { 1, 5, 2, 7 },
+ { 1, 5, 2, 7 },
+ { 5, 1, 7, 2 },
+ { 7, 2, 5, 1 },
+ { 1, 5, 2, 7 },
+ { 1, 5, 2, 7 },
+ { 5, 2, 1, 7 },
+ { 7, 2, 5, 1 },
+ { 1, 5, 2, 7 },
+ { 1, 5, 2, 7 },
+ { 5, 1, 7, 2 },
+ { 1, 7, 5, 2 },
+ { 1, 5, 2, 7 },
+ { 1, 5, 2, 7 },
+ { 5, 2, 1, 7 },
+ { 1, 7, 5, 2 }
}};
// xor masks, dependent on the same address bits than the bitswaps,
// and with the same 5-values structure
- constexpr std::array<uint8_t,16> xm {
+ constexpr std::array<uint8_t, 16> xm {
0x02, 0x02, 0xa6, 0x82, 0x02, 0x02, 0x06, 0x82, 0x02, 0x02, 0xa6, 0x00, 0x02, 0x02, 0x06, 0x00
};
uint8_t data {_maincpu->space(AS_PROGRAM).read_byte(offset)};
- if(offset<0x800)
- data = bitswap<8>(data^0x22,2,6,7,4,3,1,5,0);
+ if(offset < 0x800)
+ data = bitswap<8>(data ^ 0x22, 2, 6, 7, 4, 3, 1, 5, 0);
- unsigned idx {bitswap<4>(offset, 8,5,2,1)};
+ unsigned idx {bitswap<4>(offset, 8, 5, 2, 1)};
- return bitswap<8>(data, bs[idx][3],6,bs[idx][2],4,3,bs[idx][1],bs[idx][0],0) ^ xm[idx];
+ return bitswap<8>(data, bs[idx][3], 6, bs[idx][2], 4, 3, bs[idx][1], bs[idx][0], 0) ^ xm[idx];
}
void royalcrdf_state::royalcrdf_opcodes_map(address_map &map)
@@ -3255,15 +3292,15 @@ void royalcrdf_state::driver_init()
uint8_t *ROM = memregion("maincpu")->base();
for (int x = 0x8000; x < 0x10000; x++)
{
- ROM[x] = bitswap<8>(ROM[x]^0x22,2,6,7,4,3,1,5,0);
+ ROM[x] = bitswap<8>(ROM[x] ^ 0x22, 2, 6, 7, 4, 3, 1, 5, 0);
}
/* Temporary hack to modify the value that ends to be a NOP,
after the BRK, and balanced checksums. Will be removed once
found a workaround in the decryption routines.
*/
- ROM[0x802d]=0xa2; // checksum.
- ROM[0xbc4e]=0x68; // future NOP after BRK.
+ ROM[0x802d] = 0xa2; // checksum.
+ ROM[0xbc4e] = 0x68; // future NOP after BRK.
}
void royalcrdf_state::royalcrdf(machine_config &config)
@@ -3285,19 +3322,19 @@ uint8_t multiwin_state::multiwin_opcode_r(offs_t offset)
// one of the address bits don't have effect on the bitswap, just on the xor;
// again, we have just five different bitswaps, and the hardware is probably using
// passive logic on the address bits to do the selection
- constexpr std::array<std::array<int,5>,8> bs{{ // bitswaps for data bits 0,2,4,5 & 7, in that order
- { 5,2,4,0,7 },
- { 4,0,2,7,5 },
- { 7,4,5,2,0 },
- { 4,0,2,7,5 },
- { 2,7,0,5,4 },
- { 4,0,2,7,5 },
- { 0,5,7,4,2 },
- { 4,0,2,7,5 }
+ constexpr std::array<std::array<int, 5>, 8> bs{{ // bitswaps for data bits 0, 2, 4, 5 & 7, in that order
+ { 5, 2, 4, 0, 7 },
+ { 4, 0, 2, 7, 5 },
+ { 7, 4, 5, 2, 0 },
+ { 4, 0, 2, 7, 5 },
+ { 2, 7, 0, 5, 4 },
+ { 4, 0, 2, 7, 5 },
+ { 0, 5, 7, 4, 2 },
+ { 4, 0, 2, 7, 5 }
}};
// xor masks
- constexpr std::array<uint8_t,16> xm {
+ constexpr std::array<uint8_t, 16> xm {
0x00, 0x00, 0x10, 0x00, 0x20, 0x00, 0x30, 0x00, 0x00, 0xb5, 0x10, 0xb5, 0x20, 0xb5, 0x30, 0xb5
};
@@ -3317,7 +3354,7 @@ void multiwin_state::driver_init()
uint8_t *ROM = memregion("maincpu")->base();
for (int x = 0x4000; x < 0x10000; x++)
{
- ROM[x] = bitswap<8>(ROM[x]^0x91,5,6,7,2,3,0,1,4);
+ ROM[x] = bitswap<8>(ROM[x] ^ 0x91, 5, 6, 7, 2, 3, 0, 1, 4);
}
}
@@ -3357,7 +3394,7 @@ uint8_t powercrd_state::powercrd_opcode_r(offs_t offset)
constexpr uint8_t UNKN {0xfc};
- constexpr std::array<std::array<uint8_t,256>,4> decryption_tables{{
+ constexpr std::array<std::array<uint8_t, 256>, 4> decryption_tables{{
// _0 _1 _2 _3 _4 _5 _6 _7 _8 _9 _a _b _c _d _e _f
{ 0xe8, 0x29, UNKN, UNKN, 0x85, UNKN, 0x18, UNKN, UNKN, UNKN, UNKN, UNKN, UNKN, UNKN, UNKN, 0xd5, // 0_
UNKN, UNKN, 0xa6, 0x4c, UNKN, UNKN, 0x84, UNKN, UNKN, UNKN, 0x69, UNKN, 0x91, 0x38, 0xa8, UNKN, // 1_
@@ -3432,7 +3469,7 @@ uint8_t powercrd_state::powercrd_opcode_r(offs_t offset)
}};
uint8_t data {_maincpu->space(AS_PROGRAM).read_byte(offset)};
- return decryption_tables[offset&3][data];
+ return decryption_tables[offset & 3][data];
}
void powercrd_state::powercrd_opcodes_map(address_map &map)
@@ -3472,7 +3509,7 @@ uint8_t megacard_state::megacard_opcode_r(offs_t offset)
constexpr uint8_t UNKN {0xfc};
- constexpr std::array<std::array<uint8_t,256>,4> decryption_tables{{
+ constexpr std::array<std::array<uint8_t, 256>, 4> decryption_tables{{
// _0 _1 _2 _3 _4 _5 _6 _7 _8 _9 _a _b _c _d _e _f
{ UNKN, 0x6c, UNKN, UNKN, UNKN, 0xfa, 0x38, UNKN, UNKN, 0x4c, 0xd8, UNKN, 0xe8, UNKN, 0xc5, UNKN, // 0_
UNKN, 0xa6, 0x91, UNKN, UNKN, UNKN, UNKN, 0x58, 0xa0, 0xe0, 0xb9, 0x4e, UNKN, UNKN, UNKN, 0x78, // 1_
@@ -3547,7 +3584,7 @@ uint8_t megacard_state::megacard_opcode_r(offs_t offset)
}};
uint8_t data {_maincpu->space(AS_PROGRAM).read_byte(offset)};
- return decryption_tables[offset&3][data];
+ return decryption_tables[offset & 3][data];
}
void megacard_state::megacard_opcodes_map(address_map &map)
@@ -3621,7 +3658,7 @@ uint8_t jokercrd_state::jokercrd_opcode_r(offs_t offset)
constexpr uint8_t UNKN {0xfc};
- constexpr std::array<std::array<uint8_t,256>,4> decryption_tables{{
+ constexpr std::array<std::array<uint8_t, 256>, 4> decryption_tables{{
// _0 _1 _2 _3 _4 _5 _6 _7 _8 _9 _a _b _c _d _e _f
{ UNKN, UNKN, UNKN, 0x3d, 0xe0, UNKN, UNKN, 0xb0, UNKN, 0xa0, UNKN, UNKN, UNKN, UNKN, UNKN, UNKN, // 0_
UNKN, UNKN, 0x4a, 0x65, 0x18, 0x64, 0xad, UNKN, 0x90, UNKN, UNKN, UNKN, UNKN, UNKN, UNKN, UNKN, // 1_
@@ -3696,7 +3733,7 @@ uint8_t jokercrd_state::jokercrd_opcode_r(offs_t offset)
}};
uint8_t data {_maincpu->space(AS_PROGRAM).read_byte(offset)};
- return decryption_tables[offset&3][data];
+ return decryption_tables[offset & 3][data];
}
void jokercrd_state::jokercrd_opcodes_map(address_map &map)
@@ -3794,7 +3831,7 @@ ROM_START( jollycrd )
ROM_LOAD( "jolycard.ch2", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jolycard.ch1", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jollycrd_nvram.bin", 0x0000, 0x0800, CRC(8f0a86c9) SHA1(467bd4f601ac6aa818c036f1269c2d43d27854f6) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -3830,13 +3867,13 @@ ROM_START( jollycrda )
ROM_LOAD( "tab3.bin", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "tab2.bin", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* Default NVRAM. The game doesn't work without it */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM. the game doesn't work without it
ROM_LOAD( "jollycrda_nvram.bin", 0x0000, 0x0800, CRC(5cbb4d8f) SHA1(da5edbef20bb4f0c634939389b3a9744c5743641) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "jop.bin", 0x0000, 0x0200, CRC(5ebc5659) SHA1(8d59011a181399682ab6e8ed14f83101e9bfa0c6) )
- ROM_REGION( 0x0200, "plds", 0 ) /* Cracked PLD */
+ ROM_REGION( 0x0200, "plds", 0 ) // cracked PLD
ROM_LOAD( "tab1.0_gal16v8s.bin", 0x0000, 0x0117, CRC(574f9a48) SHA1(bb5e2e86da85130d92f61cc57038a844950f443e) )
ROM_END
@@ -3849,7 +3886,7 @@ ROM_START( jolyc3x3 )
ROM_LOAD( "jolycard.ch2", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jolycard.ch1", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyc3x3_nvram.bin", 0x0000, 0x0800, CRC(727c70cf) SHA1(3639b0891514064e21ebdb280791cc9c8f5ba481) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -3914,18 +3951,20 @@ ROM_END
*/
ROM_START( jolycmzs )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* MZS Tech */
+ ROM_REGION( 0x10000, "maincpu", 0 ) // MZS Tech
ROM_LOAD( "mzstech.bin", 0x8000, 0x8000, CRC(cebd1e56) SHA1(24d88b3383cecf3829556d75460053663aab4ef1) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "jolycard.ch2", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jolycard.ch1", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
-/* Load a default eeprom, otherwise an annoying password system should be inserted with
- inputs correlated to a code that pops up on the screen.
- This code should be inserted into a PC-DOS program, that program is nowhere to be found right now.
+/* Load a default NVRAM, otherwise an annoying password system appears
+ generating a code that needs to be parsed by a PC-DOS program, that
+ is currently missing and never would appear. This program is supossed
+ to give back an hexa code to feed in the game through a combination
+ of inputs.
*/
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycmzs_nvram.bin", 0x0000, 0x0800, CRC(828ffeef) SHA1(6a52282231f1944ba79049f267a9c1941373aea2) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -3933,18 +3972,20 @@ ROM_START( jolycmzs )
ROM_END
ROM_START( jolyc980 )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* Spale Soft */
+ ROM_REGION( 0x10000, "maincpu", 0 ) // Spale Soft
ROM_LOAD( "j980.bin", 0x8000, 0x8000, CRC(48249fff) SHA1(390cd0eb3399446a66363dc6760458170e1970fd) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "jolycard.ch2", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jolycard.ch1", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
-/* Load a default eeprom, otherwise an annoying password system should be inserted with
- inputs correlated to a code that pops up on the screen.
- This code should be inserted into a PC-DOS program, that program is nowhere to be found right now.
+/* Load a default NVRAM, otherwise an annoying password system appears
+ generating a code that needs to be parsed by a PC-DOS program, that
+ is currently missing and never would appear. This program is supossed
+ to give back an hexa code to feed in the game through a combination
+ of inputs.
*/
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyc980_nvram.bin", 0x0000, 0x0800, CRC(ef2c89c7) SHA1(a286001e205dcd16d914e07ba2b7c820335ab9c2) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -3952,7 +3993,7 @@ ROM_START( jolyc980 )
ROM_END
-ROM_START( jolycdev ) /* Jolly Card (lipa) from Evona */
+ROM_START( jolycdev ) // Jolly Card (lipa) from Evona
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "lipa.bin", 0x8000, 0x8000, CRC(62657c98) SHA1(237466dde26540c119c631c75f51c87ea59d1a91) )
@@ -3960,7 +4001,7 @@ ROM_START( jolycdev ) /* Jolly Card (lipa) from Evona */
ROM_LOAD( "jollyb.bin", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jollya.bin", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdev_nvram.bin", 0x0000, 0x0800, CRC(ae2c2fb8) SHA1(912d673ea8e26ff62520a7b86e702e5260cff4c0) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -3989,7 +4030,7 @@ ROM_END
Only remote credits, as can be seen in test mode.
*/
-ROM_START( jolyccra ) /* Jolly Card (croatian, set 1) */
+ROM_START( jolyccra ) // Jolly Card (Croatian, set 1)
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "jollyc.bin", 0x8000, 0x8000, CRC(8926d99d) SHA1(dd5d1ac03d30d823dfcfe1349328ecb7afbc37fa) )
@@ -3997,7 +4038,7 @@ ROM_START( jolyccra ) /* Jolly Card (croatian, set 1) */
ROM_LOAD( "jollyb.bin", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jollya.bin", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyccra_nvram.bin", 0x0000, 0x0800, CRC(478ab0a9) SHA1(8c5160d2ac8d4a9db0ae1e478d3bb1513a04544f) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4005,7 +4046,7 @@ ROM_START( jolyccra ) /* Jolly Card (croatian, set 1) */
ROM_END
-ROM_START( jolyccrb ) /* Jolly Card (croatian, set 2) */
+ROM_START( jolyccrb ) // Jolly Card (Croatian, set 2)
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "jollypkr.003", 0x8000, 0x8000, CRC(ea7340b4) SHA1(7dd468f28a488a4781521809d06db1d7917048ad) )
@@ -4013,7 +4054,7 @@ ROM_START( jolyccrb ) /* Jolly Card (croatian, set 2) */
ROM_LOAD( "jolycard.ch2", 0x0000, 0x8000, CRC(c512b103) SHA1(1f4e78e97855afaf0332fb75e1b5571aafd01c29) )
ROM_LOAD( "jolycard.ch1", 0x8000, 0x8000, CRC(0f24f39d) SHA1(ac1f6a8a4a2a37cbc0d45c15187b33c25371bffb) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyccrb_nvram.bin", 0x0000, 0x0800, CRC(c1d49c88) SHA1(27ffdedfc7f09ff11c3b2537db3681473b776074) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4043,7 +4084,7 @@ ROM_END
- 1x trimmer (volume)(missing)
*/
-ROM_START( jolycdit ) /* blue TAB PCB, encrypted graphics */
+ROM_START( jolycdit ) // blue TAB PCB, encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "jn.bin", 0x8000, 0x8000, CRC(6ae00ed0) SHA1(5921c2882aeb5eadd0e04a477fa505ad35e9d98c) )
@@ -4051,7 +4092,7 @@ ROM_START( jolycdit ) /* blue TAB PCB, encrypted graphics */
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(46805150) SHA1(63687ac44f6ace6d8924b2629536bcc7d3979ed2) )
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(43bcb2df) SHA1(5022bc3a0b852a7cd433e25c3c90a720e6328261) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdit_nvram.bin", 0x0000, 0x0800, CRC(c55c6706) SHA1(a38ae926f057fb47e48ca841b2d097fc4fd06416) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4063,7 +4104,7 @@ ROM_END
/*
- Jolly Card (italian encrypted bootleg)
+ Jolly Card (Italian encrypted bootleg)
--------------------------------------
- 1x UM6845P
@@ -4093,7 +4134,7 @@ ROM_END
Only remote credits, as can be seen in test mode.
*/
-ROM_START( jolycdib ) /* bootleg PCB, encrypted graphics */
+ROM_START( jolycdib ) // bootleg PCB, encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3.bin", 0x8000, 0x8000, CRC(c76fdc79) SHA1(fc75c274d64fa9c99a546d424f38e79f1acf2576) )
@@ -4101,7 +4142,7 @@ ROM_START( jolycdib ) /* bootleg PCB, encrypted graphics */
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(46805150) SHA1(63687ac44f6ace6d8924b2629536bcc7d3979ed2) ) // sldh
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(43bcb2df) SHA1(5022bc3a0b852a7cd433e25c3c90a720e6328261) ) // sldh
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdib_nvram.bin", 0x0000, 0x0800, CRC(038a71fe) SHA1(99d3befbee8f9f86ce7f074de7f16fb25053c077) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4113,7 +4154,7 @@ ROM_END
/*
- Jolly Card (italian encrypted bootleg, set 2)
+ Jolly Card (Italian encrypted bootleg, set 2)
---------------------------------------------
This program works in both 'normal' and 'remote' modes,
@@ -4127,18 +4168,18 @@ ROM_END
buttons.
*/
-ROM_START( jolycdic ) /* another bootleg PCB, encrypted graphics */
+ROM_START( jolycdic ) // another bootleg PCB, encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3ss.bin", 0x8000, 0x8000, CRC(3d7cde61) SHA1(6154878491f4d2f1ea035d18cdf43154c550d509) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(32c24495) SHA1(0d78c4d2743401b5ec9919d09814064eeac8023f) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(91093176) SHA1(b889c617f94161933c35c324c7d84fec182953d8) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdic_nvram.bin", 0x0000, 0x0800, CRC(47a5890b) SHA1(6a6531fe5e8f6c1b5a9aac314b2cce6a0129f6da) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4148,6 +4189,44 @@ ROM_START( jolycdic ) /* another bootleg PCB, encrypted graphics */
ROM_LOAD( "gal16v8b.bin", 0x0000, 0x0117, NO_DUMP ) // sldh
ROM_END
+/*
+ Jolly Card (Italian encrypted bootleg, set 3)
+ ---------------------------------------------
+
+ Running in a Cleco bootleg board.
+ Encrypted GFX.
+
+ Differences: 1 byte.
+
+ jolycdib jolycdic
+
+ C1D6: 0x60 0x10
+
+ C1E5: lda #$60 lda #$10
+ C1E7: sta $0000 sta $0000
+ C1EA: sta $0003 sta $0003
+ C1ED: sta $07f8 sta $07f8
+
+*/
+ROM_START( jolycdii )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "145-3.bin", 0x8000, 0x8000, CRC(812f88f1) SHA1(d387b7e4818dc6f5f2b6161a623c6e4f1eeedf2a) )
+
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "145-2.bin", 0x0000, 0x8000, CRC(46805150) SHA1(63687ac44f6ace6d8924b2629536bcc7d3979ed2) )
+ ROM_LOAD( "145-1.bin", 0x8000, 0x8000, CRC(43bcb2df) SHA1(5022bc3a0b852a7cd433e25c3c90a720e6328261) )
+
+ ROM_REGION( 0x0800, "nvram", 0 ) // Default NVRAM
+ ROM_LOAD( "jolycdii_nvram.bin", 0x0000, 0x0800, CRC(c2a138ad) SHA1(463fed8b495fa5286513f52fa09cf97f29e5f40e) )
+
+ ROM_REGION( 0x0800, "proms", 0 ) // Not a bipolar PROM. Just a replacement.
+ ROM_LOAD( "ws57c291_d27hc65d.bin", 0x0000, 0x0200, CRC(d96f3760) SHA1(07e80baf9c6c08171195b7810261e043197a9c3c) )
+ ROM_IGNORE( 0x0600 ) // empty
+
+ ROM_REGION( 0x0200, "plds", 0 )
+ ROM_LOAD( "gal16v8b.bin", 0x0000, 0x0117, NO_DUMP )
+ROM_END
+
/* Jolly Card Italian bootleg...
@@ -4188,17 +4267,17 @@ ROM_END
1x Unknown POT between two caps, maybe for sound amp stage.
*/
-ROM_START( jolycdid ) /* Altera EP910PC CPLD */
+ROM_START( jolycdid ) // Altera EP910PC CPLD
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "5.cpu", 0x8000, 0x8000, CRC(56158851) SHA1(abf1daad1198dcc017352742e3c00d57e8955bd4) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "7.bin", 0x0000, 0x8000, CRC(a4452751) SHA1(a0b32a8801ebaee7ede7873b244f1a424433fe94) )
- ROM_CONTINUE( 0x0000, 0x8000) /* Discarding 1nd half 1ST AND 2ND HALF IDENTICAL*/
+ ROM_CONTINUE( 0x0000, 0x8000) // Discarding 1nd half. 1ST AND 2ND HALF IDENTICAL
ROM_LOAD( "6.bin", 0x8000, 0x8000, CRC(8b64d4c6) SHA1(8106cba31cd3fbda0855e6070182d248e3d52495) )
- ROM_CONTINUE( 0x8000, 0x8000) /* Discarding 1nd half 1ST AND 2ND HALF IDENTICAL*/
+ ROM_CONTINUE( 0x8000, 0x8000) // Discarding 1nd half. 1ST AND 2ND HALF IDENTICAL
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdid_nvram.bin", 0x0000, 0x0800, CRC(6eb66015) SHA1(39490cf5d404c9e9fb58439f6d9876a3e9b29ba0) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4218,7 +4297,7 @@ ROM_END
used by another program.
*/
-ROM_START( jolycdie ) /* Bootleg PCB, NON encrypted graphics */
+ROM_START( jolycdie ) // Bootleg PCB, NON encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "aic.cpu", 0x8000, 0x8000, CRC(56158851) SHA1(abf1daad1198dcc017352742e3c00d57e8955bd4) )
@@ -4226,7 +4305,7 @@ ROM_START( jolycdie ) /* Bootleg PCB, NON encrypted graphics */
ROM_LOAD( "c.bin", 0x0000, 0x8000, CRC(eff5362c) SHA1(1c9a48866dc5ee37fad6d68465f326d243c821c3) )
ROM_LOAD( "b.bin", 0x8000, 0x8000, CRC(98309e14) SHA1(0d3e3766768fafc728a08668ad693f950d1fabab) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdie_nvram.bin", 0x0000, 0x0800, CRC(1b2fba44) SHA1(be5c956517072581edaebe9ae440a542964c8490) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4242,15 +4321,15 @@ ROM_END
5 & 6 are coins.
W is payout.
*/
-ROM_START( jolycdif ) /* Altera EP910PC CPLD */
+ROM_START( jolycdif ) // Altera EP910PC CPLD
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(80983f6a) SHA1(222ce5d4800887de92a73decbad31e96f8da3b4a) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(a4452751) SHA1(a0b32a8801ebaee7ede7873b244f1a424433fe94) )
- ROM_CONTINUE( 0x0000, 0x8000) /* Discarding 1nd half 1ST AND 2ND HALF IDENTICAL*/
+ ROM_CONTINUE( 0x0000, 0x8000) // Discarding 1nd half. 1ST AND 2ND HALF IDENTICAL
ROM_LOAD( "3.bin", 0x8000, 0x8000, CRC(2856c82d) SHA1(7ce835bc2246ffede180cff0d8d0d4528afcc297) )
- ROM_CONTINUE( 0x8000, 0x8000) /* Discarding 1nd half 1ST AND 2ND HALF IDENTICAL*/
+ ROM_CONTINUE( 0x8000, 0x8000) // Discarding 1nd half. 1ST AND 2ND HALF IDENTICAL
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "82s147.bin", 0x0000, 0x0200, CRC(5ebc5659) SHA1(8d59011a181399682ab6e8ed14f83101e9bfa0c6) ) // proper dump
@@ -4311,9 +4390,9 @@ ROM_START( jolycdih )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "3.bin", 0x0000, 0x8000, CRC(a4452751) SHA1(a0b32a8801ebaee7ede7873b244f1a424433fe94) )
- ROM_CONTINUE( 0x0000, 0x8000) /* Discarding 1nd half 1ST AND 2ND HALF IDENTICAL*/
+ ROM_CONTINUE( 0x0000, 0x8000) // Discarding 1nd half. 1ST AND 2ND HALF IDENTICAL
ROM_LOAD( "2.bin", 0x8000, 0x8000, CRC(8b64d4c6) SHA1(8106cba31cd3fbda0855e6070182d248e3d52495) )
- ROM_CONTINUE( 0x8000, 0x8000) /* Discarding 1nd half 1ST AND 2ND HALF IDENTICAL*/
+ ROM_CONTINUE( 0x8000, 0x8000) // Discarding 1nd half. 1ST AND 2ND HALF IDENTICAL
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "dm74s472n.bin", 0x0000, 0x0200, CRC(5ebc5659) SHA1(8d59011a181399682ab6e8ed14f83101e9bfa0c6) )
@@ -4322,11 +4401,11 @@ ROM_START( jolycdih )
ROM_LOAD( "ep910.bin", 0x0000, 0x0884, CRC(aa62207e) SHA1(a2e51cf3617d07ff1ce42ee1d56e1c17b6fe71de) )
ROM_LOAD( "pal16v8h-25pc-4.bin", 0x0900, 0x0117, CRC(df5be97d) SHA1(8cd63d49ab7020cdec07c1198413dc7d93e90d35) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolycdih_nvram.bin", 0x0000, 0x0800, CRC(02b3b335) SHA1(207a1289e4298d942e4806adf8ffb87e0b9b4e58) )
ROM_END
-ROM_START( sjcd2kx3 ) /* Super Joly 2000 3x */
+ROM_START( sjcd2kx3 ) // Super Joly 2000 3x
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "sj3.bin", 0x8000, 0x8000, CRC(c530b518) SHA1(36934d8e1e2cb2f71eb44a05b86ec970c9f398cd) )
@@ -4334,7 +4413,7 @@ ROM_START( sjcd2kx3 ) /* Super Joly 2000 3x */
ROM_LOAD( "sj2.bin", 0x0000, 0x8000, CRC(d7253325) SHA1(ad40e662519da9b11f77690b7d41c5007f74e280) )
ROM_LOAD( "sj1.bin", 0x8000, 0x8000, CRC(82741749) SHA1(d0bf3073dff9ba1c4913fd754f965951e9cb5b03) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "sjcd2kx3_nvram.bin", 0x0000, 0x0800, CRC(1141368b) SHA1(b4af2d59b5e8115440e1219a621cfd2fb8c2c978) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4500,7 +4579,7 @@ ROM_START( bigdeal )
ROM_LOAD( "poker4.003", 0x0000, 0x8000, CRC(8c33a15f) SHA1(a1c8451c99a23eeffaedb21d1a1b69f54629f8ab) )
ROM_LOAD( "poker4.002", 0x8000, 0x8000, CRC(5f4e12d8) SHA1(014b2364879faaf4922cdb82ee07692389f20c2d) )
- ROM_REGION( 0x0200, "proms", 0 ) /* using joker card palette till a correct dump appear */
+ ROM_REGION( 0x0200, "proms", 0 ) // using joker card palette till a correct dump appear
ROM_LOAD( "jokercrd_prom.bin", 0x0000, 0x0200, BAD_DUMP CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) )
ROM_END
@@ -4513,7 +4592,7 @@ ROM_START( bigdealb )
ROM_LOAD( "poker4.003", 0x0000, 0x8000, CRC(8c33a15f) SHA1(a1c8451c99a23eeffaedb21d1a1b69f54629f8ab) )
ROM_LOAD( "poker4.002", 0x8000, 0x8000, CRC(5f4e12d8) SHA1(014b2364879faaf4922cdb82ee07692389f20c2d) )
- ROM_REGION( 0x0200, "proms", 0 ) /* using joker card palette till a correct dump appear */
+ ROM_REGION( 0x0200, "proms", 0 ) // using joker card palette till a correct dump appear
ROM_LOAD( "jokercrd_prom.bin", 0x0000, 0x0200, BAD_DUMP CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) )
ROM_END
@@ -4548,16 +4627,16 @@ ROM_START( cuoreuno )
ROM_LOAD( "cuore1b.u21", 0x0000, 0x8000, CRC(14eca2b8) SHA1(35cba415800c6cd3e6ed9946057f33510ad2bfc9) )
ROM_LOAD( "cuore1c.u22", 0x8000, 0x8000, CRC(253fac84) SHA1(1ad104ab8e8d73df6397a840a4b26565b245d7a3) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "cuoreuno_nvram.bin", 0x0000, 0x0800, CRC(b5a1bf25) SHA1(c2996a28c080debf10ab7a7dc47c305aed172a83) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29_cu.bin", 0x0000, 0x0200, CRC(7ea61749) SHA1(3167acd79f9bda2078c2af3e049ad6abf160aeae) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_cu.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_cu.u22", 0x0200, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_cu.u23", 0x0400, 0x0157, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_cu.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_cu.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_cu.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4588,24 +4667,24 @@ ROM_END
ROM_START( elephfam )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "eleph_a.u2", 0x8000, 0x8000, CRC(8392b842) SHA1(74c850c734ca8174167b2f826b9b1ac902669392) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "eleph_b.u21", 0x0000, 0x8000, CRC(e3612670) SHA1(beb65f7d2bd6d7bc68cfd876af51910cf6417bd0) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "eleph_c.u22", 0x8000, 0x8000, CRC(4b909bf3) SHA1(a822b12126bc58af6d3f999ab2117370015a039b) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "elephfam_nvram.bin", 0x0000, 0x0800, CRC(fb9b1100) SHA1(cf15ce55042f1c4399fec480c2f862622905a8b5) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29_ef.u25", 0x0000, 0x0200, CRC(bca8b82a) SHA1(4aa19f5ecd9953bf8792dceb075a746f77c01cfc) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_ef.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_ef.u22", 0x0200, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_ef.u23", 0x0400, 0x0157, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_ef.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_ef.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_ef.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4617,16 +4696,16 @@ ROM_START( elephfmb )
ROM_LOAD( "elephb.u21", 0x0000, 0x8000, CRC(3c60549c) SHA1(c839b3ea415a877e5eac04e0522c342cce8d6e64) )
ROM_LOAD( "elephc.u20", 0x8000, 0x8000, CRC(448ba955) SHA1(2785cbc8cd42a7dda85bd8b81d5fbec01a1ba0bd) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "elephfmb_nvram.bin", 0x0000, 0x0800, CRC(13a0cfea) SHA1(9c8ce509ef1076e88ea853347b64c5591bc2e18c) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29_ef.u25", 0x0000, 0x0200, CRC(bca8b82a) SHA1(4aa19f5ecd9953bf8792dceb075a746f77c01cfc) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_ef.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_ef.u22", 0x0200, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_ef.u23", 0x0400, 0x0157, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_ef.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_ef.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_ef.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4736,16 +4815,16 @@ ROM_START( pool10 )
ROM_LOAD( "2.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "1.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10_nvram.bin", 0x0000, 0x0800, CRC(2f2fab43) SHA1(f815b70c171bad99fa6a60c256e4fdc85dd6b290) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147an_p10.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4756,28 +4835,28 @@ ROM_END
u20.bin 1ST AND 2ND HALF IDENTICAL
u21.bin 1ST AND 2ND HALF IDENTICAL
*/
- ROM_START( pool10b ) /* this set should be the parent */
+ ROM_START( pool10b ) // 1st set nominated for parent
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "u2.bin", 0x8000, 0x8000, CRC(64fee38e) SHA1(8a624a0b6eb4a3ba09e5b396dc5a01994dfdf294) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- /* GFX ROMs are the same of pool10, but double sized with identical halves. */
+// GFX ROMs are the same of pool10, but double sized with identical halves.
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "u21.bin", 0x0000, 0x8000, CRC(581c4878) SHA1(5ae61af090feea1745e22f46b33b2c01e6013fbe) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "u20.bin", 0x8000, 0x8000, CRC(3bdf1106) SHA1(fa21cbd49bb27ea4a784cf4e4b3fbd52650a285b) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10b_nvram.bin", 0x0000, 0x0800, CRC(d9f35299) SHA1(2c3608bc9c322a9cc86f74d8fa2f660804a8cf3c) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147an_p10.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10b.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_p10b.u22", 0x0200, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_p10b.u23", 0x0400, 0x0157, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_p10b.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_p10b.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_p10b.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4789,16 +4868,16 @@ ROM_START( pool10c )
ROM_LOAD( "b.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "c.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10c_nvram.bin", 0x0000, 0x0800, CRC(396aefed) SHA1(066b87ff054dfb37f733a812ad0dc1b1bd2478e6) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147an_p10.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4810,22 +4889,22 @@ ROM_END
ROM_START( pool10d )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3.50.u2", 0x8000, 0x8000, CRC(4c68e1f4) SHA1(bbab63a18e0c041ce519daa32e12dd1b6a672dce) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "2.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) ) // sldh
ROM_LOAD( "1.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) ) // sldh
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10d_nvram.bin", 0x0000, 0x0800, CRC(6b5984a0) SHA1(156a94e74e33b1a15222cffff9b62e65f6f5f2f5) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147an_p10.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -4913,23 +4992,19 @@ ROM_START( pool10e )
ROM_LOAD( "2.u21", 0x0000, 0x8000, CRC(a0d54044) SHA1(c7be1f12f72095daee32ae41c3554d8ab4f99245) ) // sldh
ROM_LOAD( "1.u20", 0x8000, 0x8000, CRC(55c9fcc8) SHA1(224bdf63ed345b1def4852af3b33f07790fbf123) ) // sldh
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10e_nvram.bin", 0x0000, 0x0800, CRC(e20f9a14) SHA1(617ca53263a971c9f835a95737a66fac5b99780f) )
- ROM_REGION( 0x0200, "proms", 0 ) /* Same as Pool 10, but the 1st half duplicated to cover any PLD addressing */
+ ROM_REGION( 0x0200, "proms", 0 ) // Same as Pool 10, but the 1st half duplicated to cover any PLD addressing
ROM_LOAD( "am27s29.u25", 0x0000, 0x0200, CRC(2c315cbf) SHA1(f3f91329f2b8388decf26a050f8fb7da38694218) )
ROM_REGION( 0x3000, "plds", 0 )
- ROM_LOAD( "palce16v8h.u5", 0x0000, 0x0892, BAD_DUMP CRC(123d539a) SHA1(cccf0cbae3175b091a998eedf4aa44a55b679400) ) /* read protected */
- ROM_LOAD( "palce20v8h.u22", 0x1000, 0x0a92, BAD_DUMP CRC(ba2a021f) SHA1(e9c5970f80c7446c91282d53cfe97c92353dce7d) ) /* read protected */
- ROM_LOAD( "palce20v8h.u23", 0x2000, 0x0a92, BAD_DUMP CRC(ba2a021f) SHA1(e9c5970f80c7446c91282d53cfe97c92353dce7d) ) /* read protected */
+ ROM_LOAD( "palce16v8h.u5", 0x0000, 0x0892, BAD_DUMP CRC(123d539a) SHA1(cccf0cbae3175b091a998eedf4aa44a55b679400) ) // read protected
+ ROM_LOAD( "palce20v8h.u22", 0x1000, 0x0a92, BAD_DUMP CRC(ba2a021f) SHA1(e9c5970f80c7446c91282d53cfe97c92353dce7d) ) // read protected
+ ROM_LOAD( "palce20v8h.u23", 0x2000, 0x0a92, BAD_DUMP CRC(ba2a021f) SHA1(e9c5970f80c7446c91282d53cfe97c92353dce7d) ) // read protected
ROM_END
-/*
-
-*/
-
ROM_START( pool10f )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "cmc-pool10+a+.u2", 0x8000, 0x8000, CRC(e8087fb8) SHA1(c012a81f561978bd97708a52f656e7b13e41a3e2) ) // sldh
@@ -4938,20 +5013,20 @@ ROM_START( pool10f )
ROM_LOAD( "cmc-pool10-b.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "cmc-pool10-c.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10f_nvram.bin", 0x0000, 0x0800, CRC(75dd3562) SHA1(a359cada144e7c90946649f5dd0998d0ee48f4d2) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "27s29.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
-ROM_START( pool10g ) /* this set should be the parent */
+ROM_START( pool10g ) // 2nd set nominated for parent
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3.u2", 0x8000, 0x8000, CRC(7b537ce6) SHA1(b221d08c53b9e14178335632420e78070b9cfb27) )
@@ -4959,7 +5034,7 @@ ROM_START( pool10g ) /* this set should be the parent */
ROM_LOAD( "2.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "1.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10h_nvram.bin", 0x0000, 0x0800, CRC(3ec39472) SHA1(aa2bb5abd16557560a19842929ad7dab852abbbf) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4975,7 +5050,7 @@ ROM_START( pool10h )
ROM_LOAD( "cmc-pool10+b+.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "cmc-pool10+c+.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10i_nvram.bin", 0x0000, 0x0800, CRC(e93dee30) SHA1(195525e95a3bdc1b002b12fd27bc31c63d7a9276) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -4986,15 +5061,15 @@ ROM_END
ROM_START( pool10i )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "a.u2", 0x8000, 0x8000, CRC(566bc05d) SHA1(eec88c8ba6cb664f38ebf8b71f99b4e7d04a9601) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "b.u21", 0x0000, 0x8000, CRC(581c4878) SHA1(5ae61af090feea1745e22f46b33b2c01e6013fbe) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "c.u20", 0x8000, 0x8000, CRC(3bdf1106) SHA1(fa21cbd49bb27ea4a784cf4e4b3fbd52650a285b) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10l_nvram.bin", 0x0000, 0x0800, CRC(89cbee4b) SHA1(ff8031a96ee40e1e62abbae7a0b3d9dc2122759f) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5009,7 +5084,7 @@ ROM_START( pool10j )
ROM_LOAD( "cmcpool10.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "cmcpool10.u20", 0x8000, 0x8000, CRC(9abedd0c) SHA1(f184a82e8ec2387069d631bcb77e890acd44b3f5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "pool10j_nvram.bin", 0x0000, 0x0800, CRC(48684b02) SHA1(6f2fbd0e2621e31b881edd8056ff93ee78f331ab) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5063,16 +5138,16 @@ ROM_START( biliard )
ROM_LOAD( "cmcpool10-b.u21", 0x0000, 0x8000, CRC(99c8c074) SHA1(f8082b08e895cbcd028a2b7cd961a7a2c8b2762c) )
ROM_LOAD( "biliard-c.u20", 0x8000, 0x8000, CRC(b15d10ec) SHA1(9b0f32ff791063cfb2d8339a4e8041e034e73eb7) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "biliard_nvram.bin", 0x0000, 0x0800, CRC(2f2fab43) SHA1(f815b70c171bad99fa6a60c256e4fdc85dd6b290) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29pc.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h-25pc-4.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8a-25lp.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8a-25lp.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h-25pc-4.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8a-25lp.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8a-25lp.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -5081,18 +5156,18 @@ ROM_END
This one seems to run in royalcd1 hardware.
*/
-ROM_START( royal ) /* brute hack of pool 10 */
+ROM_START( royal ) // brute hack of pool 10
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3.u2", 0x8000, 0x8000, CRC(d4f36273) SHA1(2049257ea9ee52fde9cabfe40e809e00526a960e) ) // sldh
- /* GFX ROMs are the same of pool10, but double sized with identical halves. */
+// GFX ROMs are the same of pool10, but double sized with identical halves.
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "2.u21", 0x0000, 0x8000, CRC(439eec10) SHA1(500139c16a883f0a5b0b8d91f4f067ba428d2d11) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "1.u20", 0x8000, 0x8000, CRC(9b59e72d) SHA1(96217272ce5abb78ff45ff116a5d921c57717ed9) ) // sldh
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royal_nvram.bin", 0x0000, 0x0800, CRC(9df190d5) SHA1(4be0f5c6f89f822568e45e0e8457cf51ced2dcfe) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5129,16 +5204,16 @@ ROM_START( tortufam )
ROM_LOAD( "tortu.b.u21", 0x0000, 0x8000, CRC(e7b18584) SHA1(fa1c367469d4ced5d7c83c15a25ec5fd6afcca10) )
ROM_LOAD( "tortu.c.u20", 0x8000, 0x8000, CRC(3cda6f73) SHA1(b4f3d2d3c652ebf6973358ae33b7808de5939acd) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "tortufam_nvram.bin", 0x0000, 0x0800, CRC(e5a08b1b) SHA1(6575ed3ec66ef0e42129225fe1679519e5e1c946) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29pc_tf.u25", 0x0000, 0x0200, CRC(c6d433fb) SHA1(065de832bbe8765eb0aacc2029e587a4f5362f8a) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce20v8h_tf.u5", 0x0000, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_tf.u22", 0x0200, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_tf.u23", 0x0400, 0x0157, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce20v8h_tf.u5", 0x0000, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_tf.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_tf.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -5150,16 +5225,16 @@ ROM_START( potgame )
ROM_LOAD( "potg.b.u21", 0x0000, 0x8000, CRC(32fc1d4f) SHA1(cc533a44498338bc0cbb7c7b9c42559ce7ff1337) )
ROM_LOAD( "potg.c.u20", 0x8000, 0x8000, CRC(0331eb42) SHA1(a8e838d644fc6d93a9632070b305e44e4242ce94) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "potgame_nvram.bin", 0x0000, 0x0800, CRC(2b07fb37) SHA1(9cbd3d8fb076d683a7853b3dd8a39a27f1c8872b) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29_pot.u25", 0x0000, 0x0200, CRC(a221f151) SHA1(270c57c9b7de912b136686bc6720eb8f12dbb805) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_pot.u5", 0x0000, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_pot.u22", 0x0200, 0x0157, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "palce20v8h_pot.u23", 0x0400, 0x0157, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_pot.u5", 0x0000, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_pot.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "palce20v8h_pot.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -5171,16 +5246,16 @@ ROM_START( bottle10 )
ROM_LOAD( "boat_2.bin", 0x0000, 0x8000, CRC(a6b36c3f) SHA1(90b12d9552ad5dbf11a30fc7451da1f3e6763cc3) )
ROM_LOAD( "boat_1.bin", 0x8000, 0x8000, CRC(61fd8c19) SHA1(eb8fd8bd7de38a6c8a435e9e36daf699162138a5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "bottle10_nvram.bin", 0x0000, 0x0800, CRC(82927c53) SHA1(8cde91588cb53fefc84f0b14fc5c0b26a3a445eb) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147an_p10.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
@@ -5192,16 +5267,16 @@ ROM_START( bottl10b )
ROM_LOAD( "2.u21", 0x0000, 0x8000, CRC(9395c15b) SHA1(e4caefc6f55b07f5c4370a3b8652fa93e08987ce) )
ROM_LOAD( "1.u20", 0x8000, 0x8000, CRC(61fd8c19) SHA1(eb8fd8bd7de38a6c8a435e9e36daf699162138a5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "bottl10b_nvram.bin", 0x0000, 0x0800, CRC(59976182) SHA1(f8d26169e86444607bc5a6649f41e7f5c05ddbb4) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147an_p10.u25", 0x0000, 0x0200, CRC(1de03d14) SHA1(d8eda20865c1d885a428931f4380032e103b252c) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) /* GAL is read protected */
- ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) /* GAL is read protected */
+ ROM_LOAD( "palce16v8h_p10.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u22", 0x0200, 0x0157, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "gal20v8b_p10.u23", 0x0400, 0x0157, NO_DUMP ) // PLD is read protected
ROM_END
/*
@@ -5233,18 +5308,18 @@ ROM_END
were changed to match the second program.
*/
-/* The following two have mirrored video RAM 4000/5000 to 6000/7000. */
+// The following two have mirrored video RAM 4000/5000 to 6000/7000.
ROM_START( lunapark )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* Two different programs. Selectable through a DIP switch */
+ ROM_REGION( 0x10000, "maincpu", 0 ) // Two different programs. Selectable through a DIP switch
ROM_LOAD( "lunapark-425-95n003.u2", 0x0000, 0x10000, CRC(b3a620ee) SHA1(67b3498edf7b536e22c4d97c1f6ad5a71521e68f) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "lunapark-425-95n002.u21", 0x0000, 0x8000, CRC(2bededb7) SHA1(b8d7e6fe307d347d762adf35d361ade620aab37b) )
- ROM_CONTINUE( 0x0000, 0x8000) /* Discarding 1nd half 0xff filled*/
+ ROM_CONTINUE( 0x0000, 0x8000) // Discarding 1nd half 0xff filled
ROM_LOAD( "lunapark-425-95n001.u20", 0x8000, 0x8000, CRC(7d91ce1f) SHA1(7e9bfad76f305d5787faffe3a07b218beb37fda8) )
- ROM_CONTINUE( 0x8000, 0x8000) /* Discarding 1nd half 0xff filled*/
+ ROM_CONTINUE( 0x8000, 0x8000) // Discarding 1nd half 0xff filled
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "lunapark_nvram.bin", 0x0000, 0x0800, CRC(f99e749b) SHA1(fafd4205dfaacb4c21215af6997d06ab419c9281) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5252,23 +5327,23 @@ ROM_START( lunapark )
ROM_END
ROM_START( lunaparkb )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* Two different programs. Selectable through a DIP switch */
+ ROM_REGION( 0x10000, "maincpu", 0 ) // Two different programs. Selectable through a DIP switch
ROM_LOAD( "lunapark-number-03_lunaparkb.u2", 0x0000, 0x10000, CRC(cb819bb7) SHA1(c7fb25eab093de2f644445a713d99ee8024d8499) )
ROM_REGION( 0x10000, "gfx1", 0 )
- ROM_LOAD( "27512.u21", 0x0000, 0x8000, CRC(d64ac315) SHA1(c67d9e67a988036844efd4f980d47a90c022ba18) ) /* only the first 2 bytes different */
- ROM_CONTINUE( 0x0000, 0x8000) /* Discarding 1nd half 0xff filled*/
+ ROM_LOAD( "27512.u21", 0x0000, 0x8000, CRC(d64ac315) SHA1(c67d9e67a988036844efd4f980d47a90c022ba18) ) // only the first 2 bytes different
+ ROM_CONTINUE( 0x0000, 0x8000) // Discarding 1nd half 0xff filled
ROM_LOAD( "27512.u20", 0x8000, 0x8000, CRC(7d91ce1f) SHA1(7e9bfad76f305d5787faffe3a07b218beb37fda8 ) )
- ROM_CONTINUE( 0x8000, 0x8000) /* Discarding 1nd half 0xff filled*/
+ ROM_CONTINUE( 0x8000, 0x8000) // Discarding 1nd half 0xff filled
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "lunaparkb_nvram.bin", 0x0000, 0x0800, CRC(f99e749b) SHA1(fafd4205dfaacb4c21215af6997d06ab419c9281) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "82s147.u25", 0x0000, 0x0200, CRC(ddb74d72) SHA1(3d5dda3a935a3100cb86017f103b855d6449f73a) )
ROM_END
-/* This one hasn't mirrored video RAM, so could run in regular Cuore 1 hardware */
+// This one hasn't mirrored video RAM, so could run in regular Cuore 1 hardware
ROM_START( lunaparkc )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "lunapark-number-03_lunaparkc.u2", 0x8000, 0x8000, CRC(fdbe49c3) SHA1(a2b14a6998d5a27fba7bc360a15f17a48c91194f) )
@@ -5277,7 +5352,7 @@ ROM_START( lunaparkc )
ROM_LOAD( "lunapark-number-01.u21", 0x0000, 0x8000, CRC(ee057944) SHA1(31b76dcadf1dd5aacac1dfed0c7c9f7190797ead) )
ROM_LOAD( "lunapark-number-02.u20", 0x8000, 0x8000, CRC(b8795aec) SHA1(5db2e64657dee7742eb9d11e65d29c83a93332b7) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "lunaparkc_nvram.bin", 0x0000, 0x0800, CRC(005b70fc) SHA1(682c2315b4fafb6255db989f0d49255fd8d7a1a9) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5296,7 +5371,7 @@ ROM_START( crystal )
ROM_LOAD( "425-1995-number-02.u21", 0x0000, 0x8000, CRC(1eaf1bd9) SHA1(eb392f4a8864c59c7792f905f165f543087cb4a0) )
ROM_LOAD( "425-1995-number-01.u20", 0x8000, 0x8000, CRC(d3972c19) SHA1(a84ae765eeae1f9d443b0c4941b6f93dcc540f8c) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "crystal_nvram.bin", 0x0000, 0x0800, CRC(21a712ee) SHA1(259d83b8268a93f96b53580562e9c6e835f7473e) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5324,7 +5399,7 @@ ROM_START( royalcrd )
ROM_LOAD( "3.bin", 0x0000, 0x8000, CRC(c46d804f) SHA1(b089821c7dae6714b49401d787f8bed859815763) )
ROM_LOAD( "2.bin", 0x8000, 0x8000, CRC(41f7a0b3) SHA1(9aff2b8832d2a4f868daa9849a0bfe5e44f88fc0) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrd_nvram.bin", 0x0000, 0x0800, CRC(1c775f61) SHA1(c810421eaa31a72e3f2fe9a1d82858e7cc2f6b93) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5349,7 +5424,7 @@ ROM_START( royalcrda )
ROM_LOAD( "r.2", 0x8000, 0x8000, CRC(8a66f22c) SHA1(67d6e8f8f5a0fd979dc498ba2cc67cf707ccdf95) )
ROM_IGNORE( 0x8000)
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrda_nvram.bin", 0x0000, 0x0800, CRC(c42dbad4) SHA1(b38552192e3f5f6bc2a4b92bddd2f95ac17ecc8c) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5372,7 +5447,7 @@ ROM_START( royalcrdb )
ROM_LOAD( "rc_3_pl.bin", 0x0000, 0x8000, CRC(85e77661) SHA1(7d7a765c1bfcfeb9eb91d2519b22d734f20eab24) )
ROM_LOAD( "rc_2_pl.bin", 0x8000, 0x8000, CRC(41f7a0b3) SHA1(9aff2b8832d2a4f868daa9849a0bfe5e44f88fc0) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrdb_nvram.bin", 0x0000, 0x0800, CRC(19bb3dea) SHA1(0965fbcec48ded99c5f6793efffb1d9329cc00eb) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5447,15 +5522,15 @@ ROM_START( royalcrdd )
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(85e77661) SHA1(7d7a765c1bfcfeb9eb91d2519b22d734f20eab24) ) // sldh
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(41f7a0b3) SHA1(9aff2b8832d2a4f868daa9849a0bfe5e44f88fc0) ) // sldh
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrdd_nvram.bin", 0x0000, 0x0800, CRC(335bfa5a) SHA1(7e9cbb502f450c515ea03ffcf4b7fbae60af4e73) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147.bin", 0x0000, 0x0200, CRC(8bc86f48) SHA1(4c677ab9314a1f571e35104b22659e6811aeb194) )
ROM_REGION( 0x0600, "plds", 0 )
- ROM_LOAD( "palce16v8h-4.bin", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
- ROM_LOAD( "1-peel18cv8.bin", 0x0200, 0x0155, NO_DUMP ) /* PEEL is read protected */
+ ROM_LOAD( "palce16v8h-4.bin", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
+ ROM_LOAD( "1-peel18cv8.bin", 0x0200, 0x0155, NO_DUMP ) // PLD is read protected
ROM_LOAD( "2-peel18cv8.bin", 0x0400, 0x0155, CRC(8fdafd55) SHA1(fbb187ba682111648ea1586f400990cb81a3077a) )
ROM_END
@@ -5479,24 +5554,24 @@ ROM_END
- 1x trimmer (volume)
*/
-ROM_START( royalcrde ) /* both halves have different programs. we're using the 2nd one */
- ROM_REGION( 0x10000, "maincpu", 0 ) /* 1st half prg is testing RAM in offset $8600-$BF00...?? */
+ROM_START( royalcrde ) // both halves have different programs. we're using the 2nd one.
+ ROM_REGION( 0x10000, "maincpu", 0 ) // 1st half prg is testing RAM in offset $8600-$BF00...??
ROM_LOAD( "rc.bin", 0x0000, 0x10000, CRC(8a9a6dd6) SHA1(04c3f9f17d5404ac1414c51ef8f930df54530e72) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "2a.bin", 0x0000, 0x8000, CRC(3af71cf8) SHA1(3a0ce0d0abebf386573c5936545dada1d3558e55) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "1a.bin", 0x8000, 0x8000, CRC(8a66f22c) SHA1(67d6e8f8f5a0fd979dc498ba2cc67cf707ccdf95) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrde_nvram.bin", 0x0000, 0x0800, CRC(3b03440f) SHA1(49e51b8c9e1404d39c479a2d0619aab43f1a6529) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147.bin", 0x0000, 0x0200, CRC(8bc86f48) SHA1(4c677ab9314a1f571e35104b22659e6811aeb194) )
ROM_REGION( 0x0200, "plds", 0 )
- ROM_LOAD( "palce16v8h-4.bin", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h-4.bin", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
ROM_END
@@ -5519,7 +5594,7 @@ ROM_START( royalcrdt )
ROM_REGION( 0x0800, "nvram", 0 )
ROM_LOAD( "royalcrdt_nv.bin", 0x0000, 0x0800, CRC(67a6e68b) SHA1(d7ab01c4d9bd4fe58b5d0f4a945c00c5c4906008) )
- ROM_REGION( 0x0200, "plds", 0 ) /* Device type is 16L8 */
+ ROM_REGION( 0x0200, "plds", 0 ) // Device type is 16L8
ROM_LOAD( "tab01_3.bin", 0x0000, 0x0104, CRC(a13a7a0a) SHA1(28e918ece4dcfa3883d2439c226b2f125d43f386) )
ROM_END
@@ -5568,7 +5643,7 @@ ROM_START( royalcrdf ) // encrypted program rom
ROM_END
-ROM_START( royalcrdg ) /* CMC C1030 PCB, EP910EC-30 CPLD, NON encrypted graphics */
+ROM_START( royalcrdg ) // CMC C1030 PCB, EP910EC-30 CPLD, NON encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3.cpu", 0x8000, 0x8000, CRC(829a6a1d) SHA1(b7064e4d60e33d0875eb73525230ea3b99f10542) )
@@ -5576,7 +5651,7 @@ ROM_START( royalcrdg ) /* CMC C1030 PCB, EP910EC-30 CPLD, NON encrypted graphi
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(85e77661) SHA1(7d7a765c1bfcfeb9eb91d2519b22d734f20eab24) ) // sldh
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(41f7a0b3) SHA1(9aff2b8832d2a4f868daa9849a0bfe5e44f88fc0) ) // sldh
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrdg_nvram.bin", 0x0000, 0x0800, CRC(853c7da9) SHA1(e275b22a9f470672bfc71425fcc44f547ba38b6d) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5598,7 +5673,7 @@ ROM_START( royalcrdh )
ROM_LOAD( "145-2.bin", 0x0000, 0x8000, CRC(85e77661) SHA1(7d7a765c1bfcfeb9eb91d2519b22d734f20eab24) )
ROM_LOAD( "145-1.bin", 0x8000, 0x8000, CRC(41f7a0b3) SHA1(9aff2b8832d2a4f868daa9849a0bfe5e44f88fc0) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrdh_nvram.bin", 0x0000, 0x0800, CRC(7757d73a) SHA1(997bfbd847d1d21777694331be92a1a5e79e4faf) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5632,7 +5707,7 @@ ROM_END
1x battery (missing)
*/
-ROM_START( royalcdfr ) /* Seems bootleg PCB, non encrypted graphics */
+ROM_START( royalcdfr ) // Seems bootleg PCB, non encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "3.bin", 0x8000, 0x8000, CRC(69b944c1) SHA1(6ef76bff01f20376117dd7f67e5890eca754fcfb) ) // sldh
@@ -5640,7 +5715,7 @@ ROM_START( royalcdfr ) /* Seems bootleg PCB, non encrypted graphics */
ROM_LOAD( "2.bin", 0x0000, 0x8000, CRC(85e77661) SHA1(7d7a765c1bfcfeb9eb91d2519b22d734f20eab24) ) // sldh
ROM_LOAD( "1.bin", 0x8000, 0x8000, CRC(41f7a0b3) SHA1(9aff2b8832d2a4f868daa9849a0bfe5e44f88fc0) ) // sldh
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcdfr_nvram.bin", 0x0000, 0x0800, CRC(bda344d4) SHA1(7793d289147bf03c0d8256d4023252c9677ac8ff) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5659,7 +5734,7 @@ ROM_START( royalcrdp )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "n82s147a.bin", 0x0000, 0x0200, CRC(8bc86f48) SHA1(4c677ab9314a1f571e35104b22659e6811aeb194) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "royalcrdp_nvram.bin", 0x0000, 0x0800, BAD_DUMP CRC(553f8c66) SHA1(d2c21786d715f81c537d860d8515fda6d766f630) )
ROM_REGION( 0x0200, "plds", 0 )
@@ -5692,7 +5767,7 @@ ROM_START( royaljp )
ROM_REGION( 0x0800, "nvram", 0 )
ROM_LOAD( "royaljp_nvram.bin", 0x0000, 0x0800, CRC(48e51e2a) SHA1(b81a1741eef299384d4fa98a534099b2c0332074) )
- ROM_REGION( 0x0600, "plds", 0 ) /* There are 3 GALs */
+ ROM_REGION( 0x0600, "plds", 0 ) // There are 3 GALs
ROM_LOAD( "gal20v8b.bin", 0x0000, 0x0157, NO_DUMP )
ROM_LOAD( "gal20v8a.bin", 0x0200, 0x0157, NO_DUMP )
ROM_LOAD( "gal16v8d.bin", 0x0400, 0x0117, NO_DUMP )
@@ -5709,7 +5784,7 @@ ROM_START( lluck3x3 )
ROM_LOAD( "l2.bin", 0x0000, 0x8000, CRC(8ca90a8f) SHA1(bc3db3f8c097f89eff488e3aca39bf24ff2b5cff) )
ROM_LOAD( "l1.bin", 0x8000, 0x8000, CRC(beadc35c) SHA1(8a6a5954a827def8c4c3b904d8ee58a4bde53d85) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "lluck3x3_nvram.bin", 0x0000, 0x0800, CRC(2fe79cff) SHA1(7839c04336b7702c7bdcd2b6917a353f4376f824) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5725,7 +5800,7 @@ ROM_START( lluck4x1 )
ROM_LOAD( "l2.bin", 0x0000, 0x8000, CRC(8ca90a8f) SHA1(bc3db3f8c097f89eff488e3aca39bf24ff2b5cff) )
ROM_LOAD( "l1.bin", 0x8000, 0x8000, CRC(beadc35c) SHA1(8a6a5954a827def8c4c3b904d8ee58a4bde53d85) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "lluck4x1_nvram.bin", 0x0000, 0x0800, CRC(05d2d7b8) SHA1(1188b2b4835cadd95b1e9160c2948a2e3457afd2) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5762,28 +5837,28 @@ ROM_END
*/
-ROM_START( magicrd2 ) /* Impera... but seems Bulgarian hack, just for copyright */
- ROM_REGION( 0x10000, "maincpu", 0 ) /* magicard.004 has extra code, and 2 different NVRAM contents harcoded */
+ROM_START( magicrd2 ) // Impera... but seems Bulgarian hack, just for copyright
+ ROM_REGION( 0x10000, "maincpu", 0 ) // magicard.004 has extra code, and 2 different NVRAM contents harcoded
ROM_LOAD( "magicard.004", 0x0000, 0x8000, CRC(f6e948b8) SHA1(7d5983015a508ab135ccbf69b7f3c526c229e3ef) )
- ROM_LOAD( "magicard.01", 0x8000, 0x8000, CRC(c94767d4) SHA1(171ac946bdf2575f9e4a31e534a8e641597af519) ) /* 1st and 2nd half identical */
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_LOAD( "magicard.01", 0x8000, 0x8000, CRC(c94767d4) SHA1(171ac946bdf2575f9e4a31e534a8e641597af519) ) // 1st and 2nd half identical
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "mc2gr2.bin", 0x0000, 0x8000, CRC(733da697) SHA1(45122c64d5a371ec91cecc67b7faf179078e714d) )
ROM_LOAD( "mc2gr1.bin", 0x8000, 0x8000, CRC(2406b8d2) SHA1(e9d7a25562fd5adee351d7ef6ba02fff6aab021a) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "magicrd2_nvram.bin", 0x0000, 0x0800, CRC(343b3162) SHA1(1524959dbbc0c6d7c5c3a4a6b20976382cfbe88f) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "mc2-82s147.bin", 0x0000, 0x0200, CRC(aa91cc35) SHA1(79f9a755441500e618c4183f524f969fffd44100) )
ROM_REGION( 0x0200, "plds", 0 )
- ROM_LOAD( "gal16v8uni.bin", 0x0000, 0x0117, CRC(b81d7e0a) SHA1(7fef0b2bcea931a830d38ae0f1102434cf281d2d) ) /* Universal GAL */
+ ROM_LOAD( "gal16v8uni.bin", 0x0000, 0x0117, CRC(b81d7e0a) SHA1(7fef0b2bcea931a830d38ae0f1102434cf281d2d) ) // Universal GAL
ROM_END
-ROM_START( magicrd2a ) /* Nov (new). Imatic Yugoslavian hack for green TAB or Impera boards */
+ROM_START( magicrd2a ) // Nov (new). Imatic Yugoslavian hack for green TAB or Impera boards
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "m3_nov.bin", 0x8000, 0x8000, CRC(ee5468e6) SHA1(f859adbad30e561fca86e60ff5b2e666d8bf4071) )
@@ -5791,7 +5866,7 @@ ROM_START( magicrd2a ) /* Nov (new). Imatic Yugoslavian hack for green TAB or I
ROM_LOAD( "m2_nov.bin", 0x0000, 0x8000, CRC(684d71f2) SHA1(e4522844a0406b3e83fa723508a7c05dd21e7fb6) )
ROM_LOAD( "m1_nov.bin", 0x8000, 0x8000, CRC(96151034) SHA1(3107d353705c6240a71faf308e11c45a87d95cf4) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM (passed protection) */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM (passed protection)
ROM_LOAD( "mc2_nvram.bin", 0x0000, 0x0800, CRC(2070d63d) SHA1(86c72a2e81651b0138d8551a0cfcd07176f8e7d2) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5802,16 +5877,15 @@ ROM_START( magicrd2a ) /* Nov (new). Imatic Yugoslavian hack for green TAB or I
ROM_END
-ROM_START( magicrd2b ) /* Imatic Yugoslavian hack for green TAB or Impera boards */
+ROM_START( magicrd2b ) // Imatic Yugoslavian hack for green TAB or Impera boards
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "mc2prgv1.bin", 0x8000, 0x8000, CRC(7f759b70) SHA1(23a1a6e8eda57c4a90c51a970302f9a7bf590083) )
-// ROM_LOAD( "mc2prgv2.bin", 0x8000, 0x8000, CRC(b0ed6b40) SHA1(7167e67608f1b0b1cd956c838dacc1310861cb4a) ) // there are also pcbs with this program
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "mc2gr2.bin", 0x0000, 0x8000, CRC(733da697) SHA1(45122c64d5a371ec91cecc67b7faf179078e714d) )
ROM_LOAD( "mc2gr1.bin", 0x8000, 0x8000, CRC(2406b8d2) SHA1(e9d7a25562fd5adee351d7ef6ba02fff6aab021a) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM (passed protection) */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM (passed protection)
ROM_LOAD( "mc2_v1-v2_nvram.bin", 0x0000, 0x0800, BAD_DUMP CRC(f88c493d) SHA1(8a5352b46ab68164cd7adaaad6f15f04327b7451) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5822,16 +5896,15 @@ ROM_START( magicrd2b ) /* Imatic Yugoslavian hack for green TAB or Impera board
ROM_END
-ROM_START( magicrd2c ) /* Imatic Yugoslavian hack for blue TAB board (encrypted)*/
+ROM_START( magicrd2c ) // Imatic Yugoslavian hack for blue TAB board (encrypted)
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "mc2prgv2.bin", 0x8000, 0x8000, CRC(b0ed6b40) SHA1(7167e67608f1b0b1cd956c838dacc1310861cb4a) )
-// ROM_LOAD( "mc2prgv1.bin", 0x8000, 0x8000, CRC(7f759b70) SHA1(23a1a6e8eda57c4a90c51a970302f9a7bf590083) ) // there are also pcbs with this program
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "mc2gr1b.bin", 0x0000, 0x8000, CRC(ce2629a7) SHA1(84767ed5da8dcee44a210255537e10372bcc264b) )
ROM_LOAD( "mc2gr2b.bin", 0x8000, 0x8000, CRC(d2bf8bde) SHA1(975b8f43a0396c09e357b96d5ae7381b12152b9e) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM (passed protection) */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM (passed protection)
ROM_LOAD( "mc2_v1-v2_nvram.bin", 0x0000, 0x0800, BAD_DUMP CRC(f88c493d) SHA1(8a5352b46ab68164cd7adaaad6f15f04327b7451) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5853,10 +5926,10 @@ ROM_START( vegasslw )
ROM_LOAD( "v2.bin", 0x0000, 0x8000, CRC(af7ab460) SHA1(01ea400424152c09c10eb83a1bd569019969ccb7) )
ROM_LOAD( "v1.bin", 0x8000, 0x8000, CRC(23e0d1c6) SHA1(98967b14d3264c444a1dfbd15c57cde70f41f09d) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "vegasslw_nvram.bin", 0x0000, 0x0800, CRC(1aa043e3) SHA1(c93d071effb2f2fe95e9dc751174c2c765595f74) )
- ROM_REGION( 0x0200, "proms", 0 ) /* PLD address the 2nd half */
+ ROM_REGION( 0x0200, "proms", 0 ) // PLD address the 2nd half
ROM_LOAD( "jokercrd_prom.bin", 0x0000, 0x0200, CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) )
ROM_END
@@ -5869,39 +5942,39 @@ ROM_START( vegasfst )
ROM_LOAD( "v2.bin", 0x0000, 0x8000, CRC(af7ab460) SHA1(01ea400424152c09c10eb83a1bd569019969ccb7) )
ROM_LOAD( "v1.bin", 0x8000, 0x8000, CRC(23e0d1c6) SHA1(98967b14d3264c444a1dfbd15c57cde70f41f09d) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "vegasfst_nvram.bin", 0x0000, 0x0800, CRC(5034de7a) SHA1(ab2077a49d94676531c73ad8d8ce9548bbfa2b81) )
- ROM_REGION( 0x0200, "proms", 0 ) /* PLD address the 2nd half */
+ ROM_REGION( 0x0200, "proms", 0 ) // PLD address the 2nd half
ROM_LOAD( "jokercrd_prom.bin", 0x0000, 0x0200, CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) )
ROM_END
-ROM_START( vegasfte ) /* Royal Vegas Joker Card (fast deal, english gfx) */
+ROM_START( vegasfte ) // Royal Vegas Joker Card (fast deal, english gfx)
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "ch3.bin", 0x8000, 0x8000, CRC(87dfb28d) SHA1(9a06e695e59722b6c97e5a9fd2c8b238661e5a4a) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "ch2.bin", 0x0000, 0x8000, CRC(af7ab460) SHA1(01ea400424152c09c10eb83a1bd569019969ccb7) )
- ROM_LOAD( "ch1.bin", 0x8000, 0x8000, CRC(0a3679c0) SHA1(ce8a067e1a2eccf9fabb16733ef3a14e0e8129e5) ) /* X & Y in txt layer */
+ ROM_LOAD( "ch1.bin", 0x8000, 0x8000, CRC(0a3679c0) SHA1(ce8a067e1a2eccf9fabb16733ef3a14e0e8129e5) ) // X & Y in txt layer
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "vegasfte_nvram.bin", 0x0000, 0x0800, CRC(166c6055) SHA1(db2143a2a3adc92578bd3707391d2f5030cc6a6f) )
- ROM_REGION( 0x0200, "proms", 0 ) /* PLD address the 2nd half */
+ ROM_REGION( 0x0200, "proms", 0 ) // PLD address the 2nd half
ROM_LOAD( "jokercrd_prom.bin", 0x0000, 0x0200, CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) )
ROM_END
ROM_START( vegasmil )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* Mile */
+ ROM_REGION( 0x10000, "maincpu", 0 ) // Mile
ROM_LOAD( "mile.bin", 0x8000, 0x8000, CRC(ef7e02e2) SHA1(7432b0e723dc528901c422ab1d7d01fd1bc1eb20) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "v2.bin", 0x0000, 0x8000, CRC(af7ab460) SHA1(01ea400424152c09c10eb83a1bd569019969ccb7) )
ROM_LOAD( "v1.bin", 0x8000, 0x8000, CRC(23e0d1c6) SHA1(98967b14d3264c444a1dfbd15c57cde70f41f09d) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "vegasmil_nvram.bin", 0x0000, 0x0800, CRC(d2608e5f) SHA1(ac936df71dbc0bfb811a3ba3c91444a2a3e7b036) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -5993,7 +6066,7 @@ ROM_END
*/
-ROM_START( jolyjokr ) /* Jolly Joker (98bet, set 1) */
+ROM_START( jolyjokr ) // Jolly Joker (98bet, set 1)
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "impera3orig.bin", 0x8000, 0x8000, CRC(ceb3a0d5) SHA1(25efae9f225abddfa663e6abcc91801996e5b0ea) )
@@ -6001,7 +6074,7 @@ ROM_START( jolyjokr ) /* Jolly Joker (98bet, set 1) */
ROM_LOAD( "impera2.bin", 0x0000, 0x8000, CRC(f0fa5941) SHA1(1fcade31ed6893ffcfd4efe97dfaaa31d24283ec) )
ROM_LOAD( "impera1.bin", 0x8000, 0x8000, CRC(c3ab44dd) SHA1(e46c0fd94da561f57033647f1703fa135777ece5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyjokr_nvram.bin", 0x0000, 0x0800, CRC(f33e66ed) SHA1(7a4b9a1b2f976d5d26f54915a213d5ac5eca0a42) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -6009,7 +6082,7 @@ ROM_START( jolyjokr ) /* Jolly Joker (98bet, set 1) */
ROM_END
-ROM_START( jolyjokra ) /* Jolly Joker (98bet, set 2) */
+ROM_START( jolyjokra ) // Jolly Joker (98bet, set 2)
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "impera50.bin", 0x8000, 0x8000, CRC(7effc044) SHA1(961438e7fb8222296fb959b510cdf646e4ac3226) )
@@ -6017,7 +6090,7 @@ ROM_START( jolyjokra ) /* Jolly Joker (98bet, set 2) */
ROM_LOAD( "impera2.bin", 0x0000, 0x8000, CRC(f0fa5941) SHA1(1fcade31ed6893ffcfd4efe97dfaaa31d24283ec) )
ROM_LOAD( "impera1.bin", 0x8000, 0x8000, CRC(c3ab44dd) SHA1(e46c0fd94da561f57033647f1703fa135777ece5) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyjokra_nvram.bin", 0x0000, 0x0800, CRC(ed43693c) SHA1(d4aa4e539ab12c97bc9b9b1077997195a11d782b) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -6026,34 +6099,80 @@ ROM_END
/*
- Jolly Joker (40bet, croatian hack)
+ Jolly Joker (40bet)
+
+ am27s29_ic40.bin 1ST AND 2ND HALF IDENTICAL
+ ic25.bin 1ST AND 2ND HALF IDENTICAL
+ ic26.bin 1ST AND 2ND HALF IDENTICAL
+
+ These graphics ROMs have enough data to fix the bitrotten graphics from the other Jolly Joker sets.
+ impera1.bin ---> bits 7 & 6
+ impera2.bin ---> bits 7 & 0
+
+ Two slightly different programs. One in each half.
+ Both have Min Bet (5), Max Bet (40).
+ Surely selectable through a PLD.
+
+ This is clearly the paytable. Here the differences...
+
+ offset: C9CF C9D0 C9D1 C9D2 C9D3 C9D4 C9D5 C9D6 C9D7 C9D8 C9D9 C9DA C9DB C9DC C9DD C9DE C9DF C9E0 C9E1 C9E2
+ program #1 0x01 0x00 0x02 0x00 0x03 0x00 0x05 0x00 0x07 0x00 0x10 0x00 0x40 0x00 0x00 0x01 0x00 0x05 0x00 0x11
+ program #2 0x01 0x00 0x02 0x00 0x03 0x00 0x05 0x00 0x07 0x00 0x10 0x00 0x40 0x00 0x00 0x01 0x50 0x02 0x00 0x03
+ ^^^^ ^^^^ ^^^^
+
+ offset: C9E3 C9E4 C9E5 C9E6 C9E7 C9E8 C9E9 C9EA C9EB C9EC C9ED C9EE C9EF C9F0 C9F1 C9F2 C9F3 C9F4 C9F5 C9F6
+ program #1 0x01 0x00 0x02 0x00 0x03 0x00 0x05 0x00 0x07 0x00 0x10 0x00 0x40 0x00 0x00 0x01 0x00 0x05 0x00 0x11
+ program #2 0x01 0x00 0x02 0x00 0x03 0x00 0x05 0x00 0x07 0x00 0x10 0x00 0x40 0x00 0x00 0x01 0x50 0x02 0x00 0x03
+ ^^^^ ^^^^ ^^^^
+ This change the paytable to the following values:
+
+ Program #1 Program #2
+
+ Five of a Kind 1100 Five of a Kind 300
+ Royak Flush 500 Royak Flush 250
+ Street Flush 100 Street Flush 100
+ Poker 40 Poker 40
+ Full House 10 Full House 10
+ Farbe 7 Farbe 7
+ Strasse 5 Strasse 5
+ Drilling 3 Drilling 3
+ 2 Paare 2 2 Paare 2
+ Hohes Paar 1 Hohes Paar 1
+
+ Will split in two different sets, since these programs were made to use as different
+ game variations, and aren't user selectable.
- am27s29_ic40.bin 1ST AND 2ND HALF IDENTICAL
- ic25.bin 1ST AND 2ND HALF IDENTICAL
- ic26.bin 1ST AND 2ND HALF IDENTICAL
+*/
+ROM_START( jolyjokrb1 )
+ ROM_REGION( 0x10000, "maincpu", 0 ) // Two different paytable programs. Using the 1st one (higher paytable)
+ ROM_LOAD( "unbekannt.bin", 0x8000, 0x8000, CRC(327fa3d7) SHA1(2435aada2377b2f8f01d059a7aba9bc7a8993537) )
+ ROM_IGNORE( 0x8000 ) // Using the 1st program. Discarding 2nd half
- These graphics ROMs have enough data to fix the bitrotten graphics from the other Jolly Joker sets.
- impera1.bin ---> bits 7 & 6
- impera2.bin ---> bits 7 & 0
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "ic26.bin", 0x0000, 0x8000, CRC(3e45dfc6) SHA1(8fd0b0cc00cdd96244ae7e7a91f6613b1c144ee0) )
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
+ ROM_LOAD( "ic25.bin", 0x8000, 0x8000, CRC(1bd067af) SHA1(9436fe085ba63c00a12ea80903470a84535e3dc1) )
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- Two slightly different programs. One in each half.
- Both have Min Bet (5), Max Bet (40).
- Surely selectable through a PLD.
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_LOAD( "jolyjokrb_nvram.bin", 0x0000, 0x0800, CRC(17007bb5) SHA1(72e08096293ce4fbde205a63b5ecd9641dbee017) )
-*/
-ROM_START( jolyjokrb )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* Two slightly different programs. Using the 1st one...*/
- ROM_LOAD( "unbekannt.bin", 0x8000, 0x8000, CRC(327fa3d7) SHA1(2435aada2377b2f8f01d059a7aba9bc7a8993537) ) /* 1st prg */
- ROM_IGNORE( 0x8000 ) /* Using the 1st program. Discarding 2nd half */
-// ROM_LOAD( "unbekannt.bin", 0x0000, 0x10000, CRC(327fa3d7) SHA1(2435aada2377b2f8f01d059a7aba9bc7a8993537) ) /* 2nd prg */
+ ROM_REGION( 0x0200, "proms", 0 )
+ ROM_LOAD( "am27s29_ic40.bin", 0x0000, 0x0200, CRC(0b671bba) SHA1(92d512e02b50f98b7bc5a60deee4fee722656c4f) )
+ROM_END
+
+ROM_START( jolyjokrb2 )
+ ROM_REGION( 0x10000, "maincpu", 0 ) // Two different paytable programs. Using the 2nd one (lower paytable)
+ ROM_LOAD( "unbekannt.bin", 0x8000, 0x8000, CRC(327fa3d7) SHA1(2435aada2377b2f8f01d059a7aba9bc7a8993537) )
+ ROM_CONTINUE( 0x8000, 0x8000) // overlapping with the 2nd program.
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "ic26.bin", 0x0000, 0x8000, CRC(3e45dfc6) SHA1(8fd0b0cc00cdd96244ae7e7a91f6613b1c144ee0) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "ic25.bin", 0x8000, 0x8000, CRC(1bd067af) SHA1(9436fe085ba63c00a12ea80903470a84535e3dc1) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyjokrb_nvram.bin", 0x0000, 0x0800, CRC(17007bb5) SHA1(72e08096293ce4fbde205a63b5ecd9641dbee017) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -6078,7 +6197,7 @@ ROM_START( jolyjokrc )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "tbp28s42.bin", 0x0000, 0x0200, CRC(0b671bba) SHA1(92d512e02b50f98b7bc5a60deee4fee722656c4f) )
- ROM_REGION( 0x0200, "plds", 0 ) /* Cracked PLD */
+ ROM_REGION( 0x0200, "plds", 0 ) // cracked PLD
ROM_LOAD( "jjpal.bin", 0x0000, 0x0117, CRC(3b084c34) SHA1(5d186b70317ef871c9a426eb420b66efcbd918de) )
ROM_END
@@ -6088,7 +6207,7 @@ ROM_END
The following two sets have the same program
but different graphics system.
-
+
Both sets have graphics ROMs data interleaved
inside the second half of a 16bit 27C210 EPROM.
The second set has some 8bits data in the first half.
@@ -6105,20 +6224,20 @@ ROM_END
*/
ROM_START( jolyjokro )
- ROM_REGION( 0x20000, "maincpu", 0 )
+ ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "impera1.bin", 0x0000, 0x10000, CRC(3cad9fcf) SHA1(09f23ae8c04e6b461e17a8b3978fe44566ffc3aa) )
ROM_REGION( 0x10000, "gfxpool", 0 )
ROM_LOAD( "impera2.bin", 0x0000, 0x10000, CRC(aa86dba6) SHA1(fe189dde83bd855f4a0b34b20c161a9addc15017) )
- ROM_CONTINUE( 0x0000, 0x10000) // discarding 1nd empty half (0000-ffff)
+ ROM_CONTINUE( 0x0000, 0x10000) // discarding 1nd empty half (0000-ffff)
ROM_REGION( 0x10000, "gfx1", 0 )
- ROM_FILL( 0x0000, 0x10000, 0xff) // deinterleaved GFX data will be placed here
+ ROM_FILL( 0x0000, 0x10000, 0xff) // deinterleaved GFX data will be placed here
- ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "jolyjokro_nvram.bin", 0x0000, 0x0800, CRC(1f69e567) SHA1(86695ca6f9f93c6badd092410611d8061edf8efa) )
- ROM_REGION( 0x0200, "proms", 0 ) // PLD address the 2nd half
+ ROM_REGION( 0x0200, "proms", 0 ) // PLD address the 2nd half
ROM_LOAD( "1_impera_color_ii.bin", 0x0000, 0x0200, CRC(9d62f9f5) SHA1(68300c25c7eaa13a3fdbf91ab0711d0bc530543d) )
ROM_END
@@ -6128,7 +6247,7 @@ ROM_START( jolyjokrp )
ROM_REGION( 0x10000, "gfxpool", 0 )
ROM_LOAD( "9c_1ff1.bin", 0x00000, 0x10000, CRC(4b8f0821) SHA1(0821eed07f5e98b66d87a3079756dad72ffe9665) )
- ROM_CONTINUE( 0x00000, 0x10000) // discarding 1nd half (0000-ffff), but has some data. maybe the missing impera logo?
+ ROM_CONTINUE( 0x00000, 0x10000) // discarding 1nd half (0000-ffff), but has some data. leftover?
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_FILL( 0x0000, 0x10000, 0xff) // deinterleaved GFX data will be placed here
@@ -6140,6 +6259,41 @@ ROM_START( jolyjokrp )
ROM_LOAD( "impera_color_ii.bin", 0x0000, 0x0200, CRC(9d62f9f5) SHA1(68300c25c7eaa13a3fdbf91ab0711d0bc530543d) )
ROM_END
+/*
+ Jolly Joker
+ Impera.
+
+ This hardware has a daughterboard that seems a solid state replacement
+ for the suicide modules of funworld boards.
+
+ It's just a theory, but the main battery is routed to the daughterboard
+ connectors, when this module has not suicide program inside a RAM.
+
+ Module contents:
+
+ 1x Rockwell R65C02P2 Mexico.
+ 1x 27c512 EPROM stickered 'IMPERA1'.
+ 1x PAL16L8A2NC.
+ 1x 74HC241N.
+ 1x 74LS245N.
+ 1x 74LS139N.
+
+*/
+ROM_START( jolyjokrm ) // Jolly Joker (Solid State module in suicide board)
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "impera1.bin", 0x0000, 0x10000, CRC(3cad9fcf) SHA1(09f23ae8c04e6b461e17a8b3978fe44566ffc3aa) )
+
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "02.bin", 0x0000, 0x8000, CRC(f0fa5941) SHA1(1fcade31ed6893ffcfd4efe97dfaaa31d24283ec) )
+ ROM_LOAD( "01.bin", 0x8000, 0x8000, CRC(c3ab44dd) SHA1(e46c0fd94da561f57033647f1703fa135777ece5) )
+
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_LOAD( "jolyjokrm_nvram.bin", 0x0000, 0x0800, CRC(f33e66ed) SHA1(7a4b9a1b2f976d5d26f54915a213d5ac5eca0a42) )
+
+ ROM_REGION( 0x0200, "proms", 0 )
+ ROM_LOAD( "63s481.bin", 0x0000, 0x0200, CRC(1f974802) SHA1(c9d4d72edef3c03b0c6e1a0ffc0b82f6d213d29c) )
+ROM_END
+
/******************************** Other sets ************************************/
@@ -6161,7 +6315,7 @@ ROM_START( multiwin )
ROM_LOAD( "multiwin1.bin", 0x8000, 0x8000, CRC(97589aa6) SHA1(2486116637bd906cb3b32acd86fc861c48a0475e) )
ROM_REGION( 0x0200, "proms", 0 )
- ROM_LOAD( "multi_prom.bin", 0x0000, 0x0200, BAD_DUMP CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) ) /* using the joker card one */
+ ROM_LOAD( "multi_prom.bin", 0x0000, 0x0200, BAD_DUMP CRC(e59fc06e) SHA1(88a3bb89f020fe2b20f768ca010a082e0b974831) ) // using the joker card one
ROM_END
@@ -6259,12 +6413,12 @@ ROM_END
*/
ROM_START( powercrd )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* need proper decryption */
- ROM_LOAD( "263a1.bin", 0x8000, 0x8000, CRC(9e5e477d) SHA1(428464a64bea8cb478bc8033859baa47d7de0297) ) /* just the 2nd half */
- ROM_LOAD( "263a2.bin", 0x0000, 0x8000, CRC(11b1a13f) SHA1(766c1a45c238467d6a292795f5a159187966ceec) ) /* just the 2nd half */
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "263a1.bin", 0x8000, 0x8000, CRC(9e5e477d) SHA1(428464a64bea8cb478bc8033859baa47d7de0297) ) // just the 2nd half
+ ROM_LOAD( "263a2.bin", 0x0000, 0x8000, CRC(11b1a13f) SHA1(766c1a45c238467d6a292795f5a159187966ceec) ) // just the 2nd half
- ROM_REGION( 0x0800, "decode", 0 ) /* from the CY7C291A inside of the custom CPU */
- ROM_LOAD( "powercrd_cy7c291a.bin", 0x0000, 0x0800, CRC(f1d8f35d) SHA1(2b5f9222a81a627d43fd8448385f85c71c24b914) ) /* new dump */
+ ROM_REGION( 0x0800, "decode", 0 ) // from the CY7C291A inside of the custom CPU
+ ROM_LOAD( "powercrd_cy7c291a.bin", 0x0000, 0x0800, CRC(f1d8f35d) SHA1(2b5f9222a81a627d43fd8448385f85c71c24b914) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "power_c_zg2.ic11", 0x0000, 0x8000, CRC(108380bb) SHA1(922beffe3c06f391239125e6f4ccc86ec6980c45) )
@@ -6393,15 +6547,15 @@ ROM_END
*/
ROM_START( megacard )
- ROM_REGION( 0x10000, "maincpu", 0 ) /* need proper decryption */
- ROM_LOAD( "mega_mc3_210-f-1.ic37", 0x8000, 0x8000, CRC(747f5ed1) SHA1(06757bb6a792dca93978b17b54c28e413e3720b1) ) /* just the 2nd half */
- ROM_LOAD( "mega_mc3_210-f-2.ic41", 0x0000, 0x8000, CRC(373094d2) SHA1(8aed2502e89b0e7522e88f351ac256f1afad7ee8) ) /* just the 2nd half */
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "mega_mc3_210-f-1.ic37", 0x8000, 0x8000, CRC(747f5ed1) SHA1(06757bb6a792dca93978b17b54c28e413e3720b1) ) // just the 2nd half
+ ROM_LOAD( "mega_mc3_210-f-2.ic41", 0x0000, 0x8000, CRC(373094d2) SHA1(8aed2502e89b0e7522e88f351ac256f1afad7ee8) ) // just the 2nd half
- ROM_REGION( 0x0300, "die_65sc02", 0 ) /* from the 65SC02 die inside of the custom CPU */
+ ROM_REGION( 0x0300, "die_65sc02", 0 ) // from the 65SC02 die inside of the custom CPU
ROM_LOAD( "gteu65decoderom.bin", 0x0000, 0x02f1, CRC(089af0c6) SHA1(0f46a73a7859a694a07ebe74d476fae80e57e329) )
- ROM_REGION( 0x0800, "decode", 0 ) /* from the CY7C291A inside of the custom CPU */
- ROM_LOAD( "megacard_cy7291a.bin", 0x0000, 0x0800, CRC(596f01ac) SHA1(a8606a1dd385fbb46b1a96f11a759fa6580803d8) ) /* new dump */
+ ROM_REGION( 0x0800, "decode", 0 ) // from the CY7C291A inside of the custom CPU
+ ROM_LOAD( "megacard_cy7291a.bin", 0x0000, 0x0800, CRC(596f01ac) SHA1(a8606a1dd385fbb46b1a96f11a759fa6580803d8) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "mega_zg2.ic11", 0x0000, 0x8000, CRC(0993d380) SHA1(e5e2386948fba2fb6b79339af27bd1d0f1e198ca) )
@@ -6427,9 +6581,9 @@ ROM_END
Unfortunatelly, the graphics ROM vesely_zg_1.ic10 has address 8 line (leg 25) shorted.
Seems that the protection diode was blown due to a bad handling.
- With forensics technics, a special device was constructed to process the faulty ROM
- and try to read the contents. Fortunatelly after all these efforts, we got
- a perfect and complete dump.
+ With forensics techniques, a special device was constructed to process
+ the faulty ROM and try to read the contents. Fortunatelly after all these
+ efforts, we got a perfect and complete dump.
Specs:
@@ -6484,9 +6638,9 @@ ROM_END
ROM_START( jokercrd )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "ic41.bin", 0x4000, 0x4000, CRC(d36188b3) SHA1(3fb848fabbbde9fbb70875b3dfef62bfb3a8cbcb) )
- ROM_IGNORE( 0x4000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x4000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "ic37.bin", 0xc000, 0x4000, CRC(8e0d70c4) SHA1(018f92631acbe98e5826a41698f0e07b4b46cd71) )
- ROM_IGNORE( 0x4000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x4000 ) // Identical halves. Discarding 2nd half
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "vesely_zg_2.ic11", 0x0000, 0x8000, CRC(21d05a57) SHA1(156c18ec31b08e4c4af6f73b49cb5d5c68d1670f) )
@@ -6528,25 +6682,25 @@ ROM_END
ROM_START( mongolnw )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "prgteov.2.3m.u16", 0x8000, 0x8000, CRC(996b851a) SHA1(ef4e3d036ca10b33c83749024d04c4d4c09feeb7) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x10000, "cpu1", 0 ) /* TSC87C52-16CB MCU Code */
+ ROM_REGION( 0x10000, "cpu1", 0 ) // TSC87C52-16CB MCU Code
ROM_LOAD( "tsc87c52-mf.u40", 0x0000, 0x02000 , CRC(ae22e778) SHA1(0897e05967d68d7f23489e98717663e3a3176070) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "mong.rc.b2.u3", 0x0000, 0x8000, CRC(5e019b73) SHA1(63a544dccb9589e5a6b938e604c09d4d8fc060fc) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "mong.rc.c1.u2", 0x8000, 0x8000, CRC(e3fc24c4) SHA1(ea4e67ace63b55a76365f7e11a67c7d420a52dd7) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "mongolnw_nvram.bin", 0x0000, 0x0800, CRC(700531fa) SHA1(a8bcf86df6bd06d2ee54b4898dd7822060b81dba) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29pc_mf.u24", 0x0000, 0x0200, CRC(da9181af) SHA1(1b30d992f3b2a4b3bd81e3f99632311988e2e8d1) )
ROM_REGION( 0x0200, "plds", 0 )
- ROM_LOAD( "palce16v8h_mf.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_mf.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
ROM_END
@@ -6588,25 +6742,25 @@ ROM_END
ROM_START( soccernw )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "prgteo2gv2.3.u16", 0x8000, 0x8000, CRC(c61d1937) SHA1(c516f13a108da60b7ccee338b63a025009ef9099) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x10000, "cpu1", 0 ) /* TSC87C52-16CB MCU Code */
+ ROM_REGION( 0x10000, "cpu1", 0 ) // TSC87C52-16CB MCU Code
ROM_LOAD( "tsc87c52-sn.u40", 0x0000, 0x02000 , CRC(af0bd35b) SHA1(c6613a7bcdec2fd6060d6dcf639654568de87e75) )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "soccer2.u3", 0x0000, 0x8000, CRC(db09b5bb) SHA1(a12bf2938f5482ea5ebc0db6fd6594e1beb97017) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "soccer1.u2", 0x8000, 0x8000, CRC(564cc467) SHA1(8f90c4bacd97484623666b25dae77e628908e243) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "soccernw_nvram.bin", 0x0000, 0x0800, CRC(607247bd) SHA1(06bbed08166d8930f14e1f41843ac7faeded263d) )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "am27s29pc_sn.u24", 0x0000, 0x0200, CRC(d02894fc) SHA1(adcdc912cc0b7a7f67b122fa94fca921c957b282) )
ROM_REGION( 0x0200, "plds", 0 )
- ROM_LOAD( "palce16v8h_sn.u5", 0x0000, 0x0117, NO_DUMP ) /* PAL is read protected */
+ ROM_LOAD( "palce16v8h_sn.u5", 0x0000, 0x0117, NO_DUMP ) // PLD is read protected
ROM_END
@@ -6730,7 +6884,7 @@ ROM_END
--+-----------------------------------------------------------------------
*/
-ROM_START( funquiz ) /* Fun World Quiz */
+ROM_START( funquiz ) // Fun World Quiz
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "kqu_6.bin", 0xc000, 0x4000, CRC(50f0e586) SHA1(85ce5b95283113e2ac94fd882c57ce1b26135ed0) )
@@ -6740,31 +6894,31 @@ ROM_START( funquiz ) /* Fun World Quiz */
ROM_FILL( 0x8000, 0x4000, 0xff)
ROM_LOAD( "q_2.bin", 0xc000, 0x4000, CRC(ce07c6e1) SHA1(6b77a9198e29c195d983b856e8826e8174945321) )
- /* One unpopulated questions socket... Maybe sport_1 is missing */
+// One unpopulated questions socket... Maybe sport_1 is missing
ROM_REGION( 0x100000, "questions", ROMREGION_ERASEFF )
- /* 01 - Allgemein */
+ // 01 - Allgemein
ROM_LOAD( "allg_1.bin", 0x00000, 0x8000, CRC(1351cf56) SHA1(50e89c3e6d256bcf7f1d3c0dbef935e4e8561096) )
ROM_LOAD( "allg_2.bin", 0x08000, 0x8000, CRC(021492a4) SHA1(b59e1303f17c9e5af05a808118ae729205690bb2) )
ROM_LOAD( "allg_3.bin", 0x10000, 0x8000, CRC(de8e055f) SHA1(593fce143ee5994087bbac8b51ac7e2d02e8701c) )
ROM_LOAD( "allg_4.bin", 0x18000, 0x8000, CRC(5c87177a) SHA1(a8a8318165008cb3295e25d4b4d38146f44a32fc) ) // this one has the category in the rom in ALL caps, is it official?
ROM_LOAD( "allg_5.bin", 0x20000, 0x8000, CRC(83056686) SHA1(00f14ded371751d54a391bf583d940b32ddeae58) )
- /* 02 - Geschichte */
+ // 02 - Geschichte
ROM_LOAD( "gesch_1.bin", 0x28000, 0x8000, CRC(6f785938) SHA1(1e3df7c262d8cb7d7981c9d424d4c1361fe55b50) )
ROM_LOAD( "gesch_2.bin", 0x30000, 0x8000, CRC(3363c0ba) SHA1(f1a2a86e6abc73dd9312fa744b6929fae138e219) )
- /* 03 - Geographie */
+ // 03 - Geographie
ROM_LOAD( "geo_1.bin", 0x38000, 0x8000, CRC(504da831) SHA1(4bef7bed4d300400c094cb30e9af55d3c6f47c29) )
ROM_LOAD( "geo_2.bin", 0x40000, 0x8000, CRC(7c563119) SHA1(9f3ae3ba3e4f60d9ea4b5c95aa5aaada8bb446a3) )
- /* 04 - Technik */
+ // 04 - Technik
ROM_LOAD( "tech_1.bin", 0x48000, 0x8000, CRC(cf5b9edc) SHA1(f1085c9915d21c4da581d06c9568d2bb47d467ed) )
- /* 05 - Sport */
+ // 05 - Sport
ROM_LOAD( "sport_2.bin", 0x50000, 0x8000, CRC(7accde63) SHA1(75ec3a02368d3a07d48ef9a9ff4ca7f8cf7798e2) )
- /* 07 - Pop */
+ // 07 - Pop
ROM_LOAD( "pop_1.bin", 0x58000, 0x8000, CRC(5c74781e) SHA1(0a50a706fd397bb220e31f1a7adaa4204b242888) )
ROM_LOAD( "pop_2.bin", 0x60000, 0x8000, CRC(10103648) SHA1(6fdc1aa4dcc8919e46def1c19adc2b9686c0f72d) )
@@ -6793,29 +6947,29 @@ ROM_START( funquiza )
ROM_REGION( 0x100000, "questions", ROMREGION_ERASEFF )
- /* 01 - Allgemein */
+ // 01 - Allgemein
ROM_LOAD( "allg1.bin", 0x00000, 0x8000, CRC(1351cf56) SHA1(50e89c3e6d256bcf7f1d3c0dbef935e4e8561096) )
ROM_LOAD( "allg2.bin", 0x08000, 0x8000, CRC(021492a4) SHA1(b59e1303f17c9e5af05a808118ae729205690bb2) )
ROM_LOAD( "allg3.bin", 0x10000, 0x8000, CRC(4eb29de3) SHA1(5c5d47959c06261ab51fc4e821bff0fe41ac9176) )
ROM_LOAD( "allg4.bin", 0x18000, 0x8000, CRC(5c87177a) SHA1(a8a8318165008cb3295e25d4b4d38146f44a32fc) )
ROM_LOAD( "allg5.bin", 0x20000, 0x8000, CRC(83056686) SHA1(00f14ded371751d54a391bf583d940b32ddeae58) )
- /* 02 - Technik */
+ // 02 - Technik
ROM_LOAD( "tech1.bin", 0x28000, 0x8000, CRC(cf5b9edc) SHA1(f1085c9915d21c4da581d06c9568d2bb47d467ed) )
- /* 03 - Sport */
+ // 03 - Sport
ROM_LOAD( "sp1.bin", 0x30000, 0x8000, CRC(20fb1261) SHA1(ad029f1a2b19365543c77fcd1103f6c5783c9f68) )
ROM_LOAD( "sp2.bin", 0x38000, 0x8000, CRC(1988f5b7) SHA1(969ae64796e432c04862cb8c159e419a4793e9f0) )
- /* 04 - Film - Unterhaltung */
+ // 04 - Film - Unterhaltung
ROM_LOAD( "unterh1.bin", 0x40000, 0x8000, CRC(996e7adc) SHA1(7b271cdb6ef555d31c2b17c6104bd30cd2eabcb3) )
- /* 05 - Geographie */
+ // 05 - Geographie
ROM_LOAD( "geo1.bin", 0x48000, 0x8000, CRC(504da831) SHA1(4bef7bed4d300400c094cb30e9af55d3c6f47c29) )
ROM_LOAD( "geo2.bin", 0x50000, 0x8000, CRC(7c563119) SHA1(9f3ae3ba3e4f60d9ea4b5c95aa5aaada8bb446a3) )
ROM_LOAD( "geo3.bin", 0x58000, 0x8000, CRC(7c563119) SHA1(9f3ae3ba3e4f60d9ea4b5c95aa5aaada8bb446a3) )
- /* 06 - Pop */
+ // 06 - Pop
ROM_LOAD( "pop_1.bin", 0x60000, 0x8000, CRC(5c74781e) SHA1(0a50a706fd397bb220e31f1a7adaa4204b242888) )
ROM_LOAD( "pop_2.bin", 0x68000, 0x8000, CRC(10103648) SHA1(6fdc1aa4dcc8919e46def1c19adc2b9686c0f72d) )
@@ -6841,29 +6995,29 @@ ROM_START( funquizb )
ROM_REGION( 0x100000, "questions", ROMREGION_ERASEFF )
- /* 01 - Allgemein */
+ // 01 - Allgemein
ROM_LOAD( "allg1.bin", 0x00000, 0x8000, CRC(1351cf56) SHA1(50e89c3e6d256bcf7f1d3c0dbef935e4e8561096) )
ROM_LOAD( "allg2.bin", 0x08000, 0x8000, CRC(021492a4) SHA1(b59e1303f17c9e5af05a808118ae729205690bb2) )
ROM_LOAD( "allg3.bin", 0x10000, 0x8000, CRC(de8e055f) SHA1(593fce143ee5994087bbac8b51ac7e2d02e8701c) )
ROM_LOAD( "allg4.bin", 0x18000, 0x8000, CRC(5c87177a) SHA1(a8a8318165008cb3295e25d4b4d38146f44a32fc) )
ROM_LOAD( "allg5.bin", 0x20000, 0x8000, CRC(83056686) SHA1(00f14ded371751d54a391bf583d940b32ddeae58) )
- /* 02 - Technik */
+ // 02 - Technik
ROM_LOAD( "tech1.bin", 0x28000, 0x8000, CRC(cf5b9edc) SHA1(f1085c9915d21c4da581d06c9568d2bb47d467ed) )
- /* 03 - Sport */
+ // 03 - Sport
ROM_LOAD( "sport1.bin", 0x30000, 0x8000, CRC(b351c745) SHA1(3b64d8e935eb4cd5bdf82934983b3ffab465257a) )
ROM_LOAD( "sport2.bin", 0x38000, 0x8000, CRC(7accde63) SHA1(75ec3a02368d3a07d48ef9a9ff4ca7f8cf7798e2) )
- /* 04 - Film - Unterhaltung */
+ // 04 - Film - Unterhaltung
ROM_LOAD( "unt1.bin", 0x40000, 0x8000, CRC(996e7adc) SHA1(7b271cdb6ef555d31c2b17c6104bd30cd2eabcb3) )
- /* 05 - Geographie */
+ // 05 - Geographie
ROM_LOAD( "geo1.bin", 0x48000, 0x8000, CRC(504da831) SHA1(4bef7bed4d300400c094cb30e9af55d3c6f47c29) )
ROM_LOAD( "geo2.bin", 0x50000, 0x8000, CRC(7c563119) SHA1(9f3ae3ba3e4f60d9ea4b5c95aa5aaada8bb446a3) )
ROM_LOAD( "geo3.bin", 0x58000, 0x8000, CRC(7c563119) SHA1(9f3ae3ba3e4f60d9ea4b5c95aa5aaada8bb446a3) )
- /* 06 - Pop */
+ // 06 - Pop
ROM_LOAD( "pop1.bin", 0x60000, 0x8000, CRC(5c74781e) SHA1(0a50a706fd397bb220e31f1a7adaa4204b242888) )
ROM_LOAD( "pop2.bin", 0x68000, 0x8000, CRC(10103648) SHA1(6fdc1aa4dcc8919e46def1c19adc2b9686c0f72d) )
@@ -6887,11 +7041,11 @@ ROM_START( witchryl )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "2.u11", 0x0000, 0x8000, CRC(7edc8f44) SHA1(cabad613fa8a72dc12587d19a72bc9c6861486bd) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "3.u4", 0x8000, 0x8000, CRC(5e4a0d59) SHA1(08eb9b1a617a7b2e6f87377819dba07082cf38b4) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "witchryl_nvram.bin", 0x0000, 0x0800, CRC(98366bed) SHA1(279a5ce4639b8b2ac29146b32512615253c45991) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -6908,7 +7062,7 @@ ROM_END
*/
-ROM_START( novoplay ) /* Similar to Royal Vegas Joker Card */
+ROM_START( novoplay ) // Similar to Royal Vegas Joker Card
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "np1_run.bin", 0x8000, 0x8000, CRC(4078d695) SHA1(d0e39064250733968044aec216040fe62fecc880) )
@@ -6916,10 +7070,10 @@ ROM_START( novoplay ) /* Similar to Royal Vegas Joker Card */
ROM_LOAD( "np1_ch2.bin", 0x0000, 0x8000, CRC(188d6fad) SHA1(3bc9bab24d8c7beed0c5f491c19a004ca7d719a1) )
ROM_LOAD( "np1_ch1.bin", 0x8000, 0x8000, CRC(fdc3bd67) SHA1(0ec2d5e0b1937849934f98e253e18887af0331e8) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "novoplay_nvram.bin", 0x0000, 0x0800, CRC(92019972) SHA1(e6d1e231cd2ce27e718ed9482dbe9ddc8612eb67) )
- ROM_REGION( 0x0200, "proms", 0 ) /* PLD address the 2nd half */
+ ROM_REGION( 0x0200, "proms", 0 ) // PLD address the 2nd half
ROM_LOAD( "np1_27s29.bin", 0x0000, 0x0200, CRC(8992aa4d) SHA1(5a0649bff66e7cab1bcbadcdfc74c77a747cc58f) )
ROM_END
@@ -6939,7 +7093,7 @@ ROM_END
*/
-ROM_START( jolycdsp ) /* Encrypted program in a module. Blue TAB PCB encrypted graphics */
+ROM_START( jolycdsp ) // Encrypted program in a module. Blue TAB PCB encrypted graphics
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "ct3.bin", 0x8000, 0x8000, CRC(0c9cbae6) SHA1(4f834370229797cac302a5185ed1e77ef2b7cabb) )
@@ -6947,10 +7101,10 @@ ROM_START( jolycdsp ) /* Encrypted program in a module. Blue TAB PCB encrypted
ROM_LOAD( "ct2.bin", 0x0000, 0x8000, CRC(7569e719) SHA1(f96e1e72bc13d1888f3868f8d404fd3db94db7b2) )
ROM_LOAD( "ct1.bin", 0x8000, 0x8000, CRC(8f438635) SHA1(3200e20f4b28173cc2a68d0f87969627570418dc) )
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "ctunk_nvram.bin", 0x0000, 0x0800, CRC(c55c6706) SHA1(a38ae926f057fb47e48ca841b2d097fc4fd06416) )
- ROM_REGION( 0x0200, "proms", 0 ) /* Borrowed from the parent set */
+ ROM_REGION( 0x0200, "proms", 0 ) // Borrowed from the parent set
ROM_LOAD( "82s147.bin", 0x0000, 0x0200, CRC(5ebc5659) SHA1(8d59011a181399682ab6e8ed14f83101e9bfa0c6) )
ROM_END
@@ -6983,11 +7137,11 @@ ROM_START( rcdino4 )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "m27c512.u2", 0x0000, 0x8000, CRC(915f1e59) SHA1(2eb2a7acca50318eb1775b01a00b1d3c74e1522c) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
ROM_LOAD( "m27c512.u20", 0x8000, 0x8000, CRC(86e55f5a) SHA1(be71301b6887e8cc5924864d0f97b54e0668875e) )
- ROM_IGNORE( 0x8000 ) /* Identical halves. Discarding 2nd half */
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "rcdino4_nvram.bin", 0x0000, 0x0800, CRC(a2dc069e) SHA1(23e296cc0cc0c6f0c34eccffff8c78d2cef2dbae) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -7010,11 +7164,11 @@ ROM_START( chinatow )
ROM_REGION( 0x10000, "gfx1", 0 )
ROM_LOAD( "27c512.u2", 0x0000, 0x8000, CRC(6ace221f) SHA1(d35a6621d9d9231a844d7043da78035855ebf572) )
- ROM_CONTINUE( 0x0000, 0x8000) /* Discarding 1nd half 0xff filled*/
+ ROM_CONTINUE( 0x0000, 0x8000) // Discarding 1nd half 0xff filled
ROM_LOAD( "27c512.u20", 0x8000, 0x8000, CRC(efb7f1ec) SHA1(260005526fc9b4087ca03f7cc585e40b6fa007fb) )
- ROM_CONTINUE( 0x8000, 0x8000) /* Discarding 1nd half 0xff filled*/
+ ROM_CONTINUE( 0x8000, 0x8000) // Discarding 1nd half 0xff filled
- ROM_REGION( 0x0800, "nvram", 0 ) /* default NVRAM */
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
ROM_LOAD( "chinatow_nvram.bin", 0x0000, 0x0800, CRC(eef4c5e7) SHA1(a2d9a9f617d35ccb99236114e5ce3257ad572f49) )
ROM_REGION( 0x0200, "proms", 0 )
@@ -7164,7 +7318,7 @@ ROM_START( fw_a7_11a )
ROM_REGION( 0x0200, "proms", 0 )
ROM_LOAD( "m3-7649a-5.bin", 0x0000, 0x0200, CRC(f990a9ae) SHA1(f7133798b5f20dd5b8dbe5d1a6876341710d93a8) )
- ROM_REGION( 0x0200, "plds", 0 ) /* Cracked PLD */
+ ROM_REGION( 0x0200, "plds", 0 ) // cracked PLD
ROM_LOAD( "pal16l8acn_block.bin", 0x0000, 0x0117, CRC(fcda7872) SHA1(60acdb968e6229a8f71c2e29d22e132906a65bd5) )
ROM_END
@@ -7244,7 +7398,110 @@ ROM_START( jokcrdep )
ROM_END
+/*
+ Gratis Poker
+ Stmk
+ Version: 004
+ 29. Sept. 95
+
+*/
+ROM_START( gratispk ) // Gratis Poker (V.204, Set 1)
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "gratis_poker_club_ver_204.bin", 0x8000, 0x8000, CRC(e53da78e) SHA1(6b87af4d66082f1a18e9e00a41df2484f5373cc7) )
+
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "3.bin", 0x0000, 0x8000, CRC(daec20c7) SHA1(340bdb7749a7d898e96db5a470821cfe7216ea57) )
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
+ ROM_LOAD( "2.bin", 0x8000, 0x8000, CRC(112c5f33) SHA1(fffaa247a97f9bde7374cc80ab0bb9fb71bcc4b6) )
+ ROM_IGNORE( 0x8000 ) // Identical halves. Discarding 2nd half
+
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_LOAD( "gratispk_nvram.bin", 0x0000, 0x0800, CRC(8fcad62f) SHA1(85def713ed5b9bbdbf0d077a38f779d6f4329a1c) )
+
+ ROM_REGION( 0x0200, "proms", 0 )
+ ROM_LOAD( "tbp28s42n.bin", 0x0000, 0x0200, CRC(e92f74e0) SHA1(dfc4a9d140d21b990f769c10802c4d2c33dd4132) )
+ROM_END
+
+ROM_START( gratispka ) // Gratis Poker (V.204, Set 2)
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "35g_ver_204.bin", 0x8000, 0x8000, CRC(e53da78e) SHA1(6b87af4d66082f1a18e9e00a41df2484f5373cc7) )
+
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "3.bin", 0x0000, 0x8000, CRC(4f077fa3) SHA1(d65005b7111b77ac7c3707bd12bc376506d9477b) )
+ ROM_LOAD( "2.bin", 0x8000, 0x8000, CRC(0f3711b0) SHA1(ce874dbfc2d7171cff2be41d4a44fe8194526ef7) )
+
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_LOAD( "gratispk_nvram.bin", 0x0000, 0x0800, CRC(8fcad62f) SHA1(85def713ed5b9bbdbf0d077a38f779d6f4329a1c) )
+
+ ROM_REGION( 0x0200, "proms", 0 )
+ ROM_LOAD( "tbp28s42n.bin", 0x0000, 0x0200, CRC(e92f74e0) SHA1(dfc4a9d140d21b990f769c10802c4d2c33dd4132) )
+ROM_END
+
+
+/*
+ Γκούλιτ
+ Nkoúlit
+ Gullit
+
+ Greek hack of Royal Card.
+
+*/
+ROM_START( nkoulit )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "27c256-3.bin", 0x8000, 0x8000, CRC(3f4f671d) SHA1(0aa87f813567f7a537315bf3d452343e5a449e13) )
+
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "27c256-2.bin", 0x0000, 0x8000, CRC(4a9ea5ad) SHA1(50504544265646e12ce769a1fd40d7afeae8b8d3) )
+ ROM_LOAD( "27c256-1.bin", 0x8000, 0x8000, CRC(7b3a6d1a) SHA1(b7f2e534ad4467cd0a9d86019be8110caf45c024) )
+
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_LOAD( "nkoulit_nvram.bin", 0x0000, 0x0800, CRC(73584f67) SHA1(4aab0d4fe846592e1cbc8b3c2411ddc1bf79fd95) )
+
+ ROM_REGION( 0x0200, "proms", 0 )
+ ROM_LOAD( "am27s29pc.bin", 0x0000, 0x0200, CRC(8bc86f48) SHA1(4c677ab9314a1f571e35104b22659e6811aeb194) )
+ROM_END
+
+
+/*
+ Reflex Cards (English)
+ Need special NVRAM to boot.
+
+ Without the factory NVRAM, you can generate one.
+ The attract works, and allow coin up. When you start a game,
+ a serial number entering screen appears. You must to match
+ the secret number to continue:
+
+ Serial: 00000000
+ Key: FFFFFFFF
+
+ The real serial number isn't shown. Just zeroes as mask.
+ You must to enter digit by digit using the HOLD buttons,
+ then turn the machine off, and on. (you can reset in MAME).
+
+ If you entered the correct number, the game continues,
+ otherwise you'll be stuck forever.
+
+ The code and NVRAM were reversed to find the serial number
+ and key offsets and the way they are stored, to construct
+ a working default NVRAM.
+
+*/
+ROM_START( reflexcrd )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "bonus_2_27c256-1.bin", 0x8000, 0x8000, CRC(8fbcf0b9) SHA1(3a45c09fbec3e4ecce24ac2562a68b453755886f) )
+
+ ROM_REGION( 0x10000, "gfx1", 0 )
+ ROM_LOAD( "27c256-2.bin", 0x0000, 0x8000, CRC(05fe86fc) SHA1(a58ab5d107936f7d462f8f748bb6ac27bd77429b) )
+ ROM_LOAD( "27c256-3.bin", 0x8000, 0x8000, CRC(1617ed13) SHA1(312065406ce1d1d7c4ad566e2b13268f7eb524bb) )
+
+ ROM_REGION( 0x0800, "nvram", 0 ) // default NVRAM
+ ROM_LOAD( "reflexcrd_nvram.bin", 0x0000, 0x0800, CRC(c2c69e5b) SHA1(e4abbf09abc044ba17e542cc8e1cfa16ee7cf776) )
+
+ ROM_REGION( 0x0200, "proms", 0 )
+ ROM_LOAD( "bipolar_prom.bin", 0x0000, 0x0200, CRC(8bc86f48) SHA1(4c677ab9314a1f571e35104b22659e6811aeb194) )
+ROM_END
+
/**************************
* Driver Initialization *
**************************/
@@ -7276,13 +7533,13 @@ void funworld_state::init_tabblue()
for (x=0x0000; x < 0x10000; x++)
{
- na = src[x] & 0xf0; /* nibble A */
- nb = src[x] << 4; /* nibble B */
+ na = src[x] & 0xf0; // nibble A
+ nb = src[x] << 4; // nibble B
- nad = (na ^ (na >> 1)) << 1; /* nibble A decrypted */
- nbd = ((nb ^ (nb >> 1)) >> 3) & 0x0f; /* nibble B decrypted */
+ nad = (na ^ (na >> 1)) << 1; // nibble A decrypted
+ nbd = ((nb ^ (nb >> 1)) >> 3) & 0x0f; // nibble B decrypted
- src[x] = nad + nbd; /* decrypted byte */
+ src[x] = nad + nbd; // decrypted byte
}
}
@@ -7310,20 +7567,20 @@ void magicrd2_state::init_magicd2b()
void magicrd2_state::init_magicd2c()
{
- /*** same as blue TAB PCB, with the magicd2a patch ***/
+// *** same as blue TAB PCB, with the magicd2a patch ***
int x, na, nb, nad, nbd;
uint8_t *src = memregion( "gfx1" )->base();
uint8_t *ROM = memregion("maincpu")->base();
for (x=0x0000; x < 0x10000; x++)
{
- na = src[x] & 0xf0; /* nibble A */
- nb = src[x] << 4; /* nibble B */
+ na = src[x] & 0xf0; // nibble A
+ nb = src[x] << 4; // nibble B
- nad = (na ^ (na >> 1)) << 1; /* nibble A decrypted */
- nbd = ((nb ^ (nb >> 1)) >> 3) & 0x0f; /* nibble B decrypted */
+ nad = (na ^ (na >> 1)) << 1; // nibble A decrypted
+ nbd = ((nb ^ (nb >> 1)) >> 3) & 0x0f; // nibble B decrypted
- src[x] = nad + nbd; /* decrypted byte */
+ src[x] = nad + nbd; // decrypted byte
}
ROM[0xc1c6] = 0x92;
@@ -7332,26 +7589,26 @@ void magicrd2_state::init_magicd2c()
void funworld_state::init_mongolnw()
{
- /* temporary patch to avoid hardware errors for debug purposes */
+// temporary patch to avoid hardware errors for debug purposes
uint8_t *ROM = memregion("maincpu")->base();
ROM[0x9115] = 0xa5;
- /* prevents one test from triggering hardware error */
+// prevents one test from triggering hardware error
ROM[0xb8f3] = 0xff;
}
void funworld_state::init_soccernw()
{
-/* temporary patch to avoid hardware errors for debug purposes */
+// temporary patch to avoid hardware errors for debug purposes
uint8_t *ROM = memregion("maincpu")->base();
ROM[0x80b2] = 0xa9;
ROM[0x80b3] = 0x00;
ROM[0x9115] = 0xa5;
-/* prevent one test from triggering hardware error */
+// prevents one test from triggering hardware error
ROM[0xb8f3] = 0xff;
}
@@ -7395,7 +7652,7 @@ void funworld_state::init_saloon()
* Program ROM decryption *
*****************************/
- /* data lines swap: 76543210 -> 76543012 */
+ // data lines swap: 76543210 -> 76543012
for (int i = start; i < size; i++)
{
@@ -7406,7 +7663,7 @@ void funworld_state::init_saloon()
std::vector<uint8_t> buffer(size);
memcpy(&buffer[0], rom, size);
- /* address lines swap: fedcba9876543210 -> fedcba9820134567 */
+ // address lines swap: fedcba9876543210 -> fedcba9820134567
for (int i = start; i < size; i++)
{
@@ -7425,7 +7682,7 @@ void funworld_state::init_saloon()
std::vector<uint8_t> buffer(sizeg);
memcpy(&buffer[0], gfxrom, sizeg);
- /* address lines swap: fedcba9876543210 -> fedcb67584a39012 */
+ // address lines swap: fedcba9876543210 -> fedcb67584a39012
for (int i = 0; i < sizeg; i++)
{
@@ -7439,7 +7696,7 @@ void funworld_state::init_saloon()
* Color PROM decryption *
****************************/
- /* data lines swap: 76543210 -> 23546710 */
+ // data lines swap: 76543210 -> 23546710
{
std::vector<uint8_t> buffer;
@@ -7448,7 +7705,7 @@ void funworld_state::init_saloon()
buffer.push_back(bitswap<8>(prom[i], 2, 3, 5, 4, 6, 7, 1, 0));
}
- /* address lines swap: fedcba9876543210 -> fedcba9487652013 */
+ // address lines swap: fedcba9876543210 -> fedcba9487652013
for (int i = 0; i < sizep; i++)
{
int a = bitswap<16>(i, 15, 14, 13, 12, 11, 10, 9, 4, 8, 7, 6, 5, 2, 0, 1, 3);
@@ -7494,7 +7751,7 @@ void funworld_state::init_dino4()
* Program ROM decryption *
*****************************/
- /* data lines swap: 76543210 -> 76543120 */
+ // data lines swap: 76543210 -> 76543120
for (int i = start; i < size; i++)
{
@@ -7505,7 +7762,7 @@ void funworld_state::init_dino4()
std::vector<uint8_t> buffer(size);
memcpy(&buffer[0], rom, size);
- /* address lines swap: fedcba9876543210 -> fedcba9867543210 */
+ // address lines swap: fedcba9876543210 -> fedcba9867543210
for (int i = start; i < size; i++)
{
int a = bitswap<16>(i, 15, 13, 14, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0);
@@ -7522,7 +7779,7 @@ void funworld_state::init_dino4()
std::vector<uint8_t> buffer(sizeg);
memcpy(&buffer[0], gfxrom, sizeg);
- /* address lines swap: fedcba9876543210 -> fedcb67584a39012 */
+ // address lines swap: fedcba9876543210 -> fedcb67584a39012
for (int i = 0; i < sizeg; i++)
{
@@ -7549,7 +7806,7 @@ void funworld_state::init_ctunk()
* Program ROM decryption *
*****************************/
- /* data lines swap: 76543210 -> 56734012 */
+ // data lines swap: 76543210 -> 56734012
for (int i = start; i < size; i++)
{
@@ -7568,13 +7825,13 @@ void funworld_state::init_ctunk()
//uint8_t *ROM = memregion("maincpu")->base();
for (int x = 0x0000; x < 0x10000; x++)
{
- int na = src[x] & 0xf0; /* nibble A */
- int nb = src[x] << 4; /* nibble B */
+ int na = src[x] & 0xf0; // nibble A
+ int nb = src[x] << 4; // nibble B
- int nad = (na ^ (na >> 1)) << 1; /* nibble A decrypted */
- int nbd = ((nb ^ (nb >> 1)) >> 3) & 0x0f; /* nibble B decrypted */
+ int nad = (na ^ (na >> 1)) << 1; // nibble A decrypted
+ int nbd = ((nb ^ (nb >> 1)) >> 3) & 0x0f; // nibble B decrypted
- src[x] = nad + nbd; /* decrypted byte */
+ src[x] = nad + nbd; // decrypted byte
}
}
@@ -7585,7 +7842,7 @@ static void decrypt_rcdino4(uint8_t *rom, int size, uint8_t *gfxrom, int sizeg,
* Program ROM decryption *
*****************************/
- /* data lines swap: 76543210 -> 76543120 */
+ // data lines swap: 76543210 -> 76543120
{
std::vector<uint8_t> buffer;
for (int i = 0; i < size; i++)
@@ -7593,7 +7850,7 @@ static void decrypt_rcdino4(uint8_t *rom, int size, uint8_t *gfxrom, int sizeg,
buffer.push_back(bitswap<8>(rom[i], 7, 6, 5, 4, 3, 1, 2, 0));
}
- /* address lines swap: fedcba9876543210 -> fedcba9867543210 */
+ // address lines swap: fedcba9876543210 -> fedcba9867543210
for (int i = 0; i < size; i++)
{
@@ -7611,7 +7868,7 @@ static void decrypt_rcdino4(uint8_t *rom, int size, uint8_t *gfxrom, int sizeg,
std::vector<uint8_t> buffer(sizeg);
memcpy(&buffer[0], gfxrom, sizeg);
- /* address lines swap: fedcba9876543210 -> fedcb67584a39012 */
+ // address lines swap: fedcba9876543210 -> fedcb67584a39012
for (int i = 0; i < sizeg; i++)
{
@@ -7620,7 +7877,7 @@ static void decrypt_rcdino4(uint8_t *rom, int size, uint8_t *gfxrom, int sizeg,
}
}
- /* d4-d5 data lines swap, plus a XOR with 0x81, implemented in two steps for an easy view */
+ // d4-d5 data lines swap, plus a XOR with 0x81, implemented in two steps for an easy view
for (int x = 0x0000; x < 0x10000; x++)
{
@@ -7634,7 +7891,7 @@ static void decrypt_rcdino4(uint8_t *rom, int size, uint8_t *gfxrom, int sizeg,
static uint8_t rcdino4_add[] =
{
-/* 0 1 2 3 4 5 6 7 8 9 a b c d e f*/
+// 0 1 2 3 4 5 6 7 8 9 a b c d e f
/*0*/ 1, 9, 9, 9, 9, 2, 9, 9, 1, 2, 1, 9, 9, 3, 9, 9,
/*1*/ 2, 2, 9, 9, 9, 9, 9, 9, 1, 9, 1, 9, 9, 9, 9, 9,
/*2*/ 3, 9, 9, 9, 9, 2, 2, 9, 1, 2, 1, 9, 9, 3, 3, 9,
@@ -7655,65 +7912,65 @@ static uint8_t rcdino4_add[] =
static uint8_t rcdino4_keys40[] =
{
-/* 40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d*/
+// 40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d
0x36, 0x54, 0x47, 0x6b, 0xce, 0x95, 0xa2, 0x66, 0x3a, 0x46, 0x53, 0xd7, 0xc4, 0xa4,
-/* 4e 4f*/
+// 4e 4f
0x00, 0x00,
-/* 50*/
+// 50
0x56
};
static uint8_t rcdino4_keys80[] =
{
-/* 81 82 83 84 85 */
+// 81 82 83 84 85
0xb8, 0x32, 0x1c, 0x23, 0xe2,
-/* 86 87 88 89 8a 8b 8c 8d 8e 8f 90 91*/
+// 86 87 88 89 8a 8b 8c 8d 8e 8f 90 91
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-/* 92 93 94 95 96 97 */
+// 92 93 94 95 96 97
0x4c, 0x00, 0x3d, 0x00, 0xd9, 0x16,
-/* 98 99 9a 9b 9c 9d 9e 9f a0 a1 a2 a3*/
+// 98 99 9a 9b 9c 9d 9e 9f a0 a1 a2 a3
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-/* a4 a5 a6*/
+// a4 a5 a6
0x5e, 0x73, 0x69,
-/* a7 a8 a9*/
+// a7 a8 a9
0x00, 0x00, 0x00,
-/* aa*/
+// aa
0xa6,
-/* ab ac ad ae af*/
+// ab ac ad ae af
0x00, 0x00, 0x00, 0x00, 0x00,
-/* b0 b1*/
+// b0 b1
0xc3, 0x40,
-/* b2 b3 b4 b5 b6 b7 b8 b9 ba bb bc bd be bf c0 c1 c2*/
+// b2 b3 b4 b5 b6 b7 b8 b9 ba bb bc bd be bf c0 c1 c2
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-/* c3 c4 c5*/
+// c3 c4 c5
0x92, 0xb7, 0x24,
-/* c6 c7 c8 c9*/
+// c6 c7 c8 c9
0x00, 0x00, 0x00, 0x00,
-/* ca*/
+// ca
0x62,
-/* cb cc cd ce cf*/
+// cb cc cd ce cf
0x00, 0x00, 0x00, 0x00, 0x00,
-/* d0*/
+// d0
0x84,
-/* d1*/
+// d1
0x00,
-/* d2*/
+// d2
0xaa,
-/* d3 d4 d5*/
+// d3 d4 d5
0x00, 0x00, 0x00,
-/* d6*/
+// d6
0xea,
-/* d7 d8 d9 da db dc dd de df*/
+// d7 d8 d9 da db dc dd de df
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-/* e0*/
+// e0
0x17,
-/* e1 e2 e3*/
+// e1 e2 e3
0x00, 0x00, 0x00,
-/* e4*/
+// e4
0xc0,
-/* e5 e6 e7 e8 e9 ea eb ec ed ee ef f0 f1 f2 f3 f4 f5 f6 f7*/
+// e5 e6 e7 e8 e9 ea eb ec ed ee ef f0 f1 f2 f3 f4 f5 f6 f7
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-/* f8 f9 fa fb fc fd fe*/
+// f8 f9 fa fb fc fd fe
0x06, 0x1e, 0x28, 0x5a, 0xcf, 0x79, 0x11
};
@@ -7773,40 +8030,40 @@ void chinatow_state::init_rcdino4()
int add = rcdino4_add[c];
if (((i == 0x81)
- && (j >= 0xa3) && (j <= 0xb1) /* text string */
+ && (j >= 0xa3) && (j <= 0xb1) // text string
)
|| ((i == 0x82)
- && (j >= 0x35) && (j <= 0x53) /* table of addresses */
+ && (j >= 0x35) && (j <= 0x53) // table of addresses
)
|| ((i == 0x85)
- && (j >= 0x7e) && (j <= 0x8d) /* '0'-'9', 'A'-'F' */
+ && (j >= 0x7e) && (j <= 0x8d) // '0'-'9', 'A'-'F'
)
|| ((i == 0x94)
- && (((j >= 0x4a) && (j <= 0x86)) /* zeroes */
- || ((j >= 0xbf) && (j <= 0xc1)) /* set of masks */
+ && (((j >= 0x4a) && (j <= 0x86)) // zeroes
+ || ((j >= 0xbf) && (j <= 0xc1)) // set of masks */
)
)
|| ((i == 0x96)
- && (j >= 0x39) && (j <= 0x3e) /* set of masks */
+ && (j >= 0x39) && (j <= 0x3e) // set of masks
)
|| ((i == 0xa6)
- && (j >= 0x30) && (j <= 0x32) /* set of masks */
+ && (j >= 0x30) && (j <= 0x32) // set of masks
)
|| ((i == 0xaa)
- && (j >= 0xf2) /* table of addresses */
+ && (j >= 0xf2) // table of addresses
)
|| ((i == 0xc3)
- && (j >= 0x70) && (j <= 0xaf) /* set of masks */
+ && (j >= 0x70) && (j <= 0xaf) // set of masks
)
|| ((i == 0xc4)
- && (j >= 0xdc) /* zeroes and things */
+ && (j >= 0xdc) // zeroes and things
)
|| ((i == 0xd0)
- && (j >= 0xd2) /* text and zeroes */
+ && (j >= 0xd2) // text and zeroes
)
|| ((i == 0xd2)
- && ((j <= 0x2f) /* text and zeroes */
- || ((j >= 0x84) && (j <= 0xaf)) /* text and zeroes */
+ && ((j <= 0x2f) // text and zeroes
+ || ((j >= 0x84) && (j <= 0xaf)) // text and zeroes
)
)
|| (add == 9)
@@ -7837,7 +8094,7 @@ void chinatow_state::init_rcdino4()
|| (i == 0xf8)
)
{
- j = 0; /* re-align offset after skipping some pages */
+ j = 0; // re-align offset after skipping some pages
}
}
while (1);
@@ -7937,130 +8194,137 @@ void funworld_state::init_impera16()
* Game Drivers *
**********************************************/
-/* YEAR NAME PARENT MACHINE INPUT STATE INIT ROT COMPANY FULLNAME FLAGS LAYOUT */
+// YEAR NAME PARENT MACHINE INPUT STATE INIT ROT COMPANY FULLNAME FLAGS LAYOUT
// Jolly Card based...
-GAMEL( 1985, jollycrd, 0, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (German, set 1)", 0, layout_jollycrd )
-GAMEL( 1985, jollycrda, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (German, set 2)", 0, layout_jollycrd )
-GAMEL( 1985, jolyc3x3, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (3x3 deal)", 0, layout_jollycrd )
-GAMEL( 1993, jolycmzs, jollycrd, cuoreuno, jolyc980, funworld_state, empty_init, ROT0, "MZS Tech", "Jolly Card Professional 2.0 (MZS Tech)", 0, layout_jollycrd )
-GAMEL( 2000, jolyc980, jollycrd, cuoreuno, jolyc980, funworld_state, empty_init, ROT0, "Spale Soft", "Jolly Card Professional 2.0 (Spale Soft)", 0, layout_jollycrd )
-GAMEL( 1998, jolycdev, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria / Evona Electronic", "Jolly Card (Evona Electronic)", 0, layout_jollycrd )
-GAMEL( 1985, jolyccra, jollycrd, cuoreuno, jolycdcr, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (Croatian, set 1)", 0, layout_jollycrd )
-GAMEL( 1993, jolyccrb, jollycrd, cuoreuno, jolycdcr, funworld_state, empty_init, ROT0, "Soft Design", "Jolly Card (Croatian, set 2)", 0, layout_jollycrd )
-GAMEL( 1985, sjcd2kx3, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "M.P.", "Super Joly 2000 - 3x", 0, layout_jollycrd )
-GAMEL( 1986, jolycdab, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Inter Games", "Jolly Card (German, Fun World, bootleg)", 0, layout_jollycrd )
-GAMEL( 1992, jolycdsp, jollycrd, cuoreuno, jolycdit, funworld_state, init_ctunk, ROT0, "TAB Austria", "Jolly Card (Spanish, blue TAB board, encrypted)", 0, layout_royalcrd )
-GAMEL( 1990, jolycdid, jollycrd, cuoreuno, jolycdcr, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, different colors, set 1)", 0, layout_jollycrd ) // italian, CPLD, different colors.
-GAMEL( 1990, jolycdie, jollycrd, cuoreuno, jolycdib, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, different colors, set 2)", 0, layout_jollycrd ) // not from TAB blue PCB.
-GAMEL( 1990, jolycdif, jollycrd, cuoreuno, jolycdib, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, bootleg, set 1)", 0, layout_jollycrd ) // italian, CPLD. doesn't need nvram init.
-GAMEL( 1993, jolycdig, jollycrd, cuoreuno, jolycdib, funworld_state, init_jolycdig, ROT0, "bootleg", "Jolly Card (Italian, bootleg, set 2)", 0, layout_jollycrd ) // italian, CPLD. needs nvram.
-GAMEL( 1990, jolycdih, jollycrd, cuoreuno, jolycdib, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, bootleg, set 3)", 0, layout_jollycrd )
+GAMEL( 1985, jollycrd, 0, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (German, set 1)", 0, layout_jollycrd )
+GAMEL( 1985, jollycrda, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (German, set 2)", 0, layout_jollycrd )
+GAMEL( 1985, jolyc3x3, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (3x3 deal)", 0, layout_jollycrd )
+GAMEL( 1993, jolycmzs, jollycrd, cuoreuno, jolyc980, funworld_state, empty_init, ROT0, "MZS Tech", "Jolly Card Professional 2.0 (MZS Tech)", 0, layout_jollycrd )
+GAMEL( 2000, jolyc980, jollycrd, cuoreuno, jolyc980, funworld_state, empty_init, ROT0, "Spale Soft", "Jolly Card Professional 2.0 (Spale Soft)", 0, layout_jollycrd )
+GAMEL( 1998, jolycdev, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "TAB Austria / Evona Electronic", "Jolly Card (Evona Electronic)", 0, layout_jollycrd )
+GAMEL( 1985, jolyccra, jollycrd, cuoreuno, jolycdcr, funworld_state, empty_init, ROT0, "TAB Austria", "Jolly Card (Croatian, set 1)", 0, layout_jollycrd )
+GAMEL( 1993, jolyccrb, jollycrd, cuoreuno, jolycdcr, funworld_state, empty_init, ROT0, "Soft Design", "Jolly Card (Croatian, set 2)", 0, layout_jollycrd )
+GAMEL( 1985, sjcd2kx3, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "M.P.", "Super Joly 2000 - 3x", 0, layout_jollycrd )
+GAMEL( 1986, jolycdab, jollycrd, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Inter Games", "Jolly Card (German, Fun World, bootleg)", 0, layout_jollycrd )
+GAMEL( 1992, jolycdsp, jollycrd, cuoreuno, jolycdit, funworld_state, init_ctunk, ROT0, "TAB Austria", "Jolly Card (Spanish, blue TAB board, encrypted)", 0, layout_royalcrd )
+GAMEL( 1990, jolycdid, jollycrd, cuoreuno, jolycdcr, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, different colors, set 1)", 0, layout_jollycrd ) // italian, CPLD, different colors.
+GAMEL( 1990, jolycdie, jollycrd, cuoreuno, jolycdib, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, different colors, set 2)", 0, layout_jollycrd ) // not from TAB blue PCB.
+GAMEL( 1990, jolycdif, jollycrd, cuoreuno, jolycdib, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, bootleg, set 1)", 0, layout_jollycrd ) // italian, CPLD. doesn't need nvram init.
+GAMEL( 1993, jolycdig, jollycrd, cuoreuno, jolycdib, funworld_state, init_jolycdig, ROT0, "bootleg", "Jolly Card (Italian, bootleg, set 2)", 0, layout_jollycrd ) // italian, CPLD. needs nvram.
+GAMEL( 1990, jolycdih, jollycrd, cuoreuno, jolycdib, funworld_state, empty_init, ROT0, "bootleg", "Jolly Card (Italian, bootleg, set 3)", 0, layout_jollycrd )
// Bonus Card based...
-GAMEL( 1986, bonuscrd, 0, fw2ndpal, bonuscrd, funworld_state, empty_init, ROT0, "Fun World", "Bonus Card (German)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd ) // use fw1stpal machine for green background
-GAMEL( 1986, bonuscrda, bonuscrd, fw2ndpal, bonuscrd, funworld_state, empty_init, ROT0, "Fun World", "Bonus Card (German, ATG Electronic hack)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd ) // use fw1stpal machine for green background
-GAMEL( 1986, bigdeal, bonuscrd, fw2ndpal, bigdeal, funworld_state, empty_init, ROT0, "Fun World", "Big Deal (Hungarian, set 1)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd )
-GAMEL( 1986, bigdealb, bonuscrd, fw2ndpal, bigdeal, funworld_state, empty_init, ROT0, "Fun World", "Big Deal (Hungarian, set 2)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd )
+GAMEL( 1986, bonuscrd, 0, fw2ndpal, bonuscrd, funworld_state, empty_init, ROT0, "Fun World", "Bonus Card (German)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd ) // use fw1stpal machine for green background
+GAMEL( 1986, bonuscrda, bonuscrd, fw2ndpal, bonuscrd, funworld_state, empty_init, ROT0, "Fun World", "Bonus Card (German, ATG Electronic hack)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd ) // use fw1stpal machine for green background
+GAMEL( 1986, bigdeal, bonuscrd, fw2ndpal, bigdeal, funworld_state, empty_init, ROT0, "Fun World", "Big Deal (Hungarian, set 1)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd )
+GAMEL( 1986, bigdealb, bonuscrd, fw2ndpal, bigdeal, funworld_state, empty_init, ROT0, "Fun World", "Big Deal (Hungarian, set 2)", MACHINE_IMPERFECT_COLORS, layout_bonuscrd )
// CMC Italian jamma PCB's...
-GAMEL( 1996, cuoreuno, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Cuore 1 (Italian)", 0, layout_jollycrd )
-GAMEL( 1997, elephfam, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Elephant Family (Italian, new)", 0, layout_jollycrd )
-GAMEL( 1996, elephfmb, elephfam, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Elephant Family (Italian, old)", 0, layout_jollycrd )
-GAMEL( 1996, pool10, 0, cuoreuno, pool10, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 1)", 0, layout_jollycrd )
-GAMEL( 1996, pool10b, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 2)", 0, layout_jollycrd )
-GAMEL( 1996, pool10c, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 3)", 0, layout_jollycrd )
-GAMEL( 1997, pool10d, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 4)", 0, layout_jollycrd )
-GAMEL( 1997, pool10f, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 5)", 0, layout_jollycrd )
-GAMEL( 1996, pool10g, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 6)", 0, layout_jollycrd )
-GAMEL( 1996, pool10h, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 7)", 0, layout_jollycrd )
-GAMEL( 1997, pool10i, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 8)", 0, layout_jollycrd )
-GAMEL( 1996, pool10j, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "bootleg (R.B.)", "Pool 10 (Italian, set 9)", 0, layout_jollycrd )
-GAMEL( 1998, biliard, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "bootleg", "New Biliard 98 (Pool 10 hack)", 0, layout_jollycrd )
-GAMEL( 2001, royal, pool10, royalcd1, royal, funworld_state, empty_init, ROT0, "<unknown>", "Royal (Pool 10 hack)", 0, layout_jollycrd )
-GAMEL( 1997, tortufam, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Tortuga Family (Italian)", 0, layout_jollycrd )
-GAMEL( 1996, potgame, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pot Game (Italian)", 0, layout_jollycrd )
-GAMEL( 1996, bottle10, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Bottle 10 (Italian, set 1)", 0, layout_jollycrd )
-GAMEL( 1996, bottl10b, bottle10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Bottle 10 (Italian, set 2)", 0, layout_jollycrd )
-GAMEL( 1998, lunapark, 0, lunapark, lunapark, lunapark_state, empty_init, ROT0, "<unknown>", "Luna Park (set 1, dual program)", 0, layout_jollycrd ) // mirrored video RAM (4000/5000 to 6000/7000).
-GAMEL( 1998, lunaparkb, lunapark, lunapark, lunapark, lunapark_state, empty_init, ROT0, "<unknown>", "Luna Park (set 2, dual program)", 0, layout_jollycrd ) // mirrored video RAM (4000/5000 to 6000/7000).
-GAMEL( 1998, lunaparkc, lunapark, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "<unknown>", "Luna Park (set 3)", 0, layout_jollycrd ) // regular video RAM 6000/7000.
-GAMEL( 1998, crystal, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "J.C.D. srl", "Crystal Colours (CMC hardware)", 0, layout_jollycrd )
+GAMEL( 1996, cuoreuno, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Cuore 1 (Italian)", 0, layout_jollycrd )
+GAMEL( 1997, elephfam, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Elephant Family (Italian, new)", 0, layout_jollycrd )
+GAMEL( 1996, elephfmb, elephfam, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Elephant Family (Italian, old)", 0, layout_jollycrd )
+GAMEL( 1996, pool10, 0, cuoreuno, pool10, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 1)", 0, layout_jollycrd )
+GAMEL( 1996, pool10b, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 2)", 0, layout_jollycrd )
+GAMEL( 1996, pool10c, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 3)", 0, layout_jollycrd )
+GAMEL( 1997, pool10d, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 4)", 0, layout_jollycrd )
+GAMEL( 1997, pool10f, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 5)", 0, layout_jollycrd )
+GAMEL( 1996, pool10g, pool10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 6)", 0, layout_jollycrd )
+GAMEL( 1996, pool10h, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 7)", 0, layout_jollycrd )
+GAMEL( 1997, pool10i, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "C.M.C.", "Pool 10 (Italian, set 8)", 0, layout_jollycrd )
+GAMEL( 1996, pool10j, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "bootleg (R.B.)", "Pool 10 (Italian, set 9)", 0, layout_jollycrd )
+GAMEL( 1998, biliard, pool10, cuoreuno, pool10, funworld_state, empty_init, ROT0, "bootleg", "New Biliard 98 (Pool 10 hack)", 0, layout_jollycrd )
+GAMEL( 2001, royal, pool10, royalcd1, royal, funworld_state, empty_init, ROT0, "<unknown>", "Royal (Pool 10 hack)", 0, layout_jollycrd )
+GAMEL( 1997, tortufam, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Tortuga Family (Italian)", 0, layout_jollycrd )
+GAMEL( 1996, potgame, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Pot Game (Italian)", 0, layout_jollycrd )
+GAMEL( 1996, bottle10, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Bottle 10 (Italian, set 1)", 0, layout_jollycrd )
+GAMEL( 1996, bottl10b, bottle10, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "C.M.C.", "Bottle 10 (Italian, set 2)", 0, layout_jollycrd )
+GAMEL( 1998, lunapark, 0, lunapark, lunapark, lunapark_state, empty_init, ROT0, "<unknown>", "Luna Park (set 1, dual program)", 0, layout_jollycrd ) // mirrored video RAM (4000/5000 to 6000/7000).
+GAMEL( 1998, lunaparkb, lunapark, lunapark, lunapark, lunapark_state, empty_init, ROT0, "<unknown>", "Luna Park (set 2, dual program)", 0, layout_jollycrd ) // mirrored video RAM (4000/5000 to 6000/7000).
+GAMEL( 1998, lunaparkc, lunapark, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "<unknown>", "Luna Park (set 3)", 0, layout_jollycrd ) // regular video RAM 6000/7000.
+GAMEL( 1998, crystal, 0, cuoreuno, cuoreuno, funworld_state, empty_init, ROT0, "J.C.D. srl", "Crystal Colours (CMC hardware)", 0, layout_jollycrd )
// Royal Card based...
-GAMEL( 1991, royalcrd, 0, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 1)", 0, layout_jollycrd )
-GAMEL( 1991, royalcrda, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 2)", 0, layout_jollycrd )
-GAMEL( 1991, royalcrdb, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German/Polish, set 3)", 0, layout_jollycrd )
-GAMEL( 1991, royalcrdc, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 4)", 0, layout_jollycrd )
-GAMEL( 1991, royalcrdd, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 5)", 0, layout_royalcrd )
-GAMEL( 1991, royalcrde, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 6)", 0, layout_jollycrd )
-GAMEL( 1991, royalcrdt, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (TAB original)", 0, layout_jollycrd )
-GAMEL( 1990, royalcrdg, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "bootleg", "Royal Card (German, set 7, CMC C1030 HW)", 0, layout_jollycrd ) // big CPLD
-GAMEL( 1991, royalcrdh, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 8)", 0, layout_jollycrd )
-GAMEL( 1991, royalcdfr, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (French)", 0, layout_jollycrd )
-GAME( 1993, royalcrdp, royalcrd, cuoreuno, royalcrd, funworld_state, empty_init, ROT0, "Digital Dreams", "Royal Card v2.0 Professional", 0 )
-GAMEL( 199?, royaljp, royalcrd, royalcd1, royaljp, funworld_state, init_tabblue, ROT0, "TAB / Video Klein","Royal Card / Royal Jackpot (with a third draw)(encrypted)", 0, layout_jollycrd )
-GAMEL( 199?, witchryl, 0, witchryl, witchryl, funworld_state, empty_init, ROT0, "Video Klein", "Witch Royal (Export version 2.1)", 0, layout_jollycrd )
+GAMEL( 1991, royalcrd, 0, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 1)", 0, layout_jollycrd )
+GAMEL( 1991, royalcrda, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 2)", 0, layout_jollycrd )
+GAMEL( 1991, royalcrdb, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German/Polish, set 3)", 0, layout_jollycrd )
+GAMEL( 1991, royalcrdc, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 4)", 0, layout_jollycrd )
+GAMEL( 1991, royalcrdd, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 5)", 0, layout_royalcrd )
+GAMEL( 1991, royalcrde, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 6)", 0, layout_jollycrd )
+GAMEL( 1991, royalcrdt, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (TAB original)", 0, layout_jollycrd )
+GAMEL( 1990, royalcrdg, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "bootleg", "Royal Card (German, set 7, CMC C1030 HW)", 0, layout_jollycrd ) // big CPLD
+GAMEL( 1991, royalcrdh, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (German, set 8)", 0, layout_jollycrd )
+GAMEL( 1991, royalcdfr, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Royal Card (French)", 0, layout_jollycrd )
+GAME( 1993, royalcrdp, royalcrd, cuoreuno, royalcrd, funworld_state, empty_init, ROT0, "Digital Dreams", "Royal Card v2.0 Professional", 0 )
+GAMEL( 199?, royaljp, royalcrd, royalcd1, royaljp, funworld_state, init_tabblue, ROT0, "TAB / Video Klein", "Royal Card / Royal Jackpot (with a third draw)(encrypted)", 0, layout_jollycrd )
+GAMEL( 199?, witchryl, 0, witchryl, witchryl, funworld_state, empty_init, ROT0, "Video Klein", "Witch Royal (Export version 2.1)", 0, layout_jollycrd )
// Lucky Lady based...
-GAMEL( 1991, lluck3x3, royalcrd, cuoreuno, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Lucky Lady (3x3 deal)", 0, layout_jollycrd )
-GAMEL( 1991, lluck4x1, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Lucky Lady (4x1 aces)", 0, layout_jollycrd )
+GAMEL( 1991, lluck3x3, royalcrd, cuoreuno, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Lucky Lady (3x3 deal)", 0, layout_jollycrd )
+GAMEL( 1991, lluck4x1, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Lucky Lady (4x1 aces)", 0, layout_jollycrd )
// Magic Card 2 based...
-GAMEL( 1996, magicrd2, 0, magicrd2, magicrd2, magicrd2_state, empty_init, ROT0, "Impera", "Magic Card II (Bulgarian)", 0, layout_jollycrd )
-GAMEL( 1996, magicrd2a, magicrd2, magicrd2, magicrd2, magicrd2_state, empty_init, ROT0, "Impera", "Magic Card II (Nov, Yugoslavian)", 0, layout_jollycrd )
-GAME( 1996, magicrd2b, magicrd2, magicrd2, magicrd2, magicrd2_state, init_magicd2b, ROT0, "Impera", "Magic Card II (green TAB or Impera board)", 0 )
-GAME( 1996, magicrd2c, magicrd2, magicrd2, magicrd2, magicrd2_state, init_magicd2c, ROT0, "Impera", "Magic Card II (blue TAB board, encrypted)", 0 )
+GAMEL( 1996, magicrd2, 0, magicrd2, magicrd2, magicrd2_state, empty_init, ROT0, "Impera", "Magic Card II (Bulgarian)", 0, layout_jollycrd )
+GAMEL( 1996, magicrd2a, magicrd2, magicrd2, magicrd2, magicrd2_state, empty_init, ROT0, "Impera", "Magic Card II (Nov, Yugoslavian)", 0, layout_jollycrd )
+GAME( 1996, magicrd2b, magicrd2, magicrd2, magicrd2, magicrd2_state, init_magicd2b, ROT0, "Impera", "Magic Card II (green TAB or Impera board)", 0 )
+GAME( 1996, magicrd2c, magicrd2, magicrd2, magicrd2, magicrd2_state, init_magicd2c, ROT0, "Impera", "Magic Card II (blue TAB board, encrypted)", 0 )
// Joker Card based...
-GAMEL( 1993, vegasslw, 0, fw2ndpal, vegasslw, funworld_state, empty_init, ROT0, "Fun World", "Royal Vegas Joker Card (slow deal)", 0, layout_jollycrd )
-GAMEL( 1993, vegasfst, vegasslw, fw2ndpal, vegasfst, funworld_state, empty_init, ROT0, "Soft Design", "Royal Vegas Joker Card (fast deal)", 0, layout_jollycrd )
-GAMEL( 1993, vegasfte, vegasslw, fw2ndpal, vegasfte, funworld_state, empty_init, ROT0, "Soft Design", "Royal Vegas Joker Card (fast deal, English gfx)", 0, layout_jollycrd )
-GAMEL( 1993, vegasmil, vegasslw, fw2ndpal, vegasmil, funworld_state, empty_init, ROT0, "Mile", "Royal Vegas Joker Card (fast deal, Mile)", 0, layout_jollycrd )
+GAMEL( 1993, vegasslw, 0, fw2ndpal, vegasslw, funworld_state, empty_init, ROT0, "Fun World", "Royal Vegas Joker Card (slow deal)", 0, layout_jollycrd )
+GAMEL( 1993, vegasfst, vegasslw, fw2ndpal, vegasfst, funworld_state, empty_init, ROT0, "Soft Design", "Royal Vegas Joker Card (fast deal)", 0, layout_jollycrd )
+GAMEL( 1993, vegasfte, vegasslw, fw2ndpal, vegasfte, funworld_state, empty_init, ROT0, "Soft Design", "Royal Vegas Joker Card (fast deal, English gfx)", 0, layout_jollycrd )
+GAMEL( 1993, vegasmil, vegasslw, fw2ndpal, vegasmil, funworld_state, empty_init, ROT0, "Mile", "Royal Vegas Joker Card (fast deal, Mile)", 0, layout_jollycrd )
// Jolly Joker based...
-GAMEL( 198?, jolyjokr, 0, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (98bet, set 1)", 0, layout_jollycrd )
-GAMEL( 198?, jolyjokra, jolyjokr, fw1stpal, jolyjokra, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (98bet, set 2)", 0, layout_jollycrd )
-GAMEL( 198?, jolyjokrb, jolyjokr, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (40bet, Croatian hack)", 0, layout_jollycrd )
-GAMEL( 198?, jolyjokrc, jolyjokr, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Apple Time", "Jolly Joker (Apple Time)", MACHINE_NOT_WORKING, layout_jollycrd ) // bad program ROM...
-GAMEL( 198?, jolyjokro, jolyjokr, fw2ndpal, funworld, funworld_state, init_impera16, ROT0, "Impera", "Jolly Joker (original program, interleaved GFX, Impera logo)", 0, layout_jollycrd )
-GAMEL( 198?, jolyjokrp, jolyjokr, fw2ndpal, funworld, funworld_state, init_impera16, ROT0, "Impera", "Jolly Joker (original program, interleaved GFX, no logo)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokr, 0, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (98bet, set 1)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokra, jolyjokr, fw1stpal, jolyjokra, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (98bet, set 2)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokrb1, jolyjokr, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (40bet, higher paytable)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokrb2, jolyjokr, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (40bet, lower paytable)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokrc, jolyjokr, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Apple Time", "Jolly Joker (Apple Time)", MACHINE_NOT_WORKING, layout_jollycrd ) // bad program ROM...
+GAMEL( 199?, jolyjokro, jolyjokr, fw2ndpal, funworld, funworld_state, init_impera16, ROT0, "Impera", "Jolly Joker (original program, interleaved GFX, Impera logo)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokrp, jolyjokr, fw2ndpal, funworld, funworld_state, init_impera16, ROT0, "Impera", "Jolly Joker (original program, interleaved GFX, no logo)", 0, layout_jollycrd )
+GAMEL( 199?, jolyjokrm, jolyjokr, fw1stpal, funworld, funworld_state, empty_init, ROT0, "Impera", "Jolly Joker (Solid State module in suicide board)", 0, layout_jollycrd )
// Encrypted games...
-GAME( 1992, multiwin, 0, multiwin, funworld, multiwin_state, driver_init, ROT0, "Fun World", "Multi Win (Ver.0167, encrypted)", 0 )
-GAME( 1993, powercrd, 0, powercrd, funworld, powercrd_state, empty_init, ROT0, "Fun World", "Power Card (Ver 0263, encrypted)", 0 ) // clone of Bonus Card.
-GAME( 1993, megacard, 0, megacard, funworld, megacard_state, empty_init, ROT0, "Fun World", "Mega Card (Ver.0210, encrypted)", 0 )
-GAME( 1993, jokercrd, 0, jokercrd, funworld, jokercrd_state, empty_init, ROT0, "Amatic Trading", "Joker Card 300 (Ver.A267BC, encrypted)", 0 )
-GAME( 1991, royalcrdf, royalcrd, royalcrdf,royalcrdf, royalcrdf_state,driver_init, ROT0, "Evona Electronic","Royal Card (Evona, Polish, encrypted)", 0 )
-GAME( 198?, saloon, 0, saloon, saloon, funworld_state, init_saloon, ROT0, "<unknown>", "Saloon (French, encrypted)", 0 )
-GAME( 198?, nevadafw, 0, saloon, saloon, funworld_state, init_saloon, ROT0, "<unknown>", "Nevada (French, encrypted)", 0 )
+GAME( 1992, multiwin, 0, multiwin, funworld, multiwin_state, driver_init, ROT0, "Fun World", "Multi Win (Ver.0167, encrypted)", 0 )
+GAME( 1993, powercrd, 0, powercrd, funworld, powercrd_state, empty_init, ROT0, "Fun World", "Power Card (Ver 0263, encrypted)", 0 ) // clone of Bonus Card.
+GAME( 1993, megacard, 0, megacard, funworld, megacard_state, empty_init, ROT0, "Fun World", "Mega Card (Ver.0210, encrypted)", 0 )
+GAME( 1993, jokercrd, 0, jokercrd, funworld, jokercrd_state, empty_init, ROT0, "Amatic Trading", "Joker Card 300 (Ver.A267BC, encrypted)", 0 )
+GAME( 1991, royalcrdf, royalcrd, royalcrdf,royalcrdf, royalcrdf_state,driver_init, ROT0, "Evona Electronic", "Royal Card (Evona, Polish, encrypted)", 0 )
+GAME( 198?, saloon, 0, saloon, saloon, funworld_state, init_saloon, ROT0, "<unknown>", "Saloon (French, encrypted)", 0 )
+GAME( 198?, nevadafw, 0, saloon, saloon, funworld_state, init_saloon, ROT0, "<unknown>", "Nevada (French, encrypted)", 0 )
// Encrypted TAB blue PCB...
-GAMEL( 199?, jolycdit, jollycrd, cuoreuno, jolycdit, funworld_state, init_tabblue, ROT0, "bootleg", "Jolly Card (Italian, blue TAB board, encrypted)", 0, layout_royalcrd )
-GAMEL( 1990, jolycdib, jollycrd, cuoreuno, jolycdib, funworld_state, init_tabblue, ROT0, "bootleg", "Jolly Card (Italian, encrypted bootleg, set 1)", 0, layout_jollycrd ) // not a real TAB blue PCB
-GAMEL( 1993, jolycdic, jollycrd, cuoreuno, jolycdic, funworld_state, init_tabblue, ROT0, "bootleg", "Jolly Card (Italian, encrypted bootleg, set 2)", 0, layout_jollycrd ) // not a real TAB blue PCB
+GAMEL( 199?, jolycdit, jollycrd, cuoreuno, jolycdit, funworld_state, init_tabblue, ROT0, "bootleg", "Jolly Card (Italian, blue TAB board, encrypted)", 0, layout_royalcrd )
+GAMEL( 1990, jolycdib, jollycrd, cuoreuno, jolycdib, funworld_state, init_tabblue, ROT0, "bootleg", "Jolly Card (Italian, encrypted bootleg, set 1)", 0, layout_jollycrd ) // not a real TAB blue PCB
+GAMEL( 1993, jolycdic, jollycrd, cuoreuno, jolycdic, funworld_state, init_tabblue, ROT0, "bootleg", "Jolly Card (Italian, encrypted bootleg, set 2)", 0, layout_jollycrd ) // not a real TAB blue PCB
+GAMEL( 1993, jolycdii, jollycrd, cuoreuno, jolycdib, funworld_state, init_tabblue, ROT0, "bootleg (Cleco)", "Jolly Card (Italian, encrypted bootleg, set 3)", 0, layout_jollycrd ) // Cleco bootleg PCB
// Dino 4 encrypted hardware...
-GAMEL( 1997, pool10e, pool10, cuoreuno, cuoreuno, funworld_state, init_dino4, ROT0, "C.M.C.", "Pool 10 (Italian, Dino 4 hardware, encrypted)", 0, layout_jollycrd )
-GAME( 1998, rcdino4, 0, rcdino4, rcdino4, chinatow_state, init_rcdino4, ROT0, "<unknown>", "Royal Card (Italian, Dino 4 hardware, encrypted)",0 )
-GAMEL( 1998, chinatow, 0, chinatow, chinatow, chinatow_state, init_rcdinch, ROT0, "<unknown>", "China Town (Ver 1B, Dino4 HW)", 0, layout_jollycrd )
+GAMEL( 1997, pool10e, pool10, cuoreuno, cuoreuno, funworld_state, init_dino4, ROT0, "C.M.C.", "Pool 10 (Italian, Dino 4 hardware, encrypted)", 0, layout_jollycrd )
+GAME( 1998, rcdino4, 0, rcdino4, rcdino4, chinatow_state, init_rcdino4, ROT0, "<unknown>", "Royal Card (Italian, Dino 4 hardware, encrypted)",0 )
+GAMEL( 1998, chinatow, 0, chinatow, chinatow, chinatow_state, init_rcdinch, ROT0, "<unknown>", "China Town (Ver 1B, Dino4 HW)", 0, layout_jollycrd )
// MCU based games...
-GAME( 199?, mongolnw, 0, royalcd1, royalcrd, funworld_state, init_mongolnw, ROT0, "<unknown>", "Mongolfier New (Italian)", MACHINE_UNEMULATED_PROTECTION )
-GAME( 199?, soccernw, 0, royalcd1, royalcrd, funworld_state, init_soccernw, ROT0, "<unknown>", "Soccer New (Italian)", MACHINE_UNEMULATED_PROTECTION )
+GAME( 199?, mongolnw, 0, royalcd1, royalcrd, funworld_state, init_mongolnw, ROT0, "<unknown>", "Mongolfier New (Italian)", MACHINE_UNEMULATED_PROTECTION )
+GAME( 199?, soccernw, 0, royalcd1, royalcrd, funworld_state, init_soccernw, ROT0, "<unknown>", "Soccer New (Italian)", MACHINE_UNEMULATED_PROTECTION )
// Quiz games...
-GAME( 199?, funquiz, 0, funquiz, funquiz, funworld_state, empty_init, ROT0, "Fun World", "Fun World Quiz (German)", 0 )
-GAME( 1990, funquiza, 0, funquiz, funquiza, funworld_state, empty_init, ROT0, "Fun World", "Fun World Quiz (German, 12-11-1990)", 0 )
-GAME( 1990, funquizb, 0, funquiz, funquiza, funworld_state, empty_init, ROT0, "Fun World", "Fun World Quiz (German, 27-04-1990)", 0 )
+GAME( 199?, funquiz, 0, funquiz, funquiz, funworld_state, empty_init, ROT0, "Fun World", "Fun World Quiz (German)", 0 )
+GAME( 1990, funquiza, 0, funquiz, funquiza, funworld_state, empty_init, ROT0, "Fun World", "Fun World Quiz (German, 12-11-1990)", 0 )
+GAME( 1990, funquizb, 0, funquiz, funquiza, funworld_state, empty_init, ROT0, "Fun World", "Fun World Quiz (German, 27-04-1990)", 0 )
// Other games...
-GAMEL( 1986, novoplay, 0, fw2ndpal, novoplay, funworld_state, empty_init, ROT0, "Admiral/Novomatic","Novo Play Multi Card / Club Card", 0, layout_novoplay )
-GAME( 1991, intrgmes, 0, intrgmes, intrgmes, intergames_state, empty_init, ROT0, "Inter Games", "Joker Card (Inter Games)", 0 )
-GAMEL( 1985, fw_a7_11, 0, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "unknown Fun World A7-11 game 1", MACHINE_NOT_WORKING, layout_jollycrd )
-GAMEL( 1985, fw_a7_11a, fw_a7_11, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "unknown Fun World A7-11 game 2", MACHINE_NOT_WORKING, layout_jollycrd )
-GAMEL( 1991, fw_a0_1, 0, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "unknown Fun World A0-1 game", MACHINE_NOT_WORKING, layout_jollycrd )
-GAMEL( 1991, jokcrdep, 0, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "Joker Card / Multi Card (Epoxy brick CPU)", MACHINE_NOT_WORKING, layout_jollycrd )
+GAMEL( 1986, novoplay, 0, fw2ndpal, novoplay, funworld_state, empty_init, ROT0, "Admiral/Novomatic", "Novo Play Multi Card / Club Card", 0, layout_novoplay )
+GAME( 1991, intrgmes, 0, intrgmes, intrgmes, intergames_state, empty_init, ROT0, "Inter Games", "Joker Card (Inter Games)", 0 )
+GAMEL( 1985, fw_a7_11, 0, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "unknown Fun World A7-11 game 1", MACHINE_NOT_WORKING, layout_jollycrd )
+GAMEL( 1985, fw_a7_11a, fw_a7_11, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "unknown Fun World A7-11 game 2", MACHINE_NOT_WORKING, layout_jollycrd )
+GAMEL( 1991, fw_a0_1, 0, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "unknown Fun World A0-1 game", MACHINE_NOT_WORKING, layout_jollycrd )
+GAMEL( 1991, jokcrdep, 0, fw_brick_2, fw_brick1, funworld_state, empty_init, ROT0, "Fun World", "Joker Card / Multi Card (Epoxy brick CPU)", MACHINE_NOT_WORKING, layout_jollycrd )
+GAMEL( 199?, gratispk, 0, gratispk, funworld, funworld_state, empty_init, ROT0, "Mega Soft", "Gratis Poker (V.204, Set 1)", 0, layout_jollycrd )
+GAMEL( 199?, gratispka, gratispk, gratispk, funworld, funworld_state, empty_init, ROT0, "Mega Soft", "Gratis Poker (V.204, Set 2)", 0, layout_jollycrd )
+GAMEL( 1995, nkoulit, royalcrd, royalcd1, royalcrd, funworld_state, init_tabblue, ROT0, "JK Amusement", "Nkoulit (Gullit) (encrypted GFX)", 0, layout_jollycrd )
+GAMEL( 1999, reflexcrd, royalcrd, royalcd1, royalcrd, funworld_state, empty_init, ROT0, "TAB Austria", "Reflex Cards (English, serial protected)", 0, layout_jollycrd )
// These are 2-in-1 stealth boards, they can run the Poker game, or, using completely separate hardware on the same PCB, a NES / MSX Multigames!
GAMEL( 1991, royalcrd_nes, royalcrd, royalcd2, royalcrd, funworld_state, empty_init, ROT0, "bootleg", "Royal Card (stealth with NES multigame)", MACHINE_NOT_WORKING, layout_jollycrd )
diff --git a/src/mame/drivers/gaelcof3.cpp b/src/mame/drivers/gaelcof3.cpp
index 0e8c3668b82..91c1eb15bd3 100644
--- a/src/mame/drivers/gaelcof3.cpp
+++ b/src/mame/drivers/gaelcof3.cpp
@@ -9,15 +9,34 @@
OKI M6295 for sound
1 bank of 6 dips
+ Gaelco FUTBOL-3 PCB
+ _____________________________________________________
+ |JP1 JP2 __________ |
+ | __ ___ |ULN2803A_| |
+ || | | | ___________ |
+ || | | | |MC74HCT273A |
+ ||_| | | _________ _________ |
+ |JP3 | | |TLP504A_| |TLP504A_| |
+ | __ | | __________ |
+ || | | | |PIC16C55| |
+ ||_| | | |
+ | ___ |__| ___ <-SN74LS365AN |
+ | VOL | | ______ ___________________ |
+ | _______ | | | OKI | |ROM U1 | |
+ | |DIPSx6| | | |_____| |___________________| |
+ | |__| |
+ |___________________________________________________|
+
+ JP1 = 10 pin [+5V, GND, DAT, CLK, ENA, PU1, PU2, PU3, PU4, GND]
+ JP2 = 14 pin [12VA, 12VA, +5V, ALT, CON, BOM, MOT, N/U, BOM, POT, ALT, 12V, GND, GND]
+ JP3 = 5 pin [PU5, PU6, PU7, PU8, GND]
The PCBs were inside two "Coche de Bomberos" kiddie rides from CMC Cresmatic (https://www.recreativas.org/coche-de-bomberos-6022-cresmatic).
Anyway, the hardware is generic enough to serve any basic kiddie ride.
- The only dumpable ROM on the PCB is the Oki sound samples. There are two different versions dumped (from two different machines):
-
- "Susanita tiene un ratón" - Based on the song composed by Emilio Alberto Aragón 'Miliki'.
-
- "El auto de papá" - Based on the song composed by Enrique Fischer 'Pipo Pescador'.
+ The only dumped ROM on the PCB is the Oki sound samples. There are two different versions dumped (from two different machines):
+ -"Susanita tiene un ratón" - Based on the song composed by Emilio Alberto Aragón 'Miliki'.
+ -"El auto de papá" - Based on the song composed by Enrique Fischer 'Pipo Pescador'.
*/
#include "emu.h"
diff --git a/src/mame/drivers/gaiden.cpp b/src/mame/drivers/gaiden.cpp
index c9f6e46f197..92e99b89ea9 100644
--- a/src/mame/drivers/gaiden.cpp
+++ b/src/mame/drivers/gaiden.cpp
@@ -1048,30 +1048,26 @@ ROM_START( shadoww )
ROM_LOAD( "gaiden_5.7a", 0x000000, 0x10000, CRC(8d4035f7) SHA1(3473456cdd24e312e3073586d7e8f24eb71bbea1) ) /* 8x8 tiles */
ROM_REGION( 0x080000, "gfx2", 0 )
- ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
- ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
- ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
- ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
+ ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
+ ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
+ ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
+ ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
ROM_REGION( 0x080000, "gfx3", 0 )
- ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
- ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
- ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
- ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
-
- ROM_REGION( 0x100000, "gfx4", 0 )
- /* Should all these roms be 0x10000 bytes on this board? */
- ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
- ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
- ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
- ROM_LOAD16_BYTE( "shadoww_12a.xx", 0x0c0000, 0x10000, CRC(9bb07731) SHA1(b799b1958dc9b84797fdab2591e33bd5d28884a3) ) /* sprites D1 */
- ROM_LOAD16_BYTE( "shadoww_12b.xx", 0x0e0000, 0x10000, CRC(a4a950a2) SHA1(9766b5e88edd16554e59179a37cca49d29f83367) ) /* sprites D1 */
-
- ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
- ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
- ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
- ROM_LOAD16_BYTE( "shadoww_13a.xx", 0x0c0001, 0x10000, CRC(996d2fa5) SHA1(a32526949af3635914927ebbbe684c3de9562a9d) ) /* sprites D2 */
- ROM_LOAD16_BYTE( "shadoww_13b.xx", 0x0e0001, 0x10000, CRC(b8df8a34) SHA1(6810f7961052a983b8c78b42d550038051012c6d) ) /* sprites D2 */
+ ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
+ ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
+ ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
+ ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
+
+ ROM_REGION( 0x100000, "gfx4", 0 ) // sprite roms also seen on daughterboard "4M512" with 16 0x10000-sized roms
+ ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
+ ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
+ ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
+ ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
+ ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
+ ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
+ ROM_LOAD16_BYTE( "12.3s", 0x0c0000, 0x20000, CRC(94a836d8) SHA1(55658f4c6cf6aadc4369b943705f5734396b2e43) ) /* sprites D1 */
+ ROM_LOAD16_BYTE( "13.1s", 0x0c0001, 0x20000, CRC(e9caea3b) SHA1(39ef300e7dfd9469f04127d5a06dceb0b7e357f8) ) /* sprites D2 */
ROM_REGION( 0x40000, "oki", 0 ) /* 128k for ADPCM samples - sound chip is OKIM6295 */
ROM_LOAD( "4.4a", 0x0000, 0x20000, CRC(b0e0faf9) SHA1(2275d2ef5eee356ccf80b9e9644d16fc30a4d107) ) /* samples */
@@ -1089,30 +1085,26 @@ ROM_START( shadowwa )
ROM_LOAD( "gaiden_5.7a", 0x000000, 0x10000, CRC(8d4035f7) SHA1(3473456cdd24e312e3073586d7e8f24eb71bbea1) ) /* 8x8 tiles */
ROM_REGION( 0x080000, "gfx2", 0 )
- ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
- ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
- ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
- ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
+ ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
+ ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
+ ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
+ ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
ROM_REGION( 0x080000, "gfx3", 0 )
- ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
- ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
- ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
- ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
-
- ROM_REGION( 0x100000, "gfx4", 0 )
- /* Should all these roms be 0x10000 bytes on this board? */
- ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
- ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
- ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
- ROM_LOAD16_BYTE( "shadoww_12a.xx", 0x0c0000, 0x10000, CRC(9bb07731) SHA1(b799b1958dc9b84797fdab2591e33bd5d28884a3) ) /* sprites D1 */
- ROM_LOAD16_BYTE( "shadoww_12b.xx", 0x0e0000, 0x10000, CRC(a4a950a2) SHA1(9766b5e88edd16554e59179a37cca49d29f83367) ) /* sprites D1 */
-
- ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
- ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
- ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
- ROM_LOAD16_BYTE( "shadoww_13a.xx", 0x0c0001, 0x10000, CRC(996d2fa5) SHA1(a32526949af3635914927ebbbe684c3de9562a9d) ) /* sprites D2 */
- ROM_LOAD16_BYTE( "shadoww_13b.xx", 0x0e0001, 0x10000, CRC(b8df8a34) SHA1(6810f7961052a983b8c78b42d550038051012c6d) ) /* sprites D2 */
+ ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
+ ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
+ ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
+ ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
+
+ ROM_REGION( 0x100000, "gfx4", 0 ) // sprite roms also seen on daughterboard "4M512" with 16 0x10000-sized roms
+ ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
+ ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
+ ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
+ ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
+ ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
+ ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
+ ROM_LOAD16_BYTE( "12.3s", 0x0c0000, 0x20000, CRC(94a836d8) SHA1(55658f4c6cf6aadc4369b943705f5734396b2e43) ) /* sprites D1 */
+ ROM_LOAD16_BYTE( "13.1s", 0x0c0001, 0x20000, CRC(e9caea3b) SHA1(39ef300e7dfd9469f04127d5a06dceb0b7e357f8) ) /* sprites D2 */
ROM_REGION( 0x40000, "oki", 0 ) /* 128k for ADPCM samples - sound chip is OKIM6295 */
ROM_LOAD( "4.4a", 0x0000, 0x20000, CRC(b0e0faf9) SHA1(2275d2ef5eee356ccf80b9e9644d16fc30a4d107) ) /* samples */
@@ -1130,27 +1122,26 @@ ROM_START( gaiden )
ROM_LOAD( "gaiden_5.7a", 0x000000, 0x10000, CRC(8d4035f7) SHA1(3473456cdd24e312e3073586d7e8f24eb71bbea1) ) /* 8x8 tiles */
ROM_REGION( 0x080000, "gfx2", 0 )
- ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
- ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
- ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
- ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
+ ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
+ ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
+ ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
+ ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
ROM_REGION( 0x080000, "gfx3", 0 )
- ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
- ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
- ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
- ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
-
- ROM_REGION( 0x100000, "gfx4", 0 )
- ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
- ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
- ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
- ROM_LOAD16_BYTE( "gaiden_12.3s", 0x0c0000, 0x20000, CRC(90f1e13a) SHA1(3fe9fe62aa9e92c871c791a3b11f96c9a48099a9) ) /* sprites D1 */
-
- ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
- ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
- ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
- ROM_LOAD16_BYTE( "gaiden_13.1s", 0x0c0001, 0x20000, CRC(7d9f5c5e) SHA1(200102532ea9a88c7c708e03f8893c46dff827d1) ) /* sprites D2 */
+ ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
+ ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
+ ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
+ ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
+
+ ROM_REGION( 0x100000, "gfx4", 0 ) // sprite roms also seen on daughterboard "4M512" with 16 0x10000-sized roms
+ ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
+ ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
+ ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
+ ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
+ ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
+ ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
+ ROM_LOAD16_BYTE( "12.3s", 0x0c0000, 0x20000, CRC(90f1e13a) SHA1(3fe9fe62aa9e92c871c791a3b11f96c9a48099a9) ) /* sprites D1 */
+ ROM_LOAD16_BYTE( "13.1s", 0x0c0001, 0x20000, CRC(7d9f5c5e) SHA1(200102532ea9a88c7c708e03f8893c46dff827d1) ) /* sprites D2 */
ROM_REGION( 0x40000, "oki", 0 ) /* 128k for ADPCM samples - sound chip is OKIM6295 */
ROM_LOAD( "4.4a", 0x0000, 0x20000, CRC(b0e0faf9) SHA1(2275d2ef5eee356ccf80b9e9644d16fc30a4d107) ) /* samples */
@@ -1168,30 +1159,26 @@ ROM_START( ryukendn )
ROM_LOAD( "hn27512p.7a", 0x000000, 0x10000, CRC(765e7baa) SHA1(4d0a50f091b284739b6d9a8ceb4f81999da445fc) ) /* 8x8 tiles */
ROM_REGION( 0x080000, "gfx2", 0 )
- ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
- ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
- ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
- ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
+ ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
+ ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
+ ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
+ ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
ROM_REGION( 0x080000, "gfx3", 0 )
- ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
- ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
- ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
- ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
-
- ROM_REGION( 0x100000, "gfx4", 0 )
- /* Should all these roms be 0x10000 bytes on this board? */
- ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
- ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
- ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
- ROM_LOAD16_BYTE( "shadoww_12a.xx", 0x0c0000, 0x10000, CRC(9bb07731) SHA1(b799b1958dc9b84797fdab2591e33bd5d28884a3) ) /* sprites D1 */
- ROM_LOAD16_BYTE( "ryukendn_12b.xx", 0x0e0000, 0x10000, CRC(1773628a) SHA1(e7eacc880f2a4174f17b263bedf8c1bc64007dbd) ) /* sprites D1 */
-
- ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
- ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
- ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
- ROM_LOAD16_BYTE( "shadoww_13a.xx", 0x0c0001, 0x10000, CRC(996d2fa5) SHA1(a32526949af3635914927ebbbe684c3de9562a9d) ) /* sprites D2 */
- ROM_LOAD16_BYTE( "ryukendn_13b.xx", 0x0e0001, 0x10000, CRC(1f43c507) SHA1(29f655442c16677855073284c7ab41059c99c497) ) /* sprites D2 */
+ ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
+ ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
+ ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
+ ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
+
+ ROM_REGION( 0x100000, "gfx4", 0 ) // sprite roms also seen on daughterboard "4M512" with 16 0x10000-sized roms
+ ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
+ ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
+ ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
+ ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
+ ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
+ ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
+ ROM_LOAD16_BYTE( "12.3s", 0x0c0000, 0x20000, CRC(277204f0) SHA1(918e05f10959f2b50c16b6e0dc62e3076c99250e) ) /* sprites D1 */
+ ROM_LOAD16_BYTE( "13.1s", 0x0c0001, 0x20000, CRC(4e56a508) SHA1(f89a6037e602b26d6ce11859e0b43a602b50d985) ) /* sprites D2 */
ROM_REGION( 0x40000, "oki", 0 ) /* 128k for ADPCM samples - sound chip is OKIM6295 */
ROM_LOAD( "4.4a", 0x0000, 0x20000, CRC(b0e0faf9) SHA1(2275d2ef5eee356ccf80b9e9644d16fc30a4d107) ) /* samples */
@@ -1219,27 +1206,26 @@ ROM_START( ryukendna )
ROM_LOAD( "hn27512p.7a", 0x000000, 0x10000, CRC(765e7baa) SHA1(4d0a50f091b284739b6d9a8ceb4f81999da445fc) ) /* 8x8 tiles */
ROM_REGION( 0x080000, "gfx2", 0 )
- ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
- ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
- ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
- ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
+ ROM_LOAD( "14.3a", 0x000000, 0x20000, CRC(1ecfddaa) SHA1(e71d60ae1a98fe8512498f91cce01c16be9f0871) )
+ ROM_LOAD( "15.3b", 0x020000, 0x20000, CRC(1291a696) SHA1(023b05260214adc39bdba81d5e2aa246b6d74a6a) )
+ ROM_LOAD( "16.1a", 0x040000, 0x20000, CRC(140b47ca) SHA1(6ffd9b7116658a46a124f9085602d88aa143d829) )
+ ROM_LOAD( "17.1b", 0x060000, 0x20000, CRC(7638cccb) SHA1(780d47d3aa248346e0e7abc6e6284542e7392919) )
ROM_REGION( 0x080000, "gfx3", 0 )
- ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
- ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
- ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
- ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
-
- ROM_REGION( 0x100000, "gfx4", 0 )
- ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
- ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
- ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
- ROM_LOAD16_BYTE( "12.3s", 0x0c0000, 0x20000, CRC(277204f0) SHA1(918e05f10959f2b50c16b6e0dc62e3076c99250e) ) /* sprites D1 */
-
- ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
- ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
- ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
- ROM_LOAD16_BYTE( "13.1s", 0x0c0001, 0x20000, CRC(4e56a508) SHA1(f89a6037e602b26d6ce11859e0b43a602b50d985) ) /* sprites D2 */
+ ROM_LOAD( "18.6a", 0x000000, 0x20000, CRC(3fadafd6) SHA1(0cb5387a354c631d5c6aca8f77ecbbc0d175a574) )
+ ROM_LOAD( "19.6b", 0x020000, 0x20000, CRC(ddae9d5b) SHA1(108b202ae7ae124a32400a0a404c7d2b614c60bd) )
+ ROM_LOAD( "20.4b", 0x040000, 0x20000, CRC(08cf7a93) SHA1(fd3278c3fb3ef30ed03c8a95656d86ba82a163d8) )
+ ROM_LOAD( "21.4b", 0x060000, 0x20000, CRC(1ac892f5) SHA1(28364266ca9d1955fb7953f5c2d6f35e114beec6) )
+
+ ROM_REGION( 0x100000, "gfx4", 0 ) // sprite roms also seen on daughterboard "4M512" with 16 0x10000-sized roms
+ ROM_LOAD16_BYTE( "6.3m", 0x000000, 0x20000, CRC(e7ccdf9f) SHA1(80ffcefc95660471124898a9c2bee55df36bda13) ) /* sprites A1 */
+ ROM_LOAD16_BYTE( "7.1m", 0x000001, 0x20000, CRC(016bec95) SHA1(6a6757c52ca9a2398ea43d1af4a8d5adde6f4cd2) ) /* sprites A2 */
+ ROM_LOAD16_BYTE( "8.3n", 0x040000, 0x20000, CRC(7ef7f880) SHA1(26ba9a76adce24beea3cffa1cb95aeafe6f82f96) ) /* sprites B1 */
+ ROM_LOAD16_BYTE( "9.1n", 0x040001, 0x20000, CRC(6e9b7fd3) SHA1(c86ff61844fc94c02625bb812b9062d0649c8fdf) ) /* sprites B2 */
+ ROM_LOAD16_BYTE( "10.3r", 0x080000, 0x20000, CRC(a6451dec) SHA1(553e7a1453b59055fa0b10ca04125543d9f8987c) ) /* sprites C1 */
+ ROM_LOAD16_BYTE( "11.1r", 0x080001, 0x20000, CRC(7fbfdf5e) SHA1(ab67b72dcadb5f2236d29de751de5bf890a9e423) ) /* sprites C2 */
+ ROM_LOAD16_BYTE( "12.3s", 0x0c0000, 0x20000, CRC(277204f0) SHA1(918e05f10959f2b50c16b6e0dc62e3076c99250e) ) /* sprites D1 */
+ ROM_LOAD16_BYTE( "13.1s", 0x0c0001, 0x20000, CRC(4e56a508) SHA1(f89a6037e602b26d6ce11859e0b43a602b50d985) ) /* sprites D2 */
ROM_REGION( 0x40000, "oki", 0 ) /* 128k for ADPCM samples - sound chip is OKIM6295 */
ROM_LOAD( "4.4a", 0x0000, 0x20000, CRC(b0e0faf9) SHA1(2275d2ef5eee356ccf80b9e9644d16fc30a4d107) ) /* samples */
diff --git a/src/mame/drivers/generalplus_gpl16250_rom.cpp b/src/mame/drivers/generalplus_gpl16250_rom.cpp
index 0350f37dcbd..0f6a192e7e9 100644
--- a/src/mame/drivers/generalplus_gpl16250_rom.cpp
+++ b/src/mame/drivers/generalplus_gpl16250_rom.cpp
@@ -400,6 +400,14 @@ ROM_START( tkmag220 )
ROM_END
+ROM_START( imgame )
+ //ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) // not on this model? (or at least not this size, as CS base is different)
+ //ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP )
+
+ ROM_REGION( 0x8000000, "maincpu", ROMREGION_ERASE00 ) // the 2nd half of this ROM required multiple attempts to get a matching dump, so could be suspect, might also be unused as this only has 120 games
+ ROM_LOAD16_WORD_SWAP( "imgame.bin", 0x0000000, 0x8000000, CRC(6fba9021) SHA1(852f4c0aaed682aa8ff5b8cd52313ea2d3d920a1))
+ROM_END
+
ROM_START( myac220 )
//ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) // not on this model? (or at least not this size, as CS base is different)
//ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP )
@@ -474,6 +482,10 @@ CONS(201?, tkmag220, 0, 0, tkmag220, tkmag220, tkmag220_game_state, empt
// DGUN-2891 or DGUN-2864 ? both look the same, no indication on unboxed unit?
CONS(201?, myac220, 0, 0, tkmag220, tkmag220, tkmag220_game_state, empty_init, "dreamGEAR", "My Arcade Go Gamer Portable (Family Sport 220-in-1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS )
+// 2012 date from manual
+CONS(2012, imgame, 0, 0, tkmag220, tkmag220, tkmag220_game_state, empty_init, "I'm Game", "I'm Game! GP120 (Family Sport 120-in-1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS )
+// a 180 game Family Sport I'm Game! also exists (and some Famiclones)
+
// die on this one is 'GCM420'
CONS(2013, gormiti, 0, 0, base, gormiti, gormiti_game_state, empty_init, "Giochi Preziosi", "Gormiti Game Arena (Spain)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND)
diff --git a/src/mame/drivers/gigatron.cpp b/src/mame/drivers/gigatron.cpp
index 7f929ace430..f709b1980ac 100644
--- a/src/mame/drivers/gigatron.cpp
+++ b/src/mame/drivers/gigatron.cpp
@@ -1,15 +1,14 @@
-// license:BSD-3-Clause
+// license:BSD-2-Clause
// copyright-holders:Sterophonick, Phil Thomas
/***************************************************************************
- Skeleton driver for Gigatron TTL Microcomputer
- Driver by Sterophonick
+ Driver for Gigatron TTL Microcomputer by Sterophonick
+
+ Based on Gigatron.js by Phil Thomas
+ https://github.com/PhilThomas/gigatron
***************************************************************************/
-//There is a pre-existing emulator here https://github.com/PhilThomas/gigatron
-//It's just a matter of translating it to MAME.
-
#include "emu.h"
#include "cpu/gigatron/gigatron.h"
#include "screen.h"
@@ -17,10 +16,22 @@
#include "sound/volt_reg.h"
#include "speaker.h"
+#include "gigatron.lh"
+
#define MAIN_CLOCK 6250000
#define VSYNC 0x80
#define HSYNC 0x40
+/***************************************************************************
+
+ TODO
+
+ Hook up a quikload for loading .gt1 files
+ HLE the keyboard and Pluggy McPlugface
+
+***************************************************************************/
+
+
//**************************************************************************
// Driver Definition
//**************************************************************************
@@ -32,13 +43,17 @@ public:
: driver_device(mconfig, type, tag)
, m_maincpu(*this, "maincpu")
, m_dac(*this, "dac")
+ , m_screen(*this, "screen")
, m_io_inputs(*this, "GAMEPAD")
+ , m_blinken1(*this, "blinken1")
+ , m_blinken2(*this, "blinken2")
+ , m_blinken3(*this, "blinken3")
+ , m_blinken4(*this, "blinken4")
{
}
void gigatron(machine_config &config);
-
private:
uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
@@ -46,29 +61,35 @@ private:
virtual void machine_start() override;
virtual void machine_reset() override;
virtual void video_start() override;
+ virtual void video_reset() override;
void prog_map(address_map &map);
void data_map(address_map &map);
- uint16_t m_lc; //Lights Changed
+ uint8_t m_lights; //blinkenlights
//Video Generation stuff
uint8_t m_out;
- uint8_t m_row;
- uint8_t m_col;
+ int16_t m_row;
+ int16_t m_col;
uint8_t m_pixel;
+
+ uint8_t m_dacoutput;
- void blinkenlights(uint8_t data);
- void video_draw(u8 data);
- uint8_t inputs();
void port_outx(uint8_t data);
-
- std::unique_ptr<bitmap_ind16> m_bitmap_render;
- std::unique_ptr<bitmap_ind16> m_bitmap_buffer;
+ void port_out(uint8_t data);
+
+ std::unique_ptr<bitmap_rgb32> m_bitmap_render;
required_device<gigatron_cpu_device> m_maincpu;
required_device<dac_byte_interface> m_dac;
+ required_device<screen_device> m_screen;
required_ioport m_io_inputs;
+
+ output_finder<> m_blinken1;
+ output_finder<> m_blinken2;
+ output_finder<> m_blinken3;
+ output_finder<> m_blinken4;
};
//**************************************************************************
@@ -77,47 +98,64 @@ private:
void gigatron_state::video_start()
{
- m_bitmap_render = std::make_unique<bitmap_ind16>(640, 480);
- m_bitmap_buffer = std::make_unique<bitmap_ind16>(640, 480);
+ m_bitmap_render = std::make_unique<bitmap_rgb32>(640, 480);
}
-void gigatron_state::video_draw(u8 data)
+void gigatron_state::video_reset()
{
- uint8_t out = data;
- uint8_t falling = m_out & ~out;
-
- if (falling & VSYNC)
- {
- m_row = 0;
- m_pixel = 0;
- }
-
- if (falling & HSYNC)
- {
- m_col = 0;
- m_row++;
- }
-
- m_out = out;
-
- if ((out & (VSYNC | HSYNC)) != (VSYNC | HSYNC))
- {
- return;
- }
+ uint32_t *dest = &m_bitmap_render->pix32(0, 0);
+ for(uint32_t i = 0; i < 640*480; i++)
+ *dest++ = 0;
+}
- if((m_row >= 0 && m_row < 480) && (m_col >= 0 && m_col < 640))
- {
- //uint16_t *dest;
- //uint8_t tPixel = pixel;
- //uint8_t r = (out << 6) & 0xC0;
- //uint8_t g = (out << 4) & 0xC0;
- //uint8_t b = (out << 2) & 0xC0;
- }
+void gigatron_state::port_out(uint8_t data)
+{
+ m_pixel = data;
+ uint8_t out = m_pixel;
+ uint8_t falling = m_out & ~out;
+
+ if (falling & VSYNC)
+ {
+ m_row = -36;
+ m_pixel = 0;
+ }
+
+ if (falling & HSYNC)
+ {
+ m_col = -4;
+ m_row++;
+ }
+
+ m_out = out;
+
+ if ((out & (VSYNC | HSYNC)) != (VSYNC | HSYNC))
+ {
+ return;
+ }
+
+ if((m_row >= 0 && m_row < 480) && (m_col >= 0 && m_col < 640))
+ {
+ uint8_t r = (out << 6) & 0xC0;
+ uint8_t g = (out << 4) & 0xC0;
+ uint8_t b = (out << 2) & 0xC0;
+ uint32_t *dest = &m_bitmap_render->pix32(m_row, m_col);
+ for(uint8_t i = 0; i < 4; i++)
+ *dest++ = b|(g<<8)|(r<<16);
+ }
+ m_col += 4;
}
+//6-bit color, VGA
uint32_t gigatron_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
{
- return 0;
+ copybitmap(bitmap, *m_bitmap_render, 0, 0, 0, 0, cliprect);
+ video_reset();
+
+ m_blinken1 = (m_lights >> 3) & 1;
+ m_blinken2 = (m_lights >> 2) & 1;
+ m_blinken3 = (m_lights >> 1) & 1;
+ m_blinken4 = (m_lights >> 0) & 1;
+ return 0;
}
//**************************************************************************
@@ -126,12 +164,12 @@ uint32_t gigatron_state::screen_update(screen_device &screen, bitmap_rgb32 &bitm
void gigatron_state::prog_map(address_map &map)
{
- map(0x0000, 0x3fff).rom().region("maincpu", 0);
+ map(0x0000, 0xffff).rom().region("maincpu", 0);
}
void gigatron_state::data_map(address_map &map)
{
- map(0x0000, 0x7fff).ram();
+ map(0x0000, 0xffff).ram();
}
//**************************************************************************
@@ -140,62 +178,71 @@ void gigatron_state::data_map(address_map &map)
static INPUT_PORTS_START(gigatron)
PORT_START("GAMEPAD")
- PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1)
- PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_PLAYER(1)
- PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1)
- PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1)
- PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_START ) PORT_PLAYER(1) // START
- PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_SELECT ) PORT_PLAYER(1) // SELECT
- PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("B Button") PORT_PLAYER(1) // B Button
- PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_NAME("A Button") PORT_PLAYER(1) // A Button
+ PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1)
+ PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1)
+ PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1)
+ PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1)
+ PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_START ) PORT_PLAYER(1) // START
+ PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_SELECT ) PORT_PLAYER(1) // SELECT
+ PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("B Button") PORT_PLAYER(1) // B Button
+ PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("A Button") PORT_PLAYER(1) // A Button
INPUT_PORTS_END
void gigatron_state::machine_start()
{
- save_item(NAME(m_lc));
+ //blinkenlights
+ m_blinken1.resolve();
+ m_blinken2.resolve();
+ m_blinken3.resolve();
+ m_blinken4.resolve();
+
+ //Savestate stuff
+ save_item(NAME(m_lights));
save_item(NAME(m_out));
save_item(NAME(m_row));
save_item(NAME(m_col));
save_item(NAME(m_pixel));
+ save_item(NAME(m_dacoutput));
}
void gigatron_state::machine_reset()
{
+ m_dacoutput = 0;
m_dac->write(0);
+ m_lights = 0;
+ m_out = 0;
+ m_row = 0;
+ m_col = 0;
+ m_pixel = 0;
}
void gigatron_state::port_outx(uint8_t data)
{
- blinkenlights(data & 0x0F);
- m_dac->write((data & 0xF0) >> 4);
-}
-
-void gigatron_state::blinkenlights(uint8_t data)
-{
- uint16_t light = data & 0xF;
- m_lc ^= light;
-}
-
-uint8_t gigatron_state::inputs()
-{
- return m_io_inputs->read() ^ 0xFF;
+ //Write sound to DAC
+ m_dacoutput = (data & 0xF0) >> 4;
+ m_dac->write(m_dacoutput);
+
+ //Blinkenlights
+ m_lights = data & 0xF;
}
void gigatron_state::gigatron(machine_config &config)
{
+ config.set_default_layout(layout_gigatron);
+
GTRON(config, m_maincpu, MAIN_CLOCK);
m_maincpu->set_addrmap(AS_PROGRAM, &gigatron_state::prog_map);
m_maincpu->set_addrmap(AS_DATA, &gigatron_state::data_map);
m_maincpu->outx_cb().set(FUNC(gigatron_state::port_outx));
- m_maincpu->out_cb().set(FUNC(gigatron_state::video_draw));
- m_maincpu->ir_cb().set(FUNC(gigatron_state::inputs));
+ m_maincpu->out_cb().set(FUNC(gigatron_state::port_out));
+ m_maincpu->ir_cb().set_ioport("GAMEPAD").invert();
/* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(59.98);
- screen.set_size(640, 480);
- screen.set_visarea(0, 640-1, 0, 480-1);
- screen.set_screen_update(FUNC(gigatron_state::screen_update));
+ screen_device &m_screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
+ m_screen.set_refresh_hz(59.98);
+ m_screen.set_size(640, 480);
+ m_screen.set_visarea(0, 640-1, 0, 480-1);
+ m_screen.set_screen_update(FUNC(gigatron_state::screen_update));
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@@ -207,16 +254,16 @@ void gigatron_state::gigatron(machine_config &config)
ROM_START( gigatron )
ROM_REGION( 0x20000, "maincpu", 0 )
- ROM_SYSTEM_BIOS(0, "v5a", "Gigatron ROM V5a")
+ ROM_SYSTEM_BIOS(0, "v5a", "Gigatron ROM v5a")
ROMX_LOAD( "gigrom5a.rom", 0x0000, 0x20000, CRC(DCC071A6) SHA1(F82059BA0227FF48E4C687B90C8445DA30213EE2),ROM_BIOS(0))
- ROM_SYSTEM_BIOS(1, "v4", "Gigatron ROM V4")
+ ROM_SYSTEM_BIOS(1, "v4", "Gigatron ROM v4")
ROMX_LOAD( "gigrom4.rom", 0x0000, 0x20000, CRC(78995109) SHA1(2395fc48e64099836111f5aeca39ddbf4650ea4e),ROM_BIOS(1))
- ROM_SYSTEM_BIOS(2, "v3", "Gigatron ROM V3")
+ ROM_SYSTEM_BIOS(2, "v3", "Gigatron ROM v3")
ROMX_LOAD( "gigrom3.rom", 0x0000, 0x20000, CRC(1536efbe) SHA1(959268069e761a01d620396eedb9abc1ee63c421),ROM_BIOS(2))
- ROM_SYSTEM_BIOS(3, "v2", "Gigatron ROM V2")
+ ROM_SYSTEM_BIOS(3, "v2", "Gigatron ROM v2")
ROMX_LOAD( "gigrom2.rom", 0x0000, 0x20000, CRC(b4a3d936) SHA1(c93f417d589144b912c79f85b9e942d66242c2c3),ROM_BIOS(3))
- ROM_SYSTEM_BIOS(4, "v1", "Gigatron ROM V1")
+ ROM_SYSTEM_BIOS(4, "v1", "Gigatron ROM v1")
ROMX_LOAD( "gigrom1.rom", 0x0000, 0x20000, CRC(8ea5a2af) SHA1(e5758d5cc467c3476bd8f992fd45dfcdf06d0430),ROM_BIOS(4))
ROM_END
-COMP(2018, gigatron, 0, 0, gigatron, gigatron, gigatron_state, empty_init, "Marcel van Kervinck / Walter Belgers", "Gigatron TTL Microcomputer", MACHINE_IS_SKELETON)
+COMP(2018, gigatron, 0, 0, gigatron, gigatron, gigatron_state, empty_init, "Marcel van Kervinck / Walter Belgers", "Gigatron TTL Microcomputer", MACHINE_SUPPORTS_SAVE)
diff --git a/src/mame/drivers/goldnpkr.cpp b/src/mame/drivers/goldnpkr.cpp
index aab11939887..ea2fa1cc8cb 100644
--- a/src/mame/drivers/goldnpkr.cpp
+++ b/src/mame/drivers/goldnpkr.cpp
@@ -486,14 +486,31 @@
2 or 3 deals per hand. It's running in a ICP-1 PCB.
Entering the service mode (key 0), you can enter to a submenu for settings pressing
- DEAL (key 2). Use HOLD keys (keys ZXCVB) to navigate through the menu and change
+ DEAL (key 2):
+
+ Win Limit (0-9 the first time, then 3-9)
+ Payout Limit (0-2)
+ Double Odds % (0-9)
+ Payout % (0-9)
+ Hard Setting (0-4)
+ Note Value (fixed in 5)
+
+ Bonus (0 to 10000, step x100)
+ (if you rech 10000, settings exits and go to game. You can't change bonus anymore.
+
+ Use HOLD keys (keys ZXCVB) to navigate through the menu and change
the values. Press CANCEL to exit the settings menu.
+ ** NOTE **
+ 2-3 deals, turbo mode, bonus and royal flush could be set through DIP switches.
+
+
Program is currently not working because seems to fill some zeropage registers and
check for existent values and changes... Maybe an external device is writting them.
This is NVRAM zone, so some values could be previously harcoded.
- Also seems to expect some inputs combination entered to boot.
+ Also seems to manipulate the stack pointer expecting different values, and some inputs
+ combination entered to boot.
To run...
1) Start the game.
@@ -515,6 +532,13 @@
fully working.
+ For now will patch the dead end to get it working.
+ e9f4: jmp $ea56 ---> death
+ e9f7: jmp $cec6 ---> works
+
+ The game needs ~25 seconds to check all the things to start.
+
+
************************************************************************************
@@ -1356,6 +1380,7 @@ public:
void init_vkdlswwv();
void init_bchancep();
void init_bonuspkr();
+ void init_super98();
uint8_t pottnpkr_mux_port_r();
void lamps_a_w(uint8_t data);
@@ -4158,10 +4183,10 @@ static INPUT_PORTS_START( super98 )
PORT_DIPNAME( 0x20, 0x00, "Turbo" )
PORT_DIPSETTING( 0x20, DEF_STR( No ) )
PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
- PORT_DIPNAME( 0x40, 0x40, "Bonus" )
+ PORT_DIPNAME( 0x40, 0x00, "Bonus" )
PORT_DIPSETTING( 0x40, DEF_STR( No ) )
PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
- PORT_DIPNAME( 0x80, 0x80, "Royal Flush" )
+ PORT_DIPNAME( 0x80, 0x00, "Royal Flush" )
PORT_DIPSETTING( 0x80, DEF_STR( No ) )
PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
INPUT_PORTS_END
@@ -12143,6 +12168,32 @@ void goldnpkr_state::init_bonuspkr()
}
+/*
+ Super 98 protection.
+
+ Code checks for different things on NVRAM space.
+ There are involved zeropage registers, inputs
+ combinations, and stack pointer handling.
+
+ The game takes 25 seconds to do all the checks.
+
+ E9F4: jmp $EA56 ; infinite loop / dead end.
+ E9F7: jmp $CEC6 ; the game continue executing...
+
+*/
+
+void goldnpkr_state::init_super98()
+{
+// NOPing the deadly call for now.
+
+ uint8_t *ROM = memregion("maincpu")->base();
+
+ ROM[0x69f4] = 0xea;
+ ROM[0x69f5] = 0xea;
+ ROM[0x69f6] = 0xea;
+}
+
+
/*********************************************
* Game Drivers *
*********************************************/
@@ -12299,8 +12350,8 @@ GAME( 198?, pokersis, 0, bchancep, goldnpkr, goldnpkr_state, empty_init
GAMEL( 198?, bchancep, 0, bchancep, goldnpkr, goldnpkr_state, init_bchancep, ROT0, "<unknown>", "Bonne Chance! (Golden Poker prequel HW, set 1)", MACHINE_NOT_WORKING, layout_goldnpkr )
GAMEL( 198?, bchanceq, 0, goldnpkr, goldnpkr, goldnpkr_state, empty_init, ROT0, "<unknown>", "Bonne Chance! (Golden Poker prequel HW, set 2)", MACHINE_NOT_WORKING, layout_goldnpkr )
-GAME( 1987, pokermon, 0, mondial, mondial, goldnpkr_state, empty_init, ROT0, "<unknown>", "Mundial/Mondial (Italian/French)", 0 ) // banked selectable program
-GAME( 1998, super98, bsuerte, witchcrd, super98, goldnpkr_state, empty_init, ROT0, "<unknown>", "Super 98 (3-hands, ICP-1)", MACHINE_NOT_WORKING ) // program checks zeropage registers for changes...
+GAME( 1987, pokermon, 0, mondial, mondial, goldnpkr_state, empty_init, ROT0, "<unknown>", "Mundial/Mondial (Italian/French)", 0 ) // banked selectable program.
+GAME( 1998, super98, bsuerte, witchcrd, super98, goldnpkr_state, init_super98, ROT0, "<unknown>", "Super 98 (3-hands, ICP-1)", 0 ) // complex protection. see notes.
GAME( 198?, animpkr, 0, icp_ext, animpkr, goldnpkr_state, empty_init, ROT0, "<unknown>", "unknown rocket/animal-themed poker", MACHINE_IMPERFECT_COLORS ) // banked program. how to switch gfx?
diff --git a/src/mame/drivers/goldstar.cpp b/src/mame/drivers/goldstar.cpp
index 3207046a21a..8d0519c7f07 100644
--- a/src/mame/drivers/goldstar.cpp
+++ b/src/mame/drivers/goldstar.cpp
@@ -11242,6 +11242,138 @@ ROM_START( cmasterh )
ROM_END
+/*
+ Cherry Master.
+
+ The EPROMS devices only hold the second half of the needed program and regular tiles data.
+ EPROMS are NMC27CP128Q that are sized 0x4000, when the real data should be 0x8000 for each position.
+
+ *EDIT*
+ Even when the NMC27CP128Q datasheet says that these devices are 128 Kbits (16k x8), we redumped
+ them as 27c256, and got perfect complete 32k x8 dumps.
+
+ This is very weird, since the datasheet diagram clearly shows that this device lacks of A14 line.
+
+ So... The National NMC27CP128Q devices could hold twice the specified size, or these on the board
+ are just fake devices for protection purposes.
+
+*/
+ROM_START( cmasteri )
+ ROM_REGION( 0x10000, "maincpu", 0 ) // 32k x 8 data coming from a real NMC27CP128Q
+ ROM_LOAD( "9.u81", 0x0000, 0x1000, CRC(2738eb55) SHA1(95e420544f36e4ce6358f14fee7a6b7ecd4cc568) )
+ ROM_CONTINUE(0x4000,0x1000)
+ ROM_CONTINUE(0x3000,0x1000)
+ ROM_CONTINUE(0x7000,0x1000)
+ ROM_CONTINUE(0x1000,0x1000)
+ ROM_CONTINUE(0x6000,0x1000)
+ ROM_CONTINUE(0x2000,0x1000)
+ ROM_CONTINUE(0x5000,0x1000)
+
+ ROM_REGION( 0x18000, "gfx1", 0 ) // 32k x 8 data coming from real NMC27CP128Q devices
+ ROM_LOAD( "7.u16", 0x00000, 0x8000, CRC(19cc1d67) SHA1(47487f9362bfb36a32100ed772960628844462bf) )
+ ROM_LOAD( "6.u11", 0x08000, 0x8000, CRC(63b3df4e) SHA1(9bacd23da598805ec18ec5ad15cab95d71eb9262) )
+ ROM_LOAD( "5.u4", 0x10000, 0x8000, CRC(e39fff9c) SHA1(22fdc517fa478441622c6245cecb5728c5595757) )
+
+ ROM_REGION( 0x8000, "gfx2", 0 )
+ ROM_LOAD( "4.u15", 0x0000, 0x2000, CRC(8607ffd9) SHA1(9bc94715554aa2473ae2ed249a47f29c7886b3dc) )
+ ROM_LOAD( "3.u10", 0x2000, 0x2000, CRC(c32367be) SHA1(ff217021b9c58e23b2226f8b0a7f5da966225715) )
+ ROM_LOAD( "2.u14", 0x4000, 0x2000, CRC(6dfcb188) SHA1(22430429c798954d9d979e62699b58feae7fdbf4) )
+ ROM_LOAD( "1.u9", 0x6000, 0x2000, CRC(9678ead2) SHA1(e80aefa98b2363fe9e6b2415762695ace272e4d3) )
+
+ ROM_REGION( 0x10000, "user1", 0 )
+ ROM_LOAD( "8.u58", 0x0000, 0x10000, CRC(e92443d3) SHA1(4b6ca4521841610054165f085ae05510e77af191) )
+
+ ROM_REGION( 0x200, "proms", 0 )
+ ROM_LOAD( "74s287.u84", 0x0000, 0x0100, CRC(0489b760) SHA1(78f8632b17a76335183c5c204cdec856988368b0) )
+ ROM_LOAD( "74s287.u79", 0x0100, 0x0100, CRC(21eb5b19) SHA1(9b8425bdb97f11f4855c998c7792c3291fd07470) )
+
+ ROM_REGION( 0x100, "proms2", 0 )
+ ROM_LOAD( "74s287.u46", 0x0000, 0x0100, CRC(50ec383b) SHA1(ae95b92bd3946b40134bcdc22708d5c6b0f4c23e) )
+ROM_END
+
+
+/*
+ Cherry Master.
+ CM-1 v1.01
+
+ These sets were modified to use different inputs to stop all reels.
+
+ cmasterj uses BET to stop all.
+ (this set needs to press stop as soon as the spin starts)
+
+ cmasterk uses TAKE to stop all.
+
+ Should be other changes since there are program blocks moved/modded,
+ but these are unknown.
+
+*/
+ROM_START( cmasterj )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "mb1_hold__bet_all_stop.bin", 0x0000, 0x1000, CRC(5f168417) SHA1(7ba7fed94ce7211fa8cf6c2abe8dea4b44a22aee) )
+ ROM_CONTINUE(0x4000,0x1000)
+ ROM_CONTINUE(0x3000,0x1000)
+ ROM_CONTINUE(0x7000,0x1000)
+ ROM_CONTINUE(0x1000,0x1000)
+ ROM_CONTINUE(0x6000,0x1000)
+ ROM_CONTINUE(0x2000,0x1000)
+ ROM_CONTINUE(0x5000,0x1000)
+
+ ROM_REGION( 0x18000, "gfx1", 0 )
+ ROM_LOAD( "7.u16", 0x00000, 0x8000, CRC(19cc1d67) SHA1(47487f9362bfb36a32100ed772960628844462bf) )
+ ROM_LOAD( "6.u11", 0x08000, 0x8000, CRC(63b3df4e) SHA1(9bacd23da598805ec18ec5ad15cab95d71eb9262) )
+ ROM_LOAD( "5.u4", 0x10000, 0x8000, CRC(e39fff9c) SHA1(22fdc517fa478441622c6245cecb5728c5595757) )
+
+ ROM_REGION( 0x8000, "gfx2", 0 )
+ ROM_LOAD( "4.u15", 0x0000, 0x2000, CRC(8607ffd9) SHA1(9bc94715554aa2473ae2ed249a47f29c7886b3dc) )
+ ROM_LOAD( "3.u10", 0x2000, 0x2000, CRC(c32367be) SHA1(ff217021b9c58e23b2226f8b0a7f5da966225715) )
+ ROM_LOAD( "2.u14", 0x4000, 0x2000, CRC(6dfcb188) SHA1(22430429c798954d9d979e62699b58feae7fdbf4) )
+ ROM_LOAD( "1.u9", 0x6000, 0x2000, CRC(9678ead2) SHA1(e80aefa98b2363fe9e6b2415762695ace272e4d3) )
+
+ ROM_REGION( 0x10000, "user1", 0 )
+ ROM_LOAD( "8.u58", 0x0000, 0x10000, CRC(e92443d3) SHA1(4b6ca4521841610054165f085ae05510e77af191) )
+
+ ROM_REGION( 0x200, "proms", 0 )
+ ROM_LOAD( "prom1.u84", 0x0000, 0x0100, CRC(0489b760) SHA1(78f8632b17a76335183c5c204cdec856988368b0) )
+ ROM_LOAD( "prom2.u79", 0x0100, 0x0100, CRC(21eb5b19) SHA1(9b8425bdb97f11f4855c998c7792c3291fd07470) )
+
+ ROM_REGION( 0x100, "proms2", 0 )
+ ROM_LOAD( "prom3.u46", 0x0000, 0x0100, CRC(50ec383b) SHA1(ae95b92bd3946b40134bcdc22708d5c6b0f4c23e) )
+ROM_END
+
+ROM_START( cmasterk )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "mb1_hold__take_all_stop.bin", 0x0000, 0x1000, CRC(4ffc137f) SHA1(0f080241fa9ded561324b0c602f80159f4683387) )
+ ROM_CONTINUE(0x4000,0x1000)
+ ROM_CONTINUE(0x3000,0x1000)
+ ROM_CONTINUE(0x7000,0x1000)
+ ROM_CONTINUE(0x1000,0x1000)
+ ROM_CONTINUE(0x6000,0x1000)
+ ROM_CONTINUE(0x2000,0x1000)
+ ROM_CONTINUE(0x5000,0x1000)
+
+ ROM_REGION( 0x18000, "gfx1", 0 )
+ ROM_LOAD( "7.u16", 0x00000, 0x8000, CRC(19cc1d67) SHA1(47487f9362bfb36a32100ed772960628844462bf) )
+ ROM_LOAD( "6.u11", 0x08000, 0x8000, CRC(63b3df4e) SHA1(9bacd23da598805ec18ec5ad15cab95d71eb9262) )
+ ROM_LOAD( "5.u4", 0x10000, 0x8000, CRC(e39fff9c) SHA1(22fdc517fa478441622c6245cecb5728c5595757) )
+
+ ROM_REGION( 0x8000, "gfx2", 0 )
+ ROM_LOAD( "4.u15", 0x0000, 0x2000, CRC(8607ffd9) SHA1(9bc94715554aa2473ae2ed249a47f29c7886b3dc) )
+ ROM_LOAD( "3.u10", 0x2000, 0x2000, CRC(c32367be) SHA1(ff217021b9c58e23b2226f8b0a7f5da966225715) )
+ ROM_LOAD( "2.u14", 0x4000, 0x2000, CRC(6dfcb188) SHA1(22430429c798954d9d979e62699b58feae7fdbf4) )
+ ROM_LOAD( "1.u9", 0x6000, 0x2000, CRC(9678ead2) SHA1(e80aefa98b2363fe9e6b2415762695ace272e4d3) )
+
+ ROM_REGION( 0x10000, "user1", 0 )
+ ROM_LOAD( "8.u58", 0x0000, 0x10000, CRC(e92443d3) SHA1(4b6ca4521841610054165f085ae05510e77af191) )
+
+ ROM_REGION( 0x200, "proms", 0 )
+ ROM_LOAD( "prom1.u84", 0x0000, 0x0100, CRC(0489b760) SHA1(78f8632b17a76335183c5c204cdec856988368b0) )
+ ROM_LOAD( "prom2.u79", 0x0100, 0x0100, CRC(21eb5b19) SHA1(9b8425bdb97f11f4855c998c7792c3291fd07470) )
+
+ ROM_REGION( 0x100, "proms2", 0 )
+ ROM_LOAD( "prom3.u46", 0x0000, 0x0100, CRC(50ec383b) SHA1(ae95b92bd3946b40134bcdc22708d5c6b0f4c23e) )
+ROM_END
+
+
ROM_START( cmast99 )
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "cm99-041-8.u81", 0x0000, 0x1000, CRC(5fb0800e) SHA1(14d316b7b89340c5b5c9fdd0b43d5810513b74d6) )
@@ -19208,6 +19340,9 @@ GAMEL( 1991, cmastere, cmaster, cm, cmasterb, cmaster_state, init_cmv4,
GAMEL( 1991, cmasterf, cmaster, cm, cmasterb, cmaster_state, init_cmv4, ROT0, "Dyna", "Cherry Master I (ver.1.01, set 7)", 0, layout_cmasterb )
GAMEL( 1991, cmasterg, cmaster, cm, cmasterg, cmaster_state, init_cmv4, ROT0, "Dyna", "Cherry Master I (ver.1.01, set 8, V4-B-)", 0, layout_cmasterb )
GAMEL( 1991, cmasterh, cmaster, cm, cmasterh, cmaster_state, init_cmv4, ROT0, "Dyna", "Cherry Master I (ver.1.10)", 0, layout_cmasterb )
+GAMEL( 1991, cmasteri, cmaster, cm, cmasterb, cmaster_state, init_cmv4, ROT0, "Dyna", "Cherry Master I (ver.1.01, set 9)", 0, layout_cmasterb ) // NMC27CP128Q being 32k x8 instead of 16k x8...
+GAMEL( 1991, cmasterj, cmaster, cm, cmasterb, cmaster_state, init_cmv4, ROT0, "Dyna", "Cherry Master I (ver.1.01, set 10, BET stops all)", 0, layout_cmasterb )
+GAMEL( 1991, cmasterk, cmaster, cm, cmasterb, cmaster_state, init_cmv4, ROT0, "Dyna", "Cherry Master I (ver.1.01, set 11, TAKE stops all)", 0, layout_cmasterb )
GAMEL( 199?, super7, cmaster, cm, cmaster, cmaster_state, init_super7, ROT0, "bootleg", "Super Seven", MACHINE_NOT_WORKING, layout_cmasterb )
GAME ( 199?, wcat3a, wcat3, chryangl, cmaster, cmaster_state, init_wcat3a, ROT0, "E.A.I.", "Wild Cat 3 (CMV4 hardware)", MACHINE_NOT_WORKING ) // does not boot. Wrong decryption, wrong machine or wrong what?
diff --git a/src/mame/drivers/hec2hrp.cpp b/src/mame/drivers/hec2hrp.cpp
index 8de75c1a7d2..36977c2e70e 100644
--- a/src/mame/drivers/hec2hrp.cpp
+++ b/src/mame/drivers/hec2hrp.cpp
@@ -11,20 +11,31 @@
Hector 1
Interact
- These machines can load and run cassettes for the interact / hector1.
+The first model (Interact)was made by Interact Electronics Inc of Ann Arbor,
+Michigan. However, just after launch, the company collapsed. The liquidator,
+Protecto, sold some and MicroVideo sold the rest. MicroVideo continued to
+develop but went under 2 years later. Meanwhile, the French company
+Lambda Systems sold a clone called the Victor Lambda. But, like the
+Americans, Lambda Systems also collapsed. Another French company,
+Micronique, purchased all remaining stock and intellectual rights
+from Lambda Systems, Microvideo and Interact, and the computer becomes
+wholly French. The computer has a name change, becoming the Hector.
+This in turn gets upgraded (2HR, HRX, MX). The line is finally
+retired in about 1985.
+
+These machines can load and run cassettes for the interact / hector1.
hec2hr - press 2 then 1
hec2hrp - press 2 then 1
- hec2hrx - press 5 then 1
- hec2mx40 - press 5 then 1
- hec2mx80 - not compatible
victor - press R then L
- 12/05/2009 Skeleton driver - Micko : mmicko@gmail.com
- 31/06/2009 Video - Robbbert
+These machines will load the cassette but the keys don't work
+ hec2hrx, hec2mx40, hec2mdhrx - press 5 then 1
- 29/10/2009 Update skeleton to functional machine
- by yo_fr (jj.stac @ aliceadsl.fr)
+This machine not compatible
+ hec2mx80
+2009-05-12 Skeleton driver - Micko : mmicko@gmail.com
+2009-10-29 Update skeleton to functional machine by yo_fr (jj.stac @ aliceadsl.fr)
=> add Keyboard,
=> add color,
=> add cassette,
@@ -33,19 +44,19 @@
=> add BR/HR switching
=> add bank switch for HRX
=> add device MX80c and bank switching for the ROM
- Importante note : Keyboard emulation code obtained from
+ Important note : Keyboard emulation code obtained from
DChector project : http://dchector.free.fr/ made by DanielCoulom
(thanks Daniel)
- 03/01/2010 Update and cleanup by yo_fr (jj.stac@aliceadsl.fr)
+2010-01-03 Update and cleanup by yo_fr (jj.stac@aliceadsl.fr)
=> add the port mapping for keyboard
- 20/11/2010 : synchronization between uPD765 and Z80 are now OK, CP/M running! JJStacino
- 11/11/2011 : add minidisk (3.5") support JJStacino
+2010-11-20 : synchronization between uPD765 and Z80 are now OK, CP/M running! JJStacino
+2011-11-11 : add minidisk (3.5") support JJStacino
- for more information about these machines, see the DChector project : http://dchector.free.fr/ made by DanielCoulom
+ For more information about these machines, see the DChector project : http://dchector.free.fr/ made by DanielCoulom
(thanks to Daniel) and Yves site : http://hectorvictor.free.fr/ (thanks too Yves!)
- TODO : Add cartridge functionality
- Adjust the one-shot and A/D timing (sn76477)
+TODO : Add cartridge functionality
+ Adjust the one-shot and A/D timing (sn76477)
****************************************************************************/
/* Joystick 1 :
@@ -75,101 +86,59 @@
#include "includes/hec2hrp.h"
#include "cpu/z80/z80.h"
-#include "imagedev/cassette.h"
-#include "imagedev/printer.h"
-#include "sound/discrete.h" /* for 1 Bit sound*/
-
+#include "cpu/i8085/i8085.h"
#include "screen.h"
#include "speaker.h"
-
#include "formats/hect_dsk.h"
#include "formats/hect_tap.h"
#include "formats/hector_minidisc.h"
-void hec2hrp_state::hecdisc2_mem(address_map &map)
-{
- map.unmap_value_high();
-
- map(0x0000, 0x3fff).bankrw("bank3"); /* ROM at start up, RAM later */
- map(0x4000, 0xffff).ram();
-}
-
-void hec2hrp_state::hecdisc2_io(address_map &map)
+void hec2hrp_state::interact_mem(address_map &map)
{
map.unmap_value_high();
- map.global_mask(0xff);
- // ROM page handling
- map(0x000, 0x00f).rw(FUNC(hec2hrp_state::disc2_io00_port_r), FUNC(hec2hrp_state::disc2_io00_port_w));
- // RS232 - 8251 comms handling
- map(0x020, 0x02f).rw(FUNC(hec2hrp_state::disc2_io20_port_r), FUNC(hec2hrp_state::disc2_io20_port_w));
- // Hector comms handling
- map(0x030, 0x03f).rw(FUNC(hec2hrp_state::disc2_io30_port_r), FUNC(hec2hrp_state::disc2_io30_port_w));
- map(0x040, 0x04f).rw(FUNC(hec2hrp_state::disc2_io40_port_r), FUNC(hec2hrp_state::disc2_io40_port_w));
- map(0x050, 0x05f).rw(FUNC(hec2hrp_state::disc2_io50_port_r), FUNC(hec2hrp_state::disc2_io50_port_w));
- // uPD765 link
- map(0x060, 0x061).m(m_upd_fdc, FUNC(upd765a_device::map));
- map(0x070, 0x070).mirror(0x00f).rw(m_upd_fdc, FUNC(upd765a_device::dma_r), FUNC(upd765a_device::dma_w));
+ /* Main ROM page*/
+ map(0x0000, 0x3fff).rom();
+ map(0x1000, 0x1000).w(FUNC(hec2hrp_state::color_a_w)); /* Color c0/c1*/
+ map(0x1800, 0x1800).w(FUNC(hec2hrp_state::color_b_w)); /* Color c2/c3*/
+ map(0x2000, 0x2003).w(FUNC(hec2hrp_state::sn_2000_w)); /* Sound*/
+ map(0x2800, 0x2803).w(FUNC(hec2hrp_state::sn_2800_w)); /* Sound*/
+ map(0x3000, 0x3000).rw(FUNC(hec2hrp_state::cassette_r), FUNC(hec2hrp_state::sn_3000_w));/* Write necessary*/
+ map(0x3800, 0x3807).rw(FUNC(hec2hrp_state::keyboard_r), FUNC(hec2hrp_state::keyboard_w)); /* Keyboard*/
+ map(0x4000, 0x49ff).ram().share("videoram");
+ map(0x4A00, 0xffff).ram();
}
void hec2hrp_state::hec2hrp_mem(address_map &map)
{
map.unmap_value_high();
- /* Main ROM page*/
- map(0x0000, 0x3fff).rom();
-
- /* Hardware address mapping */
- map(0x0800, 0x0808).w(FUNC(hec2hrp_state::switch_bank_w));/* Bank handling */
- map(0x1000, 0x1000).w(FUNC(hec2hrp_state::color_a_w)); /* Color c0/c1 */
- map(0x1800, 0x1800).w(FUNC(hec2hrp_state::color_b_w)); /* Color c2/c3 */
- map(0x2000, 0x2003).w(FUNC(hec2hrp_state::sn_2000_w)); /* Sound */
- map(0x2800, 0x2803).w(FUNC(hec2hrp_state::sn_2800_w)); /* Sound */
- map(0x3000, 0x3000).rw(FUNC(hec2hrp_state::cassette_r), FUNC(hec2hrp_state::sn_3000_w)); /* Write necessary */
- map(0x3800, 0x3807).rw(FUNC(hec2hrp_state::keyboard_r), FUNC(hec2hrp_state::keyboard_w)); /* Keyboard */
-
- /* Video br mapping */
- map(0x4000, 0x49ff).ram().share("videoram");
- /* contiguous RAM */
- map(0x4A00, 0xbfff).ram();
- /* from 0xC000 to 0xFFFF => Bank Ram for video and data */
- map(0xc000, 0xffff).ram().share("hector_videoram");
+ interact_mem(map);
+ map(0x0800, 0x0808).w(FUNC(hec2hrp_state::switch_bank_w)); // bank management
+ map(0xc000, 0xffff).ram().share("hector_videoram"); /* => Bank Ram for video and data */
}
void hec2hrp_state::hec2hrx_mem(address_map &map)
{
map.unmap_value_high();
- /* Main ROM page*/
- map(0x0000, 0x3fff).bankr("bank2");
-
- /* Hardware address mapping*/
- map(0x0800, 0x0808).w(FUNC(hec2hrp_state::switch_bank_w));/* Bank handling */
- map(0x1000, 0x1000).w(FUNC(hec2hrp_state::color_a_w)); /* Color c0/c1 */
- map(0x1800, 0x1800).w(FUNC(hec2hrp_state::color_b_w)); /* Color c2/c3 */
- map(0x2000, 0x2003).w(FUNC(hec2hrp_state::sn_2000_w)); /* Sound */
- map(0x2800, 0x2803).w(FUNC(hec2hrp_state::sn_2800_w)); /* Sound */
- map(0x3000, 0x3000).rw(FUNC(hec2hrp_state::cassette_r), FUNC(hec2hrp_state::sn_3000_w)); /* Write necessary */
- map(0x3800, 0x3807).rw(FUNC(hec2hrp_state::keyboard_r), FUNC(hec2hrp_state::keyboard_w)); /* Keyboard */
-
- /* Video br mapping */
- map(0x4000, 0x49ff).ram().share("videoram");
- /* contiguous RAM */
- map(0x4A00, 0xbfff).ram();
- /* from 0xC000 to 0xFFFF => Bank Ram for video and data */
- map(0xc000, 0xffff).bankrw("bank1").share("hector_videoram");
+ hec2hrp_mem(map);
+ map(0x0000, 0x3fff).bankr("bank2"); /* Main ROM page*/
+ map(0x3000, 0x3000).rw(FUNC(hec2hrp_state::cassette_r), FUNC(hec2hrp_state::sn_3000_w));/* Write necessary*/
+ map(0x3800, 0x3807).rw(FUNC(hec2hrp_state::keyboard_r), FUNC(hec2hrp_state::keyboard_w)); /* Keyboard*/
+ map(0xc000, 0xffff).bankrw("bank1").share("hector_videoram"); /* => Bank Ram for video and data */
}
void hec2hrp_state::hec2hrp_io(address_map &map)
{
map.unmap_value_high();
map.global_mask(0xff);
- map(0x000, 0x0ff).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
+ map(0x00, 0xff).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
}
void hec2hrp_state::hec2hrx_io(address_map &map)
{
map.unmap_value_high();
map.global_mask(0xff);
- map(0x0f0, 0x0ff).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
+ map(0xf0, 0xff).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
}
void hec2hrp_state::hec2mdhrx_io(address_map &map)
@@ -180,27 +149,54 @@ void hec2hrp_state::hec2mdhrx_io(address_map &map)
// Minidisc commands and changing the rom page */
map(0x04, 0x07).rw(m_minidisc_fdc, FUNC(fd1793_device::read), FUNC(fd1793_device::write));
map(0x08, 0x08).w(FUNC(hec2hrp_state::minidisc_control_w));
- map(0x0f0, 0x0ff).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
+ map(0xf0, 0xff).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
}
void hec2hrp_state::hec2mx40_io(address_map &map)
{
map.unmap_value_high();
map.global_mask(0xff);
- map(0x000, 0x0ef).w(FUNC(hec2hrp_state::mx40_io_port_w));
- map(0x0f0, 0x0f3).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
+ map(0x00, 0xef).w(FUNC(hec2hrp_state::mx40_io_port_w));
+ map(0xf0, 0xf3).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
}
void hec2hrp_state::hec2mx80_io(address_map &map)
{
map.unmap_value_high();
map.global_mask(0xff);
- map(0x000, 0x0ef).w(FUNC(hec2hrp_state::mx80_io_port_w));
- map(0x0f0, 0x0f3).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
+ map(0x00, 0xef).w(FUNC(hec2hrp_state::mx80_io_port_w));
+ map(0xf0, 0xf3).rw(FUNC(hec2hrp_state::io_8255_r), FUNC(hec2hrp_state::io_8255_w));
+
+}
+// 2nd cpu
+void hec2hrp_state::hecdisc2_mem(address_map &map)
+{
+ map.unmap_value_high();
+
+ map(0x0000, 0x3fff).bankrw("bank3"); /* ROM at start up, RAM later */
+ map(0x4000, 0xffff).ram();
}
+void hec2hrp_state::hecdisc2_io(address_map &map)
+{
+ map.unmap_value_high();
+ map.global_mask(0xff);
+ // ROM page handling
+ map(0x00, 0x0f).rw(FUNC(hec2hrp_state::disc2_io00_port_r), FUNC(hec2hrp_state::disc2_io00_port_w));
+ // RS232 - 8251 comms handling
+ map(0x20, 0x2f).rw(FUNC(hec2hrp_state::disc2_io20_port_r), FUNC(hec2hrp_state::disc2_io20_port_w));
+ // Hector comms handling
+ map(0x30, 0x3f).rw(FUNC(hec2hrp_state::disc2_io30_port_r), FUNC(hec2hrp_state::disc2_io30_port_w));
+ map(0x40, 0x4f).rw(FUNC(hec2hrp_state::disc2_io40_port_r), FUNC(hec2hrp_state::disc2_io40_port_w));
+ map(0x50, 0x5f).rw(FUNC(hec2hrp_state::disc2_io50_port_r), FUNC(hec2hrp_state::disc2_io50_port_w));
+ // uPD765 link
+ map(0x60, 0x61).m(m_upd_fdc, FUNC(upd765a_device::map));
+ map(0x70, 0x70).mirror(0x0f).rw(m_upd_fdc, FUNC(upd765a_device::dma_r), FUNC(upd765a_device::dma_w));
+}
+
+
/* Input ports */
static INPUT_PORTS_START( hec2hrp )
/* keyboard input */
@@ -292,6 +288,11 @@ static INPUT_PORTS_START( hec2hrp )
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_UNUSED)
INPUT_PORTS_END
+MACHINE_RESET_MEMBER(hec2hrp_state,interact)
+{
+ hector_reset(0, 0);
+}
+
MACHINE_START_MEMBER(hec2hrp_state,hec2hrp)
{
hector_init();
@@ -305,30 +306,30 @@ MACHINE_RESET_MEMBER(hec2hrp_state,hec2hrp)
MACHINE_START_MEMBER(hec2hrp_state,hec2hrx)
{
- uint8_t *RAM = memregion("maincpu")->base();
+ uint8_t *r = m_ram->pointer();
//Patch rom possible !
- //RAMD2[0xff6b] = 0x0ff; // force verbose mode
+ //RAMD2[0xff6b] = 0xff; // force verbose mode
// Memory install for bank switching
- membank("bank1")->configure_entry(HECTOR_BANK_PROG , &RAM[0xc000] );
- membank("bank1")->configure_entry(HECTOR_BANK_VIDEO, m_hector_videoram_hrx); // Video RAM
+ m_bank[1]->configure_entry(HECTOR_BANK_PROG, r+0x10000);
+ m_bank[1]->configure_entry(HECTOR_BANK_VIDEO, m_hector_videoram_hrx); // Video RAM
// Set bank HECTOR_BANK_PROG as basic bank
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
// MX-specific
- membank("bank2")->configure_entry(HECTORMX_BANK_PAGE0 , &RAM[0x0000]);
- membank("bank2")->configure_entry(HECTORMX_BANK_PAGE1 , memregion("page1")->base() ); // ROM page 1
- membank("bank2")->configure_entry(HECTORMX_BANK_PAGE2 , memregion("page2")->base() ); // ROM page 2
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE0);
+ m_bank[2]->configure_entry(HECTORMX_BANK_PAGE0, m_rom);
+ m_bank[2]->configure_entry(HECTORMX_BANK_PAGE1, memregion("page1")->base() ); // ROM page 1
+ m_bank[2]->configure_entry(HECTORMX_BANK_PAGE2, memregion("page2")->base() ); // ROM page 2
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE0);
// Disk II-specific
- membank("bank3")->configure_entry(DISCII_BANK_ROM , memregion("rom_disc2")->base() ); // ROM
- membank("bank3")->configure_entry(DISCII_BANK_RAM , memregion("disc2mem" )->base() ); // RAM
- membank("bank3")->set_entry(DISCII_BANK_ROM);
+ m_bank[3]->configure_entry(DISCII_BANK_ROM, memregion("rom_disc2")->base() ); // ROM
+ m_bank[3]->configure_entry(DISCII_BANK_RAM, r); // RAM
+ m_bank[3]->set_entry(DISCII_BANK_ROM);
// As video HR ram is in bank, use external memory
- m_hector_videoram.set_target(m_hector_videoram_hrx,m_hector_videoram.bytes());
+ m_hector_vram.set_target(m_hector_videoram_hrx,m_hector_vram.bytes());
hector_init();
}
@@ -337,23 +338,23 @@ MACHINE_START_MEMBER(hec2hrp_state,hec2mdhrx)
/*****************************************************************************/
//minidisc
{
- uint8_t *RAM = memregion("maincpu")->base();
+ uint8_t *r = m_ram->pointer();
// Memory install for bank switching
- membank("bank1")->configure_entry(HECTOR_BANK_PROG, &RAM[0xc000]);
- membank("bank1")->configure_entry(HECTOR_BANK_VIDEO, m_hector_videoram_hrx); // Video RAM
+ m_bank[1]->configure_entry(HECTOR_BANK_PROG, r+0x10000);
+ m_bank[1]->configure_entry(HECTOR_BANK_VIDEO, m_hector_videoram_hrx); // Video RAM
// Set HECTOR_BANK_PROG as basic bank
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
//Here, bank 5 is not used for the language switch but for the floppy ROM
// Mini disk-specific
- membank("bank2")->configure_entry(HECTOR_BANK_BASE, &RAM[0x0000]); // ROM base page
- membank("bank2")->configure_entry(HECTOR_BANK_DISC, memregion("page2")->base() ); // ROM mini disc page
- membank("bank2")->set_entry(HECTOR_BANK_BASE);
+ m_bank[2]->configure_entry(HECTOR_BANK_BASE, m_rom); // ROM base page
+ m_bank[2]->configure_entry(HECTOR_BANK_DISC, memregion("page2")->base() ); // ROM mini disc page
+ m_bank[2]->set_entry(HECTOR_BANK_BASE);
// As video HR ram is in bank, use external memory
- m_hector_videoram.set_target(m_hector_videoram_hrx,m_hector_videoram.bytes());
+ m_hector_vram.set_target(m_hector_videoram_hrx,m_hector_vram.bytes());
hector_init();
}
@@ -361,11 +362,11 @@ MACHINE_START_MEMBER(hec2hrp_state,hec2mdhrx)
MACHINE_RESET_MEMBER(hec2hrp_state,hec2hrx)
{
// Hector Memory
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE0);
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE0);
// DISK II Memory
- membank("bank3")->set_entry(DISCII_BANK_ROM);
+ m_bank[3]->set_entry(DISCII_BANK_ROM);
hector_reset(1, 1);
hector_disc2_reset();
@@ -375,82 +376,72 @@ MACHINE_RESET_MEMBER(hec2hrp_state,hec2hrx)
MACHINE_RESET_MEMBER(hec2hrp_state,hec2mdhrx)
{
// Hector Memory
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE0);
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE0);
hector_reset(1, 0);
}
-// mini disk interface
-
-FLOPPY_FORMATS_MEMBER( hec2hrp_state::minidisc_formats )
- FLOPPY_HMD_FORMAT
-FLOPPY_FORMATS_END
-
-static void minidisc_floppies(device_slot_interface &device)
-{
- device.option_add("dd", FLOPPY_35_DD);
-}
-
-
-void hec2hrp_state::hec2hr(machine_config &config)
+void hec2hrp_state::interact_common(machine_config &config)
{
- Z80(config, m_maincpu, 5_MHz_XTAL);
- m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrp_mem);
- m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2hrp_io);
- m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50)); /* put on the Z80 irq in Hz*/
-
- MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrp)
+ MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,interact)
MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrp)
+ /* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(50);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(400)); /* 2500 not accurate */
- screen.set_size(512, 230);
- screen.set_visarea(0, 243, 0, 227);
- screen.set_screen_update(FUNC(hec2hrp_state::screen_update_hec2hrp));
+ screen.set_refresh_hz(60);
+ screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
+ screen.set_size(256, 79);
+ screen.set_visarea(0, 112, 0, 77);
+ screen.set_screen_update(FUNC(hec2hrp_state::screen_update_interact));
screen.set_palette(m_palette);
- PALETTE(config, m_palette).set_entries(16);
- MCFG_VIDEO_START_OVERRIDE(hec2hrp_state,hec2hrp)
+ PALETTE(config, m_palette, FUNC(hec2hrp_state::init_palette), 16); /* 8 colours, but only 4 at a time*/
hector_audio(config);
CASSETTE(config, m_cassette);
m_cassette->set_formats(hector_cassette_formats);
m_cassette->set_default_state(CASSETTE_PLAY | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED);
+ m_cassette->add_route(ALL_OUTPUTS, "mono", 0.05);
+ m_cassette->set_interface("interact_cass");
+ SOFTWARE_LIST(config, "cass_list").set_original("interact");
+
+ /* printer */
PRINTER(config, m_printer, 0);
}
-void hec2hrp_state::hec2hrp(machine_config &config)
+void hec2hrp_state::interact(machine_config &config)
{
- Z80(config, m_maincpu, 5_MHz_XTAL);
- m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrp_mem);
- m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2hrp_io);
- m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50)); /* put on the Z80 irq in Hz*/
+ /* basic machine hardware */
+ I8080(config, m_maincpu, XTAL(2'000'000));
+ m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::interact_mem);
+ m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50));
- MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrp)
- MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrp)
+ interact_common(config);
+}
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(50);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(400)); /* 2500 not accurate */
- screen.set_size(512, 230);
- screen.set_visarea(0, 243, 0, 227);
- screen.set_screen_update(FUNC(hec2hrp_state::screen_update_hec2hrp));
- screen.set_palette(m_palette);
+void hec2hrp_state::hector1(machine_config &config)
+{
+ /* basic machine hardware */
+ Z80(config, m_maincpu, XTAL(1'750'000));
+ m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::interact_mem);
+ m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50));
- PALETTE(config, m_palette).set_entries(16);
- MCFG_VIDEO_START_OVERRIDE(hec2hrp_state,hec2hrp)
+ interact_common(config);
+}
- hector_audio(config);
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_PLAY | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED);
+// mini disk interface
- PRINTER(config, m_printer, 0);
+FLOPPY_FORMATS_MEMBER( hec2hrp_state::minidisc_formats )
+ FLOPPY_HMD_FORMAT
+FLOPPY_FORMATS_END
+
+static void minidisc_floppies(device_slot_interface &device)
+{
+ device.option_add("dd", FLOPPY_35_DD);
}
static void hector_floppies(device_slot_interface &device)
@@ -458,26 +449,16 @@ static void hector_floppies(device_slot_interface &device)
device.option_add("525hd", FLOPPY_525_HD);
}
-void hec2hrp_state::hec2mx40(machine_config &config)
+
+void hec2hrp_state::hec2hr(machine_config &config)
{
Z80(config, m_maincpu, 5_MHz_XTAL);
- m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrx_mem);
- m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2mx40_io);
+ m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrp_mem);
+ m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2hrp_io);
m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50)); /* put on the Z80 irq in Hz*/
- Z80(config, m_disc2cpu, 4_MHz_XTAL);
- m_disc2cpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hecdisc2_mem);
- m_disc2cpu->set_addrmap(AS_IO, &hec2hrp_state::hecdisc2_io);
-
- UPD765A(config, m_upd_fdc, 8'000'000, false, true);
- m_upd_fdc->intrq_wr_callback().set(FUNC(hec2hrp_state::disc2_fdc_interrupt));
- m_upd_fdc->drq_wr_callback().set(FUNC(hec2hrp_state::disc2_fdc_dma_irq));
-
- FLOPPY_CONNECTOR(config, m_upd_connector[0], hector_floppies, "525hd", floppy_image_device::default_floppy_formats);
- FLOPPY_CONNECTOR(config, m_upd_connector[1], hector_floppies, "525hd", floppy_image_device::default_floppy_formats);
-
- MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrx)
- MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrx)
+ MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrp)
+ MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrp)
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
screen.set_refresh_hz(50);
@@ -487,28 +468,29 @@ void hec2hrp_state::hec2mx40(machine_config &config)
screen.set_screen_update(FUNC(hec2hrp_state::screen_update_hec2hrp));
screen.set_palette(m_palette);
- PALETTE(config, m_palette).set_entries(16);
- MCFG_VIDEO_START_OVERRIDE(hec2hrp_state,hec2hrp)
+ PALETTE(config, m_palette, FUNC(hec2hrp_state::init_palette), 16); /* 8 colours, but only 4 at a time*/
hector_audio(config);
CASSETTE(config, m_cassette);
m_cassette->set_formats(hector_cassette_formats);
m_cassette->set_default_state(CASSETTE_PLAY | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED);
+ m_cassette->add_route(ALL_OUTPUTS, "mono", 0.05);
+ m_cassette->set_interface("interact_cass");
PRINTER(config, m_printer, 0);
-}
+ /* internal ram */
+ RAM(config, RAM_TAG).set_default_size("80K").set_default_value(0x00);
+
+ SOFTWARE_LIST(config, "cass_list").set_original("interact");
+}
void hec2hrp_state::hec2hrx(machine_config &config)
{
- Z80(config, m_maincpu, 5_MHz_XTAL);
+ hec2hr(config);
m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrx_mem);
m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2hrx_io);
- m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50)); /* put on the Z80 irq in Hz*/
-
- MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrx)
- MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrx)
Z80(config, m_disc2cpu, 4_MHz_XTAL);
m_disc2cpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hecdisc2_mem);
@@ -518,143 +500,91 @@ void hec2hrp_state::hec2hrx(machine_config &config)
m_upd_fdc->intrq_wr_callback().set(FUNC(hec2hrp_state::disc2_fdc_interrupt));
m_upd_fdc->drq_wr_callback().set(FUNC(hec2hrp_state::disc2_fdc_dma_irq));
- FLOPPY_CONNECTOR(config, m_upd_connector[0], hector_floppies, "525hd", floppy_image_device::default_floppy_formats);
- FLOPPY_CONNECTOR(config, m_upd_connector[1], hector_floppies, "525hd", floppy_image_device::default_floppy_formats);
+ FLOPPY_CONNECTOR(config, m_upd_connector[0], hector_floppies, "525hd", floppy_image_device::default_floppy_formats).enable_sound(true);
+ FLOPPY_CONNECTOR(config, m_upd_connector[1], hector_floppies, "525hd", floppy_image_device::default_floppy_formats).enable_sound(true);
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(50);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(400)); /* 2500 not accurate */
- screen.set_size(512, 230);
- screen.set_visarea(0, 243, 0, 227);
- screen.set_screen_update(FUNC(hec2hrp_state::screen_update_hec2hrp));
- screen.set_palette(m_palette);
-
- PALETTE(config, m_palette).set_entries(16);
- MCFG_VIDEO_START_OVERRIDE(hec2hrp_state,hec2hrp)
-
- hector_audio(config);
+ MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrx)
+ MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrx)
+}
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_PLAY | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED);
+void hec2hrp_state::hec2mx40(machine_config &config)
+{
+ hec2hrx(config);
+ m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2mx40_io);
+}
- PRINTER(config, m_printer, 0);
+void hec2hrp_state::hec2mx80(machine_config &config)
+{
+ hec2hrx(config);
+ m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2mx80_io);
}
void hec2hrp_state::hec2mdhrx(machine_config &config)
{
- Z80(config, m_maincpu, 5_MHz_XTAL);
+ hec2hr(config);
m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrx_mem);
m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2mdhrx_io);
- m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50)); /* put on the Z80 irq in Hz*/
MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2mdhrx)
MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2mdhrx)
/* 3.5" ("mini") disc */
FD1793(config, m_minidisc_fdc, 1_MHz_XTAL);
- FLOPPY_CONNECTOR(config, "wd179x:0", minidisc_floppies, "dd", hec2hrp_state::minidisc_formats);
-
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(50);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(400)); /* 2500 not accurate */
- screen.set_size(512, 230);
- screen.set_visarea(0, 243, 0, 227);
- screen.set_screen_update(FUNC(hec2hrp_state::screen_update_hec2hrp));
- screen.set_palette(m_palette);
-
- PALETTE(config, m_palette).set_entries(16);
- MCFG_VIDEO_START_OVERRIDE(hec2hrp_state,hec2hrp)
-
- hector_audio(config);
-
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_PLAY | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED);
-
- PRINTER(config, m_printer, 0);
+ FLOPPY_CONNECTOR(config, "wd179x:0", minidisc_floppies, "dd", hec2hrp_state::minidisc_formats).enable_sound(true);
}
-void hec2hrp_state::hec2mx80(machine_config &config)
-{
- Z80(config, m_maincpu, 5_MHz_XTAL);
- m_maincpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hec2hrx_mem);
- m_maincpu->set_addrmap(AS_IO, &hec2hrp_state::hec2mx80_io);
- m_maincpu->set_periodic_int(FUNC(hec2hrp_state::irq0_line_hold), attotime::from_hz(50)); /* put on the Z80 irq in Hz*/
-
- MCFG_MACHINE_RESET_OVERRIDE(hec2hrp_state,hec2hrx)
- MCFG_MACHINE_START_OVERRIDE(hec2hrp_state,hec2hrx)
-
- Z80(config, m_disc2cpu, 4_MHz_XTAL);
- m_disc2cpu->set_addrmap(AS_PROGRAM, &hec2hrp_state::hecdisc2_mem);
- m_disc2cpu->set_addrmap(AS_IO, &hec2hrp_state::hecdisc2_io);
-
- UPD765A(config, m_upd_fdc, 8'000'000, false, true);
- m_upd_fdc->intrq_wr_callback().set(FUNC(hec2hrp_state::disc2_fdc_interrupt));
- m_upd_fdc->drq_wr_callback().set(FUNC(hec2hrp_state::disc2_fdc_dma_irq));
-
- FLOPPY_CONNECTOR(config, m_upd_connector[0], hector_floppies, "525hd", floppy_image_device::default_floppy_formats);
- FLOPPY_CONNECTOR(config, m_upd_connector[1], hector_floppies, "525hd", floppy_image_device::default_floppy_formats);
-
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(50);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(400)); /* 2500 not accurate */
- screen.set_size(512, 230);
- screen.set_visarea(0, 243, 0, 227);
- screen.set_screen_update(FUNC(hec2hrp_state::screen_update_hec2hrp));
- screen.set_palette(m_palette);
-
- PALETTE(config, m_palette).set_entries(16);
- MCFG_VIDEO_START_OVERRIDE(hec2hrp_state,hec2hrp)
-
- hector_audio(config);
-
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_PLAY | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED);
+ROM_START( interact )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
+ ROM_LOAD( "interact.rom", 0x0000, 0x0800, CRC(1aa50444) SHA1(405806c97378abcf7c7b0d549430c78c7fc60ba2))
+ // cartridge space 0800-0FFF, first byte must be 00.
+ROM_END
- PRINTER(config, m_printer, 0);
-}
+ROM_START( hector1 )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
+ ROM_LOAD( "hector1.rom", 0x0000, 0x1000, CRC(3be6628b) SHA1(1c106d6732bed743d8283d39e5b8248271f18c42))
+ROM_END
ROM_START( hec2hr )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "2hr.bin", 0x0000, 0x1000, CRC(84b9e672) SHA1(8c8b089166122eee565addaed10f84c5ce6d849b))
+ // option roms
ROM_REGION( 0x4000, "page1", ROMREGION_ERASEFF )
ROM_REGION( 0x4000, "page2", ROMREGION_ERASEFF )
ROM_END
ROM_START( victor )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "victor.rom", 0x0000, 0x1000, CRC(d1e9508f) SHA1(d0f1bdcd39917fafc8859223ab38eee2a7dc85ff))
+ // option roms
ROM_REGION( 0x4000, "page1", ROMREGION_ERASEFF )
ROM_REGION( 0x4000, "page2", ROMREGION_ERASEFF )
ROM_END
ROM_START( hec2hrp )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "hector2hrp.rom", 0x0000, 0x4000, CRC(983f52e4) SHA1(71695941d689827356042ee52ffe55ce7e6b8ecd))
+ // option roms
ROM_REGION( 0x4000, "page1", ROMREGION_ERASEFF )
ROM_REGION( 0x4000, "page2", ROMREGION_ERASEFF )
- ROM_REGION( 0x10000, "disc2cpu", ROMREGION_ERASEFF )
+ // 2nd cpu
ROM_REGION( 0x04000, "rom_disc2", ROMREGION_ERASEFF )
ROM_END
ROM_START( hec2hrx )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "hector2hrx.rom", 0x0000, 0x4000, CRC(f047c521) SHA1(744336b2acc76acd7c245b562bdc96dca155b066))
+ // option roms
ROM_REGION( 0x4000, "page1", ROMREGION_ERASEFF )
ROM_REGION( 0x4000, "page2", ROMREGION_ERASEFF )
- ROM_REGION( 0x10000, "disc2cpu", ROMREGION_ERASEFF )
-
+ // 2nd cpu
ROM_REGION( 0x04000, "rom_disc2", ROMREGION_ERASEFF )
ROM_LOAD( "d800k.bin" , 0x0000,0x1000, CRC(831bd584) SHA1(9782ee58f570042608d9d568b2c3fc4c6d87d8b9))
- ROM_REGION( 0x10000, "disc2mem", ROMREGION_ERASE00 )
ROM_END
// minidisc
ROM_START( hec2mdhrx )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "mdic1.bin" , 0x0000,0x2000, CRC(ddda1065) SHA1(e7bba14a72605238d2f8299da029b8320a563254))
ROM_LOAD( "mdicmb.bin" , 0x2000,0x2000, CRC(d8090747) SHA1(f2925b68002307562e2ea5e36b740e5458f0f0eb))
@@ -665,40 +595,42 @@ ROM_START( hec2mdhrx )
ROM_END
ROM_START( hec2mx80 )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "mx80c_page0.rom" , 0x0000,0x4000, CRC(a75945cf) SHA1(542391e482271be0997b069cf13c8b5dae28feec))
+ // option roms
ROM_REGION( 0x4000, "page1", ROMREGION_ERASEFF )
ROM_LOAD( "mx80c_page1.rom", 0x0000, 0x4000, CRC(4615f57c) SHA1(5de291bf3ae0320915133b99f1a088cb56c41658))
ROM_REGION( 0x4000, "page2", ROMREGION_ERASEFF )
ROM_LOAD( "mx80c_page2.rom" , 0x0000,0x4000, CRC(2d5d975e) SHA1(48307132e0f3fad0262859bb8142d108f694a436))
-
+ // 2nd cpu
ROM_REGION( 0x04000, "rom_disc2", ROMREGION_ERASEFF )
ROM_LOAD( "d800k.bin" , 0x0000,0x1000, CRC(831bd584) SHA1(9782ee58f570042608d9d568b2c3fc4c6d87d8b9))
- ROM_REGION( 0x10000, "disc2mem", ROMREGION_ERASE00 )
ROM_END
ROM_START( hec2mx40 )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
+ ROM_REGION( 0x4000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "mx40c_page0.rom" , 0x0000,0x4000, CRC(9bb5566d) SHA1(0c8c2e396ec8eb995d2b621abe06b6968ca5d0aa))
+ // option roms
ROM_REGION( 0x4000, "page1", ROMREGION_ERASEFF )
ROM_LOAD( "mx40c_page1.rom", 0x0000, 0x4000, CRC(192a76fa) SHA1(062aa6df0b554b85774d4b5edeea8496a4baca35))
ROM_REGION( 0x4000, "page2", ROMREGION_ERASEFF )
ROM_LOAD( "mx40c_page2.rom" , 0x0000,0x4000, CRC(ef1b2654) SHA1(66624ea040cb7ede4720ad2eca0738d0d3bad89a))
-
+ // 2nd cpu
ROM_REGION( 0x04000, "rom_disc2", ROMREGION_ERASEFF )
// ROM_LOAD( "d360k.bin" , 0x0000,0x4000, CRC(2454eacb) SHA1(dc0d5a7d5891a7e422d9d142a2419527bb15dfd5))
ROM_LOAD( "d800k.bin" , 0x0000,0x1000, CRC(831bd584) SHA1(9782ee58f570042608d9d568b2c3fc4c6d87d8b9))
// ROM_LOAD( "d200k.bin" , 0x0000,0x4000, CRC(e2801377) SHA1(0926df5b417ecd8013e35c71b76780c5a25c1cbf))
- ROM_REGION( 0x10000, "disc2mem", ROMREGION_ERASE00 )
ROM_END
/* Driver */
-/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
-COMP(1983, hec2hrp, 0, interact, hec2hrp, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Hector 2HR+", MACHINE_IMPERFECT_SOUND)
-COMP(1980, victor, hec2hrp, 0, hec2hrp, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Victor", MACHINE_IMPERFECT_SOUND)
-COMP(1983, hec2hr, hec2hrp, 0, hec2hr, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Hector 2HR", MACHINE_IMPERFECT_SOUND)
-COMP(1984, hec2hrx, hec2hrp, 0, hec2hrx, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Hector HRX + Disc2", MACHINE_IMPERFECT_SOUND)
-COMP(1985, hec2mdhrx, hec2hrp, 0, hec2mdhrx, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Hector HRX + mini Disc", MACHINE_IMPERFECT_SOUND)
-COMP(1985, hec2mx80, hec2hrp, 0, hec2mx80, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Hector MX 80c + Disc2", MACHINE_IMPERFECT_SOUND)
-COMP(1985, hec2mx40, hec2hrp, 0, hec2mx40, hec2hrp, hec2hrp_state, empty_init, "Micronique", "Hector MX 40c + Disc2", MACHINE_IMPERFECT_SOUND)
+/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
+COMP(1979, interact, 0, 0, interact, hec2hrp, hec2hrp_state, init_interact, "Interact Electronics", "Interact Family Computer", MACHINE_IMPERFECT_SOUND)
+COMP(1983, hector1, interact, 0, hector1, hec2hrp, hec2hrp_state, init_interact, "Micronique", "Hector 1", MACHINE_IMPERFECT_SOUND)
+COMP(1983, hec2hrp, 0, interact, hec2hr, hec2hrp, hec2hrp_state, init_interact, "Micronique", "Hector 2HR+", MACHINE_IMPERFECT_SOUND)
+COMP(1980, victor, hec2hrp, 0, hec2hr, hec2hrp, hec2hrp_state, init_victor, "Micronique", "Victor", MACHINE_IMPERFECT_SOUND)
+COMP(1983, hec2hr, hec2hrp, 0, hec2hr, hec2hrp, hec2hrp_state, init_victor, "Micronique", "Hector 2HR", MACHINE_IMPERFECT_SOUND)
+COMP(1984, hec2hrx, hec2hrp, 0, hec2hrx, hec2hrp, hec2hrp_state, init_hrx, "Micronique", "Hector HRX + Disc2", MACHINE_IMPERFECT_SOUND)
+COMP(1985, hec2mdhrx, hec2hrp, 0, hec2mdhrx, hec2hrp, hec2hrp_state, init_mdhrx, "Micronique", "Hector HRX + mini Disc", MACHINE_IMPERFECT_SOUND)
+COMP(1985, hec2mx80, hec2hrp, 0, hec2mx80, hec2hrp, hec2hrp_state, init_mx40, "Micronique", "Hector MX 80c + Disc2", MACHINE_IMPERFECT_SOUND)
+COMP(1985, hec2mx40, hec2hrp, 0, hec2mx40, hec2hrp, hec2hrp_state, init_mx40, "Micronique", "Hector MX 40c + Disc2", MACHINE_IMPERFECT_SOUND)
diff --git a/src/mame/drivers/hp_ipc.cpp b/src/mame/drivers/hp_ipc.cpp
index 0dbbccbc3a2..3b14722a88a 100644
--- a/src/mame/drivers/hp_ipc.cpp
+++ b/src/mame/drivers/hp_ipc.cpp
@@ -373,6 +373,8 @@ Software to look for
#include "speaker.h"
#include "sound/dac.h"
#include "sound/volt_reg.h"
+#include "machine/input_merger.h"
+#include "bus/hp_ipc_io/hp_ipc_io.h"
#include "emupal.h"
#include "screen.h"
@@ -391,6 +393,12 @@ public:
, m_screen(*this, "screen")
, m_spkr(*this , "spkr")
, m_dac(*this , "dac")
+ , m_irq3_merger(*this , "merge_irq3")
+ , m_irq4_merger(*this , "merge_irq4")
+ , m_irq5_merger(*this , "merge_irq5")
+ , m_irq6_merger(*this , "merge_irq6")
+ , m_io_slot_a(*this , "slot_a")
+ , m_io_slot_b(*this , "slot_b")
{ }
void hp_ipc_base(machine_config &config);
@@ -439,6 +447,12 @@ private:
required_device<screen_device> m_screen;
required_device<cop452_device> m_spkr;
required_device<dac_1bit_device> m_dac;
+ required_device<input_merger_any_high_device> m_irq3_merger;
+ required_device<input_merger_any_high_device> m_irq4_merger;
+ required_device<input_merger_any_high_device> m_irq5_merger;
+ required_device<input_merger_any_high_device> m_irq6_merger;
+ required_device<hp_ipc_io_slot_device> m_io_slot_a;
+ required_device<hp_ipc_io_slot_device> m_io_slot_b;
uint32_t m_mmu[4], m_lowest_ram_addr;
uint16_t *m_internal_ram;
@@ -688,22 +702,22 @@ WRITE_LINE_MEMBER(hp_ipc_state::irq_2)
WRITE_LINE_MEMBER(hp_ipc_state::irq_3)
{
- m_maincpu->set_input_line(M68K_IRQ_3, state);
+ m_irq3_merger->in_w<0>(state);
}
WRITE_LINE_MEMBER(hp_ipc_state::irq_4)
{
- m_maincpu->set_input_line(M68K_IRQ_4, state);
+ m_irq4_merger->in_w<0>(state);
}
WRITE_LINE_MEMBER(hp_ipc_state::irq_5)
{
- m_maincpu->set_input_line(M68K_IRQ_5, state);
+ m_irq5_merger->in_w<0>(state);
}
WRITE_LINE_MEMBER(hp_ipc_state::irq_6)
{
- m_maincpu->set_input_line(M68K_IRQ_6, state);
+ m_irq6_merger->in_w<0>(state);
}
WRITE_LINE_MEMBER(hp_ipc_state::irq_7)
@@ -720,6 +734,9 @@ void hp_ipc_state::machine_start()
m_lowest_ram_addr = 0x3c0000 - (m_ram->size() >> 1);
m_internal_ram = (uint16_t *)m_ram->pointer();
+
+ m_io_slot_a->install_read_write_handlers(m_bankdev->space());
+ m_io_slot_b->install_read_write_handlers(m_bankdev->space());
}
void hp_ipc_state::machine_reset()
@@ -809,6 +826,24 @@ void hp_ipc_state::hp_ipc_base(machine_config &config)
vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT);
m_spkr->oa_w().set(m_dac , FUNC(dac_1bit_device::write));
+ // IO slots
+ HP_IPC_IO_SLOT(config , m_io_slot_a).set_slot_idx(0);
+ HP_IPC_IO_SLOT(config , m_io_slot_b).set_slot_idx(1);
+
+ // IRQ3/4/5/6 mergers
+ INPUT_MERGER_ANY_HIGH(config , m_irq3_merger).output_handler().set_inputline(m_maincpu , M68K_IRQ_3);
+ INPUT_MERGER_ANY_HIGH(config , m_irq4_merger).output_handler().set_inputline(m_maincpu , M68K_IRQ_4);
+ INPUT_MERGER_ANY_HIGH(config , m_irq5_merger).output_handler().set_inputline(m_maincpu , M68K_IRQ_5);
+ INPUT_MERGER_ANY_HIGH(config , m_irq6_merger).output_handler().set_inputline(m_maincpu , M68K_IRQ_6);
+ m_io_slot_a->irq3_cb().set(m_irq3_merger , FUNC(input_merger_any_high_device::in_w<1>));
+ m_io_slot_a->irq4_cb().set(m_irq4_merger , FUNC(input_merger_any_high_device::in_w<1>));
+ m_io_slot_a->irq5_cb().set(m_irq5_merger , FUNC(input_merger_any_high_device::in_w<1>));
+ m_io_slot_a->irq6_cb().set(m_irq6_merger , FUNC(input_merger_any_high_device::in_w<1>));
+ m_io_slot_b->irq3_cb().set(m_irq3_merger , FUNC(input_merger_any_high_device::in_w<2>));
+ m_io_slot_b->irq4_cb().set(m_irq4_merger , FUNC(input_merger_any_high_device::in_w<2>));
+ m_io_slot_b->irq5_cb().set(m_irq5_merger , FUNC(input_merger_any_high_device::in_w<2>));
+ m_io_slot_b->irq6_cb().set(m_irq6_merger , FUNC(input_merger_any_high_device::in_w<2>));
+
RAM(config, RAM_TAG).set_default_size("512K").set_extra_options("768K,1M,1576K,2M,3M,4M,5M,6M,7M,7680K");
}
diff --git a/src/mame/drivers/interact.cpp b/src/mame/drivers/interact.cpp
deleted file mode 100644
index 7fd448941c5..00000000000
--- a/src/mame/drivers/interact.cpp
+++ /dev/null
@@ -1,305 +0,0 @@
-// license:BSD-3-Clause
-// copyright-holders:JJ Stacino
-/***************************************************************************
-
- Interact Family Computer
-
- 12/05/2009 Skeleton driver - Micko
- 31/05/2009 Added notes - Robbbert
-
- This was made by Interact Company of Ann Arbor, Michigan. However,
- just after launch, the company collapsed. The liquidator, Protecto,
- sold some and MicroVideo sold the rest. MicroVideo continued to
- develop but went under 2 years later. Meanwhile, the French company
- Lambda Systems sold a clone called the Victor Lambda. But, like the
- Americans, Lambda Systems also collapsed. Another French company,
- Micronique, purchased all remaining stock and intellectual rights
- from Lambda Systems, Microvideo and Interact, and the computer becomes
- wholly French. The computer has a name change, becoming the Hector.
- This in turn gets upgraded (2HR, HRX, MX). The line is finally
- retired in about 1985.
-
- Hector 2HR+
- Victor
- Hector 2HR
- Hector HRX
- Hector MX40c
- Hector MX80c
- Hector 1
- Interact
-
- 12/05/2009 Skeleton driver - Micko : mmicko@gmail.com
- 31/06/2009 Video - Robbbert
-
- 29/10/2009 Update skeleton to functional machine
- by yo_fr (jj.stac @ aliceadsl.fr)
-
- => add Keyboard,
- => add color,
- => add cassette,
- => add sn76477 sound and 1bit sound,
- => add joysticks (stick, pot, fire)
- => add BR/HR switching
- => add bank switch for HRX
- => add device MX80c and bank switching for the ROM
- Importante note : the keyboard function add been piked from
- DChector project : http://dchector.free.fr/ made by DanielCoulom
- (thank's Daniel)
- TODO : Add the cartridge function,
- Adjust the one shot and A/D timing (sn76477)
-****************************************************************************/
-/* Mapping for joystick see hec2hrp.c*/
-
-#include "emu.h"
-#include "includes/hec2hrp.h"
-
-#include "cpu/i8085/i8085.h"
-#include "cpu/z80/z80.h"
-#include "formats/hect_tap.h"
-#include "imagedev/cassette.h"
-#include "imagedev/printer.h"
-#include "machine/upd765.h" /* for floppy disc controller */
-#include "sound/discrete.h" /* for 1 Bit sound*/
-#include "screen.h"
-#include "softlist.h"
-
-
-class interact_state : public hec2hrp_state
-{
-public:
- interact_state(const machine_config &mconfig, device_type type, const char *tag)
- : hec2hrp_state(mconfig, type, tag),
- m_videoram(*this, "videoram") { }
-
- void hector1(machine_config &config);
- void interact(machine_config &config);
-
-private:
-
- required_shared_ptr<uint8_t> m_videoram;
- DECLARE_MACHINE_START(interact);
- DECLARE_MACHINE_RESET(interact);
- uint32_t screen_update_interact(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
- void interact_mem(address_map &map);
-};
-
-
-void interact_state::interact_mem(address_map &map)
-{
- map.unmap_value_high();
- /* Main ROM page*/
- map(0x0000, 0x3fff).rom(); /*BANK(2)*/
-// map(0x1000,0x3fff).ram();
-
- /* Hardware address mapping*/
-// map(0x0800,0x0808).w(FUNC(interact_state::switch_bank_w)); // Bank management not udsed in BR machine*/
- map(0x1000, 0x1000).w(FUNC(interact_state::color_a_w)); /* Color c0/c1*/
- map(0x1800, 0x1800).w(FUNC(interact_state::color_b_w)); /* Color c2/c3*/
- map(0x2000, 0x2003).w(FUNC(interact_state::sn_2000_w)); /* Sound*/
- map(0x2800, 0x2803).w(FUNC(interact_state::sn_2800_w)); /* Sound*/
- map(0x3000, 0x3000).rw(FUNC(interact_state::cassette_r), FUNC(interact_state::sn_3000_w));/* Write necessary*/
- map(0x3800, 0x3807).rw(FUNC(interact_state::keyboard_r), FUNC(interact_state::keyboard_w)); /* Keyboard*/
-
- /* Video br mapping*/
- map(0x4000, 0x49ff).ram().share("videoram");
- /* continous RAM*/
- map(0x4A00, 0xffff).ram();
-
-}
-
-
-MACHINE_RESET_MEMBER(interact_state,interact)
-{
- hector_reset(0, 0);
-}
-
-MACHINE_START_MEMBER(interact_state,interact)
-{
- hector_init();
-}
-
-uint32_t interact_state::screen_update_interact(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
-{
- uint8_t *videoram = m_videoram;
- screen.set_visible_area(0, 113, 0, 75);
- hector_hr(bitmap, videoram, 77, 32);
- return 0;
-}
-
-void interact_state::interact(machine_config &config)
-{
- /* basic machine hardware */
- I8080(config, m_maincpu, XTAL(2'000'000));
- m_maincpu->set_addrmap(AS_PROGRAM, &interact_state::interact_mem);
- m_maincpu->set_periodic_int(FUNC(interact_state::irq0_line_hold), attotime::from_hz(50)); /* put on the I8080 irq in Hz*/
-
- MCFG_MACHINE_RESET_OVERRIDE(interact_state,interact)
- MCFG_MACHINE_START_OVERRIDE(interact_state,interact)
-
- /* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(60);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
- screen.set_size(256, 79);
- screen.set_visarea(0, 112, 0, 77);
- screen.set_screen_update(FUNC(interact_state::screen_update_interact));
- screen.set_palette(m_palette);
-
- PALETTE(config, m_palette).set_entries(16); /* 8 colours, but only 4 at a time*/
-
- MCFG_VIDEO_START_OVERRIDE(interact_state,hec2hrp)
-
- hector_audio(config);
-
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_STOPPED | CASSETTE_SPEAKER_ENABLED);
- m_cassette->set_interface("interact_cass");
-
- SOFTWARE_LIST(config, "cass_list").set_original("interact");
-
- /* printer */
- PRINTER(config, m_printer, 0);
-}
-
-void interact_state::hector1(machine_config &config)
-{
- /* basic machine hardware */
- Z80(config, m_maincpu, XTAL(1'750'000));
- m_maincpu->set_addrmap(AS_PROGRAM, &interact_state::interact_mem);
- m_maincpu->set_periodic_int(FUNC(interact_state::irq0_line_hold), attotime::from_hz(50)); /* put on the I8080 irq in Hz*/
-
- MCFG_MACHINE_RESET_OVERRIDE(interact_state,interact)
- MCFG_MACHINE_START_OVERRIDE(interact_state,interact)
-
- /* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(60);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
- screen.set_size(256, 79);
- screen.set_visarea(0, 112, 0, 77);
- screen.set_screen_update(FUNC(interact_state::screen_update_interact));
- screen.set_palette(m_palette);
-
- PALETTE(config, m_palette).set_entries(16); /* 8 colours, but only 4 at a time*/
-
- MCFG_VIDEO_START_OVERRIDE(interact_state,hec2hrp)
-
- hector_audio(config);
-
- CASSETTE(config, m_cassette);
- m_cassette->set_formats(hector_cassette_formats);
- m_cassette->set_default_state(CASSETTE_STOPPED | CASSETTE_SPEAKER_ENABLED);
- m_cassette->set_interface("interact_cass");
-
- /* printer */
- PRINTER(config, m_printer, 0);
-}
-
-/* Input ports */
-static INPUT_PORTS_START( interact )
- /* keyboard input */
- PORT_START("KEY.0") /* [0] - port 3000 @ 0 */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR('\\') PORT_CHAR('|')
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Space") PORT_CODE(KEYCODE_SPACE)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Return") PORT_CODE(KEYCODE_ENTER) PORT_CHAR(13)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Tab") PORT_CODE(KEYCODE_TAB)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("<--") PORT_CODE(KEYCODE_BACKSPACE)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Caps Lock") PORT_CODE(KEYCODE_CAPSLOCK)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Ctrl") PORT_CODE(KEYCODE_LCONTROL) PORT_CHAR(UCHAR_MAMEKEY(LCONTROL))
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Shift") PORT_CODE(KEYCODE_LSHIFT) PORT_CODE(KEYCODE_RSHIFT) PORT_CHAR(UCHAR_SHIFT_1)
- PORT_START("KEY.1") /* [1] - port 3000 @ 1 */ /* touches => 2 1 0 / . - , + */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("2 \"") PORT_CODE(KEYCODE_2) PORT_CHAR('2')
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1 >") PORT_CODE(KEYCODE_1) PORT_CHAR('1')
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("0 <") PORT_CODE(KEYCODE_0) PORT_CHAR('0')
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_STOP) PORT_CHAR('.') PORT_CHAR('>')
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_COMMA) PORT_CHAR(',') PORT_CHAR('<')
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-') PORT_CHAR('_')
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_M)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_EQUALS) PORT_CHAR('=') PORT_CHAR('+')
-
- PORT_START("KEY.2") /* [1] - port 3000 @ 2 */ /* touches => .. 9 8 7 6 5 4 3 */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_UNUSED)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9 )") PORT_CODE(KEYCODE_9) PORT_CHAR('9')
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8 (") PORT_CODE(KEYCODE_8) PORT_CHAR('8')
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7 :") PORT_CODE(KEYCODE_7) PORT_CHAR('7')
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6 !") PORT_CODE(KEYCODE_6) PORT_CHAR('6')
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5 %") PORT_CODE(KEYCODE_5) PORT_CHAR('5')
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("4 $") PORT_CODE(KEYCODE_4) PORT_CHAR('4')
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("3 /") PORT_CODE(KEYCODE_3) PORT_CHAR('3')
- PORT_START("KEY.3") /* [1] - port 3000 @ 3 */ /* touches => B A .. ? .. = .. ; */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_B) PORT_CHAR('B')
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A") PORT_CODE(KEYCODE_Q) PORT_CHAR('Q')
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_UNUSED)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_OPENBRACE) PORT_CHAR('[') PORT_CHAR('{')
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_UNUSED)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_CLOSEBRACE) PORT_CHAR(']') PORT_CHAR('}')
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_UNUSED)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_SLASH) PORT_CHAR('/') PORT_CHAR('?')
- PORT_START("KEY.4") /* [1] - port 3000 @ 4 */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_J) PORT_CHAR('J')
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_I) PORT_CHAR('I')
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_H) PORT_CHAR('H')
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_G) PORT_CHAR('G')
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_F) PORT_CHAR('F')
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_E) PORT_CHAR('E')
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_C) PORT_CHAR('C')
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_D) PORT_CHAR('D')
-
- PORT_START("KEY.5") /* [1] - port 3000 @ 5 */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_R) PORT_CHAR('R')
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Q") PORT_CODE(KEYCODE_A) PORT_CHAR('A')
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_P) PORT_CHAR('P')
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_O) PORT_CHAR('O')
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_N) PORT_CHAR('N')
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_COLON)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_L) PORT_CHAR('L')
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_K) PORT_CHAR('K')
-
- PORT_START("KEY.6") /* [1] - port 3000 @ 6 */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Z") PORT_CODE(KEYCODE_W) PORT_CHAR('W')
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_Y) PORT_CHAR('Y')
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("X") PORT_CODE(KEYCODE_X) PORT_CHAR('X')
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("W") PORT_CODE(KEYCODE_Z) PORT_CHAR('Z')
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_V) PORT_CHAR('V')
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_U) PORT_CHAR('U')
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_T) PORT_CHAR('T')
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CODE(KEYCODE_S) PORT_CHAR('S')
-
- PORT_START("KEY.7") /* [1] - port 3000 @ 7 JOYSTICK */
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(0) LEFT") PORT_CODE(KEYCODE_LEFT) PORT_CHAR(UCHAR_MAMEKEY(LEFT))
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(0) RIGHT") PORT_CODE(KEYCODE_RIGHT) PORT_CHAR(UCHAR_MAMEKEY(RIGHT))
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(0) UP") PORT_CODE(KEYCODE_UP) PORT_CHAR(UCHAR_MAMEKEY(UP))
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(0) DOWN") PORT_CODE(KEYCODE_DOWN) PORT_CHAR(UCHAR_MAMEKEY(DOWN))
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(1) LEFT") PORT_CODE(KEYCODE_1_PAD) /* Joy(1) on numpad*/
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(1) RIGHT") PORT_CODE(KEYCODE_3_PAD)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(1) UP") PORT_CODE(KEYCODE_5_PAD)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(1) DOWN") PORT_CODE(KEYCODE_2_PAD)
-
- PORT_START("KEY.8") /* [1] - port 3000 @ 8 not for the real machine, but to emulate the analog signal of the joystick */
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("RESET") PORT_CODE(KEYCODE_ESC) PORT_CHAR(27)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(0) FIRE") PORT_CODE(KEYCODE_0_PAD)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Joy(1) FIRE") PORT_CODE(KEYCODE_PLUS_PAD)
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_NAME("Pot(0)+") PORT_CODE(KEYCODE_INSERT)
- PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_NAME("Pot(0)-") PORT_CODE(KEYCODE_DEL)
- PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_NAME("Pot(1)+") PORT_CODE(KEYCODE_HOME) PORT_CHAR(UCHAR_MAMEKEY(HOME))
- PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_NAME("Pot(1)-") PORT_CODE(KEYCODE_END) PORT_CHAR(UCHAR_MAMEKEY(END))
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_UNUSED)
-INPUT_PORTS_END
-
-/* ROM definition */
-ROM_START( interact )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
- ROM_LOAD( "interact.rom", 0x0000, 0x0800, CRC(1aa50444) SHA1(405806c97378abcf7c7b0d549430c78c7fc60ba2))
-ROM_END
-
-ROM_START( hector1 )
- ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASEFF )
- ROM_LOAD( "hector1.rom", 0x0000, 0x1000, CRC(3be6628b) SHA1(1c106d6732bed743d8283d39e5b8248271f18c42))
-ROM_END
-
-/* Driver */
-
-/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
-COMP(1979, interact, 0, 0, interact, interact, interact_state, empty_init, "Interact", "Interact Family Computer", MACHINE_IMPERFECT_SOUND)
-COMP(1983, hector1, interact, 0, hector1, interact, interact_state, empty_init, "Micronique", "Hector 1", MACHINE_IMPERFECT_SOUND)
diff --git a/src/mame/drivers/itech8.cpp b/src/mame/drivers/itech8.cpp
index 36907d4a467..d443900b88d 100644
--- a/src/mame/drivers/itech8.cpp
+++ b/src/mame/drivers/itech8.cpp
@@ -2742,7 +2742,7 @@ void itech8_state::init_neckneck()
/* Wheel of Fortune-style PCB */
GAME( 1989, wfortune, 0, wfortune, wfortune, itech8_state, empty_init, ROT0, "GameTek", "Wheel Of Fortune (set 1)", 0 )
-GAME( 1989, wfortunea, wfortune, wfortune, wfortune, itech8_state, empty_init, ROT0, "GameTek", "Wheel Of Fortune (set 2)", 0 ) /* prgram ROM label states "R1" */
+GAME( 1989, wfortunea, wfortune, wfortune, wfortune, itech8_state, empty_init, ROT0, "GameTek", "Wheel Of Fortune (set 2)", 0 ) /* program ROM label states "R1" */
/* Grudge Match-style PCB */
GAME( 1989, grmatch, 0, grmatch, grmatch, grmatch_state, empty_init, ROT0, "Yankee Game Technology", "Grudge Match (Yankee Game Technology)", 0 )
diff --git a/src/mame/drivers/jaguar.cpp b/src/mame/drivers/jaguar.cpp
index 5bc216440b2..7cf28b0fa99 100644
--- a/src/mame/drivers/jaguar.cpp
+++ b/src/mame/drivers/jaguar.cpp
@@ -2114,10 +2114,10 @@ ROM_END
ROM_START( area51 ) /* R3000 based, Area51 Atari Games License - MAIN: Oct 24 1996 12:02:23 / GUTS: 2.06CJ Nov 11 1996 11:46:43 */
ROM_REGION( 0x200000, "maincpu", 0 ) /* 2MB for IDT 79R3041 code */
- ROM_LOAD32_BYTE( "2-c_area_51_hh.hh", 0x00000, 0x80000, CRC(13af6a1e) SHA1(69da54ed6886e825156bbcc256e8d7abd4dc1ff8) ) /* Grean labels: 2-C AREA 51 HH */
- ROM_LOAD32_BYTE( "2-c_area_51_hl.hl", 0x00001, 0x80000, CRC(8ab6649b) SHA1(9b4945bc04f8a73161638a2c5fa2fd84c6fd31b4) ) /* Grean labels: 2-C AREA 51 HL */
- ROM_LOAD32_BYTE( "2-c_area_51_lh.lh", 0x00002, 0x80000, CRC(a6524f73) SHA1(ae377a6803a4f7d1bbcc111725af121a3e82317d) ) /* Grean labels: 2-C AREA 51 LH */
- ROM_LOAD32_BYTE( "2-c_area_51_ll.ll", 0x00003, 0x80000, CRC(471b15d2) SHA1(4b5f45ee140b03a6be61475cae1c2dbef0f07457) ) /* Grean labels: 2-C AREA 51 LL */
+ ROM_LOAD32_BYTE( "2-c_area_51_hh.hh", 0x00000, 0x80000, CRC(13af6a1e) SHA1(69da54ed6886e825156bbcc256e8d7abd4dc1ff8) ) /* Green labels: 2-C AREA 51 HH */
+ ROM_LOAD32_BYTE( "2-c_area_51_hl.hl", 0x00001, 0x80000, CRC(8ab6649b) SHA1(9b4945bc04f8a73161638a2c5fa2fd84c6fd31b4) ) /* Green labels: 2-C AREA 51 HL */
+ ROM_LOAD32_BYTE( "2-c_area_51_lh.lh", 0x00002, 0x80000, CRC(a6524f73) SHA1(ae377a6803a4f7d1bbcc111725af121a3e82317d) ) /* Green labels: 2-C AREA 51 LH */
+ ROM_LOAD32_BYTE( "2-c_area_51_ll.ll", 0x00003, 0x80000, CRC(471b15d2) SHA1(4b5f45ee140b03a6be61475cae1c2dbef0f07457) ) /* Green labels: 2-C AREA 51 LL */
ROM_REGION16_BE( 0x1000, "waverom", 0 )
ROM_LOAD16_WORD("jagwave.rom", 0x0000, 0x1000, CRC(7a25ee5b) SHA1(58117e11fd6478c521fbd3fdbe157f39567552f0) )
diff --git a/src/mame/drivers/kc.cpp b/src/mame/drivers/kc.cpp
index 9161059bc31..fb91275d0f6 100644
--- a/src/mame/drivers/kc.cpp
+++ b/src/mame/drivers/kc.cpp
@@ -2,7 +2,7 @@
// copyright-holders:Kevin Thacker,Sandro Ronco
/******************************************************************************
- kc.c
+ kc.cpp
system driver
A big thankyou to Torsten Paul for his great help with this
@@ -11,7 +11,7 @@
Kevin Thacker [MESS driver]
- ******************************************************************************/
+******************************************************************************/
/* Core includes */
#include "emu.h"
@@ -292,7 +292,7 @@ ROM_START(kc85_5)
ROM_END
// YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY, FULLNAME, FLAGS
-COMP( 1987, kc85_2, 0, 0, kc85_3, kc85, kc_state, empty_init, "VEB Mikroelektronik \"Wilhelm Pieck\" Muehlhausen", "HC900 / KC 85/2", MACHINE_NOT_WORKING)
-COMP( 1987, kc85_3, kc85_2, 0, kc85_3, kc85, kc_state, empty_init, "VEB Mikroelektronik \"Wilhelm Pieck\" Muehlhausen", "KC 85/3", MACHINE_NOT_WORKING)
-COMP( 1989, kc85_4, kc85_2, 0, kc85_4, kc85, kc85_4_state, empty_init, "VEB Mikroelektronik \"Wilhelm Pieck\" Muehlhausen", "KC 85/4", MACHINE_NOT_WORKING)
-COMP( 1989, kc85_5, kc85_2, 0, kc85_5, kc85, kc85_4_state, empty_init, "VEB Mikroelektronik \"Wilhelm Pieck\" Muehlhausen", "KC 85/5", MACHINE_NOT_WORKING)
+COMP( 1987, kc85_2, 0, 0, kc85_3, kc85, kc_state, empty_init, u8"VEB Mikroelektronik \"Wilhelm Pieck\" Mühlhausen", "HC900 / KC 85/2", MACHINE_NOT_WORKING)
+COMP( 1987, kc85_3, kc85_2, 0, kc85_3, kc85, kc_state, empty_init, u8"VEB Mikroelektronik \"Wilhelm Pieck\" Mühlhausen", "KC 85/3", MACHINE_NOT_WORKING)
+COMP( 1989, kc85_4, kc85_2, 0, kc85_4, kc85, kc85_4_state, empty_init, u8"VEB Mikroelektronik \"Wilhelm Pieck\" Mühlhausen", "KC 85/4", MACHINE_NOT_WORKING)
+COMP( 1989, kc85_5, kc85_2, 0, kc85_5, kc85, kc85_4_state, empty_init, u8"VEB Mikroelektronik \"Wilhelm Pieck\" Mühlhausen", "KC 85/5", MACHINE_NOT_WORKING)
diff --git a/src/mame/drivers/lucky37.cpp b/src/mame/drivers/lucky37.cpp
index 56e2ac9f22c..fe0ad771fb6 100644
--- a/src/mame/drivers/lucky37.cpp
+++ b/src/mame/drivers/lucky37.cpp
@@ -32,6 +32,21 @@
A001: marked B 9G1. Sticker: 8907 1991.03 L-21-D BET/WON
MCU: Sticker: 8907 1990.10 L21-D M.COM
+
+ Bingo 75:
+ A001: marks can't be seen. Sticker: WE8802-A 1989.2
+ PCB marked: Wing 8802-C
+
+ 1x scratched DIL40 (@ location 3r)
+ 1x 89206A 61H09516P (@ location 7s)
+ 1x 101B10P (@ location 7p)
+ 2x 06B53P (@ locations 1d & 2d)
+ 1x 06B49P (@ location 2b)
+
+ 1x 12 MHz Xtal (@ location 3t)
+ 5x 8 DIP switches banks (@ locations 5l, 5m, 5n, 5p & 5r)
+
+
Not much can be done until main CPU ROMs are dumped.
*/
@@ -211,7 +226,32 @@ ROM_START( lucky37 )
ROM_LOAD( "6.bin", 0xa0000, 0x20000, CRC(3283c1b7) SHA1(7a30dd55216b47332ea7c18c2378352f405b2f0a) )
ROM_END
+ROM_START( bingo75 ) // runs on wing 8802-c board
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "a001-nomarks", 0x0000, 0x10000, NO_DUMP )
+
+ ROM_REGION( 0x4000, "mcu", 0 )
+ ROM_LOAD( "internal_rom", 0x0000, 0x4000, NO_DUMP )
+
+ ROM_REGION( 0x40000, "unsorted", 0 )
+ ROM_LOAD( "6.bin", 0x00000, 0x10000, CRC(bda18251) SHA1(7e9ddea30bbedcc9f4b48a2ca2660505ed45ca8d) )
+ ROM_LOAD( "7.bin", 0x10000, 0x10000, CRC(1316d78b) SHA1(9f7a7c5407642d2aad6765d3fb00c7fb5bd08561) )
+ ROM_LOAD( "8.bin", 0x20000, 0x10000, CRC(6a3ce8f1) SHA1(48d3a1d3c1739200c10599ec9451683ba60487eb) )
+ ROM_LOAD( "9.bin", 0x30000, 0x10000, CRC(325169c5) SHA1(00f3fa44c8bda7fd4a9e7855b5681f254ab6de84) )
+
+ ROM_REGION( 0x0700, "proms", 0 )
+ ROM_LOAD( "27s21.4h", 0x0000, 0x0100, CRC(21ae1edd) SHA1(df6204f30412b5c1835146127f45956bc986b182) )
+ ROM_LOAD( "27s21.4j", 0x0100, 0x0100, CRC(a6c2ed16) SHA1(e472bebdc982239ebef5ebe361fb07e6469fc5ed) )
+ ROM_LOAD( "27s21.5h", 0x0200, 0x0100, CRC(a5b1dd09) SHA1(0af6eacc09742f35d2703ba011df20f582ce676a) )
+ ROM_LOAD( "27s21.5j", 0x0300, 0x0100, CRC(0d985358) SHA1(ceb32eb6fd1804febdd1766f8590ae0db1b03faa) )
+ ROM_LOAD( "27s21.5k", 0x0400, 0x0100, CRC(40e880c0) SHA1(74eafbf9506651991b66b6264664325204f61227) )
+ ROM_LOAD( "82s129.4k", 0x0500, 0x0100, CRC(0a9e160d) SHA1(d2377850aa344b027a974ef116bb1aee852d61d8) )
+ ROM_LOAD( "82s129.5f", 0x0600, 0x0100, CRC(83c3ec8f) SHA1(4a6452ef73061a446e6a8ceb9d077bc71cc8e2b2) )
+ROM_END
+
+
GAME( 199?, lucky21, 0, lucky37, lucky37, lucky37_state, empty_init, ROT0, "Wing Co., Ltd.", "Lucky 21", MACHINE_IS_SKELETON )
GAME( 199?, lucky21d, 0, lucky37, lucky37, lucky37_state, empty_init, ROT0, "Wing Co., Ltd.", "Lucky 21-D", MACHINE_IS_SKELETON )
GAME( 199?, lucky25, 0, lucky37, lucky37, lucky37_state, empty_init, ROT0, "Wing Co., Ltd.", "Lucky 25", MACHINE_IS_SKELETON )
GAME( 199?, lucky37, 0, lucky37, lucky37, lucky37_state, empty_init, ROT0, "Wing Co., Ltd.", "Lucky 37", MACHINE_IS_SKELETON )
+GAME( 199?, bingo75, 0, lucky37, lucky37, lucky37_state, empty_init, ROT0, "Wing Co., Ltd.", "Bingo 75", MACHINE_IS_SKELETON )
diff --git a/src/mame/drivers/lviv.cpp b/src/mame/drivers/lviv.cpp
index 258960825a0..7aac9930b97 100644
--- a/src/mame/drivers/lviv.cpp
+++ b/src/mame/drivers/lviv.cpp
@@ -280,6 +280,7 @@ Timings:
b: only if the CPU is requesting a RAM write
c: only if the CPU is requesting a RAM read
+
*******************************************************************************/
#include "emu.h"
@@ -287,7 +288,6 @@ Timings:
#include "cpu/i8085/i8085.h"
-#include "softlist.h"
#include "speaker.h"
#include "formats/lviv_lvt.h"
@@ -429,20 +429,20 @@ void lviv_state::lviv(machine_config &config)
config.set_maximum_quantum(attotime::from_hz(60));
I8255(config, m_ppi[0]);
- m_ppi[0]->in_pa_callback().set(FUNC(lviv_state::ppi_0_porta_r));
- m_ppi[0]->out_pa_callback().set(FUNC(lviv_state::ppi_0_porta_w));
- m_ppi[0]->in_pb_callback().set(FUNC(lviv_state::ppi_0_portb_r));
- m_ppi[0]->out_pb_callback().set(FUNC(lviv_state::ppi_0_portb_w));
- m_ppi[0]->in_pc_callback().set(FUNC(lviv_state::ppi_0_portc_r));
- m_ppi[0]->out_pc_callback().set(FUNC(lviv_state::ppi_0_portc_w));
+ m_ppi[0]->in_pa_callback().set(FUNC(lviv_state::ppi0_porta_r));
+ m_ppi[0]->out_pa_callback().set(FUNC(lviv_state::ppi0_porta_w));
+ m_ppi[0]->in_pb_callback().set(FUNC(lviv_state::ppi0_portb_r));
+ m_ppi[0]->out_pb_callback().set(FUNC(lviv_state::ppi0_portb_w));
+ m_ppi[0]->in_pc_callback().set(FUNC(lviv_state::ppi0_portc_r));
+ m_ppi[0]->out_pc_callback().set(FUNC(lviv_state::ppi0_portc_w));
I8255(config, m_ppi[1]);
- m_ppi[1]->in_pa_callback().set(FUNC(lviv_state::ppi_1_porta_r));
- m_ppi[1]->out_pa_callback().set(FUNC(lviv_state::ppi_1_porta_w));
- m_ppi[1]->in_pb_callback().set(FUNC(lviv_state::ppi_1_portb_r));
- m_ppi[1]->out_pb_callback().set(FUNC(lviv_state::ppi_1_portb_w));
- m_ppi[1]->in_pc_callback().set(FUNC(lviv_state::ppi_1_portc_r));
- m_ppi[1]->out_pc_callback().set(FUNC(lviv_state::ppi_1_portc_w));
+ m_ppi[1]->in_pa_callback().set(FUNC(lviv_state::ppi1_porta_r));
+ m_ppi[1]->out_pa_callback().set(FUNC(lviv_state::ppi1_porta_w));
+ m_ppi[1]->in_pb_callback().set(FUNC(lviv_state::ppi1_portb_r));
+ m_ppi[1]->out_pb_callback().set(FUNC(lviv_state::ppi1_portb_w));
+ m_ppi[1]->in_pc_callback().set(FUNC(lviv_state::ppi1_portc_r));
+ m_ppi[1]->out_pc_callback().set(FUNC(lviv_state::ppi1_portc_w));
/* video hardware */
SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
@@ -476,14 +476,14 @@ void lviv_state::lviv(machine_config &config)
ROM_START(lviv)
- ROM_REGION(0x14000,"maincpu",0)
+ ROM_REGION(0x4000,"maincpu",0)
ROM_SYSTEM_BIOS( 0, "lviv", "Lviv/L'vov" )
- ROMX_LOAD("lviv.bin", 0x10000, 0x4000, CRC(44a347d9) SHA1(74e067493b2b7d9ab17333202009a1a4f5e460fd), ROM_BIOS(0))
+ ROMX_LOAD("lviv.bin", 0x0000, 0x4000, CRC(44a347d9) SHA1(74e067493b2b7d9ab17333202009a1a4f5e460fd), ROM_BIOS(0))
ROM_SYSTEM_BIOS( 1, "lviva", "Lviv/L'vov (alternate)" )
- ROMX_LOAD("lviva.bin", 0x10000, 0x4000, CRC(551622f5) SHA1(b225f3542b029d767b7db9dce562e8a3f77f92a2), ROM_BIOS(1))
+ ROMX_LOAD("lviva.bin", 0x0000, 0x4000, CRC(551622f5) SHA1(b225f3542b029d767b7db9dce562e8a3f77f92a2), ROM_BIOS(1))
ROM_SYSTEM_BIOS( 2, "lvivp", "Lviv/L'vov (prototype)" )
- ROMX_LOAD("lvivp.bin", 0x10000, 0x4000, CRC(f171c282) SHA1(c7dc2bdb02400e6b5cdcc50040eb06f506a7ed84), ROM_BIOS(2))
+ ROMX_LOAD("lvivp.bin", 0x0000, 0x4000, CRC(f171c282) SHA1(c7dc2bdb02400e6b5cdcc50040eb06f506a7ed84), ROM_BIOS(2))
ROM_END
/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
-COMP( 1989, lviv, 0, 0, lviv, lviv, lviv_state, empty_init, "V. I. Lenin", "PK-01 Lviv", 0 )
+COMP( 1989, lviv, 0, 0, lviv, lviv, lviv_state, empty_init, "V. I. Lenin", "PK-01 Lviv", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/megadriv_acbl.cpp b/src/mame/drivers/megadriv_acbl.cpp
index 8bc27d110d4..afb0db44e1c 100644
--- a/src/mame/drivers/megadriv_acbl.cpp
+++ b/src/mame/drivers/megadriv_acbl.cpp
@@ -6,6 +6,7 @@
Games supported:
* Aladdin
+ * Bare Knuckle II
* Bare Knuckle III
* Jurassic Park
* Mortal Kombat 3
@@ -356,6 +357,18 @@ uint16_t md_boot_state::jparkmb_r()
return 0x0000;
}
+uint16_t md_boot_state::barek2mb_r()
+{
+ if (m_maincpu->pc()==0xfa40)
+ return 0x0400; // TODO: what's this? Needed or the game doesn't boot
+
+ if (m_maincpu->pc()==0xfa88)
+ return 0x0ff0; // TODO: fix this, should probably read coin inputs, as is gives 9 credits at start up
+
+ logerror("aladbl_r : %06x\n",m_maincpu->pc());
+ return 0x0000;
+}
+
uint16_t md_boot_state::mk3mdb_dsw_r(offs_t offset)
{
static const char *const dswname[3] = { "DSWA", "DSWB", "DSWC" };
@@ -769,6 +782,11 @@ static INPUT_PORTS_START( topshoot ) /* Top Shooter Input Ports */
PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
INPUT_PORTS_END
+INPUT_PORTS_START( barek2 )
+ PORT_INCLUDE( aladmdb )
+ // TODO!
+INPUT_PORTS_END
+
INPUT_PORTS_START( barek3 )
PORT_INCLUDE( md_common )
@@ -843,7 +861,7 @@ ROM_START( aladmdb )
ROM_LOAD16_BYTE( "m1.bin", 0x000001, 0x080000, CRC(5e2671e4) SHA1(54705c7614fc7b5a1065478fa41f51dd1d8045b7) )
ROM_LOAD16_BYTE( "m2.bin", 0x000000, 0x080000, CRC(142a0366) SHA1(6c94aa9936cd11ccda503b52019a6721e64a32f0) )
ROM_LOAD16_BYTE( "m3.bin", 0x100001, 0x080000, CRC(0feeeb19) SHA1(bd567a33077ab9997871d21736066140d50e3d70) )
- ROM_LOAD16_BYTE( "m4.bin", 0x100000, 0x080000, CRC(bc712661) SHA1(dfd554d000399e17b4ddc69761e572195ed4e1f0))
+ ROM_LOAD16_BYTE( "m4.bin", 0x100000, 0x080000, CRC(bc712661) SHA1(dfd554d000399e17b4ddc69761e572195ed4e1f0) )
ROM_REGION( 0x2000, "pic", ROMREGION_ERASE00 )
ROM_LOAD( "pic16c57xtp", 0x0000, 0x2000, NO_DUMP )
@@ -888,7 +906,7 @@ ROM_START( srmdb )
ROM_LOAD16_BYTE( "u1", 0x000001, 0x020000, CRC(c59f33bd) SHA1(bd5bce7698a70ea005b79ab34bcdb056872ef980) )
ROM_LOAD16_BYTE( "u2", 0x000000, 0x020000, CRC(9125c054) SHA1(c73bdeb6b11c59d2b5f5968959b02697957ca894) )
ROM_LOAD16_BYTE( "u3", 0x040001, 0x020000, CRC(0fee0fbe) SHA1(001e0fda12707512aad537e533acf28e726e6107) )
- ROM_LOAD16_BYTE( "u4", 0x040000, 0x020000, CRC(fc2aed41) SHA1(27eb3957f5ed26ee5276523b1df46fa7eb298e1f))
+ ROM_LOAD16_BYTE( "u4", 0x040000, 0x020000, CRC(fc2aed41) SHA1(27eb3957f5ed26ee5276523b1df46fa7eb298e1f) )
ROM_END
ROM_START( topshoot ) /* Top Shooter (c)1995 Sun Mixing */
@@ -907,6 +925,17 @@ ROM_START( sonic2mb )
ROM_LOAD16_BYTE( "m2", 0x000000, 0x080000, CRC(84b3f758) SHA1(19846b9d951db6f78f3e155d33f1b6349fb87f1a) )
ROM_END
+ROM_START( barek2mb )
+ ROM_REGION( 0x200000, "maincpu", 0 )
+ ROM_LOAD16_BYTE( "m1.bin", 0x000001, 0x080000, CRC(1c1fa718) SHA1(393488f7747478728eb4f20c10b0cfce3b188719) )
+ ROM_LOAD16_BYTE( "m2.bin", 0x000000, 0x080000, CRC(59ee0905) SHA1(0e9f1f6e17aae2dd99bf9d7f640568b48ba699c7) )
+ ROM_LOAD16_BYTE( "m3.bin", 0x100001, 0x080000, CRC(6ec5af5d) SHA1(9088a2d4cff5e7eb439ebaa91ad3bfff11366127) )
+ ROM_LOAD16_BYTE( "m4.bin", 0x100000, 0x080000, CRC(d8c61e0d) SHA1(3d06e656f6621bb0741211f80c1ecff1669475ee) )
+
+ ROM_REGION( 0x2000, "pic", ROMREGION_ERASE00 )
+ ROM_LOAD( "pic16c57xtp", 0x0000, 0x2000, NO_DUMP )
+ROM_END
+
ROM_START( barek3mb )
ROM_REGION( 0x400000, "maincpu", 0 ) /* 68000 Code */
ROM_LOAD16_BYTE( "6.u19", 0x000000, 0x080000, CRC(2de19519) SHA1(f5fcef1da8b5370e399f0451382e3c6e7754c9c8) )
@@ -1068,6 +1097,14 @@ void md_boot_state::init_topshoot()
init_megadriv();
}
+void md_boot_state::init_barek2()
+{
+ m_maincpu->space(AS_PROGRAM).install_write_handler(0x220000, 0x220001, write16smo_delegate(*this, FUNC(md_boot_state::aladmdb_w)));
+ m_maincpu->space(AS_PROGRAM).install_read_handler(0x330000, 0x330001, read16smo_delegate(*this, FUNC(md_boot_state::barek2mb_r)));
+
+ init_megadrij();
+}
+
void md_boot_state::init_barek3()
{
uint8_t* rom = memregion("maincpu")->base();
@@ -1126,6 +1163,7 @@ GAME( 1994, ssf2mdb, 0, megadrvb_6b, ssf2mdb, md_boot_state, init_ssf2mdb, R
GAME( 1993, srmdb, 0, megadrvb, srmdb, md_boot_state, init_srmdb, ROT0, "bootleg / Konami", "Sunset Riders (bootleg of Megadrive version)", 0)
GAME( 1995, topshoot, 0, md_bootleg, topshoot, md_boot_state, init_topshoot, ROT0, "Sun Mixing", "Top Shooter", 0)
GAME( 1993, sonic2mb, 0, md_bootleg, sonic2mb, md_boot_state, init_sonic2mb, ROT0, "bootleg / Sega", "Sonic The Hedgehog 2 (bootleg of Megadrive version)", 0 ) // flying wires going through the empty PIC space aren't completely understood
+GAME( 1994, barek2mb, 0, md_bootleg, barek2, md_boot_state, init_barek2, ROT0, "bootleg / Sega", "Bare Knuckle II (bootleg of Megadrive version)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // needs PIC decap or simulation
GAME( 1994, barek3mb, 0, megadrvb, barek3, md_boot_state, init_barek3, ROT0, "bootleg / Sega", "Bare Knuckle III (bootleg of Megadrive version)", 0 )
-GAME( 1993, twinktmb, 0, md_bootleg, twinktmb, md_boot_state, init_twinktmb, ROT0, "bootleg / Sega", "Twinkle Tale (bootleg of Megadrive version)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // needs PIC decap or simulation
-GAME( 1993, jparkmb, 0, md_bootleg, twinktmb, md_boot_state, init_jparkmb, ROT0, "bootleg / Sega", "Jurassic Park (bootleg of Megadrive version)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // needs PIC decap or simulation
+GAME( 1993, twinktmb, 0, md_bootleg, twinktmb, md_boot_state, init_twinktmb, ROT0, "bootleg / Sega", "Twinkle Tale (bootleg of Megadrive version)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // needs PIC decap or simulation
+GAME( 1993, jparkmb, 0, md_bootleg, twinktmb, md_boot_state, init_jparkmb, ROT0, "bootleg / Sega", "Jurassic Park (bootleg of Megadrive version)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) // needs PIC decap or simulation
diff --git a/src/mame/drivers/microvsn.cpp b/src/mame/drivers/microvsn.cpp
index 311e2150213..1000ec09ab7 100644
--- a/src/mame/drivers/microvsn.cpp
+++ b/src/mame/drivers/microvsn.cpp
@@ -259,7 +259,8 @@ uint32_t microvision_state::screen_update(screen_device &screen, bitmap_rgb32 &b
int p = m_lcd_pwm->read_element_bri(y ^ 15, x ^ 15) * 10000;
p = (p > 255) ? 0 : p ^ 255;
- bitmap.pix32(y, x) = p << 16 | p << 8 | p;
+ if (cliprect.contains(x, y))
+ bitmap.pix32(y, x) = p << 16 | p << 8 | p;
}
}
diff --git a/src/mame/drivers/midvunit.cpp b/src/mame/drivers/midvunit.cpp
index 491fe61cd28..5db2802f8e7 100644
--- a/src/mame/drivers/midvunit.cpp
+++ b/src/mame/drivers/midvunit.cpp
@@ -1281,7 +1281,7 @@ Also had V4.4 printed sideways at front of the label.
*/
ROM_START( crusnusa ) /* Version 4.4, Wed Mar 15 1995 - 10:52:28 */
ROM_REGION16_LE( 0x1000000, "dcs", ROMREGION_ERASEFF ) /* sound data */
- ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* seen labeled as P1 & P2, niether seems dumped to verify if they are different */
+ ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* also known to be labeled as P2, the P1 revision hasn't been dumped or confirmed to be different */
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u3.u3", 0x200000, 0x80000, CRC(cd8325d6) SHA1(d65d7263e056ca1d637adb44cafef523e0831a34) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u4.u4", 0x400000, 0x80000, CRC(fab457f3) SHA1(2b4b647838b7a8100afc25ca1ffdc74ed67ae00a) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u5.u5", 0x600000, 0x80000, CRC(becc92f4) SHA1(6dffa73ff5270155c44f295e443d5e77c03c0338) )
@@ -1323,7 +1323,7 @@ ROM_END
ROM_START( crusnusa41 ) /* Version 4.1, Mon Feb 13 1995 - 16:53:40 */
ROM_REGION16_LE( 0x1000000, "dcs", ROMREGION_ERASEFF ) /* sound data */
- ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* seen labeled as P1 & P2, niether seems dumped to verify if they are different */
+ ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* also known to be labeled as P2, the P1 revision hasn't been dumped or confirmed to be different */
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u3.u3", 0x200000, 0x80000, CRC(cd8325d6) SHA1(d65d7263e056ca1d637adb44cafef523e0831a34) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u4.u4", 0x400000, 0x80000, CRC(fab457f3) SHA1(2b4b647838b7a8100afc25ca1ffdc74ed67ae00a) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u5.u5", 0x600000, 0x80000, CRC(becc92f4) SHA1(6dffa73ff5270155c44f295e443d5e77c03c0338) )
@@ -1366,7 +1366,7 @@ ROM_END
ROM_START( crusnusa40 ) /* Version 4.0, Wed Feb 08 1995 - 10:45:14 */
ROM_REGION16_LE( 0x1000000, "dcs", ROMREGION_ERASEFF ) /* sound data */
- ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* seen labeled as P1 & P2, niether seems dumped to verify if they are different */
+ ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* also known to be labeled as P2, the P1 revision hasn't been dumped or confirmed to be different */
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u3.u3", 0x200000, 0x80000, CRC(cd8325d6) SHA1(d65d7263e056ca1d637adb44cafef523e0831a34) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u4.u4", 0x400000, 0x80000, CRC(fab457f3) SHA1(2b4b647838b7a8100afc25ca1ffdc74ed67ae00a) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u5.u5", 0x600000, 0x80000, CRC(becc92f4) SHA1(6dffa73ff5270155c44f295e443d5e77c03c0338) )
@@ -1409,7 +1409,7 @@ ROM_END
ROM_START( crusnusa21 ) /* Version 2.1, Wed Nov 09 1994 - 16:28:10 */
ROM_REGION16_LE( 0x1000000, "dcs", ROMREGION_ERASEFF ) /* sound data */
- ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* seen labeled as P1 & P2, niether seems dumped to verify if they are different */
+ ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u2.u2", 0x000000, 0x80000, CRC(b9338332) SHA1(e5c420e63c4eba0010a68c7e0a57ef210e2c83d2) ) /* also known to be labeled as P2, the P1 revision hasn't been dumped or confirmed to be different */
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u3.u3", 0x200000, 0x80000, CRC(cd8325d6) SHA1(d65d7263e056ca1d637adb44cafef523e0831a34) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u4.u4", 0x400000, 0x80000, CRC(fab457f3) SHA1(2b4b647838b7a8100afc25ca1ffdc74ed67ae00a) )
ROM_LOAD16_BYTE( "l1_cruisin_u.s.a._sound_rom_u5.u5", 0x600000, 0x80000, CRC(becc92f4) SHA1(6dffa73ff5270155c44f295e443d5e77c03c0338) )
@@ -1450,6 +1450,19 @@ ROM_START( crusnusa21 ) /* Version 2.1, Wed Nov 09 1994 - 16:28:10 */
ROM_END
+/*
+Some Cruis'n World PCBs have mask ROMs for the data ROMs
+
+Mask ROMs are in the following format:
+-------------------------------- --------------------------------
+| MIDWAY GAMES INC | | MIDWAY GAMES INC |
+| CRUISN WORLD | | CRUISN WORLD |
+) 5341-15282-01 | ) 5341-15287-01 |
+| U3 SOUND | | U14 VIDEO IMAGE |
+| (C)1996 MIDWAY GAMES | | (C)1996 MIDWAY GAMES |
+-------------------------------- --------------------------------
+
+*/
ROM_START( crusnwld ) /* Version 2.5, Wed Nov 04 1998 - 15:50:52 */
ROM_REGION16_LE( 0x1000000, "dcs", ROMREGION_ERASEFF ) /* sound data */
ROM_LOAD16_BYTE( "1.0_cruisn_world_u2_sound.u2", 0x000000, 0x80000, CRC(7a233c89) SHA1(ecfad4bc48a69cd3399e3b3266c81574082e0169) )
diff --git a/src/mame/drivers/model3.cpp b/src/mame/drivers/model3.cpp
index f7e0ae45f0f..6c641709690 100644
--- a/src/mame/drivers/model3.cpp
+++ b/src/mame/drivers/model3.cpp
@@ -735,6 +735,8 @@ JP4/5/6/7 - Jumpers to configure ROMs
#include "includes/model3.h"
#include "cpu/m68000/m68000.h"
+#include "cpu/z80/kl5c80a16.h"
+#include "machine/315_5296.h"
#include "machine/clock.h"
#include "machine/eepromser.h"
#include "machine/53c810.h"
@@ -6006,6 +6008,31 @@ void model3_state::model3_10(machine_config &config)
MCFG_MACHINE_RESET_OVERRIDE(model3_state,model3_10)
}
+void model3_state::getbass_iocpu_mem(address_map &map)
+{
+ map(0x00000, 0x0efff).rom();
+ map(0x0f000, 0x0ffff).ram();
+}
+
+void model3_state::getbass_iocpu_io(address_map &map)
+{
+ map.global_mask(0xff);
+ map(0x60, 0x6f).rw("io60", FUNC(sega_315_5296_device::read), FUNC(sega_315_5296_device::write));
+ map(0x70, 0x7f).rw("io70", FUNC(sega_315_5649_device::read), FUNC(sega_315_5649_device::write));
+}
+
+void model3_state::getbass(machine_config &config)
+{
+ model3_10(config);
+
+ kl5c80a16_device &iocpu(KL5C80A16(config, "iocpu", 32_MHz_XTAL / 2));
+ iocpu.set_addrmap(AS_PROGRAM, &model3_state::getbass_iocpu_mem);
+ iocpu.set_addrmap(AS_IO, &model3_state::getbass_iocpu_io);
+
+ SEGA_315_5296(config, "io60", 32_MHz_XTAL);
+ SEGA_315_5649(config, "io70", 0);
+}
+
void model3_state::model3_15(machine_config &config)
{
add_cpu_100mhz(config);
@@ -6469,7 +6496,7 @@ GAME( 1996, vf3a, vf3, model3_10, model3, model3_state, init_vf3,
GAME( 1996, vf3tb, vf3, model3_10, model3, model3_state, init_model3_10, ROT0, "Sega", "Virtua Fighter 3 Team Battle", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
GAME( 1997, bass, 0, model3_10, bass, model3_state, init_bass, ROT0, "Sega", "Sega Bass Fishing", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
GAME( 1997, bassdx, bass, model3_10, bass, model3_state, init_getbass, ROT0, "Sega", "Sega Bass Fishing Deluxe", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-GAME( 1997, getbass, bass, model3_10, bass, model3_state, init_getbass, ROT0, "Sega", "Get Bass", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+GAME( 1997, getbass, bass, getbass, bass, model3_state, init_getbass, ROT0, "Sega", "Get Bass", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
/* Model 3 Step 1.5 */
GAME( 1996, scud, 0, scud, scud, model3_state, init_scud, ROT0, "Sega", "Scud Race Twin (Australia)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
diff --git a/src/mame/drivers/mpu4vid.cpp b/src/mame/drivers/mpu4vid.cpp
index 10737f30668..f393a4bfbc1 100644
--- a/src/mame/drivers/mpu4vid.cpp
+++ b/src/mame/drivers/mpu4vid.cpp
@@ -171,6 +171,8 @@ TODO:
* They have a slightly different 68k memory map. The 6850 is at e00000 and the 6840 is at e01000
They appear to hang on the handshake with the MPU4 board
- Layouts needed for the other working games, and DIP switches need checking/altering (no test mode?)
+ - BWB Vid5 cabinets seem to have the speakers wired the other way according to test (left/right swapped)
+ - BWB sampled sound seems to not play despite hookup.
***********************************************************************************************************/
#include "emu.h"
#include "includes/mpu4.h"
@@ -202,6 +204,7 @@ TODO:
#include "crmaze4p.lh"
#include "v4addlad.lh"
#include "v4barqst.lh"
+#include "v4psi.lh"
#include "v4strike.lh"
@@ -239,7 +242,7 @@ public:
void bwbvid(machine_config &config);
void crmaze(machine_config &config);
- void bwbvid5(machine_config &config);
+ void bwbvid_oki(machine_config &config);
void mating(machine_config &config);
void vid_oki(machine_config &config);
@@ -311,7 +314,7 @@ private:
uint8_t vram_r(offs_t offset);
void ic3ss_vid_w(offs_t offset, uint8_t data);
- void bwbvid5_68k_map(address_map &map);
+ void bwbvidoki_68k_map(address_map &map);
void bwbvid_68k_map(address_map &map);
void mpu4_68k_map_base(address_map &map);
void mpu4_68k_map(address_map &map);
@@ -871,11 +874,194 @@ static INPUT_PORTS_START( adders )
PORT_BIT(0xFF, IP_ACTIVE_HIGH, IPT_UNUSED)
INPUT_PORTS_END
+
+static INPUT_PORTS_START( strike )
+ PORT_INCLUDE( mpu4vid )
+ PORT_MODIFY("ORANGE1")
+ PORT_BIT( 0x0F, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON9) PORT_NAME("Freeze")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON10) PORT_NAME("Go On!")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_MODIFY("ORANGE2")
+ PORT_BIT(0xFF, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_START2) PORT_NAME("Play")
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_BUTTON3) PORT_NAME("Green (Left)")
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_BUTTON2) PORT_NAME("Yellow (Left)")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_BUTTON1) PORT_NAME("Red (Left)")
+
+ PORT_MODIFY("BLACK2")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_BUTTON7) PORT_NAME("Help")
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_BUTTON6) PORT_NAME("Green (Right)")
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_BUTTON5) PORT_NAME("Yellow (Right)")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_BUTTON4) PORT_NAME("Red (Right)")
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_BUTTON8) PORT_NAME("Collect")
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_START1)
+
+ PORT_MODIFY("AUX1")
+ PORT_BIT(0xFF, IP_ACTIVE_HIGH, IPT_UNUSED)
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( bwbvid )
+ PORT_START("ORANGE1")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM )// 20p level
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token bottom level
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM )// 100p level
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM )// Long token bottom level
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_CUSTOM )// Prize token level sensor
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token top level
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+
+ PORT_START("ORANGE2")
+ PORT_CONFNAME( 0x0F, 0x00, "Jackpot / Prize Key" )
+ PORT_CONFSETTING( 0x00, "Not fitted" )
+ PORT_CONFSETTING( 0x01, "3 GBP" )
+ PORT_CONFSETTING( 0x02, "4 GBP" )
+ PORT_CONFSETTING( 0x08, "5 GBP" )
+ PORT_CONFSETTING( 0x03, "6 GBP" )
+ PORT_CONFSETTING( 0x04, "6 GBP Token" )
+ PORT_CONFSETTING( 0x05, "8 GBP" )
+ PORT_CONFSETTING( 0x06, "8 GBP Token" )
+ PORT_CONFSETTING( 0x07, "10 GBP" )
+ PORT_CONFSETTING( 0x09, "15 GBP" )
+ PORT_CONFSETTING( 0x0A, "25 GBP" )
+ PORT_CONFSETTING( 0x0B, "25 GBP (Licensed Betting Office Profile)" )
+ PORT_CONFSETTING( 0x0C, "35 GBP" )
+ PORT_CONFSETTING( 0x0D, "70 GBP" )
+ PORT_CONFSETTING( 0x0E, "Reserved" )
+ PORT_CONFSETTING( 0x0F, "Reserved" )
+
+ PORT_CONFNAME( 0xF0, 0x00, "Percentage Key" )
+ PORT_CONFSETTING( 0x00, "Not fitted / 68% (Invalid for UK Games)" )
+ PORT_CONFSETTING( 0x10, "70" )
+ PORT_CONFSETTING( 0x20, "72" )
+ PORT_CONFSETTING( 0x30, "74" )
+ PORT_CONFSETTING( 0x40, "76" )
+ PORT_CONFSETTING( 0x50, "78" )
+ PORT_CONFSETTING( 0x60, "80" )
+ PORT_CONFSETTING( 0x70, "82" )
+ PORT_CONFSETTING( 0x80, "84" )
+ PORT_CONFSETTING( 0x90, "86" )
+ PORT_CONFSETTING( 0xA0, "88" )
+ PORT_CONFSETTING( 0xB0, "90" )
+ PORT_CONFSETTING( 0xC0, "92" )
+ PORT_CONFSETTING( 0xD0, "94" )
+ PORT_CONFSETTING( 0xE0, "96" )
+ PORT_CONFSETTING( 0xF0, "98" )
+
+ PORT_START("BLACK1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_BUTTON1) PORT_NAME("Button 9")
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_BUTTON2) PORT_NAME("Button 10")
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 11")
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 12")
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_CUSTOM) // Prize Shelf Opto
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_SERVICE) PORT_NAME("Test Button") PORT_CODE(KEYCODE_W)
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_SERVICE) PORT_NAME("Refill Key") PORT_CODE(KEYCODE_R) PORT_TOGGLE
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_INTERLOCK) PORT_NAME("Cashbox (Back) Door") PORT_CODE(KEYCODE_Q) PORT_TOGGLE
+
+ PORT_START("BLACK2")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 1")
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 2")
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 3")
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 4")
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 5")
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 6")
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 7")
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_START1) //Button 8
+
+ PORT_START("DIL1")
+ PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, "High Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:03")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x08, 0x00, "Low Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:04")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0xF0, 0x00, "Target Percentage (if key not fitted)" )PORT_DIPLOCATION("DIL1:05,06,07,08")
+ PORT_DIPSETTING( 0x00, "Unset (Program Optimum)" )
+ PORT_DIPSETTING( 0x10, "70" )
+ PORT_DIPSETTING( 0x20, "72" )
+ PORT_DIPSETTING( 0x30, "74" )
+ PORT_DIPSETTING( 0x40, "76" )
+ PORT_DIPSETTING( 0x50, "78" )
+ PORT_DIPSETTING( 0x60, "80" )
+ PORT_DIPSETTING( 0x70, "82" )
+ PORT_DIPSETTING( 0x80, "84" )
+ PORT_DIPSETTING( 0x90, "86" )
+ PORT_DIPSETTING( 0xA0, "88" )
+ PORT_DIPSETTING( 0xB0, "90" )
+ PORT_DIPSETTING( 0xC0, "92" )
+ PORT_DIPSETTING( 0xD0, "94" )
+ PORT_DIPSETTING( 0xE0, "96" )
+ PORT_DIPSETTING( 0xF0, "98" )
+
+ PORT_START("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:01") //Clear MPU on some machines
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "High Prize Payout proportion (if available)" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("AUX1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_START("AUX2")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_CUSTOM) //Lockouts, in same order as below
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_CUSTOM)
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_CUSTOM)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_COIN5) PORT_NAME("Token")// If valid, then 0x04 is unused, 0x01 is token lockout, 0x02 is all other lockouts.
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_COIN1) PORT_NAME("10p")
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_COIN2) PORT_NAME("20p")
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_COIN3) PORT_NAME("50p")
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_COIN4) PORT_NAME("100p")
+INPUT_PORTS_END
+
+
static INPUT_PORTS_START( v4psi )
- PORT_INCLUDE( mpu4 )
+ PORT_INCLUDE( bwbvid )
PORT_MODIFY("ORANGE1")
- PORT_BIT( 0x07, IP_ACTIVE_HIGH, IPT_UNKNOWN )
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) // Payout Shelf opto
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM )// 20p level
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token bottom level
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM )// 100p level
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_CUSTOM ) // Payout Shelf opto
PORT_BIT( 0xf0, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_MODIFY("ORANGE2")
@@ -927,7 +1113,21 @@ static INPUT_PORTS_START( v4psi )
INPUT_PORTS_END
static INPUT_PORTS_START( v4tetris )
- PORT_INCLUDE( mpu4 )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("ORANGE1")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM )// 20p level
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token bottom level
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM )// 100p level
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM )// Long token bottom level
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_CUSTOM )// Prize token level sensor
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token top level
+ PORT_BIT( 0xc0, IP_ACTIVE_HIGH, IPT_UNKNOWN )
+
+
+ PORT_MODIFY("ORANGE2")
+ PORT_BIT(0xFF, IP_ACTIVE_HIGH, IPT_UNUSED)
+
PORT_MODIFY("BLACK1")
// no up also according to cabinet panel
@@ -939,8 +1139,6 @@ static INPUT_PORTS_START( v4tetris )
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Rotate Left")
// left of main screen cab
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Start (Practice Mode)")
- // TODO: bit 5,6 unconfirmed if they behaves the same as vanilla MPU4
- // (bit 7 certainly is door open)
PORT_MODIFY("BLACK2")
PORT_BIT( 0x07, IP_ACTIVE_HIGH, IPT_UNKNOWN )
@@ -949,7 +1147,6 @@ static INPUT_PORTS_START( v4tetris )
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_START2 ) PORT_NAME("Start (Prize Mode)")
PORT_BIT( 0xe0, IP_ACTIVE_HIGH, IPT_UNKNOWN )
- // TODO: dips
PORT_MODIFY("DIL2")
PORT_DIPNAME( 0x01, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:01")
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
@@ -980,12 +1177,12 @@ INPUT_PORTS_END
static INPUT_PORTS_START( v4pztet )
- PORT_INCLUDE( mpu4 )
+ PORT_INCLUDE( v4tetris )
PORT_MODIFY("BLACK1")
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Start (Practice Mode)")
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_START2 ) PORT_NAME("Start (Prize Mode)")
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_CUSTOM) // Prize Shelf Opto (v4bulblx will hang on boot without an error message otherwise)
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_CUSTOM ) // Prize Shelf Opto
PORT_MODIFY("BLACK2")
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
@@ -995,8 +1192,19 @@ static INPUT_PORTS_START( v4pztet )
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Rotate Right")
INPUT_PORTS_END
+
+static INPUT_PORTS_START( v4bulblx )
+ PORT_INCLUDE( v4pztet )
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START2 ) PORT_NAME("Start (Practice Mode)")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Start (Prize Mode)")
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_CUSTOM) // Prize Shelf Opto
+INPUT_PORTS_END
+
+
static INPUT_PORTS_START( v4vgpok )
- PORT_INCLUDE( mpu4 )
+ PORT_INCLUDE( bwbvid )
PORT_MODIFY("BLACK1")
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Start / Deal / Draw")
@@ -1014,114 +1222,100 @@ static INPUT_PORTS_START( v4vgpok )
INPUT_PORTS_END
-static INPUT_PORTS_START( strike )
- PORT_INCLUDE( mpu4vid )
- PORT_MODIFY("ORANGE1")
- PORT_BIT( 0x0F, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON9) PORT_NAME("Freeze")
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON10) PORT_NAME("Go On!")
- PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNUSED)
-
- PORT_MODIFY("ORANGE2")
- PORT_BIT(0xFF, IP_ACTIVE_HIGH, IPT_UNUSED)
-
- PORT_MODIFY("BLACK1")
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_START2) PORT_NAME("Play")
- PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_BUTTON3) PORT_NAME("Green (Left)")
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_BUTTON2) PORT_NAME("Yellow (Left)")
- PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_BUTTON1) PORT_NAME("Red (Left)")
-
- PORT_MODIFY("BLACK2")
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_BUTTON7) PORT_NAME("Help")
- PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_BUTTON6) PORT_NAME("Green (Right)")
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_BUTTON5) PORT_NAME("Yellow (Right)")
- PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_BUTTON4) PORT_NAME("Red (Right)")
- PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_BUTTON8) PORT_NAME("Collect")
- PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_START1)
-
- PORT_MODIFY("AUX1")
- PORT_BIT(0xFF, IP_ACTIVE_HIGH, IPT_UNUSED)
-INPUT_PORTS_END
-static INPUT_PORTS_START( bwbvid )
- PORT_START("ORANGE1")
+static INPUT_PORTS_START( v4mdice )
+ PORT_INCLUDE( bwbvid )
+ PORT_MODIFY("ORANGE1")
PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM )// 20p level
PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token bottom level
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM )// 100p level
PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM )// Long token bottom level
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_CUSTOM )// Prize token level sensor
PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token top level
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_UNKNOWN )
- PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN )
-
- PORT_START("ORANGE2")
- PORT_CONFNAME( 0x0F, 0x00, "Jackpot / Prize Key" )
- PORT_CONFSETTING( 0x00, "Not fitted" )
- PORT_CONFSETTING( 0x01, "3 GBP" )
- PORT_CONFSETTING( 0x02, "4 GBP" )
- PORT_CONFSETTING( 0x08, "5 GBP" )
- PORT_CONFSETTING( 0x03, "6 GBP" )
- PORT_CONFSETTING( 0x04, "6 GBP Token" )
- PORT_CONFSETTING( 0x05, "8 GBP" )
- PORT_CONFSETTING( 0x06, "8 GBP Token" )
- PORT_CONFSETTING( 0x07, "10 GBP" )
- PORT_CONFSETTING( 0x09, "15 GBP" )
- PORT_CONFSETTING( 0x0A, "25 GBP" )
- PORT_CONFSETTING( 0x0B, "25 GBP (Licensed Betting Office Profile)" )
- PORT_CONFSETTING( 0x0C, "35 GBP" )
- PORT_CONFSETTING( 0x0D, "70 GBP" )
- PORT_CONFSETTING( 0x0E, "Reserved" )
- PORT_CONFSETTING( 0x0F, "Reserved" )
+ PORT_BIT( 0xc0, IP_ACTIVE_HIGH, IPT_UNKNOWN )
- PORT_CONFNAME( 0xF0, 0x00, "Percentage Key" )
- PORT_CONFSETTING( 0x00, "Not fitted / 68% (Invalid for UK Games)" )
- PORT_CONFSETTING( 0x10, "70" )
- PORT_CONFSETTING( 0x20, "72" )
- PORT_CONFSETTING( 0x30, "74" )
- PORT_CONFSETTING( 0x40, "76" )
- PORT_CONFSETTING( 0x50, "78" )
- PORT_CONFSETTING( 0x60, "80" )
- PORT_CONFSETTING( 0x70, "82" )
- PORT_CONFSETTING( 0x80, "84" )
- PORT_CONFSETTING( 0x90, "86" )
- PORT_CONFSETTING( 0xA0, "88" )
- PORT_CONFSETTING( 0xB0, "90" )
- PORT_CONFSETTING( 0xC0, "92" )
- PORT_CONFSETTING( 0xD0, "94" )
- PORT_CONFSETTING( 0xE0, "96" )
- PORT_CONFSETTING( 0xF0, "98" )
+ PORT_MODIFY("BLACK1")
+ PORT_BIT( 0x0f, IP_ACTIVE_HIGH, IPT_UNUSED )
- PORT_START("BLACK1")
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_BUTTON1) PORT_NAME("Button 9")
- PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_BUTTON2) PORT_NAME("Button 10")
- PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 11")
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 12")
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_CUSTOM) // Prize Shelf Opto
- PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_SERVICE) PORT_NAME("Test Button") PORT_CODE(KEYCODE_W)
- PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_SERVICE) PORT_NAME("Refill Key") PORT_CODE(KEYCODE_R) PORT_TOGGLE
- PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_INTERLOCK) PORT_NAME("Cashbox (Back) Door") PORT_CODE(KEYCODE_Q) PORT_TOGGLE
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Cancel/Collect")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold/Nudge A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold/Nudge B")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold/Nudge C")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Hi")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Lo")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Exchange")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_START1 )
- PORT_START("BLACK2")
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 1")
- PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 2")
- PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 3")
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 4")
- PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 5")
- PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 6")
- PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_OTHER) PORT_NAME("Button 7")
- PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_START1) //Button 8
+ PORT_MODIFY("DIL1")
+ PORT_DIPNAME( 0x01, 0x00, "Play Jingle" ) PORT_DIPLOCATION("DIL1:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( No ) )
+ PORT_DIPNAME( 0x02, 0x00, u8"£8 Advert?" ) PORT_DIPLOCATION("DIL1:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( No ) )
+ PORT_DIPNAME( 0x04, 0x00, "High Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:03")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x08, 0x00, "Low Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:04")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0xF0, 0x00, "Target Percentage (if key not fitted)" )PORT_DIPLOCATION("DIL1:05,06,07,08")
+ PORT_DIPSETTING( 0x00, "Unset (Program Optimum)" )
+ PORT_DIPSETTING( 0x10, "70" )
+ PORT_DIPSETTING( 0x20, "72" )
+ PORT_DIPSETTING( 0x30, "74" )
+ PORT_DIPSETTING( 0x40, "76" )
+ PORT_DIPSETTING( 0x50, "78" )
+ PORT_DIPSETTING( 0x60, "80" )
+ PORT_DIPSETTING( 0x70, "82" )
+ PORT_DIPSETTING( 0x80, "84" )
+ PORT_DIPSETTING( 0x90, "86" )
+ PORT_DIPSETTING( 0xA0, "88" )
+ PORT_DIPSETTING( 0xB0, "90" )
+ PORT_DIPSETTING( 0xC0, "92" )
+ PORT_DIPSETTING( 0xD0, "94" )
+ PORT_DIPSETTING( 0xE0, "96" )
+ PORT_DIPSETTING( 0xF0, "98" )
- PORT_START("DIL1")
- PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:01")
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:02")
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "High Prize Payout proportion (if available)" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( v4cshinf )
+ PORT_INCLUDE( v4mdice )
+
+ PORT_MODIFY("DIL1")
+ PORT_DIPNAME( 0x01, 0x00, "Lower Price of Play?" ) PORT_DIPLOCATION("DIL1:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( No ) )
+ PORT_DIPNAME( 0x02, 0x00, "Higher Price of Play?" ) PORT_DIPLOCATION("DIL1:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( No ) )
PORT_DIPNAME( 0x04, 0x00, "High Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:03")
PORT_DIPSETTING( 0x00, DEF_STR( No ) )
PORT_DIPSETTING( 0x04, DEF_STR( Yes ) )
@@ -1146,17 +1340,80 @@ static INPUT_PORTS_START( bwbvid )
PORT_DIPSETTING( 0xE0, "96" )
PORT_DIPSETTING( 0xF0, "98" )
- PORT_START("DIL2")
- PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:01") //Clear MPU on some machines
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "High Prize Payout proportion (if available)" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout (Token ROMs)" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( v4reno )
+ PORT_INCLUDE( v4mdice )
+
+ PORT_MODIFY("DIL1")
+ PORT_DIPNAME( 0x01, 0x00, "Set Price of Play?" ) PORT_DIPLOCATION("DIL1:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( No ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:03")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:04")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0xF0, 0x00, "Target Percentage (if key not fitted)" )PORT_DIPLOCATION("DIL1:05,06,07,08")
+ PORT_DIPSETTING( 0x00, "Unset (Program Optimum)" )
+ PORT_DIPSETTING( 0x10, "70" )
+ PORT_DIPSETTING( 0x20, "72" )
+ PORT_DIPSETTING( 0x30, "74" )
+ PORT_DIPSETTING( 0x40, "76" )
+ PORT_DIPSETTING( 0x50, "78" )
+ PORT_DIPSETTING( 0x60, "80" )
+ PORT_DIPSETTING( 0x70, "82" )
+ PORT_DIPSETTING( 0x80, "84" )
+ PORT_DIPSETTING( 0x90, "86" )
+ PORT_DIPSETTING( 0xA0, "88" )
+ PORT_DIPSETTING( 0xB0, "90" )
+ PORT_DIPSETTING( 0xC0, "92" )
+ PORT_DIPSETTING( 0xD0, "94" )
+ PORT_DIPSETTING( 0xE0, "96" )
+ PORT_DIPSETTING( 0xF0, "98" )
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
PORT_DIPSETTING( 0x00, DEF_STR( No ) )
PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x04, DEF_STR( On ) )
- PORT_DIPNAME( 0x08, 0x08, "High Prize Payout proportion (if available)" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPNAME( 0x08, 0x00, "High Prize Payout proportion (if available)" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
PORT_DIPSETTING( 0x00, DEF_STR( No ) )
PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
@@ -1165,58 +1422,373 @@ static INPUT_PORTS_START( bwbvid )
PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x20, DEF_STR( On ) )
- PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout (Token ROMs)" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x40, DEF_STR( On ) )
PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
PORT_DIPSETTING( 0x80, DEF_STR( On ) )
- PORT_START("AUX1")
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( v4bigfrt )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_BUTTON9) PORT_NAME("Fast/ High Play")
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_START1) PORT_NAME("Start 1")
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Cancel/Collect")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold/Nudge A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hi")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold/Nudge B")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Lo")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Hold/Nudge C")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Take It")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) PORT_NAME("Leave It")
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "Inhibit Attract Mode" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( v4bubbnk )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("BLACK1")
PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_UNUSED)
PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_START("AUX2")
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_CUSTOM) //Lockouts, in same order as below
- PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_CUSTOM)
- PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_CUSTOM)
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_COIN5) PORT_NAME("Token")// If valid, then 0x04 is unused, 0x01 is token lockout, 0x02 is all other lockouts.
- PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_COIN1) PORT_NAME("10p")
- PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_COIN2) PORT_NAME("20p")
- PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_COIN3) PORT_NAME("50p")
- PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_COIN4) PORT_NAME("100p")
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Cancel/Nudge Up")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold B")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold C")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Swop")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Hi")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Lo")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_START1 )
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "Inhibit Attract Mode" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout (Token ROMs)" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
INPUT_PORTS_END
+static INPUT_PORTS_START( v4dbltak )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_BUTTON9) PORT_NAME("Swop")
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_START1)
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
-static INPUT_PORTS_START( v4mdice )
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Cancel/Collect")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold B")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold C")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Hold D")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Hold E")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Hi/Twist")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) PORT_NAME("Lo/Stick")
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "High Prize Percentage?" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( No ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( Yes ) )
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( v4mazbel )
PORT_INCLUDE( bwbvid )
- PORT_MODIFY("ORANGE1")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_CUSTOM )// 20p level
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token bottom level
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM )// 100p level
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM )// Long token bottom level
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_CUSTOM )// Prize token level sensor
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_CUSTOM )// Short token top level
- PORT_BIT( 0xc0, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_MODIFY("BLACK1")
- PORT_BIT( 0x0f, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
PORT_MODIFY("BLACK2")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Cancel/Collect")
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold/Nudge A")
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold/Nudge B")
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold/Nudge C")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Collect/Cancel")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold B")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold C")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Hold/Swop")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Hi/Up")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Lo/Down")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_START1 )
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "Inhibit Attract Mode" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( v4redhtp )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_BUTTON9) PORT_NAME("Swop")
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_START1) PORT_NAME("Deal/Draw")
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Collect")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold B")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Hold C")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Hold D")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Hold E")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Hi")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 ) PORT_NAME("Lo")
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "Inhibit Attract Mode" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( v4shpwnd )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Start (L)")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Hold A")
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Hold B")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Hold C")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Cancel")
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Collect")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_START2 ) PORT_NAME("Auto Start")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_START3 ) PORT_NAME("Start (R)")
+
+ PORT_MODIFY("DIL1")
+ PORT_DIPNAME( 0x01, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL1:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, "Price of Play" ) PORT_DIPLOCATION("DIL1:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( Low ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( High ) )
+ PORT_DIPNAME( 0x04, 0x00, "High Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:03")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x08, 0x00, "Low Token Payout Proportion" ) PORT_DIPLOCATION("DIL1:04")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0xF0, 0x00, "Target Percentage (if key not fitted)" )PORT_DIPLOCATION("DIL1:05,06,07,08")
+ PORT_DIPSETTING( 0x00, "Unset (Program Optimum)" )
+ PORT_DIPSETTING( 0x10, "70" )
+ PORT_DIPSETTING( 0x20, "72" )
+ PORT_DIPSETTING( 0x30, "74" )
+ PORT_DIPSETTING( 0x40, "76" )
+ PORT_DIPSETTING( 0x50, "78" )
+ PORT_DIPSETTING( 0x60, "80" )
+ PORT_DIPSETTING( 0x70, "82" )
+ PORT_DIPSETTING( 0x80, "84" )
+ PORT_DIPSETTING( 0x90, "86" )
+ PORT_DIPSETTING( 0xA0, "88" )
+ PORT_DIPSETTING( 0xB0, "90" )
+ PORT_DIPSETTING( 0xC0, "92" )
+ PORT_DIPSETTING( 0xD0, "94" )
+ PORT_DIPSETTING( 0xE0, "96" )
+ PORT_DIPSETTING( 0xF0, "98" )
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "Spin Speed" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, "Normal" )
+ PORT_DIPSETTING( 0x08, "Fast" )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, "Excess Token Lockout (Token games only)" ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( v4timebn )
+ PORT_INCLUDE( bwbvid )
+
+ PORT_MODIFY("BLACK1")
+ PORT_BIT(0x0F, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_CUSTOM) // Prize Shelf Opto
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_SERVICE) PORT_NAME("Test Button") PORT_CODE(KEYCODE_W)
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_SERVICE) PORT_NAME("Refill Key") PORT_CODE(KEYCODE_R) PORT_TOGGLE
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_INTERLOCK) PORT_NAME("Cashbox (Back) Door") PORT_CODE(KEYCODE_Q) PORT_TOGGLE
+
+ PORT_MODIFY("BLACK2")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Collect")
+ //Will show as 'unused' in test, but give response when connected
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED )
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Hi")
PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Lo")
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Exchange")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 ) PORT_NAME("Luck")
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_START1 )
+
+ PORT_MODIFY("DIL2")
+ PORT_DIPNAME( 0x01, 0x00, "Clear MPU Memory" ) PORT_DIPLOCATION("DIL2:01")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x02, 0x00, "Enable Cash Refill") PORT_DIPLOCATION("DIL2:02")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x04, 0x00, "Inhibit Win Banking" ) PORT_DIPLOCATION("DIL2:03") //If on, wins are paid live, as opposed to stored
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, "Inhibit Attract Mode" ) PORT_DIPLOCATION("DIL2:04") //Non Prize machines use this to inhibit OCD attract mode
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, "Halt Payout when Empty" ) PORT_DIPLOCATION("DIL2:05")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Yes ) )
+ PORT_DIPNAME( 0x20, 0x00, "Coin Alarm Inhibit" ) PORT_DIPLOCATION("DIL2:06")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unused ) ) PORT_DIPLOCATION("DIL2:07") //If an 'arcade' ROM, this flips, or is unused entirely.
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, "Single Credit Entry" ) PORT_DIPLOCATION("DIL2:08")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
INPUT_PORTS_END
@@ -1323,7 +1895,7 @@ void mpu4vid_state::bwbvid_68k_map(address_map &map)
map(0xe01000, 0xe0100f).rw(m_ptm, FUNC(ptm6840_device::read), FUNC(ptm6840_device::write)).umask16(0x00ff);
}
-void mpu4vid_state::bwbvid5_68k_map(address_map &map)
+void mpu4vid_state::bwbvidoki_68k_map(address_map &map)
{
map(0x000000, 0x7fffff).rom();
map(0x800000, 0x80ffff).ram().share("vid_mainram");
@@ -1338,10 +1910,10 @@ void mpu4vid_state::bwbvid5_68k_map(address_map &map)
map(0xc00000, 0xc1ffff).rw(FUNC(mpu4vid_state::mpu4_vid_vidram_r), FUNC(mpu4vid_state::mpu4_vid_vidram_w)).share("vid_vidram");
map(0xe00000, 0xe00003).rw(m_acia_1, FUNC(acia6850_device::read), FUNC(acia6850_device::write)).umask16(0x00ff);
map(0xe01000, 0xe0100f).rw(m_ptm, FUNC(ptm6840_device::read), FUNC(ptm6840_device::write)).umask16(0x00ff);
- map(0xe02000, 0xe02007).rw("pia_ic4ss", FUNC(pia6821_device::read), FUNC(pia6821_device::write)).umask16(0xff00); //Seems odd...
+ map(0xe02000, 0xe02007).rw("pia_ic4ss", FUNC(pia6821_device::read), FUNC(pia6821_device::write)).umask16(0xff00);
map(0xe03000, 0xe0300f).r("ptm_ic3ss", FUNC(ptm6840_device::read)).umask16(0xff00); // 6840PTM on sampled sound board
map(0xe03000, 0xe0300f).w(FUNC(mpu4vid_state::ic3ss_vid_w)).umask16(0xff00); // 6840PTM on sampled sound board
- map(0xe04000, 0xe0400f).rw(FUNC(mpu4vid_state::bwb_characteriser_r), FUNC(mpu4vid_state::bwb_characteriser_w)).umask16(0x00ff); // CHR ?
+ map(0xe05000, 0xe05001).noprw();
}
/* TODO: Fix up MPU4 map*/
@@ -1402,7 +1974,6 @@ void mpu4vid_state::ic3ss_vid_w(offs_t offset, uint8_t data)
int denom2 = denom1 + 0.5f;//need to round up, this gives same precision as chip
int freq=num*denom2;
-
if (freq)
{
m_msm6376->set_unscaled_clock(freq);
@@ -1426,6 +1997,7 @@ void mpu4vid_state::mpu4_vid(machine_config &config)
mpu4_common(config);
+
/* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
screen.set_raw(VIDEO_MASTER_CLOCK, (63*8)+(17*8), 0, (63*8), (37*8)+17, 0, (37*8));
@@ -1500,12 +2072,16 @@ void mpu4vid_state::vid_oki(machine_config &config)
//m_ptm_ic3ss->o3_callback().set("ptm_ic3ss", FUNC(ptm6840_device::set_g1));
//m_ptm_ic3ss->irq_callback().set(FUNC(mpu4_state::cpu1_ptm_irq));
- pia6821_device &pia_ic4ss(PIA6821(config, "pia_ic4ss", 0));
- pia_ic4ss.readpb_handler().set(FUNC(mpu4vid_state::pia_gb_portb_r));
- pia_ic4ss.writepa_handler().set(FUNC(mpu4vid_state::pia_gb_porta_w));
- pia_ic4ss.writepb_handler().set(FUNC(mpu4vid_state::pia_gb_portb_w));
- pia_ic4ss.ca2_handler().set(FUNC(mpu4vid_state::pia_gb_ca2_w));
- pia_ic4ss.cb2_handler().set(FUNC(mpu4vid_state::pia_gb_cb2_w));
+ PIA6821(config, m_pia_ic4ss, 0);
+ m_pia_ic4ss->readpb_handler().set(FUNC(mpu4vid_state::pia_gb_portb_r));
+ m_pia_ic4ss->writepa_handler().set(FUNC(mpu4vid_state::pia_gb_porta_w));
+ m_pia_ic4ss->writepb_handler().set(FUNC(mpu4vid_state::pia_gb_portb_w));
+ m_pia_ic4ss->ca2_handler().set(FUNC(mpu4vid_state::pia_gb_ca2_w));
+ m_pia_ic4ss->cb2_handler().set(FUNC(mpu4vid_state::pia_gb_cb2_w));
+
+ okim6376_device &msm6376(OKIM6376(config, "msm6376", 128000)); //Adjusted by IC3 on sound board
+ msm6376.add_route(0, "lspeaker", 0.5);
+ msm6376.add_route(1, "rspeaker", 0.5);
}
void mpu4vid_state::mating(machine_config &config)
@@ -1513,12 +2089,9 @@ void mpu4vid_state::mating(machine_config &config)
crmaze(config);
vid_oki(config);
m_videocpu->set_addrmap(AS_PROGRAM, &mpu4vid_state::mpu4oki_68k_map);
+}
- okim6376_device &msm6376(OKIM6376(config, "msm6376", 128000)); //Adjusted by IC3 on sound board
- msm6376.add_route(0, "lspeaker", 0.5);
- msm6376.add_route(1, "rspeaker", 0.5);
-}
void mpu4vid_state::bwbvid(machine_config &config)
{
@@ -1526,16 +2099,11 @@ void mpu4vid_state::bwbvid(machine_config &config)
m_videocpu->set_addrmap(AS_PROGRAM, &mpu4vid_state::bwbvid_68k_map);
}
-void mpu4vid_state::bwbvid5(machine_config &config)
+void mpu4vid_state::bwbvid_oki(machine_config &config)
{
- bwbvid(config);
- m_videocpu->set_addrmap(AS_PROGRAM, &mpu4vid_state::bwbvid5_68k_map);
-
- mpu4_common2(config);
-
- okim6376_device &msm6376(OKIM6376(config, "msm6376", 128000)); //?
- msm6376.add_route(0, "lspeaker", 0.5);
- msm6376.add_route(1, "rspeaker", 0.5);
+ mpu4_vid(config);
+ m_videocpu->set_addrmap(AS_PROGRAM, &mpu4vid_state::bwbvidoki_68k_map);
+ vid_oki(config);
}
/*
@@ -8107,13 +8675,13 @@ GAMEL( 199?, v4barqstd, v4barqst, mpu4_vid_strike, barquest, mpu4vid_state,
/* Quiz games - Questions not decoded properly on games below (no complete characteriser table) */
-GAME( 199?, v4turnov, v4bios, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v2.3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4turnova, v4turnov, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v2.33) (MPU4 Video)",GAME_FLAGS ) // the 2nd 3 is likely be a machine type, because much like Strike It Lucky and Wize Move the pairing 68k ROM doesn't change
-GAME( 199?, v4turnovc, v4turnov, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v2.3O) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4turnovd, v4turnov, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v?.?) (MPU4 Video)",GAME_FLAGS ) // only have a single program ROM
+GAME( 199?, v4turnov, v4bios, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v2.3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4turnova, v4turnov, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v2.33) (MPU4 Video)",GAME_FLAGS ) // the 2nd 3 is likely be a machine type, because much like Strike It Lucky and Wize Move the pairing 68k ROM doesn't change
+GAME( 199?, v4turnovc, v4turnov, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v2.3O) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4turnovd, v4turnov, mpu4_vid, turnover, mpu4vid_state, init_turnover, ROT0, "Barcrest","Turnover (v?.?) (MPU4 Video)",GAME_FLAGS ) // only have a single program ROM
-GAME( 1990, v4skltrk, v4bios, mpu4_vid, skiltrek, mpu4vid_state, init_skiltrek, ROT0, "Barcrest","Skill Trek (v1.1) (MPU4 Video, set 1)",GAME_FLAGS ) // 10 pound max
-GAME( 1990, v4skltrka, v4skltrk, mpu4_vid, skiltrek, mpu4vid_state, init_skiltrek, ROT0, "Barcrest","Skill Trek (v1.1) (MPU4 Video, set 2)",GAME_FLAGS ) // 12 pound max
+GAME( 1990, v4skltrk, v4bios, mpu4_vid, skiltrek, mpu4vid_state, init_skiltrek, ROT0, "Barcrest","Skill Trek (v1.1) (MPU4 Video, set 1)",GAME_FLAGS ) // 10 pound max
+GAME( 1990, v4skltrka, v4skltrk, mpu4_vid, skiltrek, mpu4vid_state, init_skiltrek, ROT0, "Barcrest","Skill Trek (v1.1) (MPU4 Video, set 2)",GAME_FLAGS ) // 12 pound max
GAME( 1989, v4tmach, v4bios, mpu4_vid, skiltrek, mpu4vid_state, init_timemchn, ROT0, "Barcrest","Time Machine (v2.0) (Issue 3 Questions) (MPU4 Video)",GAME_FLAGS )
GAME( 1989, v4tmachd, v4tmach, mpu4_vid, skiltrek, mpu4vid_state, init_timemchn, ROT0, "Barcrest","Time Machine (v2.0) (Issue 3 Questions) (Datapak) (MPU4 Video)",GAME_FLAGS )
@@ -8154,15 +8722,14 @@ GAME( 1991, v4opt3d, v4opt3, mpu4_vid, mpu4vid, mpu4vid_state, init_v4
/* Games below are newer BWB games and use their own game and revision specific MPU4 base ROMs (which must be correctly paired with video ROMs of the same revision) and sometimes differing hardware setups */
/* ---------------------------------------------------------------- */
-// "payout shelf unplugged", can be bypassed by opening door
-GAME( 1991, v4psi, 0, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 20\" Version 1.1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1991, v4psid, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 20\" Version 1.1) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAMEL( 1991, v4psi, 0, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 20\" Version 1.1) (MPU4 Video)",GAME_FLAGS,layout_v4psi )
+GAMEL( 1991, v4psid, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 20\" Version 1.1) (Datapak) (MPU4 Video)",GAME_FLAGS,layout_v4psi )
// the 68k ROMs are bad on these (one missing)
-GAME( 1991, v4psi14, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 14\" Version 1.1, set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1991, v4psi14a, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 14\" Version 1.1, set 2) (MPU4 Video)",GAME_FLAGS )
+GAMEL( 1991, v4psi14, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 14\" Version 1.1, set 1) (MPU4 Video)",GAME_FLAGS,layout_v4psi )
+GAMEL( 1991, v4psi14a, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB", u8"Prize Space Invaders (BWB IN2, £20, 50p/30p Play, 14\" Version 1.1, set 2) (MPU4 Video)",GAME_FLAGS,layout_v4psi )
// these show BWB and Barcrest (older game release 'INV1' but higher version of it)
-GAME( 1991, v4psibc, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB / Barcrest","Prize Space Invaders (BWB INV1, 50p/30p Play, Version 1.2) (MPU4 Video)",GAME_FLAGS_OK )
-GAME( 1991, v4psibcd, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB / Barcrest","Prize Space Invaders (BWB INV1, 50p/30p Play, Version 1.2) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAMEL( 1991, v4psibc, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB / Barcrest","Prize Space Invaders (BWB INV1, 50p/30p Play, Version 1.2) (MPU4 Video)",GAME_FLAGS_OK,layout_v4psi )
+GAMEL( 1991, v4psibcd, v4psi, bwbvid, v4psi, mpu4vid_state, init_prizeinv, ROT0, "BWB / Barcrest","Prize Space Invaders (BWB INV1, 50p/30p Play, Version 1.2) (Datapak) (MPU4 Video)",GAME_FLAGS,layout_v4psi )
// Tetris games, these were all sold as different machines so are not set as clones
@@ -8177,10 +8744,10 @@ GAME( 1994, v4pzteta, v4pztet, bwbvid, v4pztet, mpu4vid_state, init_b
GAME( 1994, v4pztetb, v4pztet, bwbvid, v4pztet, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Prize Tetris (BWB) (Showcase) (MPU4 Video)",GAME_FLAGS_OK ) // screen telling you to exchange tickets for prizes in the 'showcase' during attract
GAME( 1994, v4pztetc, v4pztet, bwbvid, v4pztet, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Prize Tetris (BWB) (Showcase) (Datapak) (MPU4 Video)",GAME_FLAGS )
// this appears to be a version of Prize Tetris without the Tetris license. These don't have proper alarms, eg coin1 stuck is 'undefined'
-GAME( 1994, v4bulblx, 0, bwbvid, v4pztet, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1994, v4bulblxb, v4bulblx, bwbvid, v4pztet, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1994, v4bulblxa, v4bulblx, bwbvid, v4pztet, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1994, v4bulblxc, v4bulblx, bwbvid, v4pztet, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1994, v4bulblx, 0, bwbvid, v4bulblx, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1994, v4bulblxb, v4bulblx, bwbvid, v4bulblx, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1994, v4bulblxa, v4bulblx, bwbvid, v4bulblx, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1994, v4bulblxc, v4bulblx, bwbvid, v4bulblx, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Bullion Blox (BWB) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
// doesn't have payout so no shelf error (no payout on prototype?), runs with door closed
@@ -8188,348 +8755,350 @@ GAME( 199?, v4vgpok, 0, bwbvid, v4vgpok, mpu4vid_state, init_b
// boot and run
-GAME( 199?, v4redhtp, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpk, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpl, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpm, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpo, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpp, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpq, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 5) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpn, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpr, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtps, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpx, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpt, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpu, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpw, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpy, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpz, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 5) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpv, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpaa, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpb, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpg, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpc, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpd, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpf, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpi, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtph, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 5) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpe, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpj, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpab, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fxed, All-Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4redhtpa, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtp, 0, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpk, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpl, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpm, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpo, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpp, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpq, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, Datapak) (set 5) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpn, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpr, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Fixed, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtps, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpx, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpt, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpu, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpw, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpy, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpz, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 5) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpv, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpaa, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpb, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpg, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpc, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpd, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpf, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpi, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtph, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, Datapak) (set 5) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpe, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpj, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fixed, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpab, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 10p Fxed, All-Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpa, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 3, 20p Switchable to 10p, All - Cash) (MPU4 Video)",GAME_FLAGS )
// 'version 1.9' 68k ROMs - different numbering format?
-GAME( 199?, v4redhtparc,v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Arcade, Cash+Tokens, 1993 Awards, 20p Fixed, Version 1.9) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtparc,v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Arcade, Cash+Tokens, 1993 Awards, 20p Fixed, Version 1.9) (MPU4 Video)",GAME_FLAGS )
// release 2 68k ROMs
-GAME( 1993, v4redhtp2, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copyright, 5p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2a, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2b, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2c, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2e, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2f, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2d, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1993, v4redhtp2g, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copyright, 5p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2a, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2b, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2c, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2e, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2f, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, Datapak) (set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2d, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, % Key) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1993, v4redhtp2g, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1993 copryight, 5p Fixed, Cash+Token, % Key) (set 2) (MPU4 Video)",GAME_FLAGS )
// this is older despite still being 'release 2'
-GAME( 1992, v4redhtp2z, v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1992 copyright, 20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 1992, v4redhtp2z, v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (Release 2, 1992 copyright, 20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
// no matching 68k ROMs for this one
-GAME( 199?, v4redhtpunk,v4redhtp, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (unknown release) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4bubbnk, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bubbnkb, v4bubbnk, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bubbnkc, v4bubbnk, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bubbnkd, v4bubbnk, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bubbnka, v4bubbnk, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4ovrmn3, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4ovrmn3a, v4ovrmn3, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4ovrmn3b, v4ovrmn3, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4ovrmn3c, v4ovrmn3, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4ovrmn3d, v4ovrmn3, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4mazbel, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Mazooma Belle (v2.5 DY, S/Site, Cash+Token, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4mazbel15, v4mazbel, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Mazooma Belle (v1.5) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4mazbel15a,v4mazbel, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Mazooma Belle (v1.5) (set 2) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4rhmaz, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmaza, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 10p Fixed, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazb, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 10p Fixed, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazc, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazd, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS ) // B
-GAME( 199?, v4rhmaze, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS ) // BL
-GAME( 199?, v4rhmazf, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazg, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazh, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Switchable to 10p, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazi, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Switchable to 10p, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazj, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 20p Switchable to 10p, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4rhmazk, v4rhmaz, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 C, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4shpwnd, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndi, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwnde, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndf, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndh, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndg, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwnda, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndb, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndc, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndd, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndj, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndk, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndl, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4shpwndm, v4shpwnd, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token, % Key) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4sixx, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxa, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxe, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxb, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxd, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxf, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxc, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxg, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxh, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxi, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxj, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxk, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxl, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Switchable to 10p, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sixxm, v4sixx, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","6-X (BWB) (Release 3, 20p Switchable to 10p, All - Cash, Datapak) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4cshinf, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfd, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfg, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfe, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfi, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfk, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfh, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Showcase) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinff, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Showcase, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfj, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Showcase, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfl, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfm, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfr, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfo, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfp, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfs, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfn, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Showcase) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfq, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfu, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfw, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, All - Cash, Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfb, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 10p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinfa, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 5p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4redhtpunk,v4redhtp, bwbvid, v4redhtp, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Poker (unknown release) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4bubbnk, 0, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bubbnkb, v4bubbnk, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bubbnkc, v4bubbnk, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bubbnkd, v4bubbnk, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bubbnka, v4bubbnk, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Bubbly Bonk (v4.0?) (20p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4ovrmn3, 0, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4ovrmn3a, v4ovrmn3, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4ovrmn3b, v4ovrmn3, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4ovrmn3c, v4ovrmn3, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4ovrmn3d, v4ovrmn3, bwbvid, v4bubbnk, mpu4vid_state, init_bwbhack, ROT0, "BWB","Over Moon Pt3 (BWB) (20p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4mazbel, 0, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Mazooma Belle (v2.5 DY, S/Site, Cash+Token, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4mazbel15, v4mazbel, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Mazooma Belle (v1.5) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4mazbel15a,v4mazbel, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Mazooma Belle (v1.5) (set 2) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4rhmaz, 0, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmaza, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 10p Fixed, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazb, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 10p Fixed, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazc, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazd, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS ) // B
+GAME( 199?, v4rhmaze, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS ) // BL
+GAME( 199?, v4rhmazf, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazg, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazh, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Switchable to 10p, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazi, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Switchable to 10p, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazj, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 20p Switchable to 10p, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4rhmazk, v4rhmaz, bwbvid, v4mazbel, mpu4vid_state, init_bwbhack, ROT0, "BWB","Red Hot Mazooma Belle (BWB) (Version 1.4 C, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4shpwnd, 0, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndi, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwnde, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndf, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndh, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndg, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Fixed, Cash + Special BWB Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwnda, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndb, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndc, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndd, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 10p Fixed, Cash + Special BWB Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndj, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndk, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndl, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4shpwndm, v4shpwnd, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB","Shop Window (v2.0) (Release 2, 20p Switchable to 10p, Cash + Special BWB Token, % Key) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4sixx, 0, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxa, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxe, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxb, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxd, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxf, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxc, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxg, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxh, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxi, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxj, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Switchable to 10p, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxk, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxl, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Switchable to 10p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sixxm, v4sixx, bwbvid, v4shpwnd, mpu4vid_state, init_bwbhack, ROT0, "BWB",u8"£6-X (BWB) (Release 3, 20p Switchable to 10p, All - Cash, Datapak) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4cshinf, 0, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfd, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfg, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfe, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfi, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfk, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfh, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Showcase) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinff, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Showcase, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfj, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, Showcase, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfl, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Fixed, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfm, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfr, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfo, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfp, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfs, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfn, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, Showcase) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfq, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, Cash+Token, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfu, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfw, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 20p Switchable 20p/10p/5p, All - Cash, Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfb, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 10p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinfa, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 4, 5p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
// no 68k program is dumped for Release 3
-GAME( 199?, v4cshinf3, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 3) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4cshinf3a, v4cshinf, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 3) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinf3, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 3) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cshinf3a, v4cshinf, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Cash Inferno (BWB) (Release 3) (set 2) (MPU4 Video)",GAME_FLAGS )
// the onscreen 'version' display doesn't quite align with the labels, 'DY' seems to be represented as 'B' on the labels, rather than the individual flags?
// the labels seem closer to the Barcrest standard used on MPU4 fruit machines
-GAME( 199?, v4sunbst, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbsta, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstb, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash + Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstc, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstd, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstk, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Fixed) (set 2) (MPU4 Video)",GAME_FLAGS ) // BT
-GAME( 199?, v4sunbste, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed) (set 1) (MPU4 Video)",GAME_FLAGS ) // B
-GAME( 199?, v4sunbstf, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed) (set 2) (MPU4 Video)",GAME_FLAGS ) // BL
-GAME( 199?, v4sunbstg, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed) (set 1) (MPU4 Video)",GAME_FLAGS ) // D
-GAME( 199?, v4sunbsth, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed) (set 2) (MPU4 Video)",GAME_FLAGS ) // DL
-GAME( 199?, v4sunbsti, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 20p Fixed, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstj, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstl, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Switchable to 10p) (set 1) (MPU4 Video)",GAME_FLAGS ) // XC
-GAME( 199?, v4sunbstm, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Switchable to 10p) (set 2) (MPU4 Video)",GAME_FLAGS ) // XC L
-GAME( 199?, v4sunbstn, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbsto, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Switchable to 10p (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstp, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstq, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 20p Switchable to 10p, % Key) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstr, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 C, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbsts, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 C, 1993 Awards, 20p Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstt, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 C, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4sunbstu, v4sunbst, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 IC, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4bigfrt, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bigfrta, v4bigfrt, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bigfrtb, v4bigfrt, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4bigfrtc, v4bigfrt, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 4) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 1996, v4reno, 0, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, All - Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoa, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, All - Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renom, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoe, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoi, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renol, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoc, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renog, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renok, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renod, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoh, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renof, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 1) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoj, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 2) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoo, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 25p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renon, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 25p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renoq, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/25p, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renop, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/25p, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renob, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renos, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renou, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renor, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (Showcase) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1996, v4renot, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (Showcase) (set 2) (MPU4 Video)",GAME_FLAGS )
+// gfx look wrong in test mode, uses BT chip?
+GAME( 199?, v4sunbst, 0, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbsta, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstb, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash + Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstc, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstd, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstk, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Fixed) (set 2) (MPU4 Video)",GAME_FLAGS ) // BT
+GAME( 199?, v4sunbste, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed) (set 1) (MPU4 Video)",GAME_FLAGS ) // B
+GAME( 199?, v4sunbstf, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Fixed) (set 2) (MPU4 Video)",GAME_FLAGS ) // BL
+GAME( 199?, v4sunbstg, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed) (set 1) (MPU4 Video)",GAME_FLAGS ) // D
+GAME( 199?, v4sunbsth, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed) (set 2) (MPU4 Video)",GAME_FLAGS ) // DL
+GAME( 199?, v4sunbsti, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 20p Fixed, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstj, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstl, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Switchable to 10p) (set 1) (MPU4 Video)",GAME_FLAGS ) // XC
+GAME( 199?, v4sunbstm, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4, Cash+Token, 1993 Awards, 20p Switchable to 10p) (set 2) (MPU4 Video)",GAME_FLAGS ) // XC L
+GAME( 199?, v4sunbstn, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 DY, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbsto, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Switchable to 10p (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstp, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 D, Cash+Token, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstq, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 Y, Cash+Token, 1993 Awards, 20p Switchable to 10p, % Key) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstr, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 C, 1993 Awards, 10p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbsts, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 C, 1993 Awards, 20p Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstt, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 C, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4sunbstu, v4sunbst, bwbvid, v4cshinf, mpu4vid_state, init_bwbhack, ROT0, "BWB","Sunburst (BWB) (Version 1.4 IC, 1993 Awards, 20p Switchable to 10p) (MPU4 Video)",GAME_FLAGS )
+
+//gfx look wrong in test mode, uses BT chip?
+GAME( 199?, v4bigfrt, 0, bwbvid, v4bigfrt, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bigfrta, v4bigfrt, bwbvid, v4bigfrt, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bigfrtb, v4bigfrt, bwbvid, v4bigfrt, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4bigfrtc, v4bigfrt, bwbvid, v4bigfrt, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big Fruits (v2.0?) (set 4) (MPU4 Video)",GAME_FLAGS )
+
+
+//gfx look wrong in test mode, uses BT chip?
+GAME( 1996, v4reno, 0, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, All - Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoa, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, All - Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renom, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoe, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoi, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renol, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoc, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renog, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renok, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renod, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoh, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renof, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 1) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoj, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Fixed, Cash+Token) (Showcase) (set 2) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoo, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 25p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renon, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 25p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renoq, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/25p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renop, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/25p, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renob, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renos, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renou, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renor, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (Showcase) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4renot, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release A, 20p Switchable 20p/10p/5p, Cash+Token) (Showcase) (set 2) (MPU4 Video)",GAME_FLAGS )
// older 68k version
-GAME( 1996, v4reno8, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release 8, 20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 1996, v4reno8, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release 8, 20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
// 68k ROMs below have no matching base roms
-GAME( 1996, v4reno7, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release 7) (MPU4 Video)",GAME_FLAGS ) // no base ROM
-GAME( 1996, v4reno5, v4reno, bwbvid5, bwbvid, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release 5) (MPU4 Video)",GAME_FLAGS ) // no base ROM
+GAME( 1996, v4reno7, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release 7) (MPU4 Video)",GAME_FLAGS ) // no base ROM
+GAME( 1996, v4reno5, v4reno, bwbvid_oki, v4reno, mpu4vid_state, init_prizeinv, ROT0, "BWB","Reno Reels (Release 5) (MPU4 Video)",GAME_FLAGS ) // no base ROM
// v4big40 sets black screen after the initial boot, are they complete?
-GAME( 199?, v4big40, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40a, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40b, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40c, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40d, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Data) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40e, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Data) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40g, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Standard) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40h, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Standard) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40k, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40i, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data + %-Key) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40j, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data + %-Key) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4big40f, v4big40, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data + %-Key + OCDM) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40, 0, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40a, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40b, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40c, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Standard) (set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40d, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Data) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40e, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (Arcade Data) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40g, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Standard) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40h, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Standard) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40k, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40i, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data + %-Key) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40j, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data + %-Key) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4big40f, v4big40, bwbvid_oki, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Big 40 Poker (BWB) (S_Site Data + %-Key + OCDM) (MPU4 Video)",GAME_FLAGS )
// v4dbltak sets black screen after the initial boot, are they complete?
-GAME( 199?, v4dbltak, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Double Take (BWB) (Release 4, Arcade Standard) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4dbltaka, v4dbltak, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Double Take (BWB) (Release 4, Arcade Data) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4dbltakb, v4dbltak, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Double Take (BWB) (Release 4, S_Site Data + %-Key) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4gldrsh, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, All - Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrsht, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, All - Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshk, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshl, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 25p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshm, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 25p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshn, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/25p, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrsho, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/25p, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshu, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, All - Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshc, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshd, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrsha, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshf, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshb, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshg, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshe, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshj, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshh, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshi, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshp, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshq, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (Showcase) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshr, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (Datapak) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4gldrshs, v4gldrsh, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (Showcase) (Datapak) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 199?, v4timebn, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4timebna, v4timebn, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4timebnc, v4timebn, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4timebnb, v4timebn, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4timebnd, v4timebn, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4timebne, v4timebn, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4dbltak, 0, bwbvid_oki, v4dbltak,mpu4vid_state, init_bwbhack, ROT0, "BWB","Double Take (BWB) (Release 4, Arcade Standard) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4dbltaka, v4dbltak, bwbvid_oki, v4dbltak,mpu4vid_state, init_bwbhack, ROT0, "BWB","Double Take (BWB) (Release 4, Arcade Data) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4dbltakb, v4dbltak, bwbvid_oki, v4dbltak,mpu4vid_state, init_bwbhack, ROT0, "BWB","Double Take (BWB) (Release 4, S_Site Data + %-Key) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4gldrsh, 0, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, All - Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrsht, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, All - Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshk, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshl, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 25p Fixed, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshm, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 25p Fixed, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshn, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/25p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrsho, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/25p, All - Cash) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshu, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, All - Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshc, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshd, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrsha, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshf, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshb, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshg, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshe, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshj, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Showcase) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshh, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshi, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, 20p Fixed, Cash+Token) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshp, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshq, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (Showcase) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshr, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (Datapak) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4gldrshs, v4gldrsh, bwbvid, v4reno, mpu4vid_state, init_bwbhack, ROT0, "BWB","Gold Rush (BWB) (Release 8, Switchable 20p/10p/5p, Cash+Token) (Showcase) (Datapak) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 199?, v4timebn, 0, bwbvid_oki, v4timebn, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4timebna, v4timebn, bwbvid_oki, v4timebn, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4timebnc, v4timebn, bwbvid_oki, v4timebn, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4timebnb, v4timebn, bwbvid_oki, v4timebn, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (Datapak) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4timebnd, v4timebn, bwbvid_oki, v4timebn, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (Datapak) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4timebne, v4timebn, bwbvid_oki, v4timebn, mpu4vid_state, init_bwbhack, ROT0, "BWB","Time Bandit (BWB) (Release 1, 20p Fixed, Cash + Tokens) (Datapak) (set 3) (MPU4 Video)",GAME_FLAGS )
// Release D
-GAME( 199?, v4monte, 0, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Switchable, £8 All Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montea, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Switchable, £10 All Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montee, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Switchable, Cash and Tokens) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monted, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Fixed, £10 All Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteg, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 25p Fixed, £10 All Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montec, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release D, Arcade Special, 20p Fixed, Cash and Tokens) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte, 0, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Switchable, £8 All Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montea, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Switchable, £10 All Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montee, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Switchable, Cash and Tokens) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monted, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 20p Fixed, £10 All Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteg, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release D, S/Site Standard, 25p Fixed, £10 All Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montec, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release D, Arcade Special, 20p Fixed, Cash and Tokens) (MPU4 Video)",GAME_FLAGS )
// Release 9
-GAME( 199?, v4monte9, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, £8 All Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9a, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, £8 All Cash) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9e, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9b, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9f, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, £10 All Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9n, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, £10 All Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9j, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, £10 All Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9k, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, £10 All Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9l, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 25p Fixed, £10 All Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9m, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 25p Fixed, £10 All Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9o, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9i, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9c, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9d, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9h, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monte9g, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, £8 All Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9a, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, £8 All Cash) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9e, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9b, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9f, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, £10 All Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9n, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Switchable, £10 All Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9j, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, £10 All Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9k, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, £10 All Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9l, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 25p Fixed, £10 All Cash) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9m, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 25p Fixed, £10 All Cash) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9o, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9i, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, S/Site Standard, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9c, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9d, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Switchable, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9h, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monte9g, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", "Monte Carlo Or Bust (BWB) (Release 9, Arcade Special, Options 4 Cabinet, 20p Fixed, Cash and Tokens) (set 2) (MPU4 Video)",GAME_FLAGS )
// no suitable 68k ROMs for these
-GAME( 199?, v4monteh, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montei, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montej, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montek, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montel, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 5) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montem, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 6) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monten, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 7) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteo, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 8) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montep, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 9) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteq, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 10) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monter, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 11) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montes, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 12) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montet, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 13) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteu, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 14) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montev, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 15) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montew, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 16) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montex, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 17) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montey, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 18) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montez, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 19) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteaa, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 20) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteab, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 21) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteac, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 22) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montead, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 23) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteae, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 24) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteaf, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 25) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteag, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 26) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteah, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 27) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteai, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 28) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteaj, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 29) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteak, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 30) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteal, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 31) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteam, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 32) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4montean, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 33) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4monteao, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 34) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteh, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montei, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montej, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montek, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montel, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 5) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montem, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 6) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monten, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 7) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteo, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 8) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montep, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 9) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteq, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 10) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monter, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 11) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montes, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 12) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montet, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 13) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteu, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 14) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montev, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 15) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montew, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 16) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montex, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 17) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montey, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 18) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montez, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 19) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteaa, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 20) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteab, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 21) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteac, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 22) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montead, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 23) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteae, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 24) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteaf, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 25) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteag, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 26) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteah, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 27) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteai, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 28) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteaj, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 29) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteak, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 30) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteal, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 31) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteam, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 32) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montean, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 33) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4monteao, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 34) (MPU4 Video)",GAME_FLAGS )
// only have a single loose 68k ROM from this which doesn't match any other set
-GAME( 199?, v4montezz, v4monte, bwbvid, bwbvid, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 35) (MPU4 Video)",GAME_FLAGS )
-
-
-GAME( 1995, v4mdice, 0, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 25p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicee, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicep, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiceq, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicer, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£10 Cash - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiceu, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 25p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicev, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 25p-£10 Cash - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicei, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicej, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicel, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicem, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 4) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicek, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Showcase, 20p-£8 Token - Fixed) (set 5) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicea, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 5p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiceb, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 10p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiced, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicew, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£8 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicen, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiceo, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdices, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 25p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicet, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 25p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicec, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 10p-£8 Token - Fixed) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdicef, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£8 Token - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiceh, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£8 Token - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
-GAME( 1995, v4mdiceg, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Showcase, 20p-£8 Token - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4montezz, v4monte, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Monte Carlo Or Bust (BWB) (Release ?, set 35) (MPU4 Video)",GAME_FLAGS )
+
+
+GAME( 1995, v4mdice, 0, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 25p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicee, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicep, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiceq, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicer, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£10 Cash - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiceu, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 25p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicev, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 25p-£10 Cash - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicei, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicej, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicel, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicem, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Standard, 20p-£8 Token - Fixed) (set 4) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicek, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, S/Site Showcase, 20p-£8 Token - Fixed) (set 5) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicea, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 5p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiceb, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 10p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiced, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£4 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicew, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£8 Cash - Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicen, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiceo, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdices, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 25p-£10 Cash - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicet, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 25p-£10 Cash - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicec, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 10p-£8 Token - Fixed) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdicef, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£8 Token - Fixed) (set 1) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiceh, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Standard, 20p-£8 Token - Fixed) (set 2) (MPU4 Video)",GAME_FLAGS )
+GAME( 1995, v4mdiceg, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB", u8"Miami Dice (BWB) (Release 8, Arcade Showcase, 20p-£8 Token - Fixed) (set 3) (MPU4 Video)",GAME_FLAGS )
// no base ROMs, only 68k ROMs dumped for Release 5
-GAME( 1995, v4mdice5, v4mdice, bwbvid, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Miami Dice (BWB) (Release 5) (MPU4 Video)",GAME_FLAGS ) // no base ROM
+GAME( 1995, v4mdice5, v4mdice, bwbvid_oki, v4mdice, mpu4vid_state, init_bwbhack, ROT0, "BWB","Miami Dice (BWB) (Release 5) (MPU4 Video)",GAME_FLAGS ) // no base ROM
// this is a German version of v4mdice, produced by Nova
-GAME( 199?, v4mdiceger, v4mdice, bwbvid5, mpu4, mpu4vid_state, init_bwbhack, ROT0, "Nova","Miami Dice (Nova, German) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4mdiceger, v4mdice, bwbvid_oki, mpu4, mpu4vid_state, init_bwbhack, ROT0, "Nova","Miami Dice (Nova, German) (MPU4 Video)",GAME_FLAGS )
// other issues
@@ -8567,9 +9136,9 @@ GAME( 199?, v4frfactf, v4frfact, crmaze, crmaze, mpu4vid_state, init_bwb
/* All contain BWB video in the BIOS rom tho */
/* These seem to use the other palette chip (BT471). and use the German BWB bank setup, so may need more work */
-GAME( 199?, v4cybcas, 0, bwbvid5, mpu4, mpu4vid_state, init_cybcas, ROT0, "Nova","Cyber Casino (Nova, German) (MPU4 Video)",GAME_FLAGS )
+GAME( 199?, v4cybcas, 0, bwbvid_oki, mpu4, mpu4vid_state, init_cybcas, ROT0, "Nova","Cyber Casino (Nova, German) (MPU4 Video)",GAME_FLAGS )
-GAME( 199?, v4missis, 0, bwbvid5, mpu4, mpu4vid_state, init_bwbhack, ROT0, "Nova","Mississippi Lady (Nova, German) (MPU4 Video)",GAME_FLAGS ) // different hardware type? extra ram on mpu4 side?
+GAME( 199?, v4missis, 0, bwbvid_oki, mpu4, mpu4vid_state, init_bwbhack, ROT0, "Nova","Mississippi Lady (Nova, German) (MPU4 Video)",GAME_FLAGS ) // different hardware type? extra ram on mpu4 side?
-GAME( 199?, v4picdil, 0, bwbvid5, mpu4, mpu4vid_state, init_bwbhack, ROT0, "Nova","Piccadilly Nights (Nova, German) (MPU4 Video)",GAME_FLAGS ) // different hardware type? extra ram on mpu4 side?
+GAME( 199?, v4picdil, 0, bwbvid_oki, mpu4, mpu4vid_state, init_bwbhack, ROT0, "Nova","Piccadilly Nights (Nova, German) (MPU4 Video)",GAME_FLAGS ) // different hardware type? extra ram on mpu4 side?
diff --git a/src/mame/drivers/nes_sh6578.cpp b/src/mame/drivers/nes_sh6578.cpp
index c23707dfc2e..497884a1bf1 100644
--- a/src/mame/drivers/nes_sh6578.cpp
+++ b/src/mame/drivers/nes_sh6578.cpp
@@ -35,9 +35,9 @@ class nes_sh6578_state : public driver_device
public:
nes_sh6578_state(const machine_config& mconfig, device_type type, const char* tag) :
driver_device(mconfig, type, tag),
+ m_bank(*this, "cartbank"),
m_maincpu(*this, "maincpu"),
m_ppu(*this, "ppu"),
- m_bank(*this, "cartbank"),
m_fullrom(*this, "fullrom"),
m_screen(*this, "screen"),
m_apu(*this, "nesapu"),
@@ -57,10 +57,14 @@ protected:
void sprite_dma_w(address_space &space, uint8_t data);
+ virtual void io_w(uint8_t data);
+ virtual void extio_w(uint8_t data);
+ bool m_isbanked;
+ required_memory_bank m_bank;
+
private:
required_device<cpu_device> m_maincpu;
required_device<ppu_sh6578_device> m_ppu;
- required_memory_bank m_bank;
required_device<address_map_bank_device> m_fullrom;
required_device<screen_device> m_screen;
required_device<nesapu_device> m_apu;
@@ -101,7 +105,6 @@ private:
uint8_t io0_r();
uint8_t io1_r();
- void io_w(uint8_t data);
uint8_t psg1_4014_r();
uint8_t psg1_4015_r();
@@ -138,11 +141,31 @@ private:
// this might be game specific
uint8_t m_previo;
uint8_t m_iolatch[2];
- bool m_isbanked;
required_ioport_array<2> m_in;
};
+class nes_sh6578_abl_wikid_state : public nes_sh6578_state
+{
+public:
+ nes_sh6578_abl_wikid_state(const machine_config& mconfig, device_type type, const char* tag) :
+ nes_sh6578_state(mconfig, type, tag)
+ { }
+protected:
+ virtual void io_w(uint8_t data) override;
+};
+
+class nes_sh6578_max10in1_state : public nes_sh6578_state
+{
+public:
+ nes_sh6578_max10in1_state(const machine_config& mconfig, device_type type, const char* tag) :
+ nes_sh6578_state(mconfig, type, tag)
+ { }
+
+protected:
+ virtual void extio_w(uint8_t data) override;
+ virtual void machine_reset() override;
+};
uint8_t nes_sh6578_state::bank_r(int bank, uint16_t offset)
{
@@ -400,14 +423,34 @@ void nes_sh6578_state::io_w(uint8_t data)
}
}
+ m_previo = data;
+}
+
+void nes_sh6578_abl_wikid_state::io_w(uint8_t data)
+{
+ nes_sh6578_state::io_w(data);
+
if (m_isbanked)
{
m_bank->set_entry((data>>1)&1);
}
+}
- m_previo = data;
+void nes_sh6578_state::extio_w(uint8_t data)
+{
+ logerror("%s: extio_w : %02x\n", machine().describe_context(), data);
}
+void nes_sh6578_max10in1_state::extio_w(uint8_t data)
+{
+ logerror("%s: extio_w : %02x (max10in1)\n", machine().describe_context(), data);
+
+ m_bank->set_entry((data & 0x80) >> 7);
+}
+
+
+
+
uint8_t nes_sh6578_state::psg1_4014_r()
{
@@ -456,6 +499,13 @@ void nes_sh6578_state::nes_sh6578_map(address_map& map)
map(0x4017, 0x4017).rw(FUNC(nes_sh6578_state::io1_r), FUNC(nes_sh6578_state::psg1_4017_w));
map(0x4020, 0x4020).w(FUNC(nes_sh6578_state::timing_setting_control_w));
+ //4021 write keyboard output port
+ //4022 read/write keyboard data control
+ //4023 read/write joystick,mouse control
+ //4024 read - mouse port / write - mouse baud
+ //4025 write - Printer Port
+ map(0x4026, 0x4026).w(FUNC(nes_sh6578_state::extio_w));
+ //4027 read/write - DAC data register
map(0x4031, 0x4031).w(FUNC(nes_sh6578_state::initial_startup_w));
map(0x4032, 0x4032).w(FUNC(nes_sh6578_state::irq_mask_w));
@@ -512,6 +562,12 @@ void nes_sh6578_state::machine_reset()
m_timerval = 0x00;
}
+void nes_sh6578_max10in1_state::machine_reset()
+{
+ nes_sh6578_state::machine_reset();
+ m_bank->set_entry(1);
+}
+
void nes_sh6578_state::machine_start()
{
m_bank->configure_entry(0, memregion("maincpu")->base() + 0x0000000);
@@ -643,11 +699,21 @@ ROM_START( ablwikid )
ROM_LOAD( "mx29f1610atc.u2", 0x00000, 0x200000, CRC(f16abf79) SHA1(aeccbb40d7fdd451ba8e5cca20464da2cf116461) )
ROM_END
+ROM_START( maxx5in1 )
+ ROM_REGION( 0x100000, "maincpu", ROMREGION_ERASEFF )
+ ROM_LOAD( "vsmaxxcasino5_e28f008sa_89a2.bin", 0x00000, 0x100000, CRC(e3d8f24f) SHA1(121411e72d53eabe6be927d1db2f871d59a9e08e) )
+ROM_END
+
ROM_START( maxx6in1 )
ROM_REGION( 0x100000, "maincpu", ROMREGION_ERASEFF )
ROM_LOAD( "maxx6in1.bin", 0x00000, 0x100000, CRC(8e582298) SHA1(89892b9095dbd5101cdf2477a66abd2cb11ad8c8) )
ROM_END
+ROM_START( max10in1 )
+ ROM_REGION( 0x200000, "maincpu", ROMREGION_ERASEFF )
+ ROM_LOAD( "csmaxxcasino10.bin", 0x000000, 0x200000, CRC(2a05e9af) SHA1(fcf591c22ce8773f72e9d0fa0bae545f6a82a063) )
+ROM_END
+
CONS( 1997, bandgpad, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "Bandai", "Multi Game Player Gamepad", MACHINE_NOT_WORKING )
CONS( 1997, bandggcn, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "Bandai", "Go! Go! Connie-chan! Asobou Mouse", MACHINE_NOT_WORKING )
@@ -657,6 +723,11 @@ CONS( 2001, ts_handy11, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_state, i
CONS( 200?, cpatrolm, 0, 0, nes_sh6578_pal, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "TimeTop", "City Patrolman", MACHINE_NOT_WORKING )
// ROM is banked
-CONS( 200?, ablwikid, 0, 0, nes_sh6578_pal, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "Advance Bright Ltd.", "Wikid Joystick", MACHINE_NOT_WORKING ) // or Wik!d Joystick
+CONS( 200?, ablwikid, 0, 0, nes_sh6578_pal, nes_sh6578, nes_sh6578_abl_wikid_state, init_nes_sh6578, "Advance Bright Ltd.", "Wikid Joystick", MACHINE_NOT_WORKING ) // or Wik!d Joystick
+
+CONS( 200?, maxx5in1, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "Senario", "Vs Maxx 5-in-1 Casino / Senario Card & Casino Games", 0 ) // advertised on box as 'With Solitaire" (was there an even older version without it?)
+
+CONS( 200?, maxx6in1, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "Senario", "Vs Maxx 6-in-1 Casino / Senario Card & Casino Games", 0 ) // advertised on box as "With Texas Hold 'Em" (which is the added game since the 5-in-1)
+
+CONS( 200?, max10in1, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_max10in1_state, init_nes_sh6578, "Senario", "Vs Maxx 10-in-1 Casino / Senario Card & Casino Games", 0 )
-CONS( 200?, maxx6in1, 0, 0, nes_sh6578, nes_sh6578, nes_sh6578_state, init_nes_sh6578, "Senario", "Vs Maxx 6-in-1 Casino / Senario Card & Casino Games", 0 )
diff --git a/src/mame/drivers/nes_vt.cpp b/src/mame/drivers/nes_vt.cpp
index 8a8501ad3a7..2b7680b3051 100644
--- a/src/mame/drivers/nes_vt.cpp
+++ b/src/mame/drivers/nes_vt.cpp
@@ -274,6 +274,8 @@ public:
m_latch1_bit(0)
{ }
+ void init_lxcmcypp();
+
protected:
virtual uint8_t in0_r() override;
virtual uint8_t in1_r() override;
@@ -394,23 +396,6 @@ private:
required_ioport m_plunger;
};
-class nes_vt_sudoku_state : public nes_vt_state
-{
-public:
- nes_vt_sudoku_state(const machine_config& mconfig, device_type type, const char* tag) :
- nes_vt_state(mconfig, type, tag)
- { }
-
- void init_sudoku();
-
- void nes_vt_sudoku_512kb(machine_config& config);
-
-private:
- virtual uint8_t in0_r() override;
- virtual uint8_t in1_r() override;
- virtual void in0_w(uint8_t data) override;
-};
-
class nes_vt_vg_1mb_majgnc_state : public nes_vt_state
{
public:
@@ -724,20 +709,6 @@ void nes_vt_ablpinb_state::in0_w(uint8_t data)
logerror("in0_w %02x\n", data);
}
-uint8_t nes_vt_sudoku_state::in0_r()
-{
- return machine().rand();
-}
-
-uint8_t nes_vt_sudoku_state::in1_r()
-{
- return machine().rand();
-}
-
-void nes_vt_sudoku_state::in0_w(uint8_t data)
-{
-}
-
/* not strictly needed, but helps us see where things are in ROM to aid with figuring out banking schemes*/
static const gfx_layout helper_layout =
@@ -1614,6 +1585,17 @@ ROM_START( lxcmcysp )
ROM_LOAD( "lexibookspiderman.bin", 0x00000, 0x4000000, CRC(ef6e8847) SHA1(0012df193c52fd48595d85886fd431619c5d5e3e) )
ROM_END
+ROM_START( lxcmcycr )
+ ROM_REGION( 0x4000000, "mainrom", 0 )
+ ROM_LOAD( "lexibook cars.bin", 0x00000, 0x4000000, CRC(198fe11b) SHA1(5e35caa3fc319ec69812c187a3ec89f01749f749) )
+ROM_END
+
+ROM_START( lxcmcypp )
+ ROM_REGION( 0x4000000, "mainrom", 0 )
+ // marked 512mbit, possible A22 / A23 are swapped as they were marked on the board in a different way.
+ ROM_LOAD( "pawpatrol_compact.bin", 0x00000, 0x4000000, CRC(bf536762) SHA1(80dde8426a636bae33a82d779e564fa743eb3776) )
+ROM_END
+
ROM_START( lxcmc250 )
ROM_REGION( 0x4000000, "mainrom", 0 )
// sub-board was marked for 2GB capacity (A0-A26 address lines), but only address lines A0-A24 are connected to the chip
@@ -1678,6 +1660,11 @@ ROM_START( duetpp )
ROM_LOAD( "gamesporzduetpingpong.bin", 0x00000, 0x400000, CRC(96af199b) SHA1(c14ff15683545c1edf03376cebcee7ac408da733) )
ROM_END
+ROM_START( sporzbx )
+ ROM_REGION( 0x400000, "mainrom", 0 )
+ ROM_LOAD( "sporzboxing.bin", 0x00000, 0x400000, CRC(8b832c0b) SHA1(8193955a81e894a01308a80d5153f2ecfe134da6) )
+ROM_END
+
ROM_START( lpgm240 )
ROM_REGION( 0x800000, "mainrom", 0 )
ROM_LOAD( "w25q64jv.u1", 0x00000, 0x800000, CRC(b973e65b) SHA1(36ff137068ea56b4679c2db386ac0067de0a9eaf) )
@@ -1969,8 +1956,21 @@ ROM_START( otrail )
ROM_LOAD( "t24c04a.bin", 0x000, 0x200, CRC(ce1fad6f) SHA1(82878996765739edba42042b6336460d5c8f8096) )
ROM_END
+ROM_START( zonefusn )
+ ROM_REGION( 0x1000000, "mainrom", 0 )
+ ROM_LOAD( "fusion.bin", 0x00000, 0x1000000, CRC(240bf970) SHA1(1b82d95a252c08e52fb8da6320276574a30b60db) )
+ROM_END
+void nes_vt_cy_lexibook_state::init_lxcmcypp()
+{
+ int size = memregion("mainrom")->bytes()/2;
+ uint16_t* ROM = (uint16_t*)memregion("mainrom")->base();
+ for (int i = 0; i < size; i++)
+ {
+ ROM[i] = bitswap<16>(ROM[i], 4, 5, 6, 7, 0, 1, 2, 3, 12, 13, 14, 15, 8, 9, 10, 11);
+ }
+}
// earlier version of vdogdemo
CONS( 200?, vdogdeme, 0, 0, nes_vt_1mb, nes_vt, nes_vt_state, empty_init, "VRT", "V-Dog (prototype, earlier)", MACHINE_NOT_WORKING )
@@ -1994,10 +1994,10 @@ CONS( 200?, vtboxing, 0, 0, nes_vt_512kb, nes_vt, nes_vt_state, empty_init
// 050329 (29th March 2005) date on PCB
CONS( 2005, ablpinb, 0, 0, nes_vt_pal_2mb, ablpinb, nes_vt_ablpinb_state, empty_init, "Advance Bright Ltd", "Pinball (P8002, ABL TV Game)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-// need to map 2 player controls for Ping Pong, 'Eat-Bean' (the PacMan hack) gets stuck during intermission?
-CONS( 200?, duetpp, 0, 0, nes_vt_waixing_alt_4mb_duetpp, duetpp, nes_vt_waixing_alt_duetpp_state, empty_init, "Macro Winners", "Game Sporz Wireless Duet Play Ping-Pong", MACHINE_NOT_WORKING )
-
+// need to map 2 player controls for Ping Pong, 'Eat-Bean' (the PacMan hack) gets stuck during intermission? (same happens on hardware?)
+CONS( 2004, duetpp, 0, 0, nes_vt_waixing_alt_4mb_duetpp, duetpp, nes_vt_waixing_alt_duetpp_state, empty_init, "Macro Winners", "Game Sporz Wireless Duet Play Ping-Pong", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2004, sporzbx, 0, 0, nes_vt_waixing_alt_4mb_duetpp, duetpp, nes_vt_waixing_alt_duetpp_state, empty_init, "Macro Winners", "Game Sporz Wireless Boxing", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
// should be VT03 based
// for testing 'Shark', 'Octopus', 'Harbor', and 'Earth Fighter' use the extended colour modes, other games just seem to use standard NES modes
@@ -2042,30 +2042,33 @@ CONS( 200?, vgpmini, 0, 0, nes_vt_vg_4mb, nes_vt, nes_vt_hh_state, empty_ini
CONS( 200?, dgun2500, 0, 0, nes_vt_dg_baddma_16mb, nes_vt, nes_vt_dg_state, empty_init, "dreamGEAR", "dreamGEAR Wireless Motion Control with 130 games (DGUN-2500)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND)
// don't even get to menu. very enhanced chipset, VT368/9?
-CONS( 2012, dgun2561, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "dreamGEAR", "My Arcade Portable Gaming System (DGUN-2561)", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 2012, dgun2561, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "dreamGEAR", "My Arcade Portable Gaming System with 140 Games (DGUN-2561)", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
CONS( 2016, dgun2593, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "dreamGEAR", "My Arcade Retro Arcade Machine - 300 Handheld Video Games (DGUN-2593)", MACHINE_NOT_WORKING ) // 128Mbyte ROM, must be externally banked or different addressing scheme
-CONS( 200?, lxcmcy, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
-CONS( 200?, lxcmc250, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - 250-in-1 (JL2375)", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
-CONS( 200?, lxcmcysw, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Star Wars Rebels", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
-CONS( 200?, lxcmcyfz, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Frozen", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
-CONS( 200?, lxcmcydp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Disney Princess", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
-CONS( 200?, lxcmcysp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Marvel Ultimate Spider-Man", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmcy, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmc250, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - 250-in-1 (JL2375)", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmcysw, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Star Wars Rebels", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmcyfz, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Frozen", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmcydp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Disney Princess", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmcysp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Marvel Ultimate Spider-Man", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxcmcycr, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Compact Cyber Arcade - Cars", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+// the data order is swapped for this one, maybe other internal differences?
+CONS( 200?, lxcmcypp, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, init_lxcmcypp, "Lexibook", "Lexibook Compact Cyber Arcade - Paw Patrol", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+
-CONS( 200?, lxccminn, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Console Colour - Minnie Mouse", MACHINE_NOT_WORKING ) // 64Mbyte (used) ROM, must be externally banked, or different addressing scheme
-CONS( 200?, lxccplan, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Console Colour - Disney's Planes", MACHINE_NOT_WORKING ) // 64Mbyte (used) ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxccminn, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Console Colour - Minnie Mouse", MACHINE_NOT_WORKING ) // 64Mbyte (used) ROM, must be externally banked, or different addressing scheme
+CONS( 200?, lxccplan, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Console Colour - Disney's Planes", MACHINE_NOT_WORKING ) // 64Mbyte (used) ROM, must be externally banked, or different addressing scheme
// GB-NO13-Main-VT389-2 on PCBs
-CONS( 2016, rtvgc300, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Retro TV Game Console - 300 Games", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
-CONS( 2017, rtvgc300fz,0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Retro TV Game Console - Frozen - 300 Games", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 2016, rtvgc300, 0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Retro TV Game Console - 300 Games", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
+CONS( 2017, rtvgc300fz,0, 0, nes_vt_cy_bigger, nes_vt, nes_vt_cy_lexibook_state, empty_init, "Lexibook", "Lexibook Retro TV Game Console - Frozen - 300 Games", MACHINE_NOT_WORKING ) // 64Mbyte ROM, must be externally banked, or different addressing scheme
/* The following are also confirmed to be NES/VT derived units, most having a standard set of games with a handful of lazy graphic mods thrown in to fit the unit theme
(handhekd units, use standard AAA batteries)
Lexibook Compact Cyber Arcade - Cars
- Lexibook Compact Cyber Arcade - Paw Patrol
Lexibook Compact Cyber Arcade - Barbie
Lexibook Compact Cyber Arcade - Finding Dory
Lexibook Compact Cyber Arcade - PJ Masks
@@ -2213,3 +2216,4 @@ CONS( 2015, rminitv, 0, 0, nes_vt_fp_pal_32mb, nes_vt, nes_vt_hh_state, empt
// Use DIP switch to select console or cartridge, as cartridge is fake and just toggles a GPIO
CONS( 2016, fcpocket, 0, 0, nes_vt_fp_4x16mb, nes_vt_fp, nes_vt_hh_state, empty_init, "<unknown>", "FC Pocket 600 in 1", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has external banking (2x 32mbyte banks)
+CONS( 200?, zonefusn, 0, 0, nes_vt_fp_16mb, nes_vt, nes_vt_hh_state, empty_init, "Ultimate Products / Jungle's Soft", "Zone Fusion", MACHINE_NOT_WORKING )
diff --git a/src/mame/drivers/novag_savant.cpp b/src/mame/drivers/novag_savant.cpp
index 96496ee5b24..7e0944a7290 100644
--- a/src/mame/drivers/novag_savant.cpp
+++ b/src/mame/drivers/novag_savant.cpp
@@ -372,7 +372,9 @@ void savant_state::savant(machine_config &config)
config.set_perfect_quantum(m_mcu);
SENSORBOARD(config, m_board).set_type(sensorboard_device::BUTTONS);
+ m_board->set_delay(attotime::from_msec(200));
m_board->set_ui_enable(false); // no chesspieces
+ m_board->set_mod_enable(true);
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1);
diff --git a/src/mame/drivers/odyssey2.cpp b/src/mame/drivers/odyssey2.cpp
index ad083128ee2..5226574e1cd 100644
--- a/src/mame/drivers/odyssey2.cpp
+++ b/src/mame/drivers/odyssey2.cpp
@@ -2,12 +2,16 @@
// copyright-holders:Wilbert Pol
/***************************************************************************
- /drivers/odyssey2.c
+Driver file to handle emulation of the Odyssey2.
- Driver file to handle emulation of the Odyssey2.
-
- Minor update to "the voice" rom names, and add comment about
- the older revision of "the voice" - LN, 10/03/08
+TODO:
+- odyssey3 cpu/video should probably have a different XTAL
+- backgamm has display timing problems (it does a lot of partial screen updates)
+- homecomp does not work, needs new slot device
+- g7400 keyboard has 2 more columns
+- g7400 EF9341 R/W is connected to CPU A2, what happens if it is disobeyed?
+- a lot more issues, probably, this TODO list was written by someone with
+ not much knowledge on odyssey2
***************************************************************************/
@@ -38,26 +42,25 @@ public:
m_joysticks(*this, "JOY.%u", 0)
{ }
- void odyssey2_cartslot(machine_config &config);
- void videopac(machine_config &config);
- void odyssey2(machine_config &config);
+ // Reset button is tied to 8048 RESET pin
+ DECLARE_INPUT_CHANGED_MEMBER(reset_button) { m_maincpu->set_input_line(INPUT_LINE_RESET, newval ? ASSERT_LINE : CLEAR_LINE); }
- void init_odyssey2();
+ void odyssey2(machine_config &config);
+ void videopac(machine_config &config);
+ void videopacf(machine_config &config);
uint32_t screen_update_odyssey2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
protected:
-
required_device<i8048_device> m_maincpu;
required_device<i8244_device> m_i8244;
required_device<o2_cart_slot_device> m_cart;
- uint8_t m_ram[256];
+ uint8_t m_ram[0x80];
uint8_t m_p1;
uint8_t m_p2;
uint8_t m_lum;
-
DECLARE_READ_LINE_MEMBER(t1_read);
void odyssey2_palette(palette_device &palette) const;
@@ -79,7 +82,7 @@ protected:
static const uint8_t P1_VDC_COPY_MODE_ENABLE = 0x40;
static const uint8_t P2_KEYBOARD_SELECT_MASK = 0x07; /* select row to scan */
- required_ioport_array<6> m_keyboard;
+ required_ioport_array<8> m_keyboard;
required_ioport_array<2> m_joysticks;
uint8_t io_read(offs_t offset);
@@ -149,80 +152,89 @@ void g7400_state::g7400_io(address_map &map)
static INPUT_PORTS_START( odyssey2 )
PORT_START("KEY.0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_0) PORT_CHAR('0')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_1) PORT_CHAR('1')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_2) PORT_CHAR('2')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_3) PORT_CHAR('3')
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_4) PORT_CHAR('4')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_5) PORT_CHAR('5')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_6) PORT_CHAR('6')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_7) PORT_CHAR('7')
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_0) PORT_CHAR('0')
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_1) PORT_CHAR('1')
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_2) PORT_CHAR('2')
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_3) PORT_CHAR('3')
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_4) PORT_CHAR('4')
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_5) PORT_CHAR('5')
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_6) PORT_CHAR('6')
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_7) PORT_CHAR('7')
PORT_START("KEY.1")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_8) PORT_CHAR('8')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_9) PORT_CHAR('9')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("?? :") PORT_CODE(KEYCODE_F1) PORT_CHAR(UCHAR_MAMEKEY(F1))
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("?? $") PORT_CODE(KEYCODE_F2) PORT_CHAR(UCHAR_MAMEKEY(F2))
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_SPACE) PORT_CHAR(' ')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_SLASH) PORT_CHAR('?')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_L) PORT_CHAR('L')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_P) PORT_CHAR('P')
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_8) PORT_CHAR('8')
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_9) PORT_CHAR('9')
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_UNUSED)
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_SPACE) PORT_CHAR(' ')
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_SLASH) PORT_CHAR('?')
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_L) PORT_CHAR('L')
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_P) PORT_CHAR('P')
PORT_START("KEY.2")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_PLUS_PAD) PORT_CHAR('+')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_W) PORT_CHAR('W')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_E) PORT_CHAR('E')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_R) PORT_CHAR('R')
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_T) PORT_CHAR('T')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_U) PORT_CHAR('U')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_I) PORT_CHAR('I')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_O) PORT_CHAR('O')
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_PLUS_PAD) PORT_CHAR('+')
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_W) PORT_CHAR('W')
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_E) PORT_CHAR('E')
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_R) PORT_CHAR('R')
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_T) PORT_CHAR('T')
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_U) PORT_CHAR('U')
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_I) PORT_CHAR('I')
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_O) PORT_CHAR('O')
PORT_START("KEY.3")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Q) PORT_CHAR('Q')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_S) PORT_CHAR('S')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_D) PORT_CHAR('D')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_F) PORT_CHAR('F')
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_G) PORT_CHAR('G')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_H) PORT_CHAR('H')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_J) PORT_CHAR('J')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_K) PORT_CHAR('K')
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_Q) PORT_CHAR('Q')
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_S) PORT_CHAR('S')
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_D) PORT_CHAR('D')
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_F) PORT_CHAR('F')
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_G) PORT_CHAR('G')
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_H) PORT_CHAR('H')
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_J) PORT_CHAR('J')
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_K) PORT_CHAR('K')
PORT_START("KEY.4")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_A) PORT_CHAR('A')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Z) PORT_CHAR('Z')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_X) PORT_CHAR('X')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_C) PORT_CHAR('C')
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_V) PORT_CHAR('V')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_B) PORT_CHAR('B')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_M) PORT_CHAR('M')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_STOP) PORT_CHAR('.')
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_A) PORT_CHAR('A')
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_Z) PORT_CHAR('Z')
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_X) PORT_CHAR('X')
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_C) PORT_CHAR('C')
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_V) PORT_CHAR('V')
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_B) PORT_CHAR('B')
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_M) PORT_CHAR('M')
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_STOP) PORT_CHAR('.')
PORT_START("KEY.5")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_ASTERISK) PORT_CHAR('*')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_SLASH_PAD) PORT_CHAR('/')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_EQUALS) PORT_CHAR('=')
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME(DEF_STR( Yes )) PORT_CODE(KEYCODE_Y) PORT_CHAR('Y')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME(DEF_STR( No )) PORT_CODE(KEYCODE_N) PORT_CHAR('N')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("CLR") PORT_CODE(KEYCODE_BACKSPACE) PORT_CHAR(8)
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("ENT") PORT_CODE(KEYCODE_ENTER) PORT_CHAR('\r')
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-')
+ PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_ASTERISK) PORT_CHAR('*')
+ PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_SLASH_PAD) PORT_CHAR('/')
+ PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_EQUALS) PORT_CHAR('=')
+ PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME(DEF_STR(Yes)) PORT_CODE(KEYCODE_Y) PORT_CHAR('Y')
+ PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME(DEF_STR(No)) PORT_CODE(KEYCODE_N) PORT_CHAR('N')
+ PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("CLR") PORT_CODE(KEYCODE_BACKSPACE) PORT_CHAR(8)
+ PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("ENT") PORT_CODE(KEYCODE_ENTER) PORT_CHAR('\r')
+
+ PORT_START("KEY.6")
+ PORT_BIT(0xff, IP_ACTIVE_HIGH, IPT_UNUSED)
+
+ PORT_START("KEY.7")
+ PORT_BIT(0xff, IP_ACTIVE_HIGH, IPT_UNUSED)
PORT_START("JOY.0")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN) PORT_PLAYER(1)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1) PORT_PLAYER(1)
- PORT_BIT( 0xe0, 0xe0, IPT_UNUSED )
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) PORT_PLAYER(2)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT) PORT_PLAYER(2)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN) PORT_PLAYER(2)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT) PORT_PLAYER(2)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_BUTTON1) PORT_PLAYER(2)
+ PORT_BIT(0xe0, IP_ACTIVE_LOW, IPT_UNUSED)
PORT_START("JOY.1")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) PORT_PLAYER(2)
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT) PORT_PLAYER(2)
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN) PORT_PLAYER(2)
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT) PORT_PLAYER(2)
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1) PORT_PLAYER(2)
- PORT_BIT( 0xe0, 0xe0, IPT_UNUSED )
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) PORT_PLAYER(1)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT) PORT_PLAYER(1)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN) PORT_PLAYER(1)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT) PORT_PLAYER(1)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_BUTTON1) PORT_PLAYER(1)
+ PORT_BIT(0xe0, IP_ACTIVE_LOW, IPT_UNUSED)
+
+ PORT_START("RESET")
+ PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CODE(KEYCODE_F1) PORT_CHANGED_MEMBER(DEVICE_SELF, odyssey2_state, reset_button, 0) PORT_NAME("Reset")
INPUT_PORTS_END
@@ -288,21 +300,12 @@ void g7400_state::g7400_palette(palette_device &palette) const
palette.set_pen_colors(0, g7400_colors);
}
-void odyssey2_state::init_odyssey2()
-{
- uint8_t *gfx = memregion("gfx1")->base();
-
- for (int i = 0; i < 256; i++)
- {
- gfx[i] = i; /* TODO: Why i and not 0? */
- m_ram[i] = 0;
- }
-}
-
void odyssey2_state::machine_start()
{
- save_pointer(NAME(m_ram),256);
+ memset(m_ram, 0, 0x80);
+
+ save_item(NAME(m_ram));
save_item(NAME(m_p1));
save_item(NAME(m_p2));
save_item(NAME(m_lum));
@@ -311,12 +314,6 @@ void odyssey2_state::machine_start()
void odyssey2_state::machine_reset()
{
- m_lum = 0;
-
- /* jump to "last" bank, will work for all sizes due to being mirrored */
- m_p1 = 0xff;
- m_p2 = 0xff;
- m_cart->write_bank(m_p1);
}
@@ -344,75 +341,48 @@ void g7400_state::machine_reset()
uint8_t odyssey2_state::io_read(offs_t offset)
{
+ u8 data = m_cart->io_read(offset);
+ if (!(m_p1 & P1_EXT_RAM_ENABLE) && ~offset & 0x80)
+ data &= m_ram[offset];
+
if ((m_p1 & (P1_VDC_COPY_MODE_ENABLE | P1_VDC_ENABLE)) == 0)
- {
- return m_i8244->read(offset);
- }
- if (!(m_p1 & P1_EXT_RAM_ENABLE))
- {
- return m_ram[offset];
- }
+ data &= m_i8244->read(offset);
- return 0;
+ return data;
}
void odyssey2_state::io_write(offs_t offset, uint8_t data)
{
- if ((m_p1 & (P1_EXT_RAM_ENABLE | P1_VDC_COPY_MODE_ENABLE)) == 0x00)
+ if (!(m_p1 & P1_VDC_COPY_MODE_ENABLE))
{
- m_ram[offset] = data;
- if (offset & 0x80)
- {
- logerror("voice write %02X, data = %02X (p1 = %02X)\n", offset, data, m_p1);
- m_cart->io_write(offset, data);
- }
+ m_cart->io_write(offset, data);
+ if (!(m_p1 & P1_EXT_RAM_ENABLE) && ~offset & 0x80)
+ m_ram[offset] = data;
}
- else if (!(m_p1 & P1_VDC_ENABLE))
- {
+
+ if (!(m_p1 & P1_VDC_ENABLE))
m_i8244->write(offset, data);
- }
}
uint8_t g7400_state::io_read(offs_t offset)
{
- if ((m_p1 & (P1_VDC_COPY_MODE_ENABLE | P1_VDC_ENABLE)) == 0)
- {
- return m_i8244->read(offset);
- }
- else if (!(m_p1 & P1_EXT_RAM_ENABLE))
- {
- return m_ram[offset];
- }
- else if (!(m_p1 & P1_VPP_ENABLE))
- {
- return m_ef9340_1->ef9341_read( offset & 0x02, offset & 0x01 );
- }
+ u8 data = odyssey2_state::io_read(offset);
- return 0;
+ if (!(m_p1 & P1_VPP_ENABLE) && offset & 4)
+ data &= m_ef9340_1->ef9341_read( offset & 0x02, offset & 0x01 );
+
+ return data;
}
void g7400_state::io_write(offs_t offset, uint8_t data)
{
- if ((m_p1 & (P1_EXT_RAM_ENABLE | P1_VDC_COPY_MODE_ENABLE)) == 0x00)
- {
- m_ram[offset] = data;
- if (offset & 0x80)
- {
- logerror("voice write %02X, data = %02X (p1 = %02X)\n", offset, data, m_p1);
- m_cart->io_write(offset, data);
- }
- }
- else if (!(m_p1 & P1_VDC_ENABLE))
- {
- m_i8244->write(offset, data);
- }
- else if (!(m_p1 & P1_VPP_ENABLE))
- {
+ odyssey2_state::io_write(offset, data);
+
+ if (!(m_p1 & P1_VPP_ENABLE) && ~offset & 4)
m_ef9340_1->ef9341_write( offset & 0x02, offset & 0x01, data );
- }
}
@@ -481,11 +451,7 @@ uint32_t odyssey2_state::screen_update_odyssey2(screen_device &screen, bitmap_in
READ_LINE_MEMBER(odyssey2_state::t1_read)
{
- if ( m_i8244->vblank() || m_i8244->hblank() )
- {
- return 1;
- }
- return 0;
+ return m_i8244->vblank() | m_i8244->hblank();
}
@@ -501,72 +467,49 @@ void odyssey2_state::p1_write(uint8_t data)
{
m_p1 = data;
m_lum = ( data & 0x80 ) >> 4;
- m_cart->write_bank(m_p1);
+ m_cart->write_p1(m_p1 & 0x13);
}
uint8_t odyssey2_state::p2_read()
{
- uint8_t h = 0xFF;
- int i, j;
+ u8 data = m_p2;
if (!(m_p1 & P1_KEYBOARD_SCAN_ENABLE))
{
- if ((m_p2 & P2_KEYBOARD_SELECT_MASK) <= 5) /* read keyboard */
- {
- h &= m_keyboard[m_p2 & P2_KEYBOARD_SELECT_MASK]->read();
- }
-
- for (i= 0x80, j = 0; i > 0; i >>= 1, j++)
- {
- if (!(h & i))
- {
- m_p2 &= ~0x10; /* set key was pressed indicator */
- m_p2 = (m_p2 & ~0xE0) | (j << 5); /* column that was pressed */
-
- break;
- }
- }
-
- if (h == 0xFF) /* active low inputs, so no keypresses */
- {
- m_p2 = m_p2 | 0xF0;
- }
- }
- else
- {
- m_p2 = m_p2 | 0xF0;
+ // 74148 priority encoder, GS to P24, outputs to P25-P27
+ u8 inp = count_leading_zeros(m_keyboard[m_p2 & P2_KEYBOARD_SELECT_MASK]->read()) - 24;
+ if (inp < 8)
+ data &= inp << 5 | 0xf;
}
- return m_p2;
+ return data;
}
void odyssey2_state::p2_write(uint8_t data)
{
m_p2 = data;
+ m_cart->write_p2(m_p2 & 0x0f);
}
void g7400_state::p2_write(uint8_t data)
{
- m_p2 = data;
+ odyssey2_state::p2_write(data);
m_i8243->p2_w(m_p2 & 0x0f);
}
uint8_t odyssey2_state::bus_read()
{
- uint8_t data = 0xff;
-
- if ((m_p2 & P2_KEYBOARD_SELECT_MASK) == 1)
- {
- data &= m_joysticks[0]->read();
- }
+ u8 data = 0xff;
- if ((m_p2 & P2_KEYBOARD_SELECT_MASK) == 0)
+ if (!(m_p1 & P1_KEYBOARD_SCAN_ENABLE))
{
- data &= m_joysticks[1]->read();
+ u8 sel = m_p2 & P2_KEYBOARD_SELECT_MASK;
+ if (sel < 2)
+ data &= m_joysticks[sel]->read();
}
return data;
@@ -627,64 +570,11 @@ void g7400_state::i8243_p7_w(uint8_t data)
}
-static const gfx_layout odyssey2_graphicslayout =
-{
- 8,1,
- 256, /* 256 characters */
- 1, /* 1 bits per pixel */
- { 0 }, /* no bitplanes; 1 bit per pixel */
- /* x offsets */
- {
- 0,
- 1,
- 2,
- 3,
- 4,
- 5,
- 6,
- 7,
- },
- /* y offsets */
- { 0 },
- 1*8
-};
-
-
-static const gfx_layout odyssey2_spritelayout =
-{
- 8,1,
- 256, /* 256 characters */
- 1, /* 1 bits per pixel */
- { 0 }, /* no bitplanes; 1 bit per pixel */
- /* x offsets */
- {
- 7,6,5,4,3,2,1,0
- },
- /* y offsets */
- { 0 },
- 1*8
-};
-
-
-static GFXDECODE_START( gfx_odyssey2 )
- GFXDECODE_ENTRY( "gfx1", 0x0000, odyssey2_graphicslayout, 0, 2 )
- GFXDECODE_ENTRY( "gfx1", 0x0000, odyssey2_spritelayout, 0, 2 )
-GFXDECODE_END
-
-
-
-void odyssey2_state::odyssey2_cartslot(machine_config &config)
-{
- O2_CART_SLOT(config, m_cart, o2_cart, nullptr);
-
- SOFTWARE_LIST(config, "cart_list").set_original("odyssey2");
-}
-
void odyssey2_state::odyssey2(machine_config &config)
{
/* basic machine hardware */
- I8048(config, m_maincpu, ((XTAL(7'159'090) * 3) / 4));
+ I8048(config, m_maincpu, (XTAL(7'159'090) * 3) / 4);
m_maincpu->set_addrmap(AS_PROGRAM, &odyssey2_state::odyssey2_mem);
m_maincpu->set_addrmap(AS_IO, &odyssey2_state::odyssey2_io);
m_maincpu->p1_in_cb().set(FUNC(odyssey2_state::p1_read));
@@ -696,62 +586,47 @@ void odyssey2_state::odyssey2(machine_config &config)
m_maincpu->t0_in_cb().set("cartslot", FUNC(o2_cart_slot_device::t0_read));
m_maincpu->t1_in_cb().set(FUNC(odyssey2_state::t1_read));
- config.set_maximum_quantum(attotime::from_hz(60));
-
/* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
screen.set_screen_update(FUNC(odyssey2_state::screen_update_odyssey2));
screen.set_palette("palette");
- GFXDECODE(config, "gfxdecode", "palette", gfx_odyssey2);
- PALETTE(config, "palette", FUNC(odyssey2_state::odyssey2_palette), 32);
+ PALETTE(config, "palette", FUNC(odyssey2_state::odyssey2_palette), 16);
- /* sound hardware */
SPEAKER(config, "mono").front_center();
- I8244(config, m_i8244, XTAL(7'159'090)/2 * 2);
+ I8244(config, m_i8244, XTAL(7'159'090) / 2);
m_i8244->set_screen("screen");
m_i8244->irq_cb().set_inputline(m_maincpu, MCS48_INPUT_IRQ);
m_i8244->postprocess_cb().set(FUNC(odyssey2_state::scanline_postprocess));
m_i8244->add_route(ALL_OUTPUTS, "mono", 0.40);
- odyssey2_cartslot(config);
+ /* cartridge */
+ O2_CART_SLOT(config, m_cart, o2_cart, nullptr);
+ SOFTWARE_LIST(config, "cart_list").set_original("odyssey2");
}
-
void odyssey2_state::videopac(machine_config &config)
{
- /* basic machine hardware */
- I8048(config, m_maincpu, (XTAL(17'734'470) / 3));
- m_maincpu->set_addrmap(AS_PROGRAM, &odyssey2_state::odyssey2_mem);
- m_maincpu->set_addrmap(AS_IO, &odyssey2_state::odyssey2_io);
- m_maincpu->p1_in_cb().set(FUNC(odyssey2_state::p1_read));
- m_maincpu->p1_out_cb().set(FUNC(odyssey2_state::p1_write));
- m_maincpu->p2_in_cb().set(FUNC(odyssey2_state::p2_read));
- m_maincpu->p2_out_cb().set(FUNC(odyssey2_state::p2_write));
- m_maincpu->bus_in_cb().set(FUNC(odyssey2_state::bus_read));
- m_maincpu->bus_out_cb().set(FUNC(odyssey2_state::bus_write));
- m_maincpu->t0_in_cb().set("cartslot", FUNC(o2_cart_slot_device::t0_read));
- m_maincpu->t1_in_cb().set(FUNC(odyssey2_state::t1_read));
-
- config.set_maximum_quantum(attotime::from_hz(60));
+ odyssey2(config);
- /* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_screen_update(FUNC(odyssey2_state::screen_update_odyssey2));
- screen.set_palette("palette");
+ // different master XTAL
+ m_maincpu->set_clock(XTAL(17'734'470) / 3);
- GFXDECODE(config, "gfxdecode", "palette", gfx_odyssey2);
- PALETTE(config, "palette", FUNC(odyssey2_state::odyssey2_palette), 16);
-
- /* sound hardware */
- SPEAKER(config, "mono").front_center();
- I8245(config, m_i8244, XTAL(17'734'470)/5 * 2);
+ // PAL video chip
+ I8245(config.replace(), m_i8244, XTAL(17'734'470) / 5);
m_i8244->set_screen("screen");
m_i8244->irq_cb().set_inputline(m_maincpu, MCS48_INPUT_IRQ);
m_i8244->postprocess_cb().set(FUNC(odyssey2_state::scanline_postprocess));
m_i8244->add_route(ALL_OUTPUTS, "mono", 0.40);
+}
+
+void odyssey2_state::videopacf(machine_config &config)
+{
+ videopac(config);
- odyssey2_cartslot(config);
+ // different master XTAL
+ m_maincpu->set_clock(XTAL(17'812'000) / 3);
+ m_i8244->set_clock(XTAL(17'812'000) / 5);
}
@@ -771,14 +646,11 @@ void g7400_state::g7400(machine_config &config)
m_maincpu->t1_in_cb().set(FUNC(g7400_state::t1_read));
m_maincpu->prog_out_cb().set(m_i8243, FUNC(i8243_device::prog_w));
- config.set_maximum_quantum(attotime::from_hz(60));
-
/* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
screen.set_screen_update(FUNC(odyssey2_state::screen_update_odyssey2));
screen.set_palette("palette");
- GFXDECODE(config, "gfxdecode", "palette", gfx_odyssey2);
PALETTE(config, "palette", FUNC(g7400_state::g7400_palette), 16);
I8243(config, m_i8243);
@@ -787,109 +659,71 @@ void g7400_state::g7400(machine_config &config)
m_i8243->p6_out_cb().set(FUNC(g7400_state::i8243_p6_w));
m_i8243->p7_out_cb().set(FUNC(g7400_state::i8243_p7_w));
- EF9340_1(config, m_ef9340_1, 3540000, "screen");
+ EF9340_1(config, m_ef9340_1, XTAL(8'867'000)/5 * 2, "screen");
SPEAKER(config, "mono").front_center();
- I8245(config, m_i8244, 3540000 * 2);
+ I8245(config, m_i8244, XTAL(8'867'000)/5 * 2);
m_i8244->set_screen("screen");
m_i8244->irq_cb().set_inputline(m_maincpu, MCS48_INPUT_IRQ);
m_i8244->postprocess_cb().set(FUNC(g7400_state::scanline_postprocess));
m_i8244->add_route(ALL_OUTPUTS, "mono", 0.40);
- odyssey2_cartslot(config);
- SOFTWARE_LIST(config.replace(), "cart_list").set_original("g7400");
+ /* cartridge */
+ O2_CART_SLOT(config, m_cart, o2_cart, nullptr);
+ SOFTWARE_LIST(config, "cart_list").set_original("g7400");
SOFTWARE_LIST(config, "ody2_list").set_compatible("odyssey2");
}
-
void g7400_state::odyssey3(machine_config &config)
{
- /* basic machine hardware */
- I8048(config, m_maincpu, XTAL(5'911'000));
- m_maincpu->set_addrmap(AS_PROGRAM, &g7400_state::odyssey2_mem);
- m_maincpu->set_addrmap(AS_IO, &g7400_state::g7400_io);
- m_maincpu->p1_in_cb().set(FUNC(g7400_state::p1_read));
- m_maincpu->p1_out_cb().set(FUNC(g7400_state::p1_write));
- m_maincpu->p2_in_cb().set(FUNC(g7400_state::p2_read));
- m_maincpu->p2_out_cb().set(FUNC(g7400_state::p2_write));
- m_maincpu->bus_in_cb().set(FUNC(g7400_state::bus_read));
- m_maincpu->bus_out_cb().set(FUNC(g7400_state::bus_write));
- m_maincpu->t0_in_cb().set("cartslot", FUNC(o2_cart_slot_device::t0_read));
- m_maincpu->t1_in_cb().set(FUNC(g7400_state::t1_read));
- m_maincpu->prog_out_cb().set(m_i8243, FUNC(i8243_device::prog_w));
-
- config.set_maximum_quantum(attotime::from_hz(60));
-
- /* video hardware */
- screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_screen_update(FUNC(odyssey2_state::screen_update_odyssey2));
- screen.set_palette("palette");
-
- GFXDECODE(config, "gfxdecode", "palette", gfx_odyssey2);
- PALETTE(config, "palette", FUNC(g7400_state::g7400_palette), 16);
+ g7400(config);
- I8243(config, m_i8243);
- m_i8243->p4_out_cb().set(FUNC(g7400_state::i8243_p4_w));
- m_i8243->p5_out_cb().set(FUNC(g7400_state::i8243_p5_w));
- m_i8243->p6_out_cb().set(FUNC(g7400_state::i8243_p6_w));
- m_i8243->p7_out_cb().set(FUNC(g7400_state::i8243_p7_w));
-
- EF9340_1(config, m_ef9340_1, 3540000, "screen");
-
- SPEAKER(config, "mono").front_center();
- I8244(config, m_i8244, 3540000 * 2);
+ // NTSC video chip
+ I8244(config.replace(), m_i8244, XTAL(8'867'000)/5 * 2);
m_i8244->set_screen("screen");
m_i8244->irq_cb().set_inputline(m_maincpu, MCS48_INPUT_IRQ);
m_i8244->postprocess_cb().set(FUNC(g7400_state::scanline_postprocess));
m_i8244->add_route(ALL_OUTPUTS, "mono", 0.40);
-
- odyssey2_cartslot(config);
- SOFTWARE_LIST(config.replace(), "cart_list").set_original("g7400");
- SOFTWARE_LIST(config, "ody2_list").set_compatible("odyssey2");
}
ROM_START (odyssey2)
- ROM_REGION(0x10000,"maincpu",0) /* safer for the memory handler/bankswitching??? */
+ ROM_REGION(0x0400,"maincpu",0)
ROM_LOAD ("o2bios.rom", 0x0000, 0x0400, CRC(8016a315) SHA1(b2e1955d957a475de2411770452eff4ea19f4cee))
- ROM_REGION(0x100, "gfx1", ROMREGION_ERASEFF)
ROM_END
-
ROM_START (videopac)
- ROM_REGION(0x10000,"maincpu",0) /* safer for the memory handler/bankswitching??? */
- ROM_SYSTEM_BIOS( 0, "g7000", "g7000" )
- ROMX_LOAD ("o2bios.rom", 0x0000, 0x0400, CRC(8016a315) SHA1(b2e1955d957a475de2411770452eff4ea19f4cee), ROM_BIOS(0))
- ROM_SYSTEM_BIOS( 1, "c52", "c52" )
- ROMX_LOAD ("c52.bin", 0x0000, 0x0400, CRC(a318e8d6) SHA1(a6120aed50831c9c0d95dbdf707820f601d9452e), ROM_BIOS(1))
- ROM_REGION(0x100, "gfx1", ROMREGION_ERASEFF)
+ ROM_REGION(0x0400,"maincpu",0)
+ ROM_LOAD ("o2bios.rom", 0x0000, 0x0400, CRC(8016a315) SHA1(b2e1955d957a475de2411770452eff4ea19f4cee))
+ROM_END
+
+ROM_START (videopacf)
+ ROM_REGION(0x0400,"maincpu",0)
+ ROM_LOAD ("c52.rom", 0x0000, 0x0400, CRC(a318e8d6) SHA1(a6120aed50831c9c0d95dbdf707820f601d9452e))
ROM_END
ROM_START (g7400)
- ROM_REGION(0x10000,"maincpu",0) /* safer for the memory handler/bankswitching??? */
+ ROM_REGION(0x0400,"maincpu",0)
ROM_LOAD ("g7400.bin", 0x0000, 0x0400, CRC(e20a9f41) SHA1(5130243429b40b01a14e1304d0394b8459a6fbae))
- ROM_REGION(0x100, "gfx1", ROMREGION_ERASEFF)
ROM_END
-
ROM_START (jopac)
- ROM_REGION(0x10000,"maincpu",0) /* safer for the memory handler/bankswitching??? */
+ ROM_REGION(0x0400,"maincpu",0)
ROM_LOAD ("jopac.bin", 0x0000, 0x0400, CRC(11647ca5) SHA1(54b8d2c1317628de51a85fc1c424423a986775e4))
- ROM_REGION(0x100, "gfx1", ROMREGION_ERASEFF)
ROM_END
-
ROM_START (odyssey3)
- ROM_REGION(0x10000, "maincpu", 0)
+ ROM_REGION(0x0400, "maincpu", 0)
ROM_LOAD ("odyssey3.bin", 0x0000, 0x0400, CRC(e2b23324) SHA1(0a38c5f2cea929d2fe0a23e5e1a60de9155815dc))
-
- ROM_REGION(0x100, "gfx1", ROMREGION_ERASEFF)
ROM_END
-/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
-COMP( 1978, odyssey2, 0, 0, odyssey2, odyssey2, odyssey2_state, init_odyssey2, "Magnavox", "Odyssey 2", 0 )
-COMP( 1979, videopac, odyssey2, 0, videopac, odyssey2, odyssey2_state, init_odyssey2, "Philips", "Videopac G7000/C52", 0 )
-COMP( 1983, g7400, odyssey2, 0, g7400, odyssey2, g7400_state, init_odyssey2, "Philips", "Videopac Plus G7400", MACHINE_IMPERFECT_GRAPHICS )
-COMP( 1983, jopac, odyssey2, 0, g7400, odyssey2, g7400_state, init_odyssey2, "Brandt", "Jopac JO7400", MACHINE_IMPERFECT_GRAPHICS )
-COMP( 1983, odyssey3, odyssey2, 0, odyssey3, odyssey2, g7400_state, init_odyssey2, "Magnavox", "Odyssey 3 Command Center (prototype)", MACHINE_IMPERFECT_GRAPHICS )
+
+/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY, FULLNAME, FLAGS */
+COMP( 1979, odyssey2, 0, 0, odyssey2, odyssey2, odyssey2_state, empty_init, "Magnavox", "Odyssey 2 (US)", 0 )
+COMP( 1979, videopac, odyssey2, 0, videopac, odyssey2, odyssey2_state, empty_init, "Philips", "Videopac G7000 (Europe)", 0 )
+COMP( 1979, videopacf, odyssey2, 0, videopacf, odyssey2, odyssey2_state, empty_init, "Philips", "Videopac C52 (France)", 0 )
+
+COMP( 1983, g7400, 0, 0, g7400, odyssey2, g7400_state, empty_init, "Philips", "Videopac Plus G7400 (Europe)", MACHINE_IMPERFECT_GRAPHICS )
+COMP( 1983, jopac, g7400, 0, g7400, odyssey2, g7400_state, empty_init, "Philips (Brandt license)", "Jopac JO7400 (France)", MACHINE_IMPERFECT_GRAPHICS )
+COMP( 1983, odyssey3, g7400, 0, odyssey3, odyssey2, g7400_state, empty_init, "Magnavox", "Odyssey 3 Command Center (US, prototype)", MACHINE_IMPERFECT_GRAPHICS )
diff --git a/src/mame/drivers/pcd.cpp b/src/mame/drivers/pcd.cpp
index 07321718c9c..b3c5f6a1787 100644
--- a/src/mame/drivers/pcd.cpp
+++ b/src/mame/drivers/pcd.cpp
@@ -239,7 +239,7 @@ uint16_t pcd_state::mmu_r(offs_t offset)
//logerror("%s: mmu read %04x %04x\n", machine().describe_context(), (offset << 1) + 0x8000, data);
if(!offset)
return m_mmu.ctl;
- else if((offset >= 0x200) && (offset < 0x300) && !(offset & 3))
+ else if((offset >= 0x200) && (offset < 0x400) && !(offset & 3))
return (data << 4) | (data >> 12) | (m_mmu.sc && (offset == 0x200) ? 0xc0 : 0);
else if(offset == 0x400)
{
@@ -254,7 +254,7 @@ void pcd_state::mmu_w(offs_t offset, uint16_t data)
//logerror("%s: mmu write %04x %04x\n", machine().describe_context(), (offset << 1) + 0x8000, data);
if(!offset)
m_mmu.ctl = data;
- else if((offset >= 0x200) && (offset < 0x300) && !(offset & 3))
+ else if((offset >= 0x200) && (offset < 0x400) && !(offset & 3))
m_mmu.regs[((m_mmu.ctl & 0x1f) << 5) | ((offset >> 2) & 0x1f)] = (data >> 4) | (data << 12);
else if(offset == 0x400)
{
@@ -376,7 +376,7 @@ void pcd_state::mem_w(address_space &space, offs_t offset, uint16_t data, uint16
reg = m_mmu.regs[((offset >> 10) & 0xff) | ((m_mmu.ctl & 0x18) << 5)];
else
reg = m_mmu.regs[((offset >> 10) & 0x7f) | ((m_mmu.ctl & 0x1c) << 5)];
- if(!reg && !machine().side_effects_disabled())
+ if(!(reg & 1) && !machine().side_effects_disabled())
{
offset <<= 1;
logerror("%s: Null mmu entry %06x\n", machine().describe_context(), offset);
@@ -398,7 +398,7 @@ uint16_t pcd_state::mem_r(address_space &space, offs_t offset)
reg = m_mmu.regs[((offset >> 10) & 0xff) | ((m_mmu.ctl & 0x18) << 5)];
else
reg = m_mmu.regs[((offset >> 10) & 0x7f) | ((m_mmu.ctl & 0x1c) << 5)];
- if(!reg && !machine().side_effects_disabled())
+ if(!(reg & 2) && !machine().side_effects_disabled())
{
offset <<= 1;
logerror("%s: Null mmu entry %06x\n", machine().describe_context(), offset);
diff --git a/src/mame/drivers/qix.cpp b/src/mame/drivers/qix.cpp
index 4c2faffe3b3..3b9ddce892e 100644
--- a/src/mame/drivers/qix.cpp
+++ b/src/mame/drivers/qix.cpp
@@ -681,7 +681,12 @@ void zookeep_state::zookeep(machine_config &config)
video(config);
}
-
+void zookeep_state::zookeepbl(machine_config &config)
+{
+ qix(config);
+ m_maincpu->set_addrmap(AS_PROGRAM, &zookeep_state::main_map);
+ video(config);
+}
/***************************************************************************
@@ -1106,6 +1111,28 @@ ROM_START( zookeep3 )
ROM_LOAD( "za_coin.bin", 0x0000, 0x0800, CRC(364d3557) SHA1(049d0759750c576187053306e07984b1e5877df7) )
ROM_END
+// the top PCB is definitely an Italian made one (same place Sidam PCBs were made). The bottom PCB (MTD-19) looks like one of those Taito PCBs made for licensees.
+// there's an unpopulated IC location for an M68705
+// only ROMS 16-17, 18-19 and 26-27 had still stickers on, so the others are educated guesses
+ROM_START( zookeepbl )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "zk-12-13.bin", 0x8000, 0x2000, CRC(b85e5200) SHA1(3f47626fe35f2e9fa893595e06ea4275a9beb10b) )
+ ROM_LOAD( "zk-14-15.bin", 0xa000, 0x2000, CRC(b621a415) SHA1(7b6e595f1c797d6619e7ea128aeb67f432d64a83) )
+ ROM_LOAD( "zk-16-17.bin", 0xc000, 0x2000, CRC(9e192104) SHA1(318c902debfcb49a02a3a776bf2a860685603b3c) )
+ ROM_LOAD( "zk-18-19.bin", 0xe000, 0x2000, CRC(2854b69d) SHA1(3d258d57909228d13b1b557e8178b722ec297d6d) )
+
+ ROM_REGION( 0x12000, "videocpu", 0 )
+ ROM_LOAD( "zk-5-6.bin", 0x0a000, 0x2000, CRC(467b42dc) SHA1(e92a98b56959f5ccf2a4dc4ebafa13f9074e551b) )
+ ROM_LOAD( "zk-7-8.bin", 0x0c000, 0x2000, CRC(2a5571ed) SHA1(ac6947c8fb22c0c549c747cc88b1a4da7063fcf6) )
+ ROM_LOAD( "zk-9-10.bin", 0x0e000, 0x2000, CRC(7430e09c) SHA1(05a2cd5a9dd06c235881e7d9b734be1d3e41de5d) ) // only ROM with differences compared to the parent
+ ROM_LOAD( "zk-3-4.bin", 0x10000, 0x2000, CRC(ab5a72f0) SHA1(4595a785d212464d599cfacd75ea4fc368231550) )
+
+ ROM_REGION( 0x10000, "audiocpu", 0 )
+ ROM_LOAD( "zk-25.bin", 0xd000, 0x1000, CRC(32e6d667) SHA1(4d693ac4a73746f17515b805382f5aeaf606da39) ) // 0xxxxxxxxxxxx = 0xFF
+ ROM_CONTINUE( 0xd000, 0x1000 )
+ ROM_LOAD( "zk-26-27.bin", 0xe000, 0x2000, CRC(2138554c) SHA1(6fbf46e0dd3d8a0dd526064baee3d84212713b9a) )
+ROM_END
+
ROM_START( slither )
ROM_REGION( 0x10000, "maincpu", 0 )
@@ -1433,21 +1460,22 @@ WRITE_LINE_MEMBER(qix_state::kram3_lic_videocpu_changed)
*
*************************************/
-GAME( 1981, qix, 0, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (Rev 2)", MACHINE_SUPPORTS_SAVE ) // newest set? closest to 'qix2'
-GAME( 1981, qixa, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (set 2, smaller roms)", MACHINE_SUPPORTS_SAVE )
-GAME( 1981, qixb, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (set 2, larger roms)", MACHINE_SUPPORTS_SAVE )
-GAME( 1981, qixo, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (set 3, earlier)", MACHINE_SUPPORTS_SAVE ) // oldest set / prototype? has incorrect spelling 'deutch' and doesn't allow language selection to be changed
-GAME( 1981, qix2, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix II (Tournament)", MACHINE_SUPPORTS_SAVE )
-GAME( 1981, sdungeon, 0, mcu, sdungeon, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "Space Dungeon", MACHINE_SUPPORTS_SAVE ) // actually released July 1982
-GAME( 1981, sdungeona, sdungeon, mcu, sdungeon, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "Space Dungeon (larger roms)", MACHINE_SUPPORTS_SAVE ) // same as above but uses larger ROMs
-GAMEL(1982, elecyoyo, 0, mcu, elecyoyo, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "The Electric Yo-Yo (set 1)", MACHINE_SUPPORTS_SAVE, layout_elecyoyo )
-GAMEL(1982, elecyoyo2, elecyoyo, mcu, elecyoyo, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "The Electric Yo-Yo (set 2)", MACHINE_SUPPORTS_SAVE, layout_elecyoyo )
-GAME( 1982, kram, 0, mcu, kram, qixmcu_state, empty_init, ROT0, "Taito America Corporation", "Kram (set 1)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, kram2, kram, mcu, kram, qixmcu_state, empty_init, ROT0, "Taito America Corporation", "Kram (set 2)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, kram3, kram, kram3, kram, qix_state, init_kram3, ROT0, "Taito America Corporation", "Kram (encrypted)", MACHINE_UNEMULATED_PROTECTION | MACHINE_SUPPORTS_SAVE )
-GAME( 1982, zookeep, 0, zookeep, zookeep, zookeep_state, empty_init, ROT0, "Taito America Corporation", "Zoo Keeper (set 1)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, zookeep2, zookeep, zookeep, zookeep, zookeep_state, empty_init, ROT0, "Taito America Corporation", "Zoo Keeper (set 2)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, zookeep3, zookeep, zookeep, zookeep, zookeep_state, empty_init, ROT0, "Taito America Corporation", "Zoo Keeper (set 3)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, slither, 0, slither, slither, qix_state, empty_init, ROT270, "Century II", "Slither (set 1)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, slithera, slither, slither, slither, qix_state, empty_init, ROT270, "Century II", "Slither (set 2)", MACHINE_SUPPORTS_SAVE )
-GAME( 1984, complexx, 0, qix, complexx, qix_state, empty_init, ROT270, "Taito America Corporation", "Complex X", MACHINE_SUPPORTS_SAVE )
+GAME( 1981, qix, 0, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (Rev 2)", MACHINE_SUPPORTS_SAVE ) // newest set? closest to 'qix2'
+GAME( 1981, qixa, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (set 2, smaller roms)", MACHINE_SUPPORTS_SAVE )
+GAME( 1981, qixb, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (set 2, larger roms)", MACHINE_SUPPORTS_SAVE )
+GAME( 1981, qixo, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix (set 3, earlier)", MACHINE_SUPPORTS_SAVE ) // oldest set / prototype? has incorrect spelling 'deutch' and doesn't allow language selection to be changed
+GAME( 1981, qix2, qix, qix, qix, qix_state, empty_init, ROT270, "Taito America Corporation", "Qix II (Tournament)", MACHINE_SUPPORTS_SAVE )
+GAME( 1981, sdungeon, 0, mcu, sdungeon, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "Space Dungeon", MACHINE_SUPPORTS_SAVE ) // actually released July 1982
+GAME( 1981, sdungeona, sdungeon, mcu, sdungeon, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "Space Dungeon (larger roms)", MACHINE_SUPPORTS_SAVE ) // same as above but uses larger ROMs
+GAMEL(1982, elecyoyo, 0, mcu, elecyoyo, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "The Electric Yo-Yo (set 1)", MACHINE_SUPPORTS_SAVE, layout_elecyoyo )
+GAMEL(1982, elecyoyo2, elecyoyo, mcu, elecyoyo, qixmcu_state, empty_init, ROT270, "Taito America Corporation", "The Electric Yo-Yo (set 2)", MACHINE_SUPPORTS_SAVE, layout_elecyoyo )
+GAME( 1982, kram, 0, mcu, kram, qixmcu_state, empty_init, ROT0, "Taito America Corporation", "Kram (set 1)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, kram2, kram, mcu, kram, qixmcu_state, empty_init, ROT0, "Taito America Corporation", "Kram (set 2)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, kram3, kram, kram3, kram, qix_state, init_kram3, ROT0, "Taito America Corporation", "Kram (encrypted)", MACHINE_UNEMULATED_PROTECTION | MACHINE_SUPPORTS_SAVE )
+GAME( 1982, zookeep, 0, zookeep, zookeep, zookeep_state, empty_init, ROT0, "Taito America Corporation", "Zoo Keeper (set 1)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, zookeep2, zookeep, zookeep, zookeep, zookeep_state, empty_init, ROT0, "Taito America Corporation", "Zoo Keeper (set 2)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, zookeep3, zookeep, zookeep, zookeep, zookeep_state, empty_init, ROT0, "Taito America Corporation", "Zoo Keeper (set 3)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, zookeepbl, zookeep, zookeepbl, zookeep, zookeep_state, empty_init, ROT0, "bootleg", "Zoo Keeper (bootleg)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, slither, 0, slither, slither, qix_state, empty_init, ROT270, "Century II", "Slither (set 1)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, slithera, slither, slither, slither, qix_state, empty_init, ROT270, "Century II", "Slither (set 2)", MACHINE_SUPPORTS_SAVE )
+GAME( 1984, complexx, 0, qix, complexx, qix_state, empty_init, ROT270, "Taito America Corporation", "Complex X", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/renegade.cpp b/src/mame/drivers/renegade.cpp
index f66e5cd14d8..8c9e6613ec4 100644
--- a/src/mame/drivers/renegade.cpp
+++ b/src/mame/drivers/renegade.cpp
@@ -9,55 +9,55 @@ Nekketsu Kouha Kunio Kun
(c)1986 Technos Japan
Nekketsu Kouha Kunio Kun (bootleg)
+Renegade (bootleg)
driver by Phil Stroffolino, Carlos A. Lozano, Rob Rosenbrock
to enter test mode, hold down P1+P2 and press reset
NMI is used to refresh the sprites
-IRQ is used to handle coin inputs
+IRQ is used to poll the coin and service inputs
+coin counter outputs are connected directly to coin inputs (via 74LS04 inverter gates IC55, IC43)
+no coin lockout
Known issues:
-- Knockdown samples farts (coming from YM3526 DAC);
-- Static ADPCM sound, end trigger not understood.
- Most likely ends when specific data format is encountered during playback
- cfr. jantotsu.cpp;
-- Verify irq sources;
- Unemulated partial update bg scrolling, which should effectively add layer
tearing at line ~12 according to the refs. Scrolling currently
triggers at line 6 with current timings so we are quite off.
Additionally scrolling updates every other frame so simply using partial
updates won't cope with it;
-- None of the refs has the top 8 pixels shown but 256x232 seems unlikely.
- Verify what it shows on real HW, should be either garbage or vblank or
- border color;
-- Verify if coin counter is really tied to $3807;
-Memory Map (Preliminary):
+Non-emulation issues: (these are confirmed accurate, present on real pcb)
+- Knockdown samples farts (coming from YM3526 DAC)
+- Static ADPCM sound
+- Active video period is 238 lines but last 7 lines are unused
+
+
+Memory Map:
Working RAM
- $24 used to mirror bankswitch state
- $25 coin trigger state
- $26 #credits (decimal)
- $27 - $28 partial credits
- $2C - $2D sprite refresh trigger (used by NMI)
- $31 live/demo (if live, player controls are read from input ports)
- $32 indicates 2 player (alternating) game, or 1 player game
- $33 active player
- $37 stage number
- $38 stage state (for stages with more than one part)
- $40 game status flags; 0x80 indicates time over, 0x40 indicates player dead
- $220 player health
- $222 - $223 stage timer
- $48a - $48b horizontal scroll buffer
- $511 - $690 sprite RAM buffer
- $693 num pending sound commands
- $694 - $698 sound command queue
-
-$1002 #lives
+ $24 used to mirror bankswitch state
+ $25 coin trigger state
+ $26 #credits (decimal)
+ $27 - $28 partial credits
+ $2C - $2D sprite refresh trigger (used by NMI)
+ $31 live/demo (if live, player controls are read from input ports)
+ $32 indicates 2 player (alternating) game, or 1 player game
+ $33 active player
+ $37 stage number
+ $38 stage state (for stages with more than one part)
+ $40 game status flags; 0x80 indicates time over, 0x40 indicates player dead
+ $220 player health
+ $222 - $223 stage timer
+ $48a - $48b horizontal scroll buffer
+ $511 - $690 sprite RAM buffer
+ $693 num pending sound commands
+ $694 - $698 sound command queue
+
+$1002 #lives
$1014 - $1015 stage timer - separated digits
$1017 - $1019 stage timer: (ticks,seconds,minutes)
-$101a timer for palette animation
+$101a timer for palette animation
$1020 - $1048 high score table
$10e5 - $10ff 68705 data buffer
@@ -80,33 +80,33 @@ $3804w send data to 68705
$3804r receive data from 68705
$3805w bankswitch
-$3806w watchdog?
-$3807w coin counter
-
-$3800r 'player1'
- xx start buttons
- xx fire buttons
- xxxx joystick state
-
-$3801r 'player2'
- xx coin inputs
- xx fire buttons
- xxxx joystick state
-
-$3802r 'DIP2'
- x unused?
- x vblank
- x 0: 68705 is ready to send information
- x 1: 68705 is ready to receive information
- xx 3rd fire buttons for player 2,1
- xx difficulty
-
-$3803r 'DIP1'
- x screen flip
- x cabinet type
- x bonus (extra life for high score)
- x starting lives: 1 or 2
- xxxx coins per play
+$3806w nmi clear
+$3807w irq clear
+
+$3800r player 1 controls
+xx start buttons
+ xx fire buttons
+ xxxx joystick state
+
+$3801r player 2 controls
+xx coin inputs
+ xx fire buttons
+ xxxx joystick state
+
+$3802r dipswitch 2 + misc
+x service input
+ x vblank (reads state of nmi flipflop)
+ x 0: 68705 is ready to send information
+ x 1: 68705 is ready to receive information
+ xx 3rd fire buttons for player 2,1
+ xx difficulty
+
+$3803r dipswitch 1
+x screen flip
+ x cabinet type
+ x bonus (extra life for high score)
+ x starting lives: 1 or 2
+ xxxx coins per play
ROM
$4000 - $7fff bankswitched ROM
@@ -128,15 +128,22 @@ $8000 - $ffff ROM
/**************************************************************************/
/* ADPCM sound
**
-** Inferred from the 6809 code and analogy with ddragon
-** NMI at end of sample is not needed in order for
-** playback to work, but seems to be what the code expects
+** oki m5205 s/w selectable 4/8KHz
+** 12x speech samples of 0x2000*2 samples each (approx 2.5 seconds)
+** 4x chained 4-bit binary counters clock out the rom data (2x 74LS393, IC48/IC46, 2 counters per chip)
+** 74LS74A @ IC45 is the nmi control flipflop, nmi = Q, m5205 and counter chain shared reset = /Q
+** 6809 wr to 3000-37ff asserts nmi (ff CLR pin)
+** 6809 wr to 1800-1fff clears nmi, releases m5205/counter shared reset line (ff SET pin)
+** 6809 wr to 2000-27ff selects 1 of 3 sample roms, sets upper 2 address lines, and sets m5205 sample rate
+** counter asserts nmi on rollover (sample playback finished) (ff CLK pin, ff D = gnd)
+** main system reset line is ANDed (74LS08 IC11) with ff CLR pin such that nmi is asserted on system reset
*/
void renegade_state::adpcm_start_w(uint8_t data)
{
m_msm->reset_w(0);
m_adpcm_playing = true;
+ m_audiocpu->set_input_line(INPUT_LINE_NMI, CLEAR_LINE);
}
void renegade_state::adpcm_addr_w(uint8_t data)
@@ -144,36 +151,38 @@ void renegade_state::adpcm_addr_w(uint8_t data)
// table at $CB52 in audiocpu program:
// 38 38 39 3A 3B 34 35 36 37 2C 2D 2E 2F
//
- // bits 2-4 are active-low chip select; bit 5 is always set
- // (chip select for an unpopulated fourth ROM?)
+ // bits 2-4 are active-low chip select
switch (data & 0x1c)
{
- case 0x18: m_adpcm_pos = 0 * 0x8000 * 2; break; // 110 -> ic33
- case 0x14: m_adpcm_pos = 1 * 0x8000 * 2; break; // 101 -> ic32
- case 0x0c: m_adpcm_pos = 2 * 0x8000 * 2; break; // 011 -> ic31
- default: m_adpcm_pos = m_adpcm_end = 0; return; // doesn't happen
+ case 0x18: m_adpcm_pos = 0 * 0x8000 * 2; break; // 110 -> ic33
+ case 0x14: m_adpcm_pos = 1 * 0x8000 * 2; break; // 101 -> ic32
+ case 0x0c: m_adpcm_pos = 2 * 0x8000 * 2; break; // 011 -> ic31
+ default: m_adpcm_pos = m_adpcm_end = 0; return; // doesn't happen
}
// bits 0-1 are a13-a14
m_adpcm_pos |= (data & 0x03) * 0x2000 * 2;
// a0-a12 are driven by a binary counter; playback ends when it rolls over
m_adpcm_end = m_adpcm_pos + 0x2000 * 2;
+ // bit 5 selects 8 or 4 KHz m5205 sample rate (connected to the S1 pin, S2 pin is gnd)
+ m_msm->playmode_w(BIT(data, 5) ? msm5205_device::S48_4B : msm5205_device::S96_4B);
}
void renegade_state::adpcm_stop_w(uint8_t data)
{
m_msm->reset_w(1);
m_adpcm_playing = false;
+ m_audiocpu->set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
}
WRITE_LINE_MEMBER(renegade_state::adpcm_int)
{
- if (!m_adpcm_playing) return;
+ if (!m_adpcm_playing || !state) return;
if (m_adpcm_pos >= m_adpcm_end)
{
m_msm->reset_w(1);
m_adpcm_playing = false;
- m_audiocpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero);
+ m_audiocpu->set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
}
else
{
@@ -186,7 +195,7 @@ WRITE_LINE_MEMBER(renegade_state::adpcm_int)
void renegade_state::machine_start()
{
m_rombank->configure_entries(0, 2, memregion("maincpu")->base(), 0x4000);
-
+
save_item(NAME(m_adpcm_pos));
save_item(NAME(m_adpcm_end));
save_item(NAME(m_adpcm_playing));
@@ -234,9 +243,14 @@ TIMER_DEVICE_CALLBACK_MEMBER(renegade_state::interrupt)
{
int scanline = param;
- // vblank irq?
- if (scanline == 240)
+ // nmi 8 lines before vsync
+ if (scanline == 265)
m_maincpu->set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
+
+ // irq 16 clks per frame: once every 16 lines, but increases to 24 lines during vblank
+ // (lines 16,40,56,72,88,104,120,136,152,168,184,200,216,232,248,264)
+ if (scanline == 0x10 || (scanline > 0x20 && (scanline & 0xf) == 8))
+ m_maincpu->set_input_line(0, ASSERT_LINE);
}
void renegade_state::nmi_ack_w(uint8_t data)
@@ -246,13 +260,7 @@ void renegade_state::nmi_ack_w(uint8_t data)
void renegade_state::irq_ack_w(uint8_t data)
{
- if (data != 0xff)
- {
- // guess: trigger a 1->0 transition on irq ack
- machine().bookkeeping().coin_counter_w(0, 1);
- machine().bookkeeping().coin_counter_w(0, 0);
- }
- //m_maincpu->set_input_line(0, CLEAR_LINE);
+ m_maincpu->set_input_line(0, CLEAR_LINE);
}
@@ -287,18 +295,18 @@ void renegade_state::renegade_map(address_map &map)
void renegade_state::renegade_sound_map(address_map &map)
{
map(0x0000, 0x0fff).ram();
- map(0x1000, 0x1000).r(m_soundlatch, FUNC(generic_latch_8_device::read));
- map(0x1800, 0x1800).w(FUNC(renegade_state::adpcm_start_w));
- map(0x2000, 0x2000).w(FUNC(renegade_state::adpcm_addr_w));
- map(0x2800, 0x2801).rw("ymsnd", FUNC(ym3526_device::read), FUNC(ym3526_device::write));
- map(0x3000, 0x3000).w(FUNC(renegade_state::adpcm_stop_w));
-// map(0x2000, 0x7fff) read in service mode during sound test
+ map(0x1000, 0x17ff).r(m_soundlatch, FUNC(generic_latch_8_device::read));
+ map(0x1800, 0x1fff).w(FUNC(renegade_state::adpcm_start_w));
+ map(0x2000, 0x27ff).w(FUNC(renegade_state::adpcm_addr_w));
+ map(0x2800, 0x2fff).rw("ymsnd", FUNC(ym3526_device::read), FUNC(ym3526_device::write));
+ map(0x3000, 0x37ff).w(FUNC(renegade_state::adpcm_stop_w));
+ map(0x3800, 0x7fff).nopr(); // misc reads in service mode during sound test
map(0x8000, 0xffff).rom();
}
INPUT_CHANGED_MEMBER(renegade_state::coin_inserted)
{
- m_maincpu->set_input_line(0, newval ? CLEAR_LINE : ASSERT_LINE);
+ machine().bookkeeping().coin_counter_w(param ? 1 : 0, oldval);
}
@@ -321,7 +329,7 @@ static INPUT_PORTS_START( renegade )
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_NAME("P2 Left Attack")
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) PORT_NAME("P2 Jump")
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_CHANGED_MEMBER(DEVICE_SELF, renegade_state, coin_inserted, 0)
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_COIN2 ) PORT_CHANGED_MEMBER(DEVICE_SELF, renegade_state, coin_inserted, 0)
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_COIN2 ) PORT_CHANGED_MEMBER(DEVICE_SELF, renegade_state, coin_inserted, 1)
PORT_START("DSW2") /* DIP2 */
PORT_DIPNAME( 0x03, 0x03, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW2:1,2")
@@ -333,7 +341,7 @@ static INPUT_PORTS_START( renegade )
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_PLAYER(2) PORT_NAME("P2 Right Attack")
PORT_BIT( 0x30, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(renegade_state, mcu_status_r)
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_VBLANK("screen")
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE1 ) PORT_CHANGED_MEMBER(DEVICE_SELF, renegade_state, coin_inserted, 0)
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE1 )
PORT_START("DSW1") /* DIP1 */
PORT_DIPNAME( 0x03, 0x03, DEF_STR( Coin_A ) ) PORT_DIPLOCATION("SW1:1,2")
@@ -496,6 +504,7 @@ void renegade_state::machine_reset()
m_rombank->set_entry(0);
m_msm->reset_w(1);
m_adpcm_playing = 0;
+ m_audiocpu->set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
}
@@ -506,14 +515,14 @@ void renegade_state::renegade(machine_config &config)
m_maincpu->set_addrmap(AS_PROGRAM, &renegade_state::renegade_map);
TIMER(config, "scantimer").configure_scanline(FUNC(renegade_state::interrupt), "screen", 0, 1);
- MC6809(config, m_audiocpu, 12000000/2); // HD68A09P
+ MC6809(config, m_audiocpu, 12000000/2); /* HD68A09P 6 MHz (measured) */
m_audiocpu->set_addrmap(AS_PROGRAM, &renegade_state::renegade_sound_map); /* IRQs are caused by the main CPU */
- TAITO68705_MCU(config, m_mcu, 12000000/4); // ?
+ TAITO68705_MCU(config, m_mcu, 12000000/4); /* 3 MHz (measured) */
/* video hardware */
SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
- m_screen->set_raw(12000000/2, 384, 0, 256, 272, 0, 240); // assume same as ddragon.cpp
+ m_screen->set_raw(12000000/2, 384, 0, 256, 272, 19, 257);
m_screen->set_screen_update(FUNC(renegade_state::screen_update));
m_screen->set_palette("palette");
@@ -526,13 +535,12 @@ void renegade_state::renegade(machine_config &config)
GENERIC_LATCH_8(config, m_soundlatch);
m_soundlatch->data_pending_callback().set_inputline(m_audiocpu, M6809_IRQ_LINE);
- ym3526_device &ymsnd(YM3526(config, "ymsnd", 12000000/4));
+ ym3526_device &ymsnd(YM3526(config, "ymsnd", 12000000/4)); /* 3 MHz (measured) */
ymsnd.irq_handler().set_inputline(m_audiocpu, M6809_FIRQ_LINE);
ymsnd.add_route(ALL_OUTPUTS, "mono", 1.0);
- MSM5205(config, m_msm, 12000000/32);
- m_msm->vck_legacy_callback().set(FUNC(renegade_state::adpcm_int));
- m_msm->set_prescaler_selector(msm5205_device::S48_4B); /* 8kHz */
+ MSM5205(config, m_msm, 12000000/32); /* 375 KHz (measured) */
+ m_msm->vck_callback().set(FUNC(renegade_state::adpcm_int));
m_msm->add_route(ALL_OUTPUTS, "mono", 1.0);
}
@@ -709,7 +717,7 @@ ROM_END
-GAME( 1986, renegade, 0, renegade, renegade, renegade_state, empty_init, ROT0, "Technos Japan (Taito America license)", "Renegade (US)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
-GAME( 1986, renegadeb, renegade, kuniokunb, renegade, renegade_state, empty_init, ROT0, "bootleg", "Renegade (US bootleg)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
-GAME( 1986, kuniokun, renegade, renegade, renegade, renegade_state, empty_init, ROT0, "Technos Japan", "Nekketsu Kouha Kunio-kun (Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
-GAME( 1986, kuniokunb, renegade, kuniokunb, renegade, renegade_state, empty_init, ROT0, "bootleg", "Nekketsu Kouha Kunio-kun (Japan bootleg)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
+GAME( 1986, renegade, 0, renegade, renegade, renegade_state, empty_init, ROT0, "Technos Japan (Taito America license)", "Renegade (US)", MACHINE_SUPPORTS_SAVE )
+GAME( 1986, renegadeb, renegade, kuniokunb, renegade, renegade_state, empty_init, ROT0, "bootleg", "Renegade (US bootleg)", MACHINE_SUPPORTS_SAVE )
+GAME( 1986, kuniokun, renegade, renegade, renegade, renegade_state, empty_init, ROT0, "Technos Japan", "Nekketsu Kouha Kunio-kun (Japan)", MACHINE_SUPPORTS_SAVE )
+GAME( 1986, kuniokunb, renegade, kuniokunb, renegade, renegade_state, empty_init, ROT0, "bootleg", "Nekketsu Kouha Kunio-kun (Japan bootleg)", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/saitek_exchess.cpp b/src/mame/drivers/saitek_exchess.cpp
index e95ec363acf..447e9bbe21a 100644
--- a/src/mame/drivers/saitek_exchess.cpp
+++ b/src/mame/drivers/saitek_exchess.cpp
@@ -241,7 +241,7 @@ void exchess_state::exchess(machine_config &config)
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
- screen.set_size(1020, 1080);
+ screen.set_size(1020/1.5, 1080/1.5);
screen.set_visarea_full();
}
diff --git a/src/mame/drivers/saitek_mark5.cpp b/src/mame/drivers/saitek_mark5.cpp
index 1a3ca4bb6ae..827fa92d5be 100644
--- a/src/mame/drivers/saitek_mark5.cpp
+++ b/src/mame/drivers/saitek_mark5.cpp
@@ -436,7 +436,7 @@ void mark5_state::mark5(machine_config &config)
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
- screen.set_size(942, 1080);
+ screen.set_size(942/1.5, 1080/1.5);
screen.set_visarea_full();
config.set_default_layout(layout_saitek_mark5);
diff --git a/src/mame/drivers/saitek_simultano.cpp b/src/mame/drivers/saitek_simultano.cpp
index a5cfaf3f967..a01e5f80391 100644
--- a/src/mame/drivers/saitek_simultano.cpp
+++ b/src/mame/drivers/saitek_simultano.cpp
@@ -19,6 +19,9 @@ Hardware notes:
It also appeared in Tandy's Chess Champion 2150, not as a simple rebrand, but
with hardware differences: 3MHz R65C02, 1 64KB ROM and no EGR socket.
+TODO:
+- where does the IRQ come from? same problem as with stratos
+
***************************************************************************/
#include "emu.h"
diff --git a/src/mame/drivers/saitek_ssystem3.cpp b/src/mame/drivers/saitek_ssystem3.cpp
index 3036d4c0aed..08ae361f714 100644
--- a/src/mame/drivers/saitek_ssystem3.cpp
+++ b/src/mame/drivers/saitek_ssystem3.cpp
@@ -8,13 +8,11 @@ both SciSys and Novag. Which company was responsible for which part of the
manufacturing chain is unknown. The software is by SciSys (no mention of Novag
in the ROM, it has "COPYRIGHT SCISYS LTD 1979").
-This is their 1st original product. MK II was licensed from Commodore, and
+This is their 1st original product. MK II was licensed from Peter Jennings, and
MK I was, to put it bluntly, a bootleg. The chess engine is by Mike Johnson,
with support from David Levy.
-Hardware notes:
-
-Master Unit:
+Hardware notes (Master Unit):
- Synertek 6502A @ 2MHz (4MHz XTAL)
- Synertek 6522 VIA
- 8KB ROM (2*Synertek 2332)
@@ -25,7 +23,7 @@ Master Unit:
Chess Unit:
- PCB label: Radofin XM-2057-0C
-- Fairchild F6808P CPU @ ~6MHz (M6808 compatible)
+- Fairchild F6808P CPU @ ~6.8MHz (M6808 compatible)
- Fairchild F6821P PIA
- 2KB ROM(2316), 128x8 RAM(F6810P)
- 2*HLCD0438, chessboard LCD
@@ -54,7 +52,6 @@ TODO:
Should be doable to add, but 6522 device doesn't support live clock changes.
- LCD TC pin? connects to the display, source is a 50hz timer(from power supply),
probably to keep refreshing the LCD when inactive, there is no need to emulate it
-- finish chess unit lcd emulation
- dump/add printer unit
- dump/add ssystem3 1980 program revision, were the BTANB fixed?
- ssystem4 softwarelist if a prototype cartridge is ever dumped
@@ -65,6 +62,8 @@ BTANB (ssystem3):
lessen the chance by adding a spring to the switch.
- Similar to the TIME switch bug, pressing 2 buttons simultaneously can cause it
to malfunction, eg. press A+CE or C+CE and an "8" appears in the display.
+- chess unit screen briefly flickers at power-on and when the subcpu receives an
+ NMI in the middle of updating the LCD, it is mentioned in the manual
******************************************************************************/
@@ -97,15 +96,20 @@ public:
ssystem3_state(const machine_config &mconfig, device_type type, const char *tag) :
driver_device(mconfig, type, tag),
m_maincpu(*this, "maincpu"),
+ m_subcpu(*this, "subcpu"),
m_via(*this, "via"),
m_pia(*this, "pia"),
- m_lcd(*this, "lcd"),
- m_display(*this, "display"),
+ m_lcd1(*this, "lcd1"),
+ m_lcd2(*this, "lcd2_%u", 0),
+ m_display(*this, "display%u", 0),
m_dac(*this, "dac"),
m_nvram(*this, "nvram"),
- m_inputs(*this, "IN.%u", 0)
+ m_inputs(*this, "IN.%u", 0),
+ m_out_lcd2(*this, "s%u.%u", 0U, 0U)
{ }
+ DECLARE_INPUT_CHANGED_MEMBER(cu_plug);
+
// machine configs
void ssystem3(machine_config &config);
void ssystem4(machine_config &config);
@@ -118,13 +122,16 @@ protected:
private:
// devices/pointers
required_device<cpu_device> m_maincpu;
+ optional_device<cpu_device> m_subcpu;
required_device<via6522_device> m_via;
optional_device<pia6821_device> m_pia;
- required_device<md4332b_device> m_lcd;
- required_device<pwm_display_device> m_display;
+ required_device<md4332b_device> m_lcd1;
+ optional_device_array<hlcd0438_device, 2> m_lcd2;
+ optional_device_array<pwm_display_device, 2> m_display;
required_device<dac_bit_interface> m_dac;
optional_shared_ptr<u8> m_nvram;
- required_ioport_array<4+2> m_inputs;
+ optional_ioport_array<4+3> m_inputs;
+ output_finder<8, 48> m_out_lcd2;
// address maps
void ssystem3_map(address_map &map);
@@ -132,7 +139,7 @@ private:
void chessunit_map(address_map &map);
// I/O handlers
- void lcd_q_w(u32 data) { m_lcd_q = data; }
+ void lcd1_output_w(u32 data) { m_lcd1_data = data; }
void input_w(u8 data);
u8 input_r();
void control_w(u8 data);
@@ -141,26 +148,34 @@ private:
void nvram_w(offs_t offset, u8 data);
u8 nvram_r(offs_t offset);
- void pia_a_w(u8 data);
- u8 pia_a_r();
- void pia_b_w(u8 data);
- u8 pia_b_r();
- void pia_cb2_w(int state);
+ void lcd2_pwm_w(offs_t offset, u8 data);
+ void lcd2_update();
+ template<int N> void lcd2_output_w(offs_t offset, u32 data);
+ void cu_pia_a_w(u8 data);
+ u8 cu_pia_a_r();
+ void cu_pia_b_w(u8 data);
+ u8 cu_pia_b_r();
u8 m_inp_mux = 0;
u8 m_control = 0;
u8 m_shift = 0;
- u32 m_lcd_q = 0;
+ u32 m_lcd1_data = 0;
+ u64 m_lcd2_data = 0;
+ u8 m_lcd2_select = 0;
bool m_xor_kludge = false;
};
void ssystem3_state::machine_start()
{
+ m_out_lcd2.resolve();
+
// register for savestates
save_item(NAME(m_inp_mux));
save_item(NAME(m_control));
save_item(NAME(m_shift));
- save_item(NAME(m_lcd_q));
+ save_item(NAME(m_lcd1_data));
+ save_item(NAME(m_lcd2_data));
+ save_item(NAME(m_lcd2_select));
}
@@ -206,28 +221,28 @@ void ssystem3_state::control_w(u8 data)
// PB1: LCD DI
// PB2: LCD CLK
- m_lcd->di_w(BIT(data, 1));
- m_lcd->clk_w(BIT(data, 2));
+ m_lcd1->di_w(BIT(data, 1));
+ m_lcd1->clk_w(BIT(data, 2));
// PB2 also clocks a 4015B
// DA: LCD DO, DB: Q3A
if (data & ~m_control & 4)
{
- m_shift = m_shift << 1 | m_lcd->do_r();
+ m_shift = m_shift << 1 | m_lcd1->do_r();
// weird TTL maze, I assume it's a hw kludge to fix a bug after the maskroms were already manufactured
- u8 xorval = m_xor_kludge && (BIT(m_shift, 3) & ~(BIT(m_shift, 1) ^ BIT(m_shift, 4)) & ~(BIT(m_lcd_q, 7) & BIT(m_lcd_q, 23))) ? 0x12 : 0;
+ u8 xorval = m_xor_kludge && (BIT(m_shift, 3) & ~(BIT(m_shift, 1) ^ BIT(m_shift, 4)) & ~(BIT(m_lcd1_data, 7) & BIT(m_lcd1_data, 23))) ? 0x12 : 0;
// update display
for (int i = 0; i < 4; i++)
- m_display->write_row(i, m_lcd_q >> (8*i) & 0xff);
- m_display->write_row(4, (m_shift ^ xorval) | 0x100);
- m_display->update();
+ m_display[0]->write_row(i, m_lcd1_data >> (8*i) & 0xff);
+ m_display[0]->write_row(4, (m_shift ^ xorval) | 0x100);
+ m_display[0]->update();
}
// PB3: device serial out
if (m_inputs[5]->read() & 2)
- m_pia->ca1_w(BIT(data, 3));
+ m_pia->ca1_w(BIT(~data, 3));
// PB7: tied to PB6 (pulse timer 2)
m_via->write_pb6(BIT(data, 7));
@@ -239,9 +254,10 @@ u8 ssystem3_state::control_r()
{
u8 data = 0;
- // PB4: device busy
- // PB5: device attached?
- //data ^= 0x30;
+ // PB4: device busy (unused on chess unit)
+ // PB5: device attached
+ if (m_inputs[5]->read() & 2)
+ data ^= 0x30;
return ~data;
}
@@ -264,26 +280,74 @@ u8 ssystem3_state::nvram_r(offs_t offset)
// Chess Unit
-void ssystem3_state::pia_a_w(u8 data)
+INPUT_CHANGED_MEMBER(ssystem3_state::cu_plug)
+{
+ m_subcpu->set_input_line(INPUT_LINE_RESET, newval ? CLEAR_LINE : ASSERT_LINE);
+
+ if (newval)
+ m_pia->reset();
+ else
+ m_display[1]->clear();
+}
+
+void ssystem3_state::lcd2_pwm_w(offs_t offset, u8 data)
{
+ m_out_lcd2[offset & 0x3f][offset >> 6] = data;
}
-u8 ssystem3_state::pia_a_r()
+void ssystem3_state::lcd2_update()
{
- return 0;
+ if (m_inputs[5]->read() & 2)
+ m_display[1]->matrix(1 << m_lcd2_select, m_lcd2_data);
}
-void ssystem3_state::pia_b_w(u8 data)
+template<int N>
+void ssystem3_state::lcd2_output_w(offs_t offset, u32 data)
{
+ if (!offset)
+ data = 0;
+
+ m_lcd2_data = u64(data) << 32 | m_lcd2_data >> 32;
+
+ if (N == 1)
+ lcd2_update();
}
-u8 ssystem3_state::pia_b_r()
+void ssystem3_state::cu_pia_a_w(u8 data)
{
- return 0;
+ // PA0-PA2: CD4051 to LCD column
+ m_lcd2_select = data & 7;
+ lcd2_update();
}
-void ssystem3_state::pia_cb2_w(int state)
+u8 ssystem3_state::cu_pia_a_r()
{
+ // PA7: serial data in
+ return ~m_control << 4 & 0x80;
+}
+
+void ssystem3_state::cu_pia_b_w(u8 data)
+{
+ // PB3: LCD LOAD (both)
+ // PB4: LCD LCD (both) + CD4051 COM OUT/IN
+ // PB6: LCD CLOCK (both)
+ // PB7: LCD DATA IN (1st)
+ m_lcd2[0]->data_w(BIT(data, 7));
+
+ for (int i = 0; i < 2; i++)
+ m_lcd2[i]->clock_w(BIT(data, 6));
+
+ for (int i = 0; i < 2; i++)
+ m_lcd2[i]->load_w(BIT(~data, 3));
+
+ for (int i = 0; i < 2; i++)
+ m_lcd2[i]->lcd_w(BIT(data, 4));
+}
+
+u8 ssystem3_state::cu_pia_b_r()
+{
+ // PB5: look switch
+ return m_inputs[6]->read() << 5 & 0x20;
}
@@ -310,9 +374,9 @@ void ssystem3_state::ssystem4_map(address_map &map)
void ssystem3_state::chessunit_map(address_map &map)
{
- map(0x3600, 0x367f).ram();
+ map(0x3000, 0x307f).mirror(0x0f80).ram();
map(0x4000, 0x47ff).mirror(0xb800).rom();
- map(0xa000, 0xa003).rw(m_pia, FUNC(pia6821_device::read), FUNC(pia6821_device::write));
+ map(0x8000, 0x8003).mirror(0x3ffc).rw(m_pia, FUNC(pia6821_device::read), FUNC(pia6821_device::write));
}
@@ -350,7 +414,7 @@ static INPUT_PORTS_START( ssystem4 )
PORT_CONFNAME( 0x01, 0x01, "Sound" )
PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
PORT_CONFSETTING( 0x01, DEF_STR( On ) )
- PORT_CONFNAME( 0x02, 0x02, "LCD Light" )
+ PORT_CONFNAME( 0x02, 0x02, "LCD 1 Light" )
PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
PORT_CONFSETTING( 0x02, DEF_STR( On ) )
@@ -368,14 +432,22 @@ static INPUT_PORTS_START( ssystem3 )
PORT_MODIFY("IN.3")
PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYPAD) PORT_CODE(KEYCODE_T) PORT_NAME("Time") // spring-loaded
+ PORT_MODIFY("IN.4") // switches
+ PORT_CONFNAME( 0x04, 0x04, "LCD 2 Light" )
+ PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
+ PORT_CONFSETTING( 0x04, DEF_STR( On ) )
+
PORT_MODIFY("IN.5") // accessories/diodes
PORT_CONFNAME( 0x01, 0x01, "Memory Unit" )
PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
PORT_CONFSETTING( 0x01, DEF_STR( On ) )
- PORT_CONFNAME( 0x02, 0x02, "Chess Unit" )
+ PORT_CONFNAME( 0x02, 0x02, "Chess Unit" ) PORT_CHANGED_MEMBER(DEVICE_SELF, ssystem3_state, cu_plug, 0)
PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
PORT_CONFSETTING( 0x02, DEF_STR( On ) )
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_CUSTOM)
+
+ PORT_START("IN.6") // chess unit
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYPAD) PORT_TOGGLE PORT_CODE(KEYCODE_O) PORT_NAME("Look")
INPUT_PORTS_END
@@ -397,16 +469,16 @@ void ssystem3_state::ssystem4(machine_config &config)
m_via->readpb_handler().set(FUNC(ssystem3_state::control_r));
/* video hardware */
- MD4332B(config, m_lcd);
- m_lcd->write_q().set(FUNC(ssystem3_state::lcd_q_w));
+ MD4332B(config, m_lcd1);
+ m_lcd1->write_q().set(FUNC(ssystem3_state::lcd1_output_w));
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920/2, 729/2);
screen.set_visarea_full();
- PWM_DISPLAY(config, m_display).set_size(5, 9);
- m_display->set_bri_levels(0.25);
+ PWM_DISPLAY(config, m_display[0]).set_size(5, 9);
+ m_display[0]->set_bri_levels(0.25);
config.set_default_layout(layout_saitek_ssystem4);
@@ -423,22 +495,39 @@ void ssystem3_state::ssystem3(machine_config &config)
/* basic machine hardware */
m_maincpu->set_addrmap(AS_PROGRAM, &ssystem3_state::ssystem3_map);
- m6808_cpu_device &subcpu(M6808(config, "subcpu", 6000000)); // LC circuit
- subcpu.set_addrmap(AS_PROGRAM, &ssystem3_state::chessunit_map);
+ M6808(config, m_subcpu, 6800000); // LC circuit, measured
+ m_subcpu->set_addrmap(AS_PROGRAM, &ssystem3_state::chessunit_map);
config.set_perfect_quantum(m_maincpu);
PIA6821(config, m_pia, 0);
- m_pia->irqa_handler().set_inputline("subcpu", INPUT_LINE_NMI);
- m_pia->writepa_handler().set(FUNC(ssystem3_state::pia_a_w));
- m_pia->readpa_handler().set(FUNC(ssystem3_state::pia_a_r));
- m_pia->writepb_handler().set(FUNC(ssystem3_state::pia_b_w));
- m_pia->readpb_handler().set(FUNC(ssystem3_state::pia_b_r));
- m_pia->cb2_handler().set(FUNC(ssystem3_state::pia_cb2_w));
+ m_pia->irqa_handler().set_inputline(m_subcpu, INPUT_LINE_NMI);
+ m_pia->writepa_handler().set(FUNC(ssystem3_state::cu_pia_a_w));
+ m_pia->readpa_handler().set(FUNC(ssystem3_state::cu_pia_a_r));
+ m_pia->writepb_handler().set(FUNC(ssystem3_state::cu_pia_b_w));
+ m_pia->readpb_handler().set(FUNC(ssystem3_state::cu_pia_b_r));
+ m_pia->cb2_handler().set(m_pia, FUNC(pia6821_device::cb1_w));
+ m_pia->cb2_handler().append(m_pia, FUNC(pia6821_device::ca2_w));
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0);
- m_display->set_segmask(0xf, 0x7f); // 7segs are at expected positions
+ /* video hardware */
+ HLCD0438(config, m_lcd2[0], 0);
+ m_lcd2[0]->write_segs().set(FUNC(ssystem3_state::lcd2_output_w<0>));
+ m_lcd2[0]->write_data().set(m_lcd2[1], FUNC(hlcd0438_device::data_w));
+
+ HLCD0438(config, m_lcd2[1], 0);
+ m_lcd2[1]->write_segs().set(FUNC(ssystem3_state::lcd2_output_w<1>));
+
+ screen_device &screen(SCREEN(config, "chessunit", SCREEN_TYPE_SVG));
+ screen.set_refresh_hz(60);
+ screen.set_size(1060/1.5, 1080/1.5);
+ screen.set_visarea_full();
+
+ PWM_DISPLAY(config, m_display[1]).set_size(8, 48);
+ m_display[1]->output_x().set(FUNC(ssystem3_state::lcd2_pwm_w));
+
+ m_display[0]->set_segmask(0xf, 0x7f); // 7segs are at expected positions
config.set_default_layout(layout_saitek_ssystem3);
}
@@ -464,6 +553,9 @@ ROM_START( ssystem3 )
ROM_REGION(53552, "screen", 0)
ROM_LOAD("ssystem3.svg", 0, 53552, CRC(6047f88f) SHA1(2ff9cfce01cd3811a3f46f84b47fdc4ea2cf2ba8) )
+
+ ROM_REGION(748939, "chessunit", 0)
+ ROM_LOAD("chessunit.svg", 0, 748939, CRC(713a46fd) SHA1(6119162fb7c00f81aeca0dfe274475dc8575dd70) )
ROM_END
ROM_START( ssystem4 )
diff --git a/src/mame/drivers/saitek_stratos.cpp b/src/mame/drivers/saitek_stratos.cpp
index 4b508f34580..c370141917e 100644
--- a/src/mame/drivers/saitek_stratos.cpp
+++ b/src/mame/drivers/saitek_stratos.cpp
@@ -9,7 +9,6 @@ SciSys/Saitek Stratos chesscomputer family (1987-1990)
- Stratos
- Turbo King
- Corona --> saitek_corona.cpp
-- Simultano --> saitek_simultano.cpp
IMPORTANT: The user is expected to press the STOP button to turn off the computer.
When not using -autosave, press that button before exiting MAME, or NVRAM can get corrupt.
@@ -38,7 +37,6 @@ Hardware notes:
Stratos/Turbo King are identical.
Corona has magnet sensors and two HELIOS chips.
-Simultano has an extra LCD screen representing the chessboard state.
There is no official Saitek program versioning for these. The D/D+ versions are known since
they're the same chess engine as later Saitek modules, such as the Analyst module.
diff --git a/src/mame/drivers/sigmab98.cpp b/src/mame/drivers/sigmab98.cpp
index d569a04070c..39bc6c29f93 100644
--- a/src/mame/drivers/sigmab98.cpp
+++ b/src/mame/drivers/sigmab98.cpp
@@ -96,7 +96,7 @@ http://www.tsc-acnet.com/index.php?sort=8&action=cataloglist&s=1&mode=3&genre_id
To Do:
-- KL5C80 emulation is needed to consolidate the sammymdl games in one memory map and to run the BIOS
+- Consolidate the sammymdl games in one memory map and run the BIOS without ROM patches
- Remove ROM patches: gegege checks the EEPROM output after reset, and wants a timed 0->1 transition or locks up while
saving setting in service mode. Using a reset_delay of 7 works, unless when "play style" is set
to "coin" (it probably changes the number of reads from port $C0).
@@ -105,6 +105,7 @@ To Do:
with no visible gaps. It currently leaves the screen empty instead, for several seconds.
- tdoboon: no smoke from hit planes as shown in the video? Tiles are present (f60-125f) and used in demo mode.
- dashhero does not acknowledge the button bashing correctly, it's very hard to win (a slower pace works better!)
+- dodghero and sushimar often write zeroes to 81XX1 and 00XX1 for some reason (maybe just sloppy coding?)
Notes:
@@ -114,7 +115,7 @@ Notes:
#include "emu.h"
#include "cpu/z80/kl5c80a12.h"
-#include "cpu/z80/z80.h"
+#include "cpu/z80/ky80.h"
#include "machine/74165.h"
#include "machine/eepromser.h"
#include "machine/mb3773.h"
@@ -190,19 +191,14 @@ public:
sigmab98_state(const machine_config &mconfig, device_type type, const char *tag)
: sigmab98_base_state(mconfig, type, tag)
, m_maincpu(*this, "maincpu")
- , m_nvramdev(*this, "nvram")
- , m_eeprom(*this, "eeprom")
, m_hopper(*this, "hopper")
- , m_nvram(*this, "nvram")
+ , m_eeprom(*this, "eeprom")
, m_leds(*this, "led%u", 0U)
{ }
void sigmab98(machine_config &config);
void dodghero(machine_config &config);
- void dashhero(machine_config &config);
- void gegege(machine_config &config);
- void init_dodghero();
void init_b3rinsya();
void init_tbeastw2();
void init_dashhero();
@@ -211,19 +207,6 @@ public:
void init_ucytokyu();
protected:
- void gegege_regs_w(offs_t offset, uint8_t data);
- uint8_t gegege_regs_r(offs_t offset);
- void gegege_regs2_w(offs_t offset, uint8_t data);
- uint8_t gegege_regs2_r(offs_t offset);
-
- void dodghero_regs_w(offs_t offset, uint8_t data);
- uint8_t dodghero_regs_r(offs_t offset);
- void dodghero_regs2_w(offs_t offset, uint8_t data);
- uint8_t dodghero_regs2_r(offs_t offset);
-
- void dashhero_regs2_w(offs_t offset, uint8_t data);
- uint8_t dashhero_regs2_r(offs_t offset);
-
void c4_w(uint8_t data);
void c6_w(uint8_t data);
void c8_w(uint8_t data);
@@ -231,12 +214,8 @@ protected:
void show_outputs();
void eeprom_w(uint8_t data);
- DECLARE_MACHINE_RESET(sigmab98);
-
INTERRUPT_GEN_MEMBER(sigmab98_vblank_interrupt);
- void dashhero_io_map(address_map &map);
- void dodghero_io_map(address_map &map);
void dodghero_mem_map(address_map &map);
void gegege_io_map(address_map &map);
void gegege_mem_map(address_map &map);
@@ -244,27 +223,14 @@ protected:
virtual void machine_start() override { m_leds.resolve(); }
// Required devices
- required_device<cpu_device> m_maincpu;
+ required_device<ky80_device> m_maincpu;
+ required_device<ticket_dispenser_device> m_hopper;
// Optional devices
- optional_device<nvram_device> m_nvramdev; // battery backed RAM (should be required, but dashhero breaks with it)
optional_device<eeprom_serial_93cxx_device> m_eeprom;
- optional_device<ticket_dispenser_device> m_hopper;
-
- // Shared pointers
- required_shared_ptr<uint8_t> m_nvram;
output_finder<4> m_leds;
- uint8_t m_reg;
- uint8_t m_rombank;
- uint8_t m_reg2;
- uint8_t m_rambank;
-
- uint8_t m_vblank_vector;
- uint8_t m_timer0_vector;
- uint8_t m_timer1_vector;
-
uint8_t m_c0;
uint8_t m_c4;
uint8_t m_c6;
@@ -294,20 +260,20 @@ private:
int m_dsw_bit;
DECLARE_WRITE_LINE_MEMBER(dsw_w);
- void lufykzku_regs_w(offs_t offset, uint8_t data);
- uint8_t lufykzku_regs_r(offs_t offset);
void lufykzku_c4_w(uint8_t data);
void lufykzku_c6_w(uint8_t data);
uint8_t lufykzku_c8_r();
void lufykzku_c8_w(uint8_t data);
void lufykzku_watchdog_w(uint8_t data);
- DECLARE_MACHINE_RESET(lufykzku);
-
TIMER_DEVICE_CALLBACK_MEMBER(lufykzku_irq);
void lufykzku_io_map(address_map &map);
void lufykzku_mem_map(address_map &map);
+
+ uint8_t m_vblank_vector;
+ uint8_t m_timer0_vector;
+ uint8_t m_timer1_vector;
};
@@ -343,7 +309,6 @@ protected:
private:
TIMER_DEVICE_CALLBACK_MEMBER(sammymdl_irq);
- uint8_t unk_34_r();
uint8_t coin_counter_r();
void coin_counter_w(uint8_t data);
uint8_t leds_r();
@@ -739,229 +704,27 @@ uint8_t sigmab98_base_state::d021_r()
Minna Atsumare! Dodge Hero
***************************************************************************/
-// rombank
-void sigmab98_state::dodghero_regs_w(offs_t offset, uint8_t data)
-{
- if (offset == 0)
- {
- m_reg = data;
- return;
- }
-
- switch ( m_reg )
- {
- case 0x1f:
- m_rombank = data;
- if (data >= 0x18)
- logerror("%s: unknown rom bank = %02x\n", machine().describe_context(), data);
- else
- membank("rombank")->set_entry(data * 2);
- break;
-
- case 0x9f:
- m_rombank = data;
- if (data >= 0x18)
- logerror("%s: unknown rom bank2 = %02x\n", machine().describe_context(), data);
- else
- membank("rombank")->set_entry(data * 2 + 1);
- break;
-
- default:
- logerror("%s: unknown reg written: %02x = %02x\n", machine().describe_context(), m_reg, data);
- }
-}
-uint8_t sigmab98_state::dodghero_regs_r(offs_t offset)
-{
- if (offset == 0)
- return m_reg;
-
- switch ( m_reg )
- {
- case 0x1f:
- case 0x9f:
- return m_rombank;
-
- default:
- logerror("%s: unknown reg read: %02x\n", machine().describe_context(), m_reg);
- return 0x00;
- }
-}
-
-// rambank
-void sigmab98_state::dodghero_regs2_w(offs_t offset, uint8_t data)
-{
- if (offset == 0)
- {
- m_reg2 = data;
- return;
- }
-
- switch ( m_reg2 )
- {
- case 0x37:
- m_rambank = data;
- switch (data)
- {
- case 0x32:
- membank("rambank")->set_entry(0);
- break;
- case 0x36:
- membank("rambank")->set_entry(1);
- break;
- default:
- logerror("%s: unknown ram bank = %02x\n", machine().describe_context(), data);
- }
- break;
-
- default:
- logerror("%s: unknown reg2 written: %02x = %02x\n", machine().describe_context(), m_reg2, data);
- }
-}
-uint8_t sigmab98_state::dodghero_regs2_r(offs_t offset)
-{
- if (offset == 0)
- return m_reg2;
-
- switch ( m_reg2 )
- {
- case 0x37:
- return m_rambank;
-
- default:
- logerror("%s: unknown reg2 read: %02x\n", machine().describe_context(), m_reg2);
- return 0x00;
- }
-}
-
void sigmab98_state::dodghero_mem_map(address_map &map)
{
- map(0x0000, 0x7fff).rom();
- map(0x8000, 0xa7ff).bankr("rombank");
-
- map(0xa800, 0xb7ff).ram().share("spriteram");
-
- map(0xc800, 0xc9ff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette");
-
- map(0xd001, 0xd07f).ram().share("vtable");
+ map(0x00000, 0x1ffff).rom().nopw();
- map(0xd800, 0xdfff).bankrw("rambank"); // not used, where is it mapped?
+ map(0x40000, 0x41fff).ram().share("nvram"); // battery backed RAM
- map(0xd800, 0xd821).rw(FUNC(sigmab98_state::vregs_r), FUNC(sigmab98_state::vregs_w)).share("vregs");
- map(0xd813, 0xd813).r(FUNC(sigmab98_state::d013_r));
- map(0xd821, 0xd821).r(FUNC(sigmab98_state::d021_r));
+ map(0x80000, 0x80fff).ram().share("spriteram");
+ map(0x81000, 0x811ff).nopw();
+ map(0x82000, 0x821ff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette");
- map(0xe000, 0xefff).ram().share("nvram"); // battery backed RAM
+ map(0x82800, 0x8287f).ram().share("vtable");
- map(0xf000, 0xffff).ram();
-}
-
-void sigmab98_state::dodghero_io_map(address_map &map)
-{
- map.global_mask(0xff);
-
- map(0x00, 0x01).rw("ymz", FUNC(ymz280b_device::read), FUNC(ymz280b_device::write));
-
- map(0xa0, 0xa1).rw(FUNC(sigmab98_state::dodghero_regs_r), FUNC(sigmab98_state::dodghero_regs_w));
-// map(0xa2, 0xa3)
- map(0xa4, 0xa5).rw(FUNC(sigmab98_state::dodghero_regs2_r), FUNC(sigmab98_state::dodghero_regs2_w));
-
- map(0xc0, 0xc0).portr("EEPROM").w(FUNC(sigmab98_state::eeprom_w));
- map(0xc2, 0xc2).portr("BUTTON");
- map(0xc4, 0xc4).portr("PAYOUT").w(FUNC(sigmab98_state::c4_w));
- map(0xc6, 0xc6).w(FUNC(sigmab98_state::c6_w));
- map(0xc8, 0xc8).w(FUNC(sigmab98_state::c8_w));
+ map(0x83000, 0x83021).rw(FUNC(sigmab98_state::vregs_r), FUNC(sigmab98_state::vregs_w)).share("vregs");
+ map(0x83013, 0x83013).r(FUNC(sigmab98_state::d013_r));
+ map(0x83021, 0x83021).r(FUNC(sigmab98_state::d021_r));
}
/***************************************************************************
GeGeGe no Kitarou Youkai Slot
***************************************************************************/
-// rombank
-void sigmab98_state::gegege_regs_w(offs_t offset, uint8_t data)
-{
- if (offset == 0)
- {
- m_reg = data;
- return;
- }
-
- switch ( m_reg )
- {
- case 0x1f:
- m_rombank = data;
- if (data >= 0x18)
- logerror("%s: unknown rom bank = %02x\n", machine().describe_context(), data);
- else
- membank("rombank")->set_entry(data);
- break;
-
- default:
- logerror("%s: unknown reg written: %02x = %02x\n", machine().describe_context(), m_reg, data);
- }
-}
-uint8_t sigmab98_state::gegege_regs_r(offs_t offset)
-{
- if (offset == 0)
- return m_reg;
-
- switch ( m_reg )
- {
- case 0x1f:
- return m_rombank;
-
- default:
- logerror("%s: unknown reg read: %02x\n", machine().describe_context(), m_reg);
- return 0x00;
- }
-}
-
-// rambank
-void sigmab98_state::gegege_regs2_w(offs_t offset, uint8_t data)
-{
- if (offset == 0)
- {
- m_reg2 = data;
- return;
- }
-
- switch ( m_reg2 )
- {
- case 0xb5:
- m_rambank = data;
- switch (data)
- {
- case 0x32:
- membank("rambank")->set_entry(0);
- break;
- case 0x36:
- membank("rambank")->set_entry(1);
- break;
- default:
- logerror("%s: unknown ram bank = %02x\n", machine().describe_context(), data);
- }
- break;
-
- default:
- logerror("%s: unknown reg2 written: %02x = %02x\n", machine().describe_context(), m_reg2, data);
- }
-}
-uint8_t sigmab98_state::gegege_regs2_r(offs_t offset)
-{
- if (offset == 0)
- return m_reg2;
-
- switch ( m_reg2 )
- {
- case 0xb5:
- return m_rambank;
-
- default:
- logerror("%s: unknown reg2 read: %02x\n", machine().describe_context(), m_reg2);
- return 0x00;
- }
-}
-
-
// Outputs
void sigmab98_state::show_outputs()
@@ -1033,24 +796,19 @@ void sigmab98_state::c8_w(uint8_t data)
void sigmab98_state::gegege_mem_map(address_map &map)
{
- map(0x0000, 0x7fff).rom();
- map(0x8000, 0x9fff).bankr("rombank");
-
- map(0xa000, 0xafff).ram().share("spriteram");
-
- map(0xc000, 0xc1ff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette");
+ map(0x00000, 0x1ffff).rom();
- map(0xc800, 0xc87f).ram().share("vtable");
+ map(0x40000, 0x47fff).ram().share("nvram"); // battery backed RAM
- map(0xd000, 0xd021).rw(FUNC(sigmab98_state::vregs_r), FUNC(sigmab98_state::vregs_w)).share("vregs");
- map(0xd013, 0xd013).r(FUNC(sigmab98_state::d013_r));
- map(0xd021, 0xd021).r(FUNC(sigmab98_state::d021_r));
+ map(0x80000, 0x80fff).ram().share("spriteram");
- map(0xd800, 0xdfff).bankrw("rambank");
+ map(0x82000, 0x821ff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette");
- map(0xe000, 0xefff).ram().share("nvram"); // battery backed RAM
+ map(0x82800, 0x8287f).ram().share("vtable");
- map(0xf000, 0xffff).ram();
+ map(0x83000, 0x83021).rw(FUNC(sigmab98_state::vregs_r), FUNC(sigmab98_state::vregs_w)).share("vregs");
+ map(0x83013, 0x83013).r(FUNC(sigmab98_state::d013_r));
+ map(0x83021, 0x83021).r(FUNC(sigmab98_state::d021_r));
}
void sigmab98_state::gegege_io_map(address_map &map)
@@ -1059,89 +817,6 @@ void sigmab98_state::gegege_io_map(address_map &map)
map(0x00, 0x01).rw("ymz", FUNC(ymz280b_device::read), FUNC(ymz280b_device::write));
- map(0xa0, 0xa1).rw(FUNC(sigmab98_state::gegege_regs_r), FUNC(sigmab98_state::gegege_regs_w));
-// map(0xa2, 0xa3)
- map(0xa4, 0xa5).rw(FUNC(sigmab98_state::gegege_regs2_r), FUNC(sigmab98_state::gegege_regs2_w));
-
- map(0xc0, 0xc0).portr("EEPROM").w(FUNC(sigmab98_state::eeprom_w));
- map(0xc2, 0xc2).portr("BUTTON");
- map(0xc4, 0xc4).portr("PAYOUT").w(FUNC(sigmab98_state::c4_w));
- map(0xc6, 0xc6).w(FUNC(sigmab98_state::c6_w));
- map(0xc8, 0xc8).w(FUNC(sigmab98_state::c8_w));
-
- map(0xe5, 0xe5).nopr(); // during irq
-}
-
-/***************************************************************************
- Minna Ganbare! Dash Hero
-***************************************************************************/
-
-// rambank
-void sigmab98_state::dashhero_regs2_w(offs_t offset, uint8_t data)
-{
- if (offset == 0)
- {
- m_reg2 = data;
- return;
- }
-
- switch ( m_reg2 )
- {
- case 0x75:
- case 0xb5:
- case 0xf5:
- m_rambank = data;
- switch (data)
- {
- case 0x32:
- membank("rambank")->set_entry(0);
- break;
- case 0x34:
- membank("rambank")->set_entry(1);
- break;
- case 0x36:
- membank("rambank")->set_entry(2);
- break;
- case 0x39:
- membank("rambank")->set_entry(3);
- break;
- default:
- logerror("%s: unknown ram bank = %02x\n", machine().describe_context(), data);
- }
- break;
-
- default:
- logerror("%s: unknown reg2 written: %02x = %02x\n", machine().describe_context(), m_reg2, data);
- }
-}
-uint8_t sigmab98_state::dashhero_regs2_r(offs_t offset)
-{
- if (offset == 0)
- return m_reg2;
-
- switch ( m_reg2 )
- {
- case 0x75:
- case 0xb5:
- case 0xf5:
- return m_rambank;
-
- default:
- logerror("%s: unknown reg2 read: %02x\n", machine().describe_context(), m_reg2);
- return 0x00;
- }
-}
-
-void sigmab98_state::dashhero_io_map(address_map &map)
-{
- map.global_mask(0xff);
-
- map(0x00, 0x01).rw("ymz", FUNC(ymz280b_device::read), FUNC(ymz280b_device::write));
-
- map(0xa0, 0xa1).rw(FUNC(sigmab98_state::gegege_regs_r), FUNC(sigmab98_state::gegege_regs_w));
-// map(0xa2, 0xa3)
- map(0xa4, 0xa5).rw(FUNC(sigmab98_state::dashhero_regs2_r), FUNC(sigmab98_state::dashhero_regs2_w));
-
map(0xc0, 0xc0).portr("EEPROM").w(FUNC(sigmab98_state::eeprom_w));
map(0xc2, 0xc2).portr("BUTTON");
map(0xc4, 0xc4).portr("PAYOUT").w(FUNC(sigmab98_state::c4_w));
@@ -1156,56 +831,6 @@ void sigmab98_state::dashhero_io_map(address_map &map)
Otakara Itadaki Luffy Kaizoku-Dan!
***************************************************************************/
-// romrambank
-void lufykzku_state::lufykzku_regs_w(offs_t offset, uint8_t data)
-{
- if (offset == 0)
- {
- m_reg = data;
- return;
- }
-
- switch ( m_reg )
- {
- case 0x1f: // 8000
- m_rombank = data;
- switch (data)
- {
- case 0x00: // (8000) ROM
- membank("romrambank")->set_entry(0);
- break;
-
- case 0x78: // (80000) NVRAM
- membank("romrambank")->set_entry(1);
- break;
-
- default:
- logerror("%s: unknown rom bank = %02x, reg = %02x\n", machine().describe_context(), data, m_reg);
- }
- break;
-
- default:
- logerror("%s: unknown reg written: %02x = %02x\n", machine().describe_context(), m_reg, data);
- }
-}
-
-uint8_t lufykzku_state::lufykzku_regs_r(offs_t offset)
-{
- if (offset == 0)
- return m_reg;
-
- switch ( m_reg )
- {
- case 0x00:
- case 0x78:
- return m_rombank;
-
- default:
- logerror("%s: unknown reg read: %02x\n", machine().describe_context(), m_reg);
- return 0x00;
- }
-}
-
WRITE_LINE_MEMBER(lufykzku_state::dsw_w)
{
m_dsw_bit = state;
@@ -1267,20 +892,16 @@ void lufykzku_state::lufykzku_c8_w(uint8_t data)
void lufykzku_state::lufykzku_mem_map(address_map &map)
{
- map(0x0000, 0x7fff).rom();
- map(0x8000, 0xbfff).bankrw("romrambank").share("nvram"); // ROM | NVRAM
+ map(0x00000, 0x1ffff).rom();
+ map(0x80000, 0x83fff).ram().share("nvram");
- map(0xc000, 0xcfff).ram().share("spriteram");
+ map(0xc0000, 0xc0fff).ram().share("spriteram");
+ map(0xc1000, 0xc2fff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette"); // more palette entries
+ map(0xc3000, 0xc3021).rw(FUNC(lufykzku_state::vregs_r), FUNC(lufykzku_state::vregs_w)).share("vregs");
+ map(0xc3013, 0xc3013).r(FUNC(lufykzku_state::d013_r));
+ map(0xc3021, 0xc3021).r(FUNC(lufykzku_state::d021_r));
- map(0xd000, 0xefff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette"); // more palette entries
-
- map(0xf000, 0xf021).rw(FUNC(lufykzku_state::vregs_r), FUNC(lufykzku_state::vregs_w)).share("vregs");
- map(0xf013, 0xf013).r(FUNC(lufykzku_state::d013_r));
- map(0xf021, 0xf021).r(FUNC(lufykzku_state::d021_r));
-
- map(0xf400, 0xf47f).ram().share("vtable");
-
- map(0xfc00, 0xffff).ram();
+ map(0xc3400, 0xc347f).ram().share("vtable");
}
void lufykzku_state::lufykzku_io_map(address_map &map)
@@ -1289,8 +910,6 @@ void lufykzku_state::lufykzku_io_map(address_map &map)
map(0x00, 0x00).w("oki", FUNC(okim9810_device::write));
map(0x01, 0x01).w("oki", FUNC(okim9810_device::tmp_register_w));
- map(0xa2, 0xa3).rw(FUNC(lufykzku_state::lufykzku_regs_r), FUNC(lufykzku_state::lufykzku_regs_w));
-
map(0xc0, 0xc0).portr("COIN").w(FUNC(lufykzku_state::lufykzku_watchdog_w)); // bit 7 -> watchdog
map(0xc2, 0xc2).portr("BUTTON");
map(0xc4, 0xc4).portr("PAYOUT").w(FUNC(lufykzku_state::lufykzku_c4_w)); // bit 7 = medal lock, bit 6 = coin3, bit 5 = yen
@@ -1323,12 +942,6 @@ void sammymdl_state::eeprom_w(uint8_t data)
logerror("%s: unknown eeeprom bits written %02x\n", machine().describe_context(), data);
}
-uint8_t sammymdl_state::unk_34_r()
-{
- // mask 0x01?
- return 0x01;
-}
-
uint8_t sigmab98_base_state::vblank_r()
{
// mask 0x04 must be set before writing sprite list
@@ -1433,7 +1046,6 @@ void sammymdl_state::animalc_io(address_map &map)
map(0x30, 0x30).portr("BUTTON");
map(0x31, 0x31).rw(FUNC(sammymdl_state::coin_counter_r), FUNC(sammymdl_state::coin_counter_w));
map(0x32, 0x32).rw(FUNC(sammymdl_state::leds_r), FUNC(sammymdl_state::leds_w));
- map(0x34, 0x34).r(FUNC(sammymdl_state::unk_34_r));
map(0x90, 0x90).w("oki", FUNC(okim9810_device::write));
map(0x91, 0x91).w("oki", FUNC(okim9810_device::tmp_register_w));
map(0x92, 0x92).r("oki", FUNC(okim9810_device::read));
@@ -1447,7 +1059,7 @@ void sammymdl_state::animalc_io(address_map &map)
void sammymdl_state::gocowboy_map(address_map &map)
{
- map(0x00000, 0x3ffff).rom().region("mainbios", 0);
+ map(0x00000, 0x5ffff).rom().region("mainbios", 0);
map(0x60000, 0x67fff).ram().share("nvram");
map(0x70000, 0x70fff).ram().share("spriteram");
map(0x72000, 0x721ff).ram().w(m_palette, FUNC(palette_device::write8)).share("palette");
@@ -1905,15 +1517,6 @@ INPUT_PORTS_END
Sigma B-98 Games
***************************************************************************/
-MACHINE_RESET_MEMBER(sigmab98_state,sigmab98)
-{
- m_rombank = 0;
- membank("rombank")->set_entry(0);
-
- m_rambank = 0;
- membank("rambank")->set_entry(0);
-}
-
INTERRUPT_GEN_MEMBER(sigmab98_state::sigmab98_vblank_interrupt)
{
device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x5a); // Z80
@@ -1921,13 +1524,11 @@ INTERRUPT_GEN_MEMBER(sigmab98_state::sigmab98_vblank_interrupt)
void sigmab98_state::sigmab98(machine_config &config)
{
- Z80(config, m_maincpu, 10000000); // !! TAXAN KY-80, clock @X1? !!
+ KY80(config, m_maincpu, 20000000); // !! TAXAN KY-80, clock @X1? !!
m_maincpu->set_addrmap(AS_PROGRAM, &sigmab98_state::gegege_mem_map);
m_maincpu->set_addrmap(AS_IO, &sigmab98_state::gegege_io_map);
m_maincpu->set_vblank_int("screen", FUNC(sigmab98_state::sigmab98_vblank_interrupt));
- MCFG_MACHINE_RESET_OVERRIDE(sigmab98_state, sigmab98)
-
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0);
EEPROM_93C46_16BIT(config, "eeprom");
@@ -1962,25 +1563,6 @@ void sigmab98_state::dodghero(machine_config &config)
sigmab98(config);
m_maincpu->set_addrmap(AS_PROGRAM, &sigmab98_state::dodghero_mem_map);
- m_maincpu->set_addrmap(AS_IO, &sigmab98_state::dodghero_io_map);
-}
-
-void sigmab98_state::gegege(machine_config &config)
-{
- sigmab98(config);
-
- m_maincpu->set_addrmap(AS_PROGRAM, &sigmab98_state::gegege_mem_map);
- m_maincpu->set_addrmap(AS_IO, &sigmab98_state::gegege_io_map);
-}
-
-void sigmab98_state::dashhero(machine_config &config)
-{
- sigmab98(config);
-
- m_maincpu->set_addrmap(AS_PROGRAM, &sigmab98_state::gegege_mem_map);
- m_maincpu->set_addrmap(AS_IO, &sigmab98_state::dashhero_io_map);
-
- config.device_remove("nvram"); // FIXME: does not survive between sessions otherwise
}
@@ -1988,12 +1570,6 @@ void sigmab98_state::dashhero(machine_config &config)
Banpresto Medal Games
***************************************************************************/
-MACHINE_RESET_MEMBER(lufykzku_state,lufykzku)
-{
- m_rombank = 0;
- membank("romrambank")->set_entry(0);
-}
-
TIMER_DEVICE_CALLBACK_MEMBER(lufykzku_state::lufykzku_irq)
{
int scanline = param;
@@ -2008,13 +1584,11 @@ TIMER_DEVICE_CALLBACK_MEMBER(lufykzku_state::lufykzku_irq)
void lufykzku_state::lufykzku(machine_config &config)
{
- Z80(config, m_maincpu, XTAL(20'000'000) / 2); // !! TAXAN KY-80, clock @X1? !!
+ KY80(config, m_maincpu, XTAL(20'000'000)); // !! TAXAN KY-80, clock @X1? !!
m_maincpu->set_addrmap(AS_PROGRAM, &lufykzku_state::lufykzku_mem_map);
m_maincpu->set_addrmap(AS_IO, &lufykzku_state::lufykzku_io_map);
TIMER(config, "scantimer").configure_scanline(FUNC(lufykzku_state::lufykzku_irq), "screen", 0, 1);
- MCFG_MACHINE_RESET_OVERRIDE(lufykzku_state, lufykzku)
-
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0); // battery backed RAM
// No EEPROM
@@ -2061,15 +1635,20 @@ void lufykzku_state::lufykzku(machine_config &config)
TIMER_DEVICE_CALLBACK_MEMBER(sammymdl_state::sammymdl_irq)
{
int scanline = param;
+ uint16_t irqs = 0;
if (scanline == 240)
- m_maincpu->set_input_line_and_vector(0, HOLD_LINE, m_vblank_vector); // Z80
+ irqs |= 1 << ((m_vblank_vector & 0x1e) >> 1);
if (scanline == 128)
- m_maincpu->set_input_line_and_vector(0, HOLD_LINE, m_timer0_vector); // Z80
+ irqs |= 1 << ((m_timer0_vector & 0x1e) >> 1);
if (scanline == 32)
- m_maincpu->set_input_line_and_vector(0, HOLD_LINE, m_timer1_vector); // Z80
+ irqs |= 1 << ((m_timer1_vector & 0x1e) >> 1);
+
+ // FIXME: this is not much less of a hack than HOLD_LINE
+ if (irqs != 0)
+ m_maincpu->set_state_int(kl5c80a12_device::KP69_IRR, m_maincpu->state_int(kl5c80a12_device::KP69_IRR) | irqs);
}
void sammymdl_state::sammymdl(machine_config &config)
@@ -2192,17 +1771,6 @@ ROM_START( dodghero )
ROM_LOAD( "b9802-6.ic26", 0x80000, 0x80000, CRC(d83d8537) SHA1(9a5afdc68417db828a09188d653552452930b136) )
ROM_END
-void sigmab98_state::init_dodghero()
-{
- // ROM banks
- uint8_t *rom = memregion("maincpu")->base();
- membank("rombank")->configure_entries(0, 0x18*2, rom + 0x8000, 0x800);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 2);
- membank("rambank")->configure_entries(0, 2, bankedram, 0x800);
-}
-
/***************************************************************************
Itazura Daisuki! Sushimaru Kun
@@ -2287,15 +1855,6 @@ void sigmab98_state::init_gegege()
rom[0x8164] = 0x00;
rom[0x8165] = 0x00;
-
- // ROM banks
- membank("rombank")->configure_entries(0, 0x18, rom + 0x8000, 0x1000);
- membank("rombank")->set_entry(0);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 2);
- membank("rambank")->configure_entries(0, 2, bankedram, 0x800);
- membank("rambank")->set_entry(0);
}
/***************************************************************************
@@ -2326,15 +1885,6 @@ void sigmab98_state::init_b3rinsya()
rom[0x8164] = 0x00;
rom[0x8165] = 0x00;
-
- // ROM banks
- membank("rombank")->configure_entries(0, 0x18, rom + 0x8000, 0x1000);
- membank("rombank")->set_entry(0);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 2);
- membank("rambank")->configure_entries(0, 2, bankedram, 0x800);
- membank("rambank")->set_entry(0);
}
/***************************************************************************
@@ -2373,15 +1923,6 @@ void sigmab98_state::init_pepsiman()
rom[0x8164] = 0x00;
rom[0x8165] = 0x00;
-
- // ROM banks
- membank("rombank")->configure_entries(0, 0x18, rom + 0x8000, 0x1000);
- membank("rombank")->set_entry(0);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 2);
- membank("rambank")->configure_entries(0, 2, bankedram, 0x800);
- membank("rambank")->set_entry(0);
}
/***************************************************************************
@@ -2414,15 +1955,6 @@ void sigmab98_state::init_tbeastw2()
rom[0x8164] = 0x00;
rom[0x8165] = 0x00;
-
- // ROM banks
- membank("rombank")->configure_entries(0, 0x18, rom + 0x8000, 0x1000);
- membank("rombank")->set_entry(0);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 2);
- membank("rambank")->configure_entries(0, 2, bankedram, 0x800);
- membank("rambank")->set_entry(0);
}
/***************************************************************************
@@ -2463,15 +1995,6 @@ void sigmab98_state::init_ucytokyu()
rom[0x8164] = 0x00;
rom[0x8165] = 0x00;
-
- // ROM banks
- membank("rombank")->configure_entries(0, 0x18, rom + 0x8000, 0x1000);
- membank("rombank")->set_entry(0);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 2);
- membank("rambank")->configure_entries(0, 2, bankedram, 0x800);
- membank("rambank")->set_entry(0);
}
/***************************************************************************
@@ -2503,15 +2026,6 @@ void sigmab98_state::init_dashhero()
rom[0x8162] = 0x00;
rom[0x8163] = 0x00;
-
- // ROM banks
- membank("rombank")->configure_entries(0, 0x18, rom + 0x8000, 0x1000);
- membank("rombank")->set_entry(0);
-
- // RAM banks
- uint8_t *bankedram = auto_alloc_array(machine(), uint8_t, 0x800 * 4);
- membank("rambank")->configure_entries(0, 4, bankedram, 0x800);
- membank("rambank")->set_entry(0);
}
@@ -2561,17 +2075,6 @@ ROM_END
void lufykzku_state::init_lufykzku()
{
- m_nvram.allocate(0x4000);
- memset(m_nvram, 0, 0x4000);
- m_nvramdev->set_base(m_nvram, 0x4000);
-
- // ROM/RAM banks
- uint8_t *rom = memregion("maincpu")->base();
-
- membank("romrambank")->configure_entry(0, rom + 0x8000);
- membank("romrambank")->configure_entry(1, m_nvram);
- membank("romrambank")->set_entry(0);
-
m_vblank_vector = 0xfa; // nop
m_timer0_vector = 0xfc; // write coin counters/lockout, drive hopper
m_timer1_vector = 0xfe; // read inputs and hopper sensor, handle coin in
@@ -2876,14 +2379,14 @@ void sammymdl_state::init_haekaka()
***************************************************************************/
// Sigma Medal Games
-GAME( 1997, dodghero, 0, dodghero, sigma_1b, sigmab98_state, init_dodghero, ROT0, "Sigma", "Minna Atsumare! Dodge Hero", 0 )
-GAME( 1997, sushimar, 0, dodghero, sigma_3b, sigmab98_state, init_dodghero, ROT0, "Sigma", "Itazura Daisuki! Sushimaru Kun", 0 )
-GAME( 1997, gegege, 0, gegege, sigma_1b, sigmab98_state, init_gegege, ROT0, "Sigma / Banpresto", "GeGeGe no Kitarou Youkai Slot", 0 )
-GAME( 1997, b3rinsya, 0, gegege, sigma_5b, sigmab98_state, init_b3rinsya, ROT0, "Sigma", "Burning Sanrinsya - Burning Tricycle", 0 ) // 1997 in the rom
-GAME( 1997, pepsiman, 0, gegege, sigma_3b, sigmab98_state, init_pepsiman, ROT0, "Sigma", "PEPSI Man", 0 )
-GAME( 1998, tbeastw2, 0, gegege, sigma_3b, sigmab98_state, init_tbeastw2, ROT0, "Sigma / Transformer Production Company / Takara", "Transformers Beast Wars II", 0 ) // 1997 in the rom
-GAME( 1997, ucytokyu, 0, gegege, sigma_js, sigmab98_state, init_ucytokyu, ROT0, "Sigma", "Uchuu Tokkyuu Medalian", 0 ) // Banpresto + others in the ROM
-GAME( 2000, dashhero, 0, dashhero, sigma_1b, sigmab98_state, init_dashhero, ROT0, "Sigma", "Minna Ganbare! Dash Hero", MACHINE_NOT_WORKING ) // 1999 in the rom
+GAME( 1997, dodghero, 0, dodghero, sigma_1b, sigmab98_state, empty_init, ROT0, "Sigma", "Minna Atsumare! Dodge Hero", 0 )
+GAME( 1997, sushimar, 0, dodghero, sigma_3b, sigmab98_state, empty_init, ROT0, "Sigma", "Itazura Daisuki! Sushimaru Kun", 0 )
+GAME( 1997, gegege, 0, sigmab98, sigma_1b, sigmab98_state, init_gegege, ROT0, "Sigma / Banpresto", "GeGeGe no Kitarou Youkai Slot", 0 )
+GAME( 1997, b3rinsya, 0, sigmab98, sigma_5b, sigmab98_state, init_b3rinsya, ROT0, "Sigma", "Burning Sanrinsya - Burning Tricycle", 0 ) // 1997 in the rom
+GAME( 1997, pepsiman, 0, sigmab98, sigma_3b, sigmab98_state, init_pepsiman, ROT0, "Sigma", "PEPSI Man", 0 )
+GAME( 1998, tbeastw2, 0, sigmab98, sigma_3b, sigmab98_state, init_tbeastw2, ROT0, "Sigma / Transformer Production Company / Takara", "Transformers Beast Wars II", 0 ) // 1997 in the rom
+GAME( 1997, ucytokyu, 0, sigmab98, sigma_js, sigmab98_state, init_ucytokyu, ROT0, "Sigma", "Uchuu Tokkyuu Medalian", 0 ) // Banpresto + others in the ROM
+GAME( 2000, dashhero, 0, sigmab98, sigma_1b, sigmab98_state, init_dashhero, ROT0, "Sigma", "Minna Ganbare! Dash Hero", MACHINE_NOT_WORKING ) // 1999 in the rom
// Banpresto Medal Games
GAME( 2001, lufykzku, 0, lufykzku, lufykzku, lufykzku_state, init_lufykzku, ROT0, "Banpresto / Eiichiro Oda / Shueisha - Fuji TV - Toho Animation", "Otakara Itadaki Luffy Kaizoku-Dan! (Japan, v1.02)", 0 )
// Sammy Medal Games:
diff --git a/src/mame/drivers/snesb51.cpp b/src/mame/drivers/snesb51.cpp
index 14e700ecee5..7d44c11e308 100644
--- a/src/mame/drivers/snesb51.cpp
+++ b/src/mame/drivers/snesb51.cpp
@@ -6,9 +6,10 @@
Skeleton driver
- Currently there are dumps for a Mortal Kombat 3 board and a board with
- 4 slots that supports various games directly and also has a generic
- timer based mode.
+ The following systems are dumped:
+ - Mortal Kombat 3
+ - 4 Slot board
+ - 4 Slot board with built-in NBA Jam
Hardware (for the 4 slot switcher):
- MCS-51 based CPU 44-pin (markings removed)
@@ -67,6 +68,7 @@ public:
void mk3snes(machine_config &config);
void snes4sl(machine_config &config);
+ void snes4sln(machine_config &config);
protected:
void machine_start() override;
@@ -180,7 +182,7 @@ void snesb51_state::machine_start()
void snesb51_state::mk3snes(machine_config &config)
{
- I8751(config, m_mcu, 12_MHz_XTAL / 6);
+ I8751(config, m_mcu, 12_MHz_XTAL);
m_mcu->set_addrmap(AS_IO, &snesb51_state::io_map);
m_mcu->port_out_cb<1>().set(FUNC(snesb51_state::mcu_p1_w));
m_mcu->port_in_cb<3>().set(FUNC(snesb51_state::mcu_p3_r));
@@ -189,8 +191,8 @@ void snesb51_state::mk3snes(machine_config &config)
void snesb51_state::snes4sl(machine_config &config)
{
- // exact type and clock unknown
- I8031(config, m_mcu, 12_MHz_XTAL / 6);
+ // exact type unknown
+ I8031(config, m_mcu, 12_MHz_XTAL);
m_mcu->set_addrmap(AS_PROGRAM, &snesb51_state::mem_map);
m_mcu->set_addrmap(AS_IO, &snesb51_state::io_map);
m_mcu->port_out_cb<1>().set(FUNC(snesb51_state::mcu_p1_w));
@@ -202,6 +204,16 @@ void snesb51_state::snes4sl(machine_config &config)
GFXDECODE(config, "gfxdecode", "palette", chars);
}
+void snesb51_state::snes4sln(machine_config &config)
+{
+ I8051(config, m_mcu, 12_MHz_XTAL); // SAB 8051A-P
+ m_mcu->set_addrmap(AS_PROGRAM, &snesb51_state::mem_map);
+ m_mcu->set_addrmap(AS_IO, &snesb51_state::io_map);
+ m_mcu->port_out_cb<1>().set(FUNC(snesb51_state::mcu_p1_w));
+ m_mcu->port_in_cb<3>().set(FUNC(snesb51_state::mcu_p3_r));
+ m_mcu->port_out_cb<3>().set(FUNC(snesb51_state::mcu_p3_w));
+}
+
// this is identical to the snes release apart from a single byte
ROM_START( mk3snes )
ROM_REGION(0x400000, "game", 0)
@@ -227,6 +239,19 @@ ROM_START( snes4sl )
ROM_LOAD("27c256_11-03.bin", 0x0000, 0x8000, CRC(4e471581) SHA1(0f23ad065d448097f56ab45c3850d53cf85f3670))
ROM_END
-// YEAR NAME PARENT MACHINE INPUT CLASS INIT ROT COMPANY FULLNAME FLAGS
-GAME( 199?, mk3snes, 0, mk3snes, mk3snes, snesb51_state, empty_init, ROT0, "bootleg", "Mortal Kombat 3 (SNES bootleg)", MACHINE_IS_SKELETON )
-GAME( 1993, snes4sl, 0, snes4sl, snes4sl, snesb51_state, empty_init, ROT0, "bootleg", "SNES 4 Slot arcade switcher", MACHINE_IS_SKELETON )
+ROM_START( snes4sln )
+ // identical to NBA Jam (nbajamua)
+ ROM_REGION(0x400000, "game", 0)
+ ROM_LOAD("4.bin", 0x000000, 0x080000, CRC(d27bbebe) SHA1(fcf614fcd3c0fb06037038514d828f0cb597838e))
+ ROM_LOAD("3.bin", 0x080000, 0x080000, CRC(c0ca8c3c) SHA1(af5caa1b0254f6b42e4f7f3ba07d0af904017e3c))
+ ROM_LOAD("2.bin", 0x100000, 0x080000, CRC(4de70641) SHA1(1f575282a1bb842afcc80e29cebc13d96f8158a4))
+ ROM_LOAD("1.bin", 0x180000, 0x080000, CRC(9d59835f) SHA1(061872d9a2b39d271fbfc90b9e8f9abefcfa4282))
+
+ ROM_REGION(0x8000, "mcu", 0)
+ ROM_LOAD("5.bin", 0x0000, 0x8000, CRC(af8a64e3) SHA1(f13187d213fe7c2a0edcb88d4e828bd24112e812))
+ROM_END
+
+// YEAR NAME PARENT MACHINE INPUT CLASS INIT ROT COMPANY FULLNAME FLAGS
+GAME( 199?, mk3snes, 0, mk3snes, mk3snes, snesb51_state, empty_init, ROT0, "bootleg", "Mortal Kombat 3 (SNES bootleg)", MACHINE_IS_SKELETON )
+GAME( 1993, snes4sl, 0, snes4sl, snes4sl, snesb51_state, empty_init, ROT0, "bootleg", "SNES 4 Slot arcade switcher", MACHINE_IS_SKELETON )
+GAME( 1994, snes4sln, 0, snes4sln, snes4sl, snesb51_state, empty_init, ROT0, "bootleg", "SNES 4 Slot arcade switcher (NBA Jam)", MACHINE_IS_SKELETON )
diff --git a/src/mame/drivers/spg2xx.cpp b/src/mame/drivers/spg2xx.cpp
index d73041cf329..3ffed32cb32 100644
--- a/src/mame/drivers/spg2xx.cpp
+++ b/src/mame/drivers/spg2xx.cpp
@@ -317,6 +317,14 @@ void spg2xx_game_gssytts_state::mem_map_upperbank(address_map &map)
map(0x200000, 0x3fffff).bankr("upperbank");
}
+
+void spg2xx_game_wfcentro_state::mem_map_wfcentro(address_map &map)
+{
+ map(0x000000, 0x37ffff).bankr("cartbank");
+ map(0x380000, 0x3fffff).ram();
+}
+
+
static INPUT_PORTS_START( spg2xx ) // base structure for easy debugging / figuring out of inputs
PORT_START("P1")
PORT_DIPNAME( 0x0001, 0x0001, "P1:0001" )
@@ -629,6 +637,19 @@ static INPUT_PORTS_START( abltenni )
PORT_MODIFY("P3")
INPUT_PORTS_END
+
+static INPUT_PORTS_START( ordentv )
+ PORT_INCLUDE( spg2xx )
+
+ PORT_MODIFY("P2")
+ PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
+ PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
+ PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT )
+ PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
+ PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_BUTTON1 )
+ PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_BUTTON2 )
+INPUT_PORTS_END
+
static INPUT_PORTS_START( fordrace )
PORT_INCLUDE( spg2xx )
@@ -1482,6 +1503,20 @@ void spg2xx_game_gssytts_state::gssytts(machine_config &config)
}
+void spg2xx_game_wfcentro_state::wfcentro(machine_config &config)
+{
+ SPG24X(config, m_maincpu, XTAL(27'000'000), m_screen);
+ m_maincpu->set_addrmap(AS_PROGRAM, &spg2xx_game_wfcentro_state::mem_map_wfcentro);
+
+ spg2xx_base(config);
+
+ m_maincpu->porta_in().set(FUNC(spg2xx_game_wfcentro_state::base_porta_r));
+ m_maincpu->portb_in().set(FUNC(spg2xx_game_wfcentro_state::base_portb_r));
+ m_maincpu->portc_in().set(FUNC(spg2xx_game_wfcentro_state::base_portc_r));
+}
+
+
+
void spg2xx_game_senwfit_state::portc_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
int bank = 0;
@@ -1560,6 +1595,26 @@ void spg2xx_game_state::rad_crik(machine_config &config)
m_maincpu->i2c_r().set(FUNC(spg2xx_game_state::i2c_r));
}
+uint16_t spg2xx_game_ordentv_state::ordentv_portc_r(offs_t offset, uint16_t mem_mask)
+{
+ uint16_t data = m_io_p3->read() ^ (machine().rand() & 1);
+ logerror("%s: Port C Read: %04x (%04x)\n", machine().describe_context(), data, mem_mask);
+ return data;
+}
+
+void spg2xx_game_ordentv_state::ordentv(machine_config &config)
+{
+ SPG24X(config, m_maincpu, XTAL(27'000'000), m_screen);
+ m_maincpu->set_addrmap(AS_PROGRAM, &spg2xx_game_ordentv_state::mem_map_4m);
+
+ spg2xx_base(config);
+
+ m_maincpu->porta_in().set(FUNC(spg2xx_game_ordentv_state::base_porta_r));
+ m_maincpu->portb_in().set(FUNC(spg2xx_game_ordentv_state::base_portb_r));
+ m_maincpu->portc_in().set(FUNC(spg2xx_game_ordentv_state::ordentv_portc_r));
+}
+
+
ROM_START( rad_skat )
ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 )
ROM_LOAD16_WORD_SWAP( "skateboarder.bin", 0x000000, 0x400000, CRC(08b9ab91) SHA1(6665edc4740804956136c68065890925a144626b) )
@@ -1716,6 +1771,21 @@ ROM_START( senspeed )
ROM_LOAD16_WORD_SWAP( "speedracer.bin", 0x000000, 0x800000, CRC(4efbcd39) SHA1(2edffbaa9ea309ad308fa60f32d8b7a98ee313c7) )
ROM_END
+ROM_START( ordentv )
+ ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 )
+ ROM_LOAD16_WORD_SWAP( "taikeeordenadortv.bin", 0x000000, 0x800000, CRC(ba15895a) SHA1(0a18076cbc3264c91473b8518dfb10d679321b47) )
+ROM_END
+
+ROM_START( wfcentro )
+ ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 )
+ ROM_LOAD16_WORD_SWAP( "winfuncentro.bin", 0x000000, 0x800000, CRC(fd6ad052) SHA1(78af844729bf4843dc70531349e38a8c25caf748) )
+ROM_END
+
+ROM_START( tiktokmm )
+ ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 )
+ ROM_LOAD16_WORD_SWAP( "webcamthingy.bin", 0x000000, 0x800000, CRC(54c0d4a9) SHA1(709ee607ca447baa6f7e686268df1998372fe617) )
+ROM_END
+
void spg2xx_game_state::init_crc()
{
// several games have a byte sum checksum listed at the start of ROM, this little helper function logs what it should match.
@@ -1764,6 +1834,13 @@ void spg2xx_game_albkickb_state::init_ablkickb()
decrypt_ac_ff(ROM, size);
}
+void spg2xx_game_ordentv_state::init_ordentv()
+{
+ // the game will die by jumping to an infinite loop if this check fails, what is it checking?
+ uint16_t* rom = (uint16_t*)memregion("maincpu")->base();
+ rom[0x4fef8] = 0xee07;
+}
+
// year, name, parent, compat, machine, input, class, init, company, fullname, flags
@@ -1825,6 +1902,11 @@ CONS( 2007, dreamlss, 0, 0, dreamlss, dreamlss, spg2xx_game_dreamlss_
CONS( 2008, swclone, 0, 0, swclone, swclone, spg2xx_game_swclone_state, init_swclone, "Hasbro / Tiger Electronics", "Star Wars - The Clone Wars", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS )
// Mattel games
-CONS( 2005, mattelcs, 0, 0, rad_skat, mattelcs, spg2xx_game_state, empty_init, "Mattel", "Mattel Classic Sports", MACHINE_IMPERFECT_SOUND )
+CONS( 2005, mattelcs, 0, 0, rad_skat, mattelcs, spg2xx_game_state, empty_init, "Mattel", "Mattel Classic Sports", MACHINE_IMPERFECT_SOUND )
+
+CONS( 2007, ordentv, 0, 0, ordentv, ordentv, spg2xx_game_ordentv_state, init_ordentv, "Taikee / V-Tac", "Ordenador-TV (Spain)", MACHINE_NOT_WORKING )
+
+CONS( 200?, wfcentro, 0, 0, wfcentro, spg2xx, spg2xx_game_wfcentro_state, empty_init, "WinFun", "Centro TV de Diseno Artistico (Spain)", MACHINE_NOT_WORKING )
-// Both the WiWi and Fox Sports units seem to be related to the 'Virtual Interactive' (aka 'Vi') console
+// set 2862 to 0003 (irq enable) when it stalls on boot to show something (doesn't turn on IRQs again otherwise?) needs camera emulating
+CONS( 200?, tiktokmm, 0, 0, spg2xx, spg2xx, spg2xx_game_wfcentro_state, empty_init, "TikTokTech Ltd. / 3T Games / Senario", "Moving Music (MM-TV110)", MACHINE_NOT_WORKING )
diff --git a/src/mame/drivers/spg2xx_zone_32bit.cpp b/src/mame/drivers/spg2xx_zone_32bit.cpp
index d03f3641ae6..deec37e8ebe 100644
--- a/src/mame/drivers/spg2xx_zone_32bit.cpp
+++ b/src/mame/drivers/spg2xx_zone_32bit.cpp
@@ -49,6 +49,18 @@ protected:
int m_basebank;
};
+class mywicogt_state : public zon32bit_state
+{
+public:
+ mywicogt_state(const machine_config& mconfig, device_type type, const char* tag) :
+ zon32bit_state(mconfig, type, tag)
+ { }
+
+protected:
+ virtual void porta_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override;
+};
+
+
class mywicodx_state : public zon32bit_state
{
public:
@@ -153,6 +165,52 @@ void zon32bit_state::porta_w(offs_t offset, uint16_t data, uint16_t mem_mask)
}
+void mywicogt_state::porta_w(offs_t offset, uint16_t data, uint16_t mem_mask)
+{
+ if (1)
+ logerror("%s: porta_w %04x (%04x) %c %c %c %c | %c %c %c %c | %c %c %c %c | %c %c %c %c \n", machine().describe_context(), data, mem_mask,
+ (mem_mask & 0x8000) ? ((data & 0x8000) ? '1' : '0') : 'x',
+ (mem_mask & 0x4000) ? ((data & 0x4000) ? '1' : '0') : 'x',
+ (mem_mask & 0x2000) ? ((data & 0x2000) ? '1' : '0') : 'x',
+ (mem_mask & 0x1000) ? ((data & 0x1000) ? '1' : '0') : 'x',
+ (mem_mask & 0x0800) ? ((data & 0x0800) ? '1' : '0') : 'x',
+ (mem_mask & 0x0400) ? ((data & 0x0400) ? '1' : '0') : 'x',
+ (mem_mask & 0x0200) ? ((data & 0x0200) ? '1' : '0') : 'x',
+ (mem_mask & 0x0100) ? ((data & 0x0100) ? '1' : '0') : 'x',
+ (mem_mask & 0x0080) ? ((data & 0x0080) ? '1' : '0') : 'x',
+ (mem_mask & 0x0040) ? ((data & 0x0040) ? '1' : '0') : 'x',
+ (mem_mask & 0x0020) ? ((data & 0x0020) ? '1' : '0') : 'x',
+ (mem_mask & 0x0010) ? ((data & 0x0010) ? '1' : '0') : 'x',
+ (mem_mask & 0x0008) ? ((data & 0x0008) ? '1' : '0') : 'x',
+ (mem_mask & 0x0004) ? ((data & 0x0004) ? '1' : '0') : 'x',
+ (mem_mask & 0x0002) ? ((data & 0x0002) ? '1' : '0') : 'x',
+ (mem_mask & 0x0001) ? ((data & 0x0001) ? '1' : '0') : 'x');
+
+//[:] ':maincpu' (000508): porta_w 0b00 (0f00) x x x x | 1 0 1 1 | x x x x | x x x x
+//[:] ':maincpu' (000510): porta_w 0b00 (0f00) x x x x | 1 0 1 1 | x x x x | x x x x
+//[:] ':maincpu' (000518): porta_w 0f00 (0f00) x x x x | 1 1 1 1 | x x x x | x x x x
+
+ if (m_maincpu->pc() < 0x1000)
+ {
+ if (data == 0x0f00)
+ {
+ m_basebank = 1;
+ m_maincpu->invalidate_cache();
+ logerror("changing to bank 1\n");
+
+ }
+ else if (data == 0x0b00)
+ {
+ m_basebank = 0;
+ m_maincpu->invalidate_cache();
+ logerror("changing to bank 0\n");
+ }
+ }
+
+ m_porta_dat = data;
+}
+
+
void mywicodx_state::porta_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
if (0)
@@ -747,6 +805,14 @@ ROM_START( zon32bit )
ROM_CONTINUE(0x1800000, 0x0800000)
ROM_END
+ROM_START( mywicogt )
+ ROM_REGION( 0x2000000, "maincpu", ROMREGION_ERASE00 )
+ ROM_LOAD16_WORD_SWAP( "mywicoguitar.bin", 0x0000000, 0x0800000, CRC(3c037c50) SHA1(3b9a28fb643c9f90563d653be0f38eba09c26f26) )
+ ROM_CONTINUE(0x1000000, 0x0800000)
+ ROM_CONTINUE(0x0800000, 0x0800000)
+ ROM_CONTINUE(0x1800000, 0x0800000)
+ROM_END
+
/*
Following pinout was used for dumping
@@ -928,6 +994,8 @@ CONS( 200?, zon32bit, 0, 0, zon32bit, zon32bit, zon32bit_state, empty_init,
// The Mi Guitar menu contains 24 games, but they're dupes, and just counting those would exclude the other Mi Fit and Mi Papacon menus (which also contain dupes)
CONS( 200?, mywicodx, 0, 0, zon32bit, zon32bit, mywicodx_state, empty_init, "<unknown>", "My Wico Deluxe (Family Sport 85-in-1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS )
+CONS( 200?, mywicogt, 0, 0, zon32bit, zon32bit, mywicogt_state, empty_init, "<unknown>", "My Wico Guitar", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS )
+
// issues with 'low battery' always showing, but otherwise functional
CONS( 200?, oplayer, 0, 0, zon32bit_bat, oplayer, oplayer_100in1_state, init_oplayer, "OPlayer", "OPlayer Mobile Game Console (MGS03-white) (Family Sport 100-in-1)", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS )
diff --git a/src/mame/drivers/starcrus.cpp b/src/mame/drivers/starcrus.cpp
index eb304d53549..5cbcb2e6ff5 100644
--- a/src/mame/drivers/starcrus.cpp
+++ b/src/mame/drivers/starcrus.cpp
@@ -1,13 +1,15 @@
// license:BSD-3-Clause
-// copyright-holders:Frank Palazzolo
+// copyright-holders:Frank Palazzolo, Ryan Holtz
/***************************************************************************
-Ramtek Star Cruiser Driver
+ Ramtek Star Cruiser Driver
-(no known issues)
+ (no known issues)
-Frank Palazzolo
-palazzol@home.com
+ Frank Palazzolo
+ palazzol@home.com
+
+ Netlist Audio by Ryan Holtz
***************************************************************************/
@@ -15,7 +17,6 @@ palazzol@home.com
#include "includes/starcrus.h"
#include "cpu/i8085/i8085.h"
-#include "sound/samples.h"
#include "screen.h"
#include "speaker.h"
@@ -84,6 +85,12 @@ static INPUT_PORTS_START( starcrus )
PORT_DIPSETTING( 0x00, DEF_STR( Alternate ) )
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
+
+ PORT_START("POT_1")
+ PORT_ADJUSTER( 50, "Pot: Noise Level" ) NETLIST_ANALOG_PORT_CHANGED("sound_nl", "noise_volume")
+
+ PORT_START("POT_2")
+ PORT_ADJUSTER( 50, "Pot: Volume" ) NETLIST_ANALOG_PORT_CHANGED("sound_nl", "volume")
INPUT_PORTS_END
@@ -129,17 +136,6 @@ static GFXDECODE_START( gfx_starcrus )
GFXDECODE_END
-static const char *const starcrus_sample_names[] =
-{
- "*starcrus",
- "engine", /* engine sound, channel 0 */
- "explos1", /* explosion sound, first part, channel 1 */
- "explos2", /* explosion sound, second part, channel 1 */
- "launch", /* launch sound, channels 2 and 3 */
- nullptr
-};
-
-
void starcrus_state::starcrus(machine_config &config)
{
/* basic machine hardware */
@@ -163,10 +159,20 @@ void starcrus_state::starcrus(machine_config &config)
/* sound hardware */
SPEAKER(config, "mono").front_center();
- SAMPLES(config, m_samples);
- m_samples->set_channels(4);
- m_samples->set_samples_names(starcrus_sample_names);
- m_samples->add_route(ALL_OUTPUTS, "mono", 1.0);
+ NETLIST_SOUND(config, "sound_nl", 48000)
+ .set_source(NETLIST_NAME(starcrus))
+ .add_route(ALL_OUTPUTS, "mono", 1.0);
+
+ NETLIST_LOGIC_INPUT(config, "sound_nl:explode1", "EXPLODE_1.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:explode2", "EXPLODE_2.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:launch1", "LAUNCH_1.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:launch2", "LAUNCH_2.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:engine1", "ENGINE_1.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:engine2", "ENGINE_2.IN", 0);
+ NETLIST_ANALOG_INPUT(config, "sound_nl:noise_volume", "R23.DIAL");
+ NETLIST_ANALOG_INPUT(config, "sound_nl:volume", "R75.DIAL");
+
+ NETLIST_STREAM_OUTPUT(config, "sound_nl:cout0", 0, "R77.2").set_mult_offset(100000.0, 0.0);
}
/***************************************************************************
diff --git a/src/mame/drivers/taito_f3.cpp b/src/mame/drivers/taito_f3.cpp
index ff1450cc934..16fafb91630 100644
--- a/src/mame/drivers/taito_f3.cpp
+++ b/src/mame/drivers/taito_f3.cpp
@@ -3455,7 +3455,7 @@ ROMs found in a genuine Taito Cleopatra Fortune cart meant for the Japanese mark
all genuine parts including mask ROMs, PALs, ect. However the 4 program ROMs were replaced with 4 EPROMs without specific labels.
The replacement ROMs were 27C010 type instead of the standard 27C040 that Taito would normaly use. In the case of Cleopatra
-Fortune, each original program ROM is 0xFF filled from bytes 0x20000 through 0x3FFFF.
+Fortune, each original program ROM is 0xFF filled from bytes 0x20000 through 0x7FFFF.
In cleopatro, the program ROMs match the 1st 1/4 of cleopatr program ROMs except for 1 byte in ic17.bin. 0x1FFFF has been
changed from 0x00 to 0x03, which amounts to a simple region hack.
diff --git a/src/mame/drivers/tamag1.cpp b/src/mame/drivers/tamag1.cpp
index 84dc32cc379..649a6ca54cc 100644
--- a/src/mame/drivers/tamag1.cpp
+++ b/src/mame/drivers/tamag1.cpp
@@ -1,5 +1,6 @@
// license:BSD-3-Clause
// copyright-holders:hap
+// thanks-to:digshadow, segher
/***************************************************************************
Bandai Tamagotchi generation 1 hardware
diff --git a/src/mame/drivers/tankbatt.cpp b/src/mame/drivers/tankbatt.cpp
index 39264cb98dd..8dab5811de0 100644
--- a/src/mame/drivers/tankbatt.cpp
+++ b/src/mame/drivers/tankbatt.cpp
@@ -2,59 +2,74 @@
// copyright-holders:Brad Oliver
/***************************************************************************
-Tank Battalion memory map (preliminary)
+Tank Battalion memory map (verified)
driver by Brad Oliver
-$0000-$000f : bullet ram, first entry is player's bullet
-$0010-$01ff : zero page & stack
-$0200-$07ff : RAM
-$0800-$0bff : videoram
-$0c00-$0c1f : I/O
-
-Read:
- $0c00-$0c03 : p1 joystick
- $0c04
- $0c07 : stop at grid self-test if bit 7 is low
- $0c0f : stop at first self-test if bit 7 is low
-
- $0c18 : Cabinet, 0 = table, 1 = upright
- $0c19-$0c1a : Coinage, 00 = free play, 01 = 2 coin 1 credit, 10 = 1 coin 2 credits, 11 = 1 coin 1 credit
- $0c1b-$0c1c : Bonus, 00 = 10000, 01 = 15000, 10 = 20000, 11 = none
- $0c1d : Tanks, 0 = 3, 1 = 2
- $0c1e-$0c1f : ??
-
-Write:
- $0c00-$0c01 : p1/p2 start leds
- $0c02 : ?? written to at end of IRQ, either 0 or 1 - coin counter?
- $0c03 : ?? written to during IRQ if grid test is on
- $0c08 : ?? written to during IRQ if grid test is on
- $0c09 : Sound - coin ding
- $0c0a : NMI enable (active low) ?? game only ??
- $0c0b : Sound - background noise, 0 - low rumble, 1 - high rumble
- $0c0c : Sound - player fire
- $0c0d : Sound - explosion
- $0c0f : NMI enable (active high) ?? demo only ??
-
- $0c10 : IRQ ack ??
- $0c18 : Watchdog ?? Not written to while game screen is up
-
-$2000-$3fff : ROM
+Memory Map:
+ $0000-$03ff : Work RAM 0
+ $0400-$07ff : Work RAM 1
+ $0800-$0bff : VRAM
+ $0c00-$0fff : I/O
+ $2000-$3fff : ROM
+
+A 4-bit BCD value is created from the following four bits:
+ Bit 0: A3
+ Bit 1: A4
+ Bit 2: Read
+ Bit 3: !(A10 & A11)
+
+For writes, the following upper ranges are decoded:
+ xxxx 11xx xxx0 0xxx: OUT0
+ xxxx 11xx xxx0 1xxx: OUT1
+ xxxx 11xx xxx1 0xxx: INTACK
+ xxxx 11xx xxx1 1xxx: Watchdog
+
+For reads, the following upper ranges are decoded:
+ xxxx 11xx xxx0 0xxx: IN0
+ xxxx 11xx xxx0 1xxx: IN1
+ xxxx 11xx xxx1 0xxx: -
+ xxxx 11xx xxx1 1xxx: DIP switches
+
+OUT0:
+ 000: Edge Pin F P1 LED (schematic states Unused)
+ 001: Edge Pin 6 P2 LED (schematic states Unused)
+ 010: Edge Pin H Coin Counter (schematic states Unused)
+ 011: Edge Pin 7 Coin Lockout (schematic states Coin Counter)
+ 1xx: Unused
+
+OUT1:
+ 000: S1 (Square Wave 1, connected to 2V)
+ 001: S2 (Square Wave 2, connected to 4V)
+ 010: Sound off (1), on (0)
+ 011: Rumble hi (1), rumble low (0)
+ 100: Shoot sound effect
+ 101: Hit sound effect
+ 110: Unused
+ 111: NMI Enable
+
+IN0:
+ 000: Edge Pin Y Joystick Up
+ 001: Edge Pin M Joystick Left
+ 010: Edge Pin 14 Joystick Down
+ 011: Edge Pin 11 Joystick Right
+ 100: Edge Pin N Shoot
+ 101: Edge Pin J Coin 1
+ 110: Edge Pin 8 Coin 2
+ 111: Edge Pin 9 Service Switch
+
+IN1:
+ 000: Edge Pin 21 Joystick Up (Cocktail)
+ 001: Edge Pin P Joystick Left (Cocktail)
+ 010: Edge Pin V Joystick Down (Cocktail)
+ 011: Edge Pin 13 Joystick Right (Cocktail)
+ 100: Edge Pin 12 Shoot (Cocktail)
+ 101: Edge Pin L P1 Start
+ 110: Edge Pin 10 P2 Start
+ 111: Edge Pin K Test DIP Switch
TODO:
- . Needs proper discrete emulation
- . Resistor values on the color prom need to be verified
-
-Changes:
- 28 Feb 98 LBO
- . Fixed the coin interrupts
- . Fixed the color issues, should be 100% if I guessed at the resistor values properly
- . Fixed the 2nd player cocktail joystick, had the polarity reversed
- . Hacked the sound sample triggers so they work better
-
-Known issues:
- . The 'moving' tank rumble noise seems to keep playing a second too long
- . Sample support is all a crapshoot. I have no idea how it really works
+ . Resistor values on the color prom need to be corrected
***************************************************************************/
@@ -63,87 +78,35 @@ Known issues:
#include "cpu/m6502/m6502.h"
#include "machine/74259.h"
-#include "sound/samples.h"
+#include "machine/input_merger.h"
+#include "machine/watchdog.h"
#include "screen.h"
#include "speaker.h"
void tankbatt_state::machine_start()
{
- save_item(NAME(m_nmi_enable));
save_item(NAME(m_sound_enable));
}
uint8_t tankbatt_state::in0_r(offs_t offset)
{
- int val;
-
- val = ioport("P1")->read();
- return ((val << (7 - offset)) & 0x80);
+ return BIT(m_player_input[0]->read(), offset) << 7;
}
uint8_t tankbatt_state::in1_r(offs_t offset)
{
- int val;
-
- val = ioport("P2")->read();
- return ((val << (7 - offset)) & 0x80);
+ return BIT(m_player_input[1]->read(), offset) << 7;
}
uint8_t tankbatt_state::dsw_r(offs_t offset)
{
- int val;
-
- val = ioport("DSW")->read();
- return ((val << (7 - offset)) & 0x80);
-}
-
-WRITE_LINE_MEMBER(tankbatt_state::interrupt_enable_w)
-{
- m_nmi_enable = !state;
- m_sound_enable = !state;
-
- /* hack - turn off the engine noise if the normal game nmi's are disabled */
- if (state) m_samples->stop(2);
-}
-
-WRITE_LINE_MEMBER(tankbatt_state::demo_interrupt_enable_w)
-{
- m_nmi_enable = state;
-}
-
-WRITE_LINE_MEMBER(tankbatt_state::sh_expl_w)
-{
- if (state) // rising edge
- {
- m_samples->start(1, 3);
- }
-}
-
-WRITE_LINE_MEMBER(tankbatt_state::sh_engine_w)
-{
- if (m_sound_enable)
- {
- if (state)
- m_samples->start(2, 2, true);
- else
- m_samples->start(2, 1, true);
- }
- else m_samples->stop(2);
+ return BIT(m_dips->read(), offset) << 7;
}
-WRITE_LINE_MEMBER(tankbatt_state::sh_fire_w)
+void tankbatt_state::intack_w(uint8_t data)
{
- if (state) // rising edge
- {
- m_samples->start(0, 0);
- }
-}
-
-void tankbatt_state::irq_ack_w(uint8_t data)
-{
- /* 0x6e written at the end of the irq routine, could be either irq ack or a coin sample */
- m_maincpu->set_input_line(0, CLEAR_LINE);
+ m_maincpu->set_input_line(m6502_device::IRQ_LINE, CLEAR_LINE);
}
WRITE_LINE_MEMBER(tankbatt_state::coincounter_w)
@@ -159,29 +122,21 @@ WRITE_LINE_MEMBER(tankbatt_state::coinlockout_w)
void tankbatt_state::main_map(address_map &map)
{
- map(0x0000, 0x000f).ram().share("bulletsram");
- map(0x0010, 0x01ff).ram();
- map(0x0200, 0x07ff).ram();
- map(0x0800, 0x0bff).ram().w(FUNC(tankbatt_state::videoram_w)).share("videoram");
- map(0x0c00, 0x0c07).r(FUNC(tankbatt_state::in0_r)).w("outlatch", FUNC(cd4099_device::write_d0));
- map(0x0c08, 0x0c0f).r(FUNC(tankbatt_state::in1_r)).w("mainlatch", FUNC(cd4099_device::write_d0));
- map(0x0c10, 0x0c10).w(FUNC(tankbatt_state::irq_ack_w));
- map(0x0c18, 0x0c1f).r(FUNC(tankbatt_state::dsw_r));
- map(0x0c18, 0x0c18).nopw(); /* watchdog ?? */
- map(0x6000, 0x7fff).rom().region("maincpu", 0);
- map(0xe000, 0xffff).rom().region("maincpu", 0); //mirror for the reset/irq vectors
- map(0x2000, 0x5fff).nopr(); //anything else might be left-over for a diagnostic ROM or something related to the discrete sound HW
- map(0x8000, 0xdfff).nopr();
+ map.global_mask(0x3fff);
+ map(0x0000, 0x000f).mirror(0x1000).ram().share("bulletsram");
+ map(0x0010, 0x07ff).mirror(0x1000).ram();
+ map(0x0800, 0x0bff).mirror(0x1000).ram().w(FUNC(tankbatt_state::videoram_w)).share("videoram");
+ map(0x0c00, 0x0c07).mirror(0x13e0).r(FUNC(tankbatt_state::in0_r)).w("outlatch0", FUNC(cd4099_device::write_d0));
+ map(0x0c08, 0x0c0f).mirror(0x13e0).r(FUNC(tankbatt_state::in1_r)).w("outlatch1", FUNC(cd4099_device::write_d0));
+ map(0x0c10, 0x0c10).mirror(0x13e7).w(FUNC(tankbatt_state::intack_w));
+ map(0x0c18, 0x0c1f).mirror(0x13e0).r(FUNC(tankbatt_state::dsw_r));
+ map(0x0c18, 0x0c18).mirror(0x13e7).w("watchdog", FUNC(watchdog_timer_device::reset_w));
+ map(0x2000, 0x3fff).rom().region("maincpu", 0);
}
-INTERRUPT_GEN_MEMBER(tankbatt_state::interrupt)
+TIMER_DEVICE_CALLBACK_MEMBER(tankbatt_state::scanline_interrupt)
{
- if (m_nmi_enable) device.execute().pulse_input_line(INPUT_LINE_NMI, attotime::zero);
-}
-
-INPUT_CHANGED_MEMBER(tankbatt_state::coin_inserted)
-{
- m_maincpu->set_input_line(0, ASSERT_LINE);
+ m_maincpu->set_input_line(m6502_device::IRQ_LINE, ASSERT_LINE);
}
static INPUT_PORTS_START( tankbatt )
@@ -191,9 +146,9 @@ static INPUT_PORTS_START( tankbatt )
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_4WAY
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_4WAY
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 )
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_CHANGED_MEMBER(DEVICE_SELF, tankbatt_state,coin_inserted, 0)
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN2 ) PORT_CHANGED_MEMBER(DEVICE_SELF, tankbatt_state,coin_inserted, 0)
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_TILT )
+ PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 )
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN2 )
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE )
PORT_START("P2") /* IN1 */
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_4WAY PORT_COCKTAIL
@@ -258,47 +213,41 @@ GFXDECODE_END
-static const char *const tankbatt_sample_names[] =
-{
- "*tankbatt",
- "fire",
- "engine1",
- "engine2",
- "explode1",
- nullptr /* end of array */
-};
-
-
void tankbatt_state::tankbatt(machine_config &config)
{
/* basic machine hardware */
- M6502(config, m_maincpu, 1000000); /* 1 MHz ???? */
+ M6502(config, m_maincpu, 18.432_MHz_XTAL / 24); // ϕ0 = 4H
m_maincpu->set_addrmap(AS_PROGRAM, &tankbatt_state::main_map);
- m_maincpu->set_vblank_int("screen", FUNC(tankbatt_state::interrupt));
-
- cd4099_device &mainlatch(CD4099(config, "mainlatch")); // latches at 4H and 5H (are the empty 4J and 5J locations for LS259 substitution?)
- mainlatch.q_out_cb<0>().set_nop(); //coin counter mirror?
- mainlatch.q_out_cb<2>().set(FUNC(tankbatt_state::interrupt_enable_w));
- mainlatch.q_out_cb<3>().set(FUNC(tankbatt_state::sh_engine_w));
- mainlatch.q_out_cb<4>().set(FUNC(tankbatt_state::sh_fire_w));
- mainlatch.q_out_cb<5>().set(FUNC(tankbatt_state::sh_expl_w)); // bit 7 also set by ASL instruction
- mainlatch.q_out_cb<6>().set_nop(); // bit 7 also set by ASL instruction
- mainlatch.q_out_cb<7>().set(FUNC(tankbatt_state::demo_interrupt_enable_w));
-
- cd4099_device &outlatch(CD4099(config, "outlatch"));
- outlatch.q_out_cb<0>().set_output("led0");
- outlatch.q_out_cb<1>().set_output("led1");
- outlatch.q_out_cb<2>().set(FUNC(tankbatt_state::coincounter_w));
- outlatch.q_out_cb<3>().set(FUNC(tankbatt_state::coinlockout_w));
+
+ INPUT_MERGER_ALL_HIGH(config, "nmigate").output_handler().set_inputline(m_maincpu, m6502_device::NMI_LINE);
+
+ TIMER(config, "16v").configure_scanline(FUNC(tankbatt_state::scanline_interrupt), "screen", 16, 32);
+
+ WATCHDOG_TIMER(config, "watchdog").set_vblank_count("screen", 16); // system reset pulse is ripple carry output of 74LS161 at 7C
+
+ cd4099_device &outlatch0(CD4099(config, "outlatch0")); // 4099 at 5H or 259 at 5J
+ outlatch0.q_out_cb<0>().set_output("led0");
+ outlatch0.q_out_cb<1>().set_output("led1");
+ outlatch0.q_out_cb<2>().set(FUNC(tankbatt_state::coincounter_w));
+ outlatch0.q_out_cb<3>().set(FUNC(tankbatt_state::coinlockout_w));
+ // Q4 through Q7 are not connected
+
+ cd4099_device &outlatch1(CD4099(config, "outlatch1")); // 4099 at 4H or 259 at 4J
+ outlatch1.q_out_cb<0>().set(m_sound_s1, FUNC(netlist_mame_logic_input_device::write_line));
+ outlatch1.q_out_cb<1>().set(m_sound_s2, FUNC(netlist_mame_logic_input_device::write_line));
+ outlatch1.q_out_cb<2>().set(m_sound_off, FUNC(netlist_mame_logic_input_device::write_line));
+ outlatch1.q_out_cb<3>().set(m_sound_engine_hi, FUNC(netlist_mame_logic_input_device::write_line));
+ outlatch1.q_out_cb<4>().set(m_sound_shoot, FUNC(netlist_mame_logic_input_device::write_line));
+ outlatch1.q_out_cb<5>().set(m_sound_hit, FUNC(netlist_mame_logic_input_device::write_line));
+ // Q6 is not connected
+ outlatch1.q_out_cb<7>().set("nmigate", FUNC(input_merger_device::in_w<1>));
/* video hardware */
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
- screen.set_refresh_hz(60);
- screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
- screen.set_size(32*8, 32*8);
- screen.set_visarea(0*8, 32*8-1, 2*8, 30*8-1);
+ screen.set_raw(18.432_MHz_XTAL / 3, 384, 0, 256, 264, 16, 240); // timing chain is same as in Galaxian
screen.set_screen_update(FUNC(tankbatt_state::screen_update));
screen.set_palette(m_palette);
+ screen.screen_vblank().set("nmigate", FUNC(input_merger_device::in_w<0>));
GFXDECODE(config, m_gfxdecode, m_palette, gfx_tankbatt);
PALETTE(config, m_palette, FUNC(tankbatt_state::tankbatt_palette), 256*2, 256);
@@ -306,10 +255,18 @@ void tankbatt_state::tankbatt(machine_config &config)
/* sound hardware */
SPEAKER(config, "mono").front_center();
- SAMPLES(config, m_samples);
- m_samples->set_channels(3);
- m_samples->set_samples_names(tankbatt_sample_names);
- m_samples->add_route(ALL_OUTPUTS, "mono", 0.25);
+ NETLIST_SOUND(config, "sound_nl", 48000)
+ .set_source(NETLIST_NAME(tankbatt))
+ .add_route(ALL_OUTPUTS, "mono", 1.0);
+
+ NETLIST_LOGIC_INPUT(config, "sound_nl:s1", "S1.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:s2", "S2.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:off", "OFF.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:engine_hi", "ENGINE_HI.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:shoot", "SHOOT.IN", 0);
+ NETLIST_LOGIC_INPUT(config, "sound_nl:hit", "HIT.IN", 0);
+
+ NETLIST_STREAM_OUTPUT(config, "sound_nl:cout0", 0, "R35.2").set_mult_offset(10000.0, 0.0);
}
@@ -348,5 +305,5 @@ ROM_START( tankbattb ) /* board with "NAMCO" removed from gfx1 rom, otherwise id
ROM_LOAD( "bct1-1.l3", 0x0000, 0x0100, CRC(d17518bc) SHA1(f3b0deffa586808bc59e9a24ec1699c54ebe84cc) ) // dm74s287n.3l
ROM_END
-GAME( 1980, tankbatt, 0, tankbatt, tankbatt, tankbatt_state, empty_init, ROT90, "Namco", "Tank Battalion", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
-GAME( 1980, tankbattb, tankbatt, tankbatt, tankbatt, tankbatt_state, empty_init, ROT90, "bootleg", "Tank Battalion (bootleg)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
+GAME( 1980, tankbatt, 0, tankbatt, tankbatt, tankbatt_state, empty_init, ROT90, "Namco", "Tank Battalion", MACHINE_IMPERFECT_COLORS |MACHINE_SUPPORTS_SAVE )
+GAME( 1980, tankbattb, tankbatt, tankbatt, tankbatt, tankbatt_state, empty_init, ROT90, "bootleg", "Tank Battalion (bootleg)", MACHINE_IMPERFECT_COLORS | MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/tecmo.cpp b/src/mame/drivers/tecmo.cpp
index ea82c85c471..641564fb73e 100644
--- a/src/mame/drivers/tecmo.cpp
+++ b/src/mame/drivers/tecmo.cpp
@@ -1105,6 +1105,12 @@ ROM_END
sound cpu: sharp LH0080A Z80A @ 4MHz 8705
this set shows "GF" (revision?) on title screen
this seems to be a bootleg of a prototype, not sure if it's the other proto set hacked or another rev proto
+ some of the tile roms are half size but the original has a lot of unused data so nothing is missing in game.
+ the various Mitsubishi custom chips present on original board are implemented with standard ttl chips:
+ MN50005XTA on the main board is 11 ttl chips
+ M60002-0118P on the video board is 27 ttl chips
+ MA7053 sil module on the main board is 4 ttl chips
+ these are all properly integrated into the design of the boards, not plug-in sub/daughter boards.
*/
ROM_START( silkwormb )
ROM_REGION( 0x20000, "maincpu", 0 )
@@ -1133,7 +1139,7 @@ ROM_START( silkwormb )
ROM_LOAD( "silkworm.14", 0x00000, 0x10000, CRC(409df64b) SHA1(cada970bf9cc8f6522e7a71e00fe873568852873) ) /* bg tiles TMM24512 */
ROM_LOAD( "e14.15", 0x10000, 0x08000, CRC(b02acdb6) SHA1(6be74bb89680b79b3a5d13af638ed5a0bb077dad) ) /* bg tiles 27C256 */
ROM_LOAD( "e15.16", 0x20000, 0x08000, CRC(caf7b25e) SHA1(2c348af9d03efd801cbbc06deb02869bd6449518) ) /* bg tiles 27C256 */
- ROM_LOAD( "e16.17", 0x30000, 0x08000, CRC(7ec93873) SHA1(0993a3b3e5ca84ef0ea32159825e379ba4cc5fbb) ) /* bg tiles 27C256 */
+ ROM_LOAD( "e16.17", 0x38000, 0x08000, CRC(7ec93873) SHA1(0993a3b3e5ca84ef0ea32159825e379ba4cc5fbb) ) /* bg tiles 27C256 */
ROM_END
/*
diff --git a/src/mame/drivers/tecnodar.cpp b/src/mame/drivers/tecnodar.cpp
index bead411e116..9202f413d0c 100644
--- a/src/mame/drivers/tecnodar.cpp
+++ b/src/mame/drivers/tecnodar.cpp
@@ -1,8 +1,38 @@
// license:BSD-3-Clause
// copyright-holders:AJR
/*******************************************************************************
-
Skeleton driver for Automatics Pasqual darts with CRT display.
+ ________________________________________________________________________________
+ | _______ _______ ______ |
+ | |__CN__| |__CN__| |__CN_| ___ |
+ | ___ ___ | ||
+ | |F| |F| __________ ___ | ||
+ | |U| |U| |74LS373N_| ____ | | | ||
+ | |S| |S| __________ ___________ |___|| | | ||
+ | |E| |E| KS74HCTLS379N | RAM | _________ | | |C ||
+ | |__________| |_LM380N_| ______ |__| |N ||
+ | _________ ____________ _________ | | ___ | ||
+ | |SN74HC14N | EMPTY | |MT4264-10 | | | | | ||
+ | |___________| _________ | | | | | ||
+ | _________ ____________ |MT4264-10 TMP82C55AP-2 | | ||
+ | |74HC32AP| | EMPTY | _________ | | |__| |__||
+ | |___________| |MT4264-10 | | ___ ___ |
+ | ___ _________ ____________ _________ | | | | |C ||
+ | |F| |GAL16V8_| | ROM 3 | |MT4264-10 |_____| | | |N ||
+ | |U| |___________| _________ ______ | | | ||
+ | |S| _________ ____________ |MT4264-10 | | |__|<-ULN2903A
+ | |E| |74HC244AP | ROM 2 | _________ | | |__||
+ | |___________| |MT4264-10 | | ___ |
+ | ___ _________ ____________ _________ | | |CN||
+ | |F| |74HC244AP | ROM 1 | |MT4264-10 AY38910A/P |__||
+ | |U| |___________| _________ | | ___ |
+ | |S| _________ _________ _____ |MT4264-10 | | | ||
+ | |E| |74HC244AP |74HC245AP |XTAL 10.245MHz |_____| |C ||
+ | ________________ ________________ _____ |N ||
+ | _________ |Z8400A PS | |VIDEO | |DIPS |__||
+ | |_GD4011B| |_______________| |_______________| _________ |
+ | |CD40208E| |
+ |_______________________________________________________________________________|
*******************************************************************************/
diff --git a/src/mame/drivers/votrtnt.cpp b/src/mame/drivers/votrtnt.cpp
index 89de200b62d..74251ceb5dc 100644
--- a/src/mame/drivers/votrtnt.cpp
+++ b/src/mame/drivers/votrtnt.cpp
@@ -55,7 +55,7 @@ public:
private:
virtual void machine_reset() override;
- void _6802_mem(address_map &map);
+ void mem_map(address_map &map);
required_device<m6802_cpu_device> m_maincpu;
required_device<votrax_sc01_device> m_votrax;
@@ -81,13 +81,13 @@ private:
x 1 1 x * * * * * * * * * * * * R ROM (2332 4kx8 Mask ROM, inside potted brick)
*/
-void votrtnt_state::_6802_mem(address_map &map)
+void votrtnt_state::mem_map(address_map &map)
{
map.unmap_value_high();
map(0x0000, 0x03ff).mirror(0x9c00).ram(); /* RAM, 2114*2 (0x400 bytes) mirrored 4x */
map(0x2000, 0x2001).mirror(0x9ffe).rw("acia", FUNC(acia6850_device::read), FUNC(acia6850_device::write));
map(0x4000, 0x4000).mirror(0x9fff).w(m_votrax, FUNC(votrax_sc01_device::write));
- map(0x6000, 0x6fff).mirror(0x9000).rom(); /* ROM in potted block */
+ map(0x6000, 0x6fff).mirror(0x9000).rom().region("maincpu",0); /* ROM in potted block */
}
@@ -141,7 +141,7 @@ void votrtnt_state::votrtnt(machine_config &config)
/* basic machine hardware */
M6802(config, m_maincpu, 2.4576_MHz_XTAL); // 2.4576MHz XTAL, verified; divided by 4 inside the MC6802
m_maincpu->set_ram_enable(false);
- m_maincpu->set_addrmap(AS_PROGRAM, &votrtnt_state::_6802_mem);
+ m_maincpu->set_addrmap(AS_PROGRAM, &votrtnt_state::mem_map);
/* video hardware */
//config.set_default_layout(layout_votrtnt);
@@ -173,8 +173,8 @@ void votrtnt_state::votrtnt(machine_config &config)
******************************************************************************/
ROM_START(votrtnt)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("cn49752n.bin", 0x6000, 0x1000, CRC(a44e1af3) SHA1(af83b9e84f44c126b24ee754a22e34ca992a8d3d)) /* 2332 mask rom inside potted brick */
+ ROM_REGION(0x1000, "maincpu", 0)
+ ROM_LOAD("cn49752n.bin", 0x0000, 0x1000, CRC(a44e1af3) SHA1(af83b9e84f44c126b24ee754a22e34ca992a8d3d)) /* 2332 mask rom inside potted brick */
ROM_END
@@ -183,4 +183,4 @@ ROM_END
******************************************************************************/
// YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS
-COMP( 1980, votrtnt, 0, 0, votrtnt, votrtnt, votrtnt_state, empty_init, "Votrax", "Type 'N Talk", 0 )
+COMP( 1980, votrtnt, 0, 0, votrtnt, votrtnt, votrtnt_state, empty_init, "Votrax", "Type 'N Talk", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/vt1682.cpp b/src/mame/drivers/vt1682.cpp
index edcefb1d3a3..2edbf8008fd 100644
--- a/src/mame/drivers/vt1682.cpp
+++ b/src/mame/drivers/vt1682.cpp
@@ -685,6 +685,10 @@ public:
{ }
void vt1682_lxts3(machine_config& config);
+ void vt1682_unk1682(machine_config& config);
+
+ void unk1682_init();
+ void njp60in1_init();
protected:
uint8_t uio_porta_r();
@@ -5687,6 +5691,18 @@ static INPUT_PORTS_START( lxts3 )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT )
INPUT_PORTS_END
+static INPUT_PORTS_START( njp60in1 )
+ PORT_START("IN0")
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_BUTTON2 )
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_BUTTON1 )
+ PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START1 )
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON3 )
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT )
+ PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT )
+ PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN )
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP )
+INPUT_PORTS_END
+
static INPUT_PORTS_START( exsprt48 )
PORT_START("P1")
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1)
@@ -5964,6 +5980,26 @@ void vt1682_lxts3_state::vt1682_lxts3(machine_config& config)
m_uio->porta_in().set(FUNC(vt1682_lxts3_state::uio_porta_r));
}
+void vt1682_lxts3_state::vt1682_unk1682(machine_config& config)
+{
+ vt_vt1682_palbase(config);
+ vt_vt1682_common(config);
+
+ M6502(config.replace(), m_maincpu, MAIN_CPU_CLOCK_PAL); // no opcode bitswap
+ m_maincpu->set_addrmap(AS_PROGRAM, &vt1682_lxts3_state::vt_vt1682_map);
+
+ m_leftdac->reset_routes();
+ m_rightdac->reset_routes();
+
+ config.device_remove(":lspeaker");
+ config.device_remove(":rspeaker");
+
+ SPEAKER(config, "mono").front_center();
+ m_leftdac->add_route(0, "mono", 0.5);
+ m_rightdac->add_route(0, "mono", 0.5);
+
+ m_uio->porta_in().set(FUNC(vt1682_lxts3_state::uio_porta_r));
+}
void vt1682_wow_state::vt1682_wow(machine_config& config)
@@ -5996,8 +6032,28 @@ void intec_interact_state::banked_init()
}
+void vt1682_lxts3_state::unk1682_init()
+{
+ regular_init();
+ uint8_t* ROM = memregion("mainrom")->base();
+ // this jumps to a function on startup that has a bunch of jumps / accesses to the 3xxx region, which is internal ROM
+ // but bypassing it allows the unit to boot.
+ ROM[0x7ef43] = 0xea;
+ ROM[0x7ef44] = 0xea;
+ ROM[0x7ef45] = 0xea;
+}
+
+void vt1682_lxts3_state::njp60in1_init()
+{
+ regular_init();
+ uint8_t* ROM = memregion("mainrom")->base();
+ // first jsr in the code is for some port based security(?) check, might be SEEPROM
+ ROM[0x7ff44] = 0xea;
+ ROM[0x7ff45] = 0xea;
+ ROM[0x7ff46] = 0xea;
+}
// the VT1682 can have 0x1000 bytes of internal ROM, but none of the software dumped makes use of it.
@@ -6072,6 +6128,31 @@ ROM_START( wowwg )
ROM_RELOAD(0x1000000,0x1000000)
ROM_END
+ROM_START( unk1682 )
+ ROM_REGION( 0x1000, "internal", 0 )
+ // this appears to use the internal ROM on startup, so mark it as missing
+ ROM_LOAD( "101in1.internal.rom", 0x00000, 0x1000, NO_DUMP )
+
+ ROM_REGION( 0x2000000, "mainrom", 0 )
+ ROM_LOAD( "vt1682_101in1.bin", 0x00000, 0x0800000, CRC(82879200) SHA1(c1977d1733f8849326286102c0755629d0406ec4) )
+ ROM_CONTINUE(0x0800000, 0x0800000)
+ ROM_CONTINUE(0x1000000, 0x0800000)
+ ROM_CONTINUE(0x1800000, 0x0800000)
+
+ // also has a 24c02N SEEPROM, no accesses noted (maybe accessed from 'internal ROM' code?)
+ROM_END
+
+ROM_START( njp60in1 )
+ ROM_REGION( 0x2000000, "mainrom", 0 ) // the 6Mbyte - 7Mbyte region of the ROM is missing, causing Extreme Power Soccer to fail
+ ROM_LOAD( "60-in-1.bin", 0x00000, 0x0800000, CRC(7b2ee951) SHA1(fc7c214704908b85676efc64a21930483d24a457) )
+ ROM_CONTINUE(0x0800000, 0x0800000)
+ ROM_CONTINUE(0x1000000, 0x0800000)
+ ROM_CONTINUE(0x1800000, 0x0800000)
+
+ // also has a 24c02n SEEPROM, seems to access it on startup (security check?)
+ROM_END
+
+
ROM_START( 110dance )
ROM_REGION( 0x2000000, "mainrom", 0 )
ROM_LOAD( "110songdancemat.bin", 0x00000, 0x2000000, CRC(cd668e41) SHA1(975bfe05f4cce047860b05766bc8539218f6014f) )
@@ -6144,6 +6225,7 @@ This might be a regional / store thing if some places didn't want to sell a unit
// 'Riding Horse' on the other hand actually needs PAL timings, so this unit clearly was designed for PAL regions, however 'Explosion' was left broken.
CONS( 200?, wowwg, 0, 0, vt1682_wow, exsprt48, vt1682_wow_state, regular_init, "Wow", "Wow Wireless Gaming (PAL)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND) // needs high colour line mode for main menu
+
CONS( 200?, 110dance, 0, 0, vt1682_dance, 110dance, vt1682_dance_state, regular_init, "<unknown>", "Retro Dance Mat (110 song Super StepMania + 9-in-1 games) (PAL)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND)
// songs 5-8 are repeats of songs 1-4, but probably not a bug?
@@ -6152,4 +6234,14 @@ CONS( 200?, dance555, 0, 0, vt1682_exsportp, dance555, vt1682_exsport_state
// NJ Pocket 60-in-1 (NJ-250) is meant to have similar games to the mini-games found in wowwg and 110dance, so almost certainly fits here
+// manual explicitly states it has NTSC output only (unit can be connected to a TV) and both Ranning Horse + Explosion (Bomberman) are the NTSC versions
+// has 21.477 Mhz XTAL
+CONS( 200?, njp60in1, 0, 0, vt1682_lxts3, njp60in1, vt1682_lxts3_state, njp60in1_init, "<unknown>", "NJ Pocket 60-in-1 handheld 'X zero' (NTSC)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND) // needs high colour line mode for main menu
+
+// this appears to be related to the NJ Pocket, claims 101-in-1 but has some duplicates.
+// Like the 'Wow Wireless gaming' it incorrectly mixes the PAL version of 'Ranning Horse' with the NTSC version of 'Bomberman', it has no TV output.
+// has 26.6017 Mhz (6xPAL) XTAL
+CONS( 200?, unk1682, 0, 0, vt1682_unk1682, lxts3, vt1682_lxts3_state, unk1682_init, "<unknown>", "unknown VT1682 based 101-in-1 handheld (PAL)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND) // needs high colour line mode for main menu
+
CONS( 2010, lxts3, 0, 0, vt1682_lxts3, lxts3, vt1682_lxts3_state, regular_init, "Lexibook", "Toy Story 3 (Lexibook)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // random number generation issues on 2 games, linescroll on racing games
+
diff --git a/src/mame/drivers/williams.cpp b/src/mame/drivers/williams.cpp
index cfcc015bddd..c2e4cbfd6b4 100644
--- a/src/mame/drivers/williams.cpp
+++ b/src/mame/drivers/williams.cpp
@@ -2657,82 +2657,130 @@ ROM_START( splat )
ROM_END
-ROM_START( sinistar )
- ROM_REGION( 0x19000, "maincpu", 0 )
- ROM_LOAD( "sinistar.10", 0x0e000, 0x1000, CRC(3d670417) SHA1(81802622bee8dbea5c0f08019d87d941dcdbe292) )
- ROM_LOAD( "sinistar.11", 0x0f000, 0x1000, CRC(3162bc50) SHA1(2f38e572ab9c731e38dfe9bad3cc8222a775c5ea) )
- ROM_LOAD( "sinistar.01", 0x10000, 0x1000, CRC(f6f3a22c) SHA1(026d8cab07734fa294a5645edbe65a904bcbc302) )
- ROM_LOAD( "sinistar.02", 0x11000, 0x1000, CRC(cab3185c) SHA1(423d1e3b0c07333ec582529bc4d0b7baf591820a) )
- ROM_LOAD( "sinistar.03", 0x12000, 0x1000, CRC(1ce1b3cc) SHA1(5bc03d7249529d827dc60c087e074ab3e4ea7361) )
- ROM_LOAD( "sinistar.04", 0x13000, 0x1000, CRC(6da632ba) SHA1(72c0c3d5a5ca87ca4d95fcedaf834206e4633950) )
- ROM_LOAD( "sinistar.05", 0x14000, 0x1000, CRC(b662e8fc) SHA1(828a89d2ea13d8a362dae708f86bff54cb231887) )
- ROM_LOAD( "sinistar.06", 0x15000, 0x1000, CRC(2306183d) SHA1(703e29e6446856615760a4897c0f5d79cc7bdfb2) )
- ROM_LOAD( "sinistar.07", 0x16000, 0x1000, CRC(e5dd918e) SHA1(bf4e2ada6a59d246218544d822ba5355da925924) )
- ROM_LOAD( "sinistar.08", 0x17000, 0x1000, CRC(4785a787) SHA1(8c7eca656b2c23b0da41a8c7ce51a2735cab85a4) )
- ROM_LOAD( "sinistar.09", 0x18000, 0x1000, CRC(50cb63ad) SHA1(96e28e4fef98fff2649741a266fa590e0313e3b0) )
+/*
+Sinistar
+
+Multiple different ROM boards are known to exist:
+
+Rev.3:
+ ROM board known to come with final production rev. 2 labels with corresponding part numbers and two rev. 3
+ upgrade ROMs: white labels and orange stripe:
+
+ SINISTAR SINISTAR
+ ROM 8-B and ROM 11-B
+ REV. 3 REV. 3
+
+ ROM board known to come with all rev. 2 upgrade ROMs (as described below): white labels and red stripe plus the
+ two rev. 3 upgrade ROMs as described above
+
+Rev.2:
+ Earlier ROM boards known to have all upgrade styled labels, white with red stripe, in the format:
+
+ SINISTAR
+ ROM 1-B
+ REV. 2
+
+Although not currently dumped, "true" rev.1 Sinistar ROMs are believed to be numbered 16-3004-23 through 16-3004-33,
+ with speech ROMs 16-3004-34 through 16-3004-37 (labels believed to be solid brown)
+There is known to be a "perfect" version of Sinistar, that being the original version presented to Williams by the
+ dev team. The dev team thought this version had the best game play while Williams decided it was too easy (IE: it
+ could be played too long on one quarter)
+
+*/
+ROM_START( sinistar ) // rev. 3
+ ROM_REGION( 0x19000, "maincpu", 0 ) // solid RED labels with final production part numbers
+ ROM_LOAD( "sinistar_rom_10-b_16-3004-62.4c", 0x0e000, 0x1000, CRC(3d670417) SHA1(81802622bee8dbea5c0f08019d87d941dcdbe292) )
+ ROM_LOAD( "sinistar_rom_11-b_16-3004-64.4a", 0x0f000, 0x1000, CRC(3162bc50) SHA1(2f38e572ab9c731e38dfe9bad3cc8222a775c5ea) )
+ ROM_LOAD( "sinistar_rom_1-b_16-3004-53.1d", 0x10000, 0x1000, CRC(f6f3a22c) SHA1(026d8cab07734fa294a5645edbe65a904bcbc302) )
+ ROM_LOAD( "sinistar_rom_2-b_16-3004-54.1c", 0x11000, 0x1000, CRC(cab3185c) SHA1(423d1e3b0c07333ec582529bc4d0b7baf591820a) )
+ ROM_LOAD( "sinistar_rom_3-b_16-3004-55.1a", 0x12000, 0x1000, CRC(1ce1b3cc) SHA1(5bc03d7249529d827dc60c087e074ab3e4ea7361) )
+ ROM_LOAD( "sinistar_rom_4-b_16-3004-56.2d", 0x13000, 0x1000, CRC(6da632ba) SHA1(72c0c3d5a5ca87ca4d95fcedaf834206e4633950) )
+ ROM_LOAD( "sinistar_rom_5-b_16-3004-57.2c", 0x14000, 0x1000, CRC(b662e8fc) SHA1(828a89d2ea13d8a362dae708f86bff54cb231887) )
+ ROM_LOAD( "sinistar_rom_6-b_16-3004-58.2a", 0x15000, 0x1000, CRC(2306183d) SHA1(703e29e6446856615760a4897c0f5d79cc7bdfb2) )
+ ROM_LOAD( "sinistar_rom_7-b_16-3004-59.3d", 0x16000, 0x1000, CRC(e5dd918e) SHA1(bf4e2ada6a59d246218544d822ba5355da925924) )
+ ROM_LOAD( "sinistar_rom_8-b_16-3004-60.3c", 0x17000, 0x1000, CRC(4785a787) SHA1(8c7eca656b2c23b0da41a8c7ce51a2735cab85a4) )
+ ROM_LOAD( "sinistar_rom_9-b_16-3004-61.3a", 0x18000, 0x1000, CRC(50cb63ad) SHA1(96e28e4fef98fff2649741a266fa590e0313e3b0) )
ROM_REGION( 0x10000, "soundcpu", 0 )
- ROM_LOAD( "speech.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
- ROM_LOAD( "speech.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
- ROM_LOAD( "speech.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
- ROM_LOAD( "speech.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
- ROM_LOAD( "sinistar.snd", 0xf000, 0x1000, CRC(b82f4ddb) SHA1(c70c7dd6e88897920d7709a260f27810f66aade1) )
+ ROM_LOAD( "3004_speech_ic7_r1_16-3004-52.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
+ ROM_LOAD( "3004_speech_ic5_r1_16-3004-50.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
+ ROM_LOAD( "3004_speech_ic6_r1_16-3004-51.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
+ ROM_LOAD( "3004_speech_ic4_r1_16-3004-49.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
+ ROM_LOAD( "video_sound_rom_9_std.808", 0xf000, 0x1000, CRC(b82f4ddb) SHA1(c70c7dd6e88897920d7709a260f27810f66aade1) )
+
+/*
+ ROM_REGION( 0x10000, "soundcpu_b", 0 ) // Stereo sound requires 2nd sound board as used in the cockpit version
+ ROM_LOAD( "3004_speech_ic7_r1_16-3004-52.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
+ ROM_LOAD( "3004_speech_ic5_r1_16-3004-50.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
+ ROM_LOAD( "3004_speech_ic6_r1_16-3004-51.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
+ ROM_LOAD( "3004_speech_ic4_r1_16-3004-49.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
+ ROM_LOAD( "sinistar_stereo_18-a.ic12", 0xf000, 0x1000, CRC(b5c70082) SHA1(643af087b57da3a71c68372c79c5777e0c1fbef7) ) // not sure if all speech ROMs need to be here too
+*/
ROM_REGION( 0x0400, "proms", 0 )
- ROM_LOAD( "decoder.4", 0x0000, 0x0200, CRC(e6631c23) SHA1(9988723269367fb44ef83f627186a1c88cf7877e) )
- ROM_LOAD( "decoder.6", 0x0200, 0x0200, CRC(83faf25e) SHA1(30002643d08ed983a6701a7c4b5ee74a2f4a1adb) )
+ ROM_LOAD( "a-5342-09694.3c", 0x0000, 0x0200, CRC(e6631c23) SHA1(9988723269367fb44ef83f627186a1c88cf7877e) ) // Decoder ROM 4 - Horizontal - 7641-5 BPROM
+ ROM_LOAD( "a-5342-09821.3g", 0x0200, 0x0200, CRC(83faf25e) SHA1(30002643d08ed983a6701a7c4b5ee74a2f4a1adb) ) // Decoder ROM 6 - Vertical - 7641-5 BPROM
ROM_END
-ROM_START( sinistar1 )
- ROM_REGION( 0x19000, "maincpu", 0 )
- ROM_LOAD( "sinrev1.10", 0x0e000, 0x1000, CRC(ea87a53f) SHA1(4e4bad5315a8f5740c926ee5681879919a5be37f) )
- ROM_LOAD( "sinrev1.11", 0x0f000, 0x1000, CRC(88d36e80) SHA1(bb9adaf5b73f9874e52dc2f5fd35e22f8b4fc258) )
- ROM_LOAD( "sinrev1.01", 0x10000, 0x1000, CRC(3810d7b8) SHA1(dcd690cbc958a2f97f022765315d77fb7c7d8e8b) )
- ROM_LOAD( "sinistar.02", 0x11000, 0x1000, CRC(cab3185c) SHA1(423d1e3b0c07333ec582529bc4d0b7baf591820a) )
- ROM_LOAD( "sinrev1.03", 0x12000, 0x1000, CRC(7c984ca9) SHA1(b32b7d15194051db5d29acf95b049e2eccf6d393) )
- ROM_LOAD( "sinrev1.04", 0x13000, 0x1000, CRC(cc6c4f24) SHA1(b4375544e02a19458c6fcc85edb31025c0b8eb71) )
- ROM_LOAD( "sinrev1.05", 0x14000, 0x1000, CRC(12285bfe) SHA1(6d433103332ddda2f2af23febc0b15aa93db1f31) )
- ROM_LOAD( "sinrev1.06", 0x15000, 0x1000, CRC(7a675f35) SHA1(3a7e9fdb2aef52dc29d33799694737038802b6e0) )
- ROM_LOAD( "sinrev1.07", 0x16000, 0x1000, CRC(b0463243) SHA1(95d597856a1942bd176f5f62db0d691f8f2f2932) )
- ROM_LOAD( "sinrev1.08", 0x17000, 0x1000, CRC(909040d4) SHA1(5361cc378bdace0799227e901341747dce9bb029) )
- ROM_LOAD( "sinrev1.09", 0x18000, 0x1000, CRC(cc949810) SHA1(2d2d1cccd7e43b63e424c34ab5215a412e2b9809) )
+ROM_START( sinistar2 ) // rev. 2
+ ROM_REGION( 0x19000, "maincpu", 0 ) // solid RED labels with final production part numbers
+ ROM_LOAD( "sinistar_rom_10-b_16-3004-47.4c", 0x0e000, 0x1000, CRC(3d670417) SHA1(81802622bee8dbea5c0f08019d87d941dcdbe292) ) // == rev. 3 PN 16-3004-62
+ ROM_LOAD( "sinistar_rom_11-b_16-3004-48.4a", 0x0f000, 0x1000, CRC(792c8b00) SHA1(1f847ca8a67595927c36d69cead02813c2431c7b) ) // unique to rev. 2
+ ROM_LOAD( "sinistar_rom_1-b_16-3004-38.1d", 0x10000, 0x1000, CRC(f6f3a22c) SHA1(026d8cab07734fa294a5645edbe65a904bcbc302) ) // == rev. 3 PN 16-3004-53
+ ROM_LOAD( "sinistar_rom_2-b_16-3004-39.1c", 0x11000, 0x1000, CRC(cab3185c) SHA1(423d1e3b0c07333ec582529bc4d0b7baf591820a) ) // == rev. 3 PN 16-3004-54
+ ROM_LOAD( "sinistar_rom_3-b_16-3004-40.1a", 0x12000, 0x1000, CRC(1ce1b3cc) SHA1(5bc03d7249529d827dc60c087e074ab3e4ea7361) ) // == rev. 3 PN 16-3004-55
+ ROM_LOAD( "sinistar_rom_4-b_16-3004-41.2d", 0x13000, 0x1000, CRC(6da632ba) SHA1(72c0c3d5a5ca87ca4d95fcedaf834206e4633950) ) // == rev. 3 PN 16-3004-56
+ ROM_LOAD( "sinistar_rom_5-b_16-3004-42.2c", 0x14000, 0x1000, CRC(b662e8fc) SHA1(828a89d2ea13d8a362dae708f86bff54cb231887) ) // == rev. 3 PN 16-3004-57
+ ROM_LOAD( "sinistar_rom_6-b_16-3004-43.2a", 0x15000, 0x1000, CRC(2306183d) SHA1(703e29e6446856615760a4897c0f5d79cc7bdfb2) ) // == rev. 3 PN 16-3004-57
+ ROM_LOAD( "sinistar_rom_7-b_16-3004-44.3d", 0x16000, 0x1000, CRC(e5dd918e) SHA1(bf4e2ada6a59d246218544d822ba5355da925924) ) // == rev. 3 PN 16-3004-59
+ ROM_LOAD( "sinistar_rom_8-b_16-3004-45.3c", 0x17000, 0x1000, CRC(d7ecee45) SHA1(f9552035409bce0a36ed93a677b28f8cd361f8f1) ) // unique to rev. 2
+ ROM_LOAD( "sinistar_rom_9-b_16-3004-46.3a", 0x18000, 0x1000, CRC(50cb63ad) SHA1(96e28e4fef98fff2649741a266fa590e0313e3b0) ) // == rev. 3 PN 16-3004-61
ROM_REGION( 0x10000, "soundcpu", 0 )
- ROM_LOAD( "speech.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
- ROM_LOAD( "speech.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
- ROM_LOAD( "speech.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
- ROM_LOAD( "speech.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
- ROM_LOAD( "sinistar.snd", 0xf000, 0x1000, CRC(b82f4ddb) SHA1(c70c7dd6e88897920d7709a260f27810f66aade1) )
+ ROM_LOAD( "3004_speech_ic7_r1_16-3004-52.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
+ ROM_LOAD( "3004_speech_ic5_r1_16-3004-50.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
+ ROM_LOAD( "3004_speech_ic6_r1_16-3004-51.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
+ ROM_LOAD( "3004_speech_ic4_r1_16-3004-49.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
+ ROM_LOAD( "video_sound_rom_9_std.808", 0xf000, 0x1000, CRC(b82f4ddb) SHA1(c70c7dd6e88897920d7709a260f27810f66aade1) )
+
+/*
+ ROM_REGION( 0x10000, "soundcpu_b", 0 ) // Stereo sound requires 2nd sound board as used in the cockpit version
+ ROM_LOAD( "3004_speech_ic7_r1_16-3004-52.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
+ ROM_LOAD( "3004_speech_ic5_r1_16-3004-50.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
+ ROM_LOAD( "3004_speech_ic6_r1_16-3004-51.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
+ ROM_LOAD( "3004_speech_ic4_r1_16-3004-49.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
+ ROM_LOAD( "sinistar_stereo_18-a.ic12", 0xf000, 0x1000, CRC(b5c70082) SHA1(643af087b57da3a71c68372c79c5777e0c1fbef7) ) // not sure if all speech ROMs need to be here too
+*/
ROM_REGION( 0x0400, "proms", 0 )
- ROM_LOAD( "decoder.4", 0x0000, 0x0200, CRC(e6631c23) SHA1(9988723269367fb44ef83f627186a1c88cf7877e) )
- ROM_LOAD( "decoder.6", 0x0200, 0x0200, CRC(83faf25e) SHA1(30002643d08ed983a6701a7c4b5ee74a2f4a1adb) )
+ ROM_LOAD( "a-5342-09694.3c", 0x0000, 0x0200, CRC(e6631c23) SHA1(9988723269367fb44ef83f627186a1c88cf7877e) ) // Decoder ROM 4 - Horizontal - 7641-5 BPROM
+ ROM_LOAD( "a-5342-09821.3g", 0x0200, 0x0200, CRC(83faf25e) SHA1(30002643d08ed983a6701a7c4b5ee74a2f4a1adb) ) // Decoder ROM 6 - Vertical - 7641-5 BPROM
ROM_END
-ROM_START( sinistar2 )
+ROM_START( sinistarp ) // solid pink labels - 1982 AMOA prototype
ROM_REGION( 0x19000, "maincpu", 0 )
- ROM_LOAD( "sinistar.10", 0x0e000, 0x1000, CRC(3d670417) SHA1(81802622bee8dbea5c0f08019d87d941dcdbe292) )
- ROM_LOAD( "sinrev2.11", 0x0f000, 0x1000, CRC(792c8b00) SHA1(1f847ca8a67595927c36d69cead02813c2431c7b) )
- ROM_LOAD( "sinistar.01", 0x10000, 0x1000, CRC(f6f3a22c) SHA1(026d8cab07734fa294a5645edbe65a904bcbc302) )
- ROM_LOAD( "sinistar.02", 0x11000, 0x1000, CRC(cab3185c) SHA1(423d1e3b0c07333ec582529bc4d0b7baf591820a) )
- ROM_LOAD( "sinistar.03", 0x12000, 0x1000, CRC(1ce1b3cc) SHA1(5bc03d7249529d827dc60c087e074ab3e4ea7361) )
- ROM_LOAD( "sinistar.04", 0x13000, 0x1000, CRC(6da632ba) SHA1(72c0c3d5a5ca87ca4d95fcedaf834206e4633950) )
- ROM_LOAD( "sinistar.05", 0x14000, 0x1000, CRC(b662e8fc) SHA1(828a89d2ea13d8a362dae708f86bff54cb231887) )
- ROM_LOAD( "sinistar.06", 0x15000, 0x1000, CRC(2306183d) SHA1(703e29e6446856615760a4897c0f5d79cc7bdfb2) )
- ROM_LOAD( "sinistar.07", 0x16000, 0x1000, CRC(e5dd918e) SHA1(bf4e2ada6a59d246218544d822ba5355da925924) )
- ROM_LOAD( "sinrev2.08", 0x17000, 0x1000, CRC(d7ecee45) SHA1(f9552035409bce0a36ed93a677b28f8cd361f8f1) )
- ROM_LOAD( "sinistar.09", 0x18000, 0x1000, CRC(50cb63ad) SHA1(96e28e4fef98fff2649741a266fa590e0313e3b0) )
+ ROM_LOAD( "sinistar_rom_10-b_16-3004-21.4c", 0x0e000, 0x1000, CRC(ea87a53f) SHA1(4e4bad5315a8f5740c926ee5681879919a5be37f) )
+ ROM_LOAD( "sinistar_rom_11-b_16-3004-22.4a", 0x0f000, 0x1000, CRC(88d36e80) SHA1(bb9adaf5b73f9874e52dc2f5fd35e22f8b4fc258) )
+ ROM_LOAD( "sinistar_rom_1-b_16-3004-12.1d", 0x10000, 0x1000, CRC(3810d7b8) SHA1(dcd690cbc958a2f97f022765315d77fb7c7d8e8b) )
+ ROM_LOAD( "sinistar_rom_2-b_16-3004-13.1c", 0x11000, 0x1000, CRC(cab3185c) SHA1(423d1e3b0c07333ec582529bc4d0b7baf591820a) ) // only this one ROM remains the same through to rev. 3
+ ROM_LOAD( "sinistar_rom_3-b_16-3004-14.1a", 0x12000, 0x1000, CRC(7c984ca9) SHA1(b32b7d15194051db5d29acf95b049e2eccf6d393) )
+ ROM_LOAD( "sinistar_rom_4-b_16-3004-15.2d", 0x13000, 0x1000, CRC(cc6c4f24) SHA1(b4375544e02a19458c6fcc85edb31025c0b8eb71) )
+ ROM_LOAD( "sinistar_rom_5-b_16-3004-16.2c", 0x14000, 0x1000, CRC(12285bfe) SHA1(6d433103332ddda2f2af23febc0b15aa93db1f31) )
+ ROM_LOAD( "sinistar_rom_6-b_16-3004-17.2a", 0x15000, 0x1000, CRC(7a675f35) SHA1(3a7e9fdb2aef52dc29d33799694737038802b6e0) )
+ ROM_LOAD( "sinistar_rom_7-b_16-3004-18.3d", 0x16000, 0x1000, CRC(b0463243) SHA1(95d597856a1942bd176f5f62db0d691f8f2f2932) )
+ ROM_LOAD( "sinistar_rom_8-b_16-3004-19.3c", 0x17000, 0x1000, CRC(909040d4) SHA1(5361cc378bdace0799227e901341747dce9bb029) )
+ ROM_LOAD( "sinistar_rom_9-b_16-3004-20.3a", 0x18000, 0x1000, CRC(cc949810) SHA1(2d2d1cccd7e43b63e424c34ab5215a412e2b9809) )
ROM_REGION( 0x10000, "soundcpu", 0 )
- ROM_LOAD( "speech.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) )
- ROM_LOAD( "speech.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
- ROM_LOAD( "speech.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
- ROM_LOAD( "speech.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
- ROM_LOAD( "sinistar.snd", 0xf000, 0x1000, CRC(b82f4ddb) SHA1(c70c7dd6e88897920d7709a260f27810f66aade1) )
+ ROM_LOAD( "3004_speech_ic7_r1.ic7", 0xb000, 0x1000, CRC(e1019568) SHA1(442f4f3ccd2e1db2136d2ffb121ea442921f87ca) ) // same data as later sets, but no official part number assigned yet
+ ROM_LOAD( "3004_speech_ic5_r1.ic5", 0xc000, 0x1000, CRC(cf3b5ffd) SHA1(d5d51c550581c9d46ab331dd4fd32541a2ef598e) )
+ ROM_LOAD( "3004_speech_ic6_r1.ic6", 0xd000, 0x1000, CRC(ff8d2645) SHA1(16fa2a602acbbc182dd96bab113ab18356f3daf0) )
+ ROM_LOAD( "3004_speech_ic4_r1.ic4", 0xe000, 0x1000, CRC(4b56a626) SHA1(44430cd5c110ec751b0bfb8ae99b26d443350db1) )
+ ROM_LOAD( "video_sound_rom_9_std.808", 0xf000, 0x1000, CRC(b82f4ddb) SHA1(c70c7dd6e88897920d7709a260f27810f66aade1) )
ROM_REGION( 0x0400, "proms", 0 )
- ROM_LOAD( "decoder.4", 0x0000, 0x0200, CRC(e6631c23) SHA1(9988723269367fb44ef83f627186a1c88cf7877e) )
- ROM_LOAD( "decoder.6", 0x0200, 0x0200, CRC(83faf25e) SHA1(30002643d08ed983a6701a7c4b5ee74a2f4a1adb) )
+ ROM_LOAD( "a-5342-09694.3c", 0x0000, 0x0200, CRC(e6631c23) SHA1(9988723269367fb44ef83f627186a1c88cf7877e) ) // Decoder ROM 4 - Horizontal - 7641-5 BPROM
+ ROM_LOAD( "a-5342-09821.3g", 0x0200, 0x0200, CRC(83faf25e) SHA1(30002643d08ed983a6701a7c4b5ee74a2f4a1adb) ) // Decoder ROM 6 - Vertical - 7641-5 BPROM
ROM_END
@@ -3427,8 +3475,8 @@ GAME( 1982, bubblesp, bubbles, bubbles, bubbles, bubbles_state,
GAME( 1982, splat, 0, williams_muxed, splat, williams_muxed_state, init_splat, ROT0, "Williams", "Splat!", MACHINE_SUPPORTS_SAVE )
GAME( 1982, sinistar, 0, sinistar, sinistar, sinistar_state, empty_init, ROT270, "Williams", "Sinistar (revision 3)", MACHINE_SUPPORTS_SAVE )
-GAME( 1982, sinistar1, sinistar, sinistar, sinistar, sinistar_state, empty_init, ROT270, "Williams", "Sinistar (prototype version)", MACHINE_SUPPORTS_SAVE )
GAME( 1982, sinistar2, sinistar, sinistar, sinistar, sinistar_state, empty_init, ROT270, "Williams", "Sinistar (revision 2)", MACHINE_SUPPORTS_SAVE )
+GAME( 1982, sinistarp, sinistar, sinistar, sinistar, sinistar_state, empty_init, ROT270, "Williams", "Sinistar (AMOA-82 prototype)", MACHINE_SUPPORTS_SAVE )
GAME( 1983, playball, 0, playball, playball, playball_state, empty_init, ROT270, "Williams", "PlayBall! (prototype)", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/xavix.cpp b/src/mame/drivers/xavix.cpp
index 0215cf6e5c8..64174166145 100644
--- a/src/mame/drivers/xavix.cpp
+++ b/src/mame/drivers/xavix.cpp
@@ -233,10 +233,6 @@
#include "emu.h"
#include "includes/xavix.h"
-// NTSC clock for regular XaviX?
-#define MAIN_CLOCK XTAL(21'477'272)
-// some games (eg Radica Opus) run off a 3.579545MHz XTAL ( same as the above /6 ) so presumably there is a divider / multiplier circuit on some PCBs?
-// TODO: what's the PAL clock?
/* rad_madf has callf #$8f3f21 in various places, and expects to jump to code in ROM, it is unclear how things map in this case, as presumably
the CPU 0 page memory and stack are still at 0 but ROM must be in the 3xxx range (game hasn't got far enough to call this yet to help either)
@@ -547,22 +543,7 @@ static INPUT_PORTS_START( xavix_i2c )
INPUT_PORTS_END
-static INPUT_PORTS_START( epo_tfit )
- PORT_INCLUDE(xavix)
- PORT_MODIFY("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // select
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // back
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 )
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 )
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT )
- PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
-
- PORT_MODIFY("IN1")
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
-INPUT_PORTS_END
static INPUT_PORTS_START( tomcpin )
@@ -582,176 +563,6 @@ static INPUT_PORTS_START( tomcpin )
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_POWER_OFF ) PORT_NAME("Power Switch") // pressing this will turn the game off.
INPUT_PORTS_END
-static INPUT_PORTS_START( mrangbat )
- PORT_INCLUDE(xavix_i2c)
-
- PORT_MODIFY("IN0")
- PORT_DIPNAME( 0x01, 0x00, "IN0" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x02, DEF_STR( On ) )
- PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x04, DEF_STR( On ) )
- PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x08, DEF_STR( On ) )
- PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x10, DEF_STR( On ) )
- PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x20, DEF_STR( On ) )
- PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x40, DEF_STR( On ) )
- PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x80, DEF_STR( On ) )
-
- PORT_MODIFY("IN1")
- PORT_DIPNAME( 0x01, 0x00, "IN1" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x02, DEF_STR( On ) )
- PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x04, DEF_STR( On ) )
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
- PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x10, DEF_STR( On ) )
- PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x20, DEF_STR( On ) )
- PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x40, DEF_STR( On ) )
- PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x80, DEF_STR( On ) )
-
- PORT_START("EX0") // NOT A JOYSTICK!!
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1) PORT_16WAY // Red/Up 1
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(2) PORT_16WAY // Red/Up 2
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(2) PORT_16WAY // Green / Circle / Right 2
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(2) PORT_16WAY // Pink / Star / Left 2
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) PORT_16WAY // Blue / Square / Right 1
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) PORT_16WAY // Yellow / Triangle / Left 1
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 )
- PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 )
-
-
- PORT_START("EX1")
- PORT_DIPNAME( 0x01, 0x00, "EX1" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x02, DEF_STR( On ) )
- PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x04, DEF_STR( On ) )
- PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x08, DEF_STR( On ) )
- PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x10, DEF_STR( On ) )
- PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x20, DEF_STR( On ) )
- PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x40, DEF_STR( On ) )
- PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x80, DEF_STR( On ) )
-
- PORT_START("EX2")
- PORT_DIPNAME( 0x01, 0x00, "EX2" )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x01, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x02, DEF_STR( On ) )
- PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x04, DEF_STR( On ) )
- PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x08, DEF_STR( On ) )
- PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x10, DEF_STR( On ) )
- PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x20, DEF_STR( On ) )
- PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x40, DEF_STR( On ) )
- PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x80, DEF_STR( On ) )
-INPUT_PORTS_END
-
-static INPUT_PORTS_START( epo_bowl )
- PORT_INCLUDE(xavix)
-
- PORT_MODIFY("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1)
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_PLAYER(1)
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1)
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1)
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1)
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1)
-
- PORT_MODIFY("IN1")
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
-INPUT_PORTS_END
-
-
-static INPUT_PORTS_START( ttv_lotr )
- PORT_INCLUDE(xavix)
-
- PORT_MODIFY("IN1")
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r)
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r)
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
-INPUT_PORTS_END
-
-static INPUT_PORTS_START( xavix_bowl )
- PORT_INCLUDE(xavix)
-
- PORT_MODIFY("IN1")
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r)
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r)
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
-INPUT_PORTS_END
-
-static INPUT_PORTS_START( epo_sdb )
- PORT_INCLUDE(xavix)
-
- PORT_MODIFY("MOUSE0X")
- PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(1)
- PORT_MODIFY("MOUSE0Y")
- PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(1)
- PORT_MODIFY("MOUSE1X")
- PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(2)
- PORT_MODIFY("MOUSE1Y")
- PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(2)
-
- PORT_MODIFY("IN0")
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(2)
-
- PORT_MODIFY("IN1")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1)
-INPUT_PORTS_END
-
static INPUT_PORTS_START( ltv_tam )
PORT_INCLUDE(xavix_i2c)
@@ -819,14 +630,6 @@ INPUT_PORTS_END
-static INPUT_PORTS_START( xavixp )
- PORT_INCLUDE(xavix)
-
- PORT_MODIFY("REGION") // PAL/NTSC flag
- PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_CUSTOM )
-INPUT_PORTS_END
-
-
/* Test mode lists the following
LED (on power button?)
@@ -1208,19 +1011,6 @@ static INPUT_PORTS_START( rad_bb2 )
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_POWER_OFF ) PORT_NAME("Power Switch") // pressing this will turn the game off.
INPUT_PORTS_END
-static INPUT_PORTS_START( ttv_mx )
- PORT_INCLUDE(xavix_i2c)
-
- PORT_MODIFY("IN0")
- PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // Accel
- PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // Brake
- PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Pause")
- PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED )
- PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Motion Up") // you tilt the device, but actual inputs are digital
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Motion Down")
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("Motion Left")
- PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("Motion Right")
-INPUT_PORTS_END
static INPUT_PORTS_START( rad_fb )
@@ -1613,81 +1403,7 @@ void xavix_state::xavixp_nv(machine_config &config)
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1);
}
-void xavix_state::xavix2000(machine_config &config)
-{
- xavix(config);
-
- XAVIX2000(config.replace(), m_maincpu, MAIN_CLOCK);
- m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map);
- m_maincpu->set_addrmap(5, &xavix_state::xavix_lowbus_map);
- m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map);
- m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt));
- m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors));
-
- m_palette->set_entries(512);
-}
-
-void xavix_state::xavix2002(machine_config &config)
-{
- xavix(config);
- XAVIX2002(config.replace(), m_maincpu, MAIN_CLOCK);
- m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map);
- m_maincpu->set_addrmap(5, &xavix_state::superxavix_lowbus_map); // has extra video, io etc.
- m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map);
- m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt));
- m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors));
-
- m_palette->set_entries(512);
-
- XAVIX2002IO(config, m_xavix2002io, 0);
-}
-
-
-
-void xavix_i2c_jmat_state::xavix2002_i2c_jmat(machine_config &config)
-{
- xavix2002_i2c_24c04(config);
-
- m_xavix2002io->read_0_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io0));
- m_xavix2002io->write_0_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io0));
- m_xavix2002io->read_1_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io1));
- m_xavix2002io->write_1_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io1));
- m_xavix2002io->read_2_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io2));
- m_xavix2002io->write_2_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io2));
-}
-
-
-void xavix_state::xavix2000_nv(machine_config &config)
-{
- xavix2000(config);
-
- NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1);
-}
-
-void xavix_2000_nv_sdb_state::xavix2000_nv_sdb(machine_config &config)
-{
- xavix2000_nv(config);
-
- m_anport->read_0_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport0_r));
- m_anport->read_1_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport1_r));
- m_anport->read_2_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport2_r));
- m_anport->read_3_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport3_r));
-}
-
-void xavix_i2c_state::xavix2000_i2c_24c04(machine_config &config)
-{
- xavix2000(config);
-
- I2C_24C04(config, "i2cmem", 0);
-}
-
-void xavix_i2c_state::xavix2000_i2c_24c02(machine_config &config)
-{
- xavix2000(config);
-
- I2C_24C02(config, "i2cmem", 0);
-}
void xavix_mtrk_state::xavix_mtrk(machine_config &config)
{
@@ -1843,28 +1559,6 @@ void xavix_cart_state::xavix_cart_ddrfammt(machine_config &config)
}
-void xavix_i2c_state::xavix2002_i2c_24c04(machine_config &config)
-{
- xavix2002(config);
-
- I2C_24C04(config, "i2cmem", 0);
-}
-
-void xavix_i2c_state::xavix2002_i2c_mrangbat(machine_config &config)
-{
- xavix2002(config);
-
- I2C_24C02(config, "i2cmem", 0); // 24C02?
-
- m_xavix2002io->read_0_callback().set_ioport("EX0");
- //m_xavix2002io->write_0_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io0));
- m_xavix2002io->read_1_callback().set_ioport("EX1");
- //m_xavix2002io->write_1_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io1));
- m_xavix2002io->read_2_callback().set_ioport("EX2");
- //m_xavix2002io->write_2_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io2));
-
-}
-
void xavix_state::init_xavix()
{
@@ -2020,11 +1714,6 @@ ROM_START( epo_efdx )
ROM_LOAD("excitefishing.bin", 0x000000, 0x400000, CRC(9c85b261) SHA1(6a363faed2ec89c5176e46554a98ca1e20132579) )
ROM_END
-ROM_START( epo_bowl )
- ROM_REGION(0x200000, "bios", ROMREGION_ERASE00)
- ROM_LOAD("bowling.bin", 0x000000, 0x200000, CRC(d34f8d9e) SHA1(ebe3792172dc43904b9226beb27f1da89d2388cc) )
-ROM_END
-
ROM_START( epo_esdx )
ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
ROM_LOAD("baseballdx.bin", 0x000000, 0x400000, CRC(fe2e832e) SHA1(e6343f5e5f52316538d918d0d67c15764aa40f65) )
@@ -2279,7 +1968,7 @@ CONS( 2002, epo_esdx, 0, 0, xavix, epo_epp, xavix_state,
CONS( 2000, epo_epp, 0, 0, xavix, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Ping Pong (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
CONS( 2000, epo_eppk, epo_epp, 0, xavix, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD / Sonokong", "Real Ping Pong (Korea)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-// Excite Ping Pong 2 is from 2003, and there's a 3rd game from 2006 also
+// Excite Ping Pong 2 is from 2003
CONS( 2006, epo_epp3, 0, 0, xavix, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Challenge Ai-chan! Excite Ping Pong (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
@@ -2336,226 +2025,5 @@ CONS( 2003, evio, 0, 0, xavix_cart_evio, evio, xavix_cart_st
CONS( 2002, gcslottv, 0, 0, xavix_cart_gcslottv, gcslottv, xavix_cart_gcslottv_state, init_xavix, "Takara / Sammy / DCT / SSD Company LTD", "Gachinko Contest! Slot machine TV (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND /*|MACHINE_IS_BIOS_ROOT*/ )
-
-
// Let’s!TVプレイ 超にんきスポット!ころがしほーだい たまごっちりぞーと (Let's! TV Play Chou Ninki Spot! Korogashi-Houdai Tamagotchi Resort) (only on the Japanese list? http://test.shinsedai.co.jp/english/products/Applied/list.html ) This also allows you to use an IR reciever to import a Tamagotchi from compatible games
CONS( 2006, ltv_tam, 0, 0, xavix_i2c_24lc04_tam, ltv_tam,xavix_i2c_ltv_tam_state, init_xavix, "Bandai / SSD Company LTD", "Let's! TV Play Chou Ninki Spot! Korogashi-Houdai Tamagotchi Resort (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-
-
-/* SuperXaviX(?) (XaviX 2000 type CPU) hardware titles (2nd XaviX generation?)
-
- these use the SSD 2000 NEC 85605-621 type CPU
-
- XavixPort Golf is "SSD 2003 SuperXaviX MXIC 2003 3009" (not dumped yet, but actually marked as SuperXaviX unlike the others!)
-
- This CPU type adds extra opcodes that don't appear to be present in the 97/98 types
- It does not appear to support the bitmap modes or 16-bit ROMs found in the 2002 type
-*/
-
-ROM_START( epo_sdb )
- ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
- ROM_LOAD("superdashball.bin", 0x000000, 0x400000, CRC(a004a764) SHA1(47a96822d4d7d6a0f6be5cd729c3747dbab65979) )
-ROM_END
-
-ROM_START( epo_ebox )
- ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
- ROM_LOAD("exciteboxing.bin", 0x000000, 0x400000, CRC(e25ae4f5) SHA1(7f7b613f0ab8f43f5cad0d13de538921e77cae9c) )
-ROM_END
-
-ROM_START( ttv_sw )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "jedi.bin", 0x000000, 0x800000, CRC(51cae5fd) SHA1(1ed8d556f31b4182259ca8c766d60c824d8d9744) )
-ROM_END
-
-ROM_START( ttv_lotr )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "lotr.bin", 0x000000, 0x800000, CRC(a034ecd5) SHA1(264a9d4327af0a075841ad6129db67d82cf741f1) )
-ROM_END
-
-ROM_START( ttv_mx )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "mxdirtrebel.bin", 0x000000, 0x800000, CRC(e64bf1a1) SHA1(137f97d7d857697a13e0c8984509994dc7bc5fc5) )
-ROM_END
-
-ROM_START( drgqst )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "dragonquest.bin", 0x000000, 0x800000, CRC(3d24413f) SHA1(1677e81cedcf349de7bf091a232dc82c6424efba) )
-ROM_END
-
-ROM_START( ban_onep )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00)
- ROM_LOAD("onepiece.bin", 0x000000, 0x800000, CRC(c5cb5a5f) SHA1(db85f6cc48d77c5a4967b9b8e2999167e3dfc8c8) )
-ROM_END
-
-
-CONS( 2002, epo_ebox, 0, 0, xavix2000_nv, epo_epp, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Boxing (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // doesn't use XaviX2000 extra opcodes, but had that type of CPU
- // die not confirmed, but uses extra opcodes. (hangs on title screen due to combination of freq_timer_done nested interrupts tripping, and waiting on bits in input ports to change
-CONS( 2002, epo_bowl, 0, 0, xavix2000_i2c_24c02, epo_bowl, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Bowling (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-
-CONS( 2004, epo_sdb, 0, 0, xavix2000_nv_sdb, epo_sdb, xavix_2000_nv_sdb_state, init_xavix, "Epoch / SSD Company LTD", "Super Dash Ball (Japan)", MACHINE_IMPERFECT_SOUND )
-
-CONS( 2005, ttv_sw, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Star Wars Saga Edition - Lightsaber Battle Game", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-CONS( 2005, ttv_lotr, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Lord Of The Rings - Warrior of Middle-Earth", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-CONS( 2005, ttv_mx, 0, 0, xavix2000_i2c_24c04, ttv_mx, xavix_i2c_state, init_xavix, "Tiger / SSD Company LTD", "MX Dirt Rebel", MACHINE_IMPERFECT_SOUND )
-CONS( 2003, drgqst, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Square Enix / SSD Company LTD", "Kenshin Dragon Quest: Yomigaerishi Densetsu no Ken", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-
-// hangs after starting a game, or after quite a long time in attract mode (first problem could be bad save data read with the eeprom code, 2nd problem might just be how it is, ends up in a dead loop, not executing invalid code, idle timeout / battery saver)
-CONS( 2004, ban_onep, 0, 0, xavix2000_i2c_24c04, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Bandai / SSD Company LTD", "One Piece Punch Battle (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
-
-/* SuperXaviX (XaviX 2002 type CPU) hardware titles (3rd XaviX generation?)
-
- these use the SSD 2002 NEC 85054-611 type CPU
- differences include support for 16-bit ROMs, various bitmap modes, interlace screen modes etc.
- possibly higher horizontal resolution for bitmap layers with others scaled to fit?
-
-*/
-
-/* The 'XaviXPORT' isn't a real console, more of a TV adapter, all the actual hardware (CPU including video hw, sound hw) is in the cartridges and controllers
- and can vary between games, see notes at top of driver.
-
- The 'Domyos Interactive System (DiS)' released in France by Decathlon appears to be identical to XaviXPORT (but for PAL regions, and with an entirely different software range)
-*/
-
-// XaviXPORT
-ROM_START( xavtenni )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "xavixtennis.bin", 0x000000, 0x800000, CRC(23a1d918) SHA1(2241c59e8ea8328013e55952ebf9060ea0a4675b) )
-ROM_END
-
-ROM_START( xavbaseb )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "xpbaseball.bin", 0x000000, 0x800000, CRC(e9ed692d) SHA1(537e390e972156dc7da66ee127ae4c8052038ee5) )
-ROM_END
-
-ROM_START( xavbowl )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "xpbowling.bin", 0x000000, 0x800000, CRC(2873460b) SHA1(ea8e2392f5a12961a23eb66dca8e07dec81ce8c8) )
-ROM_END
-
-ROM_START( xavbassf )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "xpbassfishing.bin", 0x000000, 0x800000, CRC(09ab2f29) SHA1(616254176315d0947002e9ae5a6371a3ffa2e8eb) )
-
- // code for the nRF24E1s, stored in SEEPROMs. One in the cartridge, one in the rod/reel
- ROM_REGION( 0x1001, "reel_io", ROMREGION_ERASE00 )
- ROM_LOAD( "xpbassfishingnrf24e1reel.bin", 0x0000, 0x1001, CRC(cfbb19ae) SHA1(32464e4e4be33fdbc7768311f93ce437a316c616) )
-
- ROM_REGION( 0x800000, "base_io", ROMREGION_ERASE00 )
- ROM_LOAD( "xpbassfishingnrf24e1cart.bin", 0x0000, 0x1001, CRC(62f6303e) SHA1(126b2663e252fb80948f53153e4046e63dd8be32) )
-ROM_END
-
-ROM_START( xavbox )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "xpboxing.bin", 0x000000, 0x800000, CRC(b61e7717) SHA1(162b9c53ac8c9d7b6972db44f7bc1cb0a7837b70) )
-ROM_END
-
-// Several of the XaviXport and DiS games are 2 glob setups (and must have some kind of banking)
-
-ROM_START( xavjmat )
- ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(1420640d) SHA1(dd714cd57cff885293688f74f69b5c1726e20ec0) )
-
- ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
- ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(52dc318c) SHA1(dc50e0747ba29cfb1048fd4a55d26870086c869b) )
-ROM_END
-
-// currently copies the wrong code into RAM to execute (due to extended ROM size, and possible banking)
-// [:] ':maincpu' (00E074): rom_dmatrg_w (do DMA?) 01
-// [:] (possible DMA op SRC 00ebe2d3 DST 358a LEN 0398)
-// needs to come from 006be2d3 (so still from lower 8MB, not upper 8MB)
-
-ROM_START( xavmusic )
- ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(e7c8ad59) SHA1(d47fac8b480de4db88a1b306ff8830a65d1738a3) )
-
- ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
- ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(977c956f) SHA1(debc086d0cf6c391002ad163e7bfaa2f010cc8f5) )
-ROM_END
-
-
-// Domyos DiS (XaviX 2002 based titles)
-ROM_START( domfitex )
- ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(841fe3cd) SHA1(8678b8a0c5198b24169a84dbe3ae979bb0838f23) )
-
- ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
- ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(1dc844ea) SHA1(c23da9006227f7fe4982998c17759d403a47472a) )
-ROM_END
-
-ROM_START( domfitch )
- ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(0ff2a7a6) SHA1(9b924cc4330e3f8d9204390854048fe2325bfdf7) )
-
- ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
- ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(284583f6) SHA1(bd2d5304f1e01eed656b5de957ec0a0330a3d969) )
-ROM_END
-
-ROM_START( domdance )
- ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(74f9499d) SHA1(a64235075e32567cd6d2ab7b1284efcb8e7538e2) )
-
- ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
- ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(e437565c) SHA1(f6db219ea14404b698ca453f6e50c726b2e77abb) )
-ROM_END
-
-ROM_START( domstepc )
- ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(cb37b5e9) SHA1(b742e3db98f36720adf5af9096c6bc235279de12) )
-
- ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
- ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(dadaa744) SHA1(fd7ca77232a8fe228fc93b0a8a47ba3260349d90) )
-ROM_END
-
-ROM_START( mrangbat )
- ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
- ROM_LOAD("powerrangerspad.bin", 0x000000, 0x400000, CRC(d3a98775) SHA1(485c66242dd0ee436a278d23005aece48d606431) )
-ROM_END
-
-ROM_START( tmy_thom )
- ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
- ROM_LOAD( "thomastank.bin", 0x000000, 0x800000, CRC(a52a23be) SHA1(e5b3500239d9e56eb5405f7585982959e5a162da) )
-ROM_END
-
-ROM_START( epo_tfit )
- ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
- ROM_LOAD("tennisfitness.bin", 0x000000, 0x400000, CRC(cbf65bd2) SHA1(30b3da6f061b2dd91679db42a050f715901beb87) )
-ROM_END
-
-
-CONS( 2004, xavtenni, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Tennis (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-CONS( 2004, xavbaseb, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Baseball (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-CONS( 2004, xavbowl, 0, 0, xavix2002_i2c_24c04, xavix_bowl, xavix_i2c_bowl_state, init_xavix, "SSD Company LTD", "XaviX Bowling (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera'
-CONS( 2004, xavbox, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Boxing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera'
-// Bass Fishing PCB is just like Tennis except with an RF daughterboard.
-CONS( 2004, xavbassf, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Bass Fishing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-
-// TODO: check SEEPROM type and hookup, banking!
-CONS( 2005, xavjmat, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "Jackie Chan J-Mat Fitness (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-CONS( 2007, xavmusic, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Music & Circuit (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-
-// https://arnaudmeyer.wordpress.com/domyos-interactive-system/
-// Domyos Fitness Adventure
-// Domyos Fitness Challenge
-// Domyos Fitness Exercises
-// Domyos Fit Race
-// Domyos Soft Fitness
-// Domyos Fitness Dance
-// Domyos Fitness Play
-// Domyos Fitness Training
-
-// Domyos Bike Concept (not listed on site above)
-
-// Has SEEPROM and an RTC. Exercise has some leftover PC buffer stuff. (TODO, check SEEPROM type, RTC type, banking) (both Exercises and Challenge are identical PCBs)
-CONS( 2008, domfitex, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Exercises (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-CONS( 2008, domfitch, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Challenge (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-CONS( 2007, domdance, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Dance (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-CONS( 2007, domstepc, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Step Concept (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-
-// some DIS games run on XaviX 2 instead, see xavix2.cpp for Domyos Fitness Adventure and Domyos Bike Concept
-
-CONS( 2005, mrangbat, 0, 0, xavix2002_i2c_mrangbat, mrangbat, xavix_i2c_state, init_xavix, "Bandai / SSD Company LTD", "Mahou Taiketsu Magiranger - Magimat de Dance & Battle (Japan)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-
-CONS( 2004, epo_tfit, 0, 0, xavix2002_i2c_24c04, epo_tfit, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Sports Tennis x Fitness (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // Epoch Tennis and Fitness has 24LC04
-
-// TODO: does it have an SEEPROM? why does it hang? full title?
-CONS( 2005, tmy_thom, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "Tomy / SSD Company LTD", "Thomas and Friends (Tomy)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
diff --git a/src/mame/drivers/xavix_2000.cpp b/src/mame/drivers/xavix_2000.cpp
new file mode 100644
index 00000000000..30909fd8c17
--- /dev/null
+++ b/src/mame/drivers/xavix_2000.cpp
@@ -0,0 +1,287 @@
+// license:BSD-3-Clause
+// copyright-holders:David Haywood
+/***************************************************************************/
+
+/* (XaviX 2000 type CPU) hardware titles (2nd XaviX generation?)
+
+ these use the SSD 2000 NEC 85605-621 type CPU
+
+ This CPU type adds extra opcodes that don't appear to be present in the 97/98 types
+ It does not appear to support the bitmap modes or 16-bit ROMs found in the 2002 type
+
+ It is possible some games in the regular xavix.cpp drivers use this type, there
+ does not appear to be a way to tell unless the extra opcodes are used or the CPU
+ has been decapped
+
+*/
+
+#include "emu.h"
+#include "includes/xavix_2002.h"
+
+// #define VERBOSE 1
+#include "logmacro.h"
+
+static INPUT_PORTS_START( xavix )
+ PORT_START("IN0")
+ PORT_DIPNAME( 0x01, 0x00, "IN0" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("IN1")
+ PORT_DIPNAME( 0x01, 0x00, "IN1" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("AN0")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN1")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN2")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN3")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN4")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN5")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN6")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN7")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+
+ PORT_START("MOUSE0X")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("MOUSE0Y")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("MOUSE1X")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("MOUSE1Y")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+
+ PORT_START("REGION") // PAL/NTSC flag
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_CUSTOM )
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( xavix_i2c )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( epo_ebox )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN0")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // select
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // back
+ // 04/08 not used for buttons?
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( epo_bowl )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN0")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1)
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_PLAYER(1)
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1)
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1)
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1)
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1)
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( epo_sdb )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("MOUSE0X")
+ PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(1)
+ PORT_MODIFY("MOUSE0Y")
+ PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(1)
+ PORT_MODIFY("MOUSE1X")
+ PORT_BIT( 0xff, 0x00, IPT_AD_STICK_X ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_REVERSE PORT_PLAYER(2)
+ PORT_MODIFY("MOUSE1Y")
+ PORT_BIT( 0xff, 0x00, IPT_AD_STICK_Y ) PORT_SENSITIVITY(25) PORT_KEYDELTA(32) PORT_PLAYER(2)
+
+ PORT_MODIFY("IN0")
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(2)
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(1)
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( ttv_lotr )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r)
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_lotr_state, camera_r)
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( ttv_mx )
+ PORT_INCLUDE(xavix_i2c)
+
+ PORT_MODIFY("IN0")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // Accel
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // Brake
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Pause")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("Motion Up") // you tilt the device, but actual inputs are digital
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("Motion Down")
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("Motion Left")
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("Motion Right")
+INPUT_PORTS_END
+
+
+void xavix_state::xavix2000(machine_config &config)
+{
+ xavix(config);
+
+ XAVIX2000(config.replace(), m_maincpu, MAIN_CLOCK);
+ m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map);
+ m_maincpu->set_addrmap(5, &xavix_state::xavix_lowbus_map);
+ m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map);
+ m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt));
+ m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors));
+
+ m_palette->set_entries(512);
+}
+
+void xavix_state::xavix2000_nv(machine_config &config)
+{
+ xavix2000(config);
+
+ NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_1);
+}
+
+void xavix_2000_nv_sdb_state::xavix2000_nv_sdb(machine_config &config)
+{
+ xavix2000_nv(config);
+
+ m_anport->read_0_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport0_r));
+ m_anport->read_1_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport1_r));
+ m_anport->read_2_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport2_r));
+ m_anport->read_3_callback().set(FUNC(xavix_2000_nv_sdb_state::sdb_anport3_r));
+}
+
+void xavix_i2c_state::xavix2000_i2c_24c04(machine_config &config)
+{
+ xavix2000(config);
+
+ I2C_24C04(config, "i2cmem", 0);
+}
+
+void xavix_i2c_state::xavix2000_i2c_24c02(machine_config &config)
+{
+ xavix2000(config);
+
+ I2C_24C02(config, "i2cmem", 0);
+}
+
+
+
+ROM_START( epo_sdb )
+ ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("superdashball.bin", 0x000000, 0x400000, CRC(a004a764) SHA1(47a96822d4d7d6a0f6be5cd729c3747dbab65979) )
+ROM_END
+
+ROM_START( epo_ebox )
+ ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("exciteboxing.bin", 0x000000, 0x400000, CRC(e25ae4f5) SHA1(7f7b613f0ab8f43f5cad0d13de538921e77cae9c) )
+ROM_END
+
+ROM_START( epo_bowl )
+ ROM_REGION(0x200000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("bowling.bin", 0x000000, 0x200000, CRC(d34f8d9e) SHA1(ebe3792172dc43904b9226beb27f1da89d2388cc) )
+ROM_END
+
+ROM_START( ttv_sw )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "jedi.bin", 0x000000, 0x800000, CRC(51cae5fd) SHA1(1ed8d556f31b4182259ca8c766d60c824d8d9744) )
+ROM_END
+
+ROM_START( ttv_lotr )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "lotr.bin", 0x000000, 0x800000, CRC(a034ecd5) SHA1(264a9d4327af0a075841ad6129db67d82cf741f1) )
+ROM_END
+
+ROM_START( ttv_mx )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "mxdirtrebel.bin", 0x000000, 0x800000, CRC(e64bf1a1) SHA1(137f97d7d857697a13e0c8984509994dc7bc5fc5) )
+ROM_END
+
+ROM_START( drgqst )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "dragonquest.bin", 0x000000, 0x800000, CRC(3d24413f) SHA1(1677e81cedcf349de7bf091a232dc82c6424efba) )
+ROM_END
+
+ROM_START( ban_onep )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("onepiece.bin", 0x000000, 0x800000, CRC(c5cb5a5f) SHA1(db85f6cc48d77c5a4967b9b8e2999167e3dfc8c8) )
+ROM_END
+
+// doesn't use extra opcodes?
+CONS( 2002, epo_ebox, 0, 0, xavix2000_nv, epo_ebox, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Boxing (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // doesn't use XaviX2000 extra opcodes, but had that type of CPU
+ // die not confirmed, but uses extra opcodes. (hangs on title screen due to combination of freq_timer_done nested interrupts tripping, and waiting on bits in input ports to change
+CONS( 2002, epo_bowl, 0, 0, xavix2000_i2c_24c02, epo_bowl, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Bowling (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
+
+CONS( 2004, epo_sdb, 0, 0, xavix2000_nv_sdb, epo_sdb, xavix_2000_nv_sdb_state, init_xavix, "Epoch / SSD Company LTD", "Super Dash Ball (Japan)", MACHINE_IMPERFECT_SOUND )
+
+CONS( 2005, ttv_sw, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Star Wars Saga Edition - Lightsaber Battle Game", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
+CONS( 2005, ttv_lotr, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Tiger / SSD Company LTD", "Lord Of The Rings - Warrior of Middle-Earth", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
+CONS( 2005, ttv_mx, 0, 0, xavix2000_i2c_24c04, ttv_mx, xavix_i2c_state, init_xavix, "Tiger / SSD Company LTD", "MX Dirt Rebel", MACHINE_IMPERFECT_SOUND )
+CONS( 2003, drgqst, 0, 0, xavix2000_i2c_24c02, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Square Enix / SSD Company LTD", "Kenshin Dragon Quest: Yomigaerishi Densetsu no Ken", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
+
+// hangs after starting a game, or after quite a long time in attract mode (first problem could be bad save data read with the eeprom code, 2nd problem might just be how it is, ends up in a dead loop, not executing invalid code, idle timeout / battery saver)
+CONS( 2004, ban_onep, 0, 0, xavix2000_i2c_24c04, ttv_lotr, xavix_i2c_lotr_state, init_xavix, "Bandai / SSD Company LTD", "One Piece Punch Battle (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND )
diff --git a/src/mame/drivers/xavix_2002.cpp b/src/mame/drivers/xavix_2002.cpp
new file mode 100644
index 00000000000..5cde7e9e328
--- /dev/null
+++ b/src/mame/drivers/xavix_2002.cpp
@@ -0,0 +1,547 @@
+// license:BSD-3-Clause
+// copyright-holders:David Haywood
+/***************************************************************************/
+
+/* SuperXaviX (XaviX 2002 type CPU) hardware titles (3rd XaviX generation?)
+
+ these use the SSD 2002 NEC 85054-611 type CPU
+ differences include support for 16-bit ROMs, high resolution bitmap modes, interlace screen modes, extra IO
+
+ XavixPort Golf is "SSD 2003 SuperXaviX MXIC 2003 3009" (not dumped yet, but actually marked as SuperXaviX unlike the others!)
+
+*/
+
+#include "emu.h"
+#include "includes/xavix_2002.h"
+
+// #define VERBOSE 1
+#include "logmacro.h"
+
+/* The 'XaviXPORT' isn't a real console, more of a TV adapter, all the actual hardware (CPU including video hw, sound hw) is in the cartridges and controllers
+ and can vary between games, see notes at top of driver.
+
+ The 'Domyos Interactive System (DiS)' released in France by Decathlon appears to be identical to XaviXPORT (but for PAL regions, and with an entirely different software range)
+*/
+
+
+static INPUT_PORTS_START( xavix )
+ PORT_START("IN0")
+ PORT_DIPNAME( 0x01, 0x00, "IN0" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("IN1")
+ PORT_DIPNAME( 0x01, 0x00, "IN1" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("AN0")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN1")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN2")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN3")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN4")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN5")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN6")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("AN7")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+
+ PORT_START("MOUSE0X")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("MOUSE0Y")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("MOUSE1X")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+ PORT_START("MOUSE1Y")
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED )
+
+ PORT_START("REGION") // PAL/NTSC flag
+ PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_CUSTOM )
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( xavix_i2c )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( epo_tfit )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN0")
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) // select
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) // back
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON3 )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON4 )
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+INPUT_PORTS_END
+
+
+static INPUT_PORTS_START( mrangbat )
+ PORT_INCLUDE(xavix_i2c)
+
+ PORT_MODIFY("IN0")
+ PORT_DIPNAME( 0x01, 0x00, "IN0" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_MODIFY("IN1")
+ PORT_DIPNAME( 0x01, 0x00, "IN1" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("EX0") // NOT A JOYSTICK!!
+ PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(1) PORT_16WAY // Red/Up 1
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_PLAYER(2) PORT_16WAY // Red/Up 2
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(2) PORT_16WAY // Green / Circle / Right 2
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(2) PORT_16WAY // Pink / Star / Left 2
+ PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) PORT_16WAY // Blue / Square / Right 1
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) PORT_16WAY // Yellow / Triangle / Left 1
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON7 )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON8 )
+
+
+ PORT_START("EX1")
+ PORT_DIPNAME( 0x01, 0x00, "EX1" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+
+ PORT_START("EX2")
+ PORT_DIPNAME( 0x01, 0x00, "EX2" )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( On ) )
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( xavix_bowl )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("IN1")
+ PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r)
+ PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_MEMBER(xavix_i2c_bowl_state, camera_r)
+ PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("i2cmem", i2cmem_device, read_sda)
+INPUT_PORTS_END
+
+static INPUT_PORTS_START( xavixp )
+ PORT_INCLUDE(xavix)
+
+ PORT_MODIFY("REGION") // PAL/NTSC flag
+ PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_CUSTOM )
+INPUT_PORTS_END
+
+
+/* SuperXavix IO port handliner (per game) */
+
+uint8_t xavix_i2c_jmat_state::read_extended_io0()
+{
+ LOG("%s: read_extended_io0\n", machine().describe_context());
+ return 0x00;
+}
+
+uint8_t xavix_i2c_jmat_state::read_extended_io1()
+{
+ LOG("%s: read_extended_io1\n", machine().describe_context());
+
+ // reads this by reading the byte, then shifting right 4 times to place value into carry flag
+ return m_i2cmem->read_sda() << 3;
+ //return 0x00;
+}
+
+uint8_t xavix_i2c_jmat_state::read_extended_io2()
+{
+ LOG("%s: read_extended_io2\n", machine().describe_context());
+ return 0x00;
+}
+
+void xavix_i2c_jmat_state::write_extended_io0(uint8_t data)
+{
+ LOG("%s: io0_data_w %02x\n", machine().describe_context(), data);
+}
+
+void xavix_i2c_jmat_state::write_extended_io1(uint8_t data)
+{
+ LOG("%s: io1_data_w %02x\n", machine().describe_context(), data);
+
+ m_i2cmem->write_sda((data & 0x08) >> 3);
+ m_i2cmem->write_scl((data & 0x10) >> 4);
+
+}
+
+void xavix_i2c_jmat_state::write_extended_io2(uint8_t data)
+{
+ LOG("%s: io2_data_w %02x\n", machine().describe_context(), data);
+}
+
+READ_LINE_MEMBER(xavix_i2c_lotr_state::camera_r) // seems to be some kind of camera status bits
+{
+ return machine().rand();
+}
+
+READ_LINE_MEMBER(xavix_i2c_bowl_state::camera_r) // seems to be some kind of camera status bits
+{
+ return machine().rand();
+}
+
+void xavix_state::xavix2002(machine_config &config)
+{
+ xavix(config);
+
+ XAVIX2002(config.replace(), m_maincpu, MAIN_CLOCK);
+ m_maincpu->set_addrmap(AS_PROGRAM, &xavix_state::xavix_map);
+ m_maincpu->set_addrmap(5, &xavix_state::superxavix_lowbus_map); // has extra video, io etc.
+ m_maincpu->set_addrmap(6, &xavix_state::xavix_extbus_map);
+ m_maincpu->set_vblank_int("screen", FUNC(xavix_state::interrupt));
+ m_maincpu->set_vector_callback(FUNC(xavix_state::get_vectors));
+
+ m_palette->set_entries(512);
+
+ XAVIX2002IO(config, m_xavix2002io, 0);
+}
+
+
+
+void xavix_i2c_jmat_state::xavix2002_i2c_jmat(machine_config &config)
+{
+ xavix2002_i2c_24c04(config);
+
+ m_xavix2002io->read_0_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io0));
+ m_xavix2002io->write_0_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io0));
+ m_xavix2002io->read_1_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io1));
+ m_xavix2002io->write_1_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io1));
+ m_xavix2002io->read_2_callback().set(FUNC(xavix_i2c_jmat_state::read_extended_io2));
+ m_xavix2002io->write_2_callback().set(FUNC(xavix_i2c_jmat_state::write_extended_io2));
+}
+
+void xavix2002_superpttv_state::xavix2002_superpctv(machine_config& config)
+{
+ xavix2002(config);
+
+ m_xavix2002io->read_0_callback().set(FUNC(xavix2002_superpttv_state::read_extended_io0));
+ m_xavix2002io->read_1_callback().set(FUNC(xavix2002_superpttv_state::read_extended_io1));
+ m_xavix2002io->read_2_callback().set(FUNC(xavix2002_superpttv_state::read_extended_io2));
+}
+
+
+void xavix_i2c_state::xavix2002_i2c_24c04(machine_config &config)
+{
+ xavix2002(config);
+
+ I2C_24C04(config, "i2cmem", 0);
+}
+
+void xavix_i2c_state::xavix2002_i2c_mrangbat(machine_config &config)
+{
+ xavix2002(config);
+
+ I2C_24C02(config, "i2cmem", 0); // 24C02?
+
+ m_xavix2002io->read_0_callback().set_ioport("EX0");
+ m_xavix2002io->read_1_callback().set_ioport("EX1");
+ m_xavix2002io->read_2_callback().set_ioport("EX2");
+}
+
+
+// XaviXPORT
+ROM_START( xavtenni )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "xavixtennis.bin", 0x000000, 0x800000, CRC(23a1d918) SHA1(2241c59e8ea8328013e55952ebf9060ea0a4675b) )
+ROM_END
+
+ROM_START( xavbaseb )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "xpbaseball.bin", 0x000000, 0x800000, CRC(e9ed692d) SHA1(537e390e972156dc7da66ee127ae4c8052038ee5) )
+ROM_END
+
+ROM_START( xavbowl )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "xpbowling.bin", 0x000000, 0x800000, CRC(2873460b) SHA1(ea8e2392f5a12961a23eb66dca8e07dec81ce8c8) )
+ROM_END
+
+ROM_START( xavbassf )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "xpbassfishing.bin", 0x000000, 0x800000, CRC(09ab2f29) SHA1(616254176315d0947002e9ae5a6371a3ffa2e8eb) )
+
+ // code for the nRF24E1s, stored in SEEPROMs. One in the cartridge, one in the rod/reel
+ ROM_REGION( 0x1001, "reel_io", ROMREGION_ERASE00 )
+ ROM_LOAD( "xpbassfishingnrf24e1reel.bin", 0x0000, 0x1001, CRC(cfbb19ae) SHA1(32464e4e4be33fdbc7768311f93ce437a316c616) )
+
+ ROM_REGION( 0x800000, "base_io", ROMREGION_ERASE00 )
+ ROM_LOAD( "xpbassfishingnrf24e1cart.bin", 0x0000, 0x1001, CRC(62f6303e) SHA1(126b2663e252fb80948f53153e4046e63dd8be32) )
+ROM_END
+
+ROM_START( xavbox )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "xpboxing.bin", 0x000000, 0x800000, CRC(b61e7717) SHA1(162b9c53ac8c9d7b6972db44f7bc1cb0a7837b70) )
+ROM_END
+
+// Several of the XaviXport and DiS games are 2 glob setups (and must have some kind of banking)
+
+ROM_START( xavjmat )
+ ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(1420640d) SHA1(dd714cd57cff885293688f74f69b5c1726e20ec0) )
+
+ ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
+ ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(52dc318c) SHA1(dc50e0747ba29cfb1048fd4a55d26870086c869b) )
+ROM_END
+
+// currently copies the wrong code into RAM to execute (due to extended ROM size, and possible banking)
+// [:] ':maincpu' (00E074): rom_dmatrg_w (do DMA?) 01
+// [:] (possible DMA op SRC 00ebe2d3 DST 358a LEN 0398)
+// needs to come from 006be2d3 (so still from lower 8MB, not upper 8MB)
+
+ROM_START( xavmusic )
+ ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(e7c8ad59) SHA1(d47fac8b480de4db88a1b306ff8830a65d1738a3) )
+
+ ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
+ ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(977c956f) SHA1(debc086d0cf6c391002ad163e7bfaa2f010cc8f5) )
+ROM_END
+
+
+// Domyos DiS (XaviX 2002 based titles)
+ROM_START( domfitex )
+ ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(841fe3cd) SHA1(8678b8a0c5198b24169a84dbe3ae979bb0838f23) )
+
+ ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
+ ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(1dc844ea) SHA1(c23da9006227f7fe4982998c17759d403a47472a) )
+ROM_END
+
+ROM_START( domfitch )
+ ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(0ff2a7a6) SHA1(9b924cc4330e3f8d9204390854048fe2325bfdf7) )
+
+ ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
+ ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(284583f6) SHA1(bd2d5304f1e01eed656b5de957ec0a0330a3d969) )
+ROM_END
+
+ROM_START( domdance )
+ ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(74f9499d) SHA1(a64235075e32567cd6d2ab7b1284efcb8e7538e2) )
+
+ ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
+ ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(e437565c) SHA1(f6db219ea14404b698ca453f6e50c726b2e77abb) )
+ROM_END
+
+ROM_START( domstepc )
+ ROM_REGION( 0x0800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "u2", 0x0000000, 0x0800000, CRC(cb37b5e9) SHA1(b742e3db98f36720adf5af9096c6bc235279de12) )
+
+ ROM_REGION( 0x0800000, "biosu3", ROMREGION_ERASE00 )
+ ROM_LOAD( "u3", 0x0000000, 0x0800000, CRC(dadaa744) SHA1(fd7ca77232a8fe228fc93b0a8a47ba3260349d90) )
+ROM_END
+
+ROM_START( mrangbat )
+ ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("powerrangerspad.bin", 0x000000, 0x400000, CRC(d3a98775) SHA1(485c66242dd0ee436a278d23005aece48d606431) )
+ROM_END
+
+ROM_START( tmy_thom )
+ ROM_REGION( 0x800000, "bios", ROMREGION_ERASE00 )
+ ROM_LOAD( "thomastank.bin", 0x000000, 0x800000, CRC(a52a23be) SHA1(e5b3500239d9e56eb5405f7585982959e5a162da) )
+ROM_END
+
+ROM_START( epo_tfit )
+ ROM_REGION(0x400000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("tennisfitness.bin", 0x000000, 0x400000, CRC(cbf65bd2) SHA1(30b3da6f061b2dd91679db42a050f715901beb87) )
+ROM_END
+
+ROM_START( suprpctv )
+ ROM_REGION(0x800000, "bios", ROMREGION_ERASE00) // inverted line?
+ ROM_LOAD("superpctv.bin", 0x200000, 0x200000, CRC(4a55a81c) SHA1(178b4b595a3aefc6d1c176031b436fc3312009e7) )
+ ROM_CONTINUE(0x000000, 0x200000)
+ ROM_CONTINUE(0x600000, 0x200000)
+ ROM_CONTINUE(0x400000, 0x200000)
+ROM_END
+
+ROM_START( udance )
+ ROM_REGION(0x800000, "bios", ROMREGION_ERASE00)
+ ROM_LOAD("udancerom0.bin", 0x000000, 0x800000, CRC(3066580a) SHA1(545257c75a892894faf386f4ab9a31967cdbe8ae) )
+
+ ROM_REGION(0x800000, "biosx", ROMREGION_ERASE00)
+ ROM_LOAD("udancerom1.bin", 0x000000, 0x800000, CRC(7dbaabde) SHA1(38c523dcdf8185465fc550fb9b0e8c7909f839be) )
+ROM_END
+
+
+CONS( 2004, xavtenni, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Tennis (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2004, xavbaseb, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Baseball (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2004, xavbowl, 0, 0, xavix2002_i2c_24c04, xavix_bowl, xavix_i2c_bowl_state, init_xavix, "SSD Company LTD", "XaviX Bowling (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera'
+CONS( 2004, xavbox, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Boxing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // has IR 'Camera'
+// Bass Fishing PCB is just like Tennis except with an RF daughterboard.
+CONS( 2004, xavbassf, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "SSD Company LTD", "XaviX Bass Fishing (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+// TODO: check SEEPROM type and hookup, banking!
+CONS( 2005, xavjmat, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "Jackie Chan J-Mat Fitness (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2007, xavmusic, 0, 0, xavix2002_i2c_jmat, xavix, xavix_i2c_jmat_state, init_xavix, "SSD Company LTD", "XaviX Music & Circuit (XaviXPORT)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+// https://arnaudmeyer.wordpress.com/domyos-interactive-system/
+// Domyos Fitness Adventure
+// Domyos Fitness Challenge
+// Domyos Fitness Exercises
+// Domyos Fit Race
+// Domyos Soft Fitness
+// Domyos Fitness Dance
+// Domyos Fitness Play
+// Domyos Fitness Training
+
+// Domyos Bike Concept (not listed on site above)
+
+// Has SEEPROM and an RTC. Exercise has some leftover PC buffer stuff. (TODO, check SEEPROM type, RTC type, banking) (both Exercises and Challenge are identical PCBs)
+CONS( 2008, domfitex, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Exercises (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2008, domfitch, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Challenge (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2007, domdance, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Fitness Dance (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+CONS( 2007, domstepc, 0, 0, xavix2002_i2c_jmat, xavixp, xavix_i2c_jmat_state, init_xavix, "Decathlon / SSD Company LTD", "Domyos Step Concept (Domyos Interactive System)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+// some DIS games run on XaviX 2 instead, see xavix2.cpp for Domyos Fitness Adventure and Domyos Bike Concept
+
+CONS( 2005, mrangbat, 0, 0, xavix2002_i2c_mrangbat, mrangbat, xavix_i2c_state, init_xavix, "Bandai / SSD Company LTD", "Mahou Taiketsu Magiranger - Magimat de Dance & Battle (Japan)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+CONS( 2004, epo_tfit, 0, 0, xavix2002_i2c_24c04, epo_tfit, xavix_i2c_state, init_xavix, "Epoch / SSD Company LTD", "Excite Sports Tennis x Fitness (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // Epoch Tennis and Fitness has 24LC04
+
+// TODO: does it have an SEEPROM? why does it hang? full title?
+CONS( 2005, tmy_thom, 0, 0, xavix2002_i2c_24c04, xavix_i2c, xavix_i2c_state, init_xavix, "Tomy / SSD Company LTD", "Thomas and Friends (Tomy)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+// has HT24LC16
+CONS( 2008, udance, 0, 0, xavix2002, xavix, xavix_state, init_xavix, "Tiger / SSD Company LTD", "U-Dance", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+// this has RAM in the usual ROM space, needs handling, also has Atmel 24LC64.
+CONS( 200?, suprpctv, 0, 0, xavix2002_superpctv, xavix, xavix2002_superpttv_state, init_xavix, "Epoch / SSD Company LTD", "Super PC TV (Epoch)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
+
+
diff --git a/src/mame/drivers/z80ne.cpp b/src/mame/drivers/z80ne.cpp
index e1da99443f1..00da29c4226 100644
--- a/src/mame/drivers/z80ne.cpp
+++ b/src/mame/drivers/z80ne.cpp
@@ -87,8 +87,36 @@
9000-9FFF EPROM EPROM to be written
8400-8FFF EPROM firmware
-
-******************************************************************************/
+Quick Instructions:
+ Z80NE:
+ - Use 0-F to enter an address (or use mouse in artwork)
+ - Hold CTRL press 0 to show data at that address (CTRL cannot be held with mouse)
+ - Use 0-F to enter data
+ - CTRL 0 to advance to next address
+ - CTRL 2 to view/change CPU registers
+ - CTRL 0 change register, advance to next
+ Z80NET
+ - In Machine Configuration, select your preferred baud rate, and reboot machine.
+ - CTRL 6 to load a tape, press A or B to choose tape device, choose Play.
+ - After this, click any key, enter 1000, CTRL 4 to run.
+ - CTRL 5 to save
+ - All tapes in software list (except bioritmi & tapebas) are BASIC programs.
+ - To use tapebas, load side 1 in the normal way, run it, select side 2 for cas 0, play, the rest loads
+ - The Basic is bilingual - ENG for English, ITA for Italian, so enter ENG.
+ - Then for any Basic program in software list: CLOAD hit Play RUN
+ Z80NETB
+ - BASIC-only, English only. A version of TRS80 Level II Basic. Not compatible with software list.
+ Z80NETF
+ - There is a choice of 5 bioses, via the Machine Configuration menu
+ - EP382: same as Z80NET.
+ - EP548: same as Z80NETB.
+ - EP390: for swlist-item "basic55k". Press B, from the menu select 2, runs. Type ENG for English.
+ It can load and run tapes from the swlist, although it seems to often have load errors.
+ - EP1390: requires a floppy to boot from. Disks marked as NE-DOS 1.5 should work.
+ - EP2390: uses ports 8x, not emulated, not working. For NE-DOS G.1
+
+
+*********************************************************************************************************/
/* Core includes */
#include "emu.h"
@@ -113,25 +141,22 @@
/* LX.382 CPU Board RAM */
/* LX.382 CPU Board EPROM */
-void z80ne_state::main_mem(address_map &map)
+void z80ne_state::mem_map(address_map &map)
{
- map(0x0000, 0x03ff).bankrw("bank1");
- map(0x0400, 0x7fff).ram();
- map(0x8000, 0x83ff).bankr("bank2");
- map(0x8400, 0xffff).nopr().nopw();
+ map(0x0000, 0x7fff).ram().share("mainram");
+ map(0x8000, 0x83ff).rom().region("maincpu",0);
}
-void z80net_state::main_mem(address_map &map)
+void z80net_state::mem_map(address_map &map)
{
- map(0x0000, 0x03ff).bankrw("bank1");
- map(0x0400, 0x7fff).ram();
- map(0x8000, 0x83ff).bankr("bank2");
+ map(0x0000, 0x7fff).ram().share("mainram");
+ map(0x8000, 0x83ff).rom().region("maincpu",0);
map(0x8400, 0xebff).ram();
map(0xec00, 0xedff).ram().share("videoram"); /* (6847) */
map(0xee00, 0xffff).ram();
}
-void z80netb_state::main_mem(address_map &map)
+void z80netb_state::mem_map(address_map &map)
{
map(0x0000, 0x3fff).rom();
map(0x4000, 0xebff).ram();
@@ -139,7 +164,7 @@ void z80netb_state::main_mem(address_map &map)
map(0xee00, 0xffff).ram();
}
-void z80ne_state::main_io(address_map &map)
+void z80ne_state::io_map(address_map &map)
{
map.global_mask(0xff);
map(0xee, 0xee).rw(m_uart, FUNC(ay31015_device::receive), FUNC(ay31015_device::transmit));
@@ -147,7 +172,7 @@ void z80ne_state::main_io(address_map &map)
map(0xf0, 0xff).rw(FUNC(z80ne_state::lx383_r), FUNC(z80ne_state::lx383_w));
}
-void z80net_state::main_io(address_map &map)
+void z80net_state::io_map(address_map &map)
{
map.global_mask(0xff);
map(0xea, 0xea).r(FUNC(z80net_state::lx387_data_r));
@@ -157,21 +182,18 @@ void z80net_state::main_io(address_map &map)
map(0xf0, 0xff).rw(FUNC(z80net_state::lx383_r), FUNC(z80net_state::lx383_w));
}
-void z80netf_state::main_mem(address_map &map)
+void z80netf_state::mem_map(address_map &map)
{
map(0x0000, 0x03ff).bankrw("bank1");
map(0x0400, 0x3fff).bankrw("bank2");
map(0x4000, 0x7fff).ram();
map(0x8000, 0x83ff).bankrw("bank3");
map(0x8400, 0xdfff).ram();
- map(0xe000, 0xebff).nopr().nopw();
map(0xec00, 0xedff).ram().share("videoram"); /* (6847) */
- map(0xee00, 0xefff).nopr().nopw();
map(0xf000, 0xf3ff).bankrw("bank4");
- map(0xf400, 0xffff).nopr().nopw();
}
-void z80netf_state::main_io(address_map &map)
+void z80netf_state::io_map(address_map &map)
{
map.global_mask(0xff);
map(0xd0, 0xd7).rw(FUNC(z80netf_state::lx390_fdc_r), FUNC(z80netf_state::lx390_fdc_w));
@@ -195,30 +217,30 @@ static INPUT_PORTS_START( z80ne )
* In natural mode the CTRL key is mapped on shift
*/
PORT_START("ROW0") /* IN0 keys row 0 */
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 0") PORT_CODE(KEYCODE_0) //PORT_CHAR('0') PORT_CHAR('=')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 1") PORT_CODE(KEYCODE_1) //PORT_CHAR('1') PORT_CHAR('!')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 2") PORT_CODE(KEYCODE_2) //PORT_CHAR('2') PORT_CHAR('"')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 3") PORT_CODE(KEYCODE_3) //PORT_CHAR('3') PORT_CHAR(0x00a3) // ??
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 4") PORT_CODE(KEYCODE_4) //PORT_CHAR('4') PORT_CHAR('$')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 5") PORT_CODE(KEYCODE_5) //PORT_CHAR('5') PORT_CHAR('%')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 6") PORT_CODE(KEYCODE_6) //PORT_CHAR('6') PORT_CHAR('&')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 7") PORT_CODE(KEYCODE_7) //PORT_CHAR('7') PORT_CHAR('/')
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 0") PORT_CODE(KEYCODE_0) PORT_CHAR('0') PORT_CHAR('=') // set address, increment
+ PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 1") PORT_CODE(KEYCODE_1) PORT_CHAR('1') PORT_CHAR('-') // ?
+ PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 2") PORT_CODE(KEYCODE_2) PORT_CHAR('2') PORT_CHAR('R') // registers
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 3") PORT_CODE(KEYCODE_3) PORT_CHAR('3') PORT_CHAR('T') // single-step
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 4") PORT_CODE(KEYCODE_4) PORT_CHAR('4') PORT_CHAR('X') // go
+ PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 5") PORT_CODE(KEYCODE_5) PORT_CHAR('5') PORT_CHAR('L') // load
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 6") PORT_CODE(KEYCODE_6) PORT_CHAR('6') PORT_CHAR('S') // save
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 7") PORT_CODE(KEYCODE_7) PORT_CHAR('7') PORT_CHAR('K') // reserved for future expansion
PORT_START("ROW1") /* IN1 keys row 1 */
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 8") PORT_CODE(KEYCODE_8) //PORT_CHAR('8') PORT_CHAR('(')
- PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 9") PORT_CODE(KEYCODE_9) //PORT_CHAR('9') PORT_CHAR(')')
- PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 A") PORT_CODE(KEYCODE_A) //PORT_CHAR('a') PORT_CHAR('A')
- PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 B") PORT_CODE(KEYCODE_B) //PORT_CHAR('b') PORT_CHAR('B')
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 C") PORT_CODE(KEYCODE_C) //PORT_CHAR('c') PORT_CHAR('C')
- PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 D") PORT_CODE(KEYCODE_D) //PORT_CHAR('d') PORT_CHAR('D')
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 E") PORT_CODE(KEYCODE_E) //PORT_CHAR('e') PORT_CHAR('E')
- PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 F") PORT_CODE(KEYCODE_F) //PORT_CHAR('f') PORT_CHAR('F')
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 8") PORT_CODE(KEYCODE_8) PORT_CHAR('8')
+ PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 9") PORT_CODE(KEYCODE_9) PORT_CHAR('9')
+ PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 A") PORT_CODE(KEYCODE_A) PORT_CHAR('A')
+ PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 B") PORT_CODE(KEYCODE_B) PORT_CHAR('B')
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 C") PORT_CODE(KEYCODE_C) PORT_CHAR('C')
+ PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 D") PORT_CODE(KEYCODE_D) PORT_CHAR('D')
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 E") PORT_CODE(KEYCODE_E) PORT_CHAR('E')
+ PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 F") PORT_CODE(KEYCODE_F) PORT_CHAR('F')
PORT_START("CTRL") /* CONTROL key */
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNUSED )
- PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 CTRL") PORT_CODE(KEYCODE_LCONTROL) PORT_CODE(KEYCODE_RCONTROL) //PORT_CHAR(UCHAR_SHIFT_1)
+ PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 CTRL") PORT_CODE(KEYCODE_LCONTROL) PORT_CODE(KEYCODE_RCONTROL) PORT_CHAR(UCHAR_SHIFT_1)
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNUSED )
@@ -227,7 +249,7 @@ static INPUT_PORTS_START( z80ne )
PORT_START("RST") /* RESET key */
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("LX.384 Reset") PORT_CODE(KEYCODE_F3) PORT_CHANGED_MEMBER(DEVICE_SELF, z80ne_state, z80ne_reset, 0)
- /* Settings */
+ /* Settings - need to reboot after altering these */
PORT_START("LX.385")
PORT_CONFNAME(0x07, 0x04, "LX.385 Cassette: P1,P3 Data Rate")
PORT_CONFSETTING( 0x01, "A-B: 300 bps")
@@ -246,7 +268,7 @@ static INPUT_PORTS_START( z80net )
/* LX.387 Keyboard BREAK key */
PORT_START("LX387_BRK")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("Break") PORT_CODE(KEYCODE_INSERT) PORT_CHAR(UCHAR_MAMEKEY(INSERT)) PORT_CHANGED_MEMBER(DEVICE_SELF, z80net_state, z80net_nmi, 0)
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("Break") PORT_CODE(KEYCODE_END) PORT_CHAR(UCHAR_MAMEKEY(END)) PORT_CHANGED_MEMBER(DEVICE_SELF, z80net_state, z80net_nmi, 0)
/* LX.387 Keyboard (Encoded by KR2376) */
@@ -419,8 +441,8 @@ void z80ne_state::z80ne(machine_config &config)
{
/* basic machine hardware */
Z80(config, m_maincpu, Z80NE_CPU_SPEED_HZ);
- m_maincpu->set_addrmap(AS_PROGRAM, &z80ne_state::main_mem);
- m_maincpu->set_addrmap(AS_IO, &z80ne_state::main_io);
+ m_maincpu->set_addrmap(AS_PROGRAM, &z80ne_state::mem_map);
+ m_maincpu->set_addrmap(AS_IO, &z80ne_state::io_map);
AY31015(config, m_uart);
@@ -442,9 +464,6 @@ void z80ne_state::z80ne(machine_config &config)
config.set_default_layout(layout_z80ne);
- /* internal ram */
- RAM(config, m_ram).set_default_size("32K");
-
// all known tapes require LX.388 expansion
//SOFTWARE_LIST(config, "cass_list").set_original("z80ne_cass");
}
@@ -468,8 +487,8 @@ void z80net_state::z80net(machine_config &config)
{
z80ne(config);
- m_maincpu->set_addrmap(AS_PROGRAM, &z80net_state::main_mem);
- m_maincpu->set_addrmap(AS_IO, &z80net_state::main_io);
+ m_maincpu->set_addrmap(AS_PROGRAM, &z80net_state::mem_map);
+ m_maincpu->set_addrmap(AS_IO, &z80net_state::io_map);
lx387(config);
@@ -484,9 +503,6 @@ void z80net_state::z80net(machine_config &config)
config.set_default_layout(layout_z80net);
- /* internal ram */
- m_ram->set_default_size("32K").set_extra_options("1K");
-
SOFTWARE_LIST(config, "cass_list").set_original("z80ne_cass");
}
@@ -494,8 +510,8 @@ void z80netb_state::z80netb(machine_config &config)
{
/* basic machine hardware */
Z80(config, m_maincpu, Z80NE_CPU_SPEED_HZ);
- m_maincpu->set_addrmap(AS_PROGRAM, &z80netb_state::main_mem);
- m_maincpu->set_addrmap(AS_IO, &z80netb_state::main_io);
+ m_maincpu->set_addrmap(AS_PROGRAM, &z80netb_state::mem_map);
+ m_maincpu->set_addrmap(AS_IO, &z80netb_state::io_map);
AY31015(config, m_uart);
@@ -528,18 +544,16 @@ void z80netb_state::z80netb(machine_config &config)
config.set_default_layout(layout_z80netb);
- /* internal ram */
- RAM(config, m_ram).set_default_size("32K").set_extra_options("1K");
-
- SOFTWARE_LIST(config, "cass_list").set_original("z80ne_cass");
+ // none of the software is compatible
+ //SOFTWARE_LIST(config, "cass_list").set_original("z80ne_cass");
}
void z80netf_state::z80netf(machine_config &config)
{
/* basic machine hardware */
Z80(config, m_maincpu, Z80NE_CPU_SPEED_HZ);
- m_maincpu->set_addrmap(AS_PROGRAM, &z80netf_state::main_mem);
- m_maincpu->set_addrmap(AS_IO, &z80netf_state::main_io);
+ m_maincpu->set_addrmap(AS_PROGRAM, &z80netf_state::mem_map);
+ m_maincpu->set_addrmap(AS_IO, &z80netf_state::io_map);
AY31015(config, m_uart);
@@ -579,7 +593,7 @@ void z80netf_state::z80netf(machine_config &config)
config.set_default_layout(layout_z80netf);
/* internal ram */
- RAM(config, m_ram).set_default_size("56K");
+ RAM(config, m_ram).set_default_size("56K").set_default_value(0x00);
SOFTWARE_LIST(config, "cass_list").set_original("z80ne_cass");
SOFTWARE_LIST(config, "flop_list").set_original("z80ne_flop");
@@ -591,20 +605,20 @@ void z80netf_state::z80netf(machine_config &config)
ROM_START( z80ne )
- ROM_REGION(0x20000, "z80ne", 0)
- ROM_LOAD( "ep382.ic5", 0x14000, 0x0400, CRC(55818366) SHA1(adcac04b83c09265517b7bafbc2f5f665d751bec) )
+ ROM_REGION(0x0400, "maincpu", 0)
+ ROM_LOAD( "ep382.ic5", 0x0000, 0x0400, CRC(55818366) SHA1(adcac04b83c09265517b7bafbc2f5f665d751bec) )
ROM_END
ROM_START( z80net )
- ROM_REGION(0x20000, "z80ne", 0)
- ROM_LOAD( "ep382.ic5", 0x14000, 0x0400, CRC(55818366) SHA1(adcac04b83c09265517b7bafbc2f5f665d751bec) )
+ ROM_REGION(0x0400, "maincpu", 0)
+ ROM_LOAD( "ep382.ic5", 0x0000, 0x0400, CRC(55818366) SHA1(adcac04b83c09265517b7bafbc2f5f665d751bec) )
ROM_END
ROM_START( z80netb )
/*
* 16k Basic
*/
- ROM_REGION(0x10000, "z80ne", 0)
+ ROM_REGION(0x4000, "maincpu", 0)
ROM_LOAD( "548-1.ic1", 0x0000, 0x0800, CRC(868cad39) SHA1(0ea8af010786a080f823a879a4211f5712d260da) )
ROM_LOAD( "548-2.ic2", 0x0800, 0x0800, CRC(ac297d99) SHA1(ccf31d3f9d02c3b68a0ee3be4984424df0e83ab0) )
ROM_LOAD( "548-3.ic3", 0x1000, 0x0800, CRC(9c1fe511) SHA1(ff5b6e49a137c2ff9cb760c39bfd85ce4b52bb7d) )
@@ -616,30 +630,29 @@ ROM_START( z80netb )
ROM_END
ROM_START( z80netf )
- ROM_REGION(0x20000, "z80ne", 0) /* 64k for code 64k for banked code */
+ ROM_REGION(0x5000, "maincpu", 0)
/* ep548 banked at 0x0000 - 0x3FFF */
- ROM_LOAD( "548-1.ic1", 0x10000, 0x0800, CRC(868cad39) SHA1(0ea8af010786a080f823a879a4211f5712d260da) )
- ROM_LOAD( "548-2.ic2", 0x10800, 0x0800, CRC(ac297d99) SHA1(ccf31d3f9d02c3b68a0ee3be4984424df0e83ab0) )
- ROM_LOAD( "548-3.ic3", 0x11000, 0x0800, CRC(9c1fe511) SHA1(ff5b6e49a137c2ff9cb760c39bfd85ce4b52bb7d) )
- ROM_LOAD( "548-4.ic4", 0x11800, 0x0800, CRC(cb5e0de3) SHA1(0beaa8927faaf61f6c3fc0ea1d3d5670f901aae3) )
- ROM_LOAD( "548-5.ic5", 0x12000, 0x0800, CRC(0bd4559c) SHA1(e736a3124819ffb43e96a8114cd188f18d538053) )
- ROM_LOAD( "548-6.ic6", 0x12800, 0x0800, CRC(6d663034) SHA1(57588be4e360658dbb313946d7a608e36c1fdd68) )
- ROM_LOAD( "548-7.ic7", 0x13000, 0x0800, CRC(0bab06c0) SHA1(d52f1519c798e91f25648e996b1db174d90ce0f5) )
- ROM_LOAD( "548-8.ic8", 0x13800, 0x0800, CRC(f381b594) SHA1(2de7a8941ba48d463974c73d62e994d3cbe2868d) )
-
- /* ep382 - banked at 0x0000 - 0x03FF */
- ROM_LOAD( "ep382.ic5", 0x14000, 0x0400, CRC(55818366) SHA1(adcac04b83c09265517b7bafbc2f5f665d751bec) )
-
- /* ep390 - banked at 0x0000 - 0x03FF */
- ROM_LOAD( "ep390.ic6", 0x14400, 0x0400, CRC(e4dd7de9) SHA1(523caa97112a9e67cc078c1a70ceee94ec232093) )
- /* ep1390 - banked at 0x0000 - 0x03FF */
- ROM_LOAD( "ep1390.ic6", 0x14800, 0x0400, CRC(dc2cbc1d) SHA1(e23418b8f8261a17892f3a73ec09c72bb02e1d0b) )
- /* ep2390 - banked at 0x0000 - 0x03FF */
- ROM_LOAD( "ep2390.ic6", 0x14C00, 0x0400, CRC(28d28eee) SHA1(b80f75c1ac4905ae369ecbc9b9ce120cc85502ed) )
+ ROM_LOAD( "548-1.ic1", 0x0000, 0x0800, CRC(868cad39) SHA1(0ea8af010786a080f823a879a4211f5712d260da) )
+ ROM_LOAD( "548-2.ic2", 0x0800, 0x0800, CRC(ac297d99) SHA1(ccf31d3f9d02c3b68a0ee3be4984424df0e83ab0) )
+ ROM_LOAD( "548-3.ic3", 0x1000, 0x0800, CRC(9c1fe511) SHA1(ff5b6e49a137c2ff9cb760c39bfd85ce4b52bb7d) )
+ ROM_LOAD( "548-4.ic4", 0x1800, 0x0800, CRC(cb5e0de3) SHA1(0beaa8927faaf61f6c3fc0ea1d3d5670f901aae3) )
+ ROM_LOAD( "548-5.ic5", 0x2000, 0x0800, CRC(0bd4559c) SHA1(e736a3124819ffb43e96a8114cd188f18d538053) )
+ ROM_LOAD( "548-6.ic6", 0x2800, 0x0800, CRC(6d663034) SHA1(57588be4e360658dbb313946d7a608e36c1fdd68) )
+ ROM_LOAD( "548-7.ic7", 0x3000, 0x0800, CRC(0bab06c0) SHA1(d52f1519c798e91f25648e996b1db174d90ce0f5) )
+ ROM_LOAD( "548-8.ic8", 0x3800, 0x0800, CRC(f381b594) SHA1(2de7a8941ba48d463974c73d62e994d3cbe2868d) )
+
+ /* ep382 - 8000 */
+ ROM_LOAD( "ep382.ic5", 0x4000, 0x0400, CRC(55818366) SHA1(adcac04b83c09265517b7bafbc2f5f665d751bec) )
+ /* ep390 - F000 */
+ ROM_LOAD( "ep390.ic6", 0x4400, 0x0400, CRC(e4dd7de9) SHA1(523caa97112a9e67cc078c1a70ceee94ec232093) )
+ /* ep1390 - F000 */
+ ROM_LOAD( "ep1390.ic6", 0x4800, 0x0400, CRC(dc2cbc1d) SHA1(e23418b8f8261a17892f3a73ec09c72bb02e1d0b) )
+ /* ep2390 - F000 */
+ ROM_LOAD( "ep2390.ic6", 0x4C00, 0x0400, CRC(28d28eee) SHA1(b80f75c1ac4905ae369ecbc9b9ce120cc85502ed) )
ROM_END
// YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS
-COMP( 1980, z80ne, 0, 0, z80ne, z80ne, z80ne_state, empty_init, "Nuova Elettronica", "Z80NE", MACHINE_NO_SOUND_HW)
-COMP( 1980, z80net, z80ne, 0, z80net, z80net, z80net_state, empty_init, "Nuova Elettronica", "Z80NE + LX.388", MACHINE_NO_SOUND_HW)
-COMP( 1980, z80netb, z80ne, 0, z80netb, z80net, z80netb_state, empty_init, "Nuova Elettronica", "Z80NE + LX.388 + Basic 16k", MACHINE_NO_SOUND_HW)
-COMP( 1980, z80netf, z80ne, 0, z80netf, z80netf, z80netf_state, empty_init, "Nuova Elettronica", "Z80NE + LX.388 + LX.390", MACHINE_NO_SOUND_HW)
+COMP( 1980, z80ne, 0, 0, z80ne, z80ne, z80ne_state, init_z80ne, "Nuova Elettronica", "Z80NE", MACHINE_NO_SOUND_HW | MACHINE_SUPPORTS_SAVE )
+COMP( 1980, z80net, z80ne, 0, z80net, z80net, z80net_state, init_z80ne, "Nuova Elettronica", "Z80NE + LX.388", MACHINE_NO_SOUND_HW | MACHINE_SUPPORTS_SAVE )
+COMP( 1980, z80netb, z80ne, 0, z80netb, z80net, z80netb_state, init_z80ne, "Nuova Elettronica", "Z80NE + LX.388 + Basic 16k", MACHINE_NO_SOUND_HW | MACHINE_SUPPORTS_SAVE )
+COMP( 1980, z80netf, z80ne, 0, z80netf, z80netf, z80netf_state, empty_init, "Nuova Elettronica", "Z80NE + LX.388 + LX.390", MACHINE_NO_SOUND_HW | MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/includes/cinemat.h b/src/mame/includes/cinemat.h
index 450c3cd2939..c9e3c28ab3f 100644
--- a/src/mame/includes/cinemat.h
+++ b/src/mame/includes/cinemat.h
@@ -31,12 +31,18 @@ public:
, m_rambase(*this, "rambase")
, m_inputs(*this, "INPUTS")
, m_switches(*this, "SWITCHES")
- , m_gear_input(*this, "GEAR")
, m_wheel(*this, "WHEEL")
, m_analog_x(*this, "ANALOGX")
, m_analog_y(*this, "ANALOGY")
, m_led(*this, "led")
, m_pressed(*this, "pressed%u", 0U)
+ , m_coin_detected(0)
+ , m_coin_last_reset(0)
+ , m_mux_select(0)
+ , m_gear(0)
+ , m_vector_color(255, 255, 255)
+ , m_lastx(0)
+ , m_lasty(0)
{ }
required_device<ccpu_cpu_device> m_maincpu;
@@ -44,11 +50,10 @@ public:
required_device<ls259_device> m_outlatch;
required_device<vector_device> m_vector;
required_device<screen_device> m_screen;
- optional_shared_ptr<uint16_t> m_rambase;
+ optional_shared_ptr<s16> m_rambase;
required_ioport m_inputs;
required_ioport m_switches;
- optional_ioport m_gear_input;
optional_ioport m_wheel;
optional_ioport m_analog_x;
optional_ioport m_analog_y;
@@ -56,27 +61,27 @@ public:
output_finder<> m_led;
output_finder<10> m_pressed;
- uint8_t m_coin_detected;
- uint8_t m_coin_last_reset;
- uint8_t m_mux_select;
- int m_gear;
+ u8 m_coin_detected;
+ u8 m_coin_last_reset;
+ u8 m_mux_select;
+ u8 m_gear;
rgb_t m_vector_color;
- int16_t m_lastx;
- int16_t m_lasty;
- uint8_t inputs_r(offs_t offset);
- uint8_t switches_r(offs_t offset);
- uint8_t coin_input_r();
+ s16 m_lastx;
+ s16 m_lasty;
+ u8 inputs_r(offs_t offset);
+ u8 switches_r(offs_t offset);
+ u8 coin_input_r();
WRITE_LINE_MEMBER(coin_reset_w);
WRITE_LINE_MEMBER(mux_select_w);
- uint8_t speedfrk_wheel_r(offs_t offset);
- uint8_t speedfrk_gear_r(offs_t offset);
+ u8 speedfrk_wheel_r(offs_t offset);
+ u8 speedfrk_gear_r(offs_t offset);
virtual DECLARE_WRITE_LINE_MEMBER(vector_control_w);
- uint8_t joystick_read();
+ u8 joystick_read();
DECLARE_INPUT_CHANGED_MEMBER(coin_inserted);
void init_speedfrk();
- uint32_t screen_update_cinemat(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
- uint32_t screen_update_spacewar(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
- void cinemat_vector_callback(int16_t sx, int16_t sy, int16_t ex, int16_t ey, uint8_t shift);
+ u32 screen_update_cinemat(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ u32 screen_update_spacewar(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ void cinemat_vector_callback(s16 sx, s16 sy, s16 ex, s16 ey, u8 shift);
void ripoff(machine_config &config);
void wotw(machine_config &config);
void speedfrk(machine_config &config);
@@ -88,6 +93,18 @@ public:
void barrier(machine_config &config);
void armora(machine_config &config);
+ template<int _N>
+ DECLARE_WRITE_LINE_MEMBER(speedfrk_gear_change_w)
+ {
+ if (state)
+ m_gear = _N;
+ }
+
+ ioport_value speedfrk_gear_number_r()
+ {
+ return m_gear;
+ }
+
protected:
virtual void machine_start() override;
virtual void machine_reset() override;
@@ -121,7 +138,7 @@ public:
protected:
virtual DECLARE_WRITE_LINE_MEMBER(vector_control_w) override;
- uint8_t sundance_inputs_r(offs_t offset);
+ u8 sundance_inputs_r(offs_t offset);
};
@@ -151,7 +168,7 @@ public:
protected:
virtual DECLARE_WRITE_LINE_MEMBER(vector_control_w) override;
- uint8_t boxingb_dial_r(offs_t offset);
+ u8 boxingb_dial_r(offs_t offset);
};
@@ -165,10 +182,10 @@ public:
protected:
TIMER_CALLBACK_MEMBER(synced_sound_w);
DECLARE_WRITE_LINE_MEMBER(demon_sound4_w);
- uint8_t sound_porta_r();
- uint8_t sound_portb_r();
- void sound_portb_w(uint8_t data);
- void sound_output_w(uint8_t data);
+ u8 sound_porta_r();
+ u8 sound_portb_r();
+ void sound_portb_w(u8 data);
+ void sound_output_w(u8 data);
virtual void sound_start() override;
virtual void sound_reset() override;
@@ -179,10 +196,10 @@ protected:
void demon_sound_ports(address_map &map);
private:
- uint8_t m_sound_fifo[16];
- uint8_t m_sound_fifo_in;
- uint8_t m_sound_fifo_out;
- uint8_t m_last_portb_write;
+ u8 m_sound_fifo[16];
+ u8 m_sound_fifo_in;
+ u8 m_sound_fifo_out;
+ u8 m_last_portb_write;
};
@@ -197,9 +214,9 @@ public:
protected:
virtual DECLARE_WRITE_LINE_MEMBER(vector_control_w) override;
- uint8_t qb3_frame_r();
- void qb3_ram_bank_w(uint8_t data);
- void qb3_sound_fifo_w(uint8_t data);
+ u8 qb3_frame_r();
+ void qb3_ram_bank_w(u8 data);
+ void qb3_sound_fifo_w(u8 data);
virtual void sound_reset() override;
diff --git a/src/mame/includes/dai.h b/src/mame/includes/dai.h
index ac99048d192..56b8612cf60 100644
--- a/src/mame/includes/dai.h
+++ b/src/mame/includes/dai.h
@@ -13,7 +13,6 @@
#include "audio/dai_snd.h"
#include "machine/i8255.h"
#include "machine/pit8253.h"
-#include "machine/ram.h"
#include "machine/tms5501.h"
#include "imagedev/cassette.h"
#include "emupal.h"
@@ -22,15 +21,17 @@
class dai_state : public driver_device
{
public:
- dai_state(const machine_config &mconfig, device_type type, const char *tag) :
- driver_device(mconfig, type, tag),
- m_maincpu(*this, "maincpu"),
- m_pit(*this, "pit8253"),
- m_tms5501(*this, "tms5501"),
- m_sound(*this, "custom"),
- m_cassette(*this, "cassette"),
- m_ram(*this, RAM_TAG),
- m_palette(*this, "palette")
+ dai_state(const machine_config &mconfig, device_type type, const char *tag)
+ : driver_device(mconfig, type, tag)
+ , m_maincpu(*this, "maincpu")
+ , m_pit(*this, "pit")
+ , m_tms5501(*this, "tms5501")
+ , m_sound(*this, "custom")
+ , m_cassette(*this, "cassette")
+ , m_rom(*this, "maincpu")
+ , m_ram(*this, "mainram")
+ , m_palette(*this, "palette")
+ , m_io_keyboard(*this, "IN%u", 0U)
{ }
void dai(machine_config &config);
@@ -38,46 +39,45 @@ public:
private:
enum
{
- TIMER_BOOTSTRAP,
TIMER_TMS5501
};
- required_device<cpu_device> m_maincpu;
- required_device<pit8253_device> m_pit;
- required_device<tms5501_device> m_tms5501;
- required_device<dai_sound_device> m_sound;
- required_device<cassette_image_device> m_cassette;
- required_device<ram_device> m_ram;
- required_device<palette_device> m_palette;
-
- uint8_t m_paddle_select;
- uint8_t m_paddle_enable;
- uint8_t m_cassette_motor[2];
- uint8_t m_keyboard_scan_mask;
- unsigned short m_4_colours_palette[4];
- void dai_stack_interrupt_circuit_w(uint8_t data);
- uint8_t dai_io_discrete_devices_r(offs_t offset);
- void dai_io_discrete_devices_w(offs_t offset, uint8_t data);
- uint8_t dai_amd9511_r();
- void dai_amd9511_w(offs_t offset, uint8_t data);
- uint8_t dai_pit_r(offs_t offset);
- void dai_pit_w(offs_t offset, uint8_t data);
- uint8_t dai_keyboard_r();
- void dai_keyboard_w(uint8_t data);
+ u8 m_paddle_select;
+ u8 m_paddle_enable;
+ u8 m_cassette_motor[2];
+ u8 m_keyboard_scan_mask;
+ u8 m_4_colours_palette[4];
+ void stack_interrupt_circuit_w(u8 data);
+ u8 io_discrete_devices_r(offs_t offset);
+ void io_discrete_devices_w(offs_t offset, u8 data);
+ u8 amd9511_r();
+ void amd9511_w(offs_t offset, u8 data);
+ u8 pit_r(offs_t offset);
+ void pit_w(offs_t offset, u8 data);
+ u8 keyboard_r();
+ void keyboard_w(u8 data);
void dai_palette(palette_device &palette) const;
- uint32_t screen_update_dai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
- void dai_update_memory(int dai_rom_bank);
+ u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
IRQ_CALLBACK_MEMBER(int_ack);
- void dai_io(address_map &map);
- void dai_mem(address_map &map);
+ void mem_map(address_map &map);
static const rgb_t s_palette[16];
-protected:
virtual void machine_start() override;
virtual void machine_reset() override;
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
+
+ memory_passthrough_handler *m_rom_shadow_tap;
+ required_device<cpu_device> m_maincpu;
+ required_device<pit8253_device> m_pit;
+ required_device<tms5501_device> m_tms5501;
+ required_device<dai_sound_device> m_sound;
+ required_device<cassette_image_device> m_cassette;
+ required_region_ptr<u8> m_rom;
+ required_shared_ptr<u8> m_ram;
+ required_device<palette_device> m_palette;
+ required_ioport_array<9> m_io_keyboard;
};
diff --git a/src/mame/includes/funworld.h b/src/mame/includes/funworld.h
index 25d31af0b12..a4a7dffa4fb 100644
--- a/src/mame/includes/funworld.h
+++ b/src/mame/includes/funworld.h
@@ -35,6 +35,7 @@ public:
void witchryl(machine_config &config);
void fw_brick_1(machine_config &config);
void fw_brick_2(machine_config &config);
+ void gratispk(machine_config &config);
void init_saloon();
void init_mongolnw();
@@ -76,6 +77,7 @@ private:
void fw_brick_map(address_map &map);
void saloon_map(address_map &map);
void witchryl_map(address_map &map);
+ void gratispk_map(address_map &map);
required_shared_ptr<uint8_t> m_videoram;
required_shared_ptr<uint8_t> m_colorram;
diff --git a/src/mame/includes/hec2hrp.h b/src/mame/includes/hec2hrp.h
index bb4f8afb51c..3d99dac37df 100644
--- a/src/mame/includes/hec2hrp.h
+++ b/src/mame/includes/hec2hrp.h
@@ -3,41 +3,7 @@
/////////////////////////////////////////////////////////////////////
////// HECTOR HEADER FILE /////////////////////////////////////////
/////////////////////////////////////////////////////////////////////
-/*
- Hector 2HR+
- Victor
- Hector 2HR
- Hector HRX
- Hector MX40c
- Hector MX80c
- Hector 1
- Interact
-
- 12/05/2009 Skeleton driver - Micko : mmicko@gmail.com
- 31/06/2009 Video - Robbbert
-
- 29/10/2009 Update skeleton to functional machine
- by yo_fr (jj.stac @ aliceadsl.fr)
-
- => add Keyboard,
- => add color,
- => add cassette,
- => add sn76477 sound and 1bit sound,
- => add joysticks (stick, pot, fire)
- => add BR/HR switching
- => add bank switch for HRX
- => add device MX80c and bank switching for the ROM
- 03/01/2010 Update and clean prog by yo_fr (jj.stac@aliceadsl.fr)
- => add the port mapping for keyboard
- 20/11/2010 : synchronization between uPD765 and Z80 are now OK, CP/M running! JJStacino
- 11/11/2011 : add the minidisque support -3 pouces 1/2 driver- JJStacino (jj.stac @ aliceadsl.fr)
-
- don't forget to keep some information about these machine see DChector project : http://dchector.free.fr/ made by DanielCoulom
- (and thank's to Daniel!) and Yves site : http://hectorvictor.free.fr/ (thank's too Yves!)
-
- TODO : Add the cartridge function,
- Adjust the one shot and A/D timing (sn76477)
-*/
+
#ifndef MAME_INCLUDES_HEC2HRP_H
#define MAME_INCLUDES_HEC2HRP_H
@@ -48,6 +14,7 @@
#include "imagedev/printer.h"
#include "machine/upd765.h"
#include "machine/wd_fdc.h"
+#include "machine/ram.h"
#include "sound/discrete.h" /* for 1 Bit sound*/
#include "sound/sn76477.h" /* for sn sound*/
#include "emupal.h"
@@ -82,21 +49,24 @@ class hec2hrp_state : public driver_device
{
public:
hec2hrp_state(const machine_config &mconfig, device_type type, const char *tag)
- : driver_device(mconfig, type, tag),
- m_maincpu(*this, "maincpu"),
- m_cassette(*this, "cassette"),
- m_printer(*this, "printer"),
- m_palette(*this, "palette"),
- m_disc2cpu(*this, "disc2cpu"),
- m_discrete(*this, "discrete"),
- m_sn(*this, "sn76477"),
- m_videoram(*this,"videoram"),
- m_hector_videoram(*this,"hector_videoram") ,
- m_keyboard(*this, "KEY.%u", 0),
- m_minidisc_fdc(*this, "wd179x"),
- m_floppy0(*this, "wd179x:0"),
- m_upd_fdc(*this, "upd765"),
- m_upd_connector(*this, "upd765:%u", 0U)
+ : driver_device(mconfig, type, tag)
+ , m_maincpu(*this, "maincpu")
+ , m_cassette(*this, "cassette")
+ , m_printer(*this, "printer")
+ , m_palette(*this, "palette")
+ , m_vram(*this,"videoram")
+ , m_bank(*this, "bank%u", 0U)
+ , m_rom(*this, "maincpu")
+ , m_ram(*this, RAM_TAG)
+ , m_hector_vram(*this,"hector_videoram")
+ , m_disc2cpu(*this, "disc2cpu")
+ , m_discrete(*this, "discrete")
+ , m_sn(*this, "sn76477")
+ , m_keyboard(*this, "KEY.%u", 0)
+ , m_minidisc_fdc(*this, "wd179x")
+ , m_floppy0(*this, "wd179x:0")
+ , m_upd_fdc(*this, "upd765")
+ , m_upd_connector(*this, "upd765:%u", 0U)
{}
void hec2mx80(machine_config &config);
@@ -107,13 +77,19 @@ public:
void hec2hr(machine_config &config);
void hector_audio(machine_config &config);
- void hector_init();
+ void init_mx40();
+ void init_mdhrx();
+ void init_victor();
+ void init_hrx();
+ void init_interact();
+ void hector1(machine_config &config);
+ void interact(machine_config &config);
+ void interact_common(machine_config &config);
-protected:
- DECLARE_VIDEO_START(hec2hrp);
+private:
void hector_hr(bitmap_ind16 &bitmap, uint8_t *page, int ymax, int yram);
- void hector_reset(int hr, int with_d2);
-
+ void hector_reset(bool hr, bool with_d2);
+ void video_start() override;
void keyboard_w(uint8_t data);
uint8_t keyboard_r(offs_t offset);
void sn_2000_w(offs_t offset, uint8_t data);
@@ -122,15 +98,13 @@ protected:
void sn_3000_w(uint8_t data);
void color_a_w(uint8_t data);
void color_b_w(uint8_t data);
-
- required_device<cpu_device> m_maincpu;
- required_device<cassette_image_device> m_cassette;
- optional_device<printer_image_device> m_printer;
- required_device<palette_device> m_palette;
-
-private:
+ bool m_has_disc2;
+ bool m_has_minidisc;
+ bool m_is_hr;
+ bool m_is_extended;
+ void init_palette(palette_device &);
+ void hector_init();
void minidisc_control_w(uint8_t data);
-
void switch_bank_w(offs_t offset, uint8_t data);
uint8_t io_8255_r(offs_t offset);
void io_8255_w(offs_t offset, uint8_t data);
@@ -151,37 +125,24 @@ private:
DECLARE_FLOPPY_FORMATS(minidisc_formats);
- optional_device<cpu_device> m_disc2cpu;
- required_device<discrete_device> m_discrete;
- required_device<sn76477_device> m_sn;
- optional_shared_ptr<uint8_t> m_videoram;
- optional_shared_ptr<uint8_t> m_hector_videoram;
- required_ioport_array<9> m_keyboard;
-
- optional_device<fd1793_device> m_minidisc_fdc;
- optional_device<floppy_connector> m_floppy0;
-
- optional_device<upd765a_device> m_upd_fdc;
- optional_device_array<floppy_connector, 2> m_upd_connector;
-
- uint8_t m_hector_flag_hr;
- uint8_t m_hector_flag_80c;
+ bool m_hector_flag_hr;
+ bool m_hector_flag_80c;
uint8_t m_hector_color[4];
uint8_t m_hector_disc2_data_r_ready;
uint8_t m_hector_disc2_data_w_ready;
uint8_t m_hector_disc2_data_read;
uint8_t m_hector_disc2_data_write;
- uint8_t m_hector_disc2_rnmi;
+ bool m_hector_disc2_rnmi;
uint8_t m_state3000;
- uint8_t m_write_cassette;
+ bool m_write_cassette;
emu_timer *m_cassette_timer;
uint8_t m_ck_signal;
- uint8_t m_flag_clk;
+ bool m_flag_clk;
double m_pin_value[29][2];
- int m_au[17];
- int m_val_mixer;
- int m_oldstate3000;
- int m_oldstate1000;
+ u8 m_au[17];
+ u8 m_val_mixer;
+ u8 m_oldstate3000;
+ u8 m_oldstate1000;
uint8_t m_pot0;
uint8_t m_pot1;
uint8_t m_actions;
@@ -190,18 +151,15 @@ private:
uint8_t m_hector_port_c_h;
uint8_t m_hector_port_c_l;
uint8_t m_hector_port_cmd;
- uint8_t m_cassette_bit;
- uint8_t m_cassette_bit_mem;
+ bool m_cassette_bit;
+ bool m_cassette_bit_mem;
uint8_t m_data_k7;
int m_counter_write;
- int m_irq_current_state;
- int m_nmi_current_state;
- int m_hector_cmd[10];
- int m_hector_nb_cde;
- int m_hector_flag_result;
- int m_print;
- uint8_t m_hector_videoram_hrx[0x04000];
+ bool m_irq_current_state;
+ bool m_nmi_current_state;
+ uint8_t m_hector_videoram_hrx[0x4000];
+ DECLARE_MACHINE_RESET(interact);
DECLARE_MACHINE_START(hec2hrp);
DECLARE_MACHINE_RESET(hec2hrp);
DECLARE_MACHINE_START(hec2hrx);
@@ -213,18 +171,14 @@ private:
DECLARE_WRITE_LINE_MEMBER( disc2_fdc_interrupt );
DECLARE_WRITE_LINE_MEMBER( disc2_fdc_dma_irq );
- int has_disc2();
- int has_minidisc();
- int is_hr();
- int is_extended();
+
void update_state(int Adresse, int Value );
void init_sn76477();
void update_sound(uint8_t data);
- void init_palette();
void hector_80c(bitmap_ind16 &bitmap, uint8_t *page, int ymax, int yram);
- /*----------- defined in machine/hecdisk2.c -----------*/
-
void hector_disc2_reset();
+ uint32_t screen_update_interact(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ void interact_mem(address_map &map);
void hec2hrp_io(address_map &map);
void hec2hrp_mem(address_map &map);
@@ -235,6 +189,24 @@ private:
void hec2mx80_io(address_map &map);
void hecdisc2_io(address_map &map);
void hecdisc2_mem(address_map &map);
+
+ required_device<cpu_device> m_maincpu;
+ required_device<cassette_image_device> m_cassette;
+ optional_device<printer_image_device> m_printer;
+ required_device<palette_device> m_palette;
+ optional_shared_ptr<uint8_t> m_vram;
+ optional_memory_bank_array<4> m_bank;
+ required_region_ptr<u8> m_rom;
+ optional_device<ram_device> m_ram;
+ optional_shared_ptr<uint8_t> m_hector_vram;
+ optional_device<cpu_device> m_disc2cpu;
+ required_device<discrete_device> m_discrete;
+ required_device<sn76477_device> m_sn;
+ required_ioport_array<9> m_keyboard;
+ optional_device<fd1793_device> m_minidisc_fdc;
+ optional_device<floppy_connector> m_floppy0;
+ optional_device<upd765a_device> m_upd_fdc;
+ optional_device_array<floppy_connector, 2> m_upd_connector;
};
#endif // MAME_INCLUDES_HEC2HRP_H
diff --git a/src/mame/includes/lviv.h b/src/mame/includes/lviv.h
index 904b1782870..4e42ed307fe 100644
--- a/src/mame/includes/lviv.h
+++ b/src/mame/includes/lviv.h
@@ -41,7 +41,8 @@ public:
DECLARE_INPUT_CHANGED_MEMBER(reset_button);
private:
- virtual void machine_reset() override;
+ void machine_reset() override;
+ void machine_start() override;
void lviv_palette(palette_device &palette) const;
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
@@ -49,19 +50,19 @@ private:
uint8_t io_r(offs_t offset);
void io_w(offs_t offset, uint8_t data);
- uint8_t ppi_0_porta_r();
- uint8_t ppi_0_portb_r();
- uint8_t ppi_0_portc_r();
- uint8_t ppi_1_porta_r();
- uint8_t ppi_1_portb_r();
- uint8_t ppi_1_portc_r();
+ uint8_t ppi0_porta_r();
+ uint8_t ppi0_portb_r();
+ uint8_t ppi0_portc_r();
+ uint8_t ppi1_porta_r();
+ uint8_t ppi1_portb_r();
+ uint8_t ppi1_portc_r();
- void ppi_0_porta_w(uint8_t data);
- void ppi_0_portb_w(uint8_t data);
- void ppi_0_portc_w(uint8_t data);
- void ppi_1_porta_w(uint8_t data);
- void ppi_1_portb_w(uint8_t data);
- void ppi_1_portc_w(uint8_t data);
+ void ppi0_porta_w(uint8_t data);
+ void ppi0_portb_w(uint8_t data);
+ void ppi0_portc_w(uint8_t data);
+ void ppi1_porta_w(uint8_t data);
+ void ppi1_portb_w(uint8_t data);
+ void ppi1_portc_w(uint8_t data);
DECLARE_SNAPSHOT_LOAD_MEMBER(snapshot_cb);
@@ -87,7 +88,7 @@ private:
required_ioport_array<12> m_key;
required_ioport m_joy_port;
- uint8_t* m_video_ram;
+ uint8_t* m_vram;
uint16_t m_colortable[1][4];
uint8_t m_ppi_port_outputs[2][3];
uint8_t m_startup_mem_map;
diff --git a/src/mame/includes/megadriv_acbl.h b/src/mame/includes/megadriv_acbl.h
index 12e7a95dc7e..115477423b1 100644
--- a/src/mame/includes/megadriv_acbl.h
+++ b/src/mame/includes/megadriv_acbl.h
@@ -24,6 +24,7 @@ public:
void init_topshoot();
void init_puckpkmn();
void init_hshavoc();
+ void init_barek2();
void init_barek3();
void init_sonic2mb();
void init_twinktmb();
@@ -34,6 +35,7 @@ private:
uint16_t bl_710000_r();
void aladmdb_w(uint16_t data);
uint16_t aladmdb_r();
+ uint16_t barek2mb_r();
uint16_t jparkmb_r();
uint16_t twinktmb_r();
uint16_t mk3mdb_dsw_r(offs_t offset);
diff --git a/src/mame/includes/model3.h b/src/mame/includes/model3.h
index 70ad7882468..4559d008227 100644
--- a/src/mame/includes/model3.h
+++ b/src/mame/includes/model3.h
@@ -104,6 +104,7 @@ public:
void model3_20(machine_config &config);
void model3_21(machine_config &config);
+ void getbass(machine_config &config);
void scud(machine_config &config);
void lostwsga(machine_config &config);
@@ -382,6 +383,8 @@ private:
void model3_snd(address_map &map);
void scsp1_map(address_map &map);
void scsp2_map(address_map &map);
+ void getbass_iocpu_mem(address_map &map);
+ void getbass_iocpu_io(address_map &map);
};
#endif // MAME_INCLUDES_MODEL3_H
diff --git a/src/mame/includes/mpu4.h b/src/mame/includes/mpu4.h
index 69694712bfe..92be9cf5cc3 100644
--- a/src/mame/includes/mpu4.h
+++ b/src/mame/includes/mpu4.h
@@ -14,6 +14,9 @@
#include "machine/steppers.h"
#include "machine/roc10937.h"
#include "machine/meters.h"
+
+#include "machine/bacta_datalogger.h"
+
#include "emupal.h"
@@ -113,6 +116,7 @@ public:
, m_pia6(*this, "pia_ic6")
, m_pia7(*this, "pia_ic7")
, m_pia8(*this, "pia_ic8")
+ , m_pia_ic4ss(*this, "pia_ic4ss")
, m_port_mux(*this, {"ORANGE1", "ORANGE2", "BLACK1", "BLACK2", "ORANGE1", "ORANGE2", "DIL1", "DIL2"})
, m_aux1_port(*this, "AUX1")
, m_aux2_port(*this, "AUX2")
@@ -123,6 +127,7 @@ public:
, m_meters(*this, "meters")
, m_ym2413(*this, "ym2413")
, m_ay8913(*this, "ay8913")
+ , m_dataport(*this, "dataport")
, m_lamps(*this, "lamp%u", 0U)
, m_mpu4leds(*this, "mpu4led%u", 0U)
, m_digits(*this, "digit%u", 0U)
@@ -311,6 +316,8 @@ protected:
DECLARE_WRITE_LINE_MEMBER(pia_gb_ca2_w);
DECLARE_WRITE_LINE_MEMBER(pia_gb_cb2_w);
+ DECLARE_WRITE_LINE_MEMBER(dataport_rxd);
+
required_device<cpu_device> m_maincpu;
optional_device<rocvfd_device> m_vfd;
optional_device<ptm6840_device> m_6840ptm;
@@ -321,6 +328,7 @@ protected:
optional_device<pia6821_device> m_pia6;
optional_device<pia6821_device> m_pia7;
optional_device<pia6821_device> m_pia8;
+ optional_device<pia6821_device> m_pia_ic4ss;
required_ioport_array<8> m_port_mux;
required_ioport m_aux1_port;
required_ioport m_aux2_port;
@@ -331,6 +339,7 @@ protected:
required_device<meters_device> m_meters;
optional_device<ym2413_device> m_ym2413;
optional_device<ay8913_device> m_ay8913;
+ optional_device<bacta_datalogger_device> m_dataport;
// not all systems have this many lamps/LEDs/digits but the driver is too much of a mess to split up now
diff --git a/src/mame/includes/qix.h b/src/mame/includes/qix.h
index 7ba49a2d8c8..cc4e9bbba41 100644
--- a/src/mame/includes/qix.h
+++ b/src/mame/includes/qix.h
@@ -168,6 +168,8 @@ public:
protected:
virtual void machine_start() override;
+ optional_device<m68705p_device> m_mcu;
+
private:
uint8_t coin_r();
void coin_w(uint8_t data);
@@ -178,8 +180,6 @@ private:
void mcu_porta_w(uint8_t data);
void mcu_portb_w(uint8_t data);
- required_device<m68705p_device> m_mcu;
-
/* machine state */
uint8_t m_68705_porta_out;
uint8_t m_coinctrl;
@@ -194,6 +194,7 @@ public:
{ }
void zookeep(machine_config &config);
+ void zookeepbl(machine_config &config);
void video(machine_config &config);
protected:
diff --git a/src/mame/includes/spg2xx.h b/src/mame/includes/spg2xx.h
index 9f4f562e6fd..8437dbb9d48 100644
--- a/src/mame/includes/spg2xx.h
+++ b/src/mame/includes/spg2xx.h
@@ -275,4 +275,43 @@ private:
};
+
+class spg2xx_game_wfcentro_state : public spg2xx_game_state
+{
+public:
+ spg2xx_game_wfcentro_state(const machine_config &mconfig, device_type type, const char *tag) :
+ spg2xx_game_state(mconfig, type, tag)
+ { }
+
+ void wfcentro(machine_config &config);
+
+protected:
+// virtual void machine_start() override;
+// virtual void machine_reset() override;
+
+// virtual void portc_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override;
+
+private:
+
+ void mem_map_wfcentro(address_map& map);
+};
+
+class spg2xx_game_ordentv_state : public spg2xx_game_state
+{
+public:
+ spg2xx_game_ordentv_state(const machine_config &mconfig, device_type type, const char *tag) :
+ spg2xx_game_state(mconfig, type, tag)
+ { }
+
+ void ordentv(machine_config &config);
+
+ void init_ordentv();
+
+protected:
+
+ uint16_t ordentv_portc_r(offs_t offset, uint16_t mem_mask = ~0);
+private:
+};
+
+
#endif // MAME_INCLUDES_SPG2XX_H
diff --git a/src/mame/includes/starcrus.h b/src/mame/includes/starcrus.h
index 1677d19d9e5..c7be0638750 100644
--- a/src/mame/includes/starcrus.h
+++ b/src/mame/includes/starcrus.h
@@ -1,12 +1,14 @@
// license:BSD-3-Clause
-// copyright-holders:Frank Palazzolo
+// copyright-holders:Frank Palazzolo, Ryan Holtz
#ifndef MAME_INCLUDES_STARCRUS_H
#define MAME_INCLUDES_STARCRUS_H
#pragma once
-#include "sound/samples.h"
#include "emupal.h"
+#include "machine/netlist.h"
+#include "netlist/nl_setup.h"
+#include "audio/nl_starcrus.h"
class starcrus_state : public driver_device
{
@@ -14,10 +16,12 @@ public:
starcrus_state(const machine_config &mconfig, device_type type, const char *tag) :
driver_device(mconfig, type, tag) ,
m_maincpu(*this, "maincpu"),
- m_samples(*this, "samples"),
m_gfxdecode(*this, "gfxdecode"),
m_palette(*this, "palette"),
- m_led(*this, "led2")
+ m_led(*this, "led2"),
+ m_explode(*this, "sound_nl:explode%u", 1U),
+ m_launch(*this, "sound_nl:launch%u", 1U),
+ m_engine(*this, "sound_nl:engine%u", 1U)
{ }
void starcrus(machine_config &config);
@@ -41,7 +45,6 @@ private:
virtual void video_start() override;
required_device<cpu_device> m_maincpu;
- required_device<samples_device> m_samples;
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
@@ -66,20 +69,8 @@ private:
int m_s1_sprite;
int m_s2_sprite;
- int m_engine1_on;
- int m_engine2_on;
- int m_explode1_on;
- int m_explode2_on;
- int m_launch1_on;
- int m_launch2_on;
-
int m_collision_reg;
- int m_engine_sound_playing;
- int m_explode_sound_playing;
- int m_launch1_sound_playing;
- int m_launch2_sound_playing;
-
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
int collision_check_s1s2();
int collision_check_p1p2();
@@ -88,6 +79,10 @@ private:
void starcrus_io_map(address_map &map);
void starcrus_map(address_map &map);
+
+ required_device_array<netlist_mame_logic_input_device, 2> m_explode;
+ required_device_array<netlist_mame_logic_input_device, 2> m_launch;
+ required_device_array<netlist_mame_logic_input_device, 2> m_engine;
};
#endif // MAME_INCLUDES_STARCRUS_H
diff --git a/src/mame/includes/tankbatt.h b/src/mame/includes/tankbatt.h
index 2dcb5d2b8f6..c27436328e4 100644
--- a/src/mame/includes/tankbatt.h
+++ b/src/mame/includes/tankbatt.h
@@ -5,7 +5,12 @@
#pragma once
-#include "sound/samples.h"
+#include "machine/timer.h"
+#include "machine/netlist.h"
+
+#include "netlist/nl_setup.h"
+#include "audio/nl_tankbatt.h"
+
#include "emupal.h"
#include "tilemap.h"
@@ -15,44 +20,52 @@ public:
tankbatt_state(const machine_config &mconfig, device_type type, const char *tag) :
driver_device(mconfig, type, tag),
m_maincpu(*this, "maincpu"),
- m_samples(*this, "samples"),
m_gfxdecode(*this, "gfxdecode"),
m_palette(*this, "palette"),
m_bulletsram(*this, "bulletsram"),
- m_videoram(*this, "videoram")
+ m_videoram(*this, "videoram"),
+ m_player_input(*this, "P%u", 1U),
+ m_dips(*this, "DSW"),
+ m_sound_s1(*this, "sound_nl:s1"),
+ m_sound_s2(*this, "sound_nl:s2"),
+ m_sound_off(*this, "sound_nl:off"),
+ m_sound_engine_hi(*this, "sound_nl:engine_hi"),
+ m_sound_shoot(*this, "sound_nl:shoot"),
+ m_sound_hit(*this, "sound_nl:hit")
{ }
void tankbatt(machine_config &config);
- DECLARE_INPUT_CHANGED_MEMBER(coin_inserted);
-
private:
required_device<cpu_device> m_maincpu;
- required_device<samples_device> m_samples;
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
required_shared_ptr<uint8_t> m_bulletsram;
required_shared_ptr<uint8_t> m_videoram;
- int m_nmi_enable;
+ required_ioport_array<2> m_player_input;
+ required_ioport m_dips;
+
+ required_device<netlist_mame_logic_input_device> m_sound_s1;
+ required_device<netlist_mame_logic_input_device> m_sound_s2;
+ required_device<netlist_mame_logic_input_device> m_sound_off;
+ required_device<netlist_mame_logic_input_device> m_sound_engine_hi;
+ required_device<netlist_mame_logic_input_device> m_sound_shoot;
+ required_device<netlist_mame_logic_input_device> m_sound_hit;
+
int m_sound_enable;
tilemap_t *m_bg_tilemap;
uint8_t in0_r(offs_t offset);
uint8_t in1_r(offs_t offset);
uint8_t dsw_r(offs_t offset);
- DECLARE_WRITE_LINE_MEMBER(interrupt_enable_w);
- DECLARE_WRITE_LINE_MEMBER(demo_interrupt_enable_w);
- DECLARE_WRITE_LINE_MEMBER(sh_expl_w);
- DECLARE_WRITE_LINE_MEMBER(sh_engine_w);
- DECLARE_WRITE_LINE_MEMBER(sh_fire_w);
- void irq_ack_w(uint8_t data);
- DECLARE_WRITE_LINE_MEMBER(coincounter_w);
- DECLARE_WRITE_LINE_MEMBER(coinlockout_w);
+ void intack_w(uint8_t data);
+ void coincounter_w(int state);
+ void coinlockout_w(int state);
void videoram_w(offs_t offset, uint8_t data);
- INTERRUPT_GEN_MEMBER(interrupt);
+ TIMER_DEVICE_CALLBACK_MEMBER(scanline_interrupt);
TILE_GET_INFO_MEMBER(get_bg_tile_info);
diff --git a/src/mame/includes/xavix.h b/src/mame/includes/xavix.h
index e6b869dc537..f6ddc11e8e3 100644
--- a/src/mame/includes/xavix.h
+++ b/src/mame/includes/xavix.h
@@ -24,6 +24,12 @@
#include "machine/xavix_anport.h"
#include "machine/xavix_math.h"
+// NTSC clock for regular XaviX?
+#define MAIN_CLOCK XTAL(21'477'272)
+// some games (eg Radica Opus) run off a 3.579545MHz XTAL ( same as the above /6 ) so presumably there is a divider / multiplier circuit on some PCBs?
+// TODO: what's the PAL clock?
+
+
class xavix_sound_device : public device_t, public device_sound_interface
{
public:
@@ -596,26 +602,6 @@ private:
};
-class xavix_2000_nv_sdb_state : public xavix_state
-{
-public:
- xavix_2000_nv_sdb_state(const machine_config &mconfig, device_type type, const char *tag)
- : xavix_state(mconfig, type, tag)
- { }
-
- void xavix2000_nv_sdb(machine_config &config);
-
-protected:
-
-private:
- uint8_t sdb_anport0_r() { return m_mouse0x->read()^0x7f; }
- uint8_t sdb_anport1_r() { return m_mouse0y->read()^0x7f; }
- uint8_t sdb_anport2_r() { return m_mouse1x->read()^0x7f; }
- uint8_t sdb_anport3_r() { return m_mouse1y->read()^0x7f; }
-
-};
-
-
class xavix_i2c_state : public xavix_state
{
public:
@@ -673,24 +659,6 @@ private:
};
-class xavix_i2c_jmat_state : public xavix_i2c_state
-{
-public:
- xavix_i2c_jmat_state(const machine_config &mconfig, device_type type, const char *tag)
- : xavix_i2c_state(mconfig, type, tag)
- { }
-
- void xavix2002_i2c_jmat(machine_config &config);
-
-private:
- uint8_t read_extended_io0();
- uint8_t read_extended_io1();
- uint8_t read_extended_io2();
- void write_extended_io0(uint8_t data);
- void write_extended_io1(uint8_t data);
- void write_extended_io2(uint8_t data);
-};
-
class xavix_i2c_lotr_state : public xavix_i2c_state
{
@@ -705,15 +673,6 @@ protected:
//virtual void write_io1(uint8_t data, uint8_t direction) override;
};
-class xavix_i2c_bowl_state : public xavix_i2c_state
-{
-public:
- xavix_i2c_bowl_state(const machine_config &mconfig, device_type type, const char *tag)
- : xavix_i2c_state(mconfig, type, tag)
- { }
-
- DECLARE_READ_LINE_MEMBER(camera_r);
-};
diff --git a/src/mame/includes/xavix_2000.h b/src/mame/includes/xavix_2000.h
new file mode 100644
index 00000000000..0611ba3149c
--- /dev/null
+++ b/src/mame/includes/xavix_2000.h
@@ -0,0 +1,27 @@
+// license:BSD-3-Clause
+// copyright-holders:David Haywood
+#ifndef MAME_INCLUDES_XAVIX_2000_H
+#define MAME_INCLUDES_XAVIX_2000_H
+
+#include "xavix.h"
+
+
+class xavix_2000_nv_sdb_state : public xavix_state
+{
+public:
+ xavix_2000_nv_sdb_state(const machine_config &mconfig, device_type type, const char *tag)
+ : xavix_state(mconfig, type, tag)
+ { }
+
+ void xavix2000_nv_sdb(machine_config &config);
+
+protected:
+
+private:
+ uint8_t sdb_anport0_r() { return m_mouse0x->read()^0x7f; }
+ uint8_t sdb_anport1_r() { return m_mouse0y->read()^0x7f; }
+ uint8_t sdb_anport2_r() { return m_mouse1x->read()^0x7f; }
+ uint8_t sdb_anport3_r() { return m_mouse1y->read()^0x7f; }
+};
+
+#endif // MAME_INCLUDES_XAVIX_2000_H
diff --git a/src/mame/includes/xavix_2002.h b/src/mame/includes/xavix_2002.h
new file mode 100644
index 00000000000..66bbfe380bb
--- /dev/null
+++ b/src/mame/includes/xavix_2002.h
@@ -0,0 +1,55 @@
+// license:BSD-3-Clause
+// copyright-holders:David Haywood
+#ifndef MAME_INCLUDES_XAVIX_2002_H
+#define MAME_INCLUDES_XAVIX_2002_H
+
+#include "xavix_2000.h"
+
+class xavix_i2c_jmat_state : public xavix_i2c_state
+{
+public:
+ xavix_i2c_jmat_state(const machine_config &mconfig, device_type type, const char *tag)
+ : xavix_i2c_state(mconfig, type, tag)
+ { }
+
+ void xavix2002_i2c_jmat(machine_config &config);
+
+private:
+ uint8_t read_extended_io0();
+ uint8_t read_extended_io1();
+ uint8_t read_extended_io2();
+ void write_extended_io0(uint8_t data);
+ void write_extended_io1(uint8_t data);
+ void write_extended_io2(uint8_t data);
+};
+
+class xavix2002_superpttv_state : public xavix_state
+{
+public:
+ xavix2002_superpttv_state(const machine_config &mconfig, device_type type, const char *tag)
+ : xavix_state(mconfig, type, tag)
+ { }
+
+ void xavix2002_superpctv(machine_config &config);
+
+private:
+ uint8_t read_extended_io0() { return 0x00; };
+ uint8_t read_extended_io1() { return 0x00; };
+ uint8_t read_extended_io2() { return 0x00; };
+ //void write_extended_io0(uint8_t data);
+ //void write_extended_io1(uint8_t data);
+ //void write_extended_io2(uint8_t data);
+};
+
+class xavix_i2c_bowl_state : public xavix_i2c_state
+{
+public:
+ xavix_i2c_bowl_state(const machine_config &mconfig, device_type type, const char *tag)
+ : xavix_i2c_state(mconfig, type, tag)
+ { }
+
+ DECLARE_READ_LINE_MEMBER(camera_r);
+};
+
+
+#endif // MAME_INCLUDES_XAVIX_2002_H
diff --git a/src/mame/includes/z80ne.h b/src/mame/includes/z80ne.h
index 4309dee6fac..52aaa567bd8 100644
--- a/src/mame/includes/z80ne.h
+++ b/src/mame/includes/z80ne.h
@@ -69,11 +69,10 @@ public:
: driver_device(mconfig, type, tag),
m_uart(*this, "uart"),
m_uart_clock(*this, "uart_clock"),
- m_maincpu(*this, "z80ne"),
+ m_maincpu(*this, "maincpu"),
m_cassette1(*this, "cassette"),
m_cassette2(*this, "cassette2"),
m_ram(*this, RAM_TAG),
- m_region_z80ne(*this, "z80ne"),
m_bank1(*this, "bank1"),
m_bank2(*this, "bank2"),
m_bank3(*this, "bank3"),
@@ -84,24 +83,24 @@ public:
m_io_rst(*this, "RST"),
m_io_lx_385(*this, "LX.385"),
m_lx383_digits(*this, "digit%u", 0U)
- {
- }
+ , m_rom(*this, "maincpu")
+ , m_mram(*this, "mainram")
+ { }
void z80ne(machine_config &config);
+ void init_z80ne();
DECLARE_INPUT_CHANGED_MEMBER(z80ne_reset);
protected:
virtual void machine_start() override;
virtual void machine_reset() override;
- virtual void driver_init() override;
void base_reset();
+ void save_state_vars();
DECLARE_FLOPPY_FORMATS(floppy_formats);
- required_device<ay31015_device> m_uart;
- required_device<clock_device> m_uart_clock;
uint8_t m_lx383_scan_counter;
uint8_t m_lx383_key[LX383_KEYS];
int m_lx383_downsampler;
@@ -121,11 +120,13 @@ protected:
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
+ memory_passthrough_handler *m_rom_shadow_tap;
+ required_device<ay31015_device> m_uart;
+ required_device<clock_device> m_uart_clock;
required_device<cpu_device> m_maincpu;
required_device<cassette_image_device> m_cassette1;
required_device<cassette_image_device> m_cassette2;
- required_device<ram_device> m_ram;
- required_memory_region m_region_z80ne;
+ optional_device<ram_device> m_ram;
optional_memory_bank m_bank1;
optional_memory_bank m_bank2;
optional_memory_bank m_bank3;
@@ -136,16 +137,16 @@ protected:
required_ioport m_io_rst;
required_ioport m_io_lx_385;
output_finder<8> m_lx383_digits;
+ required_region_ptr<u8> m_rom;
+ optional_shared_ptr<u8> m_mram;
emu_timer *m_timer_nmi;
- emu_timer *m_timer_reset;
cassette_image_device *cassette_device_image();
- void reset_lx382_banking();
private:
- void main_mem(address_map &map);
- void main_io(address_map &map);
+ void mem_map(address_map &map);
+ void io_map(address_map &map);
};
class z80net_state : public z80ne_state
@@ -168,7 +169,6 @@ public:
protected:
virtual void machine_reset() override;
- virtual void driver_init() override;
DECLARE_READ_LINE_MEMBER(lx387_shift_r);
DECLARE_READ_LINE_MEMBER(lx387_control_r);
@@ -184,10 +184,10 @@ protected:
void reset_lx387();
- void main_io(address_map &map);
+ void io_map(address_map &map);
private:
- void main_mem(address_map &map);
+ void mem_map(address_map &map);
};
class z80netb_state : public z80net_state
@@ -202,10 +202,9 @@ public:
protected:
virtual void machine_reset() override;
- virtual void driver_init() override { }
private:
- void main_mem(address_map &map);
+ void mem_map(address_map &map);
};
class z80netf_state : public z80netb_state
@@ -235,11 +234,10 @@ private:
uint8_t head; /* current head */
};
- void main_mem(address_map &map);
- void main_io(address_map &map);
+ void mem_map(address_map &map);
+ void io_map(address_map &map);
void lx390_motor_w(uint8_t data);
- uint8_t lx390_reset_bank();
uint8_t lx390_fdc_r(offs_t offset);
void lx390_fdc_w(offs_t offset, uint8_t data);
diff --git a/src/mame/layout/brkball.lay b/src/mame/layout/brkball.lay
new file mode 100644
index 00000000000..a44fbf5413c
--- /dev/null
+++ b/src/mame/layout/brkball.lay
@@ -0,0 +1,4131 @@
+<?xml version="1.0"?>
+<mamelayout version="2">
+ <element name="dotmatrixdot">
+ <dotmatrixdot>
+ <color red="0" green="0" blue="0" />
+ </dotmatrixdot>
+ </element>
+ <element name="dmd_background">
+ <rect>
+ <color red="0.2" green="0.0" blue="0"/>
+ </rect>
+ </element>
+
+ <view name="main">
+ <backdrop name="dotmatrix0" element="dotmatrixdot" state="0">
+ <bounds x="0" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1" element="dotmatrixdot" state="0">
+ <bounds x="1" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix2" element="dotmatrixdot" state="0">
+ <bounds x="2" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix3" element="dotmatrixdot" state="0">
+ <bounds x="3" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix4" element="dotmatrixdot" state="0">
+ <bounds x="4" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix5" element="dotmatrixdot" state="0">
+ <bounds x="5" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix6" element="dotmatrixdot" state="0">
+ <bounds x="6" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix7" element="dotmatrixdot" state="0">
+ <bounds x="7" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix8" element="dotmatrixdot" state="0">
+ <bounds x="8" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix9" element="dotmatrixdot" state="0">
+ <bounds x="9" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix10" element="dotmatrixdot" state="0">
+ <bounds x="10" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix11" element="dotmatrixdot" state="0">
+ <bounds x="11" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix12" element="dotmatrixdot" state="0">
+ <bounds x="12" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix13" element="dotmatrixdot" state="0">
+ <bounds x="13" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix14" element="dotmatrixdot" state="0">
+ <bounds x="14" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix15" element="dotmatrixdot" state="0">
+ <bounds x="15" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix16" element="dotmatrixdot" state="0">
+ <bounds x="16" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix17" element="dotmatrixdot" state="0">
+ <bounds x="17" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix18" element="dotmatrixdot" state="0">
+ <bounds x="18" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix19" element="dotmatrixdot" state="0">
+ <bounds x="19" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix20" element="dotmatrixdot" state="0">
+ <bounds x="20" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix21" element="dotmatrixdot" state="0">
+ <bounds x="21" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix22" element="dotmatrixdot" state="0">
+ <bounds x="22" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix23" element="dotmatrixdot" state="0">
+ <bounds x="23" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix24" element="dotmatrixdot" state="0">
+ <bounds x="24" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix25" element="dotmatrixdot" state="0">
+ <bounds x="25" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix26" element="dotmatrixdot" state="0">
+ <bounds x="26" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix27" element="dotmatrixdot" state="0">
+ <bounds x="27" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix28" element="dotmatrixdot" state="0">
+ <bounds x="28" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix29" element="dotmatrixdot" state="0">
+ <bounds x="29" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix30" element="dotmatrixdot" state="0">
+ <bounds x="30" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix31" element="dotmatrixdot" state="0">
+ <bounds x="31" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix32" element="dotmatrixdot" state="0">
+ <bounds x="32" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix33" element="dotmatrixdot" state="0">
+ <bounds x="33" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix34" element="dotmatrixdot" state="0">
+ <bounds x="34" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix35" element="dotmatrixdot" state="0">
+ <bounds x="35" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix36" element="dotmatrixdot" state="0">
+ <bounds x="36" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix37" element="dotmatrixdot" state="0">
+ <bounds x="37" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix38" element="dotmatrixdot" state="0">
+ <bounds x="38" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix39" element="dotmatrixdot" state="0">
+ <bounds x="39" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix40" element="dotmatrixdot" state="0">
+ <bounds x="40" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix41" element="dotmatrixdot" state="0">
+ <bounds x="41" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix42" element="dotmatrixdot" state="0">
+ <bounds x="42" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix43" element="dotmatrixdot" state="0">
+ <bounds x="43" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix44" element="dotmatrixdot" state="0">
+ <bounds x="44" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix45" element="dotmatrixdot" state="0">
+ <bounds x="45" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix46" element="dotmatrixdot" state="0">
+ <bounds x="46" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix47" element="dotmatrixdot" state="0">
+ <bounds x="47" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix48" element="dotmatrixdot" state="0">
+ <bounds x="48" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix49" element="dotmatrixdot" state="0">
+ <bounds x="49" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix50" element="dotmatrixdot" state="0">
+ <bounds x="50" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix51" element="dotmatrixdot" state="0">
+ <bounds x="51" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix52" element="dotmatrixdot" state="0">
+ <bounds x="52" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix53" element="dotmatrixdot" state="0">
+ <bounds x="53" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix54" element="dotmatrixdot" state="0">
+ <bounds x="54" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix55" element="dotmatrixdot" state="0">
+ <bounds x="55" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix56" element="dotmatrixdot" state="0">
+ <bounds x="56" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix57" element="dotmatrixdot" state="0">
+ <bounds x="57" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix58" element="dotmatrixdot" state="0">
+ <bounds x="58" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix59" element="dotmatrixdot" state="0">
+ <bounds x="59" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix60" element="dotmatrixdot" state="0">
+ <bounds x="60" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix61" element="dotmatrixdot" state="0">
+ <bounds x="61" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix62" element="dotmatrixdot" state="0">
+ <bounds x="62" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix63" element="dotmatrixdot" state="0">
+ <bounds x="63" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix64" element="dotmatrixdot" state="0">
+ <bounds x="64" y="0" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix65" element="dotmatrixdot" state="0">
+ <bounds x="0" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix66" element="dotmatrixdot" state="0">
+ <bounds x="1" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix67" element="dotmatrixdot" state="0">
+ <bounds x="2" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix68" element="dotmatrixdot" state="0">
+ <bounds x="3" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix69" element="dotmatrixdot" state="0">
+ <bounds x="4" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix70" element="dotmatrixdot" state="0">
+ <bounds x="5" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix71" element="dotmatrixdot" state="0">
+ <bounds x="6" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix72" element="dotmatrixdot" state="0">
+ <bounds x="7" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix73" element="dotmatrixdot" state="0">
+ <bounds x="8" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix74" element="dotmatrixdot" state="0">
+ <bounds x="9" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix75" element="dotmatrixdot" state="0">
+ <bounds x="10" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix76" element="dotmatrixdot" state="0">
+ <bounds x="11" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix77" element="dotmatrixdot" state="0">
+ <bounds x="12" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix78" element="dotmatrixdot" state="0">
+ <bounds x="13" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix79" element="dotmatrixdot" state="0">
+ <bounds x="14" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix80" element="dotmatrixdot" state="0">
+ <bounds x="15" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix81" element="dotmatrixdot" state="0">
+ <bounds x="16" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix82" element="dotmatrixdot" state="0">
+ <bounds x="17" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix83" element="dotmatrixdot" state="0">
+ <bounds x="18" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix84" element="dotmatrixdot" state="0">
+ <bounds x="19" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix85" element="dotmatrixdot" state="0">
+ <bounds x="20" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix86" element="dotmatrixdot" state="0">
+ <bounds x="21" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix87" element="dotmatrixdot" state="0">
+ <bounds x="22" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix88" element="dotmatrixdot" state="0">
+ <bounds x="23" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix89" element="dotmatrixdot" state="0">
+ <bounds x="24" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix90" element="dotmatrixdot" state="0">
+ <bounds x="25" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix91" element="dotmatrixdot" state="0">
+ <bounds x="26" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix92" element="dotmatrixdot" state="0">
+ <bounds x="27" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix93" element="dotmatrixdot" state="0">
+ <bounds x="28" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix94" element="dotmatrixdot" state="0">
+ <bounds x="29" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix95" element="dotmatrixdot" state="0">
+ <bounds x="30" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix96" element="dotmatrixdot" state="0">
+ <bounds x="31" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix97" element="dotmatrixdot" state="0">
+ <bounds x="32" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix98" element="dotmatrixdot" state="0">
+ <bounds x="33" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix99" element="dotmatrixdot" state="0">
+ <bounds x="34" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix100" element="dotmatrixdot" state="0">
+ <bounds x="35" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix101" element="dotmatrixdot" state="0">
+ <bounds x="36" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix102" element="dotmatrixdot" state="0">
+ <bounds x="37" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix103" element="dotmatrixdot" state="0">
+ <bounds x="38" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix104" element="dotmatrixdot" state="0">
+ <bounds x="39" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix105" element="dotmatrixdot" state="0">
+ <bounds x="40" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix106" element="dotmatrixdot" state="0">
+ <bounds x="41" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix107" element="dotmatrixdot" state="0">
+ <bounds x="42" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix108" element="dotmatrixdot" state="0">
+ <bounds x="43" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix109" element="dotmatrixdot" state="0">
+ <bounds x="44" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix110" element="dotmatrixdot" state="0">
+ <bounds x="45" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix111" element="dotmatrixdot" state="0">
+ <bounds x="46" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix112" element="dotmatrixdot" state="0">
+ <bounds x="47" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix113" element="dotmatrixdot" state="0">
+ <bounds x="48" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix114" element="dotmatrixdot" state="0">
+ <bounds x="49" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix115" element="dotmatrixdot" state="0">
+ <bounds x="50" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix116" element="dotmatrixdot" state="0">
+ <bounds x="51" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix117" element="dotmatrixdot" state="0">
+ <bounds x="52" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix118" element="dotmatrixdot" state="0">
+ <bounds x="53" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix119" element="dotmatrixdot" state="0">
+ <bounds x="54" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix120" element="dotmatrixdot" state="0">
+ <bounds x="55" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix121" element="dotmatrixdot" state="0">
+ <bounds x="56" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix122" element="dotmatrixdot" state="0">
+ <bounds x="57" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix123" element="dotmatrixdot" state="0">
+ <bounds x="58" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix124" element="dotmatrixdot" state="0">
+ <bounds x="59" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix125" element="dotmatrixdot" state="0">
+ <bounds x="60" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix126" element="dotmatrixdot" state="0">
+ <bounds x="61" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix127" element="dotmatrixdot" state="0">
+ <bounds x="62" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix128" element="dotmatrixdot" state="0">
+ <bounds x="63" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix129" element="dotmatrixdot" state="0">
+ <bounds x="64" y="1" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix130" element="dotmatrixdot" state="0">
+ <bounds x="0" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix131" element="dotmatrixdot" state="0">
+ <bounds x="1" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix132" element="dotmatrixdot" state="0">
+ <bounds x="2" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix133" element="dotmatrixdot" state="0">
+ <bounds x="3" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix134" element="dotmatrixdot" state="0">
+ <bounds x="4" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix135" element="dotmatrixdot" state="0">
+ <bounds x="5" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix136" element="dotmatrixdot" state="0">
+ <bounds x="6" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix137" element="dotmatrixdot" state="0">
+ <bounds x="7" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix138" element="dotmatrixdot" state="0">
+ <bounds x="8" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix139" element="dotmatrixdot" state="0">
+ <bounds x="9" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix140" element="dotmatrixdot" state="0">
+ <bounds x="10" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix141" element="dotmatrixdot" state="0">
+ <bounds x="11" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix142" element="dotmatrixdot" state="0">
+ <bounds x="12" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix143" element="dotmatrixdot" state="0">
+ <bounds x="13" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix144" element="dotmatrixdot" state="0">
+ <bounds x="14" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix145" element="dotmatrixdot" state="0">
+ <bounds x="15" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix146" element="dotmatrixdot" state="0">
+ <bounds x="16" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix147" element="dotmatrixdot" state="0">
+ <bounds x="17" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix148" element="dotmatrixdot" state="0">
+ <bounds x="18" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix149" element="dotmatrixdot" state="0">
+ <bounds x="19" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix150" element="dotmatrixdot" state="0">
+ <bounds x="20" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix151" element="dotmatrixdot" state="0">
+ <bounds x="21" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix152" element="dotmatrixdot" state="0">
+ <bounds x="22" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix153" element="dotmatrixdot" state="0">
+ <bounds x="23" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix154" element="dotmatrixdot" state="0">
+ <bounds x="24" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix155" element="dotmatrixdot" state="0">
+ <bounds x="25" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix156" element="dotmatrixdot" state="0">
+ <bounds x="26" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix157" element="dotmatrixdot" state="0">
+ <bounds x="27" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix158" element="dotmatrixdot" state="0">
+ <bounds x="28" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix159" element="dotmatrixdot" state="0">
+ <bounds x="29" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix160" element="dotmatrixdot" state="0">
+ <bounds x="30" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix161" element="dotmatrixdot" state="0">
+ <bounds x="31" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix162" element="dotmatrixdot" state="0">
+ <bounds x="32" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix163" element="dotmatrixdot" state="0">
+ <bounds x="33" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix164" element="dotmatrixdot" state="0">
+ <bounds x="34" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix165" element="dotmatrixdot" state="0">
+ <bounds x="35" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix166" element="dotmatrixdot" state="0">
+ <bounds x="36" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix167" element="dotmatrixdot" state="0">
+ <bounds x="37" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix168" element="dotmatrixdot" state="0">
+ <bounds x="38" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix169" element="dotmatrixdot" state="0">
+ <bounds x="39" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix170" element="dotmatrixdot" state="0">
+ <bounds x="40" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix171" element="dotmatrixdot" state="0">
+ <bounds x="41" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix172" element="dotmatrixdot" state="0">
+ <bounds x="42" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix173" element="dotmatrixdot" state="0">
+ <bounds x="43" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix174" element="dotmatrixdot" state="0">
+ <bounds x="44" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix175" element="dotmatrixdot" state="0">
+ <bounds x="45" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix176" element="dotmatrixdot" state="0">
+ <bounds x="46" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix177" element="dotmatrixdot" state="0">
+ <bounds x="47" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix178" element="dotmatrixdot" state="0">
+ <bounds x="48" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix179" element="dotmatrixdot" state="0">
+ <bounds x="49" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix180" element="dotmatrixdot" state="0">
+ <bounds x="50" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix181" element="dotmatrixdot" state="0">
+ <bounds x="51" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix182" element="dotmatrixdot" state="0">
+ <bounds x="52" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix183" element="dotmatrixdot" state="0">
+ <bounds x="53" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix184" element="dotmatrixdot" state="0">
+ <bounds x="54" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix185" element="dotmatrixdot" state="0">
+ <bounds x="55" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix186" element="dotmatrixdot" state="0">
+ <bounds x="56" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix187" element="dotmatrixdot" state="0">
+ <bounds x="57" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix188" element="dotmatrixdot" state="0">
+ <bounds x="58" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix189" element="dotmatrixdot" state="0">
+ <bounds x="59" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix190" element="dotmatrixdot" state="0">
+ <bounds x="60" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix191" element="dotmatrixdot" state="0">
+ <bounds x="61" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix192" element="dotmatrixdot" state="0">
+ <bounds x="62" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix193" element="dotmatrixdot" state="0">
+ <bounds x="63" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix194" element="dotmatrixdot" state="0">
+ <bounds x="64" y="2" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix195" element="dotmatrixdot" state="0">
+ <bounds x="0" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix196" element="dotmatrixdot" state="0">
+ <bounds x="1" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix197" element="dotmatrixdot" state="0">
+ <bounds x="2" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix198" element="dotmatrixdot" state="0">
+ <bounds x="3" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix199" element="dotmatrixdot" state="0">
+ <bounds x="4" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix200" element="dotmatrixdot" state="0">
+ <bounds x="5" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix201" element="dotmatrixdot" state="0">
+ <bounds x="6" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix202" element="dotmatrixdot" state="0">
+ <bounds x="7" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix203" element="dotmatrixdot" state="0">
+ <bounds x="8" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix204" element="dotmatrixdot" state="0">
+ <bounds x="9" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix205" element="dotmatrixdot" state="0">
+ <bounds x="10" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix206" element="dotmatrixdot" state="0">
+ <bounds x="11" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix207" element="dotmatrixdot" state="0">
+ <bounds x="12" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix208" element="dotmatrixdot" state="0">
+ <bounds x="13" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix209" element="dotmatrixdot" state="0">
+ <bounds x="14" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix210" element="dotmatrixdot" state="0">
+ <bounds x="15" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix211" element="dotmatrixdot" state="0">
+ <bounds x="16" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix212" element="dotmatrixdot" state="0">
+ <bounds x="17" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix213" element="dotmatrixdot" state="0">
+ <bounds x="18" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix214" element="dotmatrixdot" state="0">
+ <bounds x="19" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix215" element="dotmatrixdot" state="0">
+ <bounds x="20" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix216" element="dotmatrixdot" state="0">
+ <bounds x="21" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix217" element="dotmatrixdot" state="0">
+ <bounds x="22" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix218" element="dotmatrixdot" state="0">
+ <bounds x="23" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix219" element="dotmatrixdot" state="0">
+ <bounds x="24" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix220" element="dotmatrixdot" state="0">
+ <bounds x="25" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix221" element="dotmatrixdot" state="0">
+ <bounds x="26" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix222" element="dotmatrixdot" state="0">
+ <bounds x="27" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix223" element="dotmatrixdot" state="0">
+ <bounds x="28" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix224" element="dotmatrixdot" state="0">
+ <bounds x="29" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix225" element="dotmatrixdot" state="0">
+ <bounds x="30" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix226" element="dotmatrixdot" state="0">
+ <bounds x="31" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix227" element="dotmatrixdot" state="0">
+ <bounds x="32" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix228" element="dotmatrixdot" state="0">
+ <bounds x="33" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix229" element="dotmatrixdot" state="0">
+ <bounds x="34" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix230" element="dotmatrixdot" state="0">
+ <bounds x="35" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix231" element="dotmatrixdot" state="0">
+ <bounds x="36" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix232" element="dotmatrixdot" state="0">
+ <bounds x="37" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix233" element="dotmatrixdot" state="0">
+ <bounds x="38" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix234" element="dotmatrixdot" state="0">
+ <bounds x="39" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix235" element="dotmatrixdot" state="0">
+ <bounds x="40" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix236" element="dotmatrixdot" state="0">
+ <bounds x="41" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix237" element="dotmatrixdot" state="0">
+ <bounds x="42" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix238" element="dotmatrixdot" state="0">
+ <bounds x="43" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix239" element="dotmatrixdot" state="0">
+ <bounds x="44" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix240" element="dotmatrixdot" state="0">
+ <bounds x="45" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix241" element="dotmatrixdot" state="0">
+ <bounds x="46" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix242" element="dotmatrixdot" state="0">
+ <bounds x="47" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix243" element="dotmatrixdot" state="0">
+ <bounds x="48" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix244" element="dotmatrixdot" state="0">
+ <bounds x="49" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix245" element="dotmatrixdot" state="0">
+ <bounds x="50" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix246" element="dotmatrixdot" state="0">
+ <bounds x="51" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix247" element="dotmatrixdot" state="0">
+ <bounds x="52" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix248" element="dotmatrixdot" state="0">
+ <bounds x="53" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix249" element="dotmatrixdot" state="0">
+ <bounds x="54" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix250" element="dotmatrixdot" state="0">
+ <bounds x="55" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix251" element="dotmatrixdot" state="0">
+ <bounds x="56" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix252" element="dotmatrixdot" state="0">
+ <bounds x="57" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix253" element="dotmatrixdot" state="0">
+ <bounds x="58" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix254" element="dotmatrixdot" state="0">
+ <bounds x="59" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix255" element="dotmatrixdot" state="0">
+ <bounds x="60" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix256" element="dotmatrixdot" state="0">
+ <bounds x="61" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix257" element="dotmatrixdot" state="0">
+ <bounds x="62" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix258" element="dotmatrixdot" state="0">
+ <bounds x="63" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix259" element="dotmatrixdot" state="0">
+ <bounds x="64" y="3" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix260" element="dotmatrixdot" state="0">
+ <bounds x="0" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix261" element="dotmatrixdot" state="0">
+ <bounds x="1" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix262" element="dotmatrixdot" state="0">
+ <bounds x="2" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix263" element="dotmatrixdot" state="0">
+ <bounds x="3" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix264" element="dotmatrixdot" state="0">
+ <bounds x="4" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix265" element="dotmatrixdot" state="0">
+ <bounds x="5" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix266" element="dotmatrixdot" state="0">
+ <bounds x="6" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix267" element="dotmatrixdot" state="0">
+ <bounds x="7" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix268" element="dotmatrixdot" state="0">
+ <bounds x="8" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix269" element="dotmatrixdot" state="0">
+ <bounds x="9" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix270" element="dotmatrixdot" state="0">
+ <bounds x="10" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix271" element="dotmatrixdot" state="0">
+ <bounds x="11" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix272" element="dotmatrixdot" state="0">
+ <bounds x="12" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix273" element="dotmatrixdot" state="0">
+ <bounds x="13" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix274" element="dotmatrixdot" state="0">
+ <bounds x="14" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix275" element="dotmatrixdot" state="0">
+ <bounds x="15" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix276" element="dotmatrixdot" state="0">
+ <bounds x="16" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix277" element="dotmatrixdot" state="0">
+ <bounds x="17" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix278" element="dotmatrixdot" state="0">
+ <bounds x="18" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix279" element="dotmatrixdot" state="0">
+ <bounds x="19" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix280" element="dotmatrixdot" state="0">
+ <bounds x="20" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix281" element="dotmatrixdot" state="0">
+ <bounds x="21" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix282" element="dotmatrixdot" state="0">
+ <bounds x="22" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix283" element="dotmatrixdot" state="0">
+ <bounds x="23" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix284" element="dotmatrixdot" state="0">
+ <bounds x="24" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix285" element="dotmatrixdot" state="0">
+ <bounds x="25" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix286" element="dotmatrixdot" state="0">
+ <bounds x="26" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix287" element="dotmatrixdot" state="0">
+ <bounds x="27" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix288" element="dotmatrixdot" state="0">
+ <bounds x="28" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix289" element="dotmatrixdot" state="0">
+ <bounds x="29" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix290" element="dotmatrixdot" state="0">
+ <bounds x="30" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix291" element="dotmatrixdot" state="0">
+ <bounds x="31" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix292" element="dotmatrixdot" state="0">
+ <bounds x="32" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix293" element="dotmatrixdot" state="0">
+ <bounds x="33" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix294" element="dotmatrixdot" state="0">
+ <bounds x="34" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix295" element="dotmatrixdot" state="0">
+ <bounds x="35" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix296" element="dotmatrixdot" state="0">
+ <bounds x="36" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix297" element="dotmatrixdot" state="0">
+ <bounds x="37" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix298" element="dotmatrixdot" state="0">
+ <bounds x="38" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix299" element="dotmatrixdot" state="0">
+ <bounds x="39" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix300" element="dotmatrixdot" state="0">
+ <bounds x="40" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix301" element="dotmatrixdot" state="0">
+ <bounds x="41" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix302" element="dotmatrixdot" state="0">
+ <bounds x="42" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix303" element="dotmatrixdot" state="0">
+ <bounds x="43" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix304" element="dotmatrixdot" state="0">
+ <bounds x="44" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix305" element="dotmatrixdot" state="0">
+ <bounds x="45" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix306" element="dotmatrixdot" state="0">
+ <bounds x="46" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix307" element="dotmatrixdot" state="0">
+ <bounds x="47" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix308" element="dotmatrixdot" state="0">
+ <bounds x="48" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix309" element="dotmatrixdot" state="0">
+ <bounds x="49" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix310" element="dotmatrixdot" state="0">
+ <bounds x="50" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix311" element="dotmatrixdot" state="0">
+ <bounds x="51" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix312" element="dotmatrixdot" state="0">
+ <bounds x="52" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix313" element="dotmatrixdot" state="0">
+ <bounds x="53" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix314" element="dotmatrixdot" state="0">
+ <bounds x="54" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix315" element="dotmatrixdot" state="0">
+ <bounds x="55" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix316" element="dotmatrixdot" state="0">
+ <bounds x="56" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix317" element="dotmatrixdot" state="0">
+ <bounds x="57" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix318" element="dotmatrixdot" state="0">
+ <bounds x="58" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix319" element="dotmatrixdot" state="0">
+ <bounds x="59" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix320" element="dotmatrixdot" state="0">
+ <bounds x="60" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix321" element="dotmatrixdot" state="0">
+ <bounds x="61" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix322" element="dotmatrixdot" state="0">
+ <bounds x="62" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix323" element="dotmatrixdot" state="0">
+ <bounds x="63" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix324" element="dotmatrixdot" state="0">
+ <bounds x="64" y="4" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix325" element="dotmatrixdot" state="0">
+ <bounds x="0" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix326" element="dotmatrixdot" state="0">
+ <bounds x="1" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix327" element="dotmatrixdot" state="0">
+ <bounds x="2" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix328" element="dotmatrixdot" state="0">
+ <bounds x="3" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix329" element="dotmatrixdot" state="0">
+ <bounds x="4" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix330" element="dotmatrixdot" state="0">
+ <bounds x="5" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix331" element="dotmatrixdot" state="0">
+ <bounds x="6" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix332" element="dotmatrixdot" state="0">
+ <bounds x="7" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix333" element="dotmatrixdot" state="0">
+ <bounds x="8" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix334" element="dotmatrixdot" state="0">
+ <bounds x="9" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix335" element="dotmatrixdot" state="0">
+ <bounds x="10" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix336" element="dotmatrixdot" state="0">
+ <bounds x="11" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix337" element="dotmatrixdot" state="0">
+ <bounds x="12" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix338" element="dotmatrixdot" state="0">
+ <bounds x="13" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix339" element="dotmatrixdot" state="0">
+ <bounds x="14" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix340" element="dotmatrixdot" state="0">
+ <bounds x="15" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix341" element="dotmatrixdot" state="0">
+ <bounds x="16" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix342" element="dotmatrixdot" state="0">
+ <bounds x="17" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix343" element="dotmatrixdot" state="0">
+ <bounds x="18" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix344" element="dotmatrixdot" state="0">
+ <bounds x="19" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix345" element="dotmatrixdot" state="0">
+ <bounds x="20" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix346" element="dotmatrixdot" state="0">
+ <bounds x="21" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix347" element="dotmatrixdot" state="0">
+ <bounds x="22" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix348" element="dotmatrixdot" state="0">
+ <bounds x="23" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix349" element="dotmatrixdot" state="0">
+ <bounds x="24" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix350" element="dotmatrixdot" state="0">
+ <bounds x="25" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix351" element="dotmatrixdot" state="0">
+ <bounds x="26" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix352" element="dotmatrixdot" state="0">
+ <bounds x="27" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix353" element="dotmatrixdot" state="0">
+ <bounds x="28" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix354" element="dotmatrixdot" state="0">
+ <bounds x="29" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix355" element="dotmatrixdot" state="0">
+ <bounds x="30" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix356" element="dotmatrixdot" state="0">
+ <bounds x="31" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix357" element="dotmatrixdot" state="0">
+ <bounds x="32" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix358" element="dotmatrixdot" state="0">
+ <bounds x="33" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix359" element="dotmatrixdot" state="0">
+ <bounds x="34" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix360" element="dotmatrixdot" state="0">
+ <bounds x="35" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix361" element="dotmatrixdot" state="0">
+ <bounds x="36" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix362" element="dotmatrixdot" state="0">
+ <bounds x="37" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix363" element="dotmatrixdot" state="0">
+ <bounds x="38" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix364" element="dotmatrixdot" state="0">
+ <bounds x="39" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix365" element="dotmatrixdot" state="0">
+ <bounds x="40" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix366" element="dotmatrixdot" state="0">
+ <bounds x="41" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix367" element="dotmatrixdot" state="0">
+ <bounds x="42" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix368" element="dotmatrixdot" state="0">
+ <bounds x="43" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix369" element="dotmatrixdot" state="0">
+ <bounds x="44" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix370" element="dotmatrixdot" state="0">
+ <bounds x="45" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix371" element="dotmatrixdot" state="0">
+ <bounds x="46" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix372" element="dotmatrixdot" state="0">
+ <bounds x="47" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix373" element="dotmatrixdot" state="0">
+ <bounds x="48" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix374" element="dotmatrixdot" state="0">
+ <bounds x="49" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix375" element="dotmatrixdot" state="0">
+ <bounds x="50" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix376" element="dotmatrixdot" state="0">
+ <bounds x="51" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix377" element="dotmatrixdot" state="0">
+ <bounds x="52" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix378" element="dotmatrixdot" state="0">
+ <bounds x="53" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix379" element="dotmatrixdot" state="0">
+ <bounds x="54" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix380" element="dotmatrixdot" state="0">
+ <bounds x="55" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix381" element="dotmatrixdot" state="0">
+ <bounds x="56" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix382" element="dotmatrixdot" state="0">
+ <bounds x="57" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix383" element="dotmatrixdot" state="0">
+ <bounds x="58" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix384" element="dotmatrixdot" state="0">
+ <bounds x="59" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix385" element="dotmatrixdot" state="0">
+ <bounds x="60" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix386" element="dotmatrixdot" state="0">
+ <bounds x="61" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix387" element="dotmatrixdot" state="0">
+ <bounds x="62" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix388" element="dotmatrixdot" state="0">
+ <bounds x="63" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix389" element="dotmatrixdot" state="0">
+ <bounds x="64" y="5" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix390" element="dotmatrixdot" state="0">
+ <bounds x="0" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix391" element="dotmatrixdot" state="0">
+ <bounds x="1" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix392" element="dotmatrixdot" state="0">
+ <bounds x="2" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix393" element="dotmatrixdot" state="0">
+ <bounds x="3" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix394" element="dotmatrixdot" state="0">
+ <bounds x="4" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix395" element="dotmatrixdot" state="0">
+ <bounds x="5" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix396" element="dotmatrixdot" state="0">
+ <bounds x="6" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix397" element="dotmatrixdot" state="0">
+ <bounds x="7" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix398" element="dotmatrixdot" state="0">
+ <bounds x="8" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix399" element="dotmatrixdot" state="0">
+ <bounds x="9" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix400" element="dotmatrixdot" state="0">
+ <bounds x="10" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix401" element="dotmatrixdot" state="0">
+ <bounds x="11" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix402" element="dotmatrixdot" state="0">
+ <bounds x="12" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix403" element="dotmatrixdot" state="0">
+ <bounds x="13" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix404" element="dotmatrixdot" state="0">
+ <bounds x="14" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix405" element="dotmatrixdot" state="0">
+ <bounds x="15" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix406" element="dotmatrixdot" state="0">
+ <bounds x="16" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix407" element="dotmatrixdot" state="0">
+ <bounds x="17" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix408" element="dotmatrixdot" state="0">
+ <bounds x="18" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix409" element="dotmatrixdot" state="0">
+ <bounds x="19" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix410" element="dotmatrixdot" state="0">
+ <bounds x="20" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix411" element="dotmatrixdot" state="0">
+ <bounds x="21" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix412" element="dotmatrixdot" state="0">
+ <bounds x="22" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix413" element="dotmatrixdot" state="0">
+ <bounds x="23" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix414" element="dotmatrixdot" state="0">
+ <bounds x="24" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix415" element="dotmatrixdot" state="0">
+ <bounds x="25" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix416" element="dotmatrixdot" state="0">
+ <bounds x="26" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix417" element="dotmatrixdot" state="0">
+ <bounds x="27" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix418" element="dotmatrixdot" state="0">
+ <bounds x="28" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix419" element="dotmatrixdot" state="0">
+ <bounds x="29" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix420" element="dotmatrixdot" state="0">
+ <bounds x="30" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix421" element="dotmatrixdot" state="0">
+ <bounds x="31" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix422" element="dotmatrixdot" state="0">
+ <bounds x="32" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix423" element="dotmatrixdot" state="0">
+ <bounds x="33" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix424" element="dotmatrixdot" state="0">
+ <bounds x="34" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix425" element="dotmatrixdot" state="0">
+ <bounds x="35" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix426" element="dotmatrixdot" state="0">
+ <bounds x="36" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix427" element="dotmatrixdot" state="0">
+ <bounds x="37" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix428" element="dotmatrixdot" state="0">
+ <bounds x="38" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix429" element="dotmatrixdot" state="0">
+ <bounds x="39" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix430" element="dotmatrixdot" state="0">
+ <bounds x="40" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix431" element="dotmatrixdot" state="0">
+ <bounds x="41" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix432" element="dotmatrixdot" state="0">
+ <bounds x="42" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix433" element="dotmatrixdot" state="0">
+ <bounds x="43" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix434" element="dotmatrixdot" state="0">
+ <bounds x="44" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix435" element="dotmatrixdot" state="0">
+ <bounds x="45" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix436" element="dotmatrixdot" state="0">
+ <bounds x="46" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix437" element="dotmatrixdot" state="0">
+ <bounds x="47" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix438" element="dotmatrixdot" state="0">
+ <bounds x="48" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix439" element="dotmatrixdot" state="0">
+ <bounds x="49" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix440" element="dotmatrixdot" state="0">
+ <bounds x="50" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix441" element="dotmatrixdot" state="0">
+ <bounds x="51" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix442" element="dotmatrixdot" state="0">
+ <bounds x="52" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix443" element="dotmatrixdot" state="0">
+ <bounds x="53" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix444" element="dotmatrixdot" state="0">
+ <bounds x="54" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix445" element="dotmatrixdot" state="0">
+ <bounds x="55" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix446" element="dotmatrixdot" state="0">
+ <bounds x="56" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix447" element="dotmatrixdot" state="0">
+ <bounds x="57" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix448" element="dotmatrixdot" state="0">
+ <bounds x="58" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix449" element="dotmatrixdot" state="0">
+ <bounds x="59" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix450" element="dotmatrixdot" state="0">
+ <bounds x="60" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix451" element="dotmatrixdot" state="0">
+ <bounds x="61" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix452" element="dotmatrixdot" state="0">
+ <bounds x="62" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix453" element="dotmatrixdot" state="0">
+ <bounds x="63" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix454" element="dotmatrixdot" state="0">
+ <bounds x="64" y="6" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix455" element="dotmatrixdot" state="0">
+ <bounds x="0" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix456" element="dotmatrixdot" state="0">
+ <bounds x="1" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix457" element="dotmatrixdot" state="0">
+ <bounds x="2" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix458" element="dotmatrixdot" state="0">
+ <bounds x="3" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix459" element="dotmatrixdot" state="0">
+ <bounds x="4" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix460" element="dotmatrixdot" state="0">
+ <bounds x="5" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix461" element="dotmatrixdot" state="0">
+ <bounds x="6" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix462" element="dotmatrixdot" state="0">
+ <bounds x="7" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix463" element="dotmatrixdot" state="0">
+ <bounds x="8" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix464" element="dotmatrixdot" state="0">
+ <bounds x="9" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix465" element="dotmatrixdot" state="0">
+ <bounds x="10" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix466" element="dotmatrixdot" state="0">
+ <bounds x="11" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix467" element="dotmatrixdot" state="0">
+ <bounds x="12" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix468" element="dotmatrixdot" state="0">
+ <bounds x="13" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix469" element="dotmatrixdot" state="0">
+ <bounds x="14" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix470" element="dotmatrixdot" state="0">
+ <bounds x="15" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix471" element="dotmatrixdot" state="0">
+ <bounds x="16" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix472" element="dotmatrixdot" state="0">
+ <bounds x="17" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix473" element="dotmatrixdot" state="0">
+ <bounds x="18" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix474" element="dotmatrixdot" state="0">
+ <bounds x="19" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix475" element="dotmatrixdot" state="0">
+ <bounds x="20" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix476" element="dotmatrixdot" state="0">
+ <bounds x="21" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix477" element="dotmatrixdot" state="0">
+ <bounds x="22" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix478" element="dotmatrixdot" state="0">
+ <bounds x="23" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix479" element="dotmatrixdot" state="0">
+ <bounds x="24" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix480" element="dotmatrixdot" state="0">
+ <bounds x="25" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix481" element="dotmatrixdot" state="0">
+ <bounds x="26" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix482" element="dotmatrixdot" state="0">
+ <bounds x="27" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix483" element="dotmatrixdot" state="0">
+ <bounds x="28" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix484" element="dotmatrixdot" state="0">
+ <bounds x="29" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix485" element="dotmatrixdot" state="0">
+ <bounds x="30" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix486" element="dotmatrixdot" state="0">
+ <bounds x="31" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix487" element="dotmatrixdot" state="0">
+ <bounds x="32" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix488" element="dotmatrixdot" state="0">
+ <bounds x="33" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix489" element="dotmatrixdot" state="0">
+ <bounds x="34" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix490" element="dotmatrixdot" state="0">
+ <bounds x="35" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix491" element="dotmatrixdot" state="0">
+ <bounds x="36" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix492" element="dotmatrixdot" state="0">
+ <bounds x="37" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix493" element="dotmatrixdot" state="0">
+ <bounds x="38" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix494" element="dotmatrixdot" state="0">
+ <bounds x="39" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix495" element="dotmatrixdot" state="0">
+ <bounds x="40" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix496" element="dotmatrixdot" state="0">
+ <bounds x="41" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix497" element="dotmatrixdot" state="0">
+ <bounds x="42" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix498" element="dotmatrixdot" state="0">
+ <bounds x="43" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix499" element="dotmatrixdot" state="0">
+ <bounds x="44" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix500" element="dotmatrixdot" state="0">
+ <bounds x="45" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix501" element="dotmatrixdot" state="0">
+ <bounds x="46" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix502" element="dotmatrixdot" state="0">
+ <bounds x="47" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix503" element="dotmatrixdot" state="0">
+ <bounds x="48" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix504" element="dotmatrixdot" state="0">
+ <bounds x="49" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix505" element="dotmatrixdot" state="0">
+ <bounds x="50" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix506" element="dotmatrixdot" state="0">
+ <bounds x="51" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix507" element="dotmatrixdot" state="0">
+ <bounds x="52" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix508" element="dotmatrixdot" state="0">
+ <bounds x="53" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix509" element="dotmatrixdot" state="0">
+ <bounds x="54" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix510" element="dotmatrixdot" state="0">
+ <bounds x="55" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix511" element="dotmatrixdot" state="0">
+ <bounds x="56" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix512" element="dotmatrixdot" state="0">
+ <bounds x="57" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix513" element="dotmatrixdot" state="0">
+ <bounds x="58" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix514" element="dotmatrixdot" state="0">
+ <bounds x="59" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix515" element="dotmatrixdot" state="0">
+ <bounds x="60" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix516" element="dotmatrixdot" state="0">
+ <bounds x="61" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix517" element="dotmatrixdot" state="0">
+ <bounds x="62" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix518" element="dotmatrixdot" state="0">
+ <bounds x="63" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix519" element="dotmatrixdot" state="0">
+ <bounds x="64" y="7" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix520" element="dotmatrixdot" state="0">
+ <bounds x="0" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix521" element="dotmatrixdot" state="0">
+ <bounds x="1" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix522" element="dotmatrixdot" state="0">
+ <bounds x="2" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix523" element="dotmatrixdot" state="0">
+ <bounds x="3" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix524" element="dotmatrixdot" state="0">
+ <bounds x="4" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix525" element="dotmatrixdot" state="0">
+ <bounds x="5" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix526" element="dotmatrixdot" state="0">
+ <bounds x="6" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix527" element="dotmatrixdot" state="0">
+ <bounds x="7" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix528" element="dotmatrixdot" state="0">
+ <bounds x="8" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix529" element="dotmatrixdot" state="0">
+ <bounds x="9" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix530" element="dotmatrixdot" state="0">
+ <bounds x="10" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix531" element="dotmatrixdot" state="0">
+ <bounds x="11" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix532" element="dotmatrixdot" state="0">
+ <bounds x="12" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix533" element="dotmatrixdot" state="0">
+ <bounds x="13" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix534" element="dotmatrixdot" state="0">
+ <bounds x="14" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix535" element="dotmatrixdot" state="0">
+ <bounds x="15" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix536" element="dotmatrixdot" state="0">
+ <bounds x="16" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix537" element="dotmatrixdot" state="0">
+ <bounds x="17" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix538" element="dotmatrixdot" state="0">
+ <bounds x="18" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix539" element="dotmatrixdot" state="0">
+ <bounds x="19" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix540" element="dotmatrixdot" state="0">
+ <bounds x="20" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix541" element="dotmatrixdot" state="0">
+ <bounds x="21" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix542" element="dotmatrixdot" state="0">
+ <bounds x="22" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix543" element="dotmatrixdot" state="0">
+ <bounds x="23" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix544" element="dotmatrixdot" state="0">
+ <bounds x="24" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix545" element="dotmatrixdot" state="0">
+ <bounds x="25" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix546" element="dotmatrixdot" state="0">
+ <bounds x="26" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix547" element="dotmatrixdot" state="0">
+ <bounds x="27" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix548" element="dotmatrixdot" state="0">
+ <bounds x="28" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix549" element="dotmatrixdot" state="0">
+ <bounds x="29" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix550" element="dotmatrixdot" state="0">
+ <bounds x="30" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix551" element="dotmatrixdot" state="0">
+ <bounds x="31" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix552" element="dotmatrixdot" state="0">
+ <bounds x="32" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix553" element="dotmatrixdot" state="0">
+ <bounds x="33" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix554" element="dotmatrixdot" state="0">
+ <bounds x="34" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix555" element="dotmatrixdot" state="0">
+ <bounds x="35" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix556" element="dotmatrixdot" state="0">
+ <bounds x="36" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix557" element="dotmatrixdot" state="0">
+ <bounds x="37" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix558" element="dotmatrixdot" state="0">
+ <bounds x="38" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix559" element="dotmatrixdot" state="0">
+ <bounds x="39" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix560" element="dotmatrixdot" state="0">
+ <bounds x="40" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix561" element="dotmatrixdot" state="0">
+ <bounds x="41" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix562" element="dotmatrixdot" state="0">
+ <bounds x="42" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix563" element="dotmatrixdot" state="0">
+ <bounds x="43" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix564" element="dotmatrixdot" state="0">
+ <bounds x="44" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix565" element="dotmatrixdot" state="0">
+ <bounds x="45" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix566" element="dotmatrixdot" state="0">
+ <bounds x="46" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix567" element="dotmatrixdot" state="0">
+ <bounds x="47" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix568" element="dotmatrixdot" state="0">
+ <bounds x="48" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix569" element="dotmatrixdot" state="0">
+ <bounds x="49" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix570" element="dotmatrixdot" state="0">
+ <bounds x="50" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix571" element="dotmatrixdot" state="0">
+ <bounds x="51" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix572" element="dotmatrixdot" state="0">
+ <bounds x="52" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix573" element="dotmatrixdot" state="0">
+ <bounds x="53" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix574" element="dotmatrixdot" state="0">
+ <bounds x="54" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix575" element="dotmatrixdot" state="0">
+ <bounds x="55" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix576" element="dotmatrixdot" state="0">
+ <bounds x="56" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix577" element="dotmatrixdot" state="0">
+ <bounds x="57" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix578" element="dotmatrixdot" state="0">
+ <bounds x="58" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix579" element="dotmatrixdot" state="0">
+ <bounds x="59" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix580" element="dotmatrixdot" state="0">
+ <bounds x="60" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix581" element="dotmatrixdot" state="0">
+ <bounds x="61" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix582" element="dotmatrixdot" state="0">
+ <bounds x="62" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix583" element="dotmatrixdot" state="0">
+ <bounds x="63" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix584" element="dotmatrixdot" state="0">
+ <bounds x="64" y="8" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix585" element="dotmatrixdot" state="0">
+ <bounds x="0" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix586" element="dotmatrixdot" state="0">
+ <bounds x="1" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix587" element="dotmatrixdot" state="0">
+ <bounds x="2" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix588" element="dotmatrixdot" state="0">
+ <bounds x="3" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix589" element="dotmatrixdot" state="0">
+ <bounds x="4" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix590" element="dotmatrixdot" state="0">
+ <bounds x="5" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix591" element="dotmatrixdot" state="0">
+ <bounds x="6" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix592" element="dotmatrixdot" state="0">
+ <bounds x="7" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix593" element="dotmatrixdot" state="0">
+ <bounds x="8" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix594" element="dotmatrixdot" state="0">
+ <bounds x="9" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix595" element="dotmatrixdot" state="0">
+ <bounds x="10" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix596" element="dotmatrixdot" state="0">
+ <bounds x="11" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix597" element="dotmatrixdot" state="0">
+ <bounds x="12" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix598" element="dotmatrixdot" state="0">
+ <bounds x="13" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix599" element="dotmatrixdot" state="0">
+ <bounds x="14" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix600" element="dotmatrixdot" state="0">
+ <bounds x="15" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix601" element="dotmatrixdot" state="0">
+ <bounds x="16" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix602" element="dotmatrixdot" state="0">
+ <bounds x="17" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix603" element="dotmatrixdot" state="0">
+ <bounds x="18" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix604" element="dotmatrixdot" state="0">
+ <bounds x="19" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix605" element="dotmatrixdot" state="0">
+ <bounds x="20" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix606" element="dotmatrixdot" state="0">
+ <bounds x="21" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix607" element="dotmatrixdot" state="0">
+ <bounds x="22" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix608" element="dotmatrixdot" state="0">
+ <bounds x="23" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix609" element="dotmatrixdot" state="0">
+ <bounds x="24" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix610" element="dotmatrixdot" state="0">
+ <bounds x="25" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix611" element="dotmatrixdot" state="0">
+ <bounds x="26" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix612" element="dotmatrixdot" state="0">
+ <bounds x="27" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix613" element="dotmatrixdot" state="0">
+ <bounds x="28" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix614" element="dotmatrixdot" state="0">
+ <bounds x="29" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix615" element="dotmatrixdot" state="0">
+ <bounds x="30" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix616" element="dotmatrixdot" state="0">
+ <bounds x="31" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix617" element="dotmatrixdot" state="0">
+ <bounds x="32" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix618" element="dotmatrixdot" state="0">
+ <bounds x="33" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix619" element="dotmatrixdot" state="0">
+ <bounds x="34" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix620" element="dotmatrixdot" state="0">
+ <bounds x="35" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix621" element="dotmatrixdot" state="0">
+ <bounds x="36" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix622" element="dotmatrixdot" state="0">
+ <bounds x="37" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix623" element="dotmatrixdot" state="0">
+ <bounds x="38" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix624" element="dotmatrixdot" state="0">
+ <bounds x="39" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix625" element="dotmatrixdot" state="0">
+ <bounds x="40" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix626" element="dotmatrixdot" state="0">
+ <bounds x="41" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix627" element="dotmatrixdot" state="0">
+ <bounds x="42" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix628" element="dotmatrixdot" state="0">
+ <bounds x="43" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix629" element="dotmatrixdot" state="0">
+ <bounds x="44" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix630" element="dotmatrixdot" state="0">
+ <bounds x="45" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix631" element="dotmatrixdot" state="0">
+ <bounds x="46" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix632" element="dotmatrixdot" state="0">
+ <bounds x="47" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix633" element="dotmatrixdot" state="0">
+ <bounds x="48" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix634" element="dotmatrixdot" state="0">
+ <bounds x="49" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix635" element="dotmatrixdot" state="0">
+ <bounds x="50" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix636" element="dotmatrixdot" state="0">
+ <bounds x="51" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix637" element="dotmatrixdot" state="0">
+ <bounds x="52" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix638" element="dotmatrixdot" state="0">
+ <bounds x="53" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix639" element="dotmatrixdot" state="0">
+ <bounds x="54" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix640" element="dotmatrixdot" state="0">
+ <bounds x="55" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix641" element="dotmatrixdot" state="0">
+ <bounds x="56" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix642" element="dotmatrixdot" state="0">
+ <bounds x="57" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix643" element="dotmatrixdot" state="0">
+ <bounds x="58" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix644" element="dotmatrixdot" state="0">
+ <bounds x="59" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix645" element="dotmatrixdot" state="0">
+ <bounds x="60" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix646" element="dotmatrixdot" state="0">
+ <bounds x="61" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix647" element="dotmatrixdot" state="0">
+ <bounds x="62" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix648" element="dotmatrixdot" state="0">
+ <bounds x="63" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix649" element="dotmatrixdot" state="0">
+ <bounds x="64" y="9" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix650" element="dotmatrixdot" state="0">
+ <bounds x="0" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix651" element="dotmatrixdot" state="0">
+ <bounds x="1" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix652" element="dotmatrixdot" state="0">
+ <bounds x="2" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix653" element="dotmatrixdot" state="0">
+ <bounds x="3" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix654" element="dotmatrixdot" state="0">
+ <bounds x="4" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix655" element="dotmatrixdot" state="0">
+ <bounds x="5" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix656" element="dotmatrixdot" state="0">
+ <bounds x="6" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix657" element="dotmatrixdot" state="0">
+ <bounds x="7" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix658" element="dotmatrixdot" state="0">
+ <bounds x="8" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix659" element="dotmatrixdot" state="0">
+ <bounds x="9" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix660" element="dotmatrixdot" state="0">
+ <bounds x="10" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix661" element="dotmatrixdot" state="0">
+ <bounds x="11" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix662" element="dotmatrixdot" state="0">
+ <bounds x="12" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix663" element="dotmatrixdot" state="0">
+ <bounds x="13" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix664" element="dotmatrixdot" state="0">
+ <bounds x="14" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix665" element="dotmatrixdot" state="0">
+ <bounds x="15" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix666" element="dotmatrixdot" state="0">
+ <bounds x="16" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix667" element="dotmatrixdot" state="0">
+ <bounds x="17" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix668" element="dotmatrixdot" state="0">
+ <bounds x="18" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix669" element="dotmatrixdot" state="0">
+ <bounds x="19" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix670" element="dotmatrixdot" state="0">
+ <bounds x="20" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix671" element="dotmatrixdot" state="0">
+ <bounds x="21" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix672" element="dotmatrixdot" state="0">
+ <bounds x="22" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix673" element="dotmatrixdot" state="0">
+ <bounds x="23" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix674" element="dotmatrixdot" state="0">
+ <bounds x="24" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix675" element="dotmatrixdot" state="0">
+ <bounds x="25" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix676" element="dotmatrixdot" state="0">
+ <bounds x="26" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix677" element="dotmatrixdot" state="0">
+ <bounds x="27" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix678" element="dotmatrixdot" state="0">
+ <bounds x="28" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix679" element="dotmatrixdot" state="0">
+ <bounds x="29" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix680" element="dotmatrixdot" state="0">
+ <bounds x="30" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix681" element="dotmatrixdot" state="0">
+ <bounds x="31" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix682" element="dotmatrixdot" state="0">
+ <bounds x="32" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix683" element="dotmatrixdot" state="0">
+ <bounds x="33" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix684" element="dotmatrixdot" state="0">
+ <bounds x="34" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix685" element="dotmatrixdot" state="0">
+ <bounds x="35" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix686" element="dotmatrixdot" state="0">
+ <bounds x="36" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix687" element="dotmatrixdot" state="0">
+ <bounds x="37" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix688" element="dotmatrixdot" state="0">
+ <bounds x="38" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix689" element="dotmatrixdot" state="0">
+ <bounds x="39" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix690" element="dotmatrixdot" state="0">
+ <bounds x="40" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix691" element="dotmatrixdot" state="0">
+ <bounds x="41" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix692" element="dotmatrixdot" state="0">
+ <bounds x="42" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix693" element="dotmatrixdot" state="0">
+ <bounds x="43" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix694" element="dotmatrixdot" state="0">
+ <bounds x="44" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix695" element="dotmatrixdot" state="0">
+ <bounds x="45" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix696" element="dotmatrixdot" state="0">
+ <bounds x="46" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix697" element="dotmatrixdot" state="0">
+ <bounds x="47" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix698" element="dotmatrixdot" state="0">
+ <bounds x="48" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix699" element="dotmatrixdot" state="0">
+ <bounds x="49" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix700" element="dotmatrixdot" state="0">
+ <bounds x="50" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix701" element="dotmatrixdot" state="0">
+ <bounds x="51" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix702" element="dotmatrixdot" state="0">
+ <bounds x="52" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix703" element="dotmatrixdot" state="0">
+ <bounds x="53" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix704" element="dotmatrixdot" state="0">
+ <bounds x="54" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix705" element="dotmatrixdot" state="0">
+ <bounds x="55" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix706" element="dotmatrixdot" state="0">
+ <bounds x="56" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix707" element="dotmatrixdot" state="0">
+ <bounds x="57" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix708" element="dotmatrixdot" state="0">
+ <bounds x="58" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix709" element="dotmatrixdot" state="0">
+ <bounds x="59" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix710" element="dotmatrixdot" state="0">
+ <bounds x="60" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix711" element="dotmatrixdot" state="0">
+ <bounds x="61" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix712" element="dotmatrixdot" state="0">
+ <bounds x="62" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix713" element="dotmatrixdot" state="0">
+ <bounds x="63" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix714" element="dotmatrixdot" state="0">
+ <bounds x="64" y="10" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix715" element="dotmatrixdot" state="0">
+ <bounds x="0" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix716" element="dotmatrixdot" state="0">
+ <bounds x="1" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix717" element="dotmatrixdot" state="0">
+ <bounds x="2" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix718" element="dotmatrixdot" state="0">
+ <bounds x="3" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix719" element="dotmatrixdot" state="0">
+ <bounds x="4" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix720" element="dotmatrixdot" state="0">
+ <bounds x="5" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix721" element="dotmatrixdot" state="0">
+ <bounds x="6" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix722" element="dotmatrixdot" state="0">
+ <bounds x="7" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix723" element="dotmatrixdot" state="0">
+ <bounds x="8" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix724" element="dotmatrixdot" state="0">
+ <bounds x="9" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix725" element="dotmatrixdot" state="0">
+ <bounds x="10" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix726" element="dotmatrixdot" state="0">
+ <bounds x="11" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix727" element="dotmatrixdot" state="0">
+ <bounds x="12" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix728" element="dotmatrixdot" state="0">
+ <bounds x="13" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix729" element="dotmatrixdot" state="0">
+ <bounds x="14" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix730" element="dotmatrixdot" state="0">
+ <bounds x="15" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix731" element="dotmatrixdot" state="0">
+ <bounds x="16" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix732" element="dotmatrixdot" state="0">
+ <bounds x="17" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix733" element="dotmatrixdot" state="0">
+ <bounds x="18" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix734" element="dotmatrixdot" state="0">
+ <bounds x="19" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix735" element="dotmatrixdot" state="0">
+ <bounds x="20" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix736" element="dotmatrixdot" state="0">
+ <bounds x="21" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix737" element="dotmatrixdot" state="0">
+ <bounds x="22" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix738" element="dotmatrixdot" state="0">
+ <bounds x="23" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix739" element="dotmatrixdot" state="0">
+ <bounds x="24" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix740" element="dotmatrixdot" state="0">
+ <bounds x="25" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix741" element="dotmatrixdot" state="0">
+ <bounds x="26" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix742" element="dotmatrixdot" state="0">
+ <bounds x="27" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix743" element="dotmatrixdot" state="0">
+ <bounds x="28" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix744" element="dotmatrixdot" state="0">
+ <bounds x="29" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix745" element="dotmatrixdot" state="0">
+ <bounds x="30" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix746" element="dotmatrixdot" state="0">
+ <bounds x="31" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix747" element="dotmatrixdot" state="0">
+ <bounds x="32" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix748" element="dotmatrixdot" state="0">
+ <bounds x="33" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix749" element="dotmatrixdot" state="0">
+ <bounds x="34" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix750" element="dotmatrixdot" state="0">
+ <bounds x="35" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix751" element="dotmatrixdot" state="0">
+ <bounds x="36" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix752" element="dotmatrixdot" state="0">
+ <bounds x="37" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix753" element="dotmatrixdot" state="0">
+ <bounds x="38" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix754" element="dotmatrixdot" state="0">
+ <bounds x="39" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix755" element="dotmatrixdot" state="0">
+ <bounds x="40" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix756" element="dotmatrixdot" state="0">
+ <bounds x="41" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix757" element="dotmatrixdot" state="0">
+ <bounds x="42" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix758" element="dotmatrixdot" state="0">
+ <bounds x="43" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix759" element="dotmatrixdot" state="0">
+ <bounds x="44" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix760" element="dotmatrixdot" state="0">
+ <bounds x="45" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix761" element="dotmatrixdot" state="0">
+ <bounds x="46" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix762" element="dotmatrixdot" state="0">
+ <bounds x="47" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix763" element="dotmatrixdot" state="0">
+ <bounds x="48" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix764" element="dotmatrixdot" state="0">
+ <bounds x="49" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix765" element="dotmatrixdot" state="0">
+ <bounds x="50" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix766" element="dotmatrixdot" state="0">
+ <bounds x="51" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix767" element="dotmatrixdot" state="0">
+ <bounds x="52" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix768" element="dotmatrixdot" state="0">
+ <bounds x="53" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix769" element="dotmatrixdot" state="0">
+ <bounds x="54" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix770" element="dotmatrixdot" state="0">
+ <bounds x="55" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix771" element="dotmatrixdot" state="0">
+ <bounds x="56" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix772" element="dotmatrixdot" state="0">
+ <bounds x="57" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix773" element="dotmatrixdot" state="0">
+ <bounds x="58" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix774" element="dotmatrixdot" state="0">
+ <bounds x="59" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix775" element="dotmatrixdot" state="0">
+ <bounds x="60" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix776" element="dotmatrixdot" state="0">
+ <bounds x="61" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix777" element="dotmatrixdot" state="0">
+ <bounds x="62" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix778" element="dotmatrixdot" state="0">
+ <bounds x="63" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix779" element="dotmatrixdot" state="0">
+ <bounds x="64" y="11" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix780" element="dotmatrixdot" state="0">
+ <bounds x="0" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix781" element="dotmatrixdot" state="0">
+ <bounds x="1" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix782" element="dotmatrixdot" state="0">
+ <bounds x="2" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix783" element="dotmatrixdot" state="0">
+ <bounds x="3" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix784" element="dotmatrixdot" state="0">
+ <bounds x="4" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix785" element="dotmatrixdot" state="0">
+ <bounds x="5" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix786" element="dotmatrixdot" state="0">
+ <bounds x="6" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix787" element="dotmatrixdot" state="0">
+ <bounds x="7" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix788" element="dotmatrixdot" state="0">
+ <bounds x="8" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix789" element="dotmatrixdot" state="0">
+ <bounds x="9" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix790" element="dotmatrixdot" state="0">
+ <bounds x="10" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix791" element="dotmatrixdot" state="0">
+ <bounds x="11" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix792" element="dotmatrixdot" state="0">
+ <bounds x="12" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix793" element="dotmatrixdot" state="0">
+ <bounds x="13" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix794" element="dotmatrixdot" state="0">
+ <bounds x="14" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix795" element="dotmatrixdot" state="0">
+ <bounds x="15" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix796" element="dotmatrixdot" state="0">
+ <bounds x="16" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix797" element="dotmatrixdot" state="0">
+ <bounds x="17" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix798" element="dotmatrixdot" state="0">
+ <bounds x="18" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix799" element="dotmatrixdot" state="0">
+ <bounds x="19" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix800" element="dotmatrixdot" state="0">
+ <bounds x="20" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix801" element="dotmatrixdot" state="0">
+ <bounds x="21" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix802" element="dotmatrixdot" state="0">
+ <bounds x="22" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix803" element="dotmatrixdot" state="0">
+ <bounds x="23" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix804" element="dotmatrixdot" state="0">
+ <bounds x="24" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix805" element="dotmatrixdot" state="0">
+ <bounds x="25" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix806" element="dotmatrixdot" state="0">
+ <bounds x="26" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix807" element="dotmatrixdot" state="0">
+ <bounds x="27" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix808" element="dotmatrixdot" state="0">
+ <bounds x="28" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix809" element="dotmatrixdot" state="0">
+ <bounds x="29" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix810" element="dotmatrixdot" state="0">
+ <bounds x="30" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix811" element="dotmatrixdot" state="0">
+ <bounds x="31" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix812" element="dotmatrixdot" state="0">
+ <bounds x="32" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix813" element="dotmatrixdot" state="0">
+ <bounds x="33" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix814" element="dotmatrixdot" state="0">
+ <bounds x="34" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix815" element="dotmatrixdot" state="0">
+ <bounds x="35" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix816" element="dotmatrixdot" state="0">
+ <bounds x="36" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix817" element="dotmatrixdot" state="0">
+ <bounds x="37" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix818" element="dotmatrixdot" state="0">
+ <bounds x="38" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix819" element="dotmatrixdot" state="0">
+ <bounds x="39" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix820" element="dotmatrixdot" state="0">
+ <bounds x="40" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix821" element="dotmatrixdot" state="0">
+ <bounds x="41" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix822" element="dotmatrixdot" state="0">
+ <bounds x="42" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix823" element="dotmatrixdot" state="0">
+ <bounds x="43" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix824" element="dotmatrixdot" state="0">
+ <bounds x="44" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix825" element="dotmatrixdot" state="0">
+ <bounds x="45" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix826" element="dotmatrixdot" state="0">
+ <bounds x="46" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix827" element="dotmatrixdot" state="0">
+ <bounds x="47" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix828" element="dotmatrixdot" state="0">
+ <bounds x="48" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix829" element="dotmatrixdot" state="0">
+ <bounds x="49" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix830" element="dotmatrixdot" state="0">
+ <bounds x="50" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix831" element="dotmatrixdot" state="0">
+ <bounds x="51" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix832" element="dotmatrixdot" state="0">
+ <bounds x="52" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix833" element="dotmatrixdot" state="0">
+ <bounds x="53" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix834" element="dotmatrixdot" state="0">
+ <bounds x="54" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix835" element="dotmatrixdot" state="0">
+ <bounds x="55" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix836" element="dotmatrixdot" state="0">
+ <bounds x="56" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix837" element="dotmatrixdot" state="0">
+ <bounds x="57" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix838" element="dotmatrixdot" state="0">
+ <bounds x="58" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix839" element="dotmatrixdot" state="0">
+ <bounds x="59" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix840" element="dotmatrixdot" state="0">
+ <bounds x="60" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix841" element="dotmatrixdot" state="0">
+ <bounds x="61" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix842" element="dotmatrixdot" state="0">
+ <bounds x="62" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix843" element="dotmatrixdot" state="0">
+ <bounds x="63" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix844" element="dotmatrixdot" state="0">
+ <bounds x="64" y="12" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix845" element="dotmatrixdot" state="0">
+ <bounds x="0" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix846" element="dotmatrixdot" state="0">
+ <bounds x="1" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix847" element="dotmatrixdot" state="0">
+ <bounds x="2" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix848" element="dotmatrixdot" state="0">
+ <bounds x="3" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix849" element="dotmatrixdot" state="0">
+ <bounds x="4" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix850" element="dotmatrixdot" state="0">
+ <bounds x="5" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix851" element="dotmatrixdot" state="0">
+ <bounds x="6" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix852" element="dotmatrixdot" state="0">
+ <bounds x="7" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix853" element="dotmatrixdot" state="0">
+ <bounds x="8" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix854" element="dotmatrixdot" state="0">
+ <bounds x="9" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix855" element="dotmatrixdot" state="0">
+ <bounds x="10" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix856" element="dotmatrixdot" state="0">
+ <bounds x="11" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix857" element="dotmatrixdot" state="0">
+ <bounds x="12" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix858" element="dotmatrixdot" state="0">
+ <bounds x="13" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix859" element="dotmatrixdot" state="0">
+ <bounds x="14" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix860" element="dotmatrixdot" state="0">
+ <bounds x="15" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix861" element="dotmatrixdot" state="0">
+ <bounds x="16" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix862" element="dotmatrixdot" state="0">
+ <bounds x="17" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix863" element="dotmatrixdot" state="0">
+ <bounds x="18" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix864" element="dotmatrixdot" state="0">
+ <bounds x="19" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix865" element="dotmatrixdot" state="0">
+ <bounds x="20" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix866" element="dotmatrixdot" state="0">
+ <bounds x="21" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix867" element="dotmatrixdot" state="0">
+ <bounds x="22" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix868" element="dotmatrixdot" state="0">
+ <bounds x="23" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix869" element="dotmatrixdot" state="0">
+ <bounds x="24" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix870" element="dotmatrixdot" state="0">
+ <bounds x="25" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix871" element="dotmatrixdot" state="0">
+ <bounds x="26" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix872" element="dotmatrixdot" state="0">
+ <bounds x="27" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix873" element="dotmatrixdot" state="0">
+ <bounds x="28" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix874" element="dotmatrixdot" state="0">
+ <bounds x="29" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix875" element="dotmatrixdot" state="0">
+ <bounds x="30" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix876" element="dotmatrixdot" state="0">
+ <bounds x="31" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix877" element="dotmatrixdot" state="0">
+ <bounds x="32" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix878" element="dotmatrixdot" state="0">
+ <bounds x="33" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix879" element="dotmatrixdot" state="0">
+ <bounds x="34" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix880" element="dotmatrixdot" state="0">
+ <bounds x="35" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix881" element="dotmatrixdot" state="0">
+ <bounds x="36" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix882" element="dotmatrixdot" state="0">
+ <bounds x="37" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix883" element="dotmatrixdot" state="0">
+ <bounds x="38" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix884" element="dotmatrixdot" state="0">
+ <bounds x="39" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix885" element="dotmatrixdot" state="0">
+ <bounds x="40" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix886" element="dotmatrixdot" state="0">
+ <bounds x="41" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix887" element="dotmatrixdot" state="0">
+ <bounds x="42" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix888" element="dotmatrixdot" state="0">
+ <bounds x="43" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix889" element="dotmatrixdot" state="0">
+ <bounds x="44" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix890" element="dotmatrixdot" state="0">
+ <bounds x="45" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix891" element="dotmatrixdot" state="0">
+ <bounds x="46" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix892" element="dotmatrixdot" state="0">
+ <bounds x="47" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix893" element="dotmatrixdot" state="0">
+ <bounds x="48" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix894" element="dotmatrixdot" state="0">
+ <bounds x="49" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix895" element="dotmatrixdot" state="0">
+ <bounds x="50" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix896" element="dotmatrixdot" state="0">
+ <bounds x="51" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix897" element="dotmatrixdot" state="0">
+ <bounds x="52" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix898" element="dotmatrixdot" state="0">
+ <bounds x="53" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix899" element="dotmatrixdot" state="0">
+ <bounds x="54" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix900" element="dotmatrixdot" state="0">
+ <bounds x="55" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix901" element="dotmatrixdot" state="0">
+ <bounds x="56" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix902" element="dotmatrixdot" state="0">
+ <bounds x="57" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix903" element="dotmatrixdot" state="0">
+ <bounds x="58" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix904" element="dotmatrixdot" state="0">
+ <bounds x="59" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix905" element="dotmatrixdot" state="0">
+ <bounds x="60" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix906" element="dotmatrixdot" state="0">
+ <bounds x="61" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix907" element="dotmatrixdot" state="0">
+ <bounds x="62" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix908" element="dotmatrixdot" state="0">
+ <bounds x="63" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix909" element="dotmatrixdot" state="0">
+ <bounds x="64" y="13" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix910" element="dotmatrixdot" state="0">
+ <bounds x="0" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix911" element="dotmatrixdot" state="0">
+ <bounds x="1" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix912" element="dotmatrixdot" state="0">
+ <bounds x="2" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix913" element="dotmatrixdot" state="0">
+ <bounds x="3" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix914" element="dotmatrixdot" state="0">
+ <bounds x="4" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix915" element="dotmatrixdot" state="0">
+ <bounds x="5" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix916" element="dotmatrixdot" state="0">
+ <bounds x="6" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix917" element="dotmatrixdot" state="0">
+ <bounds x="7" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix918" element="dotmatrixdot" state="0">
+ <bounds x="8" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix919" element="dotmatrixdot" state="0">
+ <bounds x="9" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix920" element="dotmatrixdot" state="0">
+ <bounds x="10" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix921" element="dotmatrixdot" state="0">
+ <bounds x="11" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix922" element="dotmatrixdot" state="0">
+ <bounds x="12" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix923" element="dotmatrixdot" state="0">
+ <bounds x="13" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix924" element="dotmatrixdot" state="0">
+ <bounds x="14" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix925" element="dotmatrixdot" state="0">
+ <bounds x="15" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix926" element="dotmatrixdot" state="0">
+ <bounds x="16" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix927" element="dotmatrixdot" state="0">
+ <bounds x="17" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix928" element="dotmatrixdot" state="0">
+ <bounds x="18" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix929" element="dotmatrixdot" state="0">
+ <bounds x="19" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix930" element="dotmatrixdot" state="0">
+ <bounds x="20" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix931" element="dotmatrixdot" state="0">
+ <bounds x="21" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix932" element="dotmatrixdot" state="0">
+ <bounds x="22" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix933" element="dotmatrixdot" state="0">
+ <bounds x="23" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix934" element="dotmatrixdot" state="0">
+ <bounds x="24" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix935" element="dotmatrixdot" state="0">
+ <bounds x="25" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix936" element="dotmatrixdot" state="0">
+ <bounds x="26" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix937" element="dotmatrixdot" state="0">
+ <bounds x="27" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix938" element="dotmatrixdot" state="0">
+ <bounds x="28" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix939" element="dotmatrixdot" state="0">
+ <bounds x="29" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix940" element="dotmatrixdot" state="0">
+ <bounds x="30" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix941" element="dotmatrixdot" state="0">
+ <bounds x="31" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix942" element="dotmatrixdot" state="0">
+ <bounds x="32" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix943" element="dotmatrixdot" state="0">
+ <bounds x="33" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix944" element="dotmatrixdot" state="0">
+ <bounds x="34" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix945" element="dotmatrixdot" state="0">
+ <bounds x="35" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix946" element="dotmatrixdot" state="0">
+ <bounds x="36" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix947" element="dotmatrixdot" state="0">
+ <bounds x="37" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix948" element="dotmatrixdot" state="0">
+ <bounds x="38" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix949" element="dotmatrixdot" state="0">
+ <bounds x="39" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix950" element="dotmatrixdot" state="0">
+ <bounds x="40" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix951" element="dotmatrixdot" state="0">
+ <bounds x="41" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix952" element="dotmatrixdot" state="0">
+ <bounds x="42" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix953" element="dotmatrixdot" state="0">
+ <bounds x="43" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix954" element="dotmatrixdot" state="0">
+ <bounds x="44" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix955" element="dotmatrixdot" state="0">
+ <bounds x="45" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix956" element="dotmatrixdot" state="0">
+ <bounds x="46" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix957" element="dotmatrixdot" state="0">
+ <bounds x="47" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix958" element="dotmatrixdot" state="0">
+ <bounds x="48" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix959" element="dotmatrixdot" state="0">
+ <bounds x="49" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix960" element="dotmatrixdot" state="0">
+ <bounds x="50" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix961" element="dotmatrixdot" state="0">
+ <bounds x="51" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix962" element="dotmatrixdot" state="0">
+ <bounds x="52" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix963" element="dotmatrixdot" state="0">
+ <bounds x="53" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix964" element="dotmatrixdot" state="0">
+ <bounds x="54" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix965" element="dotmatrixdot" state="0">
+ <bounds x="55" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix966" element="dotmatrixdot" state="0">
+ <bounds x="56" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix967" element="dotmatrixdot" state="0">
+ <bounds x="57" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix968" element="dotmatrixdot" state="0">
+ <bounds x="58" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix969" element="dotmatrixdot" state="0">
+ <bounds x="59" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix970" element="dotmatrixdot" state="0">
+ <bounds x="60" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix971" element="dotmatrixdot" state="0">
+ <bounds x="61" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix972" element="dotmatrixdot" state="0">
+ <bounds x="62" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix973" element="dotmatrixdot" state="0">
+ <bounds x="63" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix974" element="dotmatrixdot" state="0">
+ <bounds x="64" y="14" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix975" element="dotmatrixdot" state="0">
+ <bounds x="0" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix976" element="dotmatrixdot" state="0">
+ <bounds x="1" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix977" element="dotmatrixdot" state="0">
+ <bounds x="2" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix978" element="dotmatrixdot" state="0">
+ <bounds x="3" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix979" element="dotmatrixdot" state="0">
+ <bounds x="4" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix980" element="dotmatrixdot" state="0">
+ <bounds x="5" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix981" element="dotmatrixdot" state="0">
+ <bounds x="6" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix982" element="dotmatrixdot" state="0">
+ <bounds x="7" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix983" element="dotmatrixdot" state="0">
+ <bounds x="8" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix984" element="dotmatrixdot" state="0">
+ <bounds x="9" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix985" element="dotmatrixdot" state="0">
+ <bounds x="10" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix986" element="dotmatrixdot" state="0">
+ <bounds x="11" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix987" element="dotmatrixdot" state="0">
+ <bounds x="12" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix988" element="dotmatrixdot" state="0">
+ <bounds x="13" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix989" element="dotmatrixdot" state="0">
+ <bounds x="14" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix990" element="dotmatrixdot" state="0">
+ <bounds x="15" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix991" element="dotmatrixdot" state="0">
+ <bounds x="16" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix992" element="dotmatrixdot" state="0">
+ <bounds x="17" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix993" element="dotmatrixdot" state="0">
+ <bounds x="18" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix994" element="dotmatrixdot" state="0">
+ <bounds x="19" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix995" element="dotmatrixdot" state="0">
+ <bounds x="20" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix996" element="dotmatrixdot" state="0">
+ <bounds x="21" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix997" element="dotmatrixdot" state="0">
+ <bounds x="22" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix998" element="dotmatrixdot" state="0">
+ <bounds x="23" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix999" element="dotmatrixdot" state="0">
+ <bounds x="24" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1000" element="dotmatrixdot" state="0">
+ <bounds x="25" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1001" element="dotmatrixdot" state="0">
+ <bounds x="26" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1002" element="dotmatrixdot" state="0">
+ <bounds x="27" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1003" element="dotmatrixdot" state="0">
+ <bounds x="28" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1004" element="dotmatrixdot" state="0">
+ <bounds x="29" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1005" element="dotmatrixdot" state="0">
+ <bounds x="30" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1006" element="dotmatrixdot" state="0">
+ <bounds x="31" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1007" element="dotmatrixdot" state="0">
+ <bounds x="32" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1008" element="dotmatrixdot" state="0">
+ <bounds x="33" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1009" element="dotmatrixdot" state="0">
+ <bounds x="34" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1010" element="dotmatrixdot" state="0">
+ <bounds x="35" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1011" element="dotmatrixdot" state="0">
+ <bounds x="36" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1012" element="dotmatrixdot" state="0">
+ <bounds x="37" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1013" element="dotmatrixdot" state="0">
+ <bounds x="38" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1014" element="dotmatrixdot" state="0">
+ <bounds x="39" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1015" element="dotmatrixdot" state="0">
+ <bounds x="40" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1016" element="dotmatrixdot" state="0">
+ <bounds x="41" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1017" element="dotmatrixdot" state="0">
+ <bounds x="42" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1018" element="dotmatrixdot" state="0">
+ <bounds x="43" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1019" element="dotmatrixdot" state="0">
+ <bounds x="44" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1020" element="dotmatrixdot" state="0">
+ <bounds x="45" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1021" element="dotmatrixdot" state="0">
+ <bounds x="46" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1022" element="dotmatrixdot" state="0">
+ <bounds x="47" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1023" element="dotmatrixdot" state="0">
+ <bounds x="48" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1024" element="dotmatrixdot" state="0">
+ <bounds x="49" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1025" element="dotmatrixdot" state="0">
+ <bounds x="50" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1026" element="dotmatrixdot" state="0">
+ <bounds x="51" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1027" element="dotmatrixdot" state="0">
+ <bounds x="52" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1028" element="dotmatrixdot" state="0">
+ <bounds x="53" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1029" element="dotmatrixdot" state="0">
+ <bounds x="54" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1030" element="dotmatrixdot" state="0">
+ <bounds x="55" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1031" element="dotmatrixdot" state="0">
+ <bounds x="56" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1032" element="dotmatrixdot" state="0">
+ <bounds x="57" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1033" element="dotmatrixdot" state="0">
+ <bounds x="58" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1034" element="dotmatrixdot" state="0">
+ <bounds x="59" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1035" element="dotmatrixdot" state="0">
+ <bounds x="60" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1036" element="dotmatrixdot" state="0">
+ <bounds x="61" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1037" element="dotmatrixdot" state="0">
+ <bounds x="62" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1038" element="dotmatrixdot" state="0">
+ <bounds x="63" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1039" element="dotmatrixdot" state="0">
+ <bounds x="64" y="15" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1040" element="dotmatrixdot" state="0">
+ <bounds x="0" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1041" element="dotmatrixdot" state="0">
+ <bounds x="1" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1042" element="dotmatrixdot" state="0">
+ <bounds x="2" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1043" element="dotmatrixdot" state="0">
+ <bounds x="3" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1044" element="dotmatrixdot" state="0">
+ <bounds x="4" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1045" element="dotmatrixdot" state="0">
+ <bounds x="5" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1046" element="dotmatrixdot" state="0">
+ <bounds x="6" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1047" element="dotmatrixdot" state="0">
+ <bounds x="7" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1048" element="dotmatrixdot" state="0">
+ <bounds x="8" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1049" element="dotmatrixdot" state="0">
+ <bounds x="9" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1050" element="dotmatrixdot" state="0">
+ <bounds x="10" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1051" element="dotmatrixdot" state="0">
+ <bounds x="11" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1052" element="dotmatrixdot" state="0">
+ <bounds x="12" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1053" element="dotmatrixdot" state="0">
+ <bounds x="13" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1054" element="dotmatrixdot" state="0">
+ <bounds x="14" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1055" element="dotmatrixdot" state="0">
+ <bounds x="15" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1056" element="dotmatrixdot" state="0">
+ <bounds x="16" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1057" element="dotmatrixdot" state="0">
+ <bounds x="17" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1058" element="dotmatrixdot" state="0">
+ <bounds x="18" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1059" element="dotmatrixdot" state="0">
+ <bounds x="19" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1060" element="dotmatrixdot" state="0">
+ <bounds x="20" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1061" element="dotmatrixdot" state="0">
+ <bounds x="21" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1062" element="dotmatrixdot" state="0">
+ <bounds x="22" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1063" element="dotmatrixdot" state="0">
+ <bounds x="23" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1064" element="dotmatrixdot" state="0">
+ <bounds x="24" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1065" element="dotmatrixdot" state="0">
+ <bounds x="25" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1066" element="dotmatrixdot" state="0">
+ <bounds x="26" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1067" element="dotmatrixdot" state="0">
+ <bounds x="27" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1068" element="dotmatrixdot" state="0">
+ <bounds x="28" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1069" element="dotmatrixdot" state="0">
+ <bounds x="29" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1070" element="dotmatrixdot" state="0">
+ <bounds x="30" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1071" element="dotmatrixdot" state="0">
+ <bounds x="31" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1072" element="dotmatrixdot" state="0">
+ <bounds x="32" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1073" element="dotmatrixdot" state="0">
+ <bounds x="33" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1074" element="dotmatrixdot" state="0">
+ <bounds x="34" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1075" element="dotmatrixdot" state="0">
+ <bounds x="35" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1076" element="dotmatrixdot" state="0">
+ <bounds x="36" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1077" element="dotmatrixdot" state="0">
+ <bounds x="37" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1078" element="dotmatrixdot" state="0">
+ <bounds x="38" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1079" element="dotmatrixdot" state="0">
+ <bounds x="39" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1080" element="dotmatrixdot" state="0">
+ <bounds x="40" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1081" element="dotmatrixdot" state="0">
+ <bounds x="41" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1082" element="dotmatrixdot" state="0">
+ <bounds x="42" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1083" element="dotmatrixdot" state="0">
+ <bounds x="43" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1084" element="dotmatrixdot" state="0">
+ <bounds x="44" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1085" element="dotmatrixdot" state="0">
+ <bounds x="45" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1086" element="dotmatrixdot" state="0">
+ <bounds x="46" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1087" element="dotmatrixdot" state="0">
+ <bounds x="47" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1088" element="dotmatrixdot" state="0">
+ <bounds x="48" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1089" element="dotmatrixdot" state="0">
+ <bounds x="49" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1090" element="dotmatrixdot" state="0">
+ <bounds x="50" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1091" element="dotmatrixdot" state="0">
+ <bounds x="51" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1092" element="dotmatrixdot" state="0">
+ <bounds x="52" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1093" element="dotmatrixdot" state="0">
+ <bounds x="53" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1094" element="dotmatrixdot" state="0">
+ <bounds x="54" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1095" element="dotmatrixdot" state="0">
+ <bounds x="55" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1096" element="dotmatrixdot" state="0">
+ <bounds x="56" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1097" element="dotmatrixdot" state="0">
+ <bounds x="57" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1098" element="dotmatrixdot" state="0">
+ <bounds x="58" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1099" element="dotmatrixdot" state="0">
+ <bounds x="59" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1100" element="dotmatrixdot" state="0">
+ <bounds x="60" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1101" element="dotmatrixdot" state="0">
+ <bounds x="61" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1102" element="dotmatrixdot" state="0">
+ <bounds x="62" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1103" element="dotmatrixdot" state="0">
+ <bounds x="63" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1104" element="dotmatrixdot" state="0">
+ <bounds x="64" y="16" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1105" element="dotmatrixdot" state="0">
+ <bounds x="0" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1106" element="dotmatrixdot" state="0">
+ <bounds x="1" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1107" element="dotmatrixdot" state="0">
+ <bounds x="2" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1108" element="dotmatrixdot" state="0">
+ <bounds x="3" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1109" element="dotmatrixdot" state="0">
+ <bounds x="4" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1110" element="dotmatrixdot" state="0">
+ <bounds x="5" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1111" element="dotmatrixdot" state="0">
+ <bounds x="6" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1112" element="dotmatrixdot" state="0">
+ <bounds x="7" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1113" element="dotmatrixdot" state="0">
+ <bounds x="8" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1114" element="dotmatrixdot" state="0">
+ <bounds x="9" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1115" element="dotmatrixdot" state="0">
+ <bounds x="10" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1116" element="dotmatrixdot" state="0">
+ <bounds x="11" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1117" element="dotmatrixdot" state="0">
+ <bounds x="12" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1118" element="dotmatrixdot" state="0">
+ <bounds x="13" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1119" element="dotmatrixdot" state="0">
+ <bounds x="14" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1120" element="dotmatrixdot" state="0">
+ <bounds x="15" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1121" element="dotmatrixdot" state="0">
+ <bounds x="16" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1122" element="dotmatrixdot" state="0">
+ <bounds x="17" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1123" element="dotmatrixdot" state="0">
+ <bounds x="18" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1124" element="dotmatrixdot" state="0">
+ <bounds x="19" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1125" element="dotmatrixdot" state="0">
+ <bounds x="20" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1126" element="dotmatrixdot" state="0">
+ <bounds x="21" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1127" element="dotmatrixdot" state="0">
+ <bounds x="22" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1128" element="dotmatrixdot" state="0">
+ <bounds x="23" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1129" element="dotmatrixdot" state="0">
+ <bounds x="24" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1130" element="dotmatrixdot" state="0">
+ <bounds x="25" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1131" element="dotmatrixdot" state="0">
+ <bounds x="26" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1132" element="dotmatrixdot" state="0">
+ <bounds x="27" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1133" element="dotmatrixdot" state="0">
+ <bounds x="28" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1134" element="dotmatrixdot" state="0">
+ <bounds x="29" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1135" element="dotmatrixdot" state="0">
+ <bounds x="30" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1136" element="dotmatrixdot" state="0">
+ <bounds x="31" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1137" element="dotmatrixdot" state="0">
+ <bounds x="32" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1138" element="dotmatrixdot" state="0">
+ <bounds x="33" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1139" element="dotmatrixdot" state="0">
+ <bounds x="34" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1140" element="dotmatrixdot" state="0">
+ <bounds x="35" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1141" element="dotmatrixdot" state="0">
+ <bounds x="36" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1142" element="dotmatrixdot" state="0">
+ <bounds x="37" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1143" element="dotmatrixdot" state="0">
+ <bounds x="38" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1144" element="dotmatrixdot" state="0">
+ <bounds x="39" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1145" element="dotmatrixdot" state="0">
+ <bounds x="40" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1146" element="dotmatrixdot" state="0">
+ <bounds x="41" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1147" element="dotmatrixdot" state="0">
+ <bounds x="42" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1148" element="dotmatrixdot" state="0">
+ <bounds x="43" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1149" element="dotmatrixdot" state="0">
+ <bounds x="44" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1150" element="dotmatrixdot" state="0">
+ <bounds x="45" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1151" element="dotmatrixdot" state="0">
+ <bounds x="46" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1152" element="dotmatrixdot" state="0">
+ <bounds x="47" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1153" element="dotmatrixdot" state="0">
+ <bounds x="48" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1154" element="dotmatrixdot" state="0">
+ <bounds x="49" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1155" element="dotmatrixdot" state="0">
+ <bounds x="50" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1156" element="dotmatrixdot" state="0">
+ <bounds x="51" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1157" element="dotmatrixdot" state="0">
+ <bounds x="52" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1158" element="dotmatrixdot" state="0">
+ <bounds x="53" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1159" element="dotmatrixdot" state="0">
+ <bounds x="54" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1160" element="dotmatrixdot" state="0">
+ <bounds x="55" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1161" element="dotmatrixdot" state="0">
+ <bounds x="56" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1162" element="dotmatrixdot" state="0">
+ <bounds x="57" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1163" element="dotmatrixdot" state="0">
+ <bounds x="58" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1164" element="dotmatrixdot" state="0">
+ <bounds x="59" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1165" element="dotmatrixdot" state="0">
+ <bounds x="60" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1166" element="dotmatrixdot" state="0">
+ <bounds x="61" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1167" element="dotmatrixdot" state="0">
+ <bounds x="62" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1168" element="dotmatrixdot" state="0">
+ <bounds x="63" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1169" element="dotmatrixdot" state="0">
+ <bounds x="64" y="17" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1170" element="dotmatrixdot" state="0">
+ <bounds x="0" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1171" element="dotmatrixdot" state="0">
+ <bounds x="1" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1172" element="dotmatrixdot" state="0">
+ <bounds x="2" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1173" element="dotmatrixdot" state="0">
+ <bounds x="3" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1174" element="dotmatrixdot" state="0">
+ <bounds x="4" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1175" element="dotmatrixdot" state="0">
+ <bounds x="5" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1176" element="dotmatrixdot" state="0">
+ <bounds x="6" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1177" element="dotmatrixdot" state="0">
+ <bounds x="7" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1178" element="dotmatrixdot" state="0">
+ <bounds x="8" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1179" element="dotmatrixdot" state="0">
+ <bounds x="9" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1180" element="dotmatrixdot" state="0">
+ <bounds x="10" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1181" element="dotmatrixdot" state="0">
+ <bounds x="11" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1182" element="dotmatrixdot" state="0">
+ <bounds x="12" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1183" element="dotmatrixdot" state="0">
+ <bounds x="13" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1184" element="dotmatrixdot" state="0">
+ <bounds x="14" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1185" element="dotmatrixdot" state="0">
+ <bounds x="15" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1186" element="dotmatrixdot" state="0">
+ <bounds x="16" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1187" element="dotmatrixdot" state="0">
+ <bounds x="17" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1188" element="dotmatrixdot" state="0">
+ <bounds x="18" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1189" element="dotmatrixdot" state="0">
+ <bounds x="19" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1190" element="dotmatrixdot" state="0">
+ <bounds x="20" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1191" element="dotmatrixdot" state="0">
+ <bounds x="21" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1192" element="dotmatrixdot" state="0">
+ <bounds x="22" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1193" element="dotmatrixdot" state="0">
+ <bounds x="23" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1194" element="dotmatrixdot" state="0">
+ <bounds x="24" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1195" element="dotmatrixdot" state="0">
+ <bounds x="25" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1196" element="dotmatrixdot" state="0">
+ <bounds x="26" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1197" element="dotmatrixdot" state="0">
+ <bounds x="27" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1198" element="dotmatrixdot" state="0">
+ <bounds x="28" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1199" element="dotmatrixdot" state="0">
+ <bounds x="29" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1200" element="dotmatrixdot" state="0">
+ <bounds x="30" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1201" element="dotmatrixdot" state="0">
+ <bounds x="31" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1202" element="dotmatrixdot" state="0">
+ <bounds x="32" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1203" element="dotmatrixdot" state="0">
+ <bounds x="33" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1204" element="dotmatrixdot" state="0">
+ <bounds x="34" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1205" element="dotmatrixdot" state="0">
+ <bounds x="35" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1206" element="dotmatrixdot" state="0">
+ <bounds x="36" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1207" element="dotmatrixdot" state="0">
+ <bounds x="37" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1208" element="dotmatrixdot" state="0">
+ <bounds x="38" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1209" element="dotmatrixdot" state="0">
+ <bounds x="39" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1210" element="dotmatrixdot" state="0">
+ <bounds x="40" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1211" element="dotmatrixdot" state="0">
+ <bounds x="41" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1212" element="dotmatrixdot" state="0">
+ <bounds x="42" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1213" element="dotmatrixdot" state="0">
+ <bounds x="43" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1214" element="dotmatrixdot" state="0">
+ <bounds x="44" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1215" element="dotmatrixdot" state="0">
+ <bounds x="45" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1216" element="dotmatrixdot" state="0">
+ <bounds x="46" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1217" element="dotmatrixdot" state="0">
+ <bounds x="47" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1218" element="dotmatrixdot" state="0">
+ <bounds x="48" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1219" element="dotmatrixdot" state="0">
+ <bounds x="49" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1220" element="dotmatrixdot" state="0">
+ <bounds x="50" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1221" element="dotmatrixdot" state="0">
+ <bounds x="51" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1222" element="dotmatrixdot" state="0">
+ <bounds x="52" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1223" element="dotmatrixdot" state="0">
+ <bounds x="53" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1224" element="dotmatrixdot" state="0">
+ <bounds x="54" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1225" element="dotmatrixdot" state="0">
+ <bounds x="55" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1226" element="dotmatrixdot" state="0">
+ <bounds x="56" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1227" element="dotmatrixdot" state="0">
+ <bounds x="57" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1228" element="dotmatrixdot" state="0">
+ <bounds x="58" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1229" element="dotmatrixdot" state="0">
+ <bounds x="59" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1230" element="dotmatrixdot" state="0">
+ <bounds x="60" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1231" element="dotmatrixdot" state="0">
+ <bounds x="61" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1232" element="dotmatrixdot" state="0">
+ <bounds x="62" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1233" element="dotmatrixdot" state="0">
+ <bounds x="63" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1234" element="dotmatrixdot" state="0">
+ <bounds x="64" y="18" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1235" element="dotmatrixdot" state="0">
+ <bounds x="0" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1236" element="dotmatrixdot" state="0">
+ <bounds x="1" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1237" element="dotmatrixdot" state="0">
+ <bounds x="2" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1238" element="dotmatrixdot" state="0">
+ <bounds x="3" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1239" element="dotmatrixdot" state="0">
+ <bounds x="4" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1240" element="dotmatrixdot" state="0">
+ <bounds x="5" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1241" element="dotmatrixdot" state="0">
+ <bounds x="6" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1242" element="dotmatrixdot" state="0">
+ <bounds x="7" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1243" element="dotmatrixdot" state="0">
+ <bounds x="8" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1244" element="dotmatrixdot" state="0">
+ <bounds x="9" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1245" element="dotmatrixdot" state="0">
+ <bounds x="10" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1246" element="dotmatrixdot" state="0">
+ <bounds x="11" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1247" element="dotmatrixdot" state="0">
+ <bounds x="12" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1248" element="dotmatrixdot" state="0">
+ <bounds x="13" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1249" element="dotmatrixdot" state="0">
+ <bounds x="14" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1250" element="dotmatrixdot" state="0">
+ <bounds x="15" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1251" element="dotmatrixdot" state="0">
+ <bounds x="16" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1252" element="dotmatrixdot" state="0">
+ <bounds x="17" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1253" element="dotmatrixdot" state="0">
+ <bounds x="18" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1254" element="dotmatrixdot" state="0">
+ <bounds x="19" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1255" element="dotmatrixdot" state="0">
+ <bounds x="20" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1256" element="dotmatrixdot" state="0">
+ <bounds x="21" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1257" element="dotmatrixdot" state="0">
+ <bounds x="22" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1258" element="dotmatrixdot" state="0">
+ <bounds x="23" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1259" element="dotmatrixdot" state="0">
+ <bounds x="24" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1260" element="dotmatrixdot" state="0">
+ <bounds x="25" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1261" element="dotmatrixdot" state="0">
+ <bounds x="26" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1262" element="dotmatrixdot" state="0">
+ <bounds x="27" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1263" element="dotmatrixdot" state="0">
+ <bounds x="28" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1264" element="dotmatrixdot" state="0">
+ <bounds x="29" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1265" element="dotmatrixdot" state="0">
+ <bounds x="30" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1266" element="dotmatrixdot" state="0">
+ <bounds x="31" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1267" element="dotmatrixdot" state="0">
+ <bounds x="32" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1268" element="dotmatrixdot" state="0">
+ <bounds x="33" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1269" element="dotmatrixdot" state="0">
+ <bounds x="34" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1270" element="dotmatrixdot" state="0">
+ <bounds x="35" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1271" element="dotmatrixdot" state="0">
+ <bounds x="36" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1272" element="dotmatrixdot" state="0">
+ <bounds x="37" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1273" element="dotmatrixdot" state="0">
+ <bounds x="38" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1274" element="dotmatrixdot" state="0">
+ <bounds x="39" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1275" element="dotmatrixdot" state="0">
+ <bounds x="40" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1276" element="dotmatrixdot" state="0">
+ <bounds x="41" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1277" element="dotmatrixdot" state="0">
+ <bounds x="42" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1278" element="dotmatrixdot" state="0">
+ <bounds x="43" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1279" element="dotmatrixdot" state="0">
+ <bounds x="44" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1280" element="dotmatrixdot" state="0">
+ <bounds x="45" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1281" element="dotmatrixdot" state="0">
+ <bounds x="46" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1282" element="dotmatrixdot" state="0">
+ <bounds x="47" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1283" element="dotmatrixdot" state="0">
+ <bounds x="48" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1284" element="dotmatrixdot" state="0">
+ <bounds x="49" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1285" element="dotmatrixdot" state="0">
+ <bounds x="50" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1286" element="dotmatrixdot" state="0">
+ <bounds x="51" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1287" element="dotmatrixdot" state="0">
+ <bounds x="52" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1288" element="dotmatrixdot" state="0">
+ <bounds x="53" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1289" element="dotmatrixdot" state="0">
+ <bounds x="54" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1290" element="dotmatrixdot" state="0">
+ <bounds x="55" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1291" element="dotmatrixdot" state="0">
+ <bounds x="56" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1292" element="dotmatrixdot" state="0">
+ <bounds x="57" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1293" element="dotmatrixdot" state="0">
+ <bounds x="58" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1294" element="dotmatrixdot" state="0">
+ <bounds x="59" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1295" element="dotmatrixdot" state="0">
+ <bounds x="60" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1296" element="dotmatrixdot" state="0">
+ <bounds x="61" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1297" element="dotmatrixdot" state="0">
+ <bounds x="62" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1298" element="dotmatrixdot" state="0">
+ <bounds x="63" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1299" element="dotmatrixdot" state="0">
+ <bounds x="64" y="19" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1300" element="dotmatrixdot" state="0">
+ <bounds x="0" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1301" element="dotmatrixdot" state="0">
+ <bounds x="1" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1302" element="dotmatrixdot" state="0">
+ <bounds x="2" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1303" element="dotmatrixdot" state="0">
+ <bounds x="3" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1304" element="dotmatrixdot" state="0">
+ <bounds x="4" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1305" element="dotmatrixdot" state="0">
+ <bounds x="5" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1306" element="dotmatrixdot" state="0">
+ <bounds x="6" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1307" element="dotmatrixdot" state="0">
+ <bounds x="7" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1308" element="dotmatrixdot" state="0">
+ <bounds x="8" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1309" element="dotmatrixdot" state="0">
+ <bounds x="9" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1310" element="dotmatrixdot" state="0">
+ <bounds x="10" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1311" element="dotmatrixdot" state="0">
+ <bounds x="11" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1312" element="dotmatrixdot" state="0">
+ <bounds x="12" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1313" element="dotmatrixdot" state="0">
+ <bounds x="13" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1314" element="dotmatrixdot" state="0">
+ <bounds x="14" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1315" element="dotmatrixdot" state="0">
+ <bounds x="15" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1316" element="dotmatrixdot" state="0">
+ <bounds x="16" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1317" element="dotmatrixdot" state="0">
+ <bounds x="17" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1318" element="dotmatrixdot" state="0">
+ <bounds x="18" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1319" element="dotmatrixdot" state="0">
+ <bounds x="19" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1320" element="dotmatrixdot" state="0">
+ <bounds x="20" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1321" element="dotmatrixdot" state="0">
+ <bounds x="21" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1322" element="dotmatrixdot" state="0">
+ <bounds x="22" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1323" element="dotmatrixdot" state="0">
+ <bounds x="23" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1324" element="dotmatrixdot" state="0">
+ <bounds x="24" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1325" element="dotmatrixdot" state="0">
+ <bounds x="25" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1326" element="dotmatrixdot" state="0">
+ <bounds x="26" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1327" element="dotmatrixdot" state="0">
+ <bounds x="27" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1328" element="dotmatrixdot" state="0">
+ <bounds x="28" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1329" element="dotmatrixdot" state="0">
+ <bounds x="29" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1330" element="dotmatrixdot" state="0">
+ <bounds x="30" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1331" element="dotmatrixdot" state="0">
+ <bounds x="31" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1332" element="dotmatrixdot" state="0">
+ <bounds x="32" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1333" element="dotmatrixdot" state="0">
+ <bounds x="33" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1334" element="dotmatrixdot" state="0">
+ <bounds x="34" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1335" element="dotmatrixdot" state="0">
+ <bounds x="35" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1336" element="dotmatrixdot" state="0">
+ <bounds x="36" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1337" element="dotmatrixdot" state="0">
+ <bounds x="37" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1338" element="dotmatrixdot" state="0">
+ <bounds x="38" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1339" element="dotmatrixdot" state="0">
+ <bounds x="39" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1340" element="dotmatrixdot" state="0">
+ <bounds x="40" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1341" element="dotmatrixdot" state="0">
+ <bounds x="41" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1342" element="dotmatrixdot" state="0">
+ <bounds x="42" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1343" element="dotmatrixdot" state="0">
+ <bounds x="43" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1344" element="dotmatrixdot" state="0">
+ <bounds x="44" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1345" element="dotmatrixdot" state="0">
+ <bounds x="45" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1346" element="dotmatrixdot" state="0">
+ <bounds x="46" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1347" element="dotmatrixdot" state="0">
+ <bounds x="47" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1348" element="dotmatrixdot" state="0">
+ <bounds x="48" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1349" element="dotmatrixdot" state="0">
+ <bounds x="49" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1350" element="dotmatrixdot" state="0">
+ <bounds x="50" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1351" element="dotmatrixdot" state="0">
+ <bounds x="51" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1352" element="dotmatrixdot" state="0">
+ <bounds x="52" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1353" element="dotmatrixdot" state="0">
+ <bounds x="53" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1354" element="dotmatrixdot" state="0">
+ <bounds x="54" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1355" element="dotmatrixdot" state="0">
+ <bounds x="55" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1356" element="dotmatrixdot" state="0">
+ <bounds x="56" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1357" element="dotmatrixdot" state="0">
+ <bounds x="57" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1358" element="dotmatrixdot" state="0">
+ <bounds x="58" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1359" element="dotmatrixdot" state="0">
+ <bounds x="59" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1360" element="dotmatrixdot" state="0">
+ <bounds x="60" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1361" element="dotmatrixdot" state="0">
+ <bounds x="61" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1362" element="dotmatrixdot" state="0">
+ <bounds x="62" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1363" element="dotmatrixdot" state="0">
+ <bounds x="63" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop name="dotmatrix1364" element="dotmatrixdot" state="0">
+ <bounds x="64" y="20" width="1" height="1" />
+ </backdrop>
+ <backdrop element="dmd_background">
+ <bounds x="149" y="0" width="102" height="42"/>
+ </backdrop>
+ <screen index="0">
+ <bounds x="0" y="42" width="400" height="300" />
+ </screen>
+ <screen index="1">
+ <bounds x="149" y="0" width="102" height="42"/>
+ </screen>
+ <screen index="1">
+ <bounds x="149" y="0" width="102" height="42"/>
+ </screen>
+ <screen index="1">
+ <bounds x="149" y="0" width="102" height="42"/>
+ </screen>
+ </view>
+ <view name="no led">
+ <screen index="0">
+ <bounds x="0" y="0" width="400" height="300" />
+ </screen>
+ </view>
+</mamelayout>
diff --git a/src/mame/layout/ck_master.lay b/src/mame/layout/ck_master.lay
index 3058347af0e..7eeb296dade 100644
--- a/src/mame/layout/ck_master.lay
+++ b/src/mame/layout/ck_master.lay
@@ -366,7 +366,7 @@ license:CC0
<!-- build screen -->
<view name="Internal Layout">
- <bounds left="-12" right="106.5" top="-1.5" bottom="87.5" />
+ <bounds left="-12.5" right="106.5" top="-1.5" bottom="87.5" />
<group ref="sb_board"><bounds x="4" y="3" width="80" height="80" /></group>
<group ref="sb_ui"><bounds x="-11" y="3" width="10" height="80" /></group>
diff --git a/src/mame/layout/dct11em.lay b/src/mame/layout/dct11em.lay
new file mode 100644
index 00000000000..9046a2f438e
--- /dev/null
+++ b/src/mame/layout/dct11em.lay
@@ -0,0 +1,80 @@
+<?xml version="1.0"?>
+<!--
+license:CC0
+-->
+<mamelayout version="2">
+ <element name="a_led">
+ <disk state="0">
+ <color red="0.0" green="0.75" blue="0.0" />
+ </disk>
+ <disk state="1">
+ <color red="0.0" green="0.15" blue="0.0" />
+ </disk>
+ </element>
+
+ <element name="digit" defstate="0">
+ <led7seg>
+ <color red="0.75" green="0.0" blue="0.0" />
+ </led7seg>
+ </element>
+
+ <element name="background">
+ <rect>
+ <bounds left="0" top="0" right="1" bottom="1" />
+ <color red="0.0" green="0.0" blue="0.0" />
+ </rect>
+ </element>
+
+ <view name="Default Layout">
+ <screen index="0">
+ <bounds x="0" y="0" width="362" height="262" />
+ </screen>
+ <!-- Black background -->
+ <backdrop element="background">
+ <bounds left="0" top="262" right="274" bottom="350" />
+ </backdrop>
+
+ <bezel name="led0" element="a_led">
+ <bounds left="300" top="300" right="310" bottom="310" />
+ </bezel>
+
+ <bezel name="digit11" element="digit">
+ <bounds left="10" top="267" right="44" bottom="305" />
+ </bezel>
+ <bezel name="digit10" element="digit">
+ <bounds left="54" top="267" right="88" bottom="305" />
+ </bezel>
+ <bezel name="digit9" element="digit">
+ <bounds left="98" top="267" right="132" bottom="305" />
+ </bezel>
+ <bezel name="digit8" element="digit">
+ <bounds left="142" top="267" right="176" bottom="305" />
+ </bezel>
+ <bezel name="digit7" element="digit">
+ <bounds left="186" top="267" right="220" bottom="305" />
+ </bezel>
+ <bezel name="digit6" element="digit">
+ <bounds left="230" top="267" right="264" bottom="305" />
+ </bezel>
+
+ <bezel name="digit5" element="digit">
+ <bounds left="10" top="307" right="44" bottom="345" />
+ </bezel>
+ <bezel name="digit4" element="digit">
+ <bounds left="54" top="307" right="88" bottom="345" />
+ </bezel>
+ <bezel name="digit3" element="digit">
+ <bounds left="98" top="307" right="132" bottom="345" />
+ </bezel>
+ <bezel name="digit2" element="digit">
+ <bounds left="142" top="307" right="176" bottom="345" />
+ </bezel>
+ <bezel name="digit1" element="digit">
+ <bounds left="186" top="307" right="220" bottom="345" />
+ </bezel>
+ <bezel name="digit0" element="digit">
+ <bounds left="230" top="307" right="264" bottom="345" />
+ </bezel>
+
+ </view>
+</mamelayout>
diff --git a/src/mame/layout/gigatron.lay b/src/mame/layout/gigatron.lay
new file mode 100644
index 00000000000..dc7562db2f2
--- /dev/null
+++ b/src/mame/layout/gigatron.lay
@@ -0,0 +1,32 @@
+<?xml version="1.0"?>
+<!--
+license:CC0
+-->
+<mamelayout version="2">
+ <element name="led" defstate="0">
+ <rect state="1">
+ <color red="0.75" green="0.0" blue="0.0" />
+ </rect>
+ <rect state="0">
+ <color red="0.20" green="0.0" blue="0.0" />
+ </rect>
+ </element>
+
+ <view name="Default Layout">
+ <screen index="0">
+ <bounds x="0" y="30" width="640" height="480" />
+ </screen>
+ <bezel name="blinken1" element="led">
+ <bounds x="15" y="15" width="10" height="10" />
+ </bezel>
+ <bezel name="blinken2" element="led">
+ <bounds x="30" y="15" width="10" height="10" />
+ </bezel>
+ <bezel name="blinken3" element="led">
+ <bounds x="45" y="15" width="10" height="10" />
+ </bezel>
+ <bezel name="blinken4" element="led">
+ <bounds x="60" y="15" width="10" height="10" />
+ </bezel>
+ </view>
+</mamelayout> \ No newline at end of file
diff --git a/src/mame/layout/saitek_cp2000.lay b/src/mame/layout/saitek_cp2000.lay
index a68538ce269..6756c1bd191 100644
--- a/src/mame/layout/saitek_cp2000.lay
+++ b/src/mame/layout/saitek_cp2000.lay
@@ -600,12 +600,10 @@ license:CC0
<!-- build screen -->
<view name="Internal Layout">
- <bounds left="61" right="198.25" top="0" bottom="86" />
+ <bounds left="49.75" right="186" top="0" bottom="86" />
<group ref="sb_board"><bounds x="102" y="2" width="82" height="82" /></group>
-
- <!-- putting sb_ui on the right side, since chesscomputer has its own ui on the left -->
- <group ref="sb_ui"><bounds x="186" y="2" width="10.25" height="82" /></group>
+ <group ref="sb_ui"><bounds x="51.25" y="2" width="10.25" height="82" /></group>
<!-- left side display -->
diff --git a/src/mame/layout/saitek_ssystem3.lay b/src/mame/layout/saitek_ssystem3.lay
index 64643ef2044..72957cb7e79 100644
--- a/src/mame/layout/saitek_ssystem3.lay
+++ b/src/mame/layout/saitek_ssystem3.lay
@@ -12,18 +12,10 @@ license:CC0
<element name="blackb"><rect><color red="0" green="0" blue="0" /></rect></element>
<element name="brown"><rect><color red="0.4" green="0.2" blue="0.1" /></rect></element>
- <element name="lcd_bg" defstate="1">
- <rect state="1"><color red="0.58" green="0.61" blue="0.62" /></rect>
- <rect state="0"><color red="0.40" green="0.42" blue="0.43" /></rect>
- </element>
-
<element name="hl" defstate="0">
<text string=" "/>
<rect state="1"><color red="0" green="0" blue="0" /></rect>
</element>
- <element name="nothing" defstate="0">
- <text string=" "/>
- </element>
<element name="switch" defstate="0">
<disk>
@@ -48,6 +40,48 @@ license:CC0
</disk>
</element>
+ <element name="switch2" defstate="0">
+ <rect state="0">
+ <bounds x="0" y="1" width="4" height="4" />
+ <color red="0.2" green="0.2" blue="0.2" />
+ </rect>
+ <rect state="0">
+ <bounds x="0" y="0" width="4" height="4" />
+ <color red="0.8" green="0.8" blue="0.8" />
+ </rect>
+ <rect state="1">
+ <bounds x="0" y="0" width="4" height="4" />
+ <color red="0.2" green="0.2" blue="0.2" />
+ </rect>
+ <rect state="1">
+ <bounds x="0" y="1" width="4" height="4" />
+ <color red="0.8" green="0.8" blue="0.8" />
+ </rect>
+ </element>
+
+ <element name="text_v0"><text string="8"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v1"><text string="7"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v2"><text string="6"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v3"><text string="5"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v4"><text string="4"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v5"><text string="3"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v6"><text string="2"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_v7"><text string="1"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+
+ <element name="text_a0"><text string="A"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a1"><text string="B"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a2"><text string="C"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a3"><text string="D"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a4"><text string="E"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a5"><text string="F"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a6"><text string="G"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+ <element name="text_a7"><text string="H"><color red="0.65" green="0.65" blue="0.653" /></text></element>
+
+ <element name="text_cu1"><text string="LOOK"><color red="0.65" green="0.65" blue="0.65" /></text></element>
+ <element name="text_cu2"><text string="&#x2193;NOW &#x2191;MOVE"><color red="0.65" green="0.65" blue="0.65" /></text></element>
+ <element name="text_cu3"><text string="LIGHT"><color red="0.65" green="0.65" blue="0.65" /></text></element>
+ <element name="text_cu4"><text string="&#x2193;ON &#x2191;OFF"><color red="0.65" green="0.65" blue="0.65" /></text></element>
+
<element name="text_n1">
<rect><color red="0.8" green="0.8" blue="0.8" /></rect>
<text string="1" align="1"><color red="0.1" green="0.1" blue="0.1" /></text>
@@ -160,16 +194,86 @@ license:CC0
<element name="text_u3"><text string="TIME"><color red="0.65" green="0.65" blue="0.65" /></text></element>
-<!-- build screen -->
+<!-- lcd screen 1 -->
- <view name="Internal Layout">
- <bounds left="-2" right="48" top="2" bottom="32" />
+ <element name="lcd_bg" defstate="1">
+ <rect state="1"><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect state="0"><color red="0.40" green="0.42" blue="0.43" /></rect>
+ </element>
- <bezel element="brown"><bounds x="-2" y="12" width="52" height="6" /></bezel>
+ <element name="nothing" defstate="0"><text string=" "/></element>
+ <group name="lcd1">
+ <bounds x="-1" y="3" width="18" height="8" />
<screen index="0" blend="alpha"><bounds x="0" y="4" width="15.8" height="6" /></screen>
<element ref="nothing" blend="add" inputtag="IN.4" inputmask="0x00" inputraw="1"><bounds x="-1" y="3" width="18" height="8" /></element>
<element ref="lcd_bg" blend="multiply" inputtag="IN.4" inputmask="0x02" inputraw="1"><bounds x="-1" y="3" width="18" height="8" /></element>
+ </group>
+
+
+<!-- lcd screen 2 -->
+
+ <element name="whitew"><rect><color red="1" green="1" blue="1" /></rect></element>
+ <element name="lcd2m"><rect><color red="0.69" green="0.69" blue="0.69" /></rect></element>
+
+ <element name="lcd_cb">
+ <rect><bounds x="-2.5" y="-2.5" width="45" height="45" /><color red="0.05" green="0.55" blue="0.4" /></rect>
+
+ <rect><bounds x="0" y="0" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="10" y="0" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="20" y="0" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="30" y="0" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="5" y="5" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="15" y="5" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="25" y="5" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="35" y="5" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+
+ <rect><bounds x="0" y="10" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="10" y="10" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="20" y="10" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="30" y="10" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="5" y="15" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="15" y="15" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="25" y="15" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="35" y="15" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+
+ <rect><bounds x="0" y="20" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="10" y="20" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="20" y="20" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="30" y="20" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="5" y="25" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="15" y="25" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="25" y="25" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="35" y="25" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+
+ <rect><bounds x="0" y="30" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="10" y="30" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="20" y="30" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="30" y="30" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="5" y="35" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="15" y="35" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="25" y="35" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ <rect><bounds x="35" y="35" width="5" height="5" /><color red="0.58" green="0.61" blue="0.62" /></rect>
+ </element>
+
+ <group name="lcd2">
+ <bounds x="1.5" y="2.9" width="122.6" height="122.1" />
+ <element ref="whitew"><bounds x="6.2" y="7.6" width="113.3" height="112.8" /></element>
+ <screen index="1" blend="alpha"><bounds x="9.8" y="10" width="106" height="108" /></screen>
+ <element ref="lcd_cb" blend="multiply"><bounds x="1.5" y="2.9" width="122.6" height="122.1" /></element>
+
+ <element ref="nothing" blend="add" inputtag="IN.4" inputmask="0x00" inputraw="1"><bounds x="6.2" y="7.6" width="113.3" height="112.8" /></element>
+ <element ref="lcd2m" blend="multiply" inputtag="IN.4" inputmask="0x04" inputraw="1"><bounds x="6.2" y="7.6" width="113.3" height="112.8" /></element>
+ </group>
+
+
+<!-- master unit -->
+
+ <group name="main">
+ <bounds left="-2" right="48" top="2" bottom="32" />
+ <group ref="lcd1"><bounds x="-1" y="3" width="18" height="8" /></group>
+
+ <bezel element="brown"><bounds x="-2" y="12" width="52" height="6" /></bezel>
<bezel element="switch" inputtag="IN.4" inputmask="0x02" inputraw="1"><bounds x="30.0" y="5.5" width="1.2" height="2.4" /></bezel>
<bezel element="switch" inputtag="IN.4" inputmask="0x01" inputraw="1"><bounds x="34.4" y="5.5" width="1.2" height="2.4" /></bezel>
@@ -246,6 +350,53 @@ license:CC0
<bezel element="text_b9a"><bounds x="41" y="30.2" width="6" height="0.9" /></bezel>
<bezel element="text_b0b"><bounds x="-2.3" y="29.2" width="2" height="0.9" /></bezel>
<bezel element="text_b9b"><bounds x="46.3" y="29.2" width="2" height="0.9" /></bezel>
+ </group>
+
+
+<!-- build screen -->
+
+ <view name="Internal Layout (Full)">
+ <bounds left="26" right="100" top="0" bottom="30" />
+ <group ref="main"><bounds x="50" y="0" width="50" height="30" /></group>
+ <group ref="lcd2"><bounds x="29.3" y="0.35" width="17.37" height="17.3" /></group>
+ <bezel element="brown"><bounds x="26" y="0" width="2" height="30" /></bezel>
+ <bezel element="brown"><bounds x="48" y="0" width="2" height="30" /></bezel>
+ <bezel element="brown"><bounds x="49" y="10" width="2" height="6" /></bezel>
+
+ <repeat count="8">
+ <param name="y" start="1.75" increment="1.93" />
+ <param name="i" start="0" increment="1" />
+ <element ref="text_v~i~"><bounds x="28.6" y="~y~" width="1.5" height="0.9" /></element>
+ </repeat>
+ <repeat count="8">
+ <param name="x" start="30.45" increment="1.93" />
+ <param name="i" start="0" increment="1" />
+ <element ref="text_a~i~"><bounds x="~x~" y="17.2" width="1.5" height="0.9" /></element>
+ </repeat>
+
+ <bezel element="switch2" inputtag="IN.6" inputmask="0x01" inputraw="1"><bounds x="36" y="24" width="4" height="5" /></bezel>
+ <bezel element="switch2" inputtag="IN.4" inputmask="0x04" inputraw="1"><bounds x="42" y="24" width="4" height="5" /></bezel>
+
+ <bezel element="text_cu1"><bounds x="35" y="21.9" width="6" height="0.9" /></bezel>
+ <bezel element="text_cu2"><bounds x="35" y="22.9" width="6" height="0.9" /></bezel>
+ <bezel element="text_cu3"><bounds x="41" y="21.9" width="6" height="0.9" /></bezel>
+ <bezel element="text_cu4"><bounds x="41" y="22.9" width="6" height="0.9" /></bezel>
</view>
+
+ <view name="Internal Layout (Master Unit)">
+ <bounds x="0" y="0" width="50" height="30" />
+ <group ref="main"><bounds x="0" y="0" width="50" height="30" /></group>
+ </view>
+
+ <view name="Internal Layout (Screen 1)">
+ <bounds x="0" y="4" width="15.8" height="6" />
+ <group ref="lcd1"><bounds x="-1" y="3" width="18" height="8" /></group>
+ </view>
+
+ <view name="Internal Layout (Screen 2)">
+ <bounds x="6.2" y="7.6" width="113.3" height="112.8" />
+ <group ref="lcd2"><bounds x="1.5" y="2.9" width="122.6" height="122.1" /></group>
+ </view>
+
</mamelayout>
diff --git a/src/mame/layout/speedfrk.lay b/src/mame/layout/speedfrk.lay
new file mode 100644
index 00000000000..ddc65830d13
--- /dev/null
+++ b/src/mame/layout/speedfrk.lay
@@ -0,0 +1,111 @@
+<?xml version="1.0"?>
+<!--
+license:CC0
+-->
+<mamelayout version="2">
+ <element name="shifter" defstate="0">
+ <rect>
+ <bounds left="0" right="64" top="0" bottom="64" />
+ <color red="0.85" green="0.4" blue="0.3" />
+ </rect>
+ <rect>
+ <bounds left="2" right="62" top="2" bottom="62" />
+ <color red="0.14" green="0.17" blue="0.2" />
+ </rect>
+ <rect>
+ <bounds left="14" right="18" top="15" bottom="49" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </rect>
+ <rect>
+ <bounds left="46" right="50" top="15" bottom="49" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </rect>
+ <rect>
+ <bounds left="14" right="50" top="30" bottom="34" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </rect>
+ <disk>
+ <bounds left="14" right="18" top="13" bottom="17" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </disk>
+ <disk>
+ <bounds left="46" right="50" top="13" bottom="17" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </disk>
+ <disk>
+ <bounds left="14" right="18" top="47" bottom="51" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </disk>
+ <disk>
+ <bounds left="46" right="50" top="47" bottom="51" />
+ <color red="0.44" green="0.47" blue="0.5" />
+ </disk>
+ <text string="1">
+ <bounds left="3" right="29" top="2" bottom="12" />
+ <color red="1.0" green="1.0" blue="1.0" />
+ </text>
+ <text string="2">
+ <bounds left="3" right="29" top="52" bottom="62" />
+ <color red="1.0" green="1.0" blue="1.0" />
+ </text>
+ <text string="3">
+ <bounds left="34" right="61" top="2" bottom="12" />
+ <color red="1.0" green="1.0" blue="1.0" />
+ </text>
+ <text string="4">
+ <bounds left="34" right="61" top="52" bottom="62" />
+ <color red="1.0" green="1.0" blue="1.0" />
+ </text>
+ <text string="1" state="0">
+ <bounds left="3" right="29" top="2" bottom="12" />
+ <color red="1.0" green="1.0" blue="0.4" />
+ </text>
+ <text string="2" state="1">
+ <bounds left="3" right="29" top="52" bottom="62" />
+ <color red="1.0" green="1.0" blue="0.4" />
+ </text>
+ <text string="3" state="2">
+ <bounds left="34" right="61" top="2" bottom="12" />
+ <color red="1.0" green="1.0" blue="0.4" />
+ </text>
+ <text string="4" state="3">
+ <bounds left="34" right="61" top="52" bottom="62" />
+ <color red="1.0" green="1.0" blue="0.4" />
+ </text>
+ <disk state="0">
+ <bounds left="9" right="23" top="14" bottom="28" />
+ <color red="0.85" green="0.4" blue="0.3" />
+ </disk>
+ <disk state="1">
+ <bounds left="9" right="23" top="36" bottom="50" />
+ <color red="0.85" green="0.4" blue="0.3" />
+ </disk>
+ <disk state="2">
+ <bounds left="41" right="55" top="14" bottom="28" />
+ <color red="0.85" green="0.4" blue="0.3" />
+ </disk>
+ <disk state="3">
+ <bounds left="41" right="55" top="36" bottom="50" />
+ <color red="0.85" green="0.4" blue="0.3" />
+ </disk>
+ </element>
+
+ <view name="Shifter-R">
+ <screen index="0">
+ <bounds x="0" y="0" width="640" height="480" />
+ </screen>
+ <element ref="shifter" inputtag="GEAR" inputmask="0x0f" inputraw="1">
+ <bounds x="574" y="414" width="64" height="64" />
+ <color alpha="0.6" />
+ </element>
+ </view>
+ <view name="Shifter-L">
+ <screen index="0">
+ <bounds x="0" y="0" width="640" height="480" />
+ </screen>
+ <element ref="shifter" inputtag="GEAR" inputmask="0x0f" inputraw="1">
+ <bounds x="2" y="414" width="64" height="64" />
+ <color alpha="0.6" />
+ </element>
+ </view>
+</mamelayout>
diff --git a/src/mame/layout/spyhunt.lay b/src/mame/layout/spyhunt.lay
index a3883e71c38..f8dbc7baa49 100644
--- a/src/mame/layout/spyhunt.lay
+++ b/src/mame/layout/spyhunt.lay
@@ -153,6 +153,168 @@ license:CC0
</bezel>
</view>
+ <view name="Lamps + Widescreen Shifter-R">
+ <screen index="0">
+ <bounds x="0" y="0" width="480" height="640" />
+ </screen>
+
+ <bezel name="lamp1" element="lamp_miss">
+ <bounds x="5" y="641" width="60" height="25" />
+ </bezel>
+ <bezel name="lamp0" element="lamp_oil">
+ <bounds x="72" y="641" width="59" height="25" />
+ </bezel>
+ <bezel name="lamp2" element="lamp_van">
+ <bounds x="172" y="641" width="85" height="25" />
+ </bezel>
+ <bezel name="lamp3" element="lamp_smoke">
+ <bounds x="295" y="641" width="93" height="25" />
+ </bezel>
+ <bezel name="lamp4" element="lamp_gun">
+ <bounds x="390" y="641" width="90" height="25" />
+ </bezel>
+
+ <bezel element="shifter" inputtag="ssio:IP0" inputmask="0x10">
+ <bounds x="496" y="574" width="32" height="64" />
+ <color alpha="0.65" />
+ </bezel>
+ </view>
+
+ <view name="Lamps + Widescreen Shifter-L">
+ <screen index="0">
+ <bounds x="0" y="0" width="480" height="640" />
+ </screen>
+
+ <bezel name="lamp1" element="lamp_miss">
+ <bounds x="5" y="641" width="60" height="25" />
+ </bezel>
+ <bezel name="lamp0" element="lamp_oil">
+ <bounds x="72" y="641" width="59" height="25" />
+ </bezel>
+ <bezel name="lamp2" element="lamp_van">
+ <bounds x="172" y="641" width="85" height="25" />
+ </bezel>
+ <bezel name="lamp3" element="lamp_smoke">
+ <bounds x="295" y="641" width="93" height="25" />
+ </bezel>
+ <bezel name="lamp4" element="lamp_gun">
+ <bounds x="390" y="641" width="90" height="25" />
+ </bezel>
+
+ <bezel element="shifter" inputtag="ssio:IP0" inputmask="0x10">
+ <bounds x="-48" y="574" width="32" height="64" />
+ <color alpha="0.65" />
+ </bezel>
+ </view>
+
+ <view name="Widescreen Lamps and Shifter-R">
+ <screen index="0">
+ <bounds x="0" y="0" width="480" height="640" />
+ </screen>
+
+ <bezel name="lamp1" element="lamp_miss">
+ <bounds x="494" y="430" width="60" height="25" />
+ </bezel>
+ <bezel name="lamp0" element="lamp_oil">
+ <bounds x="493" y="455" width="59" height="25" />
+ </bezel>
+ <bezel name="lamp2" element="lamp_van">
+ <bounds x="494" y="480" width="85" height="25" />
+ </bezel>
+ <bezel name="lamp3" element="lamp_smoke">
+ <bounds x="492" y="505" width="93" height="25" />
+ </bezel>
+ <bezel name="lamp4" element="lamp_gun">
+ <bounds x="494" y="530" width="90" height="25" />
+ </bezel>
+
+ <bezel element="shifter" inputtag="ssio:IP0" inputmask="0x10">
+ <bounds x="496" y="574" width="32" height="64" />
+ <color alpha="0.65" />
+ </bezel>
+ </view>
+
+ <view name="Widescreen Lamps and Shifter-L">
+ <screen index="0">
+ <bounds x="0" y="0" width="480" height="640" />
+ </screen>
+
+ <bezel name="lamp1" element="lamp_miss">
+ <bounds x="-70" y="430" width="60" height="25" />
+ </bezel>
+ <bezel name="lamp0" element="lamp_oil">
+ <bounds x="-69" y="455" width="59" height="25" />
+ </bezel>
+ <bezel name="lamp2" element="lamp_van">
+ <bounds x="-95" y="480" width="85" height="25" />
+ </bezel>
+ <bezel name="lamp3" element="lamp_smoke">
+ <bounds x="-102" y="505" width="93" height="25" />
+ </bezel>
+ <bezel name="lamp4" element="lamp_gun">
+ <bounds x="-100" y="530" width="90" height="25" />
+ </bezel>
+
+ <bezel element="shifter" inputtag="ssio:IP0" inputmask="0x10">
+ <bounds x="-48" y="574" width="32" height="64" />
+ <color alpha="0.65" />
+ </bezel>
+ </view>
+
+ <view name="Vertical Widescreen Lamps + Shifter-R">
+ <screen index="0">
+ <bounds x="0" y="0" width="480" height="640" />
+ </screen>
+
+ <bezel name="lamp1" element="lamp_miss">
+ <bounds x="5" y="641" width="60" height="25" />
+ </bezel>
+ <bezel name="lamp0" element="lamp_oil">
+ <bounds x="72" y="641" width="59" height="25" />
+ </bezel>
+ <bezel name="lamp2" element="lamp_van">
+ <bounds x="172" y="641" width="85" height="25" />
+ </bezel>
+ <bezel name="lamp3" element="lamp_smoke">
+ <bounds x="295" y="641" width="93" height="25" />
+ </bezel>
+ <bezel name="lamp4" element="lamp_gun">
+ <bounds x="390" y="641" width="90" height="25" />
+ </bezel>
+
+ <bezel element="shifter" inputtag="ssio:IP0" inputmask="0x10">
+ <bounds x="446" y="667" width="32" height="64" />
+ <color alpha="0.6" />
+ </bezel>
+ </view>
+
+ <view name="Vertical Widescreen Lamps + Shifter-L">
+ <screen index="0">
+ <bounds x="0" y="0" width="480" height="640" />
+ </screen>
+
+ <bezel name="lamp1" element="lamp_miss">
+ <bounds x="5" y="641" width="60" height="25" />
+ </bezel>
+ <bezel name="lamp0" element="lamp_oil">
+ <bounds x="72" y="641" width="59" height="25" />
+ </bezel>
+ <bezel name="lamp2" element="lamp_van">
+ <bounds x="172" y="641" width="85" height="25" />
+ </bezel>
+ <bezel name="lamp3" element="lamp_smoke">
+ <bounds x="295" y="641" width="93" height="25" />
+ </bezel>
+ <bezel name="lamp4" element="lamp_gun">
+ <bounds x="390" y="641" width="90" height="25" />
+ </bezel>
+
+ <bezel element="shifter" inputtag="ssio:IP0" inputmask="0x10">
+ <bounds x="2" y="667" width="32" height="64" />
+ <color alpha="0.6" />
+ </bezel>
+ </view>
+
<view name="Lamps">
<screen index="0">
<bounds x="0" y="0" width="480" height="640" />
diff --git a/src/mame/layout/v4psi.lay b/src/mame/layout/v4psi.lay
new file mode 100644
index 00000000000..85e195d9429
--- /dev/null
+++ b/src/mame/layout/v4psi.lay
@@ -0,0 +1,30 @@
+<?xml version="1.0"?>
+<!--
+license:CC0
+-->
+<mamelayout version="2">
+ <element name="overlay">
+ <rect>
+ <bounds left="0" top="0" right="1" bottom="0.12" />
+ <color red="0.055" green="0.43" blue="0.04" />
+ </rect>
+ <rect>
+ <bounds left="0" top="0.12" right="1" bottom="0.85" />
+ <color red="0.66" green="0.65" blue="0.05" />
+ </rect>
+ <rect>
+ <bounds left="0" top="0.85" right="1" bottom="1.0" />
+ <color red="0.69" green="0.28" blue="0.00" />
+ </rect>
+ </element>
+
+ <view name="Monitor with Overlay">
+ <screen index="0">
+ <bounds x="0" y="0" width="504" height="296" />
+ </screen>
+ <overlay element="overlay">
+ <bounds x="0" y="0" width="504" height="296" />
+ </overlay>
+
+ </view>
+</mamelayout>
diff --git a/src/mame/machine/bacta_datalogger.cpp b/src/mame/machine/bacta_datalogger.cpp
new file mode 100644
index 00000000000..6caddd70bf2
--- /dev/null
+++ b/src/mame/machine/bacta_datalogger.cpp
@@ -0,0 +1,139 @@
+// license:BSD-3-Clause
+// copyright-holders:James Wallace
+#include "emu.h"
+#include "bacta_datalogger.h"
+
+#define LOG_DATA 1
+/***********************************************************************************************************
+ BACTA Datalogger emulation
+ The British Amusement and Catering Trade Association created a standard for the tracking of statistics
+ and other features on British AWPs across hardware manufacturers.
+ The specification is very simple, a 1200 baud null modem via RS232, with the logger sending an ACK
+ command (0x06) on receipt of a valid character.
+ As this is RS232, the logger itself can be of any design provided the acknowledgment is made where demanded
+ (by, for example, Protocol game ROMS).
+ In this emulation, the simplest functioning device is simulated here, derived from the rs232 null_modem.
+ We only handle the feedback for acknowledgment, not any other feature.
+************************************************************************************************************/
+
+// device type definition
+DEFINE_DEVICE_TYPE(BACTA_DATALOGGER, bacta_datalogger_device, "bacta_datalogger", "BACTA Datalogger")
+
+//-------------------------------------------------
+// bacta_datalogger_device - constructor
+//-------------------------------------------------
+
+bacta_datalogger_device::bacta_datalogger_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
+ : bacta_datalogger_device(mconfig, BACTA_DATALOGGER, tag, owner, clock)
+{
+}
+
+bacta_datalogger_device::bacta_datalogger_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock)
+ : device_t(mconfig, BACTA_DATALOGGER, tag, owner, clock),
+ device_serial_interface(mconfig, *this),
+ m_rxd_handler(*this),
+ m_output_char(0),
+ m_timer_poll(nullptr)
+{
+}
+
+void bacta_datalogger_device::device_start()
+{
+ m_rxd_handler.resolve_safe();
+
+ m_timer_poll = timer_alloc(TIMER_POLL);
+}
+
+
+WRITE_LINE_MEMBER(bacta_datalogger_device::update_serial)
+{
+ int startbits = 1;
+ int databits = 8;
+ parity_t parity = device_serial_interface::PARITY_ODD;
+ stop_bits_t stopbits = device_serial_interface::STOP_BITS_1; // 1 stop bit
+
+ set_data_frame(startbits, databits, parity, stopbits);
+
+ set_tra_rate(1200);
+
+ set_rcv_rate(1200);
+
+ output_rxd(1);
+}
+
+void bacta_datalogger_device::device_reset()
+{
+ update_serial(0);
+ queue();
+}
+
+void bacta_datalogger_device::device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr)
+{
+ switch (id)
+ {
+ case TIMER_POLL:
+ queue();
+ break;
+
+ default:
+ break;
+ }
+}
+
+void bacta_datalogger_device::queue()
+{
+ if (m_output_char != 0)
+ {
+ if (is_transmit_register_empty())
+ {
+ transmit_register_setup(m_output_char);
+ m_timer_poll->adjust(attotime::never);
+ return;
+
+ m_timer_poll->adjust(attotime::from_hz(1200));
+ }
+ }
+}
+
+void bacta_datalogger_device::tra_callback()
+{
+ output_rxd(transmit_register_get_data_bit());
+}
+
+void bacta_datalogger_device::tra_complete()
+{
+ queue();
+}
+
+void bacta_datalogger_device::rcv_complete()
+{
+ u8 data;
+
+ receive_register_extract();
+
+ data = get_received_char();
+ if (!is_receive_parity_error())
+ {
+ if (data == 0x00)//clean up logging
+ {
+ if (LOG_DATA)
+ {
+ logerror("Received: %02x () \n",data);
+ }
+
+ }
+ else
+ {
+ if (LOG_DATA)
+ {
+ logerror("Received: %02x (%c) \n",data, data);
+ }
+ }
+ m_output_char = 0x06;//ACK
+ }
+ else
+ {
+ m_output_char = 0x15;//NAK
+ }
+ queue();
+} \ No newline at end of file
diff --git a/src/mame/machine/bacta_datalogger.h b/src/mame/machine/bacta_datalogger.h
new file mode 100644
index 00000000000..63a069ff751
--- /dev/null
+++ b/src/mame/machine/bacta_datalogger.h
@@ -0,0 +1,45 @@
+// license:BSD-3-Clause
+// copyright-holders:James Wallace
+#ifndef MAME_BACTA_DATALOGGER_H
+#define MAME_BACTA_DATALOGGER_H
+
+#include "diserial.h"
+
+class bacta_datalogger_device : public device_t,
+ public device_serial_interface
+{
+public:
+ bacta_datalogger_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0);
+
+ virtual WRITE_LINE_MEMBER( write_txd ) { device_serial_interface::rx_w(state); }
+ auto rxd_handler() { return m_rxd_handler.bind(); }
+
+ DECLARE_WRITE_LINE_MEMBER( output_rxd ) { m_rxd_handler(state); }
+
+ DECLARE_WRITE_LINE_MEMBER(update_serial);
+
+protected:
+ bacta_datalogger_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
+
+ virtual void device_start() override;
+ virtual void device_reset() override;
+ virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
+
+ virtual void tra_callback() override;
+ virtual void tra_complete() override;
+ virtual void rcv_complete() override;
+
+private:
+ static constexpr int TIMER_POLL = 1;
+
+ void queue();
+
+ devcb_write_line m_rxd_handler;
+
+ uint8_t m_output_char;
+ emu_timer *m_timer_poll;
+};
+
+DECLARE_DEVICE_TYPE(BACTA_DATALOGGER, bacta_datalogger_device)
+
+#endif // MAME_BACTA_DATALOGGER_H
diff --git a/src/mame/machine/cit101_kbd.cpp b/src/mame/machine/cit101_kbd.cpp
index dedefb7e335..272f6b91006 100644
--- a/src/mame/machine/cit101_kbd.cpp
+++ b/src/mame/machine/cit101_kbd.cpp
@@ -8,15 +8,46 @@
a single bidirectional wire at 4800 bits per second. Unlike the
VT100 keyboard whose layout it mimics (indicator LEDs included),
the CIT-101 keyboard transmits standard ASCII codes for most keys,
- and the complexity of decoding these strongly suggests that this
- must be done by some sort of MCU. There are also a few special
- characters with the 8th bit set, including the numeric keypad,
- the cursor keys, the Return key and the all-important no-key code.
-
- TODO: identify and dump MCU for low-level emulation
- TODO: indicator LEDs
- TODO: make repeat key do something
- TODO: CTRL+G doesn't seem to generate a beep
+ and a MCU is used to decode the scans, generate clicks and beeps
+ and handle serial communications. The keyboard also transmits a
+ few non-ASCII codes with the most significant bit set (and
+ modifiers encoded in the next two bits):
+
+ 80 (No key pressed)
+ 82 Set-Up
+ 83 Return (host may interpret this as CR or CR+LF)
+ 84 Up
+ 85 Down
+ 86 Right
+ 87 Left
+ 88 PF1
+ 89 PF2
+ 8A PF3
+ 8B PF4
+ 8C , (on numeric keypad)
+ 8D - (on numeric keypad)
+ 8E . (on numeric keypad)
+ 8F Enter (on numeric keypad)
+ 90 0 (on numeric keypad)
+ 91 1 (on numeric keypad)
+ 92 2 (on numeric keypad)
+ 93 3 (on numeric keypad)
+ 94 4 (on numeric keypad)
+ 95 5 (on numeric keypad)
+ 96 6 (on numeric keypad)
+ 97 7 (on numeric keypad)
+ 98 8 (on numeric keypad)
+ 99 9 (on numeric keypad)
+ 9A Home
+ 9B Break
+ 9C No Scroll
+ 9D (Keyboard ID: QWERTY layout)
+ 9E (Keyboard ID: AZERTY layout)
+ 9F (Invalid key)
+
+ Two types of host commands are processed. Commands with bit 0
+ set affect the LEDs, and commands with bit 0 clear affect the
+ beeper. Sending a command is necessary to initiate a new scan.
**********************************************************************/
@@ -24,277 +55,271 @@
#include "cit101_kbd.h"
#include "speaker.h"
-#include "machine/keyboard.ipp"
-
//**************************************************************************
-// HLE KEYBOARD DEVICE
+// LLE KEYBOARD DEVICE
//**************************************************************************
-DEFINE_DEVICE_TYPE(CIT101_HLE_KEYBOARD, cit101_hle_keyboard_device, "cit101_hle_kbd", "CIT-101 HLE Keyboard")
+DEFINE_DEVICE_TYPE(CIT101_KEYBOARD, cit101_keyboard_device, "cit101_kbd", "CIT-101 Keyboard")
+DEFINE_DEVICE_TYPE(CIT101E_KEYBOARD, cit101e_keyboard_device, "cit101e_kbd", "CIT-101e Keyboard")
-cit101_hle_keyboard_device::cit101_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
- : device_t(mconfig, CIT101_HLE_KEYBOARD, tag, owner, clock)
- , device_matrix_keyboard_interface(mconfig, *this, "KEYS0", "KEYS1", "KEYS2", "KEYS3")
- , device_buffered_serial_interface(mconfig, *this)
- , m_modifiers(*this, "MODIFIERS")
+cit101_keyboard_device::cit101_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
+ : device_t(mconfig, type, tag, owner, clock)
+ , m_mcu(*this, "mcu")
, m_beeper(*this, "beeper")
+ , m_keys(*this, "KEYS%d", 0U)
+ , m_kbid(*this, "KBID")
+ , m_leds(*this, "led%d", 0U)
, m_txd_callback(*this)
- , m_command{0, 1}
+ , m_kbid_enabled(false)
{
}
-INPUT_PORTS_START(cit101_hle_keyboard)
- PORT_START("MODIFIERS")
- PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_SHIFT_2) PORT_CODE(KEYCODE_LCONTROL)
- PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_SHIFT_1) PORT_CODE(KEYCODE_LSHIFT) PORT_CODE(KEYCODE_RSHIFT)
- PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_TOGGLE PORT_CHAR(UCHAR_MAMEKEY(CAPSLOCK)) PORT_CODE(KEYCODE_CAPSLOCK)
- PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Repeat") PORT_CODE(KEYCODE_RCONTROL)
-
- PORT_START("KEYS0")
- PORT_BIT(0x00000003, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00000004, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("] }") PORT_CHAR(']') PORT_CHAR('}') PORT_CHAR(0x1d) PORT_CODE(KEYCODE_CLOSEBRACE)
- PORT_BIT(0x00000008, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("\\ |") PORT_CHAR('\\') PORT_CHAR('|') PORT_CHAR(0x1c) PORT_CODE(KEYCODE_BACKSLASH)
- PORT_BIT(0x00000010, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('[') PORT_CHAR('{') PORT_CODE(KEYCODE_OPENBRACE)
- PORT_BIT(0x00000020, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Z") PORT_CHAR('z') PORT_CHAR('Z') PORT_CHAR(0x1a) PORT_CODE(KEYCODE_Z)
- PORT_BIT(0x00000040, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Y") PORT_CHAR('y') PORT_CHAR('Y') PORT_CHAR(0x19) PORT_CODE(KEYCODE_Y)
- PORT_BIT(0x00000080, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("X") PORT_CHAR('x') PORT_CHAR('X') PORT_CHAR(0x18) PORT_CODE(KEYCODE_X)
- PORT_BIT(0x00000100, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("W") PORT_CHAR('W') PORT_CHAR('W') PORT_CHAR(0x17) PORT_CODE(KEYCODE_W)
- PORT_BIT(0x00000200, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("V") PORT_CHAR('v') PORT_CHAR('V') PORT_CHAR(0x16) PORT_CODE(KEYCODE_V)
- PORT_BIT(0x00000400, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("U") PORT_CHAR('u') PORT_CHAR('U') PORT_CHAR(0x15) PORT_CODE(KEYCODE_U)
- PORT_BIT(0x00000800, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("T") PORT_CHAR('t') PORT_CHAR('T') PORT_CHAR(0x14) PORT_CODE(KEYCODE_T)
- PORT_BIT(0x00001000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("S") PORT_CHAR('s') PORT_CHAR('S') PORT_CHAR(0x13) PORT_CODE(KEYCODE_S)
- PORT_BIT(0x00002000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("R") PORT_CHAR('r') PORT_CHAR('R') PORT_CHAR(0x12) PORT_CODE(KEYCODE_R)
- PORT_BIT(0x00004000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Q") PORT_CHAR('q') PORT_CHAR('Q') PORT_CHAR(0x11) PORT_CODE(KEYCODE_Q)
- PORT_BIT(0x00008000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("P") PORT_CHAR('p') PORT_CHAR('P') PORT_CHAR(0x10) PORT_CODE(KEYCODE_P)
- PORT_BIT(0x00010000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("O") PORT_CHAR('o') PORT_CHAR('O') PORT_CHAR(0x0f) PORT_CODE(KEYCODE_O)
- PORT_BIT(0x00020000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("N") PORT_CHAR('n') PORT_CHAR('N') PORT_CHAR(0x0e) PORT_CODE(KEYCODE_N)
- PORT_BIT(0x00040000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("M") PORT_CHAR('m') PORT_CHAR('M') PORT_CODE(KEYCODE_M)
- PORT_BIT(0x00080000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("L") PORT_CHAR('l') PORT_CHAR('L') PORT_CHAR(0x0c) PORT_CODE(KEYCODE_L)
- PORT_BIT(0x00100000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("K") PORT_CHAR('k') PORT_CHAR('K') PORT_CHAR(0x0b) PORT_CODE(KEYCODE_K)
- PORT_BIT(0x00200000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("J") PORT_CHAR('j') PORT_CHAR('J') PORT_CODE(KEYCODE_J)
- PORT_BIT(0x00400000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("I") PORT_CHAR('i') PORT_CHAR('I') PORT_CODE(KEYCODE_I)
- PORT_BIT(0x00800000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("H") PORT_CHAR('h') PORT_CHAR('H') PORT_CODE(KEYCODE_H)
- PORT_BIT(0x01000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("G (Bell)") PORT_CHAR('g') PORT_CHAR('G') PORT_CHAR(0x07) PORT_CODE(KEYCODE_G)
- PORT_BIT(0x02000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("F") PORT_CHAR('f') PORT_CHAR('F') PORT_CHAR(0x06) PORT_CODE(KEYCODE_F)
- PORT_BIT(0x04000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("E") PORT_CHAR('e') PORT_CHAR('E') PORT_CHAR(0x05) PORT_CODE(KEYCODE_E)
- PORT_BIT(0x08000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("D") PORT_CHAR('d') PORT_CHAR('D') PORT_CHAR(0x04) PORT_CODE(KEYCODE_D)
- PORT_BIT(0x10000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("C") PORT_CHAR('c') PORT_CHAR('C') PORT_CHAR(0x03) PORT_CODE(KEYCODE_C)
- PORT_BIT(0x20000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("B") PORT_CHAR('b') PORT_CHAR('B') PORT_CHAR(0x02) PORT_CODE(KEYCODE_B)
- PORT_BIT(0x40000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("A") PORT_CHAR('a') PORT_CHAR('A') PORT_CHAR(0x01) PORT_CODE(KEYCODE_A)
- PORT_BIT(0x80000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("` ~") PORT_CHAR('`') PORT_CHAR('~') PORT_CHAR(0x1e) PORT_CODE(KEYCODE_TILDE)
-
- PORT_START("KEYS1")
- PORT_BIT(0x00000003, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00000004, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('=') PORT_CHAR('+') PORT_CODE(KEYCODE_EQUALS)
- PORT_BIT(0x00000008, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00000010, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(';') PORT_CHAR(':') PORT_CODE(KEYCODE_COLON)
- PORT_BIT(0x00000020, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00000040, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('9') PORT_CHAR('(') PORT_CODE(KEYCODE_9)
- PORT_BIT(0x00000080, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('8') PORT_CHAR('*') PORT_CODE(KEYCODE_8)
- PORT_BIT(0x00000100, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('7') PORT_CHAR('&') PORT_CODE(KEYCODE_7)
- PORT_BIT(0x00000200, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('6') PORT_CHAR('^') PORT_CODE(KEYCODE_6)
- PORT_BIT(0x00000400, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('5') PORT_CHAR('%') PORT_CODE(KEYCODE_5)
- PORT_BIT(0x00000800, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('4') PORT_CHAR('$') PORT_CODE(KEYCODE_4)
- PORT_BIT(0x00001000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("3 # \xc2\xa3") PORT_CHAR('3') PORT_CHAR('#', 0xa3) PORT_CODE(KEYCODE_3)
- PORT_BIT(0x00002000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('2') PORT_CHAR('@') PORT_CODE(KEYCODE_2)
- PORT_BIT(0x00004000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('1') PORT_CHAR('!') PORT_CODE(KEYCODE_1)
- PORT_BIT(0x00008000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('0') PORT_CHAR(')') PORT_CODE(KEYCODE_0)
- PORT_BIT(0x00010000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("/ ?") PORT_CHAR('/') PORT_CHAR('?') PORT_CHAR(0x1f) PORT_CODE(KEYCODE_SLASH)
- PORT_BIT(0x00020000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('.') PORT_CHAR('>') PORT_CODE(KEYCODE_STOP)
- PORT_BIT(0x00040000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('-') PORT_CHAR('_') PORT_CODE(KEYCODE_MINUS)
- PORT_BIT(0x00080000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(',') PORT_CHAR('<') PORT_CODE(KEYCODE_COMMA)
- PORT_BIT(0x00f00000, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x01000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR('\'') PORT_CHAR('"') PORT_CODE(KEYCODE_QUOTE)
- PORT_BIT(0x7e000000, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x80000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(' ') PORT_CODE(KEYCODE_SPACE)
-
- PORT_START("KEYS2")
- PORT_BIT(0x00000001, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Delete") PORT_CHAR(0x7f) PORT_CODE(KEYCODE_DEL)
- PORT_BIT(0x0000000e, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00000010, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(0x1b) PORT_CODE(KEYCODE_ESC)
- PORT_BIT(0x001fffe0, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00200000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Line Feed") PORT_CHAR(0x0a) PORT_CODE(KEYCODE_RALT)
- PORT_BIT(0x00400000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(0x09) PORT_CODE(KEYCODE_TAB)
- PORT_BIT(0x00800000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Back Space") PORT_CHAR(0x08) PORT_CODE(KEYCODE_BACKSPACE)
- PORT_BIT(0xff000000, IP_ACTIVE_HIGH, IPT_UNUSED)
-
- PORT_START("KEYS3")
- PORT_BIT(0x00000001, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x00000002, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Test Key 2")
- PORT_BIT(0x00000004, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Test Key 1")
- PORT_BIT(0x00000008, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("No Scroll") PORT_CHAR(UCHAR_MAMEKEY(SCRLOCK)) PORT_CODE(KEYCODE_LALT)
- PORT_BIT(0x00000010, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Break") PORT_CHAR(UCHAR_MAMEKEY(PAUSE)) PORT_CODE(KEYCODE_END)
- PORT_BIT(0x00000020, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Clr Home") PORT_CHAR(UCHAR_MAMEKEY(HOME)) PORT_CODE(KEYCODE_HOME)
- PORT_BIT(0x00000040, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(9_PAD)) PORT_CODE(KEYCODE_9_PAD)
- PORT_BIT(0x00000080, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(8_PAD)) PORT_CODE(KEYCODE_8_PAD)
- PORT_BIT(0x00000100, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(7_PAD)) PORT_CODE(KEYCODE_7_PAD)
- PORT_BIT(0x00000200, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(6_PAD)) PORT_CODE(KEYCODE_6_PAD)
- PORT_BIT(0x00000400, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(5_PAD)) PORT_CODE(KEYCODE_5_PAD)
- PORT_BIT(0x00000800, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(4_PAD)) PORT_CODE(KEYCODE_4_PAD)
- PORT_BIT(0x00001000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(3_PAD)) PORT_CODE(KEYCODE_3_PAD)
- PORT_BIT(0x00002000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(2_PAD)) PORT_CODE(KEYCODE_2_PAD)
- PORT_BIT(0x00004000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(1_PAD)) PORT_CODE(KEYCODE_1_PAD)
- PORT_BIT(0x00008000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(0_PAD)) PORT_CODE(KEYCODE_0_PAD)
- PORT_BIT(0x00010000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(ENTER_PAD)) PORT_CODE(KEYCODE_ENTER_PAD)
- PORT_BIT(0x00020000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(DEL_PAD)) PORT_CODE(KEYCODE_DEL_PAD)
- PORT_BIT(0x00040000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(MINUS_PAD)) PORT_CODE(KEYCODE_MINUS_PAD)
- PORT_BIT(0x00080000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(COMMA_PAD)) PORT_CODE(KEYCODE_PLUS_PAD)
- PORT_BIT(0x00100000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("PF4") PORT_CHAR(UCHAR_MAMEKEY(F4)) PORT_CODE(KEYCODE_F4)
- PORT_BIT(0x00200000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("PF3") PORT_CHAR(UCHAR_MAMEKEY(F3)) PORT_CODE(KEYCODE_F3)
- PORT_BIT(0x00400000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("PF2") PORT_CHAR(UCHAR_MAMEKEY(F2)) PORT_CODE(KEYCODE_F2)
- PORT_BIT(0x00800000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("PF1") PORT_CHAR(UCHAR_MAMEKEY(F1)) PORT_CODE(KEYCODE_F1)
- PORT_BIT(0x01000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(LEFT)) PORT_CODE(KEYCODE_LEFT)
- PORT_BIT(0x02000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(RIGHT)) PORT_CODE(KEYCODE_RIGHT)
- PORT_BIT(0x04000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(DOWN)) PORT_CODE(KEYCODE_DOWN)
- PORT_BIT(0x08000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(UP)) PORT_CODE(KEYCODE_UP)
- PORT_BIT(0x10000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Return") PORT_CHAR(0x0d) PORT_CODE(KEYCODE_ENTER)
- PORT_BIT(0x20000000, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Set-Up") PORT_CHAR(UCHAR_MAMEKEY(F5)) PORT_CODE(KEYCODE_F5)
- PORT_BIT(0x40000000, IP_ACTIVE_HIGH, IPT_UNUSED)
- PORT_BIT(0x80000000, IP_ACTIVE_HIGH, IPT_UNUSED) // actually used for special stop code
-INPUT_PORTS_END
-
-void cit101_hle_keyboard_device::device_add_mconfig(machine_config &config)
+cit101_keyboard_device::cit101_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
+ : cit101_keyboard_device(mconfig, CIT101_KEYBOARD, tag, owner, clock)
{
- SPEAKER(config, "mono").front_center();
- BEEP(config, m_beeper, 786).add_route(ALL_OUTPUTS, "mono", 0.50);
}
-ioport_constructor cit101_hle_keyboard_device::device_input_ports() const
+cit101e_keyboard_device::cit101e_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
+ : cit101_keyboard_device(mconfig, CIT101E_KEYBOARD, tag, owner, clock)
{
- return INPUT_PORTS_NAME(cit101_hle_keyboard);
}
-void cit101_hle_keyboard_device::device_resolve_objects()
+void cit101_keyboard_device::device_resolve_objects()
{
m_txd_callback.resolve_safe();
+ m_leds.resolve();
}
-void cit101_hle_keyboard_device::device_start()
+void cit101_keyboard_device::device_start()
{
- // keyboard USART configured for mode 8Eh
- set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1_5);
- set_rate(4800);
-
- save_item(NAME(m_command));
+ save_item(NAME(m_kbid_enabled));
}
-void cit101_hle_keyboard_device::device_reset()
+WRITE_LINE_MEMBER(cit101_keyboard_device::write_rxd)
{
- stop_processing();
+ m_mcu->set_input_line(MCS48_INPUT_IRQ, state ? CLEAR_LINE : ASSERT_LINE);
}
-void cit101_hle_keyboard_device::tra_callback()
+
+void cit101_keyboard_device::p2_w(u8 data)
{
- m_txd_callback(transmit_register_get_data_bit());
+ m_txd_callback(!BIT(data, 7));
+ m_beeper->set_state(BIT(data, 5)); // Bit 6 also involved?
}
-WRITE_LINE_MEMBER(cit101_hle_keyboard_device::write_rxd)
+void cit101_keyboard_device::leds_w(u8 data)
{
- rx_w(state);
+ m_kbid_enabled = !BIT(data, 0);
+
+ // Bit 7 = ON LINE
+ // Bit 6 = OFF LINE
+ // Bit 5 = KBD LOCKED
+ // Bit 4 = L1
+ // Bit 3 = L2
+ // Bit 2 = L3
+ // Bit 1 = L4
+ for (int i = 0; i < 7; i++)
+ m_leds[i] = !BIT(data, 7 - i);
}
-void cit101_hle_keyboard_device::received_byte(u8 byte)
+u8 cit101_keyboard_device::keys_r()
{
- if (m_command[BIT(byte, 0)] != byte)
- {
- logerror("Command byte %d = %02X\n", BIT(byte, 0), byte);
+ u16 strobes = m_mcu->p1_r() | u16(m_mcu->p2_r() & 0x07) << 8;
+ u8 ret = 0xff;
- // probably not correct
- if (!BIT(byte, 0))
- m_beeper->set_state(BIT(byte, 2));
+ for (int n = 0; n < 11; n++)
+ if (!BIT(strobes, 10 - n))
+ ret &= m_keys[n]->read();
- m_command[BIT(byte, 0)] = byte;
- }
+ if (m_kbid_enabled)
+ ret &= m_kbid->read();
- start_processing(attotime::from_hz(76800)); // guess
+ return ret;
}
-void cit101_hle_keyboard_device::send_key(u8 code)
+void cit101_keyboard_device::prog_map(address_map &map)
{
- transmit_byte(code);
+ map(0x000, 0x7ff).rom().region("program", 0);
}
-void cit101_hle_keyboard_device::send_translated(u8 row, u8 column)
+void cit101_keyboard_device::ext_map(address_map &map)
{
- const ioport_value modifiers = m_modifiers->read();
-
- logerror("Key row %d column %d\n", row, column);
- switch (row)
- {
- case 0:
- if (column < 5)
- send_key((BIT(modifiers, 0) ? 0x1f : BIT(modifiers, 1) ? 0x7f : 0x5f) - column);
- else if (column < 31)
- send_key((BIT(modifiers, 0) ? 0x1f : BIT(modifiers, 1) || BIT(modifiers, 2) ? 0x5f : 0x7f) - column);
- else
- send_key(BIT(modifiers, 0) ? 0x1e : BIT(modifiers, 1) ? '~' : 0x7f - column);
- break;
- case 1:
- if (BIT(modifiers, 0) && column == 16)
- send_key(0x2f - column);
- else if (!BIT(modifiers, 1) || column == 31)
- send_key((column == 31 && BIT(modifiers, 0) ? 0x1f : 0x3f) - column);
- else switch (0x3f - column)
- {
- case '=':
- send_key('+');
- break;
- case ';':
- send_key(':');
- break;
- case '9':
- send_key('(');
- break;
- case '8':
- send_key('*');
- break;
- case '7':
- send_key('&');
- break;
- case '6':
- send_key('^');
- break;
- case '2':
- send_key('@');
- break;
- case '0':
- send_key(')');
- break;
- case '-':
- send_key('_');
- break;
- case '\'':
- send_key('"');
- break;
- default:
- send_key(0x2f ^ column);
- break;
- }
- break;
- case 2:
- send_key((column == 0) ? 0x7f : 0x1f - column);
- break;
- case 3:
- send_key((0x9f - column) | (BIT(modifiers, 0) ? 0x40 : 0) | (BIT(modifiers, 1) ? 0x20 : 0));
- break;
- }
+ map(0x00, 0x00).mirror(0xff).w(FUNC(cit101_keyboard_device::leds_w));
}
-void cit101_hle_keyboard_device::key_make(u8 row, u8 column)
+
+INPUT_PORTS_START(cit101_keyboard)
+ PORT_START("SHIFT")
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_TOGGLE PORT_CHAR(UCHAR_MAMEKEY(CAPSLOCK)) PORT_CODE(KEYCODE_CAPSLOCK)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_SHIFT_1) PORT_CODE(KEYCODE_LSHIFT) PORT_CODE(KEYCODE_RSHIFT)
+ PORT_BIT(0xe7, IP_ACTIVE_LOW, IPT_UNUSED)
+
+ PORT_START("MODIFIERS")
+ PORT_BIT(1, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Rept") PORT_CODE(KEYCODE_RCONTROL)
+ PORT_BIT(2, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Ctrl") PORT_CHAR(UCHAR_SHIFT_2) PORT_CODE(KEYCODE_LCONTROL)
+
+ PORT_START("KEYS0")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("PF3") PORT_CHAR(UCHAR_MAMEKEY(F3)) PORT_CODE(KEYCODE_F3)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("PF4") PORT_CHAR(UCHAR_MAMEKEY(F4)) PORT_CODE(KEYCODE_F4)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(9_PAD)) PORT_CODE(KEYCODE_9_PAD)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(MINUS_PAD)) PORT_CODE(KEYCODE_MINUS_PAD)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(6_PAD)) PORT_CODE(KEYCODE_6_PAD)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(COMMA_PAD)) PORT_CODE(KEYCODE_PLUS_PAD)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(3_PAD)) PORT_CODE(KEYCODE_3_PAD)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(ENTER_PAD)) PORT_CODE(KEYCODE_ENTER_PAD)
+
+ PORT_START("KEYS1")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("PF1") PORT_CHAR(UCHAR_MAMEKEY(F1)) PORT_CODE(KEYCODE_F1)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("PF2") PORT_CHAR(UCHAR_MAMEKEY(F2)) PORT_CODE(KEYCODE_F2)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(7_PAD)) PORT_CODE(KEYCODE_7_PAD)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(8_PAD)) PORT_CODE(KEYCODE_8_PAD)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(4_PAD)) PORT_CODE(KEYCODE_4_PAD)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(5_PAD)) PORT_CODE(KEYCODE_5_PAD)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(1_PAD)) PORT_CODE(KEYCODE_1_PAD)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(2_PAD)) PORT_CODE(KEYCODE_2_PAD)
+
+ PORT_START("KEYS2")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Home (Clr)") PORT_CHAR(UCHAR_MAMEKEY(HOME)) PORT_CODE(KEYCODE_HOME)
+ PORT_BIT(0x3e, IP_ACTIVE_LOW, IPT_UNUSED)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(0_PAD)) PORT_CODE(KEYCODE_0_PAD)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(DEL_PAD)) PORT_CODE(KEYCODE_DEL_PAD)
+
+ PORT_START("KEYS3")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(LEFT)) PORT_CODE(KEYCODE_LEFT)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(RIGHT)) PORT_CODE(KEYCODE_RIGHT)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("` ~") PORT_CHAR('`') PORT_CHAR('~') PORT_CHAR(0x1e) PORT_CODE(KEYCODE_TILDE)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Break") PORT_CHAR(UCHAR_MAMEKEY(PAUSE)) PORT_CODE(KEYCODE_END)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Back Space") PORT_CHAR(0x08) PORT_CODE(KEYCODE_BACKSPACE)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Delete") PORT_CHAR(UCHAR_MAMEKEY(DEL)) PORT_CODE(KEYCODE_DEL)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Line Feed") PORT_CHAR(0x0a) PORT_CODE(KEYCODE_RALT)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\\ |") PORT_CHAR('\\') PORT_CHAR('|') PORT_CHAR(0x1c) PORT_CODE(KEYCODE_BACKSLASH)
+
+ PORT_START("KEYS4")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(UP)) PORT_CODE(KEYCODE_UP)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(UCHAR_MAMEKEY(DOWN)) PORT_CODE(KEYCODE_DOWN)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('-') PORT_CHAR('_') PORT_CODE(KEYCODE_MINUS)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('=') PORT_CHAR('+') PORT_CODE(KEYCODE_EQUALS)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('[') PORT_CHAR('{') PORT_CODE(KEYCODE_OPENBRACE)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("] }") PORT_CHAR(']') PORT_CHAR('}') PORT_CHAR(0x1d) PORT_CODE(KEYCODE_CLOSEBRACE)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('\'') PORT_CHAR('"') PORT_CODE(KEYCODE_QUOTE)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Return") PORT_CHAR(0x0d) PORT_CODE(KEYCODE_ENTER)
+
+ PORT_START("KEYS5")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('9') PORT_CHAR('(') PORT_CODE(KEYCODE_9)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('0') PORT_CHAR(')') PORT_CODE(KEYCODE_0)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("O") PORT_CHAR('o') PORT_CHAR('O') PORT_CHAR(0x0f) PORT_CODE(KEYCODE_O)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("P") PORT_CHAR('p') PORT_CHAR('P') PORT_CHAR(0x10) PORT_CODE(KEYCODE_P)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("L") PORT_CHAR('l') PORT_CHAR('L') PORT_CHAR(0x0c) PORT_CODE(KEYCODE_L)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(';') PORT_CHAR(':') PORT_CODE(KEYCODE_COLON)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('.') PORT_CHAR('>') PORT_CODE(KEYCODE_STOP)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("/ ?") PORT_CHAR('/') PORT_CHAR('?') PORT_CHAR(0x1f) PORT_CODE(KEYCODE_SLASH)
+
+ PORT_START("KEYS6")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('7') PORT_CHAR('&') PORT_CODE(KEYCODE_7)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('8') PORT_CHAR('*') PORT_CODE(KEYCODE_8)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("U") PORT_CHAR('u') PORT_CHAR('U') PORT_CHAR(0x15) PORT_CODE(KEYCODE_U)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("I") PORT_CHAR('i') PORT_CHAR('I') PORT_CODE(KEYCODE_I)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("J") PORT_CHAR('j') PORT_CHAR('J') PORT_CODE(KEYCODE_J)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("K") PORT_CHAR('k') PORT_CHAR('K') PORT_CHAR(0x0b) PORT_CODE(KEYCODE_K)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("M") PORT_CHAR('m') PORT_CHAR('M') PORT_CODE(KEYCODE_M)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(',') PORT_CHAR('<') PORT_CODE(KEYCODE_COMMA)
+
+ PORT_START("KEYS7")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('5') PORT_CHAR('%') PORT_CODE(KEYCODE_5)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('6') PORT_CHAR('^') PORT_CODE(KEYCODE_6)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("T") PORT_CHAR('t') PORT_CHAR('T') PORT_CHAR(0x14) PORT_CODE(KEYCODE_T)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Y") PORT_CHAR('y') PORT_CHAR('Y') PORT_CHAR(0x19) PORT_CODE(KEYCODE_Y)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G (Bell)") PORT_CHAR('g') PORT_CHAR('G') PORT_CHAR(0x07) PORT_CODE(KEYCODE_G)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("H") PORT_CHAR('h') PORT_CHAR('H') PORT_CODE(KEYCODE_H)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B") PORT_CHAR('b') PORT_CHAR('B') PORT_CHAR(0x02) PORT_CODE(KEYCODE_B)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("N") PORT_CHAR('n') PORT_CHAR('N') PORT_CHAR(0x0e) PORT_CODE(KEYCODE_N)
+
+ PORT_START("KEYS8")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("3 # \xc2\xa3") PORT_CHAR('3') PORT_CHAR('#', 0xa3) PORT_CODE(KEYCODE_3)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('4') PORT_CHAR('$') PORT_CODE(KEYCODE_4)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E") PORT_CHAR('e') PORT_CHAR('E') PORT_CHAR(0x05) PORT_CODE(KEYCODE_E)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("R") PORT_CHAR('r') PORT_CHAR('R') PORT_CHAR(0x12) PORT_CODE(KEYCODE_R)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D") PORT_CHAR('d') PORT_CHAR('D') PORT_CHAR(0x04) PORT_CODE(KEYCODE_D)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F") PORT_CHAR('f') PORT_CHAR('F') PORT_CHAR(0x06) PORT_CODE(KEYCODE_F)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C") PORT_CHAR('c') PORT_CHAR('C') PORT_CHAR(0x03) PORT_CODE(KEYCODE_C)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("V") PORT_CHAR('v') PORT_CHAR('V') PORT_CHAR(0x16) PORT_CODE(KEYCODE_V)
+
+ PORT_START("KEYS9")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('1') PORT_CHAR('!') PORT_CODE(KEYCODE_1)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR('2') PORT_CHAR('@') PORT_CODE(KEYCODE_2)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Q") PORT_CHAR('q') PORT_CHAR('Q') PORT_CHAR(0x11) PORT_CODE(KEYCODE_Q)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("W") PORT_CHAR('w') PORT_CHAR('W') PORT_CHAR(0x17) PORT_CODE(KEYCODE_W)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A") PORT_CHAR('a') PORT_CHAR('A') PORT_CHAR(0x01) PORT_CODE(KEYCODE_A)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("S") PORT_CHAR('s') PORT_CHAR('S') PORT_CHAR(0x13) PORT_CODE(KEYCODE_S)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Z") PORT_CHAR('z') PORT_CHAR('Z') PORT_CHAR(0x1a) PORT_CODE(KEYCODE_Z)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("X") PORT_CHAR('x') PORT_CHAR('X') PORT_CHAR(0x18) PORT_CODE(KEYCODE_X)
+
+ PORT_START("KEYS10")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Set-Up") PORT_CHAR(UCHAR_MAMEKEY(F5)) PORT_CODE(KEYCODE_F5)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_UNUSED)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(0x1b) PORT_CODE(KEYCODE_ESC)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_UNUSED)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(0x09) PORT_CODE(KEYCODE_TAB)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_UNUSED)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("No Scroll") PORT_CHAR(UCHAR_MAMEKEY(SCRLOCK)) PORT_CODE(KEYCODE_LALT)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_CHAR(' ') PORT_CODE(KEYCODE_SPACE)
+
+ PORT_START("KBID")
+ PORT_CONFNAME(0x01, 0x01, "Keyboard Layout")
+ PORT_CONFSETTING(0x01, "QWERTY")
+ PORT_CONFSETTING(0x00, "AZERTY")
+ PORT_BIT(0xfe, IP_ACTIVE_LOW, IPT_UNUSED)
+INPUT_PORTS_END
+
+INPUT_PORTS_START(cit101e_keyboard)
+ PORT_INCLUDE(cit101_keyboard)
+
+ PORT_MODIFY("KEYS0")
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Keypad Enter (Print)") PORT_CHAR(UCHAR_MAMEKEY(ENTER_PAD)) PORT_CODE(KEYCODE_ENTER_PAD)
+INPUT_PORTS_END
+
+ioport_constructor cit101_keyboard_device::device_input_ports() const
{
- send_translated(row, column);
+ return INPUT_PORTS_NAME(cit101_keyboard);
}
-void cit101_hle_keyboard_device::key_repeat(u8 row, u8 column)
+ioport_constructor cit101e_keyboard_device::device_input_ports() const
+{
+ return INPUT_PORTS_NAME(cit101e_keyboard);
+}
+
+void cit101_keyboard_device::device_add_mconfig(machine_config &config)
+{
+ I8035(config, m_mcu, 2.376_MHz_XTAL); // TMP8048P in EA mode (location marked "8048/8035/8748" on original keyboard)
+ m_mcu->set_addrmap(AS_PROGRAM, &cit101_keyboard_device::prog_map);
+ m_mcu->set_addrmap(AS_IO, &cit101_keyboard_device::ext_map);
+ m_mcu->bus_in_cb().set(FUNC(cit101_keyboard_device::keys_r));
+ m_mcu->p2_in_cb().set_ioport("SHIFT");
+ m_mcu->p2_out_cb().set(FUNC(cit101_keyboard_device::p2_w));
+ m_mcu->t0_in_cb().set_ioport("MODIFIERS").bit(0);
+ m_mcu->t1_in_cb().set_ioport("MODIFIERS").bit(1);
+
+ SPEAKER(config, "mono").front_center();
+ BEEP(config, m_beeper, 786).add_route(ALL_OUTPUTS, "mono", 0.5); // unknown frequency (original keyboard has a NE555)
+}
+
+
+ROM_START(cit101_kbd)
+ ROM_REGION(0x800, "program", 0)
+ ROM_LOAD("pkb00.ic4", 0x000, 0x800, CRC(f93f9ce1) SHA1(50fe6b5448f8ec330fa09e8b0125b5b09c680859)) // 1st and 2nd halves identical
+ROM_END
+
+ROM_START(cit101e_kbd)
+ ROM_REGION(0x1000, "program", 0)
+ ROM_LOAD("101e-v12b_kbd_rom.ic4", 0x0000, 0x1000, CRC(b9eeac40) SHA1(1bbbe0d422f87c856a10de5a1492297958ff47f6)) // 1st and 2nd halves identical
+ROM_END
+
+const tiny_rom_entry *cit101_keyboard_device::device_rom_region() const
{
- send_translated(row, column);
+ return ROM_NAME(cit101_kbd);
}
-void cit101_hle_keyboard_device::scan_complete()
+const tiny_rom_entry *cit101e_keyboard_device::device_rom_region() const
{
- if (are_all_keys_up())
- {
- send_key(0x80);
- stop_processing();
- }
+ return ROM_NAME(cit101e_kbd);
}
diff --git a/src/mame/machine/cit101_kbd.h b/src/mame/machine/cit101_kbd.h
index 1b36653f44a..5e09d56002a 100644
--- a/src/mame/machine/cit101_kbd.h
+++ b/src/mame/machine/cit101_kbd.h
@@ -11,55 +11,80 @@
#pragma once
-#include "machine/keyboard.h"
+#include "cpu/mcs48/mcs48.h"
#include "sound/beep.h"
-#include "diserial.h"
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
-// ======================> cit101_hle_keyboard_device
+// ======================> cit101_keyboard_device
-class cit101_hle_keyboard_device : public device_t, public device_matrix_keyboard_interface<4U>, public device_buffered_serial_interface<16U>
+class cit101_keyboard_device : public device_t
{
public:
- // construction/destruction
- cit101_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
+ // device type constructor
+ cit101_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
- // configuration
+ static constexpr feature_type unemulated_features() { return feature::SOUND; }
+
+ // callback configuration
auto txd_callback() { return m_txd_callback.bind(); }
+ // serial line input
DECLARE_WRITE_LINE_MEMBER(write_rxd);
protected:
- // device_t overrides
- virtual void device_add_mconfig(machine_config &config) override;
- virtual ioport_constructor device_input_ports() const override;
+ cit101_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
+
+ // device-level overrides
virtual void device_resolve_objects() override;
virtual void device_start() override;
- virtual void device_reset() override;
+ virtual ioport_constructor device_input_ports() const override;
+ virtual void device_add_mconfig(machine_config &config) override;
+ virtual const tiny_rom_entry *device_rom_region() const override;
- // device_buffered_serial_interface overrides
- virtual void tra_callback() override;
- virtual void received_byte(u8 byte) override;
+private:
+ // MCU handlers
+ void p2_w(u8 data);
+ void leds_w(u8 data);
+ u8 keys_r();
- // device_matrix_keyboard_interface overrides
- virtual void key_make(u8 row, u8 column) override;
- virtual void key_repeat(u8 row, u8 column) override;
- virtual void scan_complete() override;
+ // address maps
+ void prog_map(address_map &map);
+ void ext_map(address_map &map);
- void send_translated(u8 row, u8 column);
- void send_key(u8 code);
-private:
- required_ioport m_modifiers;
+ // object finders
+ required_device<mcs48_cpu_device> m_mcu;
required_device<beep_device> m_beeper;
+ required_ioport_array<11> m_keys;
+ required_ioport m_kbid;
+ output_finder<7> m_leds;
+
+ // output callback
devcb_write_line m_txd_callback;
- u8 m_command[2];
+
+ // internal state
+ bool m_kbid_enabled;
+};
+
+// ======================> cit101e_keyboard_device
+
+class cit101e_keyboard_device : public cit101_keyboard_device
+{
+public:
+ // device type constructor
+ cit101e_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
+
+protected:
+ // device-level overrides
+ virtual ioport_constructor device_input_ports() const override;
+ virtual const tiny_rom_entry *device_rom_region() const override;
};
-// device type definition
-DECLARE_DEVICE_TYPE(CIT101_HLE_KEYBOARD, cit101_hle_keyboard_device)
+// device type declarations
+DECLARE_DEVICE_TYPE(CIT101_KEYBOARD, cit101_keyboard_device)
+DECLARE_DEVICE_TYPE(CIT101E_KEYBOARD, cit101e_keyboard_device)
#endif
diff --git a/src/mame/machine/dai.cpp b/src/mame/machine/dai.cpp
index 06cca62cf93..c569f898399 100644
--- a/src/mame/machine/dai.cpp
+++ b/src/mame/machine/dai.cpp
@@ -23,11 +23,8 @@ void dai_state::device_timer(emu_timer &timer, device_timer_id id, int param, vo
{
switch (id)
{
- case TIMER_BOOTSTRAP:
- m_maincpu->set_pc(0xc000);
- break;
case TIMER_TMS5501:
- m_tms5501->xi7_w((ioport("IN8")->read() & 0x04) ? 1:0);
+ m_tms5501->xi7_w(BIT(m_io_keyboard[8]->read(), 2));
timer_set(attotime::from_hz(100), TIMER_TMS5501);
break;
default:
@@ -41,33 +38,24 @@ void dai_state::device_timer(emu_timer &timer, device_timer_id id, int param, vo
/* Memory */
-void dai_state::dai_stack_interrupt_circuit_w(uint8_t data)
+void dai_state::stack_interrupt_circuit_w(uint8_t data)
{
m_tms5501->sens_w(1);
m_tms5501->sens_w(0);
}
-void dai_state::dai_update_memory(int dai_rom_bank)
-{
- membank("bank2")->set_entry(dai_rom_bank);
-}
-
-
-uint8_t dai_state::dai_keyboard_r()
+uint8_t dai_state::keyboard_r()
{
uint8_t data = 0x00;
- static const char *const keynames[] = { "IN0", "IN1", "IN2", "IN3", "IN4", "IN5", "IN6", "IN7" };
- for (int i = 0; i < 8; i++)
- {
+ for (u8 i = 0; i < 8; i++)
if (m_keyboard_scan_mask & (1 << i))
- data |= ioport(keynames[i])->read();
- }
+ data |= m_io_keyboard[i]->read();
return data;
}
-void dai_state::dai_keyboard_w(uint8_t data)
+void dai_state::keyboard_w(uint8_t data)
{
m_keyboard_scan_mask = data;
}
@@ -79,16 +67,33 @@ IRQ_CALLBACK_MEMBER(dai_state::int_ack)
void dai_state::machine_start()
{
- membank("bank2")->configure_entries(0, 4, memregion("maincpu")->base() + 0x010000, 0x1000);
- timer_set(attotime::zero, TIMER_BOOTSTRAP);
+ membank("bank2")->configure_entries(0, 4, m_rom + 0x2000, 0x1000);
timer_set(attotime::from_hz(100), TIMER_TMS5501);
-
- memset(m_ram->pointer(), 0, m_ram->size());
+ save_item(NAME(m_paddle_select));
+ save_item(NAME(m_paddle_enable));
+ save_item(NAME(m_cassette_motor));
+ save_item(NAME(m_keyboard_scan_mask));
+ save_item(NAME(m_4_colours_palette));
}
void dai_state::machine_reset()
{
- membank("bank1")->set_base(m_ram->pointer());
+ address_space &program = m_maincpu->space(AS_PROGRAM);
+ program.install_rom(0x0000, 0x07ff, m_rom); // do it here for F3
+ m_rom_shadow_tap = program.install_read_tap(0xc000, 0xc7ff, "rom_shadow_r",[this](offs_t offset, u8 &data, u8 mem_mask)
+ {
+ if (!machine().side_effects_disabled())
+ {
+ // delete this tap
+ m_rom_shadow_tap->remove();
+
+ // reinstall ram over the rom shadow
+ m_maincpu->space(AS_PROGRAM).install_ram(0x0000, 0x07ff, m_ram);
+ }
+
+ // return the original data
+ return data;
+ });
}
/***************************************************************************
@@ -120,13 +125,13 @@ void dai_state::machine_reset()
bit 6-7 ROM bank switching
***************************************************************************/
-uint8_t dai_state::dai_io_discrete_devices_r(offs_t offset)
+uint8_t dai_state::io_discrete_devices_r(offs_t offset)
{
- uint8_t data = 0x00;
+ uint8_t data = 0xff;
- switch(offset & 0x000f) {
- case 0x00:
- data = ioport("IN8")->read();
+ switch(offset & 0x0f) {
+ case 0:
+ data = m_io_keyboard[8]->read();
data |= 0x08; // serial ready
if (machine().rand()&0x01)
data |= 0x40; // random number generator
@@ -135,42 +140,40 @@ uint8_t dai_state::dai_io_discrete_devices_r(offs_t offset)
break;
default:
- data = 0xff;
LOG_DAI_PORT_R (offset, data, "discrete devices - unmapped");
-
break;
}
return data;
}
-void dai_state::dai_io_discrete_devices_w(offs_t offset, uint8_t data)
+void dai_state::io_discrete_devices_w(offs_t offset, uint8_t data)
{
switch(offset & 0x000f) {
case 0x04:
m_sound->set_volume(offset, data);
LOG_DAI_PORT_W (offset, data&0x0f, "discrete devices - osc. 0 volume");
- LOG_DAI_PORT_W (offset, (data&0xf0)>>4, "discrete devices - osc. 1 volume");
+ LOG_DAI_PORT_W (offset, BIT(data, 4, 4), "discrete devices - osc. 1 volume");
break;
case 0x05:
m_sound->set_volume(offset, data);
LOG_DAI_PORT_W (offset, data&0x0f, "discrete devices - osc. 2 volume");
- LOG_DAI_PORT_W (offset, (data&0xf0)>>4, "discrete devices - noise volume");
+ LOG_DAI_PORT_W (offset, BIT(data, 4, 4), "discrete devices - noise volume");
break;
case 0x06:
- m_paddle_select = (data&0x06)>>2;
- m_paddle_enable = (data&0x08)>>3;
- m_cassette_motor[0] = (data&0x10)>>4;
- m_cassette_motor[1] = (data&0x20)>>5;
+ m_paddle_select = BIT(data, 1, 2);
+ m_paddle_enable = BIT(data, 3);
+ m_cassette_motor[0] = BIT(data, 4);
+ m_cassette_motor[1] = BIT(data, 5);
m_cassette->change_state(m_cassette_motor[0]?CASSETTE_MOTOR_DISABLED:CASSETTE_MOTOR_ENABLED, CASSETTE_MASK_MOTOR);
- m_cassette->output((data & 0x01) ? -1.0 : 1.0);
- dai_update_memory ((data&0xc0)>>6);
- LOG_DAI_PORT_W (offset, (data&0x06)>>2, "discrete devices - paddle select");
- LOG_DAI_PORT_W (offset, (data&0x08)>>3, "discrete devices - paddle enable");
- LOG_DAI_PORT_W (offset, (data&0x10)>>4, "discrete devices - cassette motor 1");
- LOG_DAI_PORT_W (offset, (data&0x20)>>5, "discrete devices - cassette motor 2");
- LOG_DAI_PORT_W (offset, (data&0xc0)>>6, "discrete devices - ROM bank");
+ m_cassette->output(BIT(data, 0) ? -1.0 : 1.0);
+ membank("bank2")->set_entry(BIT(data, 6, 2));
+ LOG_DAI_PORT_W (offset, BIT(data, 1, 2), "discrete devices - paddle select");
+ LOG_DAI_PORT_W (offset, BIT(data, 3), "discrete devices - paddle enable");
+ LOG_DAI_PORT_W (offset, BIT(data, 4), "discrete devices - cassette motor 1");
+ LOG_DAI_PORT_W (offset, BIT(data, 5), "discrete devices - cassette motor 2");
+ LOG_DAI_PORT_W (offset, BIT(data, 6, 2), "discrete devices - ROM bank");
break;
default:
@@ -188,14 +191,14 @@ void dai_state::dai_io_discrete_devices_w(offs_t offset, uint8_t data)
***************************************************************************/
-uint8_t dai_state::dai_pit_r(offs_t offset)
+uint8_t dai_state::pit_r(offs_t offset)
{
- return m_pit->read((offset >> 1) & 3);
+ return m_pit->read(BIT(offset, 1, 2));
}
-void dai_state::dai_pit_w(offs_t offset, uint8_t data)
+void dai_state::pit_w(offs_t offset, uint8_t data)
{
- m_pit->write((offset >> 1) & 3, data);
+ m_pit->write(BIT(offset, 1, 2), data);
}
/***************************************************************************
@@ -204,13 +207,13 @@ void dai_state::dai_pit_w(offs_t offset, uint8_t data)
***************************************************************************/
-uint8_t dai_state::dai_amd9511_r()
+uint8_t dai_state::amd9511_r()
{
- /* optional and no present at this moment */
+ /* optional and not present at this moment */
return 0xff;
}
-void dai_state::dai_amd9511_w(offs_t offset, uint8_t data)
+void dai_state::amd9511_w(offs_t offset, uint8_t data)
{
logerror ("Writing to AMD9511 math chip, %04x, %02x\n", offset, data);
}
diff --git a/src/mame/machine/hec2hrp.cpp b/src/mame/machine/hec2hrp.cpp
index 26b5029eca0..2a7264fe668 100644
--- a/src/mame/machine/hec2hrp.cpp
+++ b/src/mame/machine/hec2hrp.cpp
@@ -36,15 +36,12 @@
- http://dchector.free.fr/
- http://hectorvictor.free.fr/
- TODO : Add cartridge functionality,
- Adjust the one shot and A/D timing (sn76477)
*/
#include "emu.h"
#include "includes/hec2hrp.h"
#include "cpu/z80/z80.h"
-#include "sound/wave.h" /* for K7 sound */
#include "speaker.h"
@@ -67,36 +64,48 @@ hec2mx80
hec2mx40
*/
-/* Helper function*/
-int hec2hrp_state::has_disc2()
+
+void hec2hrp_state::init_mx40()
+{
+ m_has_disc2 = true;
+ m_has_minidisc = false;
+ m_is_hr = true;
+ m_is_extended = true;
+}
+
+void hec2hrp_state::init_mdhrx()
{
- return ((strncmp(machine().system().name , "hec2hrx" , 7)==0) ||
- (strncmp(machine().system().name , "hec2mx40" , 8)==0) ||
- (strncmp(machine().system().name , "hec2mx80" , 8)==0));
+ m_has_disc2 = false;
+ m_has_minidisc = true;
+ m_is_hr = true;
+ m_is_extended = true;
}
-int hec2hrp_state::has_minidisc()
+void hec2hrp_state::init_victor()
{
- return ((strncmp(machine().system().name , "hec2mdhrx", 9)==0));
+ m_has_disc2 = false;
+ m_has_minidisc = false;
+ m_is_hr = true;
+ m_is_extended = false;
}
-int hec2hrp_state::is_hr()
+void hec2hrp_state::init_hrx()
{
- return ((strncmp(machine().system().name , "hec2hr" , 6)==0) || //Aviable for hr & hrp
- (strncmp(machine().system().name , "hec2mdhrx", 9)==0) ||
- (strncmp(machine().system().name , "victor" , 6)==0) ||
- (strncmp(machine().system().name , "hec2mx40" , 8)==0) ||
- (strncmp(machine().system().name , "hec2mx80" , 8)==0));
+ m_has_disc2 = true;
+ m_has_minidisc = false;
+ m_is_hr = false;
+ m_is_extended = true;
}
-int hec2hrp_state::is_extended()
+void hec2hrp_state::init_interact()
{
- return ((strncmp(machine().system().name , "hec2mdhrx", 9)==0) ||
- (strncmp(machine().system().name , "hec2hrx" , 7)==0) ||
- (strncmp(machine().system().name , "hec2mx40" , 8)==0) ||
- (strncmp(machine().system().name , "hec2mx80" , 8)==0));
+ m_has_disc2 = false;
+ m_has_minidisc = false;
+ m_is_hr = false;
+ m_is_extended = false;
}
+
/* Cassette timer*/
TIMER_CALLBACK_MEMBER(hec2hrp_state::cassette_clock)
{
@@ -119,61 +128,57 @@ void hec2hrp_state::minidisc_control_w(uint8_t data)
floppy->ss_w(BIT(data, 4));
}
- membank("bank2")->set_entry(BIT(data, 5) ? HECTOR_BANK_BASE : HECTOR_BANK_DISC);
+ m_bank[2]->set_entry(BIT(data, 5) ? HECTOR_BANK_BASE : HECTOR_BANK_DISC);
}
void hec2hrp_state::switch_bank_w(offs_t offset, uint8_t data)
{
if (offset==0x00)
{
- if (is_extended())
- {
- membank("bank1")->set_entry(HECTOR_BANK_VIDEO);
- }
- if (m_flag_clk == 1)
+ if (m_is_extended)
+ m_bank[1]->set_entry(HECTOR_BANK_VIDEO);
+
+ if (m_flag_clk)
{
- m_flag_clk = 0;
+ m_flag_clk = false;
m_maincpu->set_unscaled_clock(XTAL(5'000'000));
}
}
if (offset==0x04)
{
- m_hector_flag_hr = 0;
- if (is_extended())
- {
- membank("bank1")->set_entry(HECTOR_BANK_VIDEO);
- }
- if (m_flag_clk == 0)
+ m_hector_flag_hr = false;
+ if (m_is_extended)
+ m_bank[1]->set_entry(HECTOR_BANK_VIDEO);
+
+ if (!m_flag_clk)
{
- m_flag_clk = 1;
+ m_flag_clk = true;
m_maincpu->set_unscaled_clock(XTAL(1'750'000));
}
}
if (offset==0x08)
{
- if (is_extended())
- {
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
- }
- if (m_flag_clk == 1)
+ if (m_is_extended)
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
+
+ if (m_flag_clk)
{
- m_flag_clk = 0;
+ m_flag_clk = false;
m_maincpu->set_unscaled_clock(XTAL(5'000'000));
}
}
if (offset == 0x0c)
{
- m_hector_flag_hr = 0;
- if (is_extended())
- {
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
- }
- if (m_flag_clk == 0)
+ m_hector_flag_hr = false;
+ if (m_is_extended)
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
+
+ if (!m_flag_clk)
{
- m_flag_clk = 1;
+ m_flag_clk = true;
m_maincpu->set_unscaled_clock(XTAL(1'750'000));
}
}
@@ -196,31 +201,28 @@ uint8_t hec2hrp_state::keyboard_r(offs_t offset)
if (data & 0x01) /* Reset machine */
{
m_maincpu->pulse_input_line(INPUT_LINE_RESET, attotime::zero);
- if (is_hr())
+ if (m_is_hr)
{
- m_hector_flag_hr = 1;
- if (is_extended())
+ m_hector_flag_hr = true;
+ if (m_is_extended)
{
- membank("bank1")->set_entry(HECTOR_BANK_PROG);
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE0);
+ m_bank[1]->set_entry(HECTOR_BANK_PROG);
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE0);
}
//RESET DISC II unit
- if (has_disc2())
+ if (m_has_disc2)
hector_disc2_reset();
/* floppy md master reset */
- if (has_minidisc())
+ if (m_has_minidisc)
m_minidisc_fdc->reset();
}
else
- {
- m_hector_flag_hr=0;
- }
-
+ m_hector_flag_hr = false;
- /*Common flag*/
- m_hector_flag_80c = 0;
- m_flag_clk = 0;
+ /*Common flag*/
+ m_hector_flag_80c = false;
+ m_flag_clk = false;
}
m_actions = 0;
@@ -232,21 +234,27 @@ uint8_t hec2hrp_state::keyboard_r(offs_t offset)
if (data & 0x08) /* Pot(0)+*/
m_pot0 += 1;
- if (m_pot0>128) m_pot0 = 128;
+
+ if (m_pot0>128)
+ m_pot0 = 128;
if (data & 0x10) /* Pot(0)-*/
m_pot0 -= 1;
- if (m_pot0>250) m_pot0 = 0;
+ if (m_pot0>250)
+ m_pot0 = 0;
if (data & 0x20) /* Pot(1)+*/
m_pot1 += 1;
- if (m_pot1>128) m_pot1 = 128;
+
+ if (m_pot1>128)
+ m_pot1 = 128;
if (data & 0x40) /* Pot(1)-*/
m_pot1 -= 1;
- if (m_pot1>250) m_pot1 = 0;
+ if (m_pot1>250)
+ m_pot1 = 0;
}
/* in all case return the requested value */
@@ -284,23 +292,19 @@ uint8_t hec2hrp_state::cassette_r()
}
else
{
- if (m_write_cassette == 0)
+ if (!m_write_cassette)
{
level = m_cassette->input();
if (level < -0.08)
- m_cassette_bit = 0x00;
+ m_cassette_bit = false;
if (level > +0.08)
- m_cassette_bit = 0x01;
+ m_cassette_bit = true;
}
- if ((m_cassette_bit != m_cassette_bit_mem) && (m_cassette_bit !=0))
- {
- if (m_data_k7 == 0x00)
- m_data_k7 = 0x80;
- else
- m_data_k7 = 0x00;
- }
+ if ((m_cassette_bit != m_cassette_bit_mem) && m_cassette_bit)
+ m_data_k7 = m_data_k7 ? 0 : 0x80;
+
value = ( m_ck_signal & 0x7F ) + m_data_k7;
m_cassette_bit_mem = m_cassette_bit;
}
@@ -309,13 +313,14 @@ uint8_t hec2hrp_state::cassette_r()
void hec2hrp_state::sn_3000_w(uint8_t data)
{
m_state3000 = data & 0xf8; /* except bit 0 to 2*/
- if ((data & 7) != m_oldstate3000 )
+ data &= 7;
+ if (data != m_oldstate3000 )
{
/* Update sn76477 only when necessary!*/
- update_state(0x3000, data & 7 );
- update_sound(data & 7);
+ update_state(0x3000, data);
+ update_sound(data);
}
- m_oldstate3000 = data & 7;
+ m_oldstate3000 = data;
}
/* Color Interface */
@@ -324,18 +329,16 @@ void hec2hrp_state::color_a_w(uint8_t data)
if (data & 0x40)
{
/* Bit 6 => motor ON/OFF => for cassette state!*/
- if (m_write_cassette==0)
+ if (!m_write_cassette)
{
- m_cassette->change_state(
- CASSETTE_MOTOR_ENABLED,
- CASSETTE_MASK_MOTOR);
+ m_cassette->change_state(CASSETTE_MOTOR_ENABLED, CASSETTE_MASK_MOTOR);
// m_cassette->set_state(CASSETTE_PLAY | CASSETTE_SPEAKER_ENABLED | CASSETTE_MOTOR_ENABLED);
}
}
else
{ /* stop motor*/
m_cassette->set_state(CASSETTE_STOPPED);
- m_write_cassette=0;
+ m_write_cassette = false;
m_counter_write =0;
}
if (((data & 0x80) != (m_oldstate1000 & 0x80)) && ((m_oldstate1000 & 7)==(data & 7)) ) /* Bit7 had change but not the color statement*/
@@ -345,15 +348,14 @@ void hec2hrp_state::color_a_w(uint8_t data)
if (m_counter_write > 5)
{
- /* Wait several cycle before lauch the record to prevent somes bugs*/
+ /* Wait several cycles before launch recording to prevent somes bugs*/
m_counter_write = 6;
- if (m_write_cassette==0)
- { /* C'est la 1er fois => record*/
- m_cassette->change_state(
- CASSETTE_MOTOR_ENABLED,
- CASSETTE_MASK_MOTOR);
+ if (!m_write_cassette)
+ {
+ // record
+ m_cassette->change_state( CASSETTE_MOTOR_ENABLED, CASSETTE_MASK_MOTOR);
m_cassette->set_state(CASSETTE_RECORD);
- m_write_cassette=1;
+ m_write_cassette = true;
}
}
/* cassette data */
@@ -361,22 +363,25 @@ void hec2hrp_state::color_a_w(uint8_t data)
}
/* Other bit : color definition*/
- m_hector_color[0] = data & 0x07 ;
- m_hector_color[2] = ((data >> 3) & 0x07) | (m_hector_color[2] & 0x40);
+ m_hector_color[0] = data & 0x07 ;
+ m_hector_color[2] = BIT(data, 3, 3) | (m_hector_color[2] & 0x40);
m_oldstate1000=data; /* For next step*/
}
void hec2hrp_state::color_b_w(uint8_t data)
{
- m_hector_color[1] = data & 0x07;
- m_hector_color[3] = (data >> 3) & 0x07;
+ m_hector_color[1] = data & 0x07;
+ m_hector_color[3] = BIT(data, 3, 3);
/* Half light on color 2 only on HR machines:*/
- if (data & 0x40) m_hector_color[2] |= 8; else m_hector_color[2] &= 7;
+ if (data & 0x40)
+ m_hector_color[2] |= 8;
+ else
+ m_hector_color[2] &= 7;
/* Play bit*/
- m_discrete->write(NODE_01, (data & 0x80) ? 0:1 );
+ m_discrete->write(NODE_01, (data & 0x80) ? 0:1 );
}
@@ -391,20 +396,20 @@ uint8_t hec2hrp_state::io_8255_r(offs_t offset)
uint8_t data =0;
uint8_t data_l=0;
uint8_t data_h=0;
+ offset &= 3;
-
- if ((offset & 0x3) == 0x0) /* Port A */
+ if (offset == 0) /* Port A */
data = m_hector_port_a;
-
- if ((offset & 0x3) == 0x1) /* Port B */
+ else
+ if (offset == 1) /* Port B */
{
data = m_hector_port_b;
#ifdef DEBUG_TRACE_COM_HECTOR
printf("\nLecture data par Hector %x (portB)",data);
#endif
}
-
- if ((offset & 0x3) == 0x2) /* Port C */
+ else
+ if (offset == 2) /* Port C */
{
data_l = (m_hector_port_c_l & 0x0f);
data_h = (m_hector_port_c_h & 0xf0);
@@ -414,18 +419,18 @@ uint8_t hec2hrp_state::io_8255_r(offs_t offset)
if (BIT(m_hector_port_cmd, 3)) /* Quartet sup en entree ?*/
{
- m_hector_port_c_h = (m_hector_port_c_h & 0x0c0); /* Clear bits 4 & 5*/
+ m_hector_port_c_h = (m_hector_port_c_h & 0xc0); /* Clear bits 4 & 5*/
if (m_hector_disc2_data_w_ready != 0x00)
- m_hector_port_c_h = m_hector_port_c_h + 0x010; // PC4 (data write ready from Disc II to Hector)
+ m_hector_port_c_h = m_hector_port_c_h + 0x10; // PC4 (data write ready from Disc II to Hector)
if (m_hector_disc2_data_r_ready != 0x00)
- m_hector_port_c_h = m_hector_port_c_h + 0x020; // PC5 (data read ready from Hector to Disc2)
+ m_hector_port_c_h = m_hector_port_c_h + 0x20; // PC5 (data read ready from Hector to Disc2)
- m_hector_port_c_h = m_hector_port_c_h & 0x07F; // PC7 (printer busy=0)
+ m_hector_port_c_h = m_hector_port_c_h & 0x7F; // PC7 (printer busy=0)
data_h = m_hector_port_c_h;
}
- data= data_l + data_h;
+ data = data_l + data_h;
}
return data; // Return the value!
}
@@ -434,8 +439,9 @@ uint8_t hec2hrp_state::io_8255_r(offs_t offset)
void hec2hrp_state::io_8255_w(offs_t offset, uint8_t data)
{
+ offset &= 3;
/* 8255 in mode 0 */
- if ((offset & 0x3) == 0x0) /* Port A => to printer or Disc II*/
+ if (offset == 0) /* Port A => to printer or Disc II*/
{
m_hector_port_a = data;
/* Port A => to printer*/
@@ -443,16 +449,13 @@ void hec2hrp_state::io_8255_w(offs_t offset, uint8_t data)
So, everything sent to the Disc2 unit will be printed too! */
if (BIT(m_hector_port_c_l, 0)) // PC0 (bit 0) = strobe printer
- {
m_printer->output(m_hector_port_a);
- }
}
-
- if ((offset & 0x3) == 0x1) /* Port B */
+ else
+ if (offset == 1) /* Port B */
m_hector_port_b = data;
-
-
- if ((offset & 0x3) == 0x2) /* Port C => depending cmd word */
+ else
+ if (offset == 2) /* Port C => depending cmd word */
{
if (!BIT(m_hector_port_cmd, 0))
{
@@ -477,11 +480,8 @@ void hec2hrp_state::io_8255_w(offs_t offset, uint8_t data)
if (!BIT(m_hector_port_cmd, 3))
m_hector_port_c_h = (data & 0xf0);
}
-
- if ((offset & 0x3) == 0x3) /* command */
- {
+ else // offset=3
m_hector_port_cmd = data;
- }
}
/* End of 8255 managing */
@@ -489,36 +489,87 @@ void hec2hrp_state::io_8255_w(offs_t offset, uint8_t data)
/******************* PIO write handler for MX40 *******************/
void hec2hrp_state::mx40_io_port_w(offs_t offset, uint8_t data)
{
+ offset &= 0xff;
+
/* Bank switching on several address */
- if ((offset &0x0ff) == 0x40) /* Port page 0*/
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE0);
- if ((offset &0x0ff) == 0x41) /* Port page 1*/
+ if (offset == 0x40) /* Port page 0*/
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE0);
+ else
+ if (offset == 0x41) /* Port page 1*/
{
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE1);
- m_hector_flag_80c=0;
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE1);
+ m_hector_flag_80c = false;
}
- if ((offset &0x0ff) == 0x44) /* Port page 2 => 42 pour MX80*/
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE2);
- if ((offset &0x0ff) == 0x49) /* Port screen resolution*/
- m_hector_flag_80c=0;/* No 80c in 40c !*/
+ else
+ if (offset == 0x44) /* Port page 2 => 42 on MX80*/
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE2);
+ else
+ if (offset == 0x49) /* Port screen resolution*/
+ m_hector_flag_80c = false;/* No 80c in 40c !*/
}
/******************* PIO write handlerfor MX80 *******************/
void hec2hrp_state::mx80_io_port_w(offs_t offset, uint8_t data)
{
- if ((offset &0x0ff) == 0x40) /* Port page 0*/
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE0);
- if ((offset &0x0ff) == 0x41) /* Port page 1*/
+ offset &= 0xff;
+
+ if (offset == 0x40) /* Port page 0*/
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE0);
+ else
+ if (offset == 0x41) /* Port page 1*/
{
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE1);
- m_hector_flag_80c=0;
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE1);
+ m_hector_flag_80c = false;
}
- if ((offset &0x0ff) == 0x42) /* Port page 2 => different port on MX40 */
- membank("bank2")->set_entry(HECTORMX_BANK_PAGE2);
- if ((offset &0x0ff) == 0x49) /* Port screen resolution*/
- m_hector_flag_80c=1;
+ else
+ if (offset == 0x42) /* Port page 2 => different port on MX40 */
+ m_bank[2]->set_entry(HECTORMX_BANK_PAGE2);
+ else
+ if (offset == 0x49) /* Port screen resolution*/
+ m_hector_flag_80c = true;
+}
+
+void hec2hrp_state::video_start()
+{
+ save_item(NAME(m_has_disc2));
+ save_item(NAME(m_has_minidisc));
+ save_item(NAME(m_is_hr));
+ save_item(NAME(m_is_extended));
+ save_item(NAME(m_hector_flag_hr));
+ save_item(NAME(m_hector_flag_80c));
+ save_item(NAME(m_hector_color));
+ save_item(NAME(m_hector_disc2_data_r_ready));
+ save_item(NAME(m_hector_disc2_data_w_ready));
+ save_item(NAME(m_hector_disc2_data_read));
+ save_item(NAME(m_hector_disc2_data_write));
+ save_item(NAME(m_hector_disc2_rnmi));
+ save_item(NAME(m_state3000));
+ save_item(NAME(m_write_cassette));
+ save_item(NAME(m_ck_signal));
+ save_item(NAME(m_flag_clk));
+ save_item(NAME(m_pin_value));
+ save_item(NAME(m_au));
+ save_item(NAME(m_val_mixer));
+ save_item(NAME(m_oldstate3000));
+ save_item(NAME(m_oldstate1000));
+ save_item(NAME(m_pot0));
+ save_item(NAME(m_pot1));
+ save_item(NAME(m_actions));
+ save_item(NAME(m_hector_port_a));
+ save_item(NAME(m_hector_port_b));
+ save_item(NAME(m_hector_port_c_h));
+ save_item(NAME(m_hector_port_c_l));
+ save_item(NAME(m_hector_port_cmd));
+ save_item(NAME(m_cassette_bit));
+ save_item(NAME(m_cassette_bit_mem));
+ save_item(NAME(m_data_k7));
+ save_item(NAME(m_counter_write));
+ save_item(NAME(m_irq_current_state));
+ save_item(NAME(m_nmi_current_state));
+ save_item(NAME(m_hector_videoram_hrx));
}
+
/********************************************************************************
sound management
********************************************************************************/
@@ -530,63 +581,63 @@ switch(Adresse )
{
case 0x2000:
{
- m_au[ 0] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[ 8] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 0] = BIT(Value, 7);
+ m_au[ 8] = BIT(Value, 6);
break;
}
case 0x2001:
{
- m_au[ 1] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[ 9] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 1] = BIT(Value, 7);
+ m_au[ 9] = BIT(Value, 6);
break;
}
case 0x2002:
{
- m_au[ 2] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[10] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 2] = BIT(Value, 7);
+ m_au[10] = BIT(Value, 6);
break;
}
case 0x2003:
{
- m_au[ 3] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[11] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 3] = BIT(Value, 7);
+ m_au[11] = BIT(Value, 6);
break;
}
case 0x2800:
{
- m_au[ 4] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[12] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 4] = BIT(Value, 7);
+ m_au[12] = BIT(Value, 6);
break;
}
case 0x2801:
{
- m_au[ 5] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[13] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 5] = BIT(Value, 7);
+ m_au[13] = BIT(Value, 6);
break;
}
case 0x2802:
{
- m_au[ 6] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[14] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 6] = BIT(Value, 7);
+ m_au[14] = BIT(Value, 6);
break;
}
case 0x2803:
{
- m_au[ 7] = ((Value & 0x080 )==0) ? 0 : 1 ;
- m_au[15] = ((Value & 0x040 )==0) ? 0 : 1 ;
+ m_au[ 7] = BIT(Value, 7);
+ m_au[15] = BIT(Value, 6);
break;
}
case 0x3000:
{
- m_val_mixer = (Value & 7) ;
+ m_val_mixer = Value & 7;
break;
}
default: break;
@@ -632,8 +683,8 @@ void hec2hrp_state::init_sn76477()
m_pin_value[17][0] = CAP_N(47.0) ; /* measured */
m_pin_value[17][1] = CAP_N(580.0) ; /* measured */
/* R VCO Version 3*/
- m_pin_value[18][1] = RES_K(1400.0 );/* Measured 1300, instead of 1Mohm*/
- m_pin_value[18][0] = RES_K( 203.548 );/* Measured 223, instead of 193.548 (1000 // 240KOhm)*/
+ m_pin_value[18][1] = RES_K(1400.0); /* Measured 1300, instead of 1Mohm*/
+ m_pin_value[18][0] = RES_K(203.548);/* Measured 223, instead of 193.548 (1000 // 240KOhm)*/
/* VCO Controle*/
m_pin_value[16][0] = 0.0; /* Volts */
@@ -667,14 +718,14 @@ void hec2hrp_state::init_sn76477()
m_pin_value[6][1] = CAP_U(08.60); /* 0.48*/
/* Values from schematic */
- m_pin_value[5][1] = RES_K(3.30 ) ; /* 330Kohm*/
- m_pin_value[5][0] = RES_K(1.76 ) ; /* 76 Kohm*/
+ m_pin_value[5][1] = RES_K(3.30 ); /* 330Kohm*/
+ m_pin_value[5][0] = RES_K(1.76 ); /* 76 Kohm*/
/* Noise is not controlled by the audio bus! */
/* Only value[0] is documented! */
- m_pin_value[4][0] = RES_K(47) ; /* 47 K ohm*/
+ m_pin_value[4][0] = RES_K(47); /* 47 K ohm*/
m_pin_value[12][0] = RES_K(100); /* 100K ohm*/
- m_pin_value[3][0] = 0 ; /* NC*/
+ m_pin_value[3][0] = 0; /* NC*/
/* Envelope-related */
m_pin_value[ 1][0] = 0;
@@ -684,31 +735,18 @@ void hec2hrp_state::init_sn76477()
m_pin_value[28][1] = 1;
/* SN pins initialized to 0 */
- m_au[0]=0;
- m_au[1]=0;
- m_au[2]=0;
- m_au[3]=0;
- m_au[4]=0;
- m_au[5]=0;
- m_au[6]=0;
- m_au[7]=0;
- m_au[8]=0;
- m_au[9]=0;
- m_au[10]=0;
- m_au[11]=0;
- m_au[12]=0;
- m_au[13]=0;
- m_au[14]=0;
- m_au[15]=0;
+ for (u8 i = 0; i < 16; i++)
+ m_au[i]=0;
+
m_val_mixer = 0;
}
void hec2hrp_state::update_sound(uint8_t data)
{
/* MIXER */
- m_sn->mixer_a_w(((m_val_mixer & 0x04)==4) ? 1 : 0);
- m_sn->mixer_b_w(((m_val_mixer & 0x01)==1) ? 1 : 0);
- m_sn->mixer_c_w(((m_val_mixer & 0x02)==2) ? 1 : 0); /* Measured on HRX*/
+ m_sn->mixer_a_w(BIT(m_val_mixer, 2));
+ m_sn->mixer_b_w(BIT(m_val_mixer, 0));
+ m_sn->mixer_c_w(BIT(m_val_mixer, 1)); /* Measured on HRX*/
/* VCO oscillator */
if (m_au[12]==1)
@@ -716,17 +754,17 @@ void hec2hrp_state::update_sound(uint8_t data)
else
m_sn->vco_res_w(m_pin_value[18][m_au[10]]); /* no AU11 */
- m_sn->vco_cap_w(m_pin_value[17][m_au[2 ]]);
+ m_sn->vco_cap_w(m_pin_value[17][m_au[2]]);
m_sn->pitch_voltage_w(m_pin_value[19][m_au[15]]);
m_sn->vco_voltage_w(m_pin_value[16][m_au[15]]);
m_sn->vco_w(m_pin_value[22][m_au[12]]); /* VCO Select Ext/SLF */
/* SLF */
- m_sn->slf_res_w(m_pin_value[20][m_au[ 9]]); /* AU10 */
- m_sn->slf_cap_w(m_pin_value[21][m_au[1 ]]);
+ m_sn->slf_res_w(m_pin_value[20][m_au[9]]); /* AU10 */
+ m_sn->slf_cap_w(m_pin_value[21][m_au[1]]);
/* One Shot */
- m_sn->one_shot_res_w(m_pin_value[24][ 0]); /* NC */
+ m_sn->one_shot_res_w(m_pin_value[24][0]); /* NC */
m_sn->one_shot_cap_w(m_pin_value[23][m_au[13]]);
/* amplitude value*/
@@ -734,7 +772,7 @@ void hec2hrp_state::update_sound(uint8_t data)
/* attack/decay */
m_sn->attack_res_w(m_pin_value[10][m_au[ 8]]);
- m_sn->decay_res_w(m_pin_value[7 ][m_au[11]]);
+ m_sn->decay_res_w(m_pin_value[7][m_au[11]]);
m_sn->attack_decay_cap_w(m_pin_value[8][m_au[0]]);
/* filter */
@@ -746,23 +784,23 @@ void hec2hrp_state::update_sound(uint8_t data)
m_sn->feedback_res_w(m_pin_value[12][0]);
/* envelope */
- m_sn->envelope_1_w(m_pin_value[1 ][m_au[6]]);
+ m_sn->envelope_1_w(m_pin_value[1] [m_au[6]]);
m_sn->envelope_2_w(m_pin_value[28][m_au[7]]);
/* finally, enable */
m_sn->enable_w(m_pin_value[9][m_au[14]]);
}
-void hec2hrp_state::hector_reset(int hr, int with_d2)
+void hec2hrp_state::hector_reset(bool hr, bool with_d2)
{
// Hector init
m_hector_flag_hr = hr;
- m_flag_clk = 0;
- m_write_cassette = 0;
+ m_flag_clk = false;
+ m_write_cassette = false;
m_maincpu->pulse_input_line(INPUT_LINE_RESET, attotime::zero);
// Disc II init
- if (with_d2 == 1)
+ if (with_d2)
{
m_disc2cpu->pulse_input_line(INPUT_LINE_RESET, attotime::zero);
m_upd_fdc->reset();
@@ -791,7 +829,6 @@ DISCRETE_SOUND_END
void hec2hrp_state::hector_audio(machine_config &config)
{
SPEAKER(config, "mono").front_center();
- WAVE(config, "wave", m_cassette).add_route(0, "mono", 0.25); /* Sound level for cassette, as it is in mono => output channel=0*/
SN76477(config, m_sn);
m_sn->set_noise_params(RES_K(47), RES_K(330), CAP_P(390));
@@ -857,7 +894,7 @@ void hec2hrp_state::hector_disc2_reset()
m_disc2cpu->pulse_input_line(INPUT_LINE_RESET, attotime::zero);
m_upd_fdc->reset();
// Select ROM to cold restart
- membank("bank3")->set_entry(DISCII_BANK_ROM);
+ m_bank[3]->set_entry(DISCII_BANK_ROM);
// Clear the Hardware's buffers
m_hector_disc2_data_r_ready = 0x0; /* =ff when PC2 = true and data is in read buffer (state->m_hector_disc2_data_read) */
@@ -874,13 +911,13 @@ void hec2hrp_state::hector_disc2_reset()
uint8_t hec2hrp_state::disc2_io00_port_r()
{
/* Switch Disc 2 to RAM */
- membank("bank3")->set_entry(DISCII_BANK_RAM);
+ m_bank[3]->set_entry(DISCII_BANK_RAM);
return 0;
}
void hec2hrp_state::disc2_io00_port_w(uint8_t data)
{
/* Switch Disc 2 to RAM */
- membank("bank3")->set_entry(DISCII_BANK_RAM);
+ m_bank[3]->set_entry(DISCII_BANK_RAM);
}
uint8_t hec2hrp_state::disc2_io20_port_r()
{
diff --git a/src/mame/machine/lviv.cpp b/src/mame/machine/lviv.cpp
index 5520728e2a4..99598109f6d 100644
--- a/src/mame/machine/lviv.cpp
+++ b/src/mame/machine/lviv.cpp
@@ -24,7 +24,7 @@ void lviv_state::update_memory()
{
uint8_t *ram = m_ram->pointer();
- if (m_ppi_port_outputs[0][2] & 0x02)
+ if (BIT(m_ppi_port_outputs[0][2], 1))
{
m_bank[0]->set_base(ram);
m_bank[1]->set_base(ram + 0x4000);
@@ -41,17 +41,17 @@ INPUT_CHANGED_MEMBER(lviv_state::reset_button)
machine().schedule_soft_reset();
}
-uint8_t lviv_state::ppi_0_porta_r()
+uint8_t lviv_state::ppi0_porta_r()
{
return 0xff;
}
-uint8_t lviv_state::ppi_0_portb_r()
+uint8_t lviv_state::ppi0_portb_r()
{
return 0xff;
}
-uint8_t lviv_state::ppi_0_portc_r()
+uint8_t lviv_state::ppi0_portc_r()
{
uint8_t data = m_ppi_port_outputs[0][2] & 0x0f;
if (m_cassette->input() > 0.038)
@@ -61,32 +61,32 @@ uint8_t lviv_state::ppi_0_portc_r()
return data;
}
-void lviv_state::ppi_0_porta_w(uint8_t data)
+void lviv_state::ppi0_porta_w(uint8_t data)
{
m_ppi_port_outputs[0][0] = data;
}
-void lviv_state::ppi_0_portb_w(uint8_t data)
+void lviv_state::ppi0_portb_w(uint8_t data)
{
m_ppi_port_outputs[0][1] = data;
update_palette(data&0x7f);
}
-void lviv_state::ppi_0_portc_w(uint8_t data)/* tape in/out, video memory on/off */
+void lviv_state::ppi0_portc_w(uint8_t data)/* tape in/out, video memory on/off */
{
m_ppi_port_outputs[0][2] = data;
- if (m_ppi_port_outputs[0][1]&0x80)
- m_speaker->level_w(data & 0x01);
- m_cassette->output((data & 0x01) ? -1.0 : 1.0);
+ if (BIT(m_ppi_port_outputs[0][1], 7))
+ m_speaker->level_w(BIT(data, 0));
+ m_cassette->output(BIT(data, 0) ? -1.0 : 1.0);
update_memory();
}
-uint8_t lviv_state::ppi_1_porta_r()
+uint8_t lviv_state::ppi1_porta_r()
{
return 0xff;
}
-uint8_t lviv_state::ppi_1_portb_r()/* keyboard reading */
+uint8_t lviv_state::ppi1_portb_r()/* keyboard reading */
{
return ((m_ppi_port_outputs[1][0] & 0x01) ? 0xff : m_key[0]->read()) &
((m_ppi_port_outputs[1][0] & 0x02) ? 0xff : m_key[1]->read()) &
@@ -98,7 +98,7 @@ uint8_t lviv_state::ppi_1_portb_r()/* keyboard reading */
((m_ppi_port_outputs[1][0] & 0x80) ? 0xff : m_key[7]->read());
}
-uint8_t lviv_state::ppi_1_portc_r()/* keyboard reading */
+uint8_t lviv_state::ppi1_portc_r()/* keyboard reading */
{
return ((m_ppi_port_outputs[1][2] & 0x01) ? 0xff : m_key[ 8]->read()) &
((m_ppi_port_outputs[1][2] & 0x02) ? 0xff : m_key[ 9]->read()) &
@@ -106,17 +106,17 @@ uint8_t lviv_state::ppi_1_portc_r()/* keyboard reading */
((m_ppi_port_outputs[1][2] & 0x08) ? 0xff : m_key[11]->read());
}
-void lviv_state::ppi_1_porta_w(uint8_t data)/* kayboard scaning */
+void lviv_state::ppi1_porta_w(uint8_t data)/* kayboard scanning */
{
m_ppi_port_outputs[1][0] = data;
}
-void lviv_state::ppi_1_portb_w(uint8_t data)
+void lviv_state::ppi1_portb_w(uint8_t data)
{
m_ppi_port_outputs[1][1] = data;
}
-void lviv_state::ppi_1_portc_w(uint8_t data)/* kayboard scaning */
+void lviv_state::ppi1_portc_w(uint8_t data)/* kayboard scanning */
{
m_ppi_port_outputs[1][2] = data;
}
@@ -131,7 +131,7 @@ uint8_t lviv_state::io_r(offs_t offset)
}
else
{
- const uint8_t switch_val = (offset >> 4) & 0x3;
+ const uint8_t switch_val = BIT(offset, 4, 2);
switch (switch_val)
{
case 0:
@@ -164,11 +164,11 @@ void lviv_state::io_w(offs_t offset, uint8_t data)
m_bank[0]->set_base(ram);
m_bank[1]->set_base(ram + 0x4000);
m_bank[2]->set_base(ram + 0x8000);
- m_bank[3]->set_base(m_maincpu_region->base() + 0x010000);
+ m_bank[3]->set_base(m_maincpu_region->base());
}
else
{
- const uint8_t switch_val = (offset >> 4) & 0x3;
+ const uint8_t switch_val = BIT(offset, 4, 2);
switch (switch_val)
{
case 0:
@@ -189,7 +189,7 @@ void lviv_state::machine_reset()
{
address_space &space = m_maincpu->space(AS_PROGRAM);
- m_video_ram = m_ram->pointer() + 0xc000;
+ m_vram = m_ram->pointer() + 0xc000;
m_startup_mem_map = 1;
@@ -199,14 +199,18 @@ void lviv_state::machine_reset()
space.unmap_write(0xC000, 0xffff);
uint8_t *mem = m_maincpu_region->base();
- m_bank[0]->set_base(mem + 0x010000);
- m_bank[1]->set_base(mem + 0x010000);
- m_bank[2]->set_base(mem + 0x010000);
- m_bank[3]->set_base(mem + 0x010000);
-
- /*memset(m_ram->pointer(), 0, sizeof(unsigned char)*0xffff);*/
+ m_bank[0]->set_base(mem);
+ m_bank[1]->set_base(mem);
+ m_bank[2]->set_base(mem);
+ m_bank[3]->set_base(mem);
}
+void lviv_state::machine_start()
+{
+ save_item(NAME(m_colortable));
+ save_item(NAME(m_ppi_port_outputs));
+ save_item(NAME(m_startup_mem_map));
+}
/*******************************************************************************
Lviv snapshot files (SAV)
diff --git a/src/mame/machine/mpu4.cpp b/src/mame/machine/mpu4.cpp
index c6de7de46a4..7a763d0d0dd 100644
--- a/src/mame/machine/mpu4.cpp
+++ b/src/mame/machine/mpu4.cpp
@@ -159,7 +159,7 @@ IRQ line connected to CPU
| | |
| | | PA0-PA7, INPUT AUX1 connector
| | |
- | | | CA2 OUTPUT, serial port Transmit line
+ | | | CA2 OUTPUT, serial port Transmit line (Tx)
| | | CA1 not connected
| | | IRQA connected to IRQ of CPU
| | |
@@ -705,6 +705,13 @@ void mpu4_state::device_timer(emu_timer &timer, device_timer_id id, int param, v
}
+WRITE_LINE_MEMBER(mpu4_state::dataport_rxd)
+{
+ m_serial_data = state;
+ m_pia4->cb1_w(state);
+ LOG_IC3(("Dataport RX %x\n",state));
+}
+
/* IC4, 7 seg leds, 50Hz timer reel sensors, current sensors */
void mpu4_state::pia_ic4_porta_w(uint8_t data)
{
@@ -743,16 +750,13 @@ void mpu4_state::pia_ic4_portb_w(uint8_t data)
uint8_t mpu4_state::pia_ic4_portb_r()
{
- /// TODO: this shouldn't be clocked from a read callback
if ( m_serial_data )
{
m_ic4_input_b |= 0x80;
- m_pia4->cb1_w(1);
}
else
{
m_ic4_input_b &= ~0x80;
- m_pia4->cb1_w(0);
}
if (!m_reel_mux)
@@ -1072,7 +1076,7 @@ uint8_t mpu4_state::pia_ic5_portb_r()
WRITE_LINE_MEMBER(mpu4_state::pia_ic5_ca2_w)
{
LOG(("%s: IC5 PIA Write CA2 (Serial Tx) %2x\n",machine().describe_context(),state));
- m_serial_data = state;
+ m_dataport->write_txd(state);
}
@@ -1361,6 +1365,7 @@ void mpu4_state::pia_gb_portb_w(uint8_t data)
}
{
+ LOG_SS(("%s: GAMEBOARD: Volume Set to %2x\n", machine().describe_context(),data));
float percent = (32-m_global_volume)/32.0;
m_msm6376->set_output_gain(0, percent);
m_msm6376->set_output_gain(1, percent);
@@ -1392,7 +1397,6 @@ uint8_t mpu4_state::pia_gb_portb_r()
WRITE_LINE_MEMBER(mpu4_state::pia_gb_ca2_w)
{
LOG_SS(("%s: GAMEBOARD: OKI RESET data = %02X\n", machine().describe_context(), state));
-
// reset line
}
@@ -3058,6 +3062,9 @@ void mpu4_state::mpu4_common(machine_config &config)
m_pia8->irqb_handler().set(FUNC(mpu4_state::cpu0_irq));
METERS(config, m_meters, 0).set_number(8);
+
+ BACTA_DATALOGGER(config, m_dataport, 0);
+ m_dataport->rxd_handler().set(FUNC(mpu4_state::dataport_rxd));
}
void mpu4_state::mpu4_common2(machine_config &config)
@@ -3069,12 +3076,12 @@ void mpu4_state::mpu4_common2(machine_config &config)
//m_ptm_ic3ss->o3_callback().set("ptm_ic3ss", FUNC(ptm6840_device::set_g1));
//m_ptm_ic3ss->irq_callback().set(FUNC(mpu4_state::cpu1_ptm_irq));
- pia6821_device &pia_ic4ss(PIA6821(config, "pia_ic4ss", 0));
- pia_ic4ss.readpb_handler().set(FUNC(mpu4_state::pia_gb_portb_r));
- pia_ic4ss.writepa_handler().set(FUNC(mpu4_state::pia_gb_porta_w));
- pia_ic4ss.writepb_handler().set(FUNC(mpu4_state::pia_gb_portb_w));
- pia_ic4ss.ca2_handler().set(FUNC(mpu4_state::pia_gb_ca2_w));
- pia_ic4ss.cb2_handler().set(FUNC(mpu4_state::pia_gb_cb2_w));
+ PIA6821(config, m_pia_ic4ss, 0);
+ m_pia_ic4ss->readpb_handler().set(FUNC(mpu4_state::pia_gb_portb_r));
+ m_pia_ic4ss->writepa_handler().set(FUNC(mpu4_state::pia_gb_porta_w));
+ m_pia_ic4ss->writepb_handler().set(FUNC(mpu4_state::pia_gb_portb_w));
+ m_pia_ic4ss->ca2_handler().set(FUNC(mpu4_state::pia_gb_ca2_w));
+ m_pia_ic4ss->cb2_handler().set(FUNC(mpu4_state::pia_gb_cb2_w));
}
/* machine driver for MOD 2 board */
diff --git a/src/mame/machine/nl_breakout.cpp b/src/mame/machine/nl_breakout.cpp
index 5610c008f2d..1f8d17e4d0a 100644
--- a/src/mame/machine/nl_breakout.cpp
+++ b/src/mame/machine/nl_breakout.cpp
@@ -345,7 +345,7 @@ NETLIST_START(breakout)
TTL_7408_DIP(H2)
TTL_7427_DIP(H3)
TTL_7400_DIP(H4)
- DM9312_DIP(H5)
+ TTL_9312_DIP(H5)
TTL_9310_DIP(H6)
TTL_7408_DIP(H7)
@@ -355,7 +355,7 @@ NETLIST_START(breakout)
TTL_74175_DIP(J1)
TTL_7404_DIP(J2)
TTL_7402_DIP(J3)
- DM9312_DIP(J4)
+ TTL_9312_DIP(J4)
TTL_7448_DIP(J5)
TTL_9310_DIP(J6)
TTL_7420_DIP(J7)
@@ -366,7 +366,7 @@ NETLIST_START(breakout)
TTL_7486_DIP(K2)
TTL_7430_DIP(K3)
TTL_7408_DIP(K4)
- DM9312_DIP(K5)
+ TTL_9312_DIP(K5)
TTL_9310_DIP(K6)
TTL_7486_DIP(K7)
TTL_7474_DIP(K8)
@@ -376,7 +376,7 @@ NETLIST_START(breakout)
TTL_7486_DIP(L2)
TTL_82S16_DIP(L3) // Ram chip
TTL_7411_DIP(L4)
- DM9312_DIP(L5)
+ TTL_9312_DIP(L5)
TTL_9310_DIP(L6)
TTL_7486_DIP(L7)
TTL_74193_DIP(L8)
@@ -386,7 +386,7 @@ NETLIST_START(breakout)
TTL_7483_DIP(M2)
TTL_7486_DIP(M3)
TTL_7410_DIP(M4)
- DM9312_DIP(M5)
+ TTL_9312_DIP(M5)
TTL_9310_DIP(M6)
TTL_7427_DIP(M8)
TTL_7404_DIP(M9)
@@ -395,7 +395,7 @@ NETLIST_START(breakout)
TTL_7483_DIP(N2)
TTL_7486_DIP(N3)
TTL_7411_DIP(N4)
- DM9312_DIP(N5)
+ TTL_9312_DIP(N5)
TTL_9310_DIP(N6)
TTL_7408_DIP(N7)
diff --git a/src/mame/machine/nl_dpatrol.cpp b/src/mame/machine/nl_dpatrol.cpp
index 2ba7fc9505a..650b8e04c8e 100644
--- a/src/mame/machine/nl_dpatrol.cpp
+++ b/src/mame/machine/nl_dpatrol.cpp
@@ -473,8 +473,8 @@ NETLIST_START(dpatrol)
TTL_9322(C7, 16H, S5, S1, S6, S2, GROUND, S4, GROUND, S3, GROUND)
TTL_7448(C6, C7.Y1, C7.Y2, C7.Y4, C7.Y3, P, SCORE_WINDOW, 16H)
- DM9312(B6, 2H, 4H, 8H, 8H, C6.f, GROUND, GROUND, C6.b, C6.e, GROUND, GROUND, C6.c)
- DM9312(A6, 2V, 4V, 8V, 8H, C6.a, GROUND, GROUND, C6.g, GROUND, GROUND, GROUND, C6.d)
+ TTL_9312(B6, 2H, 4H, 8H, 8H, C6.f, GROUND, GROUND, C6.b, C6.e, GROUND, GROUND, C6.c)
+ TTL_9312(A6, 2V, 4V, 8V, 8H, C6.a, GROUND, GROUND, C6.g, GROUND, GROUND, GROUND, C6.d)
TTL_7408_AND(B5_4, A6.YQ, B6.YQ)
TTL_7474(A5_1, CLOCK, B5_4.Q, P, P)
ALIAS(COMP_SCORE_Q, A5_1.Q)
diff --git a/src/mame/machine/nl_palestra.cpp b/src/mame/machine/nl_palestra.cpp
index 4a1fe42900c..f09034fb408 100644
--- a/src/mame/machine/nl_palestra.cpp
+++ b/src/mame/machine/nl_palestra.cpp
@@ -26,6 +26,14 @@
#define SLOW_BUT_ACCURATE 0
+#ifndef __PLIB_PREPROCESSOR__
+#if defined(__GNUC__) && !defined(__clang__)
+ #if defined(__MINGW32__) && !defined(__x86_64) && defined(__i386__) && ((__GNUC__ > 10) || ((__GNUC__ == 10) && (__GNUC_MINOR__ >= 0)))
+ #pragma GCC optimize ("O1")
+ #endif
+#endif
+#endif
+
NETLIST_START(palestra)
// SOLVER(Solver, 10000000) to maintain accuracy when SLOW is set and CAP()s are connected
diff --git a/src/mame/machine/nl_stuntcyc.cpp b/src/mame/machine/nl_stuntcyc.cpp
index e55a7641574..35f69831de4 100644
--- a/src/mame/machine/nl_stuntcyc.cpp
+++ b/src/mame/machine/nl_stuntcyc.cpp
@@ -443,8 +443,8 @@ NETLIST_START(stuntcyc)
TTL_9322(C7, 16H, S5, S1, S6, S2, GROUND, S3, GROUND, S4, GROUND)
TTL_7448(C6, C7.Y1, C7.Y2, C7.Y3, C7.Y4, P, SCORE_WINDOW, 16H)
- DM9312(B6, 2H, 4H, 8V, 8H, C6.f, GROUND, GROUND, C6.b, C6.e, GROUND, GROUND, C6.c)
- DM9312(A6, 2V, 4V, 8V, 8H, C6.a, GROUND, GROUND, C6.g, GROUND, GROUND, GROUND, C6.d)
+ TTL_9312(B6, 2H, 4H, 8V, 8H, C6.f, GROUND, GROUND, C6.b, C6.e, GROUND, GROUND, C6.c)
+ TTL_9312(A6, 2V, 4V, 8V, 8H, C6.a, GROUND, GROUND, C6.g, GROUND, GROUND, GROUND, C6.d)
TTL_7408_AND(B5_4, A6.YQ, B6.YQ)
TTL_7474(A5_1, CLOCK, B5_4.Q, P, P)
ALIAS(COMP_SCORE_Q, A5_1.Q)
diff --git a/src/mame/machine/qix.cpp b/src/mame/machine/qix.cpp
index e7f9b38d3fe..8479daabc6d 100644
--- a/src/mame/machine/qix.cpp
+++ b/src/mame/machine/qix.cpp
@@ -33,7 +33,10 @@ void qixmcu_state::machine_start()
void zookeep_state::machine_start()
{
- qixmcu_state::machine_start();
+ if (m_mcu)
+ qixmcu_state::machine_start();
+ else
+ qix_state::machine_start();
/* configure the banking */
m_vidbank->configure_entry(0, memregion("videocpu")->base() + 0xa000);
diff --git a/src/mame/machine/xavix.cpp b/src/mame/machine/xavix.cpp
index b6b97e40866..317e5a3ee9e 100644
--- a/src/mame/machine/xavix.cpp
+++ b/src/mame/machine/xavix.cpp
@@ -379,15 +379,6 @@ void xavix_state::dispctrl_posirq_y_w(uint8_t data)
/* Per Game IO port callbacks */
-READ_LINE_MEMBER(xavix_i2c_lotr_state::camera_r) // seems to be some kind of camera status bits
-{
- return machine().rand();
-}
-
-READ_LINE_MEMBER(xavix_i2c_bowl_state::camera_r) // seems to be some kind of camera status bits
-{
- return machine().rand();
-}
READ_LINE_MEMBER(xavix_ekara_state::ekara_multi0_r)
{
@@ -512,48 +503,6 @@ void xavix_ekara_state::write_io1(uint8_t data, uint8_t direction)
m_extraiowrite = extraiowrite;
}
-/* SuperXavix IO port handliner (per game) */
-
-uint8_t xavix_i2c_jmat_state::read_extended_io0()
-{
- LOG("%s: read_extended_io0\n", machine().describe_context());
- return 0x00;
-}
-
-uint8_t xavix_i2c_jmat_state::read_extended_io1()
-{
- LOG("%s: read_extended_io1\n", machine().describe_context());
-
- // reads this by reading the byte, then shifting right 4 times to place value into carry flag
- return m_i2cmem->read_sda() << 3;
- //return 0x00;
-}
-
-uint8_t xavix_i2c_jmat_state::read_extended_io2()
-{
- LOG("%s: read_extended_io2\n", machine().describe_context());
- return 0x00;
-}
-
-void xavix_i2c_jmat_state::write_extended_io0(uint8_t data)
-{
- LOG("%s: io0_data_w %02x\n", machine().describe_context(), data);
-}
-
-void xavix_i2c_jmat_state::write_extended_io1(uint8_t data)
-{
- LOG("%s: io1_data_w %02x\n", machine().describe_context(), data);
-
- m_i2cmem->write_sda((data & 0x08) >> 3);
- m_i2cmem->write_scl((data & 0x10) >> 4);
-
-}
-
-void xavix_i2c_jmat_state::write_extended_io2(uint8_t data)
-{
- LOG("%s: io2_data_w %02x\n", machine().describe_context(), data);
-}
-
// the cart pins Popira 2 uses for IO with cart gc0010 are not controllable by the CPU on other ekara systems
READ_LINE_MEMBER(xavix_popira2_cart_state::i2c_r)
diff --git a/src/mame/machine/z80ne.cpp b/src/mame/machine/z80ne.cpp
index fb2087d02e3..af61fde4a04 100644
--- a/src/mame/machine/z80ne.cpp
+++ b/src/mame/machine/z80ne.cpp
@@ -65,38 +65,38 @@ TIMER_CALLBACK_MEMBER(z80ne_state::z80ne_cassette_tc)
}
}
-
-void z80ne_state::driver_init()
+void z80ne_state::save_state_vars()
{
- /* first two entries point to rom on reset */
- uint8_t *RAM = m_region_z80ne->base();
- m_bank1->configure_entry(0, &RAM[0x00000]); /* RAM at 0x0000 */
- m_bank1->configure_entry(1, &RAM[0x14000]); /* ep382 at 0x0000 */
- m_bank2->configure_entry(0, &RAM[0x14000]); /* ep382 at 0x8000 */
+ save_item(NAME(m_lx383_scan_counter));
+ save_item(NAME(m_lx383_key));
+ save_item(NAME(m_lx383_downsampler));
+ save_item(NAME(m_lx385_ctrl));
}
-void z80net_state::driver_init()
+void z80ne_state::init_z80ne()
{
- z80ne_state::driver_init();
+ save_state_vars();
}
void z80netf_state::driver_init()
{
+ save_state_vars();
+
/* first two entries point to rom on reset */
- uint8_t *RAM = m_region_z80ne->base();
- m_bank1->configure_entry(0, &RAM[0x00000]); /* RAM at 0x0000-0x03FF */
- m_bank1->configure_entries(1, 3, &RAM[0x14400], 0x0400); /* ep390, ep1390, ep2390 at 0x0000-0x03FF */
- m_bank1->configure_entry(4, &RAM[0x14000]); /* ep382 at 0x0000-0x03FF */
- m_bank1->configure_entry(5, &RAM[0x10000]); /* ep548 at 0x0000-0x03FF */
+ u8 *r = m_ram->pointer();
+ m_bank1->configure_entry(0, r); /* RAM at 0x0000-0x03FF */
+ m_bank1->configure_entries(1, 3, m_rom+0x4400, 0x0400); /* ep390, ep1390, ep2390 at 0x0000-0x03FF */
+ m_bank1->configure_entry(4, m_rom+0x4000); /* ep382 at 0x0000-0x03FF */
+ m_bank1->configure_entry(5, m_rom); /* ep548 at 0x0000-0x03FF */
- m_bank2->configure_entry(0, &RAM[0x00400]); /* RAM at 0x0400 */
- m_bank2->configure_entry(1, &RAM[0x10400]); /* ep548 at 0x0400-0x3FFF */
+ m_bank2->configure_entry(0, r+0x0400); /* RAM at 0x0400 */
+ m_bank2->configure_entry(1, m_rom+0x0400); /* ep548 at 0x0400-0x3FFF */
- m_bank3->configure_entry(0, &RAM[0x08000]); /* RAM at 0x8000 */
- m_bank3->configure_entry(1, &RAM[0x14000]); /* ep382 at 0x8000 */
+ m_bank3->configure_entry(0, r+0x4000); /* RAM at 0x8000 */
+ m_bank3->configure_entry(1, m_rom+0x4000); /* ep382 at 0x8000 */
- m_bank4->configure_entry(0, &RAM[0x0F000]); /* RAM at 0xF000 */
- m_bank4->configure_entries(1, 3, &RAM[0x14400], 0x0400); /* ep390, ep1390, ep2390 at 0xF000 */
+ m_bank4->configure_entry(0, r+0x5000); /* RAM at 0xF000 */
+ m_bank4->configure_entries(1, 3, m_rom+0x4400, 0x0400); /* ep390, ep1390, ep2390 at 0xF000 */
}
@@ -151,10 +151,8 @@ void z80ne_state::device_timer(emu_timer &timer, device_timer_id id, int param,
case 0:
m_maincpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero);
break;
- case 1:
- // switch to RAM bank at address 0x0000
- m_bank1->set_entry(0);
- break;
+ default:
+ printf("Invalid timer %d encountered\n",id);
}
}
@@ -164,16 +162,6 @@ void z80net_state::reset_lx387()
m_lx387_kr2376->set_input_pin( kr2376_device::KR2376_PII, 0);
}
-void z80ne_state::reset_lx382_banking()
-{
- /* switch to ROM bank at address 0x0000 */
- m_bank1->set_entry(1);
- m_bank2->set_entry(0); /* ep382 at 0x8000 */
-
- /* after the first 3 bytes have been read from ROM, switch the RAM back in */
- m_timer_reset->adjust(m_maincpu->cycles_to_attotime(2));
-}
-
void z80netf_state::reset_lx390_banking()
{
switch (m_io_config->read() & 0x07)
@@ -185,8 +173,6 @@ void z80netf_state::reset_lx390_banking()
m_bank2->set_entry(0); /* RAM at 0x0400 */
m_bank3->set_entry(1); /* ep382 at 0x8000 */
m_bank4->set_entry(0); /* RAM at 0xF000 */
- // after the first 3 bytes have been read from ROM, switch the RAM back in
- m_timer_reset->adjust(m_maincpu->cycles_to_attotime(2));
break;
case 0x02: /* EP548 16k BASIC */
if (VERBOSE)
@@ -271,19 +257,34 @@ void z80ne_state::base_reset()
m_uart_clock->set_unscaled_clock(m_cass_data.speed * 16);
lx385_ctrl_w(0);
-
}
void z80ne_state::machine_reset()
{
- reset_lx382_banking();
base_reset();
+
+ address_space &program = m_maincpu->space(AS_PROGRAM);
+ program.install_rom(0x0000, 0x03ff, m_rom); // do it here for F3
+ m_rom_shadow_tap = program.install_read_tap(0x8000, 0x83ff, "rom_shadow_r",[this](offs_t offset, u8 &data, u8 mem_mask)
+ {
+ if (!machine().side_effects_disabled())
+ {
+ // delete this tap
+ m_rom_shadow_tap->remove();
+
+ // reinstall ram over the rom shadow
+ m_maincpu->space(AS_PROGRAM).install_ram(0x0000, 0x03ff, m_mram);
+ }
+
+ // return the original data
+ return data;
+ });
}
void z80net_state::machine_reset()
{
- z80ne_state::machine_reset();
reset_lx387();
+ z80ne_state::machine_reset();
}
void z80netb_state::machine_reset()
@@ -297,41 +298,51 @@ void z80netf_state::machine_reset()
reset_lx390_banking();
base_reset();
reset_lx387();
+
+ // basic roms are exempt from memory tap
+ if ((m_io_config->read() & 0x07) != 2)
+ {
+ address_space &program = m_maincpu->space(AS_PROGRAM);
+ m_rom_shadow_tap = program.install_read_tap(0x8000, 0xf3ff, "rom_shadow_r",[this](offs_t offset, u8 &data, u8 mem_mask)
+ {
+ if (!machine().side_effects_disabled())
+ {
+ // delete this tap
+ m_rom_shadow_tap->remove();
+
+ // reinstall ram over the rom shadow
+ m_bank1->set_entry(0);
+ }
+
+ // return the original data
+ return data;
+ });
+ }
}
INPUT_CHANGED_MEMBER(z80ne_state::z80ne_reset)
{
- uint8_t rst;
- rst = m_io_rst->read();
+ uint8_t rst = m_io_rst->read();
if ( ! BIT(rst, 0))
- {
machine().schedule_soft_reset();
- }
}
INPUT_CHANGED_MEMBER(z80net_state::z80net_nmi)
{
- uint8_t nmi;
- nmi = m_io_lx387_brk->read();
+ uint8_t nmi = m_io_lx387_brk->read();
if ( ! BIT(nmi, 0))
- {
m_maincpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero);
- }
}
void z80ne_state::machine_start()
{
m_timer_nmi = timer_alloc(0);
- m_timer_reset = timer_alloc(1);
m_lx383_digits.resolve();
m_lx385_ctrl = 0x1f;
- save_item(NAME(m_lx383_scan_counter));
- save_item(NAME(m_lx383_downsampler));
- save_item(NAME(m_lx383_key));
m_cassette_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(z80ne_state::z80ne_cassette_tc), this));
m_kbd_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(z80ne_state::z80ne_kbd_scan), this));
m_kbd_timer->adjust(attotime::from_hz(1000), 0, attotime::from_hz(1000));
@@ -402,7 +413,7 @@ void z80ne_state::lx383_w(offs_t offset, uint8_t data)
else
{
// after writing to port 0xF8 and the first ~M1 cycles strike a NMI for single step execution
- m_timer_reset->adjust(m_maincpu->cycles_to_attotime(1));
+ m_timer_nmi->adjust(m_maincpu->cycles_to_attotime(1));
}
}
@@ -590,7 +601,7 @@ void z80netf_state::lx390_motor_w(uint8_t data)
floppy_image_device *floppy = nullptr;
- for (int f = 0; f < 4; f++)
+ for (u8 f = 0; f < 4; f++)
if (BIT(data, f))
floppy = m_floppy[f]->get_device();
@@ -613,24 +624,6 @@ void z80netf_state::lx390_motor_w(uint8_t data)
}
}
-uint8_t z80netf_state::lx390_reset_bank()
-{
- offs_t pc;
-
- /* if PC is not in range, we are under integrated debugger control, DON'T SWAP */
- pc = m_maincpu->pc();
- if((pc >= 0xf000) && (pc <=0xffff))
- {
- LOG("lx390_reset_bank, reset memory bank 1\n");
- m_bank1->set_entry(0); /* RAM at 0x0000 (bank 1) */
- }
- else
- {
- LOG("lx390_reset_bank, bypass because in debugger\n");
- }
- return 0xff;
-}
-
uint8_t z80netf_state::lx390_fdc_r(offs_t offset)
{
uint8_t d;
@@ -655,7 +648,7 @@ uint8_t z80netf_state::lx390_fdc_r(offs_t offset)
break;
case 6:
d = 0xff;
- lx390_reset_bank();
+ m_bank1->set_entry(0);
break;
case 7:
d = m_wd1771->data_r() ^ 0xff;
diff --git a/src/mame/mame.lst b/src/mame/mame.lst
index 43661f51d33..29acd0e36e5 100644
--- a/src/mame/mame.lst
+++ b/src/mame/mame.lst
@@ -101,7 +101,8 @@ undoukai // A17 (c) 1984 Taito
4d35 // IP12: Personal Iris 4D/35, R3000A @36MHz
@source:4enlinea.cpp
-4enlinea // (c) 1991 System Compumatic
+4enlinea // (c) 1991 Compumatic / CIC Play
+4enlineb // (c) 1991 Compumatic / CIC Play
k7_olym // (c) 1994 K7 Kursaal
sprtdart // (c) 1993 Compumatic / Desarrollos y Recambios S.L.
@@ -2771,6 +2772,7 @@ ncr3433 // NCR Class 3433
aavenger //
atarians //
midearth //
+mideartha //
spcrider //
time2000 //
@@ -3361,6 +3363,7 @@ beta //
@source:bfcobra.cpp
beeline // 1991 BFM
+brkball // 1994 BFM / ATOD
escounts // 1990 BFM
inquiztr // 1989 BFM
qos // 1992 BFM
@@ -10345,6 +10348,10 @@ wildplt // (c) 1992 Jaleco
@source:cit101.cpp
cit101 // (c) 1980 C. Itoh
+cit101e // (c) 1983 C. Itoh
+
+@source:cit101xl.cpp
+cit101xl //
@source:cit220.cpp
cit220p // (c) 1984 C. Itoh
@@ -13849,6 +13856,8 @@ elephfmb // (c) 1996 C.M.C.
funquiz // (c) 198? Fun World
funquiza // (c) 1990 Fun World
funquizb // (c) 1990 Fun World
+gratispk // (c) 1995 Mega Soft
+gratispka // (c) 1995 Mega Soft
jokercrd // (c) 1993 Vesely Svet
jollycrd // (c) 1985 TAB-Austria
jollycrda // (c) 1985 TAB-Austria
@@ -13865,13 +13874,16 @@ jolycdie // 1990 bootleg
jolycdif // 1990 bootleg
jolycdig // 1993 bootleg
jolycdih // 1990 bootleg
+jolycdii // 1993 bootleg
jolycdit // 199? bootleg
jolycdsp // (c) 1992 TAB-Austria
jolycmzs // (c) 1993 MZS Tech
jolyjokr // (c) 198? Impera
jolyjokra // (c) 198? Impera
-jolyjokrb // (c) 198? Impera
+jolyjokrb1 // (c) 1985 Impera
+jolyjokrb2 // (c) 1985 Impera
jolyjokrc // (c) 198? Apple Time
+jolyjokrm // (c) 198? Impera
jolyjokro // (c) 198? Impera
jolyjokrp // (c) 198? Impera
lluck3x3 // (c) 1991 TAB-Austria
@@ -13887,6 +13899,7 @@ megacard // (c) 1993 Fun World
mongolnw // 199? bootleg
multiwin // (c) 1992 Fun World
nevadafw // 199? unknown
+nkoulit // 1995 JK Amusement
novoplay // (c) 1986 Novomatic
pool10 // (c) 1996 C.M.C.
pool10b // (c) 1996 C.M.C.
@@ -13902,6 +13915,7 @@ biliard // 1998 bootleg.
potgame // (c) 1996 C.M.C.
powercrd // (c) 1993 Fun World
rcdino4 // 1998 unknown
+reflexcrd // (c) 1999 TAB-Austria
royal // 2001, hack.
royalcdfr // (c) 1991 TAB-Austria
royalcrd // (c) 1991 TAB-Austria
@@ -14791,6 +14805,7 @@ smartfps
gormiti
tkmag220 //
myac220
+imgame
@source:generalplus_gpl16250_romram.cpp
paccon
@@ -15175,6 +15190,9 @@ cmastere // (c) 1991 Dyna Electronics
cmasterf // (c) 1991 Dyna Electronics
cmasterg // (c) 1991 Dyna Electronics
cmasterh // (c) 1991 Dyna Electronics
+cmasteri // (c) 1991 Dyna Electronics
+cmasterj // (c) 1991 Dyna Electronics
+cmasterk // (c) 1991 Dyna Electronics
cmezspin // (c) 1991 Dyna Electronics
cmfun // (c) 1995 Dyna Electronics
cmpacman //
@@ -15846,6 +15864,8 @@ hec2hrx //
hec2mdhrx //
hec2mx40 //
hec2mx80 //
+hector1 //
+interact //
victor //
@source:hektor.cpp
@@ -16689,10 +16709,6 @@ intlc440 //
@source:intellect02.cpp
intel02 //
-@source:interact.cpp
-hector1 //
-interact //
-
@source:interpro.cpp
ip2000 // Intergraph InterPro/InterServe 20x0
ip2400 // Intergraph InterPro/InterServe 24x0
@@ -19526,6 +19542,7 @@ lucky21 // (c) 199? Wing Co. Ltd
lucky21d // (c) 199? Wing Co. Ltd
lucky25 // (c) 199? Wing Co. Ltd
lucky37 // (c) 199? Wing Co. Ltd
+bingo75 // (c) 199? Wing Co. Ltd
@source:lucky74.cpp
excitbj // (c) 1992 Wing Co. Ltd
@@ -22122,6 +22139,7 @@ megajet // 1993 Sega Mega Jet (Japan)
@source:megadriv_acbl.cpp
aladmdb // MegaDrive-based hack
+barek2mb // MegaDrive-based hack
barek3mb // MegaDrive-based hack
jparkmb // MegaDrive-based hack
mk3mdb // MegaDrive-based hack
@@ -32053,7 +32071,9 @@ bandggcn
cpatrolm
ts_handy11
ablwikid
+maxx5in1
maxx6in1
+max10in1
@source:nes_vt.cpp
vdogdeme
@@ -32072,6 +32092,8 @@ lxcmcysw
lxcmcyfz
lxcmcydp
lxcmcysp
+lxcmcypp
+lxcmcycr
lxccminn
lxccplan
rtvgc300
@@ -32140,8 +32162,10 @@ otrail
denv150
techni4
duetpp
+sporzbx
ablmini
senwld
+zonefusn
@source:vt1682.cpp
ii8in1
@@ -32159,6 +32183,8 @@ xing48
wowwg
110dance
lxts3
+unk1682
+njp60in1
@source:newbrain.cpp
newbrain //
@@ -32542,7 +32568,8 @@ g7400 // 1983 Videopac Plus G7400
jopac // 1983 Jopac JO7400
odyssey2 // Magnavox Odyssey 2 - 1978-1983
odyssey3 // Magnavox Odyssey 3 / Command Center (prototype)
-videopac // 1979 Videopac G7000/C52
+videopac // 1979 Videopac G7000
+videopacf // 1979 Videopac C52
@source:offtwall.cpp
offtwall // 136090 (c) 1991
@@ -34897,6 +34924,7 @@ slithera // (c) 1982 Century II
zookeep // ZA (c) 1982 Taito America Corporation
zookeep2 // ZA (c) 1982 Taito America Corporation
zookeep3 // ZA (c) 1982 Taito America Corporation
+zookeepbl // bootleg
@source:ql.cpp
ql // 1984 Sinclair QL (UK)
@@ -37617,6 +37645,7 @@ snespal // Nintendo Super Nintendo PAL
@source:snesb51.cpp
mk3snes
snes4sl
+snes4sln
@source:snesb.cpp
denseib // bootleg
@@ -37982,6 +38011,9 @@ pballpup
swclone
dreamlss
senspeed
+ordentv
+wfcentro
+tiktokmm
@source:spg2xx_digimake.cpp
rad_digi
@@ -38111,6 +38143,7 @@ react
@source:spg2xx_zone_32bit.cpp
mywicodx //
+mywicogt
zon32bit // Zone 32-bit
oplayer
dnv200fs
@@ -41779,8 +41812,8 @@ robotron87 //
robotron12 //
robotrontd //
sinistar // (c) 1982
-sinistar1 // (c) 1982
sinistar2 // (c) 1982
+sinistarp // (c) 1982 prototype (shown at AMOA 1982 show)
spdball // (c) 1985
splat // (c) 1982
stargate // (c) 1981
@@ -42231,15 +42264,11 @@ rad_snowp //
rad_madf //
rad_fb //
rad_socr //
-epo_bowl //
epo_esdx //
epo_epp //
epo_eppk //
epo_epp3 //
epo_efdx //
-epo_tfit
-epo_ebox //
-epo_sdb //
epo_guru //
epo_dmon //
rad_rh //
@@ -42254,8 +42283,6 @@ jarajal //
tcarnavi //
tomcpin
tomplc
-mrangbat
-ban_onep //
ekara //
ekaraa //
ekaraj //
@@ -42271,10 +42298,22 @@ taikodp //
jpopira //
evio //
gcslottv //
+
+@source:xavix_2000.cpp
+epo_ebox //
+epo_bowl //
+epo_sdb //
ttv_sw //
ttv_lotr //
ttv_mx //
drgqst //
+ban_onep //
+
+@source:xavix_2002.cpp
+suprpctv
+udance
+mrangbat
+epo_tfit
tmy_thom //
xavtenni //
xavbaseb //
diff --git a/src/mame/mess.flt b/src/mame/mess.flt
index ea4e340e0c5..02b0021e210 100644
--- a/src/mame/mess.flt
+++ b/src/mame/mess.flt
@@ -162,6 +162,7 @@ chaos.cpp
chessmate.cpp
chessmst.cpp
cit101.cpp
+cit101xl.cpp
cit1500.cpp
cit220.cpp
cking_master.cpp
@@ -423,7 +424,6 @@ instruct.cpp
inteladv.cpp
intellec4.cpp
intellect02.cpp
-interact.cpp
interpro.cpp
intv.cpp
ipc.cpp
@@ -1101,6 +1101,8 @@ x1.cpp
x1twin.cpp
x68k.cpp
xavix.cpp
+xavix_2000.cpp
+xavix_2002.cpp
xavix2.cpp
xbase09.cpp
xbox.cpp
diff --git a/src/mame/video/apple2.cpp b/src/mame/video/apple2.cpp
index b3eeec75eb6..37e3819052c 100644
--- a/src/mame/video/apple2.cpp
+++ b/src/mame/video/apple2.cpp
@@ -118,6 +118,7 @@ void a2_video_device::device_start()
save_item(NAME(m_GSborder));
save_item(NAME(m_newvideo));
save_item(NAME(m_monochrome));
+ save_item(NAME(m_rgbmode));
save_item(NAME(m_shr_palette));
}
@@ -136,6 +137,7 @@ void a2_video_device::device_reset()
m_80store = false;
m_monohgr = false;
m_newvideo = 0x01;
+ m_rgbmode = 3; // default to color DHGR
}
WRITE_LINE_MEMBER(a2_video_device::txt_w)
@@ -174,6 +176,14 @@ WRITE_LINE_MEMBER(a2_video_device::dhires_w)
{
// select double hi-res
screen().update_now();
+
+ // RGB cards shift in a mode bit on the rising edge
+ if ((m_dhires) && (state))
+ {
+ m_rgbmode = (m_rgbmode << 1) & 3;
+ m_rgbmode |= m_80col ? 1 : 0;
+ }
+
m_dhires = !state;
}
@@ -453,7 +463,7 @@ void a2_video_device::lores_update(screen_device &screen, bitmap_ind16 &bitmap,
switch (m_sysconfig & 0x03)
{
- case 0: fg = WHITE; break;
+ case 0: case 4: fg = WHITE; break;
case 1: fg = WHITE; break;
case 2: fg = GREEN; break;
case 3: fg = ORANGE; break;
@@ -570,7 +580,7 @@ void a2_video_device::dlores_update(screen_device &screen, bitmap_ind16 &bitmap,
switch (m_sysconfig & 0x03)
{
- case 0: fg = WHITE; break;
+ case 0: case 4: fg = WHITE; break;
case 1: fg = WHITE; break;
case 2: fg = GREEN; break;
case 3: fg = ORANGE; break;
@@ -750,13 +760,14 @@ void a2_video_device::text_update(screen_device &screen, bitmap_ind16 &bitmap, c
int fg = 0;
int bg = 0;
+ if (m_aux_ptr)
+ {
+ aux_page = m_aux_ptr;
+ }
+
if (m_80col)
{
start_address = 0x400;
- if (m_aux_ptr)
- {
- aux_page = m_aux_ptr;
- }
}
else
{
@@ -768,7 +779,7 @@ void a2_video_device::text_update(screen_device &screen, bitmap_ind16 &bitmap, c
switch (m_sysconfig & 0x03)
{
- case 0: fg = WHITE; break;
+ case 0: case 4: fg = WHITE; break;
case 1: fg = WHITE; break;
case 2: fg = GREEN; break;
case 3: fg = ORANGE; break;
@@ -795,6 +806,13 @@ void a2_video_device::text_update(screen_device &screen, bitmap_ind16 &bitmap, c
{
/* calculate address */
address = start_address + ((((row/8) & 0x07) << 7) | (((row/8) & 0x18) * 5 + col));
+ if (((m_sysconfig & 7) == 4) && (m_dhires))
+ {
+ u8 tmp = aux_page[address];
+ fg = tmp>>4;
+ bg = tmp & 0xf;
+ }
+
plot_text_character(bitmap, col * 14, row, 2, m_ram_ptr[address],
m_char_ptr, m_char_size, fg, bg);
}
@@ -815,7 +833,7 @@ void a2_video_device::text_update_orig(screen_device &screen, bitmap_ind16 &bitm
switch (m_sysconfig & 0x03)
{
- case 0: fg = WHITE; break;
+ case 0: case 4: fg = WHITE; break;
case 1: fg = WHITE; break;
case 2: fg = GREEN; break;
case 3: fg = ORANGE; break;
@@ -1027,6 +1045,12 @@ void a2_video_device::hgr_update(screen_device &screen, bitmap_ind16 &bitmap, co
mon_type = 1;
}
+ // IIgs $C021 monochrome HGR
+ if (m_monochrome & 0x80)
+ {
+ mon_type = 1;
+ }
+
switch (mon_type)
{
case 0:
@@ -1225,6 +1249,8 @@ void a2_video_device::dhgr_update(screen_device &screen, bitmap_ind16 &bitmap, c
uint32_t w;
int page = m_page2 ? 0x4000 : 0x2000;
int mon_type = m_sysconfig & 0x03;
+ bool bIsRGB = ((m_sysconfig & 7) == 4);
+ bool bIsRGBMixed = ((bIsRGB) && (m_rgbmode == 1));
// IIgs force-monochrome-DHR setting
if (m_newvideo & 0x20)
@@ -1232,6 +1258,12 @@ void a2_video_device::dhgr_update(screen_device &screen, bitmap_ind16 &bitmap, c
mon_type = 1;
}
+ // IIe RGB card monochrome DHR
+ if ((bIsRGB) && (m_rgbmode == 0))
+ {
+ mon_type = 1;
+ }
+
/* sanity checks */
if (beginrow < cliprect.top())
beginrow = cliprect.top();
@@ -1265,19 +1297,96 @@ void a2_video_device::dhgr_update(screen_device &screen, bitmap_ind16 &bitmap, c
p = &bitmap.pix16(row);
+ // RGB DHR 160-wide mode
+ if ((bIsRGB) && (m_rgbmode == 2))
+ {
+ mon_type = 4;
+ }
+
for (col = 0; col < 80; col++)
{
w = (((uint32_t) vram_row[col+0] & 0x7f) << 0)
| (((uint32_t) vram_row[col+1] & 0x7f) << 7)
| (((uint32_t) vram_row[col+2] & 0x7f) << 14);
+ /*
+ DHGR pixel layout:
+ column & 3 = 0 1 2 3
+ nBBBAAAA nDDCCCCB nFEEEEDD nGGGGFFF
+
+ n is don't care on the stock hardware's NTSC output.
+
+ On RGB cards, in mixed mode (DHGR with special mode value == 1), n
+ controls if a pixel quad starting in that byte is color or monochrome.
+ Pixel quads A&B are controlled by n in byte 0, C&D by n in byte 1,
+ E&F by n in byte 2, and G by n in byte 3.
+ */
+
switch (mon_type)
{
case 0:
- for (b = 0; b < 7; b++)
+ // every 3rd column, the first pixel quad is controlled by the previous
+ // byte's MSB, because we always draw 2 quads per column.
+ if ((bIsRGBMixed) && ((col & 3) == 3))
{
- v = m_dhires_artifact_map[((((w >> (b + 7-1)) & 0x0F) * 0x11) >> (((2-(col*7+b))) & 0x03)) & 0x0F];
- *(p++) = v;
+ uint32_t tw = (w >> 6);
+
+ if (!(vram_row[col-1] & 0x80))
+ {
+ for (b = 0; b < 4; b++)
+ {
+ v = (tw & 1);
+ tw >>= 1;
+ *(p++) = v ? WHITE : BLACK;
+ }
+ }
+ else
+ {
+ for (b = 0; b < 4; b++)
+ {
+ v = m_dhires_artifact_map[((((w >> (b + 7-1)) & 0x0F) * 0x11) >> (((2-(col*7+b))) & 0x03)) & 0x0F];
+ *(p++) = v;
+ }
+ }
+
+ if (!(vram_row[col] & 0x80))
+ {
+ for (b = 4; b < 7; b++)
+ {
+ v = (tw & 1);
+ tw >>= 1;
+ *(p++) = v ? WHITE : BLACK;
+ }
+ }
+ else
+ {
+ for (b = 4; b < 7; b++)
+ {
+ v = m_dhires_artifact_map[((((w >> (b + 7-1)) & 0x0F) * 0x11) >> (((2-(col*7+b))) & 0x03)) & 0x0F];
+ *(p++) = v;
+ }
+ }
+ }
+ else
+ {
+ if ((bIsRGBMixed) && !(vram_row[col] & 0x80))
+ {
+ uint32_t tw = (w >> 6);
+ for (b = 0; b < 7; b++)
+ {
+ v = (tw & 1);
+ tw >>= 1;
+ *(p++) = v ? WHITE : BLACK;
+ }
+ }
+ else
+ {
+ for (b = 0; b < 7; b++)
+ {
+ v = m_dhires_artifact_map[((((w >> (b + 7-1)) & 0x0F) * 0x11) >> (((2-(col*7+b))) & 0x03)) & 0x0F];
+ *(p++) = v;
+ }
+ }
}
break;
@@ -1310,6 +1419,35 @@ void a2_video_device::dhgr_update(screen_device &screen, bitmap_ind16 &bitmap, c
*(p++) = v ? ORANGE : BLACK;
}
break;
+
+ // RGB 160-wide mode (which has a much simpler VRAM layout)
+ case 4:
+ if (col == 0)
+ {
+ // Center the 480-wide image in the 560-wide display.
+ // Aspect ratio won't be perfect, but it's in range.
+ for (b = 0; b < 40; b++)
+ {
+ *(p++) = BLACK;
+ }
+ }
+ v = vram_row[col];
+ *(p++) = v & 0xf;
+ *(p++) = v & 0xf;
+ *(p++) = v & 0xf;
+ v >>= 4;
+ *(p++) = v & 0xf;
+ *(p++) = v & 0xf;
+ *(p++) = v & 0xf;
+ break;
+ }
+ }
+
+ if (mon_type == 4)
+ {
+ for (b = 0; b < 40; b++)
+ {
+ *(p++) = BLACK;
}
}
}
diff --git a/src/mame/video/apple2.h b/src/mame/video/apple2.h
index c5256f37728..a87c2aab6ce 100644
--- a/src/mame/video/apple2.h
+++ b/src/mame/video/apple2.h
@@ -32,8 +32,8 @@ public:
bool m_an2;
bool m_80store;
bool m_monohgr;
- uint8_t m_GSfg, m_GSbg, m_GSborder, m_newvideo, m_monochrome;
- uint32_t m_GSborder_colors[16], m_shr_palette[256];
+ u8 m_GSfg, m_GSbg, m_GSborder, m_newvideo, m_monochrome, m_rgbmode;
+ u32 m_GSborder_colors[16], m_shr_palette[256];
std::unique_ptr<bitmap_ind16> m_8bit_graphics;
std::unique_ptr<uint16_t[]> m_hires_artifact_map;
std::unique_ptr<uint16_t[]> m_dhires_artifact_map;
diff --git a/src/mame/video/dai.cpp b/src/mame/video/dai.cpp
index 77f507957eb..13891a8cda9 100644
--- a/src/mame/video/dai.cpp
+++ b/src/mame/video/dai.cpp
@@ -9,7 +9,7 @@
Krzysztof Strzecha
All video modes are emulated but not fully tested yet.
- dai_state::screen_update_dai() function needs strong cleanup and optimalisation.
+ dai_state::screen_update() function needs strong cleanup and optimisation.
***************************************************************************/
@@ -47,12 +47,12 @@ void dai_state::dai_palette(palette_device &palette) const
palette.set_pen_colors(0, s_palette);
}
-uint32_t dai_state::screen_update_dai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
+uint32_t dai_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
address_space &space = m_maincpu->space(AS_PROGRAM);
int i, j, k, l;
- uint8_t* char_rom = memregion("gfx1")->base();
+ uint8_t* char_rom = memregion("chargen")->base();
uint16_t dai_video_memory_start = 0xbfff;
uint16_t dai_scan_lines = 604; /* scan lines of PAL tv */
diff --git a/src/mame/video/hec2hrp.cpp b/src/mame/video/hec2hrp.cpp
index 6193c1db07e..9212b796b80 100644
--- a/src/mame/video/hec2hrp.cpp
+++ b/src/mame/video/hec2hrp.cpp
@@ -3,35 +3,7 @@
/////////////////////////////////////////////////////////////////////////////////
///// Hector video
/////////////////////////////////////////////////////////////////////////////////
-/* Hector 2HR+
- Victor
- Hector 2HR
- Hector HRX
- Hector MX40c
- Hector MX80c
- Hector 1
- Interact
- 12/05/2009 Skeleton driver - Micko : mmicko@gmail.com
- 31/06/2009 Video - Robbbert
-
- 29/10/2009 Update skeleton to functional machine
- by yo_fr (jj.stac @ aliceadsl.fr)
-
- => add Keyboard,
- => add color,
- => add cassette,
- => add sn76477 sound and 1bit sound,
- => add joysticks (stick, pot, fire)
- => add BR/HR switching
- => add bank switch for HRX
- => add device MX80c and bank switching for the ROM
- Important note : the keyboard function has been taken from the
- DChector project : http://dchector.free.fr/ made by DanielCoulom
- (thanks Daniel)
- TODO : Add the cartridge function,
- Adjust the one shot and A/D timing (sn76477)
-*/
#include "emu.h"
#include "includes/hec2hrp.h"
@@ -39,7 +11,7 @@
#include "screen.h"
-void hec2hrp_state::init_palette()
+void hec2hrp_state::init_palette(palette_device &palette)
{
m_hector_color[0] = 0; // black
m_hector_color[1] = 1; // red
@@ -69,7 +41,6 @@ void hec2hrp_state::init_palette()
void hec2hrp_state::hector_hr(bitmap_ind16 &bitmap, uint8_t *page, int ymax, int yram)
{
- uint8_t *hector_color = m_hector_color;
int sy = 0;
int ma = 0;
for (int y = 0; y <= ymax; y++)
@@ -78,15 +49,22 @@ void hec2hrp_state::hector_hr(bitmap_ind16 &bitmap, uint8_t *page, int ymax, int
for (int x = ma; x < ma + yram; x++)
{
uint8_t gfx = *(page + x);
- *pix++ = hector_color[(gfx >> 0) & 0x03];
- *pix++ = hector_color[(gfx >> 2) & 0x03];
- *pix++ = hector_color[(gfx >> 4) & 0x03];
- *pix++ = hector_color[(gfx >> 6) & 0x03];
+ *pix++ = m_hector_color[BIT(gfx, 0, 2)];
+ *pix++ = m_hector_color[BIT(gfx, 2, 2)];
+ *pix++ = m_hector_color[BIT(gfx, 4, 2)];
+ *pix++ = m_hector_color[BIT(gfx, 6, 2)];
}
ma+=yram;
}
}
+uint32_t hec2hrp_state::screen_update_interact(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
+{
+ screen.set_visible_area(0, 113, 0, 75);
+ hector_hr(bitmap, m_vram, 77, 32);
+ return 0;
+}
+
void hec2hrp_state::hector_80c(bitmap_ind16 &bitmap, uint8_t *page, int ymax, int yram)
{
int sy = 0;
@@ -97,46 +75,33 @@ void hec2hrp_state::hector_80c(bitmap_ind16 &bitmap, uint8_t *page, int ymax, in
for (int x = ma; x < ma + yram; x++)
{
uint8_t gfx = *(page + x);
- *pix++ = (gfx & 0x01) ? 7 : 0;
- *pix++ = (gfx & 0x02) ? 7 : 0;
- *pix++ = (gfx & 0x04) ? 7 : 0;
- *pix++ = (gfx & 0x08) ? 7 : 0;
- *pix++ = (gfx & 0x10) ? 7 : 0;
- *pix++ = (gfx & 0x20) ? 7 : 0;
- *pix++ = (gfx & 0x40) ? 7 : 0;
- *pix++ = (gfx & 0x80) ? 7 : 0;
+ for (u8 i = 0; i < 8; i++)
+ *pix++ = BIT(gfx, i) ? 7 : 0;
}
ma += yram;
}
}
-
-VIDEO_START_MEMBER(hec2hrp_state,hec2hrp)
-{
- init_palette();
-}
-
uint32_t hec2hrp_state::screen_update_hec2hrp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
- uint8_t *videoram = m_videoram;
- uint8_t *videoram_HR = m_hector_videoram;
- if (m_hector_flag_hr==1)
+ if (m_hector_flag_hr)
{
- if (m_hector_flag_80c==0)
+ if (!m_hector_flag_80c)
{
screen.set_visible_area(0, 243, 0, 227);
- hector_hr(bitmap , &videoram_HR[0], 227, 64);
+ hector_hr(bitmap , m_hector_vram, 227, 64);
}
else
{
screen.set_visible_area(0, 243*2, 0, 227);
- hector_80c(bitmap , &videoram_HR[0], 227, 64);
+ hector_80c(bitmap , m_hector_vram, 227, 64);
}
}
else
{
screen.set_visible_area(0, 113, 0, 75);
- hector_hr(bitmap, videoram, 77, 32);
+ hector_hr(bitmap, m_vram, 77, 32);
}
return 0;
}
+
diff --git a/src/mame/video/lviv.cpp b/src/mame/video/lviv.cpp
index badba3e4637..e53ccfd9768 100644
--- a/src/mame/video/lviv.cpp
+++ b/src/mame/video/lviv.cpp
@@ -62,7 +62,7 @@ uint32_t lviv_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap,
{
for (int x = 0; x < 256; x += 4)
{
- const uint8_t data = m_video_ram[(y << 6) | (x >> 2)];
+ const uint8_t data = m_vram[(y << 6) | (x >> 2)];
int pen = m_colortable[0][((data & 0x08) >> 3) | ((data & 0x80) >> (3+3))];
bitmap.pix16(y, x + 0) = pen;
diff --git a/src/mame/video/renegade.cpp b/src/mame/video/renegade.cpp
index 9190047e156..72e1d708fd1 100644
--- a/src/mame/video/renegade.cpp
+++ b/src/mame/video/renegade.cpp
@@ -64,6 +64,8 @@ void renegade_state::video_start()
m_fg_tilemap->set_transparent_pen(0);
m_bg_tilemap->set_scrolldx(256, 0);
+ m_fg_tilemap->set_scrolldy(10, 10);
+ m_bg_tilemap->set_scrolldy(10, 10);
save_item(NAME(m_scrollx));
}
@@ -75,8 +77,8 @@ void renegade_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprec
while (source < finish)
{
- // 224 matches reference (stage 1 boss in kuniokun is aligned with the train door)
- int sy = 224 - source[0];
+ // reference: stage 1 boss in kuniokun is aligned with the train door
+ int sy = 234 - source[0];
//if (sy >= 0)
{
@@ -96,7 +98,7 @@ void renegade_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprec
if (flip_screen())
{
sx = 240 - sx;
- sy = 224 - sy;
+ sy = 260 - sy;
xflip = !xflip;
}
diff --git a/src/mame/video/starcrus.cpp b/src/mame/video/starcrus.cpp
index c4ef6b3a566..f3a9875741e 100644
--- a/src/mame/video/starcrus.cpp
+++ b/src/mame/video/starcrus.cpp
@@ -40,40 +40,13 @@ void starcrus_state::video_start()
save_item(NAME(m_p2_sprite));
save_item(NAME(m_s1_sprite));
save_item(NAME(m_s2_sprite));
- save_item(NAME(m_engine1_on));
- save_item(NAME(m_engine2_on));
- save_item(NAME(m_explode1_on));
- save_item(NAME(m_explode2_on));
- save_item(NAME(m_launch1_on));
- save_item(NAME(m_launch2_on));
save_item(NAME(m_collision_reg));
- save_item(NAME(m_engine_sound_playing));
- save_item(NAME(m_explode_sound_playing));
- save_item(NAME(m_launch1_sound_playing));
- save_item(NAME(m_launch2_sound_playing));
}
void starcrus_state::ship_parm_1_w(uint8_t data)
{
- m_s1_sprite = data&0x1f;
- m_engine1_on = ((data&0x20)>>5)^0x01;
-
- if (m_engine1_on || m_engine2_on)
- {
- if (m_engine_sound_playing == 0)
- {
- m_engine_sound_playing = 1;
- m_samples->start(0, 0, true); /* engine sample */
- }
- }
- else
- {
- if (m_engine_sound_playing == 1)
- {
- m_engine_sound_playing = 0;
- m_samples->stop(0);
- }
- }
+ m_s1_sprite = data & 0x1f;
+ m_engine[0]->write_line(BIT(data, 5));
}
void starcrus_state::ship_parm_2_w(uint8_t data)
@@ -81,99 +54,21 @@ void starcrus_state::ship_parm_2_w(uint8_t data)
m_s2_sprite = data & 0x1f;
m_led = !BIT(data, 7); /* game over lamp */
machine().bookkeeping().coin_counter_w(0, ((data & 0x40) >> 6) ^ 0x01); /* coin counter */
- m_engine2_on = ((data & 0x20) >> 5) ^ 0x01;
-
- if (m_engine1_on || m_engine2_on)
- {
- if (m_engine_sound_playing == 0)
- {
- m_engine_sound_playing = 1;
- m_samples->start(0, 0, true); /* engine sample */
- }
- }
- else
- {
- if (m_engine_sound_playing == 1)
- {
- m_engine_sound_playing = 0;
- m_samples->stop(0);
- }
- }
-
+ m_engine[1]->write_line(BIT(data, 5));
}
void starcrus_state::proj_parm_1_w(uint8_t data)
{
m_p1_sprite = data & 0x0f;
- m_launch1_on = ((data & 0x20) >> 5) ^ 0x01;
- m_explode1_on = ((data & 0x10) >> 4) ^ 0x01;
-
- if (m_explode1_on || m_explode2_on)
- {
- if (m_explode_sound_playing == 0)
- {
- m_explode_sound_playing = 1;
- m_samples->start(1, 1, true); /* explosion initial sample */
- }
- }
- else
- {
- if (m_explode_sound_playing == 1)
- {
- m_explode_sound_playing = 0;
- m_samples->start(1,2); /* explosion ending sample */
- }
- }
-
- if (m_launch1_on)
- {
- if (m_launch1_sound_playing == 0)
- {
- m_launch1_sound_playing = 1;
- m_samples->start(2,3); /* launch sample */
- }
- }
- else
- {
- m_launch1_sound_playing = 0;
- }
+ m_launch[0]->write_line(BIT(data, 5));
+ m_explode[0]->write_line(BIT(data, 4));
}
void starcrus_state::proj_parm_2_w(uint8_t data)
{
m_p2_sprite = data & 0x0f;
- m_launch2_on = ((data & 0x20) >> 5) ^ 0x01;
- m_explode2_on = ((data & 0x10) >> 4) ^ 0x01;
-
- if (m_explode1_on || m_explode2_on)
- {
- if (m_explode_sound_playing == 0)
- {
- m_explode_sound_playing = 1;
- m_samples->start(1, 1, true); /* explosion initial sample */
- }
- }
- else
- {
- if (m_explode_sound_playing == 1)
- {
- m_explode_sound_playing = 0;
- m_samples->start(1,2); /* explosion ending sample */
- }
- }
-
- if (m_launch2_on)
- {
- if (m_launch2_sound_playing == 0)
- {
- m_launch2_sound_playing = 1;
- m_samples->start(3,3); /* launch sample */
- }
- }
- else
- {
- m_launch2_sound_playing = 0;
- }
+ m_launch[1]->write_line(BIT(data, 5));
+ m_explode[1]->write_line(BIT(data, 4));
}
int starcrus_state::collision_check_s1s2()