summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2014-12-31 07:53:27 +0100
committer Miodrag Milanovic <mmicko@gmail.com>2014-12-31 07:53:27 +0100
commite6f78d5ed281850d9e8b391c049b8bf696e140bf (patch)
treec76def6dc672e2b56d3a9b3fb61fec02f0b21f8c
parentbfd87ef73a6850f475e2020c2c2935993f932c56 (diff)
Cleanups and version bumpmame0157
-rw-r--r--hash/adam_cass.xml46
-rw-r--r--hash/adam_flop.xml106
-rw-r--r--hash/apollo_ctape.xml4
-rw-r--r--hash/archimedes.xml12
-rw-r--r--hash/gamate.xml2
-rw-r--r--hash/mtx_cass.xml2
-rw-r--r--hash/n64.xml4
-rw-r--r--hash/neogeo.xml4
-rw-r--r--hash/nes.xml6
-rw-r--r--hash/pico.xml2
-rw-r--r--hash/sms.xml6
-rw-r--r--hash/vz_cass.xml122
-rw-r--r--src/emu/bus/centronics/epson_lx810l.c3
-rw-r--r--src/emu/bus/ieee488/c8050fdc.c4
-rw-r--r--src/emu/bus/isa/cga.c4
-rw-r--r--src/emu/bus/isa/sc499.h4
-rw-r--r--src/emu/bus/sega8/rom.c6
-rw-r--r--src/emu/bus/sega8/rom.h8
-rw-r--r--src/emu/cpu/arc/arc.c1
-rw-r--r--src/emu/cpu/arc/arcdasm.c4
-rw-r--r--src/emu/cpu/arcompact/arcompact.c3
-rw-r--r--src/emu/cpu/arcompact/arcompact.h69
-rw-r--r--src/emu/cpu/arcompact/arcompact_common.c13
-rw-r--r--src/emu/cpu/arcompact/arcompact_execute.c384
-rw-r--r--src/emu/cpu/arcompact/arcompactdasm.c66
-rw-r--r--src/emu/cpu/arcompact/arcompactdasm_dispatch.c47
-rw-r--r--src/emu/cpu/arcompact/arcompactdasm_dispatch.h3
-rw-r--r--src/emu/cpu/arcompact/arcompactdasm_ops.c260
-rw-r--r--src/emu/cpu/arcompact/arcompactdasm_ops.h7
-rw-r--r--src/emu/cpu/cpu.mak2
-rw-r--r--src/emu/cpu/h8/h8_timer16.c2
-rw-r--r--src/emu/cpu/m68000/m68kcpu.c2
-rw-r--r--src/emu/cpu/m68000/m68kdasm.c4
-rw-r--r--src/emu/cpu/pps4/pps4.c908
-rw-r--r--src/emu/cpu/pps4/pps4.h268
-rw-r--r--src/emu/cpu/pps4/pps4dasm.c286
-rw-r--r--src/emu/cpu/sh2/sh2comn.c2
-rw-r--r--src/emu/cpu/tms0980/tms0980.c76
-rw-r--r--src/emu/cpu/tms0980/tms0980.h16
-rw-r--r--src/emu/luaengine.c2
-rw-r--r--src/emu/machine.c4
-rw-r--r--src/emu/machine/am9517a.c2
-rw-r--r--src/emu/machine/e05a30.c1
-rw-r--r--src/emu/machine/i6300esb.c8
-rw-r--r--src/emu/machine/i82875p.h2
-rw-r--r--src/emu/machine/r10696.c202
-rw-r--r--src/emu/machine/r10696.h32
-rw-r--r--src/emu/machine/r10788.c240
-rw-r--r--src/emu/machine/r10788.h74
-rw-r--r--src/emu/machine/ra17xx.c68
-rw-r--r--src/emu/machine/ra17xx.h34
-rw-r--r--src/emu/machine/smpc.c6
-rw-r--r--src/emu/machine/steppers.c2
-rw-r--r--src/emu/machine/steppers.h40
-rw-r--r--src/emu/rendlay.c3574
-rw-r--r--src/emu/rendlay.h446
-rw-r--r--src/emu/sound/tms5110.c6
-rw-r--r--src/emu/video/315_5124.c2
-rw-r--r--src/emu/video/stvvdp2.c4
-rw-r--r--src/emu/video/tea1002.c2
-rw-r--r--src/lib/formats/dcp_dsk.c56
-rw-r--r--src/lib/formats/dip_dsk.c20
-rw-r--r--src/lib/formats/fdd_dsk.c38
-rw-r--r--src/lib/formats/nfd_dsk.c54
-rw-r--r--src/lib/formats/victor9k_dsk.c76
-rw-r--r--src/mame/drivers/5clown.c10
-rw-r--r--src/mame/drivers/atvtrack.c9
-rw-r--r--src/mame/drivers/barata.c52
-rw-r--r--src/mame/drivers/bfm_sc1.c2
-rw-r--r--src/mame/drivers/bfm_sc2.c8
-rw-r--r--src/mame/drivers/bfm_sc4.c2
-rw-r--r--src/mame/drivers/bfm_sc4h.c90
-rw-r--r--src/mame/drivers/bwidow.c2
-rw-r--r--src/mame/drivers/cps1.c2
-rw-r--r--src/mame/drivers/cultures.c2
-rw-r--r--src/mame/drivers/dreamwld.c74
-rw-r--r--src/mame/drivers/ecoinfr.c2
-rw-r--r--src/mame/drivers/f-32.c4
-rw-r--r--src/mame/drivers/galpani2.c24
-rw-r--r--src/mame/drivers/gts1.c1250
-rw-r--r--src/mame/drivers/gundealr.c2
-rw-r--r--src/mame/drivers/igs009.c50
-rw-r--r--src/mame/drivers/jpmimpct.c4
-rw-r--r--src/mame/drivers/lindbergh.c7
-rw-r--r--src/mame/drivers/maygay1b.c2
-rw-r--r--src/mame/drivers/mjkjidai.c2
-rw-r--r--src/mame/drivers/mpu3.c2
-rw-r--r--src/mame/drivers/mpu4hw.c46
-rw-r--r--src/mame/drivers/namcops2.c29
-rw-r--r--src/mame/drivers/relief.c4
-rw-r--r--src/mame/drivers/renegade.c8
-rw-r--r--src/mame/drivers/sbrkout.c6
-rw-r--r--src/mame/drivers/snowbros.c12
-rw-r--r--src/mame/drivers/taito_f3.c12
-rw-r--r--src/mame/drivers/tigeroad.c2
-rw-r--r--src/mame/drivers/viper.c56
-rw-r--r--src/mame/drivers/wallc.c6
-rw-r--r--src/mame/drivers/yunsun16.c12
-rw-r--r--src/mame/includes/asteroid.h6
-rw-r--r--src/mame/includes/bionicc.h2
-rw-r--r--src/mame/includes/galaxold.h24
-rw-r--r--src/mame/includes/renegade.h2
-rw-r--r--src/mame/includes/yunsun16.h2
-rw-r--r--src/mame/includes/zac2650.h4
-rw-r--r--src/mame/includes/zaccaria.h12
-rw-r--r--src/mame/machine/atarigen.c2
-rw-r--r--src/mame/mame.lst10
-rw-r--r--src/mame/video/chihiro.c74
-rw-r--r--src/mame/video/galpani2.c2
-rw-r--r--src/mame/video/segaic16.c2
-rw-r--r--src/mame/video/tigeroad.c1
-rw-r--r--src/mame/video/tigeroad_spr.c16
-rw-r--r--src/mame/video/zac2650.c2
-rw-r--r--src/mess/drivers/amaztron.c12
-rw-r--r--src/mess/drivers/bitgraph.c50
-rw-r--r--src/mess/drivers/cnsector.c22
-rw-r--r--src/mess/drivers/comp4.c14
-rw-r--r--src/mess/drivers/ec184x.c2
-rw-r--r--src/mess/drivers/excali64.c4
-rw-r--r--src/mess/drivers/gamate.c164
-rw-r--r--src/mess/drivers/hp16500.c13
-rw-r--r--src/mess/drivers/hp9k_3xx.c50
-rw-r--r--src/mess/drivers/intv.c6
-rw-r--r--src/mess/drivers/leapster.c5
-rw-r--r--src/mess/drivers/mathmagi.c8
-rw-r--r--src/mess/drivers/mc1502.c18
-rw-r--r--src/mess/drivers/megadriv.c4
-rw-r--r--src/mess/drivers/merlin.c12
-rw-r--r--src/mess/drivers/ngen.c38
-rw-r--r--src/mess/drivers/simon.c10
-rw-r--r--src/mess/drivers/starwbc.c28
-rw-r--r--src/mess/drivers/stopthie.c22
-rw-r--r--src/mess/drivers/tandy12.c16
-rw-r--r--src/mess/drivers/ticalc1x.c26
-rw-r--r--src/mess/drivers/tispeak.c14
-rw-r--r--src/mess/drivers/trs80.c46
-rw-r--r--src/mess/drivers/unk3403.c18
-rw-r--r--src/mess/drivers/victor9k.c10
-rw-r--r--src/mess/drivers/vt240.c26
-rw-r--r--src/mess/includes/victor9k.h2
-rw-r--r--src/mess/layout/starwbc.lay6
-rw-r--r--src/mess/machine/gamecom.c2
-rw-r--r--src/mess/machine/ngen_kb.c1
-rw-r--r--src/mess/machine/sms.c6
-rw-r--r--src/mess/machine/victor9k_fdc.c38
-rw-r--r--src/mess/machine/victor9kb.c4
-rw-r--r--src/mess/mess.mak2
-rw-r--r--src/mess/video/apple2.c2
-rw-r--r--src/mess/video/maria.c4
-rw-r--r--src/osd/modules/debugger/qt/debugqtdeviceswindow.c22
-rw-r--r--src/osd/modules/debugger/qt/debugqtdeviceswindow.h8
-rw-r--r--src/osd/sdl/input.c2
-rw-r--r--src/osd/sdl/video.h2
-rw-r--r--src/osd/sdl/window.c80
-rw-r--r--src/osd/sdl/window.h107
-rw-r--r--src/version.c2
156 files changed, 5284 insertions, 5363 deletions
diff --git a/hash/adam_cass.xml b/hash/adam_cass.xml
index 3c24878b189..c91254ece0c 100644
--- a/hash/adam_cass.xml
+++ b/hash/adam_cass.xml
@@ -968,29 +968,29 @@
</software>
<!--
- <software name="macadam">
- <description>MacADAM (Fra)</description>
- <year>1984</year>
- <publisher>CBS Loisors - Coleco of France</publisher>
-
- <part name="cass1" interface="adam_cass">
- <dataarea name="cass" size="262144">
- <rom name="macadam (1984) (cbs loisors - coleco of france).ddp" size="262144" crc="2fe95d33" sha1="e27e3515644c2fcd28b94b1aed69ae0b2cb76afc" offset="0" />
- </dataarea>
- </part>
- </software>
-
- <software name="macadama" cloneof="macadam">
- <description>MacADAM (Fra, Alt)</description>
- <year>1984</year>
- <publisher>CBS Loisors - Coleco of France</publisher>
-
- <part name="cass1" interface="adam_cass">
- <dataarea name="cass" size="262144">
- <rom name="macadam (1984) (cbs loisors - coleco of france) [a1].ddp" size="262144" crc="5288e332" sha1="4c1de35afefc356db7303f8f584946bbf0f7c528" offset="0" />
- </dataarea>
- </part>
- </software>
+ <software name="macadam">
+ <description>MacADAM (Fra)</description>
+ <year>1984</year>
+ <publisher>CBS Loisors - Coleco of France</publisher>
+
+ <part name="cass1" interface="adam_cass">
+ <dataarea name="cass" size="262144">
+ <rom name="macadam (1984) (cbs loisors - coleco of france).ddp" size="262144" crc="2fe95d33" sha1="e27e3515644c2fcd28b94b1aed69ae0b2cb76afc" offset="0" />
+ </dataarea>
+ </part>
+ </software>
+
+ <software name="macadama" cloneof="macadam">
+ <description>MacADAM (Fra, Alt)</description>
+ <year>1984</year>
+ <publisher>CBS Loisors - Coleco of France</publisher>
+
+ <part name="cass1" interface="adam_cass">
+ <dataarea name="cass" size="262144">
+ <rom name="macadam (1984) (cbs loisors - coleco of france) [a1].ddp" size="262144" crc="5288e332" sha1="4c1de35afefc356db7303f8f584946bbf0f7c528" offset="0" />
+ </dataarea>
+ </part>
+ </software>
-->
diff --git a/hash/adam_flop.xml b/hash/adam_flop.xml
index 499666fbf5e..b8b852f8642 100644
--- a/hash/adam_flop.xml
+++ b/hash/adam_flop.xml
@@ -2,14 +2,14 @@
<!DOCTYPE softwarelist SYSTEM "softwarelist.dtd">
<softwarelist name="adam_flop" description="Coleco ADAM diskettes">
- <!--
+ <!--
Thanks to SacNews.net for their very comprehensive software database!
-
+
TODO:
- Add rest of images outside of TOSEC/SacNews databases
- Proper testing for correct info? (current info is just copy-pasted from filenames)
+ Add rest of images outside of TOSEC/SacNews databases
+ Proper testing for correct info? (current info is just copy-pasted from filenames)
-->
-
+
<!-- EOS Drivers -->
<software name="homeauto">
@@ -841,11 +841,11 @@
<dataarea name="flop" size="163840">
<rom name="world geography (1985) (a-ware educational software) [a1].dsk" size="163840" crc="c7d26848" sha1="c9581253ac1de95bbb45092bf3aeaa932f4006d7" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<!-- EOS Games -->
-
+
<software name="2010">
<description>2010 - The Text Adventure Game</description>
<year>1984</year>
@@ -857,7 +857,7 @@
</dataarea>
</part>
</software>
-
+
<software name="2010a" cloneof="2010">
<description>2010 - The Text Adventure Game (Alt)</description>
<year>1984</year>
@@ -1083,7 +1083,7 @@
<dataarea name="flop" size="163840">
<rom name="adventure pack i (1984) (victory software) [a1].dsk" size="163840" crc="1754bbf4" sha1="a38a4ab0689917e66b3b6dda874f5a4f9ab9415a" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="advpak2v">
@@ -2409,24 +2409,24 @@
</part>
</software>
-<!-- From NIAD's blog:
+<!-- From NIAD's blog:
Jeopardy for the ADAM Computer is in fact a finshed product which was copyrighted 1984, but for whatever reason (probably
- completed just prior to Coleco's announcement in Jan. '85 that they were abandoning the ColecoVision and ADAM), Coleco
- decided not to release it commercially. They instead made it available to ADAM Users Groups circa 1985/1986 to share with
- the ADAM Community with the requirement that all copyright information would be removed from the program. Because of
- this requirement by Coleco, you will see multiple versions of Jeopardy available for download that have been hacked to
- change two title screens. This hacking actually eliminated the first title screen and then replaced the copyright information on
+ completed just prior to Coleco's announcement in Jan. '85 that they were abandoning the ColecoVision and ADAM), Coleco
+ decided not to release it commercially. They instead made it available to ADAM Users Groups circa 1985/1986 to share with
+ the ADAM Community with the requirement that all copyright information would be removed from the program. Because of
+ this requirement by Coleco, you will see multiple versions of Jeopardy available for download that have been hacked to
+ change two title screens. This hacking actually eliminated the first title screen and then replaced the copyright information on
the second.
- When the original Jeopardy program was copied from data pack (256K max size) to disk (160K max size) a portion of the
- program that contained game play data/questions was lost to the ages. This disk version which floated around for a while
- would eventually crash due to the missing data, but this was later patched by Walters Software Co.'s Jim Walters to recycle to
+ When the original Jeopardy program was copied from data pack (256K max size) to disk (160K max size) a portion of the
+ program that contained game play data/questions was lost to the ages. This disk version which floated around for a while
+ would eventually crash due to the missing data, but this was later patched by Walters Software Co.'s Jim Walters to recycle to
the beginning of the questions.
- In 1992, a member of NIAD had the tremendous fortune to come in contact with a former Coleco employee who was looking
- to sell off his entire lot of ADAM gear... a number of never before seen hardware and software protos included. In this lot was
- [...] a 2-disk version of Jeopardy. I have not tested this 2-disk version thoroughly, but it does seem to work properly and
- should be the version that you use as more than likely it is the complete version that would have been released for
- commercial sale.
+ In 1992, a member of NIAD had the tremendous fortune to come in contact with a former Coleco employee who was looking
+ to sell off his entire lot of ADAM gear... a number of never before seen hardware and software protos included. In this lot was
+ [...] a 2-disk version of Jeopardy. I have not tested this 2-disk version thoroughly, but it does seem to work properly and
+ should be the version that you use as more than likely it is the complete version that would have been released for
+ commercial sale.
-->
<software name="jeopardy">
@@ -3195,7 +3195,7 @@
<dataarea name="flop" size="163840">
<rom name="robothief (1991) (steve pitman software) [a1].dsk" size="163840" crc="8df50a33" sha1="69fde2a68c6c22ae268a209bc9054f6e7206c541" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="rubychal">
@@ -3450,12 +3450,12 @@
</part>
</software>
-<!-- From NIAD's blog:
- The original prototype/demo/unreleased version as was obtained from Epyx was indeed buggy, but this mainly dealt with the
- inability to get it working on a disk, it was originally supplied on data pack, the save feature was a mess and there were a
- number of menu (especially at the start of the game) that were messed up. A programmer by the name of Joe Waters spent
- considerable time fixing these issues or most of them to get it to the state we now know. He actually lived in Albuquerque and
- released software for the ADAM under the Federation Software label and did the Temple hack and some others under the
+<!-- From NIAD's blog:
+ The original prototype/demo/unreleased version as was obtained from Epyx was indeed buggy, but this mainly dealt with the
+ inability to get it working on a disk, it was originally supplied on data pack, the save feature was a mess and there were a
+ number of menu (especially at the start of the game) that were messed up. A programmer by the name of Joe Waters spent
+ considerable time fixing these issues or most of them to get it to the state we now know. He actually lived in Albuquerque and
+ released software for the ADAM under the Federation Software label and did the Temple hack and some others under the
Falcon Federation Hack Group (or something like that) label.
-->
<software name="apshai">
@@ -4000,7 +4000,7 @@
</software>
<!-- EOS Graphics Design -->
-
+
<software name="adamgfx">
<description>ADAM Graphics</description>
<year>199?</year>
@@ -5421,7 +5421,7 @@
</software>
<!-- EOS Productivity -->
-
+
<software name="atgradeb">
<description>A-Tech Gradebook</description>
<year>198?</year>
@@ -5433,7 +5433,7 @@
</dataarea>
</part>
</software>
-
+
<software name="atgradeba" cloneof="atgradeb">
<description>A-Tech Gradebook (Alt)</description>
<year>198?</year>
@@ -5467,7 +5467,7 @@
<dataarea name="flop" size="163840">
<rom name="adam agenda - the personal schedule keeper (198x) (jeff harris) [a1].dsk" size="163840" crc="057fd444" sha1="21b76438a43a4e19a1b996789f2073cf25654a19" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="fbanalyz">
@@ -7231,7 +7231,7 @@
<!-- EOS Programming -->
-
+
<software name="adambas">
<description>ADAM Basic (v1.6)</description>
<year>198?</year>
@@ -7842,7 +7842,7 @@
</dataarea>
</part>
</software>
-
+
<software name="smartlog">
<description>SmartLOGO</description>
<year>1984</year>
@@ -7854,7 +7854,7 @@
</dataarea>
</part>
</software>
-
+
<software name="smartloga" cloneof="smartlog">
<description>SmartLOGO (Alt)</description>
<year>1984</year>
@@ -7866,7 +7866,7 @@
</dataarea>
</part>
</software>
-
+
<software name="smartlogb" cloneof="smartlog">
<description>SmartLOGO (Alt 2)</description>
<year>1984</year>
@@ -8015,7 +8015,7 @@
</dataarea>
</part>
</software>
-
+
<software name="anetdata">
<description>A-Net ADAM BBS - Data Files</description>
<year>1990</year>
@@ -9816,7 +9816,7 @@
<dataarea name="flop" size="163840">
<rom name="turbodisk v1.0 (1987) (digital express inc.) [a1].dsk" size="163840" crc="bf60a7bb" sha1="ca04851345a882589f1b8d97b11df1643ad4e947" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="turbload">
@@ -9936,7 +9936,7 @@
<dataarea name="flop" size="163840">
<rom name="xrampak i (1987) (digital express inc.) [a1].dsk" size="163840" crc="dc40400b" sha1="aeebdcf76d6fd369fe1720b0a57a48089ac8e050" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<!-- EOS Public Domain - ADAMLand -->
@@ -9966,7 +9966,7 @@
</software>
<!-- EOS Public Domain - ADAM Users Group -->
-
+
<software name="augutils">
<description>A.U.G. - Utilities</description>
<year>198?</year>
@@ -12328,7 +12328,7 @@
</software>
<!-- EOS Public Domain - Nibbles & Bits -->
-
+
<software name="nbbas01">
<description>N&amp;B - Basic Vol. #01</description>
<year>198?</year>
@@ -13582,7 +13582,7 @@
</software>
<!-- EOS Public Domain - Puget Sound ADAM Network -->
-
+
<software name="psanutil">
<description>P.S.A.N. - Utilities</description>
<year>198?</year>
@@ -13807,7 +13807,7 @@
</software>
<!-- CP/M Drivers -->
-
+
<software name="evecpm">
<description>EVE CP/M Utilities</description>
<year>198?</year>
@@ -13846,7 +13846,7 @@
<!-- CP/M Games -->
-<!-- This is a collection of Scott Adams' adventures -->
+<!-- This is a collection of Scott Adams' adventures -->
<software name="adventur">
<description>Adventure (Scott Adams)</description>
<year>198?</year>
@@ -14269,7 +14269,7 @@
</software>
<!-- CP/M Public Domain - Misc -->
-
+
<software name="cpmpd01">
<description>CP-M 2.2 or T-DOS P.D. Vol. #01</description>
<year>198?</year>
@@ -14331,7 +14331,7 @@
</software>
<!-- CP/M Public Domain - Northern Illiana ADAM User's Group -->
-
+
<software name="cndv01">
<description>N.I.A.D. - CP/M CNDV #01</description>
<year>198?</year>
@@ -15111,7 +15111,7 @@
</software>
<!-- CP/M PrintMaster Artwork -->
-
+
<software name="printm01">
<description>PrintMaster Artwork - ADAMGR01</description>
<year>198?</year>
@@ -15869,7 +15869,7 @@
</software>
<!-- CP/M Productivity -->
-
+
<software name="abovepls">
<description>Above Plus</description>
<year>198?</year>
@@ -16046,7 +16046,7 @@
</software>
<!-- CP/M Programming -->
-
+
<software name="dazzstar">
<description>DazzleStar Disassembler</description>
<year>1986</year>
@@ -16194,7 +16194,7 @@
</software>
<!-- CP/M Utilities -->
-
+
<software name="1kutils">
<description>1K Utilities</description>
<year>198?</year>
@@ -16256,7 +16256,7 @@
</software>
<!-- ADAM News Network -->
-
+
<software name="ann9103">
<description>ANN Disk - 1991-03 - E.O.S. Files</description>
<year>1991</year>
diff --git a/hash/apollo_ctape.xml b/hash/apollo_ctape.xml
index ee259d2b5f5..5e8f00a59d0 100644
--- a/hash/apollo_ctape.xml
+++ b/hash/apollo_ctape.xml
@@ -3,8 +3,8 @@
<!-- Domain/OS Known Undumped Versions (from http://www.hpmuseum.net/exhibit.php?swc=24)
- Domain/OS SR10.3 (1990) Product Number 018847 + 018848
- Domain/OS Quarterly PSK Q3-91 SR10.3 (1991) Product Number 19437 + 19439
+ Domain/OS SR10.3 (1990) Product Number 018847 + 018848
+ Domain/OS Quarterly PSK Q3-91 SR10.3 (1991) Product Number 19437 + 19439
-->
diff --git a/hash/archimedes.xml b/hash/archimedes.xml
index c9b8a888e71..136b7aa7a9c 100644
--- a/hash/archimedes.xml
+++ b/hash/archimedes.xml
@@ -786,7 +786,7 @@ Zelanites: The Onslaught by Micro Power (RiscOS2)
<dataarea name="flop" size="819200">
<rom name="enigma (1993)(archimedes world)[a].adf" size="819200" crc="9277d658" sha1="2bdd2d1f53ee5f359f12adb8b20e915d12978de0" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="enigmab" cloneof="enigma" supported="no">
@@ -1075,7 +1075,7 @@ Zelanites: The Onslaught by Micro Power (RiscOS2)
<dataarea name="flop" size="819200">
<rom name="mad professor mariarti (1990)(krisalis)[a].adf" size="819200" crc="020e0e93" sha1="e64f832705c6923edcec7e85df4cceafe30b817e" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="mariartib" cloneof="mariarti" supported="no">
@@ -1504,7 +1504,7 @@ Zelanites: The Onslaught by Micro Power (RiscOS2)
<dataarea name="flop" size="819200">
<rom name="super pool (1991)(fourth dimension)[a].adf" size="819200" crc="8fa28978" sha1="10d451076f38ab48e4b9bd754fdcb4c634935c36" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="suprpoolb" cloneof="suprpool" supported="no">
@@ -1769,7 +1769,7 @@ Zelanites: The Onslaught by Micro Power (RiscOS2)
</dataarea>
</part>
</software>
-
+
<!-- Other disks to sort (homebrew?!?) -->
@@ -2001,7 +2001,7 @@ Zelanites: The Onslaught by Micro Power (RiscOS2)
<dataarea name="flop" size="819200">
<rom name="hacker, the v3.05 (1993)(doggysoft)[a].adf" size="819200" crc="c6a88514" sha1="b02d6495f6a9a1099cb06cac7d0e0d1756f175a0" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="hackerb" cloneof="hacker" supported="no">
@@ -2213,7 +2213,7 @@ Zelanites: The Onslaught by Micro Power (RiscOS2)
<dataarea name="flop" size="820224">
<rom name="acorn archimedes risc os application suite v1.00 (19xx)(acorn)(disk 2 of 2)[req risc os].adf" size="820224" crc="d5fdf2ca" sha1="bfc96eff8cab5b61f6db82dd135dd95b32f40d4f" offset="0" />
</dataarea>
- </part>
+ </part>
</software>
<software name="riscappsa" cloneof="riscapps" supported="no">
diff --git a/hash/gamate.xml b/hash/gamate.xml
index ddc2ca7269f..3d104772978 100644
--- a/hash/gamate.xml
+++ b/hash/gamate.xml
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!DOCTYPE softwarelist SYSTEM "softwarelist.dtd">
-<!--
+<!--
Undumped carts, based on Wikipedia list
C1010 - Bump N' Run (Unreleased?)
C1016 - Volcano Panic
diff --git a/hash/mtx_cass.xml b/hash/mtx_cass.xml
index c87e00e114f..1a8bfb66465 100644
--- a/hash/mtx_cass.xml
+++ b/hash/mtx_cass.xml
@@ -3,7 +3,7 @@
<softwarelist name="mtx_cass" description="Memotech MTX cassettes">
-<!--
+<!--
TODO: find out why the driver does not recognize the program on the tapes...
-->
diff --git a/hash/n64.xml b/hash/n64.xml
index b957e352fe0..2b591f8e46a 100644
--- a/hash/n64.xml
+++ b/hash/n64.xml
@@ -3109,8 +3109,8 @@ Info on N64 chip labels (from The Cart Scan Repository)
<!--
Note from marshallh about the dongle present in the Rare proto/demo above
"The dongle is a pass-through, except that there is an Altera
-MAX7000 series CPLD intercepting the AD16 bus. This lets
-all normal bus transactions through, but in the special case
+MAX7000 series CPLD intercepting the AD16 bus. This lets
+all normal bus transactions through, but in the special case
mentioned below, takes control of the bus and gives its own data."
We currently don't emulate this, and thus we include also versions where the dongle checks have been
diff --git a/hash/neogeo.xml b/hash/neogeo.xml
index e8466e18169..ef68e42aa33 100644
--- a/hash/neogeo.xml
+++ b/hash/neogeo.xml
@@ -438,7 +438,7 @@
<dataarea name="mcu" size="0x2000">
<!-- Hitachi HD6301V1 MCU -->
<rom offset="0x000000" size="0x02000" name="rhcom.bin" crc="e5cd6306" sha1="f6bbb8ae562804d67e137290c765c3589fa334c0" />
- <!-- dumped from a prototype with external ROM, not 100% confirmed as being the same on a final, or other games (lbowling, trally) -->
+ <!-- dumped from a prototype with external ROM, not 100% confirmed as being the same on a final, or other games (lbowling, trally) -->
</dataarea>
<dataarea name="fixed" size="0x040000">
<rom offset="0x000000" size="0x020000" name="006-s1.s1" crc="eb5189f0" sha1="0239c342ea62e73140a2306052f226226461a478" />
@@ -491,7 +491,7 @@
<dataarea name="mcu" size="0x2000">
<!-- Hitachi HD6301V1 MCU -->
<rom offset="0x000000" size="0x02000" name="rhcom.bin" crc="e5cd6306" sha1="f6bbb8ae562804d67e137290c765c3589fa334c0" />
- <!-- dumped from a prototype with external ROM, not 100% confirmed as being the same on a final, or other games (lbowling, trally) -->
+ <!-- dumped from a prototype with external ROM, not 100% confirmed as being the same on a final, or other games (lbowling, trally) -->
</dataarea>
<dataarea name="fixed" size="0x040000">
<rom offset="0x000000" size="0x020000" name="006-s1.s1" crc="eb5189f0" sha1="0239c342ea62e73140a2306052f226226461a478" />
diff --git a/hash/nes.xml b/hash/nes.xml
index 8fc6e847686..fedefc1e288 100644
--- a/hash/nes.xml
+++ b/hash/nes.xml
@@ -76632,7 +76632,7 @@ be better to redump them properly. -->
<year>19??</year>
<publisher>&lt;pirate&gt;</publisher>
<part name="cart" interface="nes_cart">
- <feature name="slot" value="bmc_hik300" /> <!-- mapper says 217 but it's not gc6in1 either! -->
+ <feature name="slot" value="bmc_hik300" /> <!-- mapper says 217 but it's not gc6in1 either! -->
<dataarea name="chr" size="65536">
<rom name="500-in-1 (anim splash, no rev, alt mapper)[p1][!].chr" size="65536" crc="25bdd64a" sha1="1f95eaf20fec9058b6917aa47dbdcec4b7a5b87d" offset="00000" status="baddump" />
</dataarea>
@@ -76647,7 +76647,7 @@ be better to redump them properly. -->
<year>19??</year>
<publisher>&lt;pirate&gt;</publisher>
<part name="cart" interface="nes_cart">
- <feature name="slot" value="bmc_hik300" /> <!-- mapper says 217 but it's not gc6in1 either! -->
+ <feature name="slot" value="bmc_hik300" /> <!-- mapper says 217 but it's not gc6in1 either! -->
<dataarea name="chr" size="65536">
<rom name="500-in-1 (static splash, no rev, alt mapper)[p1][!].chr" size="65536" crc="e7dacb8a" sha1="ece1b9c7fd8be955a1df6c8505533b4fac194eeb" offset="00000" status="baddump" />
</dataarea>
@@ -77576,7 +77576,7 @@ be better to redump them properly. -->
<year>19??</year>
<publisher>&lt;pirate&gt;</publisher>
<part name="cart" interface="nes_cart">
- <feature name="slot" value="bmc_hik300" /> <!-- mapper says 217 but it's not gc6in1 either! -->
+ <feature name="slot" value="bmc_hik300" /> <!-- mapper says 217 but it's not gc6in1 either! -->
<dataarea name="chr" size="65536">
<rom name="9999999-in-1 (static splash, no rev, alt mapper)[p1][!].chr" size="65536" crc="25bdd64a" sha1="1f95eaf20fec9058b6917aa47dbdcec4b7a5b87d" offset="00000" status="baddump" />
</dataarea>
diff --git a/hash/pico.xml b/hash/pico.xml
index a2105560669..0968d286fe0 100644
--- a/hash/pico.xml
+++ b/hash/pico.xml
@@ -736,7 +736,7 @@ Published by Others (T-yyy*** serial codes, for yyy depending on the publisher)
<publisher>Samsung</publisher>
<info name="serial" value="T-102021-08 ~ PICO-9507S"/>
<part name="cart" interface="pico_cart">
- <feature name="pcb" value="??" /> <!-- non-Sega PCB, probably by Samsung -->
+ <feature name="pcb" value="??" /> <!-- non-Sega PCB, probably by Samsung -->
<feature name="ic1" value="PICO-9507S" />
<dataarea name="rom" size="524288">
<rom name="pico-9507s.ic1" size="524288" crc="042520ce" sha1="5dd748a1bdfc661d0b96f6a1d26babc6a0ae7f2d" offset="000000" loadflag="load16_word_swap" />
diff --git a/hash/sms.xml b/hash/sms.xml
index 9b36eac1d13..b1a5020995f 100644
--- a/hash/sms.xml
+++ b/hash/sms.xml
@@ -868,9 +868,9 @@
</software>
<!--
- The labelling of Hi-Com multigame carts is arbitrary. The boxes appears to what was intended as unique product number
- but boxes are typically mixed up and patched with stickers added to change game titles (on both boxes and cartridges)
- making the product number rather unreliable AND realistically we may never find out the correct numbers.
+ The labelling of Hi-Com multigame carts is arbitrary. The boxes appears to what was intended as unique product number
+ but boxes are typically mixed up and patched with stickers added to change game titles (on both boxes and cartridges)
+ making the product number rather unreliable AND realistically we may never find out the correct numbers.
-->
<software name="hicom3a">
<description>The Best Game Collection - Hang On + Pit Pot + Spy vs Spy (Kor)</description>
diff --git a/hash/vz_cass.xml b/hash/vz_cass.xml
index bc5d71bf683..9274980f6b2 100644
--- a/hash/vz_cass.xml
+++ b/hash/vz_cass.xml
@@ -5,67 +5,67 @@
List of known tape releases by Dick Smith in Australia:
-X-7274 Attack of the Killer Tomatoes
-X-7231 Match Box
-X-7232 Poker
-X-7233 Hangman
-X-7234 Slot Machine/Knock Off/Russian Roulette
-X-7235 Blackjack
-X-7236 Circus (*)
-X-7237 Biorhythm/Pair Matching/Calendar
-X-7238 Horse Race
-X-7239 Invaders (*)
-X-7240 Dynasty Derby
-X-7241 Learjet
-X-7242 Ghost Hunter (*)
-X-7243 Hoppy (*)
-X-7244 Super Snake
-X-7245 Knights and Dragons
-X-7247 Star Blaster (*)
-X-7248 VZ-Asteroids
-X-7249 Air Traffic Controller
-X-7250 Lunar Lander
-X-7251 Statistics 1
-X-7252 Statistics 2
-X-7253 Matrix
-X-7254 Tennis Lesson/Golf Lesson
-X-7255 Introduction to BASIC
-X-7256 Elementary Geometry
-X-7257 Speed Reading
-X-7258 Typing Teacher
-X-7259 Mailing List
-X-7261 Portfolio Management
-X-7262 Discounted Cash Flow Analysis
-X-7263 Financial Ratio Analysis
-X-7264 Tennis (*)
-X-7265 Checkers
-X-7266 Planet Patrol (*)
-X-7268 Ladder Challenge (*)
-X-7270 Panik (*)
-X-7271 Othello
-X-7272 Dracula's Castle
-X-7273 Backgammon
-X-7275 VZ Chess (*)
-X-7276 Music Writer
-X-7278 Disassembler
-X-7279 Duel
-X-7280 Hex Utilities
-X-7281 Word Processor
-X-7282 Editor Assembler
-X-7285 Spell'O'Matic 1 & 2
-X-7286 Spell'O'Matic 3 & 4
-X-7287 Flashword 1 & 2
-X-7288 Flashword 3 & 4
-X-7289 Metric Spycatcher
-X-7290 Whizkid Spycatcher
-X-7330 Sprite Generator
-X-7331 Formula One
-X-7332 Galaxon (*)
-X-7333 Dawn Patrol (*)
-X-7339 Space RAM
-X-7342 Crash
-X-7344 Maze of Argon
-X-7345 Word Matching
+X-7274 Attack of the Killer Tomatoes
+X-7231 Match Box
+X-7232 Poker
+X-7233 Hangman
+X-7234 Slot Machine/Knock Off/Russian Roulette
+X-7235 Blackjack
+X-7236 Circus (*)
+X-7237 Biorhythm/Pair Matching/Calendar
+X-7238 Horse Race
+X-7239 Invaders (*)
+X-7240 Dynasty Derby
+X-7241 Learjet
+X-7242 Ghost Hunter (*)
+X-7243 Hoppy (*)
+X-7244 Super Snake
+X-7245 Knights and Dragons
+X-7247 Star Blaster (*)
+X-7248 VZ-Asteroids
+X-7249 Air Traffic Controller
+X-7250 Lunar Lander
+X-7251 Statistics 1
+X-7252 Statistics 2
+X-7253 Matrix
+X-7254 Tennis Lesson/Golf Lesson
+X-7255 Introduction to BASIC
+X-7256 Elementary Geometry
+X-7257 Speed Reading
+X-7258 Typing Teacher
+X-7259 Mailing List
+X-7261 Portfolio Management
+X-7262 Discounted Cash Flow Analysis
+X-7263 Financial Ratio Analysis
+X-7264 Tennis (*)
+X-7265 Checkers
+X-7266 Planet Patrol (*)
+X-7268 Ladder Challenge (*)
+X-7270 Panik (*)
+X-7271 Othello
+X-7272 Dracula's Castle
+X-7273 Backgammon
+X-7275 VZ Chess (*)
+X-7276 Music Writer
+X-7278 Disassembler
+X-7279 Duel
+X-7280 Hex Utilities
+X-7281 Word Processor
+X-7282 Editor Assembler
+X-7285 Spell'O'Matic 1 & 2
+X-7286 Spell'O'Matic 3 & 4
+X-7287 Flashword 1 & 2
+X-7288 Flashword 3 & 4
+X-7289 Metric Spycatcher
+X-7290 Whizkid Spycatcher
+X-7330 Sprite Generator
+X-7331 Formula One
+X-7332 Galaxon (*)
+X-7333 Dawn Patrol (*)
+X-7339 Space RAM
+X-7342 Crash
+X-7344 Maze of Argon
+X-7345 Word Matching
* = dumped
diff --git a/src/emu/bus/centronics/epson_lx810l.c b/src/emu/bus/centronics/epson_lx810l.c
index 0b56ca128cc..933eef5cee4 100644
--- a/src/emu/bus/centronics/epson_lx810l.c
+++ b/src/emu/bus/centronics/epson_lx810l.c
@@ -176,7 +176,7 @@ static MACHINE_CONFIG_FRAGMENT( epson_lx810l )
MCFG_STEPPER_END_INDEX(24)
MCFG_STEPPER_INDEX_PATTERN(0x00)
MCFG_STEPPER_INIT_PHASE(2)
-
+
MACHINE_CONFIG_END
//-------------------------------------------------
@@ -345,7 +345,6 @@ epson_ap2000_t::epson_ap2000_t(const machine_config &mconfig, const char *tag, d
void epson_lx810l_t::device_start()
{
-
}
diff --git a/src/emu/bus/ieee488/c8050fdc.c b/src/emu/bus/ieee488/c8050fdc.c
index 421b2f3c4ea..0a619b7ab71 100644
--- a/src/emu/bus/ieee488/c8050fdc.c
+++ b/src/emu/bus/ieee488/c8050fdc.c
@@ -20,10 +20,10 @@
#define LOG 1
#define GCR_DECODE(_e, _i) \
- ((BIT(_e, 6) << 7) | (BIT(_i, 7) << 6) | (_e & 0x33) | (BIT(_e, 2) << 3) | (_i & 0x04))
+ ((BIT(_e, 6) << 7) | (BIT(_i, 7) << 6) | (_e & 0x33) | (BIT(_e, 2) << 3) | (_i & 0x04))
#define GCR_ENCODE(_e, _i) \
- ((_e & 0xc0) << 2 | (_i & 0x80) | (_e & 0x3c) << 1 | (_i & 0x04) | (_e & 0x03))
+ ((_e & 0xc0) << 2 | (_i & 0x80) | (_e & 0x3c) << 1 | (_i & 0x04) | (_e & 0x03))
diff --git a/src/emu/bus/isa/cga.c b/src/emu/bus/isa/cga.c
index cd47e1a1f3f..b894632d715 100644
--- a/src/emu/bus/isa/cga.c
+++ b/src/emu/bus/isa/cga.c
@@ -365,7 +365,7 @@ void isa8_cga_device::device_start()
astring tempstring;
m_chr_gen_base = memregion(subtag(tempstring, "gfx1"))->base();
m_chr_gen = m_chr_gen_base + m_chr_gen_offset[1];
-
+
save_item(NAME(m_framecnt));
save_item(NAME(m_mode_control));
save_item(NAME(m_color_select));
@@ -374,7 +374,7 @@ void isa8_cga_device::device_start()
save_item(NAME(m_vsync));
save_item(NAME(m_hsync));
save_item(NAME(m_vram));
- save_item(NAME(m_plantronics));
+ save_item(NAME(m_plantronics));
}
diff --git a/src/emu/bus/isa/sc499.h b/src/emu/bus/isa/sc499.h
index eeda9ad1a4a..2db4b28e4c7 100644
--- a/src/emu/bus/isa/sc499.h
+++ b/src/emu/bus/isa/sc499.h
@@ -28,13 +28,13 @@ class sc499_ctape_image_device : public device_t, public device_image_interface
public:
// construction/destruction
sc499_ctape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
-
+
// image-level overrides
virtual bool call_load();
virtual bool call_softlist_load(software_list_device &swlist, const char *swname, const rom_entry *start_entry) { return load_software(swlist, swname, start_entry); }
virtual void call_unload();
virtual iodevice_t image_type() const { return IO_MAGTAPE; }
-
+
virtual bool is_readable() const { return 1; }
virtual bool is_writeable() const { return 1; }
virtual bool is_creatable() const { return 1; }
diff --git a/src/emu/bus/sega8/rom.c b/src/emu/bus/sega8/rom.c
index ce15d0429fc..33ebe932e07 100644
--- a/src/emu/bus/sega8/rom.c
+++ b/src/emu/bus/sega8/rom.c
@@ -899,17 +899,17 @@ WRITE8_MEMBER(sega8_janggun_device::write_mapper)
/*-------------------------------------------------
-
+
Hi-Com X-in-1 cart, uses writes to 0xffff to
change program bank in 0x0000-0x7fff
-
+
-------------------------------------------------*/
READ8_MEMBER(sega8_hicom_device::read_cart)
{
if (offset >= 0x8000)
return m_rom[offset & 0x3fff];
-
+
return m_rom[(m_rom_bank_base * 0x8000) + offset];
}
diff --git a/src/emu/bus/sega8/rom.h b/src/emu/bus/sega8/rom.h
index 8b7336864e1..be540fc1efb 100644
--- a/src/emu/bus/sega8/rom.h
+++ b/src/emu/bus/sega8/rom.h
@@ -318,17 +318,17 @@ class sega8_hicom_device : public sega8_rom_device
public:
// construction/destruction
sega8_hicom_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
-
+
// device-level overrides
virtual void device_start() { save_item(NAME(m_rom_bank_base)); }
-
+
virtual void late_bank_setup();
-
+
// reading and writing
virtual DECLARE_READ8_MEMBER(read_cart);
virtual DECLARE_WRITE8_MEMBER(write_cart) {}
virtual DECLARE_WRITE8_MEMBER(write_mapper);
-
+
protected:
UINT8 m_rom_bank_base;
};
diff --git a/src/emu/cpu/arc/arc.c b/src/emu/cpu/arc/arc.c
index 4bc688ce92d..86337afa966 100644
--- a/src/emu/cpu/arc/arc.c
+++ b/src/emu/cpu/arc/arc.c
@@ -99,7 +99,6 @@ void arc_device::device_reset()
void arc_device::execute_set_input(int irqline, int state)
{
-
}
diff --git a/src/emu/cpu/arc/arcdasm.c b/src/emu/cpu/arc/arcdasm.c
index b1fa5d442b1..e5381db23c0 100644
--- a/src/emu/cpu/arc/arcdasm.c
+++ b/src/emu/cpu/arc/arcdasm.c
@@ -68,7 +68,7 @@ static const char *conditions[0x20] =
/* 03 */ "PL", // (aka P - Positive)
/* 04 */ "MI", // (aka N - Negative)
/* 05 */ "CS", // (aka C, LO - Carry set / Lower than) (unsigned)
- /* 06 */ "CC", // (aka CC, NC, HS - Carry Clear / Higher or Same) (unsigned)
+ /* 06 */ "CC", // (aka CC, NC, HS - Carry Clear / Higher or Same) (unsigned)
/* 07 */ "VS", // (aka V - Overflow set)
/* 08 */ "VC", // (aka NV - Overflow clear)
/* 09 */ "GT", // ( - Greater than) (signed)
@@ -204,7 +204,7 @@ CPU_DISASSEMBLE(arc)
case 0x05: // BL
print("%s(%s)(%s) %08x", basic[opcode], conditions[ARC_CONDITION], delaytype[ARC_BRANCH_DELAY], (ARC_BRANCH_ADDR<<2)+pc+4);
break;
-
+
case 0x08: // ADD
// todo, short / long immediate formats
print("%s %s , %s , %s (%08x)", basic[opcode], regnames[ARC_REGOP_DEST], regnames[ARC_REGOP_OP1], regnames[ARC_REGOP_OP2], op &~ 0xfffffe00);
diff --git a/src/emu/cpu/arcompact/arcompact.c b/src/emu/cpu/arcompact/arcompact.c
index 4f229f7a291..5527830be1b 100644
--- a/src/emu/cpu/arcompact/arcompact.c
+++ b/src/emu/cpu/arcompact/arcompact.c
@@ -164,9 +164,8 @@ void arcompact_device::device_reset()
/*****************************************************************************/
-
+
void arcompact_device::execute_set_input(int irqline, int state)
{
-
}
diff --git a/src/emu/cpu/arcompact/arcompact.h b/src/emu/cpu/arcompact/arcompact.h
index 4bf491daf00..1b901fb6950 100644
--- a/src/emu/cpu/arcompact/arcompact.h
+++ b/src/emu/cpu/arcompact/arcompact.h
@@ -21,16 +21,15 @@
ARCOMPACT_RETTYPE arcompact_handle##name##_p11(OPS_32) \
{ \
int M = (op & 0x00000020) >> 5; \
- \
+ \
switch (M) \
{ \
case 0x00: return arcompact_handle##name##_p11_m0(PARAMS); \
case 0x01: return arcompact_handle##name##_p11_m1(PARAMS); \
} \
- \
+ \
return 0; \
-}; \
-
+};
#define ARCOMPACT_HANDLER04_TYPE(name) \
ARCOMPACT_RETTYPE arcompact_handle##name(OPS_32) \
{ \
@@ -45,8 +44,7 @@ ARCOMPACT_RETTYPE arcompact_handle##name(OPS_32) \
} \
\
return 0; \
-}; \
-
+};
#define ARCOMPACT_HANDLER04_TYPE_PM(name) \
ARCOMPACT_RETTYPE arcompact_handle##name##_p00(OPS_32); \
@@ -55,8 +53,7 @@ ARCOMPACT_RETTYPE arcompact_handle##name(OPS_32) \
ARCOMPACT_RETTYPE arcompact_handle##name##_p11_m0(OPS_32); \
ARCOMPACT_RETTYPE arcompact_handle##name##_p11_m1(OPS_32); \
ARCOMPACT_HANDLER04_P11_TYPE(name); \
- ARCOMPACT_HANDLER04_TYPE(name); \
-
+ ARCOMPACT_HANDLER04_TYPE(name);
class arcompact_device : public cpu_device
{
@@ -146,53 +143,53 @@ protected:
ARCOMPACT_RETTYPE arcompact_handle01_01_01_0f(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle02(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle03(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_00(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_00(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_01(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_02(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_02(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_03(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_04(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_05(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_06(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_07(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_04(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_05(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_06(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_07(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_08(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_09(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_0a(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_0a(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_0b(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_0c(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_0d(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_0e(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_0f(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_0e(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_0f(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_10(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_11(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_12(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_13(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_14(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_15(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_16(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_17(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_18(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_19(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_13(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_14(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_15(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_16(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_17(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_18(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_19(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_1a(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_1b(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_1c(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_1d(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_20(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_20(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_21(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_22(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_23(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_28(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_29(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2a(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_2b(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_2b(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_00(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_01(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_2f_02(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_2f_02(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_03(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_04(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_05(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_06(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_2f_07(OPS_32);
-// ARCOMPACT_RETTYPE arcompact_handle04_2f_08(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_2f_07(OPS_32);
+// ARCOMPACT_RETTYPE arcompact_handle04_2f_08(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_09(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_0a(OPS_32);
ARCOMPACT_RETTYPE arcompact_handle04_2f_0b(OPS_32);
@@ -779,9 +776,9 @@ protected:
ARCOMPACT_HANDLER04_TYPE_PM(04_14);
ARCOMPACT_HANDLER04_TYPE_PM(04_15);
ARCOMPACT_HANDLER04_TYPE_PM(04_16);
- ARCOMPACT_HANDLER04_TYPE_PM(04_17);
+ ARCOMPACT_HANDLER04_TYPE_PM(04_17);
ARCOMPACT_HANDLER04_TYPE_PM(04_18);
- ARCOMPACT_HANDLER04_TYPE_PM(04_19);
+ ARCOMPACT_HANDLER04_TYPE_PM(04_19);
ARCOMPACT_HANDLER04_TYPE_PM(04_20);
ARCOMPACT_HANDLER04_TYPE_PM(04_2b);
@@ -811,10 +808,10 @@ private:
inline UINT32 READ32(UINT32 address) { return m_program->read_dword(address << 2); }
inline void WRITE32(UINT32 address, UINT32 data) { m_program->write_dword(address << 2, data); }
inline UINT16 READ16(UINT32 address) { return m_program->read_word(address << 1); }
- inline void WRITE16(UINT32 address, UINT16 data){ m_program->write_word(address << 1, data); }
+ inline void WRITE16(UINT32 address, UINT16 data){ m_program->write_word(address << 1, data); }
inline UINT8 READ8(UINT32 address) { return m_program->read_byte(address << 0); }
- inline void WRITE8(UINT32 address, UINT8 data){ m_program->write_byte(address << 0, data); }
-
+ inline void WRITE8(UINT32 address, UINT8 data){ m_program->write_byte(address << 0, data); }
+
inline UINT64 READAUX(UINT64 address) { return m_io->read_dword(address *4); }
inline void WRITEAUX(UINT64 address, UINT32 data) { m_io->write_dword(address *4, data); }
@@ -827,7 +824,7 @@ private:
int m_delaylinks;
UINT32 m_delayjump;
-// f e d c| b a 9 8| 7 6 5 4| 3 2 1 0
+// f e d c| b a 9 8| 7 6 5 4| 3 2 1 0
// - - - L| Z N C V| U DE AE A2|A1 E2 E1 H
UINT32 m_status32;
@@ -862,7 +859,7 @@ private:
#define STATUS32_CHECK_Z (m_status32 & Z_ZERO_FLAG)
// Condition 0x0c (LE)
-#define CONDITION_LE ((STATUS32_CHECK_Z) || (STATUS32_CHECK_N && !STATUS32_CHECK_V) || (!STATUS32_CHECK_N && STATUS32_CHECK_V)) // Z or (N and /V) or (/N and V)
+#define CONDITION_LE ((STATUS32_CHECK_Z) || (STATUS32_CHECK_N && !STATUS32_CHECK_V) || (!STATUS32_CHECK_N && STATUS32_CHECK_V)) // Z or (N and /V) or (/N and V)
#define CONDITION_EQ (STATUS32_CHECK_Z)
#define CONDITION_CS (STATUS32_CHECK_C)
#define CONDITION_LT ((STATUS32_CHECK_N && !STATUS32_CHECK_V) || (!STATUS32_CHECK_N && STATUS32_CHECK_V))
diff --git a/src/emu/cpu/arcompact/arcompact_common.c b/src/emu/cpu/arcompact/arcompact_common.c
index c2c12208b1e..b03f27e19ff 100644
--- a/src/emu/cpu/arcompact/arcompact_common.c
+++ b/src/emu/cpu/arcompact/arcompact_common.c
@@ -4,7 +4,7 @@
\*********************************/
-// condition codes (basic ones are the same as arc
+// condition codes (basic ones are the same as arc
const char *conditions[0x20] =
{
/* 00 */ "AL", // (aka RA - Always)
@@ -13,7 +13,7 @@ const char *conditions[0x20] =
/* 03 */ "PL", // (aka P - Positive)
/* 04 */ "MI", // (aka N - Negative)
/* 05 */ "CS", // (aka C, LO - Carry set / Lower than) (unsigned)
- /* 06 */ "CC", // (aka CC, NC, HS - Carry Clear / Higher or Same) (unsigned)
+ /* 06 */ "CC", // (aka CC, NC, HS - Carry Clear / Higher or Same) (unsigned)
/* 07 */ "VS", // (aka V - Overflow set)
/* 08 */ "VC", // (aka NV - Overflow clear)
/* 09 */ "GT", // ( - Greater than) (signed)
@@ -44,7 +44,7 @@ const char *conditions[0x20] =
#define UNUSED_REG "unusedreg"
#define AUX_UNUSED_16 \
- /* 0xxx0 */ UNUSED_REG, /* 0xxx1 */ UNUSED_REG, /* 0xxx2 */ UNUSED_REG, /* 0xxx3 */ UNUSED_REG, /* 0xxx4 */ UNUSED_REG, /* 0xxx5 */ UNUSED_REG, /* 0xxx6 */ UNUSED_REG, /* 0xxx7 */ UNUSED_REG, /* 0xxx8 */ UNUSED_REG, /* 0xxx9 */ UNUSED_REG, /* 0xxxa */ UNUSED_REG, /* 0xxxb */ UNUSED_REG, /* 0xxxc */ UNUSED_REG, /* 0xxxd */ UNUSED_REG, /* 0xxxe */ UNUSED_REG, /* 0xxxf */ UNUSED_REG,
+ /* 0xxx0 */ UNUSED_REG, /* 0xxx1 */ UNUSED_REG, /* 0xxx2 */ UNUSED_REG, /* 0xxx3 */ UNUSED_REG, /* 0xxx4 */ UNUSED_REG, /* 0xxx5 */ UNUSED_REG, /* 0xxx6 */ UNUSED_REG, /* 0xxx7 */ UNUSED_REG, /* 0xxx8 */ UNUSED_REG, /* 0xxx9 */ UNUSED_REG, /* 0xxxa */ UNUSED_REG, /* 0xxxb */ UNUSED_REG, /* 0xxxc */ UNUSED_REG, /* 0xxxd */ UNUSED_REG, /* 0xxxe */ UNUSED_REG, /* 0xxxf */ UNUSED_REG,
// the Auxiliary Register set is actually a 2^32 dword address space (so 16 GB / 34-bit)
// this table just allows us to improve the debugger display for some of the common core / internal ones
@@ -125,7 +125,7 @@ const char *auxregnames[0x420] =
AUX_UNUSED_16 /* 0x090 - 0x09f */
AUX_UNUSED_16 /* 0x0a0 - 0x0af */
AUX_UNUSED_16 /* 0x0b0 - 0x0bf */
- // build configuration registers 0x0c0 - 0x0ff
+ // build configuration registers 0x0c0 - 0x0ff
/* 0x0c0 */ "RESERVED AUX 0xc0",/* 0x0c1 */ "RESERVED AUX 0xc1",/* 0x0c2 */ "RESERVED AUX 0xc2",/* 0x0c3 */ "RESERVED AUX 0xc3",/* 0x0c4 */ "RESERVED AUX 0xc4",/* 0x0c5 */ "RESERVED AUX 0xc5",/* 0x0c6 */ "RESERVED AUX 0xc6",/* 0x0c7 */ "RESERVED AUX 0xc7",/* 0x0c8 */ "RESERVED AUX 0xc8",/* 0x0c9 */ "RESERVED AUX 0xc9",/* 0x0ca */ "RESERVED AUX 0xca",/* 0x0cb */ "RESERVED AUX 0xcb",/* 0x0cc */ "RESERVED AUX 0xcc",/* 0x0cd */ "RESERVED AUX 0xcd",/* 0x0ce */ "RESERVED AUX 0xce",/* 0x0cf */ "RESERVED AUX 0xcf",
/* 0x0d0 */ "RESERVED AUX 0xd0",/* 0x0d1 */ "RESERVED AUX 0xd1",/* 0x0d2 */ "RESERVED AUX 0xd2",/* 0x0d3 */ "RESERVED AUX 0xd3",/* 0x0d4 */ "RESERVED AUX 0xd4",/* 0x0d5 */ "RESERVED AUX 0xd5",/* 0x0d6 */ "RESERVED AUX 0xd6",/* 0x0d7 */ "RESERVED AUX 0xd7",/* 0x0d8 */ "RESERVED AUX 0xd8",/* 0x0d9 */ "RESERVED AUX 0xd9",/* 0x0da */ "RESERVED AUX 0xda",/* 0x0db */ "RESERVED AUX 0xdb",/* 0x0dc */ "RESERVED AUX 0xdc",/* 0x0dd */ "RESERVED AUX 0xdd",/* 0x0de */ "RESERVED AUX 0xde",/* 0x0df */ "RESERVED AUX 0xdf",
/* 0x0e0 */ "RESERVED AUX 0xe0",/* 0x0e1 */ "RESERVED AUX 0xe1",/* 0x0e2 */ "RESERVED AUX 0xe2",/* 0x0e3 */ "RESERVED AUX 0xe3",/* 0x0e4 */ "RESERVED AUX 0xe4",/* 0x0e5 */ "RESERVED AUX 0xe5",/* 0x0e6 */ "RESERVED AUX 0xe6",/* 0x0e7 */ "RESERVED AUX 0xe7",/* 0x0e8 */ "RESERVED AUX 0xe8",/* 0x0e9 */ "RESERVED AUX 0xe9",/* 0x0ea */ "RESERVED AUX 0xea",/* 0x0eb */ "RESERVED AUX 0xeb",/* 0x0ec */ "RESERVED AUX 0xec",/* 0x0ed */ "RESERVED AUX 0xed",/* 0x0ee */ "RESERVED AUX 0xee",/* 0x0ef */ "RESERVED AUX 0xef",
@@ -371,8 +371,8 @@ const char *regnames[0x40] =
/* 37 */ "r55(ext)",
/* 38 */ "r56(ext)",
/* 39 */ "r57(M-LO)", // MLO (result registers for optional multply functions)
- /* 3a */ "r58(M-MID)", // MMID
- /* 3b */ "r59(M-HI)", // MHI
+ /* 3a */ "r58(M-MID)", // MMID
+ /* 3b */ "r59(M-HI)", // MHI
/* 3c */ "r60(LP_COUNT)",
/* 3d */ "r61(reserved)",
/* 3e */ "r62(LIMM)", // use Long Immediate Data instead of register
@@ -523,4 +523,3 @@ const char *opcodes_04[0x40] =
/* 3e */ "0x3e",
/* 3f */ "0x3f",
};
-
diff --git a/src/emu/cpu/arcompact/arcompact_execute.c b/src/emu/cpu/arcompact/arcompact_execute.c
index 8e79c587ba1..27deef265c2 100644
--- a/src/emu/cpu/arcompact/arcompact_execute.c
+++ b/src/emu/cpu/arcompact/arcompact_execute.c
@@ -19,7 +19,7 @@ void arcompact_device::execute_run()
{
debugger_instruction_hook(this, m_pc);
-// printf("new pc %04x\n", m_pc);
+// printf("new pc %04x\n", m_pc);
if (m_delayactive)
{
@@ -56,86 +56,65 @@ void arcompact_device::execute_run()
#define GET_01_01_01_BRANCH_ADDR \
INT32 address = (op & 0x00fe0000) >> 17; \
address |= ((op & 0x00008000) >> 15) << 7; \
- if (address & 0x80) address = -0x80 + (address & 0x7f); \
-
+ if (address & 0x80) address = -0x80 + (address & 0x7f);
#define GROUP_0e_GET_h \
h = ((op & 0x0007) << 3); \
- h |= ((op & 0x00e0) >> 5); \
-
+ h |= ((op & 0x00e0) >> 5);
#define COMMON32_GET_breg \
int b_temp = (op & 0x07000000) >> 24; \
int B_temp = (op & 0x00007000) >> 12; \
- int breg = b_temp | (B_temp << 3); \
-
+ int breg = b_temp | (B_temp << 3);
#define COMMON32_GET_creg \
- int creg = (op & 0x00000fc0) >> 6; \
-
+ int creg = (op & 0x00000fc0) >> 6;
#define COMMON32_GET_u6 \
- int u = (op & 0x00000fc0) >> 6; \
-
+ int u = (op & 0x00000fc0) >> 6;
#define COMMON32_GET_areg \
- int areg = (op & 0x0000003f) >> 0; \
-
+ int areg = (op & 0x0000003f) >> 0;
#define COMMON32_GET_areg_reserved \
- int ares = (op & 0x0000003f) >> 0; \
-
+ int ares = (op & 0x0000003f) >> 0;
#define COMMON32_GET_F \
- int F = (op & 0x00008000) >> 15; \
-
+ int F = (op & 0x00008000) >> 15;
#define COMMON32_GET_p \
- int p = (op & 0x00c00000) >> 22; \
-
+ int p = (op & 0x00c00000) >> 22;
#define COMMON32_GET_s12 \
int S_temp = (op & 0x0000003f) >> 0; \
int s_temp = (op & 0x00000fc0) >> 6; \
INT32 S = s_temp | (S_temp<<6); \
- if (S & 0x800) S = -0x800 + (S&0x7ff); /* sign extend */ \
-
+ if (S & 0x800) S = -0x800 + (S&0x7ff); /* sign extend */
#define COMMON32_GET_CONDITION \
UINT8 condition = op & 0x0000001f;
#define COMMON16_GET_breg \
- breg = ((op & 0x0700) >>8); \
-
+ breg = ((op & 0x0700) >>8);
#define COMMON16_GET_creg \
- creg = ((op & 0x00e0) >>5); \
-
+ creg = ((op & 0x00e0) >>5);
#define COMMON16_GET_areg \
- areg = ((op & 0x0007) >>0); \
-
+ areg = ((op & 0x0007) >>0);
#define COMMON16_GET_u3 \
- u = ((op & 0x0007) >>0); \
-
+ u = ((op & 0x0007) >>0);
#define COMMON16_GET_u5 \
- u = ((op & 0x001f) >>0); \
-
+ u = ((op & 0x001f) >>0);
#define COMMON16_GET_u8 \
- u = ((op & 0x00ff) >>0); \
-
+ u = ((op & 0x00ff) >>0);
#define COMMON16_GET_u7 \
- u = ((op & 0x007f) >>0); \
-
+ u = ((op & 0x007f) >>0);
#define COMMON16_GET_s9 \
- s = ((op & 0x01ff) >>0); \
-
+ s = ((op & 0x01ff) >>0);
// registers used in 16-bit opcodes hae a limited range
// and can only address registers r0-r3 and r12-r15
#define REG_16BIT_RANGE(_reg_) \
- if (_reg_>3) _reg_+= 8; \
-
+ if (_reg_>3) _reg_+= 8;
#define GET_LIMM_32 \
limm = (READ16((m_pc + 4) >> 1) << 16); \
- limm |= READ16((m_pc + 6) >> 1); \
-
+ limm |= READ16((m_pc + 6) >> 1);
#define GET_LIMM_16 \
limm = (READ16((m_pc + 2) >> 1) << 16); \
- limm |= READ16((m_pc + 4) >> 1); \
-
+ limm |= READ16((m_pc + 4) >> 1);
#define PC_ALIGNED32 \
(m_pc&0xfffffffc)
@@ -178,7 +157,7 @@ int arcompact_device::check_condition(UINT8 condition)
case 0x1f: fatalerror("unhandled condition check %s", conditions[condition]); return -1;
}
- return -1;
+ return -1;
}
@@ -194,44 +173,44 @@ ARCOMPACT_RETTYPE arcompact_device::get_insruction(OPS_32)
switch (instruction) // 32-bit instructions (with optional extra dword for immediate data)
{
- case 0x00: return arcompact_handle00(PARAMS); // Bcc
- case 0x01: return arcompact_handle01(PARAMS); // BLcc/BRcc
- case 0x02: return arcompact_handle02(PARAMS); // LD r+o
- case 0x03: return arcompact_handle03(PARAMS); // ST r+o
- case 0x04: return arcompact_handle04(PARAMS); // op a,b,c (basecase)
- case 0x05: return arcompact_handle05(PARAMS); // op a,b,c (05 ARC ext)
- case 0x06: return arcompact_handle06(PARAMS); // op a,b,c (06 ARC ext)
- case 0x07: return arcompact_handle07(PARAMS); // op a,b,c (07 User ext)
- case 0x08: return arcompact_handle08(PARAMS); // op a,b,c (08 User ext)
- case 0x09: return arcompact_handle09(PARAMS); // op a,b,c (09 Market ext)
- case 0x0a: return arcompact_handle0a(PARAMS); // op a,b,c (0a Market ext)
- case 0x0b: return arcompact_handle0b(PARAMS); // op a,b,c (0b Market ext)
+ case 0x00: return arcompact_handle00(PARAMS); // Bcc
+ case 0x01: return arcompact_handle01(PARAMS); // BLcc/BRcc
+ case 0x02: return arcompact_handle02(PARAMS); // LD r+o
+ case 0x03: return arcompact_handle03(PARAMS); // ST r+o
+ case 0x04: return arcompact_handle04(PARAMS); // op a,b,c (basecase)
+ case 0x05: return arcompact_handle05(PARAMS); // op a,b,c (05 ARC ext)
+ case 0x06: return arcompact_handle06(PARAMS); // op a,b,c (06 ARC ext)
+ case 0x07: return arcompact_handle07(PARAMS); // op a,b,c (07 User ext)
+ case 0x08: return arcompact_handle08(PARAMS); // op a,b,c (08 User ext)
+ case 0x09: return arcompact_handle09(PARAMS); // op a,b,c (09 Market ext)
+ case 0x0a: return arcompact_handle0a(PARAMS); // op a,b,c (0a Market ext)
+ case 0x0b: return arcompact_handle0b(PARAMS); // op a,b,c (0b Market ext)
}
}
else
{
switch (instruction) // 16-bit instructions
{
- case 0x0c: return arcompact_handle0c(PARAMS); // Load/Add reg-reg
- case 0x0d: return arcompact_handle0d(PARAMS); // Add/Sub/Shft imm
- case 0x0e: return arcompact_handle0e(PARAMS); // Mov/Cmp/Add
- case 0x0f: return arcompact_handle0f(PARAMS); // op_S b,b,c (single 16-bit ops)
- case 0x10: return arcompact_handle10(PARAMS); // LD_S
- case 0x11: return arcompact_handle11(PARAMS); // LDB_S
- case 0x12: return arcompact_handle12(PARAMS); // LDW_S
- case 0x13: return arcompact_handle13(PARAMS); // LSW_S.X
- case 0x14: return arcompact_handle14(PARAMS); // ST_S
- case 0x15: return arcompact_handle15(PARAMS); // STB_S
- case 0x16: return arcompact_handle16(PARAMS); // STW_S
- case 0x17: return arcompact_handle17(PARAMS); // Shift/Sub/Bit
- case 0x18: return arcompact_handle18(PARAMS); // Stack Instr
- case 0x19: return arcompact_handle19(PARAMS); // GP Instr
- case 0x1a: return arcompact_handle1a(PARAMS); // PCL Instr
- case 0x1b: return arcompact_handle1b(PARAMS); // MOV_S
- case 0x1c: return arcompact_handle1c(PARAMS); // ADD_S/CMP_S
- case 0x1d: return arcompact_handle1d(PARAMS); // BRcc_S
- case 0x1e: return arcompact_handle1e(PARAMS); // Bcc_S
- case 0x1f: return arcompact_handle1f(PARAMS); // BL_S
+ case 0x0c: return arcompact_handle0c(PARAMS); // Load/Add reg-reg
+ case 0x0d: return arcompact_handle0d(PARAMS); // Add/Sub/Shft imm
+ case 0x0e: return arcompact_handle0e(PARAMS); // Mov/Cmp/Add
+ case 0x0f: return arcompact_handle0f(PARAMS); // op_S b,b,c (single 16-bit ops)
+ case 0x10: return arcompact_handle10(PARAMS); // LD_S
+ case 0x11: return arcompact_handle11(PARAMS); // LDB_S
+ case 0x12: return arcompact_handle12(PARAMS); // LDW_S
+ case 0x13: return arcompact_handle13(PARAMS); // LSW_S.X
+ case 0x14: return arcompact_handle14(PARAMS); // ST_S
+ case 0x15: return arcompact_handle15(PARAMS); // STB_S
+ case 0x16: return arcompact_handle16(PARAMS); // STW_S
+ case 0x17: return arcompact_handle17(PARAMS); // Shift/Sub/Bit
+ case 0x18: return arcompact_handle18(PARAMS); // Stack Instr
+ case 0x19: return arcompact_handle19(PARAMS); // GP Instr
+ case 0x1a: return arcompact_handle1a(PARAMS); // PCL Instr
+ case 0x1b: return arcompact_handle1b(PARAMS); // MOV_S
+ case 0x1c: return arcompact_handle1c(PARAMS); // ADD_S/CMP_S
+ case 0x1d: return arcompact_handle1d(PARAMS); // BRcc_S
+ case 0x1e: return arcompact_handle1e(PARAMS); // Bcc_S
+ case 0x1f: return arcompact_handle1f(PARAMS); // BL_S
}
}
@@ -501,15 +480,15 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle05_2f(OPS_32)
switch (subinstr2)
{
- case 0x00: return arcompact_handle05_2f_00(PARAMS); // SWAP
- case 0x01: return arcompact_handle05_2f_01(PARAMS); // NORM
+ case 0x00: return arcompact_handle05_2f_00(PARAMS); // SWAP
+ case 0x01: return arcompact_handle05_2f_01(PARAMS); // NORM
case 0x02: return arcompact_handle05_2f_02(PARAMS); // SAT16
- case 0x03: return arcompact_handle05_2f_03(PARAMS); // RND16
- case 0x04: return arcompact_handle05_2f_04(PARAMS); // ABSSW
- case 0x05: return arcompact_handle05_2f_05(PARAMS); // ABSS
- case 0x06: return arcompact_handle05_2f_06(PARAMS); // NEGSW
- case 0x07: return arcompact_handle05_2f_07(PARAMS); // NEGS
- case 0x08: return arcompact_handle05_2f_08(PARAMS); // NORMW
+ case 0x03: return arcompact_handle05_2f_03(PARAMS); // RND16
+ case 0x04: return arcompact_handle05_2f_04(PARAMS); // ABSSW
+ case 0x05: return arcompact_handle05_2f_05(PARAMS); // ABSS
+ case 0x06: return arcompact_handle05_2f_06(PARAMS); // NEGSW
+ case 0x07: return arcompact_handle05_2f_07(PARAMS); // NEGS
+ case 0x08: return arcompact_handle05_2f_08(PARAMS); // NORMW
case 0x09: return arcompact_handle05_2f_09(PARAMS); // illegal
case 0x0a: return arcompact_handle05_2f_0a(PARAMS); // illegal
case 0x0b: return arcompact_handle05_2f_0b(PARAMS); // illegal
@@ -935,13 +914,13 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle17(OPS_16)
switch (subinstr)
{
- case 0x00: return arcompact_handle17_00(PARAMS); // ASL_S
- case 0x01: return arcompact_handle17_01(PARAMS); // LSR_S
+ case 0x00: return arcompact_handle17_00(PARAMS); // ASL_S
+ case 0x01: return arcompact_handle17_01(PARAMS); // LSR_S
case 0x02: return arcompact_handle17_02(PARAMS); // ASR_S
- case 0x03: return arcompact_handle17_03(PARAMS); // SUB_S
- case 0x04: return arcompact_handle17_04(PARAMS); // BSET_S
- case 0x05: return arcompact_handle17_05(PARAMS); // BCLR_S
- case 0x06: return arcompact_handle17_06(PARAMS); // BMSK_S
+ case 0x03: return arcompact_handle17_03(PARAMS); // SUB_S
+ case 0x04: return arcompact_handle17_04(PARAMS); // BSET_S
+ case 0x05: return arcompact_handle17_05(PARAMS); // BCLR_S
+ case 0x06: return arcompact_handle17_06(PARAMS); // BMSK_S
case 0x07: return arcompact_handle17_07(PARAMS); // BTST_S
}
@@ -967,7 +946,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18(OPS_16)
return 0;
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_05(OPS_16)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_05(OPS_16)
{
UINT8 subinstr2 = (op & 0x0700) >> 8;
@@ -975,7 +954,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_05(OPS_16)
{
case 0x00: return arcompact_handle18_05_00(PARAMS); // ADD_S (SP)
case 0x01: return arcompact_handle18_05_01(PARAMS); // SUB_S (SP)
- case 0x02: return arcompact_handle18_05_02(PARAMS); // <illegal 0x18_05_02>
+ case 0x02: return arcompact_handle18_05_02(PARAMS); // <illegal 0x18_05_02>
case 0x03: return arcompact_handle18_05_03(PARAMS); // <illegal 0x18_05_03>
case 0x04: return arcompact_handle18_05_04(PARAMS); // <illegal 0x18_05_04>
case 0x05: return arcompact_handle18_05_05(PARAMS); // <illegal 0x18_05_05>
@@ -986,7 +965,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_05(OPS_16)
return 0;
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_06(OPS_16)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_06(OPS_16)
{
UINT8 subinstr2 = (op & 0x001f) >> 0;
@@ -1029,7 +1008,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_06(OPS_16)
return 0;
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07(OPS_16)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07(OPS_16)
{
UINT8 subinstr2 = (op & 0x001f) >> 0;
@@ -1135,13 +1114,13 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_03(OPS_16)
switch (subinstr2)
{
case 0x00: return arcompact_handle1e_03_00(PARAMS); // BGT_S
- case 0x01: return arcompact_handle1e_03_01(PARAMS); // BGE_S
+ case 0x01: return arcompact_handle1e_03_01(PARAMS); // BGE_S
case 0x02: return arcompact_handle1e_03_02(PARAMS); // BLT_S
case 0x03: return arcompact_handle1e_03_03(PARAMS); // BLE_S
case 0x04: return arcompact_handle1e_03_04(PARAMS); // BHI_S
case 0x05: return arcompact_handle1e_03_05(PARAMS); // BHS_S
case 0x06: return arcompact_handle1e_03_06(PARAMS); // BLO_S
- case 0x07: return arcompact_handle1e_03_07(PARAMS); // BLS_S
+ case 0x07: return arcompact_handle1e_03_07(PARAMS); // BLS_S
}
return 0;
@@ -1177,7 +1156,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle00_00(OPS_32)
}
else
{
- // m_regs[REG_BLINK] = m_pc + (size >> 0); // don't link
+ // m_regs[REG_BLINK] = m_pc + (size >> 0); // don't link
return realaddress;
}
@@ -1194,7 +1173,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle00_01(OPS_32)
address |= ((op & 0x0000000f) >> 0) << 20;
if (address & 0x800000) address = -0x800000 + (address & 0x7fffff);
int n = (op & 0x00000020) >> 5; op &= ~0x00000020;
-// int res = (op & 0x00000010) >> 4; op &= ~0x00000010; // should be set to 0
+// int res = (op & 0x00000010) >> 4; op &= ~0x00000010; // should be set to 0
UINT32 realaddress = PC_ALIGNED32 + (address * 2);
@@ -1206,7 +1185,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle00_01(OPS_32)
}
else
{
- // m_regs[REG_BLINK] = m_pc + (size >> 0); // don't link
+ // m_regs[REG_BLINK] = m_pc + (size >> 0); // don't link
return realaddress;
}
@@ -1234,9 +1213,9 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_00_01dasm(OPS_32)
INT32 address = (op & 0x07fc0000) >> 17;
address |= ((op & 0x0000ffc0) >> 6) << 10;
address |= ((op & 0x0000000f) >> 0) << 20;
- if (address & 0x800000) address = -0x800000 + (address&0x7fffff);
+ if (address & 0x800000) address = -0x800000 + (address&0x7fffff);
int n = (op & 0x00000020) >> 5; op &= ~0x00000020;
-// int res = (op & 0x00000010) >> 4; op &= ~0x00000010;
+// int res = (op & 0x00000010) >> 4; op &= ~0x00000010;
UINT32 realaddress = PC_ALIGNED32 + (address * 2);
@@ -1271,7 +1250,6 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_01_01_00_helper(OPS_32, const char
if ((breg != LIMM_REG) && (creg != LIMM_REG))
{
-
}
else
{
@@ -1305,22 +1283,21 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_01_01_00_helper(OPS_32, const char
UINT32 limm; \
GET_LIMM_32; \
size = 8; \
- \
+ \
if (breg == LIMM_REG) \
b = limm; \
else \
b = m_regs[breg]; \
- \
+ \
if (creg == LIMM_REG) \
c = limm; \
else \
c = m_regs[creg]; \
- } \
-
+ }
#define BR_TAKEJUMP \
/* take jump */ \
UINT32 realaddress = PC_ALIGNED32 + (address * 2); \
- \
+ \
if (n) \
{ \
m_delayactive = 1; \
@@ -1330,8 +1307,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_01_01_00_helper(OPS_32, const char
else \
{ \
return realaddress; \
- } \
-
+ }
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_00(OPS_32) // register - register BREQ
@@ -1343,7 +1319,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_00(OPS_32) // regi
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1356,7 +1332,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_01(OPS_32) // regis
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1369,20 +1345,20 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_02(OPS_32) // regit
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_03(OPS_32) // register - register BRGE
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_03(OPS_32) // register - register BRGE
{
BR_REGREG_SETUP
-
+
// BRGE (signed operation)
if ((INT32)b >= (INT32)c)
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1395,7 +1371,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_04(OPS_32) // regis
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1409,7 +1385,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_00_05(OPS_32) // regis
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1443,33 +1419,32 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_01_01_01_helper(OPS_32, const char
GET_LIMM_32; \
size = 8; \
b = limm; \
- } \
-
+ }
// register -immediate cases
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_00(OPS_32) // BREQ reg-imm
{
BR_REGIMM_SETUP
-
+
// BREQ
if (b == c)
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_01(OPS_32) // BRNE reg-imm
{
BR_REGIMM_SETUP
-
+
// BRNE
if (b != c)
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1478,26 +1453,26 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_01(OPS_32) // BRNE
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_02(OPS_32) // BRLT reg-imm
{
BR_REGIMM_SETUP
-
+
// BRLT (signed operation)
if ((INT32)b < (INT32)c)
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_03(OPS_32)
{
BR_REGIMM_SETUP
-
+
// BRGE (signed operation)
if ((INT32)b >= (INT32)c)
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1510,7 +1485,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_04(OPS_32) // regi
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1524,7 +1499,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle01_01_01_05(OPS_32) // regis
{
BR_TAKEJUMP
}
-
+
return m_pc + (size>>0);
}
@@ -1547,7 +1522,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle02(OPS_32)
int X = (op & 0x00000040) >> 6; //op &= ~0x00000040;
int Z = (op & 0x00000180) >> 7; //op &= ~0x00000180;
int a = (op & 0x00000600) >> 9; //op &= ~0x00000600;
-// int D = (op & 0x00000800) >> 11;// op &= ~0x00000800; // we don't use the data cache currently
+// int D = (op & 0x00000800) >> 11;// op &= ~0x00000800; // we don't use the data cache currently
UINT32 address = m_regs[breg];
@@ -1635,18 +1610,18 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle03(OPS_32)
{
int size = 4;
UINT32 limm = 0;
- int got_limm = 0;
+ int got_limm = 0;
int S = (op & 0x00008000) >> 15;
int s = (op & 0x00ff0000) >> 16;
if (S) s = -0x100 + s;
COMMON32_GET_breg;
COMMON32_GET_creg;
-
-// int R = (op & 0x00000001) >> 0; // bit 0 is reserved
- int Z = (op & 0x00000006) >> 1;
- int a = (op & 0x00000018) >> 3;
-// int D = (op & 0x00000020) >> 5; // we don't use the data cache currently
+
+// int R = (op & 0x00000001) >> 0; // bit 0 is reserved
+ int Z = (op & 0x00000006) >> 1;
+ int a = (op & 0x00000018) >> 3;
+// int D = (op & 0x00000020) >> 5; // we don't use the data cache currently
UINT32 address = m_regs[breg];
@@ -1738,7 +1713,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_helper(OPS_32, const char
COMMON32_GET_p;
COMMON32_GET_breg;
-
+
if (!b_reserved)
{
if (breg == LIMM_REG)
@@ -1813,24 +1788,24 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_helper(OPS_32, const char
#include "cpu/arcompact/arcompact.inc"
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_01(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_01(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x01], /*"ADC"*/ 0,0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_03(OPS_32)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_03(OPS_32)
{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x03], /*"SBC"*/ 0,0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_08(OPS_32)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_08(OPS_32)
{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x08], /*"MAX"*/ 0,0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_09(OPS_32)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_09(OPS_32)
{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x09], /*"MIN"*/ 0,0);
}
@@ -1848,24 +1823,24 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_0c(OPS_32)
}
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_0d(OPS_32)
-{
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x0d], /*"RCMP"*/ 1,0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_10(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_10(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x10], /*"BCLR"*/ 0,0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_11(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_11(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x11], /*"BTST"*/ 0,0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_12(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_12(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x12], /*"BXOR"*/ 0,0);
}
@@ -1874,23 +1849,23 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_12(OPS_32)
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1a(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1a(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x1a], /*"MPY"*/ 0,0);
} // *
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1b(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1b(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x1b], /*"MPYH"*/ 0,0);
} // *
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1c(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1c(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x1c], /*"MPYHU"*/ 0,0);
} // *
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1d(OPS_32)
-{
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_1d(OPS_32)
+{
return arcompact_handle04_helper(PARAMS, opcodes_04[0x1d], /*"MPYU"*/ 0,0);
} // *
@@ -1903,7 +1878,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_20_p00(OPS_32)
COMMON32_GET_creg
COMMON32_GET_F
- if (creg == LIMM_REG)
+ if (creg == LIMM_REG)
{
// opcode iiii i--- ppII IIII F--- CCCC CC-- ----
// J limm 0010 0RRR 0010 0000 0RRR 1111 10RR RRRR [LIMM] (creg = LIMM)
@@ -1945,7 +1920,6 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_20_p00(OPS_32)
}
else
{
-
return m_regs[creg];
}
}
@@ -2003,7 +1977,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_20_p11_m0(OPS_32) // Jcc
// opcode iiii i--- ppII IIII F--- cccc ccmq qqqq
// Jcc [c] 0010 0RRR 1110 0000 0RRR CCCC CC0Q QQQQ
// no conditional links to ILINK1, ILINK2?
-
+
c = m_regs[creg];
}
@@ -2026,7 +2000,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_20_p11_m0(OPS_32) // Jcc
}
if (F)
- {
+ {
// if F is set then the destination MUST be ILINK1 or ILINK2
if ((creg == REG_ILINK1) || (creg == REG_ILINK1))
@@ -2037,7 +2011,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_20_p11_m0(OPS_32) // Jcc
{
arcompact_fatal ("fatal arcompact_handle04_20_p11_m0 J %08x (F set but not ILINK1 or ILINK2 used as dst)", op);
- }
+ }
}
@@ -2076,7 +2050,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_23(OPS_32)
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_28(OPS_32) // LPcc (loop setup)
{
int size = 4;
-// COMMON32_GET_breg; // breg is reserved
+// COMMON32_GET_breg; // breg is reserved
COMMON32_GET_p;
if (p == 0x00)
@@ -2099,7 +2073,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_28(OPS_32) // LPcc (loop
COMMON32_GET_u6
COMMON32_GET_CONDITION
//arcompact_fatal("Lp conditional %s not supported %d", conditions[condition], u);
-
+
// if the loop condition fails then just jump to after the end of the loop, don't set any registers
if (!check_condition(condition))
{
@@ -2124,7 +2098,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_28(OPS_32) // LPcc (loop
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_2a(OPS_32) // Load FROM Auxiliary register TO register
{
int size = 4;
-// UINT32 limm = 0;
+// UINT32 limm = 0;
int got_limm = 0;
COMMON32_GET_p;
@@ -2132,7 +2106,6 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_2a(OPS_32) // Load FROM
if (p == 0)
{
-
COMMON32_GET_creg
if (creg == LIMM_REG)
@@ -2142,7 +2115,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_2a(OPS_32) // Load FROM
//GET_LIMM_32;
size = 8;
}
-
+
}
else
{
@@ -2176,7 +2149,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_2f_helper(OPS_32, const c
COMMON32_GET_p;
//COMMON32_GET_breg;
-
+
if (p == 0)
{
COMMON32_GET_creg
@@ -2185,7 +2158,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_2f_helper(OPS_32, const c
{
//UINT32 limm;
//GET_LIMM_32;
- size = 8;
+ size = 8;
}
else
{
@@ -2265,7 +2238,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle04_3x_helper(OPS_32, int dsi
}
else
{
- }
+ }
arcompact_log("unimplemented LD %08x (type 04_3x)", op);
return m_pc + (size>>0);
@@ -2313,7 +2286,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle05_2f_0x_helper(OPS_32, cons
COMMON32_GET_p;
//COMMON32_GET_breg;
-
+
if (p == 0)
{
COMMON32_GET_creg
@@ -2322,7 +2295,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle05_2f_0x_helper(OPS_32, cons
{
//UINT32 limm;
//GET_LIMM_32;
- size = 8;
+ size = 8;
}
else
@@ -2454,7 +2427,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_0x_helper(OPS_16, const c
int size = 2;
GROUP_0e_GET_h;
-
+
if (h == LIMM_REG)
{
//UINT32 limm;
@@ -2463,7 +2436,6 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_0x_helper(OPS_16, const c
}
else
{
-
}
arcompact_log("unimplemented %s %04x (0x0e_0x group)", optext, op);
@@ -2480,7 +2452,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_00(OPS_16) // ADD_s b, b,
GROUP_0e_GET_h;
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
if (h == LIMM_REG)
{
UINT32 limm;
@@ -2499,7 +2471,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_00(OPS_16) // ADD_s b, b,
}
// 16-bit MOV with extended register range
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_01(OPS_16) // MOV_S b <- h
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_01(OPS_16) // MOV_S b <- h
{
int h,breg;
int size = 2;
@@ -2507,7 +2479,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_01(OPS_16) // MOV_S b <-
GROUP_0e_GET_h;
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
if (h == LIMM_REG)
{
// opcode iiii ibbb hhhI Ihhh
@@ -2543,10 +2515,9 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0e_03(OPS_16) // MOV_S h <-
GROUP_0e_GET_h;
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
if (h == LIMM_REG) // no result..
{
-
}
m_regs[h] = m_regs[breg];
@@ -2573,9 +2544,9 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0f_00_02(OPS_16) // JL_S
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
m_regs[REG_BLINK] = m_pc + (2 >> 0);
-
+
return m_regs[breg];
}
@@ -2586,11 +2557,11 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0f_00_03(OPS_16) // JL_S.D
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
m_delayactive = 1;
m_delayjump = m_regs[breg];
m_delaylinks = 1;
-
+
return m_pc + (2 >> 0);
}
@@ -2616,7 +2587,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle0f_00_07_07(OPS_16) // J_S.D
m_delayactive = 1;
m_delayjump = m_regs[REG_BLINK];
m_delaylinks = 0;
-
+
return m_pc + (2 >> 0);
}
@@ -2679,7 +2650,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle_ld_helper(OPS_16, const cha
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle10(OPS_16)
-{ // LD_S c, [b, u7]
+{ // LD_S c, [b, u7]
int breg, creg, u;
COMMON16_GET_breg;
@@ -2697,7 +2668,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle10(OPS_16)
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle11(OPS_16)
{
- // LDB_S c, [b, u5]
+ // LDB_S c, [b, u5]
int breg, creg, u;
COMMON16_GET_breg;
@@ -2707,7 +2678,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle11(OPS_16)
REG_16BIT_RANGE(breg);
REG_16BIT_RANGE(creg);
-// u <<= 0; // check
+// u <<= 0; // check
m_regs[creg] = READ8((m_regs[breg] + u) >> 0);
return m_pc + (2 >> 0);
@@ -2715,7 +2686,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle11(OPS_16)
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle12(OPS_16)
{
- // LDB_W c, [b, u6]
+ // LDB_W c, [b, u6]
int breg, creg, u;
COMMON16_GET_breg;
@@ -2765,7 +2736,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle15(OPS_16) // STB_S c. [b, u
REG_16BIT_RANGE(breg);
REG_16BIT_RANGE(creg);
-// u <<= 0;
+// u <<= 0;
WRITE8((m_regs[breg] + u) >> 0, m_regs[creg]);
@@ -2833,7 +2804,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_00(OPS_16) // LD_S b, [
return m_pc + (2 >> 0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_01(OPS_16)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_01(OPS_16)
{
return arcompact_handle18_0x_helper(PARAMS, "LDB_S (SP)", 0);
}
@@ -2855,7 +2826,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_02(OPS_16) // ST_S b, [S
return m_pc + (2 >> 0);
}
-ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_03(OPS_16)
+ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_03(OPS_16)
{
return arcompact_handle18_0x_helper(PARAMS, "STB_S (SP)", 1);
}
@@ -2896,13 +2867,13 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_05_01(OPS_16)
return m_pc + (2 >> 0);
}
-// op bits remaining for 0x18_06_xx subgroups 0x0700
+// op bits remaining for 0x18_06_xx subgroups 0x0700
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_06_01(OPS_16) // POP_S b
{
int breg;
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
m_regs[breg] = READ32(m_regs[REG_SP] >> 2);
m_regs[REG_SP] += 4;
@@ -2918,15 +2889,15 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_06_11(OPS_16) // POP_S bl
return m_pc + (2 >> 0);
}
-// op bits remaining for 0x18_07_xx subgroups 0x0700
+// op bits remaining for 0x18_07_xx subgroups 0x0700
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07_01(OPS_16) // PUSH_S b
{
int breg;
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
m_regs[REG_SP] -= 4;
-
+
WRITE32(m_regs[REG_SP] >> 2, m_regs[breg]);
return m_pc + (2 >> 0);
@@ -2938,7 +2909,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07_11(OPS_16) // PUSH_S [
// breg bits are reserved
m_regs[REG_SP] -= 4;
-
+
WRITE32(m_regs[REG_SP] >> 2, m_regs[REG_BLINK]);
return m_pc + (2 >> 0);
@@ -3058,7 +3029,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1d_00(OPS_16) // BREQ_S b,0,
if (!m_regs[breg])
{
- int s = (op & 0x007f) >> 0; op &= ~0x007f;
+ int s = (op & 0x007f) >> 0; op &= ~0x007f;
if (s & 0x40) s = -0x40 + (s & 0x3f);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3077,7 +3048,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1d_01(OPS_16) // BRNE_S b,0,
if (m_regs[breg])
{
- int s = (op & 0x007f) >> 0; op &= ~0x007f;
+ int s = (op & 0x007f) >> 0; op &= ~0x007f;
if (s & 0x40) s = -0x40 + (s & 0x3f);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3098,7 +3069,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_0x_helper(OPS_16, const c
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_00(OPS_16) // B_S s10 (branch always)
{
- int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
+ int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
if (s & 0x100) s = -0x100 + (s & 0xff);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3109,7 +3080,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_01(OPS_16) // BEQ_S s10 (
{
if (STATUS32_CHECK_Z)
{
- int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
+ int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
if (s & 0x100) s = -0x100 + (s & 0xff);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3123,7 +3094,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_02(OPS_16) // BNE_S s10
{
if (!STATUS32_CHECK_Z)
{
- int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
+ int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
if (s & 0x100) s = -0x100 + (s & 0xff);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3146,7 +3117,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_03_02(OPS_16) // BLT_S
{
if (CONDITION_LT)
{
- int s = (op & 0x003f) >> 0; op &= ~0x003f;
+ int s = (op & 0x003f) >> 0; op &= ~0x003f;
if (s & 0x020) s = -0x20 + (s & 0x1f);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3160,7 +3131,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_03_03(OPS_16) // BLE_S
{
if (CONDITION_LE)
{
- int s = (op & 0x003f) >> 0; op &= ~0x003f;
+ int s = (op & 0x003f) >> 0; op &= ~0x003f;
if (s & 0x020) s = -0x20 + (s & 0x1f);
UINT32 realaddress = PC_ALIGNED32 + (s * 2);
//m_regs[REG_BLINK] = m_pc + (2 >> 0); // don't link
@@ -3177,7 +3148,7 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1e_03_07(OPS_16) { return a
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle1f(OPS_16) // BL_S s13
{
- int s = (op & 0x07ff) >> 0; op &= ~0x07ff;
+ int s = (op & 0x07ff) >> 0; op &= ~0x07ff;
if (s & 0x400) s = -0x400 + (s & 0x3ff);
UINT32 realaddress = PC_ALIGNED32 + (s * 4);
@@ -3600,6 +3571,3 @@ ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07_1c(OPS_16) { arcompac
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07_1d(OPS_16) { arcompact_fatal("<illegal 0x18_07_1d> (%04x)", op); return m_pc + (2 >> 0);}
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07_1e(OPS_16) { arcompact_fatal("<illegal 0x18_07_1e> (%04x)", op); return m_pc + (2 >> 0);}
ARCOMPACT_RETTYPE arcompact_device::arcompact_handle18_07_1f(OPS_16) { arcompact_fatal("<illegal 0x18_07_1f> (%04x)", op); return m_pc + (2 >> 0);}
-
-
-
diff --git a/src/emu/cpu/arcompact/arcompactdasm.c b/src/emu/cpu/arcompact/arcompactdasm.c
index 54829b61729..f1ff19942a1 100644
--- a/src/emu/cpu/arcompact/arcompactdasm.c
+++ b/src/emu/cpu/arcompact/arcompactdasm.c
@@ -41,48 +41,48 @@ CPU_DISASSEMBLE(arcompact)
switch (instruction) // 32-bit instructions (with optional extra dword for immediate data)
{
- case 0x00: size = arcompact_handle00_dasm(DASM_PARAMS); break; // Bcc
- case 0x01: size = arcompact_handle01_dasm(DASM_PARAMS); break; // BLcc/BRcc
- case 0x02: size = arcompact_handle02_dasm(DASM_PARAMS); break; // LD r+o
- case 0x03: size = arcompact_handle03_dasm(DASM_PARAMS); break; // ST r+o
- case 0x04: size = arcompact_handle04_dasm(DASM_PARAMS); break; // op a,b,c (basecase)
- case 0x05: size = arcompact_handle05_dasm(DASM_PARAMS); break; // op a,b,c (05 ARC ext)
- case 0x06: size = arcompact_handle06_dasm(DASM_PARAMS); break; // op a,b,c (06 ARC ext)
- case 0x07: size = arcompact_handle07_dasm(DASM_PARAMS); break; // op a,b,c (07 User ext)
- case 0x08: size = arcompact_handle08_dasm(DASM_PARAMS); break; // op a,b,c (08 User ext)
- case 0x09: size = arcompact_handle09_dasm(DASM_PARAMS); break; // op a,b,c (09 Market ext)
- case 0x0a: size = arcompact_handle0a_dasm(DASM_PARAMS); break; // op a,b,c (0a Market ext)
- case 0x0b: size = arcompact_handle0b_dasm(DASM_PARAMS); break; // op a,b,c (0b Market ext)
+ case 0x00: size = arcompact_handle00_dasm(DASM_PARAMS); break; // Bcc
+ case 0x01: size = arcompact_handle01_dasm(DASM_PARAMS); break; // BLcc/BRcc
+ case 0x02: size = arcompact_handle02_dasm(DASM_PARAMS); break; // LD r+o
+ case 0x03: size = arcompact_handle03_dasm(DASM_PARAMS); break; // ST r+o
+ case 0x04: size = arcompact_handle04_dasm(DASM_PARAMS); break; // op a,b,c (basecase)
+ case 0x05: size = arcompact_handle05_dasm(DASM_PARAMS); break; // op a,b,c (05 ARC ext)
+ case 0x06: size = arcompact_handle06_dasm(DASM_PARAMS); break; // op a,b,c (06 ARC ext)
+ case 0x07: size = arcompact_handle07_dasm(DASM_PARAMS); break; // op a,b,c (07 User ext)
+ case 0x08: size = arcompact_handle08_dasm(DASM_PARAMS); break; // op a,b,c (08 User ext)
+ case 0x09: size = arcompact_handle09_dasm(DASM_PARAMS); break; // op a,b,c (09 Market ext)
+ case 0x0a: size = arcompact_handle0a_dasm(DASM_PARAMS); break; // op a,b,c (0a Market ext)
+ case 0x0b: size = arcompact_handle0b_dasm(DASM_PARAMS); break; // op a,b,c (0b Market ext)
}
}
else
- {
+ {
size = 2;
op &= ~0xf800;
switch (instruction) // 16-bit instructions
{
- case 0x0c: size = arcompact_handle0c_dasm(DASM_PARAMS); break; // Load/Add reg-reg
- case 0x0d: size = arcompact_handle0d_dasm(DASM_PARAMS); break; // Add/Sub/Shft imm
- case 0x0e: size = arcompact_handle0e_dasm(DASM_PARAMS); break; // Mov/Cmp/Add
- case 0x0f: size = arcompact_handle0f_dasm(DASM_PARAMS); break; // op_S b,b,c (single 16-bit ops)
- case 0x10: size = arcompact_handle10_dasm(DASM_PARAMS); break; // LD_S
- case 0x11: size = arcompact_handle11_dasm(DASM_PARAMS); break; // LDB_S
- case 0x12: size = arcompact_handle12_dasm(DASM_PARAMS); break; // LDW_S
- case 0x13: size = arcompact_handle13_dasm(DASM_PARAMS); break; // LSW_S.X
- case 0x14: size = arcompact_handle14_dasm(DASM_PARAMS); break; // ST_S
- case 0x15: size = arcompact_handle15_dasm(DASM_PARAMS); break; // STB_S
- case 0x16: size = arcompact_handle16_dasm(DASM_PARAMS); break; // STW_S
- case 0x17: size = arcompact_handle17_dasm(DASM_PARAMS); break; // Shift/Sub/Bit
- case 0x18: size = arcompact_handle18_dasm(DASM_PARAMS); break; // Stack Instr
- case 0x19: size = arcompact_handle19_dasm(DASM_PARAMS); break; // GP Instr
- case 0x1a: size = arcompact_handle1a_dasm(DASM_PARAMS); break; // PCL Instr
- case 0x1b: size = arcompact_handle1b_dasm(DASM_PARAMS); break; // MOV_S
- case 0x1c: size = arcompact_handle1c_dasm(DASM_PARAMS); break; // ADD_S/CMP_S
- case 0x1d: size = arcompact_handle1d_dasm(DASM_PARAMS); break; // BRcc_S
- case 0x1e: size = arcompact_handle1e_dasm(DASM_PARAMS); break; // Bcc_S
- case 0x1f: size = arcompact_handle1f_dasm(DASM_PARAMS); break; // BL_S
+ case 0x0c: size = arcompact_handle0c_dasm(DASM_PARAMS); break; // Load/Add reg-reg
+ case 0x0d: size = arcompact_handle0d_dasm(DASM_PARAMS); break; // Add/Sub/Shft imm
+ case 0x0e: size = arcompact_handle0e_dasm(DASM_PARAMS); break; // Mov/Cmp/Add
+ case 0x0f: size = arcompact_handle0f_dasm(DASM_PARAMS); break; // op_S b,b,c (single 16-bit ops)
+ case 0x10: size = arcompact_handle10_dasm(DASM_PARAMS); break; // LD_S
+ case 0x11: size = arcompact_handle11_dasm(DASM_PARAMS); break; // LDB_S
+ case 0x12: size = arcompact_handle12_dasm(DASM_PARAMS); break; // LDW_S
+ case 0x13: size = arcompact_handle13_dasm(DASM_PARAMS); break; // LSW_S.X
+ case 0x14: size = arcompact_handle14_dasm(DASM_PARAMS); break; // ST_S
+ case 0x15: size = arcompact_handle15_dasm(DASM_PARAMS); break; // STB_S
+ case 0x16: size = arcompact_handle16_dasm(DASM_PARAMS); break; // STW_S
+ case 0x17: size = arcompact_handle17_dasm(DASM_PARAMS); break; // Shift/Sub/Bit
+ case 0x18: size = arcompact_handle18_dasm(DASM_PARAMS); break; // Stack Instr
+ case 0x19: size = arcompact_handle19_dasm(DASM_PARAMS); break; // GP Instr
+ case 0x1a: size = arcompact_handle1a_dasm(DASM_PARAMS); break; // PCL Instr
+ case 0x1b: size = arcompact_handle1b_dasm(DASM_PARAMS); break; // MOV_S
+ case 0x1c: size = arcompact_handle1c_dasm(DASM_PARAMS); break; // ADD_S/CMP_S
+ case 0x1d: size = arcompact_handle1d_dasm(DASM_PARAMS); break; // BRcc_S
+ case 0x1e: size = arcompact_handle1e_dasm(DASM_PARAMS); break; // Bcc_S
+ case 0x1f: size = arcompact_handle1f_dasm(DASM_PARAMS); break; // BL_S
}
}
diff --git a/src/emu/cpu/arcompact/arcompactdasm_dispatch.c b/src/emu/cpu/arcompact/arcompactdasm_dispatch.c
index 172c00893f2..b510cb28c41 100644
--- a/src/emu/cpu/arcompact/arcompactdasm_dispatch.c
+++ b/src/emu/cpu/arcompact/arcompactdasm_dispatch.c
@@ -141,9 +141,9 @@ int arcompact_handle04_dasm(DASM_OPS_32)
// 00100 bbb 00 iiiiii F BBB CCCCCC A AAAAA General Operations *UN*Conditional Register to Register
// 00100 bbb 01 iiiiii F BBB UUUUUU A AAAAA General Operations *UN*Conditional Register (Unsigned 6-bit IMM)
// 00100 bbb 10 iiiiii F BBB ssssss S SSSSS General Operations *UN*Conditional Register (Signed 12-bit IMM)
-
- // 00100 bbb 11 iiiiii F BBB CCCCCC 0 QQQQQ General Operations Conditional Register
- // 00100 bbb 11 iiiiii F BBB UUUUUU 1 QQQQQ General Operations Conditional Register (Unsigned 6-bit IMM)
+
+ // 00100 bbb 11 iiiiii F BBB CCCCCC 0 QQQQQ General Operations Conditional Register
+ // 00100 bbb 11 iiiiii F BBB UUUUUU 1 QQQQQ General Operations Conditional Register (Unsigned 6-bit IMM)
UINT8 subinstr = (op & 0x003f0000) >> 16;
op &= ~0x003f0000;
@@ -304,15 +304,15 @@ int arcompact_handle05_2f_dasm(DASM_OPS_32)
switch (subinstr2)
{
- case 0x00: size = arcompact_handle05_2f_00_dasm(DASM_PARAMS); break; // SWAP
- case 0x01: size = arcompact_handle05_2f_01_dasm(DASM_PARAMS); break; // NORM
+ case 0x00: size = arcompact_handle05_2f_00_dasm(DASM_PARAMS); break; // SWAP
+ case 0x01: size = arcompact_handle05_2f_01_dasm(DASM_PARAMS); break; // NORM
case 0x02: size = arcompact_handle05_2f_02_dasm(DASM_PARAMS); break; // SAT16
- case 0x03: size = arcompact_handle05_2f_03_dasm(DASM_PARAMS); break; // RND16
- case 0x04: size = arcompact_handle05_2f_04_dasm(DASM_PARAMS); break; // ABSSW
- case 0x05: size = arcompact_handle05_2f_05_dasm(DASM_PARAMS); break; // ABSS
- case 0x06: size = arcompact_handle05_2f_06_dasm(DASM_PARAMS); break; // NEGSW
- case 0x07: size = arcompact_handle05_2f_07_dasm(DASM_PARAMS); break; // NEGS
- case 0x08: size = arcompact_handle05_2f_08_dasm(DASM_PARAMS); break; // NORMW
+ case 0x03: size = arcompact_handle05_2f_03_dasm(DASM_PARAMS); break; // RND16
+ case 0x04: size = arcompact_handle05_2f_04_dasm(DASM_PARAMS); break; // ABSSW
+ case 0x05: size = arcompact_handle05_2f_05_dasm(DASM_PARAMS); break; // ABSS
+ case 0x06: size = arcompact_handle05_2f_06_dasm(DASM_PARAMS); break; // NEGSW
+ case 0x07: size = arcompact_handle05_2f_07_dasm(DASM_PARAMS); break; // NEGS
+ case 0x08: size = arcompact_handle05_2f_08_dasm(DASM_PARAMS); break; // NORMW
case 0x09: size = arcompact_handle05_2f_09_dasm(DASM_PARAMS); break; // illegal
case 0x0a: size = arcompact_handle05_2f_0a_dasm(DASM_PARAMS); break; // illegal
case 0x0b: size = arcompact_handle05_2f_0b_dasm(DASM_PARAMS); break; // illegal
@@ -759,13 +759,13 @@ int arcompact_handle17_dasm(DASM_OPS_16)
switch (subinstr)
{
- case 0x00: size = arcompact_handle17_00_dasm(DASM_PARAMS); break; // ASL_S
- case 0x01: size = arcompact_handle17_01_dasm(DASM_PARAMS); break; // LSR_S
+ case 0x00: size = arcompact_handle17_00_dasm(DASM_PARAMS); break; // ASL_S
+ case 0x01: size = arcompact_handle17_01_dasm(DASM_PARAMS); break; // LSR_S
case 0x02: size = arcompact_handle17_02_dasm(DASM_PARAMS); break; // ASR_S
- case 0x03: size = arcompact_handle17_03_dasm(DASM_PARAMS); break; // SUB_S
- case 0x04: size = arcompact_handle17_04_dasm(DASM_PARAMS); break; // BSET_S
- case 0x05: size = arcompact_handle17_05_dasm(DASM_PARAMS); break; // BCLR_S
- case 0x06: size = arcompact_handle17_06_dasm(DASM_PARAMS); break; // BMSK_S
+ case 0x03: size = arcompact_handle17_03_dasm(DASM_PARAMS); break; // SUB_S
+ case 0x04: size = arcompact_handle17_04_dasm(DASM_PARAMS); break; // BSET_S
+ case 0x05: size = arcompact_handle17_05_dasm(DASM_PARAMS); break; // BCLR_S
+ case 0x06: size = arcompact_handle17_06_dasm(DASM_PARAMS); break; // BMSK_S
case 0x07: size = arcompact_handle17_07_dasm(DASM_PARAMS); break; // BTST_S
}
@@ -795,7 +795,7 @@ int arcompact_handle18_dasm(DASM_OPS_16)
return size;
}
-int arcompact_handle18_05_dasm(DASM_OPS_16)
+int arcompact_handle18_05_dasm(DASM_OPS_16)
{
int size = 2;
UINT8 subinstr2 = (op & 0x0700) >> 8;
@@ -805,7 +805,7 @@ int arcompact_handle18_05_dasm(DASM_OPS_16)
{
case 0x00: size = arcompact_handle18_05_00_dasm(DASM_PARAMS); break; // ADD_S (SP)
case 0x01: size = arcompact_handle18_05_01_dasm(DASM_PARAMS); break; // SUB_S (SP)
- case 0x02: size = arcompact_handle18_05_02_dasm(DASM_PARAMS); break; // <illegal 0x18_05_02>
+ case 0x02: size = arcompact_handle18_05_02_dasm(DASM_PARAMS); break; // <illegal 0x18_05_02>
case 0x03: size = arcompact_handle18_05_03_dasm(DASM_PARAMS); break; // <illegal 0x18_05_03>
case 0x04: size = arcompact_handle18_05_04_dasm(DASM_PARAMS); break; // <illegal 0x18_05_04>
case 0x05: size = arcompact_handle18_05_05_dasm(DASM_PARAMS); break; // <illegal 0x18_05_05>
@@ -816,7 +816,7 @@ int arcompact_handle18_05_dasm(DASM_OPS_16)
return size;
}
-int arcompact_handle18_06_dasm(DASM_OPS_16)
+int arcompact_handle18_06_dasm(DASM_OPS_16)
{
int size = 2;
UINT8 subinstr2 = (op & 0x001f) >> 0;
@@ -861,7 +861,7 @@ int arcompact_handle18_06_dasm(DASM_OPS_16)
return size;
}
-int arcompact_handle18_07_dasm(DASM_OPS_16)
+int arcompact_handle18_07_dasm(DASM_OPS_16)
{
int size = 2;
UINT8 subinstr2 = (op & 0x001f) >> 0;
@@ -968,7 +968,6 @@ int arcompact_handle1e_dasm(DASM_OPS_16)
int arcompact_handle1e_03_dasm(DASM_OPS_16)
{
-
int size = 2;
UINT8 subinstr2 = (op & 0x01c0) >> 6;
op &= ~0x01c0;
@@ -976,13 +975,13 @@ int arcompact_handle1e_03_dasm(DASM_OPS_16)
switch (subinstr2)
{
case 0x00: size = arcompact_handle1e_03_00_dasm(DASM_PARAMS); break; // BGT_S
- case 0x01: size = arcompact_handle1e_03_01_dasm(DASM_PARAMS); break; // BGE_S
+ case 0x01: size = arcompact_handle1e_03_01_dasm(DASM_PARAMS); break; // BGE_S
case 0x02: size = arcompact_handle1e_03_02_dasm(DASM_PARAMS); break; // BLT_S
case 0x03: size = arcompact_handle1e_03_03_dasm(DASM_PARAMS); break; // BLE_S
case 0x04: size = arcompact_handle1e_03_04_dasm(DASM_PARAMS); break; // BHI_S
case 0x05: size = arcompact_handle1e_03_05_dasm(DASM_PARAMS); break; // BHS_S
case 0x06: size = arcompact_handle1e_03_06_dasm(DASM_PARAMS); break; // BLO_S
- case 0x07: size = arcompact_handle1e_03_07_dasm(DASM_PARAMS); break; // BLS_S
+ case 0x07: size = arcompact_handle1e_03_07_dasm(DASM_PARAMS); break; // BLS_S
}
return size;
diff --git a/src/emu/cpu/arcompact/arcompactdasm_dispatch.h b/src/emu/cpu/arcompact/arcompactdasm_dispatch.h
index f317e0ffb8e..5e30a2e8488 100644
--- a/src/emu/cpu/arcompact/arcompactdasm_dispatch.h
+++ b/src/emu/cpu/arcompact/arcompactdasm_dispatch.h
@@ -12,8 +12,7 @@
#define GET_LIMM_32 \
limm = oprom[6] | (oprom[7] << 8); \
- limm |= (oprom[4] << 16) | (oprom[5] << 24); \
-
+ limm |= (oprom[4] << 16) | (oprom[5] << 24);
int arcompact_handle00_dasm(DASM_OPS_32);
diff --git a/src/emu/cpu/arcompact/arcompactdasm_ops.c b/src/emu/cpu/arcompact/arcompactdasm_ops.c
index 4cdf09a37a0..842dafe3bd8 100644
--- a/src/emu/cpu/arcompact/arcompactdasm_ops.c
+++ b/src/emu/cpu/arcompact/arcompactdasm_ops.c
@@ -31,87 +31,68 @@ static void ATTR_PRINTF(1,2) print(const char *fmt, ...)
#define GROUP_0e_GET_h \
h = ((op & 0x0007) << 3); \
- h |= ((op & 0x00e0) >> 5); \
- op &= ~0x00e7; \
-
+ h |= ((op & 0x00e0) >> 5); \
+ op &= ~0x00e7;
#define COMMON32_GET_breg \
int b_temp = (op & 0x07000000) >> 24; op &= ~0x07000000; \
int B_temp = (op & 0x00007000) >> 12; op &= ~0x00007000; \
- int breg = b_temp | (B_temp << 3); \
-
+ int breg = b_temp | (B_temp << 3);
#define COMMON32_GET_creg \
- int creg = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0; \
-
+ int creg = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0;
#define COMMON32_GET_u6 \
- int u = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0; \
-
+ int u = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0;
#define COMMON32_GET_areg \
- int areg = (op & 0x0000003f) >> 0; op &= ~0x0000003f; \
-
+ int areg = (op & 0x0000003f) >> 0; op &= ~0x0000003f;
#define COMMON32_GET_areg_reserved \
- int ares = (op & 0x0000003f) >> 0; op &= ~0x0000003f; \
-
+ int ares = (op & 0x0000003f) >> 0; op &= ~0x0000003f;
#define COMMON32_GET_F \
- int F = (op & 0x00008000) >> 15; op &= ~0x00008000; \
-
+ int F = (op & 0x00008000) >> 15; op &= ~0x00008000;
#define COMMON32_GET_p \
- int p = (op & 0x00c00000) >> 22; op &= ~0x00c00000; \
-
+ int p = (op & 0x00c00000) >> 22; op &= ~0x00c00000;
#define COMMON32_GET_s12 \
int S_temp = (op & 0x0000003f) >> 0; op &= ~0x0000003f; \
int s_temp = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0; \
- int S = s_temp | (S_temp<<6); \
-
+ int S = s_temp | (S_temp<<6);
#define COMMON32_GET_CONDITION \
UINT8 condition = op & 0x0000001f; op &= ~0x0000001f;
#define COMMON16_GET_breg \
breg = ((op & 0x0700) >>8); \
- op &= ~0x0700; \
-
+ op &= ~0x0700;
#define COMMON16_GET_creg \
creg = ((op & 0x00e0) >>5); \
- op &= ~0x00e0; \
-
+ op &= ~0x00e0;
#define COMMON16_GET_areg \
areg = ((op & 0x0007) >>0); \
- op &= ~0x0007; \
-
+ op &= ~0x0007;
#define COMMON16_GET_u3 \
u = ((op & 0x0007) >>0); \
- op &= ~0x0007; \
-
+ op &= ~0x0007;
#define COMMON16_GET_u5 \
u = ((op & 0x001f) >>0); \
- op &= ~0x001f; \
-
+ op &= ~0x001f;
#define COMMON16_GET_u8 \
u = ((op & 0x00ff) >>0); \
- op &= ~0x00ff; \
-
+ op &= ~0x00ff;
#define COMMON16_GET_u7 \
u = ((op & 0x007f) >>0); \
- op &= ~0x007f; \
-
+ op &= ~0x007f;
#define COMMON16_GET_s9 \
s = ((op & 0x01ff) >>0); \
- op &= ~0x01ff; \
-
+ op &= ~0x01ff;
// registers used in 16-bit opcodes hae a limited range
// and can only address registers r0-r3 and r12-r15
#define REG_16BIT_RANGE(_reg_) \
- if (_reg_>3) _reg_+= 8; \
-
+ if (_reg_>3) _reg_+= 8;
// this is as messed up as the rest of the 16-bit alignment in LE mode...
#define GET_LIMM \
limm = oprom[4] | (oprom[5] << 8); \
- limm |= (oprom[2] << 16) | (oprom[3] << 24); \
-
+ limm |= (oprom[2] << 16) | (oprom[3] << 24);
#define PC_ALIGNED32 \
(pc&0xfffffffc)
@@ -163,7 +144,7 @@ int arcompact_handle01_00_00dasm(DASM_OPS_32)
// 00001 sssssssss 00 SSSSSSSSSS N QQQQQ
INT32 address = (op & 0x07fc0000) >> 17;
address |= ((op & 0x0000ffc0) >> 6) << 10;
- if (address & 0x800000) address = -0x800000 + (address&0x7fffff);
+ if (address & 0x800000) address = -0x800000 + (address&0x7fffff);
int n = (op & 0x00000020) >> 5; op &= ~0x00000020;
COMMON32_GET_CONDITION
@@ -180,7 +161,7 @@ int arcompact_handle01_00_01dasm(DASM_OPS_32)
INT32 address = (op & 0x07fc0000) >> 17;
address |= ((op & 0x0000ffc0) >> 6) << 10;
address |= ((op & 0x0000000f) >> 0) << 20;
- if (address & 0x800000) address = -0x800000 + (address&0x7fffff);
+ if (address & 0x800000) address = -0x800000 + (address&0x7fffff);
int n = (op & 0x00000020) >> 5; op &= ~0x00000020;
int res = (op & 0x00000010) >> 4; op &= ~0x00000010;
@@ -265,7 +246,7 @@ int arcompact_01_01_01_helper(DASM_OPS_32, const char* optext)
op &= ~0x07007fe0;
print("%s%s %s, 0x%02x %08x (%08x)", optext, delaybit[n], regnames[breg], u, PC_ALIGNED32 + (address * 2), op & ~0xf8fe800f);
-
+
return size;
}
@@ -327,7 +308,7 @@ int arcompact_handle03_dasm(DASM_OPS_32)
{
int size = 4;
UINT32 limm = 0;
- int got_limm = 0;
+ int got_limm = 0;
// bitpos
// 1111 1111 1111 1111 0000 0000 0000 0000
// fedc ba98 7654 3210 fedc ba98 7654 3210
@@ -401,7 +382,7 @@ int arcompact_handle04_p00_helper_dasm(DASM_OPS_32, const char* optext, int igno
output += sprintf(output, "%s", optext);
output += sprintf(output, "%s", flagbit[F]);
- // output += sprintf( output, " p(%d)", p);
+ // output += sprintf( output, " p(%d)", p);
if ((!b_reserved) && (breg == LIMM_REG))
@@ -429,7 +410,7 @@ int arcompact_handle04_p00_helper_dasm(DASM_OPS_32, const char* optext, int igno
}
else if (ignore_dst == 1) // certain opcode types ignore the 'a' field entirely, it should be set to 0.
{
- if (areg) output += sprintf(output, " <reserved %d> <-", areg);
+ if (areg) output += sprintf(output, " <reserved %d> <-", areg);
}
else if (ignore_dst == 2) // for multiply operations areg should always be set to LIMM
{
@@ -464,7 +445,7 @@ int arcompact_handle04_p01_helper_dasm(DASM_OPS_32, const char* optext, int igno
// 0010 0bbb 01ii iiii FBBB uuuu uuAA AAAA
int size = 4;
UINT32 limm = 0;
-// int got_limm = 0;
+// int got_limm = 0;
COMMON32_GET_breg;
COMMON32_GET_F;
@@ -473,14 +454,14 @@ int arcompact_handle04_p01_helper_dasm(DASM_OPS_32, const char* optext, int igno
output += sprintf(output, "%s", optext);
output += sprintf(output, "%s", flagbit[F]);
- // output += sprintf( output, " p(%d)", p);
+ // output += sprintf( output, " p(%d)", p);
if ((!b_reserved) && (breg == LIMM_REG))
{
GET_LIMM_32;
size = 8;
-// got_limm = 1;
+// got_limm = 1;
}
// areg can be LIMM too, but in that case LIMM indicates 'no destination' rather than an actual LIMM value following
@@ -492,7 +473,7 @@ int arcompact_handle04_p01_helper_dasm(DASM_OPS_32, const char* optext, int igno
}
else if (ignore_dst == 1) // certain opcode types ignore the 'a' field entirely, it should be set to 0.
{
- if (areg) output += sprintf(output, " <reserved %d> <-", areg);
+ if (areg) output += sprintf(output, " <reserved %d> <-", areg);
}
else if (ignore_dst == 2) // for multiply operations areg should always be set to LIMM
{
@@ -530,7 +511,7 @@ int arcompact_handle04_p10_helper_dasm(DASM_OPS_32, const char* optext, int b_re
output += sprintf(output, "%s", optext);
output += sprintf(output, "%s", flagbit[F]);
- // output += sprintf( output, " p(%d)", p);
+ // output += sprintf( output, " p(%d)", p);
if (!b_reserved)
@@ -570,7 +551,7 @@ int arcompact_handle04_p11_m0_helper_dasm(DASM_OPS_32, const char* optext, int b
output += sprintf(output, "%s", optext);
output += sprintf(output, "%s", flagbit[F]);
- // output += sprintf( output, " p(%d)", p);
+ // output += sprintf( output, " p(%d)", p);
if (!b_reserved)
{
@@ -594,7 +575,7 @@ int arcompact_handle04_p11_m0_helper_dasm(DASM_OPS_32, const char* optext, int b
output += sprintf(output, " Cond<%s> ", conditions[condition]);
-
+
if (creg == LIMM_REG)
{
@@ -626,7 +607,7 @@ int arcompact_handle04_p11_m1_helper_dasm(DASM_OPS_32, const char* optext, int b
output += sprintf(output, "%s", optext);
output += sprintf(output, "%s", flagbit[F]);
- // output += sprintf( output, " p(%d)", p);
+ // output += sprintf( output, " p(%d)", p);
if (!b_reserved)
{
@@ -685,52 +666,52 @@ int arcompact_handle04_helper_dasm(DASM_OPS_32, const char* optext, int ignore_d
return 0;
}
-int arcompact_handle04_00_dasm(DASM_OPS_32)
+int arcompact_handle04_00_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "ADD", 0,0);
}
-int arcompact_handle04_01_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_01_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "ADC", 0,0);
}
-int arcompact_handle04_02_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_02_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "SUB", 0,0);
}
-int arcompact_handle04_03_dasm(DASM_OPS_32)
+int arcompact_handle04_03_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "SBC", 0,0);
}
-int arcompact_handle04_04_dasm(DASM_OPS_32)
+int arcompact_handle04_04_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "AND", 0,0);
}
-int arcompact_handle04_05_dasm(DASM_OPS_32)
+int arcompact_handle04_05_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "OR", 0,0);
}
-int arcompact_handle04_06_dasm(DASM_OPS_32)
+int arcompact_handle04_06_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "BIC", 0,0);
}
-int arcompact_handle04_07_dasm(DASM_OPS_32)
+int arcompact_handle04_07_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "XOR", 0,0);
}
-int arcompact_handle04_08_dasm(DASM_OPS_32)
+int arcompact_handle04_08_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "MAX", 0,0);
}
-int arcompact_handle04_09_dasm(DASM_OPS_32)
+int arcompact_handle04_09_dasm(DASM_OPS_32)
{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "MIN", 0,0);
}
@@ -752,87 +733,87 @@ int arcompact_handle04_0c_dasm(DASM_OPS_32)
}
int arcompact_handle04_0d_dasm(DASM_OPS_32)
-{
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "RCMP", 1,0);
}
int arcompact_handle04_0e_dasm(DASM_OPS_32)
-{
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "RSUB", 0,0);
}
-int arcompact_handle04_0f_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_0f_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "BSET", 0,0);
}
-int arcompact_handle04_10_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_10_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "BCLR", 0,0);
}
-int arcompact_handle04_11_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_11_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "BTST", 0,0);
}
-int arcompact_handle04_12_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_12_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "BXOR", 0,0);
}
-int arcompact_handle04_13_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_13_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "BMSK", 0,0);
}
-int arcompact_handle04_14_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_14_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "ADD1", 0,0);
}
-int arcompact_handle04_15_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_15_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "ADD2", 0,0);
}
-int arcompact_handle04_16_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_16_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "ADD3", 0,0);
}
-int arcompact_handle04_17_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_17_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "SUB1", 0,0);
}
-int arcompact_handle04_18_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_18_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "SUB2", 0,0);
}
-int arcompact_handle04_19_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_19_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "SUB3", 0,0);
}
-int arcompact_handle04_1a_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_1a_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "MPY", 0,0);
} // *
-int arcompact_handle04_1b_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_1b_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "MPYH", 0,0);
} // *
-int arcompact_handle04_1c_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_1c_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "MPYHU", 0,0);
} // *
-int arcompact_handle04_1d_dasm(DASM_OPS_32)
-{
+int arcompact_handle04_1d_dasm(DASM_OPS_32)
+{
return arcompact_handle04_helper_dasm(DASM_PARAMS, "MPYU", 0,0);
} // *
@@ -890,7 +871,7 @@ int arcompact_handle04_28_dasm(DASM_OPS_32) // LPcc (loop setup)
output += sprintf(output, "LP<%s> (start %08x, end %08x)", conditions[condition], pc + 4, PC_ALIGNED32 + u*2);
int unused = (op & 0x00000020)>>5;
- if (unused==0) output += sprintf(output, "(unused bit not set)");
+ if (unused==0) output += sprintf(output, "(unused bit not set)");
}
@@ -908,11 +889,9 @@ int arcompact_handle04_28_dasm(DASM_OPS_32) // LPcc (loop setup)
output += sprintf( output, "[%03x]", auxreg); \
} \
else \
- output += sprintf( output, "[%03x]", auxreg); \
-
+ output += sprintf( output, "[%03x]", auxreg);
int arcompact_handle04_2a_dasm(DASM_OPS_32) // Load FROM Auxiliary register TO register
{
-
// pp F
// 0010 0bbb 0010 1010 0BBB CCCC CCRR RRRR
// 0010 0bbb 0010 1010 0BBB 1111 10RR RRRR
@@ -930,9 +909,9 @@ int arcompact_handle04_2a_dasm(DASM_OPS_32) // Load FROM Auxiliary register TO
output += sprintf( output, "LR");
if (F) output += sprintf( output, ".<F set, illegal>");
-// output += sprintf( output, " p(%d)", p);
-
-
+// output += sprintf( output, " p(%d)", p);
+
+
if (breg == LIMM_REG)
{
@@ -947,7 +926,6 @@ int arcompact_handle04_2a_dasm(DASM_OPS_32) // Load FROM Auxiliary register TO
if (p == 0)
{
-
COMMON32_GET_creg
COMMON32_GET_areg_reserved
@@ -960,7 +938,7 @@ int arcompact_handle04_2a_dasm(DASM_OPS_32) // Load FROM Auxiliary register TO
}
output += sprintf( output, "(%08x) ", limm );
-
+
}
else
{
@@ -976,7 +954,7 @@ int arcompact_handle04_2a_dasm(DASM_OPS_32) // Load FROM Auxiliary register TO
int auxreg = u;
PRINT_AUX_REGNAME
-
+
if (ares) output += sprintf( output, "reserved(%02x) ", ares );
}
else if (p == 2)
@@ -996,7 +974,7 @@ int arcompact_handle04_2a_dasm(DASM_OPS_32) // Load FROM Auxiliary register TO
}
int arcompact_handle04_2b_dasm(DASM_OPS_32) // Store TO Auxiliary register FROM register
-{
+{
// code at ~ 40073DFE in leapster bios is manually setting up a loop this way
// rather than using the lPcc opcode
@@ -1010,9 +988,9 @@ int arcompact_handle04_2b_dasm(DASM_OPS_32) // Store TO Auxiliary register FROM
output += sprintf( output, "SR");
if (F) output += sprintf( output, ".<F set, illegal>");
-// output += sprintf( output, " p(%d)", p);
-
-
+// output += sprintf( output, " p(%d)", p);
+
+
if (breg == LIMM_REG)
{
@@ -1031,7 +1009,6 @@ int arcompact_handle04_2b_dasm(DASM_OPS_32) // Store TO Auxiliary register FROM
if (p == 0)
{
-
COMMON32_GET_creg
COMMON32_GET_areg_reserved
@@ -1095,7 +1072,7 @@ int arcompact_handle04_29_dasm(DASM_OPS_32)
int arcompact_handle04_2f_helper_dasm(DASM_OPS_32, const char* optext)
{
- //
+ //
// 0010 0bbb pp10 1111 FBBB CCCC CCII IIII
int size = 4;
@@ -1105,8 +1082,8 @@ int arcompact_handle04_2f_helper_dasm(DASM_OPS_32, const char* optext)
output += sprintf( output, "%s", optext);
output += sprintf( output, "%s", flagbit[F]);
-// output += sprintf( output, " p(%d)", p);
-
+// output += sprintf( output, " p(%d)", p);
+
if (breg == LIMM_REG)
{
output += sprintf(output, " <no dst>, ");
@@ -1125,7 +1102,7 @@ int arcompact_handle04_2f_helper_dasm(DASM_OPS_32, const char* optext)
{
UINT32 limm;
GET_LIMM_32;
- size = 8;
+ size = 8;
output += sprintf( output, "(%08x) ", limm );
}
@@ -1232,11 +1209,11 @@ int arcompact_handle04_3x_helper_dasm(DASM_OPS_32, int dsize, int extend)
else
{
output += sprintf( output, "%s]", regnames[creg]);
- }
+ }
return size;
-
+
}
@@ -1279,7 +1256,7 @@ int arcompact_handle05_29_dasm(DASM_OPS_32) { return arcompact_handle04_helper_
int arcompact_handle05_2f_0x_helper_dasm(DASM_OPS_32, const char* optext)
{
- //
+ //
// 0010 1bbb pp10 1111 FBBB CCCC CCII IIII when pp == 0x00
// or
// 0010 1bbb pp10 1111 FBBB UUUU UUII IIII when pp == 0x01
@@ -1293,9 +1270,9 @@ int arcompact_handle05_2f_0x_helper_dasm(DASM_OPS_32, const char* optext)
output += sprintf( output, "%s", optext);
output += sprintf( output, "%s", flagbit[F]);
-// output += sprintf( output, " p(%d)", p);
-
-
+// output += sprintf( output, " p(%d)", p);
+
+
output += sprintf(output, " %s, ", regnames[breg]);
if (p == 0)
@@ -1306,7 +1283,7 @@ int arcompact_handle05_2f_0x_helper_dasm(DASM_OPS_32, const char* optext)
{
UINT32 limm;
GET_LIMM_32;
- size = 8;
+ size = 8;
output += sprintf( output, "(%08x) ", limm );
}
@@ -1469,7 +1446,7 @@ int arcompact_handle0e_0x_helper_dasm(DASM_OPS_16, const char* optext, int revop
GROUP_0e_GET_h;
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
if (h == LIMM_REG)
{
UINT32 limm;
@@ -1517,7 +1494,7 @@ int arcompact_handle0f_00_0x_helper_dasm(DASM_OPS_16, const char* optext)
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
-
+
print("%s %s", optext, regnames[breg]);
return 2;
@@ -1724,7 +1701,7 @@ int arcompact_handle17_07_dasm(DASM_OPS_16)
}
-// op bits remaining for 0x18_xx subgroups 0x071f
+// op bits remaining for 0x18_xx subgroups 0x071f
int arcompact_handle18_0x_helper_dasm(DASM_OPS_16, const char* optext, int st, int format)
{
@@ -1746,27 +1723,27 @@ int arcompact_handle18_0x_helper_dasm(DASM_OPS_16, const char* optext, int st, i
return 2;
}
-int arcompact_handle18_00_dasm(DASM_OPS_16)
+int arcompact_handle18_00_dasm(DASM_OPS_16)
{
return arcompact_handle18_0x_helper_dasm(DASM_PARAMS, "LD_S", 0,0);
}
-int arcompact_handle18_01_dasm(DASM_OPS_16)
+int arcompact_handle18_01_dasm(DASM_OPS_16)
{
return arcompact_handle18_0x_helper_dasm(DASM_PARAMS, "LDB_S", 0,0);
}
-int arcompact_handle18_02_dasm(DASM_OPS_16)
+int arcompact_handle18_02_dasm(DASM_OPS_16)
{
return arcompact_handle18_0x_helper_dasm(DASM_PARAMS, "ST_S", 1,0);
}
-int arcompact_handle18_03_dasm(DASM_OPS_16)
+int arcompact_handle18_03_dasm(DASM_OPS_16)
{
return arcompact_handle18_0x_helper_dasm(DASM_PARAMS, "STB_S", 1,0);
}
-int arcompact_handle18_04_dasm(DASM_OPS_16)
+int arcompact_handle18_04_dasm(DASM_OPS_16)
{
return arcompact_handle18_0x_helper_dasm(DASM_PARAMS, "ADD_S", 1,1); // check format
}
@@ -1791,8 +1768,8 @@ int arcompact_handle18_05_01_dasm(DASM_OPS_16)
return 2;
}
-// op bits remaining for 0x18_06_xx subgroups 0x0700
-int arcompact_handle18_06_01_dasm(DASM_OPS_16)
+// op bits remaining for 0x18_06_xx subgroups 0x0700
+int arcompact_handle18_06_01_dasm(DASM_OPS_16)
{
int breg;
COMMON16_GET_breg
@@ -1803,7 +1780,7 @@ int arcompact_handle18_06_01_dasm(DASM_OPS_16)
return 2;
}
-int arcompact_handle18_06_11_dasm(DASM_OPS_16)
+int arcompact_handle18_06_11_dasm(DASM_OPS_16)
{
int res = (op & 0x0700) >> 8;
op &= ~0x0700; // all bits now used
@@ -1816,8 +1793,8 @@ int arcompact_handle18_06_11_dasm(DASM_OPS_16)
return 2;
}
-// op bits remaining for 0x18_07_xx subgroups 0x0700
-int arcompact_handle18_07_01_dasm(DASM_OPS_16)
+// op bits remaining for 0x18_07_xx subgroups 0x0700
+int arcompact_handle18_07_01_dasm(DASM_OPS_16)
{
int breg;
COMMON16_GET_breg
@@ -1829,7 +1806,7 @@ int arcompact_handle18_07_01_dasm(DASM_OPS_16)
}
-int arcompact_handle18_07_11_dasm(DASM_OPS_16)
+int arcompact_handle18_07_11_dasm(DASM_OPS_16)
{
int res = (op & 0x0700) >> 8;
op &= ~0x0700; // all bits now used
@@ -1921,7 +1898,7 @@ int arcompact_handle1d_helper_dasm(DASM_OPS_16, const char* optext)
COMMON16_GET_breg;
REG_16BIT_RANGE(breg);
- int s = (op & 0x007f) >> 0; op &= ~0x007f;
+ int s = (op & 0x007f) >> 0; op &= ~0x007f;
if (s & 0x40) s = -0x40 + (s & 0x3f);
print("%s %s, 0 to 0x%08x", optext, regnames[breg], PC_ALIGNED32 + s*2);
@@ -1935,7 +1912,7 @@ int arcompact_handle1d_01_dasm(DASM_OPS_16) { return arcompact_handle1d_helper_
int arcompact_handle1e_0x_helper_dasm(DASM_OPS_16, const char* optext)
{
- int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
+ int s = (op & 0x01ff) >> 0; op &= ~0x01ff;
if (s & 0x100) s = -0x100 + (s & 0xff);
print("%s %08x", optext, PC_ALIGNED32 + s*2);
@@ -1950,7 +1927,7 @@ int arcompact_handle1e_02_dasm(DASM_OPS_16) { return arcompact_handle1e_0x_help
int arcompact_handle1e_03_0x_helper_dasm(DASM_OPS_16, const char* optext)
{
- int s = (op & 0x003f) >> 0; op &= ~0x003f;
+ int s = (op & 0x003f) >> 0; op &= ~0x003f;
if (s & 0x020) s = -0x20 + (s & 0x1f);
print("%s %08x", optext, PC_ALIGNED32 + s*2);
@@ -1968,7 +1945,7 @@ int arcompact_handle1e_03_07_dasm(DASM_OPS_16) { return arcompact_handle1e_03_0
int arcompact_handle1f_dasm(DASM_OPS_16)
{
- int s = (op & 0x07ff) >> 0; op &= ~0x07ff;
+ int s = (op & 0x07ff) >> 0; op &= ~0x07ff;
if (s & 0x400) s = -0x400 + (s & 0x3ff);
print("BL_S %08x", PC_ALIGNED32 + (s*4));
@@ -2389,4 +2366,3 @@ int arcompact_handle18_07_1c_dasm(DASM_OPS_16) { print("<illegal 0x18_07_1c> (%
int arcompact_handle18_07_1d_dasm(DASM_OPS_16) { print("<illegal 0x18_07_1d> (%04x)", op); return 2;}
int arcompact_handle18_07_1e_dasm(DASM_OPS_16) { print("<illegal 0x18_07_1e> (%04x)", op); return 2;}
int arcompact_handle18_07_1f_dasm(DASM_OPS_16) { print("<illegal 0x18_07_1f> (%04x)", op); return 2;}
-
diff --git a/src/emu/cpu/arcompact/arcompactdasm_ops.h b/src/emu/cpu/arcompact/arcompactdasm_ops.h
index 5bdd6c67a3b..d853899faa6 100644
--- a/src/emu/cpu/arcompact/arcompactdasm_ops.h
+++ b/src/emu/cpu/arcompact/arcompactdasm_ops.h
@@ -15,8 +15,7 @@
#define GET_LIMM_32 \
limm = oprom[6] | (oprom[7] << 8); \
- limm |= (oprom[4] << 16) | (oprom[5] << 24); \
-
+ limm |= (oprom[4] << 16) | (oprom[5] << 24);
int arcompact_handle00_00_dasm(DASM_OPS_32);
int arcompact_handle00_01_dasm(DASM_OPS_32);
@@ -367,7 +366,7 @@ int arcompact_handle04_2f_3f_3a_dasm(DASM_OPS_32);
int arcompact_handle04_2f_3f_3b_dasm(DASM_OPS_32);
int arcompact_handle04_2f_3f_3c_dasm(DASM_OPS_32);
int arcompact_handle04_2f_3f_3d_dasm(DASM_OPS_32);
-int arcompact_handle04_2f_3f_3e_dasm(DASM_OPS_32);
+int arcompact_handle04_2f_3f_3e_dasm(DASM_OPS_32);
int arcompact_handle04_2f_3f_3f_dasm(DASM_OPS_32);
int arcompact_handle05_2f_00_dasm(DASM_OPS_32);
@@ -632,7 +631,7 @@ int arcompact_handle18_07_15_dasm(DASM_OPS_16);
int arcompact_handle18_07_16_dasm(DASM_OPS_16);
int arcompact_handle18_07_17_dasm(DASM_OPS_16);
int arcompact_handle18_07_18_dasm(DASM_OPS_16);
-int arcompact_handle18_07_19_dasm(DASM_OPS_16);
+int arcompact_handle18_07_19_dasm(DASM_OPS_16);
int arcompact_handle18_07_1a_dasm(DASM_OPS_16);
int arcompact_handle18_07_1b_dasm(DASM_OPS_16);
int arcompact_handle18_07_1c_dasm(DASM_OPS_16);
diff --git a/src/emu/cpu/cpu.mak b/src/emu/cpu/cpu.mak
index 64cfc56c729..da5c799f5f1 100644
--- a/src/emu/cpu/cpu.mak
+++ b/src/emu/cpu/cpu.mak
@@ -129,7 +129,7 @@ $(CPUOBJ)/arcompact/arcompact_common.o: $(CPUSRC)/arcompact/arcompact_common.c
$(CPUOBJ)/arcompact/arcompact.inc: $(CPUSRC)/arcompact/arcompact_make.py
@echo Generating arcompact source .inc files...
$(PYTHON) $(CPUSRC)/arcompact/arcompact_make.py $@
-
+
#-------------------------------------------------
# Acorn ARM series
#
diff --git a/src/emu/cpu/h8/h8_timer16.c b/src/emu/cpu/h8/h8_timer16.c
index d8fa8f89679..56f6089b3f4 100644
--- a/src/emu/cpu/h8/h8_timer16.c
+++ b/src/emu/cpu/h8/h8_timer16.c
@@ -347,7 +347,7 @@ void h8_timer16_device::device_start()
sprintf(tm, "%d", i);
timer_channel[i] = subdevice<h8_timer16_channel_device>(tm);
}
-
+
save_item(NAME(tstr));
}
diff --git a/src/emu/cpu/m68000/m68kcpu.c b/src/emu/cpu/m68000/m68kcpu.c
index 0746edc0b1a..3bf0b84cc49 100644
--- a/src/emu/cpu/m68000/m68kcpu.c
+++ b/src/emu/cpu/m68000/m68kcpu.c
@@ -699,7 +699,7 @@ static void m68k_cause_bus_error(m68000_base_device *m68k)
{
/* only the 68010 throws this unique type-1000 frame */
m68ki_stack_frame_1000(m68k, REG_PPC(m68k), sr, EXCEPTION_BUS_ERROR);
- }
+ }
else if (m68k->mmu_tmp_buserror_address == REG_PPC(m68k))
{
m68ki_stack_frame_1010(m68k, sr, EXCEPTION_BUS_ERROR, REG_PPC(m68k), m68k->mmu_tmp_buserror_address);
diff --git a/src/emu/cpu/m68000/m68kdasm.c b/src/emu/cpu/m68000/m68kdasm.c
index ba3ab3143ba..644e7d47f99 100644
--- a/src/emu/cpu/m68000/m68kdasm.c
+++ b/src/emu/cpu/m68000/m68kdasm.c
@@ -1728,12 +1728,12 @@ static void d68881_ftrap(void)
switch (g_cpu_ir & 0x7)
{
- case 2: // word operand
+ case 2: // word operand
w3 = read_imm_16();
sprintf(g_dasm_str, "ftrap%s.w $%04x", g_cpcc[w2 & 0x3f], w3);
break;
- case 3: // long word operand
+ case 3: // long word operand
l2 = read_imm_32();
sprintf(g_dasm_str, "ftrap%s.l $%08x", g_cpcc[w2 & 0x3f], l2);
break;
diff --git a/src/emu/cpu/pps4/pps4.c b/src/emu/cpu/pps4/pps4.c
index de48dd45081..af3b1290c5e 100644
--- a/src/emu/cpu/pps4/pps4.c
+++ b/src/emu/cpu/pps4/pps4.c
@@ -71,10 +71,10 @@
const device_type PPS4 = &device_creator<pps4_device>;
pps4_device::pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
- : cpu_device(mconfig, PPS4, "PPS4", tag, owner, clock, "pps4", __FILE__ )
- , m_program_config("program", ENDIANNESS_LITTLE, 8, 12)
- , m_data_config("data", ENDIANNESS_LITTLE, 8, 12) // 4bit RAM
- , m_io_config("io", ENDIANNESS_LITTLE, 8, 8) // 4bit IO
+ : cpu_device(mconfig, PPS4, "PPS4", tag, owner, clock, "pps4", __FILE__ )
+ , m_program_config("program", ENDIANNESS_LITTLE, 8, 12)
+ , m_data_config("data", ENDIANNESS_LITTLE, 8, 12) // 4bit RAM
+ , m_io_config("io", ENDIANNESS_LITTLE, 8, 8) // 4bit IO
{
}
@@ -84,9 +84,9 @@ pps4_device::pps4_device(const machine_config &mconfig, const char *tag, device_
*/
UINT8 pps4_device::M()
{
- UINT8 ret = m_data->read_byte(m_B & ~m_SAG);
- m_SAG = 0;
- return ret;
+ UINT8 ret = m_data->read_byte(m_B & ~m_SAG);
+ m_SAG = 0;
+ return ret;
}
@@ -96,14 +96,14 @@ UINT8 pps4_device::M()
*/
void pps4_device::W(UINT8 data)
{
- m_data->write_byte(m_B & ~m_SAG, data);
- m_SAG = 0;
+ m_data->write_byte(m_B & ~m_SAG, data);
+ m_SAG = 0;
}
offs_t pps4_device::disasm_disassemble(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram, UINT32 options)
{
- extern CPU_DISASSEMBLE( pps4 );
- return CPU_DISASSEMBLE_NAME(pps4)(this, buffer, pc, oprom, opram, options);
+ extern CPU_DISASSEMBLE( pps4 );
+ return CPU_DISASSEMBLE_NAME(pps4)(this, buffer, pc, oprom, opram, options);
}
/**
@@ -115,11 +115,11 @@ offs_t pps4_device::disasm_disassemble(char *buffer, offs_t pc, const UINT8 *opr
*/
inline UINT8 pps4_device::ROP()
{
- const UINT8 op = m_direct->read_decrypted_byte(m_P & 0xFFF);
- m_Ip = m_I1; // save previous opcode
- m_P = (m_P + 1) & 0xFFF;
- m_icount -= 1;
- return op;
+ const UINT8 op = m_direct->read_decrypted_byte(m_P & 0xFFF);
+ m_Ip = m_I1; // save previous opcode
+ m_P = (m_P + 1) & 0xFFF;
+ m_icount -= 1;
+ return op;
}
/**
@@ -131,10 +131,10 @@ inline UINT8 pps4_device::ROP()
*/
inline UINT8 pps4_device::ARG()
{
- const UINT8 arg = m_direct->read_raw_byte(m_P & 0xFFF);
- m_P = (m_P + 1) & 0xFFF;
- m_icount -= 1;
- return arg;
+ const UINT8 arg = m_direct->read_raw_byte(m_P & 0xFFF);
+ m_P = (m_P + 1) & 0xFFF;
+ m_icount -= 1;
+ return arg;
}
/**
@@ -173,9 +173,9 @@ inline UINT8 pps4_device::ARG()
*/
void pps4_device::iAD()
{
- m_A = m_A + M();
- m_C = (m_A >> 4) & 1;
- m_A = m_A & 15;
+ m_A = m_A + M();
+ m_C = (m_A >> 4) & 1;
+ m_A = m_A & 15;
}
/**
@@ -193,9 +193,9 @@ void pps4_device::iAD()
*/
void pps4_device::iADC()
{
- m_A = m_A + M() + m_C;
- m_C = m_A >> 4;
- m_A = m_A & 15;
+ m_A = m_A + M() + m_C;
+ m_C = m_A >> 4;
+ m_A = m_A & 15;
}
/**
@@ -214,10 +214,10 @@ void pps4_device::iADC()
*/
void pps4_device::iADSK()
{
- m_A = m_A + M();
- m_C = m_A >> 4;
- m_Skip = m_C;
- m_A = m_A & 15;
+ m_A = m_A + M();
+ m_C = m_A >> 4;
+ m_Skip = m_C;
+ m_A = m_A & 15;
}
/**
@@ -236,10 +236,10 @@ void pps4_device::iADSK()
*/
void pps4_device::iADCSK()
{
- m_A = m_A + M() + m_C;
- m_C = m_A >> 4;
- m_Skip = m_C;
- m_A = m_A & 15;
+ m_A = m_A + M() + m_C;
+ m_C = m_A >> 4;
+ m_Skip = m_C;
+ m_A = m_A & 15;
}
/**
@@ -265,10 +265,10 @@ void pps4_device::iADCSK()
*/
void pps4_device::iADI()
{
- const UINT8 imm = ~m_I1 & 15;
- m_A = m_A + imm;
- m_Skip = (m_A >> 4) & 1;
- m_A = m_A & 15;
+ const UINT8 imm = ~m_I1 & 15;
+ m_A = m_A + imm;
+ m_Skip = (m_A >> 4) & 1;
+ m_A = m_A & 15;
}
/**
@@ -288,7 +288,7 @@ void pps4_device::iADI()
*/
void pps4_device::iDC()
{
- m_A = m_A + 10;
+ m_A = m_A + 10;
}
/**
@@ -307,7 +307,7 @@ void pps4_device::iDC()
*/
void pps4_device::iAND()
{
- m_A = m_A & M();
+ m_A = m_A & M();
}
/**
@@ -326,7 +326,7 @@ void pps4_device::iAND()
*/
void pps4_device::iOR()
{
- m_A = m_A | M();
+ m_A = m_A | M();
}
/**
@@ -346,7 +346,7 @@ void pps4_device::iOR()
*/
void pps4_device::iEOR()
{
- m_A = m_A ^ M();
+ m_A = m_A ^ M();
}
/**
@@ -364,7 +364,7 @@ void pps4_device::iEOR()
*/
void pps4_device::iCOMP()
{
- m_A = m_A ^ 15;
+ m_A = m_A ^ 15;
}
/**
@@ -381,7 +381,7 @@ void pps4_device::iCOMP()
*/
void pps4_device::iSC()
{
- m_C = 1;
+ m_C = 1;
}
/**
@@ -398,7 +398,7 @@ void pps4_device::iSC()
*/
void pps4_device::iRC()
{
- m_C = 0;
+ m_C = 0;
}
/**
@@ -415,7 +415,7 @@ void pps4_device::iRC()
*/
void pps4_device::iSF1()
{
- m_FF1 = 1;
+ m_FF1 = 1;
}
/**
@@ -432,7 +432,7 @@ void pps4_device::iSF1()
*/
void pps4_device::iRF1()
{
- m_FF1 = 0;
+ m_FF1 = 0;
}
/**
@@ -449,7 +449,7 @@ void pps4_device::iRF1()
*/
void pps4_device::iSF2()
{
- m_FF2 = 1;
+ m_FF2 = 1;
}
/**
@@ -466,7 +466,7 @@ void pps4_device::iSF2()
*/
void pps4_device::iRF2()
{
- m_FF2 = 0;
+ m_FF2 = 0;
}
/**
@@ -490,9 +490,9 @@ void pps4_device::iRF2()
*/
void pps4_device::iLD()
{
- const UINT16 i3c = ~m_I1 & 7;
- m_A = M();
- m_B = m_B ^ (i3c << 4);
+ const UINT16 i3c = ~m_I1 & 7;
+ m_A = M();
+ m_B = m_B ^ (i3c << 4);
}
/**
@@ -513,11 +513,11 @@ void pps4_device::iLD()
*/
void pps4_device::iEX()
{
- const UINT16 i3c = ~m_I1 & 7;
- const UINT8 mem = M();
- W(m_A);
- m_A = mem;
- m_B = m_B ^ (i3c << 4);
+ const UINT16 i3c = ~m_I1 & 7;
+ const UINT8 mem = M();
+ W(m_A);
+ m_A = mem;
+ m_B = m_B ^ (i3c << 4);
}
/**
@@ -542,20 +542,20 @@ void pps4_device::iEX()
*/
void pps4_device::iEXD()
{
- const UINT8 i3c = ~m_I1 & 7;
- const UINT8 mem = M();
- UINT8 bl = m_B & 15;
- W(m_A);
- m_A = mem;
- m_B = m_B ^ (i3c << 4);
- // if decrement BL wraps to 1111b
- if (0 == bl) {
- bl = 15;
- m_Skip = 1;
- } else {
- bl = bl - 1;
- }
- m_B = (m_B & ~15) | bl;
+ const UINT8 i3c = ~m_I1 & 7;
+ const UINT8 mem = M();
+ UINT8 bl = m_B & 15;
+ W(m_A);
+ m_A = mem;
+ m_B = m_B ^ (i3c << 4);
+ // if decrement BL wraps to 1111b
+ if (0 == bl) {
+ bl = 15;
+ m_Skip = 1;
+ } else {
+ bl = bl - 1;
+ }
+ m_B = (m_B & ~15) | bl;
}
/**
@@ -579,12 +579,12 @@ void pps4_device::iEXD()
*/
void pps4_device::iLDI()
{
- // previous LDI instruction?
- if (0x70 == (m_Ip & 0xf0)) {
- LOG(("%s: skip prev:%02x op:%02x\n", __FUNCTION__, m_Ip, m_I1));
- return;
- }
- m_A = ~m_I1 & 15;
+ // previous LDI instruction?
+ if (0x70 == (m_Ip & 0xf0)) {
+ LOG(("%s: skip prev:%02x op:%02x\n", __FUNCTION__, m_Ip, m_I1));
+ return;
+ }
+ m_A = ~m_I1 & 15;
}
/**
@@ -602,7 +602,7 @@ void pps4_device::iLDI()
*/
void pps4_device::iLAX()
{
- m_A = m_X;
+ m_A = m_X;
}
/**
@@ -620,7 +620,7 @@ void pps4_device::iLAX()
*/
void pps4_device::iLXA()
{
- m_X = m_A;
+ m_X = m_A;
}
/**
@@ -638,7 +638,7 @@ void pps4_device::iLXA()
*/
void pps4_device::iLABL()
{
- m_A = m_B & 15;
+ m_A = m_B & 15;
}
/**
@@ -656,7 +656,7 @@ void pps4_device::iLABL()
*/
void pps4_device::iLBMX()
{
- m_B = (m_B & ~(15 << 4)) | (m_X << 4);
+ m_B = (m_B & ~(15 << 4)) | (m_X << 4);
}
/**
@@ -676,8 +676,8 @@ void pps4_device::iLBMX()
*/
void pps4_device::iLBUA()
{
- m_B = (m_B & ~(15 << 8)) | (m_A << 8);
- m_A = M();
+ m_B = (m_B & ~(15 << 8)) | (m_A << 8);
+ m_A = M();
}
/**
@@ -695,10 +695,10 @@ void pps4_device::iLBUA()
*/
void pps4_device::iXABL()
{
- // swap A and BL
- UINT8 bl = m_B & 15;
- m_B = (m_B & ~15) | m_A;
- m_A = bl;
+ // swap A and BL
+ UINT8 bl = m_B & 15;
+ m_B = (m_B & ~15) | m_A;
+ m_A = bl;
}
/**
@@ -716,10 +716,10 @@ void pps4_device::iXABL()
*/
void pps4_device::iXBMX()
{
- // swap X and BM
- const UINT8 bm = (m_B >> 4) & 15;
- m_B = (m_B & ~(15 << 4)) | (m_X << 4);
- m_X = bm;
+ // swap X and BM
+ const UINT8 bm = (m_B >> 4) & 15;
+ m_B = (m_B & ~(15 << 4)) | (m_X << 4);
+ m_X = bm;
}
/**
@@ -737,10 +737,10 @@ void pps4_device::iXBMX()
*/
void pps4_device::iXAX()
{
- // swap A and X
- m_A ^= m_X;
- m_X ^= m_A;
- m_A ^= m_X;
+ // swap A and X
+ m_A ^= m_X;
+ m_X ^= m_A;
+ m_A ^= m_X;
}
/**
@@ -758,10 +758,10 @@ void pps4_device::iXAX()
*/
void pps4_device::iXS()
{
- // swap SA and SB
- m_SA ^= m_SB;
- m_SB ^= m_SA;
- m_SA ^= m_SB;
+ // swap SA and SB
+ m_SA ^= m_SB;
+ m_SB ^= m_SA;
+ m_SA ^= m_SB;
}
/**
@@ -786,9 +786,9 @@ void pps4_device::iXS()
*/
void pps4_device::iCYS()
{
- const UINT16 sa = (m_SA >> 4) | (m_A << 8);
- m_A = m_SA & 15;
- m_SA = sa;
+ const UINT16 sa = (m_SA >> 4) | (m_A << 8);
+ m_A = m_SA & 15;
+ m_SA = sa;
}
/**
@@ -826,20 +826,20 @@ void pps4_device::iCYS()
*/
void pps4_device::iLB()
{
- // previous LB or LBL instruction?
- if (0xc0 == (m_Ip & 0xf0) || 0x00 == m_Ip) {
- LOG(("%s: skip prev:%02x op:%02x\n", __FUNCTION__, m_Ip, m_I1));
- return;
- }
- m_SB = m_SA;
- m_SA = (m_P + 1) & 0xFFF;
- m_P = (3 << 6) | (m_I1 & 15);
- m_B = ~ARG() & 255;
- m_P = m_SA;
- // swap SA and SB
- m_SA ^= m_SB;
- m_SB ^= m_SA;
- m_SA ^= m_SB;
+ // previous LB or LBL instruction?
+ if (0xc0 == (m_Ip & 0xf0) || 0x00 == m_Ip) {
+ LOG(("%s: skip prev:%02x op:%02x\n", __FUNCTION__, m_Ip, m_I1));
+ return;
+ }
+ m_SB = m_SA;
+ m_SA = (m_P + 1) & 0xFFF;
+ m_P = (3 << 6) | (m_I1 & 15);
+ m_B = ~ARG() & 255;
+ m_P = m_SA;
+ // swap SA and SB
+ m_SA ^= m_SB;
+ m_SB ^= m_SA;
+ m_SA ^= m_SB;
}
/**
@@ -867,13 +867,13 @@ void pps4_device::iLB()
*/
void pps4_device::iLBL()
{
- m_I2 = ARG();
- // previous LB or LBL instruction?
- if (0xc0 == (m_Ip & 0xf0) || 0x00 == m_Ip) {
- LOG(("%s: skip prev:%02x op:%02x\n", __FUNCTION__, m_Ip, m_I1));
- return;
- }
- m_B = ~m_I2 & 255; // Note: immediate is 1's complement
+ m_I2 = ARG();
+ // previous LB or LBL instruction?
+ if (0xc0 == (m_Ip & 0xf0) || 0x00 == m_Ip) {
+ LOG(("%s: skip prev:%02x op:%02x\n", __FUNCTION__, m_Ip, m_I1));
+ return;
+ }
+ m_B = ~m_I2 & 255; // Note: immediate is 1's complement
}
/**
@@ -893,13 +893,13 @@ void pps4_device::iLBL()
*/
void pps4_device::iINCB()
{
- UINT8 bl = m_B & 15;
- bl = (bl + 1) & 15;
- if (0 == bl) {
- LOG(("%s: skip BL=%x\n", __FUNCTION__, bl));
- m_Skip = 1;
- }
- m_B = (m_B & ~15) | bl;
+ UINT8 bl = m_B & 15;
+ bl = (bl + 1) & 15;
+ if (0 == bl) {
+ LOG(("%s: skip BL=%x\n", __FUNCTION__, bl));
+ m_Skip = 1;
+ }
+ m_B = (m_B & ~15) | bl;
}
/**
@@ -919,13 +919,13 @@ void pps4_device::iINCB()
*/
void pps4_device::iDECB()
{
- UINT8 bl = m_B & 15;
- bl = (bl - 1) & 15;
- if (15 == bl) {
- LOG(("%s: skip BL=%x\n", __FUNCTION__, bl));
- m_Skip = 1;
- }
- m_B = (m_B & ~15) | bl;
+ UINT8 bl = m_B & 15;
+ bl = (bl - 1) & 15;
+ if (15 == bl) {
+ LOG(("%s: skip BL=%x\n", __FUNCTION__, bl));
+ m_Skip = 1;
+ }
+ m_B = (m_B & ~15) | bl;
}
/**
@@ -945,9 +945,9 @@ void pps4_device::iDECB()
*/
void pps4_device::iT()
{
- const UINT16 p = (m_P & ~63) | (m_I1 & 63);
- LOG(("%s: P=%03x I=%02x -> P=%03x\n", __FUNCTION__, m_P, m_I1, p));
- m_P = p;
+ const UINT16 p = (m_P & ~63) | (m_I1 & 63);
+ LOG(("%s: P=%03x I=%02x -> P=%03x\n", __FUNCTION__, m_P, m_I1, p));
+ m_P = p;
}
/**
@@ -977,11 +977,11 @@ void pps4_device::iT()
*/
void pps4_device::iTM()
{
- m_SB = m_SA;
- m_SA = m_P;
- m_P = (3 << 6) | (m_I1 & 63);
- m_I2 = ARG();
- m_P = (1 << 8) | m_I2;
+ m_SB = m_SA;
+ m_SA = m_P;
+ m_P = (3 << 6) | (m_I1 & 63);
+ m_I2 = ARG();
+ m_P = (1 << 8) | m_I2;
}
/**
@@ -1003,8 +1003,8 @@ void pps4_device::iTM()
*/
void pps4_device::iTL()
{
- m_I2 = ARG();
- m_P = ((m_I1 & 15) << 8) | m_I2;
+ m_I2 = ARG();
+ m_P = ((m_I1 & 15) << 8) | m_I2;
}
/**
@@ -1028,10 +1028,10 @@ void pps4_device::iTL()
*/
void pps4_device::iTML()
{
- m_I2 = ARG();
- m_SB = m_SA;
- m_SA = m_P;
- m_P = ((m_I1 & 15) << 8) | m_I2;
+ m_I2 = ARG();
+ m_SB = m_SA;
+ m_SA = m_P;
+ m_P = ((m_I1 & 15) << 8) | m_I2;
}
/**
@@ -1048,7 +1048,7 @@ void pps4_device::iTML()
*/
void pps4_device::iSKC()
{
- m_Skip = m_C;
+ m_Skip = m_C;
}
/**
@@ -1065,7 +1065,7 @@ void pps4_device::iSKC()
*/
void pps4_device::iSKZ()
{
- m_Skip = (0 == m_A) ? 1 : 0;
+ m_Skip = (0 == m_A) ? 1 : 0;
}
/**
@@ -1084,9 +1084,9 @@ void pps4_device::iSKZ()
*/
void pps4_device::iSKBI()
{
- const UINT8 i4 = m_I1 & 15;
- const UINT8 bl = m_B & 15;
- m_Skip = bl == i4 ? 1 : 0;
+ const UINT8 i4 = m_I1 & 15;
+ const UINT8 bl = m_B & 15;
+ m_Skip = bl == i4 ? 1 : 0;
}
/**
@@ -1101,7 +1101,7 @@ void pps4_device::iSKBI()
*/
void pps4_device::iSKF1()
{
- m_Skip = m_FF1;
+ m_Skip = m_FF1;
}
/**
@@ -1116,7 +1116,7 @@ void pps4_device::iSKF1()
*/
void pps4_device::iSKF2()
{
- m_Skip = m_FF2;
+ m_Skip = m_FF2;
}
/**
@@ -1135,11 +1135,11 @@ void pps4_device::iSKF2()
*/
void pps4_device::iRTN()
{
- m_P = m_SA & 0xFFF;
- // swap SA and SB
- m_SA ^= m_SB;
- m_SB ^= m_SA;
- m_SA ^= m_SB;
+ m_P = m_SA & 0xFFF;
+ // swap SA and SB
+ m_SA ^= m_SB;
+ m_SB ^= m_SA;
+ m_SA ^= m_SB;
}
/**
@@ -1158,12 +1158,12 @@ void pps4_device::iRTN()
*/
void pps4_device::iRTNSK()
{
- m_P = m_SA & 0xFFF;
- // swap SA and SB
- m_SA ^= m_SB;
- m_SB ^= m_SA;
- m_SA ^= m_SB;
- m_Skip = 1; // next opcode is ignored
+ m_P = m_SA & 0xFFF;
+ // swap SA and SB
+ m_SA ^= m_SB;
+ m_SB ^= m_SA;
+ m_SA ^= m_SB;
+ m_Skip = 1; // next opcode is ignored
}
/**
@@ -1195,13 +1195,13 @@ void pps4_device::iRTNSK()
*/
void pps4_device::iIOL()
{
- UINT8 ac = ((m_B & 15) << 4) | (~m_A & 15);
- m_I2 = ARG();
- m_io->write_byte(m_I2, ac);
- LOG(("%s: port:%02x <- %x\n", __FUNCTION__, m_I2, ac));
- ac = m_io->read_byte(m_I2) & 15;
- LOG(("%s: port:%02x -> %x\n", __FUNCTION__, m_I2, ac));
- m_A = ~ac & 15;
+ UINT8 ac = ((m_B & 15) << 4) | (~m_A & 15);
+ m_I2 = ARG();
+ m_io->write_byte(m_I2, ac);
+ LOG(("%s: port:%02x <- %x\n", __FUNCTION__, m_I2, ac));
+ ac = m_io->read_byte(m_I2) & 15;
+ LOG(("%s: port:%02x -> %x\n", __FUNCTION__, m_I2, ac));
+ m_A = ~ac & 15;
}
/**
@@ -1219,7 +1219,7 @@ void pps4_device::iIOL()
*/
void pps4_device::iDIA()
{
- m_A = m_io->read_byte(PPS4_PORT_A) & 15;
+ m_A = m_io->read_byte(PPS4_PORT_A) & 15;
}
/**
@@ -1237,7 +1237,7 @@ void pps4_device::iDIA()
*/
void pps4_device::iDIB()
{
- m_A = m_io->read_byte(PPS4_PORT_B) & 15;
+ m_A = m_io->read_byte(PPS4_PORT_B) & 15;
}
/**
@@ -1255,7 +1255,7 @@ void pps4_device::iDIB()
*/
void pps4_device::iDOA()
{
- m_io->write_byte(PPS4_PORT_A, m_A);
+ m_io->write_byte(PPS4_PORT_A, m_A);
}
/**
@@ -1277,8 +1277,8 @@ void pps4_device::iDOA()
*/
void pps4_device::iSAG()
{
- // mask bits 12:5 on next memory access
- m_SAG = 0xff0;
+ // mask bits 12:5 on next memory access
+ m_SAG = 0xff0;
}
/***************************************************************************
@@ -1286,227 +1286,227 @@ void pps4_device::iSAG()
***************************************************************************/
void pps4_device::execute_one()
{
- m_I1 = ROP();
- if (m_Skip) {
- m_Skip = 0;
- LOG(("%s: skip op:%02x\n", __FUNCTION__, m_I1));
- return;
- }
- switch (m_I1) {
- case 0x00:
- iLBL();
- break;
- case 0x01:
- iTML();
- break;
- case 0x02:
- iTML();
- break;
- case 0x03:
- iTML();
- break;
- case 0x04:
- iLBUA();
- break;
- case 0x05:
- iRTN();
- break;
- case 0x06:
- iXS();
- break;
- case 0x07:
- iRTNSK();
- break;
- case 0x08:
- iADCSK();
- break;
- case 0x09:
- iADSK();
- break;
- case 0x0a:
- iADC();
- break;
- case 0x0b:
- iAD();
- break;
- case 0x0c:
- iEOR();
- break;
- case 0x0d:
- iAND();
- break;
- case 0x0e:
- iCOMP();
- break;
- case 0x0f:
- iOR();
- break;
-
- case 0x10:
- iLBMX();
- break;
- case 0x11:
- iLABL();
- break;
- case 0x12:
- iLAX();
- break;
- case 0x13:
- iSAG();
- break;
- case 0x14:
- iSKF2();
- break;
- case 0x15:
- iSKC();
- break;
- case 0x16:
- iSKF1();
- break;
- case 0x17:
- iINCB();
- break;
- case 0x18:
- iXBMX();
- break;
- case 0x19:
- iXABL();
- break;
- case 0x1a:
- iXAX();
- break;
- case 0x1b:
- iLXA();
- break;
- case 0x1c:
- iIOL();
- break;
- case 0x1d:
- iDOA();
- break;
- case 0x1e:
- iSKZ();
- break;
- case 0x1f:
- iDECB();
- break;
-
- case 0x20:
- iSC();
- break;
- case 0x21:
- iSF2();
- break;
- case 0x22:
- iSF1();
- break;
- case 0x23:
- iDIB();
- break;
- case 0x24:
- iRC();
- break;
- case 0x25:
- iRF2();
- break;
- case 0x26:
- iRF1();
- break;
- case 0x27:
- iDIA();
- break;
-
- case 0x28: case 0x29: case 0x2a: case 0x2b:
- case 0x2c: case 0x2d: case 0x2e: case 0x2f:
- iEXD();
- break;
-
- case 0x30: case 0x31: case 0x32: case 0x33:
- case 0x34: case 0x35: case 0x36: case 0x37:
- iLD();
- break;
-
- case 0x38: case 0x39: case 0x3a: case 0x3b:
- case 0x3c: case 0x3d: case 0x3e: case 0x3f:
- iEX();
- break;
-
- case 0x40: case 0x41: case 0x42: case 0x43:
- case 0x44: case 0x45: case 0x46: case 0x47:
- case 0x48: case 0x49: case 0x4a: case 0x4b:
- case 0x4c: case 0x4d: case 0x4e: case 0x4f:
- iSKBI();
- break;
-
- case 0x50: case 0x51: case 0x52: case 0x53:
- case 0x54: case 0x55: case 0x56: case 0x57:
- case 0x58: case 0x59: case 0x5a: case 0x5b:
- case 0x5c: case 0x5d: case 0x5e: case 0x5f:
- iTL();
- break;
-
- case 0x65:
- iDC();
- break;
-
- case 0x60: case 0x61: case 0x62: case 0x63:
- case 0x64: case 0x66: case 0x67:
- case 0x68: case 0x69: case 0x6a: case 0x6b:
- case 0x6c: case 0x6d: case 0x6e:
- iADI();
- break;
-
- case 0x6f:
- iCYS();
- break;
-
- case 0x70: case 0x71: case 0x72: case 0x73:
- case 0x74: case 0x75: case 0x76: case 0x77:
- case 0x78: case 0x79: case 0x7a: case 0x7b:
- case 0x7c: case 0x7d: case 0x7e: case 0x7f:
- iLDI();
- break;
-
- case 0x80: case 0x81: case 0x82: case 0x83:
- case 0x84: case 0x85: case 0x86: case 0x87:
- case 0x88: case 0x89: case 0x8a: case 0x8b:
- case 0x8c: case 0x8d: case 0x8e: case 0x8f:
- case 0x90: case 0x91: case 0x92: case 0x93:
- case 0x94: case 0x95: case 0x96: case 0x97:
- case 0x98: case 0x99: case 0x9a: case 0x9b:
- case 0x9c: case 0x9d: case 0x9e: case 0x9f:
- case 0xa0: case 0xa1: case 0xa2: case 0xa3:
- case 0xa4: case 0xa5: case 0xa6: case 0xa7:
- case 0xa8: case 0xa9: case 0xaa: case 0xab:
- case 0xac: case 0xad: case 0xae: case 0xaf:
- case 0xb0: case 0xb1: case 0xb2: case 0xb3:
- case 0xb4: case 0xb5: case 0xb6: case 0xb7:
- case 0xb8: case 0xb9: case 0xba: case 0xbb:
- case 0xbc: case 0xbd: case 0xbe: case 0xbf:
- iT();
- break;
-
-
- case 0xc0: case 0xc1: case 0xc2: case 0xc3:
- case 0xc4: case 0xc5: case 0xc6: case 0xc7:
- case 0xc8: case 0xc9: case 0xca: case 0xcb:
- case 0xcc: case 0xcd: case 0xce: case 0xcf:
- iLB();
- break;
-
- default:
- iTM();
- }
+ m_I1 = ROP();
+ if (m_Skip) {
+ m_Skip = 0;
+ LOG(("%s: skip op:%02x\n", __FUNCTION__, m_I1));
+ return;
+ }
+ switch (m_I1) {
+ case 0x00:
+ iLBL();
+ break;
+ case 0x01:
+ iTML();
+ break;
+ case 0x02:
+ iTML();
+ break;
+ case 0x03:
+ iTML();
+ break;
+ case 0x04:
+ iLBUA();
+ break;
+ case 0x05:
+ iRTN();
+ break;
+ case 0x06:
+ iXS();
+ break;
+ case 0x07:
+ iRTNSK();
+ break;
+ case 0x08:
+ iADCSK();
+ break;
+ case 0x09:
+ iADSK();
+ break;
+ case 0x0a:
+ iADC();
+ break;
+ case 0x0b:
+ iAD();
+ break;
+ case 0x0c:
+ iEOR();
+ break;
+ case 0x0d:
+ iAND();
+ break;
+ case 0x0e:
+ iCOMP();
+ break;
+ case 0x0f:
+ iOR();
+ break;
+
+ case 0x10:
+ iLBMX();
+ break;
+ case 0x11:
+ iLABL();
+ break;
+ case 0x12:
+ iLAX();
+ break;
+ case 0x13:
+ iSAG();
+ break;
+ case 0x14:
+ iSKF2();
+ break;
+ case 0x15:
+ iSKC();
+ break;
+ case 0x16:
+ iSKF1();
+ break;
+ case 0x17:
+ iINCB();
+ break;
+ case 0x18:
+ iXBMX();
+ break;
+ case 0x19:
+ iXABL();
+ break;
+ case 0x1a:
+ iXAX();
+ break;
+ case 0x1b:
+ iLXA();
+ break;
+ case 0x1c:
+ iIOL();
+ break;
+ case 0x1d:
+ iDOA();
+ break;
+ case 0x1e:
+ iSKZ();
+ break;
+ case 0x1f:
+ iDECB();
+ break;
+
+ case 0x20:
+ iSC();
+ break;
+ case 0x21:
+ iSF2();
+ break;
+ case 0x22:
+ iSF1();
+ break;
+ case 0x23:
+ iDIB();
+ break;
+ case 0x24:
+ iRC();
+ break;
+ case 0x25:
+ iRF2();
+ break;
+ case 0x26:
+ iRF1();
+ break;
+ case 0x27:
+ iDIA();
+ break;
+
+ case 0x28: case 0x29: case 0x2a: case 0x2b:
+ case 0x2c: case 0x2d: case 0x2e: case 0x2f:
+ iEXD();
+ break;
+
+ case 0x30: case 0x31: case 0x32: case 0x33:
+ case 0x34: case 0x35: case 0x36: case 0x37:
+ iLD();
+ break;
+
+ case 0x38: case 0x39: case 0x3a: case 0x3b:
+ case 0x3c: case 0x3d: case 0x3e: case 0x3f:
+ iEX();
+ break;
+
+ case 0x40: case 0x41: case 0x42: case 0x43:
+ case 0x44: case 0x45: case 0x46: case 0x47:
+ case 0x48: case 0x49: case 0x4a: case 0x4b:
+ case 0x4c: case 0x4d: case 0x4e: case 0x4f:
+ iSKBI();
+ break;
+
+ case 0x50: case 0x51: case 0x52: case 0x53:
+ case 0x54: case 0x55: case 0x56: case 0x57:
+ case 0x58: case 0x59: case 0x5a: case 0x5b:
+ case 0x5c: case 0x5d: case 0x5e: case 0x5f:
+ iTL();
+ break;
+
+ case 0x65:
+ iDC();
+ break;
+
+ case 0x60: case 0x61: case 0x62: case 0x63:
+ case 0x64: case 0x66: case 0x67:
+ case 0x68: case 0x69: case 0x6a: case 0x6b:
+ case 0x6c: case 0x6d: case 0x6e:
+ iADI();
+ break;
+
+ case 0x6f:
+ iCYS();
+ break;
+
+ case 0x70: case 0x71: case 0x72: case 0x73:
+ case 0x74: case 0x75: case 0x76: case 0x77:
+ case 0x78: case 0x79: case 0x7a: case 0x7b:
+ case 0x7c: case 0x7d: case 0x7e: case 0x7f:
+ iLDI();
+ break;
+
+ case 0x80: case 0x81: case 0x82: case 0x83:
+ case 0x84: case 0x85: case 0x86: case 0x87:
+ case 0x88: case 0x89: case 0x8a: case 0x8b:
+ case 0x8c: case 0x8d: case 0x8e: case 0x8f:
+ case 0x90: case 0x91: case 0x92: case 0x93:
+ case 0x94: case 0x95: case 0x96: case 0x97:
+ case 0x98: case 0x99: case 0x9a: case 0x9b:
+ case 0x9c: case 0x9d: case 0x9e: case 0x9f:
+ case 0xa0: case 0xa1: case 0xa2: case 0xa3:
+ case 0xa4: case 0xa5: case 0xa6: case 0xa7:
+ case 0xa8: case 0xa9: case 0xaa: case 0xab:
+ case 0xac: case 0xad: case 0xae: case 0xaf:
+ case 0xb0: case 0xb1: case 0xb2: case 0xb3:
+ case 0xb4: case 0xb5: case 0xb6: case 0xb7:
+ case 0xb8: case 0xb9: case 0xba: case 0xbb:
+ case 0xbc: case 0xbd: case 0xbe: case 0xbf:
+ iT();
+ break;
+
+
+ case 0xc0: case 0xc1: case 0xc2: case 0xc3:
+ case 0xc4: case 0xc5: case 0xc6: case 0xc7:
+ case 0xc8: case 0xc9: case 0xca: case 0xcb:
+ case 0xcc: case 0xcd: case 0xce: case 0xcf:
+ iLB();
+ break;
+
+ default:
+ iTM();
+ }
}
void pps4_device::execute_run()
{
- do
- {
- debugger_instruction_hook(this, m_P);
- execute_one();
+ do
+ {
+ debugger_instruction_hook(this, m_P);
+ execute_one();
- } while (m_icount > 0);
+ } while (m_icount > 0);
}
/***************************************************************************
@@ -1515,54 +1515,54 @@ void pps4_device::execute_run()
void pps4_device::device_start()
{
- m_program = &space(AS_PROGRAM);
- m_direct = &m_program->direct();
- m_data = &space(AS_DATA);
- m_io = &space(AS_IO);
-
- save_item(NAME(m_A));
- save_item(NAME(m_X));
- save_item(NAME(m_P));
- save_item(NAME(m_SA));
- save_item(NAME(m_SB));
- save_item(NAME(m_Skip));
- save_item(NAME(m_SAG));
- save_item(NAME(m_B));
- save_item(NAME(m_C));
- save_item(NAME(m_FF1));
- save_item(NAME(m_FF2));
- save_item(NAME(m_I1));
- save_item(NAME(m_I2));
- save_item(NAME(m_Ip));
-
- state_add( PPS4_PC, "PC", m_P ).mask(0xFFF).formatstr("%03X");
- state_add( PPS4_A, "A", m_A ).formatstr("%01X");
- state_add( PPS4_X, "X", m_X ).formatstr("%01X");
- state_add( PPS4_SA, "SA", m_SA ).formatstr("%03X");
- state_add( PPS4_SB, "SB", m_SB ).formatstr("%03X");
- state_add( PPS4_Skip, "Skip", m_Skip ).formatstr("%01X");
- state_add( PPS4_SAG, "SAG", m_SAG ).formatstr("%03X");
- state_add( PPS4_B, "B", m_B ).formatstr("%03X");
- state_add( PPS4_I1, "I1", m_I1 ).formatstr("%02X").noshow();
- state_add( PPS4_I2, "I2", m_I2 ).formatstr("%02X").noshow();
- state_add( PPS4_Ip, "Ip", m_Ip ).formatstr("%02X").noshow();
- state_add( STATE_GENPC, "GENPC", m_P ).noshow();
- state_add( STATE_GENFLAGS, "GENFLAGS", m_C).formatstr("%3s").noshow();
-
- m_icountptr = &m_icount;
+ m_program = &space(AS_PROGRAM);
+ m_direct = &m_program->direct();
+ m_data = &space(AS_DATA);
+ m_io = &space(AS_IO);
+
+ save_item(NAME(m_A));
+ save_item(NAME(m_X));
+ save_item(NAME(m_P));
+ save_item(NAME(m_SA));
+ save_item(NAME(m_SB));
+ save_item(NAME(m_Skip));
+ save_item(NAME(m_SAG));
+ save_item(NAME(m_B));
+ save_item(NAME(m_C));
+ save_item(NAME(m_FF1));
+ save_item(NAME(m_FF2));
+ save_item(NAME(m_I1));
+ save_item(NAME(m_I2));
+ save_item(NAME(m_Ip));
+
+ state_add( PPS4_PC, "PC", m_P ).mask(0xFFF).formatstr("%03X");
+ state_add( PPS4_A, "A", m_A ).formatstr("%01X");
+ state_add( PPS4_X, "X", m_X ).formatstr("%01X");
+ state_add( PPS4_SA, "SA", m_SA ).formatstr("%03X");
+ state_add( PPS4_SB, "SB", m_SB ).formatstr("%03X");
+ state_add( PPS4_Skip, "Skip", m_Skip ).formatstr("%01X");
+ state_add( PPS4_SAG, "SAG", m_SAG ).formatstr("%03X");
+ state_add( PPS4_B, "B", m_B ).formatstr("%03X");
+ state_add( PPS4_I1, "I1", m_I1 ).formatstr("%02X").noshow();
+ state_add( PPS4_I2, "I2", m_I2 ).formatstr("%02X").noshow();
+ state_add( PPS4_Ip, "Ip", m_Ip ).formatstr("%02X").noshow();
+ state_add( STATE_GENPC, "GENPC", m_P ).noshow();
+ state_add( STATE_GENFLAGS, "GENFLAGS", m_C).formatstr("%3s").noshow();
+
+ m_icountptr = &m_icount;
}
void pps4_device::state_string_export(const device_state_entry &entry, astring &string)
{
- switch (entry.index())
- {
- case STATE_GENFLAGS:
- string.printf("%c%c%c",
- m_C ? 'C':'.',
- m_FF1 ? '1':'.',
- m_FF2 ? '2':'.');
- break;
- }
+ switch (entry.index())
+ {
+ case STATE_GENFLAGS:
+ string.printf("%c%c%c",
+ m_C ? 'C':'.',
+ m_FF1 ? '1':'.',
+ m_FF2 ? '2':'.');
+ break;
+ }
}
/***************************************************************************
@@ -1571,17 +1571,17 @@ void pps4_device::state_string_export(const device_state_entry &entry, astring &
void pps4_device::device_reset()
{
- m_A = 0; // Accumulator A(4:1)
- m_X = 0; // X register X(4:1)
- m_P = 0; // program counter P(12:1)
- m_SA = 0; // Shift register SA(12:1)
- m_SB = 0; // Shift register SB(12:1)
- m_SAG = 0; // Special address generation mask
- m_B = 0; // B address register B(12:1) (BL, BM and BU)
- m_C = 0; // Carry flip-flop
- m_FF1 = 0; // Flip-flop 1
- m_FF2 = 0; // Flip-flop 2
- m_I1 = 0; // Most recent instruction I(8:1)
- m_I2 = 0; // Most recent parameter I2(8:1)
- m_Ip = 0; // Previous instruction I(8:1)
+ m_A = 0; // Accumulator A(4:1)
+ m_X = 0; // X register X(4:1)
+ m_P = 0; // program counter P(12:1)
+ m_SA = 0; // Shift register SA(12:1)
+ m_SB = 0; // Shift register SB(12:1)
+ m_SAG = 0; // Special address generation mask
+ m_B = 0; // B address register B(12:1) (BL, BM and BU)
+ m_C = 0; // Carry flip-flop
+ m_FF1 = 0; // Flip-flop 1
+ m_FF2 = 0; // Flip-flop 2
+ m_I1 = 0; // Most recent instruction I(8:1)
+ m_I2 = 0; // Most recent parameter I2(8:1)
+ m_Ip = 0; // Previous instruction I(8:1)
}
diff --git a/src/emu/cpu/pps4/pps4.h b/src/emu/cpu/pps4/pps4.h
index e5f46906a6c..a001e3cf933 100644
--- a/src/emu/cpu/pps4/pps4.h
+++ b/src/emu/cpu/pps4/pps4.h
@@ -9,22 +9,22 @@
***************************************************************************/
enum
{
- PPS4_PC,
- PPS4_A,
- PPS4_X,
- PPS4_SA,
- PPS4_SB,
- PPS4_B,
- PPS4_Skip,
- PPS4_SAG,
- PPS4_I1,
- PPS4_I2,
- PPS4_Ip,
- PPS4_GENPC = STATE_GENPC,
- PPS4_GENSP = STATE_GENSP,
- PPS4_GENPCBASE = STATE_GENPCBASE,
- PPS4_PORT_A = 256,
- PPS4_PORT_B = 257
+ PPS4_PC,
+ PPS4_A,
+ PPS4_X,
+ PPS4_SA,
+ PPS4_SB,
+ PPS4_B,
+ PPS4_Skip,
+ PPS4_SAG,
+ PPS4_I1,
+ PPS4_I2,
+ PPS4_Ip,
+ PPS4_GENPC = STATE_GENPC,
+ PPS4_GENSP = STATE_GENSP,
+ PPS4_GENPCBASE = STATE_GENPCBASE,
+ PPS4_PORT_A = 256,
+ PPS4_PORT_B = 257
};
/***************************************************************************
@@ -40,128 +40,128 @@ extern const device_type PPS4;
class pps4_device : public cpu_device
{
public:
- // construction/destruction
- pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+ // construction/destruction
+ pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
protected:
- // device-level overrides
- virtual void device_start();
- virtual void device_reset();
-
- // device_execute_interface overrides
- virtual UINT32 execute_min_cycles() const { return 1; }
- virtual UINT32 execute_max_cycles() const { return 3; }
- virtual UINT32 execute_input_lines() const { return 0; }
- virtual UINT32 execute_default_irq_vector() const { return 0; }
- virtual void execute_run();
-
- // device_memory_interface overrides
- virtual const address_space_config *memory_space_config(address_spacenum spacenum = AS_0) const
- {
- return (spacenum == AS_PROGRAM) ? &m_program_config : ( (spacenum == AS_IO) ? &m_io_config : ( (spacenum == AS_DATA) ? &m_data_config : NULL ) );
- }
-
- // device_state_interface overrides
- void state_string_export(const device_state_entry &entry, astring &string);
-
- // device_disasm_interface overrides
- virtual UINT32 disasm_min_opcode_bytes() const { return 1; }
- virtual UINT32 disasm_max_opcode_bytes() const { return 2; }
- virtual offs_t disasm_disassemble(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram, UINT32 options);
+ // device-level overrides
+ virtual void device_start();
+ virtual void device_reset();
+
+ // device_execute_interface overrides
+ virtual UINT32 execute_min_cycles() const { return 1; }
+ virtual UINT32 execute_max_cycles() const { return 3; }
+ virtual UINT32 execute_input_lines() const { return 0; }
+ virtual UINT32 execute_default_irq_vector() const { return 0; }
+ virtual void execute_run();
+
+ // device_memory_interface overrides
+ virtual const address_space_config *memory_space_config(address_spacenum spacenum = AS_0) const
+ {
+ return (spacenum == AS_PROGRAM) ? &m_program_config : ( (spacenum == AS_IO) ? &m_io_config : ( (spacenum == AS_DATA) ? &m_data_config : NULL ) );
+ }
+
+ // device_state_interface overrides
+ void state_string_export(const device_state_entry &entry, astring &string);
+
+ // device_disasm_interface overrides
+ virtual UINT32 disasm_min_opcode_bytes() const { return 1; }
+ virtual UINT32 disasm_max_opcode_bytes() const { return 2; }
+ virtual offs_t disasm_disassemble(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram, UINT32 options);
private:
- address_space_config m_program_config;
- address_space_config m_data_config;
- address_space_config m_io_config;
-
- address_space *m_program;
- direct_read_data *m_direct;
- address_space *m_data;
- address_space *m_io;
- int m_icount;
-
- UINT8 m_A; //!< Accumulator A(4:1)
- UINT8 m_X; //!< X register X(4:1)
- UINT16 m_P; //!< program counter P(12:1)
- UINT16 m_SA; //!< Shift register SA(12:1)
- UINT16 m_SB; //!< Shift register SB(12:1)
- UINT8 m_Skip; //!< Skip next instruction
- UINT16 m_SAG; //!< Special address generation mask
- UINT16 m_B; //!< B register B(12:1) (BL, BM and BH)
- UINT8 m_C; //!< Carry flip-flop
- UINT8 m_FF1; //!< Flip-flop 1
- UINT8 m_FF2; //!< Flip-flop 2
- UINT8 m_I1; //!< Most recent instruction I(8:1)
- UINT8 m_I2; //!< Most recent parameter I2(8:1)
- UINT8 m_Ip; //!< Previous instruction I(8:1)
-
- //! return the contents of B register (made of BU, BM and BL)
- inline UINT16 B() const;
-
- //! return memory at address B(12:1)
- inline UINT8 M();
-
- //! write to memory at address B(12:1)
- inline void W(UINT8 data);
-
- //! return the next opcode (also in m_I)
- inline UINT8 ROP();
-
- //! return the next argument (also in m_I2)
- inline UINT8 ARG();
-
- void iAD(); //!< Add
- void iADC(); //!< Add with carry-in
- void iADSK(); //!< Add and skip on carry-out
- void iADCSK(); //!< Add with carry-in and skip on carry-out
- void iADI(); //!< Add immediate
- void iDC(); //!< Decimal correction
- void iAND(); //!< Logical AND
- void iOR(); //!< Logical OR
- void iEOR(); //!< Logical Exclusive-OR
- void iCOMP(); //!< Complement
- void iSC(); //!< Set Carry flip-flop
- void iRC(); //!< Reset Carry flip-flop
- void iSF1(); //!< Set FF1
- void iRF1(); //!< Reset FF1
- void iSF2(); //!< Set FF2
- void iRF2(); //!< Reset FF2
- void iLD(); //!< Load accumulator from memory
- void iEX(); //!< Exchange accumulator and memory
- void iEXD(); //!< Exchange accumulator and memory and decrement BL
- void iLDI(); //!< Load accumulator immediate
- void iLAX(); //!< Load accumulator from X register
- void iLXA(); //!< Load X register from accumulator
- void iLABL(); //!< Load accumulator with BL
- void iLBMX(); //!< Load BM with X
- void iLBUA(); //!< Load BU with A
- void iXABL(); //!< Exchange accumulator and BL
- void iXBMX(); //!< Exchange BM and X registers
- void iXAX(); //!< Exchange accumulator and X
- void iXS(); //!< Eychange SA and SB registers
- void iCYS(); //!< Cycle SA register and accumulaor
- void iLB(); //!< Load B indirect
- void iLBL(); //!< Load B long
- void iINCB(); //!< Increment BL
- void iDECB(); //!< Decrement BL
- void iT(); //!< Transfer
- void iTM(); //!< Transfer and mark indirect
- void iTL(); //!< Transfer long
- void iTML(); //!< Transfer and mark long
- void iSKC(); //!< Skip on carry flip-flop
- void iSKZ(); //!< Skip on accumulator zero
- void iSKBI(); //!< Skip if BL equal to immediate
- void iSKF1(); //!< Skip if FF1 equals 1
- void iSKF2(); //!< Skip if FF2 equals 1
- void iRTN(); //!< Return
- void iRTNSK(); //!< Return and skip
- void iIOL(); //!< Input/Output long
- void iDIA(); //!< Discrete input group A
- void iDIB(); //!< Discrete input group B
- void iDOA(); //!< Discrete output group A
- void iSAG(); //!< Special address generation
-
- void execute_one(); //!< execute one instruction
+ address_space_config m_program_config;
+ address_space_config m_data_config;
+ address_space_config m_io_config;
+
+ address_space *m_program;
+ direct_read_data *m_direct;
+ address_space *m_data;
+ address_space *m_io;
+ int m_icount;
+
+ UINT8 m_A; //!< Accumulator A(4:1)
+ UINT8 m_X; //!< X register X(4:1)
+ UINT16 m_P; //!< program counter P(12:1)
+ UINT16 m_SA; //!< Shift register SA(12:1)
+ UINT16 m_SB; //!< Shift register SB(12:1)
+ UINT8 m_Skip; //!< Skip next instruction
+ UINT16 m_SAG; //!< Special address generation mask
+ UINT16 m_B; //!< B register B(12:1) (BL, BM and BH)
+ UINT8 m_C; //!< Carry flip-flop
+ UINT8 m_FF1; //!< Flip-flop 1
+ UINT8 m_FF2; //!< Flip-flop 2
+ UINT8 m_I1; //!< Most recent instruction I(8:1)
+ UINT8 m_I2; //!< Most recent parameter I2(8:1)
+ UINT8 m_Ip; //!< Previous instruction I(8:1)
+
+ //! return the contents of B register (made of BU, BM and BL)
+ inline UINT16 B() const;
+
+ //! return memory at address B(12:1)
+ inline UINT8 M();
+
+ //! write to memory at address B(12:1)
+ inline void W(UINT8 data);
+
+ //! return the next opcode (also in m_I)
+ inline UINT8 ROP();
+
+ //! return the next argument (also in m_I2)
+ inline UINT8 ARG();
+
+ void iAD(); //!< Add
+ void iADC(); //!< Add with carry-in
+ void iADSK(); //!< Add and skip on carry-out
+ void iADCSK(); //!< Add with carry-in and skip on carry-out
+ void iADI(); //!< Add immediate
+ void iDC(); //!< Decimal correction
+ void iAND(); //!< Logical AND
+ void iOR(); //!< Logical OR
+ void iEOR(); //!< Logical Exclusive-OR
+ void iCOMP(); //!< Complement
+ void iSC(); //!< Set Carry flip-flop
+ void iRC(); //!< Reset Carry flip-flop
+ void iSF1(); //!< Set FF1
+ void iRF1(); //!< Reset FF1
+ void iSF2(); //!< Set FF2
+ void iRF2(); //!< Reset FF2
+ void iLD(); //!< Load accumulator from memory
+ void iEX(); //!< Exchange accumulator and memory
+ void iEXD(); //!< Exchange accumulator and memory and decrement BL
+ void iLDI(); //!< Load accumulator immediate
+ void iLAX(); //!< Load accumulator from X register
+ void iLXA(); //!< Load X register from accumulator
+ void iLABL(); //!< Load accumulator with BL
+ void iLBMX(); //!< Load BM with X
+ void iLBUA(); //!< Load BU with A
+ void iXABL(); //!< Exchange accumulator and BL
+ void iXBMX(); //!< Exchange BM and X registers
+ void iXAX(); //!< Exchange accumulator and X
+ void iXS(); //!< Eychange SA and SB registers
+ void iCYS(); //!< Cycle SA register and accumulaor
+ void iLB(); //!< Load B indirect
+ void iLBL(); //!< Load B long
+ void iINCB(); //!< Increment BL
+ void iDECB(); //!< Decrement BL
+ void iT(); //!< Transfer
+ void iTM(); //!< Transfer and mark indirect
+ void iTL(); //!< Transfer long
+ void iTML(); //!< Transfer and mark long
+ void iSKC(); //!< Skip on carry flip-flop
+ void iSKZ(); //!< Skip on accumulator zero
+ void iSKBI(); //!< Skip if BL equal to immediate
+ void iSKF1(); //!< Skip if FF1 equals 1
+ void iSKF2(); //!< Skip if FF2 equals 1
+ void iRTN(); //!< Return
+ void iRTNSK(); //!< Return and skip
+ void iIOL(); //!< Input/Output long
+ void iDIA(); //!< Discrete input group A
+ void iDIB(); //!< Discrete input group B
+ void iDOA(); //!< Discrete output group A
+ void iSAG(); //!< Special address generation
+
+ void execute_one(); //!< execute one instruction
};
#endif // __PPS4_H__
diff --git a/src/emu/cpu/pps4/pps4dasm.c b/src/emu/cpu/pps4/pps4dasm.c
index 2f27137ee94..6a06b498232 100644
--- a/src/emu/cpu/pps4/pps4dasm.c
+++ b/src/emu/cpu/pps4/pps4dasm.c
@@ -16,81 +16,81 @@
#define ARG(A) opram[(A) - PC]
typedef enum pps4_token_e {
- t_AD, t_ADC, t_ADSK, t_ADCSK, t_ADI,
- t_DC, t_AND, t_OR, t_EOR, t_COMP,
- t_SC, t_RC, t_SF1, t_RF1, t_SF2,
- t_RF2, t_LD, t_EX, t_EXD, t_LDI,
- t_LAX, t_LXA, t_LABL, t_LBMX, t_LBUA,
- t_XABL, t_XBMX, t_XAX, t_XS, t_CYS,
- t_LB, t_LBL, t_INCB, t_DECB, t_T,
- t_TM, t_TL, t_TML, t_SKC, t_SKZ,
- t_SKBI, t_SKF1, t_SKF2, t_RTN, t_RTNSK,
- t_IOL, t_DIA, t_DIB, t_DOA, t_SAG,
- t_COUNT,
- t_MASK = (1 << 6) - 1,
- t_I3c = 1 << 6, /* immediate 3 bit constant, complemented */
- t_I4 = 1 << 7, /* immediate 4 bit constant */
- t_I4c = 1 << 8, /* immediate 4 bit constant, complemented */
- t_I4p = 1 << 9, /* immediate 4 bit offset into page 3 */
- t_I6p = 1 << 10, /* immediate 6 bit constant; address in current page */
- t_I6i = 1 << 11, /* immediate 6 bit indirect page 3 offset (16 ... 63) + followed by page 1 address */
- t_I8 = 1 << 12, /* immediate 8 bit constant (I/O port number) */
- t_I8c = 1 << 13, /* immediate 8 bit constant inverted */
- t_OVER = 1 << 14, /* Debugger step over (CALL) */
- t_OUT = 1 << 15 /* Debugger step out (RETURN) */
+ t_AD, t_ADC, t_ADSK, t_ADCSK, t_ADI,
+ t_DC, t_AND, t_OR, t_EOR, t_COMP,
+ t_SC, t_RC, t_SF1, t_RF1, t_SF2,
+ t_RF2, t_LD, t_EX, t_EXD, t_LDI,
+ t_LAX, t_LXA, t_LABL, t_LBMX, t_LBUA,
+ t_XABL, t_XBMX, t_XAX, t_XS, t_CYS,
+ t_LB, t_LBL, t_INCB, t_DECB, t_T,
+ t_TM, t_TL, t_TML, t_SKC, t_SKZ,
+ t_SKBI, t_SKF1, t_SKF2, t_RTN, t_RTNSK,
+ t_IOL, t_DIA, t_DIB, t_DOA, t_SAG,
+ t_COUNT,
+ t_MASK = (1 << 6) - 1,
+ t_I3c = 1 << 6, /* immediate 3 bit constant, complemented */
+ t_I4 = 1 << 7, /* immediate 4 bit constant */
+ t_I4c = 1 << 8, /* immediate 4 bit constant, complemented */
+ t_I4p = 1 << 9, /* immediate 4 bit offset into page 3 */
+ t_I6p = 1 << 10, /* immediate 6 bit constant; address in current page */
+ t_I6i = 1 << 11, /* immediate 6 bit indirect page 3 offset (16 ... 63) + followed by page 1 address */
+ t_I8 = 1 << 12, /* immediate 8 bit constant (I/O port number) */
+ t_I8c = 1 << 13, /* immediate 8 bit constant inverted */
+ t_OVER = 1 << 14, /* Debugger step over (CALL) */
+ t_OUT = 1 << 15 /* Debugger step out (RETURN) */
} pps4_token_e;
static const char *token_str[t_COUNT] = {
- "ad", /* add */
- "adc", /* add with carry-in */
- "adsk", /* add and skip on carry-out */
- "adcsk", /* add with carry-in and skip on carry-out */
- "adi", /* add immediate */
- "dc", /* decimal correction */
- "and", /* logical and */
- "or", /* logical or */
- "eor", /* logical exclusive-orf */
- "comp", /* complement */
- "sc", /* set C flip-flop */
- "rc", /* reset C flip-flop */
- "sf1", /* set FF1 flip-flop */
- "rf1", /* reset FF1 flip-flop */
- "sf2", /* set FF2 flip-flop */
- "rf2", /* reset FF2 flip-flop */
- "ld", /* load accumulator from memory */
- "ex", /* exchange accumulator and memory */
- "exd", /* exchange accumulator and memory and decrement BL */
- "ldi", /* load accumulator immediate */
- "lax", /* load accumulator from X register */
- "lxa", /* load X register from accumulator */
- "labl", /* load accumulator with BL */
- "lbmx", /* load BM with X */
- "lbua", /* load BU with A */
- "xabl", /* exchange accumulator and BL */
- "xbmx", /* exchange BM and X */
- "xax", /* exchange accumulator and X */
- "xs", /* exchange SA and SB */
- "cys", /* cycle SA register and accumulator */
- "lb", /* load B indirect */
- "lbl", /* load B long */
- "incb", /* increment BL */
- "decb", /* decrement BL */
- "t", /* transfer */
- "tm", /* transfer and mark indirect */
- "tl", /* transfer long */
- "tml", /* transfer and mark long */
- "skc", /* skip on C flip-flop equals 1 */
- "skz", /* skip on accumulator zero */
- "skbi", /* skip on BL equal to immediate */
- "skf1", /* skip on FF1 flip-flop equals 1 */
- "skf2", /* skip on FF2 flip-flop equals 1 */
- "rtn", /* return */
- "rtnsk", /* return and skip */
- "iol", /* input/output long */
- "dia", /* discrete input group A */
- "dib", /* discrete input group B */
- "doa", /* discrete output */
- "sag" /* special address generation */
+ "ad", /* add */
+ "adc", /* add with carry-in */
+ "adsk", /* add and skip on carry-out */
+ "adcsk", /* add with carry-in and skip on carry-out */
+ "adi", /* add immediate */
+ "dc", /* decimal correction */
+ "and", /* logical and */
+ "or", /* logical or */
+ "eor", /* logical exclusive-orf */
+ "comp", /* complement */
+ "sc", /* set C flip-flop */
+ "rc", /* reset C flip-flop */
+ "sf1", /* set FF1 flip-flop */
+ "rf1", /* reset FF1 flip-flop */
+ "sf2", /* set FF2 flip-flop */
+ "rf2", /* reset FF2 flip-flop */
+ "ld", /* load accumulator from memory */
+ "ex", /* exchange accumulator and memory */
+ "exd", /* exchange accumulator and memory and decrement BL */
+ "ldi", /* load accumulator immediate */
+ "lax", /* load accumulator from X register */
+ "lxa", /* load X register from accumulator */
+ "labl", /* load accumulator with BL */
+ "lbmx", /* load BM with X */
+ "lbua", /* load BU with A */
+ "xabl", /* exchange accumulator and BL */
+ "xbmx", /* exchange BM and X */
+ "xax", /* exchange accumulator and X */
+ "xs", /* exchange SA and SB */
+ "cys", /* cycle SA register and accumulator */
+ "lb", /* load B indirect */
+ "lbl", /* load B long */
+ "incb", /* increment BL */
+ "decb", /* decrement BL */
+ "t", /* transfer */
+ "tm", /* transfer and mark indirect */
+ "tl", /* transfer long */
+ "tml", /* transfer and mark long */
+ "skc", /* skip on C flip-flop equals 1 */
+ "skz", /* skip on accumulator zero */
+ "skbi", /* skip on BL equal to immediate */
+ "skf1", /* skip on FF1 flip-flop equals 1 */
+ "skf2", /* skip on FF2 flip-flop equals 1 */
+ "rtn", /* return */
+ "rtnsk", /* return and skip */
+ "iol", /* input/output long */
+ "dia", /* discrete input group A */
+ "dib", /* discrete input group B */
+ "doa", /* discrete output */
+ "sag" /* special address generation */
};
static const UINT16 table[] = {
@@ -369,75 +369,75 @@ static const UINT16 table[] = {
CPU_DISASSEMBLE( pps4 )
{
- UINT32 flags = 0;
- unsigned PC = pc;
- UINT8 op = OP(pc++);
- UINT32 tok = table[op];
- char *dst = 0;
-
- if (0 == (tok & t_MASK)) {
- sprintf(buffer, "%s", token_str[tok & t_MASK]);
- } else {
- dst = buffer + sprintf(buffer, "%-7s", token_str[tok & t_MASK]);
- }
-
- if (tok & t_I3c) {
- // 3 bit immediate, complemented
- UINT8 i = ~op & 7;
- if (0 != i) // only print if non-zero
- dst += sprintf(dst, "%x", i);
- }
-
- if (tok & t_I4) {
- // 4 bit immediate
- UINT8 i = op & 15;
- dst += sprintf(dst, "%x", i);
- }
-
- if (tok & t_I4c) {
- // 4 bit immediate, complemented
- UINT8 i = ~op & 15;
- dst += sprintf(dst, "%x", i);
- }
-
- if (tok & t_I4p) {
- // 4 bit immediate offset into page 3
- UINT8 i = op & 15;
- dst += sprintf(dst, "[%x]", 0x0c0 | i);
- }
-
- if (tok & t_I6p) {
- // 6 bit immediate offset into current page
- UINT8 i = op & 63;
- dst += sprintf(dst, "%x", (PC & ~63) | i);
- }
-
- if (tok & t_I6i) {
- // 6 bit immediate offset into page 3
- UINT16 i6p3 = (3 << 6) | (op & 63);
- // 8 bit absolute offset at 0x0100
- UINT16 addr = (1 << 8) | 0; // ROM[ip3] can't be reached!?
- (void)addr; // avoid unused variable warning
- dst += sprintf(dst, "[%x]", i6p3);
- }
-
- if (tok & t_I8) {
- // 8 bit immediate I/O port address
- UINT8 arg = ARG(pc++);
- dst += sprintf(dst, "%02x", arg);
- }
-
- if (tok & t_I8c) {
- // 8 bit immediate offset into page
- UINT16 arg = ~ARG(pc++) & 255;
- dst += sprintf(dst, "%02x", arg);
- }
-
- if (tok & t_OVER) // TL or TML
- flags |= DASMFLAG_STEP_OVER;
-
- if (tok & t_OUT) // RTN or RTNSK
- flags |= DASMFLAG_STEP_OUT;
-
- return (pc - PC) | flags | DASMFLAG_SUPPORTED;
+ UINT32 flags = 0;
+ unsigned PC = pc;
+ UINT8 op = OP(pc++);
+ UINT32 tok = table[op];
+ char *dst = 0;
+
+ if (0 == (tok & t_MASK)) {
+ sprintf(buffer, "%s", token_str[tok & t_MASK]);
+ } else {
+ dst = buffer + sprintf(buffer, "%-7s", token_str[tok & t_MASK]);
+ }
+
+ if (tok & t_I3c) {
+ // 3 bit immediate, complemented
+ UINT8 i = ~op & 7;
+ if (0 != i) // only print if non-zero
+ dst += sprintf(dst, "%x", i);
+ }
+
+ if (tok & t_I4) {
+ // 4 bit immediate
+ UINT8 i = op & 15;
+ dst += sprintf(dst, "%x", i);
+ }
+
+ if (tok & t_I4c) {
+ // 4 bit immediate, complemented
+ UINT8 i = ~op & 15;
+ dst += sprintf(dst, "%x", i);
+ }
+
+ if (tok & t_I4p) {
+ // 4 bit immediate offset into page 3
+ UINT8 i = op & 15;
+ dst += sprintf(dst, "[%x]", 0x0c0 | i);
+ }
+
+ if (tok & t_I6p) {
+ // 6 bit immediate offset into current page
+ UINT8 i = op & 63;
+ dst += sprintf(dst, "%x", (PC & ~63) | i);
+ }
+
+ if (tok & t_I6i) {
+ // 6 bit immediate offset into page 3
+ UINT16 i6p3 = (3 << 6) | (op & 63);
+ // 8 bit absolute offset at 0x0100
+ UINT16 addr = (1 << 8) | 0; // ROM[ip3] can't be reached!?
+ (void)addr; // avoid unused variable warning
+ dst += sprintf(dst, "[%x]", i6p3);
+ }
+
+ if (tok & t_I8) {
+ // 8 bit immediate I/O port address
+ UINT8 arg = ARG(pc++);
+ dst += sprintf(dst, "%02x", arg);
+ }
+
+ if (tok & t_I8c) {
+ // 8 bit immediate offset into page
+ UINT16 arg = ~ARG(pc++) & 255;
+ dst += sprintf(dst, "%02x", arg);
+ }
+
+ if (tok & t_OVER) // TL or TML
+ flags |= DASMFLAG_STEP_OVER;
+
+ if (tok & t_OUT) // RTN or RTNSK
+ flags |= DASMFLAG_STEP_OUT;
+
+ return (pc - PC) | flags | DASMFLAG_SUPPORTED;
}
diff --git a/src/emu/cpu/sh2/sh2comn.c b/src/emu/cpu/sh2/sh2comn.c
index 7099a148885..8f29e8f95c5 100644
--- a/src/emu/cpu/sh2/sh2comn.c
+++ b/src/emu/cpu/sh2/sh2comn.c
@@ -699,7 +699,7 @@ READ32_MEMBER( sh2_device::sh2_internal_r )
case 0x00:
break;
case 0x01:
-// return m_m[1] | 0; // bit31 is TDRE: Trasmit Data Register Empty. Forcing it to be '1' breaks Saturn ...
+// return m_m[1] | 0; // bit31 is TDRE: Trasmit Data Register Empty. Forcing it to be '1' breaks Saturn ...
return m_m[1] | (0x84 << 24); // ... but this is actually needed to make EGWord on SS to boot?
case 0x04: // TIER, FTCSR, FRC
diff --git a/src/emu/cpu/tms0980/tms0980.c b/src/emu/cpu/tms0980/tms0980.c
index 8c085b7bd32..22ebea62b52 100644
--- a/src/emu/cpu/tms0980/tms0980.c
+++ b/src/emu/cpu/tms0980/tms0980.c
@@ -250,7 +250,7 @@ tms0270_cpu_device::tms0270_cpu_device(const machine_config &mconfig, const char
static MACHINE_CONFIG_FRAGMENT(tms1000)
-
+
// microinstructions PLA, output PLA
MCFG_PLA_ADD("mpla", 8, 16, 30)
MCFG_PLA_FILEFORMAT(PLA_FMT_BERKELEY)
@@ -374,7 +374,7 @@ void tms1xxx_cpu_device::device_start()
m_r_mask = (1 << m_r_pins) - 1;
m_pc_mask = (1 << m_pc_bits) - 1;
m_x_mask = (1 << m_x_bits) - 1;
-
+
// zerofill
m_pc = 0;
m_sr = 0;
@@ -401,7 +401,7 @@ void tms1xxx_cpu_device::device_start()
m_clatch = 0;
m_add = 0;
m_bl = 0;
-
+
m_ram_in = 0;
m_dam_in = 0;
m_ram_out = 0;
@@ -484,7 +484,7 @@ void tms0270_cpu_device::device_start()
m_o_latch_low = 0;
m_o_latch = 0;
m_o_latch_prev = 0;
-
+
// register for savestates
save_item(NAME(m_r_prev));
save_item(NAME(m_chipsel));
@@ -535,18 +535,18 @@ void tms1000_cpu_device::device_reset()
{
// common reset
tms1xxx_cpu_device::device_reset();
-
+
// pre-decode instructionset
m_fixed_decode.resize_and_clear(0x100);
m_micro_decode.resize_and_clear(0x100);
-
+
for (int op = 0; op < 0x100; op++)
{
// _____ _____ ______ _____ ______ _____ _____ _____ _____
const UINT32 md[16] = { M_STSL, M_AUTY, M_AUTA, M_CIN, M_C8, M_NE, M_CKN, M_15TN, M_MTN, M_NATN, M_ATN, M_MTP, M_YTP, M_CKP, M_CKM, M_STO };
UINT16 mask = m_mpla->read(op);
mask ^= 0x3fc8; // invert active-negative
-
+
for (int bit = 0; bit < 16; bit++)
if (mask & (1 << bit))
m_micro_decode[op] |= md[bit];
@@ -559,7 +559,7 @@ void tms1000_cpu_device::device_reset()
m_fixed_decode[0x0c] = F_RSTR;
m_fixed_decode[0x0d] = F_SETR;
m_fixed_decode[0x0f] = F_RETN;
-
+
for (int i = 0x10; i < 0x20; i++) m_fixed_decode[i] = F_LDP;
for (int i = 0x30; i < 0x34; i++) m_fixed_decode[i] = F_SBIT;
for (int i = 0x34; i < 0x38; i++) m_fixed_decode[i] = F_RBIT;
@@ -572,7 +572,7 @@ void tms1000_cpu_device::device_reset()
void tms1100_cpu_device::device_reset()
{
tms1000_cpu_device::device_reset();
-
+
// small differences in 00-3f area
m_fixed_decode[0x00] = 0;
m_fixed_decode[0x09] = F_COMX8; // !
@@ -597,29 +597,29 @@ void tms0970_cpu_device::device_reset()
// upper half of the opcodes is always branch/call
if (op & 0x80)
m_fixed_decode[op] = (op & 0x40) ? F_CALL: F_BR;
-
+
// 5 output bits select a microinstruction index
UINT32 imask = m_ipla->read(op);
UINT8 msel = imask & 0x1f;
-
+
// but if (from bottom to top) term 1 is active and output bit 5 is 0, R2,R4-R7 directly select a microinstruction index
if (imask & 0x40 && (imask & 0x20) == 0)
msel = (op & 0xf) | (op >> 1 & 0x10);
-
+
msel = BITSWAP8(msel,7,6,5,0,1,2,3,4); // lines are reversed
UINT32 mmask = m_mpla->read(msel);
mmask ^= 0x09fe; // invert active-negative
-
+
// _____ _____ _____ _____ ______ _____ ______ _____ _____
const UINT32 md[15] = { M_CKM, M_CKP, M_YTP, M_MTP, M_ATN, M_NATN, M_MTN, M_15TN, M_CKN, M_NE, M_C8, M_CIN, M_AUTA, M_AUTY, M_STO };
for (int bit = 0; bit < 15; bit++)
if (mmask & (1 << bit))
m_micro_decode[op] |= md[bit];
-
+
// the other ipla terms each select a fixed instruction
const UINT32 id[8] = { F_LDP, F_TDO, F_COMX, F_LDX, F_SBIT, F_RBIT, F_SETR, F_RETN };
-
+
for (int bit = 0; bit < 8; bit++)
if (imask & (0x80 << bit))
m_fixed_decode[op] |= id[bit];
@@ -630,20 +630,20 @@ void tms0970_cpu_device::device_reset()
UINT32 tms0980_cpu_device::decode_micro(UINT8 sel)
{
UINT32 decode = 0;
-
+
sel = BITSWAP8(sel,7,6,0,1,2,3,4,5); // lines are reversed
UINT32 mask = m_mpla->read(sel);
mask ^= 0x43fc3; // invert active-negative
-
+
// M_RSTR is specific to TMS02x0, it redirects to F_RSTR
// M_UNK1 is specific to TMS0270, unknown yet
// _______ ______ _____ _____ _____ _____ ______ _____ ______ _____ _____
const UINT32 md[22] = { M_NDMTP, M_DMTP, M_AUTY, M_AUTA, M_CKM, M_SSE, M_CKP, M_YTP, M_MTP, M_ATN, M_NATN, M_MTN, M_15TN, M_CKN, M_NE, M_C8, M_SSS, M_CME, M_CIN, M_STO, M_RSTR, M_UNK1 };
-
+
for (int bit = 0; bit < 22 && bit < m_mpla->outputs(); bit++)
if (mask & (1 << bit))
decode |= md[bit];
-
+
return decode;
}
@@ -651,7 +651,7 @@ void tms0980_cpu_device::device_reset()
{
// common reset
tms1xxx_cpu_device::device_reset();
-
+
// pre-decode instructionset
m_fixed_decode.resize_and_clear(0x200);
m_micro_decode.resize_and_clear(0x200);
@@ -661,20 +661,20 @@ void tms0980_cpu_device::device_reset()
// upper half of the opcodes is always branch/call
if (op & 0x100)
m_fixed_decode[op] = (op & 0x80) ? F_CALL: F_BR;
-
+
UINT32 imask = m_ipla->read(op);
// 6 output bits select a microinstruction index
m_micro_decode[op] = decode_micro(imask & 0x3f);
-
+
// the other ipla terms each select a fixed instruction
const UINT32 id[15] = { F_LDP, F_SBL, F_OFF, F_RBIT, F_SAL, F_XDA, F_REAC, F_SETR, F_RETN, F_SBIT, F_TDO, F_COMX8, F_COMX, F_LDX, F_SEAC };
-
+
for (int bit = 0; bit < 15; bit++)
if (imask & (0x80 << bit))
m_fixed_decode[op] |= id[bit];
}
-
+
// like on TMS0970, one of the terms directly select a microinstruction index (via R4-R8),
// but it can't be pre-determined when it's active
m_micro_direct.resize_and_clear(0x40);
@@ -710,7 +710,7 @@ void tms1xxx_cpu_device::next_pc()
fb = 1;
else if (m_pc == m_pc_mask)
fb = 0;
-
+
m_pc = (m_pc << 1 | fb) & m_pc_mask;
}
@@ -731,9 +731,9 @@ void tms0980_cpu_device::read_opcode()
debugger_instruction_hook(this, m_rom_address << 1);
m_opcode = m_program->read_word(m_rom_address << 1) & 0x1ff;
m_c4 = BITSWAP8(m_opcode,7,6,5,4,0,1,2,3) & 0xf; // opcode operand is bitswapped for most opcodes
-
+
m_fixed = m_fixed_decode[m_opcode];
-
+
// if ipla term 0 is active, R4-R8 directly select a microinstruction index when R0 or R0^BL is 0
int r0 = m_opcode >> 8 & 1;
if (m_ipla->read(m_opcode) & 0x40 && !((r0 & m_bl) ^ r0))
@@ -747,7 +747,7 @@ void tms0980_cpu_device::read_opcode()
void tms0270_cpu_device::read_opcode()
{
tms0980_cpu_device::read_opcode();
-
+
// RSTR is on the mpla
if (m_micro & M_RSTR)
m_fixed |= F_RSTR;
@@ -780,13 +780,13 @@ void tms0270_cpu_device::dynamic_output()
// R13: power off, trigger on falling edge
if ((m_r_prev >> 13 & 1) && !(m_r >> 13 & 1))
m_power_off(1);
-
+
// R11: TMS5100 CTL port direction (0=read from TMS5100, 1=write to TMS5100)
m_ctl_dir = m_r >> 11 & 1;
// R12: chip select (off=display via OPLA, on=TMS5100 via ACC/CKB)
m_chipsel = m_r >> 12 & 1;
-
+
if (m_chipsel)
{
// ACC via SEG B,C,D,G: TMS5100 CTL pins
@@ -812,7 +812,7 @@ void tms0270_cpu_device::dynamic_output()
m_o_latch_prev = m_o_latch;
}
}
-
+
// standard R-output
if (m_r != m_r_prev)
{
@@ -860,7 +860,7 @@ void tms1xxx_cpu_device::set_cki_bus()
case 0x30: case 0x38:
m_cki_bus = 1 << (m_c4 >> 2) ^ 0xf;
break;
-
+
// 01XXXXXX: constant
case 0x00: // R2,3,4 are NANDed with eachother, and then ORed with R1, making 00000XXX valid too
case 0x40: case 0x48: case 0x50: case 0x58: case 0x60: case 0x68: case 0x70: case 0x78:
@@ -886,7 +886,7 @@ void tms0980_cpu_device::set_cki_bus()
case 0x020: case 0x0a0:
m_cki_bus = 1 << (m_c4 >> 2) ^ 0xf;
break;
-
+
// 0X1XXXXXX: constant
case 0x040: case 0x048: case 0x050: case 0x058: case 0x060: case 0x068: case 0x070: case 0x078:
case 0x0c0: case 0x0c8: case 0x0d0: case 0x0d8: case 0x0e0: case 0x0e8: case 0x0f0: case 0x0f8:
@@ -1080,7 +1080,7 @@ void tms0270_cpu_device::op_tdo()
m_o_latch_low = m_a;
else
m_o_latch = m_o_latch_low | (m_a << 4 & 0x30);
-
+
// write to output is done in dynamic_output
}
@@ -1111,7 +1111,7 @@ void tms1xxx_cpu_device::execute_run()
if (m_status)
{
UINT8 new_pc = m_opcode & m_pc_mask;
-
+
// BR: conditional branch
if (m_fixed & F_BR)
{
@@ -1120,7 +1120,7 @@ void tms1xxx_cpu_device::execute_run()
m_ca = m_cb;
m_pc = new_pc;
}
-
+
// CALL: conditional call
if (m_fixed & F_CALL)
{
@@ -1166,7 +1166,7 @@ void tms1xxx_cpu_device::execute_run()
case 1:
// fetch: rom address 2/2
m_rom_address = (m_ca << (m_pc_bits+4)) | (m_pa << m_pc_bits) | m_pc;
-
+
// execute: update alu inputs
// N inputs
if (m_micro & M_15TN) m_n |= 0xf;
@@ -1233,7 +1233,7 @@ void tms1xxx_cpu_device::execute_run()
if (m_fixed & F_SAL) op_sal();
if (m_fixed & F_SBL) op_sbl();
if (m_fixed & F_XDA) op_xda();
-
+
// after fixed opcode handling: store status, write ram
m_status = status;
if (m_ram_out != -1)
diff --git a/src/emu/cpu/tms0980/tms0980.h b/src/emu/cpu/tms0980/tms0980.h
index 1b0d3e2a910..a3e3505962f 100644
--- a/src/emu/cpu/tms0980/tms0980.h
+++ b/src/emu/cpu/tms0980/tms0980.h
@@ -77,7 +77,7 @@ public:
template<class _Object> static devcb_base &set_write_r_callback(device_t &device, _Object object) { return downcast<tms1xxx_cpu_device &>(device).m_write_r.set_callback(object); }
template<class _Object> static devcb_base &set_power_off_callback(device_t &device, _Object object) { return downcast<tms1xxx_cpu_device &>(device).m_power_off.set_callback(object); }
static void set_output_pla(device_t &device, const UINT16 *output_pla) { downcast<tms1xxx_cpu_device &>(device).c_output_pla = output_pla; }
-
+
protected:
// device-level overrides
virtual void device_start();
@@ -184,7 +184,7 @@ protected:
devcb_write16 m_write_o;
devcb_write16 m_write_r;
devcb_write_line m_power_off;
-
+
UINT32 m_o_mask;
UINT32 m_r_mask;
UINT32 m_k_mask;
@@ -239,7 +239,7 @@ protected:
virtual void device_reset();
virtual offs_t disasm_disassemble(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram, UINT32 options);
-
+
virtual void op_setr();
virtual void op_rstr();
};
@@ -263,7 +263,7 @@ protected:
virtual machine_config_constructor device_mconfig_additions() const;
virtual void write_o_output(UINT8 index);
-
+
virtual void op_setr();
virtual void op_tdo();
};
@@ -284,11 +284,11 @@ protected:
virtual UINT32 disasm_min_opcode_bytes() const { return 2; }
virtual UINT32 disasm_max_opcode_bytes() const { return 2; }
virtual offs_t disasm_disassemble(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram, UINT32 options);
-
+
virtual UINT8 read_k_input();
virtual void set_cki_bus();
virtual void read_opcode();
-
+
virtual void op_comx();
UINT32 decode_micro(UINT8 sel);
@@ -299,7 +299,7 @@ class tms0270_cpu_device : public tms0980_cpu_device
{
public:
tms0270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
-
+
// static configuration helpers
template<class _Object> static devcb_base &set_read_ctl_callback(device_t &device, _Object object) { return downcast<tms0270_cpu_device &>(device).m_read_ctl.set_callback(object); }
template<class _Object> static devcb_base &set_write_ctl_callback(device_t &device, _Object object) { return downcast<tms0270_cpu_device &>(device).m_write_ctl.set_callback(object); }
@@ -316,7 +316,7 @@ protected:
virtual UINT8 read_k_input();
virtual void dynamic_output();
virtual void read_opcode();
-
+
virtual void op_setr();
virtual void op_rstr();
virtual void op_tdo();
diff --git a/src/emu/luaengine.c b/src/emu/luaengine.c
index 843c873233e..62e7d02563a 100644
--- a/src/emu/luaengine.c
+++ b/src/emu/luaengine.c
@@ -348,7 +348,7 @@ luabridge::LuaRef lua_engine::l_machine_get_devices(const running_machine *r)
luabridge::LuaRef devs_table = luabridge::LuaRef::newTable(L);
device_t *root = &(m->root_device());
- devs_table = devtree_dfs(root, devs_table);
+ devs_table = devtree_dfs(root, devs_table);
return devs_table;
}
diff --git a/src/emu/machine.c b/src/emu/machine.c
index 76855efad96..9ab3452e963 100644
--- a/src/emu/machine.c
+++ b/src/emu/machine.c
@@ -255,10 +255,10 @@ void running_machine::start()
primary_screen->register_vblank_callback(vblank_state_delegate(FUNC(running_machine::watchdog_vblank), this));
save().save_item(NAME(m_watchdog_enabled));
save().save_item(NAME(m_watchdog_counter));
-
+
// save the random seed or save states might be broken in drivers that use the rand() method
save().save_item(NAME(m_rand_seed));
-
+
// initialize image devices
image_init(*this);
m_tilemap.reset(global_alloc(tilemap_manager(*this)));
diff --git a/src/emu/machine/am9517a.c b/src/emu/machine/am9517a.c
index 7e473f8b59d..2e20fd8a475 100644
--- a/src/emu/machine/am9517a.c
+++ b/src/emu/machine/am9517a.c
@@ -523,7 +523,7 @@ void am9517a_device::device_start()
save_item(NAME(m_status));
save_item(NAME(m_temp));
save_item(NAME(m_request));
-
+
for (int i = 0; i < 4; i++)
{
save_item(NAME(m_channel[i].m_address), i);
diff --git a/src/emu/machine/e05a30.c b/src/emu/machine/e05a30.c
index 5e3de355336..804b46ccbe3 100644
--- a/src/emu/machine/e05a30.c
+++ b/src/emu/machine/e05a30.c
@@ -151,7 +151,6 @@ void e05a30_device::update_cr_stepper(UINT8 data)
WRITE_LINE_MEMBER( e05a30_device::centronics_input_strobe )
{
if (m_centronics_strobe == TRUE && state == FALSE && !m_centronics_busy) {
-
m_centronics_data_latch = m_centronics_data;
m_centronics_data_latched = TRUE;
diff --git a/src/emu/machine/i6300esb.c b/src/emu/machine/i6300esb.c
index 04592dccf1b..7619cb3eda0 100644
--- a/src/emu/machine/i6300esb.c
+++ b/src/emu/machine/i6300esb.c
@@ -83,12 +83,12 @@ DEVICE_ADDRESS_MAP_START(internal_io_map, 32, i6300esb_lpc_device)
AM_RANGE(0x00ec, 0x00ef) AM_WRITE8( nop_w, 0x0000ff00) // Non-existing, used for delays by the bios/os
ADDRESS_MAP_END
-
+
i6300esb_lpc_device::i6300esb_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
: pci_device(mconfig, I6300ESB_LPC, "i6300ESB southbridge ISA/LPC bridge", tag, owner, clock, "i6300esb_lpc", __FILE__),
- acpi(*this, "acpi"),
- rtc (*this, "rtc"),
- pit (*this, "pit")
+ acpi(*this, "acpi"),
+ rtc (*this, "rtc"),
+ pit (*this, "pit")
{
}
diff --git a/src/emu/machine/i82875p.h b/src/emu/machine/i82875p.h
index bf8c8f841ba..2fa14253b66 100644
--- a/src/emu/machine/i82875p.h
+++ b/src/emu/machine/i82875p.h
@@ -107,7 +107,7 @@ class i82875p_overflow_device : public pci_device {
public:
i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
-
+
DECLARE_READ8_MEMBER (dram_row_boundary_r);
DECLARE_WRITE8_MEMBER (dram_row_boundary_w);
DECLARE_READ8_MEMBER (dram_row_attribute_r);
diff --git a/src/emu/machine/r10696.c b/src/emu/machine/r10696.c
index 50191c0ede7..7dca19866f6 100644
--- a/src/emu/machine/r10696.c
+++ b/src/emu/machine/r10696.c
@@ -34,7 +34,7 @@
#include "emu.h"
#include "machine/r10696.h"
-#define VERBOSE 1
+#define VERBOSE 1
#if VERBOSE
#define LOG(x) logerror x
#else
@@ -50,9 +50,9 @@
const device_type R10696 = &device_creator<r10696_device>;
r10696_device::r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
- : device_t(mconfig, R10696, "Rockwell 10696", tag, owner, clock, "r10696", __FILE__),
- m_io_a(0), m_io_b(0), m_io_c(0),
- m_iord(*this), m_iowr(*this)
+ : device_t(mconfig, R10696, "Rockwell 10696", tag, owner, clock, "r10696", __FILE__),
+ m_io_a(0), m_io_b(0), m_io_c(0),
+ m_iord(*this), m_iowr(*this)
{
}
@@ -61,12 +61,12 @@ r10696_device::r10696_device(const machine_config &mconfig, const char *tag, dev
*/
void r10696_device::device_start()
{
- m_iord.resolve();
- m_iowr.resolve();
+ m_iord.resolve();
+ m_iowr.resolve();
- save_item(NAME(m_io_a));
- save_item(NAME(m_io_b));
- save_item(NAME(m_io_c));
+ save_item(NAME(m_io_a));
+ save_item(NAME(m_io_b));
+ save_item(NAME(m_io_c));
}
/**
@@ -87,101 +87,101 @@ void r10696_device::device_reset()
WRITE8_MEMBER( r10696_device::io_w )
{
- assert(offset < 16);
- const UINT8 io_a = m_io_a;
- const UINT8 io_b = m_io_b;
- const UINT8 io_c = m_io_c;
- switch (offset)
- {
- case 0x0A: // Read Group A
- case 0x09: // Read Group B
- case 0x03: // Read Group C
- case 0x00: // Read Groups A | B | C
- case 0x01: // Read Groups B | C
- case 0x02: // Read Groups A | C
- case 0x08: // Read Groups A | B
- break;
-
- case 0x0E: // Set Group A
- m_io_a = data & 0x0f;
- break;
- case 0x0D: // Set Group B
- m_io_b = data & 0x0f;
- break;
- case 0x07: // Set Group C
- m_io_c = data & 0x0f;
- break;
- case 0x04: // Set Groups A, B and C
- m_io_a = m_io_b = m_io_c = data & 0x0f;
- break;
- case 0x05: // Set Groups B and C
- m_io_b = m_io_c = data & 0x0f;
- break;
- case 0x06: // Set Groups A and C
- m_io_a = m_io_c = data & 0x0f;
- break;
- case 0x0C: // Set Groups A and B
- m_io_a = m_io_b = data & 0x0f;
- break;
- }
- if (io_a != m_io_a)
- m_iowr(0, m_io_a, 0x0f);
- if (io_b != m_io_b)
- m_iowr(1, m_io_b, 0x0f);
- if (io_c != m_io_c)
- m_iowr(2, m_io_c, 0x0f);
+ assert(offset < 16);
+ const UINT8 io_a = m_io_a;
+ const UINT8 io_b = m_io_b;
+ const UINT8 io_c = m_io_c;
+ switch (offset)
+ {
+ case 0x0A: // Read Group A
+ case 0x09: // Read Group B
+ case 0x03: // Read Group C
+ case 0x00: // Read Groups A | B | C
+ case 0x01: // Read Groups B | C
+ case 0x02: // Read Groups A | C
+ case 0x08: // Read Groups A | B
+ break;
+
+ case 0x0E: // Set Group A
+ m_io_a = data & 0x0f;
+ break;
+ case 0x0D: // Set Group B
+ m_io_b = data & 0x0f;
+ break;
+ case 0x07: // Set Group C
+ m_io_c = data & 0x0f;
+ break;
+ case 0x04: // Set Groups A, B and C
+ m_io_a = m_io_b = m_io_c = data & 0x0f;
+ break;
+ case 0x05: // Set Groups B and C
+ m_io_b = m_io_c = data & 0x0f;
+ break;
+ case 0x06: // Set Groups A and C
+ m_io_a = m_io_c = data & 0x0f;
+ break;
+ case 0x0C: // Set Groups A and B
+ m_io_a = m_io_b = data & 0x0f;
+ break;
+ }
+ if (io_a != m_io_a)
+ m_iowr(0, m_io_a, 0x0f);
+ if (io_b != m_io_b)
+ m_iowr(1, m_io_b, 0x0f);
+ if (io_c != m_io_c)
+ m_iowr(2, m_io_c, 0x0f);
}
READ8_MEMBER( r10696_device::io_r )
{
- assert(offset < 16);
- UINT8 io_a, io_b, io_c;
- UINT8 data = 0xf;
- switch (offset)
- {
- case 0x0A: // Read Group A
- io_a = m_iord(0);
- data = io_a & 0x0f;
- break;
- case 0x09: // Read Group B
- io_b = m_iord(1);
- data = io_b & 0x0f;
- break;
- case 0x03: // Read Group C
- io_c = m_iord(2);
- data = io_c & 0x0f;
- break;
- case 0x00: // Read Groups A | B | C
- io_a = m_iord(0);
- io_b = m_iord(1);
- io_c = m_iord(2);
- data = (io_a | io_b | io_a) & 0x0f;
- break;
- case 0x01: // Read Groups B | C
- io_b = m_iord(1);
- io_c = m_iord(2);
- data = (io_b | io_c) & 0x0f;
- break;
- case 0x02: // Read Groups A | C
- io_a = m_iord(0);
- io_c = m_iord(2);
- data = (io_a | io_c) & 0x0f;
- break;
- case 0x08: // Read Groups A | B
- io_a = m_iord(0);
- io_b = m_iord(1);
- data = (io_a | io_b) & 0x0f;
- break;
-
- case 0x0E: // Set Group A
- case 0x0D: // Set Group B
- case 0x07: // Set Group C
- case 0x04: // Set Groups A, B and C
- case 0x05: // Set Groups B and C
- case 0x06: // Set Groups A and C
- case 0x0C: // Set Groups A and B
- break;
- }
- return data;
+ assert(offset < 16);
+ UINT8 io_a, io_b, io_c;
+ UINT8 data = 0xf;
+ switch (offset)
+ {
+ case 0x0A: // Read Group A
+ io_a = m_iord(0);
+ data = io_a & 0x0f;
+ break;
+ case 0x09: // Read Group B
+ io_b = m_iord(1);
+ data = io_b & 0x0f;
+ break;
+ case 0x03: // Read Group C
+ io_c = m_iord(2);
+ data = io_c & 0x0f;
+ break;
+ case 0x00: // Read Groups A | B | C
+ io_a = m_iord(0);
+ io_b = m_iord(1);
+ io_c = m_iord(2);
+ data = (io_a | io_b | io_a) & 0x0f;
+ break;
+ case 0x01: // Read Groups B | C
+ io_b = m_iord(1);
+ io_c = m_iord(2);
+ data = (io_b | io_c) & 0x0f;
+ break;
+ case 0x02: // Read Groups A | C
+ io_a = m_iord(0);
+ io_c = m_iord(2);
+ data = (io_a | io_c) & 0x0f;
+ break;
+ case 0x08: // Read Groups A | B
+ io_a = m_iord(0);
+ io_b = m_iord(1);
+ data = (io_a | io_b) & 0x0f;
+ break;
+
+ case 0x0E: // Set Group A
+ case 0x0D: // Set Group B
+ case 0x07: // Set Group C
+ case 0x04: // Set Groups A, B and C
+ case 0x05: // Set Groups B and C
+ case 0x06: // Set Groups A and C
+ case 0x0C: // Set Groups A and B
+ break;
+ }
+ return data;
}
diff --git a/src/emu/machine/r10696.h b/src/emu/machine/r10696.h
index 996a7d43365..a151a4846dd 100644
--- a/src/emu/machine/r10696.h
+++ b/src/emu/machine/r10696.h
@@ -24,31 +24,31 @@
/* Set the read and write group (4-bit; nibble) delegates */
#define MCFG_R10696_IO(_devcb_rd,_devcb_wr) \
- r10696_device::set_iord(*device, DEVCB_##_devcb_rd); \
- r10696_device::set_iowr(*device, DEVCB_##_devcb_wr);
+ r10696_device::set_iord(*device, DEVCB_##_devcb_rd); \
+ r10696_device::set_iowr(*device, DEVCB_##_devcb_wr);
class r10696_device : public device_t
{
public:
- r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
- ~r10696_device() {}
+ r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+ ~r10696_device() {}
- DECLARE_READ8_MEMBER ( io_r );
- DECLARE_WRITE8_MEMBER( io_w );
+ DECLARE_READ8_MEMBER ( io_r );
+ DECLARE_WRITE8_MEMBER( io_w );
- template<class _Object> static devcb_base &set_iord(device_t &device, _Object object) { return downcast<r10696_device &>(device).m_iord.set_callback(object); }
- template<class _Object> static devcb_base &set_iowr(device_t &device, _Object object) { return downcast<r10696_device &>(device).m_iowr.set_callback(object); }
+ template<class _Object> static devcb_base &set_iord(device_t &device, _Object object) { return downcast<r10696_device &>(device).m_iord.set_callback(object); }
+ template<class _Object> static devcb_base &set_iowr(device_t &device, _Object object) { return downcast<r10696_device &>(device).m_iowr.set_callback(object); }
protected:
- // device-level overrides
- virtual void device_start();
- virtual void device_reset();
+ // device-level overrides
+ virtual void device_start();
+ virtual void device_reset();
private:
- UINT8 m_io_a; //!< input/output flip-flops group A
- UINT8 m_io_b; //!< input/output flip-flops group B
- UINT8 m_io_c; //!< input/output flip-flops group C
- devcb_read8 m_iord; //!< input line (read, offset = group, data = 4 bits)
- devcb_write8 m_iowr; //!< output line (write, offset = group, data = 4 bits)
+ UINT8 m_io_a; //!< input/output flip-flops group A
+ UINT8 m_io_b; //!< input/output flip-flops group B
+ UINT8 m_io_c; //!< input/output flip-flops group C
+ devcb_read8 m_iord; //!< input line (read, offset = group, data = 4 bits)
+ devcb_write8 m_iowr; //!< output line (write, offset = group, data = 4 bits)
};
extern const device_type R10696;
diff --git a/src/emu/machine/r10788.c b/src/emu/machine/r10788.c
index 10f46ab621a..128314903fe 100644
--- a/src/emu/machine/r10788.c
+++ b/src/emu/machine/r10788.c
@@ -41,7 +41,7 @@
#include "emu.h"
#include "machine/r10788.h"
-#define VERBOSE 0
+#define VERBOSE 0
#if VERBOSE
#define LOG(x) logerror x
#else
@@ -57,10 +57,10 @@
const device_type R10788 = &device_creator<r10788_device>;
r10788_device::r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
- : device_t(mconfig, R10788, "Rockwell 10788", tag, owner, clock, "r10788", __FILE__),
- m_ktr(0), m_kts(0), m_kla(0), m_klb(0), m_mask_a(15), m_mask_b(15), m_ker(0),
- m_io_counter(0), m_scan_counter(0),
- m_display(*this)
+ : device_t(mconfig, R10788, "Rockwell 10788", tag, owner, clock, "r10788", __FILE__),
+ m_ktr(0), m_kts(0), m_kla(0), m_klb(0), m_mask_a(15), m_mask_b(15), m_ker(0),
+ m_io_counter(0), m_scan_counter(0),
+ m_display(*this)
{
}
@@ -69,22 +69,22 @@ r10788_device::r10788_device(const machine_config &mconfig, const char *tag, dev
*/
void r10788_device::device_start()
{
- m_display.resolve();
-
- save_item(NAME(m_reg));
- save_item(NAME(m_ktr));
- save_item(NAME(m_kts));
- save_item(NAME(m_kla));
- save_item(NAME(m_klb));
- save_item(NAME(m_mask_a));
- save_item(NAME(m_mask_b));
- save_item(NAME(m_ker));
- save_item(NAME(m_io_counter));
- save_item(NAME(m_scan_counter));
-
- m_timer = timer_alloc(TIMER_DISPLAY);
- // recurring timer every 36 cycles
- m_timer->adjust(clocks_to_attotime(36), 0, clocks_to_attotime(36));
+ m_display.resolve();
+
+ save_item(NAME(m_reg));
+ save_item(NAME(m_ktr));
+ save_item(NAME(m_kts));
+ save_item(NAME(m_kla));
+ save_item(NAME(m_klb));
+ save_item(NAME(m_mask_a));
+ save_item(NAME(m_mask_b));
+ save_item(NAME(m_ker));
+ save_item(NAME(m_io_counter));
+ save_item(NAME(m_scan_counter));
+
+ m_timer = timer_alloc(TIMER_DISPLAY);
+ // recurring timer every 36 cycles
+ m_timer->adjust(clocks_to_attotime(36), 0, clocks_to_attotime(36));
}
/**
@@ -93,14 +93,14 @@ void r10788_device::device_start()
void r10788_device::device_reset()
{
memset(m_reg, 0x00, sizeof(m_reg));
- m_ktr = 0;
- m_kts = 0;
- m_kla = 0;
- m_klb = 0;
- m_mask_a = 15;
- m_mask_b = 15;
- m_ker = 0;
- m_scan_counter = 0;
+ m_ktr = 0;
+ m_kts = 0;
+ m_kla = 0;
+ m_klb = 0;
+ m_mask_a = 15;
+ m_mask_b = 15;
+ m_ker = 0;
+ m_scan_counter = 0;
}
@@ -113,19 +113,19 @@ void r10788_device::device_reset()
*/
void r10788_device::device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr)
{
- UINT8 data;
- switch (id)
- {
- case TIMER_DISPLAY:
- data = (m_reg[0][m_scan_counter] & m_mask_a) +
- 16 * (m_reg[1][m_scan_counter] & m_mask_b);
- LOG(("%s: scan counter:%2d data:%02x\n", __FUNCTION__, m_scan_counter, data));
- m_display(m_scan_counter, data, 0xff);
- break;
- default:
- LOG(("%s: invalid timer id:%d\n", __FUNCTION__, id));
- }
- m_scan_counter = (m_scan_counter + 1) % 16;
+ UINT8 data;
+ switch (id)
+ {
+ case TIMER_DISPLAY:
+ data = (m_reg[0][m_scan_counter] & m_mask_a) +
+ 16 * (m_reg[1][m_scan_counter] & m_mask_b);
+ LOG(("%s: scan counter:%2d data:%02x\n", __FUNCTION__, m_scan_counter, data));
+ m_display(m_scan_counter, data, 0xff);
+ break;
+ default:
+ LOG(("%s: invalid timer id:%d\n", __FUNCTION__, id));
+ }
+ m_scan_counter = (m_scan_counter + 1) % 16;
}
/*************************************
@@ -142,87 +142,87 @@ void r10788_device::device_timer(emu_timer &timer, device_timer_id id, int param
WRITE8_MEMBER( r10788_device::io_w )
{
- assert(offset < 16);
- switch (offset)
- {
- case KTR: // Transfer Keyboard Return
- LOG(("%s: KTR data:%02x\n", __FUNCTION__, data));
- m_ktr = data;
- break;
- case KTS: // Transfer Keyboard Strobe
- LOG(("%s: KTS data:%02x\n", __FUNCTION__, data));
- m_kts = data;
- break;
- case KLA: // Load Display Register A
- LOG(("%s: KLA [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
- m_kla = data;
- m_reg[0][m_io_counter] = m_kla;
- break;
- case KLB: // Load Display Register B
- LOG(("%s: KLB [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
- m_klb = data;
- m_reg[1][m_io_counter] = m_kla;
- break;
- case KDN: // Turn On Display
- LOG(("%s: KDN data:%02x\n", __FUNCTION__, data));
- m_mask_a = 15;
- m_mask_b = 15;
- break;
- case KAF: // Turn Off A
- LOG(("%s: KAF data:%02x\n", __FUNCTION__, data));
- m_mask_a = 0;
- m_mask_b &= ~3;
- break;
- case KBF: // Turn Off B
- LOG(("%s: KBF data:%02x\n", __FUNCTION__, data));
- m_mask_b &= ~12;
- break;
- case KER: // Reset Keyboard Error
- LOG(("%s: KER data:%02x\n", __FUNCTION__, data));
- m_ker = 10;
- break;
- }
+ assert(offset < 16);
+ switch (offset)
+ {
+ case KTR: // Transfer Keyboard Return
+ LOG(("%s: KTR data:%02x\n", __FUNCTION__, data));
+ m_ktr = data;
+ break;
+ case KTS: // Transfer Keyboard Strobe
+ LOG(("%s: KTS data:%02x\n", __FUNCTION__, data));
+ m_kts = data;
+ break;
+ case KLA: // Load Display Register A
+ LOG(("%s: KLA [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
+ m_kla = data;
+ m_reg[0][m_io_counter] = m_kla;
+ break;
+ case KLB: // Load Display Register B
+ LOG(("%s: KLB [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
+ m_klb = data;
+ m_reg[1][m_io_counter] = m_kla;
+ break;
+ case KDN: // Turn On Display
+ LOG(("%s: KDN data:%02x\n", __FUNCTION__, data));
+ m_mask_a = 15;
+ m_mask_b = 15;
+ break;
+ case KAF: // Turn Off A
+ LOG(("%s: KAF data:%02x\n", __FUNCTION__, data));
+ m_mask_a = 0;
+ m_mask_b &= ~3;
+ break;
+ case KBF: // Turn Off B
+ LOG(("%s: KBF data:%02x\n", __FUNCTION__, data));
+ m_mask_b &= ~12;
+ break;
+ case KER: // Reset Keyboard Error
+ LOG(("%s: KER data:%02x\n", __FUNCTION__, data));
+ m_ker = 10;
+ break;
+ }
}
READ8_MEMBER( r10788_device::io_r )
{
- assert(offset < 16);
- UINT8 data = 0xf;
- switch (offset)
- {
- case KTR: // Transfer Keyboard Return
- data = m_ktr;
- LOG(("%s: KTR data:%02x\n", __FUNCTION__, data));
- break;
- case KTS: // Transfer Keyboard Strobe
- data = m_kts;
- LOG(("%s: KTS data:%02x\n", __FUNCTION__, data));
- break;
- case KLA: // Load Display Register A
- m_kla = m_reg[0][m_io_counter];
- data = m_kla;
- LOG(("%s: KLA [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
- break;
- case KLB: // Load Display Register B
- m_klb = m_reg[1][m_io_counter];
- data = m_klb;
- LOG(("%s: KLB [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
- // FIXME: does it automagically increment at KLB write?
- m_io_counter = (m_io_counter + 1) % 16;
- break;
- case KDN: // Turn On Display
- LOG(("%s: KDN data:%02x\n", __FUNCTION__, data));
- break;
- case KAF: // Turn Off A
- LOG(("%s: KAF data:%02x\n", __FUNCTION__, data));
- break;
- case KBF: // Turn Off B
- LOG(("%s: KBF data:%02x\n", __FUNCTION__, data));
- break;
- case KER: // Reset Keyboard Error
- LOG(("%s: KER data:%02x\n", __FUNCTION__, data));
- break;
- }
- return data;
+ assert(offset < 16);
+ UINT8 data = 0xf;
+ switch (offset)
+ {
+ case KTR: // Transfer Keyboard Return
+ data = m_ktr;
+ LOG(("%s: KTR data:%02x\n", __FUNCTION__, data));
+ break;
+ case KTS: // Transfer Keyboard Strobe
+ data = m_kts;
+ LOG(("%s: KTS data:%02x\n", __FUNCTION__, data));
+ break;
+ case KLA: // Load Display Register A
+ m_kla = m_reg[0][m_io_counter];
+ data = m_kla;
+ LOG(("%s: KLA [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
+ break;
+ case KLB: // Load Display Register B
+ m_klb = m_reg[1][m_io_counter];
+ data = m_klb;
+ LOG(("%s: KLB [%2d] data:%02x\n", __FUNCTION__, m_io_counter, data));
+ // FIXME: does it automagically increment at KLB write?
+ m_io_counter = (m_io_counter + 1) % 16;
+ break;
+ case KDN: // Turn On Display
+ LOG(("%s: KDN data:%02x\n", __FUNCTION__, data));
+ break;
+ case KAF: // Turn Off A
+ LOG(("%s: KAF data:%02x\n", __FUNCTION__, data));
+ break;
+ case KBF: // Turn Off B
+ LOG(("%s: KBF data:%02x\n", __FUNCTION__, data));
+ break;
+ case KER: // Reset Keyboard Error
+ LOG(("%s: KER data:%02x\n", __FUNCTION__, data));
+ break;
+ }
+ return data;
}
diff --git a/src/emu/machine/r10788.h b/src/emu/machine/r10788.h
index 51eb2577710..925e579f2c1 100644
--- a/src/emu/machine/r10788.h
+++ b/src/emu/machine/r10788.h
@@ -23,50 +23,50 @@
/* Set the writer used to update a display digit */
#define MCFG_R10788_UPDATE(_devcb) \
- r10788_device::set_update(*device, DEVCB_##_devcb);
+ r10788_device::set_update(*device, DEVCB_##_devcb);
class r10788_device : public device_t
{
public:
- r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
- ~r10788_device() {}
-
- enum {
- KTR = 0xc, //!< Transfer Keyboard Return
- KTS = 0xa, //!< Transfer Keyboard Strobe
- KLA = 0xe, //!< Load Display Register A
- KLB = 0xd, //!< Load Display Register B
- KDN = 0x3, //!< Turn On Display
- KAF = 0xb, //!< Turn Off A
- KBF = 0x7, //!< Turn Off B
- KER = 0x6 //!< Reset Keyboard Error
- };
-
- DECLARE_READ8_MEMBER ( io_r );
- DECLARE_WRITE8_MEMBER( io_w );
-
- template<class _Object> static devcb_base &set_update(device_t &device, _Object object) { return downcast<r10788_device &>(device).m_display.set_callback(object); }
+ r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+ ~r10788_device() {}
+
+ enum {
+ KTR = 0xc, //!< Transfer Keyboard Return
+ KTS = 0xa, //!< Transfer Keyboard Strobe
+ KLA = 0xe, //!< Load Display Register A
+ KLB = 0xd, //!< Load Display Register B
+ KDN = 0x3, //!< Turn On Display
+ KAF = 0xb, //!< Turn Off A
+ KBF = 0x7, //!< Turn Off B
+ KER = 0x6 //!< Reset Keyboard Error
+ };
+
+ DECLARE_READ8_MEMBER ( io_r );
+ DECLARE_WRITE8_MEMBER( io_w );
+
+ template<class _Object> static devcb_base &set_update(device_t &device, _Object object) { return downcast<r10788_device &>(device).m_display.set_callback(object); }
protected:
- // device-level overrides
- virtual void device_start();
- virtual void device_reset();
- virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
+ // device-level overrides
+ virtual void device_start();
+ virtual void device_reset();
+ virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
private:
- static const device_timer_id TIMER_DISPLAY = 0;
-
- UINT8 m_reg[2][16]; //!< display registers
- UINT8 m_ktr; //!< transfer keyboard return value
- UINT8 m_kts; //!< transfer keyboard strobe value
- UINT8 m_kla; //!< display register A value
- UINT8 m_klb; //!< display register B value
- UINT8 m_mask_a; //!< display enable bits for A
- UINT8 m_mask_b; //!< display enable bits for B
- UINT8 m_ker; //!< keyboard error value
- int m_io_counter; //!< current I/O register index
- int m_scan_counter; //!< current display scan
- devcb_write8 m_display; //!< display updater
- emu_timer* m_timer; //!< timer running at clock / 18 / 36
+ static const device_timer_id TIMER_DISPLAY = 0;
+
+ UINT8 m_reg[2][16]; //!< display registers
+ UINT8 m_ktr; //!< transfer keyboard return value
+ UINT8 m_kts; //!< transfer keyboard strobe value
+ UINT8 m_kla; //!< display register A value
+ UINT8 m_klb; //!< display register B value
+ UINT8 m_mask_a; //!< display enable bits for A
+ UINT8 m_mask_b; //!< display enable bits for B
+ UINT8 m_ker; //!< keyboard error value
+ int m_io_counter; //!< current I/O register index
+ int m_scan_counter; //!< current display scan
+ devcb_write8 m_display; //!< display updater
+ emu_timer* m_timer; //!< timer running at clock / 18 / 36
};
extern const device_type R10788;
diff --git a/src/emu/machine/ra17xx.c b/src/emu/machine/ra17xx.c
index 0869016e562..2b143d0aa9c 100644
--- a/src/emu/machine/ra17xx.c
+++ b/src/emu/machine/ra17xx.c
@@ -40,7 +40,7 @@
#include "emu.h"
#include "machine/ra17xx.h"
-#define VERBOSE 1
+#define VERBOSE 1
#if VERBOSE
#define LOG(x) logerror x
#else
@@ -56,10 +56,10 @@
const device_type RA17XX = &device_creator<ra17xx_device>;
ra17xx_device::ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
- : device_t(mconfig, RA17XX, "Rockwell A17XX", tag, owner, clock, "ra17xx", __FILE__),
- m_enable(false),
- m_iord(*this),
- m_iowr(*this)
+ : device_t(mconfig, RA17XX, "Rockwell A17XX", tag, owner, clock, "ra17xx", __FILE__),
+ m_enable(false),
+ m_iord(*this),
+ m_iowr(*this)
{
}
@@ -68,10 +68,10 @@ ra17xx_device::ra17xx_device(const machine_config &mconfig, const char *tag, dev
*/
void ra17xx_device::device_start()
{
- m_iord.resolve();
- m_iowr.resolve();
+ m_iord.resolve();
+ m_iowr.resolve();
- save_item(NAME(m_line));
+ save_item(NAME(m_line));
}
/**
@@ -79,7 +79,7 @@ void ra17xx_device::device_start()
*/
void ra17xx_device::device_reset()
{
- memset(m_line, 0, sizeof(m_line));
+ memset(m_line, 0, sizeof(m_line));
}
@@ -97,36 +97,36 @@ void ra17xx_device::device_reset()
WRITE8_MEMBER( ra17xx_device::io_w )
{
- assert(offset < 16);
- m_bl = (data >> 4) & 15; // BL on the data bus most significant bits
- if (offset & 1) {
- // SOS command
- if (data & (1 << 3)) {
- m_line[m_bl] = 1; // enable output
+ assert(offset < 16);
+ m_bl = (data >> 4) & 15; // BL on the data bus most significant bits
+ if (offset & 1) {
+ // SOS command
+ if (data & (1 << 3)) {
+ m_line[m_bl] = 1; // enable output
// if (m_enable)
- m_iowr(m_bl, 1, 1);
- } else {
- m_line[m_bl] = 0; // disable output
+ m_iowr(m_bl, 1, 1);
+ } else {
+ m_line[m_bl] = 0; // disable output
// if (m_enable)
- m_iowr(m_bl, 0, 1);
- }
- } else {
- // SES command
- if (data & (1 << 3)) {
- // enable all outputs
- m_enable = true;
- for (int i = 0; i < 16; i++)
- m_iowr(i, m_line[i], 1);
- } else {
- // disable all outputs
- m_enable = false;
- }
- }
+ m_iowr(m_bl, 0, 1);
+ }
+ } else {
+ // SES command
+ if (data & (1 << 3)) {
+ // enable all outputs
+ m_enable = true;
+ for (int i = 0; i < 16; i++)
+ m_iowr(i, m_line[i], 1);
+ } else {
+ // disable all outputs
+ m_enable = false;
+ }
+ }
}
READ8_MEMBER( ra17xx_device::io_r )
{
- assert(offset < 16);
- return (m_iord(m_bl) & 1) ? 0x0f : 0x07;
+ assert(offset < 16);
+ return (m_iord(m_bl) & 1) ? 0x0f : 0x07;
}
diff --git a/src/emu/machine/ra17xx.h b/src/emu/machine/ra17xx.h
index 4833f5cb7c5..f771ca77590 100644
--- a/src/emu/machine/ra17xx.h
+++ b/src/emu/machine/ra17xx.h
@@ -23,34 +23,32 @@
/* Set the read line handler */
#define MCFG_RA17XX_READ(_devcb) \
- ra17xx_device::set_iord(*device, DEVCB_##_devcb); \
-
+ ra17xx_device::set_iord(*device, DEVCB_##_devcb);
/* Set the write line handler */
#define MCFG_RA17XX_WRITE(_devcb) \
- ra17xx_device::set_iowr(*device, DEVCB_##_devcb); \
-
+ ra17xx_device::set_iowr(*device, DEVCB_##_devcb);
class ra17xx_device : public device_t
{
public:
- ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
- ~ra17xx_device() {}
+ ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+ ~ra17xx_device() {}
- DECLARE_READ8_MEMBER ( io_r );
- DECLARE_WRITE8_MEMBER( io_w );
+ DECLARE_READ8_MEMBER ( io_r );
+ DECLARE_WRITE8_MEMBER( io_w );
- template<class _Object> static devcb_base &set_iord(device_t &device, _Object object) { return downcast<ra17xx_device &>(device).m_iord.set_callback(object); }
- template<class _Object> static devcb_base &set_iowr(device_t &device, _Object object) { return downcast<ra17xx_device &>(device).m_iowr.set_callback(object); }
+ template<class _Object> static devcb_base &set_iord(device_t &device, _Object object) { return downcast<ra17xx_device &>(device).m_iord.set_callback(object); }
+ template<class _Object> static devcb_base &set_iowr(device_t &device, _Object object) { return downcast<ra17xx_device &>(device).m_iowr.set_callback(object); }
protected:
- // device-level overrides
- virtual void device_start();
- virtual void device_reset();
+ // device-level overrides
+ virtual void device_start();
+ virtual void device_reset();
private:
- UINT8 m_line[16]; //!< input/output flip-flops for 16 I/O lines
- UINT8 m_bl; //!< value of BL during the most recent output
- bool m_enable; //!< true if outputs are enabled
- devcb_read8 m_iord; //!< input line (read, offset = line, data = 0/1)
- devcb_write8 m_iowr; //!< output line (write, offset = line, data = 0/1)
+ UINT8 m_line[16]; //!< input/output flip-flops for 16 I/O lines
+ UINT8 m_bl; //!< value of BL during the most recent output
+ bool m_enable; //!< true if outputs are enabled
+ devcb_read8 m_iord; //!< input line (read, offset = line, data = 0/1)
+ devcb_write8 m_iowr; //!< output line (write, offset = line, data = 0/1)
};
extern const device_type RA17XX;
diff --git a/src/emu/machine/smpc.c b/src/emu/machine/smpc.c
index 93ffa7a0533..955a409b308 100644
--- a/src/emu/machine/smpc.c
+++ b/src/emu/machine/smpc.c
@@ -393,7 +393,7 @@ void saturn_state::smpc_analog_pad( UINT8 pad_num, UINT8 offset, UINT8 id)
void saturn_state::smpc_keyboard(UINT8 pad_num, UINT8 offset)
{
UINT16 game_key;
-
+
game_key = 0xffff;
game_key ^= ((ioport("KEYS_1")->read() & 0x80) << 8); // right
@@ -415,8 +415,8 @@ void saturn_state::smpc_keyboard(UINT8 pad_num, UINT8 offset)
m_smpc.OREG[2+pad_num*offset] = game_key>>8; // game buttons, TODO
m_smpc.OREG[3+pad_num*offset] = game_key & 0xff;
/*
- Keyboard Status hook-up
- TODO: how shift key actually works? EGWord uses it in order to switch between hiragana and katakana modes.
+ Keyboard Status hook-up
+ TODO: how shift key actually works? EGWord uses it in order to switch between hiragana and katakana modes.
x--- ---- 0
-x-- ---- caps lock
--x- ---- num lock
diff --git a/src/emu/machine/steppers.c b/src/emu/machine/steppers.c
index 5494caf2f3e..4bf3f80ba6e 100644
--- a/src/emu/machine/steppers.c
+++ b/src/emu/machine/steppers.c
@@ -46,7 +46,7 @@ stepper_device::stepper_device(const machine_config &mconfig, const char *tag, d
m_optic_cb(*this)
{
m_max_steps=(48*2);
- }
+ }
///////////////////////////////////////////////////////////////////////////
void stepper_device::update_optic()
diff --git a/src/emu/machine/steppers.h b/src/emu/machine/steppers.h
index 4d1b49adfd4..6e7fd90c5a6 100644
--- a/src/emu/machine/steppers.h
+++ b/src/emu/machine/steppers.h
@@ -31,29 +31,29 @@
#define MCFG_STEPPER_ADD(_tag)\
MCFG_DEVICE_ADD(_tag, STEPPER, 0)
-
+
#define MCFG_STEPPER_REEL_TYPE(_data) \
stepper_device::set_reel_type(*device, _data);
/* total size of reel (in half steps) */
#define MCFG_STEPPER_MAX_STEPS(_write) \
- stepper_device::set_max_steps(*device, _write);
-
+ stepper_device::set_max_steps(*device, _write);
+
/* start position of index (in half steps) */
#define MCFG_STEPPER_START_INDEX(_write) \
- stepper_device::set_start_index(*device, _write);
+ stepper_device::set_start_index(*device, _write);
-/* end position of index (in half steps) */
+/* end position of index (in half steps) */
#define MCFG_STEPPER_END_INDEX(_write) \
- stepper_device::set_end_index(*device, _write);
+ stepper_device::set_end_index(*device, _write);
-/* end position of index (in half steps) */
+/* end position of index (in half steps) */
#define MCFG_STEPPER_INDEX_PATTERN(_write) \
- stepper_device::set_index_pattern(*device, _write);
-
+ stepper_device::set_index_pattern(*device, _write);
+
/* Phase at 0, for opto linkage */
#define MCFG_STEPPER_INIT_PHASE(_write) \
- stepper_device::set_init_phase(*device, _write);
+ stepper_device::set_init_phase(*device, _write);
#define MCFG_STARPOINT_48STEP_ADD(_tag)\
MCFG_STEPPER_ADD(_tag)\
@@ -103,9 +103,9 @@ public:
template<class _Object> static devcb_base &set_optic_handler(device_t &device, _Object object) { return downcast<stepper_device &>(device).m_optic_cb.set_callback(object); }
- static void set_reel_type(device_t &device, UINT8 type)
- {
- downcast<stepper_device &>(device).m_type = type;
+ static void set_reel_type(device_t &device, UINT8 type)
+ {
+ downcast<stepper_device &>(device).m_type = type;
switch ( type )
{ default:
case STARPOINT_48STEP_REEL: /* STARPOINT RMxxx */
@@ -127,17 +127,17 @@ public:
case ECOIN_200STEP_REEL :
downcast<stepper_device &>(device).m_max_steps = (200*2);
break;
- }
+ }
}
static void set_max_steps(device_t &device, INT16 steps) { downcast<stepper_device &>(device).m_max_steps = steps; }
static void set_start_index(device_t &device, INT16 index) { downcast<stepper_device &>(device).m_index_start = index; }
- static void set_end_index(device_t &device, INT16 index) { downcast<stepper_device &>(device).m_index_end = index; }
- static void set_index_pattern(device_t &device, INT16 index) { downcast<stepper_device &>(device).m_index_patt = index; }
- static void set_init_phase(device_t &device, UINT8 phase)
+ static void set_end_index(device_t &device, INT16 index) { downcast<stepper_device &>(device).m_index_end = index; }
+ static void set_index_pattern(device_t &device, INT16 index) { downcast<stepper_device &>(device).m_index_patt = index; }
+ static void set_init_phase(device_t &device, UINT8 phase)
{
- downcast<stepper_device &>(device).m_initphase = phase;
- downcast<stepper_device &>(device).m_phase = phase;
- downcast<stepper_device &>(device).m_old_phase = phase;
+ downcast<stepper_device &>(device).m_initphase = phase;
+ downcast<stepper_device &>(device).m_phase = phase;
+ downcast<stepper_device &>(device).m_old_phase = phase;
}
/* update a motor */
diff --git a/src/emu/rendlay.c b/src/emu/rendlay.c
index a011a527445..72e8838f7f3 100644
--- a/src/emu/rendlay.c
+++ b/src/emu/rendlay.c
@@ -94,9 +94,9 @@ const int LAYOUT_VERSION = 2;
enum
{
- LINE_CAP_NONE = 0,
- LINE_CAP_START = 1,
- LINE_CAP_END = 2
+ LINE_CAP_NONE = 0,
+ LINE_CAP_START = 1,
+ LINE_CAP_END = 2
};
@@ -120,13 +120,13 @@ render_screen_list render_target::s_empty_screen_list;
inline int gcd(int a, int b)
{
- while (b != 0)
- {
- int t = b;
- b = a % b;
- a = t;
- }
- return a;
+ while (b != 0)
+ {
+ int t = b;
+ b = a % b;
+ a = t;
+ }
+ return a;
}
@@ -137,15 +137,15 @@ inline int gcd(int a, int b)
inline void reduce_fraction(int &num, int &den)
{
- // search the greatest common divisor
- int div = gcd(num, den);
-
- // reduce the fraction if a common divisor has been found
- if (div > 1)
- {
- num /= div;
- den /= div;
- }
+ // search the greatest common divisor
+ int div = gcd(num, den);
+
+ // reduce the fraction if a common divisor has been found
+ if (div > 1)
+ {
+ num /= div;
+ den /= div;
+ }
}
@@ -161,56 +161,56 @@ inline void reduce_fraction(int &num, int &den)
static int get_variable_value(running_machine &machine, const char *string, char **outputptr)
{
- char temp[100];
-
- // screen 0 parameters
- screen_device_iterator iter(machine.root_device());
- int scrnum = 0;
- for (const screen_device *device = iter.first(); device != NULL; device = iter.next(), scrnum++)
- {
- // native X aspect factor
- sprintf(temp, "~scr%dnativexaspect~", scrnum);
- if (!strncmp(string, temp, strlen(temp)))
- {
- int num = device->visible_area().width();
- int den = device->visible_area().height();
- reduce_fraction(num, den);
- *outputptr += sprintf(*outputptr, "%d", num);
- return strlen(temp);
- }
-
- // native Y aspect factor
- sprintf(temp, "~scr%dnativeyaspect~", scrnum);
- if (!strncmp(string, temp, strlen(temp)))
- {
- int num = device->visible_area().width();
- int den = device->visible_area().height();
- reduce_fraction(num, den);
- *outputptr += sprintf(*outputptr, "%d", den);
- return strlen(temp);
- }
-
- // native width
- sprintf(temp, "~scr%dwidth~", scrnum);
- if (!strncmp(string, temp, strlen(temp)))
- {
- *outputptr += sprintf(*outputptr, "%d", device->visible_area().width());
- return strlen(temp);
- }
-
- // native height
- sprintf(temp, "~scr%dheight~", scrnum);
- if (!strncmp(string, temp, strlen(temp)))
- {
- *outputptr += sprintf(*outputptr, "%d", device->visible_area().height());
- return strlen(temp);
- }
- }
-
- // default: copy the first character and continue
- **outputptr = *string;
- *outputptr += 1;
- return 1;
+ char temp[100];
+
+ // screen 0 parameters
+ screen_device_iterator iter(machine.root_device());
+ int scrnum = 0;
+ for (const screen_device *device = iter.first(); device != NULL; device = iter.next(), scrnum++)
+ {
+ // native X aspect factor
+ sprintf(temp, "~scr%dnativexaspect~", scrnum);
+ if (!strncmp(string, temp, strlen(temp)))
+ {
+ int num = device->visible_area().width();
+ int den = device->visible_area().height();
+ reduce_fraction(num, den);
+ *outputptr += sprintf(*outputptr, "%d", num);
+ return strlen(temp);
+ }
+
+ // native Y aspect factor
+ sprintf(temp, "~scr%dnativeyaspect~", scrnum);
+ if (!strncmp(string, temp, strlen(temp)))
+ {
+ int num = device->visible_area().width();
+ int den = device->visible_area().height();
+ reduce_fraction(num, den);
+ *outputptr += sprintf(*outputptr, "%d", den);
+ return strlen(temp);
+ }
+
+ // native width
+ sprintf(temp, "~scr%dwidth~", scrnum);
+ if (!strncmp(string, temp, strlen(temp)))
+ {
+ *outputptr += sprintf(*outputptr, "%d", device->visible_area().width());
+ return strlen(temp);
+ }
+
+ // native height
+ sprintf(temp, "~scr%dheight~", scrnum);
+ if (!strncmp(string, temp, strlen(temp)))
+ {
+ *outputptr += sprintf(*outputptr, "%d", device->visible_area().height());
+ return strlen(temp);
+ }
+ }
+
+ // default: copy the first character and continue
+ **outputptr = *string;
+ *outputptr += 1;
+ return 1;
}
@@ -222,32 +222,32 @@ static int get_variable_value(running_machine &machine, const char *string, char
static const char *xml_get_attribute_string_with_subst(running_machine &machine, xml_data_node &node, const char *attribute, const char *defvalue)
{
- const char *str = xml_get_attribute_string(&node, attribute, NULL);
- static char buffer[1000];
-
- // if nothing, just return the default
- if (str == NULL)
- return defvalue;
-
- // if no tildes, don't worry
- if (strchr(str, '~') == NULL)
- return str;
-
- // make a copy of the string, doing substitutions along the way
- const char *s;
- char *d;
- for (s = str, d = buffer; *s != 0; )
- {
- // if not a variable, just copy
- if (*s != '~')
- *d++ = *s++;
-
- // extract the variable
- else
- s += get_variable_value(machine, s, &d);
- }
- *d = 0;
- return buffer;
+ const char *str = xml_get_attribute_string(&node, attribute, NULL);
+ static char buffer[1000];
+
+ // if nothing, just return the default
+ if (str == NULL)
+ return defvalue;
+
+ // if no tildes, don't worry
+ if (strchr(str, '~') == NULL)
+ return str;
+
+ // make a copy of the string, doing substitutions along the way
+ const char *s;
+ char *d;
+ for (s = str, d = buffer; *s != 0; )
+ {
+ // if not a variable, just copy
+ if (*s != '~')
+ *d++ = *s++;
+
+ // extract the variable
+ else
+ s += get_variable_value(machine, s, &d);
+ }
+ *d = 0;
+ return buffer;
}
@@ -259,18 +259,18 @@ static const char *xml_get_attribute_string_with_subst(running_machine &machine,
static int xml_get_attribute_int_with_subst(running_machine &machine, xml_data_node &node, const char *attribute, int defvalue)
{
- const char *string = xml_get_attribute_string_with_subst(machine, node, attribute, NULL);
- int value;
-
- if (string == NULL)
- return defvalue;
- if (string[0] == '$')
- return (sscanf(&string[1], "%X", &value) == 1) ? value : defvalue;
- if (string[0] == '0' && string[1] == 'x')
- return (sscanf(&string[2], "%X", &value) == 1) ? value : defvalue;
- if (string[0] == '#')
- return (sscanf(&string[1], "%d", &value) == 1) ? value : defvalue;
- return (sscanf(&string[0], "%d", &value) == 1) ? value : defvalue;
+ const char *string = xml_get_attribute_string_with_subst(machine, node, attribute, NULL);
+ int value;
+
+ if (string == NULL)
+ return defvalue;
+ if (string[0] == '$')
+ return (sscanf(&string[1], "%X", &value) == 1) ? value : defvalue;
+ if (string[0] == '0' && string[1] == 'x')
+ return (sscanf(&string[2], "%X", &value) == 1) ? value : defvalue;
+ if (string[0] == '#')
+ return (sscanf(&string[1], "%d", &value) == 1) ? value : defvalue;
+ return (sscanf(&string[0], "%d", &value) == 1) ? value : defvalue;
}
@@ -282,12 +282,12 @@ static int xml_get_attribute_int_with_subst(running_machine &machine, xml_data_n
static float xml_get_attribute_float_with_subst(running_machine &machine, xml_data_node &node, const char *attribute, float defvalue)
{
- const char *string = xml_get_attribute_string_with_subst(machine, node, attribute, NULL);
- float value;
+ const char *string = xml_get_attribute_string_with_subst(machine, node, attribute, NULL);
+ float value;
- if (string == NULL || sscanf(string, "%f", &value) != 1)
- return defvalue;
- return value;
+ if (string == NULL || sscanf(string, "%f", &value) != 1)
+ return defvalue;
+ return value;
}
@@ -297,37 +297,37 @@ static float xml_get_attribute_float_with_subst(running_machine &machine, xml_da
void parse_bounds(running_machine &machine, xml_data_node *boundsnode, render_bounds &bounds)
{
- // skip if nothing
- if (boundsnode == NULL)
- {
- bounds.x0 = bounds.y0 = 0.0f;
- bounds.x1 = bounds.y1 = 1.0f;
- return;
- }
-
- // parse out the data
- if (xml_get_attribute(boundsnode, "left") != NULL)
- {
- // left/right/top/bottom format
- bounds.x0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "left", 0.0f);
- bounds.x1 = xml_get_attribute_float_with_subst(machine, *boundsnode, "right", 1.0f);
- bounds.y0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "top", 0.0f);
- bounds.y1 = xml_get_attribute_float_with_subst(machine, *boundsnode, "bottom", 1.0f);
- }
- else if (xml_get_attribute(boundsnode, "x") != NULL)
- {
- // x/y/width/height format
- bounds.x0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "x", 0.0f);
- bounds.x1 = bounds.x0 + xml_get_attribute_float_with_subst(machine, *boundsnode, "width", 1.0f);
- bounds.y0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "y", 0.0f);
- bounds.y1 = bounds.y0 + xml_get_attribute_float_with_subst(machine, *boundsnode, "height", 1.0f);
- }
- else
- throw emu_fatalerror("Illegal bounds value in XML");
-
- // check for errors
- if (bounds.x0 > bounds.x1 || bounds.y0 > bounds.y1)
- throw emu_fatalerror("Illegal bounds value in XML: (%f-%f)-(%f-%f)", bounds.x0, bounds.x1, bounds.y0, bounds.y1);
+ // skip if nothing
+ if (boundsnode == NULL)
+ {
+ bounds.x0 = bounds.y0 = 0.0f;
+ bounds.x1 = bounds.y1 = 1.0f;
+ return;
+ }
+
+ // parse out the data
+ if (xml_get_attribute(boundsnode, "left") != NULL)
+ {
+ // left/right/top/bottom format
+ bounds.x0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "left", 0.0f);
+ bounds.x1 = xml_get_attribute_float_with_subst(machine, *boundsnode, "right", 1.0f);
+ bounds.y0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "top", 0.0f);
+ bounds.y1 = xml_get_attribute_float_with_subst(machine, *boundsnode, "bottom", 1.0f);
+ }
+ else if (xml_get_attribute(boundsnode, "x") != NULL)
+ {
+ // x/y/width/height format
+ bounds.x0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "x", 0.0f);
+ bounds.x1 = bounds.x0 + xml_get_attribute_float_with_subst(machine, *boundsnode, "width", 1.0f);
+ bounds.y0 = xml_get_attribute_float_with_subst(machine, *boundsnode, "y", 0.0f);
+ bounds.y1 = bounds.y0 + xml_get_attribute_float_with_subst(machine, *boundsnode, "height", 1.0f);
+ }
+ else
+ throw emu_fatalerror("Illegal bounds value in XML");
+
+ // check for errors
+ if (bounds.x0 > bounds.x1 || bounds.y0 > bounds.y1)
+ throw emu_fatalerror("Illegal bounds value in XML: (%f-%f)-(%f-%f)", bounds.x0, bounds.x1, bounds.y0, bounds.y1);
}
@@ -337,23 +337,23 @@ void parse_bounds(running_machine &machine, xml_data_node *boundsnode, render_bo
void parse_color(running_machine &machine, xml_data_node *colornode, render_color &color)
{
- // skip if nothing
- if (colornode == NULL)
- {
- color.r = color.g = color.b = color.a = 1.0f;
- return;
- }
-
- // parse out the data
- color.r = xml_get_attribute_float_with_subst(machine, *colornode, "red", 1.0);
- color.g = xml_get_attribute_float_with_subst(machine, *colornode, "green", 1.0);
- color.b = xml_get_attribute_float_with_subst(machine, *colornode, "blue", 1.0);
- color.a = xml_get_attribute_float_with_subst(machine, *colornode, "alpha", 1.0);
-
- // check for errors
- if (color.r < 0.0 || color.r > 1.0 || color.g < 0.0 || color.g > 1.0 ||
- color.b < 0.0 || color.b > 1.0 || color.a < 0.0 || color.a > 1.0)
- throw emu_fatalerror("Illegal ARGB color value in XML: %f,%f,%f,%f", color.r, color.g, color.b, color.a);
+ // skip if nothing
+ if (colornode == NULL)
+ {
+ color.r = color.g = color.b = color.a = 1.0f;
+ return;
+ }
+
+ // parse out the data
+ color.r = xml_get_attribute_float_with_subst(machine, *colornode, "red", 1.0);
+ color.g = xml_get_attribute_float_with_subst(machine, *colornode, "green", 1.0);
+ color.b = xml_get_attribute_float_with_subst(machine, *colornode, "blue", 1.0);
+ color.a = xml_get_attribute_float_with_subst(machine, *colornode, "alpha", 1.0);
+
+ // check for errors
+ if (color.r < 0.0 || color.r > 1.0 || color.g < 0.0 || color.g > 1.0 ||
+ color.b < 0.0 || color.b > 1.0 || color.a < 0.0 || color.a > 1.0)
+ throw emu_fatalerror("Illegal ARGB color value in XML: %f,%f,%f,%f", color.r, color.g, color.b, color.a);
}
@@ -364,29 +364,29 @@ void parse_color(running_machine &machine, xml_data_node *colornode, render_colo
static void parse_orientation(running_machine &machine, xml_data_node *orientnode, int &orientation)
{
- // skip if nothing
- if (orientnode == NULL)
- {
- orientation = ROT0;
- return;
- }
-
- // parse out the data
- int rotate = xml_get_attribute_int_with_subst(machine, *orientnode, "rotate", 0);
- switch (rotate)
- {
- case 0: orientation = ROT0; break;
- case 90: orientation = ROT90; break;
- case 180: orientation = ROT180; break;
- case 270: orientation = ROT270; break;
- default: throw emu_fatalerror("Invalid rotation in XML orientation node: %d", rotate);
- }
- if (strcmp("yes", xml_get_attribute_string_with_subst(machine, *orientnode, "swapxy", "no")) == 0)
- orientation ^= ORIENTATION_SWAP_XY;
- if (strcmp("yes", xml_get_attribute_string_with_subst(machine, *orientnode, "flipx", "no")) == 0)
- orientation ^= ORIENTATION_FLIP_X;
- if (strcmp("yes", xml_get_attribute_string_with_subst(machine, *orientnode, "flipy", "no")) == 0)
- orientation ^= ORIENTATION_FLIP_Y;
+ // skip if nothing
+ if (orientnode == NULL)
+ {
+ orientation = ROT0;
+ return;
+ }
+
+ // parse out the data
+ int rotate = xml_get_attribute_int_with_subst(machine, *orientnode, "rotate", 0);
+ switch (rotate)
+ {
+ case 0: orientation = ROT0; break;
+ case 90: orientation = ROT90; break;
+ case 180: orientation = ROT180; break;
+ case 270: orientation = ROT270; break;
+ default: throw emu_fatalerror("Invalid rotation in XML orientation node: %d", rotate);
+ }
+ if (strcmp("yes", xml_get_attribute_string_with_subst(machine, *orientnode, "swapxy", "no")) == 0)
+ orientation ^= ORIENTATION_SWAP_XY;
+ if (strcmp("yes", xml_get_attribute_string_with_subst(machine, *orientnode, "flipx", "no")) == 0)
+ orientation ^= ORIENTATION_FLIP_X;
+ if (strcmp("yes", xml_get_attribute_string_with_subst(machine, *orientnode, "flipy", "no")) == 0)
+ orientation ^= ORIENTATION_FLIP_Y;
}
@@ -400,78 +400,78 @@ static void parse_orientation(running_machine &machine, xml_data_node *orientnod
//-------------------------------------------------
layout_element::layout_element(running_machine &machine, xml_data_node &elemnode, const char *dirname)
- : m_next(NULL),
- m_machine(machine),
- m_defstate(0),
- m_maxstate(0)
+ : m_next(NULL),
+ m_machine(machine),
+ m_defstate(0),
+ m_maxstate(0)
{
- // extract the name
- const char *name = xml_get_attribute_string_with_subst(machine, elemnode, "name", NULL);
- if (name == NULL)
- throw emu_fatalerror("All layout elements must have a name!\n");
- m_name = name;
-
- // get the default state
- m_defstate = xml_get_attribute_int_with_subst(machine, elemnode, "defstate", -1);
-
- // parse components in order
- bool first = true;
- render_bounds bounds = { 0 };
- for (xml_data_node *compnode = elemnode.child; compnode != NULL; compnode = compnode->next)
- {
- // allocate a new component
- component &newcomp = m_complist.append(*global_alloc(component(machine, *compnode, dirname)));
-
- // accumulate bounds
- if (first)
- bounds = newcomp.m_bounds;
- else
- union_render_bounds(&bounds, &newcomp.m_bounds);
- first = false;
-
- // determine the maximum state
- if (newcomp.m_state > m_maxstate)
- m_maxstate = newcomp.m_state;
- if (newcomp.m_type == component::CTYPE_LED7SEG || newcomp.m_type == component::CTYPE_LED8SEG_GTS1)
- m_maxstate = 255;
- if (newcomp.m_type == component::CTYPE_LED14SEG)
- m_maxstate = 16383;
- if (newcomp.m_type == component::CTYPE_LED14SEGSC || newcomp.m_type == component::CTYPE_LED16SEG)
- m_maxstate = 65535;
- if (newcomp.m_type == component::CTYPE_LED16SEGSC)
- m_maxstate = 262143;
- if (newcomp.m_type == component::CTYPE_DOTMATRIX)
- m_maxstate = 255;
- if (newcomp.m_type == component::CTYPE_DOTMATRIX5DOT)
- m_maxstate = 31;
- if (newcomp.m_type == component::CTYPE_DOTMATRIXDOT)
- m_maxstate = 1;
- if (newcomp.m_type == component::CTYPE_SIMPLECOUNTER)
- m_maxstate = xml_get_attribute_int_with_subst(machine, *compnode, "maxstate", 999);
- if (newcomp.m_type == component::CTYPE_REEL)
- m_maxstate = 65536;
- }
-
- if (m_complist.first() != NULL)
- {
- // determine the scale/offset for normalization
- float xoffs = bounds.x0;
- float yoffs = bounds.y0;
- float xscale = 1.0f / (bounds.x1 - bounds.x0);
- float yscale = 1.0f / (bounds.y1 - bounds.y0);
-
- // normalize all the component bounds
- for (component *curcomp = m_complist.first(); curcomp != NULL; curcomp = curcomp->next())
- {
- curcomp->m_bounds.x0 = (curcomp->m_bounds.x0 - xoffs) * xscale;
- curcomp->m_bounds.x1 = (curcomp->m_bounds.x1 - xoffs) * xscale;
- curcomp->m_bounds.y0 = (curcomp->m_bounds.y0 - yoffs) * yscale;
- curcomp->m_bounds.y1 = (curcomp->m_bounds.y1 - yoffs) * yscale;
- }
- }
-
- // allocate an array of element textures for the states
- m_elemtex.resize(m_maxstate + 1);
+ // extract the name
+ const char *name = xml_get_attribute_string_with_subst(machine, elemnode, "name", NULL);
+ if (name == NULL)
+ throw emu_fatalerror("All layout elements must have a name!\n");
+ m_name = name;
+
+ // get the default state
+ m_defstate = xml_get_attribute_int_with_subst(machine, elemnode, "defstate", -1);
+
+ // parse components in order
+ bool first = true;
+ render_bounds bounds = { 0 };
+ for (xml_data_node *compnode = elemnode.child; compnode != NULL; compnode = compnode->next)
+ {
+ // allocate a new component
+ component &newcomp = m_complist.append(*global_alloc(component(machine, *compnode, dirname)));
+
+ // accumulate bounds
+ if (first)
+ bounds = newcomp.m_bounds;
+ else
+ union_render_bounds(&bounds, &newcomp.m_bounds);
+ first = false;
+
+ // determine the maximum state
+ if (newcomp.m_state > m_maxstate)
+ m_maxstate = newcomp.m_state;
+ if (newcomp.m_type == component::CTYPE_LED7SEG || newcomp.m_type == component::CTYPE_LED8SEG_GTS1)
+ m_maxstate = 255;
+ if (newcomp.m_type == component::CTYPE_LED14SEG)
+ m_maxstate = 16383;
+ if (newcomp.m_type == component::CTYPE_LED14SEGSC || newcomp.m_type == component::CTYPE_LED16SEG)
+ m_maxstate = 65535;
+ if (newcomp.m_type == component::CTYPE_LED16SEGSC)
+ m_maxstate = 262143;
+ if (newcomp.m_type == component::CTYPE_DOTMATRIX)
+ m_maxstate = 255;
+ if (newcomp.m_type == component::CTYPE_DOTMATRIX5DOT)
+ m_maxstate = 31;
+ if (newcomp.m_type == component::CTYPE_DOTMATRIXDOT)
+ m_maxstate = 1;
+ if (newcomp.m_type == component::CTYPE_SIMPLECOUNTER)
+ m_maxstate = xml_get_attribute_int_with_subst(machine, *compnode, "maxstate", 999);
+ if (newcomp.m_type == component::CTYPE_REEL)
+ m_maxstate = 65536;
+ }
+
+ if (m_complist.first() != NULL)
+ {
+ // determine the scale/offset for normalization
+ float xoffs = bounds.x0;
+ float yoffs = bounds.y0;
+ float xscale = 1.0f / (bounds.x1 - bounds.x0);
+ float yscale = 1.0f / (bounds.y1 - bounds.y0);
+
+ // normalize all the component bounds
+ for (component *curcomp = m_complist.first(); curcomp != NULL; curcomp = curcomp->next())
+ {
+ curcomp->m_bounds.x0 = (curcomp->m_bounds.x0 - xoffs) * xscale;
+ curcomp->m_bounds.x1 = (curcomp->m_bounds.x1 - xoffs) * xscale;
+ curcomp->m_bounds.y0 = (curcomp->m_bounds.y0 - yoffs) * yscale;
+ curcomp->m_bounds.y1 = (curcomp->m_bounds.y1 - yoffs) * yscale;
+ }
+ }
+
+ // allocate an array of element textures for the states
+ m_elemtex.resize(m_maxstate + 1);
}
@@ -492,14 +492,14 @@ layout_element::~layout_element()
render_texture *layout_element::state_texture(int state)
{
- assert(state <= m_maxstate);
- if (m_elemtex[state].m_texture == NULL)
- {
- m_elemtex[state].m_element = this;
- m_elemtex[state].m_state = state;
- m_elemtex[state].m_texture = machine().render().texture_alloc(element_scale, &m_elemtex[state]);
- }
- return m_elemtex[state].m_texture;
+ assert(state <= m_maxstate);
+ if (m_elemtex[state].m_texture == NULL)
+ {
+ m_elemtex[state].m_element = this;
+ m_elemtex[state].m_state = state;
+ m_elemtex[state].m_texture = machine().render().texture_alloc(element_scale, &m_elemtex[state]);
+ }
+ return m_elemtex[state].m_texture;
}
@@ -511,23 +511,23 @@ render_texture *layout_element::state_texture(int state)
void layout_element::element_scale(bitmap_argb32 &dest, bitmap_argb32 &source, const rectangle &sbounds, void *param)
{
- texture *elemtex = (texture *)param;
-
- // iterate over components that are part of the current state
- for (component *curcomp = elemtex->m_element->m_complist.first(); curcomp != NULL; curcomp = curcomp->next())
- if (curcomp->m_state == -1 || curcomp->m_state == elemtex->m_state)
- {
- // get the local scaled bounds
- rectangle bounds;
- bounds.min_x = render_round_nearest(curcomp->bounds().x0 * dest.width());
- bounds.min_y = render_round_nearest(curcomp->bounds().y0 * dest.height());
- bounds.max_x = render_round_nearest(curcomp->bounds().x1 * dest.width());
- bounds.max_y = render_round_nearest(curcomp->bounds().y1 * dest.height());
- bounds &= dest.cliprect();
-
- // based on the component type, add to the texture
- curcomp->draw(elemtex->m_element->machine(), dest, bounds, elemtex->m_state);
- }
+ texture *elemtex = (texture *)param;
+
+ // iterate over components that are part of the current state
+ for (component *curcomp = elemtex->m_element->m_complist.first(); curcomp != NULL; curcomp = curcomp->next())
+ if (curcomp->m_state == -1 || curcomp->m_state == elemtex->m_state)
+ {
+ // get the local scaled bounds
+ rectangle bounds;
+ bounds.min_x = render_round_nearest(curcomp->bounds().x0 * dest.width());
+ bounds.min_y = render_round_nearest(curcomp->bounds().y0 * dest.height());
+ bounds.max_x = render_round_nearest(curcomp->bounds().x1 * dest.width());
+ bounds.max_y = render_round_nearest(curcomp->bounds().y1 * dest.height());
+ bounds &= dest.cliprect();
+
+ // based on the component type, add to the texture
+ curcomp->draw(elemtex->m_element->machine(), dest, bounds, elemtex->m_state);
+ }
}
@@ -540,9 +540,9 @@ void layout_element::element_scale(bitmap_argb32 &dest, bitmap_argb32 &source, c
//-------------------------------------------------
layout_element::texture::texture()
- : m_element(NULL),
- m_texture(NULL),
- m_state(0)
+ : m_element(NULL),
+ m_texture(NULL),
+ m_state(0)
{
}
@@ -553,8 +553,8 @@ layout_element::texture::texture()
layout_element::texture::~texture()
{
- if (m_element != NULL)
- m_element->machine().render().texture_free(m_texture);
+ if (m_element != NULL)
+ m_element->machine().render().texture_free(m_texture);
}
@@ -568,146 +568,146 @@ layout_element::texture::~texture()
//-------------------------------------------------
layout_element::component::component(running_machine &machine, xml_data_node &compnode, const char *dirname)
- : m_next(NULL),
- m_type(CTYPE_INVALID),
- m_state(0)
+ : m_next(NULL),
+ m_type(CTYPE_INVALID),
+ m_state(0)
{
- for (int i=0;i<MAX_BITMAPS;i++)
- m_hasalpha[i] = false;
-
- // fetch common data
- m_state = xml_get_attribute_int_with_subst(machine, compnode, "state", -1);
- parse_bounds(machine, xml_get_sibling(compnode.child, "bounds"), m_bounds);
- parse_color(machine, xml_get_sibling(compnode.child, "color"), m_color);
-
- // image nodes
- if (strcmp(compnode.name, "image") == 0)
- {
- m_type = CTYPE_IMAGE;
- if (dirname != NULL)
- m_dirname = dirname;
- m_imagefile[0] = xml_get_attribute_string_with_subst(machine, compnode, "file", "");
- m_alphafile[0] = xml_get_attribute_string_with_subst(machine, compnode, "alphafile", "");
- m_file[0].reset(global_alloc(emu_file(machine.options().art_path(), OPEN_FLAG_READ)));
- }
-
- // text nodes
- else if (strcmp(compnode.name, "text") == 0)
- {
- m_type = CTYPE_TEXT;
- m_string = xml_get_attribute_string_with_subst(machine, compnode, "string", "");
- m_textalign = xml_get_attribute_int_with_subst(machine, compnode, "align", 0);
- }
-
- // dotmatrix nodes
- else if (strcmp(compnode.name, "dotmatrix") == 0)
- {
- m_type = CTYPE_DOTMATRIX;
- }
- else if (strcmp(compnode.name, "dotmatrix5dot") == 0)
- {
- m_type = CTYPE_DOTMATRIX5DOT;
- }
- else if (strcmp(compnode.name, "dotmatrixdot") == 0)
- {
- m_type = CTYPE_DOTMATRIXDOT;
- }
-
- // simplecounter nodes
- else if (strcmp(compnode.name, "simplecounter") == 0)
- {
- m_type = CTYPE_SIMPLECOUNTER;
- m_digits = xml_get_attribute_int_with_subst(machine, compnode, "digits", 2);
- m_textalign = xml_get_attribute_int_with_subst(machine, compnode, "align", 0);
- }
-
- // fruit machine reels
- else if (strcmp(compnode.name, "reel") == 0)
- {
- m_type = CTYPE_REEL;
-
- astring symbollist = xml_get_attribute_string_with_subst(machine, compnode, "symbollist", "0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15");
-
- // split out position names from string and figure out our number of symbols
- int location = -1;
- m_numstops = 0;
- location=symbollist.find(0,",");
- while (location!=-1)
- {
- m_stopnames[m_numstops] = symbollist;
- m_stopnames[m_numstops].substr(0, location);
- symbollist.substr(location+1, symbollist.len()-(location-1));
- m_numstops++;
- location=symbollist.find(0,",");
- }
- m_stopnames[m_numstops++] = symbollist;
-
- // careful, dirname is NULL if we're coming from internal layout, and our string assignment doesn't like that
- if (dirname != NULL)
- m_dirname = dirname;
-
- for (int i=0;i<m_numstops;i++)
- {
- location=m_stopnames[i].find(0,":");
- if (location!=-1)
- {
- m_imagefile[i] = m_stopnames[i];
- m_stopnames[i].substr(0, location);
- m_imagefile[i].substr(location+1, m_imagefile[i].len()-(location-1));
-
- //m_alphafile[i] =
- m_file[i].reset(global_alloc(emu_file(machine.options().art_path(), OPEN_FLAG_READ)));
- }
- else
- {
- //m_imagefile[i] = 0;
- //m_alphafile[i] = 0;
- m_file[i].reset();
- }
- }
-
- m_stateoffset = xml_get_attribute_int_with_subst(machine, compnode, "stateoffset", 0);
- m_numsymbolsvisible = xml_get_attribute_int_with_subst(machine, compnode, "numsymbolsvisible", 3);
- m_reelreversed = xml_get_attribute_int_with_subst(machine, compnode, "reelreversed", 0);
- m_beltreel = xml_get_attribute_int_with_subst(machine, compnode, "beltreel", 0);
-
- }
-
- // led7seg nodes
- else if (strcmp(compnode.name, "led7seg") == 0)
- m_type = CTYPE_LED7SEG;
-
- // led8seg_gts1 nodes
- else if (strcmp(compnode.name, "led8seg_gts1") == 0)
- m_type = CTYPE_LED8SEG_GTS1;
-
- // led14seg nodes
- else if (strcmp(compnode.name, "led14seg") == 0)
- m_type = CTYPE_LED14SEG;
-
- // led14segsc nodes
- else if (strcmp(compnode.name, "led14segsc") == 0)
- m_type = CTYPE_LED14SEGSC;
-
- // led16seg nodes
- else if (strcmp(compnode.name, "led16seg") == 0)
- m_type = CTYPE_LED16SEG;
-
- // led16segsc nodes
- else if (strcmp(compnode.name, "led16segsc") == 0)
- m_type = CTYPE_LED16SEGSC;
-
- // rect nodes
- else if (strcmp(compnode.name, "rect") == 0)
- m_type = CTYPE_RECT;
-
- // disk nodes
- else if (strcmp(compnode.name, "disk") == 0)
- m_type = CTYPE_DISK;
-
- // error otherwise
- else
- throw emu_fatalerror("Unknown element component: %s", compnode.name);
+ for (int i=0;i<MAX_BITMAPS;i++)
+ m_hasalpha[i] = false;
+
+ // fetch common data
+ m_state = xml_get_attribute_int_with_subst(machine, compnode, "state", -1);
+ parse_bounds(machine, xml_get_sibling(compnode.child, "bounds"), m_bounds);
+ parse_color(machine, xml_get_sibling(compnode.child, "color"), m_color);
+
+ // image nodes
+ if (strcmp(compnode.name, "image") == 0)
+ {
+ m_type = CTYPE_IMAGE;
+ if (dirname != NULL)
+ m_dirname = dirname;
+ m_imagefile[0] = xml_get_attribute_string_with_subst(machine, compnode, "file", "");
+ m_alphafile[0] = xml_get_attribute_string_with_subst(machine, compnode, "alphafile", "");
+ m_file[0].reset(global_alloc(emu_file(machine.options().art_path(), OPEN_FLAG_READ)));
+ }
+
+ // text nodes
+ else if (strcmp(compnode.name, "text") == 0)
+ {
+ m_type = CTYPE_TEXT;
+ m_string = xml_get_attribute_string_with_subst(machine, compnode, "string", "");
+ m_textalign = xml_get_attribute_int_with_subst(machine, compnode, "align", 0);
+ }
+
+ // dotmatrix nodes
+ else if (strcmp(compnode.name, "dotmatrix") == 0)
+ {
+ m_type = CTYPE_DOTMATRIX;
+ }
+ else if (strcmp(compnode.name, "dotmatrix5dot") == 0)
+ {
+ m_type = CTYPE_DOTMATRIX5DOT;
+ }
+ else if (strcmp(compnode.name, "dotmatrixdot") == 0)
+ {
+ m_type = CTYPE_DOTMATRIXDOT;
+ }
+
+ // simplecounter nodes
+ else if (strcmp(compnode.name, "simplecounter") == 0)
+ {
+ m_type = CTYPE_SIMPLECOUNTER;
+ m_digits = xml_get_attribute_int_with_subst(machine, compnode, "digits", 2);
+ m_textalign = xml_get_attribute_int_with_subst(machine, compnode, "align", 0);
+ }
+
+ // fruit machine reels
+ else if (strcmp(compnode.name, "reel") == 0)
+ {
+ m_type = CTYPE_REEL;
+
+ astring symbollist = xml_get_attribute_string_with_subst(machine, compnode, "symbollist", "0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15");
+
+ // split out position names from string and figure out our number of symbols
+ int location = -1;
+ m_numstops = 0;
+ location=symbollist.find(0,",");
+ while (location!=-1)
+ {
+ m_stopnames[m_numstops] = symbollist;
+ m_stopnames[m_numstops].substr(0, location);
+ symbollist.substr(location+1, symbollist.len()-(location-1));
+ m_numstops++;
+ location=symbollist.find(0,",");
+ }
+ m_stopnames[m_numstops++] = symbollist;
+
+ // careful, dirname is NULL if we're coming from internal layout, and our string assignment doesn't like that
+ if (dirname != NULL)
+ m_dirname = dirname;
+
+ for (int i=0;i<m_numstops;i++)
+ {
+ location=m_stopnames[i].find(0,":");
+ if (location!=-1)
+ {
+ m_imagefile[i] = m_stopnames[i];
+ m_stopnames[i].substr(0, location);
+ m_imagefile[i].substr(location+1, m_imagefile[i].len()-(location-1));
+
+ //m_alphafile[i] =
+ m_file[i].reset(global_alloc(emu_file(machine.options().art_path(), OPEN_FLAG_READ)));
+ }
+ else
+ {
+ //m_imagefile[i] = 0;
+ //m_alphafile[i] = 0;
+ m_file[i].reset();
+ }
+ }
+
+ m_stateoffset = xml_get_attribute_int_with_subst(machine, compnode, "stateoffset", 0);
+ m_numsymbolsvisible = xml_get_attribute_int_with_subst(machine, compnode, "numsymbolsvisible", 3);
+ m_reelreversed = xml_get_attribute_int_with_subst(machine, compnode, "reelreversed", 0);
+ m_beltreel = xml_get_attribute_int_with_subst(machine, compnode, "beltreel", 0);
+
+ }
+
+ // led7seg nodes
+ else if (strcmp(compnode.name, "led7seg") == 0)
+ m_type = CTYPE_LED7SEG;
+
+ // led8seg_gts1 nodes
+ else if (strcmp(compnode.name, "led8seg_gts1") == 0)
+ m_type = CTYPE_LED8SEG_GTS1;
+
+ // led14seg nodes
+ else if (strcmp(compnode.name, "led14seg") == 0)
+ m_type = CTYPE_LED14SEG;
+
+ // led14segsc nodes
+ else if (strcmp(compnode.name, "led14segsc") == 0)
+ m_type = CTYPE_LED14SEGSC;
+
+ // led16seg nodes
+ else if (strcmp(compnode.name, "led16seg") == 0)
+ m_type = CTYPE_LED16SEG;
+
+ // led16segsc nodes
+ else if (strcmp(compnode.name, "led16segsc") == 0)
+ m_type = CTYPE_LED16SEGSC;
+
+ // rect nodes
+ else if (strcmp(compnode.name, "rect") == 0)
+ m_type = CTYPE_RECT;
+
+ // disk nodes
+ else if (strcmp(compnode.name, "disk") == 0)
+ m_type = CTYPE_DISK;
+
+ // error otherwise
+ else
+ throw emu_fatalerror("Unknown element component: %s", compnode.name);
}
@@ -726,76 +726,76 @@ layout_element::component::~component()
void layout_element::component::draw(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state)
{
- switch (m_type)
- {
- case CTYPE_IMAGE:
- if (!m_bitmap[0].valid())
- load_bitmap();
- {
- bitmap_argb32 destsub(dest, bounds);
- render_resample_argb_bitmap_hq(destsub, m_bitmap[0], m_color);
- }
- break;
-
- case CTYPE_RECT:
- draw_rect(dest, bounds);
- break;
-
- case CTYPE_DISK:
- draw_disk(dest, bounds);
- break;
-
- case CTYPE_TEXT:
- draw_text(machine, dest, bounds);
- break;
-
- case CTYPE_LED7SEG:
- draw_led7seg(dest, bounds, state);
- break;
-
- case CTYPE_LED8SEG_GTS1:
- draw_led8seg_gts1(dest, bounds, state);
- break;
-
- case CTYPE_LED14SEG:
- draw_led14seg(dest, bounds, state);
- break;
-
- case CTYPE_LED16SEG:
- draw_led16seg(dest, bounds, state);
- break;
-
- case CTYPE_LED14SEGSC:
- draw_led14segsc(dest, bounds, state);
- break;
-
- case CTYPE_LED16SEGSC:
- draw_led16segsc(dest, bounds, state);
- break;
-
- case CTYPE_DOTMATRIX:
- draw_dotmatrix(8, dest, bounds, state);
- break;
-
- case CTYPE_DOTMATRIX5DOT:
- draw_dotmatrix(5, dest, bounds, state);
- break;
-
- case CTYPE_DOTMATRIXDOT:
- draw_dotmatrix(1, dest, bounds, state);
- break;
-
- case CTYPE_SIMPLECOUNTER:
- draw_simplecounter(machine, dest, bounds, state);
- break;
-
- case CTYPE_REEL:
- draw_reel(machine, dest, bounds, state);
- break;
-
- default:
- throw emu_fatalerror("Unknown component type requested draw()");
- }
+ switch (m_type)
+ {
+ case CTYPE_IMAGE:
+ if (!m_bitmap[0].valid())
+ load_bitmap();
+ {
+ bitmap_argb32 destsub(dest, bounds);
+ render_resample_argb_bitmap_hq(destsub, m_bitmap[0], m_color);
+ }
+ break;
+
+ case CTYPE_RECT:
+ draw_rect(dest, bounds);
+ break;
+
+ case CTYPE_DISK:
+ draw_disk(dest, bounds);
+ break;
+
+ case CTYPE_TEXT:
+ draw_text(machine, dest, bounds);
+ break;
+
+ case CTYPE_LED7SEG:
+ draw_led7seg(dest, bounds, state);
+ break;
+
+ case CTYPE_LED8SEG_GTS1:
+ draw_led8seg_gts1(dest, bounds, state);
+ break;
+
+ case CTYPE_LED14SEG:
+ draw_led14seg(dest, bounds, state);
+ break;
+
+ case CTYPE_LED16SEG:
+ draw_led16seg(dest, bounds, state);
+ break;
+
+ case CTYPE_LED14SEGSC:
+ draw_led14segsc(dest, bounds, state);
+ break;
+
+ case CTYPE_LED16SEGSC:
+ draw_led16segsc(dest, bounds, state);
+ break;
+
+ case CTYPE_DOTMATRIX:
+ draw_dotmatrix(8, dest, bounds, state);
+ break;
+
+ case CTYPE_DOTMATRIX5DOT:
+ draw_dotmatrix(5, dest, bounds, state);
+ break;
+
+ case CTYPE_DOTMATRIXDOT:
+ draw_dotmatrix(1, dest, bounds, state);
+ break;
+
+ case CTYPE_SIMPLECOUNTER:
+ draw_simplecounter(machine, dest, bounds, state);
+ break;
+
+ case CTYPE_REEL:
+ draw_reel(machine, dest, bounds, state);
+ break;
+
+ default:
+ throw emu_fatalerror("Unknown component type requested draw()");
+ }
}
@@ -806,34 +806,34 @@ void layout_element::component::draw(running_machine &machine, bitmap_argb32 &de
void layout_element::component::draw_rect(bitmap_argb32 &dest, const rectangle &bounds)
{
- // compute premultiplied colors
- UINT32 r = m_color.r * m_color.a * 255.0;
- UINT32 g = m_color.g * m_color.a * 255.0;
- UINT32 b = m_color.b * m_color.a * 255.0;
- UINT32 inva = (1.0f - m_color.a) * 255.0;
-
- // iterate over X and Y
- for (UINT32 y = bounds.min_y; y <= bounds.max_y; y++)
- {
- for (UINT32 x = bounds.min_x; x <= bounds.max_x; x++)
- {
- UINT32 finalr = r;
- UINT32 finalg = g;
- UINT32 finalb = b;
-
- // if we're translucent, add in the destination pixel contribution
- if (inva > 0)
- {
- rgb_t dpix = dest.pix32(y, x);
- finalr += (dpix.r() * inva) >> 8;
- finalg += (dpix.g() * inva) >> 8;
- finalb += (dpix.b() * inva) >> 8;
- }
-
- // store the target pixel, dividing the RGBA values by the overall scale factor
- dest.pix32(y, x) = rgb_t(finalr, finalg, finalb);
- }
- }
+ // compute premultiplied colors
+ UINT32 r = m_color.r * m_color.a * 255.0;
+ UINT32 g = m_color.g * m_color.a * 255.0;
+ UINT32 b = m_color.b * m_color.a * 255.0;
+ UINT32 inva = (1.0f - m_color.a) * 255.0;
+
+ // iterate over X and Y
+ for (UINT32 y = bounds.min_y; y <= bounds.max_y; y++)
+ {
+ for (UINT32 x = bounds.min_x; x <= bounds.max_x; x++)
+ {
+ UINT32 finalr = r;
+ UINT32 finalg = g;
+ UINT32 finalb = b;
+
+ // if we're translucent, add in the destination pixel contribution
+ if (inva > 0)
+ {
+ rgb_t dpix = dest.pix32(y, x);
+ finalr += (dpix.r() * inva) >> 8;
+ finalg += (dpix.g() * inva) >> 8;
+ finalb += (dpix.b() * inva) >> 8;
+ }
+
+ // store the target pixel, dividing the RGBA values by the overall scale factor
+ dest.pix32(y, x) = rgb_t(finalr, finalg, finalb);
+ }
+ }
}
@@ -844,49 +844,49 @@ void layout_element::component::draw_rect(bitmap_argb32 &dest, const rectangle &
void layout_element::component::draw_disk(bitmap_argb32 &dest, const rectangle &bounds)
{
- // compute premultiplied colors
- UINT32 r = m_color.r * m_color.a * 255.0;
- UINT32 g = m_color.g * m_color.a * 255.0;
- UINT32 b = m_color.b * m_color.a * 255.0;
- UINT32 inva = (1.0f - m_color.a) * 255.0;
-
- // find the center
- float xcenter = float(bounds.xcenter());
- float ycenter = float(bounds.ycenter());
- float xradius = float(bounds.width()) * 0.5f;
- float yradius = float(bounds.height()) * 0.5f;
- float ooyradius2 = 1.0f / (yradius * yradius);
-
- // iterate over y
- for (UINT32 y = bounds.min_y; y <= bounds.max_y; y++)
- {
- float ycoord = ycenter - ((float)y + 0.5f);
- float xval = xradius * sqrt(1.0f - (ycoord * ycoord) * ooyradius2);
-
- // compute left/right coordinates
- INT32 left = (INT32)(xcenter - xval + 0.5f);
- INT32 right = (INT32)(xcenter + xval + 0.5f);
-
- // draw this scanline
- for (UINT32 x = left; x < right; x++)
- {
- UINT32 finalr = r;
- UINT32 finalg = g;
- UINT32 finalb = b;
-
- // if we're translucent, add in the destination pixel contribution
- if (inva > 0)
- {
- rgb_t dpix = dest.pix32(y, x);
- finalr += (dpix.r() * inva) >> 8;
- finalg += (dpix.g() * inva) >> 8;
- finalb += (dpix.b() * inva) >> 8;
- }
-
- // store the target pixel, dividing the RGBA values by the overall scale factor
- dest.pix32(y, x) = rgb_t(finalr, finalg, finalb);
- }
- }
+ // compute premultiplied colors
+ UINT32 r = m_color.r * m_color.a * 255.0;
+ UINT32 g = m_color.g * m_color.a * 255.0;
+ UINT32 b = m_color.b * m_color.a * 255.0;
+ UINT32 inva = (1.0f - m_color.a) * 255.0;
+
+ // find the center
+ float xcenter = float(bounds.xcenter());
+ float ycenter = float(bounds.ycenter());
+ float xradius = float(bounds.width()) * 0.5f;
+ float yradius = float(bounds.height()) * 0.5f;
+ float ooyradius2 = 1.0f / (yradius * yradius);
+
+ // iterate over y
+ for (UINT32 y = bounds.min_y; y <= bounds.max_y; y++)
+ {
+ float ycoord = ycenter - ((float)y + 0.5f);
+ float xval = xradius * sqrt(1.0f - (ycoord * ycoord) * ooyradius2);
+
+ // compute left/right coordinates
+ INT32 left = (INT32)(xcenter - xval + 0.5f);
+ INT32 right = (INT32)(xcenter + xval + 0.5f);
+
+ // draw this scanline
+ for (UINT32 x = left; x < right; x++)
+ {
+ UINT32 finalr = r;
+ UINT32 finalg = g;
+ UINT32 finalb = b;
+
+ // if we're translucent, add in the destination pixel contribution
+ if (inva > 0)
+ {
+ rgb_t dpix = dest.pix32(y, x);
+ finalr += (dpix.r() * inva) >> 8;
+ finalg += (dpix.g() * inva) >> 8;
+ finalb += (dpix.b() * inva) >> 8;
+ }
+
+ // store the target pixel, dividing the RGBA values by the overall scale factor
+ dest.pix32(y, x) = rgb_t(finalr, finalg, finalb);
+ }
+ }
}
@@ -896,408 +896,408 @@ void layout_element::component::draw_disk(bitmap_argb32 &dest, const rectangle &
void layout_element::component::draw_text(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds)
{
- // compute premultiplied colors
- UINT32 r = m_color.r * 255.0;
- UINT32 g = m_color.g * 255.0;
- UINT32 b = m_color.b * 255.0;
- UINT32 a = m_color.a * 255.0;
-
- // get the width of the string
- render_font *font = machine.render().font_alloc("default");
- float aspect = 1.0f;
- INT32 width;
-
-
- while (1)
- {
- width = font->string_width(bounds.height(), aspect, m_string);
- if (width < bounds.width())
- break;
- aspect *= 0.9f;
- }
-
-
- // get alignment
- INT32 curx;
- switch (m_textalign)
- {
- // left
- case 1:
- curx = bounds.min_x;
- break;
-
- // right
- case 2:
- curx = bounds.max_x - width;
- break;
-
- // default to center
- default:
- curx = bounds.min_x + (bounds.width() - width) / 2;
- break;
- }
-
- // allocate a temporary bitmap
- bitmap_argb32 tempbitmap(dest.width(), dest.height());
-
- // loop over characters
- for (const char *s = m_string; *s != 0; s++)
- {
- // get the font bitmap
- rectangle chbounds;
- font->get_scaled_bitmap_and_bounds(tempbitmap, bounds.height(), aspect, *s, chbounds);
-
- // copy the data into the target
- for (int y = 0; y < chbounds.height(); y++)
- {
- int effy = bounds.min_y + y;
- if (effy >= bounds.min_y && effy <= bounds.max_y)
- {
- UINT32 *src = &tempbitmap.pix32(y);
- UINT32 *d = &dest.pix32(effy);
- for (int x = 0; x < chbounds.width(); x++)
- {
- int effx = curx + x + chbounds.min_x;
- if (effx >= bounds.min_x && effx <= bounds.max_x)
- {
- UINT32 spix = rgb_t(src[x]).a();
- if (spix != 0)
- {
- rgb_t dpix = d[effx];
- UINT32 ta = (a * (spix + 1)) >> 8;
- UINT32 tr = (r * ta + dpix.r() * (0x100 - ta)) >> 8;
- UINT32 tg = (g * ta + dpix.g() * (0x100 - ta)) >> 8;
- UINT32 tb = (b * ta + dpix.b() * (0x100 - ta)) >> 8;
- d[effx] = rgb_t(tr, tg, tb);
- }
- }
- }
- }
- }
-
- // advance in the X direction
- curx += font->char_width(bounds.height(), aspect, *s);
- }
-
- // free the temporary bitmap and font
- machine.render().font_free(font);
+ // compute premultiplied colors
+ UINT32 r = m_color.r * 255.0;
+ UINT32 g = m_color.g * 255.0;
+ UINT32 b = m_color.b * 255.0;
+ UINT32 a = m_color.a * 255.0;
+
+ // get the width of the string
+ render_font *font = machine.render().font_alloc("default");
+ float aspect = 1.0f;
+ INT32 width;
+
+
+ while (1)
+ {
+ width = font->string_width(bounds.height(), aspect, m_string);
+ if (width < bounds.width())
+ break;
+ aspect *= 0.9f;
+ }
+
+
+ // get alignment
+ INT32 curx;
+ switch (m_textalign)
+ {
+ // left
+ case 1:
+ curx = bounds.min_x;
+ break;
+
+ // right
+ case 2:
+ curx = bounds.max_x - width;
+ break;
+
+ // default to center
+ default:
+ curx = bounds.min_x + (bounds.width() - width) / 2;
+ break;
+ }
+
+ // allocate a temporary bitmap
+ bitmap_argb32 tempbitmap(dest.width(), dest.height());
+
+ // loop over characters
+ for (const char *s = m_string; *s != 0; s++)
+ {
+ // get the font bitmap
+ rectangle chbounds;
+ font->get_scaled_bitmap_and_bounds(tempbitmap, bounds.height(), aspect, *s, chbounds);
+
+ // copy the data into the target
+ for (int y = 0; y < chbounds.height(); y++)
+ {
+ int effy = bounds.min_y + y;
+ if (effy >= bounds.min_y && effy <= bounds.max_y)
+ {
+ UINT32 *src = &tempbitmap.pix32(y);
+ UINT32 *d = &dest.pix32(effy);
+ for (int x = 0; x < chbounds.width(); x++)
+ {
+ int effx = curx + x + chbounds.min_x;
+ if (effx >= bounds.min_x && effx <= bounds.max_x)
+ {
+ UINT32 spix = rgb_t(src[x]).a();
+ if (spix != 0)
+ {
+ rgb_t dpix = d[effx];
+ UINT32 ta = (a * (spix + 1)) >> 8;
+ UINT32 tr = (r * ta + dpix.r() * (0x100 - ta)) >> 8;
+ UINT32 tg = (g * ta + dpix.g() * (0x100 - ta)) >> 8;
+ UINT32 tb = (b * ta + dpix.b() * (0x100 - ta)) >> 8;
+ d[effx] = rgb_t(tr, tg, tb);
+ }
+ }
+ }
+ }
+ }
+
+ // advance in the X direction
+ curx += font->char_width(bounds.height(), aspect, *s);
+ }
+
+ // free the temporary bitmap and font
+ machine.render().font_free(font);
}
void layout_element::component::draw_simplecounter(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state)
{
- char temp[256];
- sprintf(temp, "%0*d", m_digits, state);
- m_string = astring(temp);
- draw_text(machine, dest, bounds);
+ char temp[256];
+ sprintf(temp, "%0*d", m_digits, state);
+ m_string = astring(temp);
+ draw_text(machine, dest, bounds);
}
/* state is a normalized value between 0 and 65536 so that we don't need to worry about how many motor steps here or in the .lay, only the number of symbols */
void layout_element::component::draw_reel(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state)
{
- if (m_beltreel)
- {
- draw_beltreel(machine,dest,bounds,state);
- }
- else
- {
- const int max_state_used = 0x10000;
-
- // shift the reels a bit based on this param, allows fine tuning
- int use_state = (state + m_stateoffset) % max_state_used;
-
- // compute premultiplied colors
- UINT32 r = m_color.r * 255.0;
- UINT32 g = m_color.g * 255.0;
- UINT32 b = m_color.b * 255.0;
- UINT32 a = m_color.a * 255.0;
-
- // get the width of the string
- render_font *font = machine.render().font_alloc("default");
- float aspect = 1.0f;
- INT32 width;
-
-
- int curry = 0;
- int num_shown = m_numsymbolsvisible;
-
- int ourheight = bounds.height();
-
- for (int fruit = 0;fruit<m_numstops;fruit++)
- {
- int basey;
-
- if (m_reelreversed==1)
- {
- basey = bounds.min_y + ((use_state)*(ourheight/num_shown)/(max_state_used/m_numstops)) + curry;
- }
- else
- {
- basey = bounds.min_y - ((use_state)*(ourheight/num_shown)/(max_state_used/m_numstops)) + curry;
- }
-
- // wrap around...
- if (basey < bounds.min_y)
- basey += ((max_state_used)*(ourheight/num_shown)/(max_state_used/m_numstops));
- if (basey > bounds.max_y)
- basey -= ((max_state_used)*(ourheight/num_shown)/(max_state_used/m_numstops));
-
- int endpos = basey+ourheight/num_shown;
-
- // only render the symbol / text if it's atually in view because the code is SLOW
- if ((endpos >= bounds.min_y) && (basey <= bounds.max_y))
- {
- while (1)
- {
- width = font->string_width(ourheight/num_shown, aspect, m_stopnames[fruit]);
- if (width < bounds.width())
- break;
- aspect *= 0.9f;
- }
-
- INT32 curx;
- curx = bounds.min_x + (bounds.width() - width) / 2;
-
- if (m_file[fruit])
- if (!m_bitmap[fruit].valid())
- load_reel_bitmap(fruit);
-
- if (m_file[fruit]) // render gfx
- {
- bitmap_argb32 tempbitmap2(dest.width(), ourheight/num_shown);
-
- if (m_bitmap[fruit].valid())
- {
- render_resample_argb_bitmap_hq(tempbitmap2, m_bitmap[fruit], m_color);
-
- for (int y = 0; y < ourheight/num_shown; y++)
- {
- int effy = basey + y;
-
- if (effy >= bounds.min_y && effy <= bounds.max_y)
- {
- UINT32 *src = &tempbitmap2.pix32(y);
- UINT32 *d = &dest.pix32(effy);
- for (int x = 0; x < dest.width(); x++)
- {
- int effx = x;
- if (effx >= bounds.min_x && effx <= bounds.max_x)
- {
- UINT32 spix = rgb_t(src[x]).a();
- if (spix != 0)
- {
- d[effx] = src[x];
- }
- }
- }
- }
-
- }
- }
- }
- else // render text (fallback)
- {
- // allocate a temporary bitmap
- bitmap_argb32 tempbitmap(dest.width(), dest.height());
-
- // loop over characters
- for (const char *s = m_stopnames[fruit]; *s != 0; s++)
- {
- // get the font bitmap
- rectangle chbounds;
- font->get_scaled_bitmap_and_bounds(tempbitmap, ourheight/num_shown, aspect, *s, chbounds);
-
- // copy the data into the target
- for (int y = 0; y < chbounds.height(); y++)
- {
- int effy = basey + y;
-
- if (effy >= bounds.min_y && effy <= bounds.max_y)
- {
- UINT32 *src = &tempbitmap.pix32(y);
- UINT32 *d = &dest.pix32(effy);
- for (int x = 0; x < chbounds.width(); x++)
- {
- int effx = curx + x + chbounds.min_x;
- if (effx >= bounds.min_x && effx <= bounds.max_x)
- {
- UINT32 spix = rgb_t(src[x]).a();
- if (spix != 0)
- {
- rgb_t dpix = d[effx];
- UINT32 ta = (a * (spix + 1)) >> 8;
- UINT32 tr = (r * ta + dpix.r() * (0x100 - ta)) >> 8;
- UINT32 tg = (g * ta + dpix.g() * (0x100 - ta)) >> 8;
- UINT32 tb = (b * ta + dpix.b() * (0x100 - ta)) >> 8;
- d[effx] = rgb_t(tr, tg, tb);
- }
- }
- }
- }
- }
-
- // advance in the X direction
- curx += font->char_width(ourheight/num_shown, aspect, *s);
-
- }
-
- }
- }
-
- curry += ourheight/num_shown;
- }
- // free the temporary bitmap and font
- machine.render().font_free(font);
- }
+ if (m_beltreel)
+ {
+ draw_beltreel(machine,dest,bounds,state);
+ }
+ else
+ {
+ const int max_state_used = 0x10000;
+
+ // shift the reels a bit based on this param, allows fine tuning
+ int use_state = (state + m_stateoffset) % max_state_used;
+
+ // compute premultiplied colors
+ UINT32 r = m_color.r * 255.0;
+ UINT32 g = m_color.g * 255.0;
+ UINT32 b = m_color.b * 255.0;
+ UINT32 a = m_color.a * 255.0;
+
+ // get the width of the string
+ render_font *font = machine.render().font_alloc("default");
+ float aspect = 1.0f;
+ INT32 width;
+
+
+ int curry = 0;
+ int num_shown = m_numsymbolsvisible;
+
+ int ourheight = bounds.height();
+
+ for (int fruit = 0;fruit<m_numstops;fruit++)
+ {
+ int basey;
+
+ if (m_reelreversed==1)
+ {
+ basey = bounds.min_y + ((use_state)*(ourheight/num_shown)/(max_state_used/m_numstops)) + curry;
+ }
+ else
+ {
+ basey = bounds.min_y - ((use_state)*(ourheight/num_shown)/(max_state_used/m_numstops)) + curry;
+ }
+
+ // wrap around...
+ if (basey < bounds.min_y)
+ basey += ((max_state_used)*(ourheight/num_shown)/(max_state_used/m_numstops));
+ if (basey > bounds.max_y)
+ basey -= ((max_state_used)*(ourheight/num_shown)/(max_state_used/m_numstops));
+
+ int endpos = basey+ourheight/num_shown;
+
+ // only render the symbol / text if it's atually in view because the code is SLOW
+ if ((endpos >= bounds.min_y) && (basey <= bounds.max_y))
+ {
+ while (1)
+ {
+ width = font->string_width(ourheight/num_shown, aspect, m_stopnames[fruit]);
+ if (width < bounds.width())
+ break;
+ aspect *= 0.9f;
+ }
+
+ INT32 curx;
+ curx = bounds.min_x + (bounds.width() - width) / 2;
+
+ if (m_file[fruit])
+ if (!m_bitmap[fruit].valid())
+ load_reel_bitmap(fruit);
+
+ if (m_file[fruit]) // render gfx
+ {
+ bitmap_argb32 tempbitmap2(dest.width(), ourheight/num_shown);
+
+ if (m_bitmap[fruit].valid())
+ {
+ render_resample_argb_bitmap_hq(tempbitmap2, m_bitmap[fruit], m_color);
+
+ for (int y = 0; y < ourheight/num_shown; y++)
+ {
+ int effy = basey + y;
+
+ if (effy >= bounds.min_y && effy <= bounds.max_y)
+ {
+ UINT32 *src = &tempbitmap2.pix32(y);
+ UINT32 *d = &dest.pix32(effy);
+ for (int x = 0; x < dest.width(); x++)
+ {
+ int effx = x;
+ if (effx >= bounds.min_x && effx <= bounds.max_x)
+ {
+ UINT32 spix = rgb_t(src[x]).a();
+ if (spix != 0)
+ {
+ d[effx] = src[x];
+ }
+ }
+ }
+ }
+
+ }
+ }
+ }
+ else // render text (fallback)
+ {
+ // allocate a temporary bitmap
+ bitmap_argb32 tempbitmap(dest.width(), dest.height());
+
+ // loop over characters
+ for (const char *s = m_stopnames[fruit]; *s != 0; s++)
+ {
+ // get the font bitmap
+ rectangle chbounds;
+ font->get_scaled_bitmap_and_bounds(tempbitmap, ourheight/num_shown, aspect, *s, chbounds);
+
+ // copy the data into the target
+ for (int y = 0; y < chbounds.height(); y++)
+ {
+ int effy = basey + y;
+
+ if (effy >= bounds.min_y && effy <= bounds.max_y)
+ {
+ UINT32 *src = &tempbitmap.pix32(y);
+ UINT32 *d = &dest.pix32(effy);
+ for (int x = 0; x < chbounds.width(); x++)
+ {
+ int effx = curx + x + chbounds.min_x;
+ if (effx >= bounds.min_x && effx <= bounds.max_x)
+ {
+ UINT32 spix = rgb_t(src[x]).a();
+ if (spix != 0)
+ {
+ rgb_t dpix = d[effx];
+ UINT32 ta = (a * (spix + 1)) >> 8;
+ UINT32 tr = (r * ta + dpix.r() * (0x100 - ta)) >> 8;
+ UINT32 tg = (g * ta + dpix.g() * (0x100 - ta)) >> 8;
+ UINT32 tb = (b * ta + dpix.b() * (0x100 - ta)) >> 8;
+ d[effx] = rgb_t(tr, tg, tb);
+ }
+ }
+ }
+ }
+ }
+
+ // advance in the X direction
+ curx += font->char_width(ourheight/num_shown, aspect, *s);
+
+ }
+
+ }
+ }
+
+ curry += ourheight/num_shown;
+ }
+ // free the temporary bitmap and font
+ machine.render().font_free(font);
+ }
}
void layout_element::component::draw_beltreel(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state)
{
- const int max_state_used = 0x10000;
-
- // shift the reels a bit based on this param, allows fine tuning
- int use_state = (state + m_stateoffset) % max_state_used;
-
- // compute premultiplied colors
- UINT32 r = m_color.r * 255.0;
- UINT32 g = m_color.g * 255.0;
- UINT32 b = m_color.b * 255.0;
- UINT32 a = m_color.a * 255.0;
-
- // get the width of the string
- render_font *font = machine.render().font_alloc("default");
- float aspect = 1.0f;
- INT32 width;
- int currx = 0;
- int num_shown = m_numsymbolsvisible;
-
- int ourwidth = bounds.width();
-
- for (int fruit = 0;fruit<m_numstops;fruit++)
- {
- int basex;
- if (m_reelreversed==1)
- {
- basex = bounds.min_x + ((use_state)*(ourwidth/num_shown)/(max_state_used/m_numstops)) + currx;
- }
- else
- {
- basex = bounds.min_x - ((use_state)*(ourwidth/num_shown)/(max_state_used/m_numstops)) + currx;
- }
-
- // wrap around...
- if (basex < bounds.min_x)
- basex += ((max_state_used)*(ourwidth/num_shown)/(max_state_used/m_numstops));
- if (basex > bounds.max_x)
- basex -= ((max_state_used)*(ourwidth/num_shown)/(max_state_used/m_numstops));
-
- int endpos = basex+(ourwidth/num_shown);
-
- // only render the symbol / text if it's atually in view because the code is SLOW
- if ((endpos >= bounds.min_x) && (basex <= bounds.max_x))
- {
- while (1)
- {
- width = font->string_width(dest.height(), aspect, m_stopnames[fruit]);
- if (width < bounds.width())
- break;
- aspect *= 0.9f;
- }
-
- INT32 curx;
- curx = bounds.min_x;
-
- if (m_file[fruit])
- if (!m_bitmap[fruit].valid())
- load_reel_bitmap(fruit);
-
- if (m_file[fruit]) // render gfx
- {
- bitmap_argb32 tempbitmap2(ourwidth/num_shown, dest.height());
-
- if (m_bitmap[fruit].valid())
- {
- render_resample_argb_bitmap_hq(tempbitmap2, m_bitmap[fruit], m_color);
-
- for (int y = 0; y < dest.height(); y++)
- {
- int effy = y;
-
- if (effy >= bounds.min_y && effy <= bounds.max_y)
- {
- UINT32 *src = &tempbitmap2.pix32(y);
- UINT32 *d = &dest.pix32(effy);
- for (int x = 0; x < ourwidth/num_shown; x++)
- {
- int effx = basex + x;
- if (effx >= bounds.min_x && effx <= bounds.max_x)
- {
- UINT32 spix = rgb_t(src[x]).a();
- if (spix != 0)
- {
- d[effx] = src[x];
- }
- }
- }
- }
-
- }
- }
- }
- else // render text (fallback)
- {
- // allocate a temporary bitmap
- bitmap_argb32 tempbitmap(dest.width(), dest.height());
-
- // loop over characters
- for (const char *s = m_stopnames[fruit]; *s != 0; s++)
- {
- // get the font bitmap
- rectangle chbounds;
- font->get_scaled_bitmap_and_bounds(tempbitmap, dest.height(), aspect, *s, chbounds);
-
- // copy the data into the target
- for (int y = 0; y < chbounds.height(); y++)
- {
- int effy = y;
-
- if (effy >= bounds.min_y && effy <= bounds.max_y)
- {
- UINT32 *src = &tempbitmap.pix32(y);
- UINT32 *d = &dest.pix32(effy);
- for (int x = 0; x < chbounds.width(); x++)
- {
- int effx = basex + curx + x;
- if (effx >= bounds.min_x && effx <= bounds.max_x)
- {
- UINT32 spix = rgb_t(src[x]).a();
- if (spix != 0)
- {
- rgb_t dpix = d[effx];
- UINT32 ta = (a * (spix + 1)) >> 8;
- UINT32 tr = (r * ta + dpix.r() * (0x100 - ta)) >> 8;
- UINT32 tg = (g * ta + dpix.g() * (0x100 - ta)) >> 8;
- UINT32 tb = (b * ta + dpix.b() * (0x100 - ta)) >> 8;
- d[effx] = rgb_t(tr, tg, tb);
- }
- }
- }
- }
- }
-
- // advance in the X direction
- curx += font->char_width(dest.height(), aspect, *s);
-
- }
-
- }
- }
-
- currx += ourwidth/num_shown;
- }
-
- // free the temporary bitmap and font
- machine.render().font_free(font);
+ const int max_state_used = 0x10000;
+
+ // shift the reels a bit based on this param, allows fine tuning
+ int use_state = (state + m_stateoffset) % max_state_used;
+
+ // compute premultiplied colors
+ UINT32 r = m_color.r * 255.0;
+ UINT32 g = m_color.g * 255.0;
+ UINT32 b = m_color.b * 255.0;
+ UINT32 a = m_color.a * 255.0;
+
+ // get the width of the string
+ render_font *font = machine.render().font_alloc("default");
+ float aspect = 1.0f;
+ INT32 width;
+ int currx = 0;
+ int num_shown = m_numsymbolsvisible;
+
+ int ourwidth = bounds.width();
+
+ for (int fruit = 0;fruit<m_numstops;fruit++)
+ {
+ int basex;
+ if (m_reelreversed==1)
+ {
+ basex = bounds.min_x + ((use_state)*(ourwidth/num_shown)/(max_state_used/m_numstops)) + currx;
+ }
+ else
+ {
+ basex = bounds.min_x - ((use_state)*(ourwidth/num_shown)/(max_state_used/m_numstops)) + currx;
+ }
+
+ // wrap around...
+ if (basex < bounds.min_x)
+ basex += ((max_state_used)*(ourwidth/num_shown)/(max_state_used/m_numstops));
+ if (basex > bounds.max_x)
+ basex -= ((max_state_used)*(ourwidth/num_shown)/(max_state_used/m_numstops));
+
+ int endpos = basex+(ourwidth/num_shown);
+
+ // only render the symbol / text if it's atually in view because the code is SLOW
+ if ((endpos >= bounds.min_x) && (basex <= bounds.max_x))
+ {
+ while (1)
+ {
+ width = font->string_width(dest.height(), aspect, m_stopnames[fruit]);
+ if (width < bounds.width())
+ break;
+ aspect *= 0.9f;
+ }
+
+ INT32 curx;
+ curx = bounds.min_x;
+
+ if (m_file[fruit])
+ if (!m_bitmap[fruit].valid())
+ load_reel_bitmap(fruit);
+
+ if (m_file[fruit]) // render gfx
+ {
+ bitmap_argb32 tempbitmap2(ourwidth/num_shown, dest.height());
+
+ if (m_bitmap[fruit].valid())
+ {
+ render_resample_argb_bitmap_hq(tempbitmap2, m_bitmap[fruit], m_color);
+
+ for (int y = 0; y < dest.height(); y++)
+ {
+ int effy = y;
+
+ if (effy >= bounds.min_y && effy <= bounds.max_y)
+ {
+ UINT32 *src = &tempbitmap2.pix32(y);
+ UINT32 *d = &dest.pix32(effy);
+ for (int x = 0; x < ourwidth/num_shown; x++)
+ {
+ int effx = basex + x;
+ if (effx >= bounds.min_x && effx <= bounds.max_x)
+ {
+ UINT32 spix = rgb_t(src[x]).a();
+ if (spix != 0)
+ {
+ d[effx] = src[x];
+ }
+ }
+ }
+ }
+
+ }
+ }
+ }
+ else // render text (fallback)
+ {
+ // allocate a temporary bitmap
+ bitmap_argb32 tempbitmap(dest.width(), dest.height());
+
+ // loop over characters
+ for (const char *s = m_stopnames[fruit]; *s != 0; s++)
+ {
+ // get the font bitmap
+ rectangle chbounds;
+ font->get_scaled_bitmap_and_bounds(tempbitmap, dest.height(), aspect, *s, chbounds);
+
+ // copy the data into the target
+ for (int y = 0; y < chbounds.height(); y++)
+ {
+ int effy = y;
+
+ if (effy >= bounds.min_y && effy <= bounds.max_y)
+ {
+ UINT32 *src = &tempbitmap.pix32(y);
+ UINT32 *d = &dest.pix32(effy);
+ for (int x = 0; x < chbounds.width(); x++)
+ {
+ int effx = basex + curx + x;
+ if (effx >= bounds.min_x && effx <= bounds.max_x)
+ {
+ UINT32 spix = rgb_t(src[x]).a();
+ if (spix != 0)
+ {
+ rgb_t dpix = d[effx];
+ UINT32 ta = (a * (spix + 1)) >> 8;
+ UINT32 tr = (r * ta + dpix.r() * (0x100 - ta)) >> 8;
+ UINT32 tg = (g * ta + dpix.g() * (0x100 - ta)) >> 8;
+ UINT32 tb = (b * ta + dpix.b() * (0x100 - ta)) >> 8;
+ d[effx] = rgb_t(tr, tg, tb);
+ }
+ }
+ }
+ }
+ }
+
+ // advance in the X direction
+ curx += font->char_width(dest.height(), aspect, *s);
+
+ }
+
+ }
+ }
+
+ currx += ourwidth/num_shown;
+ }
+
+ // free the temporary bitmap and font
+ machine.render().font_free(font);
}
@@ -1308,49 +1308,49 @@ void layout_element::component::draw_beltreel(running_machine &machine, bitmap_a
void layout_element::component::load_bitmap()
{
- // load the basic bitmap
- assert(m_file[0] != NULL);
- m_hasalpha[0] = render_load_png(m_bitmap[0], *m_file[0], m_dirname, m_imagefile[0]);
-
- // load the alpha bitmap if specified
- if (m_bitmap[0].valid() && m_alphafile[0])
- render_load_png(m_bitmap[0], *m_file[0], m_dirname, m_alphafile[0], true);
-
- // if we can't load the bitmap, allocate a dummy one and report an error
- if (!m_bitmap[0].valid())
- {
- // draw some stripes in the bitmap
- m_bitmap[0].allocate(100, 100);
- m_bitmap[0].fill(0);
- for (int step = 0; step < 100; step += 25)
- for (int line = 0; line < 100; line++)
- m_bitmap[0].pix32((step + line) % 100, line % 100) = rgb_t(0xff,0xff,0xff,0xff);
-
- // log an error
- if (!m_alphafile[0])
- osd_printf_warning("Unable to load component bitmap '%s'\n", m_imagefile[0].cstr());
- else
- osd_printf_warning("Unable to load component bitmap '%s'/'%s'\n", m_imagefile[0].cstr(), m_alphafile[0].cstr());
- }
+ // load the basic bitmap
+ assert(m_file[0] != NULL);
+ m_hasalpha[0] = render_load_png(m_bitmap[0], *m_file[0], m_dirname, m_imagefile[0]);
+
+ // load the alpha bitmap if specified
+ if (m_bitmap[0].valid() && m_alphafile[0])
+ render_load_png(m_bitmap[0], *m_file[0], m_dirname, m_alphafile[0], true);
+
+ // if we can't load the bitmap, allocate a dummy one and report an error
+ if (!m_bitmap[0].valid())
+ {
+ // draw some stripes in the bitmap
+ m_bitmap[0].allocate(100, 100);
+ m_bitmap[0].fill(0);
+ for (int step = 0; step < 100; step += 25)
+ for (int line = 0; line < 100; line++)
+ m_bitmap[0].pix32((step + line) % 100, line % 100) = rgb_t(0xff,0xff,0xff,0xff);
+
+ // log an error
+ if (!m_alphafile[0])
+ osd_printf_warning("Unable to load component bitmap '%s'\n", m_imagefile[0].cstr());
+ else
+ osd_printf_warning("Unable to load component bitmap '%s'/'%s'\n", m_imagefile[0].cstr(), m_alphafile[0].cstr());
+ }
}
void layout_element::component::load_reel_bitmap(int number)
{
- // load the basic bitmap
- assert(m_file != NULL);
- /*m_hasalpha[number] = */ render_load_png(m_bitmap[number], *m_file[number], m_dirname, m_imagefile[number]);
+ // load the basic bitmap
+ assert(m_file != NULL);
+ /*m_hasalpha[number] = */ render_load_png(m_bitmap[number], *m_file[number], m_dirname, m_imagefile[number]);
- // load the alpha bitmap if specified
- //if (m_bitmap[number].valid() && m_alphafile[number])
- // render_load_png(m_bitmap[number], *m_file[number], m_dirname, m_alphafile[number], true);
+ // load the alpha bitmap if specified
+ //if (m_bitmap[number].valid() && m_alphafile[number])
+ // render_load_png(m_bitmap[number], *m_file[number], m_dirname, m_alphafile[number], true);
- // if we can't load the bitmap just use text rendering
- if (!m_bitmap[number].valid())
- {
- // fallback to text rendering
- m_file[number].reset();
- }
+ // if we can't load the bitmap just use text rendering
+ if (!m_bitmap[number].valid())
+ {
+ // fallback to text rendering
+ m_file[number].reset();
+ }
}
@@ -1362,48 +1362,48 @@ void layout_element::component::load_reel_bitmap(int number)
void layout_element::component::draw_led7seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff,0xff,0xff,0xff);
- const rgb_t offpen = rgb_t(0xff,0x20,0x20,0x20);
+ const rgb_t onpen = rgb_t(0xff,0xff,0xff,0xff);
+ const rgb_t offpen = rgb_t(0xff,0x20,0x20,0x20);
- // sizes for computation
- int bmwidth = 250;
- int bmheight = 400;
- int segwidth = 40;
- int skewwidth = 40;
+ // sizes for computation
+ int bmwidth = 250;
+ int bmheight = 400;
+ int segwidth = 40;
+ int skewwidth = 40;
- // allocate a temporary bitmap for drawing
- bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
- tempbitmap.fill(rgb_t(0xff,0x00,0x00,0x00));
+ // allocate a temporary bitmap for drawing
+ bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
+ tempbitmap.fill(rgb_t(0xff,0x00,0x00,0x00));
- // top bar
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 0)) ? onpen : offpen);
+ // top bar
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 0)) ? onpen : offpen);
- // top-right bar
- draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 1)) ? onpen : offpen);
+ // top-right bar
+ draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 1)) ? onpen : offpen);
- // bottom-right bar
- draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 2)) ? onpen : offpen);
+ // bottom-right bar
+ draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 2)) ? onpen : offpen);
- // bottom bar
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2, segwidth, (pattern & (1 << 3)) ? onpen : offpen);
+ // bottom bar
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2, segwidth, (pattern & (1 << 3)) ? onpen : offpen);
- // bottom-left bar
- draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 4)) ? onpen : offpen);
+ // bottom-left bar
+ draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 4)) ? onpen : offpen);
- // top-left bar
- draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 5)) ? onpen : offpen);
+ // top-left bar
+ draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 5)) ? onpen : offpen);
- // middle bar
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight/2, segwidth, (pattern & (1 << 6)) ? onpen : offpen);
+ // middle bar
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight/2, segwidth, (pattern & (1 << 6)) ? onpen : offpen);
- // apply skew
- apply_skew(tempbitmap, 40);
+ // apply skew
+ apply_skew(tempbitmap, 40);
- // decimal point
- draw_segment_decimal(tempbitmap, bmwidth + segwidth/2, bmheight - segwidth/2, segwidth, (pattern & (1 << 7)) ? onpen : offpen);
+ // decimal point
+ draw_segment_decimal(tempbitmap, bmwidth + segwidth/2, bmheight - segwidth/2, segwidth, (pattern & (1 << 7)) ? onpen : offpen);
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1413,54 +1413,54 @@ void layout_element::component::draw_led7seg(bitmap_argb32 &dest, const rectangl
void layout_element::component::draw_led8seg_gts1(bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff,0xff,0xff,0xff);
- const rgb_t offpen = rgb_t(0xff,0x20,0x20,0x20);
- const rgb_t backpen = rgb_t(0xff,0x00,0x00,0x00);
+ const rgb_t onpen = rgb_t(0xff,0xff,0xff,0xff);
+ const rgb_t offpen = rgb_t(0xff,0x20,0x20,0x20);
+ const rgb_t backpen = rgb_t(0xff,0x00,0x00,0x00);
- // sizes for computation
- int bmwidth = 250;
- int bmheight = 400;
- int segwidth = 40;
- int skewwidth = 40;
+ // sizes for computation
+ int bmwidth = 250;
+ int bmheight = 400;
+ int segwidth = 40;
+ int skewwidth = 40;
- // allocate a temporary bitmap for drawing
- bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
- tempbitmap.fill(backpen);
+ // allocate a temporary bitmap for drawing
+ bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
+ tempbitmap.fill(backpen);
- // top bar
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 0)) ? onpen : offpen);
+ // top bar
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 0)) ? onpen : offpen);
- // top-right bar
- draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 1)) ? onpen : offpen);
+ // top-right bar
+ draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 1)) ? onpen : offpen);
- // bottom-right bar
- draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 2)) ? onpen : offpen);
+ // bottom-right bar
+ draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2, segwidth, (pattern & (1 << 2)) ? onpen : offpen);
- // bottom bar
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2, segwidth, (pattern & (1 << 3)) ? onpen : offpen);
+ // bottom bar
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2, segwidth, (pattern & (1 << 3)) ? onpen : offpen);
- // bottom-left bar
- draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 4)) ? onpen : offpen);
+ // bottom-left bar
+ draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 4)) ? onpen : offpen);
- // top-left bar
- draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 5)) ? onpen : offpen);
+ // top-left bar
+ draw_segment_vertical(tempbitmap, 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2, segwidth, (pattern & (1 << 5)) ? onpen : offpen);
- // horizontal bars
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, 2*bmwidth/3 - 2*segwidth/3, bmheight/2, segwidth, (pattern & (1 << 6)) ? onpen : offpen);
- draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3 + bmwidth/2, bmwidth - 2*segwidth/3, bmheight/2, segwidth, (pattern & (1 << 6)) ? onpen : offpen);
+ // horizontal bars
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3, 2*bmwidth/3 - 2*segwidth/3, bmheight/2, segwidth, (pattern & (1 << 6)) ? onpen : offpen);
+ draw_segment_horizontal(tempbitmap, 0 + 2*segwidth/3 + bmwidth/2, bmwidth - 2*segwidth/3, bmheight/2, segwidth, (pattern & (1 << 6)) ? onpen : offpen);
- // vertical bars
- draw_segment_vertical(tempbitmap, 0 + segwidth/3 - 8, bmheight/2 - segwidth/3 + 2, 2*bmwidth/3 - segwidth/2 - 4, segwidth + 8, backpen);
- draw_segment_vertical(tempbitmap, 0 + segwidth/3, bmheight/2 - segwidth/3, 2*bmwidth/3 - segwidth/2 - 4, segwidth, (pattern & (1 << 7)) ? onpen : offpen);
+ // vertical bars
+ draw_segment_vertical(tempbitmap, 0 + segwidth/3 - 8, bmheight/2 - segwidth/3 + 2, 2*bmwidth/3 - segwidth/2 - 4, segwidth + 8, backpen);
+ draw_segment_vertical(tempbitmap, 0 + segwidth/3, bmheight/2 - segwidth/3, 2*bmwidth/3 - segwidth/2 - 4, segwidth, (pattern & (1 << 7)) ? onpen : offpen);
- draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3 - 2, bmheight - segwidth/3 + 8, 2*bmwidth/3 - segwidth/2 - 4, segwidth + 8, backpen);
- draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - segwidth/3, 2*bmwidth/3 - segwidth/2 - 4, segwidth, (pattern & (1 << 7)) ? onpen : offpen);
+ draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3 - 2, bmheight - segwidth/3 + 8, 2*bmwidth/3 - segwidth/2 - 4, segwidth + 8, backpen);
+ draw_segment_vertical(tempbitmap, bmheight/2 + segwidth/3, bmheight - segwidth/3, 2*bmwidth/3 - segwidth/2 - 4, segwidth, (pattern & (1 << 7)) ? onpen : offpen);
- // apply skew
- apply_skew(tempbitmap, 40);
+ // apply skew
+ apply_skew(tempbitmap, 40);
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1470,98 +1470,98 @@ void layout_element::component::draw_led8seg_gts1(bitmap_argb32 &dest, const rec
void layout_element::component::draw_led14seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
- const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
-
- // sizes for computation
- int bmwidth = 250;
- int bmheight = 400;
- int segwidth = 40;
- int skewwidth = 40;
-
- // allocate a temporary bitmap for drawing
- bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
- tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
-
- // top bar
- draw_segment_horizontal(tempbitmap,
- 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 0)) ? onpen : offpen);
-
- // right-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 1)) ? onpen : offpen);
-
- // right-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 2)) ? onpen : offpen);
-
- // bottom bar
- draw_segment_horizontal(tempbitmap,
- 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
- segwidth, (pattern & (1 << 3)) ? onpen : offpen);
-
- // left-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 4)) ? onpen : offpen);
-
- // left-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 5)) ? onpen : offpen);
-
- // horizontal-middle-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 6)) ? onpen : offpen);
-
- // horizontal-middle-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 7)) ? onpen : offpen);
-
- // vertical-middle-top bar
- draw_segment_vertical_caps(tempbitmap,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 8)) ? onpen : offpen);
-
- // vertical-middle-bottom bar
- draw_segment_vertical_caps(tempbitmap,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 9)) ? onpen : offpen);
-
- // diagonal-left-bottom bar
- draw_segment_diagonal_1(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 10)) ? onpen : offpen);
-
- // diagonal-left-top bar
- draw_segment_diagonal_2(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 11)) ? onpen : offpen);
-
- // diagonal-right-top bar
- draw_segment_diagonal_1(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 12)) ? onpen : offpen);
-
- // diagonal-right-bottom bar
- draw_segment_diagonal_2(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 13)) ? onpen : offpen);
-
- // apply skew
- apply_skew(tempbitmap, 40);
-
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
+ const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
+
+ // sizes for computation
+ int bmwidth = 250;
+ int bmheight = 400;
+ int segwidth = 40;
+ int skewwidth = 40;
+
+ // allocate a temporary bitmap for drawing
+ bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
+ tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
+
+ // top bar
+ draw_segment_horizontal(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 0)) ? onpen : offpen);
+
+ // right-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 1)) ? onpen : offpen);
+
+ // right-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 2)) ? onpen : offpen);
+
+ // bottom bar
+ draw_segment_horizontal(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
+ segwidth, (pattern & (1 << 3)) ? onpen : offpen);
+
+ // left-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 4)) ? onpen : offpen);
+
+ // left-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 5)) ? onpen : offpen);
+
+ // horizontal-middle-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 6)) ? onpen : offpen);
+
+ // horizontal-middle-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 7)) ? onpen : offpen);
+
+ // vertical-middle-top bar
+ draw_segment_vertical_caps(tempbitmap,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 8)) ? onpen : offpen);
+
+ // vertical-middle-bottom bar
+ draw_segment_vertical_caps(tempbitmap,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 9)) ? onpen : offpen);
+
+ // diagonal-left-bottom bar
+ draw_segment_diagonal_1(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 10)) ? onpen : offpen);
+
+ // diagonal-left-top bar
+ draw_segment_diagonal_2(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 11)) ? onpen : offpen);
+
+ // diagonal-right-top bar
+ draw_segment_diagonal_1(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 12)) ? onpen : offpen);
+
+ // diagonal-right-bottom bar
+ draw_segment_diagonal_2(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 13)) ? onpen : offpen);
+
+ // apply skew
+ apply_skew(tempbitmap, 40);
+
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1572,107 +1572,107 @@ void layout_element::component::draw_led14seg(bitmap_argb32 &dest, const rectang
void layout_element::component::draw_led14segsc(bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
- const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
-
- // sizes for computation
- int bmwidth = 250;
- int bmheight = 400;
- int segwidth = 40;
- int skewwidth = 40;
-
- // allocate a temporary bitmap for drawing, adding some extra space for the tail
- bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight + segwidth);
- tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
-
- // top bar
- draw_segment_horizontal(tempbitmap,
- 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 0)) ? onpen : offpen);
-
- // right-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 1)) ? onpen : offpen);
-
- // right-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 2)) ? onpen : offpen);
-
- // bottom bar
- draw_segment_horizontal(tempbitmap,
- 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
- segwidth, (pattern & (1 << 3)) ? onpen : offpen);
-
- // left-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 4)) ? onpen : offpen);
-
- // left-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 5)) ? onpen : offpen);
-
- // horizontal-middle-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 6)) ? onpen : offpen);
-
- // horizontal-middle-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 7)) ? onpen : offpen);
-
- // vertical-middle-top bar
- draw_segment_vertical_caps(tempbitmap,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 8)) ? onpen : offpen);
-
- // vertical-middle-bottom bar
- draw_segment_vertical_caps(tempbitmap,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 9)) ? onpen : offpen);
-
- // diagonal-left-bottom bar
- draw_segment_diagonal_1(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 10)) ? onpen : offpen);
-
- // diagonal-left-top bar
- draw_segment_diagonal_2(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 11)) ? onpen : offpen);
-
- // diagonal-right-top bar
- draw_segment_diagonal_1(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 12)) ? onpen : offpen);
-
- // diagonal-right-bottom bar
- draw_segment_diagonal_2(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 13)) ? onpen : offpen);
-
- // apply skew
- apply_skew(tempbitmap, 40);
-
- // comma tail
- draw_segment_diagonal_1(tempbitmap,
- bmwidth - (segwidth/2), bmwidth + segwidth,
- bmheight - (segwidth), bmheight + segwidth*1.5,
- segwidth/2, (pattern & (1 << 15)) ? onpen : offpen);
-
- // decimal point
- draw_segment_decimal(tempbitmap, bmwidth + segwidth/2, bmheight - segwidth/2, segwidth, (pattern & (1 << 14)) ? onpen : offpen);
-
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
+ const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
+
+ // sizes for computation
+ int bmwidth = 250;
+ int bmheight = 400;
+ int segwidth = 40;
+ int skewwidth = 40;
+
+ // allocate a temporary bitmap for drawing, adding some extra space for the tail
+ bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight + segwidth);
+ tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
+
+ // top bar
+ draw_segment_horizontal(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 0)) ? onpen : offpen);
+
+ // right-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 1)) ? onpen : offpen);
+
+ // right-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 2)) ? onpen : offpen);
+
+ // bottom bar
+ draw_segment_horizontal(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
+ segwidth, (pattern & (1 << 3)) ? onpen : offpen);
+
+ // left-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 4)) ? onpen : offpen);
+
+ // left-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 5)) ? onpen : offpen);
+
+ // horizontal-middle-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 6)) ? onpen : offpen);
+
+ // horizontal-middle-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 7)) ? onpen : offpen);
+
+ // vertical-middle-top bar
+ draw_segment_vertical_caps(tempbitmap,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 8)) ? onpen : offpen);
+
+ // vertical-middle-bottom bar
+ draw_segment_vertical_caps(tempbitmap,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 9)) ? onpen : offpen);
+
+ // diagonal-left-bottom bar
+ draw_segment_diagonal_1(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 10)) ? onpen : offpen);
+
+ // diagonal-left-top bar
+ draw_segment_diagonal_2(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 11)) ? onpen : offpen);
+
+ // diagonal-right-top bar
+ draw_segment_diagonal_1(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 12)) ? onpen : offpen);
+
+ // diagonal-right-bottom bar
+ draw_segment_diagonal_2(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 13)) ? onpen : offpen);
+
+ // apply skew
+ apply_skew(tempbitmap, 40);
+
+ // comma tail
+ draw_segment_diagonal_1(tempbitmap,
+ bmwidth - (segwidth/2), bmwidth + segwidth,
+ bmheight - (segwidth), bmheight + segwidth*1.5,
+ segwidth/2, (pattern & (1 << 15)) ? onpen : offpen);
+
+ // decimal point
+ draw_segment_decimal(tempbitmap, bmwidth + segwidth/2, bmheight - segwidth/2, segwidth, (pattern & (1 << 14)) ? onpen : offpen);
+
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1682,108 +1682,108 @@ void layout_element::component::draw_led14segsc(bitmap_argb32 &dest, const recta
void layout_element::component::draw_led16seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
- const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
-
- // sizes for computation
- int bmwidth = 250;
- int bmheight = 400;
- int segwidth = 40;
- int skewwidth = 40;
-
- // allocate a temporary bitmap for drawing
- bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
- tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
-
- // top-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, 0 + segwidth/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 0)) ? onpen : offpen);
-
- // top-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, 0 + segwidth/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 1)) ? onpen : offpen);
-
- // right-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 2)) ? onpen : offpen);
-
- // right-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 3)) ? onpen : offpen);
-
- // bottom-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 4)) ? onpen : offpen);
-
- // bottom-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight - segwidth/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 5)) ? onpen : offpen);
-
- // left-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 6)) ? onpen : offpen);
-
- // left-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 7)) ? onpen : offpen);
-
- // horizontal-middle-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 8)) ? onpen : offpen);
-
- // horizontal-middle-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 9)) ? onpen : offpen);
-
- // vertical-middle-top bar
- draw_segment_vertical_caps(tempbitmap,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 10)) ? onpen : offpen);
-
- // vertical-middle-bottom bar
- draw_segment_vertical_caps(tempbitmap,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 11)) ? onpen : offpen);
-
- // diagonal-left-bottom bar
- draw_segment_diagonal_1(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 12)) ? onpen : offpen);
-
- // diagonal-left-top bar
- draw_segment_diagonal_2(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 13)) ? onpen : offpen);
-
- // diagonal-right-top bar
- draw_segment_diagonal_1(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 14)) ? onpen : offpen);
-
- // diagonal-right-bottom bar
- draw_segment_diagonal_2(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 15)) ? onpen : offpen);
-
- // apply skew
- apply_skew(tempbitmap, 40);
-
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
+ const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
+
+ // sizes for computation
+ int bmwidth = 250;
+ int bmheight = 400;
+ int segwidth = 40;
+ int skewwidth = 40;
+
+ // allocate a temporary bitmap for drawing
+ bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight);
+ tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
+
+ // top-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, 0 + segwidth/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 0)) ? onpen : offpen);
+
+ // top-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 1)) ? onpen : offpen);
+
+ // right-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 2)) ? onpen : offpen);
+
+ // right-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 3)) ? onpen : offpen);
+
+ // bottom-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 4)) ? onpen : offpen);
+
+ // bottom-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight - segwidth/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 5)) ? onpen : offpen);
+
+ // left-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 6)) ? onpen : offpen);
+
+ // left-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 7)) ? onpen : offpen);
+
+ // horizontal-middle-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 8)) ? onpen : offpen);
+
+ // horizontal-middle-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 9)) ? onpen : offpen);
+
+ // vertical-middle-top bar
+ draw_segment_vertical_caps(tempbitmap,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 10)) ? onpen : offpen);
+
+ // vertical-middle-bottom bar
+ draw_segment_vertical_caps(tempbitmap,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 11)) ? onpen : offpen);
+
+ // diagonal-left-bottom bar
+ draw_segment_diagonal_1(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 12)) ? onpen : offpen);
+
+ // diagonal-left-top bar
+ draw_segment_diagonal_2(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 13)) ? onpen : offpen);
+
+ // diagonal-right-top bar
+ draw_segment_diagonal_1(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 14)) ? onpen : offpen);
+
+ // diagonal-right-bottom bar
+ draw_segment_diagonal_2(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 15)) ? onpen : offpen);
+
+ // apply skew
+ apply_skew(tempbitmap, 40);
+
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1794,117 +1794,117 @@ void layout_element::component::draw_led16seg(bitmap_argb32 &dest, const rectang
void layout_element::component::draw_led16segsc(bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
- const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
-
- // sizes for computation
- int bmwidth = 250;
- int bmheight = 400;
- int segwidth = 40;
- int skewwidth = 40;
-
- // allocate a temporary bitmap for drawing
- bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight + segwidth);
- tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
-
- // top-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, 0 + segwidth/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 0)) ? onpen : offpen);
-
- // top-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, 0 + segwidth/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 1)) ? onpen : offpen);
-
- // right-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 2)) ? onpen : offpen);
-
- // right-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
- segwidth, (pattern & (1 << 3)) ? onpen : offpen);
-
- // bottom-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 4)) ? onpen : offpen);
-
- // bottom-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight - segwidth/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 5)) ? onpen : offpen);
-
- // left-bottom bar
- draw_segment_vertical(tempbitmap,
- bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 6)) ? onpen : offpen);
-
- // left-top bar
- draw_segment_vertical(tempbitmap,
- 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
- segwidth, (pattern & (1 << 7)) ? onpen : offpen);
-
- // horizontal-middle-left bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
- segwidth, LINE_CAP_START, (pattern & (1 << 8)) ? onpen : offpen);
-
- // horizontal-middle-right bar
- draw_segment_horizontal_caps(tempbitmap,
- 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
- segwidth, LINE_CAP_END, (pattern & (1 << 9)) ? onpen : offpen);
-
- // vertical-middle-top bar
- draw_segment_vertical_caps(tempbitmap,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 10)) ? onpen : offpen);
-
- // vertical-middle-bottom bar
- draw_segment_vertical_caps(tempbitmap,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
- segwidth, LINE_CAP_NONE, (pattern & (1 << 11)) ? onpen : offpen);
-
- // diagonal-left-bottom bar
- draw_segment_diagonal_1(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 12)) ? onpen : offpen);
-
- // diagonal-left-top bar
- draw_segment_diagonal_2(tempbitmap,
- 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 13)) ? onpen : offpen);
-
- // diagonal-right-top bar
- draw_segment_diagonal_1(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
- segwidth, (pattern & (1 << 14)) ? onpen : offpen);
-
- // diagonal-right-bottom bar
- draw_segment_diagonal_2(tempbitmap,
- bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
- bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
- segwidth, (pattern & (1 << 15)) ? onpen : offpen);
-
- // comma tail
- draw_segment_diagonal_1(tempbitmap,
- bmwidth - (segwidth/2), bmwidth + segwidth,
- bmheight - (segwidth), bmheight + segwidth*1.5,
- segwidth/2, (pattern & (1 << 17)) ? onpen : offpen);
-
- // decimal point (draw last for priority)
- draw_segment_decimal(tempbitmap, bmwidth + segwidth/2, bmheight - segwidth/2, segwidth, (pattern & (1 << 16)) ? onpen : offpen);
-
- // apply skew
- apply_skew(tempbitmap, 40);
-
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
+ const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
+
+ // sizes for computation
+ int bmwidth = 250;
+ int bmheight = 400;
+ int segwidth = 40;
+ int skewwidth = 40;
+
+ // allocate a temporary bitmap for drawing
+ bitmap_argb32 tempbitmap(bmwidth + skewwidth, bmheight + segwidth);
+ tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
+
+ // top-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, 0 + segwidth/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 0)) ? onpen : offpen);
+
+ // top-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 1)) ? onpen : offpen);
+
+ // right-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 2)) ? onpen : offpen);
+
+ // right-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, bmwidth - segwidth/2,
+ segwidth, (pattern & (1 << 3)) ? onpen : offpen);
+
+ // bottom-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight - segwidth/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 4)) ? onpen : offpen);
+
+ // bottom-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight - segwidth/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 5)) ? onpen : offpen);
+
+ // left-bottom bar
+ draw_segment_vertical(tempbitmap,
+ bmheight/2 + segwidth/3, bmheight - 2*segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 6)) ? onpen : offpen);
+
+ // left-top bar
+ draw_segment_vertical(tempbitmap,
+ 0 + 2*segwidth/3, bmheight/2 - segwidth/3, 0 + segwidth/2,
+ segwidth, (pattern & (1 << 7)) ? onpen : offpen);
+
+ // horizontal-middle-left bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + 2*segwidth/3, bmwidth/2 - segwidth/10, bmheight/2,
+ segwidth, LINE_CAP_START, (pattern & (1 << 8)) ? onpen : offpen);
+
+ // horizontal-middle-right bar
+ draw_segment_horizontal_caps(tempbitmap,
+ 0 + bmwidth/2 + segwidth/10, bmwidth - 2*segwidth/3, bmheight/2,
+ segwidth, LINE_CAP_END, (pattern & (1 << 9)) ? onpen : offpen);
+
+ // vertical-middle-top bar
+ draw_segment_vertical_caps(tempbitmap,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 10)) ? onpen : offpen);
+
+ // vertical-middle-bottom bar
+ draw_segment_vertical_caps(tempbitmap,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3, bmwidth/2,
+ segwidth, LINE_CAP_NONE, (pattern & (1 << 11)) ? onpen : offpen);
+
+ // diagonal-left-bottom bar
+ draw_segment_diagonal_1(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 12)) ? onpen : offpen);
+
+ // diagonal-left-top bar
+ draw_segment_diagonal_2(tempbitmap,
+ 0 + segwidth + segwidth/5, bmwidth/2 - segwidth/2 - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 13)) ? onpen : offpen);
+
+ // diagonal-right-top bar
+ draw_segment_diagonal_1(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ 0 + segwidth + segwidth/3, bmheight/2 - segwidth/2 - segwidth/3,
+ segwidth, (pattern & (1 << 14)) ? onpen : offpen);
+
+ // diagonal-right-bottom bar
+ draw_segment_diagonal_2(tempbitmap,
+ bmwidth/2 + segwidth/2 + segwidth/5, bmwidth - segwidth - segwidth/5,
+ bmheight/2 + segwidth/2 + segwidth/3, bmheight - segwidth - segwidth/3,
+ segwidth, (pattern & (1 << 15)) ? onpen : offpen);
+
+ // comma tail
+ draw_segment_diagonal_1(tempbitmap,
+ bmwidth - (segwidth/2), bmwidth + segwidth,
+ bmheight - (segwidth), bmheight + segwidth*1.5,
+ segwidth/2, (pattern & (1 << 17)) ? onpen : offpen);
+
+ // decimal point (draw last for priority)
+ draw_segment_decimal(tempbitmap, bmwidth + segwidth/2, bmheight - segwidth/2, segwidth, (pattern & (1 << 16)) ? onpen : offpen);
+
+ // apply skew
+ apply_skew(tempbitmap, 40);
+
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1915,22 +1915,22 @@ void layout_element::component::draw_led16segsc(bitmap_argb32 &dest, const recta
void layout_element::component::draw_dotmatrix(int dots, bitmap_argb32 &dest, const rectangle &bounds, int pattern)
{
- const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
- const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
+ const rgb_t onpen = rgb_t(0xff, 0xff, 0xff, 0xff);
+ const rgb_t offpen = rgb_t(0xff, 0x20, 0x20, 0x20);
- // sizes for computation
- int bmheight = 300;
- int dotwidth = 250;
+ // sizes for computation
+ int bmheight = 300;
+ int dotwidth = 250;
- // allocate a temporary bitmap for drawing
- bitmap_argb32 tempbitmap(dotwidth*dots, bmheight);
- tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
+ // allocate a temporary bitmap for drawing
+ bitmap_argb32 tempbitmap(dotwidth*dots, bmheight);
+ tempbitmap.fill(rgb_t(0xff, 0x00, 0x00, 0x00));
- for (int i = 0; i < dots; i++)
- draw_segment_decimal(tempbitmap, ((dotwidth/2 )+ (i * dotwidth)), bmheight/2, dotwidth, (pattern & (1 << i))?onpen:offpen);
+ for (int i = 0; i < dots; i++)
+ draw_segment_decimal(tempbitmap, ((dotwidth/2 )+ (i * dotwidth)), bmheight/2, dotwidth, (pattern & (1 << i))?onpen:offpen);
- // resample to the target size
- render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
+ // resample to the target size
+ render_resample_argb_bitmap_hq(dest, tempbitmap, m_color);
}
@@ -1942,17 +1942,17 @@ void layout_element::component::draw_dotmatrix(int dots, bitmap_argb32 &dest, co
void layout_element::component::draw_segment_horizontal_caps(bitmap_argb32 &dest, int minx, int maxx, int midy, int width, int caps, rgb_t color)
{
- // loop over the width of the segment
- for (int y = 0; y < width / 2; y++)
- {
- UINT32 *d0 = &dest.pix32(midy - y);
- UINT32 *d1 = &dest.pix32(midy + y);
- int ty = (y < width / 8) ? width / 8 : y;
-
- // loop over the length of the segment
- for (int x = minx + ((caps & LINE_CAP_START) ? ty : 0); x < maxx - ((caps & LINE_CAP_END) ? ty : 0); x++)
- d0[x] = d1[x] = color;
- }
+ // loop over the width of the segment
+ for (int y = 0; y < width / 2; y++)
+ {
+ UINT32 *d0 = &dest.pix32(midy - y);
+ UINT32 *d1 = &dest.pix32(midy + y);
+ int ty = (y < width / 8) ? width / 8 : y;
+
+ // loop over the length of the segment
+ for (int x = minx + ((caps & LINE_CAP_START) ? ty : 0); x < maxx - ((caps & LINE_CAP_END) ? ty : 0); x++)
+ d0[x] = d1[x] = color;
+ }
}
@@ -1963,7 +1963,7 @@ void layout_element::component::draw_segment_horizontal_caps(bitmap_argb32 &dest
void layout_element::component::draw_segment_horizontal(bitmap_argb32 &dest, int minx, int maxx, int midy, int width, rgb_t color)
{
- draw_segment_horizontal_caps(dest, minx, maxx, midy, width, LINE_CAP_START | LINE_CAP_END, color);
+ draw_segment_horizontal_caps(dest, minx, maxx, midy, width, LINE_CAP_START | LINE_CAP_END, color);
}
@@ -1975,17 +1975,17 @@ void layout_element::component::draw_segment_horizontal(bitmap_argb32 &dest, int
void layout_element::component::draw_segment_vertical_caps(bitmap_argb32 &dest, int miny, int maxy, int midx, int width, int caps, rgb_t color)
{
- // loop over the width of the segment
- for (int x = 0; x < width / 2; x++)
- {
- UINT32 *d0 = &dest.pix32(0, midx - x);
- UINT32 *d1 = &dest.pix32(0, midx + x);
- int tx = (x < width / 8) ? width / 8 : x;
-
- // loop over the length of the segment
- for (int y = miny + ((caps & LINE_CAP_START) ? tx : 0); y < maxy - ((caps & LINE_CAP_END) ? tx : 0); y++)
- d0[y * dest.rowpixels()] = d1[y * dest.rowpixels()] = color;
- }
+ // loop over the width of the segment
+ for (int x = 0; x < width / 2; x++)
+ {
+ UINT32 *d0 = &dest.pix32(0, midx - x);
+ UINT32 *d1 = &dest.pix32(0, midx + x);
+ int tx = (x < width / 8) ? width / 8 : x;
+
+ // loop over the length of the segment
+ for (int y = miny + ((caps & LINE_CAP_START) ? tx : 0); y < maxy - ((caps & LINE_CAP_END) ? tx : 0); y++)
+ d0[y * dest.rowpixels()] = d1[y * dest.rowpixels()] = color;
+ }
}
@@ -1996,7 +1996,7 @@ void layout_element::component::draw_segment_vertical_caps(bitmap_argb32 &dest,
void layout_element::component::draw_segment_vertical(bitmap_argb32 &dest, int miny, int maxy, int midx, int width, rgb_t color)
{
- draw_segment_vertical_caps(dest, miny, maxy, midx, width, LINE_CAP_START | LINE_CAP_END, color);
+ draw_segment_vertical_caps(dest, miny, maxy, midx, width, LINE_CAP_START | LINE_CAP_END, color);
}
@@ -2007,21 +2007,21 @@ void layout_element::component::draw_segment_vertical(bitmap_argb32 &dest, int m
void layout_element::component::draw_segment_diagonal_1(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color)
{
- // compute parameters
- width *= 1.5;
- float ratio = (maxy - miny - width) / (float)(maxx - minx);
-
- // draw line
- for (int x = minx; x < maxx; x++)
- if (x >= 0 && x < dest.width())
- {
- UINT32 *d = &dest.pix32(0, x);
- int step = (x - minx) * ratio;
-
- for (int y = maxy - width - step; y < maxy - step; y++)
- if (y >= 0 && y < dest.height())
- d[y * dest.rowpixels()] = color;
- }
+ // compute parameters
+ width *= 1.5;
+ float ratio = (maxy - miny - width) / (float)(maxx - minx);
+
+ // draw line
+ for (int x = minx; x < maxx; x++)
+ if (x >= 0 && x < dest.width())
+ {
+ UINT32 *d = &dest.pix32(0, x);
+ int step = (x - minx) * ratio;
+
+ for (int y = maxy - width - step; y < maxy - step; y++)
+ if (y >= 0 && y < dest.height())
+ d[y * dest.rowpixels()] = color;
+ }
}
@@ -2032,21 +2032,21 @@ void layout_element::component::draw_segment_diagonal_1(bitmap_argb32 &dest, int
void layout_element::component::draw_segment_diagonal_2(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color)
{
- // compute parameters
- width *= 1.5;
- float ratio = (maxy - miny - width) / (float)(maxx - minx);
-
- // draw line
- for (int x = minx; x < maxx; x++)
- if (x >= 0 && x < dest.width())
- {
- UINT32 *d = &dest.pix32(0, x);
- int step = (x - minx) * ratio;
-
- for (int y = miny + step; y < miny + step + width; y++)
- if (y >= 0 && y < dest.height())
- d[y * dest.rowpixels()] = color;
- }
+ // compute parameters
+ width *= 1.5;
+ float ratio = (maxy - miny - width) / (float)(maxx - minx);
+
+ // draw line
+ for (int x = minx; x < maxx; x++)
+ if (x >= 0 && x < dest.width())
+ {
+ UINT32 *d = &dest.pix32(0, x);
+ int step = (x - minx) * ratio;
+
+ for (int y = miny + step; y < miny + step + width; y++)
+ if (y >= 0 && y < dest.height())
+ d[y * dest.rowpixels()] = color;
+ }
}
@@ -2056,26 +2056,26 @@ void layout_element::component::draw_segment_diagonal_2(bitmap_argb32 &dest, int
void layout_element::component::draw_segment_decimal(bitmap_argb32 &dest, int midx, int midy, int width, rgb_t color)
{
- // compute parameters
- width /= 2;
- float ooradius2 = 1.0f / (float)(width * width);
-
- // iterate over y
- for (UINT32 y = 0; y <= width; y++)
- {
- UINT32 *d0 = &dest.pix32(midy - y);
- UINT32 *d1 = &dest.pix32(midy + y);
- float xval = width * sqrt(1.0f - (float)(y * y) * ooradius2);
- INT32 left, right;
-
- // compute left/right coordinates
- left = midx - (INT32)(xval + 0.5f);
- right = midx + (INT32)(xval + 0.5f);
-
- // draw this scanline
- for (UINT32 x = left; x < right; x++)
- d0[x] = d1[x] = color;
- }
+ // compute parameters
+ width /= 2;
+ float ooradius2 = 1.0f / (float)(width * width);
+
+ // iterate over y
+ for (UINT32 y = 0; y <= width; y++)
+ {
+ UINT32 *d0 = &dest.pix32(midy - y);
+ UINT32 *d1 = &dest.pix32(midy + y);
+ float xval = width * sqrt(1.0f - (float)(y * y) * ooradius2);
+ INT32 left, right;
+
+ // compute left/right coordinates
+ left = midx - (INT32)(xval + 0.5f);
+ right = midx + (INT32)(xval + 0.5f);
+
+ // draw this scanline
+ for (UINT32 x = left; x < right; x++)
+ d0[x] = d1[x] = color;
+ }
}
@@ -2085,19 +2085,19 @@ void layout_element::component::draw_segment_decimal(bitmap_argb32 &dest, int mi
void layout_element::component::draw_segment_comma(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color)
{
- // compute parameters
- width *= 1.5;
- float ratio = (maxy - miny - width) / (float)(maxx - minx);
-
- // draw line
- for (int x = minx; x < maxx; x++)
- {
- UINT32 *d = &dest.pix32(0, x);
- int step = (x - minx) * ratio;
-
- for (int y = maxy; y < maxy - width - step; y--)
- d[y * dest.rowpixels()] = color;
- }
+ // compute parameters
+ width *= 1.5;
+ float ratio = (maxy - miny - width) / (float)(maxx - minx);
+
+ // draw line
+ for (int x = minx; x < maxx; x++)
+ {
+ UINT32 *d = &dest.pix32(0, x);
+ int step = (x - minx) * ratio;
+
+ for (int y = maxy; y < maxy - width - step; y--)
+ d[y * dest.rowpixels()] = color;
+ }
}
@@ -2107,15 +2107,15 @@ void layout_element::component::draw_segment_comma(bitmap_argb32 &dest, int minx
void layout_element::component::apply_skew(bitmap_argb32 &dest, int skewwidth)
{
- for (int y = 0; y < dest.height(); y++)
- {
- UINT32 *destrow = &dest.pix32(y);
- int offs = skewwidth * (dest.height() - y) / dest.height();
- for (int x = dest.width() - skewwidth - 1; x >= 0; x--)
- destrow[x + offs] = destrow[x];
- for (int x = 0; x < offs; x++)
- destrow[x] = 0;
- }
+ for (int y = 0; y < dest.height(); y++)
+ {
+ UINT32 *destrow = &dest.pix32(y);
+ int offs = skewwidth * (dest.height() - y) / dest.height();
+ for (int x = dest.width() - skewwidth - 1; x >= 0; x--)
+ destrow[x + offs] = destrow[x];
+ for (int x = 0; x < offs; x++)
+ destrow[x] = 0;
+ }
}
@@ -2129,45 +2129,45 @@ void layout_element::component::apply_skew(bitmap_argb32 &dest, int skewwidth)
//-------------------------------------------------
layout_view::layout_view(running_machine &machine, xml_data_node &viewnode, simple_list<layout_element> &elemlist)
- : m_next(NULL),
- m_aspect(1.0f),
- m_scraspect(1.0f)
+ : m_next(NULL),
+ m_aspect(1.0f),
+ m_scraspect(1.0f)
{
- // allocate a copy of the name
- m_name = xml_get_attribute_string_with_subst(machine, viewnode, "name", "");
+ // allocate a copy of the name
+ m_name = xml_get_attribute_string_with_subst(machine, viewnode, "name", "");
- // if we have a bounds item, load it
- xml_data_node *boundsnode = xml_get_sibling(viewnode.child, "bounds");
- m_expbounds.x0 = m_expbounds.y0 = m_expbounds.x1 = m_expbounds.y1 = 0;
- if (boundsnode != NULL)
- parse_bounds(machine, xml_get_sibling(boundsnode, "bounds"), m_expbounds);
+ // if we have a bounds item, load it
+ xml_data_node *boundsnode = xml_get_sibling(viewnode.child, "bounds");
+ m_expbounds.x0 = m_expbounds.y0 = m_expbounds.x1 = m_expbounds.y1 = 0;
+ if (boundsnode != NULL)
+ parse_bounds(machine, xml_get_sibling(boundsnode, "bounds"), m_expbounds);
- // load backdrop items
- for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "backdrop"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "backdrop"))
- m_backdrop_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
+ // load backdrop items
+ for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "backdrop"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "backdrop"))
+ m_backdrop_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
- // load screen items
- for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "screen"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "screen"))
- m_screen_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
+ // load screen items
+ for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "screen"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "screen"))
+ m_screen_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
- // load overlay items
- for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "overlay"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "overlay"))
- m_overlay_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
+ // load overlay items
+ for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "overlay"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "overlay"))
+ m_overlay_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
- // load bezel items
- for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "bezel"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "bezel"))
- m_bezel_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
+ // load bezel items
+ for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "bezel"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "bezel"))
+ m_bezel_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
- // load cpanel items
- for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "cpanel"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "cpanel"))
- m_cpanel_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
+ // load cpanel items
+ for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "cpanel"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "cpanel"))
+ m_cpanel_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
- // load marquee items
- for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "marquee"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "marquee"))
- m_marquee_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
+ // load marquee items
+ for (xml_data_node *itemnode = xml_get_sibling(viewnode.child, "marquee"); itemnode != NULL; itemnode = xml_get_sibling(itemnode->next, "marquee"))
+ m_marquee_list.append(*global_alloc(item(machine, *itemnode, elemlist)));
- // recompute the data for the view based on a default layer config
- recompute(render_layer_config());
+ // recompute the data for the view based on a default layer config
+ recompute(render_layer_config());
}
@@ -2187,16 +2187,16 @@ layout_view::~layout_view()
layout_view::item *layout_view::first_item(item_layer layer) const
{
- switch (layer)
- {
- case ITEM_LAYER_BACKDROP: return m_backdrop_list.first();
- case ITEM_LAYER_SCREEN: return m_screen_list.first();
- case ITEM_LAYER_OVERLAY: return m_overlay_list.first();
- case ITEM_LAYER_BEZEL: return m_bezel_list.first();
- case ITEM_LAYER_CPANEL: return m_cpanel_list.first();
- case ITEM_LAYER_MARQUEE: return m_marquee_list.first();
- default: return NULL;
- }
+ switch (layer)
+ {
+ case ITEM_LAYER_BACKDROP: return m_backdrop_list.first();
+ case ITEM_LAYER_SCREEN: return m_screen_list.first();
+ case ITEM_LAYER_OVERLAY: return m_overlay_list.first();
+ case ITEM_LAYER_BEZEL: return m_bezel_list.first();
+ case ITEM_LAYER_CPANEL: return m_cpanel_list.first();
+ case ITEM_LAYER_MARQUEE: return m_marquee_list.first();
+ default: return NULL;
+ }
}
@@ -2207,97 +2207,97 @@ layout_view::item *layout_view::first_item(item_layer layer) const
void layout_view::recompute(render_layer_config layerconfig)
{
- // reset the bounds
- m_bounds.x0 = m_bounds.y0 = m_bounds.x1 = m_bounds.y1 = 0.0f;
- m_scrbounds.x0 = m_scrbounds.y0 = m_scrbounds.x1 = m_scrbounds.y1 = 0.0f;
- m_screens.reset();
-
- // loop over all layers
- bool first = true;
- bool scrfirst = true;
- for (item_layer layer = ITEM_LAYER_FIRST; layer < ITEM_LAYER_MAX; layer++)
- {
- // determine if this layer should be visible
- switch (layer)
- {
- case ITEM_LAYER_BACKDROP: m_layenabled[layer] = layerconfig.backdrops_enabled(); break;
- case ITEM_LAYER_OVERLAY: m_layenabled[layer] = layerconfig.overlays_enabled(); break;
- case ITEM_LAYER_BEZEL: m_layenabled[layer] = layerconfig.bezels_enabled(); break;
- case ITEM_LAYER_CPANEL: m_layenabled[layer] = layerconfig.cpanels_enabled(); break;
- case ITEM_LAYER_MARQUEE: m_layenabled[layer] = layerconfig.marquees_enabled(); break;
- default: m_layenabled[layer] = true; break;
- }
-
- // only do it if requested
- if (m_layenabled[layer])
- for (item *curitem = first_item(layer); curitem != NULL; curitem = curitem->next())
- {
- // accumulate bounds
- if (first)
- m_bounds = curitem->m_rawbounds;
- else
- union_render_bounds(&m_bounds, &curitem->m_rawbounds);
- first = false;
-
- // accumulate screen bounds
- if (curitem->m_screen != NULL)
- {
- if (scrfirst)
- m_scrbounds = curitem->m_rawbounds;
- else
- union_render_bounds(&m_scrbounds, &curitem->m_rawbounds);
- scrfirst = false;
-
- // accumulate the screens in use while we're scanning
- m_screens.add(*curitem->m_screen);
- }
- }
- }
-
- // if we have an explicit bounds, override it
- if (m_expbounds.x1 > m_expbounds.x0)
- m_bounds = m_expbounds;
-
- // if we're handling things normally, the target bounds are (0,0)-(1,1)
- render_bounds target_bounds;
- if (!layerconfig.zoom_to_screen() || m_screens.count() == 0)
- {
- // compute the aspect ratio of the view
- m_aspect = (m_bounds.x1 - m_bounds.x0) / (m_bounds.y1 - m_bounds.y0);
-
- target_bounds.x0 = target_bounds.y0 = 0.0f;
- target_bounds.x1 = target_bounds.y1 = 1.0f;
- }
-
- // if we're cropping, we want the screen area to fill (0,0)-(1,1)
- else
- {
- // compute the aspect ratio of the screen
- m_scraspect = (m_scrbounds.x1 - m_scrbounds.x0) / (m_scrbounds.y1 - m_scrbounds.y0);
-
- float targwidth = (m_bounds.x1 - m_bounds.x0) / (m_scrbounds.x1 - m_scrbounds.x0);
- float targheight = (m_bounds.y1 - m_bounds.y0) / (m_scrbounds.y1 - m_scrbounds.y0);
- target_bounds.x0 = (m_bounds.x0 - m_scrbounds.x0) / (m_bounds.x1 - m_bounds.x0) * targwidth;
- target_bounds.y0 = (m_bounds.y0 - m_scrbounds.y0) / (m_bounds.y1 - m_bounds.y0) * targheight;
- target_bounds.x1 = target_bounds.x0 + targwidth;
- target_bounds.y1 = target_bounds.y0 + targheight;
- }
-
- // determine the scale/offset for normalization
- float xoffs = m_bounds.x0;
- float yoffs = m_bounds.y0;
- float xscale = (target_bounds.x1 - target_bounds.x0) / (m_bounds.x1 - m_bounds.x0);
- float yscale = (target_bounds.y1 - target_bounds.y0) / (m_bounds.y1 - m_bounds.y0);
-
- // normalize all the item bounds
- for (item_layer layer = ITEM_LAYER_FIRST; layer < ITEM_LAYER_MAX; layer++)
- for (item *curitem = first_item(layer); curitem != NULL; curitem = curitem->next())
- {
- curitem->m_bounds.x0 = target_bounds.x0 + (curitem->m_rawbounds.x0 - xoffs) * xscale;
- curitem->m_bounds.x1 = target_bounds.x0 + (curitem->m_rawbounds.x1 - xoffs) * xscale;
- curitem->m_bounds.y0 = target_bounds.y0 + (curitem->m_rawbounds.y0 - yoffs) * yscale;
- curitem->m_bounds.y1 = target_bounds.y0 + (curitem->m_rawbounds.y1 - yoffs) * yscale;
- }
+ // reset the bounds
+ m_bounds.x0 = m_bounds.y0 = m_bounds.x1 = m_bounds.y1 = 0.0f;
+ m_scrbounds.x0 = m_scrbounds.y0 = m_scrbounds.x1 = m_scrbounds.y1 = 0.0f;
+ m_screens.reset();
+
+ // loop over all layers
+ bool first = true;
+ bool scrfirst = true;
+ for (item_layer layer = ITEM_LAYER_FIRST; layer < ITEM_LAYER_MAX; layer++)
+ {
+ // determine if this layer should be visible
+ switch (layer)
+ {
+ case ITEM_LAYER_BACKDROP: m_layenabled[layer] = layerconfig.backdrops_enabled(); break;
+ case ITEM_LAYER_OVERLAY: m_layenabled[layer] = layerconfig.overlays_enabled(); break;
+ case ITEM_LAYER_BEZEL: m_layenabled[layer] = layerconfig.bezels_enabled(); break;
+ case ITEM_LAYER_CPANEL: m_layenabled[layer] = layerconfig.cpanels_enabled(); break;
+ case ITEM_LAYER_MARQUEE: m_layenabled[layer] = layerconfig.marquees_enabled(); break;
+ default: m_layenabled[layer] = true; break;
+ }
+
+ // only do it if requested
+ if (m_layenabled[layer])
+ for (item *curitem = first_item(layer); curitem != NULL; curitem = curitem->next())
+ {
+ // accumulate bounds
+ if (first)
+ m_bounds = curitem->m_rawbounds;
+ else
+ union_render_bounds(&m_bounds, &curitem->m_rawbounds);
+ first = false;
+
+ // accumulate screen bounds
+ if (curitem->m_screen != NULL)
+ {
+ if (scrfirst)
+ m_scrbounds = curitem->m_rawbounds;
+ else
+ union_render_bounds(&m_scrbounds, &curitem->m_rawbounds);
+ scrfirst = false;
+
+ // accumulate the screens in use while we're scanning
+ m_screens.add(*curitem->m_screen);
+ }
+ }
+ }
+
+ // if we have an explicit bounds, override it
+ if (m_expbounds.x1 > m_expbounds.x0)
+ m_bounds = m_expbounds;
+
+ // if we're handling things normally, the target bounds are (0,0)-(1,1)
+ render_bounds target_bounds;
+ if (!layerconfig.zoom_to_screen() || m_screens.count() == 0)
+ {
+ // compute the aspect ratio of the view
+ m_aspect = (m_bounds.x1 - m_bounds.x0) / (m_bounds.y1 - m_bounds.y0);
+
+ target_bounds.x0 = target_bounds.y0 = 0.0f;
+ target_bounds.x1 = target_bounds.y1 = 1.0f;
+ }
+
+ // if we're cropping, we want the screen area to fill (0,0)-(1,1)
+ else
+ {
+ // compute the aspect ratio of the screen
+ m_scraspect = (m_scrbounds.x1 - m_scrbounds.x0) / (m_scrbounds.y1 - m_scrbounds.y0);
+
+ float targwidth = (m_bounds.x1 - m_bounds.x0) / (m_scrbounds.x1 - m_scrbounds.x0);
+ float targheight = (m_bounds.y1 - m_bounds.y0) / (m_scrbounds.y1 - m_scrbounds.y0);
+ target_bounds.x0 = (m_bounds.x0 - m_scrbounds.x0) / (m_bounds.x1 - m_bounds.x0) * targwidth;
+ target_bounds.y0 = (m_bounds.y0 - m_scrbounds.y0) / (m_bounds.y1 - m_bounds.y0) * targheight;
+ target_bounds.x1 = target_bounds.x0 + targwidth;
+ target_bounds.y1 = target_bounds.y0 + targheight;
+ }
+
+ // determine the scale/offset for normalization
+ float xoffs = m_bounds.x0;
+ float yoffs = m_bounds.y0;
+ float xscale = (target_bounds.x1 - target_bounds.x0) / (m_bounds.x1 - m_bounds.x0);
+ float yscale = (target_bounds.y1 - target_bounds.y0) / (m_bounds.y1 - m_bounds.y0);
+
+ // normalize all the item bounds
+ for (item_layer layer = ITEM_LAYER_FIRST; layer < ITEM_LAYER_MAX; layer++)
+ for (item *curitem = first_item(layer); curitem != NULL; curitem = curitem->next())
+ {
+ curitem->m_bounds.x0 = target_bounds.x0 + (curitem->m_rawbounds.x0 - xoffs) * xscale;
+ curitem->m_bounds.x1 = target_bounds.x0 + (curitem->m_rawbounds.x1 - xoffs) * xscale;
+ curitem->m_bounds.y0 = target_bounds.y0 + (curitem->m_rawbounds.y0 - yoffs) * yscale;
+ curitem->m_bounds.y1 = target_bounds.y0 + (curitem->m_rawbounds.y1 - yoffs) * yscale;
+ }
}
@@ -2311,57 +2311,57 @@ void layout_view::recompute(render_layer_config layerconfig)
//-------------------------------------------------
layout_view::item::item(running_machine &machine, xml_data_node &itemnode, simple_list<layout_element> &elemlist)
- : m_next(NULL),
- m_element(NULL),
- m_input_mask(0),
- m_screen(NULL),
- m_orientation(ROT0)
+ : m_next(NULL),
+ m_element(NULL),
+ m_input_mask(0),
+ m_screen(NULL),
+ m_orientation(ROT0)
{
- // allocate a copy of the output name
- m_output_name = xml_get_attribute_string_with_subst(machine, itemnode, "name", "");
-
- // allocate a copy of the input tag
- m_input_tag = xml_get_attribute_string_with_subst(machine, itemnode, "inputtag", "");
-
- // find the associated element
- const char *name = xml_get_attribute_string_with_subst(machine, itemnode, "element", NULL);
- if (name != NULL)
- {
- // search the list of elements for a match
- for (m_element = elemlist.first(); m_element != NULL; m_element = m_element->next())
- if (strcmp(name, m_element->name()) == 0)
- break;
-
- // error if not found
- if (m_element == NULL)
- throw emu_fatalerror("Unable to find layout element %s", name);
- }
-
- // fetch common data
- int index = xml_get_attribute_int_with_subst(machine, itemnode, "index", -1);
- if (index != -1)
- {
- screen_device_iterator iter(machine.root_device());
- m_screen = iter.byindex(index);
- }
- m_input_mask = xml_get_attribute_int_with_subst(machine, itemnode, "inputmask", 0);
- if (m_output_name[0] != 0 && m_element != NULL)
- output_set_value(m_output_name, m_element->default_state());
- parse_bounds(machine, xml_get_sibling(itemnode.child, "bounds"), m_rawbounds);
- parse_color(machine, xml_get_sibling(itemnode.child, "color"), m_color);
- parse_orientation(machine, xml_get_sibling(itemnode.child, "orientation"), m_orientation);
-
- // sanity checks
- if (strcmp(itemnode.name, "screen") == 0)
- {
- if (m_screen == NULL)
- throw emu_fatalerror("Layout references invalid screen index %d", index);
- }
- else
- {
- if (m_element == NULL)
- throw emu_fatalerror("Layout item of type %s require an element tag", itemnode.name);
- }
+ // allocate a copy of the output name
+ m_output_name = xml_get_attribute_string_with_subst(machine, itemnode, "name", "");
+
+ // allocate a copy of the input tag
+ m_input_tag = xml_get_attribute_string_with_subst(machine, itemnode, "inputtag", "");
+
+ // find the associated element
+ const char *name = xml_get_attribute_string_with_subst(machine, itemnode, "element", NULL);
+ if (name != NULL)
+ {
+ // search the list of elements for a match
+ for (m_element = elemlist.first(); m_element != NULL; m_element = m_element->next())
+ if (strcmp(name, m_element->name()) == 0)
+ break;
+
+ // error if not found
+ if (m_element == NULL)
+ throw emu_fatalerror("Unable to find layout element %s", name);
+ }
+
+ // fetch common data
+ int index = xml_get_attribute_int_with_subst(machine, itemnode, "index", -1);
+ if (index != -1)
+ {
+ screen_device_iterator iter(machine.root_device());
+ m_screen = iter.byindex(index);
+ }
+ m_input_mask = xml_get_attribute_int_with_subst(machine, itemnode, "inputmask", 0);
+ if (m_output_name[0] != 0 && m_element != NULL)
+ output_set_value(m_output_name, m_element->default_state());
+ parse_bounds(machine, xml_get_sibling(itemnode.child, "bounds"), m_rawbounds);
+ parse_color(machine, xml_get_sibling(itemnode.child, "color"), m_color);
+ parse_orientation(machine, xml_get_sibling(itemnode.child, "orientation"), m_orientation);
+
+ // sanity checks
+ if (strcmp(itemnode.name, "screen") == 0)
+ {
+ if (m_screen == NULL)
+ throw emu_fatalerror("Layout references invalid screen index %d", index);
+ }
+ else
+ {
+ if (m_element == NULL)
+ throw emu_fatalerror("Layout item of type %s require an element tag", itemnode.name);
+ }
}
@@ -2381,7 +2381,7 @@ layout_view::item::~item()
render_container *layout_view::item::screen_container(running_machine &machine) const
{
- return (m_screen != NULL) ? &m_screen->container() : NULL;
+ return (m_screen != NULL) ? &m_screen->container() : NULL;
}
//-------------------------------------------------
@@ -2390,26 +2390,26 @@ render_container *layout_view::item::screen_container(running_machine &machine)
int layout_view::item::state() const
{
- int state = 0;
-
- assert(m_element != NULL);
-
- // if configured to an output, fetch the output value
- if (m_output_name[0] != 0)
- state = output_get_value(m_output_name);
-
- // if configured to an input, fetch the input value
- else if (m_input_tag[0] != 0)
- {
- ioport_port *port = m_element->machine().root_device().ioport(m_input_tag);
- if (port != NULL)
- {
- ioport_field *field = port->field(m_input_mask);
- if (field != NULL)
- state = ((port->read() ^ field->defvalue()) & m_input_mask) ? 1 : 0;
- }
- }
- return state;
+ int state = 0;
+
+ assert(m_element != NULL);
+
+ // if configured to an output, fetch the output value
+ if (m_output_name[0] != 0)
+ state = output_get_value(m_output_name);
+
+ // if configured to an input, fetch the input value
+ else if (m_input_tag[0] != 0)
+ {
+ ioport_port *port = m_element->machine().root_device().ioport(m_input_tag);
+ if (port != NULL)
+ {
+ ioport_field *field = port->field(m_input_mask);
+ if (field != NULL)
+ state = ((port->read() ^ field->defvalue()) & m_input_mask) ? 1 : 0;
+ }
+ }
+ return state;
}
@@ -2423,25 +2423,25 @@ int layout_view::item::state() const
//-------------------------------------------------
layout_file::layout_file(running_machine &machine, xml_data_node &rootnode, const char *dirname)
- : m_next(NULL)
+ : m_next(NULL)
{
- // find the layout node
- xml_data_node *mamelayoutnode = xml_get_sibling(rootnode.child, "mamelayout");
- if (mamelayoutnode == NULL)
- throw emu_fatalerror("Invalid XML file: missing mamelayout node");
-
- // validate the config data version
- int version = xml_get_attribute_int(mamelayoutnode, "version", 0);
- if (version != LAYOUT_VERSION)
- throw emu_fatalerror("Invalid XML file: unsupported version");
-
- // parse all the elements
- for (xml_data_node *elemnode = xml_get_sibling(mamelayoutnode->child, "element"); elemnode != NULL; elemnode = xml_get_sibling(elemnode->next, "element"))
- m_elemlist.append(*global_alloc(layout_element(machine, *elemnode, dirname)));
-
- // parse all the views
- for (xml_data_node *viewnode = xml_get_sibling(mamelayoutnode->child, "view"); viewnode != NULL; viewnode = xml_get_sibling(viewnode->next, "view"))
- m_viewlist.append(*global_alloc(layout_view(machine, *viewnode, m_elemlist)));
+ // find the layout node
+ xml_data_node *mamelayoutnode = xml_get_sibling(rootnode.child, "mamelayout");
+ if (mamelayoutnode == NULL)
+ throw emu_fatalerror("Invalid XML file: missing mamelayout node");
+
+ // validate the config data version
+ int version = xml_get_attribute_int(mamelayoutnode, "version", 0);
+ if (version != LAYOUT_VERSION)
+ throw emu_fatalerror("Invalid XML file: unsupported version");
+
+ // parse all the elements
+ for (xml_data_node *elemnode = xml_get_sibling(mamelayoutnode->child, "element"); elemnode != NULL; elemnode = xml_get_sibling(elemnode->next, "element"))
+ m_elemlist.append(*global_alloc(layout_element(machine, *elemnode, dirname)));
+
+ // parse all the views
+ for (xml_data_node *viewnode = xml_get_sibling(mamelayoutnode->child, "view"); viewnode != NULL; viewnode = xml_get_sibling(viewnode->next, "view"))
+ m_viewlist.append(*global_alloc(layout_view(machine, *viewnode, m_elemlist)));
}
diff --git a/src/emu/rendlay.h b/src/emu/rendlay.h
index b8c6c8cf41b..af2eff64e59 100644
--- a/src/emu/rendlay.h
+++ b/src/emu/rendlay.h
@@ -20,14 +20,14 @@
enum item_layer
{
- ITEM_LAYER_FIRST = 0,
- ITEM_LAYER_BACKDROP = ITEM_LAYER_FIRST,
- ITEM_LAYER_SCREEN,
- ITEM_LAYER_OVERLAY,
- ITEM_LAYER_BEZEL,
- ITEM_LAYER_CPANEL,
- ITEM_LAYER_MARQUEE,
- ITEM_LAYER_MAX
+ ITEM_LAYER_FIRST = 0,
+ ITEM_LAYER_BACKDROP = ITEM_LAYER_FIRST,
+ ITEM_LAYER_SCREEN,
+ ITEM_LAYER_OVERLAY,
+ ITEM_LAYER_BEZEL,
+ ITEM_LAYER_CPANEL,
+ ITEM_LAYER_MARQUEE,
+ ITEM_LAYER_MAX
};
DECLARE_ENUM_OPERATORS(item_layer);
@@ -43,140 +43,140 @@ DECLARE_ENUM_OPERATORS(item_layer);
// a layout_element is a single named element, which may have multiple components
class layout_element
{
- friend class simple_list<layout_element>;
+ friend class simple_list<layout_element>;
public:
- // construction/destruction
- layout_element(running_machine &machine, xml_data_node &elemnode, const char *dirname);
- virtual ~layout_element();
-
- // getters
- layout_element *next() const { return m_next; }
- const char *name() const { return m_name; }
- running_machine &machine() const { return m_machine; }
- int default_state() const { return m_defstate; }
- int maxstate() const { return m_maxstate; }
- render_texture *state_texture(int state);
+ // construction/destruction
+ layout_element(running_machine &machine, xml_data_node &elemnode, const char *dirname);
+ virtual ~layout_element();
+
+ // getters
+ layout_element *next() const { return m_next; }
+ const char *name() const { return m_name; }
+ running_machine &machine() const { return m_machine; }
+ int default_state() const { return m_defstate; }
+ int maxstate() const { return m_maxstate; }
+ render_texture *state_texture(int state);
private:
- // a component represents an image, rectangle, or disk in an element
- class component
- {
- friend class layout_element;
- friend class simple_list<component>;
-
- public:
- // construction/destruction
- component(running_machine &machine, xml_data_node &compnode, const char *dirname);
- ~component();
-
- // getters
- component *next() const { return m_next; }
- const render_bounds &bounds() const { return m_bounds; }
-
- // operations
- void draw(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
-
- private:
- // component types
- enum component_type
- {
- CTYPE_INVALID = 0,
- CTYPE_IMAGE,
- CTYPE_RECT,
- CTYPE_DISK,
- CTYPE_TEXT,
- CTYPE_LED7SEG,
- CTYPE_LED8SEG_GTS1,
- CTYPE_LED14SEG,
- CTYPE_LED16SEG,
- CTYPE_LED14SEGSC,
- CTYPE_LED16SEGSC,
- CTYPE_DOTMATRIX,
- CTYPE_DOTMATRIX5DOT,
- CTYPE_DOTMATRIXDOT,
- CTYPE_SIMPLECOUNTER,
- CTYPE_REEL,
- CTYPE_MAX
- };
-
- // helpers
- void draw_rect(bitmap_argb32 &dest, const rectangle &bounds);
- void draw_disk(bitmap_argb32 &dest, const rectangle &bounds);
- void draw_text(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds);
- void draw_simplecounter(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
- void draw_reel(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
- void draw_beltreel(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
- void load_bitmap();
- void load_reel_bitmap(int number);
- void draw_led7seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_led8seg_gts1(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_led14seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_led14segsc(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_led16seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_led16segsc(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_dotmatrix(int dots,bitmap_argb32 &dest, const rectangle &bounds, int pattern);
- void draw_segment_horizontal_caps(bitmap_argb32 &dest, int minx, int maxx, int midy, int width, int caps, rgb_t color);
- void draw_segment_horizontal(bitmap_argb32 &dest, int minx, int maxx, int midy, int width, rgb_t color);
- void draw_segment_vertical_caps(bitmap_argb32 &dest, int miny, int maxy, int midx, int width, int caps, rgb_t color);
- void draw_segment_vertical(bitmap_argb32 &dest, int miny, int maxy, int midx, int width, rgb_t color);
- void draw_segment_diagonal_1(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color);
- void draw_segment_diagonal_2(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color);
- void draw_segment_decimal(bitmap_argb32 &dest, int midx, int midy, int width, rgb_t color);
- void draw_segment_comma(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color);
- void apply_skew(bitmap_argb32 &dest, int skewwidth);
-
- #define MAX_BITMAPS 32
-
- // internal state
- component * m_next; // link to next component
- component_type m_type; // type of component
- int m_state; // state where this component is visible (-1 means all states)
- render_bounds m_bounds; // bounds of the element
- render_color m_color; // color of the element
- astring m_string; // string for text components
- int m_digits; // number of digits for simple counters
- int m_textalign; // text alignment to box
- bitmap_argb32 m_bitmap[MAX_BITMAPS]; // source bitmap for images
- astring m_dirname; // directory name of image file (for lazy loading)
- auto_pointer<emu_file> m_file[MAX_BITMAPS]; // file object for reading image/alpha files
- astring m_imagefile[MAX_BITMAPS]; // name of the image file (for lazy loading)
- astring m_alphafile[MAX_BITMAPS]; // name of the alpha file (for lazy loading)
- bool m_hasalpha[MAX_BITMAPS]; // is there any alpha component present?
-
- // stuff for fruit machine reels
- // basically made up of multiple text strings / gfx
- int m_numstops;
- astring m_stopnames[MAX_BITMAPS];
- int m_stateoffset;
- int m_reelreversed;
- int m_numsymbolsvisible;
- int m_beltreel;
- };
-
- // a texture encapsulates a texture for a given element in a given state
- class texture
- {
- public:
- texture();
- ~texture();
-
- layout_element * m_element; // pointer back to the element
- render_texture * m_texture; // texture for this state
- int m_state; // associated state number
- };
-
- // internal helpers
- static void element_scale(bitmap_argb32 &dest, bitmap_argb32 &source, const rectangle &sbounds, void *param);
-
- // internal state
- layout_element * m_next; // link to next element
- running_machine & m_machine; // reference to the owning machine
- astring m_name; // name of this element
- simple_list<component> m_complist; // list of components
- int m_defstate; // default state of this element
- int m_maxstate; // maximum state value for all components
- dynamic_array<texture> m_elemtex; // array of element textures used for managing the scaled bitmaps
+ // a component represents an image, rectangle, or disk in an element
+ class component
+ {
+ friend class layout_element;
+ friend class simple_list<component>;
+
+ public:
+ // construction/destruction
+ component(running_machine &machine, xml_data_node &compnode, const char *dirname);
+ ~component();
+
+ // getters
+ component *next() const { return m_next; }
+ const render_bounds &bounds() const { return m_bounds; }
+
+ // operations
+ void draw(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
+
+ private:
+ // component types
+ enum component_type
+ {
+ CTYPE_INVALID = 0,
+ CTYPE_IMAGE,
+ CTYPE_RECT,
+ CTYPE_DISK,
+ CTYPE_TEXT,
+ CTYPE_LED7SEG,
+ CTYPE_LED8SEG_GTS1,
+ CTYPE_LED14SEG,
+ CTYPE_LED16SEG,
+ CTYPE_LED14SEGSC,
+ CTYPE_LED16SEGSC,
+ CTYPE_DOTMATRIX,
+ CTYPE_DOTMATRIX5DOT,
+ CTYPE_DOTMATRIXDOT,
+ CTYPE_SIMPLECOUNTER,
+ CTYPE_REEL,
+ CTYPE_MAX
+ };
+
+ // helpers
+ void draw_rect(bitmap_argb32 &dest, const rectangle &bounds);
+ void draw_disk(bitmap_argb32 &dest, const rectangle &bounds);
+ void draw_text(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds);
+ void draw_simplecounter(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
+ void draw_reel(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
+ void draw_beltreel(running_machine &machine, bitmap_argb32 &dest, const rectangle &bounds, int state);
+ void load_bitmap();
+ void load_reel_bitmap(int number);
+ void draw_led7seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_led8seg_gts1(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_led14seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_led14segsc(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_led16seg(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_led16segsc(bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_dotmatrix(int dots,bitmap_argb32 &dest, const rectangle &bounds, int pattern);
+ void draw_segment_horizontal_caps(bitmap_argb32 &dest, int minx, int maxx, int midy, int width, int caps, rgb_t color);
+ void draw_segment_horizontal(bitmap_argb32 &dest, int minx, int maxx, int midy, int width, rgb_t color);
+ void draw_segment_vertical_caps(bitmap_argb32 &dest, int miny, int maxy, int midx, int width, int caps, rgb_t color);
+ void draw_segment_vertical(bitmap_argb32 &dest, int miny, int maxy, int midx, int width, rgb_t color);
+ void draw_segment_diagonal_1(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color);
+ void draw_segment_diagonal_2(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color);
+ void draw_segment_decimal(bitmap_argb32 &dest, int midx, int midy, int width, rgb_t color);
+ void draw_segment_comma(bitmap_argb32 &dest, int minx, int maxx, int miny, int maxy, int width, rgb_t color);
+ void apply_skew(bitmap_argb32 &dest, int skewwidth);
+
+ #define MAX_BITMAPS 32
+
+ // internal state
+ component * m_next; // link to next component
+ component_type m_type; // type of component
+ int m_state; // state where this component is visible (-1 means all states)
+ render_bounds m_bounds; // bounds of the element
+ render_color m_color; // color of the element
+ astring m_string; // string for text components
+ int m_digits; // number of digits for simple counters
+ int m_textalign; // text alignment to box
+ bitmap_argb32 m_bitmap[MAX_BITMAPS]; // source bitmap for images
+ astring m_dirname; // directory name of image file (for lazy loading)
+ auto_pointer<emu_file> m_file[MAX_BITMAPS]; // file object for reading image/alpha files
+ astring m_imagefile[MAX_BITMAPS]; // name of the image file (for lazy loading)
+ astring m_alphafile[MAX_BITMAPS]; // name of the alpha file (for lazy loading)
+ bool m_hasalpha[MAX_BITMAPS]; // is there any alpha component present?
+
+ // stuff for fruit machine reels
+ // basically made up of multiple text strings / gfx
+ int m_numstops;
+ astring m_stopnames[MAX_BITMAPS];
+ int m_stateoffset;
+ int m_reelreversed;
+ int m_numsymbolsvisible;
+ int m_beltreel;
+ };
+
+ // a texture encapsulates a texture for a given element in a given state
+ class texture
+ {
+ public:
+ texture();
+ ~texture();
+
+ layout_element * m_element; // pointer back to the element
+ render_texture * m_texture; // texture for this state
+ int m_state; // associated state number
+ };
+
+ // internal helpers
+ static void element_scale(bitmap_argb32 &dest, bitmap_argb32 &source, const rectangle &sbounds, void *param);
+
+ // internal state
+ layout_element * m_next; // link to next element
+ running_machine & m_machine; // reference to the owning machine
+ astring m_name; // name of this element
+ simple_list<component> m_complist; // list of components
+ int m_defstate; // default state of this element
+ int m_maxstate; // maximum state value for all components
+ dynamic_array<texture> m_elemtex; // array of element textures used for managing the scaled bitmaps
};
@@ -185,83 +185,83 @@ private:
// a layout_view encapsulates a named list of items
class layout_view
{
- friend class simple_list<layout_view>;
+ friend class simple_list<layout_view>;
public:
- // an item is a single backdrop, screen, overlay, bezel, cpanel, or marquee item
- class item
- {
- friend class layout_view;
- friend class simple_list<item>;
-
- public:
- // construction/destruction
- item(running_machine &machine, xml_data_node &itemnode, simple_list<layout_element> &elemlist);
- virtual ~item();
-
- // getters
- item *next() const { return m_next; }
- layout_element *element() const { return m_element; }
- screen_device *screen() { return m_screen; }
- const render_bounds &bounds() const { return m_bounds; }
- const render_color &color() const { return m_color; }
- int orientation() const { return m_orientation; }
- render_container *screen_container(running_machine &machine) const;
- bool has_input() const { return bool(m_input_tag); }
- const char *input_tag_and_mask(ioport_value &mask) const { mask = m_input_mask; return m_input_tag; }
-
- // fetch state based on configured source
- int state() const;
-
- private:
- // internal state
- item * m_next; // link to next item
- layout_element * m_element; // pointer to the associated element (non-screens only)
- astring m_output_name; // name of this item
- astring m_input_tag; // input tag of this item
- ioport_value m_input_mask; // input mask of this item
- screen_device * m_screen; // pointer to screen
- int m_orientation; // orientation of this item
- render_bounds m_bounds; // bounds of the item
- render_bounds m_rawbounds; // raw (original) bounds of the item
- render_color m_color; // color of the item
- };
-
- // construction/destruction
- layout_view(running_machine &machine, xml_data_node &viewnode, simple_list<layout_element> &elemlist);
- virtual ~layout_view();
-
- // getters
- layout_view *next() const { return m_next; }
- item *first_item(item_layer layer) const;
- const char *name() const { return m_name; }
- const render_screen_list &screens() const { return m_screens; }
- bool layer_enabled(item_layer layer) const { return m_layenabled[layer]; }
-
- //
- bool has_art() const { return (m_backdrop_list.count() + m_overlay_list.count() + m_bezel_list.count() + m_cpanel_list.count() + m_marquee_list.count() != 0); }
- float effective_aspect(render_layer_config config) const { return (config.zoom_to_screen() && m_screens.count() != 0) ? m_scraspect : m_aspect; }
-
- // operations
- void recompute(render_layer_config layerconfig);
+ // an item is a single backdrop, screen, overlay, bezel, cpanel, or marquee item
+ class item
+ {
+ friend class layout_view;
+ friend class simple_list<item>;
+
+ public:
+ // construction/destruction
+ item(running_machine &machine, xml_data_node &itemnode, simple_list<layout_element> &elemlist);
+ virtual ~item();
+
+ // getters
+ item *next() const { return m_next; }
+ layout_element *element() const { return m_element; }
+ screen_device *screen() { return m_screen; }
+ const render_bounds &bounds() const { return m_bounds; }
+ const render_color &color() const { return m_color; }
+ int orientation() const { return m_orientation; }
+ render_container *screen_container(running_machine &machine) const;
+ bool has_input() const { return bool(m_input_tag); }
+ const char *input_tag_and_mask(ioport_value &mask) const { mask = m_input_mask; return m_input_tag; }
+
+ // fetch state based on configured source
+ int state() const;
+
+ private:
+ // internal state
+ item * m_next; // link to next item
+ layout_element * m_element; // pointer to the associated element (non-screens only)
+ astring m_output_name; // name of this item
+ astring m_input_tag; // input tag of this item
+ ioport_value m_input_mask; // input mask of this item
+ screen_device * m_screen; // pointer to screen
+ int m_orientation; // orientation of this item
+ render_bounds m_bounds; // bounds of the item
+ render_bounds m_rawbounds; // raw (original) bounds of the item
+ render_color m_color; // color of the item
+ };
+
+ // construction/destruction
+ layout_view(running_machine &machine, xml_data_node &viewnode, simple_list<layout_element> &elemlist);
+ virtual ~layout_view();
+
+ // getters
+ layout_view *next() const { return m_next; }
+ item *first_item(item_layer layer) const;
+ const char *name() const { return m_name; }
+ const render_screen_list &screens() const { return m_screens; }
+ bool layer_enabled(item_layer layer) const { return m_layenabled[layer]; }
+
+ //
+ bool has_art() const { return (m_backdrop_list.count() + m_overlay_list.count() + m_bezel_list.count() + m_cpanel_list.count() + m_marquee_list.count() != 0); }
+ float effective_aspect(render_layer_config config) const { return (config.zoom_to_screen() && m_screens.count() != 0) ? m_scraspect : m_aspect; }
+
+ // operations
+ void recompute(render_layer_config layerconfig);
private:
- // internal state
- layout_view * m_next; // pointer to next layout in the list
- astring m_name; // name of the layout
- float m_aspect; // X/Y of the layout
- float m_scraspect; // X/Y of the screen areas
- render_screen_list m_screens; // list of active screens
- render_bounds m_bounds; // computed bounds of the view
- render_bounds m_scrbounds; // computed bounds of the screens within the view
- render_bounds m_expbounds; // explicit bounds of the view
- bool m_layenabled[ITEM_LAYER_MAX]; // is this layer enabled?
- simple_list<item> m_backdrop_list; // list of backdrop items
- simple_list<item> m_screen_list; // list of screen items
- simple_list<item> m_overlay_list; // list of overlay items
- simple_list<item> m_bezel_list; // list of bezel items
- simple_list<item> m_cpanel_list; // list of marquee items
- simple_list<item> m_marquee_list; // list of marquee items
+ // internal state
+ layout_view * m_next; // pointer to next layout in the list
+ astring m_name; // name of the layout
+ float m_aspect; // X/Y of the layout
+ float m_scraspect; // X/Y of the screen areas
+ render_screen_list m_screens; // list of active screens
+ render_bounds m_bounds; // computed bounds of the view
+ render_bounds m_scrbounds; // computed bounds of the screens within the view
+ render_bounds m_expbounds; // explicit bounds of the view
+ bool m_layenabled[ITEM_LAYER_MAX]; // is this layer enabled?
+ simple_list<item> m_backdrop_list; // list of backdrop items
+ simple_list<item> m_screen_list; // list of screen items
+ simple_list<item> m_overlay_list; // list of overlay items
+ simple_list<item> m_bezel_list; // list of bezel items
+ simple_list<item> m_cpanel_list; // list of marquee items
+ simple_list<item> m_marquee_list; // list of marquee items
};
@@ -270,23 +270,23 @@ private:
// a layout_file consists of a list of elements and a list of views
class layout_file
{
- friend class simple_list<layout_file>;
+ friend class simple_list<layout_file>;
public:
- // construction/destruction
- layout_file(running_machine &machine, xml_data_node &rootnode, const char *dirname);
- virtual ~layout_file();
+ // construction/destruction
+ layout_file(running_machine &machine, xml_data_node &rootnode, const char *dirname);
+ virtual ~layout_file();
- // getters
- layout_file *next() const { return m_next; }
- layout_element *first_element() const { return m_elemlist.first(); }
- layout_view *first_view() const { return m_viewlist.first(); }
+ // getters
+ layout_file *next() const { return m_next; }
+ layout_element *first_element() const { return m_elemlist.first(); }
+ layout_view *first_view() const { return m_viewlist.first(); }
private:
- // internal state
- layout_file * m_next; // pointer to the next file in the list
- simple_list<layout_element> m_elemlist; // list of shared layout elements
- simple_list<layout_view> m_viewlist; // list of views
+ // internal state
+ layout_file * m_next; // pointer to the next file in the list
+ simple_list<layout_element> m_elemlist; // list of shared layout elements
+ simple_list<layout_view> m_viewlist; // list of views
};
diff --git a/src/emu/sound/tms5110.c b/src/emu/sound/tms5110.c
index 16e96a13226..d66f753c157 100644
--- a/src/emu/sound/tms5110.c
+++ b/src/emu/sound/tms5110.c
@@ -1056,7 +1056,7 @@ READ8_MEMBER( tms5110_device::ctl_r )
else if (m_state == CTL_STATE_OUTPUT)
{
if (DEBUG_5110) logerror("Status read while outputting buffer (buffer=%2d)\n", m_CTL_buffer);
- return (m_CTL_buffer);
+ return (m_CTL_buffer);
}
else // we're reading with the bus in input mode! just return the last thing written to the bus
{
@@ -1150,8 +1150,8 @@ void tms5110_device::sound_stream_update(sound_stream &stream, stream_sample_t *
/******************************************************************************
tms5110_set_frequency -- adjusts the playback frequency
- TODO: kill this function; we should be adjusting the tms51xx device clock itself,
- not setting it here!
+ TODO: kill this function; we should be adjusting the tms51xx device clock itself,
+ not setting it here!
******************************************************************************/
diff --git a/src/emu/video/315_5124.c b/src/emu/video/315_5124.c
index 9099ec8326e..021b6f96d93 100644
--- a/src/emu/video/315_5124.c
+++ b/src/emu/video/315_5124.c
@@ -1420,7 +1420,7 @@ void sega315_5378_device::blit_scanline( int *line_buffer, int *priority_selecte
}
while (++x < 208);
}
-
+
/* border on right side of the GG active screen */
do
{
diff --git a/src/emu/video/stvvdp2.c b/src/emu/video/stvvdp2.c
index b0e5d2be19a..5632882f2e9 100644
--- a/src/emu/video/stvvdp2.c
+++ b/src/emu/video/stvvdp2.c
@@ -5725,10 +5725,10 @@ READ16_MEMBER ( saturn_state::saturn_vdp2_regs_r )
m_vdp2_regs[offset] = (STV_VDP2_VRAMSZ << 15) |
((0 << 0) & 0xf); // VDP2 version
- /* Games basically r/w the entire VDP2 register area when this is tripped. (example: Silhouette Mirage)
+ /* Games basically r/w the entire VDP2 register area when this is tripped. (example: Silhouette Mirage)
Disable log for the time being. */
//if(!space.debugger_access())
- // printf("Warning: VDP2 version read\n");
+ // printf("Warning: VDP2 version read\n");
break;
}
diff --git a/src/emu/video/tea1002.c b/src/emu/video/tea1002.c
index f9d014ae113..2784e45382b 100644
--- a/src/emu/video/tea1002.c
+++ b/src/emu/video/tea1002.c
@@ -18,7 +18,7 @@
const float tea1002_device::m_luminance[] =
{
- 0, 22.5, 44, 66.5, 8.5, 31, 52.5, 100, // INV = 0
+ 0, 22.5, 44, 66.5, 8.5, 31, 52.5, 100, // INV = 0
75, 52.5, 31, 8.5, 66.5, 44, 22.5, 0 // INV = 1
};
diff --git a/src/lib/formats/dcp_dsk.c b/src/lib/formats/dcp_dsk.c
index 7d0c854f5ed..bdcc2966036 100644
--- a/src/lib/formats/dcp_dsk.c
+++ b/src/lib/formats/dcp_dsk.c
@@ -7,17 +7,17 @@
PC98 DCP & DCU disk images
0xA2 header, followed by track data
- header[0] - disk format
+ header[0] - disk format
header[1-0xA1] - track map (1=track used, 0=track unused/unformatted)
- header[0xA2] - all tracks used?
+ header[0xA2] - all tracks used?
(there seems to be a diff in its usage between DCP and DCU)
- TODO:
+ TODO:
- add support for track map. images available for tests were all
of type 0x01, with all 154 tracks present. combined with pete_j
reporting some images have faulty track map, we need some more
test cases to properly handle these disks!
-
+
*********************************************************************/
#include "emu.h"
@@ -52,7 +52,7 @@ int dcp_format::identify(io_generic *io, UINT32 form_factor)
io_generic_read(io, h, 0, 0xa2);
// First byte is the disk format (see below in load() for details)
- switch (h[0])
+ switch (h[0])
{
case 0x01:
default:
@@ -99,7 +99,7 @@ int dcp_format::identify(io_generic *io, UINT32 form_factor)
if (h[i])
count_tracks++;
- // in theory track map should be enough (former check), but some images have it wrong!
+ // in theory track map should be enough (former check), but some images have it wrong!
// hence, if this check fails, we also allow for images with all tracks and wrong track map
if (size - 0xa2 == (heads * count_tracks * spt * bps) || size - 0xa2 == (heads * tracks * spt * bps))
return 100;
@@ -107,7 +107,7 @@ int dcp_format::identify(io_generic *io, UINT32 form_factor)
// for disk type 0x11 the head 0 track 0 has 26 sectors of half width, so we need to compensate calculation
if (is_hdb && (size - 0xa2 + (0x80 * 26) == (heads * count_tracks * spt * bps) || size - 0xa2 + (0x80 * 26) == (heads * tracks * spt * bps)))
return 100;
-
+
return 0;
}
@@ -116,11 +116,11 @@ bool dcp_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
UINT8 h[0xa2];
int heads, tracks, spt, bps;
bool is_hdb = false;
-
+
io_generic_read(io, h, 0, 0xa2);
-
+
// First byte is the disk format:
- switch (h[0])
+ switch (h[0])
{
case 0x01:
default:
@@ -212,11 +212,11 @@ bool dcp_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
if (!is_hdb)
{
for (int track = 0; track < tracks; track++)
- for (int head = 0; head < heads; head++)
+ for (int head = 0; head < heads; head++)
{
io_generic_read(io, sect_data, 0xa2 + bps * spt * (track * heads + head), bps * spt);
-
- for (int i = 0; i < spt; i++)
+
+ for (int i = 0; i < spt; i++)
{
sects[i].track = track;
sects[i].head = head;
@@ -227,16 +227,16 @@ bool dcp_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
sects[i].bad_crc = false;
sects[i].data = sect_data + i * bps;
}
-
+
build_pc_track_mfm(track, head, image, cell_count, spt, sects, calc_default_pc_gap3_size(form_factor, bps));
}
}
- else // FIXME: the code below is untested, because no image was found... there might be some silly mistake in the disk geometry!
+ else // FIXME: the code below is untested, because no image was found... there might be some silly mistake in the disk geometry!
{
// Read Head 0 Track 0 is FM with 26 sectors of 128bytes instead of 256
io_generic_read(io, sect_data, 0xa2, 128 * spt);
-
- for (int i = 0; i < spt; i++)
+
+ for (int i = 0; i < spt; i++)
{
sects[i].track = 0;
sects[i].head = 0;
@@ -247,13 +247,13 @@ bool dcp_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
sects[i].bad_crc = false;
sects[i].data = sect_data + i * 128;
}
-
+
build_pc_track_fm(0, 0, image, cell_count, spt, sects, calc_default_pc_gap3_size(form_factor, 128));
-
+
// Read Head 1 Track 0 is MFM with 26 sectors of 256bytes
io_generic_read(io, sect_data, 0xa2 + 128 * spt, bps * spt);
-
- for (int i = 0; i < spt; i++)
+
+ for (int i = 0; i < spt; i++)
{
sects[i].track = 0;
sects[i].head = 1;
@@ -264,17 +264,17 @@ bool dcp_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
sects[i].bad_crc = false;
sects[i].data = sect_data + i * bps;
}
-
+
build_pc_track_mfm(0, 1, image, cell_count, spt, sects, calc_default_pc_gap3_size(form_factor, bps));
-
+
// Read other tracks as usual
UINT32 data_offs = 0xa2 + (26 * 0x80) + (26 * 0x100);
for (int track = 1; track < tracks; track++)
- for (int head = 0; head < heads; head++)
+ for (int head = 0; head < heads; head++)
{
io_generic_read(io, sect_data, data_offs + bps * spt * ((track - 1) * heads + head), bps * spt);
-
- for (int i = 0; i < spt; i++)
+
+ for (int i = 0; i < spt; i++)
{
sects[i].track = track;
sects[i].head = head;
@@ -285,11 +285,11 @@ bool dcp_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
sects[i].bad_crc = false;
sects[i].data = sect_data + i * bps;
}
-
+
build_pc_track_mfm(track, head, image, cell_count, spt, sects, calc_default_pc_gap3_size(form_factor, bps));
}
}
-
+
return true;
}
diff --git a/src/lib/formats/dip_dsk.c b/src/lib/formats/dip_dsk.c
index a245a69d824..85f142df8fa 100644
--- a/src/lib/formats/dip_dsk.c
+++ b/src/lib/formats/dip_dsk.c
@@ -5,11 +5,11 @@
formats/dip_dsk.h
PC98 DIP disk images
-
+
0x100 header, followed by track data
TODO:
- - Investigate header structure
+ - Investigate header structure
- can this format be used to support different disc types?
*********************************************************************/
@@ -56,21 +56,21 @@ bool dip_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
tracks = 77;
spt = 8;
bps = 1024;
-
+
int cell_count = form_factor == floppy_image::FF_35 ? 200000 : 166666;
-
+
int ssize;
for (ssize = 0; (128 << ssize) < bps; ssize++);
-
+
desc_pc_sector sects[256];
UINT8 sect_data[65536];
-
+
for (int track = 0; track < tracks; track++)
- for (int head = 0; head < heads; head++)
+ for (int head = 0; head < heads; head++)
{
io_generic_read(io, sect_data, 0x100 + bps * spt * (track * heads + head), bps * spt);
-
- for (int i = 0; i < spt; i++)
+
+ for (int i = 0; i < spt; i++)
{
sects[i].track = track;
sects[i].head = head;
@@ -81,7 +81,7 @@ bool dip_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
sects[i].bad_crc = false;
sects[i].data = sect_data + i * bps;
}
-
+
build_pc_track_mfm(track, head, image, cell_count, spt, sects, calc_default_pc_gap3_size(form_factor, bps));
}
diff --git a/src/lib/formats/fdd_dsk.c b/src/lib/formats/fdd_dsk.c
index 06af2734e74..e9d76a99973 100644
--- a/src/lib/formats/fdd_dsk.c
+++ b/src/lib/formats/fdd_dsk.c
@@ -5,7 +5,7 @@
formats/fdd_dsk.h
PC98 FDD disk images
-
+
0xC3FC header, followed by track data
Sector map starts at offset 0xDC, with 12bytes for each sector
@@ -15,15 +15,15 @@
- 0x2 = sector number
- 0x3 = sector size (128 << this byte)
- 0x4 = fill byte. if it's not 0xff, then this sector in the original
- disk consisted of this single value repeated for the whole
- sector size, and the sector is skipped in the .fdd file.
- if it's 0xff, then this sector is wholly contained in the .fdd
+ disk consisted of this single value repeated for the whole
+ sector size, and the sector is skipped in the .fdd file.
+ if it's 0xff, then this sector is wholly contained in the .fdd
file
- 0x5 = ??
- 0x6 = ??
- 0x7 = ??
- 0x8-0x0b = absolute offset of the data for this sector, or 0xfffffff
- if the sector was skipped in the .fdd (and it has to be
+ if the sector was skipped in the .fdd (and it has to be
filled with the value at 0x4)
TODO:
@@ -55,19 +55,19 @@ const char *fdd_format::extensions() const
int fdd_format::identify(io_generic *io, UINT32 form_factor)
{
- UINT8 h[7];
+ UINT8 h[7];
io_generic_read(io, h, 0, 7);
-
+
if (strncmp((const char *)h, "VFD1.0", 6) == 0)
return 100;
-
+
return 0;
}
bool fdd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
{
- UINT8 hsec[0x0c];
-
+ UINT8 hsec[0x0c];
+
// sector map
UINT8 num_secs[160];
UINT8 tracks[160 * 26];
@@ -76,9 +76,9 @@ bool fdd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
UINT8 fill_vals[160 * 26];
UINT32 sec_offs[160 * 26];
UINT8 sec_sizes[160 * 26];
-
+
int pos = 0xdc;
-
+
for (int track = 0; track < 160; track++)
{
int curr_num_sec = 0, curr_track_size = 0;
@@ -87,10 +87,10 @@ bool fdd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
// read sector map for this sector
io_generic_read(io, hsec, pos, 0x0c);
pos += 0x0c;
-
- if (hsec[0] == 0xff) // unformatted/unused sector
+
+ if (hsec[0] == 0xff) // unformatted/unused sector
continue;
-
+
tracks[(track * 26) + sect] = hsec[0];
heads[(track * 26) + sect] = hsec[1];
secs[(track * 26) + sect] = hsec[2];
@@ -110,9 +110,9 @@ bool fdd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
int cur_sec_map = 0, sector_size;
for (int track = 0; track < 160; track++)
- {
+ {
int cur_pos = 0;
- for (int i = 0; i < num_secs[track]; i++)
+ for (int i = 0; i < num_secs[track]; i++)
{
cur_sec_map = track * 26 + i;
sector_size = 128 << sec_sizes[cur_sec_map];
@@ -121,7 +121,7 @@ bool fdd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
memset(sect_data + cur_pos, fill_vals[cur_sec_map], sector_size);
else
io_generic_read(io, sect_data + cur_pos, sec_offs[cur_sec_map], sector_size);
-
+
sects[i].track = tracks[cur_sec_map];
sects[i].head = heads[cur_sec_map];
sects[i].sector = secs[cur_sec_map];
@@ -135,7 +135,7 @@ bool fdd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
build_pc_track_mfm(track / 2, track % 2, image, cell_count, num_secs[track], sects, calc_default_pc_gap3_size(form_factor, (128 << sec_sizes[track * 26])));
}
-
+
return true;
}
diff --git a/src/lib/formats/nfd_dsk.c b/src/lib/formats/nfd_dsk.c
index 7f55e22dd45..ea886e9dd3a 100644
--- a/src/lib/formats/nfd_dsk.c
+++ b/src/lib/formats/nfd_dsk.c
@@ -30,22 +30,22 @@
0xA = PDA (disk type)
0xB-0xF = reserved and equal to 0x00 (possibly available for future format extensions?)
-
- Revision 1
+
+ Revision 1
==========
-
+
header structure (variable length > 0x120, header length = DWORD at 0x110)
0x000-0x11F = same as Rev. 0 format
- 0x120-0x3AF = 164 DWORDs containing, for each track, the absolute position of the sector maps
+ 0x120-0x3AF = 164 DWORDs containing, for each track, the absolute position of the sector maps
for sectors of the track. for unformatted/unused tracks 0 is used
0x3B0-0x3B3 = absolute position of addintional info in the header, if any
0x3B4-0x3BF = reserved
- 0x120-EOHeader = sector map + special data for each track:
+ 0x120-EOHeader = sector map + special data for each track:
first 0x10 of each track = #sectors (WORD), #extra data (WORD), reserved 0xc bytes zeroed
then 0x10 for each sector of this track and 0x10 for each extra data chunk
sector map structure
- 0x0 = track number
+ 0x0 = track number
0x1 = head
0x2 = sector number
0x3 = sector size (in 128byte chunks)
@@ -74,7 +74,7 @@
- add support for DDAM in Rev. 0 (need an image which set it in some sector)
- investigate the READ DATA bytes of sector headers
- investigate RETRY DATA chunks
-
+
*********************************************************************/
#include "emu.h"
@@ -101,9 +101,9 @@ const char *nfd_format::extensions() const
int nfd_format::identify(io_generic *io, UINT32 form_factor)
{
- UINT8 h[16];
+ UINT8 h[16];
io_generic_read(io, h, 0, 16);
-
+
if (strncmp((const char *)h, "T98FDDIMAGE.R0", 14) == 0 || strncmp((const char *)h, "T98FDDIMAGE.R1", 14) == 0)
return 100;
@@ -113,7 +113,7 @@ int nfd_format::identify(io_generic *io, UINT32 form_factor)
bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
{
UINT64 size = io_generic_size(io);
- UINT8 h[0x120], hsec[0x10];
+ UINT8 h[0x120], hsec[0x10];
io_generic_read(io, h, 0, 0x120);
int format_version = !strncmp((const char *)h, "T98FDDIMAGE.R0", 14) ? 0 : 1;
@@ -156,17 +156,17 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
for (int sect = 0; sect < num_secs[track]; sect++)
{
io_generic_read(io, hsec, secmap_addr, 0x10);
-
+
if (track == 0 && sect == 0)
- disk_type = hsec[0xb]; // can this change across the disk? I don't think so...
+ disk_type = hsec[0xb]; // can this change across the disk? I don't think so...
secmap_addr += 0x10;
-
+
tracks[(track * 26) + sect] = hsec[0];
heads[(track * 26) + sect] = hsec[1];
secs[(track * 26) + sect] = hsec[2];
sec_sizes[(track * 26) + sect] = hsec[3];
mfm[(track * 26) + sect] = hsec[4];
-
+
curr_track_size += (128 << hsec[3]);
}
@@ -174,7 +174,7 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
{
for (int sect = 0; sect < num_specials[track]; sect++)
{
- io_generic_read(io, hsec, secmap_addr, 0x10);
+ io_generic_read(io, hsec, secmap_addr, 0x10);
secmap_addr += 0x10;
curr_track_size += (hsec[9] + 1) * LITTLE_ENDIANIZE_INT32(*(UINT32 *)(hsec + 0x0a));
}
@@ -200,18 +200,18 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
io_generic_read(io, hsec, pos, 0x10);
if (track == 0 && sect == 0)
- disk_type = hsec[0xa]; // can this change across the disk? I don't think so...
+ disk_type = hsec[0xa]; // can this change across the disk? I don't think so...
pos += 0x10;
-
- if (hsec[0] == 0xff) // unformatted/unused sector
+
+ if (hsec[0] == 0xff) // unformatted/unused sector
continue;
-
+
tracks[(track * 26) + sect] = hsec[0];
heads[(track * 26) + sect] = hsec[1];
secs[(track * 26) + sect] = hsec[2];
sec_sizes[(track * 26) + sect] = hsec[3];
mfm[(track * 26) + sect] = hsec[4];
-
+
curr_track_size += (128 << hsec[3]);
curr_num_sec++;
}
@@ -226,12 +226,12 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
switch (disk_type)
{
- case 0x10: // 640K disk, 2DD
+ case 0x10: // 640K disk, 2DD
image->set_variant(floppy_image::DSDD);
break;
- //case 0x30: // 1.44M disk, ?? (no images found)
- // break;
- case 0x90: // 1.2M disk, 2HD
+ //case 0x30: // 1.44M disk, ?? (no images found)
+ // break;
+ case 0x90: // 1.2M disk, 2HD
default:
image->set_variant(floppy_image::DSHD);
break;
@@ -246,7 +246,7 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
{
io_generic_read(io, sect_data, pos, track_sizes[track]);
- for (int i = 0; i < num_secs[track]; i++)
+ for (int i = 0; i < num_secs[track]; i++)
{
cur_sec_map = track * 26 + i;
sector_size = 128 << sec_sizes[cur_sec_map];
@@ -261,7 +261,7 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
}
pos += track_sizes[track];
- // notice that the operation below might fail if sectors of the same track have variable sec_sizes,
+ // notice that the operation below might fail if sectors of the same track have variable sec_sizes,
// because the gap3 calculation would account correctly only for the first sector...
// examined images had constant sec_sizes in the each track, so probably this is not an issue
if (mfm[track * 26])
@@ -269,7 +269,7 @@ bool nfd_format::load(io_generic *io, UINT32 form_factor, floppy_image *image)
else
build_pc_track_fm(track / 2, track % 2, image, cell_count, num_secs[track], sects, calc_default_pc_gap3_size(form_factor, (128 << sec_sizes[track * 26])));
}
-
+
return true;
}
diff --git a/src/lib/formats/victor9k_dsk.c b/src/lib/formats/victor9k_dsk.c
index f98b9f6e9d8..694ac3dbf80 100644
--- a/src/lib/formats/victor9k_dsk.c
+++ b/src/lib/formats/victor9k_dsk.c
@@ -40,61 +40,61 @@
cell 2.13 usec
- Boot Disc Label Format
- Track 0 Sector 0
+ Boot Disc Label Format
+ Track 0 Sector 0
- Byte
- Offset Name Description
+ Byte
+ Offset Name Description
- 0 System disc ID literally, ff,00h for a system
- disc
+ 0 System disc ID literally, ff,00h for a system
+ disc
- 2 Load address paragraph to load booted
- program at. If zero then boot
- loads in high memory.
+ 2 Load address paragraph to load booted
+ program at. If zero then boot
+ loads in high memory.
- 4 Length paragraph count to load.
+ 4 Length paragraph count to load.
- 6 Entry offset I.P. value for transfer of
- control.
+ 6 Entry offset I.P. value for transfer of
+ control.
- 8 Entry segment C.S. value for transfer of
- control.
+ 8 Entry segment C.S. value for transfer of
+ control.
- 10 I.D. disc identifier.
+ 10 I.D. disc identifier.
- 18 Part number system identifier - displayed
- by early versions of boot.
+ 18 Part number system identifier - displayed
+ by early versions of boot.
- 26 Sector size byte count for sectors.
+ 26 Sector size byte count for sectors.
- 28 Data start first data sector on disc
- (absolute sectors).
+ 28 Data start first data sector on disc
+ (absolute sectors).
- 30 Boot start first absolute sector of
- program for boot to load at
- 'load address' for 'length'
- paragraphs.
+ 30 Boot start first absolute sector of
+ program for boot to load at
+ 'load address' for 'length'
+ paragraphs.
- 32 Flags indicators:
- bit meaning
- 15-12 interleave factor
- (0-15)
- 0 0=single sided
- 1=double sided
+ 32 Flags indicators:
+ bit meaning
+ 15-12 interleave factor
+ (0-15)
+ 0 0=single sided
+ 1=double sided
- 34 Disc type 00 = CP/M
- 01 = MS-DOS
+ 34 Disc type 00 = CP/M
+ 01 = MS-DOS
- 35 Reserved
+ 35 Reserved
- 38 Speed table information for speed control
- proc.
+ 38 Speed table information for speed control
+ proc.
- 56 Zone table high track for each zone.
+ 56 Zone table high track for each zone.
- 71 Sector/track sectors per track for each
- zone.
+ 71 Sector/track sectors per track for each
+ zone.
*/
#include "emu.h"
diff --git a/src/mame/drivers/5clown.c b/src/mame/drivers/5clown.c
index 524ce62fdd1..189413abd84 100644
--- a/src/mame/drivers/5clown.c
+++ b/src/mame/drivers/5clown.c
@@ -471,17 +471,17 @@ public:
required_device<ay8910_device> m_ay8910;
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
-
+
required_shared_ptr<UINT8> m_videoram;
required_shared_ptr<UINT8> m_colorram;
-
+
UINT8 m_main_latch_d800;
UINT8 m_snd_latch_0800;
UINT8 m_snd_latch_0a02;
UINT8 m_ay8910_addr;
tilemap_t *m_bg_tilemap;
int m_mux_data;
-
+
DECLARE_WRITE8_MEMBER(fclown_videoram_w);
DECLARE_WRITE8_MEMBER(fclown_colorram_w);
DECLARE_WRITE8_MEMBER(cpu_c048_w);
@@ -505,9 +505,9 @@ public:
};
void _5clown_state::machine_start()
-{
+{
m_main_latch_d800 = m_snd_latch_0800 = m_snd_latch_0a02 = m_ay8910_addr = m_mux_data = 0;
-
+
save_item(NAME(m_main_latch_d800));
save_item(NAME(m_snd_latch_0800));
save_item(NAME(m_snd_latch_0a02));
diff --git a/src/mame/drivers/atvtrack.c b/src/mame/drivers/atvtrack.c
index bd0e243482c..ab604e4419c 100644
--- a/src/mame/drivers/atvtrack.c
+++ b/src/mame/drivers/atvtrack.c
@@ -409,7 +409,6 @@ void atvtrack_state::machine_reset()
void smashdrv_state::machine_start()
{
-
}
void smashdrv_state::machine_reset()
@@ -423,7 +422,7 @@ void smashdrv_state::machine_reset()
static ADDRESS_MAP_START( atvtrack_main_map, AS_PROGRAM, 64, atvtrack_state )
AM_RANGE(0x00000000, 0x000003ff) AM_RAM AM_SHARE("sharedmem")
AM_RANGE(0x00020000, 0x00020007) AM_READWRITE(control_r, control_w) // control registers
-// AM_RANGE(0x00020040, 0x0002007f) // audio DAC buffer
+// AM_RANGE(0x00020040, 0x0002007f) // audio DAC buffer
AM_RANGE(0x14000000, 0x14000007) AM_READWRITE(area2_r, area2_w) // data
AM_RANGE(0x14100000, 0x14100007) AM_READWRITE(area3_r, area3_w) // command
AM_RANGE(0x14200000, 0x14200007) AM_READWRITE(area4_r, area4_w) // address
@@ -585,9 +584,9 @@ ROM_START( smashdrv )
ROM_LOAD("prg.ic23", 0x0000000, 0x0400000, CRC(5cc6d3ac) SHA1(0c8426774212d891796b59c95b8c70f64db5b67a) )
ROM_REGION( 0x4000000, "maincpu", ROMREGION_ERASEFF)
- ROM_LOAD32_WORD("sdra.ic15", 0x00000000, 0x01000000, CRC(cf702287) SHA1(84cd83c339831deff15fe5fcc353e0b596667500) )
- ROM_LOAD32_WORD("sdrb.ic14", 0x00000002, 0x01000000, CRC(39b76f0e) SHA1(529943b6075925e5f72c6e966796e04b2c33686c) )
- ROM_LOAD32_WORD("sdrc.ic20", 0x02000000, 0x01000000, CRC(c9021dd7) SHA1(1d08aab433614810af858a0fc5d7f03c7b782237) )
+ ROM_LOAD32_WORD("sdra.ic15", 0x00000000, 0x01000000, CRC(cf702287) SHA1(84cd83c339831deff15fe5fcc353e0b596667500) )
+ ROM_LOAD32_WORD("sdrb.ic14", 0x00000002, 0x01000000, CRC(39b76f0e) SHA1(529943b6075925e5f72c6e966796e04b2c33686c) )
+ ROM_LOAD32_WORD("sdrc.ic20", 0x02000000, 0x01000000, CRC(c9021dd7) SHA1(1d08aab433614810af858a0fc5d7f03c7b782237) )
// ic21 unpopulated
ROM_END
diff --git a/src/mame/drivers/barata.c b/src/mame/drivers/barata.c
index 4db4d4ab506..240b8c3fab7 100644
--- a/src/mame/drivers/barata.c
+++ b/src/mame/drivers/barata.c
@@ -2,35 +2,35 @@
// copyright-holders:FelipeSanches
/*************************************************************************
- barata.c
+ barata.c
- "Dona Barata"
+ "Dona Barata"
- Brazilian "whack-a-mole"-style game themed after stepping on cockroaches.
- The name "Dona Barata" means "Lady Cockroach" in brazilian portuguese.
+ Brazilian "whack-a-mole"-style game themed after stepping on cockroaches.
+ The name "Dona Barata" means "Lady Cockroach" in brazilian portuguese.
- Manufactured by Matic: http://maticplay.com.br/
- This driver still only emulates an early prototype of the game.
- Propper dumps of the actual released game is still lacking.
- Photos on the web make us believe that there are at least 2 official
+ Manufactured by Matic: http://maticplay.com.br/
+ This driver still only emulates an early prototype of the game.
+ Propper dumps of the actual released game is still lacking.
+ Photos on the web make us believe that there are at least 2 official
releases of this game.
- http://www.maticplay.com.br/equipamentos.php?equipamento=dona-barata
- http://www.valedosduendes.com.br/site/wp-content/uploads/2012/02/barata_1.jpg
+ http://www.maticplay.com.br/equipamentos.php?equipamento=dona-barata
+ http://www.valedosduendes.com.br/site/wp-content/uploads/2012/02/barata_1.jpg
Driver by Felipe Sanches <juca@members.fsf.org>
**************************************************************************
- TO-DO:
+ TO-DO:
- * at the moment, the portbits for the rows are still a guess
- * as we don't have access to actual PCBs, the CPU clock frequency is a guess
- (but maybe it can be infered by analysing the 1ms delay routine used)
- * we don't have sound samples or background music dumps
- (i.e. we lack dumps of all of the sound memory)
- * we don't have ROM dumps of the official releases of the game
- * it would be nice to add photographic artwork to improve the layout
+ * at the moment, the portbits for the rows are still a guess
+ * as we don't have access to actual PCBs, the CPU clock frequency is a guess
+ (but maybe it can be infered by analysing the 1ms delay routine used)
+ * we don't have sound samples or background music dumps
+ (i.e. we lack dumps of all of the sound memory)
+ * we don't have ROM dumps of the official releases of the game
+ * it would be nice to add photographic artwork to improve the layout
**************************************************************************/
@@ -138,12 +138,12 @@ static UINT8 dec_7seg(int data)
return segment;
}
-#define FPGA_PLAY_BGM 0
-#define FPGA_STOP_BGM 1
-#define FPGA_PLAY_SAMPLE 2
-#define FPGA_LAMP 3
-#define FPGA_COUNTER 4
-#define FPGA_WAITING_FOR_NEW_CMD 5
+#define FPGA_PLAY_BGM 0
+#define FPGA_STOP_BGM 1
+#define FPGA_PLAY_SAMPLE 2
+#define FPGA_LAMP 3
+#define FPGA_COUNTER 4
+#define FPGA_WAITING_FOR_NEW_CMD 5
const char* mode_strings[] = {
"Play background music",
@@ -193,7 +193,7 @@ static void fpga_send(unsigned char cmd){
lamp_index = lamp_data & 0x0F;
if (erase_all){
-// logerror("LED: ERASE ALL\n");
+// logerror("LED: ERASE ALL\n");
for (int i=0; i<16; i++){
output_set_led_value(i, 1);
}
@@ -329,4 +329,4 @@ ROM_END
/*************************
* Game Drivers *
*************************/
-GAME( 2002, barata, 0, barata, barata, driver_device, 0, ROT0, "Eletro Matic Equipamentos Eletromecânicos", "Dona Barata (early prototype)", GAME_IMPERFECT_GRAPHICS )
+GAME( 2002, barata, 0, barata, barata, driver_device, 0, ROT0, "Eletro Matic Equipamentos Eletromec??nicos", "Dona Barata (early prototype)", GAME_IMPERFECT_GRAPHICS )
diff --git a/src/mame/drivers/bfm_sc1.c b/src/mame/drivers/bfm_sc1.c
index 773a558b011..d01add6ee5a 100644
--- a/src/mame/drivers/bfm_sc1.c
+++ b/src/mame/drivers/bfm_sc1.c
@@ -178,7 +178,7 @@ public:
DECLARE_READ8_MEMBER(nec_r);
DECLARE_WRITE8_MEMBER(nec_reset_w);
DECLARE_WRITE8_MEMBER(nec_latch_w);
-
+
void save_state();
DECLARE_DRIVER_INIT(toppoker);
diff --git a/src/mame/drivers/bfm_sc2.c b/src/mame/drivers/bfm_sc2.c
index 51df35674a2..2ce8714833d 100644
--- a/src/mame/drivers/bfm_sc2.c
+++ b/src/mame/drivers/bfm_sc2.c
@@ -3613,7 +3613,7 @@ static MACHINE_CONFIG_START( scorpion2, bfm_sc2_state )
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_sc2_vfd)
-
+
MCFG_DEVICE_ADD("reel0", STEPPER, 0)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel0_optic_cb))
MCFG_DEVICE_ADD("reel1", STEPPER, 0)
@@ -3621,7 +3621,7 @@ static MACHINE_CONFIG_START( scorpion2, bfm_sc2_state )
MCFG_DEVICE_ADD("reel2", STEPPER, 0)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel2_optic_cb))
MCFG_DEVICE_ADD("reel3", STEPPER, 0)
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel3_optic_cb))
MCFG_DEVICE_ADD("reel4", STEPPER, 0)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel4_optic_cb))
MCFG_DEVICE_ADD("reel5", STEPPER, 0)
@@ -3663,7 +3663,7 @@ static MACHINE_CONFIG_START( scorpion2_dm01, bfm_sc2_state )
MCFG_CPU_ADD("matrix", M6809, 2000000 ) /* matrix board 6809 CPU at 2 Mhz ?? I don't know the exact freq.*/
MCFG_CPU_PROGRAM_MAP(bfm_dm01_memmap)
MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, nmi_line_assert, 1500 ) /* generate 1500 NMI's per second ?? what is the exact freq?? */
-
+
MCFG_DEVICE_ADD("reel0", STEPPER, 0)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel0_optic_cb))
MCFG_DEVICE_ADD("reel1", STEPPER, 0)
@@ -3671,7 +3671,7 @@ static MACHINE_CONFIG_START( scorpion2_dm01, bfm_sc2_state )
MCFG_DEVICE_ADD("reel2", STEPPER, 0)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel2_optic_cb))
MCFG_DEVICE_ADD("reel3", STEPPER, 0)
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel3_optic_cb))
MCFG_DEVICE_ADD("reel4", STEPPER, 0)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(bfm_sc2_state, reel4_optic_cb))
MCFG_DEVICE_ADD("reel5", STEPPER, 0)
diff --git a/src/mame/drivers/bfm_sc4.c b/src/mame/drivers/bfm_sc4.c
index a0a30b765a5..7d8bb54cb95 100644
--- a/src/mame/drivers/bfm_sc4.c
+++ b/src/mame/drivers/bfm_sc4.c
@@ -28317,7 +28317,7 @@ GAMEL( 200?, sc4paccla ,sc4paccl, sc4_5reel, sc4paccl, sc4_state, sc4paccl, R
GAMEL( 200?, sc4pacclb ,sc4paccl, sc4_5reel, sc4paccl, sc4_state, sc4paccl, ROT0, "Mazooma","Pac Man Club (PR2018, CPAC) (Mazooma) (Scorpion 4) (set 3)", GAME_NOT_WORKING | GAME_CLICKABLE_ARTWORK, layout_bfm_sc4 )
GAMEL( 200?, sc4pacclc ,sc4paccl, sc4_5reel, sc4paccl, sc4_state, sc4paccl, ROT0, "Mazooma","Pac Man Club (PR2018, CPAC) (Mazooma) (Scorpion 4) (set 4)", GAME_NOT_WORKING | GAME_CLICKABLE_ARTWORK, layout_bfm_sc4 )
-
+
// REEL 4 ERR 24 (what type should be here??)
DRIVER_INIT_MEMBER(sc4_state,sc4pmani)
diff --git a/src/mame/drivers/bfm_sc4h.c b/src/mame/drivers/bfm_sc4h.c
index 079493126b4..f257c4713a9 100644
--- a/src/mame/drivers/bfm_sc4h.c
+++ b/src/mame/drivers/bfm_sc4h.c
@@ -522,8 +522,8 @@ void sc4_state::bfm_sc4_68307_porta_w(address_space &space, bool dedicated, UINT
m_reel1->update( data &0x0f);
awp_draw_reel("reel1", m_reel1);
}
-
- if (m_reel2)
+
+ if (m_reel2)
{
m_reel2->update((data>>4)&0x0f);
awp_draw_reel("reel2", m_reel2);
@@ -651,8 +651,8 @@ WRITE8_MEMBER(sc4_state::bfm_sc4_duart_output_w)
m_reel5->update( data &0x0f);
awp_draw_reel("reel5", m_reel5);
}
-
- if (m_reel6)
+
+ if (m_reel6)
{
m_reel6->update((data>>4)&0x0f);
awp_draw_reel("reel6", m_reel6);
@@ -712,11 +712,11 @@ MACHINE_CONFIG_FRAGMENT( sc4_common )
MCFG_YMZ280B_IRQ_HANDLER(WRITELINE(sc4_state, bfm_sc4_irqhandler))
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
MACHINE_CONFIG_END
-
+
//Standard 6 reels all connected
MACHINE_CONFIG_START( sc4, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -734,20 +734,20 @@ MACHINE_CONFIG_END
//Standard 3 reels
MACHINE_CONFIG_START( sc4_3reel, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel2_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
-
+
MACHINE_CONFIG_END
//Standard 4 reels
MACHINE_CONFIG_START( sc4_4reel, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -762,14 +762,14 @@ MACHINE_CONFIG_END
MACHINE_CONFIG_START( sc4_4reel_alt, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel2_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel5")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MACHINE_CONFIG_END
@@ -778,7 +778,7 @@ MACHINE_CONFIG_END
//Standard 5 reels
MACHINE_CONFIG_START( sc4_5reel, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -794,26 +794,26 @@ MACHINE_CONFIG_END
//5 reels, with RL4 skipped
MACHINE_CONFIG_START( sc4_5reel_alt, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel2_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel5")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
-
+
MACHINE_CONFIG_END
//6 reels, last 200 steps
MACHINE_CONFIG_START( sc4_200_std, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -823,7 +823,7 @@ MACHINE_CONFIG_START( sc4_200_std, sc4_state )
MCFG_STARPOINT_RM20_48STEP_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
@@ -831,7 +831,7 @@ MACHINE_CONFIG_END
//6 reels, last 200 steps
MACHINE_CONFIG_START( sc4_200_alt, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -841,7 +841,7 @@ MACHINE_CONFIG_START( sc4_200_alt, sc4_state )
MCFG_STARPOINT_200STEP_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
@@ -849,7 +849,7 @@ MACHINE_CONFIG_END
//6 reels, RL4 200 steps
MACHINE_CONFIG_START( sc4_200_alta, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -859,7 +859,7 @@ MACHINE_CONFIG_START( sc4_200_alta, sc4_state )
MCFG_STARPOINT_RM20_48STEP_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
@@ -867,7 +867,7 @@ MACHINE_CONFIG_END
//6 reels, 3 48 step, 3 200 step
MACHINE_CONFIG_START( sc4_200_altb, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_200STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel2")
@@ -877,7 +877,7 @@ MACHINE_CONFIG_START( sc4_200_altb, sc4_state )
MCFG_STARPOINT_RM20_48STEP_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
@@ -885,7 +885,7 @@ MACHINE_CONFIG_END
//5 reels, last one 200 steps
MACHINE_CONFIG_START( sc4_200_5r, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -893,9 +893,9 @@ MACHINE_CONFIG_START( sc4_200_5r, sc4_state )
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel4")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MACHINE_CONFIG_END
@@ -903,16 +903,16 @@ MACHINE_CONFIG_END
//5 reels, last one 200 steps, RL4 skipped
MACHINE_CONFIG_START( sc4_200_5ra, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel2_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
@@ -920,7 +920,7 @@ MACHINE_CONFIG_END
//5 reels, last one 200 steps, RL5 skipped
MACHINE_CONFIG_START( sc4_200_5rb, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -937,24 +937,24 @@ MACHINE_CONFIG_END
//5 reels, RL5 200 steps, RL4 skipped
MACHINE_CONFIG_START( sc4_200_5rc, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel2_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
-
+
MCFG_STARPOINT_200STEP_ADD("reel5")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel5_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel6")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
//4 reels, last one 200 steps
MACHINE_CONFIG_START( sc4_200_4r, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -962,13 +962,13 @@ MACHINE_CONFIG_START( sc4_200_4r, sc4_state )
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel4")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MACHINE_CONFIG_END
//4 reels, last one 200 steps, RL4 skipped
MACHINE_CONFIG_START( sc4_200_4ra, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
@@ -984,21 +984,21 @@ MACHINE_CONFIG_END
//4 reels, last one 200 steps, RL4,5 skipped
MACHINE_CONFIG_START( sc4_200_4rb, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel2_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
-
+
MCFG_STARPOINT_200STEP_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel6_optic_cb))
MACHINE_CONFIG_END
MACHINE_CONFIG_START( sc4_4reel_200, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_200STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel2")
@@ -1006,12 +1006,12 @@ MACHINE_CONFIG_START( sc4_4reel_200, sc4_state )
MCFG_STARPOINT_200STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel4")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MACHINE_CONFIG_END
MACHINE_CONFIG_START( sc4_3reel_200, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_200STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel2")
@@ -1023,7 +1023,7 @@ MACHINE_CONFIG_END
MACHINE_CONFIG_START( sc4_3reel_200_48, sc4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_STARPOINT_200STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_200STEP_ADD("reel2")
@@ -1031,7 +1031,7 @@ MACHINE_CONFIG_START( sc4_3reel_200_48, sc4_state )
MCFG_STARPOINT_200STEP_ADD("reel3")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel3_optic_cb))
MCFG_STARPOINT_48STEP_ADD("reel4")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel4_optic_cb))
MACHINE_CONFIG_END
MACHINE_CONFIG_START( sc4_no_reels, sc4_state )
@@ -1047,7 +1047,7 @@ MACHINE_START_MEMBER(sc4_adder4_state,adder4)
MACHINE_CONFIG_START( sc4_adder4, sc4_adder4_state )
MCFG_FRAGMENT_ADD(sc4_common)
-
+
MCFG_CPU_ADD("adder4", M68340, 25175000) // 68340 (CPU32 core)
MCFG_CPU_PROGRAM_MAP(sc4_adder4_map)
@@ -1066,7 +1066,7 @@ MACHINE_CONFIG_START( sc4dmd, sc4_state )
MCFG_CPU_PERIODIC_INT_DRIVER(sc4_state, nmi_line_assert, 1500 ) /* generate 1500 NMI's per second ?? what is the exact freq?? */
MCFG_MACHINE_START_OVERRIDE(sc4_state, sc4 )
-
+
MCFG_STARPOINT_RM20_48STEP_ADD("reel1")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(sc4_state, reel1_optic_cb))
MCFG_STARPOINT_RM20_48STEP_ADD("reel2")
diff --git a/src/mame/drivers/bwidow.c b/src/mame/drivers/bwidow.c
index 25705db47a4..7134c904810 100644
--- a/src/mame/drivers/bwidow.c
+++ b/src/mame/drivers/bwidow.c
@@ -393,7 +393,7 @@ static ADDRESS_MAP_START( spacduel_map, AS_PROGRAM, 8, bwidow_state )
AM_RANGE(0x0900, 0x0907) AM_READ(spacduel_IN3_r) /* IN1 */
AM_RANGE(0x0905, 0x0906) AM_WRITENOP /* ignore? */
AM_RANGE(0x0a00, 0x0a00) AM_DEVREAD("earom", atari_vg_earom_device, read)
- AM_RANGE(0x0c00, 0x0c00) AM_WRITE(spacduel_coin_counter_w) /* coin out */
+ AM_RANGE(0x0c00, 0x0c00) AM_WRITE(spacduel_coin_counter_w) /* coin out */
AM_RANGE(0x0c80, 0x0c80) AM_DEVWRITE("avg", avg_device, go_w)
AM_RANGE(0x0d00, 0x0d00) AM_WRITENOP /* watchdog clear */
AM_RANGE(0x0d80, 0x0d80) AM_DEVWRITE("avg", avg_device, reset_w)
diff --git a/src/mame/drivers/cps1.c b/src/mame/drivers/cps1.c
index 71fa6d0d688..c66338b9b94 100644
--- a/src/mame/drivers/cps1.c
+++ b/src/mame/drivers/cps1.c
@@ -11532,7 +11532,7 @@ DRIVER_INIT_MEMBER(cps_state,dinohunt)
m_maincpu->space(AS_PROGRAM).install_read_handler(0xf18000, 0xf19fff, read16_delegate(FUNC(cps_state::dinohunt_sound_r), this));
m_maincpu->space(AS_PROGRAM).install_read_port(0xfc0000, 0xfc0001, "IN2"); ;
// the ym2151 doesn't seem to be used. Is it actually on the PCB?
-
+
DRIVER_INIT_CALL(cps1);
}
diff --git a/src/mame/drivers/cultures.c b/src/mame/drivers/cultures.c
index 7390655a247..3f23fe5e24c 100644
--- a/src/mame/drivers/cultures.c
+++ b/src/mame/drivers/cultures.c
@@ -185,7 +185,7 @@ static ADDRESS_MAP_START( oki_map, AS_0, 8, cultures_state )
ADDRESS_MAP_END
static ADDRESS_MAP_START( vrambank_map, AS_PROGRAM, 8, cultures_state )
- AM_RANGE(0x0000, 0x3fff) AM_RAM_WRITE(bg0_videoram_w) AM_SHARE("bg0_videoram")
+ AM_RANGE(0x0000, 0x3fff) AM_RAM_WRITE(bg0_videoram_w) AM_SHARE("bg0_videoram")
AM_RANGE(0x4000, 0x6fff) AM_RAM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette")
ADDRESS_MAP_END
diff --git a/src/mame/drivers/dreamwld.c b/src/mame/drivers/dreamwld.c
index 74a13392acb..068fcc18497 100644
--- a/src/mame/drivers/dreamwld.c
+++ b/src/mame/drivers/dreamwld.c
@@ -383,14 +383,14 @@ UINT32 dreamwld_state::screen_update_dreamwld(screen_device &screen, bitmap_ind1
READ32_MEMBER(dreamwld_state::dreamwld_protdata_r)
{
-// static int count = 0;
+// static int count = 0;
UINT8 *protdata = memregion("user1")->base();
size_t protsize = memregion("user1")->bytes();
UINT8 dat = protdata[(m_protindex++) % protsize];
-// printf("protection read %04x %02x\n", count, dat);
-// count++;
+// printf("protection read %04x %02x\n", count, dat);
+// count++;
// real hw returns 00 after end of data, I haven't checked if it's possible to overflow the read counter
// and read out the internal rom.
@@ -614,39 +614,39 @@ static INPUT_PORTS_START( cutefght )
PORT_START("DSW")
PORT_DIPUNUSED_DIPLOC( 0x0001, IP_ACTIVE_LOW, "SW2:1" ) /* As listed in service mode, but tested */
PORT_DIPUNUSED_DIPLOC( 0x0002, IP_ACTIVE_LOW, "SW2:2" ) /* These might have some use, requires investigation of code */
- PORT_DIPUNUSED_DIPLOC( 0x0004, IP_ACTIVE_LOW, "SW2:3" )
- PORT_DIPUNUSED_DIPLOC( 0x0008, IP_ACTIVE_LOW, "SW2:4" )
- PORT_DIPUNUSED_DIPLOC( 0x0010, IP_ACTIVE_LOW, "SW2:5" )
- PORT_DIPNAME( 0x0060, 0x0060, "Ticket Payout" ) PORT_DIPLOCATION("SW2:6,7")
- PORT_DIPSETTING( 0x0000, DEF_STR( No ) )
- PORT_DIPSETTING( 0x0020, "Little" )
- PORT_DIPSETTING( 0x0060, DEF_STR( Normal ) )
- PORT_DIPSETTING( 0x0040, "Much" )
- PORT_DIPNAME( 0x0080, 0x0080, DEF_STR( Free_Play ) ) PORT_DIPLOCATION("SW2:8")
- PORT_DIPSETTING( 0x0080, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
- PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("SW1:1") /* Has no effect?? */
- PORT_DIPSETTING( 0x0100, DEF_STR( Off ) )
- PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
- PORT_DIPNAME( 0x0e00, 0x0e00, DEF_STR( Coinage ) ) PORT_DIPLOCATION("SW1:2,3,4")
- PORT_DIPSETTING( 0x0000, DEF_STR( 5C_1C ) )
- PORT_DIPSETTING( 0x0200, DEF_STR( 4C_1C ) )
- PORT_DIPSETTING( 0x0400, DEF_STR( 3C_1C ) )
- PORT_DIPSETTING( 0x0600, DEF_STR( 2C_1C ) )
- PORT_DIPSETTING( 0x0e00, DEF_STR( 1C_1C ) )
- PORT_DIPSETTING( 0x0a00, DEF_STR( 2C_3C ) )
- PORT_DIPSETTING( 0x0c00, DEF_STR( 1C_2C ) )
- PORT_DIPSETTING( 0x0800, DEF_STR( 1C_3C ) )
- PORT_DIPNAME( 0x7000, 0x7000, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW1:5,6,7")
- PORT_DIPSETTING( 0x2000, "Level 1" )
- PORT_DIPSETTING( 0x1000, "Level 2" )
- PORT_DIPSETTING( 0x0000, "Level 3" )
- PORT_DIPSETTING( 0x7000, "Level 4" )
- PORT_DIPSETTING( 0x6000, "Level 5" )
- PORT_DIPSETTING( 0x5000, "Level 6" )
- PORT_DIPSETTING( 0x4000, "Level 7" )
- PORT_DIPSETTING( 0x3000, "Level 8" )
- PORT_SERVICE_DIPLOC( 0x8000, IP_ACTIVE_LOW, "SW1:8" )
+ PORT_DIPUNUSED_DIPLOC( 0x0004, IP_ACTIVE_LOW, "SW2:3" )
+ PORT_DIPUNUSED_DIPLOC( 0x0008, IP_ACTIVE_LOW, "SW2:4" )
+ PORT_DIPUNUSED_DIPLOC( 0x0010, IP_ACTIVE_LOW, "SW2:5" )
+ PORT_DIPNAME( 0x0060, 0x0060, "Ticket Payout" ) PORT_DIPLOCATION("SW2:6,7")
+ PORT_DIPSETTING( 0x0000, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x0020, "Little" )
+ PORT_DIPSETTING( 0x0060, DEF_STR( Normal ) )
+ PORT_DIPSETTING( 0x0040, "Much" )
+ PORT_DIPNAME( 0x0080, 0x0080, DEF_STR( Free_Play ) ) PORT_DIPLOCATION("SW2:8")
+ PORT_DIPSETTING( 0x0080, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
+ PORT_DIPNAME( 0x0100, 0x0000, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("SW1:1") /* Has no effect?? */
+ PORT_DIPSETTING( 0x0100, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
+ PORT_DIPNAME( 0x0e00, 0x0e00, DEF_STR( Coinage ) ) PORT_DIPLOCATION("SW1:2,3,4")
+ PORT_DIPSETTING( 0x0000, DEF_STR( 5C_1C ) )
+ PORT_DIPSETTING( 0x0200, DEF_STR( 4C_1C ) )
+ PORT_DIPSETTING( 0x0400, DEF_STR( 3C_1C ) )
+ PORT_DIPSETTING( 0x0600, DEF_STR( 2C_1C ) )
+ PORT_DIPSETTING( 0x0e00, DEF_STR( 1C_1C ) )
+ PORT_DIPSETTING( 0x0a00, DEF_STR( 2C_3C ) )
+ PORT_DIPSETTING( 0x0c00, DEF_STR( 1C_2C ) )
+ PORT_DIPSETTING( 0x0800, DEF_STR( 1C_3C ) )
+ PORT_DIPNAME( 0x7000, 0x7000, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW1:5,6,7")
+ PORT_DIPSETTING( 0x2000, "Level 1" )
+ PORT_DIPSETTING( 0x1000, "Level 2" )
+ PORT_DIPSETTING( 0x0000, "Level 3" )
+ PORT_DIPSETTING( 0x7000, "Level 4" )
+ PORT_DIPSETTING( 0x6000, "Level 5" )
+ PORT_DIPSETTING( 0x5000, "Level 6" )
+ PORT_DIPSETTING( 0x4000, "Level 7" )
+ PORT_DIPSETTING( 0x3000, "Level 8" )
+ PORT_SERVICE_DIPLOC( 0x8000, IP_ACTIVE_LOW, "SW1:8" )
INPUT_PORTS_END
@@ -1073,5 +1073,5 @@ ROM_END
GAME( 1997, baryon, 0, baryon, baryon, driver_device, 0, ROT270, "SemiCom", "Baryon - Future Assault (set 1)", GAME_SUPPORTS_SAVE )
GAME( 1997, baryona, baryon, baryon, baryon, driver_device, 0, ROT270, "SemiCom", "Baryon - Future Assault (set 2)", GAME_SUPPORTS_SAVE )
GAME( 1998, cutefght, 0, dreamwld, cutefght, driver_device, 0, ROT0, "SemiCom", "Cute Fighter", GAME_SUPPORTS_SAVE | GAME_IMPERFECT_GRAPHICS ) // wrong linescroll?
-GAME( 1999, rolcrush, 0, baryon, rolcrush, driver_device, 0, ROT0, "Trust / SemiCom", "Rolling Crush (version 1.07.E - 1999/02/11)", GAME_SUPPORTS_SAVE | GAME_IMPERFECT_GRAPHICS ) // wrong
+GAME( 1999, rolcrush, 0, baryon, rolcrush, driver_device, 0, ROT0, "Trust / SemiCom", "Rolling Crush (version 1.07.E - 1999/02/11)", GAME_SUPPORTS_SAVE | GAME_IMPERFECT_GRAPHICS ) // wrong
GAME( 2000, dreamwld, 0, dreamwld, dreamwld, driver_device, 0, ROT0, "SemiCom", "Dream World", GAME_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/ecoinfr.c b/src/mame/drivers/ecoinfr.c
index b55777a024d..9eccedc9a6c 100644
--- a/src/mame/drivers/ecoinfr.c
+++ b/src/mame/drivers/ecoinfr.c
@@ -786,7 +786,7 @@ static MACHINE_CONFIG_START( ecoinfr, ecoinfr_state )
MCFG_ECOIN_200STEP_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(ecoinfr_state, reel2_optic_cb))
MCFG_ECOIN_200STEP_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(ecoinfr_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(ecoinfr_state, reel3_optic_cb))
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/f-32.c b/src/mame/drivers/f-32.c
index bccda2eb7ca..e6814e8954a 100644
--- a/src/mame/drivers/f-32.c
+++ b/src/mame/drivers/f-32.c
@@ -27,10 +27,10 @@ public:
/* devices */
required_device<e132xn_device> m_maincpu;
-
+
/* memory pointers */
required_shared_ptr<UINT32> m_videoram;
-
+
DECLARE_READ32_MEMBER(f32_input_port_1_r);
UINT32 screen_update_mosaicf2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
};
diff --git a/src/mame/drivers/galpani2.c b/src/mame/drivers/galpani2.c
index e05ee960f76..a23050f032f 100644
--- a/src/mame/drivers/galpani2.c
+++ b/src/mame/drivers/galpani2.c
@@ -71,9 +71,9 @@ Notes:
PISCES - NEC uPD78324 series MCU with 32k internal rom. Clock 13.500MHz [27/2] on pins 51 & 52
VSync - 59.1856Hz
HSync - 15.625kHz
-
+
(TODO: VTOTAL = 264, HTOTAL = 432, pixel clock 27 MHz / 4)
-
+
***************************************************************************/
#include "emu.h"
@@ -346,23 +346,23 @@ static ADDRESS_MAP_START( galpani2_mem1, AS_PROGRAM, 16, galpani2_state )
AM_RANGE(0x300000, 0x301fff) AM_RAM // ?
AM_RANGE(0x302000, 0x303fff) AM_RAM AM_SHARE("spriteram") // Sprites
AM_RANGE(0x304000, 0x30401f) AM_DEVREADWRITE("kan_spr", kaneko16_sprite_device, kaneko16_sprites_regs_r, kaneko16_sprites_regs_w)
-// AM_RANGE(0x308000, 0x308001) AM_WRITENOP // ? 0 at startup
-// AM_RANGE(0x30c000, 0x30c001) AM_WRITENOP // ? hblank effect ?
+// AM_RANGE(0x308000, 0x308001) AM_WRITENOP // ? 0 at startup
+// AM_RANGE(0x30c000, 0x30c001) AM_WRITENOP // ? hblank effect ?
AM_RANGE(0x310000, 0x3101ff) AM_RAM_DEVWRITE("bg8palette", palette_device, write) AM_SHARE("bg8palette") // ?
AM_RANGE(0x314000, 0x314001) AM_WRITENOP // ? flip backgrounds ?
AM_RANGE(0x318000, 0x318001) AM_READWRITE(galpani2_eeprom_r, galpani2_eeprom_w) // EEPROM
AM_RANGE(0x380000, 0x387fff) AM_RAM // Palette?
AM_RANGE(0x388000, 0x38ffff) AM_RAM_DEVWRITE("palette", palette_device, write) AM_SHARE("palette") // Palette
-// AM_RANGE(0x390000, 0x3901ff) AM_WRITENOP // ? at startup of service mode
+// AM_RANGE(0x390000, 0x3901ff) AM_WRITENOP // ? at startup of service mode
AM_RANGE(0x400000, 0x43ffff) AM_RAM AM_SHARE("bg8.0") // Background 0
AM_RANGE(0x440000, 0x440001) AM_RAM AM_SHARE("bg8_scrollx.0") // Background 0 Scroll X
AM_RANGE(0x480000, 0x480001) AM_RAM AM_SHARE("bg8_scrolly.0") // Background 0 Scroll Y
-// AM_RANGE(0x4c0000, 0x4c0001) AM_WRITENOP // ? 0 at startup only
+// AM_RANGE(0x4c0000, 0x4c0001) AM_WRITENOP // ? 0 at startup only
AM_RANGE(0x500000, 0x53ffff) AM_RAM AM_SHARE("bg8.1") // Background 1
AM_RANGE(0x540000, 0x540001) AM_RAM AM_SHARE("bg8_scrollx.1") // Background 1 Scroll X
AM_RANGE(0x580000, 0x580001) AM_RAM AM_SHARE("bg8_scrolly.1") // Background 1 Scroll Y
-// AM_RANGE(0x5c0000, 0x5c0001) AM_WRITENOP // ? 0 at startup only
+// AM_RANGE(0x5c0000, 0x5c0001) AM_WRITENOP // ? 0 at startup only
AM_RANGE(0x540572, 0x540573) AM_READNOP // ? galpani2 at F0A4
AM_RANGE(0x54057a, 0x54057b) AM_READNOP // ? galpani2 at F148
@@ -411,10 +411,10 @@ static ADDRESS_MAP_START( galpani2_mem2, AS_PROGRAM, 16, galpani2_state )
AM_RANGE(0x000000, 0x03ffff) AM_ROM // ROM
AM_RANGE(0x100000, 0x13ffff) AM_RAM AM_SHARE("ram2") // Work RAM
AM_RANGE(0x400000, 0x5fffff) AM_RAM AM_SHARE("bg15") // bg15
-// AM_RANGE(0x600000, 0x600001) AM_NOP // ? 0 at startup only
-// AM_RANGE(0x640000, 0x640001) AM_WRITENOP // ? 0 at startup only
-// AM_RANGE(0x680000, 0x680001) AM_WRITENOP // ? 0 at startup only
-// AM_RANGE(0x6c0000, 0x6c0001) AM_WRITENOP // ? 0 at startup only
+// AM_RANGE(0x600000, 0x600001) AM_NOP // ? 0 at startup only
+// AM_RANGE(0x640000, 0x640001) AM_WRITENOP // ? 0 at startup only
+// AM_RANGE(0x680000, 0x680001) AM_WRITENOP // ? 0 at startup only
+// AM_RANGE(0x6c0000, 0x6c0001) AM_WRITENOP // ? 0 at startup only
AM_RANGE(0x700000, 0x700001) AM_NOP // Watchdog
// AM_RANGE(0x740000, 0x740001) AM_WRITENOP // ? Reset mcu
AM_RANGE(0x780000, 0x780001) AM_WRITE8(galpani2_mcu_nmi2_w, 0x00ff) // ? 0 -> 1 -> 0 (lev 5)
@@ -520,7 +520,7 @@ static INPUT_PORTS_START( galpani2 )
PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_PLAYER(2)
PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN )
PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN )
- PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_SERVICE2 ) // this button is used in gp2se as an alt way to bring up the service menu, booting with it held down breaks the game tho!
+ PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_SERVICE2 ) // this button is used in gp2se as an alt way to bring up the service menu, booting with it held down breaks the game tho!
PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_TILT )
PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_SERVICE1 )
diff --git a/src/mame/drivers/gts1.c b/src/mame/drivers/gts1.c
index 2e1da009e7f..91b5f7842fc 100644
--- a/src/mame/drivers/gts1.c
+++ b/src/mame/drivers/gts1.c
@@ -84,256 +84,256 @@ ToDo:
class gts1_state : public genpin_class
{
public:
- gts1_state(const machine_config &mconfig, device_type type, const char *tag)
- : genpin_class(mconfig, type, tag)
- , m_maincpu(*this, "maincpu")
- , m_switches(*this, "X")
- { }
-
- DECLARE_DRIVER_INIT(gts1);
-
- DECLARE_READ8_MEMBER (gts1_solenoid_r);
- DECLARE_WRITE8_MEMBER(gts1_solenoid_w);
- DECLARE_READ8_MEMBER (gts1_switches_r);
- DECLARE_WRITE8_MEMBER(gts1_switches_w);
- DECLARE_WRITE8_MEMBER(gts1_display_w);
- DECLARE_READ8_MEMBER (gts1_lamp_apm_r);
- DECLARE_WRITE8_MEMBER(gts1_lamp_apm_w);
- DECLARE_READ8_MEMBER (gts1_nvram_r);
- DECLARE_WRITE8_MEMBER(gts1_nvram_w);
- DECLARE_READ8_MEMBER (gts1_io_r);
- DECLARE_WRITE8_MEMBER(gts1_io_w);
- DECLARE_READ8_MEMBER (gts1_pa_r);
- DECLARE_WRITE8_MEMBER(gts1_pa_w);
- DECLARE_WRITE8_MEMBER(gts1_pb_w);
+ gts1_state(const machine_config &mconfig, device_type type, const char *tag)
+ : genpin_class(mconfig, type, tag)
+ , m_maincpu(*this, "maincpu")
+ , m_switches(*this, "X")
+ { }
+
+ DECLARE_DRIVER_INIT(gts1);
+
+ DECLARE_READ8_MEMBER (gts1_solenoid_r);
+ DECLARE_WRITE8_MEMBER(gts1_solenoid_w);
+ DECLARE_READ8_MEMBER (gts1_switches_r);
+ DECLARE_WRITE8_MEMBER(gts1_switches_w);
+ DECLARE_WRITE8_MEMBER(gts1_display_w);
+ DECLARE_READ8_MEMBER (gts1_lamp_apm_r);
+ DECLARE_WRITE8_MEMBER(gts1_lamp_apm_w);
+ DECLARE_READ8_MEMBER (gts1_nvram_r);
+ DECLARE_WRITE8_MEMBER(gts1_nvram_w);
+ DECLARE_READ8_MEMBER (gts1_io_r);
+ DECLARE_WRITE8_MEMBER(gts1_io_w);
+ DECLARE_READ8_MEMBER (gts1_pa_r);
+ DECLARE_WRITE8_MEMBER(gts1_pa_w);
+ DECLARE_WRITE8_MEMBER(gts1_pb_w);
private:
- virtual void machine_reset();
- required_device<cpu_device> m_maincpu;
- required_ioport_array<5> m_switches;
- UINT8 m_strobe; //!< switches strobe lines (5 lower bits used)
- UINT8 m_nvram_addr; //!< NVRAM address
- bool m_nvram_e2; //!< NVRWAM enable (E2 line)
- bool m_nvram_wr; //!< NVRWAM write (W/R line)
- UINT16 m_6351_addr; //!< ROM MM6351 address (12 bits)
- UINT16 m_z30_out; //!< 4-to-16 decoder outputs
+ virtual void machine_reset();
+ required_device<cpu_device> m_maincpu;
+ required_ioport_array<5> m_switches;
+ UINT8 m_strobe; //!< switches strobe lines (5 lower bits used)
+ UINT8 m_nvram_addr; //!< NVRAM address
+ bool m_nvram_e2; //!< NVRWAM enable (E2 line)
+ bool m_nvram_wr; //!< NVRWAM write (W/R line)
+ UINT16 m_6351_addr; //!< ROM MM6351 address (12 bits)
+ UINT16 m_z30_out; //!< 4-to-16 decoder outputs
};
static ADDRESS_MAP_START( gts1_map, AS_PROGRAM, 8, gts1_state )
- AM_RANGE(0x0000, 0x0fff) AM_ROM
+ AM_RANGE(0x0000, 0x0fff) AM_ROM
ADDRESS_MAP_END
static ADDRESS_MAP_START( gts1_data, AS_DATA, 8, gts1_state )
- AM_RANGE(0x0000, 0x00ff) AM_RAM
- AM_RANGE(0x0100, 0x01ff) AM_RAM AM_SHARE("nvram")
+ AM_RANGE(0x0000, 0x00ff) AM_RAM
+ AM_RANGE(0x0100, 0x01ff) AM_RAM AM_SHARE("nvram")
ADDRESS_MAP_END
static ADDRESS_MAP_START( gts1_io, AS_IO, 8, gts1_state )
- AM_RANGE(0x0020, 0x002f) AM_DEVREADWRITE ( "u4", ra17xx_device, io_r, io_w ) // (U4) solenoid
- AM_RANGE(0x0030, 0x003f) AM_DEVREADWRITE ( "u3", r10696_device, io_r, io_w ) // (U3) solenoid + dips
- AM_RANGE(0x0040, 0x004f) AM_DEVREADWRITE ( "u5", ra17xx_device, io_r, io_w ) // (U5) switch matrix
- AM_RANGE(0x0060, 0x006f) AM_DEVREADWRITE ( "u2", r10696_device, io_r, io_w ) // (U2) NVRAM io chip
- AM_RANGE(0x00d0, 0x00df) AM_DEVREADWRITE ( "u6", r10788_device, io_r, io_w ) // (U6) display chip
- AM_RANGE(0x0000, 0x00ff) AM_READ ( gts1_io_r ) AM_WRITE( gts1_io_w ) // catch undecoded I/O accesss
- AM_RANGE(0x0100, 0x0100) AM_READ ( gts1_pa_r ) AM_WRITE( gts1_pa_w ) // CPU I/O port A (input/output)
- AM_RANGE(0x0101, 0x0101) AM_WRITE( gts1_pb_w ) // CPU I/O port B (output only)
+ AM_RANGE(0x0020, 0x002f) AM_DEVREADWRITE ( "u4", ra17xx_device, io_r, io_w ) // (U4) solenoid
+ AM_RANGE(0x0030, 0x003f) AM_DEVREADWRITE ( "u3", r10696_device, io_r, io_w ) // (U3) solenoid + dips
+ AM_RANGE(0x0040, 0x004f) AM_DEVREADWRITE ( "u5", ra17xx_device, io_r, io_w ) // (U5) switch matrix
+ AM_RANGE(0x0060, 0x006f) AM_DEVREADWRITE ( "u2", r10696_device, io_r, io_w ) // (U2) NVRAM io chip
+ AM_RANGE(0x00d0, 0x00df) AM_DEVREADWRITE ( "u6", r10788_device, io_r, io_w ) // (U6) display chip
+ AM_RANGE(0x0000, 0x00ff) AM_READ ( gts1_io_r ) AM_WRITE( gts1_io_w ) // catch undecoded I/O accesss
+ AM_RANGE(0x0100, 0x0100) AM_READ ( gts1_pa_r ) AM_WRITE( gts1_pa_w ) // CPU I/O port A (input/output)
+ AM_RANGE(0x0101, 0x0101) AM_WRITE( gts1_pb_w ) // CPU I/O port B (output only)
ADDRESS_MAP_END
static INPUT_PORTS_START( gts1_dips )
- PORT_START("DSW0")
- PORT_DIPNAME( 0x01, 0x00, "S01")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x01, DEF_STR( On ))
- PORT_DIPNAME( 0x02, 0x00, "S02")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x02, DEF_STR( On ))
- PORT_DIPNAME( 0x04, 0x00, "S03")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x04, DEF_STR( On ))
- PORT_DIPNAME( 0x08, 0x00, "S04")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x08, DEF_STR( On ))
- PORT_DIPNAME( 0x10, 0x00, "S05")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x10, DEF_STR( On ))
- PORT_DIPNAME( 0x20, 0x20, "S06")
- PORT_DIPSETTING( 0x00, DEF_STR( No ))
- PORT_DIPSETTING( 0x20, DEF_STR( Yes ))
- PORT_DIPNAME( 0x40, 0x40, "S07")
- PORT_DIPSETTING( 0x00, DEF_STR( No ))
- PORT_DIPSETTING( 0x40, DEF_STR( Yes ))
- PORT_DIPNAME( 0x80, 0x80, "S08")
- PORT_DIPSETTING( 0x00, DEF_STR( No ))
- PORT_DIPSETTING( 0x80, DEF_STR( Yes ))
-
- PORT_START("DSW1")
- PORT_DIPNAME( 0x01, 0x00, "S09")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x01, DEF_STR( On ))
- PORT_DIPNAME( 0x02, 0x00, "S10")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x02, DEF_STR( On ))
- PORT_DIPNAME( 0x04, 0x00, "S11")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x04, DEF_STR( On ))
- PORT_DIPNAME( 0x08, 0x00, "S12")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x08, DEF_STR( On ))
- PORT_DIPNAME( 0x10, 0x00, "S13")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x10, DEF_STR( On ))
- PORT_DIPNAME( 0x20, 0x00, "S14")
- PORT_DIPSETTING( 0x00, DEF_STR( Yes ))
- PORT_DIPSETTING( 0x20, DEF_STR( No ))
- PORT_DIPNAME( 0x40, 0x40, "S15")
- PORT_DIPSETTING( 0x00, DEF_STR( No ))
- PORT_DIPSETTING( 0x40, DEF_STR( Yes ))
- PORT_DIPNAME( 0x80, 0x00, "S16")
- PORT_DIPSETTING( 0x00, DEF_STR( No ))
- PORT_DIPSETTING( 0x80, DEF_STR( Yes ))
-
- PORT_START("DSW2")
- PORT_DIPNAME( 0x01, 0x00, "S17")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x01, DEF_STR( On ))
- PORT_DIPNAME( 0x02, 0x00, "S18")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x02, DEF_STR( On ))
- PORT_DIPNAME( 0x04, 0x00, "S19")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x04, DEF_STR( On ))
- PORT_DIPNAME( 0x08, 0x00, "S20")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x08, DEF_STR( On ))
- PORT_DIPNAME( 0x10, 0x00, "S21")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x10, DEF_STR( On ))
- PORT_DIPNAME( 0x20, 0x00, "S22")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x20, DEF_STR( On ))
- PORT_DIPNAME( 0x40, 0x00, "S23")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x40, DEF_STR( On ))
- PORT_DIPNAME( 0x80, 0x00, "S24")
- PORT_DIPSETTING( 0x00, DEF_STR( Off ))
- PORT_DIPSETTING( 0x80, DEF_STR( On ))
+ PORT_START("DSW0")
+ PORT_DIPNAME( 0x01, 0x00, "S01")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x01, DEF_STR( On ))
+ PORT_DIPNAME( 0x02, 0x00, "S02")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x02, DEF_STR( On ))
+ PORT_DIPNAME( 0x04, 0x00, "S03")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x04, DEF_STR( On ))
+ PORT_DIPNAME( 0x08, 0x00, "S04")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x08, DEF_STR( On ))
+ PORT_DIPNAME( 0x10, 0x00, "S05")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x10, DEF_STR( On ))
+ PORT_DIPNAME( 0x20, 0x20, "S06")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ))
+ PORT_DIPSETTING( 0x20, DEF_STR( Yes ))
+ PORT_DIPNAME( 0x40, 0x40, "S07")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ))
+ PORT_DIPSETTING( 0x40, DEF_STR( Yes ))
+ PORT_DIPNAME( 0x80, 0x80, "S08")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ))
+ PORT_DIPSETTING( 0x80, DEF_STR( Yes ))
+
+ PORT_START("DSW1")
+ PORT_DIPNAME( 0x01, 0x00, "S09")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x01, DEF_STR( On ))
+ PORT_DIPNAME( 0x02, 0x00, "S10")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x02, DEF_STR( On ))
+ PORT_DIPNAME( 0x04, 0x00, "S11")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x04, DEF_STR( On ))
+ PORT_DIPNAME( 0x08, 0x00, "S12")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x08, DEF_STR( On ))
+ PORT_DIPNAME( 0x10, 0x00, "S13")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x10, DEF_STR( On ))
+ PORT_DIPNAME( 0x20, 0x00, "S14")
+ PORT_DIPSETTING( 0x00, DEF_STR( Yes ))
+ PORT_DIPSETTING( 0x20, DEF_STR( No ))
+ PORT_DIPNAME( 0x40, 0x40, "S15")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ))
+ PORT_DIPSETTING( 0x40, DEF_STR( Yes ))
+ PORT_DIPNAME( 0x80, 0x00, "S16")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ))
+ PORT_DIPSETTING( 0x80, DEF_STR( Yes ))
+
+ PORT_START("DSW2")
+ PORT_DIPNAME( 0x01, 0x00, "S17")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x01, DEF_STR( On ))
+ PORT_DIPNAME( 0x02, 0x00, "S18")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x02, DEF_STR( On ))
+ PORT_DIPNAME( 0x04, 0x00, "S19")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x04, DEF_STR( On ))
+ PORT_DIPNAME( 0x08, 0x00, "S20")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x08, DEF_STR( On ))
+ PORT_DIPNAME( 0x10, 0x00, "S21")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x10, DEF_STR( On ))
+ PORT_DIPNAME( 0x20, 0x00, "S22")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x20, DEF_STR( On ))
+ PORT_DIPNAME( 0x40, 0x00, "S23")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x40, DEF_STR( On ))
+ PORT_DIPNAME( 0x80, 0x00, "S24")
+ PORT_DIPSETTING( 0x00, DEF_STR( Off ))
+ PORT_DIPSETTING( 0x80, DEF_STR( On ))
INPUT_PORTS_END
static INPUT_PORTS_START( gts1_switches )
- PORT_START("X.0")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_START("X.1")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_START("X.2")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_START("X.3")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_START("X.4")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_START("X.0")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_START("X.1")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_START("X.2")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_START("X.3")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_START("X.4")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
INPUT_PORTS_END
static INPUT_PORTS_START( gts1 )
- PORT_INCLUDE( gts1_dips )
+ PORT_INCLUDE( gts1_dips )
- PORT_INCLUDE( gts1_switches )
+ PORT_INCLUDE( gts1_switches )
INPUT_PORTS_END
static INPUT_PORTS_START( jokrpokr )
- PORT_INCLUDE( gts1_dips )
-
- PORT_START("X.0")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("PLAY/TEST")
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("POP/BUMBER")
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("EXTRA BALL TARGET")
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("SPECIAL ROLLOVER")
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("10 POINT CONTACTS")
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (red)")
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
-
- PORT_START("X.1")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("#1 COIN CHUTE")
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" ROLLOVER")
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"10\" DROP TARGET")
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"Q\" DROP TARGET (red)")
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET (black)")
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (black)")
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
-
- PORT_START("X.2")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("#2 COIN CHUTE")
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"B\" ROLLOVER")
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"J\" DROP TARGET (black)")
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"O\" DROP TARGET (black)")
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET")
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("JOKER DROP TARGET")
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
-
- PORT_START("X.3")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("REPLAY BUTTON")
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"C\" ROLLOVER")
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"J\" DROP TARGET (red)")
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"O\" DROP TARGET (red)")
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET")
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (red)")
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
-
- PORT_START("X.4")
- PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("TILT PANEL")
- PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET")
- PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (red)")
- PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
- PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_INCLUDE( gts1_dips )
+
+ PORT_START("X.0")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("PLAY/TEST")
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("POP/BUMBER")
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("EXTRA BALL TARGET")
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("SPECIAL ROLLOVER")
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("10 POINT CONTACTS")
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (red)")
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+
+ PORT_START("X.1")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("#1 COIN CHUTE")
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" ROLLOVER")
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"10\" DROP TARGET")
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"Q\" DROP TARGET (red)")
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET (black)")
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (black)")
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+
+ PORT_START("X.2")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("#2 COIN CHUTE")
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"B\" ROLLOVER")
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"J\" DROP TARGET (black)")
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"O\" DROP TARGET (black)")
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET")
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("JOKER DROP TARGET")
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+
+ PORT_START("X.3")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("REPLAY BUTTON")
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"C\" ROLLOVER")
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"J\" DROP TARGET (red)")
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"O\" DROP TARGET (red)")
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET")
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (red)")
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
+
+ PORT_START("X.4")
+ PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("TILT PANEL")
+ PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"K\" DROP TARGET")
+ PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_OTHER) PORT_NAME("\"A\" DROP TARGET (red)")
+ PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_OTHER)
+ PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_OTHER)
INPUT_PORTS_END
void gts1_state::machine_reset()
{
- m_strobe = 0;
- m_nvram_addr = 0;
- m_nvram_e2 = false;
- m_nvram_wr = false;
- m_6351_addr = 0;
- m_z30_out = 0;
+ m_strobe = 0;
+ m_nvram_addr = 0;
+ m_nvram_e2 = false;
+ m_nvram_wr = false;
+ m_6351_addr = 0;
+ m_z30_out = 0;
}
DRIVER_INIT_MEMBER(gts1_state,gts1)
@@ -342,81 +342,81 @@ DRIVER_INIT_MEMBER(gts1_state,gts1)
READ8_MEMBER (gts1_state::gts1_solenoid_r)
{
- UINT8 data = 0;
- LOG(("%s: solenoid[%02x] -> %x\n", __FUNCTION__, offset, data));
- return data;
+ UINT8 data = 0;
+ LOG(("%s: solenoid[%02x] -> %x\n", __FUNCTION__, offset, data));
+ return data;
}
WRITE8_MEMBER(gts1_state::gts1_solenoid_w)
{
- switch (offset)
- {
- case 0:
- LOG(("%s: outhole <- %x\n", __FUNCTION__, data));
- break;
- case 1:
- LOG(("%s: knocker <- %x\n", __FUNCTION__, data));
- break;
- case 2:
- LOG(("%s: tens chime <- %x\n", __FUNCTION__, data));
- break;
- case 3:
- LOG(("%s: hundreds chime <- %x\n", __FUNCTION__, data));
- break;
- case 4:
- LOG(("%s: thousands chime <- %x\n", __FUNCTION__, data));
- break;
- case 5:
- LOG(("%s: no. 6 <- %x\n", __FUNCTION__, data));
- break;
- case 6:
- LOG(("%s: no. 7 <- %x\n", __FUNCTION__, data));
- break;
- case 7:
- LOG(("%s: no. 8 <- %x\n", __FUNCTION__, data));
- break;
- case 8: case 9: case 10: case 11:
- LOG(("%s: not used [%x] <- %x\n", __FUNCTION__, offset, data));
- break;
- case 12: // spare
- LOG(("%s: spare [%x] <- %x\n", __FUNCTION__, offset, data));
- break;
- case 13: // RAM control E2
- LOG(("%s: RAM control E2 <- %x\n", __FUNCTION__, data));
- m_nvram_e2 = (data & 1) ? true : false;
- break;
- case 14: // RAM control W/R
- LOG(("%s: RAM control W/R <- %x\n", __FUNCTION__, data));
- break;
- m_nvram_wr = (data & 1) ? true : false;
- case 15: // spare
- LOG(("%s: spare [%x] <- %x\n", __FUNCTION__, offset, data));
- break;
- }
+ switch (offset)
+ {
+ case 0:
+ LOG(("%s: outhole <- %x\n", __FUNCTION__, data));
+ break;
+ case 1:
+ LOG(("%s: knocker <- %x\n", __FUNCTION__, data));
+ break;
+ case 2:
+ LOG(("%s: tens chime <- %x\n", __FUNCTION__, data));
+ break;
+ case 3:
+ LOG(("%s: hundreds chime <- %x\n", __FUNCTION__, data));
+ break;
+ case 4:
+ LOG(("%s: thousands chime <- %x\n", __FUNCTION__, data));
+ break;
+ case 5:
+ LOG(("%s: no. 6 <- %x\n", __FUNCTION__, data));
+ break;
+ case 6:
+ LOG(("%s: no. 7 <- %x\n", __FUNCTION__, data));
+ break;
+ case 7:
+ LOG(("%s: no. 8 <- %x\n", __FUNCTION__, data));
+ break;
+ case 8: case 9: case 10: case 11:
+ LOG(("%s: not used [%x] <- %x\n", __FUNCTION__, offset, data));
+ break;
+ case 12: // spare
+ LOG(("%s: spare [%x] <- %x\n", __FUNCTION__, offset, data));
+ break;
+ case 13: // RAM control E2
+ LOG(("%s: RAM control E2 <- %x\n", __FUNCTION__, data));
+ m_nvram_e2 = (data & 1) ? true : false;
+ break;
+ case 14: // RAM control W/R
+ LOG(("%s: RAM control W/R <- %x\n", __FUNCTION__, data));
+ break;
+ m_nvram_wr = (data & 1) ? true : false;
+ case 15: // spare
+ LOG(("%s: spare [%x] <- %x\n", __FUNCTION__, offset, data));
+ break;
+ }
}
READ8_MEMBER (gts1_state::gts1_switches_r)
{
- UINT8 data = 1;
- if (offset >= 8 && offset < 16) {
- const int bit = offset - 8;
- for (int i = 0; i < 5; i++) {
- if (m_strobe & (1 << i)) {
- data &= BIT(m_switches[i]->read(), bit);
- }
- }
- }
- LOG(("%s: switches[%x,%x] -> %x\n", __FUNCTION__, m_strobe, offset, data));
- return data;
+ UINT8 data = 1;
+ if (offset >= 8 && offset < 16) {
+ const int bit = offset - 8;
+ for (int i = 0; i < 5; i++) {
+ if (m_strobe & (1 << i)) {
+ data &= BIT(m_switches[i]->read(), bit);
+ }
+ }
+ }
+ LOG(("%s: switches[%x,%x] -> %x\n", __FUNCTION__, m_strobe, offset, data));
+ return data;
}
WRITE8_MEMBER(gts1_state::gts1_switches_w)
{
- LOG(("%s: switches[%x] <- %x\n", __FUNCTION__, offset, data));
- if (offset < 5) {
- // outputs O-0 to O-4 are the 5 strobe lines
- m_strobe = (m_strobe & ~(1 << offset)) | ((data & 1) << offset);
- }
+ LOG(("%s: switches[%x] <- %x\n", __FUNCTION__, offset, data));
+ if (offset < 5) {
+ // outputs O-0 to O-4 are the 5 strobe lines
+ m_strobe = (m_strobe & ~(1 << offset)) | ((data & 1) << offset);
+ }
}
/**
@@ -426,11 +426,11 @@ WRITE8_MEMBER(gts1_state::gts1_switches_w)
*/
WRITE8_MEMBER(gts1_state::gts1_display_w)
{
- /*
- * The 7448 is modified to be disabled through RI/RBO
- * when the input is 0001, and in this case the extra
- * output H is generated instead.
- */
+ /*
+ * The 7448 is modified to be disabled through RI/RBO
+ * when the input is 0001, and in this case the extra
+ * output H is generated instead.
+ */
#define _a (1 << 0)
#define _b (1 << 1)
#define _c (1 << 2)
@@ -439,43 +439,43 @@ WRITE8_MEMBER(gts1_state::gts1_display_w)
#define _f (1 << 5)
#define _g (1 << 6)
#define _h (1 << 7)
- static const UINT8 ttl7448_mod[16] = {
- /* 0 */ _a | _b | _c | _d | _e | _f,
- /* 1 */ _h,
- /* 2 */ _a | _b | _d | _e | _g,
- /* 3 */ _a | _b | _c | _d | _g,
- /* 4 */ _b | _c | _f | _g,
- /* 5 */ _a | _c | _d | _f | _g,
- /* 6 */ _a | _c | _d | _e | _f | _g,
- /* 7 */ _a | _b | _c,
- /* 8 */ _a | _b | _c | _d | _e | _f | _g,
- /* 9 */ _a | _b | _c | _d | _f | _g,
- /* a */ _d | _e | _g,
- /* b */ _c | _d | _g,
- /* c */ _b | _f | _g,
- /* d */ _a | _d | _f | _g,
- /* e */ _d | _e | _f | _g,
- /* f */ 0
- };
- UINT8 a = ttl7448_mod[(data >> 0) & 15];
- UINT8 b = ttl7448_mod[(data >> 4) & 15];
- // LOG(("%s: offset:%d data:%02x a:%02x b:%02x\n", __FUNCTION__, offset, data, a, b));
- if ((offset % 8) < 7) {
- output_set_indexed_value("digit8_", offset, a);
- output_set_indexed_value("digit8_", offset + 16, b);
- } else {
- /*
- * For the 4 7-seg displays the segment h is turned back into
- * segments b and c to display the 7-seg "1".
- */
- if (a & _h)
- a = _b | _c;
- if (b & _h)
- b = _b | _c;
- output_set_indexed_value("digit7_", offset, a);
- // FIXME: there is nothing on outputs 22, 23, 30 and 31?
- output_set_indexed_value("digit7_", offset + 16, b);
- }
+ static const UINT8 ttl7448_mod[16] = {
+ /* 0 */ _a | _b | _c | _d | _e | _f,
+ /* 1 */ _h,
+ /* 2 */ _a | _b | _d | _e | _g,
+ /* 3 */ _a | _b | _c | _d | _g,
+ /* 4 */ _b | _c | _f | _g,
+ /* 5 */ _a | _c | _d | _f | _g,
+ /* 6 */ _a | _c | _d | _e | _f | _g,
+ /* 7 */ _a | _b | _c,
+ /* 8 */ _a | _b | _c | _d | _e | _f | _g,
+ /* 9 */ _a | _b | _c | _d | _f | _g,
+ /* a */ _d | _e | _g,
+ /* b */ _c | _d | _g,
+ /* c */ _b | _f | _g,
+ /* d */ _a | _d | _f | _g,
+ /* e */ _d | _e | _f | _g,
+ /* f */ 0
+ };
+ UINT8 a = ttl7448_mod[(data >> 0) & 15];
+ UINT8 b = ttl7448_mod[(data >> 4) & 15];
+ // LOG(("%s: offset:%d data:%02x a:%02x b:%02x\n", __FUNCTION__, offset, data, a, b));
+ if ((offset % 8) < 7) {
+ output_set_indexed_value("digit8_", offset, a);
+ output_set_indexed_value("digit8_", offset + 16, b);
+ } else {
+ /*
+ * For the 4 7-seg displays the segment h is turned back into
+ * segments b and c to display the 7-seg "1".
+ */
+ if (a & _h)
+ a = _b | _c;
+ if (b & _h)
+ b = _b | _c;
+ output_set_indexed_value("digit7_", offset, a);
+ // FIXME: there is nothing on outputs 22, 23, 30 and 31?
+ output_set_indexed_value("digit7_", offset + 16, b);
+ }
#undef _a
#undef _b
#undef _c
@@ -493,24 +493,24 @@ WRITE8_MEMBER(gts1_state::gts1_display_w)
*/
READ8_MEMBER (gts1_state::gts1_nvram_r)
{
- UINT8 data = 0x0f;
- switch (offset)
- {
- case 0: // group A
- // FIXME: Schematics says TO Z5
- if (!m_nvram_wr && m_nvram_e2) {
- UINT8* nvram = memregion("nvram")->base();
- assert(nvram != NULL);
- data = nvram[m_nvram_addr];
- LOG(("%s: nvram[%02x] -> %x\n", __FUNCTION__, m_nvram_addr, data));
- }
- break;
- case 1: // group B
- case 2: // group C
- // Schematics says: SPARES
- break;
- }
- return data;
+ UINT8 data = 0x0f;
+ switch (offset)
+ {
+ case 0: // group A
+ // FIXME: Schematics says TO Z5
+ if (!m_nvram_wr && m_nvram_e2) {
+ UINT8* nvram = memregion("nvram")->base();
+ assert(nvram != NULL);
+ data = nvram[m_nvram_addr];
+ LOG(("%s: nvram[%02x] -> %x\n", __FUNCTION__, m_nvram_addr, data));
+ }
+ break;
+ case 1: // group B
+ case 2: // group C
+ // Schematics says: SPARES
+ break;
+ }
+ return data;
}
/**
@@ -520,23 +520,23 @@ READ8_MEMBER (gts1_state::gts1_nvram_r)
*/
WRITE8_MEMBER(gts1_state::gts1_nvram_w)
{
- switch (offset)
- {
- case 0: // group A - address lines 3:0
- m_nvram_addr = (m_nvram_addr & ~15) | (data & 15);
- break;
- case 1: // group B - address lines 7:4
- m_nvram_addr = (m_nvram_addr & ~(15 << 4)) | ((data & 15) << 4);
- break;
- case 2: // group C - data bits 3:0 of NVRAM
- if (m_nvram_wr && m_nvram_e2) {
- LOG(("%s: nvram[%02x] <- %x\n", __FUNCTION__, m_nvram_addr, data & 15));
- UINT8* nvram = memregion("nvram")->base();
- assert(nvram != NULL);
- nvram[m_nvram_addr] = data & 15;
- }
- break;
- }
+ switch (offset)
+ {
+ case 0: // group A - address lines 3:0
+ m_nvram_addr = (m_nvram_addr & ~15) | (data & 15);
+ break;
+ case 1: // group B - address lines 7:4
+ m_nvram_addr = (m_nvram_addr & ~(15 << 4)) | ((data & 15) << 4);
+ break;
+ case 2: // group C - data bits 3:0 of NVRAM
+ if (m_nvram_wr && m_nvram_e2) {
+ LOG(("%s: nvram[%02x] <- %x\n", __FUNCTION__, m_nvram_addr, data & 15));
+ UINT8* nvram = memregion("nvram")->base();
+ assert(nvram != NULL);
+ nvram[m_nvram_addr] = data & 15;
+ }
+ break;
+ }
}
/**
@@ -546,86 +546,86 @@ WRITE8_MEMBER(gts1_state::gts1_nvram_w)
*/
READ8_MEMBER (gts1_state::gts1_lamp_apm_r)
{
- UINT8 data = 0x0f;
- switch (offset) {
- case 0: // group A switches S01-S04, S09-S12, S17-S20
- if (m_z30_out & 1) {
- UINT8 dsw0 = ioport("DSW0")->read();
- if (0 == BIT(dsw0,0)) // S01
- data &= ~(1 << 3);
- if (0 == BIT(dsw0,1)) // S02
- data &= ~(1 << 2);
- if (0 == BIT(dsw0,2)) // S03
- data &= ~(1 << 1);
- if (0 == BIT(dsw0,3)) // S04
- data &= ~(1 << 0);
- }
- if (m_z30_out & 2) {
- UINT8 dsw1 = ioport("DSW1")->read();
- if (0 == BIT(dsw1,0)) // S09
- data &= ~(1 << 0);
- if (0 == BIT(dsw1,1)) // S10
- data &= ~(1 << 1);
- if (0 == BIT(dsw1,2)) // S11
- data &= ~(1 << 2);
- if (0 == BIT(dsw1,3)) // S12
- data &= ~(1 << 3);
- }
- if (m_z30_out & 4) {
- UINT8 dsw2 = ioport("DSW2")->read();
- if (0 == BIT(dsw2,0)) // S17
- data &= ~(1 << 0);
- if (0 == BIT(dsw2,1)) // S18
- data &= ~(1 << 1);
- if (0 == BIT(dsw2,2)) // S19
- data &= ~(1 << 2);
- if (0 == BIT(dsw2,3)) // S20
- data &= ~(1 << 3);
- }
- break;
- case 1: // group B switches S05-S08, S09-S12, S17-S20
- if (m_z30_out & 1) {
- UINT8 dsw0 = ioport("DSW0")->read();
- if (0 == BIT(dsw0,4)) // S05
- data &= ~(1 << 3);
- if (0 == BIT(dsw0,5)) // S06
- data &= ~(1 << 2);
- if (0 == BIT(dsw0,6)) // S07
- data &= ~(1 << 1);
- if (0 == BIT(dsw0,7)) // S08
- data &= ~(1 << 0);
- }
- if (m_z30_out & 2) {
- UINT8 dsw1 = ioport("DSW1")->read();
- if (0 == BIT(dsw1,4)) // S13
- data &= ~(1 << 0);
- if (0 == BIT(dsw1,5)) // S14
- data &= ~(1 << 1);
- if (0 == BIT(dsw1,6)) // S15
- data &= ~(1 << 2);
- if (0 == BIT(dsw1,7)) // S16
- data &= ~(1 << 3);
- }
- if (m_z30_out & 4) {
- UINT8 dsw2 = ioport("DSW2")->read();
- if (0 == BIT(dsw2,4)) // S21
- data &= ~(1 << 0);
- if (0 == BIT(dsw2,5)) // S22
- data &= ~(1 << 1);
- if (0 == BIT(dsw2,6)) // S23
- data &= ~(1 << 2);
- if (0 == BIT(dsw2,7)) // S24
- data &= ~(1 << 3);
- }
- break;
- case 2: // TODO: connect
- // IN-9 (unused?)
- // IN-10 (reset sw25)
- // IN-11 (outhole sw)
- // IN-12 (slam sw)
- break;
- }
- return data;
+ UINT8 data = 0x0f;
+ switch (offset) {
+ case 0: // group A switches S01-S04, S09-S12, S17-S20
+ if (m_z30_out & 1) {
+ UINT8 dsw0 = ioport("DSW0")->read();
+ if (0 == BIT(dsw0,0)) // S01
+ data &= ~(1 << 3);
+ if (0 == BIT(dsw0,1)) // S02
+ data &= ~(1 << 2);
+ if (0 == BIT(dsw0,2)) // S03
+ data &= ~(1 << 1);
+ if (0 == BIT(dsw0,3)) // S04
+ data &= ~(1 << 0);
+ }
+ if (m_z30_out & 2) {
+ UINT8 dsw1 = ioport("DSW1")->read();
+ if (0 == BIT(dsw1,0)) // S09
+ data &= ~(1 << 0);
+ if (0 == BIT(dsw1,1)) // S10
+ data &= ~(1 << 1);
+ if (0 == BIT(dsw1,2)) // S11
+ data &= ~(1 << 2);
+ if (0 == BIT(dsw1,3)) // S12
+ data &= ~(1 << 3);
+ }
+ if (m_z30_out & 4) {
+ UINT8 dsw2 = ioport("DSW2")->read();
+ if (0 == BIT(dsw2,0)) // S17
+ data &= ~(1 << 0);
+ if (0 == BIT(dsw2,1)) // S18
+ data &= ~(1 << 1);
+ if (0 == BIT(dsw2,2)) // S19
+ data &= ~(1 << 2);
+ if (0 == BIT(dsw2,3)) // S20
+ data &= ~(1 << 3);
+ }
+ break;
+ case 1: // group B switches S05-S08, S09-S12, S17-S20
+ if (m_z30_out & 1) {
+ UINT8 dsw0 = ioport("DSW0")->read();
+ if (0 == BIT(dsw0,4)) // S05
+ data &= ~(1 << 3);
+ if (0 == BIT(dsw0,5)) // S06
+ data &= ~(1 << 2);
+ if (0 == BIT(dsw0,6)) // S07
+ data &= ~(1 << 1);
+ if (0 == BIT(dsw0,7)) // S08
+ data &= ~(1 << 0);
+ }
+ if (m_z30_out & 2) {
+ UINT8 dsw1 = ioport("DSW1")->read();
+ if (0 == BIT(dsw1,4)) // S13
+ data &= ~(1 << 0);
+ if (0 == BIT(dsw1,5)) // S14
+ data &= ~(1 << 1);
+ if (0 == BIT(dsw1,6)) // S15
+ data &= ~(1 << 2);
+ if (0 == BIT(dsw1,7)) // S16
+ data &= ~(1 << 3);
+ }
+ if (m_z30_out & 4) {
+ UINT8 dsw2 = ioport("DSW2")->read();
+ if (0 == BIT(dsw2,4)) // S21
+ data &= ~(1 << 0);
+ if (0 == BIT(dsw2,5)) // S22
+ data &= ~(1 << 1);
+ if (0 == BIT(dsw2,6)) // S23
+ data &= ~(1 << 2);
+ if (0 == BIT(dsw2,7)) // S24
+ data &= ~(1 << 3);
+ }
+ break;
+ case 2: // TODO: connect
+ // IN-9 (unused?)
+ // IN-10 (reset sw25)
+ // IN-11 (outhole sw)
+ // IN-12 (slam sw)
+ break;
+ }
+ return data;
}
/**
@@ -635,210 +635,210 @@ READ8_MEMBER (gts1_state::gts1_lamp_apm_r)
*/
WRITE8_MEMBER(gts1_state::gts1_lamp_apm_w)
{
- switch (offset) {
- case 0: // LD1-LD4 on jumper J5
- break;
- case 1: // Z30 1-of-16 decoder
- m_z30_out = 1 << (data & 15);
- break;
- case 2: // O9: PGOL PROM A8, O10: PGOL PROM A9
- m_6351_addr = (m_6351_addr & ~(3 << 8)) | ((data & 3) << 8);
- // O11 and O12 are unused(?)
- break;
- }
+ switch (offset) {
+ case 0: // LD1-LD4 on jumper J5
+ break;
+ case 1: // Z30 1-of-16 decoder
+ m_z30_out = 1 << (data & 15);
+ break;
+ case 2: // O9: PGOL PROM A8, O10: PGOL PROM A9
+ m_6351_addr = (m_6351_addr & ~(3 << 8)) | ((data & 3) << 8);
+ // O11 and O12 are unused(?)
+ break;
+ }
}
READ8_MEMBER (gts1_state::gts1_io_r)
{
- const UINT8 data = 0x0f;
- LOG(("%s: unmapped io[%02x] -> %x\n", __FUNCTION__, offset, data));
- return data;
+ const UINT8 data = 0x0f;
+ LOG(("%s: unmapped io[%02x] -> %x\n", __FUNCTION__, offset, data));
+ return data;
}
WRITE8_MEMBER(gts1_state::gts1_io_w)
{
- LOG(("%s: unmapped io[%02x] <- %x\n", __FUNCTION__, offset, data));
+ LOG(("%s: unmapped io[%02x] <- %x\n", __FUNCTION__, offset, data));
}
READ8_MEMBER (gts1_state::gts1_pa_r)
{
- // return ROM nibble
- UINT8 *ROM = memregion("maincpu")->base();
- UINT8 data = ROM[0x2000 + m_6351_addr] & 0x0f;
- LOG(("%s: ROM[%03x]:%02x\n", __FUNCTION__, m_6351_addr, data));
- return data;
+ // return ROM nibble
+ UINT8 *ROM = memregion("maincpu")->base();
+ UINT8 data = ROM[0x2000 + m_6351_addr] & 0x0f;
+ LOG(("%s: ROM[%03x]:%02x\n", __FUNCTION__, m_6351_addr, data));
+ return data;
}
WRITE8_MEMBER(gts1_state::gts1_pa_w)
{
- // write address lines 7-4
- m_6351_addr = (m_6351_addr & 0x0f) | ((data & 0x0f) << 4);
- LOG(("%s: ROM hi:%x addr:%02x\n", __FUNCTION__, data & 0x0f, m_6351_addr));
+ // write address lines 7-4
+ m_6351_addr = (m_6351_addr & 0x0f) | ((data & 0x0f) << 4);
+ LOG(("%s: ROM hi:%x addr:%02x\n", __FUNCTION__, data & 0x0f, m_6351_addr));
}
WRITE8_MEMBER(gts1_state::gts1_pb_w)
{
- // write address lines 3-0
- m_6351_addr = (m_6351_addr & 0xf0) | (data & 0x0f);
- LOG(("%s: ROM lo:%x addr:%02x\n", __FUNCTION__, data & 0x0f, m_6351_addr));
+ // write address lines 3-0
+ m_6351_addr = (m_6351_addr & 0xf0) | (data & 0x0f);
+ LOG(("%s: ROM lo:%x addr:%02x\n", __FUNCTION__, data & 0x0f, m_6351_addr));
}
static MACHINE_CONFIG_START( gts1, gts1_state )
- /* basic machine hardware */
- MCFG_CPU_ADD("maincpu", PPS4, XTAL_3_579545MHz / 18) // divided in the CPU
- MCFG_CPU_PROGRAM_MAP(gts1_map)
- MCFG_CPU_DATA_MAP(gts1_data)
- MCFG_CPU_IO_MAP(gts1_io)
-
- MCFG_NVRAM_ADD_0FILL("nvram")
-
- /* A1753CE 2048 x 8 ROM (000-7ff), 128 x 4 RAM (00-7f) and 16 I/O lines (20 ... 2f) */
- MCFG_DEVICE_ADD( "u5", RA17XX, 0 )
- MCFG_RA17XX_READ ( READ8 (gts1_state,gts1_switches_r) )
- MCFG_RA17XX_WRITE( WRITE8(gts1_state,gts1_switches_w) )
-
- /* A1752CF 2048 x 8 ROM (800-fff), 128 x 4 RAM (80-ff) and 16 I/O lines (40 ... 4f) */
- MCFG_DEVICE_ADD( "u4", RA17XX, 0 )
- MCFG_RA17XX_READ ( READ8 (gts1_state,gts1_solenoid_r) )
- MCFG_RA17XX_WRITE( WRITE8(gts1_state,gts1_solenoid_w) )
-
- /* 10696 General Purpose Input/Output */
- MCFG_DEVICE_ADD( "u2", R10696, 0 )
- MCFG_R10696_IO( READ8 (gts1_state,gts1_nvram_r),
- WRITE8(gts1_state,gts1_nvram_w) )
-
- /* 10696 General Purpose Input/Output */
- MCFG_DEVICE_ADD( "u3", R10696, 0 )
- MCFG_R10696_IO( READ8 (gts1_state,gts1_lamp_apm_r),
- WRITE8(gts1_state,gts1_lamp_apm_w) )
-
- /* 10788 General Purpose Display and Keyboard */
- MCFG_DEVICE_ADD( "u6", R10788, XTAL_3_579545MHz / 18 ) // divided in the circuit
- MCFG_R10788_UPDATE( WRITE8(gts1_state,gts1_display_w) )
-
- /* Video */
- MCFG_DEFAULT_LAYOUT( layout_gts1 )
-
- /* Sound */
- MCFG_FRAGMENT_ADD( genpin_audio )
+ /* basic machine hardware */
+ MCFG_CPU_ADD("maincpu", PPS4, XTAL_3_579545MHz / 18) // divided in the CPU
+ MCFG_CPU_PROGRAM_MAP(gts1_map)
+ MCFG_CPU_DATA_MAP(gts1_data)
+ MCFG_CPU_IO_MAP(gts1_io)
+
+ MCFG_NVRAM_ADD_0FILL("nvram")
+
+ /* A1753CE 2048 x 8 ROM (000-7ff), 128 x 4 RAM (00-7f) and 16 I/O lines (20 ... 2f) */
+ MCFG_DEVICE_ADD( "u5", RA17XX, 0 )
+ MCFG_RA17XX_READ ( READ8 (gts1_state,gts1_switches_r) )
+ MCFG_RA17XX_WRITE( WRITE8(gts1_state,gts1_switches_w) )
+
+ /* A1752CF 2048 x 8 ROM (800-fff), 128 x 4 RAM (80-ff) and 16 I/O lines (40 ... 4f) */
+ MCFG_DEVICE_ADD( "u4", RA17XX, 0 )
+ MCFG_RA17XX_READ ( READ8 (gts1_state,gts1_solenoid_r) )
+ MCFG_RA17XX_WRITE( WRITE8(gts1_state,gts1_solenoid_w) )
+
+ /* 10696 General Purpose Input/Output */
+ MCFG_DEVICE_ADD( "u2", R10696, 0 )
+ MCFG_R10696_IO( READ8 (gts1_state,gts1_nvram_r),
+ WRITE8(gts1_state,gts1_nvram_w) )
+
+ /* 10696 General Purpose Input/Output */
+ MCFG_DEVICE_ADD( "u3", R10696, 0 )
+ MCFG_R10696_IO( READ8 (gts1_state,gts1_lamp_apm_r),
+ WRITE8(gts1_state,gts1_lamp_apm_w) )
+
+ /* 10788 General Purpose Display and Keyboard */
+ MCFG_DEVICE_ADD( "u6", R10788, XTAL_3_579545MHz / 18 ) // divided in the circuit
+ MCFG_R10788_UPDATE( WRITE8(gts1_state,gts1_display_w) )
+
+ /* Video */
+ MCFG_DEFAULT_LAYOUT( layout_gts1 )
+
+ /* Sound */
+ MCFG_FRAGMENT_ADD( genpin_audio )
MACHINE_CONFIG_END
ROM_START( gts1 )
- ROM_REGION( 0x10000, "maincpu", 0 )
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
ROM_END
ROM_START( gts1s )
- ROM_REGION( 0x10000, "maincpu", 0 )
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
ROM_END
/*-------------------------------------------------------------------
/ Asteroid Annie and the Aliens (12/1980) #442
/-------------------------------------------------------------------*/
ROM_START(astannie)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("442.cpu", 0x2000, 0x0400, CRC(579521e0) SHA1(b1b19473e1ca3373955ee96104b87f586c4c311c))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("442.snd", 0x0400, 0x0400, CRC(c70195b4) SHA1(ff06197f07111d6a4b8942dcfe8d2279bda6f281))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("442.cpu", 0x2000, 0x0400, CRC(579521e0) SHA1(b1b19473e1ca3373955ee96104b87f586c4c311c))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("442.snd", 0x0400, 0x0400, CRC(c70195b4) SHA1(ff06197f07111d6a4b8942dcfe8d2279bda6f281))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
/ Buck Rogers (01/1980) #437
/-------------------------------------------------------------------*/
ROM_START(buckrgrs)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("437.cpu", 0x2000, 0x0400, CRC(e57d9278) SHA1(dfc4ebff1e14b9a074468671a8e5ac7948d5b352))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("437.snd", 0x0400, 0x0400, CRC(732b5a27) SHA1(7860ea54e75152246c3ac3205122d750b243b40c))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("437.cpu", 0x2000, 0x0400, CRC(e57d9278) SHA1(dfc4ebff1e14b9a074468671a8e5ac7948d5b352))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("437.snd", 0x0400, 0x0400, CRC(732b5a27) SHA1(7860ea54e75152246c3ac3205122d750b243b40c))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
/ Charlie's Angels (11/1978) #425
/-------------------------------------------------------------------*/
ROM_START(charlies)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("425.cpu", 0x2000, 0x0400, CRC(928b4279) SHA1(51096d45e880d6a8263eaeaa0cdab0f61ad2f58d))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("425.cpu", 0x2000, 0x0400, CRC(928b4279) SHA1(51096d45e880d6a8263eaeaa0cdab0f61ad2f58d))
ROM_END
/*-------------------------------------------------------------------
/ Cleopatra (11/1977) #409
/-------------------------------------------------------------------*/
ROM_START(cleoptra)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("409.cpu", 0x2000, 0x0400, CRC(8063ff71) SHA1(205f09f067bf79544d2ce2a48d23259901f935dd))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("409.cpu", 0x2000, 0x0400, CRC(8063ff71) SHA1(205f09f067bf79544d2ce2a48d23259901f935dd))
ROM_END
/*-------------------------------------------------------------------
/ Close Encounters of the Third Kind (10/1978) #424
/-------------------------------------------------------------------*/
ROM_START(closeenc)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("424.cpu", 0x2000, 0x0400, CRC(a7a5dd13) SHA1(223c67b9484baa719c91de52b363ff22813db160))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("424.cpu", 0x2000, 0x0400, CRC(a7a5dd13) SHA1(223c67b9484baa719c91de52b363ff22813db160))
ROM_END
/*-------------------------------------------------------------------
/ Count-Down (05/1979) #422
/-------------------------------------------------------------------*/
ROM_START(countdwn)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("422.cpu", 0x2000, 0x0400, CRC(51bc2df0) SHA1(d4b555d106c6b4e420b0fcd1df8871f869476c22))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("422.cpu", 0x2000, 0x0400, CRC(51bc2df0) SHA1(d4b555d106c6b4e420b0fcd1df8871f869476c22))
ROM_END
/*-------------------------------------------------------------------
/ Dragon (10/1978) #419
/-------------------------------------------------------------------*/
ROM_START(dragon)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("419.cpu", 0x2000, 0x0400, CRC(018d9b3a) SHA1(da37ef5017c71bc41bdb1f30d3fd7ac3b7e1ee7e))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("419.cpu", 0x2000, 0x0400, CRC(018d9b3a) SHA1(da37ef5017c71bc41bdb1f30d3fd7ac3b7e1ee7e))
ROM_END
/*-------------------------------------------------------------------
/ Genie (11/1979) #435
/-------------------------------------------------------------------*/
ROM_START(geniep)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("435.cpu", 0x2000, 0x0400, CRC(7749fd92) SHA1(9cd3e799842392e3939877bf295759c27f199e58))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("435.snd", 0x0400, 0x0400, CRC(4a98ceed) SHA1(f1d7548e03107033c39953ee04b043b5301dbb47))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("435.cpu", 0x2000, 0x0400, CRC(7749fd92) SHA1(9cd3e799842392e3939877bf295759c27f199e58))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("435.snd", 0x0400, 0x0400, CRC(4a98ceed) SHA1(f1d7548e03107033c39953ee04b043b5301dbb47))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
/ Joker Poker (08/1978) #417
/-------------------------------------------------------------------*/
ROM_START(jokrpokr)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("417.cpu", 0x2000, 0x0400, CRC(33dade08) SHA1(23b8dbd7b6c84b806fc0d2da95478235cbf9f80a))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("417.cpu", 0x2000, 0x0400, CRC(33dade08) SHA1(23b8dbd7b6c84b806fc0d2da95478235cbf9f80a))
ROM_END
/*-------------------------------------------------------------------
@@ -848,12 +848,12 @@ ROM_END
/ L'Hexagone (04/1986)
/-------------------------------------------------------------------*/
ROM_START(hexagone)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("435.cpu", 0x2000, 0x0400, CRC(7749fd92) SHA1(9cd3e799842392e3939877bf295759c27f199e58))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("hexagone.bin", 0, 0x4000, CRC(002b5464) SHA1(e2d971c4e85b4fb6580c2d3945c9946ea0cebc2e))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("435.cpu", 0x2000, 0x0400, CRC(7749fd92) SHA1(9cd3e799842392e3939877bf295759c27f199e58))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("hexagone.bin", 0, 0x4000, CRC(002b5464) SHA1(e2d971c4e85b4fb6580c2d3945c9946ea0cebc2e))
ROM_END
/*-------------------------------------------------------------------
/ Movie
@@ -863,25 +863,25 @@ ROM_END
/ Pinball Pool (08/1979) #427
/-------------------------------------------------------------------*/
ROM_START(pinpool)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("427.cpu", 0x2000, 0x0400, CRC(c496393d) SHA1(e91d9596aacdb4277fa200a3f8f9da099c278f32))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("427.cpu", 0x2000, 0x0400, CRC(c496393d) SHA1(e91d9596aacdb4277fa200a3f8f9da099c278f32))
ROM_END
/*-------------------------------------------------------------------
/ Roller Disco (02/1980) #440
/-------------------------------------------------------------------*/
ROM_START(roldisco)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("440.cpu", 0x2000, 0x0400, CRC(bc50631f) SHA1(6aa3124d09fc4e369d087a5ad6dd1737ace55e41))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("440.snd", 0x0400, 0x0400, CRC(4a0a05ae) SHA1(88f21b5638494d8e78dc0b6b7d69873b76b5f75d))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("440.cpu", 0x2000, 0x0400, CRC(bc50631f) SHA1(6aa3124d09fc4e369d087a5ad6dd1737ace55e41))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("440.snd", 0x0400, 0x0400, CRC(4a0a05ae) SHA1(88f21b5638494d8e78dc0b6b7d69873b76b5f75d))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
@@ -892,17 +892,17 @@ ROM_END
/ Sinbad (05/1978) #412
/-------------------------------------------------------------------*/
ROM_START(sinbad)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("412.cpu", 0x2000, 0x0400, CRC(84a86b83) SHA1(f331f2ffd7d1b279b4ffbb939aa8649e723f5fac))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("412.cpu", 0x2000, 0x0400, CRC(84a86b83) SHA1(f331f2ffd7d1b279b4ffbb939aa8649e723f5fac))
ROM_END
ROM_START(sinbadn)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("412no1.cpu", 0x2000, 0x0400, CRC(f5373f5f) SHA1(027840501416ff01b2adf07188c7d667adf3ad5f))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("412no1.cpu", 0x2000, 0x0400, CRC(f5373f5f) SHA1(027840501416ff01b2adf07188c7d667adf3ad5f))
ROM_END
/*-------------------------------------------------------------------
@@ -913,65 +913,65 @@ ROM_END
/ Solar Ride (02/1979) #421
/-------------------------------------------------------------------*/
ROM_START(solaride)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("421.cpu", 0x2000, 0x0400, CRC(6b5c5da6) SHA1(a09b7009473be53586f53f48b7bfed9a0c5ecd55))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("421.cpu", 0x2000, 0x0400, CRC(6b5c5da6) SHA1(a09b7009473be53586f53f48b7bfed9a0c5ecd55))
ROM_END
/*-------------------------------------------------------------------
/ The Incredible Hulk (10/1979) #433
/-------------------------------------------------------------------*/
ROM_START(hulk)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("433.cpu", 0x2000, 0x0400, CRC(c05d2b52) SHA1(393fe063b029246317c90ee384db95a84d61dbb7))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("433.snd", 0x0400, 0x0400, CRC(20cd1dff) SHA1(93e7c47ff7051c3c0dc9f8f95aa33ba094e7cf25))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("433.cpu", 0x2000, 0x0400, CRC(c05d2b52) SHA1(393fe063b029246317c90ee384db95a84d61dbb7))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("433.snd", 0x0400, 0x0400, CRC(20cd1dff) SHA1(93e7c47ff7051c3c0dc9f8f95aa33ba094e7cf25))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
/ Torch (02/1980) #438
/-------------------------------------------------------------------*/
ROM_START(torch)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("438.cpu", 0x2000, 0x0400, CRC(2d396a64) SHA1(38a1862771500faa471071db08dfbadc6e8759e8))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("438.snd", 0x0400, 0x0400, CRC(a9619b48) SHA1(1906bc1b059bf31082e3b4546f5a30159479ad3c))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("438.cpu", 0x2000, 0x0400, CRC(2d396a64) SHA1(38a1862771500faa471071db08dfbadc6e8759e8))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("438.snd", 0x0400, 0x0400, CRC(a9619b48) SHA1(1906bc1b059bf31082e3b4546f5a30159479ad3c))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
/ Totem (10/1979) #429
/-------------------------------------------------------------------*/
ROM_START(totem)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("429.cpu", 0x2000, 0x0400, CRC(7885a384) SHA1(1770662af7d48ad8297097a9877c5c497119978d))
- ROM_REGION(0x10000, "cpu2", 0)
- ROM_LOAD("429.snd", 0x0400, 0x0400, CRC(5d1b7ed4) SHA1(4a584f880e907fb21da78f3b3a0617f20599688f))
- ROM_RELOAD( 0x0800, 0x0400)
- ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
- ROM_RELOAD( 0xfc00, 0x0400)
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("429.cpu", 0x2000, 0x0400, CRC(7885a384) SHA1(1770662af7d48ad8297097a9877c5c497119978d))
+ ROM_REGION(0x10000, "cpu2", 0)
+ ROM_LOAD("429.snd", 0x0400, 0x0400, CRC(5d1b7ed4) SHA1(4a584f880e907fb21da78f3b3a0617f20599688f))
+ ROM_RELOAD( 0x0800, 0x0400)
+ ROM_LOAD("6530sys1.bin", 0x0c00, 0x0400, CRC(b7831321) SHA1(c94f4bee97854d0373653a6867016e27d3fc1340))
+ ROM_RELOAD( 0xfc00, 0x0400)
ROM_END
/*-------------------------------------------------------------------
/ System 1 Test prom
/-------------------------------------------------------------------*/
ROM_START(sys1test)
- ROM_REGION(0x10000, "maincpu", 0)
- ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
- ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
- ROM_LOAD("test.cpu", 0x2000, 0x0400, CRC(8b0704bb) SHA1(5f0eb8d5af867b815b6012c9d078927398efe6d8))
+ ROM_REGION(0x10000, "maincpu", 0)
+ ROM_LOAD("u5_cf.bin", 0x0000, 0x0800, CRC(e0d4b405) SHA1(17aadd79c0dcbb336aadd5d203bc6ca866492345))
+ ROM_LOAD("u4_ce.bin", 0x0800, 0x0800, CRC(4cd312dd) SHA1(31245daa9972ef8652caee69986585bb8239e86e))
+ ROM_LOAD("test.cpu", 0x2000, 0x0400, CRC(8b0704bb) SHA1(5f0eb8d5af867b815b6012c9d078927398efe6d8))
ROM_END
diff --git a/src/mame/drivers/gundealr.c b/src/mame/drivers/gundealr.c
index 3253a483fca..3ed2ba7e597 100644
--- a/src/mame/drivers/gundealr.c
+++ b/src/mame/drivers/gundealr.c
@@ -495,7 +495,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(gundealr_state::yamyam_mcu_sim)
static MACHINE_CONFIG_DERIVED( yamyam, gundealr )
- MCFG_TIMER_DRIVER_ADD_PERIODIC("mcusim", gundealr_state, yamyam_mcu_sim, attotime::from_hz(6000000/60)) /* 6mhz confirmed */
+ MCFG_TIMER_DRIVER_ADD_PERIODIC("mcusim", gundealr_state, yamyam_mcu_sim, attotime::from_hz(6000000/60)) /* 6mhz confirmed */
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/igs009.c b/src/mame/drivers/igs009.c
index d7ac525f570..78f107977aa 100644
--- a/src/mame/drivers/igs009.c
+++ b/src/mame/drivers/igs009.c
@@ -510,32 +510,32 @@ ADDRESS_MAP_END
static INPUT_PORTS_START( jingbell )
PORT_START("DSW1")
- PORT_DIPNAME( 0x01, 0x00, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("DSW1:1")
+ PORT_DIPNAME( 0x01, 0x00, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("DSW1:1")
PORT_DIPSETTING( 0x01, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x02, 0x00, "W-Up Bonus" ) PORT_DIPLOCATION("DSW1:2")
+ PORT_DIPNAME( 0x02, 0x00, "W-Up Bonus" ) PORT_DIPLOCATION("DSW1:2")
PORT_DIPSETTING( 0x02, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x04, 0x04, "Min Bet" ) PORT_DIPLOCATION("DSW1:3")
+ PORT_DIPNAME( 0x04, 0x04, "Min Bet" ) PORT_DIPLOCATION("DSW1:3")
PORT_DIPSETTING( 0x04, "1" )
PORT_DIPSETTING( 0x00, "8" )
- PORT_DIPNAME( 0x08, 0x08, "Spin Speed" ) PORT_DIPLOCATION("DSW1:4")
+ PORT_DIPNAME( 0x08, 0x08, "Spin Speed" ) PORT_DIPLOCATION("DSW1:4")
PORT_DIPSETTING( 0x08, "Slow" )
PORT_DIPSETTING( 0x00, "Quick" )
- PORT_DIPNAME( 0x10, 0x00, "Strip Girl" ) PORT_DIPLOCATION("DSW1:5")
+ PORT_DIPNAME( 0x10, 0x00, "Strip Girl" ) PORT_DIPLOCATION("DSW1:5")
PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
- PORT_DIPNAME( 0x20, 0x20, "Payout Mode" ) PORT_DIPLOCATION("DSW1:6")
+ PORT_DIPNAME( 0x20, 0x20, "Payout Mode" ) PORT_DIPLOCATION("DSW1:6")
PORT_DIPSETTING( 0x20, DEF_STR( Normal ) )
PORT_DIPSETTING( 0x00, "Auto" )
- PORT_DIPNAME( 0xc0, 0xc0, "Player's Panel" ) PORT_DIPLOCATION("DSW1:7,8")
+ PORT_DIPNAME( 0xc0, 0xc0, "Player's Panel" ) PORT_DIPLOCATION("DSW1:7,8")
PORT_DIPSETTING( 0x00, "Type A" )
PORT_DIPSETTING( 0xc0, "Type A" )
PORT_DIPSETTING( 0x80, "Type B" )
PORT_DIPSETTING( 0x40, "Type C" )
PORT_START("DSW2")
- PORT_DIPNAME( 0x07, 0x07, "Main Game Rate (%)" ) PORT_DIPLOCATION("DSW2:1,2,3")
+ PORT_DIPNAME( 0x07, 0x07, "Main Game Rate (%)" ) PORT_DIPLOCATION("DSW2:1,2,3")
PORT_DIPSETTING( 0x07, "55" )
PORT_DIPSETTING( 0x06, "60" )
PORT_DIPSETTING( 0x05, "65" )
@@ -544,7 +544,7 @@ static INPUT_PORTS_START( jingbell )
PORT_DIPSETTING( 0x02, "80" )
PORT_DIPSETTING( 0x01, "85" )
PORT_DIPSETTING( 0x00, "90" )
- PORT_DIPNAME( 0x38, 0x38, "W-Up Chance (%)" ) PORT_DIPLOCATION("DSW2:4,5,6")
+ PORT_DIPNAME( 0x38, 0x38, "W-Up Chance (%)" ) PORT_DIPLOCATION("DSW2:4,5,6")
PORT_DIPSETTING( 0x38, "93" )
PORT_DIPSETTING( 0x30, "94" )
PORT_DIPSETTING( 0x28, "95" )
@@ -553,14 +553,14 @@ static INPUT_PORTS_START( jingbell )
PORT_DIPSETTING( 0x10, "98" )
PORT_DIPSETTING( 0x08, "99" )
PORT_DIPSETTING( 0x00, "100" )
- PORT_DIPNAME( 0xc0, 0xc0, "Key In Limit" ) PORT_DIPLOCATION("DSW2:7,8")
+ PORT_DIPNAME( 0xc0, 0xc0, "Key In Limit" ) PORT_DIPLOCATION("DSW2:7,8")
PORT_DIPSETTING( 0xc0, "1k" )
PORT_DIPSETTING( 0x80, "3k" )
PORT_DIPSETTING( 0x40, "5k" )
PORT_DIPSETTING( 0x00, "10k" )
PORT_START("DSW3")
- PORT_DIPNAME( 0x07, 0x07, "Key In Rate" ) PORT_DIPLOCATION("DSW3:1,2,3")
+ PORT_DIPNAME( 0x07, 0x07, "Key In Rate" ) PORT_DIPLOCATION("DSW3:1,2,3")
PORT_DIPSETTING( 0x07, "1" )
PORT_DIPSETTING( 0x06, "5" )
PORT_DIPSETTING( 0x05, "10" )
@@ -569,7 +569,7 @@ static INPUT_PORTS_START( jingbell )
PORT_DIPSETTING( 0x02, "100" )
PORT_DIPSETTING( 0x01, "200" )
PORT_DIPSETTING( 0x00, "500" )
- PORT_DIPNAME( 0x38, 0x38, "Coin 1 Rate" ) PORT_DIPLOCATION("DSW3:4,5,6")
+ PORT_DIPNAME( 0x38, 0x38, "Coin 1 Rate" ) PORT_DIPLOCATION("DSW3:4,5,6")
PORT_DIPSETTING( 0x38, "1" )
PORT_DIPSETTING( 0x30, "2" )
PORT_DIPSETTING( 0x28, "5" )
@@ -578,20 +578,20 @@ static INPUT_PORTS_START( jingbell )
PORT_DIPSETTING( 0x10, "25" )
PORT_DIPSETTING( 0x08, "50" )
PORT_DIPSETTING( 0x00, "100" )
- PORT_DIPNAME( 0xc0, 0xc0, "System Limit" ) PORT_DIPLOCATION("DSW3:7,8")
+ PORT_DIPNAME( 0xc0, 0xc0, "System Limit" ) PORT_DIPLOCATION("DSW3:7,8")
PORT_DIPSETTING( 0xc0, "5k" )
PORT_DIPSETTING( 0x80, "10k" )
PORT_DIPSETTING( 0x40, "30k" )
PORT_DIPSETTING( 0x00, "Unlimited" )
PORT_START("DSW4")
- PORT_DIPNAME( 0x01, 0x01, "Min Play For Fever" ) PORT_DIPLOCATION("DSW4:1")
+ PORT_DIPNAME( 0x01, 0x01, "Min Play For Fever" ) PORT_DIPLOCATION("DSW4:1")
PORT_DIPSETTING( 0x01, "8" )
PORT_DIPSETTING( 0x00, "16" )
- PORT_DIPNAME( 0x02, 0x02, "Max Bet" ) PORT_DIPLOCATION("DSW4:2")
+ PORT_DIPNAME( 0x02, 0x02, "Max Bet" ) PORT_DIPLOCATION("DSW4:2")
PORT_DIPSETTING( 0x02, "16" )
PORT_DIPSETTING( 0x00, "32" )
- PORT_DIPNAME( 0x1c, 0x1c, "Coin 2 Rate" ) PORT_DIPLOCATION("DSW4:3,4,5")
+ PORT_DIPNAME( 0x1c, 0x1c, "Coin 2 Rate" ) PORT_DIPLOCATION("DSW4:3,4,5")
PORT_DIPSETTING( 0x1c, "1" )
PORT_DIPSETTING( 0x18, "2" )
PORT_DIPSETTING( 0x14, "5" )
@@ -600,37 +600,37 @@ static INPUT_PORTS_START( jingbell )
PORT_DIPSETTING( 0x08, "40" )
PORT_DIPSETTING( 0x04, "50" )
PORT_DIPSETTING( 0x00, "100" )
- PORT_DIPNAME( 0x60, 0x60, "Key Out Rate" ) PORT_DIPLOCATION("DSW4:6,7")
+ PORT_DIPNAME( 0x60, 0x60, "Key Out Rate" ) PORT_DIPLOCATION("DSW4:6,7")
PORT_DIPSETTING( 0x60, "1" )
PORT_DIPSETTING( 0x40, "10" )
PORT_DIPSETTING( 0x20, "50" )
PORT_DIPSETTING( 0x00, "100" )
- PORT_DIPNAME( 0x80, 0x80, "Play Line" ) PORT_DIPLOCATION("DSW4:8")
+ PORT_DIPNAME( 0x80, 0x80, "Play Line" ) PORT_DIPLOCATION("DSW4:8")
PORT_DIPSETTING( 0x80, "8" )
PORT_DIPSETTING( 0x00, "16" )
-// These are from the manual for v201us - DSW1-DSW4 match but DSW5 doesn't seem to match or actuallly do anything
+// These are from the manual for v201us - DSW1-DSW4 match but DSW5 doesn't seem to match or actuallly do anything
PORT_START("DSW5")
- PORT_DIPNAME( 0x03, 0x00, "Maximum Play" ) PORT_DIPLOCATION("DSW5:1,2")
+ PORT_DIPNAME( 0x03, 0x00, "Maximum Play" ) PORT_DIPLOCATION("DSW5:1,2")
PORT_DIPSETTING( 0x00, "64" )
PORT_DIPSETTING( 0x01, "32" )
PORT_DIPSETTING( 0x02, "16" )
PORT_DIPSETTING( 0x03, "8" )
- PORT_DIPNAME( 0x04, 0x04, "Skill Stop" ) PORT_DIPLOCATION("DSW5:3")
+ PORT_DIPNAME( 0x04, 0x04, "Skill Stop" ) PORT_DIPLOCATION("DSW5:3")
PORT_DIPSETTING( 0x04, "On" )
PORT_DIPSETTING( 0x00, "Off" )
- PORT_DIPNAME( 0x08, 0x00, "Hands Count" ) PORT_DIPLOCATION("DSW5:4")
+ PORT_DIPNAME( 0x08, 0x00, "Hands Count" ) PORT_DIPLOCATION("DSW5:4")
PORT_DIPSETTING( 0x08, "No" )
PORT_DIPSETTING( 0x00, "Yes" )
- PORT_DIPNAME( 0x30, 0x00, "Hands Coin Rate" ) PORT_DIPLOCATION("DSW5:5,6")
+ PORT_DIPNAME( 0x30, 0x00, "Hands Coin Rate" ) PORT_DIPLOCATION("DSW5:5,6")
PORT_DIPSETTING( 0x00, "25" )
PORT_DIPSETTING( 0x20, "10" )
PORT_DIPSETTING( 0x10, "5" )
PORT_DIPSETTING( 0x30, "1" )
- PORT_DIPNAME( 0x40, 0x40, "Hands Coin Value" ) PORT_DIPLOCATION("DSW5:7")
+ PORT_DIPNAME( 0x40, 0x40, "Hands Coin Value" ) PORT_DIPLOCATION("DSW5:7")
PORT_DIPSETTING( 0x00, "40" )
PORT_DIPSETTING( 0x40, "20" )
- PORT_DIPNAME( 0x80, 0x80, "Unused" ) PORT_DIPLOCATION("DSW5:8")
+ PORT_DIPNAME( 0x80, 0x80, "Unused" ) PORT_DIPLOCATION("DSW5:8")
PORT_DIPSETTING( 0x00, "On" )
PORT_DIPSETTING( 0x80, "Off" )
diff --git a/src/mame/drivers/jpmimpct.c b/src/mame/drivers/jpmimpct.c
index 987d2bac576..9f37edf4f82 100644
--- a/src/mame/drivers/jpmimpct.c
+++ b/src/mame/drivers/jpmimpct.c
@@ -1324,7 +1324,7 @@ MACHINE_CONFIG_START( impctawp, jpmimpct_state )
MCFG_SOUND_ADD("upd",UPD7759, UPD7759_STANDARD_CLOCK)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
MCFG_DEFAULT_LAYOUT(layout_jpmimpct)
-
+
MCFG_STARPOINT_48STEP_ADD("reel0")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(jpmimpct_state, reel0_optic_cb))
MCFG_STARPOINT_48STEP_ADD("reel1")
@@ -1337,7 +1337,7 @@ MACHINE_CONFIG_START( impctawp, jpmimpct_state )
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(jpmimpct_state, reel4_optic_cb))
MCFG_STARPOINT_48STEP_ADD("reel5")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(jpmimpct_state, reel5_optic_cb))
-
+
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/lindbergh.c b/src/mame/drivers/lindbergh.c
index 0083f3e5974..42d3b6be0ab 100644
--- a/src/mame/drivers/lindbergh.c
+++ b/src/mame/drivers/lindbergh.c
@@ -114,8 +114,8 @@ Game Dongle Sticker PIC Number
WCC Football Intercontinental Clubs 2008-2009 ? ? ?
WCC Football Intercontinental Clubs 2009-2010 ? ? ?
-* denotes these DVDs are archived.
-^ denotes these PICs are archived.
+* denotes these DVDs are archived.
+^ denotes these PICs are archived.
This list is not necessarily correct or complete.
Corrections and additions to the above are welcome.
@@ -386,8 +386,7 @@ MACHINE_CONFIG_END
ROM_LOAD("fpr-24370b.ic6", 0x000000, 0x400000, CRC(c3b021a4) SHA1(1b6938a50fe0e4ae813864649eb103838c399ac0)) \
\
ROM_REGION32_LE(0x10000, ":pci:01.0:00.0", 0) /* Geforce bios extension (custom for the card) */ \
- ROM_LOAD("vid_bios.u504", 0x00000, 0x10000, CRC(f78d14d7) SHA1(f129787e487984edd23bf344f2e9500c85052275)) \
-
+ ROM_LOAD("vid_bios.u504", 0x00000, 0x10000, CRC(f78d14d7) SHA1(f129787e487984edd23bf344f2e9500c85052275))
ROM_START(lindbios)
LINDBERGH_BIOS
ROM_END
diff --git a/src/mame/drivers/maygay1b.c b/src/mame/drivers/maygay1b.c
index bfbf1858ffe..fc6005b6ce2 100644
--- a/src/mame/drivers/maygay1b.c
+++ b/src/mame/drivers/maygay1b.c
@@ -628,7 +628,7 @@ MACHINE_CONFIG_START( maygay_m1, maygay1b_state )
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(maygay1b_state, reel4_optic_cb))
MCFG_STARPOINT_48STEP_ADD("reel5")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(maygay1b_state, reel5_optic_cb))
-
+
MCFG_NVRAM_ADD_0FILL("nvram")
MCFG_DEFAULT_LAYOUT(layout_maygay1b)
diff --git a/src/mame/drivers/mjkjidai.c b/src/mame/drivers/mjkjidai.c
index 6fd2b4e4338..d7a535b3892 100644
--- a/src/mame/drivers/mjkjidai.c
+++ b/src/mame/drivers/mjkjidai.c
@@ -282,7 +282,7 @@ INTERRUPT_GEN_MEMBER(mjkjidai_state::vblank_irq)
void mjkjidai_state::machine_start()
{
membank("bank1")->configure_entries(0, 4, memregion("maincpu")->base() + 0x8000, 0x4000);
-
+
save_item(NAME(m_adpcm_pos));
save_item(NAME(m_adpcm_end));
save_item(NAME(m_keyb));
diff --git a/src/mame/drivers/mpu3.c b/src/mame/drivers/mpu3.c
index df8af8617d0..14900ac36c7 100644
--- a/src/mame/drivers/mpu3.c
+++ b/src/mame/drivers/mpu3.c
@@ -801,7 +801,7 @@ ADDRESS_MAP_END
MCFG_STEPPER_END_INDEX(3)\
MCFG_STEPPER_INDEX_PATTERN(0x00)\
MCFG_STEPPER_INIT_PHASE(2)
-
+
static MACHINE_CONFIG_START( mpu3base, mpu3_state )
MCFG_CPU_ADD("maincpu", M6808, MPU3_MASTER_CLOCK)///4)
MCFG_CPU_PROGRAM_MAP(mpu3_basemap)
diff --git a/src/mame/drivers/mpu4hw.c b/src/mame/drivers/mpu4hw.c
index 46c6777a0f9..a58a953585b 100644
--- a/src/mame/drivers/mpu4hw.c
+++ b/src/mame/drivers/mpu4hw.c
@@ -2477,7 +2477,7 @@ ADDRESS_MAP_END
MCFG_STEPPER_END_INDEX(3)\
MCFG_STEPPER_INDEX_PATTERN(0x00)\
MCFG_STEPPER_INIT_PHASE(2)
-
+
#define MCFG_MPU4_TYPE2_REEL_ADD(_tag)\
MCFG_STEPPER_ADD(_tag)\
MCFG_STEPPER_REEL_TYPE(BARCREST_48STEP_REEL)\
@@ -2501,7 +2501,7 @@ ADDRESS_MAP_END
MCFG_STEPPER_END_INDEX(3)\
MCFG_STEPPER_INDEX_PATTERN(0x00)\
MCFG_STEPPER_INIT_PHASE(2)
-
+
MACHINE_CONFIG_FRAGMENT( mpu4_std_4reel )
MCFG_MPU4_STD_REEL_ADD("reel0")
@@ -2511,8 +2511,8 @@ MACHINE_CONFIG_FRAGMENT( mpu4_std_4reel )
MCFG_MPU4_STD_REEL_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel2_optic_cb))
MCFG_MPU4_STD_REEL_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
-MACHINE_CONFIG_END
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
+MACHINE_CONFIG_END
MACHINE_CONFIG_FRAGMENT( mpu4_std_5reel )
MCFG_MPU4_STD_REEL_ADD("reel0")
@@ -2522,10 +2522,10 @@ MACHINE_CONFIG_FRAGMENT( mpu4_std_5reel )
MCFG_MPU4_STD_REEL_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel2_optic_cb))
MCFG_MPU4_STD_REEL_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
MCFG_MPU4_STD_REEL_ADD("reel4")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
-MACHINE_CONFIG_END
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
+MACHINE_CONFIG_END
MACHINE_CONFIG_FRAGMENT( mpu4_std_6reel )
MCFG_MPU4_STD_REEL_ADD("reel0")
@@ -2535,12 +2535,12 @@ MACHINE_CONFIG_FRAGMENT( mpu4_std_6reel )
MCFG_MPU4_STD_REEL_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel2_optic_cb))
MCFG_MPU4_STD_REEL_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
MCFG_MPU4_STD_REEL_ADD("reel4")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
MCFG_MPU4_STD_REEL_ADD("reel5")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
-MACHINE_CONFIG_END
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
+MACHINE_CONFIG_END
MACHINE_CONFIG_FRAGMENT( mpu4_type2_6reel )
MCFG_MPU4_TYPE2_REEL_ADD("reel0")
@@ -2550,12 +2550,12 @@ MACHINE_CONFIG_FRAGMENT( mpu4_type2_6reel )
MCFG_MPU4_TYPE2_REEL_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel2_optic_cb))
MCFG_MPU4_TYPE2_REEL_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
MCFG_MPU4_TYPE2_REEL_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
MCFG_MPU4_TYPE2_REEL_ADD("reel5")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel5_optic_cb))
-MACHINE_CONFIG_END
+MACHINE_CONFIG_END
MACHINE_CONFIG_FRAGMENT( mpu4_bwb_5reel )
@@ -2566,11 +2566,11 @@ MACHINE_CONFIG_FRAGMENT( mpu4_bwb_5reel )
MCFG_MPU4_BWB_REEL_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel2_optic_cb))
MCFG_MPU4_BWB_REEL_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
MCFG_MPU4_BWB_REEL_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
-MACHINE_CONFIG_END
-
+MACHINE_CONFIG_END
+
MACHINE_CONFIG_FRAGMENT( mpu4_alt_7reel )
MCFG_MPU4_TYPE3_REEL_ADD("reel0")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel0_optic_cb))
@@ -2579,7 +2579,7 @@ MACHINE_CONFIG_FRAGMENT( mpu4_alt_7reel )
MCFG_MPU4_TYPE3_REEL_ADD("reel2")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel2_optic_cb))
MCFG_MPU4_TYPE3_REEL_ADD("reel3")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel3_optic_cb))
MCFG_MPU4_TYPE3_REEL_ADD("reel4")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel4_optic_cb))
MCFG_MPU4_TYPE3_REEL_ADD("reel5")
@@ -2587,8 +2587,8 @@ MACHINE_CONFIG_FRAGMENT( mpu4_alt_7reel )
MCFG_MPU4_TYPE3_REEL_ADD("reel6")
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel6_optic_cb))
MCFG_MPU4_TYPE3_REEL_ADD("reel7")
- MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel7_optic_cb))
-MACHINE_CONFIG_END
+ MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(mpu4_state, reel7_optic_cb))
+MACHINE_CONFIG_END
MACHINE_CONFIG_FRAGMENT( mpu4_common )
MCFG_TIMER_DRIVER_ADD_PERIODIC("50hz", mpu4_state, gen_50hz, attotime::from_hz(100))
@@ -2654,7 +2654,7 @@ MACHINE_CONFIG_FRAGMENT( mpu4_common )
MCFG_PIA_CB2_HANDLER(WRITELINE(mpu4_state, pia_ic8_cb2_w))
MCFG_PIA_IRQA_HANDLER(WRITELINE(mpu4_state, cpu0_irq))
MCFG_PIA_IRQB_HANDLER(WRITELINE(mpu4_state, cpu0_irq))
-
+
MACHINE_CONFIG_END
MACHINE_CONFIG_FRAGMENT( mpu4_common2 )
@@ -2727,7 +2727,7 @@ MACHINE_CONFIG_DERIVED( mod4oki, mpu4base )
MCFG_FRAGMENT_ADD(mpu4_common2)
MCFG_FRAGMENT_ADD(mpu4_std_6reel)
-
+
MCFG_SOUND_ADD("msm6376", OKIM6376, 128000) //16KHz sample Can also be 85430 at 10.5KHz and 64000 at 8KHz
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0)
@@ -2749,7 +2749,7 @@ MACHINE_CONFIG_DERIVED( mod4oki_5r, mpu4base )
MCFG_FRAGMENT_ADD(mpu4_common2)
MCFG_FRAGMENT_ADD(mpu4_std_5reel)
-
+
MCFG_SOUND_ADD("msm6376", OKIM6376, 128000) //16KHz sample Can also be 85430 at 10.5KHz and 64000 at 8KHz
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0)
@@ -2759,7 +2759,7 @@ MACHINE_CONFIG_DERIVED( bwboki, mpu4base )
MCFG_MACHINE_START_OVERRIDE(mpu4_state,mpu4bwb)
MCFG_FRAGMENT_ADD(mpu4_common2)
MCFG_FRAGMENT_ADD(mpu4_bwb_5reel)
-
+
MCFG_SOUND_ADD("msm6376", OKIM6376, 128000) //16KHz sample Can also be 85430 at 10.5KHz and 64000 at 8KHz
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0)
diff --git a/src/mame/drivers/namcops2.c b/src/mame/drivers/namcops2.c
index 2079c06eee0..de37f27302c 100644
--- a/src/mame/drivers/namcops2.c
+++ b/src/mame/drivers/namcops2.c
@@ -325,13 +325,13 @@ ROM_END
// only known System Super 256 game; if more surface the BIOS should be moved out like 246/256
ROM_START( timecrs4 )
ROM_REGION(0x200000, "bios", 0)
- ROM_LOAD( "r27v1602f.8g", 0x000000, 0x200000, CRC(b2a8eeb6) SHA1(bc4fb4e1e53adbd92385f1726bd69663ff870f1e) )
+ ROM_LOAD( "r27v1602f.8g", 0x000000, 0x200000, CRC(b2a8eeb6) SHA1(bc4fb4e1e53adbd92385f1726bd69663ff870f1e) )
ROM_REGION(0x840000, "key", ROMREGION_ERASE00)
- ROM_LOAD( "tsf1002-na-a.ic002", 0x000000, 0x800000, CRC(406183a4) SHA1(dd6afaa4808254b277c5969d071f1dd0019633a0) )
- ROM_LOAD( "tsf1002-na-a_spr.ic002", 0x800000, 0x040000, CRC(e7339b66) SHA1(99a2fd5528daf11a7ea548d9de804f899a2a9c6b) )
+ ROM_LOAD( "tsf1002-na-a.ic002", 0x000000, 0x800000, CRC(406183a4) SHA1(dd6afaa4808254b277c5969d071f1dd0019633a0) )
+ ROM_LOAD( "tsf1002-na-a_spr.ic002", 0x800000, 0x040000, CRC(e7339b66) SHA1(99a2fd5528daf11a7ea548d9de804f899a2a9c6b) )
- DISK_REGION("dvd") // HDD for this game
+ DISK_REGION("dvd") // HDD for this game
DISK_IMAGE_READONLY( "tsf1-ha", 0, SHA1(8ba7eec0d1add2192a115b295a32265c8d084aea) )
ROM_END
@@ -411,8 +411,8 @@ ROM_START( tekken5d )
SYSTEM256_BIOS
ROM_REGION(0x840000, "key", ROMREGION_ERASE00)
- ROM_LOAD( "ted1vera.ic002", 0x000000, 0x800000, CRC(491521d1) SHA1(9c27836445690bc083c6f274a4b1a499d5677830) )
- ROM_LOAD( "ted1vera_spr.ic002", 0x800000, 0x040000, CRC(a9e1e92b) SHA1(3843d0fea2f12f14f83d0a04430bb9b01cfdef07) )
+ ROM_LOAD( "ted1vera.ic002", 0x000000, 0x800000, CRC(491521d1) SHA1(9c27836445690bc083c6f274a4b1a499d5677830) )
+ ROM_LOAD( "ted1vera_spr.ic002", 0x800000, 0x040000, CRC(a9e1e92b) SHA1(3843d0fea2f12f14f83d0a04430bb9b01cfdef07) )
DISK_REGION("dvd")
DISK_IMAGE_READONLY( "ted1dvd0b", 0, SHA1(5940cc628a1555763ef2055e518f840f9a44d123) )
@@ -435,8 +435,8 @@ ROM_START( prdgp03 )
SYSTEM246_BIOS
ROM_REGION(0x840000, "key", ROMREGION_ERASE00)
- ROM_LOAD( "pr21vera.ic002", 0x000000, 0x800000, CRC(36634ad2) SHA1(e365a79220202640e5bc80bbd8a329012f22f9c4) )
- ROM_LOAD( "pr21vera_spr.ic002", 0x000000, 0x040000, CRC(4e81ef24) SHA1(7b7b9d9a0193bcaccb1578cae9dde37fc456e6f8) )
+ ROM_LOAD( "pr21vera.ic002", 0x000000, 0x800000, CRC(36634ad2) SHA1(e365a79220202640e5bc80bbd8a329012f22f9c4) )
+ ROM_LOAD( "pr21vera_spr.ic002", 0x000000, 0x040000, CRC(4e81ef24) SHA1(7b7b9d9a0193bcaccb1578cae9dde37fc456e6f8) )
DISK_REGION("dvd")
DISK_IMAGE_READONLY( "pr21dvd0", 0, SHA1(6bad5c25996bbe68da71199fbe8377b51fe78d81) )
@@ -513,8 +513,8 @@ ROM_START( rrvac2 )
SYSTEM246_BIOS
ROM_REGION(0x840000, "key", ROMREGION_ERASE00)
- ROM_LOAD( "rrv2vera.ic002", 0x000000, 0x800000, CRC(4666f6b5) SHA1(974ed4f6c5869ecf879c0d3540db6ea576225c04) )
- ROM_LOAD( "rrv2vera_spr.ic002", 0x800000, 0x040000, CRC(8d98ef04) SHA1(3f33046a8283b918226301fcf5538729be84bfbe) )
+ ROM_LOAD( "rrv2vera.ic002", 0x000000, 0x800000, CRC(4666f6b5) SHA1(974ed4f6c5869ecf879c0d3540db6ea576225c04) )
+ ROM_LOAD( "rrv2vera_spr.ic002", 0x800000, 0x040000, CRC(8d98ef04) SHA1(3f33046a8283b918226301fcf5538729be84bfbe) )
ROM_REGION(0x4010, "jvsio", 0) // Namco "FCA" JVS I/O board PIC16F84 code (see namcos23.c for FCA details)
ROM_LOAD( "fcap11.ic2", 0x000000, 0x004010, CRC(1b2592ce) SHA1(a1a487361053af564f6ec67e545413e370a3b38c) )
@@ -579,8 +579,8 @@ ROM_START( qgundam )
SYSTEM246_BIOS
ROM_REGION(0x840000, "key", ROMREGION_ERASE00)
- ROM_LOAD( "qg1vera.ic002", 0x000000, 0x800000, CRC(650d55fa) SHA1(cf1210bc1f2d48c298ed19e3c6a1e5e564840e47) )
- ROM_LOAD( "qg1vera_spr.ic002", 0x800000, 0x040000, CRC(d9715f53) SHA1(e45f0eef5b82b2e1afb054a137aced0344ddbd71) )
+ ROM_LOAD( "qg1vera.ic002", 0x000000, 0x800000, CRC(650d55fa) SHA1(cf1210bc1f2d48c298ed19e3c6a1e5e564840e47) )
+ ROM_LOAD( "qg1vera_spr.ic002", 0x800000, 0x040000, CRC(d9715f53) SHA1(e45f0eef5b82b2e1afb054a137aced0344ddbd71) )
DISK_REGION("dvd")
DISK_IMAGE_READONLY( "qg1", 0, SHA1(80fe5cb325c7cfa439d66e9d264337c01559d0e5) )
@@ -614,8 +614,8 @@ ROM_START( gdvsgd )
SYSTEM256_BIOS
ROM_REGION(0x840000, "key", ROMREGION_ERASE00)
- ROM_LOAD( "gvs1vera.ic002", 0x000000, 0x800000, CRC(b938b96d) SHA1(e79bc7f8c234d51d1b6a34be88f34abc8205a370) )
- ROM_LOAD( "gvs1vera_spr.ic002", 0x800000, 0x040000, CRC(f2d65d54) SHA1(297726098c3723e38cbaf3a3150a4a027a9c2124) )
+ ROM_LOAD( "gvs1vera.ic002", 0x000000, 0x800000, CRC(b938b96d) SHA1(e79bc7f8c234d51d1b6a34be88f34abc8205a370) )
+ ROM_LOAD( "gvs1vera_spr.ic002", 0x800000, 0x040000, CRC(f2d65d54) SHA1(297726098c3723e38cbaf3a3150a4a027a9c2124) )
DISK_REGION("dvd")
DISK_IMAGE_READONLY( "gvs1dvd0b", 0, SHA1(3cf9ade5495982fcb8e106e7be4067429530f864) )
@@ -703,4 +703,3 @@ GAME(2009, gdvsgdnx, sys256, system256, system246, driver_device, 0, ROT0, "Ca
// System Super 256
GAME(2006, timecrs4, sys256, system256, system246, driver_device, 0, ROT0, "Namco", "Time Crisis 4", GAME_IS_SKELETON)
-
diff --git a/src/mame/drivers/relief.c b/src/mame/drivers/relief.c
index d1c6d4d1237..b1ba6031cc9 100644
--- a/src/mame/drivers/relief.c
+++ b/src/mame/drivers/relief.c
@@ -106,7 +106,7 @@ WRITE16_MEMBER(relief_state::audio_volume_w)
static ADDRESS_MAP_START( oki_map, AS_0, 8, relief_state )
AM_RANGE(0x00000, 0x1ffff) AM_ROMBANK("okibank")
- AM_RANGE(0x20000, 0x3ffff) AM_ROM
+ AM_RANGE(0x20000, 0x3ffff) AM_ROM
ADDRESS_MAP_END
@@ -431,7 +431,7 @@ DRIVER_INIT_MEMBER(relief_state,relief)
}
-
+
/*************************************
*
diff --git a/src/mame/drivers/renegade.c b/src/mame/drivers/renegade.c
index c5fb2e92981..7323599ed76 100644
--- a/src/mame/drivers/renegade.c
+++ b/src/mame/drivers/renegade.c
@@ -131,10 +131,10 @@ WRITE8_MEMBER(renegade_state::adpcm_addr_w)
// (chip select for an unpopulated fourth ROM?)
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;
diff --git a/src/mame/drivers/sbrkout.c b/src/mame/drivers/sbrkout.c
index 4f1c871a93e..683228fbc13 100644
--- a/src/mame/drivers/sbrkout.c
+++ b/src/mame/drivers/sbrkout.c
@@ -6,8 +6,8 @@
Games supported:
* Super Breakout
- * Super Breakout (Canyon and Vertical Breakout, prototype)
- * Super Breakout (Cocktail, prototype)
+ * Super Breakout (Canyon and Vertical Breakout, prototype)
+ * Super Breakout (Cocktail, prototype)
Known issues:
* none at this time
@@ -529,7 +529,7 @@ static INPUT_PORTS_START( sbrkoutct )
PORT_MODIFY("SELECT")
PORT_CONFNAME(0x80, 0x00, "Game Select" )
- PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
+ PORT_CONFSETTING( 0x00, DEF_STR( Off ) )
PORT_CONFSETTING( 0x80, DEF_STR( On ) )
INPUT_PORTS_END
diff --git a/src/mame/drivers/snowbros.c b/src/mame/drivers/snowbros.c
index 60e7d23c99e..dea54fc0a83 100644
--- a/src/mame/drivers/snowbros.c
+++ b/src/mame/drivers/snowbros.c
@@ -1401,12 +1401,12 @@ static INPUT_PORTS_START( suhosong )
PORT_DIPUNUSED_DIPLOC( 0x0020, 0x0000, "SW1:6" )
PORT_DIPUNUSED_DIPLOC( 0x0040, 0x0000, "SW1:7" )
PORT_SERVICE_DIPLOC( 0x0080, IP_ACTIVE_LOW, "SW1:8" )
- PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Button 4 / Stand / Stop / Drop / Full Bet / Take") PORT_CODE(KEYCODE_V)
- PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Button 1 / High") PORT_CODE(KEYCODE_Z)
- PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Button 2 / Low") PORT_CODE(KEYCODE_X)
- PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Button 3 / Hit / Go / Double Up") PORT_CODE(KEYCODE_C)
+ PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_BUTTON4 ) PORT_NAME("Button 4 / Stand / Stop / Drop / Full Bet / Take") PORT_CODE(KEYCODE_V)
+ PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Button 1 / High") PORT_CODE(KEYCODE_Z)
+ PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Button 2 / Low") PORT_CODE(KEYCODE_X)
+ PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Button 3 / Hit / Go / Double Up") PORT_CODE(KEYCODE_C)
PORT_BIT( 0x1000, IP_ACTIVE_HIGH, IPT_UNKNOWN )
- PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Button 6 / Bet / Raise") PORT_CODE(KEYCODE_N)
+ PORT_BIT( 0x2000, IP_ACTIVE_HIGH, IPT_BUTTON6 ) PORT_NAME("Button 6 / Bet / Raise") PORT_CODE(KEYCODE_N)
PORT_BIT( 0x4000, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_UNKNOWN )
@@ -1429,7 +1429,7 @@ static INPUT_PORTS_START( suhosong )
PORT_BIT( 0x8000, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_START("SYSTEM")
- PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Button 5 / Start / Double / Call / Check") PORT_CODE(KEYCODE_B) // Double != Double Up
+ PORT_BIT( 0x0100, IP_ACTIVE_HIGH, IPT_BUTTON5 ) PORT_NAME("Button 5 / Start / Double / Call / Check") PORT_CODE(KEYCODE_B) // Double != Double Up
PORT_BIT( 0x0200, IP_ACTIVE_HIGH, IPT_UNKNOWN )
PORT_BIT( 0x0400, IP_ACTIVE_HIGH, IPT_COIN1 )
PORT_BIT( 0x0800, IP_ACTIVE_HIGH, IPT_COIN2 )
diff --git a/src/mame/drivers/taito_f3.c b/src/mame/drivers/taito_f3.c
index d09844670a2..9635f30e88a 100644
--- a/src/mame/drivers/taito_f3.c
+++ b/src/mame/drivers/taito_f3.c
@@ -3143,12 +3143,12 @@ ROM_START( pbobble3j )
ROM_LOAD16_BYTE("e29-04.ic39", 0x800000, 0x200000, CRC(d1f42457) SHA1(2c77be6365deb5ef215da0c66da23b415623bdb1) ) // D2 C8 C9 CA
ROM_LOAD16_BYTE("e29-05.ic41", 0xc00000, 0x200000, CRC(e33c1234) SHA1(84c336ed6fd8723e824889fe7b52c284be659e62) ) // CB CC -std-
- ROM_REGION(0x034a, "pals", 0)
- ROM_LOAD("d77-12.ic48.bin", 0x0000, 0x0001, NO_DUMP) /* PALCE16V8Q-15PC/4 */
- ROM_LOAD("d77-14.ic21.bin", 0x0001, 0x0001, NO_DUMP) /* PALCE16V8Q-15PC/4 */
- ROM_LOAD("d77-11.ic37.bin", 0x0002, 0x0001, NO_DUMP) /* PALCE16V8Q-15PC/4 */
- ROM_LOAD("d77-09.ic14.bin", 0x0003, 0x0001, NO_DUMP) /* PAL16L8ACN */
- ROM_LOAD("d77-10.ic28.bin", 0x0004, 0x0001, NO_DUMP) /* PAL16L8ACN */
+ ROM_REGION(0x034a, "pals", 0)
+ ROM_LOAD("d77-12.ic48.bin", 0x0000, 0x0001, NO_DUMP) /* PALCE16V8Q-15PC/4 */
+ ROM_LOAD("d77-14.ic21.bin", 0x0001, 0x0001, NO_DUMP) /* PALCE16V8Q-15PC/4 */
+ ROM_LOAD("d77-11.ic37.bin", 0x0002, 0x0001, NO_DUMP) /* PALCE16V8Q-15PC/4 */
+ ROM_LOAD("d77-09.ic14.bin", 0x0003, 0x0001, NO_DUMP) /* PAL16L8ACN */
+ ROM_LOAD("d77-10.ic28.bin", 0x0004, 0x0001, NO_DUMP) /* PAL16L8ACN */
ROM_END
ROM_START( arkretrn )
diff --git a/src/mame/drivers/tigeroad.c b/src/mame/drivers/tigeroad.c
index d3cf4dbc383..ef1d42553db 100644
--- a/src/mame/drivers/tigeroad.c
+++ b/src/mame/drivers/tigeroad.c
@@ -619,7 +619,7 @@ static MACHINE_CONFIG_START( tigeroad, tigeroad_state )
MCFG_SCREEN_PALETTE("palette")
MCFG_GFXDECODE_ADD("gfxdecode", "palette", tigeroad)
-
+
MCFG_DEVICE_ADD("spritegen", TIGEROAD_SPRITE, 0)
MCFG_PALETTE_ADD("palette", 1024)
diff --git a/src/mame/drivers/viper.c b/src/mame/drivers/viper.c
index 6d2c2bbb7b2..7aeb2252613 100644
--- a/src/mame/drivers/viper.c
+++ b/src/mame/drivers/viper.c
@@ -80,17 +80,17 @@ MB81G163222-80 - Fujitsu MB81G163222-80 256k x 32-bit x 2 banks Synchronous Grap
DS2430 - Dallas DS2430 256-bits 1-Wire EEPROM. Has 256 bits x8 EEPROM (32 bytes), 64 bits x8 (8 bytes)
one-time programmable application register and unique factory-lasered and tested 64-bit
registration number (8-bit family code + 48-bit serial number + 8-bit CRC) (TO-92 @ U37)
- The OTP application register on the common DS2430 and the Police 911 2 DS2430 are not programmed
- (application register reads all 0xFF and the status register reads back 0xFF), so it's probably safe
+ The OTP application register on the common DS2430 and the Police 911 2 DS2430 are not programmed
+ (application register reads all 0xFF and the status register reads back 0xFF), so it's probably safe
to assume they're not used on any of them.
It appears the DS2430 is not protected from reading and the unique silicon serial number is
included in the 40 byte dump. This serial number is used as a check to verify the NVRAM and DS2430.
In the Police 911 2 NVRAM dump the serial number of the DS2430 is located at 0x002A and 0x1026
If the serial number in the NVRAM and DS2430 match then they are paired and the game accepts the NVRAM.
If they don't match the game requires an external DS2430 (i.e. dongle) and flags the NVRAM as 'BAD'
- The serial number is not present in the CF card (2 different Police 911 2 cards of the same version
+ The serial number is not present in the CF card (2 different Police 911 2 cards of the same version
were dumped and matched).
- When the lasered ROM is read from the DS2430, it comes out from LSB to MSB (family code, LSB of
+ When the lasered ROM is read from the DS2430, it comes out from LSB to MSB (family code, LSB of
S/N->MSB of S/N, CRC)
For Police 911 2 that is 0x14 0xB2 0xB7 0x4A 0x00 0x00 0x00 0x83
Family code=0x14
@@ -104,12 +104,12 @@ MB81G163222-80 - Fujitsu MB81G163222-80 256k x 32-bit x 2 banks Synchronous Grap
It may be possible to hand craft a DS2430 for a dongle-protected version of a game simply by using
one of the existing DS2430 dumps and adjusting the serial number found in a dump of the NVRAM to pair them
or adjusting the serial number in the NVRAM to match the serial number found in one of the dumped DS2430s.
- This Police 911 2 board was upgraded from Police 911 by plugging in the dongle and changing the CF card.
- The NVRAM had previously died and the board was dead. Normally for a Viper game that is fatal. Using
- the NVRAM from Police 911 allowed it to boot and then the NVRAM upgraded itself with some additional
+ This Police 911 2 board was upgraded from Police 911 by plugging in the dongle and changing the CF card.
+ The NVRAM had previously died and the board was dead. Normally for a Viper game that is fatal. Using
+ the NVRAM from Police 911 allowed it to boot and then the NVRAM upgraded itself with some additional
data (the original data remained untouched). This means the dongle does more than just protect the game.
- Another interesting fact about this upgrade is it has been discovered that the PCB can write to the
- external DS2430 in the dongle. This has been proven because the serial number of the DS2430 soldered
+ Another interesting fact about this upgrade is it has been discovered that the PCB can write to the
+ external DS2430 in the dongle. This has been proven because the serial number of the DS2430 soldered
on the PCB is present in the EEPROM area of the Police 911 2 DS2430.
Here is a dump of the DS2430 from Police 911. Note the EEPROM area is empty and the serial number (from 0x20 onwards)
is present in the above Police 911 2 DS2430 dump at locations 0x11, 0x10 and 0x0F
@@ -117,34 +117,34 @@ MB81G163222-80 - Fujitsu MB81G163222-80 256k x 32-bit x 2 banks Synchronous Grap
00000010h FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
00000020h 14 A9 30 74 00 00 00 E7
This proves that the EEPROM area in the DS2430 is unused by an unprotected game and in fact the on-board
- DS2430 is completely unused by an unprotected game. That is why any unprotected game will work on any
+ DS2430 is completely unused by an unprotected game. That is why any unprotected game will work on any
Viper PCB regardless of the on-board DS2430 serial number.
- The existing DS2430 'common' dump used in the unprotected games was actually from a (dongle-protected)
+ The existing DS2430 'common' dump used in the unprotected games was actually from a (dongle-protected)
Mahjong Fight Club PCB but that PCB was used to test and run all of the unprotected Viper games.
M48T58Y - ST Microelectronics M48T58Y Timekeeper RAM (DIP28 @ U39). When this dies (after 10 year lifespan)
the game will complain with error RTC BAD then reset. The data inside the RTC can not be hand created
(yet) so to revive the PCB the correct RTC data must be re-programmed to a new RTC and replaced
on the PCB.
Regarding the RTC and protection-related checks....
- "RTC OK" checks 0x0000->0x0945 (i.e. I can clear the contents after 0x0945 and the game will still
+ "RTC OK" checks 0x0000->0x0945 (i.e. I can clear the contents after 0x0945 and the game will still
happily boot). The NVRAM contents are split into chunks, each of which are checksummed. It is a 16-bit checksum,
- computed by summing two consecutive bytes as a 16-bit integer, where the final sum must add up to 0xFFFF (mod
- 65536). The last two bytes in the chunk are used to make the value 0xFFFF. There doesn't appear to be a
- complete checksum over all the chunks (I can pick and choose chunks from various NVRAMs, as long as each chunk
+ computed by summing two consecutive bytes as a 16-bit integer, where the final sum must add up to 0xFFFF (mod
+ 65536). The last two bytes in the chunk are used to make the value 0xFFFF. There doesn't appear to be a
+ complete checksum over all the chunks (I can pick and choose chunks from various NVRAMs, as long as each chunk
checksum checks out). The important chunks for booting are the first two.
- The first chunk goes from 0x0000-0x000F. This seems to be a game/region identifier, and doesn't like its
- contents changed (I didn't try changing every byte, but several of the bytes would throw RTC errors, even with a
- fixed checksum). I'd guess that the CF verifies this value, since it's different for every game (i.e. Mocap
+ The first chunk goes from 0x0000-0x000F. This seems to be a game/region identifier, and doesn't like its
+ contents changed (I didn't try changing every byte, but several of the bytes would throw RTC errors, even with a
+ fixed checksum). I'd guess that the CF verifies this value, since it's different for every game (i.e. Mocap
Boxing NVRAM would have a correct checksum, but shouldn't pass Police 911 checks).
- The second chunk goes from 0x0010-0x0079. This seems to be a board identifier. This has (optionally)
- several fields, each of which are 20 bytes long. I'm unsure of the first 6 bytes, the following 6
- bytes are the DS2430A S/N, and the last 8 bytes are a game/region/dongle identifier. If running
- without a dongle, only the first 20 byte field is present. With a dongle, a second 20 byte field will
- be present. Moving this second field into the place of the first field (and fixing the checksum)
- doesn't work, and the second field will be ignored if the first field is valid for the game (and in
- which case the dongle will be ignored). For example, Police 911 will boot with a valid first field,
- with or without the second field, and with or without the dongle plugged in. If you have both fields,
- and leave the dongle plugged in, you can switch between Police 911 and Police 911/2 by simply swapping
+ The second chunk goes from 0x0010-0x0079. This seems to be a board identifier. This has (optionally)
+ several fields, each of which are 20 bytes long. I'm unsure of the first 6 bytes, the following 6
+ bytes are the DS2430A S/N, and the last 8 bytes are a game/region/dongle identifier. If running
+ without a dongle, only the first 20 byte field is present. With a dongle, a second 20 byte field will
+ be present. Moving this second field into the place of the first field (and fixing the checksum)
+ doesn't work, and the second field will be ignored if the first field is valid for the game (and in
+ which case the dongle will be ignored). For example, Police 911 will boot with a valid first field,
+ with or without the second field, and with or without the dongle plugged in. If you have both fields,
+ and leave the dongle plugged in, you can switch between Police 911 and Police 911/2 by simply swapping
CF cards.
29F002 - Fujitsu 29F002 256k x8 EEPROM stamped '941B01' (PLCC44 @ U25). Earlier revision stamped '941A01'
CN4/CN5 - RCA-type network connection jacks
@@ -244,7 +244,7 @@ MB81G163222-80 - Fujitsu MB81G163222-80 256k x 32-bit x 2 banks Synchronous Grap
CN2/CN3 - Video output connector to external monitors
CN4/CN5 - Multi-pin IDC connectors joining to main board CN15/CN16
-An additional control PCB is used for Mocap Golf for the golf club sensor. It contains a ROMless MCU, an EPROM and
+An additional control PCB is used for Mocap Golf for the golf club sensor. It contains a ROMless MCU, an EPROM and
some other components. It will be documented at a later date.
*/
diff --git a/src/mame/drivers/wallc.c b/src/mame/drivers/wallc.c
index 7ebd56060e8..1c66fdbfa5f 100644
--- a/src/mame/drivers/wallc.c
+++ b/src/mame/drivers/wallc.c
@@ -64,11 +64,11 @@ public:
required_device<cpu_device> m_maincpu;
required_device<gfxdecode_device> m_gfxdecode;
-
+
required_shared_ptr<UINT8> m_videoram;
-
+
tilemap_t *m_bg_tilemap;
-
+
DECLARE_WRITE8_MEMBER(wallc_videoram_w);
DECLARE_WRITE8_MEMBER(wallc_coin_counter_w);
DECLARE_DRIVER_INIT(wallc);
diff --git a/src/mame/drivers/yunsun16.c b/src/mame/drivers/yunsun16.c
index 3ba6d62f969..d0022da8f8e 100644
--- a/src/mame/drivers/yunsun16.c
+++ b/src/mame/drivers/yunsun16.c
@@ -634,7 +634,7 @@ static MACHINE_CONFIG_START( shocking, yunsun16_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", yunsun16_state, irq2_line_hold)
-
+
MCFG_MACHINE_START_OVERRIDE(yunsun16_state, shocking)
MCFG_MACHINE_RESET_OVERRIDE(yunsun16_state, shocking)
@@ -876,7 +876,7 @@ ROM_START( paprazzi )
ROM_REGION( 0x080000, "oki", 0 ) /* Samples */
ROM_LOAD( "u131.bin", 0x000000, 0x080000, CRC(bcf7aa12) SHA1(f7bf5258396ed0eb7e85eccf250c6d0a333a4d61) )
-
+
ROM_END
/***************************************************************************
@@ -905,7 +905,7 @@ ROM_START( shocking )
ROM_REGION( 0x080000, "oki", 0 ) /* Samples */
ROM_LOAD( "yunsun16.131", 0x000000, 0x080000, CRC(d0a1bb8c) SHA1(10f33521bd6031ed73ee5c7be1382165925aa8f8) )
-
+
ROM_END
ROM_START( shockingk )
@@ -928,7 +928,7 @@ ROM_START( shockingk )
ROM_REGION( 0x080000, "oki", 0 ) /* Samples */
ROM_LOAD( "yunsun16.131", 0x000000, 0x080000, CRC(d0a1bb8c) SHA1(10f33521bd6031ed73ee5c7be1382165925aa8f8) )
-
+
ROM_END
@@ -960,7 +960,7 @@ ROM_START( bombkick )
ROM_REGION( 0x080000, "oki", 0 ) /* Samples */
ROM_LOAD( "bk_u131", 0x000000, 0x080000, CRC(22cc5732) SHA1(38aefa4e543ea54e004eee428ee087121eb20905) )
-
+
ROM_END
ROM_START( bombkicka ) // marked 'Bomb Kick 98'
@@ -983,7 +983,7 @@ ROM_START( bombkicka ) // marked 'Bomb Kick 98'
ROM_REGION( 0x080000, "oki", 0 ) /* Samples */
ROM_LOAD( "bk_u131", 0x000000, 0x080000, CRC(22cc5732) SHA1(38aefa4e543ea54e004eee428ee087121eb20905) )
-
+
ROM_END
/***************************************************************************
diff --git a/src/mame/includes/asteroid.h b/src/mame/includes/asteroid.h
index 4104def464f..cbe2038e5d8 100644
--- a/src/mame/includes/asteroid.h
+++ b/src/mame/includes/asteroid.h
@@ -43,13 +43,13 @@ public:
DECLARE_WRITE8_MEMBER(asteroid_noise_reset_w);
DECLARE_WRITE8_MEMBER(llander_snd_reset_w);
DECLARE_WRITE8_MEMBER(llander_sounds_w);
-
+
DECLARE_CUSTOM_INPUT_MEMBER(clock_r);
-
+
INTERRUPT_GEN_MEMBER(asteroid_interrupt);
INTERRUPT_GEN_MEMBER(asterock_interrupt);
INTERRUPT_GEN_MEMBER(llander_interrupt);
-
+
DECLARE_DRIVER_INIT(asterock);
DECLARE_DRIVER_INIT(asteroidb);
diff --git a/src/mame/includes/bionicc.h b/src/mame/includes/bionicc.h
index d98f5d9e013..2b8866b3085 100644
--- a/src/mame/includes/bionicc.h
+++ b/src/mame/includes/bionicc.h
@@ -20,7 +20,7 @@ public:
m_maincpu(*this, "maincpu"),
m_gfxdecode(*this, "gfxdecode"),
m_palette(*this, "palette"),
- m_spritegen(*this, "spritegen")
+ m_spritegen(*this, "spritegen")
{ }
/* memory pointers */
diff --git a/src/mame/includes/galaxold.h b/src/mame/includes/galaxold.h
index 2c5b5401a72..c6ed3ae8621 100644
--- a/src/mame/includes/galaxold.h
+++ b/src/mame/includes/galaxold.h
@@ -52,7 +52,7 @@ public:
required_device<gfxdecode_device> m_gfxdecode;
required_device<screen_device> m_screen;
required_device<palette_device> m_palette;
-
+
/* memory pointers */
required_shared_ptr<UINT8> m_videoram;
required_shared_ptr<UINT8> m_spriteram;
@@ -74,7 +74,7 @@ public:
UINT8 m_color_mask;
tilemap_t *m_dambustr_tilemap2;
UINT8 *m_dambustr_videoram2;
-
+
void (galaxold_state::*m_modify_charcode)(UINT16 *code, UINT8 x); /* function to call to do character banking */
void (galaxold_state::*m_modify_spritecode)(UINT8 *spriteram, int*, int*, int*, int); /* function to call to do sprite banking */
void (galaxold_state::*m_modify_color)(UINT8 *color); /* function to call to do modify how the color codes map to the PROM */
@@ -147,30 +147,30 @@ public:
DECLARE_WRITE8_MEMBER(dambustr_bg_split_line_w);
DECLARE_WRITE8_MEMBER(dambustr_bg_color_w);
DECLARE_WRITE_LINE_MEMBER(galaxold_7474_9m_2_q_callback);
- DECLARE_WRITE_LINE_MEMBER(galaxold_7474_9m_1_callback);
-
+ DECLARE_WRITE_LINE_MEMBER(galaxold_7474_9m_1_callback);
+
DECLARE_CUSTOM_INPUT_MEMBER(_4in1_fake_port_r);
DECLARE_CUSTOM_INPUT_MEMBER(vpool_lives_r);
DECLARE_CUSTOM_INPUT_MEMBER(ckongg_coinage_r);
DECLARE_CUSTOM_INPUT_MEMBER(dkongjrm_coinage_r);
-
+
DECLARE_DRIVER_INIT(bullsdrtg);
DECLARE_DRIVER_INIT(ladybugg);
DECLARE_DRIVER_INIT(4in1);
DECLARE_DRIVER_INIT(guttangt);
DECLARE_DRIVER_INIT(ckonggx);
-
+
TILE_GET_INFO_MEMBER(drivfrcg_get_tile_info);
TILE_GET_INFO_MEMBER(racknrol_get_tile_info);
TILE_GET_INFO_MEMBER(dambustr_get_tile_info2);
TILE_GET_INFO_MEMBER(get_tile_info);
TILE_GET_INFO_MEMBER(rockclim_get_tile_info);
TILE_GET_INFO_MEMBER(harem_get_tile_info);
-
+
DECLARE_MACHINE_RESET(galaxold);
DECLARE_MACHINE_RESET(devilfsg);
DECLARE_MACHINE_RESET(hunchbkg);
-
+
DECLARE_PALETTE_INIT(galaxold);
DECLARE_PALETTE_INIT(rockclim);
DECLARE_PALETTE_INIT(scrambold);
@@ -181,7 +181,7 @@ public:
DECLARE_PALETTE_INIT(mariner);
DECLARE_PALETTE_INIT(dambustr);
DECLARE_PALETTE_INIT(turtles);
-
+
DECLARE_VIDEO_START(galaxold);
DECLARE_VIDEO_START(drivfrcg);
DECLARE_VIDEO_START(racknrol);
@@ -206,16 +206,16 @@ public:
DECLARE_VIDEO_START(dambustr);
DECLARE_VIDEO_START(harem);
DECLARE_VIDEO_START(bagmanmc);
-
+
UINT32 screen_update_galaxold(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
UINT32 screen_update_dambustr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
-
+
INTERRUPT_GEN_MEMBER(hunchbks_vh_interrupt);
TIMER_CALLBACK_MEMBER(stars_blink_callback);
TIMER_CALLBACK_MEMBER(stars_scroll_callback);
TIMER_DEVICE_CALLBACK_MEMBER(galaxold_interrupt_timer);
IRQ_CALLBACK_MEMBER(hunchbkg_irq_callback);
-
+
void state_save_register();
void video_start_common();
void pisces_modify_spritecode(UINT8 *spriteram, int *code, int *flipx, int *flipy, int offs);
diff --git a/src/mame/includes/renegade.h b/src/mame/includes/renegade.h
index e6940c2663f..3e8fc56db87 100644
--- a/src/mame/includes/renegade.h
+++ b/src/mame/includes/renegade.h
@@ -84,7 +84,7 @@ public:
DECLARE_WRITE8_MEMBER(adpcm_addr_w);
DECLARE_WRITE8_MEMBER(adpcm_stop_w);
DECLARE_WRITE_LINE_MEMBER(adpcm_int);
-
+
DECLARE_DRIVER_INIT(kuniokun);
DECLARE_DRIVER_INIT(kuniokunb);
DECLARE_DRIVER_INIT(renegade);
diff --git a/src/mame/includes/yunsun16.h b/src/mame/includes/yunsun16.h
index 8ae94f9abb0..3f230255c5e 100644
--- a/src/mame/includes/yunsun16.h
+++ b/src/mame/includes/yunsun16.h
@@ -27,7 +27,7 @@ public:
required_device<gfxdecode_device> m_gfxdecode;
required_device<screen_device> m_screen;
required_device<palette_device> m_palette;
-
+
/* memory pointers */
required_shared_ptr<UINT16> m_vram_0;
required_shared_ptr<UINT16> m_vram_1;
diff --git a/src/mame/includes/zac2650.h b/src/mame/includes/zac2650.h
index 8ae5ebd076e..678d2252daf 100644
--- a/src/mame/includes/zac2650.h
+++ b/src/mame/includes/zac2650.h
@@ -19,7 +19,7 @@ public:
required_device<gfxdecode_device> m_gfxdecode;
required_device<screen_device> m_screen;
required_device<palette_device> m_palette;
-
+
/* memory pointers */
required_shared_ptr<UINT8> m_videoram;
required_shared_ptr<UINT8> m_s2636_0_ram;
@@ -29,7 +29,7 @@ public:
int m_CollisionBackground;
int m_CollisionSprite;
tilemap_t *m_bg_tilemap;
-
+
DECLARE_WRITE8_MEMBER(tinvader_sound_w);
DECLARE_WRITE8_MEMBER(tinvader_videoram_w);
DECLARE_READ8_MEMBER(zac_s2636_r);
diff --git a/src/mame/includes/zaccaria.h b/src/mame/includes/zaccaria.h
index e271f12fd37..e1a1961e8e4 100644
--- a/src/mame/includes/zaccaria.h
+++ b/src/mame/includes/zaccaria.h
@@ -20,9 +20,9 @@ public:
m_spriteram(*this, "spriteram"),
m_spriteram2(*this, "spriteram2"),
m_dsw_port(*this, "DSW") { }
-
-
-
+
+
+
/* devices */
required_device<cpu_device> m_maincpu;
required_device<cpu_device> m_audio2;
@@ -32,13 +32,13 @@ public:
required_device<tms5220_device> m_tms;
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
-
+
/* memory pointers */
required_shared_ptr<UINT8> m_videoram;
required_shared_ptr<UINT8> m_attributesram;
required_shared_ptr<UINT8> m_spriteram;
required_shared_ptr<UINT8> m_spriteram2;
-
+
required_ioport_array<3> m_dsw_port;
int m_dsw_sel;
@@ -49,7 +49,7 @@ public:
int m_toggle;
tilemap_t *m_bg_tilemap;
UINT8 m_nmi_mask;
-
+
DECLARE_READ8_MEMBER(dsw_r);
DECLARE_WRITE8_MEMBER(sound_command_w);
DECLARE_WRITE8_MEMBER(sound1_command_w);
diff --git a/src/mame/machine/atarigen.c b/src/mame/machine/atarigen.c
index 95b84b563f4..ccf75a5eeb7 100644
--- a/src/mame/machine/atarigen.c
+++ b/src/mame/machine/atarigen.c
@@ -1199,7 +1199,7 @@ void atarigen_state::device_post_load()
{
if (!m_slapstic_device)
fatalerror("Slapstic device is missing?\n");
-
+
slapstic_update_bank(m_slapstic_device->slapstic_bank());
}
}
diff --git a/src/mame/mame.lst b/src/mame/mame.lst
index 2d3a99edc08..24a61b694d8 100644
--- a/src/mame/mame.lst
+++ b/src/mame/mame.lst
@@ -4642,7 +4642,7 @@ wb32 // (c) 1988 Sega / Westone (FD1094, decrypted)
wrestwar // (c) 1989 (8751)
wrestwar2 // (c) 1989 (FD1094, decrypted)
wrestwar1 // (c) 1989 (FD1094, decrypted)
-fantzoneta // (c) 2008 Sega / M2 (bootleg conversion)
+fantzoneta // (c) 2008 Sega / M2 (bootleg conversion)
// System 16C
fantzn2x // (c) 2008 Sega / M2
@@ -6861,7 +6861,7 @@ sprint4 // 008716 1977/12 [6502]
sprint4a // 008716 1977/12 [6502]
nitedrvr // 006321 1976/10 [6502]
dominos // 007305 1977/01 [6502]
-dominos4 // 007754-007765 ??????? [6502]
+dominos4 // 007754-007765 ??????? [6502]
triplhnt // 008422-008791 1977/04 [6800]
sprint8 // ?????? 1977/05 [6800]
sprint8a // ?????? 1977/05 [6800]
@@ -6891,7 +6891,7 @@ sbrkoutc // unrealeased proto
sbrkoutct // 034555-034559 proto ???? [6502]
atarifb // 033xxx 1978/10 [6502]
atarifb1 // 033xxx 1978/10 [6502]
-atarifb2 // 035330-035350 ??? [6502]
+atarifb2 // 035330-035350 ??? [6502]
orbit // 033689-033702 1978/11 [6800]
boxer // ?????? prototype 1978 [6502]
wolfpack // ?????? prototype [6502]
@@ -9245,7 +9245,7 @@ yamyamk // (c) 1990 Dooyong
wiseguy // (c) 1990 Dooyong
lastday // (c) 1990 Dooyong
lastdaya // (c) 1990 Dooyong
-ddaydoo // (c) 1990 Dooyong
+ddaydoo // (c) 1990 Dooyong
gulfstrm // (c) 1991 Dooyong
gulfstrma // (c) 1991 Dooyong
gulfstrmb // (c) 1991 Dooyong
@@ -10374,7 +10374,7 @@ thedeep // (c) 1987 Wood Place
rundeep // (c) 1988 Cream (bootleg?)
wallc // (c) 1984 Midcoin
wallca // (c) 1984 Midcoin
-brkblast // bootleg (Fadesa)
+brkblast // bootleg (Fadesa)
sidampkr //
wink // (c) 1985 Midcoin
winka // (c) 1985 Midcoin
diff --git a/src/mame/video/chihiro.c b/src/mame/video/chihiro.c
index 15e9b418150..69a6e50e812 100644
--- a/src/mame/video/chihiro.c
+++ b/src/mame/video/chihiro.c
@@ -546,7 +546,7 @@ int vertex_program_simulator::step()
}
}
if ((d->OutputWriteMask != 0) && (d->MultiplexerControl == 0)) {
- //o[1] = 1;
+ //o[1] = 1;
if (d->OutputSelect) { // assign to output
int wm = d->OutputWriteMask;
for (p1 = 0; p1 < 4; p1++) {
@@ -737,55 +737,55 @@ void vertex_program_simulator::compute_vectorial_operation(float t_out[4], int i
t_out[2] = par_in[p1_A + 2] * par_in[p2_B + 2];
t_out[3] = par_in[p1_A + 3] * par_in[p2_B + 3];
break;
- case 3: // "ADD"
+ case 3: // "ADD"
t_out[0] = par_in[p1_A + 0] + par_in[p3_C + 0];
t_out[1] = par_in[p1_A + 1] + par_in[p3_C + 1];
t_out[2] = par_in[p1_A + 2] + par_in[p3_C + 2];
t_out[3] = par_in[p1_A + 3] + par_in[p3_C + 3];
break;
- case 4: // "MAD"
+ case 4: // "MAD"
t_out[0] = par_in[p1_A + 0] * par_in[p2_B + 0] + par_in[p3_C + 0];
t_out[1] = par_in[p1_A + 1] * par_in[p2_B + 1] + par_in[p3_C + 1];
t_out[2] = par_in[p1_A + 2] * par_in[p2_B + 2] + par_in[p3_C + 2];
t_out[3] = par_in[p1_A + 3] * par_in[p2_B + 3] + par_in[p3_C + 3];
break;
- case 5: // "DP3"
+ case 5: // "DP3"
t_out[0] = par_in[p1_A + 0] * par_in[p2_B + 0] + par_in[p1_A + 1] * par_in[p2_B + 1] + par_in[p1_A + 2] * par_in[p2_B + 2];
t_out[1] = t_out[2] = t_out[3] = t_out[0];
break;
- case 6: // "DPH"
+ case 6: // "DPH"
t_out[0] = par_in[p1_A + 0] * par_in[p2_B + 0] + par_in[p1_A + 1] * par_in[p2_B + 1] + par_in[p1_A + 2] * par_in[p2_B + 2] + par_in[p2_B + 3];
t_out[1] = t_out[2] = t_out[3] = t_out[0];
break;
- case 7: // "DP4"
+ case 7: // "DP4"
t_out[0] = par_in[p1_A + 0] * par_in[p2_B + 0] + par_in[p1_A + 1] * par_in[p2_B + 1] + par_in[p1_A + 2] * par_in[p2_B + 2] + par_in[p1_A + 3] * par_in[p2_B + 3];
t_out[1] = t_out[2] = t_out[3] = t_out[0];
break;
- case 8: // "DST"
+ case 8: // "DST"
t_out[0] = 1.0;
t_out[1] = par_in[p1_A + 1] * par_in[p2_B + 1];
t_out[2] = par_in[p1_A + 2];
t_out[3] = par_in[p2_B + 3];
break;
- case 9: // "MIN"
+ case 9: // "MIN"
t_out[0] = fmin(par_in[p1_A + 0], par_in[p2_B + 0]);
t_out[1] = fmin(par_in[p1_A + 1], par_in[p2_B + 1]);
t_out[2] = fmin(par_in[p1_A + 2], par_in[p2_B + 2]);
t_out[3] = fmin(par_in[p1_A + 3], par_in[p2_B + 3]);
break;
- case 10: // "MAX"
+ case 10: // "MAX"
t_out[0] = fmax(par_in[p1_A + 0], par_in[p2_B + 0]);
t_out[1] = fmax(par_in[p1_A + 1], par_in[p2_B + 1]);
t_out[2] = fmax(par_in[p1_A + 2], par_in[p2_B + 2]);
t_out[3] = fmax(par_in[p1_A + 3], par_in[p2_B + 3]);
break;
- case 11: // "SLT"
+ case 11: // "SLT"
t_out[0] = (par_in[p1_A + 0] < par_in[p2_B + 0]) ? 1.0 : 0;
t_out[1] = (par_in[p1_A + 1] < par_in[p2_B + 1]) ? 1.0 : 0;
t_out[2] = (par_in[p1_A + 2] < par_in[p2_B + 2]) ? 1.0 : 0;
t_out[3] = (par_in[p1_A + 3] < par_in[p2_B + 3]) ? 1.0 : 0;
break;
- case 12: // "SGE"
+ case 12: // "SGE"
t_out[0] = (par_in[p1_A + 0] >= par_in[p2_B + 0]) ? 1.0 : 0;
t_out[1] = (par_in[p1_A + 1] >= par_in[p2_B + 1]) ? 1.0 : 0;
t_out[2] = (par_in[p1_A + 2] >= par_in[p2_B + 2]) ? 1.0 : 0;
@@ -817,16 +817,16 @@ void vertex_program_simulator::compute_scalar_operation(float t_out[4], int inst
t_out[2] = par_in[p3_C + 2];
t_out[3] = par_in[p3_C + 3];
break;
- case 2: // "RCP"
+ case 2: // "RCP"
t_out[0] = t_out[1] = t_out[2] = t_out[3] = 1.0 / par_in[p3_C + 0];
break;
- case 3: // "RCC"
+ case 3: // "RCC"
t_out[0] = t_out[1] = t_out[2] = t_out[3] = 1.0 / par_in[p3_C + 0]; // ?
break;
- case 4: // "RSQ"
+ case 4: // "RSQ"
t_out[0] = t_out[1] = t_out[2] = t_out[3] = 1.0 / sqrt(abs(par_in[p3_C + 0]));
break;
- case 5: // "EXP"
+ case 5: // "EXP"
t_out[0] = pow(2, floor(par_in[p3_C + 0]));
t_out[1] = par_in[p3_C + 0] - floor(par_in[p3_C + 0]);
t.f = pow(2, par_in[p3_C + 0]);
@@ -834,7 +834,7 @@ void vertex_program_simulator::compute_scalar_operation(float t_out[4], int inst
t_out[2] = t.f;
t_out[3] = 1.0;
break;
- case 6: // "LOG"
+ case 6: // "LOG"
t_out[1] = frexp(par_in[p3_C + 0], &e)*2.0; // frexp gives mantissa as 0.5....1
t_out[0] = e - 1;
t.f = log2(abs(par_in[p3_C + 0]));
@@ -958,27 +958,27 @@ void nv2a_renderer::geforce_read_dma_object(UINT32 handle, UINT32 &offset, UINT3
{
int xx1,yy1,xx2,yy2;
- xx1=x1;
- xx2=x2;
- yy1=y1;
- yy2=y2;
- if (xx1 == xx2) {
- if (yy1 > yy2) {
- int t=yy1;
- yy1=yy2;
- yy2=t;
- }
- for (int y=yy1;y <= yy2;y++)
- *((UINT32 *)bmp.raw_pixptr(y,xx1))= -1;
- } else if (yy1 == yy2) {
- if (xx1 > xx2) {
- int t=xx1;
- xx1=xx2;
- xx2=t;
- }
- for (int x=xx1;x <= xx2;x++)
- *((UINT32 *)bmp.raw_pixptr(yy1,x))= -1;
- }
+ xx1=x1;
+ xx2=x2;
+ yy1=y1;
+ yy2=y2;
+ if (xx1 == xx2) {
+ if (yy1 > yy2) {
+ int t=yy1;
+ yy1=yy2;
+ yy2=t;
+ }
+ for (int y=yy1;y <= yy2;y++)
+ *((UINT32 *)bmp.raw_pixptr(y,xx1))= -1;
+ } else if (yy1 == yy2) {
+ if (xx1 > xx2) {
+ int t=xx1;
+ xx1=xx2;
+ xx2=t;
+ }
+ for (int x=xx1;x <= xx2;x++)
+ *((UINT32 *)bmp.raw_pixptr(yy1,x))= -1;
+ }
}*/
inline UINT32 convert_a4r4g4b4_a8r8g8b8(UINT32 a4r4g4b4)
diff --git a/src/mame/video/galpani2.c b/src/mame/video/galpani2.c
index 9e565cb3209..01626a5ee70 100644
--- a/src/mame/video/galpani2.c
+++ b/src/mame/video/galpani2.c
@@ -115,7 +115,7 @@ void galpani2_state::copybg8(screen_device &screen, bitmap_rgb32 &bitmap, const
void galpani2_state::copybg15(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
{
UINT16* ram = m_bg15 + 0x40000/2;
-
+
//int x = 0;
//int y = 0;
diff --git a/src/mame/video/segaic16.c b/src/mame/video/segaic16.c
index 94d16641193..3a5882683e7 100644
--- a/src/mame/video/segaic16.c
+++ b/src/mame/video/segaic16.c
@@ -1126,7 +1126,7 @@ void segaic16_video_device::tilemap_init(int which, int type, int colorbase, int
info->tilemaps[pagenum]->set_scrolldx(0, 22);
info->tilemaps[pagenum]->set_scrolldy(0, 38);
}
-
+
save_item(NAME(info->flip), which);
save_item(NAME(info->rowscroll), which);
save_item(NAME(info->colscroll), which);
diff --git a/src/mame/video/tigeroad.c b/src/mame/video/tigeroad.c
index 76c7d5d6e9b..757f896a5b5 100644
--- a/src/mame/video/tigeroad.c
+++ b/src/mame/video/tigeroad.c
@@ -122,4 +122,3 @@ UINT32 tigeroad_state::screen_update_tigeroad(screen_device &screen, bitmap_ind1
m_fg_tilemap->draw(screen, bitmap, cliprect, 0, 2);
return 0;
}
-
diff --git a/src/mame/video/tigeroad_spr.c b/src/mame/video/tigeroad_spr.c
index a180f8ba56a..d7e764f4d6c 100644
--- a/src/mame/video/tigeroad_spr.c
+++ b/src/mame/video/tigeroad_spr.c
@@ -1,14 +1,14 @@
/*
- very simple sprite scheme, used by some Capcom games and hardware cloned from them
+ very simple sprite scheme, used by some Capcom games and hardware cloned from them
- bionicc.c
- tigeroad.c
- supduck.c
+ bionicc.c
+ tigeroad.c
+ supduck.c
- it is unknown if this is handled by a custom chip, or simple logic.
- y positions are inverted in Bionic Commando, but it seems otherwise the same as
- Tiger Road
+ it is unknown if this is handled by a custom chip, or simple logic.
+ y positions are inverted in Bionic Commando, but it seems otherwise the same as
+ Tiger Road
*/
@@ -39,7 +39,7 @@ void tigeroad_spr_device::device_reset()
4 words per sprite
0 ---- ---t tttt tttt = tile number
-
+
1 ---- ---- --cc cc-- = colour
1 ---- ---- ---- --x- = flip x
1 ---- ---- ---- ---y = flip y
diff --git a/src/mame/video/zac2650.c b/src/mame/video/zac2650.c
index c4adb273f56..baf218d4e49 100644
--- a/src/mame/video/zac2650.c
+++ b/src/mame/video/zac2650.c
@@ -125,7 +125,7 @@ void zac2650_state::video_start()
m_gfxdecode->gfx(1)->set_source(m_s2636_0_ram);
m_gfxdecode->gfx(2)->set_source(m_s2636_0_ram);
-
+
save_item(NAME(m_bitmap));
save_item(NAME(m_spritebitmap));
save_item(NAME(m_CollisionBackground));
diff --git a/src/mess/drivers/amaztron.c b/src/mess/drivers/amaztron.c
index 3dfdb6ac319..b8e686857ef 100644
--- a/src/mess/drivers/amaztron.c
+++ b/src/mess/drivers/amaztron.c
@@ -4,7 +4,7 @@
Coleco Amaze-A-Tron
* TMS1100 MCU, labeled MP3405(die label too)
-
+
This is an electronic board game with a selection of 8 maze games,
most of them for 2 players. A 5x5 playing grid and four markers are
required to play. Refer to the official manual for more information.
@@ -42,9 +42,9 @@ public:
DECLARE_READ8_MEMBER(read_k);
DECLARE_WRITE16_MEMBER(write_o);
DECLARE_WRITE16_MEMBER(write_r);
-
+
void leds_update();
-
+
virtual void machine_start();
};
@@ -85,11 +85,11 @@ WRITE16_MEMBER(amaztron_state::write_r)
// R6,R7: lamps
output_set_lamp_value(0, data >> 6 & 1);
output_set_lamp_value(1, data >> 7 & 1);
-
+
// R8,R9: select digit
m_r = data;
leds_update();
-
+
// R10: speaker out
m_speaker->level_w(data >> 10 & 1);
}
@@ -166,7 +166,7 @@ void amaztron_state::machine_start()
{
m_r = 0;
m_o = 0;
-
+
save_item(NAME(m_r));
save_item(NAME(m_o));
}
diff --git a/src/mess/drivers/bitgraph.c b/src/mess/drivers/bitgraph.c
index 7171ed5ae6d..684443f6bcd 100644
--- a/src/mess/drivers/bitgraph.c
+++ b/src/mess/drivers/bitgraph.c
@@ -165,16 +165,16 @@ private:
static ADDRESS_MAP_START(bitgrapha_mem, AS_PROGRAM, 16, bitgraph_state)
ADDRESS_MAP_UNMAP_HIGH
AM_RANGE(0x000000, 0x007fff) AM_ROM
- AM_RANGE(0x010000, 0x010001) AM_DEVREADWRITE8(ACIA0_TAG, acia6850_device, data_r, data_w, 0xff00) // HOST
+ AM_RANGE(0x010000, 0x010001) AM_DEVREADWRITE8(ACIA0_TAG, acia6850_device, data_r, data_w, 0xff00) // HOST
AM_RANGE(0x010002, 0x010003) AM_DEVREADWRITE8(ACIA0_TAG, acia6850_device, status_r, control_w, 0xff00)
- AM_RANGE(0x010008, 0x010009) AM_DEVREADWRITE8(ACIA1_TAG, acia6850_device, data_r, data_w, 0x00ff) // KEYBOARD
+ AM_RANGE(0x010008, 0x010009) AM_DEVREADWRITE8(ACIA1_TAG, acia6850_device, data_r, data_w, 0x00ff) // KEYBOARD
AM_RANGE(0x01000a, 0x01000b) AM_DEVREADWRITE8(ACIA1_TAG, acia6850_device, status_r, control_w, 0x00ff)
- AM_RANGE(0x010010, 0x010011) AM_DEVREADWRITE8(ACIA2_TAG, acia6850_device, data_r, data_w, 0x00ff) // DEBUGGER
+ AM_RANGE(0x010010, 0x010011) AM_DEVREADWRITE8(ACIA2_TAG, acia6850_device, data_r, data_w, 0x00ff) // DEBUGGER
AM_RANGE(0x010012, 0x010013) AM_DEVREADWRITE8(ACIA2_TAG, acia6850_device, status_r, control_w, 0x00ff)
- AM_RANGE(0x010018, 0x010019) AM_DEVREADWRITE8(ACIA3_TAG, acia6850_device, data_r, data_w, 0x00ff) // POINTER
+ AM_RANGE(0x010018, 0x010019) AM_DEVREADWRITE8(ACIA3_TAG, acia6850_device, data_r, data_w, 0x00ff) // POINTER
AM_RANGE(0x01001a, 0x01001b) AM_DEVREADWRITE8(ACIA3_TAG, acia6850_device, status_r, control_w, 0x00ff)
AM_RANGE(0x010020, 0x010027) AM_READWRITE8(adlc_r, adlc_w, 0xff00)
- AM_RANGE(0x010028, 0x01002f) AM_READWRITE8(pia_r, pia_w, 0xff00) // EAROM, PSG
+ AM_RANGE(0x010028, 0x01002f) AM_READWRITE8(pia_r, pia_w, 0xff00) // EAROM, PSG
AM_RANGE(0x010030, 0x010031) AM_WRITE(baud_write)
AM_RANGE(0x3e0000, 0x3fffff) AM_RAM
ADDRESS_MAP_END
@@ -182,18 +182,18 @@ ADDRESS_MAP_END
static ADDRESS_MAP_START(bitgraphb_mem, AS_PROGRAM, 16, bitgraph_state)
ADDRESS_MAP_UNMAP_HIGH
AM_RANGE(0x000000, 0x007fff) AM_ROM
- AM_RANGE(0x010000, 0x010001) AM_DEVREADWRITE8(ACIA0_TAG, acia6850_device, data_r, data_w, 0xff00) // HOST
+ AM_RANGE(0x010000, 0x010001) AM_DEVREADWRITE8(ACIA0_TAG, acia6850_device, data_r, data_w, 0xff00) // HOST
AM_RANGE(0x010002, 0x010003) AM_DEVREADWRITE8(ACIA0_TAG, acia6850_device, status_r, control_w, 0xff00)
- AM_RANGE(0x010008, 0x010009) AM_DEVREADWRITE8(ACIA1_TAG, acia6850_device, data_r, data_w, 0x00ff) // KEYBOARD
+ AM_RANGE(0x010008, 0x010009) AM_DEVREADWRITE8(ACIA1_TAG, acia6850_device, data_r, data_w, 0x00ff) // KEYBOARD
AM_RANGE(0x01000a, 0x01000b) AM_DEVREADWRITE8(ACIA1_TAG, acia6850_device, status_r, control_w, 0x00ff)
- AM_RANGE(0x010010, 0x010011) AM_DEVREADWRITE8(ACIA2_TAG, acia6850_device, data_r, data_w, 0x00ff) // DEBUGGER
+ AM_RANGE(0x010010, 0x010011) AM_DEVREADWRITE8(ACIA2_TAG, acia6850_device, data_r, data_w, 0x00ff) // DEBUGGER
AM_RANGE(0x010012, 0x010013) AM_DEVREADWRITE8(ACIA2_TAG, acia6850_device, status_r, control_w, 0x00ff)
AM_RANGE(0x01001a, 0x01001b) AM_WRITE8(misccr_write, 0x00ff)
AM_RANGE(0x010020, 0x010027) AM_READWRITE8(adlc_r, adlc_w, 0xff00)
- AM_RANGE(0x010028, 0x01002f) AM_READWRITE8(pia_r, pia_w, 0xff00) // EAROM, PSG
+ AM_RANGE(0x010028, 0x01002f) AM_READWRITE8(pia_r, pia_w, 0xff00) // EAROM, PSG
AM_RANGE(0x010030, 0x010031) AM_WRITE(baud_write)
-// AM_RANGE(0x010030, 0x010037) AM_READ8(ppu_read, 0x00ff)
-// AM_RANGE(0x010038, 0x01003f) AM_WRITE8(ppu_write, 0x00ff)
+// AM_RANGE(0x010030, 0x010037) AM_READ8(ppu_read, 0x00ff)
+// AM_RANGE(0x010038, 0x01003f) AM_WRITE8(ppu_write, 0x00ff)
AM_RANGE(0x380000, 0x3fffff) AM_RAM
ADDRESS_MAP_END
@@ -257,8 +257,8 @@ WRITE8_MEMBER(bitgraph_state::pia_pb_w)
m_pia_b = data;
switch (m_pia_b & 0x03) {
- case 2: m_psg->data_w(space, 0, m_pia_a); break;
- case 3: m_psg->address_w(space, 0, m_pia_a); break;
+ case 2: m_psg->data_w(space, 0, m_pia_a); break;
+ case 3: m_psg->address_w(space, 0, m_pia_a); break;
}
if (BIT(m_pia_b, 3)) {
@@ -302,10 +302,10 @@ WRITE_LINE_MEMBER(bitgraph_state::system_clock_write)
WRITE16_MEMBER(bitgraph_state::baud_write)
{
DBG_LOG(1,"Baud", ("%04X\n", data));
- m_dbrgb->str_w(data & 15); // 2 DBG
- m_dbrga->stt_w((data >> 4) & 15); // 1 KBD
- m_dbrgb->stt_w((data >> 8) & 15); // 3 PNT
- m_dbrga->str_w((data >> 12) & 15); // 0 HOST
+ m_dbrgb->str_w(data & 15); // 2 DBG
+ m_dbrga->stt_w((data >> 4) & 15); // 1 KBD
+ m_dbrgb->stt_w((data >> 8) & 15); // 3 PNT
+ m_dbrga->str_w((data >> 12) & 15); // 0 HOST
}
WRITE_LINE_MEMBER(bitgraph_state::com8116_a_fr_w)
@@ -398,18 +398,18 @@ WRITE8_MEMBER(bitgraph_state::ppu_write)
#ifdef UNUSED_FUNCTION
static ADDRESS_MAP_START(ppu_io, AS_IO, 8, bitgraph_state)
-// AM_RANGE(0x00, 0x00) AM_READ(ppu_irq)
-// AM_RANGE(MCS48_PORT_P1, MCS48_PORT_P1)
-// AM_RANGE(MCS48_PORT_T0, MCS48_PORT_T0) AM_READ(ppu_t0_r)
+// AM_RANGE(0x00, 0x00) AM_READ(ppu_irq)
+// AM_RANGE(MCS48_PORT_P1, MCS48_PORT_P1)
+// AM_RANGE(MCS48_PORT_T0, MCS48_PORT_T0) AM_READ(ppu_t0_r)
AM_RANGE(MCS48_PORT_PROG, MCS48_PORT_PROG) AM_DEVWRITE("i8243", i8243_device, i8243_prog_w)
ADDRESS_MAP_END
#endif
/*
- p4 O: Centronics data 3..0
- p5 O: Centronics data 7..4
- p6 O: Centronics control
- p7 I: Centronics status
+ p4 O: Centronics data 3..0
+ p5 O: Centronics data 7..4
+ p6 O: Centronics control
+ p7 I: Centronics status
*/
WRITE8_MEMBER(bitgraph_state::ppu_i8243_w)
{
@@ -572,7 +572,7 @@ static MACHINE_CONFIG_START( bitgrphb, bitgraph_state )
MCFG_CPU_PROGRAM_MAP(bitgraphb_mem)
MCFG_FRAGMENT_ADD(bg_motherboard)
-// MCFG_FRAGMENT_ADD(bg_ppu)
+// MCFG_FRAGMENT_ADD(bg_ppu)
MCFG_DEVICE_ADD("system_clock", CLOCK, 1040)
MCFG_CLOCK_SIGNAL_HANDLER(WRITELINE(bitgraph_state, system_clock_write))
diff --git a/src/mess/drivers/cnsector.c b/src/mess/drivers/cnsector.c
index a62a581b89c..b76f85a3358 100644
--- a/src/mess/drivers/cnsector.c
+++ b/src/mess/drivers/cnsector.c
@@ -4,7 +4,7 @@
Parker Brothers Code Name: Sector
* MP0905BNL ZA0379 (die labeled 0970F-05B)
-
+
This is a tabletop submarine pursuit game. A grid board and small toy
boats are used to remember your locations (a Paint app should be ok too).
Refer to the official manual for more information, it is not a simple game.
@@ -69,30 +69,30 @@ public:
void cnsector_state::leds_update()
{
UINT16 active_state[0x10];
-
+
for (int i = 0; i < 0x10; i++)
{
active_state[i] = 0;
-
+
for (int j = 0; j < 0x10; j++)
{
int di = j << 4 | i;
-
+
// turn on powered leds
if (m_leds_state[i] >> j & 1)
m_leds_decay[di] = LEDS_DECAY_TIME;
-
+
// determine active state
int ds = (m_leds_decay[di] != 0) ? 1 : 0;
active_state[i] |= (ds << j);
}
}
-
+
// on difference, send to output
for (int i = 0; i < 0x10; i++)
if (m_leds_cache[i] != active_state[i])
output_set_digit_value(i, active_state[i]);
-
+
memcpy(m_leds_cache, active_state, sizeof(m_leds_cache));
}
@@ -102,7 +102,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(cnsector_state::leds_decay_tick)
for (int i = 0; i < 0x100; i++)
if (!(m_leds_state[i & 0xf] >> (i>>4) & 1) && m_leds_decay[i])
m_leds_decay[i]--;
-
+
leds_update();
}
@@ -122,7 +122,7 @@ READ8_MEMBER(cnsector_state::read_k)
for (int i = 0; i < 5; i++)
if (m_o >> i & 1)
k |= m_button_matrix[i]->read();
-
+
return k;
}
@@ -201,7 +201,7 @@ void cnsector_state::machine_start()
memset(m_leds_decay, 0, sizeof(m_leds_decay));
m_o = 0;
-
+
// register for savestates
save_item(NAME(m_leds_state));
save_item(NAME(m_leds_cache));
@@ -218,7 +218,7 @@ static MACHINE_CONFIG_START( cnsector, cnsector_state )
MCFG_TMS1XXX_READ_K_CB(READ8(cnsector_state, read_k))
MCFG_TMS1XXX_WRITE_O_CB(WRITE16(cnsector_state, write_o))
MCFG_TMS1XXX_WRITE_R_CB(WRITE16(cnsector_state, write_r))
-
+
MCFG_TIMER_DRIVER_ADD_PERIODIC("leds_decay", cnsector_state, leds_decay_tick, attotime::from_msec(10))
MCFG_DEFAULT_LAYOUT(layout_cnsector)
diff --git a/src/mess/drivers/comp4.c b/src/mess/drivers/comp4.c
index 86735250f26..240f259cef1 100644
--- a/src/mess/drivers/comp4.c
+++ b/src/mess/drivers/comp4.c
@@ -4,11 +4,11 @@
Milton Bradley Comp IV
* TMC0904NL CP0904A (die labeled 4A0970D-04A)
-
+
This is small tabletop Mastermind game; a code-breaking game where the player
needs to find out the correct sequence of colours (numbers in our case).
It is known as Logic 5 in Europe, and as Pythaligoras in Japan.
-
+
Press the R key to start, followed by a set of unique numbers and E.
Refer to the official manual for more information.
@@ -74,7 +74,7 @@ void comp4_state::leds_update()
// turn on powered leds
if (m_leds_state >> i & 1)
m_leds_decay[i] = LEDS_DECAY_TIME;
-
+
// send to output
output_set_lamp_value(i, (m_leds_decay[i] != 0) ? 1 : 0);
}
@@ -86,7 +86,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(comp4_state::leds_decay_tick)
for (int i = 0; i < 0x10; i++)
if (!(m_leds_state >> i & 1) && m_leds_decay[i])
m_leds_decay[i]--;
-
+
leds_update();
}
@@ -106,7 +106,7 @@ READ8_MEMBER(comp4_state::read_k)
for (int i = 0; i < 3; i++)
if (m_o >> (i+1) & 1)
k |= m_button_matrix[i]->read();
-
+
return k;
}
@@ -173,7 +173,7 @@ void comp4_state::machine_start()
memset(m_leds_decay, 0, sizeof(m_leds_decay));
m_o = 0;
-
+
// register for savestates
save_item(NAME(m_leds_state));
save_item(NAME(m_leds_decay));
@@ -189,7 +189,7 @@ static MACHINE_CONFIG_START( comp4, comp4_state )
MCFG_TMS1XXX_READ_K_CB(READ8(comp4_state, read_k))
MCFG_TMS1XXX_WRITE_O_CB(WRITE16(comp4_state, write_o))
MCFG_TMS1XXX_WRITE_R_CB(WRITE16(comp4_state, write_r))
-
+
MCFG_TIMER_DRIVER_ADD_PERIODIC("leds_decay", comp4_state, leds_decay_tick, attotime::from_msec(10))
MCFG_DEFAULT_LAYOUT(layout_comp4)
diff --git a/src/mess/drivers/ec184x.c b/src/mess/drivers/ec184x.c
index 2a21c5a476c..a25bb42395c 100644
--- a/src/mess/drivers/ec184x.c
+++ b/src/mess/drivers/ec184x.c
@@ -202,7 +202,7 @@ ADDRESS_MAP_END
static ADDRESS_MAP_START( ec1847_io, AS_IO, 8, ec184x_state )
ADDRESS_MAP_UNMAP_HIGH
-// AM_RANGE(0x0210, 0x021f) AM_RAM // internal (non-standard?) bus extender
+// AM_RANGE(0x0210, 0x021f) AM_RAM // internal (non-standard?) bus extender
ADDRESS_MAP_END
diff --git a/src/mess/drivers/excali64.c b/src/mess/drivers/excali64.c
index 3c937265a20..687a65f270f 100644
--- a/src/mess/drivers/excali64.c
+++ b/src/mess/drivers/excali64.c
@@ -101,7 +101,7 @@ public:
DECLARE_WRITE8_MEMBER(motor_w);
DECLARE_MACHINE_RESET(excali64);
required_device<palette_device> m_palette;
-
+
private:
const UINT8 *m_p_chargen;
UINT8 *m_p_videoram;
@@ -585,7 +585,7 @@ MC6845_UPDATE_ROW( excali64_state::update_row )
}
else
gfx = m_p_chargen[(chr<<4) | ra]; // normal character
-
+
gfx ^= (x == cursor_x) ? 0xff : 0;
/* Display a scanline of a character */
diff --git a/src/mess/drivers/gamate.c b/src/mess/drivers/gamate.c
index cf48dbf80df..4ef0a94ab4a 100644
--- a/src/mess/drivers/gamate.c
+++ b/src/mess/drivers/gamate.c
@@ -2,7 +2,7 @@
PeT mess@utanet.at 2007, 2014
Peter Wilhelmsen peter.wilhelmsen@gmail.com
Morten Shearman Kirkegaard morten+gamate@afdelingp.dk
- Juan Félix Mateos vectrex@hackermesh.org
+ Juan F??lix Mateos vectrex@hackermesh.org
******************************************************************************/
#include "emu.h"
@@ -18,7 +18,7 @@ public:
: driver_device(mconfig, type, tag)
, m_maincpu(*this, "maincpu")
, m_cart(*this, "cartslot")
-// , m_gfxdecode(*this, "gfxdecode")
+// , m_gfxdecode(*this, "gfxdecode")
, m_io_joy(*this, "JOY")
, m_palette(*this, "palette")
, m_bios(*this, "bios")
@@ -47,14 +47,14 @@ private:
struct
{
- UINT8 reg[8];
- struct {
- bool write;
- bool page2; // else page1
+ UINT8 reg[8];
+ struct {
+ bool write;
+ bool page2; // else page1
UINT8 ypos, xpos/*tennis*/;
- UINT8 data[2][0x100][0x20];
- } bitmap;
- UINT8 x, y;
+ UINT8 data[2][0x100][0x20];
+ } bitmap;
+ UINT8 x, y;
bool y_increment;
} video;
@@ -68,7 +68,7 @@ private:
required_device<cpu_device> m_maincpu;
required_device<generic_slot_device> m_cart;
-// required_device<gfxdecode_device> m_gfxdecode;
+// required_device<gfxdecode_device> m_gfxdecode;
required_ioport m_io_joy;
required_device<palette_device> m_palette;
required_shared_ptr<UINT8> m_bios;
@@ -113,27 +113,27 @@ READ8_MEMBER( gamate_state::protection_r ) { return 1; }
WRITE8_MEMBER( gamate_state::gamate_video_w )
{
- video.reg[offset]=data;
- switch (offset) {
- case 1: video.bitmap.write=data&0xc0; // more addressing mode
+ video.reg[offset]=data;
+ switch (offset) {
+ case 1: video.bitmap.write=data&0xc0; // more addressing mode
video.y_increment=data&0x40;
break;
case 2: video.bitmap.xpos=data;break; // at least 7 bits
case 3: video.bitmap.ypos=data;break; // at least 7 bits
- case 4: video.bitmap.page2=data&0x80;video.x=data&0x7f;break;
- case 5: video.y=data;break;
- case 7:
- if (video.bitmap.write) {
- if (video.x<ARRAY_LENGTH(video.bitmap.data[0][0]) /*&& video.y<ARRAY_LENGTH(video.bitmap.data[0])*/)
- video.bitmap.data[video.bitmap.page2][video.y][video.x]=data;
- else
- logerror("%.6f %04x video bitmap x %x invalid\n",machine().time().as_double(), m_maincpu->pc(), video.x);
- } else {
- video.bitmap.data[0][video.y][video.x&(ARRAY_LENGTH(video.bitmap.data[0][0])-1)]=data;
- }
- if (video.y_increment) video.y++;
+ case 4: video.bitmap.page2=data&0x80;video.x=data&0x7f;break;
+ case 5: video.y=data;break;
+ case 7:
+ if (video.bitmap.write) {
+ if (video.x<ARRAY_LENGTH(video.bitmap.data[0][0]) /*&& video.y<ARRAY_LENGTH(video.bitmap.data[0])*/)
+ video.bitmap.data[video.bitmap.page2][video.y][video.x]=data;
+ else
+ logerror("%.6f %04x video bitmap x %x invalid\n",machine().time().as_double(), m_maincpu->pc(), video.x);
+ } else {
+ video.bitmap.data[0][video.y][video.x&(ARRAY_LENGTH(video.bitmap.data[0][0])-1)]=data;
+ }
+ if (video.y_increment) video.y++;
else video.x++;
- }
+ }
}
WRITE8_MEMBER( gamate_state::cart_bankswitchmulti_w )
@@ -149,54 +149,54 @@ WRITE8_MEMBER( gamate_state::cart_bankswitch_w )
READ8_MEMBER( gamate_state::gamate_video_r )
{
if (offset!=6) return 0;
- UINT8 data=0;
- if (video.bitmap.write) {
- if (video.x<ARRAY_LENGTH(video.bitmap.data[0][0]) /*&& video.y<ARRAY_LENGTH(video.bitmap.data[0])*/)
- data=video.bitmap.data[video.bitmap.page2][video.y][video.x];
- else
- logerror("%.6f video bitmap x %x invalid\n",machine().time().as_double(),video.x);
- } else {
- data=video.bitmap.data[0][video.y][video.x&(ARRAY_LENGTH(video.bitmap.data[0][0])-1)];
- }
- if (m_maincpu->pc()<0xf000)
- logerror("%.6f video read %04x %02x\n",machine().time().as_double(),offset, data);
- return data;
+ UINT8 data=0;
+ if (video.bitmap.write) {
+ if (video.x<ARRAY_LENGTH(video.bitmap.data[0][0]) /*&& video.y<ARRAY_LENGTH(video.bitmap.data[0])*/)
+ data=video.bitmap.data[video.bitmap.page2][video.y][video.x];
+ else
+ logerror("%.6f video bitmap x %x invalid\n",machine().time().as_double(),video.x);
+ } else {
+ data=video.bitmap.data[0][video.y][video.x&(ARRAY_LENGTH(video.bitmap.data[0][0])-1)];
+ }
+ if (m_maincpu->pc()<0xf000)
+ logerror("%.6f video read %04x %02x\n",machine().time().as_double(),offset, data);
+ return data;
}
WRITE8_MEMBER( gamate_state::gamate_audio_w )
{
- logerror("%.6f %04x audio write %04x %02x\n",machine().time().as_double(),m_maincpu->pc(),offset,data);
+ logerror("%.6f %04x audio write %04x %02x\n",machine().time().as_double(),m_maincpu->pc(),offset,data);
}
READ8_MEMBER( gamate_state::gamate_audio_r )
{
- logerror("%.6f %04x audio read %04x \n",machine().time().as_double(),m_maincpu->pc(),offset);
+ logerror("%.6f %04x audio read %04x \n",machine().time().as_double(),m_maincpu->pc(),offset);
return 0;
}
READ8_MEMBER( gamate_state::gamate_pad_r )
{
- UINT8 data=m_io_joy->read();
- return data;
+ UINT8 data=m_io_joy->read();
+ return data;
}
static ADDRESS_MAP_START( gamate_mem, AS_PROGRAM, 8, gamate_state )
- AM_RANGE(0x0000, 0x03ff) AM_RAM
- AM_RANGE(0x4000, 0x400d) AM_READWRITE(gamate_audio_r, gamate_audio_w)
- AM_RANGE(0x4400, 0x4400) AM_READ(gamate_pad_r)
- AM_RANGE(0x5000, 0x5007) AM_READWRITE(gamate_video_r, gamate_video_w)
- AM_RANGE(0x5a00, 0x5a00) AM_READ(protection_r)
+ AM_RANGE(0x0000, 0x03ff) AM_RAM
+ AM_RANGE(0x4000, 0x400d) AM_READWRITE(gamate_audio_r, gamate_audio_w)
+ AM_RANGE(0x4400, 0x4400) AM_READ(gamate_pad_r)
+ AM_RANGE(0x5000, 0x5007) AM_READWRITE(gamate_video_r, gamate_video_w)
+ AM_RANGE(0x5a00, 0x5a00) AM_READ(protection_r)
- AM_RANGE(0x6000, 0x9fff) AM_READ_BANK("bankmulti")
- AM_RANGE(0xa000, 0xdfff) AM_READ_BANK("bank")
+ AM_RANGE(0x6000, 0x9fff) AM_READ_BANK("bankmulti")
+ AM_RANGE(0xa000, 0xdfff) AM_READ_BANK("bank")
AM_RANGE(0x6000, 0x6002) AM_READWRITE(gamate_cart_protection_r, gamate_cart_protection_w)
-// AM_RANGE(0x6000, 0xdfff) AM_READWRITE(gamate_cart_r, gamate_cart_w)
+// AM_RANGE(0x6000, 0xdfff) AM_READWRITE(gamate_cart_r, gamate_cart_w)
AM_RANGE(0x8000, 0x8000) AM_WRITE(cart_bankswitchmulti_w)
AM_RANGE(0xc000, 0xc000) AM_WRITE(cart_bankswitch_w)
- AM_RANGE(0xf000, 0xffff) AM_ROM AM_SHARE("bios")
+ AM_RANGE(0xf000, 0xffff) AM_ROM AM_SHARE("bios")
ADDRESS_MAP_END
@@ -215,16 +215,16 @@ INPUT_PORTS_END
#ifdef UNUSED_CODE
static const struct gfx_layout gamate_charlayout =
{
- 4, /* width of object */
- 1, /* height of object */
- 256,/* 256 characters */
- 2, /* bits per pixel */
- { 0,1 }, /* no bitplanes */
- /* x offsets */
- { 0,2,4,6 },
- /* y offsets */
- { 0 },
- 8*1 /* size of 1 object in bits */
+ 4, /* width of object */
+ 1, /* height of object */
+ 256,/* 256 characters */
+ 2, /* bits per pixel */
+ { 0,1 }, /* no bitplanes */
+ /* x offsets */
+ { 0,2,4,6 },
+ /* y offsets */
+ { 0 },
+ 8*1 /* size of 1 object in bits */
};
static const unsigned short gamate_palette[4] =
@@ -233,17 +233,17 @@ static const unsigned short gamate_palette[4] =
};
static GFXDECODE_START( gamate_charlayout )
- GFXDECODE_ENTRY( "gfx1", 0x0000, gamate_charlayout, 0, 0x100 )
+ GFXDECODE_ENTRY( "gfx1", 0x0000, gamate_charlayout, 0, 0x100 )
GFXDECODE_END
#endif
/* palette in red, green, blue tribles */
static const unsigned char gamate_colors[4][3] =
{
- { 255,255,255 },
- { 0xa0, 0xa0, 0xa0 },
- { 0x60, 0x60, 0x60 },
- { 0, 0, 0 }
+ { 255,255,255 },
+ { 0xa0, 0xa0, 0xa0 },
+ { 0x60, 0x60, 0x60 },
+ { 0, 0, 0 }
};
PALETTE_INIT_MEMBER(gamate_state, gamate)
@@ -274,22 +274,22 @@ static void BlitPlane(UINT16* line, UINT8 plane1, UINT8 plane2)
UINT32 gamate_state::screen_update_gamate(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
- int x, y, j;
- for (y=0;y<152;y++) {
- for (x=-(video.bitmap.xpos&7), j=0;x<160;x+=8, j++) {
- UINT8 d1=video.bitmap.data[0][(y+video.bitmap.ypos)&0xff][(j+video.bitmap.xpos/8)&0x1f];
- UINT8 d2=video.bitmap.data[1][(y+video.bitmap.ypos)&0xff][(j+video.bitmap.xpos/8)&0x1f];
- BlitPlane(&bitmap.pix16(y, x+4), d1, d2);
- BlitPlane(&bitmap.pix16(y, x), d1>>4, d2>>4);
- }
- }
- return 0;
+ int x, y, j;
+ for (y=0;y<152;y++) {
+ for (x=-(video.bitmap.xpos&7), j=0;x<160;x+=8, j++) {
+ UINT8 d1=video.bitmap.data[0][(y+video.bitmap.ypos)&0xff][(j+video.bitmap.xpos/8)&0x1f];
+ UINT8 d2=video.bitmap.data[1][(y+video.bitmap.ypos)&0xff][(j+video.bitmap.xpos/8)&0x1f];
+ BlitPlane(&bitmap.pix16(y, x+4), d1, d2);
+ BlitPlane(&bitmap.pix16(y, x), d1>>4, d2>>4);
+ }
+ }
+ return 0;
}
DRIVER_INIT_MEMBER(gamate_state,gamate)
{
memset(&video, 0, sizeof(video));/* memset(m_ram, 0, sizeof(m_ram));*/
- UINT8 *gfx=memregion("gfx1")->base(); for (int i=0; i<256; i++) gfx[i]=i;
+ UINT8 *gfx=memregion("gfx1")->base(); for (int i=0; i<256; i++) gfx[i]=i;
timer1 = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(gamate_state::gamate_timer),this));
timer2 = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(gamate_state::gamate_timer2),this));
}
@@ -298,7 +298,7 @@ DRIVER_INIT_MEMBER(gamate_state,gamate)
void gamate_state::machine_start()
{
if (m_cart->exists()) {
-// m_maincpu->space(AS_PROGRAM).install_read_handler(0x6000, 0x6000, READ8_DELEGATE(gamate_state, gamate_cart_protection_r));
+// m_maincpu->space(AS_PROGRAM).install_read_handler(0x6000, 0x6000, READ8_DELEGATE(gamate_state, gamate_cart_protection_r));
membank("bankmulti")->set_base(m_cart->get_rom_base());
membank("bank")->set_base(m_cart->get_rom_base()+0x4000); // bankswitched games in reality no offset
}
@@ -355,9 +355,9 @@ static MACHINE_CONFIG_START( gamate, gamate_state )
MCFG_SCREEN_UPDATE_DRIVER(gamate_state, screen_update_gamate)
MCFG_SCREEN_PALETTE("palette")
-// MCFG_GFXDECODE_ADD("gfxdecode", "palette", gamate )
+// MCFG_GFXDECODE_ADD("gfxdecode", "palette", gamate )
MCFG_PALETTE_ADD("palette", ARRAY_LENGTH(gamate_colors))
-// MCFG_PALETTE_INDIRECT_ENTRIES(4)
+// MCFG_PALETTE_INDIRECT_ENTRIES(4)
MCFG_PALETTE_INIT_OWNER(gamate_state, gamate)
MCFG_DEFAULT_LAYOUT(layout_lcd)
@@ -371,11 +371,9 @@ MACHINE_CONFIG_END
ROM_START(gamate)
ROM_REGION(0x10000,"maincpu", 0)
ROM_LOAD("gamate_bios_umc.bin", 0xf000, 0x1000, CRC(07090415) SHA1(ea449dc607601f9a68d855ad6ab53800d2e99297) )
- ROM_REGION(0x100,"gfx1", ROMREGION_ERASEFF)
+ ROM_REGION(0x100,"gfx1", ROMREGION_ERASEFF)
ROM_END
/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME */
CONS( 19??, gamate, 0, 0, gamate, gamate, gamate_state, gamate, "Bit Corp", "Gamate", GAME_NO_SOUND)
-
-
diff --git a/src/mess/drivers/hp16500.c b/src/mess/drivers/hp16500.c
index 892d2abadb9..ac2a5aa4fd0 100644
--- a/src/mess/drivers/hp16500.c
+++ b/src/mess/drivers/hp16500.c
@@ -1,6 +1,6 @@
/***************************************************************************
-
- Hewlett-Packard HP16500b Logic Analyzer
+
+ Hewlett-Packard HP16500b Logic Analyzer
MC68EC030 @ 25 MHz
@@ -16,7 +16,7 @@
IRQ 5 = 814a
IRQ 6 = 35c8 (jump 840120)
IRQ 7 = 35d4 (jump 840120)
-
+
****************************************************************************/
#include "emu.h"
@@ -28,7 +28,7 @@ public:
hp16500_state(const machine_config &mconfig, device_type type, const char *tag)
: driver_device(mconfig, type, tag),
m_maincpu(*this, "maincpu")
- { }
+ { }
virtual void video_start();
UINT32 screen_update_hp16500(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
@@ -55,7 +55,7 @@ private:
READ32_MEMBER(hp16500_state::vbl_state_r)
{
- return 0x03000000; // bit 0 set means the interrupt handler advances the pSOS tick counter.
+ return 0x03000000; // bit 0 set means the interrupt handler advances the pSOS tick counter.
}
WRITE32_MEMBER(hp16500_state::vbl_ack_w)
@@ -71,7 +71,7 @@ static ADDRESS_MAP_START(hp16500_map, AS_PROGRAM, 32, hp16500_state)
AM_RANGE(0x00203000, 0x00203003) AM_WRITE(vbl_ack_w)
AM_RANGE(0x00209800, 0x00209803) AM_READ(vbl_state_r)
- AM_RANGE(0x0020b800, 0x0020b8ff) AM_RAM // system ram test is really strange.
+ AM_RANGE(0x0020b800, 0x0020b8ff) AM_RAM // system ram test is really strange.
AM_RANGE(0x00600000, 0x0061ffff) AM_WRITE16(vram_w, 0xffffffff)
AM_RANGE(0x00600000, 0x0067ffff) AM_READ8 (vram_r, 0x00ff00ff)
@@ -201,4 +201,3 @@ ROM_START( hp16500b )
ROM_END
COMP( 1994, hp16500b, 0, 0, hp16500, hp16500, driver_device, 0, "Hewlett Packard", "HP 16500b", GAME_NOT_WORKING|GAME_NO_SOUND)
-
diff --git a/src/mess/drivers/hp9k_3xx.c b/src/mess/drivers/hp9k_3xx.c
index 95cd0b0cf72..05e34fb654b 100644
--- a/src/mess/drivers/hp9k_3xx.c
+++ b/src/mess/drivers/hp9k_3xx.c
@@ -1,23 +1,23 @@
// license:BSD-3-Clause
// copyright-holders:R. Belmont
/***************************************************************************
-
+
hp9k3xx.c: preliminary driver for HP9000 300 Series (aka HP9000/3xx)
-
+
Currently supporting:
-
+
320:
MC68020 CPU @ 16.67 MHz
HP custom MMU
MC68881 FPU
-
+
330:
- MC68020 CPU @ 16.67 MHz
- MC68851 MMU
- MC68881 FPU
-
+ MC68020 CPU @ 16.67 MHz
+ MC68851 MMU
+ MC68881 FPU
+
All models have an MC6840 PIT on IRQ6 clocked at 250 kHz.
-
+
TODO:
BBCADDR 0x420000
RTC_DATA: 0x420001
@@ -27,9 +27,9 @@
KBDNMIST: 0x478005
DMA: 0x500000
FRAMEBUF: 0x560000
-
+
6840: 0x5F8001/3/5/7/9, IRQ 6
-
+
****************************************************************************/
#include "emu.h"
@@ -88,14 +88,14 @@ UINT32 hp9k3xx_state::hp98544_update(screen_device &screen, bitmap_rgb32 &bitmap
// shared mappings for all 9000/3xx systems
static ADDRESS_MAP_START(hp9k3xx_common, AS_PROGRAM, 32, hp9k3xx_state)
- AM_RANGE(0x00000000, 0x0001ffff) AM_ROM AM_REGION("maincpu",0) AM_WRITENOP // writes to 1fffc are the LED
+ AM_RANGE(0x00000000, 0x0001ffff) AM_ROM AM_REGION("maincpu",0) AM_WRITENOP // writes to 1fffc are the LED
- AM_RANGE(0x00200000, 0x002fffff) AM_RAM AM_SHARE("vram") // 98544 mono framebuffer
- AM_RANGE(0x00560000, 0x00563fff) AM_ROM AM_REGION("graphics", 0x0000) // 98544 mono ROM
+ AM_RANGE(0x00200000, 0x002fffff) AM_RAM AM_SHARE("vram") // 98544 mono framebuffer
+ AM_RANGE(0x00560000, 0x00563fff) AM_ROM AM_REGION("graphics", 0x0000) // 98544 mono ROM
- AM_RANGE(0x00510000, 0x00510003) AM_READWRITE(buserror_r, buserror_w) // no "Alpha display"
- AM_RANGE(0x00538000, 0x00538003) AM_READWRITE(buserror_r, buserror_w) // no "Graphics"
- AM_RANGE(0x005c0000, 0x005c0003) AM_READWRITE(buserror_r, buserror_w) // no add-on FP coprocessor
+ AM_RANGE(0x00510000, 0x00510003) AM_READWRITE(buserror_r, buserror_w) // no "Alpha display"
+ AM_RANGE(0x00538000, 0x00538003) AM_READWRITE(buserror_r, buserror_w) // no "Graphics"
+ AM_RANGE(0x005c0000, 0x005c0003) AM_READWRITE(buserror_r, buserror_w) // no add-on FP coprocessor
AM_RANGE(0x005f8000, 0x005f800f) AM_DEVREADWRITE8(PTM6840_TAG, ptm6840_device, read, write, 0x00ff00ff)
ADDRESS_MAP_END
@@ -148,7 +148,7 @@ static MACHINE_CONFIG_START( hp9k320, hp9k3xx_state )
MCFG_CPU_PROGRAM_MAP(hp9k320_map)
MCFG_DEVICE_ADD(PTM6840_TAG, PTM6840, 0)
- MCFG_PTM6840_INTERNAL_CLOCK(250000.0f) // from oscillator module next to the 6840
+ MCFG_PTM6840_INTERNAL_CLOCK(250000.0f) // from oscillator module next to the 6840
MCFG_PTM6840_EXTERNAL_CLOCKS(250000.0f, 250000.0f, 250000.0f)
MCFG_SCREEN_ADD( "screen", RASTER)
@@ -164,7 +164,7 @@ static MACHINE_CONFIG_START( hp9k330, hp9k3xx_state )
MCFG_CPU_PROGRAM_MAP(hp9k330_map)
MCFG_DEVICE_ADD(PTM6840_TAG, PTM6840, 0)
- MCFG_PTM6840_INTERNAL_CLOCK(250000.0f) // from oscillator module next to the 6840
+ MCFG_PTM6840_INTERNAL_CLOCK(250000.0f) // from oscillator module next to the 6840
MCFG_PTM6840_EXTERNAL_CLOCKS(250000.0f, 250000.0f, 250000.0f)
MCFG_SCREEN_ADD( "screen", RASTER)
@@ -176,10 +176,10 @@ MACHINE_CONFIG_END
ROM_START( hp9k320 )
ROM_REGION( 0x20000, MAINCPU_TAG, 0 )
- ROM_LOAD16_BYTE( "5061-6538.bin", 0x000001, 0x004000, CRC(d6aafeb1) SHA1(88c6b0b2f504303cbbac0c496c26b85458ac5d63) )
- ROM_LOAD16_BYTE( "5061-6539.bin", 0x000000, 0x004000, CRC(a7ff104c) SHA1(c640fe68314654716bd41b04c6a7f4e560036c7e) )
- ROM_LOAD16_BYTE( "5061-6540.bin", 0x008001, 0x004000, CRC(4f6796d6) SHA1(fd254897ac1afb8628f40ea93213f60a082c8d36) )
- ROM_LOAD16_BYTE( "5061-6541.bin", 0x008000, 0x004000, CRC(39d32998) SHA1(6de1bda75187b0878c03c074942b807cf2924f0e) )
+ ROM_LOAD16_BYTE( "5061-6538.bin", 0x000001, 0x004000, CRC(d6aafeb1) SHA1(88c6b0b2f504303cbbac0c496c26b85458ac5d63) )
+ ROM_LOAD16_BYTE( "5061-6539.bin", 0x000000, 0x004000, CRC(a7ff104c) SHA1(c640fe68314654716bd41b04c6a7f4e560036c7e) )
+ ROM_LOAD16_BYTE( "5061-6540.bin", 0x008001, 0x004000, CRC(4f6796d6) SHA1(fd254897ac1afb8628f40ea93213f60a082c8d36) )
+ ROM_LOAD16_BYTE( "5061-6541.bin", 0x008000, 0x004000, CRC(39d32998) SHA1(6de1bda75187b0878c03c074942b807cf2924f0e) )
ROM_REGION( 0x4000, "graphics", ROMREGION_ERASEFF | ROMREGION_BE | ROMREGION_32BIT )
ROM_LOAD16_BYTE( "98544_1818-1999.bin", 0x000001, 0x002000, CRC(8c7d6480) SHA1(d2bcfd39452c38bc652df39f84c7041cfdf6bd51) )
@@ -187,8 +187,8 @@ ROM_END
ROM_START( hp9k330 )
ROM_REGION( 0x20000, MAINCPU_TAG, 0 )
- ROM_LOAD16_BYTE( "1818-4416.bin", 0x000000, 0x010000, CRC(cd71e85e) SHA1(3e83a80682f733417fdc3720410e45a2cfdcf869) )
- ROM_LOAD16_BYTE( "1818-4417.bin", 0x000001, 0x010000, CRC(374d49db) SHA1(a12cbf6c151e2f421da4571000b5dffa3ef403b3) )
+ ROM_LOAD16_BYTE( "1818-4416.bin", 0x000000, 0x010000, CRC(cd71e85e) SHA1(3e83a80682f733417fdc3720410e45a2cfdcf869) )
+ ROM_LOAD16_BYTE( "1818-4417.bin", 0x000001, 0x010000, CRC(374d49db) SHA1(a12cbf6c151e2f421da4571000b5dffa3ef403b3) )
ROM_REGION( 0x4000, "graphics", ROMREGION_ERASEFF | ROMREGION_BE | ROMREGION_32BIT )
ROM_LOAD16_BYTE( "98544_1818-1999.bin", 0x000001, 0x002000, CRC(8c7d6480) SHA1(d2bcfd39452c38bc652df39f84c7041cfdf6bd51) )
diff --git a/src/mess/drivers/intv.c b/src/mess/drivers/intv.c
index 79843415575..0ff310c509c 100644
--- a/src/mess/drivers/intv.c
+++ b/src/mess/drivers/intv.c
@@ -682,7 +682,7 @@ Intel 2732 "CPU 2D" CPU2D.U21 4Kx8 EPROM, 6502 code
TI 8S030N 1149-0360 0360.U58 32x8 Timing prom?
TI 8S030N 1149-0370 0370.U74 32x8 Timing prom?
-
+
GI RO-3-9502-024 024.U60 2Kx10 Mask ROM+Addr Decoder, CP1600 code
GI 9316B-4D72 4D72.U62 2Kx8 Mask ROM, CP1600 code (upper)
GI 9316B-4D71 4D71.U63 2Kx8 Mask ROM, CP1600 code (lower)
@@ -691,7 +691,7 @@ GI 9316B-4C52 4C52.U34 2Kx8 Mask ROM, Alphanumerics
Main board also includes:
2 2114 DRAMS 1Kx4 Character memory
- 10 MM5290J DRAMS 16Kx10 CP1600 memory?
+ 10 MM5290J DRAMS 16Kx10 CP1600 memory?
1 6502
1 Mystery 40-pin chip (under heat sink)
(actually a SMC CRT5027 aka TI TMS9927 CRT controller)
@@ -715,7 +715,7 @@ ROM_START(intvkbd) // the intv1 exec rom should be two roms: RO-3-9502-011.U5 an
ROM_REGION(0x0100,"proms",0)
ROM_LOAD( "0360.u58", 0x00, 0x20, CRC(1295528a) SHA1(b35e598891f1185e02cbacb4811d2334357abd79))
- ROM_LOAD( "0370.u74", 0x20, 0x20, CRC(19da5096) SHA1(76af50e4fd29649fc4837120c245321a8fc84cd3))
+ ROM_LOAD( "0370.u74", 0x20, 0x20, CRC(19da5096) SHA1(76af50e4fd29649fc4837120c245321a8fc84cd3))
ROM_END
DRIVER_INIT_MEMBER(intv_state,intv)
diff --git a/src/mess/drivers/leapster.c b/src/mess/drivers/leapster.c
index 5d25830036c..efdf33e23af 100644
--- a/src/mess/drivers/leapster.c
+++ b/src/mess/drivers/leapster.c
@@ -283,9 +283,9 @@ void leapster_state::machine_reset()
static ADDRESS_MAP_START( leapster_map, AS_PROGRAM, 32, leapster_state )
AM_RANGE(0x00000000, 0x001fffff) AM_ROM AM_MIRROR(0x40000000) // pointers in the bios region seem to be to the 40xxxxxx region, either we mirror there or something (real bios?) is acutally missing
AM_RANGE(0x0180D800, 0x0180D803) AM_READ(leapster_random_r)
- AM_RANGE(0x03000000, 0x030007ff) AM_RAM // puts stack here, writes a pointer @ 0x03000000 on startup
+ AM_RANGE(0x03000000, 0x030007ff) AM_RAM // puts stack here, writes a pointer @ 0x03000000 on startup
AM_RANGE(0x3c000000, 0x3c1fffff) AM_RAM // really ram, or has our code execution gone wrong?
-// AM_RANGE(0x80000000, 0x807fffff) AM_ROMBANK("cartrom") // game ROM pointers are all to the 80xxxxxx region, so I assume it maps here - installed if a cart is present
+// AM_RANGE(0x80000000, 0x807fffff) AM_ROMBANK("cartrom") // game ROM pointers are all to the 80xxxxxx region, so I assume it maps here - installed if a cart is present
ADDRESS_MAP_END
static MACHINE_CONFIG_START( leapster, leapster_state )
@@ -323,7 +323,6 @@ ROM_END
DRIVER_INIT_MEMBER(leapster_state,leapster)
{
-
}
CONS(2003, leapster, 0, 0, leapster, leapster, leapster_state, leapster, "LeapFrog", "Leapster (Germany)", GAME_NOT_WORKING | GAME_NO_SOUND | GAME_IS_SKELETON )
diff --git a/src/mess/drivers/mathmagi.c b/src/mess/drivers/mathmagi.c
index aac21203ff0..e271bdddd9a 100644
--- a/src/mess/drivers/mathmagi.c
+++ b/src/mess/drivers/mathmagi.c
@@ -6,13 +6,13 @@
* TMS1100 MP1030 - MCU
* 2 x DS8870N - Hex LED Digit Driver
* 2 x DS8861N - MOS-to-LED 5-Segment Driver
-
+
This is a tabletop educational calculator. It came with plastic overlays
for playing different kind of games. Refer to the manual on how to use it.
In short, to start from scratch, press [SEL]. By default the device is in
calculator teaching mode. If [SEL] is followed with 1-6 and then [NXT],
one of the games is started.
-
+
1) Number Machine
2) Countin' On
3) Walk The Plank
@@ -24,7 +24,7 @@
TODO:
- some of the led symbols are probably wrong, output PLA is unknown
- microinstructions PLA is not verified
-
+
***************************************************************************/
#include "emu.h"
@@ -102,7 +102,7 @@ WRITE16_MEMBER(mathmagi_state::write_r)
if (i >= 8)
for (int j = 0; j < 8; j++)
output_set_lamp_value(i*10 + j, m_o >> j & 1);
-
+
// R0-R7: 7seg leds
else
output_set_digit_value(i, m_o >> 1 & 0x7f);
diff --git a/src/mess/drivers/mc1502.c b/src/mess/drivers/mc1502.c
index 5a2b4fba8bc..7ee666e6270 100644
--- a/src/mess/drivers/mc1502.c
+++ b/src/mess/drivers/mc1502.c
@@ -51,8 +51,8 @@ TIMER_CALLBACK_MEMBER(mc1502_state::keyb_signal_callback)
key |= ioport("Y10")->read();
key |= ioport("Y11")->read();
key |= ioport("Y12")->read();
-// DBG_LOG(1,"mc1502_k_s_c",("= %02X (%d) %s\n", key, m_kbd.pulsing,
-// (key || m_kbd.pulsing) ? " will IRQ" : ""));
+// DBG_LOG(1,"mc1502_k_s_c",("= %02X (%d) %s\n", key, m_kbd.pulsing,
+// (key || m_kbd.pulsing) ? " will IRQ" : ""));
/*
If a key is pressed and we're not pulsing yet, start pulsing the IRQ1;
@@ -73,7 +73,7 @@ TIMER_CALLBACK_MEMBER(mc1502_state::keyb_signal_callback)
WRITE8_MEMBER(mc1502_state::mc1502_ppi_portb_w)
{
-// DBG_LOG(2,"mc1502_ppi_portb_w",("( %02X )\n", data));
+// DBG_LOG(2,"mc1502_ppi_portb_w",("( %02X )\n", data));
m_ppi_portb = data;
m_pit8253->write_gate2(BIT(data, 0));
mc1502_speaker_set_spkrdata(BIT(data, 1));
@@ -87,7 +87,7 @@ WRITE8_MEMBER(mc1502_state::mc1502_ppi_portb_w)
// bit 3: i8251 SYNDET pin triggers NMI (default = 1 = no)
WRITE8_MEMBER(mc1502_state::mc1502_ppi_portc_w)
{
-// DBG_LOG(2,"mc1502_ppi_portc_w",("( %02X )\n", data));
+// DBG_LOG(2,"mc1502_ppi_portc_w",("( %02X )\n", data));
m_ppi_portc = data & 15;
}
@@ -104,8 +104,8 @@ READ8_MEMBER(mc1502_state::mc1502_ppi_portc_r)
data = ( data & ~0x20 ) | ( m_pit_out2 ? 0x20 : 0x00 );
data = ( data & ~0x10 ) | ( (BIT(m_ppi_portb, 1) && m_pit_out2) ? 0x10 : 0x00 );
-// DBG_LOG(2,"mc1502_ppi_portc_r",("= %02X (tap_val %f t2out %d) at %s\n",
-// data, tap_val, m_pit_out2, machine().describe_context()));
+// DBG_LOG(2,"mc1502_ppi_portc_r",("= %02X (tap_val %f t2out %d) at %s\n",
+// data, tap_val, m_pit_out2, machine().describe_context()));
return data;
}
@@ -126,7 +126,7 @@ READ8_MEMBER(mc1502_state::mc1502_kppi_porta_r)
if (m_kbd.mask & 0x0400) { key |= ioport("Y11")->read(); }
if (m_kbd.mask & 0x0800) { key |= ioport("Y12")->read(); }
key ^= 0xff;
-// DBG_LOG(2,"mc1502_kppi_porta_r",("= %02X\n", key));
+// DBG_LOG(2,"mc1502_kppi_porta_r",("= %02X\n", key));
return key;
}
@@ -138,14 +138,14 @@ WRITE8_MEMBER(mc1502_state::mc1502_kppi_portb_w)
m_kbd.mask |= 1 << 11;
else
m_kbd.mask &= ~(1 << 11);
-// DBG_LOG(2,"mc1502_kppi_portb_w",("( %02X -> %04X )\n", data, m_kbd.mask));
+// DBG_LOG(2,"mc1502_kppi_portb_w",("( %02X -> %04X )\n", data, m_kbd.mask));
}
WRITE8_MEMBER(mc1502_state::mc1502_kppi_portc_w)
{
m_kbd.mask &= ~(7 << 8);
m_kbd.mask |= ((data ^ 7) & 7) << 8;
-// DBG_LOG(2,"mc1502_kppi_portc_w",("( %02X -> %04X )\n", data, m_kbd.mask));
+// DBG_LOG(2,"mc1502_kppi_portc_w",("( %02X -> %04X )\n", data, m_kbd.mask));
}
WRITE_LINE_MEMBER(mc1502_state::mc1502_i8251_syndet)
diff --git a/src/mess/drivers/megadriv.c b/src/mess/drivers/megadriv.c
index 51ecd138784..25ffbb0a446 100644
--- a/src/mess/drivers/megadriv.c
+++ b/src/mess/drivers/megadriv.c
@@ -769,7 +769,7 @@ ROM_END
ROM_START( megacdj )
ROM_REGION16_BE( 0x400000, "maincpu", ROMREGION_ERASE00 )
- ROM_DEFAULT_BIOS("v100g") // this seems the only revision where the cursor in CD menu works, allowing to boot games
+ ROM_DEFAULT_BIOS("v100g") // this seems the only revision where the cursor in CD menu works, allowing to boot games
/* Confirmed by ElBarto */
ROM_SYSTEM_BIOS(0, "v100s", "v1.00S")
ROMX_LOAD( "mpr-14088h.bin", 0x000000, 0x020000, CRC(3773d5aa) SHA1(bbf729a1aaa1667b783749299e1ad932aaf5f253), ROM_BIOS(1) | ROM_GROUPWORD | ROM_REVERSE)
@@ -782,7 +782,7 @@ ROM_START( megacdj )
/* Confirmed by ElBarto */
ROM_SYSTEM_BIOS(3, "v100o", "v1.00O")
ROMX_LOAD( "epr-14088d.bin", 0x000000, 0x020000, CRC(dfa95ee9) SHA1(e13666c76fa0a2e94e2f651b26b0fd625bf55f07), ROM_BIOS(4) | ROM_GROUPWORD | ROM_REVERSE)
- ROM_SYSTEM_BIOS(4, "v100p", "v1.00P") // CRC: e2e70bc8 when byteswapped
+ ROM_SYSTEM_BIOS(4, "v100p", "v1.00P") // CRC: e2e70bc8 when byteswapped
ROMX_LOAD( "epr-14088e.bin", 0x000000, 0x020000, CRC(9d2da8f2) SHA1(4846f448160059a7da0215a5df12ca160f26dd69), ROM_BIOS(5) )
ROM_END
diff --git a/src/mess/drivers/merlin.c b/src/mess/drivers/merlin.c
index 2d226239125..38bc08ddc52 100644
--- a/src/mess/drivers/merlin.c
+++ b/src/mess/drivers/merlin.c
@@ -4,7 +4,7 @@
Parker Bros Merlin handheld computer game
* TMS1100NLL MP3404A-N2 (has internal ROM)
-
+
To start a game, press NEW GAME, followed by a number:
1: Tic-Tac-Toe
2: Music Machine
@@ -12,15 +12,15 @@
4: Blackjack 13
5: Magic Square
6: Mindbender
-
+
Refer to the official manual for more information on the games.
-
-
+
+
Other handhelds assumed to be on similar hardware:
- Dr. Smith - by Tomy, released in Japan (basically a white version of Merlin,
let's assume for now that the ROM contents is identical)
- Master Merlin
-
+
Another sequel, called Split Second, looks like different hardware.
@@ -75,7 +75,7 @@ protected:
READ8_MEMBER(merlin_state::read_k)
{
UINT8 k = 0;
-
+
// read selected button rows
for (int i = 0; i < 4; i++)
if (m_o >> i & 1)
diff --git a/src/mess/drivers/ngen.c b/src/mess/drivers/ngen.c
index 5782e178117..2c044d7a283 100644
--- a/src/mess/drivers/ngen.c
+++ b/src/mess/drivers/ngen.c
@@ -4,18 +4,18 @@
10-11-14 - Skeleton driver
- Interrupts based on patents:
- level 1 - SIO
- level 3 - timer (from PIT, presumably channel 0? Patent says "channel 3")
- level 4 - "interrupt detector" - keyboard, printer, RTC
- level 7 - floppy/hard disk
-
- DMA channels:
- channel 0 - communications (RS-232)
- channel 1 - X-Bus expansion modules (except disk and graphics)
- channel 2 - graphics?
- channel 3 - hard disk
-
+ Interrupts based on patents:
+ level 1 - SIO
+ level 3 - timer (from PIT, presumably channel 0? Patent says "channel 3")
+ level 4 - "interrupt detector" - keyboard, printer, RTC
+ level 7 - floppy/hard disk
+
+ DMA channels:
+ channel 0 - communications (RS-232)
+ channel 1 - X-Bus expansion modules (except disk and graphics)
+ channel 2 - graphics?
+ channel 3 - hard disk
+
To get to "menu mode", press Space quickly after reset (might need good timing)
The bootstrap ROM version number is displayed, along with "B,D,L,M,P,T:"
You can press one of these keys for the following tests:
@@ -33,18 +33,18 @@
T: Type of Operating System
Gives an "OS:" prompt, at which you can enter the number of the system image to
load at the master workstation.
-
+
Panel Debugger:
- Open/Modify RAM
Enter an address (seg:off) followed by a forward-slash, the contents of this word will
appear, you can enter a value to set it to, or just press Next (default: Enter) to leave
- it as is. It will then go on to the next word. Pressing Return (scan code unknown
+ it as is. It will then go on to the next word. Pressing Return (scan code unknown
currently) will return to the debugger prompt.
- Open/Modify Register
Enter the register only, and the contents will appear, you can leave it or alter it (you
must enter all digits (eg: 0A03 if you're modifying DX) then press Return.
- I/O to or from a port
- Input: Address (segment is ignored, and not required) followed by I, a byte is read from
+ Input: Address (segment is ignored, and not required) followed by I, a byte is read from
the port defined by the offset, and the byte is displayed.
Output: Address followed by O, you are now prompted with an '='. Enter the byte to send
to the port, and press Return.
@@ -52,7 +52,7 @@
Enter an address (seg:off) followed by H. Sets a haltpoint at the specified address. Does
not work for ROM addresses. Only one allowed at a time. Haltpoint info is stored at
0000:01F0. Uses a software interrupt (INT 7C), rather than INT 3.
-
+
To start or continue from the current address, enter P.
To start from a specific address, enter the address (seg:off) followed by a G.
*/
@@ -624,7 +624,7 @@ static MACHINE_CONFIG_START( ngen, ngen_state )
MCFG_I8251_TXD_HANDLER(DEVWRITELINE("keyboard", rs232_port_device, write_txd))
MCFG_RS232_PORT_ADD("keyboard", keyboard, "ngen")
MCFG_RS232_RXD_HANDLER(DEVWRITELINE("videouart", i8251_device, write_rxd))
-
+
MCFG_DEVICE_ADD("refresh_clock", CLOCK, 19200*16) // should be 19530Hz
MCFG_CLOCK_SIGNAL_HANDLER(WRITELINE(ngen_state,timer_clk_out))
@@ -662,10 +662,10 @@ ROM_START( ngen )
ROM_REGION( 0x2000, "bios", 0)
ROM_LOAD16_BYTE( "72-00414_80186_cpu.bin", 0x000000, 0x001000, CRC(e1387a03) SHA1(ddca4eba67fbf8b731a8009c14f6b40edcbc3279) ) // bootstrap ROM v8.4
ROM_LOAD16_BYTE( "72-00415_80186_cpu.bin", 0x000001, 0x001000, CRC(a6dde7d9) SHA1(b4d15c1bce31460ab5b92ff43a68c15ac5485816) )
-
+
ROM_REGION( 0x1000, "disk", 0)
ROM_LOAD( "72-00422_10mb_disk.bin", 0x000000, 0x001000, CRC(f5b046b6) SHA1(b303c6f6aa40504016de9826879bc316e44389aa) )
-
+
ROM_REGION( 0x20, "disk_prom", 0)
ROM_LOAD( "72-00422_10mb_disk_15d.bin", 0x000000, 0x000020, CRC(121ee494) SHA1(9a8d3c336cc7378a71f9d48c99f88515eb236fbf) )
ROM_END
diff --git a/src/mess/drivers/simon.c b/src/mess/drivers/simon.c
index 5ce6333129f..0a7947d9a94 100644
--- a/src/mess/drivers/simon.c
+++ b/src/mess/drivers/simon.c
@@ -3,14 +3,14 @@
/***************************************************************************
Milton Bradley Simon
-
+
Revision A hardware:
* TMS1000 (has internal ROM), DS75494 lamp driver
-
+
Newer revisions have a smaller 16-pin MB4850 chip instead of the TMS1000.
This one has been decapped too, but we couldn't find an internal ROM.
It is possibly a cost-reduced custom ASIC specifically for Simon.
-
+
Other games assumed to be on similar hardware:
- Pocket Simon, but there's a chance it only exists with MB4850 chip
- Super Simon (TMS1100)
@@ -61,7 +61,7 @@ public:
READ8_MEMBER(simon_state::read_k)
{
UINT8 k = 0;
-
+
// read selected button rows
for (int i = 0; i < 4; i++)
{
@@ -82,7 +82,7 @@ WRITE16_MEMBER(simon_state::write_r)
// R7 -> 75494 IN2 -> blue lamp
for (int i = 0; i < 4; i++)
output_set_lamp_value(i, data >> (4 + i) & 1);
-
+
// R8 -> 75494 IN0 -> speaker
m_speaker->level_w(data >> 8 & 1);
diff --git a/src/mess/drivers/starwbc.c b/src/mess/drivers/starwbc.c
index e45b8cb9441..bc85356fba6 100644
--- a/src/mess/drivers/starwbc.c
+++ b/src/mess/drivers/starwbc.c
@@ -4,7 +4,7 @@
Kenner Star Wars - Electronic Battle Command
* TMS1100 MCU, labeled MP3438A
-
+
This is a small tabletop space-dogfighting game. To start the game,
press BASIC/INTER/ADV and enter P#(number of players), then
START TURN. Refer to the official manual for more information.
@@ -46,7 +46,7 @@ public:
DECLARE_READ8_MEMBER(read_k);
DECLARE_WRITE16_MEMBER(write_o);
DECLARE_WRITE16_MEMBER(write_r);
-
+
TIMER_DEVICE_CALLBACK_MEMBER(leds_decay_tick);
void leds_update();
void prepare_and_update();
@@ -71,35 +71,35 @@ public:
void starwbc_state::leds_update()
{
UINT16 active_state[0x10];
-
+
for (int i = 0; i < 0x10; i++)
{
active_state[i] = 0;
-
+
for (int j = 0; j < 0x10; j++)
{
int di = j << 4 | i;
-
+
// turn on powered leds
if (m_leds_state[i] >> j & 1)
m_leds_decay[di] = LEDS_DECAY_TIME;
-
+
// determine active state
int ds = (m_leds_decay[di] != 0) ? 1 : 0;
active_state[i] |= (ds << j);
}
}
-
+
// on difference, send to output
for (int i = 0; i < 0x10; i++)
if (m_leds_cache[i] != active_state[i])
{
output_set_digit_value(i, active_state[i]);
-
+
for (int j = 0; j < 8; j++)
output_set_lamp_value(i*10 + j, active_state[i] >> j & 1);
}
-
+
memcpy(m_leds_cache, active_state, sizeof(m_leds_cache));
}
@@ -109,7 +109,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(starwbc_state::leds_decay_tick)
for (int i = 0; i < 0x100; i++)
if (!(m_leds_state[i & 0xf] >> (i>>4) & 1) && m_leds_decay[i])
m_leds_decay[i]--;
-
+
leds_update();
}
@@ -117,7 +117,7 @@ void starwbc_state::prepare_and_update()
{
UINT8 o = (m_o << 4 & 0xf0) | (m_o >> 4 & 0x0f);
const UINT8 mask[5] = { 0x30, 0xff, 0xff, 0x7f, 0x7f };
-
+
// R0,R2,R4,R6,R8
for (int i = 0; i < 5; i++)
m_leds_state[i*2] = (m_r >> (i*2) & 1) ? (o & mask[i]) : 0;
@@ -155,7 +155,7 @@ WRITE16_MEMBER(starwbc_state::write_r)
// R0,R1,R3,R5,R7: input mux
// R9: piezo speaker
m_speaker->level_w(data >> 9 & 1);
-
+
m_r = data;
prepare_and_update();
}
@@ -233,7 +233,7 @@ void starwbc_state::machine_start()
m_r = 0;
m_o = 0;
-
+
// register for savestates
save_item(NAME(m_leds_state));
save_item(NAME(m_leds_cache));
@@ -253,7 +253,7 @@ static MACHINE_CONFIG_START( starwbc, starwbc_state )
MCFG_TMS1XXX_WRITE_R_CB(WRITE16(starwbc_state, write_r))
MCFG_TIMER_DRIVER_ADD_PERIODIC("leds_decay", starwbc_state, leds_decay_tick, attotime::from_msec(10))
-
+
MCFG_DEFAULT_LAYOUT(layout_starwbc)
/* no video! */
diff --git a/src/mess/drivers/stopthie.c b/src/mess/drivers/stopthie.c
index 7ae0084b720..8c318e3cfa4 100644
--- a/src/mess/drivers/stopthie.c
+++ b/src/mess/drivers/stopthie.c
@@ -4,7 +4,7 @@
Parker Brothers Stop Thief
* TMS0980NLL MP6101B (die labeled 0980B-01A)
-
+
Stop Thief is actually a board game, the electronic device emulated here
(called Electronic Crime Scanner) is an accessory. To start a game, press
the ON button. Otherwise, it is in test-mode where you can hear all sounds.
@@ -78,30 +78,30 @@ public:
void stopthief_state::leds_update()
{
UINT16 active_state[0x10];
-
+
for (int i = 0; i < 0x10; i++)
{
active_state[i] = 0;
-
+
for (int j = 0; j < 0x10; j++)
{
int di = j << 4 | i;
-
+
// turn on powered leds
if (m_leds_state[i] >> j & 1)
m_leds_decay[di] = LEDS_DECAY_TIME;
-
+
// determine active state
int ds = (m_power_on && m_leds_decay[di] != 0) ? 1 : 0;
active_state[i] |= (ds << j);
}
}
-
+
// on difference, send to output
for (int i = 0; i < 0x10; i++)
if (m_leds_cache[i] != active_state[i])
output_set_digit_value(i, active_state[i]);
-
+
memcpy(m_leds_cache, active_state, sizeof(m_leds_cache));
}
@@ -111,7 +111,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(stopthief_state::leds_decay_tick)
for (int i = 0; i < 0x100; i++)
if (!(m_leds_state[i & 0xf] >> (i>>4) & 1) && m_leds_decay[i])
m_leds_decay[i]--;
-
+
leds_update();
}
@@ -145,9 +145,9 @@ WRITE16_MEMBER(stopthief_state::write_r)
UINT8 o = BITSWAP8(m_o,3,5,2,1,4,0,6,7) & 0x7f;
for (int i = 0; i < 3; i++)
m_leds_state[i] = (data >> i & 1) ? o : 0;
-
+
leds_update();
-
+
// R3-R8: speaker on
m_speaker->level_w((data & 0x1f8 && m_o & 8) ? 1 : 0);
}
@@ -261,7 +261,7 @@ static MACHINE_CONFIG_START( stopthief, stopthief_state )
MCFG_TMS1XXX_POWER_OFF_CB(WRITELINE(stopthief_state, auto_power_off))
MCFG_TIMER_DRIVER_ADD_PERIODIC("leds_decay", stopthief_state, leds_decay_tick, attotime::from_msec(10))
-
+
MCFG_DEFAULT_LAYOUT(layout_stopthie)
/* no video! */
diff --git a/src/mess/drivers/tandy12.c b/src/mess/drivers/tandy12.c
index d0a0b58cecd..d3ddb9b564e 100644
--- a/src/mess/drivers/tandy12.c
+++ b/src/mess/drivers/tandy12.c
@@ -4,22 +4,22 @@
Tandy Radio Shack Computerized Arcade (1981, 1982, 1995)
* TMS1100 CD7282SL
-
+
This handheld contains 12 minigames. It looks and plays like "Fabulous Fred"
by the Japanese company Mego Corp. in 1980, which in turn is a mix of Merlin
and Simon. Unlike Merlin and Simon, spin-offs like these were not successful.
There were releases with and without the prefix "Tandy-12", I don't know
which name was more common. Also not worth noting is that it needed five
batteries; 4 C-cells and a 9-volt.
-
+
Some of the games require accessories included with the toy (eg. the Baseball
game is played with a board representing the playing field). To start a game,
hold the [SELECT] button, then press [START] when the game button lights up.
As always, refer to the official manual for more information.
-
+
See below at the input defs for a list of the games.
-
+
TODO:
- output PLA is not verified
- microinstructions PLA is not verified
@@ -70,7 +70,7 @@ public:
READ8_MEMBER(tandy12_state::read_k)
{
UINT8 k = 0;
-
+
// read selected button rows
for (int i = 0; i < 5; i++)
if (m_r >> (i+5) & 1)
@@ -114,10 +114,10 @@ WRITE16_MEMBER(tandy12_state::write_r)
[purple]1 [blue]5 [l-green]9
ORGAN TAG-IT TREASURE HUNT
-
+
[l-orange]2 [turquoise]6 [red]10
SONG WRITER ROULETTE COMPETE
-
+
[pink]3 [yellow]7 [violet]11
REPEAT BASEBALL FIRE AWAY
@@ -180,7 +180,7 @@ static const UINT16 tandy12_output_pla[0x20] =
// these are certain
0x00, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40,
0x80, 0x00, 0x00, 0x00, 0x00,
-
+
// rest is unused?
0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
diff --git a/src/mess/drivers/ticalc1x.c b/src/mess/drivers/ticalc1x.c
index 7af0d941fc5..28f11c197aa 100644
--- a/src/mess/drivers/ticalc1x.c
+++ b/src/mess/drivers/ticalc1x.c
@@ -3,10 +3,10 @@
/***************************************************************************
Texas Instruments TMS1xxx/0970/0980 handheld calculators (mostly single-chip)
-
+
Refer to their official manuals on how to use them.
-
+
TODO:
- MCU clocks are unknown
@@ -85,31 +85,31 @@ public:
void ticalc1x_state::leds_update()
{
UINT16 active_state[0x10];
-
+
for (int i = 0; i < 0x10; i++)
{
active_state[i] = 0;
-
+
for (int j = 0; j < 0x10; j++)
{
int di = j << 4 | i;
-
+
// turn on powered leds
if (m_leds_state[i] >> j & 1)
m_leds_decay[di] = LEDS_DECAY_TIME;
-
+
// determine active state
int ds = (m_power_on && m_leds_decay[di] != 0) ? 1 : 0;
active_state[i] |= (ds << j);
}
}
-
+
// on difference, send to output
for (int i = 0; i < 0x10; i++)
if (m_leds_cache[i] != active_state[i])
{
output_set_digit_value(i, active_state[i]);
-
+
for (int j = 0; j < 8; j++)
output_set_lamp_value(i*10 + j, active_state[i] >> j & 1);
}
@@ -123,7 +123,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(ticalc1x_state::leds_decay_tick)
for (int i = 0; i < 0x100; i++)
if (!(m_leds_state[i & 0xf] >> (i>>4) & 1) && m_leds_decay[i])
m_leds_decay[i]--;
-
+
leds_update();
}
@@ -143,7 +143,7 @@ void ticalc1x_state::tisr16_leds_update()
for (int i = 0; i < 11; i++)
if (m_r >> i & 1)
m_leds_state[i] = m_o;
-
+
// exponent sign (not 100% sure this is correct)
m_leds_state[11] = (m_leds_state[0] | m_leds_state[1]) ? 0x40 : 0;
@@ -169,7 +169,7 @@ WRITE16_MEMBER(ticalc1x_state::tisr16_write_r)
// R0-R10: input mux
// R0-R10: select digit (right-to-left)
m_r = data;
-
+
tisr16_leds_update();
}
@@ -233,7 +233,7 @@ WRITE16_MEMBER(ticalc1x_state::wizatron_write_r)
// note: 3rd digit is custom(not 7seg), for math symbols
for (int i = 0; i < 9; i++)
m_leds_state[i] = (data >> i & 1) ? m_o : 0;
-
+
// 6th digit only has A and G for =
m_leds_state[3] &= 0x41;
@@ -272,7 +272,7 @@ WRITE16_MEMBER(ticalc1x_state::ti30_write_r)
UINT8 o = BITSWAP8(m_o,7,5,2,1,4,0,6,3);
for (int i = 0; i < 9; i++)
m_leds_state[i] = (data >> i & 1) ? o : 0;
-
+
// 1st digit only has segments B,F,G,DP
m_leds_state[0] &= 0xe2;
diff --git a/src/mess/drivers/tispeak.c b/src/mess/drivers/tispeak.c
index 61e22e5c49d..26419b897e0 100644
--- a/src/mess/drivers/tispeak.c
+++ b/src/mess/drivers/tispeak.c
@@ -3,9 +3,9 @@
/***************************************************************************
Texas Instruments Speak & Spell hardware
-
+
(still need to write notes here..)
-
+
Other stuff on similar hardware:
- Language Tutor/Translator
- Touch & Tell, but it runs on a TMS1100!
@@ -134,7 +134,7 @@ void tispeak_state::display_update()
// schedule delayed filament-off
m_filoff_timer->adjust(attotime::from_msec(FILOFF_DECAY_TIME));
}
-
+
// update digit state
for (int i = 0; i < 9; i++)
if (m_r >> i & 1)
@@ -145,7 +145,7 @@ void tispeak_state::display_update()
{
// standard led14seg
output_set_digit_value(i, m_filament_on ? m_digit_state[i] & 0x3fff : 0);
-
+
// DP(display point) and AP(apostrophe) segments as lamps
output_set_lamp_value(i*10 + 0, m_digit_state[i] >> 14 & m_filament_on);
output_set_lamp_value(i*10 + 1, m_digit_state[i] >> 15 & m_filament_on);
@@ -233,7 +233,7 @@ WRITE16_MEMBER(tispeak_state::snmath_write_o)
INPUT_CHANGED_MEMBER(tispeak_state::power_button)
{
int on = (int)(FPTR)param;
-
+
if (on && !m_power_on)
{
m_power_on = 1;
@@ -391,7 +391,7 @@ void tispeak_state::machine_start()
save_item(NAME(m_o));
save_item(NAME(m_filament_on));
save_item(NAME(m_power_on));
-
+
// init cartridge
if (m_cart != NULL && m_cart->exists())
{
@@ -442,7 +442,7 @@ static MACHINE_CONFIG_DERIVED( snspell, snmath )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_TMS1XXX_WRITE_O_CB(WRITE16(tispeak_state, snspell_write_o))
-
+
/* cartridge */
MCFG_GENERIC_CARTSLOT_ADD("cartslot", generic_plain_slot, "snspell")
MCFG_GENERIC_EXTENSIONS("vsm")
diff --git a/src/mess/drivers/trs80.c b/src/mess/drivers/trs80.c
index 7d5ff95779c..1e05bff8aad 100644
--- a/src/mess/drivers/trs80.c
+++ b/src/mess/drivers/trs80.c
@@ -5,7 +5,7 @@ TRS80 memory map
0000-2fff ROM R D0-D7
3000-37ff ROM on Model III R D0-D7
- unused on Model I
+ unused on Model I
37de UART status R/W D0-D7
37df UART data R/W D0-D7
37e0 interrupt latch address (lnw80 = for the realtime clock)
@@ -16,7 +16,7 @@ TRS80 memory map
37e5 select disk drive 2 W
37e7 select disk drive 3 W
37e0-37e3 floppy motor W D0-D3
- or floppy head select W D3
+ or floppy head select W D3
37e8 send a byte to printer W D0-D7
37e8 read printer status R D7
37ec-37ef FDC WD179x R/W D0-D7
@@ -42,10 +42,10 @@ It is assumed that the TRS80L2 UART setup is identical to the System80, apart fr
Due to the above, the only working emulated UART is for the Model 3.
Cassette baud rates: Model I level I - 250 baud
- Model I level II and all clones - 500 baud
- Model III/4 - 500 and 1500 baud selectable at boot time
- - When it says "Cass?" press L for 500 baud, or Enter otherwise.
- LNW-80 - 500 baud @1.77MHz and 1000 baud @4MHz.
+ Model I level II and all clones - 500 baud
+ Model III/4 - 500 and 1500 baud selectable at boot time
+ - When it says "Cass?" press L for 500 baud, or Enter otherwise.
+ LNW-80 - 500 baud @1.77MHz and 1000 baud @4MHz.
I/O ports
FF:
@@ -92,29 +92,29 @@ Model 4 - C0-CF = hard drive (optional)
- 80-8F hires graphics (optional)
About the ht1080z - This was made for schools in Hungary. Each comes with a BASIC extension roms
- which activated Hungarian features. To activate - start emulation - enter SYSTEM
- Enter /12288 and the extensions will be installed and you are returned to READY.
- The ht1080z is identical to the System 80, apart from the character rom.
- The ht1080z2 has a modified extension rom and character generator.
+ which activated Hungarian features. To activate - start emulation - enter SYSTEM
+ Enter /12288 and the extensions will be installed and you are returned to READY.
+ The ht1080z is identical to the System 80, apart from the character rom.
+ The ht1080z2 has a modified extension rom and character generator.
About the RTC - The time is incremented while ever the cursor is flashing. It is stored in a series
- of bytes in the computer's work area. The bytes are in a certain order, this is:
- seconds, minutes, hours, year, day, month. On a model 1, the seconds are stored at
- 0x4041, while on the model 4 it is 0x4217. A reboot always sets the time to zero.
+ of bytes in the computer's work area. The bytes are in a certain order, this is:
+ seconds, minutes, hours, year, day, month. On a model 1, the seconds are stored at
+ 0x4041, while on the model 4 it is 0x4217. A reboot always sets the time to zero.
Model 4 memory organisation -
- Mode 0: ROM=0-37E7 and 37EA-3FFF; Printer=37E8-37E9; Keyboard=3800-3BFF; Video=3C00-3FFF
- Mode 1: Keyboard and Video as above; 0-3FFF read=ROM and write=RAM
- Mode 2: Keyboard=F400-F7FF; Video=F800-FFFF; the rest is RAM
- Mode 3: All RAM
- In the "maincpu" memory map, the first 64k is given to the ROM, keyboard, printer and video,
- while the second 64k is RAM that is switched in as needed. The area from 4800-FFFF
- is considered a "black hole", any writes to there will disappear.
- The video is organised as 2 banks of 0x400 bytes, except in Mode 2 where it becomes contiguous.
+ Mode 0: ROM=0-37E7 and 37EA-3FFF; Printer=37E8-37E9; Keyboard=3800-3BFF; Video=3C00-3FFF
+ Mode 1: Keyboard and Video as above; 0-3FFF read=ROM and write=RAM
+ Mode 2: Keyboard=F400-F7FF; Video=F800-FFFF; the rest is RAM
+ Mode 3: All RAM
+ In the "maincpu" memory map, the first 64k is given to the ROM, keyboard, printer and video,
+ while the second 64k is RAM that is switched in as needed. The area from 4800-FFFF
+ is considered a "black hole", any writes to there will disappear.
+ The video is organised as 2 banks of 0x400 bytes, except in Mode 2 where it becomes contiguous.
Model 4P - is the same as Model 4 except:
- - ROM is only 0000-0FFF, while 1000-37FF is given over to RAM
- - There is no cassette support in hardware.
+ - ROM is only 0000-0FFF, while 1000-37FF is given over to RAM
+ - There is no cassette support in hardware.
***************************************************************************
diff --git a/src/mess/drivers/unk3403.c b/src/mess/drivers/unk3403.c
index 343328ffed5..cf1fc6391c0 100644
--- a/src/mess/drivers/unk3403.c
+++ b/src/mess/drivers/unk3403.c
@@ -3,15 +3,15 @@
/***************************************************************************
TMS1100NLL MP3403 DBS 7836 SINGAPORE some game board with 7-segs.
-
+
What old electronic game is this?
-
+
some clues:
- it's from 1978
- Merlin is MP3404, Amaze-A-Tron is MP3405, this one is MP3403
- it plays some short jingles (you need to be lucky with button mashing),
jingles feel like maybe a horse racing game
-
+
***************************************************************************/
#include "emu.h"
@@ -42,9 +42,9 @@ public:
DECLARE_READ8_MEMBER(read_k);
DECLARE_WRITE16_MEMBER(write_o);
DECLARE_WRITE16_MEMBER(write_r);
-
+
void leds_update();
-
+
virtual void machine_start();
};
@@ -73,7 +73,7 @@ void unk3403_state::leds_update()
sprintf(dig, "\n %X %c %02X",i, (m_r >> i & 1) ? 'X' : '_', leds[i]);
strcat(msg, dig);
}
-
+
popmessage("%s", msg);
}
@@ -87,7 +87,7 @@ READ8_MEMBER(unk3403_state::read_k)
if (m_r >> (i + 4) & 1)
k |= m_button_matrix[i]->read();
}
-
+
return k;
}
@@ -97,7 +97,7 @@ WRITE16_MEMBER(unk3403_state::write_r)
// R10: maybe a switch or other button row?
// R9: speaker out
m_speaker->level_w(data >> 9 & 1);
-
+
// others: ?
m_r = data;
leds_update();
@@ -156,7 +156,7 @@ void unk3403_state::machine_start()
{
m_r = 0;
m_o = 0;
-
+
save_item(NAME(m_r));
save_item(NAME(m_o));
}
diff --git a/src/mess/drivers/victor9k.c b/src/mess/drivers/victor9k.c
index b33898e5871..5cbce2fa289 100644
--- a/src/mess/drivers/victor9k.c
+++ b/src/mess/drivers/victor9k.c
@@ -14,11 +14,11 @@
TODO:
- keyboard
- - expansion bus
- - Z80 card
- - Winchester DMA card (Xebec S1410 + Tandon TM502/TM603SE)
- - RAM cards
- - clock cards
+ - expansion bus
+ - Z80 card
+ - Winchester DMA card (Xebec S1410 + Tandon TM502/TM603SE)
+ - RAM cards
+ - clock cards
- floppy 8048
- hires graphics
- brightness/contrast
diff --git a/src/mess/drivers/vt240.c b/src/mess/drivers/vt240.c
index aa05c3e60c4..f14845b6c46 100644
--- a/src/mess/drivers/vt240.c
+++ b/src/mess/drivers/vt240.c
@@ -205,10 +205,10 @@ static MACHINE_CONFIG_FRAGMENT( vt240_motherboard )
MCFG_T11_INITIAL_MODE(5 << 13)
/*
- MCFG_CPU_ADD("charcpu", I8085A, XTAL_16MHz / 4)
- MCFG_CPU_PROGRAM_MAP(vt240_char_mem)
- MCFG_CPU_IO_MAP(vt240_char_io)
- MCFG_CPU_VBLANK_INT_DRIVER("screen", vt240_state, vt240_irq)
+ MCFG_CPU_ADD("charcpu", I8085A, XTAL_16MHz / 4)
+ MCFG_CPU_PROGRAM_MAP(vt240_char_mem)
+ MCFG_CPU_IO_MAP(vt240_char_io)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", vt240_state, vt240_irq)
*/
MCFG_SCREEN_ADD("screen", RASTER)
@@ -216,7 +216,7 @@ static MACHINE_CONFIG_FRAGMENT( vt240_motherboard )
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */
MCFG_SCREEN_SIZE(640, 480)
MCFG_SCREEN_VISIBLE_AREA(0, 640-1, 0, 480-1)
-// MCFG_VIDEO_START_OVERRIDE(vt240_state,vt240)
+// MCFG_VIDEO_START_OVERRIDE(vt240_state,vt240)
MCFG_SCREEN_UPDATE_DEVICE("upd7220", upd7220_device, screen_update)
MCFG_PALETTE_ADD_BLACK_AND_WHITE("palette")
MCFG_GFXDECODE_ADD("gfxdecode", "palette", vt240)
@@ -226,17 +226,17 @@ static MACHINE_CONFIG_FRAGMENT( vt240_motherboard )
MCFG_UPD7220_DRAW_TEXT_CALLBACK_OWNER(vt240_state, hgdc_draw_text)
MCFG_MC68681_ADD("duart", XTAL_3_6864MHz) /* 2681 duart (not 68681!) */
-// MCFG_MC68681_IRQ_CALLBACK(WRITELINE(dectalk_state, dectalk_duart_irq_handler))
+// MCFG_MC68681_IRQ_CALLBACK(WRITELINE(dectalk_state, dectalk_duart_irq_handler))
MCFG_MC68681_A_TX_CALLBACK(DEVWRITELINE("rs232", rs232_port_device, write_txd))
-// MCFG_MC68681_B_TX_CALLBACK(WRITELINE(dectalk_state, dectalk_duart_txa))
-// MCFG_MC68681_INPORT_CALLBACK(READ8(dectalk_state, dectalk_duart_input))
-// MCFG_MC68681_OUTPORT_CALLBACK(WRITE8(dectalk_state, dectalk_duart_output))
-// MCFG_I8251_DTR_HANDLER(DEVWRITELINE("rs232", rs232_port_device, write_dtr))
-// MCFG_I8251_RTS_HANDLER(DEVWRITELINE("rs232", rs232_port_device, write_rts))
+// MCFG_MC68681_B_TX_CALLBACK(WRITELINE(dectalk_state, dectalk_duart_txa))
+// MCFG_MC68681_INPORT_CALLBACK(READ8(dectalk_state, dectalk_duart_input))
+// MCFG_MC68681_OUTPORT_CALLBACK(WRITE8(dectalk_state, dectalk_duart_output))
+// MCFG_I8251_DTR_HANDLER(DEVWRITELINE("rs232", rs232_port_device, write_dtr))
+// MCFG_I8251_RTS_HANDLER(DEVWRITELINE("rs232", rs232_port_device, write_rts))
MCFG_RS232_PORT_ADD("rs232", default_rs232_devices, "null_modem")
MCFG_RS232_RXD_HANDLER(DEVWRITELINE("duart", mc68681_device, rx_a_w))
-// MCFG_RS232_DSR_HANDLER(DEVWRITELINE("duart", mc68681_device, ipX_w))
+// MCFG_RS232_DSR_HANDLER(DEVWRITELINE("duart", mc68681_device, ipX_w))
MACHINE_CONFIG_END
static MACHINE_CONFIG_START( mc7105, vt240_state )
@@ -244,7 +244,7 @@ static MACHINE_CONFIG_START( mc7105, vt240_state )
// serial connection to MS7004 keyboard
MCFG_DEVICE_ADD("i8251", I8251, 0)
-// MCFG_I8251_RXRDY_HANDLER(DEVWRITELINE("pic8259", pic8259_device, ir1_w))
+// MCFG_I8251_RXRDY_HANDLER(DEVWRITELINE("pic8259", pic8259_device, ir1_w))
MCFG_DEVICE_ADD("ms7004", MS7004, 0)
MCFG_MS7004_TX_HANDLER(DEVWRITELINE("i8251", i8251_device, write_rxd))
diff --git a/src/mess/includes/victor9k.h b/src/mess/includes/victor9k.h
index f27f07fd501..a010d424d37 100644
--- a/src/mess/includes/victor9k.h
+++ b/src/mess/includes/victor9k.h
@@ -48,7 +48,7 @@
#define RS232_A_TAG "rs232a"
#define RS232_B_TAG "rs232b"
#define SCREEN_TAG "screen"
-#define KB_TAG "kb"
+#define KB_TAG "kb"
#define FDC_TAG "fdc"
class victor9k_state : public driver_device
diff --git a/src/mess/layout/starwbc.lay b/src/mess/layout/starwbc.lay
index 0005b6c679a..6469cb7dc9a 100644
--- a/src/mess/layout/starwbc.lay
+++ b/src/mess/layout/starwbc.lay
@@ -50,7 +50,7 @@
<view name="Internal Layout">
<bounds left="0" right="165" top="0" bottom="105" />
-
+
<bezel element="static_yellow"><bounds x="3" y="17" width="10" height="83" /></bezel>
<bezel element="static_black"><bounds x="4" y="18" width="8" height="81" /></bezel>
@@ -75,9 +75,9 @@
<bezel element="text_3"><bounds x="64.5" y="4" width="8" height="8" /></bezel>
<bezel element="text_4"><bounds x="84.5" y="4" width="8" height="8" /></bezel>
-
+
<!-- lamp matrix -->
-
+
<bezel element="static_gray"><bounds x="17" y="17" width="83" height="83" /></bezel>
<bezel name="lamp20" element="lamp"><bounds x="20" y="20" width="17" height="17" /></bezel>
diff --git a/src/mess/machine/gamecom.c b/src/mess/machine/gamecom.c
index 0ca4496d6dc..2395f30d318 100644
--- a/src/mess/machine/gamecom.c
+++ b/src/mess/machine/gamecom.c
@@ -500,7 +500,7 @@ WRITE8_MEMBER( gamecom_state::gamecom_handle_dma )
UINT16 dest_addr = m_dma.dest_current & m_dma.dest_mask;
UINT8 dest_adj = (3 - (m_dma.dest_x_current & 3)) << 1;
UINT8 src_adj = (3 - (m_dma.source_x_current & 3)) << 1;
-
+
/* handle DMA for 1 pixel */
// Get new pixel
UINT8 source_pixel = (m_dma.source_bank[src_addr] >> src_adj) & 3;
diff --git a/src/mess/machine/ngen_kb.c b/src/mess/machine/ngen_kb.c
index 498a49dd7fb..8913296100c 100644
--- a/src/mess/machine/ngen_kb.c
+++ b/src/mess/machine/ngen_kb.c
@@ -216,4 +216,3 @@ void ngen_keyboard_device::rcv_complete()
}
const device_type NGEN_KEYBOARD = &device_creator<ngen_keyboard_device>;
-
diff --git a/src/mess/machine/sms.c b/src/mess/machine/sms.c
index 76c2bf0e527..ed3ed5ad016 100644
--- a/src/mess/machine/sms.c
+++ b/src/mess/machine/sms.c
@@ -1299,7 +1299,7 @@ void sms_state::screen_gg_sms_mode_scaling(screen_device &screen, bitmap_rgb32 &
/* Do horizontal scaling */
for (int plot_x = plot_min_x; plot_x <= plot_max_x;)
{
- for (int j = (plot_x - plot_x_group); j <= MIN(1, plot_max_x - plot_x_group); j++)
+ for (int j = (plot_x - plot_x_group); j <= MIN(1, plot_max_x - plot_x_group); j++)
{
if (sms_x + j >= vdp_bitmap.cliprect().min_x && sms_x + j + 1 <= vdp_bitmap.cliprect().max_x)
{
@@ -1366,8 +1366,8 @@ void sms_state::screen_gg_sms_mode_scaling(screen_device &screen, bitmap_rgb32 &
rgb_t c4 = line4[plot_x];
p_bitmap[plot_x] =
rgb_t( ( c1.r() / 6 + c2.r() / 3 + c3.r() / 3 + c4.r() / 6 ),
- ( c1.g() / 6 + c2.g() / 3 + c3.g() / 3 + c4.g() / 6 ),
- ( c1.b() / 6 + c2.b() / 3 + c3.b() / 3 + c4.b() / 6 ) );
+ ( c1.g() / 6 + c2.g() / 3 + c3.g() / 3 + c4.g() / 6 ),
+ ( c1.b() / 6 + c2.b() / 3 + c3.b() / 3 + c4.b() / 6 ) );
}
}
}
diff --git a/src/mess/machine/victor9k_fdc.c b/src/mess/machine/victor9k_fdc.c
index f2c3b2778dc..060d95f80ba 100644
--- a/src/mess/machine/victor9k_fdc.c
+++ b/src/mess/machine/victor9k_fdc.c
@@ -11,20 +11,20 @@
/*
- value error description
+ value error description
- 01 no sync pulse detected
- 02 no header track
- 03 checksum error in header
- 04 not right track
- 05 not right sector
- 06 not a data block
- 07 data checksum error
- 08 sync too long
- 99 not a system disc
+ 01 no sync pulse detected
+ 02 no header track
+ 03 checksum error in header
+ 04 not right track
+ 05 not right sector
+ 06 not a data block
+ 07 data checksum error
+ 08 sync too long
+ 99 not a system disc
- 11 Noise on sync
- FF No sync (bad or unformatted disk)
+ 11 Noise on sync
+ FF No sync (bad or unformatted disk)
*/
@@ -32,9 +32,9 @@
TODO:
- - communication error with SCP after loading boot sector
- - bp ff1a8
- - patch ff1ab=c3
+ - communication error with SCP after loading boot sector
+ - bp ff1a8
+ - patch ff1ab=c3
- single/double sided jumper
- header sync length unknown (6 is too short)
- 8048 spindle speed control
@@ -60,17 +60,17 @@
// this is exactly the same decode/encode as used in the Commodore 4040/8050 series drives
#define GCR_DECODE(_e, _i) \
- ((BIT(_e, 6) << 7) | (BIT(_i, 7) << 6) | (_e & 0x33) | (BIT(_e, 2) << 3) | (_i & 0x04))
+ ((BIT(_e, 6) << 7) | (BIT(_i, 7) << 6) | (_e & 0x33) | (BIT(_e, 2) << 3) | (_i & 0x04))
// E7 E6 I7 E5 E4 E3 E2 I2 E1 E0
#define GCR_ENCODE(_e, _i) \
- ((_e & 0xc0) << 2 | (_i & 0x80) | (_e & 0x3c) << 1 | (_i & 0x04) | (_e & 0x03))
+ ((_e & 0xc0) << 2 | (_i & 0x80) | (_e & 0x3c) << 1 | (_i & 0x04) | (_e & 0x03))
// Tandon TM-100 spindle @ 300RPM, measured TACH 12VAC 256Hz
// TACH = RPM / 60 * SPINDLE RATIO * MOTOR POLES
// 256 = 300 / 60 * 6.4 * 8
-#define SPINDLE_RATIO 6.4
-#define MOTOR_POLES 8
+#define SPINDLE_RATIO 6.4
+#define MOTOR_POLES 8
// TODO wrong values here! motor speed is controlled by an LM2917, with help from the spindle TACH and a DAC0808 whose value is set by the SCP 8048
const int victor_9000_fdc_t::rpm[] = { 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 252, 254, 255, 257, 259, 260, 262, 264, 266, 267, 269, 271, 273, 275, 276, 278, 280, 282, 284, 286, 288, 290, 291, 293, 295, 297, 299, 301, 303, 305, 307, 309, 311, 313, 315, 318, 320, 322, 324, 326, 328, 330, 333, 335, 337, 339, 342, 344, 346, 348, 351, 353, 355, 358, 360, 362, 365, 367, 370, 372, 375, 377, 380, 382, 385, 387, 390, 392, 395, 398, 400, 403, 406, 408, 411, 414, 416, 419, 422, 425, 428, 430, 433, 436, 439, 442, 445, 448, 451, 454, 457, 460, 463, 466, 469, 472, 475, 478, 482, 485, 488, 491, 494, 498, 501, 504, 508, 511, 514, 518, 521, 525, 528, 532, 535, 539, 542, 546, 550, 553, 557, 561, 564, 568, 572, 576, 579, 583, 587, 591, 595, 599, 603, 607, 611, 615, 619, 623, 627, 631, 636, 640, 644, 648, 653, 657, 661, 666, 670, 674, 679, 683, 688, 693, 697, 702, 706, 711, 716, 721, 725, 730, 735, 740, 745, 750, 755, 760, 765, 770, 775, 780, 785, 790, 796, 801, 806, 812, 817, 822, 828, 833, 839, 844, 850, 856, 861, 867, 873, 878, 884 };
diff --git a/src/mess/machine/victor9kb.c b/src/mess/machine/victor9kb.c
index 2774feffffa..291c62b62cf 100644
--- a/src/mess/machine/victor9kb.c
+++ b/src/mess/machine/victor9kb.c
@@ -347,7 +347,7 @@ Y11 104 103 102 101 100 99 98 97 kN/A k. k00 k0 RGHT LEFT PAUS
#define I8021_TAG "z3"
-#define LOG 0
+#define LOG 0
@@ -433,7 +433,7 @@ INPUT_PORTS_START( victor9k_keyboard )
PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("W") PORT_CODE(KEYCODE_W) PORT_CHAR('w') PORT_CHAR('W') // S36
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("A") PORT_CODE(KEYCODE_A) PORT_CHAR('a') PORT_CHAR('A') // S56
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("S") PORT_CODE(KEYCODE_S) PORT_CHAR('s') PORT_CHAR('S') // S57
- PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("UNUSED S75") // unused // S75
+ PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("UNUSED S75") // unused // S75
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("Z") PORT_CODE(KEYCODE_Z) PORT_CHAR('z') PORT_CHAR('Z') // S76
PORT_START("Y2")
diff --git a/src/mess/mess.mak b/src/mess/mess.mak
index 9b88e02231a..2c452ee535e 100644
--- a/src/mess/mess.mak
+++ b/src/mess/mess.mak
@@ -1302,7 +1302,7 @@ $(MESSOBJ)/hp.a: \
$(MESS_DRIVERS)/hp49gp.o \
$(MESS_DRIVERS)/hp9845.o \
$(MESS_DRIVERS)/hp9k.o \
- $(MESS_DRIVERS)/hp9k_3xx.o \
+ $(MESS_DRIVERS)/hp9k_3xx.o \
$(MESSOBJ)/hec2hrp.a: \
diff --git a/src/mess/video/apple2.c b/src/mess/video/apple2.c
index 2d46ffaf82b..1e3c3311354 100644
--- a/src/mess/video/apple2.c
+++ b/src/mess/video/apple2.c
@@ -1209,7 +1209,7 @@ void a2_video_device::hgr_update(screen_device &screen, bitmap_ind16 &bitmap, co
}
else
{
- artifact_map_ptr = &m_hires_artifact_map[((vram_row[col + 1] & 0x80) >> 7) * 16];
+ artifact_map_ptr = &m_hires_artifact_map[((vram_row[col + 1] & 0x80) >> 7) * 16];
}
for (b = 0; b < 7; b++)
{
diff --git a/src/mess/video/maria.c b/src/mess/video/maria.c
index 7d9679561dc..6c0841b8cef 100644
--- a/src/mess/video/maria.c
+++ b/src/mess/video/maria.c
@@ -4,8 +4,8 @@
- some history:
- 2014-12-01 Mike Saarna, Robert Tuccitto Implemented "colorburst kill" bit
- of the MARIA CTRL register.
+ 2014-12-01 Mike Saarna, Robert Tuccitto Implemented "colorburst kill" bit
+ of the MARIA CTRL register.
2014-10-05 Mike Saarna, Robert Tuccitto Last Line DMA value corrected
to 6. GCC and Atari docs both show a difference between
Other Line and Last Line as +6 at the lowest part of the
diff --git a/src/osd/modules/debugger/qt/debugqtdeviceswindow.c b/src/osd/modules/debugger/qt/debugqtdeviceswindow.c
index 10596a1c9f1..09b2fa8d7a5 100644
--- a/src/osd/modules/debugger/qt/debugqtdeviceswindow.c
+++ b/src/osd/modules/debugger/qt/debugqtdeviceswindow.c
@@ -14,8 +14,8 @@ DevicesWindowModel::~DevicesWindowModel()
QVariant DevicesWindowModel::data(const QModelIndex &index, int role) const
{
- if(!index.isValid() || role != Qt::DisplayRole)
- return QVariant();
+ if(!index.isValid() || role != Qt::DisplayRole)
+ return QVariant();
device_t *dev = static_cast<device_t *>(index.internalPointer());
switch(index.column()) {
@@ -43,8 +43,8 @@ QVariant DevicesWindowModel::headerData(int section, Qt::Orientation orientation
QModelIndex DevicesWindowModel::index(int row, int column, const QModelIndex &parent) const
{
- if(!hasIndex(row, column, parent))
- return QModelIndex();
+ if(!hasIndex(row, column, parent))
+ return QModelIndex();
device_t *target = NULL;
@@ -67,10 +67,10 @@ QModelIndex DevicesWindowModel::index(int row, int column, const QModelIndex &pa
QModelIndex DevicesWindowModel::parent(const QModelIndex &index) const
{
- if(!index.isValid())
- return QModelIndex();
+ if(!index.isValid())
+ return QModelIndex();
- device_t *dchild = static_cast<device_t *>(index.internalPointer());
+ device_t *dchild = static_cast<device_t *>(index.internalPointer());
device_t *dparent = dchild->owner();
if(!dparent)
@@ -82,14 +82,14 @@ QModelIndex DevicesWindowModel::parent(const QModelIndex &index) const
for(device_t *child = dpp->first_subdevice(); child && child != dparent; child = child->next())
row++;
}
- return createIndex(row, 0, dparent);
+ return createIndex(row, 0, dparent);
}
int DevicesWindowModel::rowCount(const QModelIndex &parent) const
{
if(!parent.isValid())
return 1;
-
+
device_t *dparent = static_cast<device_t *>(parent.internalPointer());
int count = 0;
for(device_t *child = dparent->first_subdevice(); child; child = child->next())
@@ -157,14 +157,14 @@ void DevicesWindow::activated(const QModelIndex &index)
void DevicesWindowQtConfig::buildFromQWidget(QWidget* widget)
{
WindowQtConfig::buildFromQWidget(widget);
- // DevicesWindow* window = dynamic_cast<DevicesWindow*>(widget);
+ // DevicesWindow* window = dynamic_cast<DevicesWindow*>(widget);
}
void DevicesWindowQtConfig::applyToQWidget(QWidget* widget)
{
WindowQtConfig::applyToQWidget(widget);
- // DevicesWindow* window = dynamic_cast<DevicesWindow*>(widget);
+ // DevicesWindow* window = dynamic_cast<DevicesWindow*>(widget);
}
diff --git a/src/osd/modules/debugger/qt/debugqtdeviceswindow.h b/src/osd/modules/debugger/qt/debugqtdeviceswindow.h
index 833d8d80aca..f541f303efd 100644
--- a/src/osd/modules/debugger/qt/debugqtdeviceswindow.h
+++ b/src/osd/modules/debugger/qt/debugqtdeviceswindow.h
@@ -23,11 +23,11 @@ public:
QVariant headerData(int section, Qt::Orientation orientation,
int role = Qt::DisplayRole) const;
QModelIndex index(int row, int column,
- const QModelIndex &parent = QModelIndex()) const;
+ const QModelIndex &parent = QModelIndex()) const;
QModelIndex parent(const QModelIndex &index) const;
int rowCount(const QModelIndex &parent = QModelIndex()) const;
int columnCount(const QModelIndex &parent = QModelIndex()) const;
-
+
private:
running_machine *m_machine;
};
@@ -44,8 +44,8 @@ public:
virtual ~DevicesWindow();
public slots:
- void currentRowChanged(const QModelIndex &current, const QModelIndex &previous);
- void activated(const QModelIndex &index);
+ void currentRowChanged(const QModelIndex &current, const QModelIndex &previous);
+ void activated(const QModelIndex &index);
private:
QTreeView *m_devices_view;
diff --git a/src/osd/sdl/input.c b/src/osd/sdl/input.c
index 7dbec939198..3fe3c7fcbb0 100644
--- a/src/osd/sdl/input.c
+++ b/src/osd/sdl/input.c
@@ -1941,7 +1941,7 @@ void sdlinput_poll(running_machine &machine)
machine.schedule_exit();
break;
case SDL_VIDEORESIZE:
- sdl_window_list->window_resize(event.resize.w, event.resize.h);
+ sdl_window_list->window_resize(event.resize.w, event.resize.h);
break;
#else
case SDL_TEXTINPUT:
diff --git a/src/osd/sdl/video.h b/src/osd/sdl/video.h
index 843583a8a06..195fd878f83 100644
--- a/src/osd/sdl/video.h
+++ b/src/osd/sdl/video.h
@@ -70,7 +70,7 @@ struct sdl_monitor_info
float aspect; // computed/configured aspect ratio of the physical device
int center_width; // width of first physical screen for centering
int center_height; // height of first physical screen for centering
- int monitor_x; // X position of this monitor in virtual desktop space (SDL virtual space has them all horizontally stacked, not real geometry)
+ int monitor_x; // X position of this monitor in virtual desktop space (SDL virtual space has them all horizontally stacked, not real geometry)
};
diff --git a/src/osd/sdl/window.c b/src/osd/sdl/window.c
index 91169f32f87..a08840fd852 100644
--- a/src/osd/sdl/window.c
+++ b/src/osd/sdl/window.c
@@ -101,33 +101,33 @@ static SDL_threadID window_threadid;
static sdl_draw_info draw;
struct worker_param {
- worker_param()
- : m_window(NULL), m_list(NULL), m_machine(NULL), m_resize_new_width(0), m_resize_new_height(0)
- {
- }
- worker_param(running_machine &amachine, sdl_window_info *awindow)
- : m_window(awindow), m_list(NULL), m_machine(&amachine), m_resize_new_width(0), m_resize_new_height(0)
- {
- }
- worker_param(running_machine &amachine, sdl_window_info *awindow, render_primitive_list *alist)
- : m_window(awindow), m_list(alist), m_machine(&amachine), m_resize_new_width(0), m_resize_new_height(0)
- {
- }
- worker_param(sdl_window_info *awindow, int anew_width, int anew_height)
- : m_window(awindow), m_list(NULL), m_machine(NULL), m_resize_new_width(anew_width), m_resize_new_height(anew_height)
- {
- }
- worker_param(sdl_window_info *awindow)
- : m_window(awindow), m_list(NULL), m_machine(NULL), m_resize_new_width(0), m_resize_new_height(0)
- {
- }
+ worker_param()
+ : m_window(NULL), m_list(NULL), m_machine(NULL), m_resize_new_width(0), m_resize_new_height(0)
+ {
+ }
+ worker_param(running_machine &amachine, sdl_window_info *awindow)
+ : m_window(awindow), m_list(NULL), m_machine(&amachine), m_resize_new_width(0), m_resize_new_height(0)
+ {
+ }
+ worker_param(running_machine &amachine, sdl_window_info *awindow, render_primitive_list *alist)
+ : m_window(awindow), m_list(alist), m_machine(&amachine), m_resize_new_width(0), m_resize_new_height(0)
+ {
+ }
+ worker_param(sdl_window_info *awindow, int anew_width, int anew_height)
+ : m_window(awindow), m_list(NULL), m_machine(NULL), m_resize_new_width(anew_width), m_resize_new_height(anew_height)
+ {
+ }
+ worker_param(sdl_window_info *awindow)
+ : m_window(awindow), m_list(NULL), m_machine(NULL), m_resize_new_width(0), m_resize_new_height(0)
+ {
+ }
running_machine &machine() const { assert(m_machine != NULL); return *m_machine; }
sdl_window_info *window() const { assert(m_window != NULL); return m_window; }
- render_primitive_list *list() const { return m_list; }
+ render_primitive_list *list() const { return m_list; }
int new_width() const { return m_resize_new_width; }
- int new_height() const { return m_resize_new_height; }
- // FIXME: only needed for window set-up which returns an error.
- void set_window(sdl_window_info *window) { m_window = window; }
+ int new_height() const { return m_resize_new_height; }
+ // FIXME: only needed for window set-up which returns an error.
+ void set_window(sdl_window_info *window) { m_window = window; }
private:
sdl_window_info *m_window;
render_primitive_list *m_list;
@@ -170,10 +170,10 @@ INLINE void execute_async(osd_work_callback callback, const worker_param &wp)
INLINE void execute_sync(osd_work_callback callback, const worker_param &wp)
{
- worker_param *wp_temp = (worker_param *) osd_malloc(sizeof(worker_param));
- *wp_temp = wp;
+ worker_param *wp_temp = (worker_param *) osd_malloc(sizeof(worker_param));
+ *wp_temp = wp;
- callback((void *) wp_temp, 0);
+ callback((void *) wp_temp, 0);
}
@@ -307,7 +307,7 @@ static OSDWORK_CALLBACK( sdlwindow_exit_wt )
void sdl_osd_interface::window_exit()
{
- worker_param wp_dummy;
+ worker_param wp_dummy;
ASSERT_MAIN_THREAD();
@@ -319,8 +319,8 @@ void sdl_osd_interface::window_exit()
sdl_window_info *temp = sdl_window_list;
sdl_window_list = temp->next;
temp->video_window_destroy(machine());
- // free the window itself
- global_free(temp);
+ // free the window itself
+ global_free(temp);
}
// if we're multithreaded, clean up the window thread
@@ -495,7 +495,7 @@ void sdl_window_info::window_clear()
execute_async_wait(&sdlwindow_clear_surface_wt, worker_param(this));
}
else
- execute_sync(&sdlwindow_clear_surface_wt, worker_param(this));
+ execute_sync(&sdlwindow_clear_surface_wt, worker_param(this));
}
@@ -651,12 +651,12 @@ static void sdlwindow_update_cursor_state(running_machine &machine, sdl_window_i
static OSDWORK_CALLBACK( sdlwindow_update_cursor_state_wt )
{
- worker_param * wp = (worker_param *) param;
- //sdl_window_info * window = wp->window;
+ worker_param * wp = (worker_param *) param;
+ //sdl_window_info * window = wp->window;
- sdlwindow_update_cursor_state(wp->machine(), wp->window());
+ sdlwindow_update_cursor_state(wp->machine(), wp->window());
- return NULL;
+ return NULL;
}
@@ -725,8 +725,8 @@ int sdlwindow_video_window_create(running_machine &machine, int index, sdl_monit
error:
window->video_window_destroy(machine);
- // free the window itself
- global_free(window);
+ // free the window itself
+ global_free(window);
return 1;
}
@@ -946,7 +946,7 @@ void sdl_window_info::video_window_update(running_machine &machine)
// adjust the cursor state
//sdlwindow_update_cursor_state(machine, window);
- execute_async(&sdlwindow_update_cursor_state_wt, worker_param(machine, this));
+ execute_async(&sdlwindow_update_cursor_state_wt, worker_param(machine, this));
// if we're visible and running and not in the middle of a resize, draw
if (target != NULL)
@@ -979,7 +979,7 @@ void sdl_window_info::video_window_update(running_machine &machine)
if (osd_event_wait(rendered_event, event_wait_ticks))
{
- // ensure the target bounds are up-to-date, and then get the primitives
+ // ensure the target bounds are up-to-date, and then get the primitives
render_primitive_list *primlist = &get_primitives(this);
// and redraw now
@@ -1038,7 +1038,7 @@ static OSDWORK_CALLBACK( complete_create_wt )
// if we're allowed to switch resolutions, override with something better
if (video_config.switchres)
- window->pick_best_mode(&tempwidth, &tempheight);
+ window->pick_best_mode(&tempwidth, &tempheight);
}
else if (window->windowed_width)
{
diff --git a/src/osd/sdl/window.h b/src/osd/sdl/window.h
index 39f518eab09..e8d96ef3d97 100644
--- a/src/osd/sdl/window.h
+++ b/src/osd/sdl/window.h
@@ -34,62 +34,61 @@ typedef UINT32 HashT;
struct sdl_window_info
{
-
- sdl_window_info(running_machine *a_machine, sdl_monitor_info *a_monitor,
- int index, const sdl_window_config *config)
- : next(NULL), m_minwidth(0), m_minheight(0),
- startmaximized(0),
- rendered_event(0), target(0), primlist(NULL), dxdata(NULL),
- width(0), height(0), blitwidth(0), blitheight(0),
- start_viewscreen(0),
+ sdl_window_info(running_machine *a_machine, sdl_monitor_info *a_monitor,
+ int index, const sdl_window_config *config)
+ : next(NULL), m_minwidth(0), m_minheight(0),
+ startmaximized(0),
+ rendered_event(0), target(0), primlist(NULL), dxdata(NULL),
+ width(0), height(0), blitwidth(0), blitheight(0),
+ start_viewscreen(0),
#if (SDLMAME_SDL2)
- sdl_window(NULL),
- resize_width(0),
- resize_height(0),
- last_resize(0),
+ sdl_window(NULL),
+ resize_width(0),
+ resize_height(0),
+ last_resize(0),
#else
- screen_width(0), screen_height(0),
+ screen_width(0), screen_height(0),
#endif
- m_machine(a_machine), m_monitor(a_monitor), m_fullscreen(0), m_index(0)
- {
- m_maxwidth = config->width;
- m_maxheight = config->height;
- depth = config->depth;
- refresh = config->refresh;
- m_index = index;
-
- //FIXME: these should be per_window in config-> or even better a bit set
- m_fullscreen = !video_config.windowed;
- prescale = video_config.prescale;
-
- if (!m_fullscreen)
- {
- windowed_width = config->width;
- windowed_height = config->height;
- }
- }
-
- void video_window_update(running_machine &machine);
- void blit_surface_size(int window_width, int window_height);
- void toggle_full_screen(running_machine &machine);
- void modify_prescale(running_machine &machine, int dir);
- void window_resize(INT32 width, INT32 height);
- void window_clear();
-
- void video_window_destroy(running_machine &machine);
- void pick_best_mode(int *fswidth, int *fsheight);
- void get_min_bounds(int *window_width, int *window_height, int constrain);
- void get_max_bounds(int *window_width, int *window_height, int constrain);
-
- // Pointer to next window
+ m_machine(a_machine), m_monitor(a_monitor), m_fullscreen(0), m_index(0)
+ {
+ m_maxwidth = config->width;
+ m_maxheight = config->height;
+ depth = config->depth;
+ refresh = config->refresh;
+ m_index = index;
+
+ //FIXME: these should be per_window in config-> or even better a bit set
+ m_fullscreen = !video_config.windowed;
+ prescale = video_config.prescale;
+
+ if (!m_fullscreen)
+ {
+ windowed_width = config->width;
+ windowed_height = config->height;
+ }
+ }
+
+ void video_window_update(running_machine &machine);
+ void blit_surface_size(int window_width, int window_height);
+ void toggle_full_screen(running_machine &machine);
+ void modify_prescale(running_machine &machine, int dir);
+ void window_resize(INT32 width, INT32 height);
+ void window_clear();
+
+ void video_window_destroy(running_machine &machine);
+ void pick_best_mode(int *fswidth, int *fsheight);
+ void get_min_bounds(int *window_width, int *window_height, int constrain);
+ void get_max_bounds(int *window_width, int *window_height, int constrain);
+
+ // Pointer to next window
sdl_window_info * next;
running_machine &machine() const { assert(m_machine != NULL); return *m_machine; }
sdl_monitor_info *monitor() const { return m_monitor; }
- int fullscreen() const { return m_fullscreen; }
- int index() const { return m_index; }
+ int fullscreen() const { return m_fullscreen; }
+ int index() const { return m_index; }
- void set_fullscreen(int afullscreen) { m_fullscreen = afullscreen; }
+ void set_fullscreen(int afullscreen) { m_fullscreen = afullscreen; }
// Draw Callbacks
int (*create)(sdl_window_info *window, int width, int height);
@@ -149,12 +148,12 @@ struct sdl_window_info
private:
void constrain_to_aspect_ratio(int *window_width, int *window_height, int adjustment);
- // Pointer to machine
- running_machine * m_machine;
- // monitor info
- sdl_monitor_info * m_monitor;
- int m_fullscreen;
- int m_index;
+ // Pointer to machine
+ running_machine * m_machine;
+ // monitor info
+ sdl_monitor_info * m_monitor;
+ int m_fullscreen;
+ int m_index;
};
diff --git a/src/version.c b/src/version.c
index 93121236803..ed6293382da 100644
--- a/src/version.c
+++ b/src/version.c
@@ -8,7 +8,7 @@
***************************************************************************/
-#define BARE_BUILD_VERSION "0.156"
+#define BARE_BUILD_VERSION "0.157"
extern const char bare_build_version[];
extern const char build_version[];