Previous | 199869 Revisions | Next |
r44488 Monday 25th January, 2016 at 23:27:07 UTC by Joakim Larsson Edström |
---|
Fixed keyboard lag issue due to faulty clock setup |
[/trunk] | makefile |
[scripts] | genie.lua toolchain.lua |
[src/devices/bus/intv] | ecs.cpp |
[src/devices/cpu/i86] | i86.cpp |
[src/emu/debug] | dvdisasm.cpp |
[src/mame] | arcade.lst |
[src/mame/audio] | cclimber.cpp |
[src/mame/drivers] | didact.cpp jclub2.cpp legionna.cpp marywu.cpp ssv.cpp st_mp200.cpp viper.cpp |
[src/mame/machine] | kc.cpp midwayic.cpp naomi.cpp |
[src/mame/video] | m107.cpp st0020.cpp st0020.h |
r252999 | r253000 | |
---|---|---|
1179 | 1179 | |
1180 | 1180 | |
1181 | 1181 | #------------------------------------------------- |
1182 | # gmake-steamlink | |
1183 | #------------------------------------------------- | |
1184 | ||
1185 | $(PROJECTDIR)/gmake-steamlink/Makefile: makefile $(SCRIPTS) $(GENIE) | |
1186 | ifndef MARVELL_SDK_PATH | |
1187 | $(error MARVELL_SDK_PATH is not set) | |
1188 | endif | |
1189 | ifndef MARVELL_ROOTFS | |
1190 | $(error MARVELL_ROOTFS is not set) | |
1191 | endif | |
1192 | $(SILENT) $(GENIE) $(PARAMS) --gcc=steamlink --gcc_version=$(GCC_VERSION) --USE_BGFX=0 --NO_OPENGL=1 --NO_USE_MIDI=1 --NO_X11=1 --NOASM=1 --SDL_INSTALL_ROOT=$(MARVELL_ROOTFS)/usr gmake | |
1193 | ||
1194 | .PHONY: steamlink | |
1195 | ifndef MARVELL_SDK_PATH | |
1196 | $(error MARVELL_SDK_PATH is not set) | |
1197 | endif | |
1198 | ifndef MARVELL_ROOTFS | |
1199 | $(error MARVELL_ROOTFS is not set) | |
1200 | endif | |
1201 | steamlink: generate $(PROJECTDIR)/gmake-steamlink/Makefile | |
1202 | $(SILENT) $(MAKE) $(MAKEPARAMS) -C $(PROJECTDIR)/gmake-steamlink config=$(CONFIG) precompile | |
1203 | $(SILENT) $(MAKE) $(MAKEPARAMS) -C $(PROJECTDIR)/gmake-steamlink config=$(CONFIG) | |
1204 | ||
1205 | ||
1206 | ||
1207 | #------------------------------------------------- | |
1208 | 1182 | # cmake |
1209 | 1183 | #------------------------------------------------- |
1210 | 1184 | cmake: generate |
r252999 | r253000 | |
---|---|---|
108 | 108 | { "os2", "OS/2 eComStation" }, |
109 | 109 | { "haiku", "Haiku" }, |
110 | 110 | { "solaris", "Solaris SunOS" }, |
111 | { "steamlink", "Steam Link" }, | |
112 | 111 | }, |
113 | 112 | } |
114 | 113 | |
r252999 | r253000 | |
1053 | 1052 | end |
1054 | 1053 | |
1055 | 1054 | |
1056 | ||
1057 | configuration { "steamlink" } | |
1058 | links { | |
1059 | "dl", | |
1060 | } | |
1061 | defines { | |
1062 | "EGL_API_FB", | |
1063 | } | |
1064 | ||
1065 | 1055 | configuration { "osx*" } |
1066 | 1056 | links { |
1067 | 1057 | "pthread", |
r252999 | r253000 | |
---|---|---|
32 | 32 | { "qnx-arm", "QNX/Blackberry - ARM" }, |
33 | 33 | { "rpi", "RaspberryPi" }, |
34 | 34 | { "solaris", "Solaris" }, |
35 | { "steamlink", "Steam Link" }, | |
36 | 35 | }, |
37 | 36 | } |
38 | 37 | |
r252999 | r253000 | |
190 | 189 | location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-linux-clang") |
191 | 190 | end |
192 | 191 | |
193 | if "steamlink" == _OPTIONS["gcc"] then | |
194 | if not os.getenv("MARVELL_SDK_PATH") then | |
195 | print("Set MARVELL_SDK_PATH envrionment variable.") | |
196 | end | |
197 | premake.gcc.cc = "$(MARVELL_SDK_PATH)/toolchain/bin/armv7a-cros-linux-gnueabi-gcc" | |
198 | premake.gcc.cxx = "$(MARVELL_SDK_PATH)/toolchain/bin/armv7a-cros-linux-gnueabi-g++" | |
199 | premake.gcc.ar = "$(MARVELL_SDK_PATH)/toolchain/bin/armv7a-cros-linux-gnueabi-ar" | |
200 | location (_buildDir .. "projects/" .. _subDir .. "/".. _ACTION .. "-steamlink") | |
201 | end | |
202 | ||
203 | 192 | if "mingw32-gcc" == _OPTIONS["gcc"] then |
204 | if not os.getenv("MINGW32") then | |
193 | if not os.getenv("MINGW32") or not os.getenv("MINGW32") then | |
205 | 194 | print("Set MINGW32 envrionment variable.") |
206 | 195 | end |
207 | 196 | premake.gcc.cc = "$(MINGW32)/bin/i686-w64-mingw32-gcc" |
r252999 | r253000 | |
218 | 207 | end |
219 | 208 | |
220 | 209 | if "mingw64-gcc" == _OPTIONS["gcc"] then |
221 | if not os.getenv("MINGW64") then | |
210 | if not os.getenv("MINGW64") or not os.getenv("MINGW64") then | |
222 | 211 | print("Set MINGW64 envrionment variable.") |
223 | 212 | end |
224 | 213 | premake.gcc.cc = "$(MINGW64)/bin/x86_64-w64-mingw32-gcc" |
r252999 | r253000 | |
494 | 483 | configuration { "x64", "mingw64-gcc", "Debug" } |
495 | 484 | targetdir (_buildDir .. "mingw-gcc" .. "/bin/x64/Debug") |
496 | 485 | |
497 | configuration { "steamlink" } | |
498 | objdir ( _buildDir .. "steamlink/obj") | |
499 | ||
500 | buildoptions { | |
501 | "-marm", | |
502 | "-mfloat-abi=hard", | |
503 | "--sysroot=$(MARVELL_SDK_PATH)/rootfs", | |
504 | } | |
505 | linkoptions { | |
506 | "-static-libgcc", | |
507 | "-static-libstdc++", | |
508 | "--sysroot=$(MARVELL_SDK_PATH)/rootfs", | |
509 | } | |
510 | ||
511 | configuration { "steamlink", "Release" } | |
512 | targetdir (_buildDir .. "steamlink/bin/Release") | |
513 | ||
514 | configuration { "steamlink", "Debug" } | |
515 | targetdir (_buildDir .. "steamlink/bin/Debug") | |
516 | ||
517 | 486 | configuration { "mingw-clang" } |
518 | 487 | linkoptions { |
519 | 488 | "-Wl,--allow-multiple-definition", |
r252999 | r253000 | |
527 | 496 | targetdir (_buildDir .. "mingw-clang/bin/x32/Release") |
528 | 497 | |
529 | 498 | configuration { "x32", "mingw-clang", "Debug" } |
530 | targetdir (_buildDir .. "mingw-clang/bin/x32/Debug") | |
499 | targetdir (_buildDir .. "win32_mingw-clang/bin/x32/Debug") | |
531 | 500 | |
532 | 501 | configuration { "x64", "mingw-clang" } |
533 | 502 | objdir (_buildDir .. "mingw-clang/obj") |
r252999 | r253000 | |
---|---|---|
138 | 138 | } |
139 | 139 | } |
140 | 140 | |
141 | y = (m_options->read() >> ((hand + 2) * 2)) & 3; | |
142 | switch (y) | |
141 | switch ((m_options->read() >> hand) & 4) | |
143 | 142 | { |
144 | case 0: /* disc == digital 8-way */ | |
145 | case 1: /* disc == digital 16-way */ | |
143 | case 0: /* disc == digital */ | |
146 | 144 | default: |
147 | 145 | |
148 | 146 | x = m_disc[hand]->read(); |
149 | if (!!x && (!y || !(x & 0x7777))) | |
150 | { | |
151 | // merge cardinals to form true diagonals | |
152 | y = ((x >> 2) & (x << 2)) | ((x >> (16 - 2)) & (x >> 2)); | |
153 | x = y | (x & ~((y << 2) | (y >> 2) | (y << (16 - 2)))); | |
154 | } | |
155 | ||
156 | // only one disc direction is allowed | |
157 | x &= -x; | |
158 | ||
159 | 147 | for (y = 0; y < 16; y++) |
160 | 148 | { |
161 | 149 | if (x & (1 << y)) |
r252999 | r253000 | |
165 | 153 | } |
166 | 154 | break; |
167 | 155 | |
168 | case | |
156 | case 4: /* disc == _fake_ analog */ | |
169 | 157 | |
170 | 158 | x = m_discx[hand]->read(); |
171 | 159 | y = m_discy[hand]->read(); |
r252999 | r253000 | |
429 | 417 | static INPUT_PORTS_START( intv_ecs_pads ) |
430 | 418 | // First ECS Hand Controller |
431 | 419 | PORT_START("KEYPAD.0") |
432 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 1") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
433 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 2") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
434 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 3") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
435 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 4") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
436 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 5") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
437 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 6") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
438 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 7") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
439 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 8") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
440 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 9") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
441 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 Clear") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
442 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 0") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
443 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3 Enter") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
444 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("P3 Upper") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
445 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("P3 Lower-Left") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
446 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("P3 Lower-Right") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
420 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/1") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
421 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/2") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
422 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/3") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
423 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/4") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
424 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/5") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
425 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/6") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
426 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/7") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
427 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/8") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
428 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/9") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
429 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/Clear") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
430 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/0") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
431 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P3/Enter") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
432 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("P3/Upper") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
433 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("P3/Lower-Left") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
434 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("P3/Lower-Right") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
447 | 435 | PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_UNUSED ) |
448 | 436 | |
449 | 437 | PORT_START("DISC.0") |
450 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("P3 Up") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,NOTEQUALS,0x20) | |
451 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Up-Up-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
452 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Up-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
453 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Right-Up-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
454 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("P3 Right") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,NOTEQUALS,0x20) | |
455 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Right-Down-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
456 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Down-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
457 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Down-Down-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
458 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("P3 Down") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,NOTEQUALS,0x20) | |
459 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Down-Down-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
460 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Down-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
461 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Left-Down-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
462 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("P3 Left") PORT_PLAYER(3) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,NOTEQUALS,0x20) | |
463 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Left-Up-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
464 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Up-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
465 | PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3 Up-Up-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0x30,EQUALS,0x10) | |
438 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("P3/Up") PORT_PLAYER(3) PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
439 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Up-Up-Right") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
440 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Right") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
441 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Right-Up-Right") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
442 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("P3/Right") PORT_PLAYER(3) PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
443 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Right-Down-Right") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
444 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Down-Right") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
445 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Down-Down-Right") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
446 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("P3/Down") PORT_PLAYER(3) PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
447 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Down-Down-Left") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
448 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Down-Left") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
449 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Left-Down-Left") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
450 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("P3/Left") PORT_PLAYER(3) PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
451 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Left-Up-Left") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
452 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Up-Left") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
453 | PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P3/Up-Up-Left") PORT_CONDITION("OPTIONS",0x04,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
466 | 454 | |
467 | 455 | PORT_START("DISCX.0") |
468 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_X ) PORT_NAME("P3 | |
456 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_X ) PORT_NAME("P3/X") PORT_MINMAX(0x00,0x9f) PORT_SENSITIVITY(100) PORT_KEYDELTA(0x50) PORT_PLAYER(3) PORT_CONDITION("OPTIONS",0x04,EQUALS,0x04) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
469 | 457 | |
470 | 458 | PORT_START("DISCY.0") |
471 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_Y ) PORT_NAME("P3 | |
459 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_Y ) PORT_NAME("P3/Y") PORT_MINMAX(0x00,0x9f) PORT_SENSITIVITY(100) PORT_KEYDELTA(0x50) PORT_PLAYER(3) PORT_CONDITION("OPTIONS",0x04,EQUALS,0x04) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
472 | 460 | |
473 | 461 | // Second ECS Hand Controller |
474 | 462 | PORT_START("KEYPAD.1") |
475 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 1") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
476 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 2") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
477 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 3") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
478 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 4") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
479 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 5") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
480 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 6") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
481 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 7") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
482 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 8") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
483 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 9") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
484 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 Clear") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
485 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 0") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
486 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4 Enter") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
487 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("P4 Upper") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
488 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("P4 Lower-Left") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
489 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("P4 Lower-Right") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
463 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/1") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
464 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/2") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
465 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/3") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
466 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/4") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
467 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/5") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
468 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/6") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
469 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/7") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
470 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/8") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
471 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/9") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
472 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/Clear") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
473 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/0") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
474 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_NAME("P4/Enter") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
475 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("P4/Upper") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
476 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("P4/Lower-Left") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
477 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("P4/Lower-Right") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
490 | 478 | PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_UNUSED ) |
491 | 479 | |
492 | 480 | PORT_START("DISC.1") |
493 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("P4 Up") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,NOTEQUALS,0x80) | |
494 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Up-Up-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
495 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Up-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
496 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Right-Up-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
497 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("P4 Right") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,NOTEQUALS,0x80) | |
498 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Right-Down-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
499 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Down-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
500 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Down-Down-Right") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
501 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("P4 Down") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,NOTEQUALS,0x80) | |
502 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Down-Down-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
503 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Down-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
504 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Left-Down-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
505 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("P4 Left") PORT_PLAYER(4) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,NOTEQUALS,0x80) | |
506 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Left-Up-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
507 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Up-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
508 | PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4 Up-Up-Left") PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) PORT_CONDITION("OPTIONS",0xC0,EQUALS,0x40) | |
481 | PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_NAME("P4/Up") PORT_PLAYER(4) PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
482 | PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Up-Up-Right") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
483 | PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Up-Right") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
484 | PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Right-Up-Right") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
485 | PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) PORT_NAME("P4/Right") PORT_PLAYER(4) PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
486 | PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Right-Down-Right") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
487 | PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Down-Right") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
488 | PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Down-Down-Right") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
489 | PORT_BIT( 0x0080, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_NAME("P4/Down") PORT_PLAYER(4) PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
490 | PORT_BIT( 0x0040, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Down-Down-Left") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
491 | PORT_BIT( 0x0020, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Down-Left") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
492 | PORT_BIT( 0x0010, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Left-Down-Left") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
493 | PORT_BIT( 0x0008, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) PORT_NAME("P4/Left") PORT_PLAYER(4) PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
494 | PORT_BIT( 0x0004, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Left-Up-Left") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
495 | PORT_BIT( 0x0002, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Up-Left") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
496 | PORT_BIT( 0x0001, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("P4/Up-Up-Left") PORT_CONDITION("OPTIONS",0x08,EQUALS,0x00) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
509 | 497 | |
510 | 498 | PORT_START("DISCX.1") |
511 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_X ) PORT_NAME("P4 | |
499 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_X ) PORT_NAME("P4/X") PORT_MINMAX(0x00,0x9f) PORT_SENSITIVITY(100) PORT_KEYDELTA(0x50) PORT_CODE_DEC(KEYCODE_D) PORT_CODE_INC(KEYCODE_G) PORT_PLAYER(4) PORT_CONDITION("OPTIONS",0x08,EQUALS,0x08) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
512 | 500 | |
513 | 501 | PORT_START("DISCY.1") |
514 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_Y ) PORT_NAME("P4 | |
502 | PORT_BIT( 0xff, 0x50, IPT_AD_STICK_Y ) PORT_NAME("P4/Y") PORT_MINMAX(0x00,0x9f) PORT_SENSITIVITY(100) PORT_KEYDELTA(0x50) PORT_CODE_DEC(KEYCODE_R) PORT_CODE_INC(KEYCODE_F) PORT_PLAYER(4) PORT_CONDITION("OPTIONS",0x08,EQUALS,0x08) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
515 | 503 | INPUT_PORTS_END |
516 | 504 | |
517 | 505 | static INPUT_PORTS_START( intv_ecs ) |
r252999 | r253000 | |
520 | 508 | PORT_INCLUDE( intv_ecs_kbd ) |
521 | 509 | |
522 | 510 | PORT_START("OPTIONS") |
523 | PORT_CONFNAME( 0x30, 0x00, "ECS P3 Disc" ) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
524 | PORT_CONFSETTING( 0x00, "Digital 8-way" ) | |
525 | PORT_CONFSETTING( 0x10, "Digital 16-way" ) | |
526 | PORT_CONFSETTING( 0x20, "Analog" ) | |
527 | PORT_CONFNAME( 0xC0, 0x00, "ECS P4 Disc" ) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
528 | PORT_CONFSETTING( 0x00, "Digital 8-way" ) | |
529 | PORT_CONFSETTING( 0x40, "Digital 16-way" ) | |
530 | PORT_CONFSETTING( 0x80, "Analog" ) | |
511 | PORT_CONFNAME( 0x04, 0x00, "ECS_P3 Disc" ) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
512 | PORT_CONFSETTING( 0x00, "Digital" ) | |
513 | PORT_CONFSETTING( 0x04, "Analog" ) | |
514 | PORT_CONFNAME( 0x08, 0x00, "ECS_P4 Disc" ) PORT_CONDITION("CNTRLSEL",0x0f,EQUALS,0x00) | |
515 | PORT_CONFSETTING( 0x00, "Digital" ) | |
516 | PORT_CONFSETTING( 0x08, "Analog" ) | |
531 | 517 | |
532 | 518 | PORT_START("CNTRLSEL") |
533 | 519 | PORT_CONFNAME( 0x0F, 0x02, "ECS Controller") |
r252999 | r253000 | |
---|---|---|
144 | 144 | m_seg_prefix = false; |
145 | 145 | |
146 | 146 | /* Dispatch IRQ */ |
147 | if ( m_pending_irq && | |
147 | if ( m_pending_irq && m_no_interrupt == 0 ) | |
148 | 148 | { |
149 | 149 | if ( m_pending_irq & NMI_IRQ ) |
150 | 150 | { |
r252999 | r253000 | |
159 | 159 | } |
160 | 160 | } |
161 | 161 | |
162 | /* Trap should allow one instruction to be executed. | |
163 | CPUID.ASM (by Bob Smith, 1985) suggests that in situations where m_no_interrupt is 1, | |
164 | (directly after POP SS / MOV_SREG), single step IRQs don't fire. | |
165 | */ | |
166 | if (m_fire_trap ) | |
162 | /* No interrupt allowed between last instruction and this one */ | |
163 | if ( m_no_interrupt ) | |
167 | 164 | { |
168 | if ( (m_fire_trap >= 2) && (m_no_interrupt == 0) ) | |
165 | m_no_interrupt--; | |
166 | } | |
167 | ||
168 | /* trap should allow one instruction to be executed */ | |
169 | if ( m_fire_trap ) | |
170 | { | |
171 | if ( m_fire_trap >= 2 ) | |
169 | 172 | { |
170 | m_fire_trap = 0; // reset trap flag upon entry | |
171 | 173 | interrupt(1); |
174 | m_fire_trap = 0; | |
172 | 175 | } |
173 | 176 | else |
174 | 177 | { |
175 | 178 | m_fire_trap++; |
176 | 179 | } |
177 | 180 | } |
178 | ||
179 | /* No interrupt allowed between last instruction and this one */ | |
180 | if ( m_no_interrupt ) | |
181 | { | |
182 | m_no_interrupt--; | |
183 | } | |
184 | ||
185 | 181 | } |
186 | 182 | |
187 | 183 | if (!m_seg_prefix) |
r252999 | r253000 | |
1408 | 1404 | m_src = GetRMWord(); |
1409 | 1405 | m_sregs[(m_modrm & 0x18) >> 3] = m_src; // confirmed on hw: modrm bit 5 ignored |
1410 | 1406 | CLKM(MOV_SR,MOV_SM); |
1411 | m_no_interrupt = 1; // Disable IRQ after load segment register. | |
1412 | 1407 | break; |
1413 | 1408 | |
1414 | 1409 | case 0x8f: // i_popw |
r252999 | r253000 | |
---|---|---|
100 | 100 | for (device_disasm_interface *dasm = iter.first(); dasm != nullptr; dasm = iter.next()) |
101 | 101 | { |
102 | 102 | strprintf(name,"%s '%s'", dasm->device().name(), dasm->device().tag()); |
103 | if (dasm->device().memory().space_config(AS_PROGRAM)!=nullptr) | |
104 | m_source_list.append(*global_alloc(debug_view_disasm_source(name.c_str(), dasm->device()))); | |
103 | m_source_list.append(*global_alloc(debug_view_disasm_source(name.c_str(), dasm->device()))); | |
105 | 104 | } |
106 | 105 | |
107 | 106 | // reset the source to a known good entry |
r252999 | r253000 | |
---|---|---|
8837 | 8837 | skysmash // (c) 1990 Nihon System Inc. |
8838 | 8838 | legionna // (c) 1992 Tad (World) |
8839 | 8839 | legionnau // (c) 1992 Tad + Fabtek license (US) |
8840 | legionnaj // (c) 1992 Tad (Japan) | |
8841 | 8840 | heatbrl // (c) 1992 Tad (World version 3) |
8842 | 8841 | heatbrl2 // (c) 1992 Tad (World version 2) |
8843 | 8842 | heatbrlo // (c) 1992 Tad (World) |
r252999 | r253000 | |
---|---|---|
52 | 52 | m_sample_freq(0), |
53 | 53 | m_sample_volume(0), |
54 | 54 | m_samples(*this, "samples"), |
55 | m_samples_region(*this, " | |
55 | m_samples_region(*this, "samples") | |
56 | 56 | { |
57 | 57 | } |
58 | 58 |
r252999 | r253000 | |
---|---|---|
105 | 105 | * - Expansion bus |
106 | 106 | * - Expansion overlay |
107 | 107 | * |
108 | * - The md6802 has a strange delay in keyboard input that needs to be investigated | |
109 | * | |
110 | 108 | ****************************************************************************/ |
111 | 109 | |
112 | 110 | #include "emu.h" |
r252999 | r253000 | |
593 | 591 | } |
594 | 592 | |
595 | 593 | static MACHINE_CONFIG_START( e100, e100_state ) |
596 | MCFG_CPU_ADD("maincpu", M6802, XTAL_4MHz | |
594 | MCFG_CPU_ADD("maincpu", M6802, XTAL_4MHz) | |
597 | 595 | MCFG_CPU_PROGRAM_MAP(e100_map) |
598 | 596 | |
599 | 597 | /* devices */ |
r252999 | r253000 | |
602 | 600 | MACHINE_CONFIG_END |
603 | 601 | |
604 | 602 | static MACHINE_CONFIG_START( md6802, md6802_state ) |
605 | MCFG_CPU_ADD("maincpu", M6802, XTAL_4MHz | |
603 | MCFG_CPU_ADD("maincpu", M6802, XTAL_4MHz) | |
606 | 604 | MCFG_CPU_PROGRAM_MAP(md6802_map) |
607 | 605 | MCFG_DEFAULT_LAYOUT(layout_md6802) |
608 | 606 |
r252999 | r253000 | |
---|---|---|
500 | 500 | AM_RANGE(0x600000, 0x67ffff) AM_DEVREADWRITE16( "st0020_spr", st0020_device, st0020_sprram_r, st0020_sprram_w, 0xffffffff ); |
501 | 501 | AM_RANGE(0x680000, 0x69ffff) AM_RAM AM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette") |
502 | 502 | AM_RANGE(0x6a0000, 0x6bffff) AM_RAM |
503 | AM_RANGE(0x6C0000, 0x6C00ff) AM_DEVREADWRITE16( "st0020_spr", st0020_device, st0020_blitram_r, st0020_blitram_w, 0xffffffff ); | |
503 | //AM_RANGE(0x6C0000, 0x6C00ff) AM_DEVREADWRITE16( "st0020_spr", st0020_device, st0020_blitram_r, st0020_blitram_w, 0xffffffff ); | |
504 | 504 | AM_RANGE(0x700000, 0x7fffff) AM_DEVREADWRITE16( "st0020_spr", st0020_device, st0020_gfxram_r, st0020_gfxram_w, 0xffffffff ); |
505 | 505 | |
506 | 506 | ADDRESS_MAP_END |
r252999 | r253000 | |
---|---|---|
1488 | 1488 | |
1489 | 1489 | ***************************************************************************/ |
1490 | 1490 | |
1491 | // all 3 Legionnaire sets differ only by the region byte at 0x1ef in rom 4 (Japan 0x00, US 0x01, World 0x02) | |
1492 | 1491 | ROM_START( legionna ) |
1493 | 1492 | ROM_REGION( 0x80000, "maincpu", 0 ) /* 68000 code */ |
1494 | 1493 | ROM_LOAD32_BYTE( "1.u025", 0x00000, 0x20000, CRC(9e2d3ec8) SHA1(8af9ca349389cbbd2b541aafa09de57f87f6fd72) ) |
r252999 | r253000 | |
1537 | 1536 | ROM_LOAD( "leg007.u091", 0x000000, 0x000200, NO_DUMP ) /* N82S147N type BPROM */ |
1538 | 1537 | ROM_END |
1539 | 1538 | |
1540 | ROM_START( legionnaj ) | |
1541 | ROM_REGION( 0x80000, "maincpu", 0 ) /* 68000 code */ | |
1542 | ROM_LOAD32_BYTE( "1.u025", 0x00000, 0x20000, CRC(9e2d3ec8) SHA1(8af9ca349389cbbd2b541aafa09de57f87f6fd72) ) | |
1543 | ROM_LOAD32_BYTE( "2.u024", 0x00001, 0x20000, CRC(35c8a28f) SHA1(31a1f2f9e04dfcab4b3357d6d27c24b434a8c14b) ) | |
1544 | ROM_LOAD32_BYTE( "3.u026", 0x00002, 0x20000, CRC(553fc7c0) SHA1(b12a2eea6b2c9bd76c0c74ddf2765d58510f586a) ) | |
1545 | ROM_LOAD32_BYTE( "4.u023", 0x00003, 0x20000, CRC(4c385dc7) SHA1(75ec869a5553228369faa8f8487d92ac5df7e563) ) // sldh | |
1546 | ||
1547 | ROM_REGION( 0x20000, "audiocpu", 0 ) /* Z80 code, banked data */ | |
1548 | ROM_LOAD( "6.u1110", 0x000000, 0x08000, CRC(fe7b8d06) SHA1(1e5b52ea4b4042940e2ee2db75c7c0f24973422a) ) | |
1549 | ROM_CONTINUE( 0x010000, 0x08000 ) /* banked stuff */ | |
1550 | ROM_COPY( "audiocpu", 0x000000, 0x018000, 0x08000 ) | |
1551 | ||
1552 | ROM_REGION( 0x020000, "user1", 0 ) /* load the tiles here so we can split them up into the required regions by hand */ | |
1553 | ROM_LOAD16_BYTE( "7.u077", 0x000000, 0x10000, CRC(88e26809) SHA1(40ee55d3b5329b6f657e0621d93c4caf6a035fdf) ) | |
1554 | ROM_LOAD16_BYTE( "8.u072", 0x000001, 0x10000, CRC(06e35407) SHA1(affeeb97b7f3cfa9b65a584ebe25c16a5b2c9a89) ) | |
1555 | ||
1556 | ROM_REGION( 0x010000, "char", 0 ) /* FG Tiles */ | |
1557 | ROM_COPY( "user1", 0x010000, 0x000000, 0x010000 ) | |
1558 | ||
1559 | ROM_REGION( 0x010000, "gfx5", 0 ) /* BK3 */ | |
1560 | ROM_COPY( "user1", 0x000000, 0x000000, 0x010000 ) /* decrambled in INIT */ | |
1561 | ||
1562 | ROM_REGION( 0x200000, "sprite", 0 ) | |
1563 | ROM_LOAD( "legionnire_obj1.u0815", 0x000000, 0x100000, CRC(d35602f5) SHA1(79379abf1c8131df47f81f42b2dc6876926a4e9d) ) /* sprites */ | |
1564 | ROM_LOAD( "legionnire_obj2.u0814", 0x100000, 0x100000, CRC(351d3917) SHA1(014562ac55c09227c08275df3129df19d81af164) ) | |
1565 | ||
1566 | ROM_REGION( 0x100000, "user2", 0 ) /* load the tiles here so we can split them up into the required regions by hand */ | |
1567 | ROM_LOAD( "legionnire_back.u075", 0x000000, 0x100000, CRC(58280989) SHA1(e3eef1f52829a91b8f87cfe27776a1f12679b3ca) ) /* 3 sets of tiles ('MBK','LBK','BK3') */ | |
1568 | ||
1569 | ROM_REGION( 0x80000, "gfx3", 0 ) /* MBK */ | |
1570 | ROM_COPY( "user2", 0x000000, 0x000000, 0x80000 ) | |
1571 | ||
1572 | ROM_REGION( 0x100000, "gfx4", ROMREGION_ERASEFF ) | |
1573 | /* Not Used */ | |
1574 | ||
1575 | ROM_REGION( 0x80000, "gfx6", 0 ) /* LBK */ | |
1576 | ROM_COPY( "user2", 0x080000, 0x000000, 0x78000 ) | |
1577 | ||
1578 | ROM_REGION( 0x40000, "oki", 0 ) /* ADPCM samples */ | |
1579 | ROM_LOAD( "5.u106", 0x00000, 0x20000, CRC(21d09bde) SHA1(8dce5011e083706ac7b57c5aee4b79d30fa8d4cb) ) | |
1580 | ||
1581 | ROM_REGION( 0x080000, "copx", 0 ) /* SEI300 data rom */ | |
1582 | ROM_LOAD( "copx-d1.u0330", 0x000000, 0x080000, CRC(029bc402) SHA1(0f64e4c32d95abfa3920b39ed3cf0cc6eb50191b) ) /* not dumped from this PCB assumed to be the same */ | |
1583 | ||
1584 | ROM_REGION( 0x200, "proms", 0 ) /* Priority? */ | |
1585 | ROM_LOAD( "leg007.u091", 0x000000, 0x000200, NO_DUMP ) /* N82S147N type BPROM */ | |
1586 | ROM_END | |
1587 | ||
1588 | 1539 | ROM_START( legionnau ) |
1589 | 1540 | ROM_REGION( 0x80000, "maincpu", 0 ) /* 68000 code */ |
1590 | 1541 | ROM_LOAD32_BYTE( "1.u025", 0x00000, 0x20000, CRC(9e2d3ec8) SHA1(8af9ca349389cbbd2b541aafa09de57f87f6fd72) ) |
r252999 | r253000 | |
2735 | 2686 | |
2736 | 2687 | |
2737 | 2688 | |
2738 | GAME( 1992, legionna, 0, legionna, legionna, legionna_state, legiongfx, ROT0, "TAD Corporation", | |
2689 | GAME( 1992, legionna, 0, legionna, legionna, legionna_state, legiongfx, ROT0, "TAD Corporation", "Legionnaire (World)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) | |
2739 | 2690 | GAME( 1992, legionnau,legionna, legionna, legionna, legionna_state, legiongfx, ROT0, "TAD Corporation (Fabtek license)", "Legionnaire (US)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) |
2740 | GAME( 1992, legionnaj,legionna, legionna, legionna, legionna_state, legiongfx, ROT0, "TAD Corporation", "Legionnaire (Japan)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) | |
2741 | 2691 | |
2742 | 2692 | GAME( 1992, heatbrl, 0, heatbrl, heatbrl, driver_device, 0, ROT0, "TAD Corporation", "Heated Barrel (World version 3)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) |
2743 | 2693 | GAME( 1992, heatbrl2, heatbrl, heatbrl, heatbrl, driver_device, 0, ROT0, "TAD Corporation", "Heated Barrel (World version 2)", MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING ) |
r252999 | r253000 | |
---|---|---|
102 | 102 | WRITE8_MEMBER( marywu_state::ay1_port_a_w ) |
103 | 103 | { |
104 | 104 | for (uint8_t i=0; i<8; i++){ |
105 | output | |
105 | output_set_led_value(i, (data & (1 << i)) ? 1 : 0); | |
106 | 106 | } |
107 | 107 | } |
108 | 108 | |
109 | 109 | WRITE8_MEMBER( marywu_state::ay1_port_b_w ) |
110 | 110 | { |
111 | 111 | for (uint8_t i=0; i<8; i++){ |
112 | output | |
112 | output_set_led_value(i+8, (data & (1 << i)) ? 1 : 0); | |
113 | 113 | } |
114 | 114 | } |
115 | 115 | |
116 | 116 | WRITE8_MEMBER( marywu_state::ay2_port_a_w ) |
117 | 117 | { |
118 | 118 | for (uint8_t i=0; i<8; i++){ |
119 | output | |
119 | output_set_led_value(i+16, (data & (1 << i)) ? 1 : 0); | |
120 | 120 | } |
121 | 121 | } |
122 | 122 | |
r252999 | r253000 | |
124 | 124 | { |
125 | 125 | for (uint8_t i=0; i<6; i++){ |
126 | 126 | /* we only have 30 LEDs. The last 2 bits in this port are unused. */ |
127 | output | |
127 | output_set_led_value(i+24, (data & (1 << i)) ? 1 : 0); | |
128 | 128 | } |
129 | 129 | } |
130 | 130 | |
r252999 | r253000 | |
160 | 160 | { |
161 | 161 | static const UINT8 patterns[16] = { 0x3f, 0x06, 0x5b, 0x4f, 0x66, 0x6d, 0x7c, 0x07, 0x7f, 0x67, 0, 0, 0, 0, 0, 0 }; // HEF4511BP (7 seg display driver) |
162 | 162 | |
163 | output().set_digit_value(2 * m_selected_7seg_module + 0, patterns[data & 0x0F]); | |
164 | output().set_digit_value(2 * m_selected_7seg_module + 1, patterns[(data >> 4) & 0x0F]); | |
163 | output_set_digit_value(2 * m_selected_7seg_module + 0, patterns[data & 0x0F]); | |
164 | output_set_digit_value(2 * m_selected_7seg_module + 1, patterns[(data >> 4) & 0x0F]); | |
165 | 165 | } |
166 | 166 | |
167 | 167 | static ADDRESS_MAP_START( program_map, AS_PROGRAM, 8, marywu_state ) |
r252999 | r253000 | |
---|---|---|
4675 | 4675 | ROM_LOAD( "vg004-10.u45", 0x200000, 0x200000, CRC(b3c6b1cb) SHA1(c601213e35d8dfd1244921da5c093f82145706d2) ) |
4676 | 4676 | ROM_LOAD( "vg004-11.u48", 0x400000, 0x200000, CRC(1491def1) SHA1(344043302c81b4118cac4f692375b8af7ea68570) ) |
4677 | 4677 | |
4678 | ROM_REGION( 0x1000000, "st0020 | |
4678 | ROM_REGION( 0x1000000, "st0020", /*0*/0 ) // Zooming Sprites, read by a blitter | |
4679 | 4679 | ROM_LOAD( "vg004-01.u33", 0x0000000, 0x200000, CRC(aa9a81c2) SHA1(a7d005f9be199e317aa4c6aed8a2ab322fe82119) ) |
4680 | 4680 | ROM_LOAD( "vg004-02.u34", 0x0200000, 0x200000, CRC(fa40ecb4) SHA1(0513f3b6879dc7d207646d949d6ddb7251f77bcc) ) |
4681 | 4681 | ROM_LOAD( "vg004-03.u35", 0x0400000, 0x200000, CRC(90004023) SHA1(041edb77b34e6677ac5b85ce542d87a9bb1baf31) ) |
r252999 | r253000 | |
---|---|---|
73 | 73 | bool m_u11_cb2; |
74 | 74 | bool m_timer_x; |
75 | 75 | bool m_u11_timer; |
76 | bool m_su; // speech unit fitted yes/no | |
76 | 77 | bool m_7d; // 7-digit display yes/no |
77 | 78 | UINT8 m_digit; |
78 | 79 | UINT8 m_counter; |
r252999 | r253000 | |
320 | 321 | |
321 | 322 | WRITE_LINE_MEMBER( st_mp200_state::u10_cb2_w ) |
322 | 323 | { |
323 | if (m_s | |
324 | if (m_su) | |
324 | 325 | { |
325 | 326 | if (m_s14001a->busy_r()) |
326 | 327 | m_pia_u11->cb1_w(0); |
r252999 | r253000 | |
333 | 334 | { |
334 | 335 | output().set_value("led0", !state); |
335 | 336 | |
336 | if (m_s | |
337 | if ((m_su) & (state)) | |
337 | 338 | { |
338 | 339 | if BIT(m_u10a, 7) |
339 | 340 | { |
r252999 | r253000 | |
551 | 552 | DRIVER_INIT_MEMBER( st_mp200_state, st_mp200 ) |
552 | 553 | { |
553 | 554 | m_7d = 1; |
555 | m_su = 0; | |
554 | 556 | } |
555 | 557 | |
556 | 558 | DRIVER_INIT_MEMBER( st_mp200_state, st_mp201 ) |
557 | 559 | { |
558 | 560 | m_7d = 1; |
561 | m_su = 1; | |
559 | 562 | } |
560 | 563 | |
561 | 564 | DRIVER_INIT_MEMBER( st_mp200_state, st_mp202 ) |
562 | 565 | { |
563 | 566 | m_7d = 0; |
567 | m_su = 0; | |
564 | 568 | } |
565 | 569 | |
566 | 570 | // zero-cross detection |
r252999 | r253000 | |
---|---|---|
2228 | 2228 | ROM_START(gticlub2ea) //* |
2229 | 2229 | VIPER_BIOS |
2230 | 2230 | |
2231 | ROM_REGION(0x28, "ds2430", ROMREGION_ERASE00) /* DS2430 */ | |
2232 | ||
2233 | 2231 | ROM_REGION(0x2000, "m48t58", ROMREGION_ERASE00) /* M48T58 Timekeeper NVRAM */ |
2234 | 2232 | ROM_LOAD("941eaa_nvram.u39", 0x00000, 0x2000, CRC(5ee7004d) SHA1(92e0ce01049308f459985d466fbfcfac82f34a47)) |
2235 | 2233 | |
r252999 | r253000 | |
2493 | 2491 | ROM_START(wcombatk) //* |
2494 | 2492 | VIPER_BIOS |
2495 | 2493 | |
2496 | ROM_REGION(0x28, "ds2430", ROMREGION_ERASE00) /* DS2430 */ | |
2497 | ||
2498 | 2494 | ROM_REGION(0x2000, "m48t58", ROMREGION_ERASE00) /* M48T58 Timekeeper NVRAM */ |
2499 | 2495 | ROM_LOAD("wcombatk_nvram.u39", 0x00000, 0x2000, CRC(ebd4d645) SHA1(2fa7e2c6b113214f3eb1900c8ceef4d5fcf0bb76)) |
2500 | 2496 | |
r252999 | r253000 | |
2505 | 2501 | ROM_START(wcombatu) //* |
2506 | 2502 | VIPER_BIOS |
2507 | 2503 | |
2508 | ROM_REGION(0x28, "ds2430", ROMREGION_ERASE00) /* DS2430 */ | |
2509 | ||
2510 | 2504 | ROM_REGION(0x2000, "m48t58", ROMREGION_ERASE00) /* M48T58 Timekeeper NVRAM */ |
2511 | 2505 | ROM_LOAD("Warzaid u39 c22d02", 0x00000, 0x2000, CRC(71744990) SHA1(19ed07572f183e7b3a712704ebddf7a848c48a78) ) |
2512 | 2506 |
r252999 | r253000 | |
---|---|---|
332 | 332 | { |
333 | 333 | address_space &space = m_maincpu->space( AS_PROGRAM ); |
334 | 334 | |
335 | if ((m_pio_data[0] & (1<<7)) && memregion("basic") != nullptr) | |
335 | if ((m_pio_data[0] & (1<<7)) && memregion("basic")->base() != nullptr) | |
336 | 336 | { |
337 | 337 | /* BASIC takes next priority */ |
338 | 338 | LOG(("BASIC rom 0x0c000\n")); |
r252999 | r253000 | |
---|---|---|
645 | 645 | m_cage = machine().device<atari_cage_device>("cage"); |
646 | 646 | m_has_cage = (m_cage != nullptr); |
647 | 647 | |
648 | if (m_has_dcs) | |
649 | { | |
650 | m_dcs_cpu = m_dcs->subdevice("dcs2"); | |
651 | if (m_dcs_cpu == nullptr) | |
652 | m_dcs_cpu = m_dcs->subdevice("dsio"); | |
653 | if (m_dcs_cpu == nullptr) | |
654 | m_dcs_cpu = m_dcs->subdevice("denver"); | |
655 | } | |
656 | ||
648 | m_dcs_cpu = m_dcs->subdevice("dcs2"); | |
649 | if (m_dcs_cpu == nullptr) | |
650 | m_dcs_cpu = m_dcs->subdevice("dsio"); | |
651 | if (m_dcs_cpu == nullptr) | |
652 | m_dcs_cpu = m_dcs->subdevice("denver"); | |
657 | 653 | m_shuffle_map = &shuffle_maps[m_shuffle_type][0]; |
658 | 654 | // resolve callbacks |
659 | 655 | m_irq_callback.resolve_safe(); |
r252999 | r253000 | |
666 | 662 | |
667 | 663 | m_reg[IOASIC_SOUNDCTL] = 0x0001; |
668 | 664 | |
669 | ||
670 | 665 | /* configure the fifo */ |
671 | 666 | if (m_has_dcs) |
672 | 667 | { |
r252999 | r253000 | |
676 | 671 | m_dcs->set_io_callbacks(write_line_delegate(FUNC(midway_ioasic_device::ioasic_output_full),this), |
677 | 672 | write_line_delegate(FUNC(midway_ioasic_device::ioasic_input_empty),this)); |
678 | 673 | } |
679 | ||
680 | 674 | fifo_reset_w(1); |
681 | 675 | } |
682 | 676 |
r252999 | r253000 | |
---|---|---|
87 | 87 | void naomi_state::create_pic_from_retdat() |
88 | 88 | { |
89 | 89 | { |
90 | memory_region * rgn_hexregion = memregion("pichex"); | |
91 | memory_region * rgn_retregion = memregion("picreturn"); | |
92 | memory_region * rgn_newregion = memregion("pic"); | |
90 | UINT8* hexregion = memregion("pichex")->base(); | |
91 | UINT8* retregion = memregion("picreturn")->base(); | |
92 | UINT8* newregion = memregion("pic")->base(); | |
93 | 93 | int outcount = 0; |
94 | 94 | |
95 | if ( | |
95 | if (hexregion && retregion && newregion) | |
96 | 96 | { |
97 | UINT8* hexregion = rgn_hexregion->base(); | |
98 | UINT8* newregion = rgn_newregion->base(); | |
99 | ||
100 | ||
101 | 97 | int hexoffs = 0; |
102 | 98 | int line; |
103 | 99 | |
r252999 | r253000 | |
135 | 131 | |
136 | 132 | } |
137 | 133 | |
138 | if (rgn_retregion && rgn_newregion) | |
139 | 134 | { |
140 | UINT8* retregion = rgn_retregion->base(); | |
141 | UINT8* newregion = rgn_newregion->base(); | |
142 | ||
143 | ||
144 | 135 | int i; |
145 | 136 | printf("string 1 (key1)\n"); |
146 | 137 | for (i=0;i<7;i++) |
r252999 | r253000 | |
175 | 166 | } |
176 | 167 | } |
177 | 168 | |
178 | if (rgn_newregion) | |
179 | { | |
180 | UINT8* newregion = rgn_newregion->base(); | |
181 | 169 | |
170 | { | |
182 | 171 | FILE *fp; |
183 | 172 | char filename[256]; |
184 | 173 | sprintf(filename,"picbin_%s", machine().system().name); |
r252999 | r253000 | |
---|---|---|
160 | 160 | void m107_state::draw_sprites(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) |
161 | 161 | { |
162 | 162 | UINT16 *spriteram = m_buffered_spriteram.get(); |
163 | int offs; | |
164 | UINT8 *rom = m_user1_ptr; | |
165 | ||
166 | for (offs = 0;offs < 0x800;offs += 4) | |
163 | ||
164 | for (int offs = 0; offs < 0x800; offs += 4) | |
167 | 165 | { |
168 | int | |
166 | int pri_mask = (!(spriteram[offs + 2] & 0x80)) ? 2 : 0; | |
169 | 167 | |
170 | pri_mask = (!(spriteram[offs+2]&0x80)) ? 2 : 0; | |
168 | int y = spriteram[offs + 0] & 0x1ff; | |
169 | int x = spriteram[offs + 3] & 0x1ff; | |
171 | 170 | |
172 | y=spriteram[offs+0]; | |
173 | x=spriteram[offs+3]; | |
174 | x&=0x1ff; | |
175 | y&=0x1ff; | |
176 | ||
177 | 171 | if (x==0 || y==0) continue; /* offscreen */ |
178 | 172 | |
179 | sprite=spriteram[offs+1]&0x7fff; | |
173 | int sprite_code = spriteram[offs + 1] & 0x7fff; | |
180 | 174 | |
181 | 175 | x = x - 16; |
182 | 176 | y = 384 - 16 - y; |
183 | 177 | |
184 | colour=spriteram[offs+2]&0x7f; | |
185 | fx=(spriteram[offs+2]>>8)&0x1; | |
186 | fy=(spriteram[offs+2]>>8)&0x2; | |
187 | y_multi=(spriteram[offs+0]>>11)&0x3; | |
178 | int colour = spriteram[offs + 2] & 0x7f; | |
179 | bool fx = (spriteram[offs + 2] >> 8) & 0x1; | |
180 | bool fy = (spriteram[offs + 2] >> 8) & 0x2; | |
181 | int y_multi=(spriteram[offs + 0] >> 11) & 0x3; | |
188 | 182 | |
189 | 183 | if (m_spritesystem == 0) |
190 | 184 | { |
191 | y_multi=1 << y_multi; /* 1, 2, 4 or 8 */ | |
185 | y_multi = 1 << y_multi; /* 1, 2, 4 or 8 */ | |
192 | 186 | |
193 | s_ptr = 0; | |
194 | if (!fy) s_ptr+=y_multi-1; | |
187 | int s_ptr = fy ? 0 : y_multi - 1; | |
195 | 188 | |
196 | for (i=0; i<y_multi; i++) | |
189 | for (int i = 0; i < y_multi; i++) | |
197 | 190 | { |
198 | m_gfxdecode->gfx(1)->prio_transpen(bitmap,cliprect, | |
199 | sprite + s_ptr, | |
200 | colour, | |
201 | fx,fy, | |
202 | x,y-i*16, | |
203 | screen.priority(),pri_mask,0); | |
191 | m_gfxdecode->gfx(1)->prio_transpen(bitmap, cliprect, sprite_code + s_ptr, colour, fx, fy, x, y - i * 16, screen.priority(), pri_mask, 0); | |
192 | m_gfxdecode->gfx(1)->prio_transpen(bitmap, cliprect, sprite_code + s_ptr, colour, fx, fy, x, (y - i * 16) - 0x200, screen.priority(), pri_mask, 0); /* wrap-around y */ | |
204 | 193 | |
205 | /* wrap-around y */ | |
206 | m_gfxdecode->gfx(1)->prio_transpen(bitmap,cliprect, | |
207 | sprite + s_ptr, | |
208 | colour, | |
209 | fx,fy, | |
210 | x,(y-i*16) - 0x200, | |
211 | screen.priority(),pri_mask,0); | |
212 | ||
213 | if (fy) s_ptr++; else s_ptr--; | |
194 | if (fy) | |
195 | s_ptr++; | |
196 | else | |
197 | s_ptr--; | |
214 | 198 | } |
215 | 199 | } |
216 | 200 | else |
217 | 201 | { |
218 | int rom_offs = sprite*8; | |
202 | int rom_offs = sprite_code * 8; | |
219 | 203 | |
220 | if (!rom) | |
221 | return; | |
222 | ||
223 | if (rom[rom_offs+1] || rom[rom_offs+3] || rom[rom_offs+5] || rom[rom_offs+7]) | |
204 | if (m_user1_ptr[rom_offs + 1] || m_user1_ptr[rom_offs + 3] || m_user1_ptr[rom_offs + 5] || m_user1_ptr[rom_offs + 7]) | |
224 | 205 | { |
225 | 206 | while (rom_offs < 0x40000) /* safety check */ |
226 | 207 | { |
208 | UINT8 *sprite = m_user1_ptr + rom_offs; | |
227 | 209 | /* |
228 | 210 | [1] |
229 | 211 | x--- ---- end of block marker |
r252999 | r253000 | |
244 | 226 | ---- ---x X offs hi byte |
245 | 227 | */ |
246 | 228 | |
247 | int xdisp = rom[rom_offs+6]+256*rom[rom_offs+7]; | |
248 | int ydisp = rom[rom_offs+2]+256*rom[rom_offs+3]; | |
249 | int ffx=fx^(rom[rom_offs+1]&1); | |
250 | int ffy=fy^(rom[rom_offs+1]&2); | |
251 | sprite=rom[rom_offs+4]+256*rom[rom_offs+5]; | |
252 | y_multi=1<<((rom[rom_offs+3]>>1)&0x3); | |
253 | if (fx) xdisp = -xdisp-16; | |
254 | if (fy) ydisp = -ydisp - (16*y_multi-1); | |
255 | if (!ffy) sprite+=y_multi-1; | |
256 | for (i=0; i<y_multi; i++) | |
229 | int xdisp = (sprite[7] << 8) | sprite[6]; | |
230 | int ydisp = (sprite[3] << 8) | sprite[2]; | |
231 | int ffx = fx ^ (sprite[1] & 1); | |
232 | int ffy = fy ^ (sprite[1] & 2); | |
233 | sprite_code = (sprite[5] << 8) | sprite[4]; | |
234 | y_multi = 1 << ((sprite[3] >> 1) & 0x3); | |
235 | if (fx) | |
236 | xdisp = -xdisp - 16; | |
237 | if (fy) | |
238 | ydisp = -ydisp - (16 * y_multi - 1); | |
239 | if (!ffy) | |
240 | sprite += y_multi - 1; | |
241 | ||
242 | for (int i = 0; i < y_multi; i++) | |
257 | 243 | { |
258 | m_gfxdecode->gfx(1)->prio_transpen(bitmap,cliprect, | |
259 | sprite+(ffy?i:-i), | |
260 | colour, | |
261 | ffx,ffy, | |
262 | (x+xdisp)&0x1ff,(y-ydisp-16*i)&0x1ff, | |
263 | screen.priority(),pri_mask,0); | |
244 | m_gfxdecode->gfx(1)->prio_transpen(bitmap, cliprect, sprite_code + (ffy ? i : -i), colour, ffx, ffy, (x + xdisp) & 0x1ff, (y - ydisp - 16 * i) & 0x1ff, screen.priority(), pri_mask, 0); | |
264 | 245 | |
265 | 246 | /* wrap-around y */ |
266 | m_gfxdecode->gfx(1)->prio_transpen(bitmap,cliprect, | |
267 | sprite+(ffy?i:-i), | |
268 | colour, | |
269 | ffx,ffy, | |
270 | (x+xdisp)&0x1ff,((y-ydisp-16*i)&0x1ff)-0x200, | |
271 | screen.priority(),pri_mask,0); | |
247 | m_gfxdecode->gfx(1)->prio_transpen(bitmap, cliprect, sprite_code + (ffy ? i : -i), colour, ffx, ffy, (x + xdisp) & 0x1ff, ((y - ydisp - 16 * i) & 0x1ff) - 0x200, screen.priority(), pri_mask, 0); | |
272 | 248 | } |
273 | 249 | |
274 | if (rom[rom_offs+1]&0x80) break; /* end of block */ | |
250 | if (sprite[1] & 0x80) | |
251 | break; /* end of block */ | |
275 | 252 | |
276 | 253 | rom_offs += 8; |
277 | 254 | } |
r252999 | r253000 | |
---|---|---|
19 | 19 | : device_t(mconfig, ST0020_SPRITES, "Seta ST0020 Sprites", tag, owner, clock, "st0020", __FILE__) |
20 | 20 | , m_gfxdecode(*this) |
21 | 21 | , m_palette(*this) |
22 | , m_rom_ptr(*this, ":st0020") | |
22 | 23 | { |
23 | 24 | m_is_st0032 = 0; |
24 | 25 | m_is_jclub2 = 0; |
r252999 | r253000 | |
73 | 74 | |
74 | 75 | void st0020_device::device_start() |
75 | 76 | { |
76 | memory_region* rgn = memregion(tag()); | |
77 | ||
78 | if (rgn) | |
79 | { | |
80 | m_rom_ptr = rgn->base(); | |
81 | m_rom_size = rgn->bytes(); | |
82 | } | |
83 | else | |
84 | { | |
85 | m_rom_ptr = nullptr; | |
86 | m_rom_size = 0; | |
87 | } | |
88 | ||
89 | 77 | m_st0020_gfxram = make_unique_clear<UINT16[]>(4 * 0x100000 / 2); |
90 | 78 | m_st0020_spriteram = make_unique_clear<UINT16[]>(0x80000 / 2); |
91 | 79 | m_st0020_blitram = make_unique_clear<UINT16[]>(0x100 / 2); |
r252999 | r253000 | |
202 | 190 | return; |
203 | 191 | } |
204 | 192 | |
205 | size_t size = m_rom_ | |
193 | size_t size = m_rom_ptr.bytes(); | |
206 | 194 | |
207 | 195 | if ( (src+len <= size) && (dst+len <= 4 * 0x100000) ) |
208 | 196 | { |
r252999 | r253000 | |
---|---|---|
47 | 47 | DECLARE_WRITE16_MEMBER(st0020_blit_w); |
48 | 48 | required_device<gfxdecode_device> m_gfxdecode; |
49 | 49 | required_device<palette_device> m_palette; |
50 | UINT8* m_rom_ptr; | |
51 | size_t m_rom_size; | |
50 | optional_region_ptr<UINT8> m_rom_ptr; | |
52 | 51 | }; |
53 | 52 | |
54 | 53 | #define ST0020_ST0032_BYTESWAP_DATA \ |
https://github.com/mamedev/mame/commit/2696952ef00fe4f14b628c1a013d0d5cba4ed1fe |
Previous | 199869 Revisions | Next |